var mGe=Object.create;var PX=Object.defineProperty;var gGe=Object.getOwnPropertyDescriptor;var _Ge=Object.getOwnPropertyNames;var bGe=Object.getPrototypeOf,vGe=Object.prototype.hasOwnProperty;var u1e=(n=>typeof require<"u"?require:typeof Proxy<"u"?new Proxy(n,{get:(e,t)=>(typeof require<"u"?require:e)[t]}):n)(function(n){if(typeof require<"u")return require.apply(this,arguments);throw Error('Dynamic require of "'+n+'" is not supported')});var k=(n,e)=>()=>(n&&(e=n(n=0)),e);var ws=(n,e)=>()=>(e||n((e={exports:{}}).exports,e),e.exports),st=(n,e)=>{for(var t in e)PX(n,t,{get:e[t],enumerable:!0})},xGe=(n,e,t,i)=>{if(e&&typeof e=="object"||typeof e=="function")for(let o of _Ge(e))!vGe.call(n,o)&&o!==t&&PX(n,o,{get:()=>e[o],enumerable:!(i=gGe(e,o))||i.enumerable});return n};var Ue=(n,e,t)=>(t=n!=null?mGe(bGe(n)):{},xGe(e||!n||!n.__esModule?PX(t,"default",{value:n,enumerable:!0}):t,n));var C1e=ws(Sn=>{"use strict";var sN=Symbol.for("react.element"),wGe=Symbol.for("react.portal"),yGe=Symbol.for("react.fragment"),CGe=Symbol.for("react.strict_mode"),SGe=Symbol.for("react.profiler"),kGe=Symbol.for("react.provider"),LGe=Symbol.for("react.context"),IGe=Symbol.for("react.forward_ref"),EGe=Symbol.for("react.suspense"),TGe=Symbol.for("react.memo"),DGe=Symbol.for("react.lazy"),h1e=Symbol.iterator;function NGe(n){return n===null||typeof n!="object"?null:(n=h1e&&n[h1e]||n["@@iterator"],typeof n=="function"?n:null)}var m1e={isMounted:function(){return!1},enqueueForceUpdate:function(){},enqueueReplaceState:function(){},enqueueSetState:function(){}},g1e=Object.assign,_1e={};function IS(n,e,t){this.props=n,this.context=e,this.refs=_1e,this.updater=t||m1e}IS.prototype.isReactComponent={};IS.prototype.setState=function(n,e){if(typeof n!="object"&&typeof n!="function"&&n!=null)throw Error("setState(...): takes an object of state variables to update or a function which returns an object of state variables.");this.updater.enqueueSetState(this,n,e,"setState")};IS.prototype.forceUpdate=function(n){this.updater.enqueueForceUpdate(this,n,"forceUpdate")};function b1e(){}b1e.prototype=IS.prototype;function FX(n,e,t){this.props=n,this.context=e,this.refs=_1e,this.updater=t||m1e}var BX=FX.prototype=new b1e;BX.constructor=FX;g1e(BX,IS.prototype);BX.isPureReactComponent=!0;var f1e=Array.isArray,v1e=Object.prototype.hasOwnProperty,WX={current:null},x1e={key:!0,ref:!0,__self:!0,__source:!0};function w1e(n,e,t){var i,o={},r=null,s=null;if(e!=null)for(i in e.ref!==void 0&&(s=e.ref),e.key!==void 0&&(r=""+e.key),e)v1e.call(e,i)&&!x1e.hasOwnProperty(i)&&(o[i]=e[i]);var a=arguments.length-2;if(a===1)o.children=t;else if(1{"use strict";S1e.exports=C1e()});var M1e=ws(fr=>{"use strict";function $X(n,e){var t=n.length;n.push(e);e:for(;0>>1,o=n[i];if(0>>1;itF(a,t))ltF(c,a)?(n[i]=c,n[l]=t,i=l):(n[i]=a,n[s]=t,i=s);else if(ltF(c,t))n[i]=c,n[l]=t,i=l;else break e}}return e}function tF(n,e){var t=n.sortIndex-e.sortIndex;return t!==0?t:n.id-e.id}typeof performance=="object"&&typeof performance.now=="function"?(k1e=performance,fr.unstable_now=function(){return k1e.now()}):(zX=Date,L1e=zX.now(),fr.unstable_now=function(){return zX.now()-L1e});var k1e,zX,L1e,cm=[],vv=[],OGe=1,Yh=null,Lc=3,oF=!1,Ty=!1,lN=!1,T1e=typeof setTimeout=="function"?setTimeout:null,D1e=typeof clearTimeout=="function"?clearTimeout:null,I1e=typeof setImmediate<"u"?setImmediate:null;typeof navigator<"u"&&navigator.scheduling!==void 0&&navigator.scheduling.isInputPending!==void 0&&navigator.scheduling.isInputPending.bind(navigator.scheduling);function jX(n){for(var e=Zf(vv);e!==null;){if(e.callback===null)nF(vv);else if(e.startTime<=n)nF(vv),e.sortIndex=e.expirationTime,$X(cm,e);else break;e=Zf(vv)}}function qX(n){if(lN=!1,jX(n),!Ty)if(Zf(cm)!==null)Ty=!0,GX(KX);else{var e=Zf(vv);e!==null&&YX(qX,e.startTime-n)}}function KX(n,e){Ty=!1,lN&&(lN=!1,D1e(cN),cN=-1),oF=!0;var t=Lc;try{for(jX(e),Yh=Zf(cm);Yh!==null&&(!(Yh.expirationTime>e)||n&&!A1e());){var i=Yh.callback;if(typeof i=="function"){Yh.callback=null,Lc=Yh.priorityLevel;var o=i(Yh.expirationTime<=e);e=fr.unstable_now(),typeof o=="function"?Yh.callback=o:Yh===Zf(cm)&&nF(cm),jX(e)}else nF(cm);Yh=Zf(cm)}if(Yh!==null)var r=!0;else{var s=Zf(vv);s!==null&&YX(qX,s.startTime-e),r=!1}return r}finally{Yh=null,Lc=t,oF=!1}}var rF=!1,iF=null,cN=-1,N1e=5,R1e=-1;function A1e(){return!(fr.unstable_now()-R1en||125i?(n.sortIndex=t,$X(vv,n),Zf(cm)===null&&n===Zf(vv)&&(lN?(D1e(cN),cN=-1):lN=!0,YX(qX,t-i))):(n.sortIndex=o,$X(cm,n),Ty||oF||(Ty=!0,GX(KX))),n};fr.unstable_shouldYield=A1e;fr.unstable_wrapCallback=function(n){var e=Lc;return function(){var t=Lc;Lc=e;try{return n.apply(this,arguments)}finally{Lc=t}}}});var O1e=ws((Ukt,P1e)=>{"use strict";P1e.exports=M1e()});var HSe=ws(ih=>{"use strict";var FGe=Xe(),eh=O1e();function Ye(n){for(var e="https://reactjs.org/docs/error-decoder.html?invariant="+n,t=1;t"u"||typeof window.document>"u"||typeof window.document.createElement>"u"),bQ=Object.prototype.hasOwnProperty,BGe=/^[:A-Z_a-z\u00C0-\u00D6\u00D8-\u00F6\u00F8-\u02FF\u0370-\u037D\u037F-\u1FFF\u200C-\u200D\u2070-\u218F\u2C00-\u2FEF\u3001-\uD7FF\uF900-\uFDCF\uFDF0-\uFFFD][:A-Z_a-z\u00C0-\u00D6\u00D8-\u00F6\u00F8-\u02FF\u0370-\u037D\u037F-\u1FFF\u200C-\u200D\u2070-\u218F\u2C00-\u2FEF\u3001-\uD7FF\uF900-\uFDCF\uFDF0-\uFFFD\-.0-9\u00B7\u0300-\u036F\u203F-\u2040]*$/,F1e={},B1e={};function WGe(n){return bQ.call(B1e,n)?!0:bQ.call(F1e,n)?!1:BGe.test(n)?B1e[n]=!0:(F1e[n]=!0,!1)}function HGe(n,e,t,i){if(t!==null&&t.type===0)return!1;switch(typeof e){case"function":case"symbol":return!0;case"boolean":return i?!1:t!==null?!t.acceptsBooleans:(n=n.toLowerCase().slice(0,5),n!=="data-"&&n!=="aria-");default:return!1}}function zGe(n,e,t,i){if(e===null||typeof e>"u"||HGe(n,e,t,i))return!0;if(i)return!1;if(t!==null)switch(t.type){case 3:return!e;case 4:return e===!1;case 5:return isNaN(e);case 6:return isNaN(e)||1>e}return!1}function bd(n,e,t,i,o,r,s){this.acceptsBooleans=e===2||e===3||e===4,this.attributeName=i,this.attributeNamespace=o,this.mustUseProperty=t,this.propertyName=n,this.type=e,this.sanitizeURL=r,this.removeEmptyString=s}var Ql={};"children dangerouslySetInnerHTML defaultValue defaultChecked innerHTML suppressContentEditableWarning suppressHydrationWarning style".split(" ").forEach(function(n){Ql[n]=new bd(n,0,!1,n,null,!1,!1)});[["acceptCharset","accept-charset"],["className","class"],["htmlFor","for"],["httpEquiv","http-equiv"]].forEach(function(n){var e=n[0];Ql[e]=new bd(e,1,!1,n[1],null,!1,!1)});["contentEditable","draggable","spellCheck","value"].forEach(function(n){Ql[n]=new bd(n,2,!1,n.toLowerCase(),null,!1,!1)});["autoReverse","externalResourcesRequired","focusable","preserveAlpha"].forEach(function(n){Ql[n]=new bd(n,2,!1,n,null,!1,!1)});"allowFullScreen async autoFocus autoPlay controls default defer disabled disablePictureInPicture disableRemotePlayback formNoValidate hidden loop noModule noValidate open playsInline readOnly required reversed scoped seamless itemScope".split(" ").forEach(function(n){Ql[n]=new bd(n,3,!1,n.toLowerCase(),null,!1,!1)});["checked","multiple","muted","selected"].forEach(function(n){Ql[n]=new bd(n,3,!0,n,null,!1,!1)});["capture","download"].forEach(function(n){Ql[n]=new bd(n,4,!1,n,null,!1,!1)});["cols","rows","size","span"].forEach(function(n){Ql[n]=new bd(n,6,!1,n,null,!1,!1)});["rowSpan","start"].forEach(function(n){Ql[n]=new bd(n,5,!1,n.toLowerCase(),null,!1,!1)});var dJ=/[\-:]([a-z])/g;function uJ(n){return n[1].toUpperCase()}"accent-height alignment-baseline arabic-form baseline-shift cap-height clip-path clip-rule color-interpolation color-interpolation-filters color-profile color-rendering dominant-baseline enable-background fill-opacity fill-rule flood-color flood-opacity font-family font-size font-size-adjust font-stretch font-style font-variant font-weight glyph-name glyph-orientation-horizontal glyph-orientation-vertical horiz-adv-x horiz-origin-x image-rendering letter-spacing lighting-color marker-end marker-mid marker-start overline-position overline-thickness paint-order panose-1 pointer-events rendering-intent shape-rendering stop-color stop-opacity strikethrough-position strikethrough-thickness stroke-dasharray stroke-dashoffset stroke-linecap stroke-linejoin stroke-miterlimit stroke-opacity stroke-width text-anchor text-decoration text-rendering underline-position underline-thickness unicode-bidi unicode-range units-per-em v-alphabetic v-hanging v-ideographic v-mathematical vector-effect vert-adv-y vert-origin-x vert-origin-y word-spacing writing-mode xmlns:xlink x-height".split(" ").forEach(function(n){var e=n.replace(dJ,uJ);Ql[e]=new bd(e,1,!1,n,null,!1,!1)});"xlink:actuate xlink:arcrole xlink:role xlink:show xlink:title xlink:type".split(" ").forEach(function(n){var e=n.replace(dJ,uJ);Ql[e]=new bd(e,1,!1,n,"http://www.w3.org/1999/xlink",!1,!1)});["xml:base","xml:lang","xml:space"].forEach(function(n){var e=n.replace(dJ,uJ);Ql[e]=new bd(e,1,!1,n,"http://www.w3.org/XML/1998/namespace",!1,!1)});["tabIndex","crossOrigin"].forEach(function(n){Ql[n]=new bd(n,1,!1,n.toLowerCase(),null,!1,!1)});Ql.xlinkHref=new bd("xlinkHref",1,!1,"xlink:href","http://www.w3.org/1999/xlink",!0,!1);["src","href","action","formAction"].forEach(function(n){Ql[n]=new bd(n,1,!1,n.toLowerCase(),null,!0,!0)});function hJ(n,e,t,i){var o=Ql.hasOwnProperty(e)?Ql[e]:null;(o!==null?o.type!==0:i||!(2a||o[s]!==r[a]){var l=` `+o[s].replace(" at new "," at ");return n.displayName&&l.includes("")&&(l=l.replace("",n.displayName)),l}while(1<=s&&0<=a);break}}}finally{XX=!1,Error.prepareStackTrace=t}return(n=n?n.displayName||n.name:"")?bN(n):""}function VGe(n){switch(n.tag){case 5:return bN(n.type);case 16:return bN("Lazy");case 13:return bN("Suspense");case 19:return bN("SuspenseList");case 0:case 2:case 15:return n=QX(n.type,!1),n;case 11:return n=QX(n.type.render,!1),n;case 1:return n=QX(n.type,!0),n;default:return""}}function yQ(n){if(n==null)return null;if(typeof n=="function")return n.displayName||n.name||null;if(typeof n=="string")return n;switch(n){case NS:return"Fragment";case DS:return"Portal";case vQ:return"Profiler";case fJ:return"StrictMode";case xQ:return"Suspense";case wQ:return"SuspenseList"}if(typeof n=="object")switch(n.$$typeof){case jCe:return(n.displayName||"Context")+".Consumer";case $Ce:return(n._context.displayName||"Context")+".Provider";case pJ:var e=n.render;return n=n.displayName,n||(n=e.displayName||e.name||"",n=n!==""?"ForwardRef("+n+")":"ForwardRef"),n;case mJ:return e=n.displayName||null,e!==null?e:yQ(n.type)||"Memo";case wv:e=n._payload,n=n._init;try{return yQ(n(e))}catch{}}return null}function UGe(n){var e=n.type;switch(n.tag){case 24:return"Cache";case 9:return(e.displayName||"Context")+".Consumer";case 10:return(e._context.displayName||"Context")+".Provider";case 18:return"DehydratedFragment";case 11:return n=e.render,n=n.displayName||n.name||"",e.displayName||(n!==""?"ForwardRef("+n+")":"ForwardRef");case 7:return"Fragment";case 5:return e;case 4:return"Portal";case 3:return"Root";case 6:return"Text";case 16:return yQ(e);case 8:return e===fJ?"StrictMode":"Mode";case 22:return"Offscreen";case 12:return"Profiler";case 21:return"Scope";case 13:return"Suspense";case 19:return"SuspenseList";case 25:return"TracingMarker";case 1:case 0:case 17:case 2:case 14:case 15:if(typeof e=="function")return e.displayName||e.name||null;if(typeof e=="string")return e}return null}function Pv(n){switch(typeof n){case"boolean":case"number":case"string":case"undefined":return n;case"object":return n;default:return""}}function KCe(n){var e=n.type;return(n=n.nodeName)&&n.toLowerCase()==="input"&&(e==="checkbox"||e==="radio")}function $Ge(n){var e=KCe(n)?"checked":"value",t=Object.getOwnPropertyDescriptor(n.constructor.prototype,e),i=""+n[e];if(!n.hasOwnProperty(e)&&typeof t<"u"&&typeof t.get=="function"&&typeof t.set=="function"){var o=t.get,r=t.set;return Object.defineProperty(n,e,{configurable:!0,get:function(){return o.call(this)},set:function(s){i=""+s,r.call(this,s)}}),Object.defineProperty(n,e,{enumerable:t.enumerable}),{getValue:function(){return i},setValue:function(s){i=""+s},stopTracking:function(){n._valueTracker=null,delete n[e]}}}}function aF(n){n._valueTracker||(n._valueTracker=$Ge(n))}function GCe(n){if(!n)return!1;var e=n._valueTracker;if(!e)return!0;var t=e.getValue(),i="";return n&&(i=KCe(n)?n.checked?"true":"false":n.value),n=i,n!==t?(e.setValue(n),!0):!1}function PF(n){if(n=n||(typeof document<"u"?document:void 0),typeof n>"u")return null;try{return n.activeElement||n.body}catch{return n.body}}function CQ(n,e){var t=e.checked;return is({},e,{defaultChecked:void 0,defaultValue:void 0,value:void 0,checked:t??n._wrapperState.initialChecked})}function H1e(n,e){var t=e.defaultValue==null?"":e.defaultValue,i=e.checked!=null?e.checked:e.defaultChecked;t=Pv(e.value!=null?e.value:t),n._wrapperState={initialChecked:i,initialValue:t,controlled:e.type==="checkbox"||e.type==="radio"?e.checked!=null:e.value!=null}}function YCe(n,e){e=e.checked,e!=null&&hJ(n,"checked",e,!1)}function SQ(n,e){YCe(n,e);var t=Pv(e.value),i=e.type;if(t!=null)i==="number"?(t===0&&n.value===""||n.value!=t)&&(n.value=""+t):n.value!==""+t&&(n.value=""+t);else if(i==="submit"||i==="reset"){n.removeAttribute("value");return}e.hasOwnProperty("value")?kQ(n,e.type,t):e.hasOwnProperty("defaultValue")&&kQ(n,e.type,Pv(e.defaultValue)),e.checked==null&&e.defaultChecked!=null&&(n.defaultChecked=!!e.defaultChecked)}function z1e(n,e,t){if(e.hasOwnProperty("value")||e.hasOwnProperty("defaultValue")){var i=e.type;if(!(i!=="submit"&&i!=="reset"||e.value!==void 0&&e.value!==null))return;e=""+n._wrapperState.initialValue,t||e===n.value||(n.value=e),n.defaultValue=e}t=n.name,t!==""&&(n.name=""),n.defaultChecked=!!n._wrapperState.initialChecked,t!==""&&(n.name=t)}function kQ(n,e,t){(e!=="number"||PF(n.ownerDocument)!==n)&&(t==null?n.defaultValue=""+n._wrapperState.initialValue:n.defaultValue!==""+t&&(n.defaultValue=""+t))}var vN=Array.isArray;function VS(n,e,t,i){if(n=n.options,e){e={};for(var o=0;o"+e.valueOf().toString()+"",e=lF.firstChild;n.firstChild;)n.removeChild(n.firstChild);for(;e.firstChild;)n.appendChild(e.firstChild)}});function RN(n,e){if(e){var t=n.firstChild;if(t&&t===n.lastChild&&t.nodeType===3){t.nodeValue=e;return}}n.textContent=e}var yN={animationIterationCount:!0,aspectRatio:!0,borderImageOutset:!0,borderImageSlice:!0,borderImageWidth:!0,boxFlex:!0,boxFlexGroup:!0,boxOrdinalGroup:!0,columnCount:!0,columns:!0,flex:!0,flexGrow:!0,flexPositive:!0,flexShrink:!0,flexNegative:!0,flexOrder:!0,gridArea:!0,gridRow:!0,gridRowEnd:!0,gridRowSpan:!0,gridRowStart:!0,gridColumn:!0,gridColumnEnd:!0,gridColumnSpan:!0,gridColumnStart:!0,fontWeight:!0,lineClamp:!0,lineHeight:!0,opacity:!0,order:!0,orphans:!0,tabSize:!0,widows:!0,zIndex:!0,zoom:!0,fillOpacity:!0,floodOpacity:!0,stopOpacity:!0,strokeDasharray:!0,strokeDashoffset:!0,strokeMiterlimit:!0,strokeOpacity:!0,strokeWidth:!0},jGe=["Webkit","ms","Moz","O"];Object.keys(yN).forEach(function(n){jGe.forEach(function(e){e=e+n.charAt(0).toUpperCase()+n.substring(1),yN[e]=yN[n]})});function JCe(n,e,t){return e==null||typeof e=="boolean"||e===""?"":t||typeof e!="number"||e===0||yN.hasOwnProperty(n)&&yN[n]?(""+e).trim():e+"px"}function e0e(n,e){n=n.style;for(var t in e)if(e.hasOwnProperty(t)){var i=t.indexOf("--")===0,o=JCe(t,e[t],i);t==="float"&&(t="cssFloat"),i?n.setProperty(t,o):n[t]=o}}var qGe=is({menuitem:!0},{area:!0,base:!0,br:!0,col:!0,embed:!0,hr:!0,img:!0,input:!0,keygen:!0,link:!0,meta:!0,param:!0,source:!0,track:!0,wbr:!0});function EQ(n,e){if(e){if(qGe[n]&&(e.children!=null||e.dangerouslySetInnerHTML!=null))throw Error(Ye(137,n));if(e.dangerouslySetInnerHTML!=null){if(e.children!=null)throw Error(Ye(60));if(typeof e.dangerouslySetInnerHTML!="object"||!("__html"in e.dangerouslySetInnerHTML))throw Error(Ye(61))}if(e.style!=null&&typeof e.style!="object")throw Error(Ye(62))}}function TQ(n,e){if(n.indexOf("-")===-1)return typeof e.is=="string";switch(n){case"annotation-xml":case"color-profile":case"font-face":case"font-face-src":case"font-face-uri":case"font-face-format":case"font-face-name":case"missing-glyph":return!1;default:return!0}}var DQ=null;function gJ(n){return n=n.target||n.srcElement||window,n.correspondingUseElement&&(n=n.correspondingUseElement),n.nodeType===3?n.parentNode:n}var NQ=null,US=null,$S=null;function $1e(n){if(n=ZN(n)){if(typeof NQ!="function")throw Error(Ye(280));var e=n.stateNode;e&&(e=c5(e),NQ(n.stateNode,n.type,e))}}function t0e(n){US?$S?$S.push(n):$S=[n]:US=n}function i0e(){if(US){var n=US,e=$S;if($S=US=null,$1e(n),e)for(n=0;n>>=0,n===0?32:31-(nYe(n)/oYe|0)|0}var cF=64,dF=4194304;function xN(n){switch(n&-n){case 1:return 1;case 2:return 2;case 4:return 4;case 8:return 8;case 16:return 16;case 32:return 32;case 64:case 128:case 256:case 512:case 1024:case 2048:case 4096:case 8192:case 16384:case 32768:case 65536:case 131072:case 262144:case 524288:case 1048576:case 2097152:return n&4194240;case 4194304:case 8388608:case 16777216:case 33554432:case 67108864:return n&130023424;case 134217728:return 134217728;case 268435456:return 268435456;case 536870912:return 536870912;case 1073741824:return 1073741824;default:return n}}function WF(n,e){var t=n.pendingLanes;if(t===0)return 0;var i=0,o=n.suspendedLanes,r=n.pingedLanes,s=t&268435455;if(s!==0){var a=s&~o;a!==0?i=xN(a):(r&=s,r!==0&&(i=xN(r)))}else s=t&~o,s!==0?i=xN(s):r!==0&&(i=xN(r));if(i===0)return 0;if(e!==0&&e!==i&&(e&o)===0&&(o=i&-i,r=e&-e,o>=r||o===16&&(r&4194240)!==0))return e;if((i&4)!==0&&(i|=t&16),e=n.entangledLanes,e!==0)for(n=n.entanglements,e&=i;0t;t++)e.push(n);return e}function GN(n,e,t){n.pendingLanes|=e,e!==536870912&&(n.suspendedLanes=0,n.pingedLanes=0),n=n.eventTimes,e=31-tp(e),n[e]=t}function lYe(n,e){var t=n.pendingLanes&~e;n.pendingLanes=e,n.suspendedLanes=0,n.pingedLanes=0,n.expiredLanes&=e,n.mutableReadLanes&=e,n.entangledLanes&=e,e=n.entanglements;var i=n.eventTimes;for(n=n.expirationTimes;0=SN),J1e=" ",eCe=!1;function y0e(n,e){switch(n){case"keyup":return OYe.indexOf(e.keyCode)!==-1;case"keydown":return e.keyCode!==229;case"keypress":case"mousedown":case"focusout":return!0;default:return!1}}function C0e(n){return n=n.detail,typeof n=="object"&&"data"in n?n.data:null}var RS=!1;function BYe(n,e){switch(n){case"compositionend":return C0e(e);case"keypress":return e.which!==32?null:(eCe=!0,J1e);case"textInput":return n=e.data,n===J1e&&eCe?null:n;default:return null}}function WYe(n,e){if(RS)return n==="compositionend"||!SJ&&y0e(n,e)?(n=x0e(),LF=wJ=kv=null,RS=!1,n):null;switch(n){case"paste":return null;case"keypress":if(!(e.ctrlKey||e.altKey||e.metaKey)||e.ctrlKey&&e.altKey){if(e.char&&1=e)return{node:t,offset:e-n};n=i}e:{for(;t;){if(t.nextSibling){t=t.nextSibling;break e}t=t.parentNode}t=void 0}t=nCe(t)}}function I0e(n,e){return n&&e?n===e?!0:n&&n.nodeType===3?!1:e&&e.nodeType===3?I0e(n,e.parentNode):"contains"in n?n.contains(e):n.compareDocumentPosition?!!(n.compareDocumentPosition(e)&16):!1:!1}function E0e(){for(var n=window,e=PF();e instanceof n.HTMLIFrameElement;){try{var t=typeof e.contentWindow.location.href=="string"}catch{t=!1}if(t)n=e.contentWindow;else break;e=PF(n.document)}return e}function kJ(n){var e=n&&n.nodeName&&n.nodeName.toLowerCase();return e&&(e==="input"&&(n.type==="text"||n.type==="search"||n.type==="tel"||n.type==="url"||n.type==="password")||e==="textarea"||n.contentEditable==="true")}function GYe(n){var e=E0e(),t=n.focusedElem,i=n.selectionRange;if(e!==t&&t&&t.ownerDocument&&I0e(t.ownerDocument.documentElement,t)){if(i!==null&&kJ(t)){if(e=i.start,n=i.end,n===void 0&&(n=e),"selectionStart"in t)t.selectionStart=e,t.selectionEnd=Math.min(n,t.value.length);else if(n=(e=t.ownerDocument||document)&&e.defaultView||window,n.getSelection){n=n.getSelection();var o=t.textContent.length,r=Math.min(i.start,o);i=i.end===void 0?r:Math.min(i.end,o),!n.extend&&r>i&&(o=i,i=r,r=o),o=oCe(t,r);var s=oCe(t,i);o&&s&&(n.rangeCount!==1||n.anchorNode!==o.node||n.anchorOffset!==o.offset||n.focusNode!==s.node||n.focusOffset!==s.offset)&&(e=e.createRange(),e.setStart(o.node,o.offset),n.removeAllRanges(),r>i?(n.addRange(e),n.extend(s.node,s.offset)):(e.setEnd(s.node,s.offset),n.addRange(e)))}}for(e=[],n=t;n=n.parentNode;)n.nodeType===1&&e.push({element:n,left:n.scrollLeft,top:n.scrollTop});for(typeof t.focus=="function"&&t.focus(),t=0;t=document.documentMode,AS=null,FQ=null,LN=null,BQ=!1;function rCe(n,e,t){var i=t.window===t?t.document:t.nodeType===9?t:t.ownerDocument;BQ||AS==null||AS!==PF(i)||(i=AS,"selectionStart"in i&&kJ(i)?i={start:i.selectionStart,end:i.selectionEnd}:(i=(i.ownerDocument&&i.ownerDocument.defaultView||window).getSelection(),i={anchorNode:i.anchorNode,anchorOffset:i.anchorOffset,focusNode:i.focusNode,focusOffset:i.focusOffset}),LN&&BN(LN,i)||(LN=i,i=VF(FQ,"onSelect"),0OS||(n.current=$Q[OS],$Q[OS]=null,OS--)}function pr(n,e){OS++,$Q[OS]=n.current,n.current=e}var Ov={},Dc=Bv(Ov),tu=Bv(!1),Fy=Ov;function YS(n,e){var t=n.type.contextTypes;if(!t)return Ov;var i=n.stateNode;if(i&&i.__reactInternalMemoizedUnmaskedChildContext===e)return i.__reactInternalMemoizedMaskedChildContext;var o={},r;for(r in t)o[r]=e[r];return i&&(n=n.stateNode,n.__reactInternalMemoizedUnmaskedChildContext=e,n.__reactInternalMemoizedMaskedChildContext=o),o}function iu(n){return n=n.childContextTypes,n!=null}function $F(){Nr(tu),Nr(Dc)}function pCe(n,e,t){if(Dc.current!==Ov)throw Error(Ye(168));pr(Dc,e),pr(tu,t)}function F0e(n,e,t){var i=n.stateNode;if(e=e.childContextTypes,typeof i.getChildContext!="function")return t;i=i.getChildContext();for(var o in i)if(!(o in e))throw Error(Ye(108,UGe(n)||"Unknown",o));return is({},t,i)}function jF(n){return n=(n=n.stateNode)&&n.__reactInternalMemoizedMergedChildContext||Ov,Fy=Dc.current,pr(Dc,n),pr(tu,tu.current),!0}function mCe(n,e,t){var i=n.stateNode;if(!i)throw Error(Ye(169));t?(n=F0e(n,e,Fy),i.__reactInternalMemoizedMergedChildContext=n,Nr(tu),Nr(Dc),pr(Dc,n)):Nr(tu),pr(tu,t)}var m_=null,d5=!1,cQ=!1;function B0e(n){m_===null?m_=[n]:m_.push(n)}function oZe(n){d5=!0,B0e(n)}function Wv(){if(!cQ&&m_!==null){cQ=!0;var n=0,e=zo;try{var t=m_;for(zo=1;n>=s,o-=s,g_=1<<32-tp(e)+o|t<E?(N=L,L=null):N=L.sibling;var M=h(b,L,x[E],w);if(M===null){L===null&&(L=N);break}n&&L&&M.alternate===null&&e(b,L),v=r(M,v,E),C===null?y=M:C.sibling=M,C=M,L=N}if(E===x.length)return t(b,L),zr&&Dy(b,E),y;if(L===null){for(;EE?(N=L,L=null):N=L.sibling;var F=h(b,L,M.value,w);if(F===null){L===null&&(L=N);break}n&&L&&F.alternate===null&&e(b,L),v=r(F,v,E),C===null?y=F:C.sibling=F,C=F,L=N}if(M.done)return t(b,L),zr&&Dy(b,E),y;if(L===null){for(;!M.done;E++,M=x.next())M=u(b,M.value,w),M!==null&&(v=r(M,v,E),C===null?y=M:C.sibling=M,C=M);return zr&&Dy(b,E),y}for(L=i(b,L);!M.done;E++,M=x.next())M=f(L,b,E,M.value,w),M!==null&&(n&&M.alternate!==null&&L.delete(M.key===null?E:M.key),v=r(M,v,E),C===null?y=M:C.sibling=M,C=M);return n&&L.forEach(function(q){return e(b,q)}),zr&&Dy(b,E),y}function _(b,v,x,w){if(typeof x=="object"&&x!==null&&x.type===NS&&x.key===null&&(x=x.props.children),typeof x=="object"&&x!==null){switch(x.$$typeof){case sF:e:{for(var y=x.key,C=v;C!==null;){if(C.key===y){if(y=x.type,y===NS){if(C.tag===7){t(b,C.sibling),v=o(C,x.props.children),v.return=b,b=v;break e}}else if(C.elementType===y||typeof y=="object"&&y!==null&&y.$$typeof===wv&&bCe(y)===C.type){t(b,C.sibling),v=o(C,x.props),v.ref=pN(b,C,x),v.return=b,b=v;break e}t(b,C);break}else e(b,C);C=C.sibling}x.type===NS?(v=Oy(x.props.children,b.mode,w,x.key),v.return=b,b=v):(w=MF(x.type,x.key,x.props,null,b.mode,w),w.ref=pN(b,v,x),w.return=b,b=w)}return s(b);case DS:e:{for(C=x.key;v!==null;){if(v.key===C)if(v.tag===4&&v.stateNode.containerInfo===x.containerInfo&&v.stateNode.implementation===x.implementation){t(b,v.sibling),v=o(v,x.children||[]),v.return=b,b=v;break e}else{t(b,v);break}else e(b,v);v=v.sibling}v=_Q(x,b.mode,w),v.return=b,b=v}return s(b);case wv:return C=x._init,_(b,v,C(x._payload),w)}if(vN(x))return p(b,v,x,w);if(dN(x))return g(b,v,x,w);wF(b,x)}return typeof x=="string"&&x!==""||typeof x=="number"?(x=""+x,v!==null&&v.tag===6?(t(b,v.sibling),v=o(v,x),v.return=b,b=v):(t(b,v),v=gQ(x,b.mode,w),v.return=b,b=v),s(b)):t(b,v)}return _}var XS=V0e(!0),U0e=V0e(!1),GF=Bv(null),YF=null,WS=null,TJ=null;function DJ(){TJ=WS=YF=null}function NJ(n){var e=GF.current;Nr(GF),n._currentValue=e}function KQ(n,e,t){for(;n!==null;){var i=n.alternate;if((n.childLanes&e)!==e?(n.childLanes|=e,i!==null&&(i.childLanes|=e)):i!==null&&(i.childLanes&e)!==e&&(i.childLanes|=e),n===t)break;n=n.return}}function qS(n,e){YF=n,TJ=WS=null,n=n.dependencies,n!==null&&n.firstContext!==null&&((n.lanes&e)!==0&&(eu=!0),n.firstContext=null)}function ef(n){var e=n._currentValue;if(TJ!==n)if(n={context:n,memoizedValue:e,next:null},WS===null){if(YF===null)throw Error(Ye(308));WS=n,YF.dependencies={lanes:0,firstContext:n}}else WS=WS.next=n;return e}var Ay=null;function RJ(n){Ay===null?Ay=[n]:Ay.push(n)}function $0e(n,e,t,i){var o=e.interleaved;return o===null?(t.next=t,RJ(e)):(t.next=o.next,o.next=t),e.interleaved=t,w_(n,i)}function w_(n,e){n.lanes|=e;var t=n.alternate;for(t!==null&&(t.lanes|=e),t=n,n=n.return;n!==null;)n.childLanes|=e,t=n.alternate,t!==null&&(t.childLanes|=e),t=n,n=n.return;return t.tag===3?t.stateNode:null}var yv=!1;function AJ(n){n.updateQueue={baseState:n.memoizedState,firstBaseUpdate:null,lastBaseUpdate:null,shared:{pending:null,interleaved:null,lanes:0},effects:null}}function j0e(n,e){n=n.updateQueue,e.updateQueue===n&&(e.updateQueue={baseState:n.baseState,firstBaseUpdate:n.firstBaseUpdate,lastBaseUpdate:n.lastBaseUpdate,shared:n.shared,effects:n.effects})}function b_(n,e){return{eventTime:n,lane:e,tag:0,payload:null,callback:null,next:null}}function Nv(n,e,t){var i=n.updateQueue;if(i===null)return null;if(i=i.shared,(Zn&2)!==0){var o=i.pending;return o===null?e.next=e:(e.next=o.next,o.next=e),i.pending=e,w_(n,t)}return o=i.interleaved,o===null?(e.next=e,RJ(i)):(e.next=o.next,o.next=e),i.interleaved=e,w_(n,t)}function EF(n,e,t){if(e=e.updateQueue,e!==null&&(e=e.shared,(t&4194240)!==0)){var i=e.lanes;i&=n.pendingLanes,t|=i,e.lanes=t,bJ(n,t)}}function vCe(n,e){var t=n.updateQueue,i=n.alternate;if(i!==null&&(i=i.updateQueue,t===i)){var o=null,r=null;if(t=t.firstBaseUpdate,t!==null){do{var s={eventTime:t.eventTime,lane:t.lane,tag:t.tag,payload:t.payload,callback:t.callback,next:null};r===null?o=r=s:r=r.next=s,t=t.next}while(t!==null);r===null?o=r=e:r=r.next=e}else o=r=e;t={baseState:i.baseState,firstBaseUpdate:o,lastBaseUpdate:r,shared:i.shared,effects:i.effects},n.updateQueue=t;return}n=t.lastBaseUpdate,n===null?t.firstBaseUpdate=e:n.next=e,t.lastBaseUpdate=e}function ZF(n,e,t,i){var o=n.updateQueue;yv=!1;var r=o.firstBaseUpdate,s=o.lastBaseUpdate,a=o.shared.pending;if(a!==null){o.shared.pending=null;var l=a,c=l.next;l.next=null,s===null?r=c:s.next=c,s=l;var d=n.alternate;d!==null&&(d=d.updateQueue,a=d.lastBaseUpdate,a!==s&&(a===null?d.firstBaseUpdate=c:a.next=c,d.lastBaseUpdate=l))}if(r!==null){var u=o.baseState;s=0,d=c=l=null,a=r;do{var h=a.lane,f=a.eventTime;if((i&h)===h){d!==null&&(d=d.next={eventTime:f,lane:0,tag:a.tag,payload:a.payload,callback:a.callback,next:null});e:{var p=n,g=a;switch(h=e,f=t,g.tag){case 1:if(p=g.payload,typeof p=="function"){u=p.call(f,u,h);break e}u=p;break e;case 3:p.flags=p.flags&-65537|128;case 0:if(p=g.payload,h=typeof p=="function"?p.call(f,u,h):p,h==null)break e;u=is({},u,h);break e;case 2:yv=!0}}a.callback!==null&&a.lane!==0&&(n.flags|=64,h=o.effects,h===null?o.effects=[a]:h.push(a))}else f={eventTime:f,lane:h,tag:a.tag,payload:a.payload,callback:a.callback,next:null},d===null?(c=d=f,l=u):d=d.next=f,s|=h;if(a=a.next,a===null){if(a=o.shared.pending,a===null)break;h=a,a=h.next,h.next=null,o.lastBaseUpdate=h,o.shared.pending=null}}while(!0);if(d===null&&(l=u),o.baseState=l,o.firstBaseUpdate=c,o.lastBaseUpdate=d,e=o.shared.interleaved,e!==null){o=e;do s|=o.lane,o=o.next;while(o!==e)}else r===null&&(o.shared.lanes=0);Hy|=s,n.lanes=s,n.memoizedState=u}}function xCe(n,e,t){if(n=e.effects,e.effects=null,n!==null)for(e=0;et?t:4,n(!0);var i=uQ.transition;uQ.transition={};try{n(!1),e()}finally{zo=t,uQ.transition=i}}function lSe(){return tf().memoizedState}function lZe(n,e,t){var i=Av(n);if(t={lane:i,action:t,hasEagerState:!1,eagerState:null,next:null},cSe(n))dSe(e,t);else if(t=$0e(n,e,t,i),t!==null){var o=_d();ip(t,n,i,o),uSe(t,e,i)}}function cZe(n,e,t){var i=Av(n),o={lane:i,action:t,hasEagerState:!1,eagerState:null,next:null};if(cSe(n))dSe(e,o);else{var r=n.alternate;if(n.lanes===0&&(r===null||r.lanes===0)&&(r=e.lastRenderedReducer,r!==null))try{var s=e.lastRenderedState,a=r(s,t);if(o.hasEagerState=!0,o.eagerState=a,np(a,s)){var l=e.interleaved;l===null?(o.next=o,RJ(e)):(o.next=l.next,l.next=o),e.interleaved=o;return}}catch{}finally{}t=$0e(n,e,o,i),t!==null&&(o=_d(),ip(t,n,i,o),uSe(t,e,i))}}function cSe(n){var e=n.alternate;return n===ts||e!==null&&e===ts}function dSe(n,e){IN=QF=!0;var t=n.pending;t===null?e.next=e:(e.next=t.next,t.next=e),n.pending=e}function uSe(n,e,t){if((t&4194240)!==0){var i=e.lanes;i&=n.pendingLanes,t|=i,e.lanes=t,bJ(n,t)}}var JF={readContext:ef,useCallback:Ic,useContext:Ic,useEffect:Ic,useImperativeHandle:Ic,useInsertionEffect:Ic,useLayoutEffect:Ic,useMemo:Ic,useReducer:Ic,useRef:Ic,useState:Ic,useDebugValue:Ic,useDeferredValue:Ic,useTransition:Ic,useMutableSource:Ic,useSyncExternalStore:Ic,useId:Ic,unstable_isNewReconciler:!1},dZe={readContext:ef,useCallback:function(n,e){return um().memoizedState=[n,e===void 0?null:e],n},useContext:ef,useEffect:yCe,useImperativeHandle:function(n,e,t){return t=t!=null?t.concat([n]):null,DF(4194308,4,nSe.bind(null,e,n),t)},useLayoutEffect:function(n,e){return DF(4194308,4,n,e)},useInsertionEffect:function(n,e){return DF(4,2,n,e)},useMemo:function(n,e){var t=um();return e=e===void 0?null:e,n=n(),t.memoizedState=[n,e],n},useReducer:function(n,e,t){var i=um();return e=t!==void 0?t(e):e,i.memoizedState=i.baseState=e,n={pending:null,interleaved:null,lanes:0,dispatch:null,lastRenderedReducer:n,lastRenderedState:e},i.queue=n,n=n.dispatch=lZe.bind(null,ts,n),[i.memoizedState,n]},useRef:function(n){var e=um();return n={current:n},e.memoizedState=n},useState:wCe,useDebugValue:zJ,useDeferredValue:function(n){return um().memoizedState=n},useTransition:function(){var n=wCe(!1),e=n[0];return n=aZe.bind(null,n[1]),um().memoizedState=n,[e,n]},useMutableSource:function(){},useSyncExternalStore:function(n,e,t){var i=ts,o=um();if(zr){if(t===void 0)throw Error(Ye(407));t=t()}else{if(t=e(),_l===null)throw Error(Ye(349));(Wy&30)!==0||Y0e(i,e,t)}o.memoizedState=t;var r={value:t,getSnapshot:e};return o.queue=r,yCe(X0e.bind(null,i,r,n),[n]),i.flags|=2048,qN(9,Z0e.bind(null,i,r,t,e),void 0,null),t},useId:function(){var n=um(),e=_l.identifierPrefix;if(zr){var t=__,i=g_;t=(i&~(1<<32-tp(i)-1)).toString(32)+t,e=":"+e+"R"+t,t=$N++,0<\/script>",n=n.removeChild(n.firstChild)):typeof i.is=="string"?n=s.createElement(t,{is:i.is}):(n=s.createElement(t),t==="select"&&(s=n,i.multiple?s.multiple=!0:i.size&&(s.size=i.size))):n=s.createElementNS(n,t),n[hm]=e,n[zN]=i,wSe(n,e,!1,!1),e.stateNode=n;e:{switch(s=TQ(t,i),t){case"dialog":Dr("cancel",n),Dr("close",n),o=i;break;case"iframe":case"object":case"embed":Dr("load",n),o=i;break;case"video":case"audio":for(o=0;oek&&(e.flags|=128,i=!0,mN(r,!1),e.lanes=4194304)}else{if(!i)if(n=XF(s),n!==null){if(e.flags|=128,i=!0,t=n.updateQueue,t!==null&&(e.updateQueue=t,e.flags|=4),mN(r,!0),r.tail===null&&r.tailMode==="hidden"&&!s.alternate&&!zr)return Ec(e),null}else 2*zs()-r.renderingStartTime>ek&&t!==1073741824&&(e.flags|=128,i=!0,mN(r,!1),e.lanes=4194304);r.isBackwards?(s.sibling=e.child,e.child=s):(t=r.last,t!==null?t.sibling=s:e.child=s,r.last=s)}return r.tail!==null?(e=r.tail,r.rendering=e,r.tail=e.sibling,r.renderingStartTime=zs(),e.sibling=null,t=es.current,pr(es,i?t&1|2:t&1),e):(Ec(e),null);case 22:case 23:return KJ(),i=e.memoizedState!==null,n!==null&&n.memoizedState!==null!==i&&(e.flags|=8192),i&&(e.mode&1)!==0?(Xu&1073741824)!==0&&(Ec(e),e.subtreeFlags&6&&(e.flags|=8192)):Ec(e),null;case 24:return null;case 25:return null}throw Error(Ye(156,e.tag))}function bZe(n,e){switch(IJ(e),e.tag){case 1:return iu(e.type)&&$F(),n=e.flags,n&65536?(e.flags=n&-65537|128,e):null;case 3:return QS(),Nr(tu),Nr(Dc),OJ(),n=e.flags,(n&65536)!==0&&(n&128)===0?(e.flags=n&-65537|128,e):null;case 5:return PJ(e),null;case 13:if(Nr(es),n=e.memoizedState,n!==null&&n.dehydrated!==null){if(e.alternate===null)throw Error(Ye(340));ZS()}return n=e.flags,n&65536?(e.flags=n&-65537|128,e):null;case 19:return Nr(es),null;case 4:return QS(),null;case 10:return NJ(e.type._context),null;case 22:case 23:return KJ(),null;case 24:return null;default:return null}}var CF=!1,Tc=!1,vZe=typeof WeakSet=="function"?WeakSet:Set,Ft=null;function HS(n,e){var t=n.ref;if(t!==null)if(typeof t=="function")try{t(null)}catch(i){ys(n,e,i)}else t.current=null}function iJ(n,e,t){try{t()}catch(i){ys(n,e,i)}}var ACe=!1;function xZe(n,e){if(WQ=HF,n=E0e(),kJ(n)){if("selectionStart"in n)var t={start:n.selectionStart,end:n.selectionEnd};else e:{t=(t=n.ownerDocument)&&t.defaultView||window;var i=t.getSelection&&t.getSelection();if(i&&i.rangeCount!==0){t=i.anchorNode;var o=i.anchorOffset,r=i.focusNode;i=i.focusOffset;try{t.nodeType,r.nodeType}catch{t=null;break e}var s=0,a=-1,l=-1,c=0,d=0,u=n,h=null;t:for(;;){for(var f;u!==t||o!==0&&u.nodeType!==3||(a=s+o),u!==r||i!==0&&u.nodeType!==3||(l=s+i),u.nodeType===3&&(s+=u.nodeValue.length),(f=u.firstChild)!==null;)h=u,u=f;for(;;){if(u===n)break t;if(h===t&&++c===o&&(a=s),h===r&&++d===i&&(l=s),(f=u.nextSibling)!==null)break;u=h,h=u.parentNode}u=f}t=a===-1||l===-1?null:{start:a,end:l}}else t=null}t=t||{start:0,end:0}}else t=null;for(HQ={focusedElem:n,selectionRange:t},HF=!1,Ft=e;Ft!==null;)if(e=Ft,n=e.child,(e.subtreeFlags&1028)!==0&&n!==null)n.return=e,Ft=n;else for(;Ft!==null;){e=Ft;try{var p=e.alternate;if((e.flags&1024)!==0)switch(e.tag){case 0:case 11:case 15:break;case 1:if(p!==null){var g=p.memoizedProps,_=p.memoizedState,b=e.stateNode,v=b.getSnapshotBeforeUpdate(e.elementType===e.type?g:Qf(e.type,g),_);b.__reactInternalSnapshotBeforeUpdate=v}break;case 3:var x=e.stateNode.containerInfo;x.nodeType===1?x.textContent="":x.nodeType===9&&x.documentElement&&x.removeChild(x.documentElement);break;case 5:case 6:case 4:case 17:break;default:throw Error(Ye(163))}}catch(w){ys(e,e.return,w)}if(n=e.sibling,n!==null){n.return=e.return,Ft=n;break}Ft=e.return}return p=ACe,ACe=!1,p}function EN(n,e,t){var i=e.updateQueue;if(i=i!==null?i.lastEffect:null,i!==null){var o=i=i.next;do{if((o.tag&n)===n){var r=o.destroy;o.destroy=void 0,r!==void 0&&iJ(e,t,r)}o=o.next}while(o!==i)}}function f5(n,e){if(e=e.updateQueue,e=e!==null?e.lastEffect:null,e!==null){var t=e=e.next;do{if((t.tag&n)===n){var i=t.create;t.destroy=i()}t=t.next}while(t!==e)}}function nJ(n){var e=n.ref;if(e!==null){var t=n.stateNode;switch(n.tag){case 5:n=t;break;default:n=t}typeof e=="function"?e(n):e.current=n}}function SSe(n){var e=n.alternate;e!==null&&(n.alternate=null,SSe(e)),n.child=null,n.deletions=null,n.sibling=null,n.tag===5&&(e=n.stateNode,e!==null&&(delete e[hm],delete e[zN],delete e[UQ],delete e[iZe],delete e[nZe])),n.stateNode=null,n.return=null,n.dependencies=null,n.memoizedProps=null,n.memoizedState=null,n.pendingProps=null,n.stateNode=null,n.updateQueue=null}function kSe(n){return n.tag===5||n.tag===3||n.tag===4}function MCe(n){e:for(;;){for(;n.sibling===null;){if(n.return===null||kSe(n.return))return null;n=n.return}for(n.sibling.return=n.return,n=n.sibling;n.tag!==5&&n.tag!==6&&n.tag!==18;){if(n.flags&2||n.child===null||n.tag===4)continue e;n.child.return=n,n=n.child}if(!(n.flags&2))return n.stateNode}}function oJ(n,e,t){var i=n.tag;if(i===5||i===6)n=n.stateNode,e?t.nodeType===8?t.parentNode.insertBefore(n,e):t.insertBefore(n,e):(t.nodeType===8?(e=t.parentNode,e.insertBefore(n,t)):(e=t,e.appendChild(n)),t=t._reactRootContainer,t!=null||e.onclick!==null||(e.onclick=UF));else if(i!==4&&(n=n.child,n!==null))for(oJ(n,e,t),n=n.sibling;n!==null;)oJ(n,e,t),n=n.sibling}function rJ(n,e,t){var i=n.tag;if(i===5||i===6)n=n.stateNode,e?t.insertBefore(n,e):t.appendChild(n);else if(i!==4&&(n=n.child,n!==null))for(rJ(n,e,t),n=n.sibling;n!==null;)rJ(n,e,t),n=n.sibling}var Zl=null,Jf=!1;function xv(n,e,t){for(t=t.child;t!==null;)LSe(n,e,t),t=t.sibling}function LSe(n,e,t){if(fm&&typeof fm.onCommitFiberUnmount=="function")try{fm.onCommitFiberUnmount(r5,t)}catch{}switch(t.tag){case 5:Tc||HS(t,e);case 6:var i=Zl,o=Jf;Zl=null,xv(n,e,t),Zl=i,Jf=o,Zl!==null&&(Jf?(n=Zl,t=t.stateNode,n.nodeType===8?n.parentNode.removeChild(t):n.removeChild(t)):Zl.removeChild(t.stateNode));break;case 18:Zl!==null&&(Jf?(n=Zl,t=t.stateNode,n.nodeType===8?lQ(n.parentNode,t):n.nodeType===1&&lQ(n,t),ON(n)):lQ(Zl,t.stateNode));break;case 4:i=Zl,o=Jf,Zl=t.stateNode.containerInfo,Jf=!0,xv(n,e,t),Zl=i,Jf=o;break;case 0:case 11:case 14:case 15:if(!Tc&&(i=t.updateQueue,i!==null&&(i=i.lastEffect,i!==null))){o=i=i.next;do{var r=o,s=r.destroy;r=r.tag,s!==void 0&&((r&2)!==0||(r&4)!==0)&&iJ(t,e,s),o=o.next}while(o!==i)}xv(n,e,t);break;case 1:if(!Tc&&(HS(t,e),i=t.stateNode,typeof i.componentWillUnmount=="function"))try{i.props=t.memoizedProps,i.state=t.memoizedState,i.componentWillUnmount()}catch(a){ys(t,e,a)}xv(n,e,t);break;case 21:xv(n,e,t);break;case 22:t.mode&1?(Tc=(i=Tc)||t.memoizedState!==null,xv(n,e,t),Tc=i):xv(n,e,t);break;default:xv(n,e,t)}}function PCe(n){var e=n.updateQueue;if(e!==null){n.updateQueue=null;var t=n.stateNode;t===null&&(t=n.stateNode=new vZe),e.forEach(function(i){var o=TZe.bind(null,n,i);t.has(i)||(t.add(i),i.then(o,o))})}}function Xf(n,e){var t=e.deletions;if(t!==null)for(var i=0;io&&(o=s),i&=~r}if(i=o,i=zs()-i,i=(120>i?120:480>i?480:1080>i?1080:1920>i?1920:3e3>i?3e3:4320>i?4320:1960*yZe(i/1960))-i,10n?16:n,Lv===null)var i=!1;else{if(n=Lv,Lv=null,i5=0,(Zn&6)!==0)throw Error(Ye(331));var o=Zn;for(Zn|=4,Ft=n.current;Ft!==null;){var r=Ft,s=r.child;if((Ft.flags&16)!==0){var a=r.deletions;if(a!==null){for(var l=0;lzs()-jJ?Py(n,0):$J|=t),nu(n,e)}function MSe(n,e){e===0&&((n.mode&1)===0?e=1:(e=dF,dF<<=1,(dF&130023424)===0&&(dF=4194304)));var t=_d();n=w_(n,e),n!==null&&(GN(n,e,t),nu(n,t))}function EZe(n){var e=n.memoizedState,t=0;e!==null&&(t=e.retryLane),MSe(n,t)}function TZe(n,e){var t=0;switch(n.tag){case 13:var i=n.stateNode,o=n.memoizedState;o!==null&&(t=o.retryLane);break;case 19:i=n.stateNode;break;default:throw Error(Ye(314))}i!==null&&i.delete(e),MSe(n,t)}var PSe;PSe=function(n,e,t){if(n!==null)if(n.memoizedProps!==e.pendingProps||tu.current)eu=!0;else{if((n.lanes&t)===0&&(e.flags&128)===0)return eu=!1,gZe(n,e,t);eu=(n.flags&131072)!==0}else eu=!1,zr&&(e.flags&1048576)!==0&&W0e(e,KF,e.index);switch(e.lanes=0,e.tag){case 2:var i=e.type;NF(n,e),n=e.pendingProps;var o=YS(e,Dc.current);qS(e,t),o=BJ(null,e,i,n,o,t);var r=WJ();return e.flags|=1,typeof o=="object"&&o!==null&&typeof o.render=="function"&&o.$$typeof===void 0?(e.tag=1,e.memoizedState=null,e.updateQueue=null,iu(i)?(r=!0,jF(e)):r=!1,e.memoizedState=o.state!==null&&o.state!==void 0?o.state:null,AJ(e),o.updater=h5,e.stateNode=o,o._reactInternals=e,YQ(e,i,n,t),e=QQ(null,e,i,!0,r,t)):(e.tag=0,zr&&r&&LJ(e),gd(null,e,o,t),e=e.child),e;case 16:i=e.elementType;e:{switch(NF(n,e),n=e.pendingProps,o=i._init,i=o(i._payload),e.type=i,o=e.tag=NZe(i),n=Qf(i,n),o){case 0:e=XQ(null,e,i,n,t);break e;case 1:e=DCe(null,e,i,n,t);break e;case 11:e=ECe(null,e,i,n,t);break e;case 14:e=TCe(null,e,i,Qf(i.type,n),t);break e}throw Error(Ye(306,i,""))}return e;case 0:return i=e.type,o=e.pendingProps,o=e.elementType===i?o:Qf(i,o),XQ(n,e,i,o,t);case 1:return i=e.type,o=e.pendingProps,o=e.elementType===i?o:Qf(i,o),DCe(n,e,i,o,t);case 3:e:{if(bSe(e),n===null)throw Error(Ye(387));i=e.pendingProps,r=e.memoizedState,o=r.element,j0e(n,e),ZF(e,i,null,t);var s=e.memoizedState;if(i=s.element,r.isDehydrated)if(r={element:i,isDehydrated:!1,cache:s.cache,pendingSuspenseBoundaries:s.pendingSuspenseBoundaries,transitions:s.transitions},e.updateQueue.baseState=r,e.memoizedState=r,e.flags&256){o=JS(Error(Ye(423)),e),e=NCe(n,e,i,t,o);break e}else if(i!==o){o=JS(Error(Ye(424)),e),e=NCe(n,e,i,t,o);break e}else for(Qu=Dv(e.stateNode.containerInfo.firstChild),Ju=e,zr=!0,ep=null,t=U0e(e,null,i,t),e.child=t;t;)t.flags=t.flags&-3|4096,t=t.sibling;else{if(ZS(),i===o){e=y_(n,e,t);break e}gd(n,e,i,t)}e=e.child}return e;case 5:return q0e(e),n===null&&qQ(e),i=e.type,o=e.pendingProps,r=n!==null?n.memoizedProps:null,s=o.children,zQ(i,o)?s=null:r!==null&&zQ(i,r)&&(e.flags|=32),_Se(n,e),gd(n,e,s,t),e.child;case 6:return n===null&&qQ(e),null;case 13:return vSe(n,e,t);case 4:return MJ(e,e.stateNode.containerInfo),i=e.pendingProps,n===null?e.child=XS(e,null,i,t):gd(n,e,i,t),e.child;case 11:return i=e.type,o=e.pendingProps,o=e.elementType===i?o:Qf(i,o),ECe(n,e,i,o,t);case 7:return gd(n,e,e.pendingProps,t),e.child;case 8:return gd(n,e,e.pendingProps.children,t),e.child;case 12:return gd(n,e,e.pendingProps.children,t),e.child;case 10:e:{if(i=e.type._context,o=e.pendingProps,r=e.memoizedProps,s=o.value,pr(GF,i._currentValue),i._currentValue=s,r!==null)if(np(r.value,s)){if(r.children===o.children&&!tu.current){e=y_(n,e,t);break e}}else for(r=e.child,r!==null&&(r.return=e);r!==null;){var a=r.dependencies;if(a!==null){s=r.child;for(var l=a.firstContext;l!==null;){if(l.context===i){if(r.tag===1){l=b_(-1,t&-t),l.tag=2;var c=r.updateQueue;if(c!==null){c=c.shared;var d=c.pending;d===null?l.next=l:(l.next=d.next,d.next=l),c.pending=l}}r.lanes|=t,l=r.alternate,l!==null&&(l.lanes|=t),KQ(r.return,t,e),a.lanes|=t;break}l=l.next}}else if(r.tag===10)s=r.type===e.type?null:r.child;else if(r.tag===18){if(s=r.return,s===null)throw Error(Ye(341));s.lanes|=t,a=s.alternate,a!==null&&(a.lanes|=t),KQ(s,t,e),s=r.sibling}else s=r.child;if(s!==null)s.return=r;else for(s=r;s!==null;){if(s===e){s=null;break}if(r=s.sibling,r!==null){r.return=s.return,s=r;break}s=s.return}r=s}gd(n,e,o.children,t),e=e.child}return e;case 9:return o=e.type,i=e.pendingProps.children,qS(e,t),o=ef(o),i=i(o),e.flags|=1,gd(n,e,i,t),e.child;case 14:return i=e.type,o=Qf(i,e.pendingProps),o=Qf(i.type,o),TCe(n,e,i,o,t);case 15:return mSe(n,e,e.type,e.pendingProps,t);case 17:return i=e.type,o=e.pendingProps,o=e.elementType===i?o:Qf(i,o),NF(n,e),e.tag=1,iu(i)?(n=!0,jF(e)):n=!1,qS(e,t),hSe(e,i,o),YQ(e,i,o,t),QQ(null,e,i,!0,n,t);case 19:return xSe(n,e,t);case 22:return gSe(n,e,t)}throw Error(Ye(156,e.tag))};function OSe(n,e){return c0e(n,e)}function DZe(n,e,t,i){this.tag=n,this.key=t,this.sibling=this.child=this.return=this.stateNode=this.type=this.elementType=null,this.index=0,this.ref=null,this.pendingProps=e,this.dependencies=this.memoizedState=this.updateQueue=this.memoizedProps=null,this.mode=i,this.subtreeFlags=this.flags=0,this.deletions=null,this.childLanes=this.lanes=0,this.alternate=null}function Qh(n,e,t,i){return new DZe(n,e,t,i)}function YJ(n){return n=n.prototype,!(!n||!n.isReactComponent)}function NZe(n){if(typeof n=="function")return YJ(n)?1:0;if(n!=null){if(n=n.$$typeof,n===pJ)return 11;if(n===mJ)return 14}return 2}function Mv(n,e){var t=n.alternate;return t===null?(t=Qh(n.tag,e,n.key,n.mode),t.elementType=n.elementType,t.type=n.type,t.stateNode=n.stateNode,t.alternate=n,n.alternate=t):(t.pendingProps=e,t.type=n.type,t.flags=0,t.subtreeFlags=0,t.deletions=null),t.flags=n.flags&14680064,t.childLanes=n.childLanes,t.lanes=n.lanes,t.child=n.child,t.memoizedProps=n.memoizedProps,t.memoizedState=n.memoizedState,t.updateQueue=n.updateQueue,e=n.dependencies,t.dependencies=e===null?null:{lanes:e.lanes,firstContext:e.firstContext},t.sibling=n.sibling,t.index=n.index,t.ref=n.ref,t}function MF(n,e,t,i,o,r){var s=2;if(i=n,typeof n=="function")YJ(n)&&(s=1);else if(typeof n=="string")s=5;else e:switch(n){case NS:return Oy(t.children,o,r,e);case fJ:s=8,o|=8;break;case vQ:return n=Qh(12,t,e,o|2),n.elementType=vQ,n.lanes=r,n;case xQ:return n=Qh(13,t,e,o),n.elementType=xQ,n.lanes=r,n;case wQ:return n=Qh(19,t,e,o),n.elementType=wQ,n.lanes=r,n;case qCe:return m5(t,o,r,e);default:if(typeof n=="object"&&n!==null)switch(n.$$typeof){case $Ce:s=10;break e;case jCe:s=9;break e;case pJ:s=11;break e;case mJ:s=14;break e;case wv:s=16,i=null;break e}throw Error(Ye(130,n==null?n:typeof n,""))}return e=Qh(s,t,e,o),e.elementType=n,e.type=i,e.lanes=r,e}function Oy(n,e,t,i){return n=Qh(7,n,i,e),n.lanes=t,n}function m5(n,e,t,i){return n=Qh(22,n,i,e),n.elementType=qCe,n.lanes=t,n.stateNode={isHidden:!1},n}function gQ(n,e,t){return n=Qh(6,n,null,e),n.lanes=t,n}function _Q(n,e,t){return e=Qh(4,n.children!==null?n.children:[],n.key,e),e.lanes=t,e.stateNode={containerInfo:n.containerInfo,pendingChildren:null,implementation:n.implementation},e}function RZe(n,e,t,i,o){this.tag=e,this.containerInfo=n,this.finishedWork=this.pingCache=this.current=this.pendingChildren=null,this.timeoutHandle=-1,this.callbackNode=this.pendingContext=this.context=null,this.callbackPriority=0,this.eventTimes=eQ(0),this.expirationTimes=eQ(-1),this.entangledLanes=this.finishedLanes=this.mutableReadLanes=this.expiredLanes=this.pingedLanes=this.suspendedLanes=this.pendingLanes=0,this.entanglements=eQ(0),this.identifierPrefix=i,this.onRecoverableError=o,this.mutableSourceEagerHydrationData=null}function ZJ(n,e,t,i,o,r,s,a,l){return n=new RZe(n,e,t,a,l),e===1?(e=1,r===!0&&(e|=8)):e=0,r=Qh(3,null,null,e),n.current=r,r.stateNode=n,r.memoizedState={element:i,isDehydrated:t,cache:null,transitions:null,pendingSuspenseBoundaries:null},AJ(r),n}function AZe(n,e,t){var i=3{"use strict";function zSe(){if(!(typeof __REACT_DEVTOOLS_GLOBAL_HOOK__>"u"||typeof __REACT_DEVTOOLS_GLOBAL_HOOK__.checkDCE!="function"))try{__REACT_DEVTOOLS_GLOBAL_HOOK__.checkDCE(zSe)}catch(n){console.error(n)}}zSe(),VSe.exports=HSe()});var $Se=ws(eee=>{"use strict";var USe=x5();eee.createRoot=USe.createRoot,eee.hydrateRoot=USe.hydrateRoot;var qkt});var XSe=ws(ZSe=>{"use strict";var rk=Xe();function HZe(n,e){return n===e&&(n!==0||1/n===1/e)||n!==n&&e!==e}var zZe=typeof Object.is=="function"?Object.is:HZe,VZe=rk.useState,UZe=rk.useEffect,$Ze=rk.useLayoutEffect,jZe=rk.useDebugValue;function qZe(n,e){var t=e(),i=VZe({inst:{value:t,getSnapshot:e}}),o=i[0].inst,r=i[1];return $Ze(function(){o.value=t,o.getSnapshot=e,oee(o)&&r({inst:o})},[n,t,e]),UZe(function(){return oee(o)&&r({inst:o}),n(function(){oee(o)&&r({inst:o})})},[n]),jZe(t),t}function oee(n){var e=n.getSnapshot;n=n.value;try{var t=e();return!zZe(n,t)}catch{return!0}}function KZe(n,e){return e()}var GZe=typeof window>"u"||typeof window.document>"u"||typeof window.document.createElement>"u"?KZe:qZe;ZSe.useSyncExternalStore=rk.useSyncExternalStore!==void 0?rk.useSyncExternalStore:GZe});var JSe=ws((Zkt,QSe)=>{"use strict";QSe.exports=XSe()});var vke=ws(R5=>{"use strict";R5.byteLength=xXe;R5.toByteArray=yXe;R5.fromByteArray=kXe;var mm=[],rf=[],vXe=typeof Uint8Array<"u"?Uint8Array:Array,uee="ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789+/";for(jy=0,_ke=uee.length;jy<_ke;++jy)mm[jy]=uee[jy],rf[uee.charCodeAt(jy)]=jy;var jy,_ke;rf[45]=62;rf[95]=63;function bke(n){var e=n.length;if(e%4>0)throw new Error("Invalid string. Length must be a multiple of 4");var t=n.indexOf("=");t===-1&&(t=e);var i=t===e?0:4-t%4;return[t,i]}function xXe(n){var e=bke(n),t=e[0],i=e[1];return(t+i)*3/4-i}function wXe(n,e,t){return(e+t)*3/4-t}function yXe(n){var e,t=bke(n),i=t[0],o=t[1],r=new vXe(wXe(n,i,o)),s=0,a=o>0?i-4:i,l;for(l=0;l>16&255,r[s++]=e>>8&255,r[s++]=e&255;return o===2&&(e=rf[n.charCodeAt(l)]<<2|rf[n.charCodeAt(l+1)]>>4,r[s++]=e&255),o===1&&(e=rf[n.charCodeAt(l)]<<10|rf[n.charCodeAt(l+1)]<<4|rf[n.charCodeAt(l+2)]>>2,r[s++]=e>>8&255,r[s++]=e&255),r}function CXe(n){return mm[n>>18&63]+mm[n>>12&63]+mm[n>>6&63]+mm[n&63]}function SXe(n,e,t){for(var i,o=[],r=e;ra?a:s+r));return i===1?(e=n[t-1],o.push(mm[e>>2]+mm[e<<4&63]+"==")):i===2&&(e=(n[t-2]<<8)+n[t-1],o.push(mm[e>>10]+mm[e>>4&63]+mm[e<<2&63]+"=")),o.join("")}});var xke=ws(hee=>{hee.read=function(n,e,t,i,o){var r,s,a=o*8-i-1,l=(1<>1,d=-7,u=t?o-1:0,h=t?-1:1,f=n[e+u];for(u+=h,r=f&(1<<-d)-1,f>>=-d,d+=a;d>0;r=r*256+n[e+u],u+=h,d-=8);for(s=r&(1<<-d)-1,r>>=-d,d+=i;d>0;s=s*256+n[e+u],u+=h,d-=8);if(r===0)r=1-c;else{if(r===l)return s?NaN:(f?-1:1)*(1/0);s=s+Math.pow(2,i),r=r-c}return(f?-1:1)*s*Math.pow(2,r-i)};hee.write=function(n,e,t,i,o,r){var s,a,l,c=r*8-o-1,d=(1<>1,h=o===23?Math.pow(2,-24)-Math.pow(2,-77):0,f=i?0:r-1,p=i?1:-1,g=e<0||e===0&&1/e<0?1:0;for(e=Math.abs(e),isNaN(e)||e===1/0?(a=isNaN(e)?1:0,s=d):(s=Math.floor(Math.log(e)/Math.LN2),e*(l=Math.pow(2,-s))<1&&(s--,l*=2),s+u>=1?e+=h/l:e+=h*Math.pow(2,1-u),e*l>=2&&(s++,l/=2),s+u>=d?(a=0,s=d):s+u>=1?(a=(e*l-1)*Math.pow(2,o),s=s+u):(a=e*Math.pow(2,u-1)*Math.pow(2,o),s=0));o>=8;n[t+f]=a&255,f+=p,a/=256,o-=8);for(s=s<0;n[t+f]=s&255,f+=p,s/=256,c-=8);n[t+f-p]|=g*128}});var Fke=ws(uk=>{"use strict";var fee=vke(),ck=xke(),wke=typeof Symbol=="function"&&typeof Symbol.for=="function"?Symbol.for("nodejs.util.inspect.custom"):null;uk.Buffer=Ae;uk.SlowBuffer=NXe;uk.INSPECT_MAX_BYTES=50;var A5=2147483647;uk.kMaxLength=A5;Ae.TYPED_ARRAY_SUPPORT=LXe();!Ae.TYPED_ARRAY_SUPPORT&&typeof console<"u"&&typeof console.error=="function"&&console.error("This browser lacks typed array (Uint8Array) support which is required by `buffer` v5.x. Use `buffer` v4.x if you require old browser support.");function LXe(){try{let n=new Uint8Array(1),e={foo:function(){return 42}};return Object.setPrototypeOf(e,Uint8Array.prototype),Object.setPrototypeOf(n,e),n.foo()===42}catch{return!1}}Object.defineProperty(Ae.prototype,"parent",{enumerable:!0,get:function(){if(Ae.isBuffer(this))return this.buffer}});Object.defineProperty(Ae.prototype,"offset",{enumerable:!0,get:function(){if(Ae.isBuffer(this))return this.byteOffset}});function I_(n){if(n>A5)throw new RangeError('The value "'+n+'" is invalid for option "size"');let e=new Uint8Array(n);return Object.setPrototypeOf(e,Ae.prototype),e}function Ae(n,e,t){if(typeof n=="number"){if(typeof e=="string")throw new TypeError('The "string" argument must be of type string. Received type number');return _ee(n)}return kke(n,e,t)}Ae.poolSize=8192;function kke(n,e,t){if(typeof n=="string")return EXe(n,e);if(ArrayBuffer.isView(n))return TXe(n);if(n==null)throw new TypeError("The first argument must be one of type string, Buffer, ArrayBuffer, Array, or Array-like Object. Received type "+typeof n);if(gm(n,ArrayBuffer)||n&&gm(n.buffer,ArrayBuffer)||typeof SharedArrayBuffer<"u"&&(gm(n,SharedArrayBuffer)||n&&gm(n.buffer,SharedArrayBuffer)))return mee(n,e,t);if(typeof n=="number")throw new TypeError('The "value" argument must not be of type number. Received type number');let i=n.valueOf&&n.valueOf();if(i!=null&&i!==n)return Ae.from(i,e,t);let o=DXe(n);if(o)return o;if(typeof Symbol<"u"&&Symbol.toPrimitive!=null&&typeof n[Symbol.toPrimitive]=="function")return Ae.from(n[Symbol.toPrimitive]("string"),e,t);throw new TypeError("The first argument must be one of type string, Buffer, ArrayBuffer, Array, or Array-like Object. Received type "+typeof n)}Ae.from=function(n,e,t){return kke(n,e,t)};Object.setPrototypeOf(Ae.prototype,Uint8Array.prototype);Object.setPrototypeOf(Ae,Uint8Array);function Lke(n){if(typeof n!="number")throw new TypeError('"size" argument must be of type number');if(n<0)throw new RangeError('The value "'+n+'" is invalid for option "size"')}function IXe(n,e,t){return Lke(n),n<=0?I_(n):e!==void 0?typeof t=="string"?I_(n).fill(e,t):I_(n).fill(e):I_(n)}Ae.alloc=function(n,e,t){return IXe(n,e,t)};function _ee(n){return Lke(n),I_(n<0?0:bee(n)|0)}Ae.allocUnsafe=function(n){return _ee(n)};Ae.allocUnsafeSlow=function(n){return _ee(n)};function EXe(n,e){if((typeof e!="string"||e==="")&&(e="utf8"),!Ae.isEncoding(e))throw new TypeError("Unknown encoding: "+e);let t=Ike(n,e)|0,i=I_(t),o=i.write(n,e);return o!==t&&(i=i.slice(0,o)),i}function pee(n){let e=n.length<0?0:bee(n.length)|0,t=I_(e);for(let i=0;i=A5)throw new RangeError("Attempt to allocate Buffer larger than maximum size: 0x"+A5.toString(16)+" bytes");return n|0}function NXe(n){return+n!=n&&(n=0),Ae.alloc(+n)}Ae.isBuffer=function(e){return e!=null&&e._isBuffer===!0&&e!==Ae.prototype};Ae.compare=function(e,t){if(gm(e,Uint8Array)&&(e=Ae.from(e,e.offset,e.byteLength)),gm(t,Uint8Array)&&(t=Ae.from(t,t.offset,t.byteLength)),!Ae.isBuffer(e)||!Ae.isBuffer(t))throw new TypeError('The "buf1", "buf2" arguments must be one of type Buffer or Uint8Array');if(e===t)return 0;let i=e.length,o=t.length;for(let r=0,s=Math.min(i,o);ro.length?(Ae.isBuffer(s)||(s=Ae.from(s)),s.copy(o,r)):Uint8Array.prototype.set.call(o,s,r);else if(Ae.isBuffer(s))s.copy(o,r);else throw new TypeError('"list" argument must be an Array of Buffers');r+=s.length}return o};function Ike(n,e){if(Ae.isBuffer(n))return n.length;if(ArrayBuffer.isView(n)||gm(n,ArrayBuffer))return n.byteLength;if(typeof n!="string")throw new TypeError('The "string" argument must be one of type string, Buffer, or ArrayBuffer. Received type '+typeof n);let t=n.length,i=arguments.length>2&&arguments[2]===!0;if(!i&&t===0)return 0;let o=!1;for(;;)switch(e){case"ascii":case"latin1":case"binary":return t;case"utf8":case"utf-8":return gee(n).length;case"ucs2":case"ucs-2":case"utf16le":case"utf-16le":return t*2;case"hex":return t>>>1;case"base64":return Oke(n).length;default:if(o)return i?-1:gee(n).length;e=(""+e).toLowerCase(),o=!0}}Ae.byteLength=Ike;function RXe(n,e,t){let i=!1;if((e===void 0||e<0)&&(e=0),e>this.length||((t===void 0||t>this.length)&&(t=this.length),t<=0)||(t>>>=0,e>>>=0,t<=e))return"";for(n||(n="utf8");;)switch(n){case"hex":return VXe(this,e,t);case"utf8":case"utf-8":return Tke(this,e,t);case"ascii":return HXe(this,e,t);case"latin1":case"binary":return zXe(this,e,t);case"base64":return BXe(this,e,t);case"ucs2":case"ucs-2":case"utf16le":case"utf-16le":return UXe(this,e,t);default:if(i)throw new TypeError("Unknown encoding: "+n);n=(n+"").toLowerCase(),i=!0}}Ae.prototype._isBuffer=!0;function qy(n,e,t){let i=n[e];n[e]=n[t],n[t]=i}Ae.prototype.swap16=function(){let e=this.length;if(e%2!==0)throw new RangeError("Buffer size must be a multiple of 16-bits");for(let t=0;tt&&(e+=" ... "),""};wke&&(Ae.prototype[wke]=Ae.prototype.inspect);Ae.prototype.compare=function(e,t,i,o,r){if(gm(e,Uint8Array)&&(e=Ae.from(e,e.offset,e.byteLength)),!Ae.isBuffer(e))throw new TypeError('The "target" argument must be one of type Buffer or Uint8Array. Received type '+typeof e);if(t===void 0&&(t=0),i===void 0&&(i=e?e.length:0),o===void 0&&(o=0),r===void 0&&(r=this.length),t<0||i>e.length||o<0||r>this.length)throw new RangeError("out of range index");if(o>=r&&t>=i)return 0;if(o>=r)return-1;if(t>=i)return 1;if(t>>>=0,i>>>=0,o>>>=0,r>>>=0,this===e)return 0;let s=r-o,a=i-t,l=Math.min(s,a),c=this.slice(o,r),d=e.slice(t,i);for(let u=0;u2147483647?t=2147483647:t<-2147483648&&(t=-2147483648),t=+t,xee(t)&&(t=o?0:n.length-1),t<0&&(t=n.length+t),t>=n.length){if(o)return-1;t=n.length-1}else if(t<0)if(o)t=0;else return-1;if(typeof e=="string"&&(e=Ae.from(e,i)),Ae.isBuffer(e))return e.length===0?-1:yke(n,e,t,i,o);if(typeof e=="number")return e=e&255,typeof Uint8Array.prototype.indexOf=="function"?o?Uint8Array.prototype.indexOf.call(n,e,t):Uint8Array.prototype.lastIndexOf.call(n,e,t):yke(n,[e],t,i,o);throw new TypeError("val must be string, number or Buffer")}function yke(n,e,t,i,o){let r=1,s=n.length,a=e.length;if(i!==void 0&&(i=String(i).toLowerCase(),i==="ucs2"||i==="ucs-2"||i==="utf16le"||i==="utf-16le")){if(n.length<2||e.length<2)return-1;r=2,s/=2,a/=2,t/=2}function l(d,u){return r===1?d[u]:d.readUInt16BE(u*r)}let c;if(o){let d=-1;for(c=t;cs&&(t=s-a),c=t;c>=0;c--){let d=!0;for(let u=0;uo&&(i=o)):i=o;let r=e.length;i>r/2&&(i=r/2);let s;for(s=0;s>>0,isFinite(i)?(i=i>>>0,o===void 0&&(o="utf8")):(o=i,i=void 0);else throw new Error("Buffer.write(string, encoding, offset[, length]) is no longer supported");let r=this.length-t;if((i===void 0||i>r)&&(i=r),e.length>0&&(i<0||t<0)||t>this.length)throw new RangeError("Attempt to write outside buffer bounds");o||(o="utf8");let s=!1;for(;;)switch(o){case"hex":return AXe(this,e,t,i);case"utf8":case"utf-8":return MXe(this,e,t,i);case"ascii":case"latin1":case"binary":return PXe(this,e,t,i);case"base64":return OXe(this,e,t,i);case"ucs2":case"ucs-2":case"utf16le":case"utf-16le":return FXe(this,e,t,i);default:if(s)throw new TypeError("Unknown encoding: "+o);o=(""+o).toLowerCase(),s=!0}};Ae.prototype.toJSON=function(){return{type:"Buffer",data:Array.prototype.slice.call(this._arr||this,0)}};function BXe(n,e,t){return e===0&&t===n.length?fee.fromByteArray(n):fee.fromByteArray(n.slice(e,t))}function Tke(n,e,t){t=Math.min(n.length,t);let i=[],o=e;for(;o239?4:r>223?3:r>191?2:1;if(o+a<=t){let l,c,d,u;switch(a){case 1:r<128&&(s=r);break;case 2:l=n[o+1],(l&192)===128&&(u=(r&31)<<6|l&63,u>127&&(s=u));break;case 3:l=n[o+1],c=n[o+2],(l&192)===128&&(c&192)===128&&(u=(r&15)<<12|(l&63)<<6|c&63,u>2047&&(u<55296||u>57343)&&(s=u));break;case 4:l=n[o+1],c=n[o+2],d=n[o+3],(l&192)===128&&(c&192)===128&&(d&192)===128&&(u=(r&15)<<18|(l&63)<<12|(c&63)<<6|d&63,u>65535&&u<1114112&&(s=u))}}s===null?(s=65533,a=1):s>65535&&(s-=65536,i.push(s>>>10&1023|55296),s=56320|s&1023),i.push(s),o+=a}return WXe(i)}var Cke=4096;function WXe(n){let e=n.length;if(e<=Cke)return String.fromCharCode.apply(String,n);let t="",i=0;for(;ii)&&(t=i);let o="";for(let r=e;ri&&(e=i),t<0?(t+=i,t<0&&(t=0)):t>i&&(t=i),tt)throw new RangeError("Trying to access beyond buffer length")}Ae.prototype.readUintLE=Ae.prototype.readUIntLE=function(e,t,i){e=e>>>0,t=t>>>0,i||vl(e,t,this.length);let o=this[e],r=1,s=0;for(;++s>>0,t=t>>>0,i||vl(e,t,this.length);let o=this[e+--t],r=1;for(;t>0&&(r*=256);)o+=this[e+--t]*r;return o};Ae.prototype.readUint8=Ae.prototype.readUInt8=function(e,t){return e=e>>>0,t||vl(e,1,this.length),this[e]};Ae.prototype.readUint16LE=Ae.prototype.readUInt16LE=function(e,t){return e=e>>>0,t||vl(e,2,this.length),this[e]|this[e+1]<<8};Ae.prototype.readUint16BE=Ae.prototype.readUInt16BE=function(e,t){return e=e>>>0,t||vl(e,2,this.length),this[e]<<8|this[e+1]};Ae.prototype.readUint32LE=Ae.prototype.readUInt32LE=function(e,t){return e=e>>>0,t||vl(e,4,this.length),(this[e]|this[e+1]<<8|this[e+2]<<16)+this[e+3]*16777216};Ae.prototype.readUint32BE=Ae.prototype.readUInt32BE=function(e,t){return e=e>>>0,t||vl(e,4,this.length),this[e]*16777216+(this[e+1]<<16|this[e+2]<<8|this[e+3])};Ae.prototype.readBigUInt64LE=zv(function(e){e=e>>>0,dk(e,"offset");let t=this[e],i=this[e+7];(t===void 0||i===void 0)&&eR(e,this.length-8);let o=t+this[++e]*2**8+this[++e]*2**16+this[++e]*2**24,r=this[++e]+this[++e]*2**8+this[++e]*2**16+i*2**24;return BigInt(o)+(BigInt(r)<>>0,dk(e,"offset");let t=this[e],i=this[e+7];(t===void 0||i===void 0)&&eR(e,this.length-8);let o=t*2**24+this[++e]*2**16+this[++e]*2**8+this[++e],r=this[++e]*2**24+this[++e]*2**16+this[++e]*2**8+i;return(BigInt(o)<>>0,t=t>>>0,i||vl(e,t,this.length);let o=this[e],r=1,s=0;for(;++s=r&&(o-=Math.pow(2,8*t)),o};Ae.prototype.readIntBE=function(e,t,i){e=e>>>0,t=t>>>0,i||vl(e,t,this.length);let o=t,r=1,s=this[e+--o];for(;o>0&&(r*=256);)s+=this[e+--o]*r;return r*=128,s>=r&&(s-=Math.pow(2,8*t)),s};Ae.prototype.readInt8=function(e,t){return e=e>>>0,t||vl(e,1,this.length),this[e]&128?(255-this[e]+1)*-1:this[e]};Ae.prototype.readInt16LE=function(e,t){e=e>>>0,t||vl(e,2,this.length);let i=this[e]|this[e+1]<<8;return i&32768?i|4294901760:i};Ae.prototype.readInt16BE=function(e,t){e=e>>>0,t||vl(e,2,this.length);let i=this[e+1]|this[e]<<8;return i&32768?i|4294901760:i};Ae.prototype.readInt32LE=function(e,t){return e=e>>>0,t||vl(e,4,this.length),this[e]|this[e+1]<<8|this[e+2]<<16|this[e+3]<<24};Ae.prototype.readInt32BE=function(e,t){return e=e>>>0,t||vl(e,4,this.length),this[e]<<24|this[e+1]<<16|this[e+2]<<8|this[e+3]};Ae.prototype.readBigInt64LE=zv(function(e){e=e>>>0,dk(e,"offset");let t=this[e],i=this[e+7];(t===void 0||i===void 0)&&eR(e,this.length-8);let o=this[e+4]+this[e+5]*2**8+this[e+6]*2**16+(i<<24);return(BigInt(o)<>>0,dk(e,"offset");let t=this[e],i=this[e+7];(t===void 0||i===void 0)&&eR(e,this.length-8);let o=(t<<24)+this[++e]*2**16+this[++e]*2**8+this[++e];return(BigInt(o)<>>0,t||vl(e,4,this.length),ck.read(this,e,!0,23,4)};Ae.prototype.readFloatBE=function(e,t){return e=e>>>0,t||vl(e,4,this.length),ck.read(this,e,!1,23,4)};Ae.prototype.readDoubleLE=function(e,t){return e=e>>>0,t||vl(e,8,this.length),ck.read(this,e,!0,52,8)};Ae.prototype.readDoubleBE=function(e,t){return e=e>>>0,t||vl(e,8,this.length),ck.read(this,e,!1,52,8)};function su(n,e,t,i,o,r){if(!Ae.isBuffer(n))throw new TypeError('"buffer" argument must be a Buffer instance');if(e>o||en.length)throw new RangeError("Index out of range")}Ae.prototype.writeUintLE=Ae.prototype.writeUIntLE=function(e,t,i,o){if(e=+e,t=t>>>0,i=i>>>0,!o){let a=Math.pow(2,8*i)-1;su(this,e,t,i,a,0)}let r=1,s=0;for(this[t]=e&255;++s>>0,i=i>>>0,!o){let a=Math.pow(2,8*i)-1;su(this,e,t,i,a,0)}let r=i-1,s=1;for(this[t+r]=e&255;--r>=0&&(s*=256);)this[t+r]=e/s&255;return t+i};Ae.prototype.writeUint8=Ae.prototype.writeUInt8=function(e,t,i){return e=+e,t=t>>>0,i||su(this,e,t,1,255,0),this[t]=e&255,t+1};Ae.prototype.writeUint16LE=Ae.prototype.writeUInt16LE=function(e,t,i){return e=+e,t=t>>>0,i||su(this,e,t,2,65535,0),this[t]=e&255,this[t+1]=e>>>8,t+2};Ae.prototype.writeUint16BE=Ae.prototype.writeUInt16BE=function(e,t,i){return e=+e,t=t>>>0,i||su(this,e,t,2,65535,0),this[t]=e>>>8,this[t+1]=e&255,t+2};Ae.prototype.writeUint32LE=Ae.prototype.writeUInt32LE=function(e,t,i){return e=+e,t=t>>>0,i||su(this,e,t,4,4294967295,0),this[t+3]=e>>>24,this[t+2]=e>>>16,this[t+1]=e>>>8,this[t]=e&255,t+4};Ae.prototype.writeUint32BE=Ae.prototype.writeUInt32BE=function(e,t,i){return e=+e,t=t>>>0,i||su(this,e,t,4,4294967295,0),this[t]=e>>>24,this[t+1]=e>>>16,this[t+2]=e>>>8,this[t+3]=e&255,t+4};function Dke(n,e,t,i,o){Pke(e,i,o,n,t,7);let r=Number(e&BigInt(4294967295));n[t++]=r,r=r>>8,n[t++]=r,r=r>>8,n[t++]=r,r=r>>8,n[t++]=r;let s=Number(e>>BigInt(32)&BigInt(4294967295));return n[t++]=s,s=s>>8,n[t++]=s,s=s>>8,n[t++]=s,s=s>>8,n[t++]=s,t}function Nke(n,e,t,i,o){Pke(e,i,o,n,t,7);let r=Number(e&BigInt(4294967295));n[t+7]=r,r=r>>8,n[t+6]=r,r=r>>8,n[t+5]=r,r=r>>8,n[t+4]=r;let s=Number(e>>BigInt(32)&BigInt(4294967295));return n[t+3]=s,s=s>>8,n[t+2]=s,s=s>>8,n[t+1]=s,s=s>>8,n[t]=s,t+8}Ae.prototype.writeBigUInt64LE=zv(function(e,t=0){return Dke(this,e,t,BigInt(0),BigInt("0xffffffffffffffff"))});Ae.prototype.writeBigUInt64BE=zv(function(e,t=0){return Nke(this,e,t,BigInt(0),BigInt("0xffffffffffffffff"))});Ae.prototype.writeIntLE=function(e,t,i,o){if(e=+e,t=t>>>0,!o){let l=Math.pow(2,8*i-1);su(this,e,t,i,l-1,-l)}let r=0,s=1,a=0;for(this[t]=e&255;++r>0)-a&255;return t+i};Ae.prototype.writeIntBE=function(e,t,i,o){if(e=+e,t=t>>>0,!o){let l=Math.pow(2,8*i-1);su(this,e,t,i,l-1,-l)}let r=i-1,s=1,a=0;for(this[t+r]=e&255;--r>=0&&(s*=256);)e<0&&a===0&&this[t+r+1]!==0&&(a=1),this[t+r]=(e/s>>0)-a&255;return t+i};Ae.prototype.writeInt8=function(e,t,i){return e=+e,t=t>>>0,i||su(this,e,t,1,127,-128),e<0&&(e=255+e+1),this[t]=e&255,t+1};Ae.prototype.writeInt16LE=function(e,t,i){return e=+e,t=t>>>0,i||su(this,e,t,2,32767,-32768),this[t]=e&255,this[t+1]=e>>>8,t+2};Ae.prototype.writeInt16BE=function(e,t,i){return e=+e,t=t>>>0,i||su(this,e,t,2,32767,-32768),this[t]=e>>>8,this[t+1]=e&255,t+2};Ae.prototype.writeInt32LE=function(e,t,i){return e=+e,t=t>>>0,i||su(this,e,t,4,2147483647,-2147483648),this[t]=e&255,this[t+1]=e>>>8,this[t+2]=e>>>16,this[t+3]=e>>>24,t+4};Ae.prototype.writeInt32BE=function(e,t,i){return e=+e,t=t>>>0,i||su(this,e,t,4,2147483647,-2147483648),e<0&&(e=4294967295+e+1),this[t]=e>>>24,this[t+1]=e>>>16,this[t+2]=e>>>8,this[t+3]=e&255,t+4};Ae.prototype.writeBigInt64LE=zv(function(e,t=0){return Dke(this,e,t,-BigInt("0x8000000000000000"),BigInt("0x7fffffffffffffff"))});Ae.prototype.writeBigInt64BE=zv(function(e,t=0){return Nke(this,e,t,-BigInt("0x8000000000000000"),BigInt("0x7fffffffffffffff"))});function Rke(n,e,t,i,o,r){if(t+i>n.length)throw new RangeError("Index out of range");if(t<0)throw new RangeError("Index out of range")}function Ake(n,e,t,i,o){return e=+e,t=t>>>0,o||Rke(n,e,t,4,34028234663852886e22,-34028234663852886e22),ck.write(n,e,t,i,23,4),t+4}Ae.prototype.writeFloatLE=function(e,t,i){return Ake(this,e,t,!0,i)};Ae.prototype.writeFloatBE=function(e,t,i){return Ake(this,e,t,!1,i)};function Mke(n,e,t,i,o){return e=+e,t=t>>>0,o||Rke(n,e,t,8,17976931348623157e292,-17976931348623157e292),ck.write(n,e,t,i,52,8),t+8}Ae.prototype.writeDoubleLE=function(e,t,i){return Mke(this,e,t,!0,i)};Ae.prototype.writeDoubleBE=function(e,t,i){return Mke(this,e,t,!1,i)};Ae.prototype.copy=function(e,t,i,o){if(!Ae.isBuffer(e))throw new TypeError("argument should be a Buffer");if(i||(i=0),!o&&o!==0&&(o=this.length),t>=e.length&&(t=e.length),t||(t=0),o>0&&o=this.length)throw new RangeError("Index out of range");if(o<0)throw new RangeError("sourceEnd out of bounds");o>this.length&&(o=this.length),e.length-t>>0,i=i===void 0?this.length:i>>>0,e||(e=0);let r;if(typeof e=="number")for(r=t;r2**32?o=Ske(String(t)):typeof t=="bigint"&&(o=String(t),(t>BigInt(2)**BigInt(32)||t<-(BigInt(2)**BigInt(32)))&&(o=Ske(o)),o+="n"),i+=` It must be ${e}. Received ${o}`,i},RangeError);function Ske(n){let e="",t=n.length,i=n[0]==="-"?1:0;for(;t>=i+4;t-=3)e=`_${n.slice(t-3,t)}${e}`;return`${n.slice(0,t)}${e}`}function $Xe(n,e,t){dk(e,"offset"),(n[e]===void 0||n[e+t]===void 0)&&eR(e,n.length-(t+1))}function Pke(n,e,t,i,o,r){if(n>t||n3?e===0||e===BigInt(0)?a=`>= 0${s} and < 2${s} ** ${(r+1)*8}${s}`:a=`>= -(2${s} ** ${(r+1)*8-1}${s}) and < 2 ** ${(r+1)*8-1}${s}`:a=`>= ${e}${s} and <= ${t}${s}`,new lk.ERR_OUT_OF_RANGE("value",a,n)}$Xe(i,o,r)}function dk(n,e){if(typeof n!="number")throw new lk.ERR_INVALID_ARG_TYPE(e,"number",n)}function eR(n,e,t){throw Math.floor(n)!==n?(dk(n,t),new lk.ERR_OUT_OF_RANGE(t||"offset","an integer",n)):e<0?new lk.ERR_BUFFER_OUT_OF_BOUNDS:new lk.ERR_OUT_OF_RANGE(t||"offset",`>= ${t?1:0} and <= ${e}`,n)}var jXe=/[^+/0-9A-Za-z-_]/g;function qXe(n){if(n=n.split("=")[0],n=n.trim().replace(jXe,""),n.length<2)return"";for(;n.length%4!==0;)n=n+"=";return n}function gee(n,e){e=e||1/0;let t,i=n.length,o=null,r=[];for(let s=0;s55295&&t<57344){if(!o){if(t>56319){(e-=3)>-1&&r.push(239,191,189);continue}else if(s+1===i){(e-=3)>-1&&r.push(239,191,189);continue}o=t;continue}if(t<56320){(e-=3)>-1&&r.push(239,191,189),o=t;continue}t=(o-55296<<10|t-56320)+65536}else o&&(e-=3)>-1&&r.push(239,191,189);if(o=null,t<128){if((e-=1)<0)break;r.push(t)}else if(t<2048){if((e-=2)<0)break;r.push(t>>6|192,t&63|128)}else if(t<65536){if((e-=3)<0)break;r.push(t>>12|224,t>>6&63|128,t&63|128)}else if(t<1114112){if((e-=4)<0)break;r.push(t>>18|240,t>>12&63|128,t>>6&63|128,t&63|128)}else throw new Error("Invalid code point")}return r}function KXe(n){let e=[];for(let t=0;t>8,o=t%256,r.push(o),r.push(i);return r}function Oke(n){return fee.toByteArray(qXe(n))}function M5(n,e,t,i){let o;for(o=0;o=e.length||o>=n.length);++o)e[o+t]=n[o];return o}function gm(n,e){return n instanceof e||n!=null&&n.constructor!=null&&n.constructor.name!=null&&n.constructor.name===e.name}function xee(n){return n!==n}var YXe=function(){let n="0123456789abcdef",e=new Array(256);for(let t=0;t<16;++t){let i=t*16;for(let o=0;o<16;++o)e[i+o]=n[t]+n[o]}return e}();function zv(n){return typeof BigInt>"u"?ZXe:n}function ZXe(){throw new Error("BigInt not supported")}});var Xke=ws((lEt,Zke)=>{var qke=/\/\*[^*]*\*+([^/*][^*]*\*+)*\//g,aQe=/\n/g,lQe=/^\s*/,cQe=/^(\*?[-#/*\\\w]+(\[[0-9a-z_-]+\])?)\s*/,dQe=/^:\s*/,uQe=/^((?:'(?:\\'|.)*?'|"(?:\\"|.)*?"|\([^)]*?\)|[^};])+)/,hQe=/^[;\s]*/,fQe=/^\s+|\s+$/g,pQe=` `,Kke="/",Gke="*",Yy="",mQe="comment",gQe="declaration";Zke.exports=function(n,e){if(typeof n!="string")throw new TypeError("First argument must be a string");if(!n)return[];e=e||{};var t=1,i=1;function o(g){var _=g.match(aQe);_&&(t+=_.length);var b=g.lastIndexOf(pQe);i=~b?g.length-b:i+g.length}function r(){var g={line:t,column:i};return function(_){return _.position=new s(g),d(),_}}function s(g){this.start=g,this.end={line:t,column:i},this.source=e.source}s.prototype.content=n;var a=[];function l(g){var _=new Error(e.source+":"+t+":"+i+": "+g);if(_.reason=g,_.filename=e.source,_.line=t,_.column=i,_.source=n,e.silent)a.push(_);else throw _}function c(g){var _=g.exec(n);if(_){var b=_[0];return o(b),n=n.slice(b.length),_}}function d(){c(lQe)}function u(g){var _;for(g=g||[];_=h();)_!==!1&&g.push(_);return g}function h(){var g=r();if(!(Kke!=n.charAt(0)||Gke!=n.charAt(1))){for(var _=2;Yy!=n.charAt(_)&&(Gke!=n.charAt(_)||Kke!=n.charAt(_+1));)++_;if(_+=2,Yy===n.charAt(_-1))return l("End of comment missing");var b=n.slice(2,_-2);return i+=2,o(b),n=n.slice(_),i+=2,g({type:mQe,comment:b})}}function f(){var g=r(),_=c(cQe);if(_){if(h(),!c(dQe))return l("property missing ':'");var b=c(uQe),v=g({type:gQe,property:Yke(_[0].replace(qke,Yy)),value:b?Yke(b[0].replace(qke,Yy)):Yy});return c(hQe),v}}function p(){var g=[];u(g);for(var _;_=f();)_!==!1&&(g.push(_),u(g));return g}return d(),p()};function Yke(n){return n?n.replace(fQe,Yy):Yy}});var Qke=ws(nR=>{"use strict";var _Qe=nR&&nR.__importDefault||function(n){return n&&n.__esModule?n:{default:n}};Object.defineProperty(nR,"__esModule",{value:!0});nR.default=vQe;var bQe=_Qe(Xke());function vQe(n,e){var t=null;if(!n||typeof n!="string")return t;var i=(0,bQe.default)(n),o=typeof e=="function";return i.forEach(function(r){if(r.type==="declaration"){var s=r.property,a=r.value;o?e(s,a,r):a&&(t=t||{},t[s]=a)}}),t}});var eLe=ws(z5=>{"use strict";Object.defineProperty(z5,"__esModule",{value:!0});z5.camelCase=void 0;var xQe=/^--[a-zA-Z0-9_-]+$/,wQe=/-([a-z])/g,yQe=/^[^-]+$/,CQe=/^-(webkit|moz|ms|o|khtml)-/,SQe=/^-(ms)-/,kQe=function(n){return!n||yQe.test(n)||xQe.test(n)},LQe=function(n,e){return e.toUpperCase()},Jke=function(n,e){return"".concat(e,"-")},IQe=function(n,e){return e===void 0&&(e={}),kQe(n)?n:(n=n.toLowerCase(),e.reactCompat?n=n.replace(SQe,Jke):n=n.replace(CQe,Jke),n.replace(wQe,LQe))};z5.camelCase=IQe});var iLe=ws((Nee,tLe)=>{"use strict";var EQe=Nee&&Nee.__importDefault||function(n){return n&&n.__esModule?n:{default:n}},TQe=EQe(Qke()),DQe=eLe();function Dee(n,e){var t={};return!n||typeof n!="string"||(0,TQe.default)(n,function(i,o){i&&o&&(t[(0,DQe.camelCase)(i,e)]=o)}),t}Dee.default=Dee;tLe.exports=Dee});var hLe=ws(U5=>{"use strict";var ZQe=Xe(),XQe=Symbol.for("react.element"),QQe=Symbol.for("react.fragment"),JQe=Object.prototype.hasOwnProperty,eJe=ZQe.__SECRET_INTERNALS_DO_NOT_USE_OR_YOU_WILL_BE_FIRED.ReactCurrentOwner,tJe={key:!0,ref:!0,__self:!0,__source:!0};function uLe(n,e,t){var i,o={},r=null,s=null;t!==void 0&&(r=""+t),e.key!==void 0&&(r=""+e.key),e.ref!==void 0&&(s=e.ref);for(i in e)JQe.call(e,i)&&!tJe.hasOwnProperty(i)&&(o[i]=e[i]);if(n&&n.defaultProps)for(i in e=n.defaultProps,e)o[i]===void 0&&(o[i]=e[i]);return{$$typeof:XQe,type:n,key:r,ref:s,props:o,_owner:eJe.current}}U5.Fragment=QQe;U5.jsx=uLe;U5.jsxs=uLe});var pLe=ws((PEt,fLe)=>{"use strict";fLe.exports=hLe()});var DIe=ws((HAt,TIe)=>{"use strict";var h3=Object.prototype.hasOwnProperty,EIe=Object.prototype.toString,yIe=Object.defineProperty,CIe=Object.getOwnPropertyDescriptor,SIe=function(e){return typeof Array.isArray=="function"?Array.isArray(e):EIe.call(e)==="[object Array]"},kIe=function(e){if(!e||EIe.call(e)!=="[object Object]")return!1;var t=h3.call(e,"constructor"),i=e.constructor&&e.constructor.prototype&&h3.call(e.constructor.prototype,"isPrototypeOf");if(e.constructor&&!t&&!i)return!1;var o;for(o in e);return typeof o>"u"||h3.call(e,o)},LIe=function(e,t){yIe&&t.name==="__proto__"?yIe(e,t.name,{enumerable:!0,configurable:!0,value:t.newValue,writable:!0}):e[t.name]=t.newValue},IIe=function(e,t){if(t==="__proto__")if(h3.call(e,t)){if(CIe)return CIe(e,t).value}else return;return e[t]};TIe.exports=function n(){var e,t,i,o,r,s,a=arguments[0],l=1,c=arguments.length,d=!1;for(typeof a=="boolean"&&(d=a,a=arguments[1]||{},l=2),(a==null||typeof a!="object"&&typeof a!="function")&&(a={});li===o){if(n===e)return!0;if(!n||!e||n.length!==e.length)return!1;for(let i=0,o=n.length;it(n[i],e))}function Cnt(n,e){let t=0,i=n-1;for(;t<=i;){let o=(t+i)/2|0,r=e(o);if(r<0)t=o+1;else if(r>0)i=o-1;else return o}return-(t+1)}function k3(n,e,t){if(n=n|0,n>=e.length)throw new TypeError("invalid index");let i=e[Math.floor(e.length*Math.random())],o=[],r=[],s=[];for(let a of e){let l=t(a,i);l<0?o.push(a):l>0?r.push(a):s.push(a)}return n!!e)}function _ie(n){let e=0;for(let t=0;t0}function Ac(n,e=t=>t){let t=new Set;return n.filter(i=>{let o=e(i);return t.has(o)?!1:(t.add(o),!0)})}function Wk(n,e){return n.length>0?n[0]:e}function ma(n,e){let t=typeof e=="number"?n:0;typeof e=="number"?t=n:(t=0,e=n);let i=[];if(t<=e)for(let o=t;oe;o--)i.push(o);return i}function Jv(n,e,t){let i=n.slice(0,e),o=n.slice(e);return i.concat(t,o)}function T3(n,e){let t=n.indexOf(e);t>-1&&(n.splice(t,1),n.unshift(e))}function wR(n,e){let t=n.indexOf(e);t>-1&&(n.splice(t,1),n.push(e))}function yR(n,e){for(let t of e)n.push(t)}function Hk(n){return Array.isArray(n)?n:[n]}function Snt(n,e,t){let i=BEe(n,e),o=n.length,r=t.length;n.length=o+r;for(let s=o-1;s>=i;s--)n[s+r]=n[s];for(let s=0;se(n(t),n(i))}function WEe(...n){return(e,t)=>{for(let i of n){let o=i(e,t);if(!xR.isNeitherLessOrGreaterThan(o))return o}return xR.neitherLessOrGreaterThan}}function D3(n){return(e,t)=>-n(e,t)}var xR,yl,HEe,wl,A_,L3,at=k(()=>{(function(n){function e(r){return r<0}n.isLessThan=e;function t(r){return r<=0}n.isLessThanOrEqual=t;function i(r){return r>0}n.isGreaterThan=i;function o(r){return r===0}n.isNeitherLessOrGreaterThan=o,n.greaterThan=1,n.lessThan=-1,n.neitherLessOrGreaterThan=0})(xR||(xR={}));yl=(n,e)=>n-e,HEe=(n,e)=>yl(n?1:0,e?1:0);wl=class{constructor(e){this.items=e,this.firstIdx=0,this.lastIdx=this.items.length-1}get length(){return this.lastIdx-this.firstIdx+1}takeWhile(e){let t=this.firstIdx;for(;t=0&&e(this.items[t]);)t--;let i=t===this.lastIdx?null:this.items.slice(t+1,this.lastIdx+1);return this.lastIdx=t,i}peek(){if(this.length!==0)return this.items[this.firstIdx]}dequeue(){let e=this.items[this.firstIdx];return this.firstIdx++,e}takeCount(e){let t=this.items.slice(this.firstIdx,this.firstIdx+e);return this.firstIdx+=e,t}},A_=class n{static{this.empty=new n(e=>{})}constructor(e){this.iterate=e}toArray(){let e=[];return this.iterate(t=>(e.push(t),!0)),e}filter(e){return new n(t=>this.iterate(i=>e(i)?t(i):!0))}map(e){return new n(t=>this.iterate(i=>t(e(i))))}findLast(e){let t;return this.iterate(i=>(e(i)&&(t=i),!0)),t}findLastMaxBy(e){let t,i=!0;return this.iterate(o=>((i||xR.isGreaterThan(e(o,t)))&&(i=!1,t=o),!0)),t}},L3=class n{constructor(e){this._indexMap=e}static createSortPermutation(e,t){let i=Array.from(e.keys()).sort((o,r)=>t(e[o],e[r]));return new n(i)}apply(e){return e.map((t,i)=>e[this._indexMap[i]])}inverse(){let e=this._indexMap.slice();for(let t=0;t"u"}function xd(n){return!Za(n)}function Za(n){return Vr(n)||n===null}function At(n,e){if(!n)throw new Error(e?`Unexpected type, expected '${e}'`:"Unexpected type")}function lf(n){if(Za(n))throw new Error("Assertion Failed: argument is undefined or null");return n}function ex(n){return typeof n=="function"}function VEe(n,e){let t=Math.min(n.length,e.length);for(let i=0;i{});function cf(n){if(!n||typeof n!="object"||n instanceof RegExp)return n;let e=Array.isArray(n)?[]:{};return Object.entries(n).forEach(([t,i])=>{e[t]=i&&typeof i=="object"?cf(i):i}),e}function UEe(n){if(!n||typeof n!="object")return n;let e=[n];for(;e.length>0;){let t=e.shift();Object.freeze(t);for(let i in t)if($Ee.call(t,i)){let o=t[i];typeof o=="object"&&!Object.isFrozen(o)&&!zEe(o)&&e.push(o)}}return n}function R3(n,e){return xie(n,e,new Set)}function xie(n,e,t){if(Za(n))return n;let i=e(n);if(typeof i<"u")return i;if(Array.isArray(n)){let o=[];for(let r of n)o.push(xie(r,e,t));return o}if(mo(n)){if(t.has(n))throw new Error("Cannot clone recursive data-structure");t.add(n);let o={};for(let r in n)$Ee.call(n,r)&&(o[r]=xie(n[r],e,t));return t.delete(n),o}return n}function c1(n,e,t=!0){return mo(n)?(mo(e)&&Object.keys(e).forEach(i=>{i in n?t&&(mo(n[i])&&mo(e[i])?c1(n[i],e[i],t):n[i]=e[i]):n[i]=e[i]}),n):e}function os(n,e){if(n===e)return!0;if(n==null||e===null||e===void 0||typeof n!=typeof e||typeof n!="object"||Array.isArray(n)!==Array.isArray(e))return!1;let t,i;if(Array.isArray(n)){if(n.length!==e.length)return!1;for(t=0;tfunction(){let r=Array.prototype.slice.call(arguments,0);return e(o,r)},i={};for(let o of n)i[o]=t(o);return i}var $Ee,ec=k(()=>{yi();$Ee=Object.prototype.hasOwnProperty});function SR(){return globalThis._VSCODE_NLS_MESSAGES}function u1(){return globalThis._VSCODE_NLS_LANGUAGE}var wie=k(()=>{});function A3(n,e){let t;return e.length===0?t=n:t=n.replace(/\{(\d+)\}/g,(i,o)=>{let r=o[0],s=e[r],a=i;return typeof s=="string"?a=s:(typeof s=="number"||typeof s=="boolean"||s===void 0||s===null)&&(a=String(s)),a}),Int&&(t="\uFF3B"+t.replace(/[aouei]/g,"$&$&")+"\uFF3D"),t}function m(n,e,...t){return A3(typeof n=="number"?qEe(n,e):e,t)}function qEe(n,e){let t=SR()?.[n];if(typeof t!="string"){if(typeof e=="string")return e;throw new Error(`!!! NLS MISSING: ${n} !!!`)}return t}function et(n,e,...t){let i;typeof n=="number"?i=qEe(n,e):i=e;let o=A3(i,t);return{value:o,original:e===i?o:A3(e,t)}}var Int,pe=k(()=>{wie();wie();Int=u1()==="pseudo"||typeof document<"u"&&document.location&&document.location.hash.indexOf("pseudo=true")>=0});function B3(){if(!YEe){YEe=!0;let n=new Uint8Array(2);n[0]=1,n[1]=2,GEe=new Uint16Array(n.buffer)[0]===513}return GEe}var zk,LR,IR,kR,Ent,ZEe,Cie,Tnt,Sie,Dnt,XEe,M3,P3,KEe,Nnt,P_,O_,rh,QEe,Rnt,yie,kn,dt,Qn,Pc,df,Ant,JEe,Xa,O3,Cm,eTe,Mnt,F3,Ur,GEe,YEe,kie,tTe,iTe,nTe,oTe,Bt=k(()=>{pe();zk="en",LR=!1,IR=!1,kR=!1,Ent=!1,ZEe=!1,Cie=!1,Tnt=!1,Sie=!1,Dnt=!1,XEe=!1,P3=zk,KEe=zk,O_=globalThis;typeof O_.vscode<"u"&&typeof O_.vscode.process<"u"?rh=O_.vscode.process:typeof process<"u"&&typeof process?.versions?.node=="string"&&(rh=process);QEe=typeof rh?.versions?.electron=="string",Rnt=QEe&&rh?.type==="renderer";if(typeof rh=="object"){LR=rh.platform==="win32",IR=rh.platform==="darwin",kR=rh.platform==="linux",Ent=kR&&!!rh.env.SNAP&&!!rh.env.SNAP_REVISION,Tnt=QEe,Dnt=!!rh.env.CI||!!rh.env.BUILD_ARTIFACTSTAGINGDIRECTORY,M3=zk,P3=zk;let n=rh.env.VSCODE_NLS_CONFIG;if(n)try{let e=JSON.parse(n);M3=e.userLocale,KEe=e.osLocale,P3=e.resolvedLanguage||zk,Nnt=e.languagePack?.translationsConfigFile}catch{}ZEe=!0}else typeof navigator=="object"&&!Rnt?(P_=navigator.userAgent,LR=P_.indexOf("Windows")>=0,IR=P_.indexOf("Macintosh")>=0,Sie=(P_.indexOf("Macintosh")>=0||P_.indexOf("iPad")>=0||P_.indexOf("iPhone")>=0)&&!!navigator.maxTouchPoints&&navigator.maxTouchPoints>0,kR=P_.indexOf("Linux")>=0,XEe=P_?.indexOf("Mobi")>=0,Cie=!0,P3=u1()||zk,M3=navigator.language.toLowerCase(),KEe=M3):console.error("Unable to resolve platform.");yie=0;IR?yie=1:LR?yie=3:kR&&(yie=2);kn=LR,dt=IR,Qn=kR,Pc=ZEe,df=Cie,Ant=Cie&&typeof O_.importScripts=="function",JEe=Ant?O_.origin:void 0,Xa=Sie,O3=XEe,Cm=P_,eTe=P3,Mnt=typeof O_.postMessage=="function"&&!O_.importScripts,F3=(()=>{if(Mnt){let n=[];O_.addEventListener("message",t=>{if(t.data&&t.data.vscodeScheduleAsyncWork)for(let i=0,o=n.length;i{let i=++e;n.push({id:i,callback:t}),O_.postMessage({vscodeScheduleAsyncWork:i},"*")}}return n=>setTimeout(n)})(),Ur=IR||Sie?2:LR?1:3,GEe=!0,YEe=!1;kie=!!(Cm&&Cm.indexOf("Chrome")>=0),tTe=!!(Cm&&Cm.indexOf("Firefox")>=0),iTe=!!(!kie&&Cm&&Cm.indexOf("Safari")>=0),nTe=!!(Cm&&Cm.indexOf("Edg/")>=0),oTe=!!(Cm&&Cm.indexOf("Android")>=0)});var rs,ER=k(()=>{rs={tabSize:4,indentSize:4,insertSpaces:!0,detectIndentation:!0,trimAutoWhitespace:!0,largeFileOptimizations:!0,bracketPairColorizationOptions:{enabled:!0,independentColorPoolPerBracketType:!1}}});var Dt,Cl=k(()=>{(function(n){function e(w){return w&&typeof w=="object"&&typeof w[Symbol.iterator]=="function"}n.is=e;let t=Object.freeze([]);function i(){return t}n.empty=i;function*o(w){yield w}n.single=o;function r(w){return e(w)?w:o(w)}n.wrap=r;function s(w){return w||t}n.from=s;function*a(w){for(let y=w.length-1;y>=0;y--)yield w[y]}n.reverse=a;function l(w){return!w||w[Symbol.iterator]().next().done===!0}n.isEmpty=l;function c(w){return w[Symbol.iterator]().next().value}n.first=c;function d(w,y){let C=0;for(let L of w)if(y(L,C++))return!0;return!1}n.some=d;function u(w,y){for(let C of w)if(y(C))return C}n.find=u;function*h(w,y){for(let C of w)y(C)&&(yield C)}n.filter=h;function*f(w,y){let C=0;for(let L of w)yield y(L,C++)}n.map=f;function*p(w,y){let C=0;for(let L of w)yield*y(L,C++)}n.flatMap=p;function*g(...w){for(let y of w)yield*y}n.concat=g;function _(w,y,C){let L=C;for(let E of w)L=y(L,E);return L}n.reduce=_;function*b(w,y,C=w.length){for(y<0&&(y+=w.length),C<0?C+=w.length:C>w.length&&(C=w.length);y{Ar=class n{static{this.Undefined=new n(void 0)}constructor(e){this.element=e,this.next=n.Undefined,this.prev=n.Undefined}},go=class{constructor(){this._first=Ar.Undefined,this._last=Ar.Undefined,this._size=0}get size(){return this._size}isEmpty(){return this._first===Ar.Undefined}clear(){let e=this._first;for(;e!==Ar.Undefined;){let t=e.next;e.prev=Ar.Undefined,e.next=Ar.Undefined,e=t}this._first=Ar.Undefined,this._last=Ar.Undefined,this._size=0}unshift(e){return this._insert(e,!1)}push(e){return this._insert(e,!0)}_insert(e,t){let i=new Ar(e);if(this._first===Ar.Undefined)this._first=i,this._last=i;else if(t){let r=this._last;this._last=i,i.prev=r,r.next=i}else{let r=this._first;this._first=i,i.next=r,r.prev=i}this._size+=1;let o=!1;return()=>{o||(o=!0,this._remove(i))}}shift(){if(this._first!==Ar.Undefined){let e=this._first.element;return this._remove(this._first),e}}pop(){if(this._last!==Ar.Undefined){let e=this._last.element;return this._remove(this._last),e}}_remove(e){if(e.prev!==Ar.Undefined&&e.next!==Ar.Undefined){let t=e.prev;t.next=e.next,e.next.prev=t}else e.prev===Ar.Undefined&&e.next===Ar.Undefined?(this._first=Ar.Undefined,this._last=Ar.Undefined):e.next===Ar.Undefined?(this._last=this._last.prev,this._last.next=Ar.Undefined):e.prev===Ar.Undefined&&(this._first=this._first.next,this._first.prev=Ar.Undefined);this._size-=1}*[Symbol.iterator](){let e=this._first;for(;e!==Ar.Undefined;)yield e.element,e=e.next}}});function Pnt(n=""){let e="(-?\\d*\\.\\d\\w*)|([^";for(let t of Vk)n.indexOf(t)>=0||(e+="\\"+t);return e+="\\s]+)",new RegExp(e,"g")}function DR(n){let e=TR;if(n&&n instanceof RegExp)if(n.global)e=n;else{let t="g";n.ignoreCase&&(t+="i"),n.multiline&&(t+="m"),n.unicode&&(t+="u"),e=new RegExp(n.source,t)}return e.lastIndex=0,e}function tx(n,e,t,i,o){if(e=DR(e),o||(o=Dt.first(rTe)),t.length>o.maxLen){let c=n-o.maxLen/2;return c<0?c=0:i+=c,t=t.substring(c,n+o.maxLen/2),tx(n,e,t,i,o)}let r=Date.now(),s=n-1-i,a=-1,l=null;for(let c=1;!(Date.now()-r>=o.timeBudget);c++){let d=s-o.windowSize*c;e.lastIndex=Math.max(0,d);let u=Ont(e,t,s,a);if(!u&&l||(l=u,d<=0))break;a=d}if(l){let c={word:l[0],startColumn:i+1+l.index,endColumn:i+1+l.index+l[0].length};return e.lastIndex=0,c}return null}function Ont(n,e,t,i){let o;for(;o=n.exec(e);){let r=o.index||0;if(r<=t&&n.lastIndex>=t)return o;if(i>0&&r>i)return null}return null}var Vk,TR,rTe,h1=k(()=>{Cl();du();Vk="`~!@#$%^&*()-=+[{]}\\|;:'\",.<>/?";TR=Pnt();rTe=new go;rTe.unshift({maxLen:1e3,windowSize:15,timeBudget:150})});function W3(n,e){if(typeof n!="object"||typeof e!="object"||!n||!e)return new ix(e,n!==e);if(Array.isArray(n)||Array.isArray(e)){let i=Array.isArray(n)&&Array.isArray(e)&&oi(n,e);return new ix(e,!i)}let t=!1;for(let i in e)if(e.hasOwnProperty(i)){let o=W3(n[i],e[i]);o.didChange&&(n[i]=o.newValue,t=!0)}return new ix(n,t)}function $e(n,e){return typeof n>"u"?e:n==="false"?!1:!!n}function ox(n,e,t,i){if(typeof n>"u")return e;let o=parseInt(n,10);return isNaN(o)?e:(o=Math.max(t,o),o=Math.min(i,o),o|0)}function aTe(n,e,t,i){if(typeof n>"u")return e;let o=uu.float(n,e);return uu.clamp(o,t,i)}function ko(n,e,t,i){return typeof n!="string"?e:i&&n in i?i[n]:t.indexOf(n)===-1?e:n}function Fnt(n){switch(n){case"none":return 0;case"keep":return 1;case"brackets":return 2;case"advanced":return 3;case"full":return 4}}function Bnt(n){switch(n){case"blink":return 1;case"smooth":return 2;case"phase":return 3;case"expand":return 4;case"solid":return 5}}function Wnt(n){switch(n){case"line":return ss.Line;case"block":return ss.Block;case"underline":return ss.Underline;case"line-thin":return ss.LineThin;case"block-outline":return ss.BlockOutline;case"underline-thin":return ss.UnderlineThin}}function Hnt(n){return n==="ctrlCmd"?dt?"metaKey":"ctrlKey":"altKey"}function p1(n){let e=n.get(99);return e==="editable"?n.get(92):e!=="on"}function sTe(n,e){if(typeof n!="string")return e;switch(n){case"hidden":return 2;case"visible":return 3;default:return 1}}function $k(n,e,t){let i=t.indexOf(n);return i===-1?e:t[i]}function Ce(n){return rx[n.id]=n,n}var rp,jk,NR,Nn,ix,f1,nx,pi,Ln,uu,Sl,_o,Uk,Lie,Iie,ss,Eie,Tie,Die,ah,qk,Nie,Rie,Aie,Mie,Pie,RR,Oie,sh,Fie,Bie,Wie,Hie,zie,Vie,Uie,$ie,jie,qie,Kie,Gie,Yie,Zie,Xie,wd,tc,Qie,Jie,ene,tne,ine,nne,one,rne,sne,ane,lne,cne,znt,Vnt,Unt,as,rx,Oc,ir=k(()=>{at();ec();Bt();ER();h1();pe();rp=8,jk=class{constructor(e){this._values=e}hasChanged(e){return this._values[e]}},NR=class{constructor(){this.stableMinimapLayoutInput=null,this.stableFitMaxMinimapScale=0,this.stableFitRemainingWidth=0}},Nn=class{constructor(e,t,i,o){this.id=e,this.name=t,this.defaultValue=i,this.schema=o}applyUpdate(e,t){return W3(e,t)}compute(e,t,i){return i}},ix=class{constructor(e,t){this.newValue=e,this.didChange=t}};f1=class{constructor(e){this.schema=void 0,this.id=e,this.name="_never_",this.defaultValue=void 0}applyUpdate(e,t){return W3(e,t)}validate(e){return this.defaultValue}},nx=class{constructor(e,t,i,o){this.id=e,this.name=t,this.defaultValue=i,this.schema=o}applyUpdate(e,t){return W3(e,t)}validate(e){return typeof e>"u"?this.defaultValue:e}compute(e,t,i){return i}};pi=class extends nx{constructor(e,t,i,o=void 0){typeof o<"u"&&(o.type="boolean",o.default=i),super(e,t,i,o)}validate(e){return $e(e,this.defaultValue)}};Ln=class n extends nx{static clampedInt(e,t,i,o){return ox(e,t,i,o)}constructor(e,t,i,o,r,s=void 0){typeof s<"u"&&(s.type="integer",s.default=i,s.minimum=o,s.maximum=r),super(e,t,i,s),this.minimum=o,this.maximum=r}validate(e){return n.clampedInt(e,this.defaultValue,this.minimum,this.maximum)}};uu=class n extends nx{static clamp(e,t,i){return ei?i:e}static float(e,t){if(typeof e=="number")return e;if(typeof e>"u")return t;let i=parseFloat(e);return isNaN(i)?t:i}constructor(e,t,i,o,r){typeof r<"u"&&(r.type="number",r.default=i),super(e,t,i,r),this.validationFn=o}validate(e){return this.validationFn(n.float(e,this.defaultValue))}},Sl=class n extends nx{static string(e,t){return typeof e!="string"?t:e}constructor(e,t,i,o=void 0){typeof o<"u"&&(o.type="string",o.default=i),super(e,t,i,o)}validate(e){return n.string(e,this.defaultValue)}};_o=class extends nx{constructor(e,t,i,o,r=void 0){typeof r<"u"&&(r.type="string",r.enum=o,r.default=i),super(e,t,i,r),this._allowedValues=o}validate(e){return ko(e,this.defaultValue,this._allowedValues)}},Uk=class extends Nn{constructor(e,t,i,o,r,s,a=void 0){typeof a<"u"&&(a.type="string",a.enum=r,a.default=o),super(e,t,i,a),this._allowedValues=r,this._convert=s}validate(e){return typeof e!="string"?this.defaultValue:this._allowedValues.indexOf(e)===-1?this.defaultValue:this._convert(e)}};Lie=class extends Nn{constructor(){super(2,"accessibilitySupport",0,{type:"string",enum:["auto","on","off"],enumDescriptions:[m("accessibilitySupport.auto","Use platform APIs to detect when a Screen Reader is attached."),m("accessibilitySupport.on","Optimize for usage with a Screen Reader."),m("accessibilitySupport.off","Assume a screen reader is not attached.")],default:"auto",tags:["accessibility"],description:m("accessibilitySupport","Controls if the UI should run in a mode where it is optimized for screen readers.")})}validate(e){switch(e){case"auto":return 0;case"off":return 1;case"on":return 2}return this.defaultValue}compute(e,t,i){return i===0?e.accessibilitySupport:i}},Iie=class extends Nn{constructor(){let e={insertSpace:!0,ignoreEmptyLines:!0};super(23,"comments",e,{"editor.comments.insertSpace":{type:"boolean",default:e.insertSpace,description:m("comments.insertSpace","Controls whether a space character is inserted when commenting.")},"editor.comments.ignoreEmptyLines":{type:"boolean",default:e.ignoreEmptyLines,description:m("comments.ignoreEmptyLines","Controls if empty lines should be ignored with toggle, add or remove actions for line comments.")}})}validate(e){if(!e||typeof e!="object")return this.defaultValue;let t=e;return{insertSpace:$e(t.insertSpace,this.defaultValue.insertSpace),ignoreEmptyLines:$e(t.ignoreEmptyLines,this.defaultValue.ignoreEmptyLines)}}};(function(n){n[n.Line=1]="Line",n[n.Block=2]="Block",n[n.Underline=3]="Underline",n[n.LineThin=4]="LineThin",n[n.BlockOutline=5]="BlockOutline",n[n.UnderlineThin=6]="UnderlineThin"})(ss||(ss={}));Eie=class extends f1{constructor(){super(143)}compute(e,t,i){let o=["monaco-editor"];return t.get(39)&&o.push(t.get(39)),e.extraEditorClassName&&o.push(e.extraEditorClassName),t.get(74)==="default"?o.push("mouse-default"):t.get(74)==="copy"&&o.push("mouse-copy"),t.get(112)&&o.push("showUnused"),t.get(141)&&o.push("showDeprecated"),o.join(" ")}},Tie=class extends pi{constructor(){super(37,"emptySelectionClipboard",!0,{description:m("emptySelectionClipboard","Controls whether copying without a selection copies the current line.")})}compute(e,t,i){return i&&e.emptySelectionClipboard}},Die=class extends Nn{constructor(){let e={cursorMoveOnType:!0,seedSearchStringFromSelection:"always",autoFindInSelection:"never",globalFindClipboard:!1,addExtraSpaceOnTop:!0,loop:!0};super(41,"find",e,{"editor.find.cursorMoveOnType":{type:"boolean",default:e.cursorMoveOnType,description:m("find.cursorMoveOnType","Controls whether the cursor should jump to find matches while typing.")},"editor.find.seedSearchStringFromSelection":{type:"string",enum:["never","always","selection"],default:e.seedSearchStringFromSelection,enumDescriptions:[m("editor.find.seedSearchStringFromSelection.never","Never seed search string from the editor selection."),m("editor.find.seedSearchStringFromSelection.always","Always seed search string from the editor selection, including word at cursor position."),m("editor.find.seedSearchStringFromSelection.selection","Only seed search string from the editor selection.")],description:m("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:e.autoFindInSelection,enumDescriptions:[m("editor.find.autoFindInSelection.never","Never turn on Find in Selection automatically (default)."),m("editor.find.autoFindInSelection.always","Always turn on Find in Selection automatically."),m("editor.find.autoFindInSelection.multiline","Turn on Find in Selection automatically when multiple lines of content are selected.")],description:m("find.autoFindInSelection","Controls the condition for turning on Find in Selection automatically.")},"editor.find.globalFindClipboard":{type:"boolean",default:e.globalFindClipboard,description:m("find.globalFindClipboard","Controls whether the Find Widget should read or modify the shared find clipboard on macOS."),included:dt},"editor.find.addExtraSpaceOnTop":{type:"boolean",default:e.addExtraSpaceOnTop,description:m("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:e.loop,description:m("find.loop","Controls whether the search automatically restarts from the beginning (or the end) when no further matches can be found.")}})}validate(e){if(!e||typeof e!="object")return this.defaultValue;let t=e;return{cursorMoveOnType:$e(t.cursorMoveOnType,this.defaultValue.cursorMoveOnType),seedSearchStringFromSelection:typeof e.seedSearchStringFromSelection=="boolean"?e.seedSearchStringFromSelection?"always":"never":ko(t.seedSearchStringFromSelection,this.defaultValue.seedSearchStringFromSelection,["never","always","selection"]),autoFindInSelection:typeof e.autoFindInSelection=="boolean"?e.autoFindInSelection?"always":"never":ko(t.autoFindInSelection,this.defaultValue.autoFindInSelection,["never","always","multiline"]),globalFindClipboard:$e(t.globalFindClipboard,this.defaultValue.globalFindClipboard),addExtraSpaceOnTop:$e(t.addExtraSpaceOnTop,this.defaultValue.addExtraSpaceOnTop),loop:$e(t.loop,this.defaultValue.loop)}}},ah=class n extends Nn{static{this.OFF='"liga" off, "calt" off'}static{this.ON='"liga" on, "calt" on'}constructor(){super(51,"fontLigatures",n.OFF,{anyOf:[{type:"boolean",description:m("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:m("fontFeatureSettings","Explicit 'font-feature-settings' CSS property. A boolean can be passed instead if one only needs to turn on/off ligatures.")}],description:m("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(e){return typeof e>"u"?this.defaultValue:typeof e=="string"?e==="false"||e.length===0?n.OFF:e==="true"?n.ON:e:e?n.ON:n.OFF}},qk=class n extends Nn{static{this.OFF="normal"}static{this.TRANSLATE="translate"}constructor(){super(54,"fontVariations",n.OFF,{anyOf:[{type:"boolean",description:m("fontVariations","Enables/Disables the translation from font-weight to font-variation-settings. Change this to a string for fine-grained control of the 'font-variation-settings' CSS property.")},{type:"string",description:m("fontVariationSettings","Explicit 'font-variation-settings' CSS property. A boolean can be passed instead if one only needs to translate font-weight to font-variation-settings.")}],description:m("fontVariationsGeneral","Configures font variations. Can be either a boolean to enable/disable the translation from font-weight to font-variation-settings or a string for the value of the CSS 'font-variation-settings' property."),default:!1})}validate(e){return typeof e>"u"?this.defaultValue:typeof e=="string"?e==="false"?n.OFF:e==="true"?n.TRANSLATE:e:e?n.TRANSLATE:n.OFF}compute(e,t,i){return e.fontInfo.fontVariationSettings}},Nie=class extends f1{constructor(){super(50)}compute(e,t,i){return e.fontInfo}},Rie=class extends nx{constructor(){super(52,"fontSize",as.fontSize,{type:"number",minimum:6,maximum:100,default:as.fontSize,description:m("fontSize","Controls the font size in pixels.")})}validate(e){let t=uu.float(e,this.defaultValue);return t===0?as.fontSize:uu.clamp(t,6,100)}compute(e,t,i){return e.fontInfo.fontSize}},Aie=class n extends Nn{static{this.SUGGESTION_VALUES=["normal","bold","100","200","300","400","500","600","700","800","900"]}static{this.MINIMUM_VALUE=1}static{this.MAXIMUM_VALUE=1e3}constructor(){super(53,"fontWeight",as.fontWeight,{anyOf:[{type:"number",minimum:n.MINIMUM_VALUE,maximum:n.MAXIMUM_VALUE,errorMessage:m("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:n.SUGGESTION_VALUES}],default:as.fontWeight,description:m("fontWeight",'Controls the font weight. Accepts "normal" and "bold" keywords or numbers between 1 and 1000.')})}validate(e){return e==="normal"||e==="bold"?e:String(Ln.clampedInt(e,as.fontWeight,n.MINIMUM_VALUE,n.MAXIMUM_VALUE))}},Mie=class extends Nn{constructor(){let e={multiple:"peek",multipleDefinitions:"peek",multipleTypeDefinitions:"peek",multipleDeclarations:"peek",multipleImplementations:"peek",multipleReferences:"peek",multipleTests:"peek",alternativeDefinitionCommand:"editor.action.goToReferences",alternativeTypeDefinitionCommand:"editor.action.goToReferences",alternativeDeclarationCommand:"editor.action.goToReferences",alternativeImplementationCommand:"",alternativeReferenceCommand:"",alternativeTestsCommand:""},t={type:"string",enum:["peek","gotoAndPeek","goto"],default:e.multiple,enumDescriptions:[m("editor.gotoLocation.multiple.peek","Show Peek view of the results (default)"),m("editor.gotoLocation.multiple.gotoAndPeek","Go to the primary result and show a Peek view"),m("editor.gotoLocation.multiple.goto","Go to the primary result and enable Peek-less navigation to others")]},i=["","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(58,"gotoLocation",e,{"editor.gotoLocation.multiple":{deprecationMessage:m("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":{description:m("editor.editor.gotoLocation.multipleDefinitions","Controls the behavior the 'Go to Definition'-command when multiple target locations exist."),...t},"editor.gotoLocation.multipleTypeDefinitions":{description:m("editor.editor.gotoLocation.multipleTypeDefinitions","Controls the behavior the 'Go to Type Definition'-command when multiple target locations exist."),...t},"editor.gotoLocation.multipleDeclarations":{description:m("editor.editor.gotoLocation.multipleDeclarations","Controls the behavior the 'Go to Declaration'-command when multiple target locations exist."),...t},"editor.gotoLocation.multipleImplementations":{description:m("editor.editor.gotoLocation.multipleImplemenattions","Controls the behavior the 'Go to Implementations'-command when multiple target locations exist."),...t},"editor.gotoLocation.multipleReferences":{description:m("editor.editor.gotoLocation.multipleReferences","Controls the behavior the 'Go to References'-command when multiple target locations exist."),...t},"editor.gotoLocation.alternativeDefinitionCommand":{type:"string",default:e.alternativeDefinitionCommand,enum:i,description:m("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:e.alternativeTypeDefinitionCommand,enum:i,description:m("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:e.alternativeDeclarationCommand,enum:i,description:m("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:e.alternativeImplementationCommand,enum:i,description:m("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:e.alternativeReferenceCommand,enum:i,description:m("alternativeReferenceCommand","Alternative command id that is being executed when the result of 'Go to Reference' is the current location.")}})}validate(e){if(!e||typeof e!="object")return this.defaultValue;let t=e;return{multiple:ko(t.multiple,this.defaultValue.multiple,["peek","gotoAndPeek","goto"]),multipleDefinitions:t.multipleDefinitions??ko(t.multipleDefinitions,"peek",["peek","gotoAndPeek","goto"]),multipleTypeDefinitions:t.multipleTypeDefinitions??ko(t.multipleTypeDefinitions,"peek",["peek","gotoAndPeek","goto"]),multipleDeclarations:t.multipleDeclarations??ko(t.multipleDeclarations,"peek",["peek","gotoAndPeek","goto"]),multipleImplementations:t.multipleImplementations??ko(t.multipleImplementations,"peek",["peek","gotoAndPeek","goto"]),multipleReferences:t.multipleReferences??ko(t.multipleReferences,"peek",["peek","gotoAndPeek","goto"]),multipleTests:t.multipleTests??ko(t.multipleTests,"peek",["peek","gotoAndPeek","goto"]),alternativeDefinitionCommand:Sl.string(t.alternativeDefinitionCommand,this.defaultValue.alternativeDefinitionCommand),alternativeTypeDefinitionCommand:Sl.string(t.alternativeTypeDefinitionCommand,this.defaultValue.alternativeTypeDefinitionCommand),alternativeDeclarationCommand:Sl.string(t.alternativeDeclarationCommand,this.defaultValue.alternativeDeclarationCommand),alternativeImplementationCommand:Sl.string(t.alternativeImplementationCommand,this.defaultValue.alternativeImplementationCommand),alternativeReferenceCommand:Sl.string(t.alternativeReferenceCommand,this.defaultValue.alternativeReferenceCommand),alternativeTestsCommand:Sl.string(t.alternativeTestsCommand,this.defaultValue.alternativeTestsCommand)}}},Pie=class extends Nn{constructor(){let e={enabled:!0,delay:300,hidingDelay:300,sticky:!0,above:!0};super(60,"hover",e,{"editor.hover.enabled":{type:"boolean",default:e.enabled,description:m("hover.enabled","Controls whether the hover is shown.")},"editor.hover.delay":{type:"number",default:e.delay,minimum:0,maximum:1e4,description:m("hover.delay","Controls the delay in milliseconds after which the hover is shown.")},"editor.hover.sticky":{type:"boolean",default:e.sticky,description:m("hover.sticky","Controls whether the hover should remain visible when mouse is moved over it.")},"editor.hover.hidingDelay":{type:"integer",minimum:0,default:e.hidingDelay,description:m("hover.hidingDelay","Controls the delay in milliseconds after which the hover is hidden. Requires `editor.hover.sticky` to be enabled.")},"editor.hover.above":{type:"boolean",default:e.above,description:m("hover.above","Prefer showing hovers above the line, if there's space.")}})}validate(e){if(!e||typeof e!="object")return this.defaultValue;let t=e;return{enabled:$e(t.enabled,this.defaultValue.enabled),delay:Ln.clampedInt(t.delay,this.defaultValue.delay,0,1e4),sticky:$e(t.sticky,this.defaultValue.sticky),hidingDelay:Ln.clampedInt(t.hidingDelay,this.defaultValue.hidingDelay,0,6e5),above:$e(t.above,this.defaultValue.above)}}},RR=class n extends f1{constructor(){super(146)}compute(e,t,i){return n.computeLayout(t,{memory:e.memory,outerWidth:e.outerWidth,outerHeight:e.outerHeight,isDominatedByLongLines:e.isDominatedByLongLines,lineHeight:e.fontInfo.lineHeight,viewLineCount:e.viewLineCount,lineNumbersDigitCount:e.lineNumbersDigitCount,typicalHalfwidthCharacterWidth:e.fontInfo.typicalHalfwidthCharacterWidth,maxDigitWidth:e.fontInfo.maxDigitWidth,pixelRatio:e.pixelRatio,glyphMarginDecorationLaneCount:e.glyphMarginDecorationLaneCount})}static computeContainedMinimapLineCount(e){let t=e.height/e.lineHeight,i=Math.floor(e.paddingTop/e.lineHeight),o=Math.floor(e.paddingBottom/e.lineHeight);e.scrollBeyondLastLine&&(o=Math.max(o,t-1));let r=(i+e.viewLineCount+o)/(e.pixelRatio*e.height),s=Math.floor(e.viewLineCount/r);return{typicalViewportLineCount:t,extraLinesBeforeFirstLine:i,extraLinesBeyondLastLine:o,desiredRatio:r,minimapLineCount:s}}static _computeMinimapLayout(e,t){let i=e.outerWidth,o=e.outerHeight,r=e.pixelRatio;if(!e.minimap.enabled)return{renderMinimap:0,minimapLeft:0,minimapWidth:0,minimapHeightIsEditorHeight:!1,minimapIsSampling:!1,minimapScale:1,minimapLineHeight:1,minimapCanvasInnerWidth:0,minimapCanvasInnerHeight:Math.floor(r*o),minimapCanvasOuterWidth:0,minimapCanvasOuterHeight:o};let s=t.stableMinimapLayoutInput,a=s&&e.outerHeight===s.outerHeight&&e.lineHeight===s.lineHeight&&e.typicalHalfwidthCharacterWidth===s.typicalHalfwidthCharacterWidth&&e.pixelRatio===s.pixelRatio&&e.scrollBeyondLastLine===s.scrollBeyondLastLine&&e.paddingTop===s.paddingTop&&e.paddingBottom===s.paddingBottom&&e.minimap.enabled===s.minimap.enabled&&e.minimap.side===s.minimap.side&&e.minimap.size===s.minimap.size&&e.minimap.showSlider===s.minimap.showSlider&&e.minimap.renderCharacters===s.minimap.renderCharacters&&e.minimap.maxColumn===s.minimap.maxColumn&&e.minimap.scale===s.minimap.scale&&e.verticalScrollbarWidth===s.verticalScrollbarWidth&&e.isViewportWrapping===s.isViewportWrapping,l=e.lineHeight,c=e.typicalHalfwidthCharacterWidth,d=e.scrollBeyondLastLine,u=e.minimap.renderCharacters,h=r>=2?Math.round(e.minimap.scale*2):e.minimap.scale,f=e.minimap.maxColumn,p=e.minimap.size,g=e.minimap.side,_=e.verticalScrollbarWidth,b=e.viewLineCount,v=e.remainingWidth,x=e.isViewportWrapping,w=u?2:3,y=Math.floor(r*o),C=y/r,L=!1,E=!1,N=w*h,M=h/r,F=1;if(p==="fill"||p==="fit"){let{typicalViewportLineCount:ue,extraLinesBeforeFirstLine:ce,extraLinesBeyondLastLine:B,desiredRatio:Je,minimapLineCount:ni}=n.computeContainedMinimapLineCount({viewLineCount:b,scrollBeyondLastLine:d,paddingTop:e.paddingTop,paddingBottom:e.paddingBottom,height:o,lineHeight:l,pixelRatio:r});if(b/ni>1)L=!0,E=!0,h=1,N=1,M=h/r;else{let Ni=!1,ui=h+1;if(p==="fit"){let po=Math.ceil((ce+b+B)*N);x&&a&&v<=t.stableFitRemainingWidth?(Ni=!0,ui=t.stableFitMaxMinimapScale):Ni=po>y}if(p==="fill"||Ni){L=!0;let po=h;N=Math.min(l*r,Math.max(1,Math.floor(1/Je))),x&&a&&v<=t.stableFitRemainingWidth&&(ui=t.stableFitMaxMinimapScale),h=Math.min(ui,Math.max(1,Math.floor(N/w))),h>po&&(F=Math.min(2,h/po)),M=h/r/F,y=Math.ceil(Math.max(ue,ce+b+B)*N),x?(t.stableMinimapLayoutInput=e,t.stableFitRemainingWidth=v,t.stableFitMaxMinimapScale=h):(t.stableMinimapLayoutInput=null,t.stableFitRemainingWidth=0)}}}let q=Math.floor(f*M),te=Math.min(q,Math.max(0,Math.floor((v-_-2)*M/(c+M)))+rp),$=Math.floor(r*te),z=$/r;$=Math.floor($*F);let ae=u?1:2,X=g==="left"?0:i-te-_;return{renderMinimap:ae,minimapLeft:X,minimapWidth:te,minimapHeightIsEditorHeight:L,minimapIsSampling:E,minimapScale:h,minimapLineHeight:N,minimapCanvasInnerWidth:$,minimapCanvasInnerHeight:y,minimapCanvasOuterWidth:z,minimapCanvasOuterHeight:C}}static computeLayout(e,t){let i=t.outerWidth|0,o=t.outerHeight|0,r=t.lineHeight|0,s=t.lineNumbersDigitCount|0,a=t.typicalHalfwidthCharacterWidth,l=t.maxDigitWidth,c=t.pixelRatio,d=t.viewLineCount,u=e.get(138),h=u==="inherit"?e.get(137):u,f=h==="inherit"?e.get(133):h,p=e.get(136),g=t.isDominatedByLongLines,_=e.get(57),b=e.get(68).renderType!==0,v=e.get(69),x=e.get(106),w=e.get(84),y=e.get(73),C=e.get(104),L=C.verticalScrollbarSize,E=C.verticalHasArrows,N=C.arrowSize,M=C.horizontalScrollbarSize,F=e.get(43),q=e.get(111)!=="never",te=e.get(66);F&&q&&(te+=16);let $=0;if(b){let Ri=Math.max(s,v);$=Math.round(Ri*l)}let z=0;_&&(z=r*t.glyphMarginDecorationLaneCount);let ae=0,X=ae+z,ue=X+$,ce=ue+te,B=i-z-$-te,Je=!1,ni=!1,K=-1;h==="inherit"&&g?(Je=!0,ni=!0):f==="on"||f==="bounded"?ni=!0:f==="wordWrapColumn"&&(K=p);let Ni=n._computeMinimapLayout({outerWidth:i,outerHeight:o,lineHeight:r,typicalHalfwidthCharacterWidth:a,pixelRatio:c,scrollBeyondLastLine:x,paddingTop:w.top,paddingBottom:w.bottom,minimap:y,verticalScrollbarWidth:L,viewLineCount:d,remainingWidth:B,isViewportWrapping:ni},t.memory||new NR);Ni.renderMinimap!==0&&Ni.minimapLeft===0&&(ae+=Ni.minimapWidth,X+=Ni.minimapWidth,ue+=Ni.minimapWidth,ce+=Ni.minimapWidth);let ui=B-Ni.minimapWidth,po=Math.max(1,Math.floor((ui-L-2)/a)),Jr=E?N:0;return ni&&(K=Math.max(1,po),f==="bounded"&&(K=Math.min(K,p))),{width:i,height:o,glyphMarginLeft:ae,glyphMarginWidth:z,glyphMarginDecorationLaneCount:t.glyphMarginDecorationLaneCount,lineNumbersLeft:X,lineNumbersWidth:$,decorationsLeft:ue,decorationsWidth:te,contentLeft:ce,contentWidth:ui,minimap:Ni,viewportColumn:po,isWordWrapMinified:Je,isViewportWrapping:ni,wrappingColumn:K,verticalScrollbarWidth:L,horizontalScrollbarHeight:M,overviewRuler:{top:Jr,width:L,height:o-2*Jr,right:0}}}},Oie=class extends Nn{constructor(){super(140,"wrappingStrategy","simple",{"editor.wrappingStrategy":{enumDescriptions:[m("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."),m("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.")],type:"string",enum:["simple","advanced"],default:"simple",description:m("wrappingStrategy","Controls the algorithm that computes wrapping points. Note that when in accessibility mode, advanced will be used for the best experience.")}})}validate(e){return ko(e,"simple",["simple","advanced"])}compute(e,t,i){return t.get(2)===2?"advanced":i}};(function(n){n.Off="off",n.OnCode="onCode",n.On="on"})(sh||(sh={}));Fie=class extends Nn{constructor(){let e={enabled:sh.OnCode};super(65,"lightbulb",e,{"editor.lightbulb.enabled":{type:"string",tags:["experimental"],enum:[sh.Off,sh.OnCode,sh.On],default:e.enabled,enumDescriptions:[m("editor.lightbulb.enabled.off","Disable the code action menu."),m("editor.lightbulb.enabled.onCode","Show the code action menu when the cursor is on lines with code."),m("editor.lightbulb.enabled.on","Show the code action menu when the cursor is on lines with code or on empty lines.")],description:m("enabled","Enables the Code Action lightbulb in the editor.")}})}validate(e){return!e||typeof e!="object"?this.defaultValue:{enabled:ko(e.enabled,this.defaultValue.enabled,[sh.Off,sh.OnCode,sh.On])}}},Bie=class extends Nn{constructor(){let e={enabled:!0,maxLineCount:5,defaultModel:"outlineModel",scrollWithEditor:!0};super(116,"stickyScroll",e,{"editor.stickyScroll.enabled":{type:"boolean",default:e.enabled,description:m("editor.stickyScroll.enabled","Shows the nested current scopes during the scroll at the top of the editor."),tags:["experimental"]},"editor.stickyScroll.maxLineCount":{type:"number",default:e.maxLineCount,minimum:1,maximum:20,description:m("editor.stickyScroll.maxLineCount","Defines the maximum number of sticky lines to show.")},"editor.stickyScroll.defaultModel":{type:"string",enum:["outlineModel","foldingProviderModel","indentationModel"],default:e.defaultModel,description:m("editor.stickyScroll.defaultModel","Defines the model to use for determining which lines to stick. If the outline model does not exist, it will fall back on the folding provider model which falls back on the indentation model. This order is respected in all three cases.")},"editor.stickyScroll.scrollWithEditor":{type:"boolean",default:e.scrollWithEditor,description:m("editor.stickyScroll.scrollWithEditor","Enable scrolling of Sticky Scroll with the editor's horizontal scrollbar.")}})}validate(e){if(!e||typeof e!="object")return this.defaultValue;let t=e;return{enabled:$e(t.enabled,this.defaultValue.enabled),maxLineCount:Ln.clampedInt(t.maxLineCount,this.defaultValue.maxLineCount,1,20),defaultModel:ko(t.defaultModel,this.defaultValue.defaultModel,["outlineModel","foldingProviderModel","indentationModel"]),scrollWithEditor:$e(t.scrollWithEditor,this.defaultValue.scrollWithEditor)}}},Wie=class extends Nn{constructor(){let e={enabled:"on",fontSize:0,fontFamily:"",padding:!1};super(142,"inlayHints",e,{"editor.inlayHints.enabled":{type:"string",default:e.enabled,description:m("inlayHints.enable","Enables the inlay hints in the editor."),enum:["on","onUnlessPressed","offUnlessPressed","off"],markdownEnumDescriptions:[m("editor.inlayHints.on","Inlay hints are enabled"),m("editor.inlayHints.onUnlessPressed","Inlay hints are showing by default and hide when holding {0}",dt?"Ctrl+Option":"Ctrl+Alt"),m("editor.inlayHints.offUnlessPressed","Inlay hints are hidden by default and show when holding {0}",dt?"Ctrl+Option":"Ctrl+Alt"),m("editor.inlayHints.off","Inlay hints are disabled")]},"editor.inlayHints.fontSize":{type:"number",default:e.fontSize,markdownDescription:m("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:e.fontFamily,markdownDescription:m("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:e.padding,description:m("inlayHints.padding","Enables the padding around the inlay hints in the editor.")}})}validate(e){if(!e||typeof e!="object")return this.defaultValue;let t=e;return typeof t.enabled=="boolean"&&(t.enabled=t.enabled?"on":"off"),{enabled:ko(t.enabled,this.defaultValue.enabled,["on","off","offUnlessPressed","onUnlessPressed"]),fontSize:Ln.clampedInt(t.fontSize,this.defaultValue.fontSize,0,100),fontFamily:Sl.string(t.fontFamily,this.defaultValue.fontFamily),padding:$e(t.padding,this.defaultValue.padding)}}},Hie=class extends Nn{constructor(){super(66,"lineDecorationsWidth",10)}validate(e){return typeof e=="string"&&/^\d+(\.\d+)?ch$/.test(e)?-parseFloat(e.substring(0,e.length-2)):Ln.clampedInt(e,this.defaultValue,0,1e3)}compute(e,t,i){return i<0?Ln.clampedInt(-i*e.fontInfo.typicalHalfwidthCharacterWidth,this.defaultValue,0,1e3):i}},zie=class extends uu{constructor(){super(67,"lineHeight",as.lineHeight,e=>uu.clamp(e,0,150),{markdownDescription:m("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(e,t,i){return e.fontInfo.lineHeight}},Vie=class extends Nn{constructor(){let e={enabled:!0,size:"proportional",side:"right",showSlider:"mouseover",autohide:!1,renderCharacters:!0,maxColumn:120,scale:1,showRegionSectionHeaders:!0,showMarkSectionHeaders:!0,sectionHeaderFontSize:9,sectionHeaderLetterSpacing:1};super(73,"minimap",e,{"editor.minimap.enabled":{type:"boolean",default:e.enabled,description:m("minimap.enabled","Controls whether the minimap is shown.")},"editor.minimap.autohide":{type:"boolean",default:e.autohide,description:m("minimap.autohide","Controls whether the minimap is hidden automatically.")},"editor.minimap.size":{type:"string",enum:["proportional","fill","fit"],enumDescriptions:[m("minimap.size.proportional","The minimap has the same size as the editor contents (and might scroll)."),m("minimap.size.fill","The minimap will stretch or shrink as necessary to fill the height of the editor (no scrolling)."),m("minimap.size.fit","The minimap will shrink as necessary to never be larger than the editor (no scrolling).")],default:e.size,description:m("minimap.size","Controls the size of the minimap.")},"editor.minimap.side":{type:"string",enum:["left","right"],default:e.side,description:m("minimap.side","Controls the side where to render the minimap.")},"editor.minimap.showSlider":{type:"string",enum:["always","mouseover"],default:e.showSlider,description:m("minimap.showSlider","Controls when the minimap slider is shown.")},"editor.minimap.scale":{type:"number",default:e.scale,minimum:1,maximum:3,enum:[1,2,3],description:m("minimap.scale","Scale of content drawn in the minimap: 1, 2 or 3.")},"editor.minimap.renderCharacters":{type:"boolean",default:e.renderCharacters,description:m("minimap.renderCharacters","Render the actual characters on a line as opposed to color blocks.")},"editor.minimap.maxColumn":{type:"number",default:e.maxColumn,description:m("minimap.maxColumn","Limit the width of the minimap to render at most a certain number of columns.")},"editor.minimap.showRegionSectionHeaders":{type:"boolean",default:e.showRegionSectionHeaders,description:m("minimap.showRegionSectionHeaders","Controls whether named regions are shown as section headers in the minimap.")},"editor.minimap.showMarkSectionHeaders":{type:"boolean",default:e.showMarkSectionHeaders,description:m("minimap.showMarkSectionHeaders","Controls whether MARK: comments are shown as section headers in the minimap.")},"editor.minimap.sectionHeaderFontSize":{type:"number",default:e.sectionHeaderFontSize,description:m("minimap.sectionHeaderFontSize","Controls the font size of section headers in the minimap.")},"editor.minimap.sectionHeaderLetterSpacing":{type:"number",default:e.sectionHeaderLetterSpacing,description:m("minimap.sectionHeaderLetterSpacing","Controls the amount of space (in pixels) between characters of section header. This helps the readability of the header in small font sizes.")}})}validate(e){if(!e||typeof e!="object")return this.defaultValue;let t=e;return{enabled:$e(t.enabled,this.defaultValue.enabled),autohide:$e(t.autohide,this.defaultValue.autohide),size:ko(t.size,this.defaultValue.size,["proportional","fill","fit"]),side:ko(t.side,this.defaultValue.side,["right","left"]),showSlider:ko(t.showSlider,this.defaultValue.showSlider,["always","mouseover"]),renderCharacters:$e(t.renderCharacters,this.defaultValue.renderCharacters),scale:Ln.clampedInt(t.scale,1,1,3),maxColumn:Ln.clampedInt(t.maxColumn,this.defaultValue.maxColumn,1,1e4),showRegionSectionHeaders:$e(t.showRegionSectionHeaders,this.defaultValue.showRegionSectionHeaders),showMarkSectionHeaders:$e(t.showMarkSectionHeaders,this.defaultValue.showMarkSectionHeaders),sectionHeaderFontSize:uu.clamp(t.sectionHeaderFontSize??this.defaultValue.sectionHeaderFontSize,4,32),sectionHeaderLetterSpacing:uu.clamp(t.sectionHeaderLetterSpacing??this.defaultValue.sectionHeaderLetterSpacing,0,5)}}};Uie=class extends Nn{constructor(){super(84,"padding",{top:0,bottom:0},{"editor.padding.top":{type:"number",default:0,minimum:0,maximum:1e3,description:m("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:m("padding.bottom","Controls the amount of space between the bottom edge of the editor and the last line.")}})}validate(e){if(!e||typeof e!="object")return this.defaultValue;let t=e;return{top:Ln.clampedInt(t.top,0,0,1e3),bottom:Ln.clampedInt(t.bottom,0,0,1e3)}}},$ie=class extends Nn{constructor(){let e={enabled:!0,cycle:!0};super(86,"parameterHints",e,{"editor.parameterHints.enabled":{type:"boolean",default:e.enabled,description:m("parameterHints.enabled","Enables a pop-up that shows parameter documentation and type information as you type.")},"editor.parameterHints.cycle":{type:"boolean",default:e.cycle,description:m("parameterHints.cycle","Controls whether the parameter hints menu cycles or closes when reaching the end of the list.")}})}validate(e){if(!e||typeof e!="object")return this.defaultValue;let t=e;return{enabled:$e(t.enabled,this.defaultValue.enabled),cycle:$e(t.cycle,this.defaultValue.cycle)}}},jie=class extends f1{constructor(){super(144)}compute(e,t,i){return e.pixelRatio}},qie=class extends Nn{constructor(){super(88,"placeholder",void 0)}validate(e){return typeof e>"u"?this.defaultValue:typeof e=="string"?e:this.defaultValue}},Kie=class extends Nn{constructor(){let e={other:"on",comments:"off",strings:"off"},t=[{type:"boolean"},{type:"string",enum:["on","inline","off"],enumDescriptions:[m("on","Quick suggestions show inside the suggest widget"),m("inline","Quick suggestions show as ghost text"),m("off","Quick suggestions are disabled")]}];super(90,"quickSuggestions",e,{type:"object",additionalProperties:!1,properties:{strings:{anyOf:t,default:e.strings,description:m("quickSuggestions.strings","Enable quick suggestions inside strings.")},comments:{anyOf:t,default:e.comments,description:m("quickSuggestions.comments","Enable quick suggestions inside comments.")},other:{anyOf:t,default:e.other,description:m("quickSuggestions.other","Enable quick suggestions outside of strings and comments.")}},default:e,markdownDescription:m("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=e}validate(e){if(typeof e=="boolean"){let c=e?"on":"off";return{comments:c,strings:c,other:c}}if(!e||typeof e!="object")return this.defaultValue;let{other:t,comments:i,strings:o}=e,r=["on","inline","off"],s,a,l;return typeof t=="boolean"?s=t?"on":"off":s=ko(t,this.defaultValue.other,r),typeof i=="boolean"?a=i?"on":"off":a=ko(i,this.defaultValue.comments,r),typeof o=="boolean"?l=o?"on":"off":l=ko(o,this.defaultValue.strings,r),{other:s,comments:a,strings:l}}},Gie=class extends Nn{constructor(){super(68,"lineNumbers",{renderType:1,renderFn:null},{type:"string",enum:["off","on","relative","interval"],enumDescriptions:[m("lineNumbers.off","Line numbers are not rendered."),m("lineNumbers.on","Line numbers are rendered as absolute number."),m("lineNumbers.relative","Line numbers are rendered as distance in lines to cursor position."),m("lineNumbers.interval","Line numbers are rendered every 10 lines.")],default:"on",description:m("lineNumbers","Controls the display of line numbers.")})}validate(e){let t=this.defaultValue.renderType,i=this.defaultValue.renderFn;return typeof e<"u"&&(typeof e=="function"?(t=4,i=e):e==="interval"?t=3:e==="relative"?t=2:e==="on"?t=1:t=0),{renderType:t,renderFn:i}}};Yie=class extends Nn{constructor(){let e=[],t={type:"number",description:m("rulers.size","Number of monospace characters at which this editor ruler will render.")};super(103,"rulers",e,{type:"array",items:{anyOf:[t,{type:["object"],properties:{column:t,color:{type:"string",description:m("rulers.color","Color of this editor ruler."),format:"color-hex"}}}]},default:e,description:m("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(e){if(Array.isArray(e)){let t=[];for(let i of e)if(typeof i=="number")t.push({column:Ln.clampedInt(i,0,0,1e4),color:null});else if(i&&typeof i=="object"){let o=i;t.push({column:Ln.clampedInt(o.column,0,0,1e4),color:o.color})}return t.sort((i,o)=>i.column-o.column),t}return this.defaultValue}},Zie=class extends Nn{constructor(){super(93,"readOnlyMessage",void 0)}validate(e){return!e||typeof e!="object"?this.defaultValue:e}};Xie=class extends Nn{constructor(){let e={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,ignoreHorizontalScrollbarInContentHeight:!1};super(104,"scrollbar",e,{"editor.scrollbar.vertical":{type:"string",enum:["auto","visible","hidden"],enumDescriptions:[m("scrollbar.vertical.auto","The vertical scrollbar will be visible only when necessary."),m("scrollbar.vertical.visible","The vertical scrollbar will always be visible."),m("scrollbar.vertical.fit","The vertical scrollbar will always be hidden.")],default:"auto",description:m("scrollbar.vertical","Controls the visibility of the vertical scrollbar.")},"editor.scrollbar.horizontal":{type:"string",enum:["auto","visible","hidden"],enumDescriptions:[m("scrollbar.horizontal.auto","The horizontal scrollbar will be visible only when necessary."),m("scrollbar.horizontal.visible","The horizontal scrollbar will always be visible."),m("scrollbar.horizontal.fit","The horizontal scrollbar will always be hidden.")],default:"auto",description:m("scrollbar.horizontal","Controls the visibility of the horizontal scrollbar.")},"editor.scrollbar.verticalScrollbarSize":{type:"number",default:e.verticalScrollbarSize,description:m("scrollbar.verticalScrollbarSize","The width of the vertical scrollbar.")},"editor.scrollbar.horizontalScrollbarSize":{type:"number",default:e.horizontalScrollbarSize,description:m("scrollbar.horizontalScrollbarSize","The height of the horizontal scrollbar.")},"editor.scrollbar.scrollByPage":{type:"boolean",default:e.scrollByPage,description:m("scrollbar.scrollByPage","Controls whether clicks scroll by page or jump to click position.")},"editor.scrollbar.ignoreHorizontalScrollbarInContentHeight":{type:"boolean",default:e.ignoreHorizontalScrollbarInContentHeight,description:m("scrollbar.ignoreHorizontalScrollbarInContentHeight","When set, the horizontal scrollbar will not increase the size of the editor's content.")}})}validate(e){if(!e||typeof e!="object")return this.defaultValue;let t=e,i=Ln.clampedInt(t.horizontalScrollbarSize,this.defaultValue.horizontalScrollbarSize,0,1e3),o=Ln.clampedInt(t.verticalScrollbarSize,this.defaultValue.verticalScrollbarSize,0,1e3);return{arrowSize:Ln.clampedInt(t.arrowSize,this.defaultValue.arrowSize,0,1e3),vertical:sTe(t.vertical,this.defaultValue.vertical),horizontal:sTe(t.horizontal,this.defaultValue.horizontal),useShadows:$e(t.useShadows,this.defaultValue.useShadows),verticalHasArrows:$e(t.verticalHasArrows,this.defaultValue.verticalHasArrows),horizontalHasArrows:$e(t.horizontalHasArrows,this.defaultValue.horizontalHasArrows),handleMouseWheel:$e(t.handleMouseWheel,this.defaultValue.handleMouseWheel),alwaysConsumeMouseWheel:$e(t.alwaysConsumeMouseWheel,this.defaultValue.alwaysConsumeMouseWheel),horizontalScrollbarSize:i,horizontalSliderSize:Ln.clampedInt(t.horizontalSliderSize,i,0,1e3),verticalScrollbarSize:o,verticalSliderSize:Ln.clampedInt(t.verticalSliderSize,o,0,1e3),scrollByPage:$e(t.scrollByPage,this.defaultValue.scrollByPage),ignoreHorizontalScrollbarInContentHeight:$e(t.ignoreHorizontalScrollbarInContentHeight,this.defaultValue.ignoreHorizontalScrollbarInContentHeight)}}},wd="inUntrustedWorkspace",tc={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"},Qie=class extends Nn{constructor(){let e={nonBasicASCII:wd,invisibleCharacters:!0,ambiguousCharacters:!0,includeComments:wd,includeStrings:!0,allowedCharacters:{},allowedLocales:{_os:!0,_vscode:!0}};super(126,"unicodeHighlight",e,{[tc.nonBasicASCII]:{restricted:!0,type:["boolean","string"],enum:[!0,!1,wd],default:e.nonBasicASCII,description:m("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.")},[tc.invisibleCharacters]:{restricted:!0,type:"boolean",default:e.invisibleCharacters,description:m("unicodeHighlight.invisibleCharacters","Controls whether characters that just reserve space or have no width at all are highlighted.")},[tc.ambiguousCharacters]:{restricted:!0,type:"boolean",default:e.ambiguousCharacters,description:m("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.")},[tc.includeComments]:{restricted:!0,type:["boolean","string"],enum:[!0,!1,wd],default:e.includeComments,description:m("unicodeHighlight.includeComments","Controls whether characters in comments should also be subject to Unicode highlighting.")},[tc.includeStrings]:{restricted:!0,type:["boolean","string"],enum:[!0,!1,wd],default:e.includeStrings,description:m("unicodeHighlight.includeStrings","Controls whether characters in strings should also be subject to Unicode highlighting.")},[tc.allowedCharacters]:{restricted:!0,type:"object",default:e.allowedCharacters,description:m("unicodeHighlight.allowedCharacters","Defines allowed characters that are not being highlighted."),additionalProperties:{type:"boolean"}},[tc.allowedLocales]:{restricted:!0,type:"object",additionalProperties:{type:"boolean"},default:e.allowedLocales,description:m("unicodeHighlight.allowedLocales","Unicode characters that are common in allowed locales are not being highlighted.")}})}applyUpdate(e,t){let i=!1;t.allowedCharacters&&e&&(os(e.allowedCharacters,t.allowedCharacters)||(e={...e,allowedCharacters:t.allowedCharacters},i=!0)),t.allowedLocales&&e&&(os(e.allowedLocales,t.allowedLocales)||(e={...e,allowedLocales:t.allowedLocales},i=!0));let o=super.applyUpdate(e,t);return i?new ix(o.newValue,!0):o}validate(e){if(!e||typeof e!="object")return this.defaultValue;let t=e;return{nonBasicASCII:$k(t.nonBasicASCII,wd,[!0,!1,wd]),invisibleCharacters:$e(t.invisibleCharacters,this.defaultValue.invisibleCharacters),ambiguousCharacters:$e(t.ambiguousCharacters,this.defaultValue.ambiguousCharacters),includeComments:$k(t.includeComments,wd,[!0,!1,wd]),includeStrings:$k(t.includeStrings,wd,[!0,!1,wd]),allowedCharacters:this.validateBooleanMap(e.allowedCharacters,this.defaultValue.allowedCharacters),allowedLocales:this.validateBooleanMap(e.allowedLocales,this.defaultValue.allowedLocales)}}validateBooleanMap(e,t){if(typeof e!="object"||!e)return t;let i={};for(let[o,r]of Object.entries(e))r===!0&&(i[o]=!0);return i}},Jie=class extends Nn{constructor(){let e={enabled:!0,mode:"subwordSmart",showToolbar:"onHover",suppressSuggestions:!1,keepOnBlur:!1,fontFamily:"default"};super(62,"inlineSuggest",e,{"editor.inlineSuggest.enabled":{type:"boolean",default:e.enabled,description:m("inlineSuggest.enabled","Controls whether to automatically show inline suggestions in the editor.")},"editor.inlineSuggest.showToolbar":{type:"string",default:e.showToolbar,enum:["always","onHover","never"],enumDescriptions:[m("inlineSuggest.showToolbar.always","Show the inline suggestion toolbar whenever an inline suggestion is shown."),m("inlineSuggest.showToolbar.onHover","Show the inline suggestion toolbar when hovering over an inline suggestion."),m("inlineSuggest.showToolbar.never","Never show the inline suggestion toolbar.")],description:m("inlineSuggest.showToolbar","Controls when to show the inline suggestion toolbar.")},"editor.inlineSuggest.suppressSuggestions":{type:"boolean",default:e.suppressSuggestions,description:m("inlineSuggest.suppressSuggestions","Controls how inline suggestions interact with the suggest widget. If enabled, the suggest widget is not shown automatically when inline suggestions are available.")},"editor.inlineSuggest.fontFamily":{type:"string",default:e.fontFamily,description:m("inlineSuggest.fontFamily","Controls the font family of the inline suggestions.")}})}validate(e){if(!e||typeof e!="object")return this.defaultValue;let t=e;return{enabled:$e(t.enabled,this.defaultValue.enabled),mode:ko(t.mode,this.defaultValue.mode,["prefix","subword","subwordSmart"]),showToolbar:ko(t.showToolbar,this.defaultValue.showToolbar,["always","onHover","never"]),suppressSuggestions:$e(t.suppressSuggestions,this.defaultValue.suppressSuggestions),keepOnBlur:$e(t.keepOnBlur,this.defaultValue.keepOnBlur),fontFamily:Sl.string(t.fontFamily,this.defaultValue.fontFamily)}}},ene=class extends Nn{constructor(){let e={enabled:!1,showToolbar:"onHover",fontFamily:"default",keepOnBlur:!1};super(63,"experimentalInlineEdit",e,{"editor.experimentalInlineEdit.enabled":{type:"boolean",default:e.enabled,description:m("inlineEdit.enabled","Controls whether to show inline edits in the editor.")},"editor.experimentalInlineEdit.showToolbar":{type:"string",default:e.showToolbar,enum:["always","onHover","never"],enumDescriptions:[m("inlineEdit.showToolbar.always","Show the inline edit toolbar whenever an inline suggestion is shown."),m("inlineEdit.showToolbar.onHover","Show the inline edit toolbar when hovering over an inline suggestion."),m("inlineEdit.showToolbar.never","Never show the inline edit toolbar.")],description:m("inlineEdit.showToolbar","Controls when to show the inline edit toolbar.")},"editor.experimentalInlineEdit.fontFamily":{type:"string",default:e.fontFamily,description:m("inlineEdit.fontFamily","Controls the font family of the inline edit.")}})}validate(e){if(!e||typeof e!="object")return this.defaultValue;let t=e;return{enabled:$e(t.enabled,this.defaultValue.enabled),showToolbar:ko(t.showToolbar,this.defaultValue.showToolbar,["always","onHover","never"]),fontFamily:Sl.string(t.fontFamily,this.defaultValue.fontFamily),keepOnBlur:$e(t.keepOnBlur,this.defaultValue.keepOnBlur)}}},tne=class extends Nn{constructor(){let e={enabled:rs.bracketPairColorizationOptions.enabled,independentColorPoolPerBracketType:rs.bracketPairColorizationOptions.independentColorPoolPerBracketType};super(15,"bracketPairColorization",e,{"editor.bracketPairColorization.enabled":{type:"boolean",default:e.enabled,markdownDescription:m("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:e.independentColorPoolPerBracketType,description:m("bracketPairColorization.independentColorPoolPerBracketType","Controls whether each bracket type has its own independent color pool.")}})}validate(e){if(!e||typeof e!="object")return this.defaultValue;let t=e;return{enabled:$e(t.enabled,this.defaultValue.enabled),independentColorPoolPerBracketType:$e(t.independentColorPoolPerBracketType,this.defaultValue.independentColorPoolPerBracketType)}}},ine=class extends Nn{constructor(){let e={bracketPairs:!1,bracketPairsHorizontal:"active",highlightActiveBracketPair:!0,indentation:!0,highlightActiveIndentation:!0};super(16,"guides",e,{"editor.guides.bracketPairs":{type:["boolean","string"],enum:[!0,"active",!1],enumDescriptions:[m("editor.guides.bracketPairs.true","Enables bracket pair guides."),m("editor.guides.bracketPairs.active","Enables bracket pair guides only for the active bracket pair."),m("editor.guides.bracketPairs.false","Disables bracket pair guides.")],default:e.bracketPairs,description:m("editor.guides.bracketPairs","Controls whether bracket pair guides are enabled or not.")},"editor.guides.bracketPairsHorizontal":{type:["boolean","string"],enum:[!0,"active",!1],enumDescriptions:[m("editor.guides.bracketPairsHorizontal.true","Enables horizontal guides as addition to vertical bracket pair guides."),m("editor.guides.bracketPairsHorizontal.active","Enables horizontal guides only for the active bracket pair."),m("editor.guides.bracketPairsHorizontal.false","Disables horizontal bracket pair guides.")],default:e.bracketPairsHorizontal,description:m("editor.guides.bracketPairsHorizontal","Controls whether horizontal bracket pair guides are enabled or not.")},"editor.guides.highlightActiveBracketPair":{type:"boolean",default:e.highlightActiveBracketPair,description:m("editor.guides.highlightActiveBracketPair","Controls whether the editor should highlight the active bracket pair.")},"editor.guides.indentation":{type:"boolean",default:e.indentation,description:m("editor.guides.indentation","Controls whether the editor should render indent guides.")},"editor.guides.highlightActiveIndentation":{type:["boolean","string"],enum:[!0,"always",!1],enumDescriptions:[m("editor.guides.highlightActiveIndentation.true","Highlights the active indent guide."),m("editor.guides.highlightActiveIndentation.always","Highlights the active indent guide even if bracket guides are highlighted."),m("editor.guides.highlightActiveIndentation.false","Do not highlight the active indent guide.")],default:e.highlightActiveIndentation,description:m("editor.guides.highlightActiveIndentation","Controls whether the editor should highlight the active indent guide.")}})}validate(e){if(!e||typeof e!="object")return this.defaultValue;let t=e;return{bracketPairs:$k(t.bracketPairs,this.defaultValue.bracketPairs,[!0,!1,"active"]),bracketPairsHorizontal:$k(t.bracketPairsHorizontal,this.defaultValue.bracketPairsHorizontal,[!0,!1,"active"]),highlightActiveBracketPair:$e(t.highlightActiveBracketPair,this.defaultValue.highlightActiveBracketPair),indentation:$e(t.indentation,this.defaultValue.indentation),highlightActiveIndentation:$k(t.highlightActiveIndentation,this.defaultValue.highlightActiveIndentation,[!0,!1,"always"])}}};nne=class extends Nn{constructor(){let e={insertMode:"insert",filterGraceful:!0,snippetsPreventQuickSuggestions:!1,localityBonus:!1,shareSuggestSelections:!1,selectionMode:"always",showIcons:!0,showStatusBar:!1,preview:!1,previewMode:"subwordSmart",showInlineDetails:!0,showMethods:!0,showFunctions:!0,showConstructors:!0,showDeprecated:!0,matchOnWordStartOnly:!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(119,"suggest",e,{"editor.suggest.insertMode":{type:"string",enum:["insert","replace"],enumDescriptions:[m("suggest.insertMode.insert","Insert suggestion without overwriting text right of the cursor."),m("suggest.insertMode.replace","Insert suggestion and overwrite text right of the cursor.")],default:e.insertMode,description:m("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:e.filterGraceful,description:m("suggest.filterGraceful","Controls whether filtering and sorting suggestions accounts for small typos.")},"editor.suggest.localityBonus":{type:"boolean",default:e.localityBonus,description:m("suggest.localityBonus","Controls whether sorting favors words that appear close to the cursor.")},"editor.suggest.shareSuggestSelections":{type:"boolean",default:e.shareSuggestSelections,markdownDescription:m("suggest.shareSuggestSelections","Controls whether remembered suggestion selections are shared between multiple workspaces and windows (needs `#editor.suggestSelection#`).")},"editor.suggest.selectionMode":{type:"string",enum:["always","never","whenTriggerCharacter","whenQuickSuggestion"],enumDescriptions:[m("suggest.insertMode.always","Always select a suggestion when automatically triggering IntelliSense."),m("suggest.insertMode.never","Never select a suggestion when automatically triggering IntelliSense."),m("suggest.insertMode.whenTriggerCharacter","Select a suggestion only when triggering IntelliSense from a trigger character."),m("suggest.insertMode.whenQuickSuggestion","Select a suggestion only when triggering IntelliSense as you type.")],default:e.selectionMode,markdownDescription:m("suggest.selectionMode","Controls whether a suggestion is selected when the widget shows. Note that this only applies to automatically triggered suggestions ({0} and {1}) and that a suggestion is always selected when explicitly invoked, e.g via `Ctrl+Space`.","`#editor.quickSuggestions#`","`#editor.suggestOnTriggerCharacters#`")},"editor.suggest.snippetsPreventQuickSuggestions":{type:"boolean",default:e.snippetsPreventQuickSuggestions,description:m("suggest.snippetsPreventQuickSuggestions","Controls whether an active snippet prevents quick suggestions.")},"editor.suggest.showIcons":{type:"boolean",default:e.showIcons,description:m("suggest.showIcons","Controls whether to show or hide icons in suggestions.")},"editor.suggest.showStatusBar":{type:"boolean",default:e.showStatusBar,description:m("suggest.showStatusBar","Controls the visibility of the status bar at the bottom of the suggest widget.")},"editor.suggest.preview":{type:"boolean",default:e.preview,description:m("suggest.preview","Controls whether to preview the suggestion outcome in the editor.")},"editor.suggest.showInlineDetails":{type:"boolean",default:e.showInlineDetails,description:m("suggest.showInlineDetails","Controls whether suggest details show inline with the label or only in the details widget.")},"editor.suggest.maxVisibleSuggestions":{type:"number",deprecationMessage:m("suggest.maxVisibleSuggestions.dep","This setting is deprecated. The suggest widget can now be resized.")},"editor.suggest.filteredTypes":{type:"object",deprecationMessage:m("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:m("editor.suggest.showMethods","When enabled IntelliSense shows `method`-suggestions.")},"editor.suggest.showFunctions":{type:"boolean",default:!0,markdownDescription:m("editor.suggest.showFunctions","When enabled IntelliSense shows `function`-suggestions.")},"editor.suggest.showConstructors":{type:"boolean",default:!0,markdownDescription:m("editor.suggest.showConstructors","When enabled IntelliSense shows `constructor`-suggestions.")},"editor.suggest.showDeprecated":{type:"boolean",default:!0,markdownDescription:m("editor.suggest.showDeprecated","When enabled IntelliSense shows `deprecated`-suggestions.")},"editor.suggest.matchOnWordStartOnly":{type:"boolean",default:!0,markdownDescription:m("editor.suggest.matchOnWordStartOnly","When enabled IntelliSense filtering requires that the first character matches on a word start. For example, `c` on `Console` or `WebContext` but _not_ on `description`. When disabled IntelliSense will show more results but still sorts them by match quality.")},"editor.suggest.showFields":{type:"boolean",default:!0,markdownDescription:m("editor.suggest.showFields","When enabled IntelliSense shows `field`-suggestions.")},"editor.suggest.showVariables":{type:"boolean",default:!0,markdownDescription:m("editor.suggest.showVariables","When enabled IntelliSense shows `variable`-suggestions.")},"editor.suggest.showClasses":{type:"boolean",default:!0,markdownDescription:m("editor.suggest.showClasss","When enabled IntelliSense shows `class`-suggestions.")},"editor.suggest.showStructs":{type:"boolean",default:!0,markdownDescription:m("editor.suggest.showStructs","When enabled IntelliSense shows `struct`-suggestions.")},"editor.suggest.showInterfaces":{type:"boolean",default:!0,markdownDescription:m("editor.suggest.showInterfaces","When enabled IntelliSense shows `interface`-suggestions.")},"editor.suggest.showModules":{type:"boolean",default:!0,markdownDescription:m("editor.suggest.showModules","When enabled IntelliSense shows `module`-suggestions.")},"editor.suggest.showProperties":{type:"boolean",default:!0,markdownDescription:m("editor.suggest.showPropertys","When enabled IntelliSense shows `property`-suggestions.")},"editor.suggest.showEvents":{type:"boolean",default:!0,markdownDescription:m("editor.suggest.showEvents","When enabled IntelliSense shows `event`-suggestions.")},"editor.suggest.showOperators":{type:"boolean",default:!0,markdownDescription:m("editor.suggest.showOperators","When enabled IntelliSense shows `operator`-suggestions.")},"editor.suggest.showUnits":{type:"boolean",default:!0,markdownDescription:m("editor.suggest.showUnits","When enabled IntelliSense shows `unit`-suggestions.")},"editor.suggest.showValues":{type:"boolean",default:!0,markdownDescription:m("editor.suggest.showValues","When enabled IntelliSense shows `value`-suggestions.")},"editor.suggest.showConstants":{type:"boolean",default:!0,markdownDescription:m("editor.suggest.showConstants","When enabled IntelliSense shows `constant`-suggestions.")},"editor.suggest.showEnums":{type:"boolean",default:!0,markdownDescription:m("editor.suggest.showEnums","When enabled IntelliSense shows `enum`-suggestions.")},"editor.suggest.showEnumMembers":{type:"boolean",default:!0,markdownDescription:m("editor.suggest.showEnumMembers","When enabled IntelliSense shows `enumMember`-suggestions.")},"editor.suggest.showKeywords":{type:"boolean",default:!0,markdownDescription:m("editor.suggest.showKeywords","When enabled IntelliSense shows `keyword`-suggestions.")},"editor.suggest.showWords":{type:"boolean",default:!0,markdownDescription:m("editor.suggest.showTexts","When enabled IntelliSense shows `text`-suggestions.")},"editor.suggest.showColors":{type:"boolean",default:!0,markdownDescription:m("editor.suggest.showColors","When enabled IntelliSense shows `color`-suggestions.")},"editor.suggest.showFiles":{type:"boolean",default:!0,markdownDescription:m("editor.suggest.showFiles","When enabled IntelliSense shows `file`-suggestions.")},"editor.suggest.showReferences":{type:"boolean",default:!0,markdownDescription:m("editor.suggest.showReferences","When enabled IntelliSense shows `reference`-suggestions.")},"editor.suggest.showCustomcolors":{type:"boolean",default:!0,markdownDescription:m("editor.suggest.showCustomcolors","When enabled IntelliSense shows `customcolor`-suggestions.")},"editor.suggest.showFolders":{type:"boolean",default:!0,markdownDescription:m("editor.suggest.showFolders","When enabled IntelliSense shows `folder`-suggestions.")},"editor.suggest.showTypeParameters":{type:"boolean",default:!0,markdownDescription:m("editor.suggest.showTypeParameters","When enabled IntelliSense shows `typeParameter`-suggestions.")},"editor.suggest.showSnippets":{type:"boolean",default:!0,markdownDescription:m("editor.suggest.showSnippets","When enabled IntelliSense shows `snippet`-suggestions.")},"editor.suggest.showUsers":{type:"boolean",default:!0,markdownDescription:m("editor.suggest.showUsers","When enabled IntelliSense shows `user`-suggestions.")},"editor.suggest.showIssues":{type:"boolean",default:!0,markdownDescription:m("editor.suggest.showIssues","When enabled IntelliSense shows `issues`-suggestions.")}})}validate(e){if(!e||typeof e!="object")return this.defaultValue;let t=e;return{insertMode:ko(t.insertMode,this.defaultValue.insertMode,["insert","replace"]),filterGraceful:$e(t.filterGraceful,this.defaultValue.filterGraceful),snippetsPreventQuickSuggestions:$e(t.snippetsPreventQuickSuggestions,this.defaultValue.filterGraceful),localityBonus:$e(t.localityBonus,this.defaultValue.localityBonus),shareSuggestSelections:$e(t.shareSuggestSelections,this.defaultValue.shareSuggestSelections),selectionMode:ko(t.selectionMode,this.defaultValue.selectionMode,["always","never","whenQuickSuggestion","whenTriggerCharacter"]),showIcons:$e(t.showIcons,this.defaultValue.showIcons),showStatusBar:$e(t.showStatusBar,this.defaultValue.showStatusBar),preview:$e(t.preview,this.defaultValue.preview),previewMode:ko(t.previewMode,this.defaultValue.previewMode,["prefix","subword","subwordSmart"]),showInlineDetails:$e(t.showInlineDetails,this.defaultValue.showInlineDetails),showMethods:$e(t.showMethods,this.defaultValue.showMethods),showFunctions:$e(t.showFunctions,this.defaultValue.showFunctions),showConstructors:$e(t.showConstructors,this.defaultValue.showConstructors),showDeprecated:$e(t.showDeprecated,this.defaultValue.showDeprecated),matchOnWordStartOnly:$e(t.matchOnWordStartOnly,this.defaultValue.matchOnWordStartOnly),showFields:$e(t.showFields,this.defaultValue.showFields),showVariables:$e(t.showVariables,this.defaultValue.showVariables),showClasses:$e(t.showClasses,this.defaultValue.showClasses),showStructs:$e(t.showStructs,this.defaultValue.showStructs),showInterfaces:$e(t.showInterfaces,this.defaultValue.showInterfaces),showModules:$e(t.showModules,this.defaultValue.showModules),showProperties:$e(t.showProperties,this.defaultValue.showProperties),showEvents:$e(t.showEvents,this.defaultValue.showEvents),showOperators:$e(t.showOperators,this.defaultValue.showOperators),showUnits:$e(t.showUnits,this.defaultValue.showUnits),showValues:$e(t.showValues,this.defaultValue.showValues),showConstants:$e(t.showConstants,this.defaultValue.showConstants),showEnums:$e(t.showEnums,this.defaultValue.showEnums),showEnumMembers:$e(t.showEnumMembers,this.defaultValue.showEnumMembers),showKeywords:$e(t.showKeywords,this.defaultValue.showKeywords),showWords:$e(t.showWords,this.defaultValue.showWords),showColors:$e(t.showColors,this.defaultValue.showColors),showFiles:$e(t.showFiles,this.defaultValue.showFiles),showReferences:$e(t.showReferences,this.defaultValue.showReferences),showFolders:$e(t.showFolders,this.defaultValue.showFolders),showTypeParameters:$e(t.showTypeParameters,this.defaultValue.showTypeParameters),showSnippets:$e(t.showSnippets,this.defaultValue.showSnippets),showUsers:$e(t.showUsers,this.defaultValue.showUsers),showIssues:$e(t.showIssues,this.defaultValue.showIssues)}}},one=class extends Nn{constructor(){super(114,"smartSelect",{selectLeadingAndTrailingWhitespace:!0,selectSubwords:!0},{"editor.smartSelect.selectLeadingAndTrailingWhitespace":{description:m("selectLeadingAndTrailingWhitespace","Whether leading and trailing whitespace should always be selected."),default:!0,type:"boolean"},"editor.smartSelect.selectSubwords":{description:m("selectSubwords","Whether subwords (like 'foo' in 'fooBar' or 'foo_bar') should be selected."),default:!0,type:"boolean"}})}validate(e){return!e||typeof e!="object"?this.defaultValue:{selectLeadingAndTrailingWhitespace:$e(e.selectLeadingAndTrailingWhitespace,this.defaultValue.selectLeadingAndTrailingWhitespace),selectSubwords:$e(e.selectSubwords,this.defaultValue.selectSubwords)}}},rne=class extends Nn{constructor(){let e=[];super(131,"wordSegmenterLocales",e,{anyOf:[{description:m("wordSegmenterLocales","Locales to be used for word segmentation when doing word related navigations or operations. Specify the BCP 47 language tag of the word you wish to recognize (e.g., ja, zh-CN, zh-Hant-TW, etc.)."),type:"string"},{description:m("wordSegmenterLocales","Locales to be used for word segmentation when doing word related navigations or operations. Specify the BCP 47 language tag of the word you wish to recognize (e.g., ja, zh-CN, zh-Hant-TW, etc.)."),type:"array",items:{type:"string"}}]})}validate(e){if(typeof e=="string"&&(e=[e]),Array.isArray(e)){let t=[];for(let i of e)if(typeof i=="string")try{Intl.Segmenter.supportedLocalesOf(i).length>0&&t.push(i)}catch{}return t}return this.defaultValue}},sne=class extends Nn{constructor(){super(139,"wrappingIndent",1,{"editor.wrappingIndent":{type:"string",enum:["none","same","indent","deepIndent"],enumDescriptions:[m("wrappingIndent.none","No indentation. Wrapped lines begin at column 1."),m("wrappingIndent.same","Wrapped lines get the same indentation as the parent."),m("wrappingIndent.indent","Wrapped lines get +1 indentation toward the parent."),m("wrappingIndent.deepIndent","Wrapped lines get +2 indentation toward the parent.")],description:m("wrappingIndent","Controls the indentation of wrapped lines."),default:"same"}})}validate(e){switch(e){case"none":return 0;case"same":return 1;case"indent":return 2;case"deepIndent":return 3}return 1}compute(e,t,i){return t.get(2)===2?0:i}},ane=class extends f1{constructor(){super(147)}compute(e,t,i){let o=t.get(146);return{isDominatedByLongLines:e.isDominatedByLongLines,isWordWrapMinified:o.isWordWrapMinified,isViewportWrapping:o.isViewportWrapping,wrappingColumn:o.wrappingColumn}}},lne=class extends Nn{constructor(){let e={enabled:!0,showDropSelector:"afterDrop"};super(36,"dropIntoEditor",e,{"editor.dropIntoEditor.enabled":{type:"boolean",default:e.enabled,markdownDescription:m("dropIntoEditor.enabled","Controls whether you can drag and drop a file into a text editor by holding down the `Shift` key (instead of opening the file in an editor).")},"editor.dropIntoEditor.showDropSelector":{type:"string",markdownDescription:m("dropIntoEditor.showDropSelector","Controls if a widget is shown when dropping files into the editor. This widget lets you control how the file is dropped."),enum:["afterDrop","never"],enumDescriptions:[m("dropIntoEditor.showDropSelector.afterDrop","Show the drop selector widget after a file is dropped into the editor."),m("dropIntoEditor.showDropSelector.never","Never show the drop selector widget. Instead the default drop provider is always used.")],default:"afterDrop"}})}validate(e){if(!e||typeof e!="object")return this.defaultValue;let t=e;return{enabled:$e(t.enabled,this.defaultValue.enabled),showDropSelector:ko(t.showDropSelector,this.defaultValue.showDropSelector,["afterDrop","never"])}}},cne=class extends Nn{constructor(){let e={enabled:!0,showPasteSelector:"afterPaste"};super(85,"pasteAs",e,{"editor.pasteAs.enabled":{type:"boolean",default:e.enabled,markdownDescription:m("pasteAs.enabled","Controls whether you can paste content in different ways.")},"editor.pasteAs.showPasteSelector":{type:"string",markdownDescription:m("pasteAs.showPasteSelector","Controls if a widget is shown when pasting content in to the editor. This widget lets you control how the file is pasted."),enum:["afterPaste","never"],enumDescriptions:[m("pasteAs.showPasteSelector.afterPaste","Show the paste selector widget after content is pasted into the editor."),m("pasteAs.showPasteSelector.never","Never show the paste selector widget. Instead the default pasting behavior is always used.")],default:"afterPaste"}})}validate(e){if(!e||typeof e!="object")return this.defaultValue;let t=e;return{enabled:$e(t.enabled,this.defaultValue.enabled),showPasteSelector:ko(t.showPasteSelector,this.defaultValue.showPasteSelector,["afterPaste","never"])}}},znt="Consolas, 'Courier New', monospace",Vnt="Menlo, Monaco, 'Courier New', monospace",Unt="'Droid Sans Mono', 'monospace', monospace",as={fontFamily:dt?Vnt:Qn?Unt:znt,fontWeight:"normal",fontSize:dt?12:14,lineHeight:0,letterSpacing:0},rx=[];Oc={acceptSuggestionOnCommitCharacter:Ce(new pi(0,"acceptSuggestionOnCommitCharacter",!0,{markdownDescription:m("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:Ce(new _o(1,"acceptSuggestionOnEnter","on",["on","smart","off"],{markdownEnumDescriptions:["",m("acceptSuggestionOnEnterSmart","Only accept a suggestion with `Enter` when it makes a textual change."),""],markdownDescription:m("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:Ce(new Lie),accessibilityPageSize:Ce(new Ln(3,"accessibilityPageSize",10,1,1073741824,{description:m("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."),tags:["accessibility"]})),ariaLabel:Ce(new Sl(4,"ariaLabel",m("editorViewAccessibleLabel","Editor content"))),ariaRequired:Ce(new pi(5,"ariaRequired",!1,void 0)),screenReaderAnnounceInlineSuggestion:Ce(new pi(8,"screenReaderAnnounceInlineSuggestion",!0,{description:m("screenReaderAnnounceInlineSuggestion","Control whether inline suggestions are announced by a screen reader."),tags:["accessibility"]})),autoClosingBrackets:Ce(new _o(6,"autoClosingBrackets","languageDefined",["always","languageDefined","beforeWhitespace","never"],{enumDescriptions:["",m("editor.autoClosingBrackets.languageDefined","Use language configurations to determine when to autoclose brackets."),m("editor.autoClosingBrackets.beforeWhitespace","Autoclose brackets only when the cursor is to the left of whitespace."),""],description:m("autoClosingBrackets","Controls whether the editor should automatically close brackets after the user adds an opening bracket.")})),autoClosingComments:Ce(new _o(7,"autoClosingComments","languageDefined",["always","languageDefined","beforeWhitespace","never"],{enumDescriptions:["",m("editor.autoClosingComments.languageDefined","Use language configurations to determine when to autoclose comments."),m("editor.autoClosingComments.beforeWhitespace","Autoclose comments only when the cursor is to the left of whitespace."),""],description:m("autoClosingComments","Controls whether the editor should automatically close comments after the user adds an opening comment.")})),autoClosingDelete:Ce(new _o(9,"autoClosingDelete","auto",["always","auto","never"],{enumDescriptions:["",m("editor.autoClosingDelete.auto","Remove adjacent closing quotes or brackets only if they were automatically inserted."),""],description:m("autoClosingDelete","Controls whether the editor should remove adjacent closing quotes or brackets when deleting.")})),autoClosingOvertype:Ce(new _o(10,"autoClosingOvertype","auto",["always","auto","never"],{enumDescriptions:["",m("editor.autoClosingOvertype.auto","Type over closing quotes or brackets only if they were automatically inserted."),""],description:m("autoClosingOvertype","Controls whether the editor should type over closing quotes or brackets.")})),autoClosingQuotes:Ce(new _o(11,"autoClosingQuotes","languageDefined",["always","languageDefined","beforeWhitespace","never"],{enumDescriptions:["",m("editor.autoClosingQuotes.languageDefined","Use language configurations to determine when to autoclose quotes."),m("editor.autoClosingQuotes.beforeWhitespace","Autoclose quotes only when the cursor is to the left of whitespace."),""],description:m("autoClosingQuotes","Controls whether the editor should automatically close quotes after the user adds an opening quote.")})),autoIndent:Ce(new Uk(12,"autoIndent",4,"full",["none","keep","brackets","advanced","full"],Fnt,{enumDescriptions:[m("editor.autoIndent.none","The editor will not insert indentation automatically."),m("editor.autoIndent.keep","The editor will keep the current line's indentation."),m("editor.autoIndent.brackets","The editor will keep the current line's indentation and honor language defined brackets."),m("editor.autoIndent.advanced","The editor will keep the current line's indentation, honor language defined brackets and invoke special onEnterRules defined by languages."),m("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:m("autoIndent","Controls whether the editor should automatically adjust the indentation when users type, paste, move or indent lines.")})),automaticLayout:Ce(new pi(13,"automaticLayout",!1)),autoSurround:Ce(new _o(14,"autoSurround","languageDefined",["languageDefined","quotes","brackets","never"],{enumDescriptions:[m("editor.autoSurround.languageDefined","Use language configurations to determine when to automatically surround selections."),m("editor.autoSurround.quotes","Surround with quotes but not brackets."),m("editor.autoSurround.brackets","Surround with brackets but not quotes."),""],description:m("autoSurround","Controls whether the editor should automatically surround selections when typing quotes or brackets.")})),bracketPairColorization:Ce(new tne),bracketPairGuides:Ce(new ine),stickyTabStops:Ce(new pi(117,"stickyTabStops",!1,{description:m("stickyTabStops","Emulate selection behavior of tab characters when using spaces for indentation. Selection will stick to tab stops.")})),codeLens:Ce(new pi(17,"codeLens",!0,{description:m("codeLens","Controls whether the editor shows CodeLens.")})),codeLensFontFamily:Ce(new Sl(18,"codeLensFontFamily","",{description:m("codeLensFontFamily","Controls the font family for CodeLens.")})),codeLensFontSize:Ce(new Ln(19,"codeLensFontSize",0,0,100,{type:"number",default:0,minimum:0,maximum:100,markdownDescription:m("codeLensFontSize","Controls the font size in pixels for CodeLens. When set to 0, 90% of `#editor.fontSize#` is used.")})),colorDecorators:Ce(new pi(20,"colorDecorators",!0,{description:m("colorDecorators","Controls whether the editor should render the inline color decorators and color picker.")})),colorDecoratorActivatedOn:Ce(new _o(149,"colorDecoratorsActivatedOn","clickAndHover",["clickAndHover","hover","click"],{enumDescriptions:[m("editor.colorDecoratorActivatedOn.clickAndHover","Make the color picker appear both on click and hover of the color decorator"),m("editor.colorDecoratorActivatedOn.hover","Make the color picker appear on hover of the color decorator"),m("editor.colorDecoratorActivatedOn.click","Make the color picker appear on click of the color decorator")],description:m("colorDecoratorActivatedOn","Controls the condition to make a color picker appear from a color decorator")})),colorDecoratorsLimit:Ce(new Ln(21,"colorDecoratorsLimit",500,1,1e6,{markdownDescription:m("colorDecoratorsLimit","Controls the max number of color decorators that can be rendered in an editor at once.")})),columnSelection:Ce(new pi(22,"columnSelection",!1,{description:m("columnSelection","Enable that the selection with the mouse and keys is doing column selection.")})),comments:Ce(new Iie),contextmenu:Ce(new pi(24,"contextmenu",!0)),copyWithSyntaxHighlighting:Ce(new pi(25,"copyWithSyntaxHighlighting",!0,{description:m("copyWithSyntaxHighlighting","Controls whether syntax highlighting should be copied into the clipboard.")})),cursorBlinking:Ce(new Uk(26,"cursorBlinking",1,"blink",["blink","smooth","phase","expand","solid"],Bnt,{description:m("cursorBlinking","Control the cursor animation style.")})),cursorSmoothCaretAnimation:Ce(new _o(27,"cursorSmoothCaretAnimation","off",["off","explicit","on"],{enumDescriptions:[m("cursorSmoothCaretAnimation.off","Smooth caret animation is disabled."),m("cursorSmoothCaretAnimation.explicit","Smooth caret animation is enabled only when the user moves the cursor with an explicit gesture."),m("cursorSmoothCaretAnimation.on","Smooth caret animation is always enabled.")],description:m("cursorSmoothCaretAnimation","Controls whether the smooth caret animation should be enabled.")})),cursorStyle:Ce(new Uk(28,"cursorStyle",ss.Line,"line",["line","block","underline","line-thin","block-outline","underline-thin"],Wnt,{description:m("cursorStyle","Controls the cursor style.")})),cursorSurroundingLines:Ce(new Ln(29,"cursorSurroundingLines",0,0,1073741824,{description:m("cursorSurroundingLines","Controls the minimal number of visible leading lines (minimum 0) and trailing lines (minimum 1) surrounding the cursor. Known as 'scrollOff' or 'scrollOffset' in some other editors.")})),cursorSurroundingLinesStyle:Ce(new _o(30,"cursorSurroundingLinesStyle","default",["default","all"],{enumDescriptions:[m("cursorSurroundingLinesStyle.default","`cursorSurroundingLines` is enforced only when triggered via the keyboard or API."),m("cursorSurroundingLinesStyle.all","`cursorSurroundingLines` is enforced always.")],markdownDescription:m("cursorSurroundingLinesStyle","Controls when `#editor.cursorSurroundingLines#` should be enforced.")})),cursorWidth:Ce(new Ln(31,"cursorWidth",0,0,1073741824,{markdownDescription:m("cursorWidth","Controls the width of the cursor when `#editor.cursorStyle#` is set to `line`.")})),disableLayerHinting:Ce(new pi(32,"disableLayerHinting",!1)),disableMonospaceOptimizations:Ce(new pi(33,"disableMonospaceOptimizations",!1)),domReadOnly:Ce(new pi(34,"domReadOnly",!1)),dragAndDrop:Ce(new pi(35,"dragAndDrop",!0,{description:m("dragAndDrop","Controls whether the editor should allow moving selections via drag and drop.")})),emptySelectionClipboard:Ce(new Tie),dropIntoEditor:Ce(new lne),stickyScroll:Ce(new Bie),experimentalWhitespaceRendering:Ce(new _o(38,"experimentalWhitespaceRendering","svg",["svg","font","off"],{enumDescriptions:[m("experimentalWhitespaceRendering.svg","Use a new rendering method with svgs."),m("experimentalWhitespaceRendering.font","Use a new rendering method with font characters."),m("experimentalWhitespaceRendering.off","Use the stable rendering method.")],description:m("experimentalWhitespaceRendering","Controls whether whitespace is rendered with a new, experimental method.")})),extraEditorClassName:Ce(new Sl(39,"extraEditorClassName","")),fastScrollSensitivity:Ce(new uu(40,"fastScrollSensitivity",5,n=>n<=0?5:n,{markdownDescription:m("fastScrollSensitivity","Scrolling speed multiplier when pressing `Alt`.")})),find:Ce(new Die),fixedOverflowWidgets:Ce(new pi(42,"fixedOverflowWidgets",!1)),folding:Ce(new pi(43,"folding",!0,{description:m("folding","Controls whether the editor has code folding enabled.")})),foldingStrategy:Ce(new _o(44,"foldingStrategy","auto",["auto","indentation"],{enumDescriptions:[m("foldingStrategy.auto","Use a language-specific folding strategy if available, else the indentation-based one."),m("foldingStrategy.indentation","Use the indentation-based folding strategy.")],description:m("foldingStrategy","Controls the strategy for computing folding ranges.")})),foldingHighlight:Ce(new pi(45,"foldingHighlight",!0,{description:m("foldingHighlight","Controls whether the editor should highlight folded ranges.")})),foldingImportsByDefault:Ce(new pi(46,"foldingImportsByDefault",!1,{description:m("foldingImportsByDefault","Controls whether the editor automatically collapses import ranges.")})),foldingMaximumRegions:Ce(new Ln(47,"foldingMaximumRegions",5e3,10,65e3,{description:m("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:Ce(new pi(48,"unfoldOnClickAfterEndOfLine",!1,{description:m("unfoldOnClickAfterEndOfLine","Controls whether clicking on the empty content after a folded line will unfold the line.")})),fontFamily:Ce(new Sl(49,"fontFamily",as.fontFamily,{description:m("fontFamily","Controls the font family.")})),fontInfo:Ce(new Nie),fontLigatures2:Ce(new ah),fontSize:Ce(new Rie),fontWeight:Ce(new Aie),fontVariations:Ce(new qk),formatOnPaste:Ce(new pi(55,"formatOnPaste",!1,{description:m("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:Ce(new pi(56,"formatOnType",!1,{description:m("formatOnType","Controls whether the editor should automatically format the line after typing.")})),glyphMargin:Ce(new pi(57,"glyphMargin",!0,{description:m("glyphMargin","Controls whether the editor should render the vertical glyph margin. Glyph margin is mostly used for debugging.")})),gotoLocation:Ce(new Mie),hideCursorInOverviewRuler:Ce(new pi(59,"hideCursorInOverviewRuler",!1,{description:m("hideCursorInOverviewRuler","Controls whether the cursor should be hidden in the overview ruler.")})),hover:Ce(new Pie),inDiffEditor:Ce(new pi(61,"inDiffEditor",!1)),letterSpacing:Ce(new uu(64,"letterSpacing",as.letterSpacing,n=>uu.clamp(n,-5,20),{description:m("letterSpacing","Controls the letter spacing in pixels.")})),lightbulb:Ce(new Fie),lineDecorationsWidth:Ce(new Hie),lineHeight:Ce(new zie),lineNumbers:Ce(new Gie),lineNumbersMinChars:Ce(new Ln(69,"lineNumbersMinChars",5,1,300)),linkedEditing:Ce(new pi(70,"linkedEditing",!1,{description:m("linkedEditing","Controls whether the editor has linked editing enabled. Depending on the language, related symbols such as HTML tags, are updated while editing.")})),links:Ce(new pi(71,"links",!0,{description:m("links","Controls whether the editor should detect links and make them clickable.")})),matchBrackets:Ce(new _o(72,"matchBrackets","always",["always","near","never"],{description:m("matchBrackets","Highlight matching brackets.")})),minimap:Ce(new Vie),mouseStyle:Ce(new _o(74,"mouseStyle","text",["text","default","copy"])),mouseWheelScrollSensitivity:Ce(new uu(75,"mouseWheelScrollSensitivity",1,n=>n===0?1:n,{markdownDescription:m("mouseWheelScrollSensitivity","A multiplier to be used on the `deltaX` and `deltaY` of mouse wheel scroll events.")})),mouseWheelZoom:Ce(new pi(76,"mouseWheelZoom",!1,{markdownDescription:dt?m("mouseWheelZoom.mac","Zoom the font of the editor when using mouse wheel and holding `Cmd`."):m("mouseWheelZoom","Zoom the font of the editor when using mouse wheel and holding `Ctrl`.")})),multiCursorMergeOverlapping:Ce(new pi(77,"multiCursorMergeOverlapping",!0,{description:m("multiCursorMergeOverlapping","Merge multiple cursors when they are overlapping.")})),multiCursorModifier:Ce(new Uk(78,"multiCursorModifier","altKey","alt",["ctrlCmd","alt"],Hnt,{markdownEnumDescriptions:[m("multiCursorModifier.ctrlCmd","Maps to `Control` on Windows and Linux and to `Command` on macOS."),m("multiCursorModifier.alt","Maps to `Alt` on Windows and Linux and to `Option` on macOS.")],markdownDescription:m({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:Ce(new _o(79,"multiCursorPaste","spread",["spread","full"],{markdownEnumDescriptions:[m("multiCursorPaste.spread","Each cursor pastes a single line of the text."),m("multiCursorPaste.full","Each cursor pastes the full text.")],markdownDescription:m("multiCursorPaste","Controls pasting when the line count of the pasted text matches the cursor count.")})),multiCursorLimit:Ce(new Ln(80,"multiCursorLimit",1e4,1,1e5,{markdownDescription:m("multiCursorLimit","Controls the max number of cursors that can be in an active editor at once.")})),occurrencesHighlight:Ce(new _o(81,"occurrencesHighlight","singleFile",["off","singleFile","multiFile"],{markdownEnumDescriptions:[m("occurrencesHighlight.off","Does not highlight occurrences."),m("occurrencesHighlight.singleFile","Highlights occurrences only in the current file."),m("occurrencesHighlight.multiFile","Experimental: Highlights occurrences across all valid open files.")],markdownDescription:m("occurrencesHighlight","Controls whether occurrences should be highlighted across open files.")})),overviewRulerBorder:Ce(new pi(82,"overviewRulerBorder",!0,{description:m("overviewRulerBorder","Controls whether a border should be drawn around the overview ruler.")})),overviewRulerLanes:Ce(new Ln(83,"overviewRulerLanes",3,0,3)),padding:Ce(new Uie),pasteAs:Ce(new cne),parameterHints:Ce(new $ie),peekWidgetDefaultFocus:Ce(new _o(87,"peekWidgetDefaultFocus","tree",["tree","editor"],{enumDescriptions:[m("peekWidgetDefaultFocus.tree","Focus the tree when opening peek"),m("peekWidgetDefaultFocus.editor","Focus the editor when opening peek")],description:m("peekWidgetDefaultFocus","Controls whether to focus the inline editor or the tree in the peek widget.")})),placeholder:Ce(new qie),definitionLinkOpensInPeek:Ce(new pi(89,"definitionLinkOpensInPeek",!1,{description:m("definitionLinkOpensInPeek","Controls whether the Go to Definition mouse gesture always opens the peek widget.")})),quickSuggestions:Ce(new Kie),quickSuggestionsDelay:Ce(new Ln(91,"quickSuggestionsDelay",10,0,1073741824,{description:m("quickSuggestionsDelay","Controls the delay in milliseconds after which quick suggestions will show up.")})),readOnly:Ce(new pi(92,"readOnly",!1)),readOnlyMessage:Ce(new Zie),renameOnType:Ce(new pi(94,"renameOnType",!1,{description:m("renameOnType","Controls whether the editor auto renames on type."),markdownDeprecationMessage:m("renameOnTypeDeprecate","Deprecated, use `editor.linkedEditing` instead.")})),renderControlCharacters:Ce(new pi(95,"renderControlCharacters",!0,{description:m("renderControlCharacters","Controls whether the editor should render control characters."),restricted:!0})),renderFinalNewline:Ce(new _o(96,"renderFinalNewline",Qn?"dimmed":"on",["off","on","dimmed"],{description:m("renderFinalNewline","Render last line number when the file ends with a newline.")})),renderLineHighlight:Ce(new _o(97,"renderLineHighlight","line",["none","gutter","line","all"],{enumDescriptions:["","","",m("renderLineHighlight.all","Highlights both the gutter and the current line.")],description:m("renderLineHighlight","Controls how the editor should render the current line highlight.")})),renderLineHighlightOnlyWhenFocus:Ce(new pi(98,"renderLineHighlightOnlyWhenFocus",!1,{description:m("renderLineHighlightOnlyWhenFocus","Controls if the editor should render the current line highlight only when the editor is focused.")})),renderValidationDecorations:Ce(new _o(99,"renderValidationDecorations","editable",["editable","on","off"])),renderWhitespace:Ce(new _o(100,"renderWhitespace","selection",["none","boundary","selection","trailing","all"],{enumDescriptions:["",m("renderWhitespace.boundary","Render whitespace characters except for single spaces between words."),m("renderWhitespace.selection","Render whitespace characters only on selected text."),m("renderWhitespace.trailing","Render only trailing whitespace characters."),""],description:m("renderWhitespace","Controls how the editor should render whitespace characters.")})),revealHorizontalRightPadding:Ce(new Ln(101,"revealHorizontalRightPadding",15,0,1e3)),roundedSelection:Ce(new pi(102,"roundedSelection",!0,{description:m("roundedSelection","Controls whether selections should have rounded corners.")})),rulers:Ce(new Yie),scrollbar:Ce(new Xie),scrollBeyondLastColumn:Ce(new Ln(105,"scrollBeyondLastColumn",4,0,1073741824,{description:m("scrollBeyondLastColumn","Controls the number of extra characters beyond which the editor will scroll horizontally.")})),scrollBeyondLastLine:Ce(new pi(106,"scrollBeyondLastLine",!0,{description:m("scrollBeyondLastLine","Controls whether the editor will scroll beyond the last line.")})),scrollPredominantAxis:Ce(new pi(107,"scrollPredominantAxis",!0,{description:m("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:Ce(new pi(108,"selectionClipboard",!0,{description:m("selectionClipboard","Controls whether the Linux primary clipboard should be supported."),included:Qn})),selectionHighlight:Ce(new pi(109,"selectionHighlight",!0,{description:m("selectionHighlight","Controls whether the editor should highlight matches similar to the selection.")})),selectOnLineNumbers:Ce(new pi(110,"selectOnLineNumbers",!0)),showFoldingControls:Ce(new _o(111,"showFoldingControls","mouseover",["always","never","mouseover"],{enumDescriptions:[m("showFoldingControls.always","Always show the folding controls."),m("showFoldingControls.never","Never show the folding controls and reduce the gutter size."),m("showFoldingControls.mouseover","Only show the folding controls when the mouse is over the gutter.")],description:m("showFoldingControls","Controls when the folding controls on the gutter are shown.")})),showUnused:Ce(new pi(112,"showUnused",!0,{description:m("showUnused","Controls fading out of unused code.")})),showDeprecated:Ce(new pi(141,"showDeprecated",!0,{description:m("showDeprecated","Controls strikethrough deprecated variables.")})),inlayHints:Ce(new Wie),snippetSuggestions:Ce(new _o(113,"snippetSuggestions","inline",["top","bottom","inline","none"],{enumDescriptions:[m("snippetSuggestions.top","Show snippet suggestions on top of other suggestions."),m("snippetSuggestions.bottom","Show snippet suggestions below other suggestions."),m("snippetSuggestions.inline","Show snippets suggestions with other suggestions."),m("snippetSuggestions.none","Do not show snippet suggestions.")],description:m("snippetSuggestions","Controls whether snippets are shown with other suggestions and how they are sorted.")})),smartSelect:Ce(new one),smoothScrolling:Ce(new pi(115,"smoothScrolling",!1,{description:m("smoothScrolling","Controls whether the editor will scroll using an animation.")})),stopRenderingLineAfter:Ce(new Ln(118,"stopRenderingLineAfter",1e4,-1,1073741824)),suggest:Ce(new nne),inlineSuggest:Ce(new Jie),inlineEdit:Ce(new ene),inlineCompletionsAccessibilityVerbose:Ce(new pi(150,"inlineCompletionsAccessibilityVerbose",!1,{description:m("inlineCompletionsAccessibilityVerbose","Controls whether the accessibility hint should be provided to screen reader users when an inline completion is shown.")})),suggestFontSize:Ce(new Ln(120,"suggestFontSize",0,0,1e3,{markdownDescription:m("suggestFontSize","Font size for the suggest widget. When set to {0}, the value of {1} is used.","`0`","`#editor.fontSize#`")})),suggestLineHeight:Ce(new Ln(121,"suggestLineHeight",0,0,1e3,{markdownDescription:m("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:Ce(new pi(122,"suggestOnTriggerCharacters",!0,{description:m("suggestOnTriggerCharacters","Controls whether suggestions should automatically show up when typing trigger characters.")})),suggestSelection:Ce(new _o(123,"suggestSelection","first",["first","recentlyUsed","recentlyUsedByPrefix"],{markdownEnumDescriptions:[m("suggestSelection.first","Always select the first suggestion."),m("suggestSelection.recentlyUsed","Select recent suggestions unless further typing selects one, e.g. `console.| -> console.log` because `log` has been completed recently."),m("suggestSelection.recentlyUsedByPrefix","Select suggestions based on previous prefixes that have completed those suggestions, e.g. `co -> console` and `con -> const`.")],description:m("suggestSelection","Controls how suggestions are pre-selected when showing the suggest list.")})),tabCompletion:Ce(new _o(124,"tabCompletion","off",["on","off","onlySnippets"],{enumDescriptions:[m("tabCompletion.on","Tab complete will insert the best matching suggestion when pressing tab."),m("tabCompletion.off","Disable tab completions."),m("tabCompletion.onlySnippets","Tab complete snippets when their prefix match. Works best when 'quickSuggestions' aren't enabled.")],description:m("tabCompletion","Enables tab completions.")})),tabIndex:Ce(new Ln(125,"tabIndex",0,-1,1073741824)),unicodeHighlight:Ce(new Qie),unusualLineTerminators:Ce(new _o(127,"unusualLineTerminators","prompt",["auto","off","prompt"],{enumDescriptions:[m("unusualLineTerminators.auto","Unusual line terminators are automatically removed."),m("unusualLineTerminators.off","Unusual line terminators are ignored."),m("unusualLineTerminators.prompt","Unusual line terminators prompt to be removed.")],description:m("unusualLineTerminators","Remove unusual line terminators that might cause problems.")})),useShadowDOM:Ce(new pi(128,"useShadowDOM",!0)),useTabStops:Ce(new pi(129,"useTabStops",!0,{description:m("useTabStops","Spaces and tabs are inserted and deleted in alignment with tab stops.")})),wordBreak:Ce(new _o(130,"wordBreak","normal",["normal","keepAll"],{markdownEnumDescriptions:[m("wordBreak.normal","Use the default line break rule."),m("wordBreak.keepAll","Word breaks should not be used for Chinese/Japanese/Korean (CJK) text. Non-CJK text behavior is the same as for normal.")],description:m("wordBreak","Controls the word break rules used for Chinese/Japanese/Korean (CJK) text.")})),wordSegmenterLocales:Ce(new rne),wordSeparators:Ce(new Sl(132,"wordSeparators",Vk,{description:m("wordSeparators","Characters that will be used as word separators when doing word related navigations or operations.")})),wordWrap:Ce(new _o(133,"wordWrap","off",["off","on","wordWrapColumn","bounded"],{markdownEnumDescriptions:[m("wordWrap.off","Lines will never wrap."),m("wordWrap.on","Lines will wrap at the viewport width."),m({key:"wordWrap.wordWrapColumn",comment:["- `editor.wordWrapColumn` refers to a different setting and should not be localized."]},"Lines will wrap at `#editor.wordWrapColumn#`."),m({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:m({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:Ce(new Sl(134,"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:Ce(new Sl(135,"wordWrapBreakBeforeCharacters","([{\u2018\u201C\u3008\u300A\u300C\u300E\u3010\u3014\uFF08\uFF3B\uFF5B\uFF62\xA3\xA5\uFF04\uFFE1\uFFE5+\uFF0B")),wordWrapColumn:Ce(new Ln(136,"wordWrapColumn",80,1,1073741824,{markdownDescription:m({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:Ce(new _o(137,"wordWrapOverride1","inherit",["off","on","inherit"])),wordWrapOverride2:Ce(new _o(138,"wordWrapOverride2","inherit",["off","on","inherit"])),editorClassName:Ce(new Eie),defaultColorDecorators:Ce(new pi(148,"defaultColorDecorators",!1,{markdownDescription:m("defaultColorDecorators","Controls whether inline color decorations should be shown using the default document color provider")})),pixelRatio:Ce(new jie),tabFocusMode:Ce(new pi(145,"tabFocusMode",!1,{markdownDescription:m("tabFocusMode","Controls whether the editor receives tabs or defers them to the workbench for navigation.")})),layoutInfo:Ce(new RR),wrappingInfo:Ce(new ane),wrappingIndent:Ce(new sne),wrappingStrategy:Ce(new Oie)}});function Be(n){$r(n)||lTe.onUnexpectedError(n)}function mi(n){$r(n)||lTe.onUnexpectedExternalError(n)}function une(n){if(n instanceof Error){let{name:e,message:t}=n,i=n.stacktrace||n.stack;return{$isError:!0,name:e,message:t,stack:i,noTelemetry:AR.isErrorNoTelemetry(n)}}return n}function $r(n){return n instanceof ga?!0:n instanceof Error&&n.name===H3&&n.message===H3}function cTe(){let n=new Error(H3);return n.name=n.message,n}function js(n){return n?new Error(`Illegal argument: ${n}`):new Error("Illegal argument")}function Kk(n){return n?new Error(`Illegal state: ${n}`):new Error("Illegal state")}var dne,lTe,H3,ga,z3,AR,Nt,je=k(()=>{dne=class{constructor(){this.listeners=[],this.unexpectedErrorHandler=function(e){setTimeout(()=>{throw e.stack?AR.isErrorNoTelemetry(e)?new AR(e.message+` `+e.stack):new Error(e.message+` `+e.stack):e},0)}}emit(e){this.listeners.forEach(t=>{t(e)})}onUnexpectedError(e){this.unexpectedErrorHandler(e),this.emit(e)}onUnexpectedExternalError(e){this.unexpectedErrorHandler(e)}},lTe=new dne;H3="Canceled";ga=class extends Error{constructor(){super(H3),this.name=this.message}};z3=class extends Error{constructor(e){super("NotSupported"),e&&(this.message=e)}},AR=class n extends Error{constructor(e){super(e),this.name="CodeExpectedError"}static fromError(e){if(e instanceof n)return e;let t=new n;return t.message=e.message,t.stack=e.stack,t}static isErrorNoTelemetry(e){return e.name==="CodeExpectedError"}},Nt=class n extends Error{constructor(e){super(e||"An unexpected bug occurred."),Object.setPrototypeOf(this,n.prototype)}}});function yd(n,e){let t=this,i=!1,o;return function(){if(i)return o;if(i=!0,e)try{o=n.apply(t,arguments)}finally{e()}else o=n.apply(t,arguments);return o}}var sx=k(()=>{});function jnt(n){m1=n}function g1(n){return m1?.trackDisposable(n),n}function _1(n){m1?.markAsDisposed(n)}function V3(n,e){m1?.setParent(n,e)}function qnt(n,e){if(m1)for(let t of n)m1.setParent(t,e)}function lx(n){return m1?.markAsSingleton(n),n}function cx(n){return typeof n=="object"&&n!==null&&typeof n.dispose=="function"&&n.dispose.length===0}function Yt(n){if(Dt.is(n)){let e=[];for(let t of n)if(t)try{t.dispose()}catch(i){e.push(i)}if(e.length===1)throw e[0];if(e.length>1)throw new AggregateError(e,"Encountered errors while disposing of store");return Array.isArray(n)?[]:n}else if(n)return n.dispose(),n}function qs(...n){let e=ge(()=>Yt(n));return qnt(n,e),e}function ge(n){let e=g1({dispose:yd(()=>{_1(e),n()})});return e}var $nt,m1,H,D,Hi,U3,$3,ax,j=k(()=>{sx();Cl();$nt=!1,m1=null;if($nt){let n="__is_disposable_tracked__";jnt(new class{trackDisposable(e){let t=new Error("Potentially leaked disposable").stack;setTimeout(()=>{e[n]||console.log(t)},3e3)}setParent(e,t){if(e&&e!==D.None)try{e[n]=!0}catch{}}markAsDisposed(e){if(e&&e!==D.None)try{e[n]=!0}catch{}}markAsSingleton(e){}})}H=class n{static{this.DISABLE_DISPOSED_WARNING=!1}constructor(){this._toDispose=new Set,this._isDisposed=!1,g1(this)}dispose(){this._isDisposed||(_1(this),this._isDisposed=!0,this.clear())}get isDisposed(){return this._isDisposed}clear(){if(this._toDispose.size!==0)try{Yt(this._toDispose)}finally{this._toDispose.clear()}}add(e){if(!e)return e;if(e===this)throw new Error("Cannot register a disposable on itself!");return V3(e,this),this._isDisposed?n.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(e),e}deleteAndLeak(e){e&&this._toDispose.has(e)&&(this._toDispose.delete(e),V3(e,null))}},D=class{static{this.None=Object.freeze({dispose(){}})}constructor(){this._store=new H,g1(this),V3(this._store,this)}dispose(){_1(this),this._store.dispose()}_register(e){if(e===this)throw new Error("Cannot register a disposable on itself!");return this._store.add(e)}},Hi=class{constructor(){this._isDisposed=!1,g1(this)}get value(){return this._isDisposed?void 0:this._value}set value(e){this._isDisposed||e===this._value||(this._value?.dispose(),e&&V3(e,this),this._value=e)}clear(){this.value=void 0}dispose(){this._isDisposed=!0,_1(this),this._value?.dispose(),this._value=void 0}},U3=class{constructor(e){this._disposable=e,this._counter=1}acquire(){return this._counter++,this}release(){return--this._counter===0&&this._disposable.dispose(),this}},$3=class{constructor(e){this.object=e}dispose(){}},ax=class{constructor(){this._store=new Map,this._isDisposed=!1,g1(this)}dispose(){_1(this),this._isDisposed=!0,this.clearAndDisposeAll()}clearAndDisposeAll(){if(this._store.size)try{Yt(this._store.values())}finally{this._store.clear()}}get(e){return this._store.get(e)}set(e,t,i=!1){this._isDisposed&&console.warn(new Error("Trying to add a disposable to a DisposableMap that has already been disposed of. The added object will be leaked!").stack),i||this._store.get(e)?.dispose(),this._store.set(e,t)}deleteAndDispose(e){this._store.get(e)?.dispose(),this._store.delete(e)}[Symbol.iterator](){return this._store[Symbol.iterator]()}}});var Knt,cn,kl=k(()=>{Knt=globalThis.performance&&typeof globalThis.performance.now=="function",cn=class n{static create(e){return new n(e)}constructor(e){this._now=Knt&&e===!1?Date.now:globalThis.performance.now.bind(globalThis.performance),this._startTime=this._now(),this._stopTime=-1}stop(){this._stopTime=this._now()}reset(){this._startTime=this._now(),this._stopTime=-1}elapsed(){return this._stopTime!==-1?this._stopTime-this._startTime:this._now()-this._startTime}}});var Gnt,uTe,Ynt,ne,hne,hTe,fne,MR,pne,mne,Gk,Znt,Xnt,j3,A,fTe,q3,lh,Yk,K3,G3,uf,PR,Ie=k(()=>{je();sx();j();du();kl();Gnt=!1,uTe=!1,Ynt=!1;(function(n){n.None=()=>D.None;function e($){if(Ynt){let{onDidAddListener:z}=$,ae=MR.create(),X=0;$.onDidAddListener=()=>{++X===2&&(console.warn("snapshotted emitter LIKELY used public and SHOULD HAVE BEEN created with DisposableStore. snapshotted here"),ae.print()),z?.()}}}function t($,z){return f($,()=>{},0,void 0,!0,void 0,z)}n.defer=t;function i($){return(z,ae=null,X)=>{let ue=!1,ce;return ce=$(B=>{if(!ue)return ce?ce.dispose():ue=!0,z.call(ae,B)},null,X),ue&&ce.dispose(),ce}}n.once=i;function o($,z){return n.once(n.filter($,z))}n.onceIf=o;function r($,z,ae){return u((X,ue=null,ce)=>$(B=>X.call(ue,z(B)),null,ce),ae)}n.map=r;function s($,z,ae){return u((X,ue=null,ce)=>$(B=>{z(B),X.call(ue,B)},null,ce),ae)}n.forEach=s;function a($,z,ae){return u((X,ue=null,ce)=>$(B=>z(B)&&X.call(ue,B),null,ce),ae)}n.filter=a;function l($){return $}n.signal=l;function c(...$){return(z,ae=null,X)=>{let ue=qs(...$.map(ce=>ce(B=>z.call(ae,B))));return h(ue,X)}}n.any=c;function d($,z,ae,X){let ue=ae;return r($,ce=>(ue=z(ue,ce),ue),X)}n.reduce=d;function u($,z){let ae,X={onWillAddFirstListener(){ae=$(ue.fire,ue)},onDidRemoveLastListener(){ae?.dispose()}};z||e(X);let ue=new A(X);return z?.add(ue),ue.event}function h($,z){return z instanceof Array?z.push($):z&&z.add($),$}function f($,z,ae=100,X=!1,ue=!1,ce,B){let Je,ni,K,Ni=0,ui,po={leakWarningThreshold:ce,onWillAddFirstListener(){Je=$(Ri=>{Ni++,ni=z(ni,Ri),X&&!K&&(Jr.fire(ni),ni=void 0),ui=()=>{let vs=ni;ni=void 0,K=void 0,(!X||Ni>1)&&Jr.fire(vs),Ni=0},typeof ae=="number"?(clearTimeout(K),K=setTimeout(ui,ae)):K===void 0&&(K=0,queueMicrotask(ui))})},onWillRemoveListener(){ue&&Ni>0&&ui?.()},onDidRemoveLastListener(){ui=void 0,Je.dispose()}};B||e(po);let Jr=new A(po);return B?.add(Jr),Jr.event}n.debounce=f;function p($,z=0,ae){return n.debounce($,(X,ue)=>X?(X.push(ue),X):[ue],z,void 0,!0,void 0,ae)}n.accumulate=p;function g($,z=(X,ue)=>X===ue,ae){let X=!0,ue;return a($,ce=>{let B=X||!z(ce,ue);return X=!1,ue=ce,B},ae)}n.latch=g;function _($,z,ae){return[n.filter($,z,ae),n.filter($,X=>!z(X),ae)]}n.split=_;function b($,z=!1,ae=[],X){let ue=ae.slice(),ce=$(ni=>{ue?ue.push(ni):Je.fire(ni)});X&&X.add(ce);let B=()=>{ue?.forEach(ni=>Je.fire(ni)),ue=null},Je=new A({onWillAddFirstListener(){ce||(ce=$(ni=>Je.fire(ni)),X&&X.add(ce))},onDidAddFirstListener(){ue&&(z?setTimeout(B):B())},onDidRemoveLastListener(){ce&&ce.dispose(),ce=null}});return X&&X.add(Je),Je.event}n.buffer=b;function v($,z){return(X,ue,ce)=>{let B=z(new w);return $(function(Je){let ni=B.evaluate(Je);ni!==x&&X.call(ue,ni)},void 0,ce)}}n.chain=v;let x=Symbol("HaltChainable");class w{constructor(){this.steps=[]}map(z){return this.steps.push(z),this}forEach(z){return this.steps.push(ae=>(z(ae),ae)),this}filter(z){return this.steps.push(ae=>z(ae)?ae:x),this}reduce(z,ae){let X=ae;return this.steps.push(ue=>(X=z(X,ue),X)),this}latch(z=(ae,X)=>ae===X){let ae=!0,X;return this.steps.push(ue=>{let ce=ae||!z(ue,X);return ae=!1,X=ue,ce?ue:x}),this}evaluate(z){for(let ae of this.steps)if(z=ae(z),z===x)break;return z}}function y($,z,ae=X=>X){let X=(...Je)=>B.fire(ae(...Je)),ue=()=>$.on(z,X),ce=()=>$.removeListener(z,X),B=new A({onWillAddFirstListener:ue,onDidRemoveLastListener:ce});return B.event}n.fromNodeEventEmitter=y;function C($,z,ae=X=>X){let X=(...Je)=>B.fire(ae(...Je)),ue=()=>$.addEventListener(z,X),ce=()=>$.removeEventListener(z,X),B=new A({onWillAddFirstListener:ue,onDidRemoveLastListener:ce});return B.event}n.fromDOMEventEmitter=C;function L($){return new Promise(z=>i($)(z))}n.toPromise=L;function E($){let z=new A;return $.then(ae=>{z.fire(ae)},()=>{z.fire(void 0)}).finally(()=>{z.dispose()}),z.event}n.fromPromise=E;function N($,z){return $(ae=>z.fire(ae))}n.forward=N;function M($,z,ae){return z(ae),$(X=>z(X))}n.runAndSubscribe=M;class F{constructor(z,ae){this._observable=z,this._counter=0,this._hasChanged=!1;let X={onWillAddFirstListener:()=>{z.addObserver(this),this._observable.reportChanges()},onDidRemoveLastListener:()=>{z.removeObserver(this)}};ae||e(X),this.emitter=new A(X),ae&&ae.add(this.emitter)}beginUpdate(z){this._counter++}handlePossibleChange(z){}handleChange(z,ae){this._hasChanged=!0}endUpdate(z){this._counter--,this._counter===0&&(this._observable.reportChanges(),this._hasChanged&&(this._hasChanged=!1,this.emitter.fire(this._observable.get())))}}function q($,z){return new F($,z).emitter.event}n.fromObservable=q;function te($){return(z,ae,X)=>{let ue=0,ce=!1,B={beginUpdate(){ue++},endUpdate(){ue--,ue===0&&($.reportChanges(),ce&&(ce=!1,z.call(ae)))},handlePossibleChange(){},handleChange(){ce=!0}};$.addObserver(B),$.reportChanges();let Je={dispose(){$.removeObserver(B)}};return X instanceof H?X.add(Je):Array.isArray(X)&&X.push(Je),Je}}n.fromObservableLight=te})(ne||(ne={}));hne=class n{static{this.all=new Set}static{this._idPool=0}constructor(e){this.listenerCount=0,this.invocationCount=0,this.elapsedOverall=0,this.durations=[],this.name=`${e}_${n._idPool++}`,n.all.add(this)}start(e){this._stopWatch=new cn,this.listenerCount=e}stop(){if(this._stopWatch){let e=this._stopWatch.elapsed();this.durations.push(e),this.elapsedOverall+=e,this.invocationCount+=1,this._stopWatch=void 0}}},hTe=-1,fne=class n{static{this._idPool=1}constructor(e,t,i=(n._idPool++).toString(16).padStart(3,"0")){this._errorHandler=e,this.threshold=t,this.name=i,this._warnCountdown=0}dispose(){this._stacks?.clear()}check(e,t){let i=this.threshold;if(i<=0||t{let r=this._stacks.get(e.value)||0;this._stacks.set(e.value,r-1)}}getMostFrequentStack(){if(!this._stacks)return;let e,t=0;for(let[i,o]of this._stacks)(!e||t{if(n instanceof Gk)e(n);else for(let t=0;t{n.length!==0&&(console.warn("[LEAKING LISTENERS] GC'ed these listeners that were NOT yet disposed:"),console.warn(n.join(` `)),n.length=0)},3e3),j3=new FinalizationRegistry(e=>{typeof e=="string"&&n.push(e)})}A=class{constructor(e){this._size=0,this._options=e,this._leakageMon=hTe>0||this._options?.leakWarningThreshold?new fne(e?.onListenerError??Be,this._options?.leakWarningThreshold??hTe):void 0,this._perfMon=this._options?._profName?new hne(this._options._profName):void 0,this._deliveryQueue=this._options?.deliveryQueue}dispose(){if(!this._disposed){if(this._disposed=!0,this._deliveryQueue?.current===this&&this._deliveryQueue.reset(),this._listeners){if(uTe){let e=this._listeners;queueMicrotask(()=>{Xnt(e,t=>t.stack?.print())})}this._listeners=void 0,this._size=0}this._options?.onDidRemoveLastListener?.(),this._leakageMon?.dispose()}}get event(){return this._event??=(e,t,i)=>{if(this._leakageMon&&this._size>this._leakageMon.threshold**2){let l=`[${this._leakageMon.name}] REFUSES to accept new listeners because it exceeded its threshold by far (${this._size} vs ${this._leakageMon.threshold})`;console.warn(l);let c=this._leakageMon.getMostFrequentStack()??["UNKNOWN stack",-1],d=new mne(`${l}. HINT: Stack shows most frequent listener (${c[1]}-times)`,c[0]);return(this._options?.onListenerError||Be)(d),D.None}if(this._disposed)return D.None;t&&(e=e.bind(t));let o=new Gk(e),r,s;this._leakageMon&&this._size>=Math.ceil(this._leakageMon.threshold*.2)&&(o.stack=MR.create(),r=this._leakageMon.check(o.stack,this._size+1)),uTe&&(o.stack=s??MR.create()),this._listeners?this._listeners instanceof Gk?(this._deliveryQueue??=new q3,this._listeners=[this._listeners,o]):this._listeners.push(o):(this._options?.onWillAddFirstListener?.(this),this._listeners=o,this._options?.onDidAddFirstListener?.(this)),this._size++;let a=ge(()=>{j3?.unregister(a),r?.(),this._removeListener(o)});if(i instanceof H?i.add(a):Array.isArray(i)&&i.push(a),j3){let l=new Error().stack.split(` `).slice(2,3).join(` `).trim(),c=/(file:|vscode-file:\/\/vscode-app)?(\/[^:]*:\d+:\d+)/.exec(l);j3.register(a,c?.[2]??l,a)}return a},this._event}_removeListener(e){if(this._options?.onWillRemoveListener?.(this),!this._listeners)return;if(this._size===1){this._listeners=void 0,this._options?.onDidRemoveLastListener?.(this),this._size=0;return}let t=this._listeners,i=t.indexOf(e);if(i===-1)throw console.log("disposed?",this._disposed),console.log("size?",this._size),console.log("arr?",JSON.stringify(this._listeners)),new Error("Attempted to dispose unknown listener");this._size--,t[i]=void 0;let o=this._deliveryQueue.current===this;if(this._size*Znt<=t.length){let r=0;for(let s=0;s0}},fTe=()=>new q3,q3=class{constructor(){this.i=-1,this.end=0}enqueue(e,t,i){this.i=0,this.end=i,this.current=e,this.value=t}reset(){this.i=this.end,this.current=void 0,this.value=void 0}},lh=class extends A{constructor(e){super(e),this._isPaused=0,this._eventQueue=new go,this._mergeFn=e?.merge}pause(){this._isPaused++}resume(){if(this._isPaused!==0&&--this._isPaused===0)if(this._mergeFn){if(this._eventQueue.size>0){let e=Array.from(this._eventQueue);this._eventQueue.clear(),super.fire(this._mergeFn(e))}}else for(;!this._isPaused&&this._eventQueue.size!==0;)super.fire(this._eventQueue.shift())}fire(e){this._size&&(this._isPaused!==0?this._eventQueue.push(e):super.fire(e))}},Yk=class extends lh{constructor(e){super(e),this._delay=e.delay??100}fire(e){this._handle||(this.pause(),this._handle=setTimeout(()=>{this._handle=void 0,this.resume()},this._delay)),super.fire(e)}},K3=class extends A{constructor(e){super(e),this._queuedEvents=[],this._mergeFn=e?.merge}fire(e){this.hasListeners()&&(this._queuedEvents.push(e),this._queuedEvents.length===1&&queueMicrotask(()=>{this._mergeFn?super.fire(this._mergeFn(this._queuedEvents)):this._queuedEvents.forEach(t=>super.fire(t)),this._queuedEvents=[]}))}},G3=class{constructor(){this.hasListeners=!1,this.events=[],this.emitter=new A({onWillAddFirstListener:()=>this.onFirstListenerAdd(),onDidRemoveLastListener:()=>this.onLastListenerRemove()})}get event(){return this.emitter.event}add(e){let t={event:e,listener:null};return this.events.push(t),this.hasListeners&&this.hook(t),ge(yd(()=>{this.hasListeners&&this.unhook(t);let o=this.events.indexOf(t);this.events.splice(o,1)}))}onFirstListenerAdd(){this.hasListeners=!0,this.events.forEach(e=>this.hook(e))}onLastListenerRemove(){this.hasListeners=!1,this.events.forEach(e=>this.unhook(e))}hook(e){e.listener=e.event(t=>this.emitter.fire(t))}unhook(e){e.listener?.dispose(),e.listener=null}dispose(){this.emitter.dispose();for(let e of this.events)e.listener?.dispose();this.events=[]}},uf=class{constructor(){this.data=[]}wrapEvent(e,t,i){return(o,r,s)=>e(a=>{let l=this.data[this.data.length-1];if(!t){l?l.buffers.push(()=>o.call(r,a)):o.call(r,a);return}let c=l;if(!c){o.call(r,t(i,a));return}c.items??=[],c.items.push(a),c.buffers.length===0&&l.buffers.push(()=>{c.reducedResult??=i?c.items.reduce(t,i):c.items.reduce(t),o.call(r,c.reducedResult)})},void 0,s)}bufferEvents(e){let t={buffers:new Array};this.data.push(t);let i=e();return this.data.pop(),t.buffers.forEach(o=>o()),i}},PR=class{constructor(){this.listening=!1,this.inputEvent=ne.None,this.inputEventListener=D.None,this.emitter=new A({onDidAddFirstListener:()=>{this.listening=!0,this.inputEventListener=this.inputEvent(this.emitter.fire,this.emitter)},onDidRemoveLastListener:()=>{this.listening=!1,this.inputEventListener.dispose()}}),this.event=this.emitter.event}set input(e){this.inputEvent=e,this.listening&&(this.inputEventListener.dispose(),this.inputEventListener=e(this.emitter.fire,this.emitter))}dispose(){this.inputEventListener.dispose(),this.emitter.dispose()}}});function OR(n){let e=new qt;return n.add({dispose(){e.cancel()}}),e.token}var pTe,Ze,Zk,qt,ci=k(()=>{Ie();pTe=Object.freeze(function(n,e){let t=setTimeout(n.bind(e),0);return{dispose(){clearTimeout(t)}}});(function(n){function e(t){return t===n.None||t===n.Cancelled||t instanceof Zk?!0:!t||typeof t!="object"?!1:typeof t.isCancellationRequested=="boolean"&&typeof t.onCancellationRequested=="function"}n.isCancellationToken=e,n.None=Object.freeze({isCancellationRequested:!1,onCancellationRequested:ne.None}),n.Cancelled=Object.freeze({isCancellationRequested:!0,onCancellationRequested:pTe})})(Ze||(Ze={}));Zk=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?pTe:(this._emitter||(this._emitter=new A),this._emitter.event)}dispose(){this._emitter&&(this._emitter.dispose(),this._emitter=null)}},qt=class{constructor(e){this._token=void 0,this._parentListener=void 0,this._parentListener=e&&e.onCancellationRequested(this.cancel,this)}get token(){return this._token||(this._token=new Zk),this._token}cancel(){this._token?this._token instanceof Zk&&this._token.cancel():this._token=Ze.Cancelled}dispose(e=!1){e&&this.cancel(),this._parentListener?.dispose(),this._token?this._token instanceof Zk&&this._token.dispose():this._token=Ze.None}}});function Rn(n,e){let t=(e&65535)<<16>>>0;return(n|t)>>>0}var FR,Y3,gne,_ne,vne,Jnt,eot,tot,iot,Z3,bne,hf,hu=k(()=>{FR=class{constructor(){this._keyCodeToStr=[],this._strToKeyCode=Object.create(null)}define(e,t){this._keyCodeToStr[e]=t,this._strToKeyCode[t.toLowerCase()]=e}keyCodeToStr(e){return this._keyCodeToStr[e]}strToKeyCode(e){return this._strToKeyCode[e.toLowerCase()]||0}},Y3=new FR,gne=new FR,_ne=new FR,vne=new Array(230),Jnt={},eot=[],tot=Object.create(null),iot=Object.create(null),Z3=[],bne=[];for(let n=0;n<=193;n++)Z3[n]=-1;for(let n=0;n<=132;n++)bne[n]=-1;(function(){let n="",e=[[1,0,"None",0,"unknown",0,"VK_UNKNOWN",n,n],[1,1,"Hyper",0,n,0,n,n,n],[1,2,"Super",0,n,0,n,n,n],[1,3,"Fn",0,n,0,n,n,n],[1,4,"FnLock",0,n,0,n,n,n],[1,5,"Suspend",0,n,0,n,n,n],[1,6,"Resume",0,n,0,n,n,n],[1,7,"Turbo",0,n,0,n,n,n],[1,8,"Sleep",0,n,0,"VK_SLEEP",n,n],[1,9,"WakeUp",0,n,0,n,n,n],[0,10,"KeyA",31,"A",65,"VK_A",n,n],[0,11,"KeyB",32,"B",66,"VK_B",n,n],[0,12,"KeyC",33,"C",67,"VK_C",n,n],[0,13,"KeyD",34,"D",68,"VK_D",n,n],[0,14,"KeyE",35,"E",69,"VK_E",n,n],[0,15,"KeyF",36,"F",70,"VK_F",n,n],[0,16,"KeyG",37,"G",71,"VK_G",n,n],[0,17,"KeyH",38,"H",72,"VK_H",n,n],[0,18,"KeyI",39,"I",73,"VK_I",n,n],[0,19,"KeyJ",40,"J",74,"VK_J",n,n],[0,20,"KeyK",41,"K",75,"VK_K",n,n],[0,21,"KeyL",42,"L",76,"VK_L",n,n],[0,22,"KeyM",43,"M",77,"VK_M",n,n],[0,23,"KeyN",44,"N",78,"VK_N",n,n],[0,24,"KeyO",45,"O",79,"VK_O",n,n],[0,25,"KeyP",46,"P",80,"VK_P",n,n],[0,26,"KeyQ",47,"Q",81,"VK_Q",n,n],[0,27,"KeyR",48,"R",82,"VK_R",n,n],[0,28,"KeyS",49,"S",83,"VK_S",n,n],[0,29,"KeyT",50,"T",84,"VK_T",n,n],[0,30,"KeyU",51,"U",85,"VK_U",n,n],[0,31,"KeyV",52,"V",86,"VK_V",n,n],[0,32,"KeyW",53,"W",87,"VK_W",n,n],[0,33,"KeyX",54,"X",88,"VK_X",n,n],[0,34,"KeyY",55,"Y",89,"VK_Y",n,n],[0,35,"KeyZ",56,"Z",90,"VK_Z",n,n],[0,36,"Digit1",22,"1",49,"VK_1",n,n],[0,37,"Digit2",23,"2",50,"VK_2",n,n],[0,38,"Digit3",24,"3",51,"VK_3",n,n],[0,39,"Digit4",25,"4",52,"VK_4",n,n],[0,40,"Digit5",26,"5",53,"VK_5",n,n],[0,41,"Digit6",27,"6",54,"VK_6",n,n],[0,42,"Digit7",28,"7",55,"VK_7",n,n],[0,43,"Digit8",29,"8",56,"VK_8",n,n],[0,44,"Digit9",30,"9",57,"VK_9",n,n],[0,45,"Digit0",21,"0",48,"VK_0",n,n],[1,46,"Enter",3,"Enter",13,"VK_RETURN",n,n],[1,47,"Escape",9,"Escape",27,"VK_ESCAPE",n,n],[1,48,"Backspace",1,"Backspace",8,"VK_BACK",n,n],[1,49,"Tab",2,"Tab",9,"VK_TAB",n,n],[1,50,"Space",10,"Space",32,"VK_SPACE",n,n],[0,51,"Minus",88,"-",189,"VK_OEM_MINUS","-","OEM_MINUS"],[0,52,"Equal",86,"=",187,"VK_OEM_PLUS","=","OEM_PLUS"],[0,53,"BracketLeft",92,"[",219,"VK_OEM_4","[","OEM_4"],[0,54,"BracketRight",94,"]",221,"VK_OEM_6","]","OEM_6"],[0,55,"Backslash",93,"\\",220,"VK_OEM_5","\\","OEM_5"],[0,56,"IntlHash",0,n,0,n,n,n],[0,57,"Semicolon",85,";",186,"VK_OEM_1",";","OEM_1"],[0,58,"Quote",95,"'",222,"VK_OEM_7","'","OEM_7"],[0,59,"Backquote",91,"`",192,"VK_OEM_3","`","OEM_3"],[0,60,"Comma",87,",",188,"VK_OEM_COMMA",",","OEM_COMMA"],[0,61,"Period",89,".",190,"VK_OEM_PERIOD",".","OEM_PERIOD"],[0,62,"Slash",90,"/",191,"VK_OEM_2","/","OEM_2"],[1,63,"CapsLock",8,"CapsLock",20,"VK_CAPITAL",n,n],[1,64,"F1",59,"F1",112,"VK_F1",n,n],[1,65,"F2",60,"F2",113,"VK_F2",n,n],[1,66,"F3",61,"F3",114,"VK_F3",n,n],[1,67,"F4",62,"F4",115,"VK_F4",n,n],[1,68,"F5",63,"F5",116,"VK_F5",n,n],[1,69,"F6",64,"F6",117,"VK_F6",n,n],[1,70,"F7",65,"F7",118,"VK_F7",n,n],[1,71,"F8",66,"F8",119,"VK_F8",n,n],[1,72,"F9",67,"F9",120,"VK_F9",n,n],[1,73,"F10",68,"F10",121,"VK_F10",n,n],[1,74,"F11",69,"F11",122,"VK_F11",n,n],[1,75,"F12",70,"F12",123,"VK_F12",n,n],[1,76,"PrintScreen",0,n,0,n,n,n],[1,77,"ScrollLock",84,"ScrollLock",145,"VK_SCROLL",n,n],[1,78,"Pause",7,"PauseBreak",19,"VK_PAUSE",n,n],[1,79,"Insert",19,"Insert",45,"VK_INSERT",n,n],[1,80,"Home",14,"Home",36,"VK_HOME",n,n],[1,81,"PageUp",11,"PageUp",33,"VK_PRIOR",n,n],[1,82,"Delete",20,"Delete",46,"VK_DELETE",n,n],[1,83,"End",13,"End",35,"VK_END",n,n],[1,84,"PageDown",12,"PageDown",34,"VK_NEXT",n,n],[1,85,"ArrowRight",17,"RightArrow",39,"VK_RIGHT","Right",n],[1,86,"ArrowLeft",15,"LeftArrow",37,"VK_LEFT","Left",n],[1,87,"ArrowDown",18,"DownArrow",40,"VK_DOWN","Down",n],[1,88,"ArrowUp",16,"UpArrow",38,"VK_UP","Up",n],[1,89,"NumLock",83,"NumLock",144,"VK_NUMLOCK",n,n],[1,90,"NumpadDivide",113,"NumPad_Divide",111,"VK_DIVIDE",n,n],[1,91,"NumpadMultiply",108,"NumPad_Multiply",106,"VK_MULTIPLY",n,n],[1,92,"NumpadSubtract",111,"NumPad_Subtract",109,"VK_SUBTRACT",n,n],[1,93,"NumpadAdd",109,"NumPad_Add",107,"VK_ADD",n,n],[1,94,"NumpadEnter",3,n,0,n,n,n],[1,95,"Numpad1",99,"NumPad1",97,"VK_NUMPAD1",n,n],[1,96,"Numpad2",100,"NumPad2",98,"VK_NUMPAD2",n,n],[1,97,"Numpad3",101,"NumPad3",99,"VK_NUMPAD3",n,n],[1,98,"Numpad4",102,"NumPad4",100,"VK_NUMPAD4",n,n],[1,99,"Numpad5",103,"NumPad5",101,"VK_NUMPAD5",n,n],[1,100,"Numpad6",104,"NumPad6",102,"VK_NUMPAD6",n,n],[1,101,"Numpad7",105,"NumPad7",103,"VK_NUMPAD7",n,n],[1,102,"Numpad8",106,"NumPad8",104,"VK_NUMPAD8",n,n],[1,103,"Numpad9",107,"NumPad9",105,"VK_NUMPAD9",n,n],[1,104,"Numpad0",98,"NumPad0",96,"VK_NUMPAD0",n,n],[1,105,"NumpadDecimal",112,"NumPad_Decimal",110,"VK_DECIMAL",n,n],[0,106,"IntlBackslash",97,"OEM_102",226,"VK_OEM_102",n,n],[1,107,"ContextMenu",58,"ContextMenu",93,n,n,n],[1,108,"Power",0,n,0,n,n,n],[1,109,"NumpadEqual",0,n,0,n,n,n],[1,110,"F13",71,"F13",124,"VK_F13",n,n],[1,111,"F14",72,"F14",125,"VK_F14",n,n],[1,112,"F15",73,"F15",126,"VK_F15",n,n],[1,113,"F16",74,"F16",127,"VK_F16",n,n],[1,114,"F17",75,"F17",128,"VK_F17",n,n],[1,115,"F18",76,"F18",129,"VK_F18",n,n],[1,116,"F19",77,"F19",130,"VK_F19",n,n],[1,117,"F20",78,"F20",131,"VK_F20",n,n],[1,118,"F21",79,"F21",132,"VK_F21",n,n],[1,119,"F22",80,"F22",133,"VK_F22",n,n],[1,120,"F23",81,"F23",134,"VK_F23",n,n],[1,121,"F24",82,"F24",135,"VK_F24",n,n],[1,122,"Open",0,n,0,n,n,n],[1,123,"Help",0,n,0,n,n,n],[1,124,"Select",0,n,0,n,n,n],[1,125,"Again",0,n,0,n,n,n],[1,126,"Undo",0,n,0,n,n,n],[1,127,"Cut",0,n,0,n,n,n],[1,128,"Copy",0,n,0,n,n,n],[1,129,"Paste",0,n,0,n,n,n],[1,130,"Find",0,n,0,n,n,n],[1,131,"AudioVolumeMute",117,"AudioVolumeMute",173,"VK_VOLUME_MUTE",n,n],[1,132,"AudioVolumeUp",118,"AudioVolumeUp",175,"VK_VOLUME_UP",n,n],[1,133,"AudioVolumeDown",119,"AudioVolumeDown",174,"VK_VOLUME_DOWN",n,n],[1,134,"NumpadComma",110,"NumPad_Separator",108,"VK_SEPARATOR",n,n],[0,135,"IntlRo",115,"ABNT_C1",193,"VK_ABNT_C1",n,n],[1,136,"KanaMode",0,n,0,n,n,n],[0,137,"IntlYen",0,n,0,n,n,n],[1,138,"Convert",0,n,0,n,n,n],[1,139,"NonConvert",0,n,0,n,n,n],[1,140,"Lang1",0,n,0,n,n,n],[1,141,"Lang2",0,n,0,n,n,n],[1,142,"Lang3",0,n,0,n,n,n],[1,143,"Lang4",0,n,0,n,n,n],[1,144,"Lang5",0,n,0,n,n,n],[1,145,"Abort",0,n,0,n,n,n],[1,146,"Props",0,n,0,n,n,n],[1,147,"NumpadParenLeft",0,n,0,n,n,n],[1,148,"NumpadParenRight",0,n,0,n,n,n],[1,149,"NumpadBackspace",0,n,0,n,n,n],[1,150,"NumpadMemoryStore",0,n,0,n,n,n],[1,151,"NumpadMemoryRecall",0,n,0,n,n,n],[1,152,"NumpadMemoryClear",0,n,0,n,n,n],[1,153,"NumpadMemoryAdd",0,n,0,n,n,n],[1,154,"NumpadMemorySubtract",0,n,0,n,n,n],[1,155,"NumpadClear",131,"Clear",12,"VK_CLEAR",n,n],[1,156,"NumpadClearEntry",0,n,0,n,n,n],[1,0,n,5,"Ctrl",17,"VK_CONTROL",n,n],[1,0,n,4,"Shift",16,"VK_SHIFT",n,n],[1,0,n,6,"Alt",18,"VK_MENU",n,n],[1,0,n,57,"Meta",91,"VK_COMMAND",n,n],[1,157,"ControlLeft",5,n,0,"VK_LCONTROL",n,n],[1,158,"ShiftLeft",4,n,0,"VK_LSHIFT",n,n],[1,159,"AltLeft",6,n,0,"VK_LMENU",n,n],[1,160,"MetaLeft",57,n,0,"VK_LWIN",n,n],[1,161,"ControlRight",5,n,0,"VK_RCONTROL",n,n],[1,162,"ShiftRight",4,n,0,"VK_RSHIFT",n,n],[1,163,"AltRight",6,n,0,"VK_RMENU",n,n],[1,164,"MetaRight",57,n,0,"VK_RWIN",n,n],[1,165,"BrightnessUp",0,n,0,n,n,n],[1,166,"BrightnessDown",0,n,0,n,n,n],[1,167,"MediaPlay",0,n,0,n,n,n],[1,168,"MediaRecord",0,n,0,n,n,n],[1,169,"MediaFastForward",0,n,0,n,n,n],[1,170,"MediaRewind",0,n,0,n,n,n],[1,171,"MediaTrackNext",124,"MediaTrackNext",176,"VK_MEDIA_NEXT_TRACK",n,n],[1,172,"MediaTrackPrevious",125,"MediaTrackPrevious",177,"VK_MEDIA_PREV_TRACK",n,n],[1,173,"MediaStop",126,"MediaStop",178,"VK_MEDIA_STOP",n,n],[1,174,"Eject",0,n,0,n,n,n],[1,175,"MediaPlayPause",127,"MediaPlayPause",179,"VK_MEDIA_PLAY_PAUSE",n,n],[1,176,"MediaSelect",128,"LaunchMediaPlayer",181,"VK_MEDIA_LAUNCH_MEDIA_SELECT",n,n],[1,177,"LaunchMail",129,"LaunchMail",180,"VK_MEDIA_LAUNCH_MAIL",n,n],[1,178,"LaunchApp2",130,"LaunchApp2",183,"VK_MEDIA_LAUNCH_APP2",n,n],[1,179,"LaunchApp1",0,n,0,"VK_MEDIA_LAUNCH_APP1",n,n],[1,180,"SelectTask",0,n,0,n,n,n],[1,181,"LaunchScreenSaver",0,n,0,n,n,n],[1,182,"BrowserSearch",120,"BrowserSearch",170,"VK_BROWSER_SEARCH",n,n],[1,183,"BrowserHome",121,"BrowserHome",172,"VK_BROWSER_HOME",n,n],[1,184,"BrowserBack",122,"BrowserBack",166,"VK_BROWSER_BACK",n,n],[1,185,"BrowserForward",123,"BrowserForward",167,"VK_BROWSER_FORWARD",n,n],[1,186,"BrowserStop",0,n,0,"VK_BROWSER_STOP",n,n],[1,187,"BrowserRefresh",0,n,0,"VK_BROWSER_REFRESH",n,n],[1,188,"BrowserFavorites",0,n,0,"VK_BROWSER_FAVORITES",n,n],[1,189,"ZoomToggle",0,n,0,n,n,n],[1,190,"MailReply",0,n,0,n,n,n],[1,191,"MailForward",0,n,0,n,n,n],[1,192,"MailSend",0,n,0,n,n,n],[1,0,n,114,"KeyInComposition",229,n,n,n],[1,0,n,116,"ABNT_C2",194,"VK_ABNT_C2",n,n],[1,0,n,96,"OEM_8",223,"VK_OEM_8",n,n],[1,0,n,0,n,0,"VK_KANA",n,n],[1,0,n,0,n,0,"VK_HANGUL",n,n],[1,0,n,0,n,0,"VK_JUNJA",n,n],[1,0,n,0,n,0,"VK_FINAL",n,n],[1,0,n,0,n,0,"VK_HANJA",n,n],[1,0,n,0,n,0,"VK_KANJI",n,n],[1,0,n,0,n,0,"VK_CONVERT",n,n],[1,0,n,0,n,0,"VK_NONCONVERT",n,n],[1,0,n,0,n,0,"VK_ACCEPT",n,n],[1,0,n,0,n,0,"VK_MODECHANGE",n,n],[1,0,n,0,n,0,"VK_SELECT",n,n],[1,0,n,0,n,0,"VK_PRINT",n,n],[1,0,n,0,n,0,"VK_EXECUTE",n,n],[1,0,n,0,n,0,"VK_SNAPSHOT",n,n],[1,0,n,0,n,0,"VK_HELP",n,n],[1,0,n,0,n,0,"VK_APPS",n,n],[1,0,n,0,n,0,"VK_PROCESSKEY",n,n],[1,0,n,0,n,0,"VK_PACKET",n,n],[1,0,n,0,n,0,"VK_DBE_SBCSCHAR",n,n],[1,0,n,0,n,0,"VK_DBE_DBCSCHAR",n,n],[1,0,n,0,n,0,"VK_ATTN",n,n],[1,0,n,0,n,0,"VK_CRSEL",n,n],[1,0,n,0,n,0,"VK_EXSEL",n,n],[1,0,n,0,n,0,"VK_EREOF",n,n],[1,0,n,0,n,0,"VK_PLAY",n,n],[1,0,n,0,n,0,"VK_ZOOM",n,n],[1,0,n,0,n,0,"VK_NONAME",n,n],[1,0,n,0,n,0,"VK_PA1",n,n],[1,0,n,0,n,0,"VK_OEM_CLEAR",n,n]],t=[],i=[];for(let o of e){let[r,s,a,l,c,d,u,h,f]=o;if(i[s]||(i[s]=!0,eot[s]=a,tot[a]=s,iot[a.toLowerCase()]=s,r&&(Z3[s]=l,l!==0&&l!==3&&l!==5&&l!==4&&l!==6&&l!==57&&(bne[l]=s))),!t[l]){if(t[l]=!0,!c)throw new Error(`String representation missing for key code ${l} around scan code ${a}`);Y3.define(l,c),gne.define(l,h||c),_ne.define(l,f||h||c)}d&&(vne[d]=l),u&&(Jnt[u]=l)}bne[3]=46})();(function(n){function e(a){return Y3.keyCodeToStr(a)}n.toString=e;function t(a){return Y3.strToKeyCode(a)}n.fromString=t;function i(a){return gne.keyCodeToStr(a)}n.toUserSettingsUS=i;function o(a){return _ne.keyCodeToStr(a)}n.toUserSettingsGeneral=o;function r(a){return gne.strToKeyCode(a)||_ne.strToKeyCode(a)}n.fromUserSettings=r;function s(a){if(a>=98&&a<=113)return null;switch(a){case 16:return"Up";case 18:return"Down";case 15:return"Left";case 17:return"Right"}return Y3.keyCodeToStr(a)}n.toElectronAccelerator=s})(hf||(hf={}))});var Xk,xne,BR,WR,mTe,wne=k(()=>{Bt();xne=globalThis.vscode;if(typeof xne<"u"&&typeof xne.process<"u"){let n=xne.process;Xk={get platform(){return n.platform},get arch(){return n.arch},get env(){return n.env},cwd(){return n.cwd()}}}else typeof process<"u"&&typeof process?.versions?.node=="string"?Xk={get platform(){return process.platform},get arch(){return process.arch},get env(){return process.env},cwd(){return process.env.VSCODE_CWD||process.cwd()}}:Xk={get platform(){return kn?"win32":dt?"darwin":"linux"},get arch(){},get env(){return{}},cwd(){return"/"}};BR=Xk.cwd,WR=Xk.env,mTe=Xk.platform});function cot(n,e){if(n===null||typeof n!="object")throw new X3(e,"Object",n)}function Ls(n,e){if(typeof n!="string")throw new X3(e,"string",n)}function rn(n){return n===Ll||n===fu}function yne(n){return n===Ll}function ux(n){return n>=oot&&n<=sot||n>=rot&&n<=aot}function Q3(n,e,t,i){let o="",r=0,s=-1,a=0,l=0;for(let c=0;c<=n.length;++c){if(c2){let d=o.lastIndexOf(t);d===-1?(o="",r=0):(o=o.slice(0,d),r=o.length-1-o.lastIndexOf(t)),s=c,a=0;continue}else if(o.length!==0){o="",r=0,s=c,a=0;continue}}e&&(o+=o.length>0?`${t}..`:"..",r=2)}else o.length>0?o+=`${t}${n.slice(s+1,c)}`:o=n.slice(s+1,c),r=c-s-1;s=c,a=0}else l===hx&&a!==-1?++a:a=-1}return o}function dot(n){return n?`${n[0]==="."?"":"."}${n}`:""}function gTe(n,e){cot(e,"pathObject");let t=e.dir||e.root,i=e.base||`${e.name||""}${dot(e.ext)}`;return t?t===e.root?`${t}${i}`:`${t}${n}${i}`:i}var oot,rot,sot,aot,hx,Ll,fu,dx,lot,X3,F_,ic,uot,eo,J3,_Te,bTe,vTe,e8,ff,xTe,Cd,sp=k(()=>{wne();oot=65,rot=97,sot=90,aot=122,hx=46,Ll=47,fu=92,dx=58,lot=63,X3=class extends Error{constructor(e,t,i){let o;typeof t=="string"&&t.indexOf("not ")===0?(o="must not be",t=t.replace(/^not /,"")):o="must be";let r=e.indexOf(".")!==-1?"property":"argument",s=`The "${e}" ${r} ${o} of type ${t}`;s+=`. Received type ${typeof i}`,super(s),this.code="ERR_INVALID_ARG_TYPE"}};F_=mTe==="win32";ic={resolve(...n){let e="",t="",i=!1;for(let o=n.length-1;o>=-1;o--){let r;if(o>=0){if(r=n[o],Ls(r,`paths[${o}]`),r.length===0)continue}else e.length===0?r=BR():(r=WR[`=${e}`]||BR(),(r===void 0||r.slice(0,2).toLowerCase()!==e.toLowerCase()&&r.charCodeAt(2)===fu)&&(r=`${e}\\`));let s=r.length,a=0,l="",c=!1,d=r.charCodeAt(0);if(s===1)rn(d)&&(a=1,c=!0);else if(rn(d))if(c=!0,rn(r.charCodeAt(1))){let u=2,h=u;for(;u2&&rn(r.charCodeAt(2))&&(c=!0,a=3));if(l.length>0)if(e.length>0){if(l.toLowerCase()!==e.toLowerCase())continue}else e=l;if(i){if(e.length>0)break}else if(t=`${r.slice(a)}\\${t}`,i=c,c&&e.length>0)break}return t=Q3(t,!i,"\\",rn),i?`${e}\\${t}`:`${e}${t}`||"."},normalize(n){Ls(n,"path");let e=n.length;if(e===0)return".";let t=0,i,o=!1,r=n.charCodeAt(0);if(e===1)return yne(r)?"\\":n;if(rn(r))if(o=!0,rn(n.charCodeAt(1))){let a=2,l=a;for(;a2&&rn(n.charCodeAt(2))&&(o=!0,t=3));let s=t0&&rn(n.charCodeAt(e-1))&&(s+="\\"),i===void 0?o?`\\${s}`:s:o?`${i}\\${s}`:`${i}${s}`},isAbsolute(n){Ls(n,"path");let e=n.length;if(e===0)return!1;let t=n.charCodeAt(0);return rn(t)||e>2&&ux(t)&&n.charCodeAt(1)===dx&&rn(n.charCodeAt(2))},join(...n){if(n.length===0)return".";let e,t;for(let r=0;r0&&(e===void 0?e=t=s:e+=`\\${s}`)}if(e===void 0)return".";let i=!0,o=0;if(typeof t=="string"&&rn(t.charCodeAt(0))){++o;let r=t.length;r>1&&rn(t.charCodeAt(1))&&(++o,r>2&&(rn(t.charCodeAt(2))?++o:i=!1))}if(i){for(;o=2&&(e=`\\${e.slice(o)}`)}return ic.normalize(e)},relative(n,e){if(Ls(n,"from"),Ls(e,"to"),n===e)return"";let t=ic.resolve(n),i=ic.resolve(e);if(t===i||(n=t.toLowerCase(),e=i.toLowerCase(),n===e))return"";let o=0;for(;oo&&n.charCodeAt(r-1)===fu;)r--;let s=r-o,a=0;for(;aa&&e.charCodeAt(l-1)===fu;)l--;let c=l-a,d=sd){if(e.charCodeAt(a+h)===fu)return i.slice(a+h+1);if(h===2)return i.slice(a+h)}s>d&&(n.charCodeAt(o+h)===fu?u=h:h===2&&(u=3)),u===-1&&(u=0)}let f="";for(h=o+u+1;h<=r;++h)(h===r||n.charCodeAt(h)===fu)&&(f+=f.length===0?"..":"\\..");return a+=u,f.length>0?`${f}${i.slice(a,l)}`:(i.charCodeAt(a)===fu&&++a,i.slice(a,l))},toNamespacedPath(n){if(typeof n!="string"||n.length===0)return n;let e=ic.resolve(n);if(e.length<=2)return n;if(e.charCodeAt(0)===fu){if(e.charCodeAt(1)===fu){let t=e.charCodeAt(2);if(t!==lot&&t!==hx)return`\\\\?\\UNC\\${e.slice(2)}`}}else if(ux(e.charCodeAt(0))&&e.charCodeAt(1)===dx&&e.charCodeAt(2)===fu)return`\\\\?\\${e}`;return n},dirname(n){Ls(n,"path");let e=n.length;if(e===0)return".";let t=-1,i=0,o=n.charCodeAt(0);if(e===1)return rn(o)?n:".";if(rn(o)){if(t=i=1,rn(n.charCodeAt(1))){let a=2,l=a;for(;a2&&rn(n.charCodeAt(2))?3:2,i=t);let r=-1,s=!0;for(let a=e-1;a>=i;--a)if(rn(n.charCodeAt(a))){if(!s){r=a;break}}else s=!1;if(r===-1){if(t===-1)return".";r=t}return n.slice(0,r)},basename(n,e){e!==void 0&&Ls(e,"suffix"),Ls(n,"path");let t=0,i=-1,o=!0,r;if(n.length>=2&&ux(n.charCodeAt(0))&&n.charCodeAt(1)===dx&&(t=2),e!==void 0&&e.length>0&&e.length<=n.length){if(e===n)return"";let s=e.length-1,a=-1;for(r=n.length-1;r>=t;--r){let l=n.charCodeAt(r);if(rn(l)){if(!o){t=r+1;break}}else a===-1&&(o=!1,a=r+1),s>=0&&(l===e.charCodeAt(s)?--s===-1&&(i=r):(s=-1,i=a))}return t===i?i=a:i===-1&&(i=n.length),n.slice(t,i)}for(r=n.length-1;r>=t;--r)if(rn(n.charCodeAt(r))){if(!o){t=r+1;break}}else i===-1&&(o=!1,i=r+1);return i===-1?"":n.slice(t,i)},extname(n){Ls(n,"path");let e=0,t=-1,i=0,o=-1,r=!0,s=0;n.length>=2&&n.charCodeAt(1)===dx&&ux(n.charCodeAt(0))&&(e=i=2);for(let a=n.length-1;a>=e;--a){let l=n.charCodeAt(a);if(rn(l)){if(!r){i=a+1;break}continue}o===-1&&(r=!1,o=a+1),l===hx?t===-1?t=a:s!==1&&(s=1):t!==-1&&(s=-1)}return t===-1||o===-1||s===0||s===1&&t===o-1&&t===i+1?"":n.slice(t,o)},format:gTe.bind(null,"\\"),parse(n){Ls(n,"path");let e={root:"",dir:"",base:"",ext:"",name:""};if(n.length===0)return e;let t=n.length,i=0,o=n.charCodeAt(0);if(t===1)return rn(o)?(e.root=e.dir=n,e):(e.base=e.name=n,e);if(rn(o)){if(i=1,rn(n.charCodeAt(1))){let u=2,h=u;for(;u0&&(e.root=n.slice(0,i));let r=-1,s=i,a=-1,l=!0,c=n.length-1,d=0;for(;c>=i;--c){if(o=n.charCodeAt(c),rn(o)){if(!l){s=c+1;break}continue}a===-1&&(l=!1,a=c+1),o===hx?r===-1?r=c:d!==1&&(d=1):r!==-1&&(d=-1)}return a!==-1&&(r===-1||d===0||d===1&&r===a-1&&r===s+1?e.base=e.name=n.slice(s,a):(e.name=n.slice(s,r),e.base=n.slice(s,a),e.ext=n.slice(r,a))),s>0&&s!==i?e.dir=n.slice(0,s-1):e.dir=e.root,e},sep:"\\",delimiter:";",win32:null,posix:null},uot=(()=>{if(F_){let n=/\\/g;return()=>{let e=BR().replace(n,"/");return e.slice(e.indexOf("/"))}}return()=>BR()})(),eo={resolve(...n){let e="",t=!1;for(let i=n.length-1;i>=-1&&!t;i--){let o=i>=0?n[i]:uot();Ls(o,`paths[${i}]`),o.length!==0&&(e=`${o}/${e}`,t=o.charCodeAt(0)===Ll)}return e=Q3(e,!t,"/",yne),t?`/${e}`:e.length>0?e:"."},normalize(n){if(Ls(n,"path"),n.length===0)return".";let e=n.charCodeAt(0)===Ll,t=n.charCodeAt(n.length-1)===Ll;return n=Q3(n,!e,"/",yne),n.length===0?e?"/":t?"./":".":(t&&(n+="/"),e?`/${n}`:n)},isAbsolute(n){return Ls(n,"path"),n.length>0&&n.charCodeAt(0)===Ll},join(...n){if(n.length===0)return".";let e;for(let t=0;t0&&(e===void 0?e=i:e+=`/${i}`)}return e===void 0?".":eo.normalize(e)},relative(n,e){if(Ls(n,"from"),Ls(e,"to"),n===e||(n=eo.resolve(n),e=eo.resolve(e),n===e))return"";let t=1,i=n.length,o=i-t,r=1,s=e.length-r,a=oa){if(e.charCodeAt(r+c)===Ll)return e.slice(r+c+1);if(c===0)return e.slice(r+c)}else o>a&&(n.charCodeAt(t+c)===Ll?l=c:c===0&&(l=0));let d="";for(c=t+l+1;c<=i;++c)(c===i||n.charCodeAt(c)===Ll)&&(d+=d.length===0?"..":"/..");return`${d}${e.slice(r+l)}`},toNamespacedPath(n){return n},dirname(n){if(Ls(n,"path"),n.length===0)return".";let e=n.charCodeAt(0)===Ll,t=-1,i=!0;for(let o=n.length-1;o>=1;--o)if(n.charCodeAt(o)===Ll){if(!i){t=o;break}}else i=!1;return t===-1?e?"/":".":e&&t===1?"//":n.slice(0,t)},basename(n,e){e!==void 0&&Ls(e,"ext"),Ls(n,"path");let t=0,i=-1,o=!0,r;if(e!==void 0&&e.length>0&&e.length<=n.length){if(e===n)return"";let s=e.length-1,a=-1;for(r=n.length-1;r>=0;--r){let l=n.charCodeAt(r);if(l===Ll){if(!o){t=r+1;break}}else a===-1&&(o=!1,a=r+1),s>=0&&(l===e.charCodeAt(s)?--s===-1&&(i=r):(s=-1,i=a))}return t===i?i=a:i===-1&&(i=n.length),n.slice(t,i)}for(r=n.length-1;r>=0;--r)if(n.charCodeAt(r)===Ll){if(!o){t=r+1;break}}else i===-1&&(o=!1,i=r+1);return i===-1?"":n.slice(t,i)},extname(n){Ls(n,"path");let e=-1,t=0,i=-1,o=!0,r=0;for(let s=n.length-1;s>=0;--s){let a=n.charCodeAt(s);if(a===Ll){if(!o){t=s+1;break}continue}i===-1&&(o=!1,i=s+1),a===hx?e===-1?e=s:r!==1&&(r=1):e!==-1&&(r=-1)}return e===-1||i===-1||r===0||r===1&&e===i-1&&e===t+1?"":n.slice(e,i)},format:gTe.bind(null,"/"),parse(n){Ls(n,"path");let e={root:"",dir:"",base:"",ext:"",name:""};if(n.length===0)return e;let t=n.charCodeAt(0)===Ll,i;t?(e.root="/",i=1):i=0;let o=-1,r=0,s=-1,a=!0,l=n.length-1,c=0;for(;l>=i;--l){let d=n.charCodeAt(l);if(d===Ll){if(!a){r=l+1;break}continue}s===-1&&(a=!1,s=l+1),d===hx?o===-1?o=l:c!==1&&(c=1):o!==-1&&(c=-1)}if(s!==-1){let d=r===0&&t?1:r;o===-1||c===0||c===1&&o===s-1&&o===r+1?e.base=e.name=n.slice(d,s):(e.name=n.slice(d,o),e.base=n.slice(d,s),e.ext=n.slice(o,s))}return r>0?e.dir=n.slice(0,r-1):t&&(e.dir="/"),e},sep:"/",delimiter:":",win32:null,posix:null};eo.win32=ic.win32=ic;eo.posix=ic.posix=eo;J3=F_?ic.normalize:eo.normalize,_Te=F_?ic.join:eo.join,bTe=F_?ic.resolve:eo.resolve,vTe=F_?ic.relative:eo.relative,e8=F_?ic.dirname:eo.dirname,ff=F_?ic.basename:eo.basename,xTe=F_?ic.extname:eo.extname,Cd=F_?ic.sep:eo.sep});function mot(n,e){if(!n.scheme&&e)throw new Error(`[UriError]: Scheme is missing: {scheme: "", authority: "${n.authority}", path: "${n.path}", query: "${n.query}", fragment: "${n.fragment}"}`);if(n.scheme&&!hot.test(n.scheme))throw new Error("[UriError]: Scheme contains illegal characters.");if(n.path){if(n.authority){if(!fot.test(n.path))throw new Error('[UriError]: If a URI contains an authority component, then the path component must either be empty or begin with a slash ("/") character')}else if(pot.test(n.path))throw new Error('[UriError]: If a URI does not contain an authority component, then the path cannot begin with two slash characters ("//")')}}function got(n,e){return!n&&!e?"file":n}function _ot(n,e){switch(n){case"https":case"http":case"file":e?e[0]!==ap&&(e=ap+e):e=ap;break}return e}function wTe(n,e,t){let i,o=-1;for(let r=0;r=97&&s<=122||s>=65&&s<=90||s>=48&&s<=57||s===45||s===46||s===95||s===126||e&&s===47||t&&s===91||t&&s===93||t&&s===58)o!==-1&&(i+=encodeURIComponent(n.substring(o,r)),o=-1),i!==void 0&&(i+=n.charAt(r));else{i===void 0&&(i=n.substr(0,r));let a=STe[s];a!==void 0?(o!==-1&&(i+=encodeURIComponent(n.substring(o,r)),o=-1),i+=a):o===-1&&(o=r)}}return o!==-1&&(i+=encodeURIComponent(n.substring(o))),i!==void 0?i:n}function vot(n){let e;for(let t=0;t1&&n.scheme==="file"?t=`//${n.authority}${n.path}`:n.path.charCodeAt(0)===47&&(n.path.charCodeAt(1)>=65&&n.path.charCodeAt(1)<=90||n.path.charCodeAt(1)>=97&&n.path.charCodeAt(1)<=122)&&n.path.charCodeAt(2)===58?e?t=n.path.substr(1):t=n.path[1].toLowerCase()+n.path.substr(2):t=n.path,kn&&(t=t.replace(/\//g,"\\")),t}function Cne(n,e){let t=e?vot:wTe,i="",{scheme:o,authority:r,path:s,query:a,fragment:l}=n;if(o&&(i+=o,i+=":"),(r||o==="file")&&(i+=ap,i+=ap),r){let c=r.indexOf("@");if(c!==-1){let d=r.substr(0,c);r=r.substr(c+1),c=d.lastIndexOf(":"),c===-1?i+=t(d,!1,!1):(i+=t(d.substr(0,c),!1,!1),i+=":",i+=t(d.substr(c+1),!1,!0)),i+="@"}r=r.toLowerCase(),c=r.lastIndexOf(":"),c===-1?i+=t(r,!1,!0):(i+=t(r.substr(0,c),!1,!0),i+=r.substr(c))}if(s){if(s.length>=3&&s.charCodeAt(0)===47&&s.charCodeAt(2)===58){let c=s.charCodeAt(1);c>=65&&c<=90&&(s=`/${String.fromCharCode(c+32)}:${s.substr(3)}`)}else if(s.length>=2&&s.charCodeAt(1)===58){let c=s.charCodeAt(0);c>=65&&c<=90&&(s=`${String.fromCharCode(c+32)}:${s.substr(2)}`)}i+=t(s,!0,!1)}return a&&(i+="?",i+=t(a,!1,!1)),l&&(i+="#",i+=e?l:wTe(l,!1,!1)),i}function kTe(n){try{return decodeURIComponent(n)}catch{return n.length>3?n.substr(0,3)+kTe(n.substr(3)):n}}function i8(n){return n.match(yTe)?n.replace(yTe,e=>kTe(e)):n}var hot,fot,pot,nr,ap,bot,Ee,CTe,fx,STe,yTe,Ai=k(()=>{sp();Bt();hot=/^\w[\w\d+.-]*$/,fot=/^\//,pot=/^\/\//;nr="",ap="/",bot=/^(([^:/?#]+?):)?(\/\/([^/?#]*))?([^?#]*)(\?([^#]*))?(#(.*))?/,Ee=class n{static isUri(e){return e instanceof n?!0:e?typeof e.authority=="string"&&typeof e.fragment=="string"&&typeof e.path=="string"&&typeof e.query=="string"&&typeof e.scheme=="string"&&typeof e.fsPath=="string"&&typeof e.with=="function"&&typeof e.toString=="function":!1}constructor(e,t,i,o,r,s=!1){typeof e=="object"?(this.scheme=e.scheme||nr,this.authority=e.authority||nr,this.path=e.path||nr,this.query=e.query||nr,this.fragment=e.fragment||nr):(this.scheme=got(e,s),this.authority=t||nr,this.path=_ot(this.scheme,i||nr),this.query=o||nr,this.fragment=r||nr,mot(this,s))}get fsPath(){return HR(this,!1)}with(e){if(!e)return this;let{scheme:t,authority:i,path:o,query:r,fragment:s}=e;return t===void 0?t=this.scheme:t===null&&(t=nr),i===void 0?i=this.authority:i===null&&(i=nr),o===void 0?o=this.path:o===null&&(o=nr),r===void 0?r=this.query:r===null&&(r=nr),s===void 0?s=this.fragment:s===null&&(s=nr),t===this.scheme&&i===this.authority&&o===this.path&&r===this.query&&s===this.fragment?this:new fx(t,i,o,r,s)}static parse(e,t=!1){let i=bot.exec(e);return i?new fx(i[2]||nr,i8(i[4]||nr),i8(i[5]||nr),i8(i[7]||nr),i8(i[9]||nr),t):new fx(nr,nr,nr,nr,nr)}static file(e){let t=nr;if(kn&&(e=e.replace(/\\/g,ap)),e[0]===ap&&e[1]===ap){let i=e.indexOf(ap,2);i===-1?(t=e.substring(2),e=ap):(t=e.substring(2,i),e=e.substring(i)||ap)}return new fx("file",t,e,nr,nr)}static from(e,t){return new fx(e.scheme,e.authority,e.path,e.query,e.fragment,t)}static joinPath(e,...t){if(!e.path)throw new Error("[UriError]: cannot call joinPath on URI without path");let i;return kn&&e.scheme==="file"?i=n.file(ic.join(HR(e,!0),...t)).path:i=eo.join(e.path,...t),e.with({path:i})}toString(e=!1){return Cne(this,e)}toJSON(){return this}static revive(e){if(e){if(e instanceof n)return e;{let t=new fx(e);return t._formatted=e.external??null,t._fsPath=e._sep===CTe?e.fsPath??null:null,t}}else return e}},CTe=kn?1:void 0,fx=class extends Ee{constructor(){super(...arguments),this._formatted=null,this._fsPath=null}get fsPath(){return this._fsPath||(this._fsPath=HR(this,!1)),this._fsPath}toString(e=!1){return e?Cne(this,!0):(this._formatted||(this._formatted=Cne(this,!1)),this._formatted)}toJSON(){let e={$mid:1};return this._fsPath&&(e.fsPath=this._fsPath,e._sep=CTe),this._formatted&&(e.external=this._formatted),this.path&&(e.path=this.path),this.scheme&&(e.scheme=this.scheme),this.authority&&(e.authority=this.authority),this.query&&(e.query=this.query),this.fragment&&(e.fragment=this.fragment),e}},STe={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"};yTe=/(%[0-9A-Za-z][0-9A-Za-z])+/g});var P,qe=k(()=>{P=class n{constructor(e,t){this.lineNumber=e,this.column=t}with(e=this.lineNumber,t=this.column){return e===this.lineNumber&&t===this.column?this:new n(e,t)}delta(e=0,t=0){return this.with(this.lineNumber+e,this.column+t)}equals(e){return n.equals(this,e)}static equals(e,t){return!e&&!t?!0:!!e&&!!t&&e.lineNumber===t.lineNumber&&e.column===t.column}isBefore(e){return n.isBefore(this,e)}static isBefore(e,t){return e.lineNumber{qe();S=class n{constructor(e,t,i,o){e>i||e===i&&t>o?(this.startLineNumber=i,this.startColumn=o,this.endLineNumber=e,this.endColumn=t):(this.startLineNumber=e,this.startColumn=t,this.endLineNumber=i,this.endColumn=o)}isEmpty(){return n.isEmpty(this)}static isEmpty(e){return e.startLineNumber===e.endLineNumber&&e.startColumn===e.endColumn}containsPosition(e){return n.containsPosition(this,e)}static containsPosition(e,t){return!(t.lineNumbere.endLineNumber||t.lineNumber===e.startLineNumber&&t.columne.endColumn)}static strictContainsPosition(e,t){return!(t.lineNumbere.endLineNumber||t.lineNumber===e.startLineNumber&&t.column<=e.startColumn||t.lineNumber===e.endLineNumber&&t.column>=e.endColumn)}containsRange(e){return n.containsRange(this,e)}static containsRange(e,t){return!(t.startLineNumbere.endLineNumber||t.endLineNumber>e.endLineNumber||t.startLineNumber===e.startLineNumber&&t.startColumne.endColumn)}strictContainsRange(e){return n.strictContainsRange(this,e)}static strictContainsRange(e,t){return!(t.startLineNumbere.endLineNumber||t.endLineNumber>e.endLineNumber||t.startLineNumber===e.startLineNumber&&t.startColumn<=e.startColumn||t.endLineNumber===e.endLineNumber&&t.endColumn>=e.endColumn)}plusRange(e){return n.plusRange(this,e)}static plusRange(e,t){let i,o,r,s;return t.startLineNumbere.endLineNumber?(r=t.endLineNumber,s=t.endColumn):t.endLineNumber===e.endLineNumber?(r=t.endLineNumber,s=Math.max(t.endColumn,e.endColumn)):(r=e.endLineNumber,s=e.endColumn),new n(i,o,r,s)}intersectRanges(e){return n.intersectRanges(this,e)}static intersectRanges(e,t){let i=e.startLineNumber,o=e.startColumn,r=e.endLineNumber,s=e.endColumn,a=t.startLineNumber,l=t.startColumn,c=t.endLineNumber,d=t.endColumn;return ic?(r=c,s=d):r===c&&(s=Math.min(s,d)),i>r||i===r&&o>s?null:new n(i,o,r,s)}equalsRange(e){return n.equalsRange(this,e)}static equalsRange(e,t){return!e&&!t?!0:!!e&&!!t&&e.startLineNumber===t.startLineNumber&&e.startColumn===t.startColumn&&e.endLineNumber===t.endLineNumber&&e.endColumn===t.endColumn}getEndPosition(){return n.getEndPosition(this)}static getEndPosition(e){return new P(e.endLineNumber,e.endColumn)}getStartPosition(){return n.getStartPosition(this)}static getStartPosition(e){return new P(e.startLineNumber,e.startColumn)}toString(){return"["+this.startLineNumber+","+this.startColumn+" -> "+this.endLineNumber+","+this.endColumn+"]"}setEndPosition(e,t){return new n(this.startLineNumber,this.startColumn,e,t)}setStartPosition(e,t){return new n(e,t,this.endLineNumber,this.endColumn)}collapseToStart(){return n.collapseToStart(this)}static collapseToStart(e){return new n(e.startLineNumber,e.startColumn,e.startLineNumber,e.startColumn)}collapseToEnd(){return n.collapseToEnd(this)}static collapseToEnd(e){return new n(e.endLineNumber,e.endColumn,e.endLineNumber,e.endColumn)}delta(e){return new n(this.startLineNumber+e,this.startColumn,this.endLineNumber+e,this.endColumn)}static fromPositions(e,t=e){return new n(e.lineNumber,e.column,t.lineNumber,t.column)}static lift(e){return e?new n(e.startLineNumber,e.startColumn,e.endLineNumber,e.endColumn):null}static isIRange(e){return e&&typeof e.startLineNumber=="number"&&typeof e.startColumn=="number"&&typeof e.endLineNumber=="number"&&typeof e.endColumn=="number"}static areIntersectingOrTouching(e,t){return!(e.endLineNumbere.startLineNumber}toJSON(){return this}}});var Se,Ui=k(()=>{qe();we();Se=class n extends S{constructor(e,t,i,o){super(e,t,i,o),this.selectionStartLineNumber=e,this.selectionStartColumn=t,this.positionLineNumber=i,this.positionColumn=o}toString(){return"["+this.selectionStartLineNumber+","+this.selectionStartColumn+" -> "+this.positionLineNumber+","+this.positionColumn+"]"}equalsSelection(e){return n.selectionsEqual(this,e)}static selectionsEqual(e,t){return e.selectionStartLineNumber===t.selectionStartLineNumber&&e.selectionStartColumn===t.selectionStartColumn&&e.positionLineNumber===t.positionLineNumber&&e.positionColumn===t.positionColumn}getDirection(){return this.selectionStartLineNumber===this.startLineNumber&&this.selectionStartColumn===this.startColumn?0:1}setEndPosition(e,t){return this.getDirection()===0?new n(this.startLineNumber,this.startColumn,e,t):new n(e,t,this.startLineNumber,this.startColumn)}getPosition(){return new P(this.positionLineNumber,this.positionColumn)}getSelectionStart(){return new P(this.selectionStartLineNumber,this.selectionStartColumn)}setStartPosition(e,t){return this.getDirection()===0?new n(e,t,this.endLineNumber,this.endColumn):new n(this.endLineNumber,this.endColumn,e,t)}static fromPositions(e,t=e){return new n(e.lineNumber,e.column,t.lineNumber,t.column)}static fromRange(e,t){return t===0?new n(e.startLineNumber,e.startColumn,e.endLineNumber,e.endColumn):new n(e.endLineNumber,e.endColumn,e.startLineNumber,e.startColumn)}static liftSelection(e){return new n(e.selectionStartLineNumber,e.selectionStartColumn,e.positionLineNumber,e.positionColumn)}static selectionsArrEqual(e,t){if(e&&!t||!e&&t)return!1;if(!e&&!t)return!0;if(e.length!==t.length)return!1;for(let i=0,o=e.length;i{yi();Sne=Object.create(null)});var LTe,ITe=k(()=>{zR();LTe={add:I("add",6e4),plus:I("plus",6e4),gistNew:I("gist-new",6e4),repoCreate:I("repo-create",6e4),lightbulb:I("lightbulb",60001),lightBulb:I("light-bulb",60001),repo:I("repo",60002),repoDelete:I("repo-delete",60002),gistFork:I("gist-fork",60003),repoForked:I("repo-forked",60003),gitPullRequest:I("git-pull-request",60004),gitPullRequestAbandoned:I("git-pull-request-abandoned",60004),recordKeys:I("record-keys",60005),keyboard:I("keyboard",60005),tag:I("tag",60006),gitPullRequestLabel:I("git-pull-request-label",60006),tagAdd:I("tag-add",60006),tagRemove:I("tag-remove",60006),person:I("person",60007),personFollow:I("person-follow",60007),personOutline:I("person-outline",60007),personFilled:I("person-filled",60007),gitBranch:I("git-branch",60008),gitBranchCreate:I("git-branch-create",60008),gitBranchDelete:I("git-branch-delete",60008),sourceControl:I("source-control",60008),mirror:I("mirror",60009),mirrorPublic:I("mirror-public",60009),star:I("star",60010),starAdd:I("star-add",60010),starDelete:I("star-delete",60010),starEmpty:I("star-empty",60010),comment:I("comment",60011),commentAdd:I("comment-add",60011),alert:I("alert",60012),warning:I("warning",60012),search:I("search",60013),searchSave:I("search-save",60013),logOut:I("log-out",60014),signOut:I("sign-out",60014),logIn:I("log-in",60015),signIn:I("sign-in",60015),eye:I("eye",60016),eyeUnwatch:I("eye-unwatch",60016),eyeWatch:I("eye-watch",60016),circleFilled:I("circle-filled",60017),primitiveDot:I("primitive-dot",60017),closeDirty:I("close-dirty",60017),debugBreakpoint:I("debug-breakpoint",60017),debugBreakpointDisabled:I("debug-breakpoint-disabled",60017),debugHint:I("debug-hint",60017),terminalDecorationSuccess:I("terminal-decoration-success",60017),primitiveSquare:I("primitive-square",60018),edit:I("edit",60019),pencil:I("pencil",60019),info:I("info",60020),issueOpened:I("issue-opened",60020),gistPrivate:I("gist-private",60021),gitForkPrivate:I("git-fork-private",60021),lock:I("lock",60021),mirrorPrivate:I("mirror-private",60021),close:I("close",60022),removeClose:I("remove-close",60022),x:I("x",60022),repoSync:I("repo-sync",60023),sync:I("sync",60023),clone:I("clone",60024),desktopDownload:I("desktop-download",60024),beaker:I("beaker",60025),microscope:I("microscope",60025),vm:I("vm",60026),deviceDesktop:I("device-desktop",60026),file:I("file",60027),fileText:I("file-text",60027),more:I("more",60028),ellipsis:I("ellipsis",60028),kebabHorizontal:I("kebab-horizontal",60028),mailReply:I("mail-reply",60029),reply:I("reply",60029),organization:I("organization",60030),organizationFilled:I("organization-filled",60030),organizationOutline:I("organization-outline",60030),newFile:I("new-file",60031),fileAdd:I("file-add",60031),newFolder:I("new-folder",60032),fileDirectoryCreate:I("file-directory-create",60032),trash:I("trash",60033),trashcan:I("trashcan",60033),history:I("history",60034),clock:I("clock",60034),folder:I("folder",60035),fileDirectory:I("file-directory",60035),symbolFolder:I("symbol-folder",60035),logoGithub:I("logo-github",60036),markGithub:I("mark-github",60036),github:I("github",60036),terminal:I("terminal",60037),console:I("console",60037),repl:I("repl",60037),zap:I("zap",60038),symbolEvent:I("symbol-event",60038),error:I("error",60039),stop:I("stop",60039),variable:I("variable",60040),symbolVariable:I("symbol-variable",60040),array:I("array",60042),symbolArray:I("symbol-array",60042),symbolModule:I("symbol-module",60043),symbolPackage:I("symbol-package",60043),symbolNamespace:I("symbol-namespace",60043),symbolObject:I("symbol-object",60043),symbolMethod:I("symbol-method",60044),symbolFunction:I("symbol-function",60044),symbolConstructor:I("symbol-constructor",60044),symbolBoolean:I("symbol-boolean",60047),symbolNull:I("symbol-null",60047),symbolNumeric:I("symbol-numeric",60048),symbolNumber:I("symbol-number",60048),symbolStructure:I("symbol-structure",60049),symbolStruct:I("symbol-struct",60049),symbolParameter:I("symbol-parameter",60050),symbolTypeParameter:I("symbol-type-parameter",60050),symbolKey:I("symbol-key",60051),symbolText:I("symbol-text",60051),symbolReference:I("symbol-reference",60052),goToFile:I("go-to-file",60052),symbolEnum:I("symbol-enum",60053),symbolValue:I("symbol-value",60053),symbolRuler:I("symbol-ruler",60054),symbolUnit:I("symbol-unit",60054),activateBreakpoints:I("activate-breakpoints",60055),archive:I("archive",60056),arrowBoth:I("arrow-both",60057),arrowDown:I("arrow-down",60058),arrowLeft:I("arrow-left",60059),arrowRight:I("arrow-right",60060),arrowSmallDown:I("arrow-small-down",60061),arrowSmallLeft:I("arrow-small-left",60062),arrowSmallRight:I("arrow-small-right",60063),arrowSmallUp:I("arrow-small-up",60064),arrowUp:I("arrow-up",60065),bell:I("bell",60066),bold:I("bold",60067),book:I("book",60068),bookmark:I("bookmark",60069),debugBreakpointConditionalUnverified:I("debug-breakpoint-conditional-unverified",60070),debugBreakpointConditional:I("debug-breakpoint-conditional",60071),debugBreakpointConditionalDisabled:I("debug-breakpoint-conditional-disabled",60071),debugBreakpointDataUnverified:I("debug-breakpoint-data-unverified",60072),debugBreakpointData:I("debug-breakpoint-data",60073),debugBreakpointDataDisabled:I("debug-breakpoint-data-disabled",60073),debugBreakpointLogUnverified:I("debug-breakpoint-log-unverified",60074),debugBreakpointLog:I("debug-breakpoint-log",60075),debugBreakpointLogDisabled:I("debug-breakpoint-log-disabled",60075),briefcase:I("briefcase",60076),broadcast:I("broadcast",60077),browser:I("browser",60078),bug:I("bug",60079),calendar:I("calendar",60080),caseSensitive:I("case-sensitive",60081),check:I("check",60082),checklist:I("checklist",60083),chevronDown:I("chevron-down",60084),chevronLeft:I("chevron-left",60085),chevronRight:I("chevron-right",60086),chevronUp:I("chevron-up",60087),chromeClose:I("chrome-close",60088),chromeMaximize:I("chrome-maximize",60089),chromeMinimize:I("chrome-minimize",60090),chromeRestore:I("chrome-restore",60091),circleOutline:I("circle-outline",60092),circle:I("circle",60092),debugBreakpointUnverified:I("debug-breakpoint-unverified",60092),terminalDecorationIncomplete:I("terminal-decoration-incomplete",60092),circleSlash:I("circle-slash",60093),circuitBoard:I("circuit-board",60094),clearAll:I("clear-all",60095),clippy:I("clippy",60096),closeAll:I("close-all",60097),cloudDownload:I("cloud-download",60098),cloudUpload:I("cloud-upload",60099),code:I("code",60100),collapseAll:I("collapse-all",60101),colorMode:I("color-mode",60102),commentDiscussion:I("comment-discussion",60103),creditCard:I("credit-card",60105),dash:I("dash",60108),dashboard:I("dashboard",60109),database:I("database",60110),debugContinue:I("debug-continue",60111),debugDisconnect:I("debug-disconnect",60112),debugPause:I("debug-pause",60113),debugRestart:I("debug-restart",60114),debugStart:I("debug-start",60115),debugStepInto:I("debug-step-into",60116),debugStepOut:I("debug-step-out",60117),debugStepOver:I("debug-step-over",60118),debugStop:I("debug-stop",60119),debug:I("debug",60120),deviceCameraVideo:I("device-camera-video",60121),deviceCamera:I("device-camera",60122),deviceMobile:I("device-mobile",60123),diffAdded:I("diff-added",60124),diffIgnored:I("diff-ignored",60125),diffModified:I("diff-modified",60126),diffRemoved:I("diff-removed",60127),diffRenamed:I("diff-renamed",60128),diff:I("diff",60129),diffSidebyside:I("diff-sidebyside",60129),discard:I("discard",60130),editorLayout:I("editor-layout",60131),emptyWindow:I("empty-window",60132),exclude:I("exclude",60133),extensions:I("extensions",60134),eyeClosed:I("eye-closed",60135),fileBinary:I("file-binary",60136),fileCode:I("file-code",60137),fileMedia:I("file-media",60138),filePdf:I("file-pdf",60139),fileSubmodule:I("file-submodule",60140),fileSymlinkDirectory:I("file-symlink-directory",60141),fileSymlinkFile:I("file-symlink-file",60142),fileZip:I("file-zip",60143),files:I("files",60144),filter:I("filter",60145),flame:I("flame",60146),foldDown:I("fold-down",60147),foldUp:I("fold-up",60148),fold:I("fold",60149),folderActive:I("folder-active",60150),folderOpened:I("folder-opened",60151),gear:I("gear",60152),gift:I("gift",60153),gistSecret:I("gist-secret",60154),gist:I("gist",60155),gitCommit:I("git-commit",60156),gitCompare:I("git-compare",60157),compareChanges:I("compare-changes",60157),gitMerge:I("git-merge",60158),githubAction:I("github-action",60159),githubAlt:I("github-alt",60160),globe:I("globe",60161),grabber:I("grabber",60162),graph:I("graph",60163),gripper:I("gripper",60164),heart:I("heart",60165),home:I("home",60166),horizontalRule:I("horizontal-rule",60167),hubot:I("hubot",60168),inbox:I("inbox",60169),issueReopened:I("issue-reopened",60171),issues:I("issues",60172),italic:I("italic",60173),jersey:I("jersey",60174),json:I("json",60175),kebabVertical:I("kebab-vertical",60176),key:I("key",60177),law:I("law",60178),lightbulbAutofix:I("lightbulb-autofix",60179),linkExternal:I("link-external",60180),link:I("link",60181),listOrdered:I("list-ordered",60182),listUnordered:I("list-unordered",60183),liveShare:I("live-share",60184),loading:I("loading",60185),location:I("location",60186),mailRead:I("mail-read",60187),mail:I("mail",60188),markdown:I("markdown",60189),megaphone:I("megaphone",60190),mention:I("mention",60191),milestone:I("milestone",60192),gitPullRequestMilestone:I("git-pull-request-milestone",60192),mortarBoard:I("mortar-board",60193),move:I("move",60194),multipleWindows:I("multiple-windows",60195),mute:I("mute",60196),noNewline:I("no-newline",60197),note:I("note",60198),octoface:I("octoface",60199),openPreview:I("open-preview",60200),package:I("package",60201),paintcan:I("paintcan",60202),pin:I("pin",60203),play:I("play",60204),run:I("run",60204),plug:I("plug",60205),preserveCase:I("preserve-case",60206),preview:I("preview",60207),project:I("project",60208),pulse:I("pulse",60209),question:I("question",60210),quote:I("quote",60211),radioTower:I("radio-tower",60212),reactions:I("reactions",60213),references:I("references",60214),refresh:I("refresh",60215),regex:I("regex",60216),remoteExplorer:I("remote-explorer",60217),remote:I("remote",60218),remove:I("remove",60219),replaceAll:I("replace-all",60220),replace:I("replace",60221),repoClone:I("repo-clone",60222),repoForcePush:I("repo-force-push",60223),repoPull:I("repo-pull",60224),repoPush:I("repo-push",60225),report:I("report",60226),requestChanges:I("request-changes",60227),rocket:I("rocket",60228),rootFolderOpened:I("root-folder-opened",60229),rootFolder:I("root-folder",60230),rss:I("rss",60231),ruby:I("ruby",60232),saveAll:I("save-all",60233),saveAs:I("save-as",60234),save:I("save",60235),screenFull:I("screen-full",60236),screenNormal:I("screen-normal",60237),searchStop:I("search-stop",60238),server:I("server",60240),settingsGear:I("settings-gear",60241),settings:I("settings",60242),shield:I("shield",60243),smiley:I("smiley",60244),sortPrecedence:I("sort-precedence",60245),splitHorizontal:I("split-horizontal",60246),splitVertical:I("split-vertical",60247),squirrel:I("squirrel",60248),starFull:I("star-full",60249),starHalf:I("star-half",60250),symbolClass:I("symbol-class",60251),symbolColor:I("symbol-color",60252),symbolConstant:I("symbol-constant",60253),symbolEnumMember:I("symbol-enum-member",60254),symbolField:I("symbol-field",60255),symbolFile:I("symbol-file",60256),symbolInterface:I("symbol-interface",60257),symbolKeyword:I("symbol-keyword",60258),symbolMisc:I("symbol-misc",60259),symbolOperator:I("symbol-operator",60260),symbolProperty:I("symbol-property",60261),wrench:I("wrench",60261),wrenchSubaction:I("wrench-subaction",60261),symbolSnippet:I("symbol-snippet",60262),tasklist:I("tasklist",60263),telescope:I("telescope",60264),textSize:I("text-size",60265),threeBars:I("three-bars",60266),thumbsdown:I("thumbsdown",60267),thumbsup:I("thumbsup",60268),tools:I("tools",60269),triangleDown:I("triangle-down",60270),triangleLeft:I("triangle-left",60271),triangleRight:I("triangle-right",60272),triangleUp:I("triangle-up",60273),twitter:I("twitter",60274),unfold:I("unfold",60275),unlock:I("unlock",60276),unmute:I("unmute",60277),unverified:I("unverified",60278),verified:I("verified",60279),versions:I("versions",60280),vmActive:I("vm-active",60281),vmOutline:I("vm-outline",60282),vmRunning:I("vm-running",60283),watch:I("watch",60284),whitespace:I("whitespace",60285),wholeWord:I("whole-word",60286),window:I("window",60287),wordWrap:I("word-wrap",60288),zoomIn:I("zoom-in",60289),zoomOut:I("zoom-out",60290),listFilter:I("list-filter",60291),listFlat:I("list-flat",60292),listSelection:I("list-selection",60293),selection:I("selection",60293),listTree:I("list-tree",60294),debugBreakpointFunctionUnverified:I("debug-breakpoint-function-unverified",60295),debugBreakpointFunction:I("debug-breakpoint-function",60296),debugBreakpointFunctionDisabled:I("debug-breakpoint-function-disabled",60296),debugStackframeActive:I("debug-stackframe-active",60297),circleSmallFilled:I("circle-small-filled",60298),debugStackframeDot:I("debug-stackframe-dot",60298),terminalDecorationMark:I("terminal-decoration-mark",60298),debugStackframe:I("debug-stackframe",60299),debugStackframeFocused:I("debug-stackframe-focused",60299),debugBreakpointUnsupported:I("debug-breakpoint-unsupported",60300),symbolString:I("symbol-string",60301),debugReverseContinue:I("debug-reverse-continue",60302),debugStepBack:I("debug-step-back",60303),debugRestartFrame:I("debug-restart-frame",60304),debugAlt:I("debug-alt",60305),callIncoming:I("call-incoming",60306),callOutgoing:I("call-outgoing",60307),menu:I("menu",60308),expandAll:I("expand-all",60309),feedback:I("feedback",60310),gitPullRequestReviewer:I("git-pull-request-reviewer",60310),groupByRefType:I("group-by-ref-type",60311),ungroupByRefType:I("ungroup-by-ref-type",60312),account:I("account",60313),gitPullRequestAssignee:I("git-pull-request-assignee",60313),bellDot:I("bell-dot",60314),debugConsole:I("debug-console",60315),library:I("library",60316),output:I("output",60317),runAll:I("run-all",60318),syncIgnored:I("sync-ignored",60319),pinned:I("pinned",60320),githubInverted:I("github-inverted",60321),serverProcess:I("server-process",60322),serverEnvironment:I("server-environment",60323),pass:I("pass",60324),issueClosed:I("issue-closed",60324),stopCircle:I("stop-circle",60325),playCircle:I("play-circle",60326),record:I("record",60327),debugAltSmall:I("debug-alt-small",60328),vmConnect:I("vm-connect",60329),cloud:I("cloud",60330),merge:I("merge",60331),export:I("export",60332),graphLeft:I("graph-left",60333),magnet:I("magnet",60334),notebook:I("notebook",60335),redo:I("redo",60336),checkAll:I("check-all",60337),pinnedDirty:I("pinned-dirty",60338),passFilled:I("pass-filled",60339),circleLargeFilled:I("circle-large-filled",60340),circleLarge:I("circle-large",60341),circleLargeOutline:I("circle-large-outline",60341),combine:I("combine",60342),gather:I("gather",60342),table:I("table",60343),variableGroup:I("variable-group",60344),typeHierarchy:I("type-hierarchy",60345),typeHierarchySub:I("type-hierarchy-sub",60346),typeHierarchySuper:I("type-hierarchy-super",60347),gitPullRequestCreate:I("git-pull-request-create",60348),runAbove:I("run-above",60349),runBelow:I("run-below",60350),notebookTemplate:I("notebook-template",60351),debugRerun:I("debug-rerun",60352),workspaceTrusted:I("workspace-trusted",60353),workspaceUntrusted:I("workspace-untrusted",60354),workspaceUnknown:I("workspace-unknown",60355),terminalCmd:I("terminal-cmd",60356),terminalDebian:I("terminal-debian",60357),terminalLinux:I("terminal-linux",60358),terminalPowershell:I("terminal-powershell",60359),terminalTmux:I("terminal-tmux",60360),terminalUbuntu:I("terminal-ubuntu",60361),terminalBash:I("terminal-bash",60362),arrowSwap:I("arrow-swap",60363),copy:I("copy",60364),personAdd:I("person-add",60365),filterFilled:I("filter-filled",60366),wand:I("wand",60367),debugLineByLine:I("debug-line-by-line",60368),inspect:I("inspect",60369),layers:I("layers",60370),layersDot:I("layers-dot",60371),layersActive:I("layers-active",60372),compass:I("compass",60373),compassDot:I("compass-dot",60374),compassActive:I("compass-active",60375),azure:I("azure",60376),issueDraft:I("issue-draft",60377),gitPullRequestClosed:I("git-pull-request-closed",60378),gitPullRequestDraft:I("git-pull-request-draft",60379),debugAll:I("debug-all",60380),debugCoverage:I("debug-coverage",60381),runErrors:I("run-errors",60382),folderLibrary:I("folder-library",60383),debugContinueSmall:I("debug-continue-small",60384),beakerStop:I("beaker-stop",60385),graphLine:I("graph-line",60386),graphScatter:I("graph-scatter",60387),pieChart:I("pie-chart",60388),bracket:I("bracket",60175),bracketDot:I("bracket-dot",60389),bracketError:I("bracket-error",60390),lockSmall:I("lock-small",60391),azureDevops:I("azure-devops",60392),verifiedFilled:I("verified-filled",60393),newline:I("newline",60394),layout:I("layout",60395),layoutActivitybarLeft:I("layout-activitybar-left",60396),layoutActivitybarRight:I("layout-activitybar-right",60397),layoutPanelLeft:I("layout-panel-left",60398),layoutPanelCenter:I("layout-panel-center",60399),layoutPanelJustify:I("layout-panel-justify",60400),layoutPanelRight:I("layout-panel-right",60401),layoutPanel:I("layout-panel",60402),layoutSidebarLeft:I("layout-sidebar-left",60403),layoutSidebarRight:I("layout-sidebar-right",60404),layoutStatusbar:I("layout-statusbar",60405),layoutMenubar:I("layout-menubar",60406),layoutCentered:I("layout-centered",60407),target:I("target",60408),indent:I("indent",60409),recordSmall:I("record-small",60410),errorSmall:I("error-small",60411),terminalDecorationError:I("terminal-decoration-error",60411),arrowCircleDown:I("arrow-circle-down",60412),arrowCircleLeft:I("arrow-circle-left",60413),arrowCircleRight:I("arrow-circle-right",60414),arrowCircleUp:I("arrow-circle-up",60415),layoutSidebarRightOff:I("layout-sidebar-right-off",60416),layoutPanelOff:I("layout-panel-off",60417),layoutSidebarLeftOff:I("layout-sidebar-left-off",60418),blank:I("blank",60419),heartFilled:I("heart-filled",60420),map:I("map",60421),mapHorizontal:I("map-horizontal",60421),foldHorizontal:I("fold-horizontal",60421),mapFilled:I("map-filled",60422),mapHorizontalFilled:I("map-horizontal-filled",60422),foldHorizontalFilled:I("fold-horizontal-filled",60422),circleSmall:I("circle-small",60423),bellSlash:I("bell-slash",60424),bellSlashDot:I("bell-slash-dot",60425),commentUnresolved:I("comment-unresolved",60426),gitPullRequestGoToChanges:I("git-pull-request-go-to-changes",60427),gitPullRequestNewChanges:I("git-pull-request-new-changes",60428),searchFuzzy:I("search-fuzzy",60429),commentDraft:I("comment-draft",60430),send:I("send",60431),sparkle:I("sparkle",60432),insert:I("insert",60433),mic:I("mic",60434),thumbsdownFilled:I("thumbsdown-filled",60435),thumbsupFilled:I("thumbsup-filled",60436),coffee:I("coffee",60437),snake:I("snake",60438),game:I("game",60439),vr:I("vr",60440),chip:I("chip",60441),piano:I("piano",60442),music:I("music",60443),micFilled:I("mic-filled",60444),repoFetch:I("repo-fetch",60445),copilot:I("copilot",60446),lightbulbSparkle:I("lightbulb-sparkle",60447),robot:I("robot",60448),sparkleFilled:I("sparkle-filled",60449),diffSingle:I("diff-single",60450),diffMultiple:I("diff-multiple",60451),surroundWith:I("surround-with",60452),share:I("share",60453),gitStash:I("git-stash",60454),gitStashApply:I("git-stash-apply",60455),gitStashPop:I("git-stash-pop",60456),vscode:I("vscode",60457),vscodeInsiders:I("vscode-insiders",60458),codeOss:I("code-oss",60459),runCoverage:I("run-coverage",60460),runAllCoverage:I("run-all-coverage",60461),coverage:I("coverage",60462),githubProject:I("github-project",60463),mapVertical:I("map-vertical",60464),foldVertical:I("fold-vertical",60464),mapVerticalFilled:I("map-vertical-filled",60465),foldVerticalFilled:I("fold-vertical-filled",60465),goToSearch:I("go-to-search",60466),percentage:I("percentage",60467),sortPercentage:I("sort-percentage",60467),attach:I("attach",60468)}});var wot,oe,Qi=k(()=>{zR();ITe();wot={dialogError:I("dialog-error","error"),dialogWarning:I("dialog-warning","warning"),dialogInfo:I("dialog-info","info"),dialogClose:I("dialog-close","close"),treeItemExpanded:I("tree-item-expanded","chevron-down"),treeFilterOnTypeOn:I("tree-filter-on-type-on","list-filter"),treeFilterOnTypeOff:I("tree-filter-on-type-off","list-selection"),treeFilterClear:I("tree-filter-clear","close"),treeItemLoading:I("tree-item-loading","loading"),menuSelection:I("menu-selection","check"),menuSubmenu:I("menu-submenu","chevron-right"),menuBarMore:I("menubar-more","more"),scrollbarButtonLeft:I("scrollbar-button-left","triangle-left"),scrollbarButtonRight:I("scrollbar-button-right","triangle-right"),scrollbarButtonUp:I("scrollbar-button-up","triangle-up"),scrollbarButtonDown:I("scrollbar-button-down","triangle-down"),toolBarMore:I("toolbar-more","more"),quickInputBack:I("quick-input-back","arrow-left"),dropDownButton:I("drop-down-button",60084),symbolCustomColor:I("symbol-customcolor",60252),exportIcon:I("export",60332),workspaceUnspecified:I("workspace-unspecified",60355),newLine:I("newline",60394),thumbsDownFilled:I("thumbsdown-filled",60435),thumbsUpFilled:I("thumbsup-filled",60436),gitFetch:I("git-fetch",60445),lightbulbSparkleAutofix:I("lightbulb-sparkle-autofix",60447),debugBreakpointPending:I("debug-breakpoint-pending",60377)},oe={...LTe,...wot}});var VR,kne,ETe=k(()=>{Ie();j();VR=class{constructor(){this._tokenizationSupports=new Map,this._factories=new Map,this._onDidChange=new A,this.onDidChange=this._onDidChange.event,this._colorMap=null}handleChange(e){this._onDidChange.fire({changedLanguages:e,changedColorMap:!1})}register(e,t){return this._tokenizationSupports.set(e,t),this.handleChange([e]),ge(()=>{this._tokenizationSupports.get(e)===t&&(this._tokenizationSupports.delete(e),this.handleChange([e]))})}get(e){return this._tokenizationSupports.get(e)||null}registerFactory(e,t){this._factories.get(e)?.dispose();let i=new kne(this,e,t);return this._factories.set(e,i),ge(()=>{let o=this._factories.get(e);!o||o!==i||(this._factories.delete(e),o.dispose())})}async getOrCreate(e){let t=this.get(e);if(t)return t;let i=this._factories.get(e);return!i||i.isResolved?null:(await i.resolve(),this.get(e))}isResolved(e){if(this.get(e))return!0;let i=this._factories.get(e);return!!(!i||i.isResolved)}setColorMap(e){this._colorMap=e,this._onDidChange.fire({changedLanguages:Array.from(this._tokenizationSupports.keys()),changedColorMap:!0})}getColorMap(){return this._colorMap}getDefaultBackground(){return this._colorMap&&this._colorMap.length>2?this._colorMap[2]:null}},kne=class extends D{get isResolved(){return this._isResolved}constructor(e,t,i){super(),this._registry=e,this._languageId=t,this._factory=i,this._isDisposed=!1,this._resolvePromise=null,this._isResolved=!1}dispose(){this._isDisposed=!0,super.dispose()}async resolve(){return this._resolvePromise||(this._resolvePromise=this._create()),this._resolvePromise}async _create(){let e=await this._factory.tokenizationSupport;this._isResolved=!0,e&&!this._isDisposed&&this._register(this._registry.register(this._languageId,e))}}});function TTe(n){return n&&Ee.isUri(n.uri)&&S.isIRange(n.range)&&(S.isIRange(n.originSelectionRange)||S.isIRange(n.targetSelectionRange))}function DTe(n,e){return m("symbolAriaLabel","{0} ({1})",n,yot[e])}var lp,px,B_,nc,b1,Sd,Qk,v1,ch,mx,yot,Jk,Sm,o8,x1,r8,UR,s8,$i,jR,$R,Ji=k(()=>{Qi();Ai();we();ETe();pe();lp=class{constructor(e,t,i){this.offset=e,this.type=t,this.language=i,this._tokenBrand=void 0}toString(){return"("+this.offset+", "+this.type+")"}},px=class{constructor(e,t){this.tokens=e,this.endState=t,this._tokenizationResultBrand=void 0}},B_=class{constructor(e,t){this.tokens=e,this.endState=t,this._encodedTokenizationResultBrand=void 0}};(function(n){n[n.Increase=0]="Increase",n[n.Decrease=1]="Decrease"})(nc||(nc={}));(function(n){let e=new Map;e.set(0,oe.symbolMethod),e.set(1,oe.symbolFunction),e.set(2,oe.symbolConstructor),e.set(3,oe.symbolField),e.set(4,oe.symbolVariable),e.set(5,oe.symbolClass),e.set(6,oe.symbolStruct),e.set(7,oe.symbolInterface),e.set(8,oe.symbolModule),e.set(9,oe.symbolProperty),e.set(10,oe.symbolEvent),e.set(11,oe.symbolOperator),e.set(12,oe.symbolUnit),e.set(13,oe.symbolValue),e.set(15,oe.symbolEnum),e.set(14,oe.symbolConstant),e.set(15,oe.symbolEnum),e.set(16,oe.symbolEnumMember),e.set(17,oe.symbolKeyword),e.set(27,oe.symbolSnippet),e.set(18,oe.symbolText),e.set(19,oe.symbolColor),e.set(20,oe.symbolFile),e.set(21,oe.symbolReference),e.set(22,oe.symbolCustomColor),e.set(23,oe.symbolFolder),e.set(24,oe.symbolTypeParameter),e.set(25,oe.account),e.set(26,oe.issues);function t(r){let s=e.get(r);return s||(console.info("No codicon found for CompletionItemKind "+r),s=oe.symbolProperty),s}n.toIcon=t;let i=new Map;i.set("method",0),i.set("function",1),i.set("constructor",2),i.set("field",3),i.set("variable",4),i.set("class",5),i.set("struct",6),i.set("interface",7),i.set("module",8),i.set("property",9),i.set("event",10),i.set("operator",11),i.set("unit",12),i.set("value",13),i.set("constant",14),i.set("enum",15),i.set("enum-member",16),i.set("enumMember",16),i.set("keyword",17),i.set("snippet",27),i.set("text",18),i.set("color",19),i.set("file",20),i.set("reference",21),i.set("customcolor",22),i.set("folder",23),i.set("type-parameter",24),i.set("typeParameter",24),i.set("account",25),i.set("issue",26);function o(r,s){let a=i.get(r);return typeof a>"u"&&!s&&(a=9),a}n.fromString=o})(b1||(b1={}));(function(n){n[n.Automatic=0]="Automatic",n[n.Explicit=1]="Explicit"})(Sd||(Sd={}));Qk=class{constructor(e,t,i,o){this.range=e,this.text=t,this.completionKind=i,this.isSnippetText=o}equals(e){return S.lift(this.range).equalsRange(e.range)&&this.text===e.text&&this.completionKind===e.completionKind&&this.isSnippetText===e.isSnippetText}};(function(n){n[n.Automatic=0]="Automatic",n[n.PasteAs=1]="PasteAs"})(v1||(v1={}));(function(n){n[n.Invoke=1]="Invoke",n[n.TriggerCharacter=2]="TriggerCharacter",n[n.ContentChange=3]="ContentChange"})(ch||(ch={}));(function(n){n[n.Text=0]="Text",n[n.Read=1]="Read",n[n.Write=2]="Write"})(mx||(mx={}));yot={17:m("Array","array"),16:m("Boolean","boolean"),4:m("Class","class"),13:m("Constant","constant"),8:m("Constructor","constructor"),9:m("Enum","enumeration"),21:m("EnumMember","enumeration member"),23:m("Event","event"),7:m("Field","field"),0:m("File","file"),11:m("Function","function"),10:m("Interface","interface"),19:m("Key","key"),5:m("Method","method"),1:m("Module","module"),2:m("Namespace","namespace"),20:m("Null","null"),15:m("Number","number"),18:m("Object","object"),24:m("Operator","operator"),3:m("Package","package"),6:m("Property","property"),14:m("String","string"),22:m("Struct","struct"),25:m("TypeParameter","type parameter"),12:m("Variable","variable")};(function(n){let e=new Map;e.set(0,oe.symbolFile),e.set(1,oe.symbolModule),e.set(2,oe.symbolNamespace),e.set(3,oe.symbolPackage),e.set(4,oe.symbolClass),e.set(5,oe.symbolMethod),e.set(6,oe.symbolProperty),e.set(7,oe.symbolField),e.set(8,oe.symbolConstructor),e.set(9,oe.symbolEnum),e.set(10,oe.symbolInterface),e.set(11,oe.symbolFunction),e.set(12,oe.symbolVariable),e.set(13,oe.symbolConstant),e.set(14,oe.symbolString),e.set(15,oe.symbolNumber),e.set(16,oe.symbolBoolean),e.set(17,oe.symbolArray),e.set(18,oe.symbolObject),e.set(19,oe.symbolKey),e.set(20,oe.symbolNull),e.set(21,oe.symbolEnumMember),e.set(22,oe.symbolStruct),e.set(23,oe.symbolEvent),e.set(24,oe.symbolOperator),e.set(25,oe.symbolTypeParameter);function t(i){let o=e.get(i);return o||(console.info("No codicon found for SymbolKind "+i),o=oe.symbolProperty),o}n.toIcon=t})(Jk||(Jk={}));Sm=class n{static{this.Comment=new n("comment")}static{this.Imports=new n("imports")}static{this.Region=new n("region")}static fromValue(e){switch(e){case"comment":return n.Comment;case"imports":return n.Imports;case"region":return n.Region}return new n(e)}constructor(e){this.value=e}};(function(n){n[n.AIGenerated=1]="AIGenerated"})(o8||(o8={}));(function(n){n[n.Invoke=0]="Invoke",n[n.Automatic=1]="Automatic"})(x1||(x1={}));(function(n){function e(t){return!t||typeof t!="object"?!1:typeof t.id=="string"&&typeof t.title=="string"}n.is=e})(r8||(r8={}));(function(n){n[n.Type=1]="Type",n[n.Parameter=2]="Parameter"})(UR||(UR={}));s8=class{constructor(e){this.createSupport=e,this._tokenizationSupport=null}dispose(){this._tokenizationSupport&&this._tokenizationSupport.then(e=>{e&&e.dispose()})}get tokenizationSupport(){return this._tokenizationSupport||(this._tokenizationSupport=this.createSupport()),this._tokenizationSupport}},$i=new VR,jR=new VR;(function(n){n[n.Invoke=0]="Invoke",n[n.Automatic=1]="Automatic"})($R||($R={}))});var a8,l8,c8,d8,u8,h8,f8,p8,m8,g8,_8,b8,v8,x8,w8,y8,C8,S8,k8,L8,I8,E8,T8,D8,N8,R8,A8,M8,P8,O8,F8,B8,W8,H8,z8,V8,U8,$8,j8,q8,K8,G8,Y8,Z8,X8,Q8,J8=k(()=>{(function(n){n[n.Unknown=0]="Unknown",n[n.Disabled=1]="Disabled",n[n.Enabled=2]="Enabled"})(a8||(a8={}));(function(n){n[n.Invoke=1]="Invoke",n[n.Auto=2]="Auto"})(l8||(l8={}));(function(n){n[n.None=0]="None",n[n.KeepWhitespace=1]="KeepWhitespace",n[n.InsertAsSnippet=4]="InsertAsSnippet"})(c8||(c8={}));(function(n){n[n.Method=0]="Method",n[n.Function=1]="Function",n[n.Constructor=2]="Constructor",n[n.Field=3]="Field",n[n.Variable=4]="Variable",n[n.Class=5]="Class",n[n.Struct=6]="Struct",n[n.Interface=7]="Interface",n[n.Module=8]="Module",n[n.Property=9]="Property",n[n.Event=10]="Event",n[n.Operator=11]="Operator",n[n.Unit=12]="Unit",n[n.Value=13]="Value",n[n.Constant=14]="Constant",n[n.Enum=15]="Enum",n[n.EnumMember=16]="EnumMember",n[n.Keyword=17]="Keyword",n[n.Text=18]="Text",n[n.Color=19]="Color",n[n.File=20]="File",n[n.Reference=21]="Reference",n[n.Customcolor=22]="Customcolor",n[n.Folder=23]="Folder",n[n.TypeParameter=24]="TypeParameter",n[n.User=25]="User",n[n.Issue=26]="Issue",n[n.Snippet=27]="Snippet"})(d8||(d8={}));(function(n){n[n.Deprecated=1]="Deprecated"})(u8||(u8={}));(function(n){n[n.Invoke=0]="Invoke",n[n.TriggerCharacter=1]="TriggerCharacter",n[n.TriggerForIncompleteCompletions=2]="TriggerForIncompleteCompletions"})(h8||(h8={}));(function(n){n[n.EXACT=0]="EXACT",n[n.ABOVE=1]="ABOVE",n[n.BELOW=2]="BELOW"})(f8||(f8={}));(function(n){n[n.NotSet=0]="NotSet",n[n.ContentFlush=1]="ContentFlush",n[n.RecoverFromMarkers=2]="RecoverFromMarkers",n[n.Explicit=3]="Explicit",n[n.Paste=4]="Paste",n[n.Undo=5]="Undo",n[n.Redo=6]="Redo"})(p8||(p8={}));(function(n){n[n.LF=1]="LF",n[n.CRLF=2]="CRLF"})(m8||(m8={}));(function(n){n[n.Text=0]="Text",n[n.Read=1]="Read",n[n.Write=2]="Write"})(g8||(g8={}));(function(n){n[n.None=0]="None",n[n.Keep=1]="Keep",n[n.Brackets=2]="Brackets",n[n.Advanced=3]="Advanced",n[n.Full=4]="Full"})(_8||(_8={}));(function(n){n[n.acceptSuggestionOnCommitCharacter=0]="acceptSuggestionOnCommitCharacter",n[n.acceptSuggestionOnEnter=1]="acceptSuggestionOnEnter",n[n.accessibilitySupport=2]="accessibilitySupport",n[n.accessibilityPageSize=3]="accessibilityPageSize",n[n.ariaLabel=4]="ariaLabel",n[n.ariaRequired=5]="ariaRequired",n[n.autoClosingBrackets=6]="autoClosingBrackets",n[n.autoClosingComments=7]="autoClosingComments",n[n.screenReaderAnnounceInlineSuggestion=8]="screenReaderAnnounceInlineSuggestion",n[n.autoClosingDelete=9]="autoClosingDelete",n[n.autoClosingOvertype=10]="autoClosingOvertype",n[n.autoClosingQuotes=11]="autoClosingQuotes",n[n.autoIndent=12]="autoIndent",n[n.automaticLayout=13]="automaticLayout",n[n.autoSurround=14]="autoSurround",n[n.bracketPairColorization=15]="bracketPairColorization",n[n.guides=16]="guides",n[n.codeLens=17]="codeLens",n[n.codeLensFontFamily=18]="codeLensFontFamily",n[n.codeLensFontSize=19]="codeLensFontSize",n[n.colorDecorators=20]="colorDecorators",n[n.colorDecoratorsLimit=21]="colorDecoratorsLimit",n[n.columnSelection=22]="columnSelection",n[n.comments=23]="comments",n[n.contextmenu=24]="contextmenu",n[n.copyWithSyntaxHighlighting=25]="copyWithSyntaxHighlighting",n[n.cursorBlinking=26]="cursorBlinking",n[n.cursorSmoothCaretAnimation=27]="cursorSmoothCaretAnimation",n[n.cursorStyle=28]="cursorStyle",n[n.cursorSurroundingLines=29]="cursorSurroundingLines",n[n.cursorSurroundingLinesStyle=30]="cursorSurroundingLinesStyle",n[n.cursorWidth=31]="cursorWidth",n[n.disableLayerHinting=32]="disableLayerHinting",n[n.disableMonospaceOptimizations=33]="disableMonospaceOptimizations",n[n.domReadOnly=34]="domReadOnly",n[n.dragAndDrop=35]="dragAndDrop",n[n.dropIntoEditor=36]="dropIntoEditor",n[n.emptySelectionClipboard=37]="emptySelectionClipboard",n[n.experimentalWhitespaceRendering=38]="experimentalWhitespaceRendering",n[n.extraEditorClassName=39]="extraEditorClassName",n[n.fastScrollSensitivity=40]="fastScrollSensitivity",n[n.find=41]="find",n[n.fixedOverflowWidgets=42]="fixedOverflowWidgets",n[n.folding=43]="folding",n[n.foldingStrategy=44]="foldingStrategy",n[n.foldingHighlight=45]="foldingHighlight",n[n.foldingImportsByDefault=46]="foldingImportsByDefault",n[n.foldingMaximumRegions=47]="foldingMaximumRegions",n[n.unfoldOnClickAfterEndOfLine=48]="unfoldOnClickAfterEndOfLine",n[n.fontFamily=49]="fontFamily",n[n.fontInfo=50]="fontInfo",n[n.fontLigatures=51]="fontLigatures",n[n.fontSize=52]="fontSize",n[n.fontWeight=53]="fontWeight",n[n.fontVariations=54]="fontVariations",n[n.formatOnPaste=55]="formatOnPaste",n[n.formatOnType=56]="formatOnType",n[n.glyphMargin=57]="glyphMargin",n[n.gotoLocation=58]="gotoLocation",n[n.hideCursorInOverviewRuler=59]="hideCursorInOverviewRuler",n[n.hover=60]="hover",n[n.inDiffEditor=61]="inDiffEditor",n[n.inlineSuggest=62]="inlineSuggest",n[n.inlineEdit=63]="inlineEdit",n[n.letterSpacing=64]="letterSpacing",n[n.lightbulb=65]="lightbulb",n[n.lineDecorationsWidth=66]="lineDecorationsWidth",n[n.lineHeight=67]="lineHeight",n[n.lineNumbers=68]="lineNumbers",n[n.lineNumbersMinChars=69]="lineNumbersMinChars",n[n.linkedEditing=70]="linkedEditing",n[n.links=71]="links",n[n.matchBrackets=72]="matchBrackets",n[n.minimap=73]="minimap",n[n.mouseStyle=74]="mouseStyle",n[n.mouseWheelScrollSensitivity=75]="mouseWheelScrollSensitivity",n[n.mouseWheelZoom=76]="mouseWheelZoom",n[n.multiCursorMergeOverlapping=77]="multiCursorMergeOverlapping",n[n.multiCursorModifier=78]="multiCursorModifier",n[n.multiCursorPaste=79]="multiCursorPaste",n[n.multiCursorLimit=80]="multiCursorLimit",n[n.occurrencesHighlight=81]="occurrencesHighlight",n[n.overviewRulerBorder=82]="overviewRulerBorder",n[n.overviewRulerLanes=83]="overviewRulerLanes",n[n.padding=84]="padding",n[n.pasteAs=85]="pasteAs",n[n.parameterHints=86]="parameterHints",n[n.peekWidgetDefaultFocus=87]="peekWidgetDefaultFocus",n[n.placeholder=88]="placeholder",n[n.definitionLinkOpensInPeek=89]="definitionLinkOpensInPeek",n[n.quickSuggestions=90]="quickSuggestions",n[n.quickSuggestionsDelay=91]="quickSuggestionsDelay",n[n.readOnly=92]="readOnly",n[n.readOnlyMessage=93]="readOnlyMessage",n[n.renameOnType=94]="renameOnType",n[n.renderControlCharacters=95]="renderControlCharacters",n[n.renderFinalNewline=96]="renderFinalNewline",n[n.renderLineHighlight=97]="renderLineHighlight",n[n.renderLineHighlightOnlyWhenFocus=98]="renderLineHighlightOnlyWhenFocus",n[n.renderValidationDecorations=99]="renderValidationDecorations",n[n.renderWhitespace=100]="renderWhitespace",n[n.revealHorizontalRightPadding=101]="revealHorizontalRightPadding",n[n.roundedSelection=102]="roundedSelection",n[n.rulers=103]="rulers",n[n.scrollbar=104]="scrollbar",n[n.scrollBeyondLastColumn=105]="scrollBeyondLastColumn",n[n.scrollBeyondLastLine=106]="scrollBeyondLastLine",n[n.scrollPredominantAxis=107]="scrollPredominantAxis",n[n.selectionClipboard=108]="selectionClipboard",n[n.selectionHighlight=109]="selectionHighlight",n[n.selectOnLineNumbers=110]="selectOnLineNumbers",n[n.showFoldingControls=111]="showFoldingControls",n[n.showUnused=112]="showUnused",n[n.snippetSuggestions=113]="snippetSuggestions",n[n.smartSelect=114]="smartSelect",n[n.smoothScrolling=115]="smoothScrolling",n[n.stickyScroll=116]="stickyScroll",n[n.stickyTabStops=117]="stickyTabStops",n[n.stopRenderingLineAfter=118]="stopRenderingLineAfter",n[n.suggest=119]="suggest",n[n.suggestFontSize=120]="suggestFontSize",n[n.suggestLineHeight=121]="suggestLineHeight",n[n.suggestOnTriggerCharacters=122]="suggestOnTriggerCharacters",n[n.suggestSelection=123]="suggestSelection",n[n.tabCompletion=124]="tabCompletion",n[n.tabIndex=125]="tabIndex",n[n.unicodeHighlighting=126]="unicodeHighlighting",n[n.unusualLineTerminators=127]="unusualLineTerminators",n[n.useShadowDOM=128]="useShadowDOM",n[n.useTabStops=129]="useTabStops",n[n.wordBreak=130]="wordBreak",n[n.wordSegmenterLocales=131]="wordSegmenterLocales",n[n.wordSeparators=132]="wordSeparators",n[n.wordWrap=133]="wordWrap",n[n.wordWrapBreakAfterCharacters=134]="wordWrapBreakAfterCharacters",n[n.wordWrapBreakBeforeCharacters=135]="wordWrapBreakBeforeCharacters",n[n.wordWrapColumn=136]="wordWrapColumn",n[n.wordWrapOverride1=137]="wordWrapOverride1",n[n.wordWrapOverride2=138]="wordWrapOverride2",n[n.wrappingIndent=139]="wrappingIndent",n[n.wrappingStrategy=140]="wrappingStrategy",n[n.showDeprecated=141]="showDeprecated",n[n.inlayHints=142]="inlayHints",n[n.editorClassName=143]="editorClassName",n[n.pixelRatio=144]="pixelRatio",n[n.tabFocusMode=145]="tabFocusMode",n[n.layoutInfo=146]="layoutInfo",n[n.wrappingInfo=147]="wrappingInfo",n[n.defaultColorDecorators=148]="defaultColorDecorators",n[n.colorDecoratorsActivatedOn=149]="colorDecoratorsActivatedOn",n[n.inlineCompletionsAccessibilityVerbose=150]="inlineCompletionsAccessibilityVerbose"})(b8||(b8={}));(function(n){n[n.TextDefined=0]="TextDefined",n[n.LF=1]="LF",n[n.CRLF=2]="CRLF"})(v8||(v8={}));(function(n){n[n.LF=0]="LF",n[n.CRLF=1]="CRLF"})(x8||(x8={}));(function(n){n[n.Left=1]="Left",n[n.Center=2]="Center",n[n.Right=3]="Right"})(w8||(w8={}));(function(n){n[n.Increase=0]="Increase",n[n.Decrease=1]="Decrease"})(y8||(y8={}));(function(n){n[n.None=0]="None",n[n.Indent=1]="Indent",n[n.IndentOutdent=2]="IndentOutdent",n[n.Outdent=3]="Outdent"})(C8||(C8={}));(function(n){n[n.Both=0]="Both",n[n.Right=1]="Right",n[n.Left=2]="Left",n[n.None=3]="None"})(S8||(S8={}));(function(n){n[n.Type=1]="Type",n[n.Parameter=2]="Parameter"})(k8||(k8={}));(function(n){n[n.Automatic=0]="Automatic",n[n.Explicit=1]="Explicit"})(L8||(L8={}));(function(n){n[n.Invoke=0]="Invoke",n[n.Automatic=1]="Automatic"})(I8||(I8={}));(function(n){n[n.DependsOnKbLayout=-1]="DependsOnKbLayout",n[n.Unknown=0]="Unknown",n[n.Backspace=1]="Backspace",n[n.Tab=2]="Tab",n[n.Enter=3]="Enter",n[n.Shift=4]="Shift",n[n.Ctrl=5]="Ctrl",n[n.Alt=6]="Alt",n[n.PauseBreak=7]="PauseBreak",n[n.CapsLock=8]="CapsLock",n[n.Escape=9]="Escape",n[n.Space=10]="Space",n[n.PageUp=11]="PageUp",n[n.PageDown=12]="PageDown",n[n.End=13]="End",n[n.Home=14]="Home",n[n.LeftArrow=15]="LeftArrow",n[n.UpArrow=16]="UpArrow",n[n.RightArrow=17]="RightArrow",n[n.DownArrow=18]="DownArrow",n[n.Insert=19]="Insert",n[n.Delete=20]="Delete",n[n.Digit0=21]="Digit0",n[n.Digit1=22]="Digit1",n[n.Digit2=23]="Digit2",n[n.Digit3=24]="Digit3",n[n.Digit4=25]="Digit4",n[n.Digit5=26]="Digit5",n[n.Digit6=27]="Digit6",n[n.Digit7=28]="Digit7",n[n.Digit8=29]="Digit8",n[n.Digit9=30]="Digit9",n[n.KeyA=31]="KeyA",n[n.KeyB=32]="KeyB",n[n.KeyC=33]="KeyC",n[n.KeyD=34]="KeyD",n[n.KeyE=35]="KeyE",n[n.KeyF=36]="KeyF",n[n.KeyG=37]="KeyG",n[n.KeyH=38]="KeyH",n[n.KeyI=39]="KeyI",n[n.KeyJ=40]="KeyJ",n[n.KeyK=41]="KeyK",n[n.KeyL=42]="KeyL",n[n.KeyM=43]="KeyM",n[n.KeyN=44]="KeyN",n[n.KeyO=45]="KeyO",n[n.KeyP=46]="KeyP",n[n.KeyQ=47]="KeyQ",n[n.KeyR=48]="KeyR",n[n.KeyS=49]="KeyS",n[n.KeyT=50]="KeyT",n[n.KeyU=51]="KeyU",n[n.KeyV=52]="KeyV",n[n.KeyW=53]="KeyW",n[n.KeyX=54]="KeyX",n[n.KeyY=55]="KeyY",n[n.KeyZ=56]="KeyZ",n[n.Meta=57]="Meta",n[n.ContextMenu=58]="ContextMenu",n[n.F1=59]="F1",n[n.F2=60]="F2",n[n.F3=61]="F3",n[n.F4=62]="F4",n[n.F5=63]="F5",n[n.F6=64]="F6",n[n.F7=65]="F7",n[n.F8=66]="F8",n[n.F9=67]="F9",n[n.F10=68]="F10",n[n.F11=69]="F11",n[n.F12=70]="F12",n[n.F13=71]="F13",n[n.F14=72]="F14",n[n.F15=73]="F15",n[n.F16=74]="F16",n[n.F17=75]="F17",n[n.F18=76]="F18",n[n.F19=77]="F19",n[n.F20=78]="F20",n[n.F21=79]="F21",n[n.F22=80]="F22",n[n.F23=81]="F23",n[n.F24=82]="F24",n[n.NumLock=83]="NumLock",n[n.ScrollLock=84]="ScrollLock",n[n.Semicolon=85]="Semicolon",n[n.Equal=86]="Equal",n[n.Comma=87]="Comma",n[n.Minus=88]="Minus",n[n.Period=89]="Period",n[n.Slash=90]="Slash",n[n.Backquote=91]="Backquote",n[n.BracketLeft=92]="BracketLeft",n[n.Backslash=93]="Backslash",n[n.BracketRight=94]="BracketRight",n[n.Quote=95]="Quote",n[n.OEM_8=96]="OEM_8",n[n.IntlBackslash=97]="IntlBackslash",n[n.Numpad0=98]="Numpad0",n[n.Numpad1=99]="Numpad1",n[n.Numpad2=100]="Numpad2",n[n.Numpad3=101]="Numpad3",n[n.Numpad4=102]="Numpad4",n[n.Numpad5=103]="Numpad5",n[n.Numpad6=104]="Numpad6",n[n.Numpad7=105]="Numpad7",n[n.Numpad8=106]="Numpad8",n[n.Numpad9=107]="Numpad9",n[n.NumpadMultiply=108]="NumpadMultiply",n[n.NumpadAdd=109]="NumpadAdd",n[n.NUMPAD_SEPARATOR=110]="NUMPAD_SEPARATOR",n[n.NumpadSubtract=111]="NumpadSubtract",n[n.NumpadDecimal=112]="NumpadDecimal",n[n.NumpadDivide=113]="NumpadDivide",n[n.KEY_IN_COMPOSITION=114]="KEY_IN_COMPOSITION",n[n.ABNT_C1=115]="ABNT_C1",n[n.ABNT_C2=116]="ABNT_C2",n[n.AudioVolumeMute=117]="AudioVolumeMute",n[n.AudioVolumeUp=118]="AudioVolumeUp",n[n.AudioVolumeDown=119]="AudioVolumeDown",n[n.BrowserSearch=120]="BrowserSearch",n[n.BrowserHome=121]="BrowserHome",n[n.BrowserBack=122]="BrowserBack",n[n.BrowserForward=123]="BrowserForward",n[n.MediaTrackNext=124]="MediaTrackNext",n[n.MediaTrackPrevious=125]="MediaTrackPrevious",n[n.MediaStop=126]="MediaStop",n[n.MediaPlayPause=127]="MediaPlayPause",n[n.LaunchMediaPlayer=128]="LaunchMediaPlayer",n[n.LaunchMail=129]="LaunchMail",n[n.LaunchApp2=130]="LaunchApp2",n[n.Clear=131]="Clear",n[n.MAX_VALUE=132]="MAX_VALUE"})(E8||(E8={}));(function(n){n[n.Hint=1]="Hint",n[n.Info=2]="Info",n[n.Warning=4]="Warning",n[n.Error=8]="Error"})(T8||(T8={}));(function(n){n[n.Unnecessary=1]="Unnecessary",n[n.Deprecated=2]="Deprecated"})(D8||(D8={}));(function(n){n[n.Inline=1]="Inline",n[n.Gutter=2]="Gutter"})(N8||(N8={}));(function(n){n[n.Normal=1]="Normal",n[n.Underlined=2]="Underlined"})(R8||(R8={}));(function(n){n[n.UNKNOWN=0]="UNKNOWN",n[n.TEXTAREA=1]="TEXTAREA",n[n.GUTTER_GLYPH_MARGIN=2]="GUTTER_GLYPH_MARGIN",n[n.GUTTER_LINE_NUMBERS=3]="GUTTER_LINE_NUMBERS",n[n.GUTTER_LINE_DECORATIONS=4]="GUTTER_LINE_DECORATIONS",n[n.GUTTER_VIEW_ZONE=5]="GUTTER_VIEW_ZONE",n[n.CONTENT_TEXT=6]="CONTENT_TEXT",n[n.CONTENT_EMPTY=7]="CONTENT_EMPTY",n[n.CONTENT_VIEW_ZONE=8]="CONTENT_VIEW_ZONE",n[n.CONTENT_WIDGET=9]="CONTENT_WIDGET",n[n.OVERVIEW_RULER=10]="OVERVIEW_RULER",n[n.SCROLLBAR=11]="SCROLLBAR",n[n.OVERLAY_WIDGET=12]="OVERLAY_WIDGET",n[n.OUTSIDE_EDITOR=13]="OUTSIDE_EDITOR"})(A8||(A8={}));(function(n){n[n.AIGenerated=1]="AIGenerated"})(M8||(M8={}));(function(n){n[n.Invoke=0]="Invoke",n[n.Automatic=1]="Automatic"})(P8||(P8={}));(function(n){n[n.TOP_RIGHT_CORNER=0]="TOP_RIGHT_CORNER",n[n.BOTTOM_RIGHT_CORNER=1]="BOTTOM_RIGHT_CORNER",n[n.TOP_CENTER=2]="TOP_CENTER"})(O8||(O8={}));(function(n){n[n.Left=1]="Left",n[n.Center=2]="Center",n[n.Right=4]="Right",n[n.Full=7]="Full"})(F8||(F8={}));(function(n){n[n.Word=0]="Word",n[n.Line=1]="Line",n[n.Suggest=2]="Suggest"})(B8||(B8={}));(function(n){n[n.Left=0]="Left",n[n.Right=1]="Right",n[n.None=2]="None",n[n.LeftOfInjectedText=3]="LeftOfInjectedText",n[n.RightOfInjectedText=4]="RightOfInjectedText"})(W8||(W8={}));(function(n){n[n.Off=0]="Off",n[n.On=1]="On",n[n.Relative=2]="Relative",n[n.Interval=3]="Interval",n[n.Custom=4]="Custom"})(H8||(H8={}));(function(n){n[n.None=0]="None",n[n.Text=1]="Text",n[n.Blocks=2]="Blocks"})(z8||(z8={}));(function(n){n[n.Smooth=0]="Smooth",n[n.Immediate=1]="Immediate"})(V8||(V8={}));(function(n){n[n.Auto=1]="Auto",n[n.Hidden=2]="Hidden",n[n.Visible=3]="Visible"})(U8||(U8={}));(function(n){n[n.LTR=0]="LTR",n[n.RTL=1]="RTL"})($8||($8={}));(function(n){n.Off="off",n.OnCode="onCode",n.On="on"})(j8||(j8={}));(function(n){n[n.Invoke=1]="Invoke",n[n.TriggerCharacter=2]="TriggerCharacter",n[n.ContentChange=3]="ContentChange"})(q8||(q8={}));(function(n){n[n.File=0]="File",n[n.Module=1]="Module",n[n.Namespace=2]="Namespace",n[n.Package=3]="Package",n[n.Class=4]="Class",n[n.Method=5]="Method",n[n.Property=6]="Property",n[n.Field=7]="Field",n[n.Constructor=8]="Constructor",n[n.Enum=9]="Enum",n[n.Interface=10]="Interface",n[n.Function=11]="Function",n[n.Variable=12]="Variable",n[n.Constant=13]="Constant",n[n.String=14]="String",n[n.Number=15]="Number",n[n.Boolean=16]="Boolean",n[n.Array=17]="Array",n[n.Object=18]="Object",n[n.Key=19]="Key",n[n.Null=20]="Null",n[n.EnumMember=21]="EnumMember",n[n.Struct=22]="Struct",n[n.Event=23]="Event",n[n.Operator=24]="Operator",n[n.TypeParameter=25]="TypeParameter"})(K8||(K8={}));(function(n){n[n.Deprecated=1]="Deprecated"})(G8||(G8={}));(function(n){n[n.Hidden=0]="Hidden",n[n.Blink=1]="Blink",n[n.Smooth=2]="Smooth",n[n.Phase=3]="Phase",n[n.Expand=4]="Expand",n[n.Solid=5]="Solid"})(Y8||(Y8={}));(function(n){n[n.Line=1]="Line",n[n.Block=2]="Block",n[n.Underline=3]="Underline",n[n.LineThin=4]="LineThin",n[n.BlockOutline=5]="BlockOutline",n[n.UnderlineThin=6]="UnderlineThin"})(Z8||(Z8={}));(function(n){n[n.AlwaysGrowsWhenTypingAtEdges=0]="AlwaysGrowsWhenTypingAtEdges",n[n.NeverGrowsWhenTypingAtEdges=1]="NeverGrowsWhenTypingAtEdges",n[n.GrowsOnlyWhenTypingBefore=2]="GrowsOnlyWhenTypingBefore",n[n.GrowsOnlyWhenTypingAfter=3]="GrowsOnlyWhenTypingAfter"})(X8||(X8={}));(function(n){n[n.None=0]="None",n[n.Same=1]="Same",n[n.Indent=2]="Indent",n[n.DeepIndent=3]="DeepIndent"})(Q8||(Q8={}))});function eB(){return{editor:void 0,languages:void 0,CancellationTokenSource:qt,Emitter:A,KeyCode:E8,KeyMod:Ine,Position:P,Range:S,Selection:Se,SelectionDirection:$8,MarkerSeverity:T8,MarkerTag:D8,Uri:Ee,Token:lp}}var Ine,Ene=k(()=>{ci();Ie();hu();Ai();qe();we();Ui();Ji();J8();Ine=class{static{this.CtrlCmd=2048}static{this.Shift=1024}static{this.Alt=512}static{this.WinCtrl=256}static chord(e,t){return Rn(e,t)}}});function NTe(n,e){let t=n;typeof t.vscodeWindowId!="number"&&Object.defineProperty(t,"vscodeWindowId",{get:()=>e})}var ri,Il=k(()=>{ri=window});function RTe(n){return n}var tB,qR,Tne=k(()=>{tB=class{constructor(e,t){this.lastCache=void 0,this.lastArgKey=void 0,typeof e=="function"?(this._fn=e,this._computeKey=RTe):(this._fn=t,this._computeKey=e.getCacheKey)}get(e){let t=this._computeKey(e);return this.lastArgKey!==t&&(this.lastArgKey=t,this.lastCache=this._fn(e)),this.lastCache}},qR=class{get cachedValues(){return this._map}constructor(e,t){this._map=new Map,this._map2=new Map,typeof e=="function"?(this._fn=e,this._computeKey=RTe):(this._fn=t,this._computeKey=e.getCacheKey)}get(e){let t=this._computeKey(e);if(this._map2.has(t))return this._map2.get(t);let i=this._fn(e);return this._map.set(e,i),this._map2.set(t,i),i}}});var or,cp=k(()=>{or=class{constructor(e){this.executor=e,this._didRun=!1}get value(){if(!this._didRun)try{this._value=this.executor()}catch(e){this._error=e}finally{this._didRun=!0}if(this._error)throw this._error;return this._value}get rawValue(){return this._value}}});function nB(n){return!n||typeof n!="string"?!0:n.trim().length===0}function dh(n,...e){return e.length===0?n:n.replace(Cot,function(t,i){let o=parseInt(i,10);return isNaN(o)||o<0||o>=e.length?t:e[o]})}function MTe(n){return n.replace(/[<>"'&]/g,e=>{switch(e){case"<":return"<";case">":return">";case'"':return""";case"'":return"'";case"&":return"&"}return e})}function gx(n){return n.replace(/[<>&]/g,function(e){switch(e){case"<":return"<";case">":return">";case"&":return"&";default:return e}})}function jr(n){return n.replace(/[\\\{\}\*\+\?\|\^\$\.\[\]\(\)]/g,"\\$&")}function PTe(n,e=" "){let t=H_(n,e);return Nne(t,e)}function H_(n,e){if(!n||!e)return n;let t=e.length;if(t===0||n.length===0)return n;let i=0;for(;n.indexOf(e,i)===i;)i=i+t;return n.substring(i)}function Nne(n,e){if(!n||!e)return n;let t=e.length,i=n.length;if(t===0||i===0)return n;let o=i,r=-1;for(;r=n.lastIndexOf(e,o-1),!(r===-1||r+t!==o);){if(r===0)return"";o=r}return n.substring(0,o)}function OTe(n){return n.replace(/[\-\\\{\}\+\?\|\^\$\.\,\[\]\(\)\#\s]/g,"\\$&").replace(/[\*]/g,".*")}function FTe(n){return n.replace(/\*/g,"")}function oB(n,e,t={}){if(!n)throw new Error("Cannot create regex from empty string");e||(n=jr(n)),t.wholeWord&&(/\B/.test(n.charAt(0))||(n="\\b"+n),/\B/.test(n.charAt(n.length-1))||(n=n+"\\b"));let i="";return t.global&&(i+="g"),t.matchCase||(i+="i"),t.multiline&&(i+="m"),t.unicode&&(i+="u"),new RegExp(n,i)}function BTe(n){return n.source==="^"||n.source==="^$"||n.source==="$"||n.source==="^\\s*$"?!1:!!(n.exec("")&&n.lastIndex===0)}function Qa(n){return n.split(/\r\n|\r|\n/)}function WTe(n){let e=[],t=n.split(/(\r\n|\r|\n)/);for(let i=0;i=0;t--){let i=n.charCodeAt(t);if(i!==32&&i!==9)return t}return-1}function _x(n,e){return ne?1:0}function rB(n,e,t=0,i=n.length,o=0,r=e.length){for(;tc)return 1}let s=i-t,a=r-o;return sa?1:0}function GR(n,e){return tL(n,e,0,n.length,0,e.length)}function tL(n,e,t=0,i=n.length,o=0,r=e.length){for(;t=128||c>=128)return rB(n.toLowerCase(),e.toLowerCase(),t,i,o,r);km(l)&&(l-=32),km(c)&&(c-=32);let d=l-c;if(d!==0)return d}let s=i-t,a=r-o;return sa?1:0}function YR(n){return n>=48&&n<=57}function km(n){return n>=97&&n<=122}function uh(n){return n>=65&&n<=90}function z_(n,e){return n.length===e.length&&tL(n,e)===0}function iL(n,e){let t=e.length;return e.length>n.length?!1:tL(n,e,0,t)===0}function kd(n,e){let t=Math.min(n.length,e.length),i;for(i=0;i1){let i=n.charCodeAt(e-2);if(to(i))return sB(i,t)}return t}function ZR(n,e){return new y1(n,e).nextGraphemeLength()}function Rne(n,e){return new y1(n,e).prevGraphemeLength()}function HTe(n,e){e>0&&Lm(n.charCodeAt(e))&&e--;let t=e+ZR(n,e);return[t-Rne(n,t),t]}function kot(){return/(?:[\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 dp(n){return Dne||(Dne=kot()),Dne.test(n)}function Im(n){return Lot.test(n)}function aB(n){return Ane.test(n)}function hh(n){return n>=11904&&n<=55215||n>=63744&&n<=64255||n>=65281&&n<=65374}function XR(n){return n>=127462&&n<=127487||n===8986||n===8987||n===9200||n===9203||n>=9728&&n<=10175||n===11088||n===11093||n>=127744&&n<=128591||n>=128640&&n<=128764||n>=128992&&n<=129008||n>=129280&&n<=129535||n>=129648&&n<=129782}function oL(n){return!!(n&&n.length>0&&n.charCodeAt(0)===65279)}function VTe(n,e=!1){return n?(e&&(n=n.replace(/\\./g,"")),n.toLowerCase()!==n):!1}function lB(n){return n=n%(2*26),n<26?String.fromCharCode(97+n):String.fromCharCode(65+n-26)}function ATe(n,e){return n===0?e!==5&&e!==7:n===2&&e===3?!1:n===4||n===2||n===3||e===4||e===2||e===3?!0:!(n===8&&(e===8||e===9||e===11||e===12)||(n===11||n===9)&&(e===9||e===10)||(n===12||n===10)&&e===10||e===5||e===13||e===7||n===1||n===13&&e===14||n===6&&e===6)}function Iot(){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 UTe(n,e){if(n===0)return 0;let t=Eot(n,e);if(t!==void 0)return t;let i=new KR(e,n);return i.prevCodePoint(),i.offset}function Eot(n,e){let t=new KR(e,n),i=t.prevCodePoint();for(;Tot(i)||i===65039||i===8419;){if(t.offset===0)return;i=t.prevCodePoint()}if(!XR(i))return;let o=t.offset;return o>0&&t.prevCodePoint()===8205&&(o=t.offset),o}function Tot(n){return 127995<=n&&n<=127999}var Cot,KR,y1,Dne,Lot,Ane,zTe,iB,cB,eL,W_,Qe=k(()=>{Tne();cp();Cot=/{(\d+)}/g;KR=class{get offset(){return this._offset}constructor(e,t=0){this._str=e,this._len=e.length,this._offset=t}setOffset(e){this._offset=e}prevCodePoint(){let e=Sot(this._str,this._offset);return this._offset-=e>=65536?2:1,e}nextCodePoint(){let e=nL(this._str,this._len,this._offset);return this._offset+=e>=65536?2:1,e}eol(){return this._offset>=this._len}},y1=class{get offset(){return this._iterator.offset}constructor(e,t=0){this._iterator=new KR(e,t)}nextGraphemeLength(){let e=iB.getInstance(),t=this._iterator,i=t.offset,o=e.getGraphemeBreakType(t.nextCodePoint());for(;!t.eol();){let r=t.offset,s=e.getGraphemeBreakType(t.nextCodePoint());if(ATe(o,s)){t.setOffset(r);break}o=s}return t.offset-i}prevGraphemeLength(){let e=iB.getInstance(),t=this._iterator,i=t.offset,o=e.getGraphemeBreakType(t.prevCodePoint());for(;t.offset>0;){let r=t.offset,s=e.getGraphemeBreakType(t.prevCodePoint());if(ATe(s,o)){t.setOffset(r);break}o=s}return i-t.offset}eol(){return this._iterator.eol()}};Lot=/^[\t\n\r\x20-\x7E]*$/;Ane=/[\u2028\u2029]/;zTe="\uFEFF";iB=class n{static{this._INSTANCE=null}static getInstance(){return n._INSTANCE||(n._INSTANCE=new n),n._INSTANCE}constructor(){this._data=Iot()}getGraphemeBreakType(e){if(e<32)return e===10?3:e===13?2:4;if(e<127)return 0;let t=this._data,i=t.length/3,o=1;for(;o<=i;)if(et[3*o+1])o=2*o+1;else return t[3*o+2];return 0}};cB="\xA0",eL=class n{static{this.ambiguousCharacterData=new or(()=>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,119846,109],"_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]}'))}static{this.cache=new tB({getCacheKey:JSON.stringify},e=>{function t(d){let u=new Map;for(let h=0;h!d.startsWith("_")&&d in r);s.length===0&&(s=["_default"]);let a;for(let d of s){let u=t(r[d]);a=o(a,u)}let l=t(r._common),c=i(l,a);return new n(c)})}static getInstance(e){return n.cache.get(Array.from(e))}static{this._locales=new or(()=>Object.keys(n.ambiguousCharacterData.value).filter(e=>!e.startsWith("_")))}static getLocales(){return n._locales.value}constructor(e){this.confusableDictionary=e}isAmbiguous(e){return this.confusableDictionary.has(e)}getPrimaryConfusable(e){return this.confusableDictionary.get(e)}getConfusableCodePoints(){return new Set(this.confusableDictionary.keys())}},W_=class n{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{this._data=void 0}static getData(){return this._data||(this._data=new Set(n.getRawData())),this._data}static isInvisibleCharacter(e){return n.getData().has(e)}static get codePoints(){return n.getData()}}});var $Te=k(()=>{});function Pne(n,e,t){typeof e=="string"&&(e=n.matchMedia(e)),e.addEventListener("change",t)}function jTe(n){return Mne.INSTANCE.getZoomFactor(n)}function qTe(){return dB}var Mne,rL,ls,up,bx,Ld,uB,E5t,One,dB,Fc=k(()=>{Il();Mne=class n{constructor(){this.mapWindowIdToZoomFactor=new Map}static{this.INSTANCE=new n}getZoomFactor(e){return this.mapWindowIdToZoomFactor.get(this.getWindowId(e))??1}getWindowId(e){return e.vscodeWindowId}};rL=navigator.userAgent,ls=rL.indexOf("Firefox")>=0,up=rL.indexOf("AppleWebKit")>=0,bx=rL.indexOf("Chrome")>=0,Ld=!bx&&rL.indexOf("Safari")>=0,uB=!bx&&!Ld&&up,E5t=rL.indexOf("Electron/")>=0,One=rL.indexOf("Android")>=0,dB=!1;if(typeof ri.matchMedia=="function"){let n=ri.matchMedia("(display-mode: standalone) or (display-mode: window-controls-overlay)"),e=ri.matchMedia("(display-mode: fullscreen)");dB=n.matches,Pne(ri,n,({matches:t})=>{dB&&e.matches||(dB=t)})}});var sL,hB=k(()=>{Fc();Il();Bt();sL={clipboard:{writeText:Pc||document.queryCommandSupported&&document.queryCommandSupported("copy")||!!(navigator&&navigator.clipboard&&navigator.clipboard.writeText),readText:Pc||!!(navigator&&navigator.clipboard&&navigator.clipboard.readText)},keyboard:Pc||qTe()?0:navigator.keyboard||Ld?1:2,touch:"ontouchstart"in ri||navigator.maxTouchPoints>0,pointerEvents:ri.PointerEvent&&("ontouchstart"in ri||navigator.maxTouchPoints>0)}});function JR(n,e){if(typeof n=="number"){if(n===0)return null;let t=(n&65535)>>>0,i=(n&4294901760)>>>16;return i!==0?new QR([fB(t,e),fB(i,e)]):new QR([fB(t,e)])}else{let t=[];for(let i=0;i{je();fh=class n{constructor(e,t,i,o,r){this.ctrlKey=e,this.shiftKey=t,this.altKey=i,this.metaKey=o,this.keyCode=r}equals(e){return e instanceof n&&this.ctrlKey===e.ctrlKey&&this.shiftKey===e.shiftKey&&this.altKey===e.altKey&&this.metaKey===e.metaKey&&this.keyCode===e.keyCode}isModifierKey(){return this.keyCode===0||this.keyCode===5||this.keyCode===57||this.keyCode===6||this.keyCode===4}isDuplicateModifierCase(){return this.ctrlKey&&this.keyCode===5||this.shiftKey&&this.keyCode===4||this.altKey&&this.keyCode===6||this.metaKey&&this.keyCode===57}},QR=class{constructor(e){if(e.length===0)throw js("chords");this.chords=e}},pB=class{constructor(e,t,i,o,r,s){this.ctrlKey=e,this.shiftKey=t,this.altKey=i,this.metaKey=o,this.keyLabel=r,this.keyAriaLabel=s}},mB=class{}});function Dot(n){if(n.charCode){let t=String.fromCharCode(n.charCode).toUpperCase();return hf.fromString(t)}let e=n.keyCode;if(e===3)return 7;if(ls)switch(e){case 59:return 85;case 60:if(Qn)return 97;break;case 61:return 86;case 107:return 109;case 109:return 111;case 173:return 88;case 224:if(dt)return 57;break}else if(up){if(dt&&e===93)return 57;if(!dt&&e===92)return 57}return vne[e]||0}var Not,Rot,Aot,Mot,Xt,Ks=k(()=>{Fc();hu();S1();Bt();Not=dt?256:2048,Rot=512,Aot=1024,Mot=dt?2048:256,Xt=class{constructor(e){this._standardKeyboardEventBrand=!0;let t=e;this.browserEvent=t,this.target=t.target,this.ctrlKey=t.ctrlKey,this.shiftKey=t.shiftKey,this.altKey=t.altKey,this.metaKey=t.metaKey,this.altGraphKey=t.getModifierState?.("AltGraph"),this.keyCode=Dot(t),this.code=t.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._asKeyCodeChord=this._computeKeyCodeChord()}preventDefault(){this.browserEvent&&this.browserEvent.preventDefault&&this.browserEvent.preventDefault()}stopPropagation(){this.browserEvent&&this.browserEvent.stopPropagation&&this.browserEvent.stopPropagation()}toKeyCodeChord(){return this._asKeyCodeChord}equals(e){return this._asKeybinding===e}_computeKeybinding(){let e=0;this.keyCode!==5&&this.keyCode!==4&&this.keyCode!==6&&this.keyCode!==57&&(e=this.keyCode);let t=0;return this.ctrlKey&&(t|=Not),this.altKey&&(t|=Rot),this.shiftKey&&(t|=Aot),this.metaKey&&(t|=Mot),t|=e,t}_computeKeyCodeChord(){let e=0;return this.keyCode!==5&&this.keyCode!==4&&this.keyCode!==6&&this.keyCode!==57&&(e=this.keyCode),new fh(this.ctrlKey,this.shiftKey,this.altKey,this.metaKey,e)}}});function Pot(n){if(!n.parent||n.parent===n)return null;try{let e=n.location,t=n.parent.location;if(e.origin!=="null"&&t.origin!=="null"&&e.origin!==t.origin)return null}catch{return null}return n.parent}var KTe,gB,GTe=k(()=>{KTe=new WeakMap;gB=class{static getSameOriginWindowChain(e){let t=KTe.get(e);if(!t){t=[],KTe.set(e,t);let i=e,o;do o=Pot(i),o?t.push({window:new WeakRef(i),iframeElement:i.frameElement||null}):t.push({window:new WeakRef(i),iframeElement:null}),i=o;while(i)}return t.slice(0)}static getPositionOfChildWindowRelativeToAncestorWindow(e,t){if(!t||e===t)return{top:0,left:0};let i=0,o=0,r=this.getSameOriginWindowChain(e);for(let s of r){let a=s.window.deref();if(i+=a?.scrollY??0,o+=a?.scrollX??0,a===t||!s.iframeElement)break;let l=s.iframeElement.getBoundingClientRect();i+=l.top,o+=l.left}return{top:i,left:o}}}});var cs,ph,pu=k(()=>{Fc();GTe();Bt();cs=class{constructor(e,t){this.timestamp=Date.now(),this.browserEvent=t,this.leftButton=t.button===0,this.middleButton=t.button===1,this.rightButton=t.button===2,this.buttons=t.buttons,this.target=t.target,this.detail=t.detail||1,t.type==="dblclick"&&(this.detail=2),this.ctrlKey=t.ctrlKey,this.shiftKey=t.shiftKey,this.altKey=t.altKey,this.metaKey=t.metaKey,typeof t.pageX=="number"?(this.posx=t.pageX,this.posy=t.pageY):(this.posx=t.clientX+this.target.ownerDocument.body.scrollLeft+this.target.ownerDocument.documentElement.scrollLeft,this.posy=t.clientY+this.target.ownerDocument.body.scrollTop+this.target.ownerDocument.documentElement.scrollTop);let i=gB.getPositionOfChildWindowRelativeToAncestorWindow(e,t.view);this.posx-=i.left,this.posy-=i.top}preventDefault(){this.browserEvent.preventDefault()}stopPropagation(){this.browserEvent.stopPropagation()}},ph=class{constructor(e,t=0,i=0){this.browserEvent=e||null,this.target=e?e.target||e.targetNode||e.srcElement:null,this.deltaY=i,this.deltaX=t;let o=!1;if(bx){let r=navigator.userAgent.match(/Chrome\/(\d+)/);o=(r?parseInt(r[1]):123)<=122}if(e){let r=e,s=e,a=e.view?.devicePixelRatio||1;if(typeof r.wheelDeltaY<"u")o?this.deltaY=r.wheelDeltaY/(120*a):this.deltaY=r.wheelDeltaY/120;else if(typeof s.VERTICAL_AXIS<"u"&&s.axis===s.VERTICAL_AXIS)this.deltaY=-s.detail/3;else if(e.type==="wheel"){let l=e;l.deltaMode===l.DOM_DELTA_LINE?ls&&!dt?this.deltaY=-e.deltaY/3:this.deltaY=-e.deltaY:this.deltaY=-e.deltaY/40}if(typeof r.wheelDeltaX<"u")Ld&&kn?this.deltaX=-(r.wheelDeltaX/120):o?this.deltaX=r.wheelDeltaX/(120*a):this.deltaX=r.wheelDeltaX/120;else if(typeof s.HORIZONTAL_AXIS<"u"&&s.axis===s.HORIZONTAL_AXIS)this.deltaX=-e.detail/3;else if(e.type==="wheel"){let l=e;l.deltaMode===l.DOM_DELTA_LINE?ls&&!dt?this.deltaX=-e.deltaX/3:this.deltaX=-e.deltaX:this.deltaX=-e.deltaX/40}this.deltaY===0&&this.deltaX===0&&e.wheelDelta&&(o?this.deltaY=e.wheelDelta/(120*a):this.deltaY=e.wheelDelta/120)}}preventDefault(){this.browserEvent?.preventDefault()}stopPropagation(){this.browserEvent?.stopPropagation()}}});var _B,Fne=k(()=>{_B=Symbol("MicrotaskDelay")});function xB(n){return!!n&&typeof n.then=="function"}function sn(n){let e=new qt,t=n(e.token),i=new Promise((o,r)=>{let s=e.token.onCancellationRequested(()=>{s.dispose(),r(new ga)});Promise.resolve(t).then(a=>{s.dispose(),e.dispose(),o(a)},a=>{s.dispose(),e.dispose(),r(a)})});return new class{cancel(){e.cancel(),e.dispose()}then(o,r){return i.then(o,r)}catch(o){return this.then(void 0,o)}finally(o){return i.finally(o)}}}function Em(n,e,t){return new Promise((i,o)=>{let r=e.onCancellationRequested(()=>{r.dispose(),i(t)});n.then(i,o).finally(()=>r.dispose())})}function oc(n,e){return e?new Promise((t,i)=>{let o=setTimeout(()=>{r.dispose(),t()},n),r=e.onCancellationRequested(()=>{clearTimeout(o),r.dispose(),i(new ga)})}):sn(t=>oc(n,t))}function gu(n,e=0,t){let i=setTimeout(()=>{n(),t&&o.dispose()},e),o=ge(()=>{clearTimeout(i),t?.deleteAndLeak(o)});return t?.add(o),o}function tA(n,e=i=>!!i,t=null){let i=0,o=n.length,r=()=>{if(i>=o)return Promise.resolve(t);let s=n[i++];return Promise.resolve(s()).then(l=>e(l)?Promise.resolve(l):r())};return r()}function YTe(n){let e=new qt,t=n(e.token);return new Wne(e,async i=>{let o=e.token.onCancellationRequested(()=>{o.dispose(),e.dispose(),i.reject(new ga)});try{for await(let r of t){if(e.token.isCancellationRequested)return;i.emitOne(r)}o.dispose(),e.dispose()}catch(r){o.dispose(),e.dispose(),i.reject(r)}})}var Bne,Oot,Fot,gr,lL,_r,vx,Lt,Hne,aL,eA,bB,mu,vB,Ja,Wne,ft=k(()=>{ci();je();Ie();j();Bt();Fne();Bne=class{constructor(){this.isDisposed=!1,this.activePromise=null,this.queuedPromise=null,this.queuedPromiseFactory=null}queue(e){if(this.isDisposed)return Promise.reject(new Error("Throttler is disposed"));if(this.activePromise){if(this.queuedPromiseFactory=e,!this.queuedPromise){let t=()=>{if(this.queuedPromise=null,this.isDisposed)return;let i=this.queue(this.queuedPromiseFactory);return this.queuedPromiseFactory=null,i};this.queuedPromise=new Promise(i=>{this.activePromise.then(t,t).then(i)})}return new Promise((t,i)=>{this.queuedPromise.then(t,i)})}return this.activePromise=e(),new Promise((t,i)=>{this.activePromise.then(o=>{this.activePromise=null,t(o)},o=>{this.activePromise=null,i(o)})})}dispose(){this.isDisposed=!0}},Oot=(n,e)=>{let t=!0,i=setTimeout(()=>{t=!1,e()},n);return{isTriggered:()=>t,dispose:()=>{clearTimeout(i),t=!1}}},Fot=n=>{let e=!0;return queueMicrotask(()=>{e&&(e=!1,n())}),{isTriggered:()=>e,dispose:()=>{e=!1}}},gr=class{constructor(e){this.defaultDelay=e,this.deferred=null,this.completionPromise=null,this.doResolve=null,this.doReject=null,this.task=null}trigger(e,t=this.defaultDelay){this.task=e,this.cancelTimeout(),this.completionPromise||(this.completionPromise=new Promise((o,r)=>{this.doResolve=o,this.doReject=r}).then(()=>{if(this.completionPromise=null,this.doResolve=null,this.task){let o=this.task;return this.task=null,o()}}));let i=()=>{this.deferred=null,this.doResolve?.(null)};return this.deferred=t===_B?Fot(i):Oot(t,i),this.completionPromise}isTriggered(){return!!this.deferred?.isTriggered()}cancel(){this.cancelTimeout(),this.completionPromise&&(this.doReject?.(new ga),this.completionPromise=null)}cancelTimeout(){this.deferred?.dispose(),this.deferred=null}dispose(){this.cancel()}},lL=class{constructor(e){this.delayer=new gr(e),this.throttler=new Bne}trigger(e,t){return this.delayer.trigger(()=>this.throttler.queue(e),t)}cancel(){this.delayer.cancel()}dispose(){this.delayer.dispose(),this.throttler.dispose()}};_r=class{constructor(e,t){this._isDisposed=!1,this._token=-1,typeof e=="function"&&typeof t=="number"&&this.setIfNotSet(e,t)}dispose(){this.cancel(),this._isDisposed=!0}cancel(){this._token!==-1&&(clearTimeout(this._token),this._token=-1)}cancelAndSet(e,t){if(this._isDisposed)throw new Nt("Calling 'cancelAndSet' on a disposed TimeoutTimer");this.cancel(),this._token=setTimeout(()=>{this._token=-1,e()},t)}setIfNotSet(e,t){if(this._isDisposed)throw new Nt("Calling 'setIfNotSet' on a disposed TimeoutTimer");this._token===-1&&(this._token=setTimeout(()=>{this._token=-1,e()},t))}},vx=class{constructor(){this.disposable=void 0,this.isDisposed=!1}cancel(){this.disposable?.dispose(),this.disposable=void 0}cancelAndSet(e,t,i=globalThis){if(this.isDisposed)throw new Nt("Calling 'cancelAndSet' on a disposed IntervalTimer");this.cancel();let o=i.setInterval(()=>{e()},t);this.disposable=ge(()=>{i.clearInterval(o),this.disposable=void 0})}dispose(){this.cancel(),this.isDisposed=!0}},Lt=class{constructor(e,t){this.timeoutToken=-1,this.runner=e,this.timeout=t,this.timeoutHandler=this.onTimeout.bind(this)}dispose(){this.cancel(),this.runner=null}cancel(){this.isScheduled()&&(clearTimeout(this.timeoutToken),this.timeoutToken=-1)}schedule(e=this.timeout){this.cancel(),this.timeoutToken=setTimeout(this.timeoutHandler,e)}get delay(){return this.timeout}set delay(e){this.timeout=e}isScheduled(){return this.timeoutToken!==-1}onTimeout(){this.timeoutToken=-1,this.runner&&this.doRun()}doRun(){this.runner?.()}};(function(){typeof globalThis.requestIdleCallback!="function"||typeof globalThis.cancelIdleCallback!="function"?aL=(n,e)=>{F3(()=>{if(t)return;let i=Date.now()+15;e(Object.freeze({didTimeout:!0,timeRemaining(){return Math.max(0,i-Date.now())}}))});let t=!1;return{dispose(){t||(t=!0)}}}:aL=(n,e,t)=>{let i=n.requestIdleCallback(e,typeof t=="number"?{timeout:t}:void 0),o=!1;return{dispose(){o||(o=!0,n.cancelIdleCallback(i))}}},Hne=n=>aL(globalThis,n)})();eA=class{constructor(e,t){this._didRun=!1,this._executor=()=>{try{this._value=t()}catch(i){this._error=i}finally{this._didRun=!0}},this._handle=aL(e,()=>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}},bB=class extends eA{constructor(e){super(globalThis,e)}},mu=class{get isRejected(){return this.outcome?.outcome===1}get isSettled(){return!!this.outcome}constructor(){this.p=new Promise((e,t)=>{this.completeCallback=e,this.errorCallback=t})}complete(e){return new Promise(t=>{this.completeCallback(e),this.outcome={outcome:0,value:e},t()})}error(e){return new Promise(t=>{this.errorCallback(e),this.outcome={outcome:1,value:e},t()})}cancel(){return this.error(new ga)}};(function(n){async function e(i){let o,r=await Promise.all(i.map(s=>s.then(a=>a,a=>{o||(o=a)})));if(typeof o<"u")throw o;return r}n.settled=e;function t(i){return new Promise(async(o,r)=>{try{await i(o,r)}catch(s){r(s)}})}n.withAsyncBody=t})(vB||(vB={}));Ja=class n{static fromArray(e){return new n(t=>{t.emitMany(e)})}static fromPromise(e){return new n(async t=>{t.emitMany(await e)})}static fromPromises(e){return new n(async t=>{await Promise.all(e.map(async i=>t.emitOne(await i)))})}static merge(e){return new n(async t=>{await Promise.all(e.map(async i=>{for await(let o of i)t.emitOne(o)}))})}static{this.EMPTY=n.fromArray([])}constructor(e,t){this._state=0,this._results=[],this._error=null,this._onReturn=t,this._onStateChanged=new A,queueMicrotask(async()=>{let i={emitOne:o=>this.emitOne(o),emitMany:o=>this.emitMany(o),reject:o=>this.reject(o)};try{await Promise.resolve(e(i)),this.resolve()}catch(o){this.reject(o)}finally{i.emitOne=void 0,i.emitMany=void 0,i.reject=void 0}})}[Symbol.asyncIterator](){let e=0;return{next:async()=>{do{if(this._state===2)throw this._error;if(e(this._onReturn?.(),{done:!0,value:void 0})}}static map(e,t){return new n(async i=>{for await(let o of e)i.emitOne(t(o))})}map(e){return n.map(this,e)}static filter(e,t){return new n(async i=>{for await(let o of e)t(o)&&i.emitOne(o)})}filter(e){return n.filter(this,e)}static coalesce(e){return n.filter(e,t=>!!t)}coalesce(){return n.coalesce(this)}static async toPromise(e){let t=[];for await(let i of e)t.push(i);return t}toPromise(){return n.toPromise(this)}emitOne(e){this._state===0&&(this._results.push(e),this._onStateChanged.fire())}emitMany(e){this._state===0&&(this._results=this._results.concat(e),this._onStateChanged.fire())}resolve(){this._state===0&&(this._state=1,this._onStateChanged.fire())}reject(e){this._state===0&&(this._state=2,this._error=e,this._onStateChanged.fire())}},Wne=class extends Ja{constructor(e,t){super(t),this._source=e}cancel(){this._source.cancel()}}});function mh(n){return function(e){for(var t=arguments.length,i=new Array(t>1?t-1:0),o=1;o2&&arguments[2]!==void 0?arguments[2]:CB;ZTe&&ZTe(n,null);let i=e.length;for(;i--;){let o=e[i];if(typeof o=="string"){let r=t(o);r!==o&&(Bot(e)||(e[i]=r),o=r)}n[o]=!0}return n}function $ot(n){for(let e=0;e0&&arguments[0]!==void 0?arguments[0]:trt(),e=Zt=>lDe(Zt);if(e.version="3.1.7",e.removed=[],!n||!n.document||n.document.nodeType!==sA.document)return e.isSupported=!1,e;let{document:t}=n,i=t,o=i.currentScript,{DocumentFragment:r,HTMLTemplateElement:s,Node:a,Element:l,NodeFilter:c,NamedNodeMap:d=n.NamedNodeMap||n.MozNamedAttrMap,HTMLFormElement:u,DOMParser:h,trustedTypes:f}=n,p=l.prototype,g=rA(p,"cloneNode"),_=rA(p,"remove"),b=rA(p,"nextSibling"),v=rA(p,"childNodes"),x=rA(p,"parentNode");if(typeof s=="function"){let Zt=t.createElement("template");Zt.content&&Zt.content.ownerDocument&&(t=Zt.content.ownerDocument)}let w,y="",{implementation:C,createNodeIterator:L,createDocumentFragment:E,getElementsByTagName:N}=t,{importNode:M}=i,F={};e.isSupported=typeof oDe=="function"&&typeof x=="function"&&C&&C.createHTMLDocument!==void 0;let{MUSTACHE_EXPR:q,ERB_EXPR:te,TMPLIT_EXPR:$,DATA_ATTR:z,ARIA_ATTR:ae,IS_SCRIPT_OR_DATA:X,ATTR_WHITESPACE:ue,CUSTOM_ELEMENT:ce}=nDe,{IS_ALLOWED_URI:B}=nDe,Je=null,ni=In({},[...JTe,...Vne,...Une,...$ne,...eDe]),K=null,Ni=In({},[...tDe,...jne,...iDe,...yB]),ui=Object.seal(rDe(null,{tagNameCheck:{writable:!0,configurable:!1,enumerable:!0,value:null},attributeNameCheck:{writable:!0,configurable:!1,enumerable:!0,value:null},allowCustomizedBuiltInElements:{writable:!0,configurable:!1,enumerable:!0,value:!1}})),po=null,Jr=null,Ri=!0,vs=!0,da=!1,Sc=!0,ql=!1,Yf=!0,Kl=!1,sm=!1,am=!1,Yu=!1,gt=!1,Ii=!1,un=!0,Ao=!1,Tr="user-content-",Hr=!0,Hs=!1,Gl={},Re=null,nt=In({},["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"]),Ti=null,qi=In({},["audio","video","img","source","image","track"]),Cn=null,ur=In({},["alt","class","for","id","label","name","pattern","placeholder","role","summary","title","value","style","xmlns"]),fl="http://www.w3.org/1998/Math/MathML",qa="http://www.w3.org/2000/svg",er="http://www.w3.org/1999/xhtml",pl=er,ua=!1,ml=null,Xi=In({},[fl,qa,er],zne),Ey=null,RX=["application/xhtml+xml","text/html"],AX="text/html",ha=null,bv=null,MX=t.createElement("form"),X4=function(se){return se instanceof RegExp||se instanceof Function},nN=function(){let se=arguments.length>0&&arguments[0]!==void 0?arguments[0]:{};if(!(bv&&bv===se)){if((!se||typeof se!="object")&&(se={}),se=k1(se),Ey=RX.indexOf(se.PARSER_MEDIA_TYPE)===-1?AX:se.PARSER_MEDIA_TYPE,ha=Ey==="application/xhtml+xml"?zne:CB,Je=hp(se,"ALLOWED_TAGS")?In({},se.ALLOWED_TAGS,ha):ni,K=hp(se,"ALLOWED_ATTR")?In({},se.ALLOWED_ATTR,ha):Ni,ml=hp(se,"ALLOWED_NAMESPACES")?In({},se.ALLOWED_NAMESPACES,zne):Xi,Cn=hp(se,"ADD_URI_SAFE_ATTR")?In(k1(ur),se.ADD_URI_SAFE_ATTR,ha):ur,Ti=hp(se,"ADD_DATA_URI_TAGS")?In(k1(qi),se.ADD_DATA_URI_TAGS,ha):qi,Re=hp(se,"FORBID_CONTENTS")?In({},se.FORBID_CONTENTS,ha):nt,po=hp(se,"FORBID_TAGS")?In({},se.FORBID_TAGS,ha):{},Jr=hp(se,"FORBID_ATTR")?In({},se.FORBID_ATTR,ha):{},Gl=hp(se,"USE_PROFILES")?se.USE_PROFILES:!1,Ri=se.ALLOW_ARIA_ATTR!==!1,vs=se.ALLOW_DATA_ATTR!==!1,da=se.ALLOW_UNKNOWN_PROTOCOLS||!1,Sc=se.ALLOW_SELF_CLOSE_IN_ATTR!==!1,ql=se.SAFE_FOR_TEMPLATES||!1,Yf=se.SAFE_FOR_XML!==!1,Kl=se.WHOLE_DOCUMENT||!1,Yu=se.RETURN_DOM||!1,gt=se.RETURN_DOM_FRAGMENT||!1,Ii=se.RETURN_TRUSTED_TYPE||!1,am=se.FORCE_BODY||!1,un=se.SANITIZE_DOM!==!1,Ao=se.SANITIZE_NAMED_PROPS||!1,Hr=se.KEEP_CONTENT!==!1,Hs=se.IN_PLACE||!1,B=se.ALLOWED_URI_REGEXP||sDe,pl=se.NAMESPACE||er,ui=se.CUSTOM_ELEMENT_HANDLING||{},se.CUSTOM_ELEMENT_HANDLING&&X4(se.CUSTOM_ELEMENT_HANDLING.tagNameCheck)&&(ui.tagNameCheck=se.CUSTOM_ELEMENT_HANDLING.tagNameCheck),se.CUSTOM_ELEMENT_HANDLING&&X4(se.CUSTOM_ELEMENT_HANDLING.attributeNameCheck)&&(ui.attributeNameCheck=se.CUSTOM_ELEMENT_HANDLING.attributeNameCheck),se.CUSTOM_ELEMENT_HANDLING&&typeof se.CUSTOM_ELEMENT_HANDLING.allowCustomizedBuiltInElements=="boolean"&&(ui.allowCustomizedBuiltInElements=se.CUSTOM_ELEMENT_HANDLING.allowCustomizedBuiltInElements),ql&&(vs=!1),gt&&(Yu=!0),Gl&&(Je=In({},eDe),K=[],Gl.html===!0&&(In(Je,JTe),In(K,tDe)),Gl.svg===!0&&(In(Je,Vne),In(K,jne),In(K,yB)),Gl.svgFilters===!0&&(In(Je,Une),In(K,jne),In(K,yB)),Gl.mathMl===!0&&(In(Je,$ne),In(K,iDe),In(K,yB))),se.ADD_TAGS&&(Je===ni&&(Je=k1(Je)),In(Je,se.ADD_TAGS,ha)),se.ADD_ATTR&&(K===Ni&&(K=k1(K)),In(K,se.ADD_ATTR,ha)),se.ADD_URI_SAFE_ATTR&&In(Cn,se.ADD_URI_SAFE_ATTR,ha),se.FORBID_CONTENTS&&(Re===nt&&(Re=k1(Re)),In(Re,se.FORBID_CONTENTS,ha)),Hr&&(Je["#text"]=!0),Kl&&In(Je,["html","head","body"]),Je.table&&(In(Je,["tbody"]),delete po.tbody),se.TRUSTED_TYPES_POLICY){if(typeof se.TRUSTED_TYPES_POLICY.createHTML!="function")throw oA('TRUSTED_TYPES_POLICY configuration option must provide a "createHTML" hook.');if(typeof se.TRUSTED_TYPES_POLICY.createScriptURL!="function")throw oA('TRUSTED_TYPES_POLICY configuration option must provide a "createScriptURL" hook.');w=se.TRUSTED_TYPES_POLICY,y=w.createHTML("")}else w===void 0&&(w=irt(f,o)),w!==null&&typeof y=="string"&&(y=w.createHTML(""));Ed&&Ed(se),bv=se}},wi=In({},["mi","mo","mn","ms","mtext"]),O=In({},["annotation-xml"]),W=In({},["title","style","font","a","script"]),V=In({},[...Vne,...Une,...jot]),G=In({},[...$ne,...qot]),ie=function(se){let ot=x(se);(!ot||!ot.tagName)&&(ot={namespaceURI:pl,tagName:"template"});let Vt=CB(se.tagName),hr=CB(ot.tagName);return ml[se.namespaceURI]?se.namespaceURI===qa?ot.namespaceURI===er?Vt==="svg":ot.namespaceURI===fl?Vt==="svg"&&(hr==="annotation-xml"||wi[hr]):!!V[Vt]:se.namespaceURI===fl?ot.namespaceURI===er?Vt==="math":ot.namespaceURI===qa?Vt==="math"&&O[hr]:!!G[Vt]:se.namespaceURI===er?ot.namespaceURI===qa&&!O[hr]||ot.namespaceURI===fl&&!wi[hr]?!1:!G[Vt]&&(W[Vt]||!V[Vt]):!!(Ey==="application/xhtml+xml"&&ml[se.namespaceURI]):!1},xe=function(se){iA(e.removed,{element:se});try{x(se).removeChild(se)}catch{_(se)}},Ne=function(se,ot){try{iA(e.removed,{attribute:ot.getAttributeNode(se),from:ot})}catch{iA(e.removed,{attribute:null,from:ot})}if(ot.removeAttribute(se),se==="is"&&!K[se])if(Yu||gt)try{xe(ot)}catch{}else try{ot.setAttribute(se,"")}catch{}},pt=function(se){let ot=null,Vt=null;if(am)se=""+se;else{let Yl=QTe(se,/^[\r\n\t ]+/);Vt=Yl&&Yl[0]}Ey==="application/xhtml+xml"&&pl===er&&(se=''+se+"");let hr=w?w.createHTML(se):se;if(pl===er)try{ot=new h().parseFromString(hr,Ey)}catch{}if(!ot||!ot.documentElement){ot=C.createDocument(pl,"template",null);try{ot.documentElement.innerHTML=ua?y:hr}catch{}}let kc=ot.body||ot.documentElement;return se&&Vt&&kc.insertBefore(t.createTextNode(Vt),kc.childNodes[0]||null),pl===er?N.call(ot,Kl?"html":"body")[0]:Kl?ot.documentElement:kc},Tt=function(se){return L.call(se.ownerDocument||se,se,c.SHOW_ELEMENT|c.SHOW_COMMENT|c.SHOW_TEXT|c.SHOW_PROCESSING_INSTRUCTION|c.SHOW_CDATA_SECTION,null)},hi=function(se){return se instanceof u&&(typeof se.nodeName!="string"||typeof se.textContent!="string"||typeof se.removeChild!="function"||!(se.attributes instanceof d)||typeof se.removeAttribute!="function"||typeof se.setAttribute!="function"||typeof se.namespaceURI!="string"||typeof se.insertBefore!="function"||typeof se.hasChildNodes!="function")},mn=function(se){return typeof a=="function"&&se instanceof a},Tn=function(se,ot,Vt){F[se]&&wB(F[se],hr=>{hr.call(e,ot,Vt,bv)})},xs=function(se){let ot=null;if(Tn("beforeSanitizeElements",se,null),hi(se))return xe(se),!0;let Vt=ha(se.nodeName);if(Tn("uponSanitizeElement",se,{tagName:Vt,allowedTags:Je}),se.hasChildNodes()&&!mn(se.firstElementChild)&&Id(/<[/\w]/g,se.innerHTML)&&Id(/<[/\w]/g,se.textContent)||se.nodeType===sA.progressingInstruction||Yf&&se.nodeType===sA.comment&&Id(/<[/\w]/g,se.data))return xe(se),!0;if(!Je[Vt]||po[Vt]){if(!po[Vt]&&fd(Vt)&&(ui.tagNameCheck instanceof RegExp&&Id(ui.tagNameCheck,Vt)||ui.tagNameCheck instanceof Function&&ui.tagNameCheck(Vt)))return!1;if(Hr&&!Re[Vt]){let hr=x(se)||se.parentNode,kc=v(se)||se.childNodes;if(kc&&hr){let Yl=kc.length;for(let Qd=Yl-1;Qd>=0;--Qd){let lm=g(kc[Qd],!0);lm.__removalCount=(se.__removalCount||0)+1,hr.insertBefore(lm,b(se))}}}return xe(se),!0}return se instanceof l&&!ie(se)||(Vt==="noscript"||Vt==="noembed"||Vt==="noframes")&&Id(/<\/no(script|embed|frames)/i,se.innerHTML)?(xe(se),!0):(ql&&se.nodeType===sA.text&&(ot=se.textContent,wB([q,te,$],hr=>{ot=nA(ot,hr," ")}),se.textContent!==ot&&(iA(e.removed,{element:se.cloneNode()}),se.textContent=ot)),Tn("afterSanitizeElements",se,null),!1)},qo=function(se,ot,Vt){if(un&&(ot==="id"||ot==="name")&&(Vt in t||Vt in MX))return!1;if(!(vs&&!Jr[ot]&&Id(z,ot))){if(!(Ri&&Id(ae,ot))){if(!K[ot]||Jr[ot]){if(!(fd(se)&&(ui.tagNameCheck instanceof RegExp&&Id(ui.tagNameCheck,se)||ui.tagNameCheck instanceof Function&&ui.tagNameCheck(se))&&(ui.attributeNameCheck instanceof RegExp&&Id(ui.attributeNameCheck,ot)||ui.attributeNameCheck instanceof Function&&ui.attributeNameCheck(ot))||ot==="is"&&ui.allowCustomizedBuiltInElements&&(ui.tagNameCheck instanceof RegExp&&Id(ui.tagNameCheck,Vt)||ui.tagNameCheck instanceof Function&&ui.tagNameCheck(Vt))))return!1}else if(!Cn[ot]){if(!Id(B,nA(Vt,ue,""))){if(!((ot==="src"||ot==="xlink:href"||ot==="href")&&se!=="script"&&zot(Vt,"data:")===0&&Ti[se])){if(!(da&&!Id(X,nA(Vt,ue,"")))){if(Vt)return!1}}}}}}return!0},fd=function(se){return se!=="annotation-xml"&&QTe(se,ce)},Zu=function(se){Tn("beforeSanitizeAttributes",se,null);let{attributes:ot}=se;if(!ot)return;let Vt={attrName:"",attrValue:"",keepAttr:!0,allowedAttributes:K},hr=ot.length;for(;hr--;){let kc=ot[hr],{name:Yl,namespaceURI:Qd,value:lm}=kc,rN=ha(Yl),pd=Yl==="value"?lm:Vot(lm);if(Vt.attrName=rN,Vt.attrValue=pd,Vt.keepAttr=!0,Vt.forceKeepAttr=void 0,Tn("uponSanitizeAttribute",se,Vt),pd=Vt.attrValue,Vt.forceKeepAttr||(Ne(Yl,se),!Vt.keepAttr))continue;if(!Sc&&Id(/\/>/i,pd)){Ne(Yl,se);continue}ql&&wB([q,te,$],d1e=>{pd=nA(pd,d1e," ")});let c1e=ha(se.nodeName);if(qo(c1e,rN,pd)){if(Ao&&(rN==="id"||rN==="name")&&(Ne(Yl,se),pd=Tr+pd),Yf&&Id(/((--!?|])>)|<\/(style|title)/i,pd)){Ne(Yl,se);continue}if(w&&typeof f=="object"&&typeof f.getAttributeType=="function"&&!Qd)switch(f.getAttributeType(c1e,rN)){case"TrustedHTML":{pd=w.createHTML(pd);break}case"TrustedScriptURL":{pd=w.createScriptURL(pd);break}}try{Qd?se.setAttributeNS(Qd,Yl,pd):se.setAttribute(Yl,pd),hi(se)?xe(se):XTe(e.removed)}catch{}}}Tn("afterSanitizeAttributes",se,null)},oN=function Zt(se){let ot=null,Vt=Tt(se);for(Tn("beforeSanitizeShadowDOM",se,null);ot=Vt.nextNode();)Tn("uponSanitizeShadowNode",ot,null),!xs(ot)&&(ot.content instanceof r&&Zt(ot.content),Zu(ot));Tn("afterSanitizeShadowDOM",se,null)};return e.sanitize=function(Zt){let se=arguments.length>1&&arguments[1]!==void 0?arguments[1]:{},ot=null,Vt=null,hr=null,kc=null;if(ua=!Zt,ua&&(Zt=""),typeof Zt!="string"&&!mn(Zt))if(typeof Zt.toString=="function"){if(Zt=Zt.toString(),typeof Zt!="string")throw oA("dirty is not a string, aborting")}else throw oA("toString is not a function");if(!e.isSupported)return Zt;if(sm||nN(se),e.removed=[],typeof Zt=="string"&&(Hs=!1),Hs){if(Zt.nodeName){let lm=ha(Zt.nodeName);if(!Je[lm]||po[lm])throw oA("root node is forbidden and cannot be sanitized in-place")}}else if(Zt instanceof a)ot=pt(""),Vt=ot.ownerDocument.importNode(Zt,!0),Vt.nodeType===sA.element&&Vt.nodeName==="BODY"||Vt.nodeName==="HTML"?ot=Vt:ot.appendChild(Vt);else{if(!Yu&&!ql&&!Kl&&Zt.indexOf("<")===-1)return w&&Ii?w.createHTML(Zt):Zt;if(ot=pt(Zt),!ot)return Yu?null:Ii?y:""}ot&&am&&xe(ot.firstChild);let Yl=Tt(Hs?Zt:ot);for(;hr=Yl.nextNode();)xs(hr)||(hr.content instanceof r&&oN(hr.content),Zu(hr));if(Hs)return Zt;if(Yu){if(gt)for(kc=E.call(ot.ownerDocument);ot.firstChild;)kc.appendChild(ot.firstChild);else kc=ot;return(K.shadowroot||K.shadowrootmode)&&(kc=M.call(i,kc,!0)),kc}let Qd=Kl?ot.outerHTML:ot.innerHTML;return Kl&&Je["!doctype"]&&ot.ownerDocument&&ot.ownerDocument.doctype&&ot.ownerDocument.doctype.name&&Id(aDe,ot.ownerDocument.doctype.name)&&(Qd=" `+Qd),ql&&wB([q,te,$],lm=>{Qd=nA(Qd,lm," ")}),w&&Ii?w.createHTML(Qd):Qd},e.setConfig=function(){let Zt=arguments.length>0&&arguments[0]!==void 0?arguments[0]:{};nN(Zt),sm=!0},e.clearConfig=function(){bv=null,sm=!1},e.isValidAttribute=function(Zt,se,ot){bv||nN({});let Vt=ha(Zt),hr=ha(se);return qo(Vt,hr,ot)},e.addHook=function(Zt,se){typeof se=="function"&&(F[Zt]=F[Zt]||[],iA(F[Zt],se))},e.removeHook=function(Zt){if(F[Zt])return XTe(F[Zt])},e.removeHooks=function(Zt){F[Zt]&&(F[Zt]=[])},e.removeAllHooks=function(){F={}},e}var oDe,ZTe,Bot,Wot,Hot,Ed,pf,rDe,qne,Kne,wB,XTe,iA,CB,zne,QTe,nA,zot,Vot,hp,Id,oA,JTe,Vne,Une,jot,$ne,qot,eDe,tDe,jne,iDe,yB,Kot,Got,Yot,Zot,Xot,sDe,Qot,Jot,aDe,ert,nDe,sA,trt,irt,Tm,G5t,Y5t,SB,Z5t,X5t,Q5t,kB,LB,J5t,e3t,IB=k(()=>{({entries:oDe,setPrototypeOf:ZTe,isFrozen:Bot,getPrototypeOf:Wot,getOwnPropertyDescriptor:Hot}=Object),{freeze:Ed,seal:pf,create:rDe}=Object,{apply:qne,construct:Kne}=typeof Reflect<"u"&&Reflect;Ed||(Ed=function(e){return e});pf||(pf=function(e){return e});qne||(qne=function(e,t,i){return e.apply(t,i)});Kne||(Kne=function(e,t){return new e(...t)});wB=mh(Array.prototype.forEach),XTe=mh(Array.prototype.pop),iA=mh(Array.prototype.push),CB=mh(String.prototype.toLowerCase),zne=mh(String.prototype.toString),QTe=mh(String.prototype.match),nA=mh(String.prototype.replace),zot=mh(String.prototype.indexOf),Vot=mh(String.prototype.trim),hp=mh(Object.prototype.hasOwnProperty),Id=mh(RegExp.prototype.test),oA=Uot(TypeError);JTe=Ed(["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"]),Vne=Ed(["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"]),Une=Ed(["feBlend","feColorMatrix","feComponentTransfer","feComposite","feConvolveMatrix","feDiffuseLighting","feDisplacementMap","feDistantLight","feDropShadow","feFlood","feFuncA","feFuncB","feFuncG","feFuncR","feGaussianBlur","feImage","feMerge","feMergeNode","feMorphology","feOffset","fePointLight","feSpecularLighting","feSpotLight","feTile","feTurbulence"]),jot=Ed(["animate","color-profile","cursor","discard","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"]),$ne=Ed(["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","mprescripts"]),qot=Ed(["maction","maligngroup","malignmark","mlongdiv","mscarries","mscarry","msgroup","mstack","msline","msrow","semantics","annotation","annotation-xml","mprescripts","none"]),eDe=Ed(["#text"]),tDe=Ed(["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","nonce","noshade","novalidate","nowrap","open","optimum","pattern","placeholder","playsinline","popover","popovertarget","popovertargetaction","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","wrap","xmlns","slot"]),jne=Ed(["accent-height","accumulate","additive","alignment-baseline","amplitude","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","exponent","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","intercept","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","slope","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","tablevalues","targetx","targety","transform","transform-origin","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"]),iDe=Ed(["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"]),yB=Ed(["xlink:href","xml:id","xlink:title","xml:space","xmlns:xlink"]),Kot=pf(/\{\{[\w\W]*|[\w\W]*\}\}/gm),Got=pf(/<%[\w\W]*|[\w\W]*%>/gm),Yot=pf(/\${[\w\W]*}/gm),Zot=pf(/^data-[\-\w.\u00B7-\uFFFF]/),Xot=pf(/^aria-[\-\w]+$/),sDe=pf(/^(?:(?:(?:f|ht)tps?|mailto|tel|callto|sms|cid|xmpp):|[^a-z]|[a-z+.\-]+(?:[^a-z+.\-:]|$))/i),Qot=pf(/^(?:\w+script|data):/i),Jot=pf(/[\u0000-\u0020\u00A0\u1680\u180E\u2000-\u2029\u205F\u3000]/g),aDe=pf(/^html$/i),ert=pf(/^[a-z][.\w]*(-[.\w]+)+$/i),nDe=Object.freeze({__proto__:null,MUSTACHE_EXPR:Kot,ERB_EXPR:Got,TMPLIT_EXPR:Yot,DATA_ATTR:Zot,ARIA_ATTR:Xot,IS_ALLOWED_URI:sDe,IS_SCRIPT_OR_DATA:Qot,ATTR_WHITESPACE:Jot,DOCTYPE_NAME:aDe,CUSTOM_ELEMENT:ert}),sA={element:1,attribute:2,text:3,cdataSection:4,entityReference:5,entityNode:6,progressingInstruction:7,comment:8,document:9,documentType:10,documentFragment:11,notation:12},trt=function(){return typeof window>"u"?null:window},irt=function(e,t){if(typeof e!="object"||typeof e.createPolicy!="function")return null;let i=null,o="data-tt-policy-suffix";t&&t.hasAttribute(o)&&(i=t.getAttribute(o));let r="dompurify"+(i?"#"+i:"");try{return e.createPolicy(r,{createHTML(s){return s},createScriptURL(s){return s}})}catch{return console.warn("TrustedTypes policy "+r+" could not be created."),null}};Tm=lDe(),G5t=Tm.version,Y5t=Tm.isSupported,SB=Tm.sanitize,Z5t=Tm.setConfig,X5t=Tm.clearConfig,Q5t=Tm.isValidAttribute,kB=Tm.addHook,LB=Tm.removeHook,J5t=Tm.removeHooks,e3t=Tm.removeAllHooks});function L1(n,e){return Ee.isUri(n)?z_(n.scheme,e):iL(n,e+":")}function aA(n,...e){return e.some(t=>L1(n,t))}var rt,nrt,Gne,Zne,ort,Yne,U_,EB,ds=k(()=>{je();Bt();Qe();Ai();sp();(function(n){n.inMemory="inmemory",n.vscode="vscode",n.internal="private",n.walkThrough="walkThrough",n.walkThroughSnippet="walkThroughSnippet",n.http="http",n.https="https",n.file="file",n.mailto="mailto",n.untitled="untitled",n.data="data",n.command="command",n.vscodeRemote="vscode-remote",n.vscodeRemoteResource="vscode-remote-resource",n.vscodeManagedRemoteResource="vscode-managed-remote-resource",n.vscodeUserData="vscode-userdata",n.vscodeCustomEditor="vscode-custom-editor",n.vscodeNotebookCell="vscode-notebook-cell",n.vscodeNotebookCellMetadata="vscode-notebook-cell-metadata",n.vscodeNotebookCellMetadataDiff="vscode-notebook-cell-metadata-diff",n.vscodeNotebookCellOutput="vscode-notebook-cell-output",n.vscodeNotebookCellOutputDiff="vscode-notebook-cell-output-diff",n.vscodeNotebookMetadata="vscode-notebook-metadata",n.vscodeInteractiveInput="vscode-interactive-input",n.vscodeSettings="vscode-settings",n.vscodeWorkspaceTrust="vscode-workspace-trust",n.vscodeTerminal="vscode-terminal",n.vscodeChatCodeBlock="vscode-chat-code-block",n.vscodeChatCodeCompareBlock="vscode-chat-code-compare-block",n.vscodeChatSesssion="vscode-chat-editor",n.webviewPanel="webview-panel",n.vscodeWebview="vscode-webview",n.extension="extension",n.vscodeFileResource="vscode-file",n.tmp="tmp",n.vsls="vsls",n.vscodeSourceControl="vscode-scm",n.commentsInput="comment",n.codeSetting="code-setting",n.outputChannel="output"})(rt||(rt={}));nrt="tkn",Gne=class{constructor(){this._hosts=Object.create(null),this._ports=Object.create(null),this._connectionTokens=Object.create(null),this._preferredWebSchema="http",this._delegate=null,this._serverRootPath="/"}setPreferredWebSchema(e){this._preferredWebSchema=e}get _remoteResourcesPath(){return eo.join(this._serverRootPath,rt.vscodeRemoteResource)}rewrite(e){if(this._delegate)try{return this._delegate(e)}catch(a){return Be(a),e}let t=e.authority,i=this._hosts[t];i&&i.indexOf(":")!==-1&&i.indexOf("[")===-1&&(i=`[${i}]`);let o=this._ports[t],r=this._connectionTokens[t],s=`path=${encodeURIComponent(e.path)}`;return typeof r=="string"&&(s+=`&${nrt}=${encodeURIComponent(r)}`),Ee.from({scheme:df?this._preferredWebSchema:rt.vscodeRemoteResource,authority:`${i}:${o}`,path:this._remoteResourcesPath,query:s})}},Zne=new Gne,ort="vscode-app",Yne=class n{static{this.FALLBACK_AUTHORITY=ort}asBrowserUri(e){let t=this.toUri(e);return this.uriToBrowserUri(t)}uriToBrowserUri(e){return e.scheme===rt.vscodeRemote?Zne.rewrite(e):e.scheme===rt.file&&(Pc||JEe===`${rt.vscodeFileResource}://${n.FALLBACK_AUTHORITY}`)?e.with({scheme:rt.vscodeFileResource,authority:e.authority||n.FALLBACK_AUTHORITY,query:null,fragment:null}):e}toUri(e,t){if(Ee.isUri(e))return e;if(globalThis._VSCODE_FILE_ROOT){let i=globalThis._VSCODE_FILE_ROOT;if(/^\w[\w\d+.-]*:\/\//.test(i))return Ee.joinPath(Ee.parse(i,!0),e);let o=_Te(i,e);return Ee.file(o)}return Ee.parse(t.toUrl(e))}},U_=new Yne;(function(n){let e=new Map([["1",{"Cross-Origin-Opener-Policy":"same-origin"}],["2",{"Cross-Origin-Embedder-Policy":"require-corp"}],["3",{"Cross-Origin-Opener-Policy":"same-origin","Cross-Origin-Embedder-Policy":"require-corp"}]]);n.CoopAndCoep=Object.freeze(e.get("3"));let t="vscode-coi";function i(r){let s;typeof r=="string"?s=new URL(r).searchParams:r instanceof URL?s=r.searchParams:Ee.isUri(r)&&(s=new URL(r.toString(!0)).searchParams);let a=s?.get(t);if(a)return e.get(a)}n.getHeadersFromQuery=i;function o(r,s,a){if(!globalThis.crossOriginIsolated)return;let l=s&&a?"3":a?"2":"1";r instanceof URLSearchParams?r.set(t,l):r[t]=l}n.addSearchParam=o})(EB||(EB={}))});function xx(n){return cA(n,0)}function cA(n,e){switch(typeof n){case"object":return n===null?$_(349,e):Array.isArray(n)?srt(n,e):art(n,e);case"string":return DB(n,e);case"boolean":return rrt(n,e);case"number":return $_(n,e);case"undefined":return $_(937,e);default:return $_(617,e)}}function $_(n,e){return(e<<5)-e+n|0}function rrt(n,e){return $_(n?433:863,e)}function DB(n,e){e=$_(149417,e);for(let t=0,i=n.length;tcA(i,t),e)}function art(n,e){return e=$_(181387,e),Object.keys(n).sort().reduce((t,i)=>(t=DB(i,t),cA(n[i],t)),e)}function Xne(n,e,t=32){let i=t-e,o=~((1<>>i)>>>0}function dDe(n,e=0,t=n.byteLength,i=0){for(let o=0;ot.toString(16).padStart(2,"0")).join(""):lrt((n>>>0).toString(16),e/4)}var TB,wx=k(()=>{Qe();TB=class n{static{this._bigBlock32=new DataView(new ArrayBuffer(320))}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(e){let t=e.length;if(t===0)return;let i=this._buff,o=this._buffLen,r=this._leftoverHighSurrogate,s,a;for(r!==0?(s=r,a=-1,r=0):(s=e.charCodeAt(0),a=0);;){let l=s;if(to(s))if(a+1>>6,e[t++]=128|(i&63)>>>0):i<65536?(e[t++]=224|(i&61440)>>>12,e[t++]=128|(i&4032)>>>6,e[t++]=128|(i&63)>>>0):(e[t++]=240|(i&1835008)>>>18,e[t++]=128|(i&258048)>>>12,e[t++]=128|(i&4032)>>>6,e[t++]=128|(i&63)>>>0),t>=64&&(this._step(),t-=64,this._totalLen+=64,e[0]=e[64],e[1]=e[65],e[2]=e[66]),t}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()),lA(this._h0)+lA(this._h1)+lA(this._h2)+lA(this._h3)+lA(this._h4)}_wrapUp(){this._buff[this._buffLen++]=128,dDe(this._buff,this._buffLen),this._buffLen>56&&(this._step(),dDe(this._buff));let e=8*this._totalLen;this._buffDV.setUint32(56,Math.floor(e/4294967296),!1),this._buffDV.setUint32(60,e%4294967296,!1),this._step()}_step(){let e=n._bigBlock32,t=this._buffDV;for(let u=0;u<64;u+=4)e.setUint32(u,t.getUint32(u,!1),!1);for(let u=64;u<320;u+=4)e.setUint32(u,Xne(e.getUint32(u-12,!1)^e.getUint32(u-32,!1)^e.getUint32(u-56,!1)^e.getUint32(u-64,!1),1),!1);let i=this._h0,o=this._h1,r=this._h2,s=this._h3,a=this._h4,l,c,d;for(let u=0;u<80;u++)u<20?(l=o&r|~o&s,c=1518500249):u<40?(l=o^r^s,c=1859775393):u<60?(l=o&r|o&s|r&s,c=2400959708):(l=o^r^s,c=3395469782),d=Xne(i,5)+l+a+c+e.getUint32(u*4,!1)&4294967295,a=s,s=r,r=Xne(o,30),o=i,i=d;this._h0=this._h0+i&4294967295,this._h1=this._h1+o&4294967295,this._h2=this._h2+r&4294967295,this._h3=this._h3+s&4294967295,this._h4=this._h4+a&4294967295}}});function no(n){for(;n.firstChild;)n.firstChild.remove()}function U(n,e,t,i){return new Jne(n,e,t,i)}function pDe(n,e){return function(t){return e(new cs(n,t))}}function drt(n){return function(e){return n(new Xt(e))}}function urt(n,e,t){return U(n,Xa&&sL.pointerEvents?re.POINTER_DOWN:re.MOUSE_DOWN,e,t)}function E1(n,e,t){return aL(n,e,t)}function hA(n){return Me(n).getComputedStyle(n,null)}function Wc(n,e){let t=Me(n),i=t.document;if(n!==i.body)return new vi(n.clientWidth,n.clientHeight);if(Xa&&t?.visualViewport)return new vi(t.visualViewport.width,t.visualViewport.height);if(t?.innerWidth&&t.innerHeight)return new vi(t.innerWidth,t.innerHeight);if(i.body&&i.body.clientWidth&&i.body.clientHeight)return new vi(i.body.clientWidth,i.body.clientHeight);if(i.documentElement&&i.documentElement.clientWidth&&i.documentElement.clientHeight)return new vi(i.documentElement.clientWidth,i.documentElement.clientHeight);if(e)return Wc(e);throw new Error("Unable to figure out browser width and height")}function AB(n){let e=n.offsetParent,t=n.offsetTop,i=n.offsetLeft;for(;(n=n.parentNode)!==null&&n!==n.ownerDocument.body&&n!==n.ownerDocument.documentElement;){t-=n.scrollTop;let o=bDe(n)?null:hA(n);o&&(i-=o.direction!=="rtl"?n.scrollLeft:-n.scrollLeft),n===e&&(i+=Bc.getBorderLeftWidth(n),t+=Bc.getBorderTopWidth(n),t+=n.offsetTop,i+=n.offsetLeft,e=n.offsetParent)}return{left:i,top:t}}function gDe(n,e,t){typeof e=="number"&&(n.style.width=`${e}px`),typeof t=="number"&&(n.style.height=`${t}px`)}function Ci(n){let e=n.getBoundingClientRect(),t=Me(n);return{left:e.left+t.scrollX,top:e.top+t.scrollY,width:e.width,height:e.height}}function MB(n){let e=n,t=1;do{let i=hA(e).zoom;i!=null&&i!=="1"&&(t*=i),e=e.parentElement}while(e!==null&&e!==e.ownerDocument.documentElement);return t}function Gs(n){let e=Bc.getMarginLeft(n)+Bc.getMarginRight(n);return n.offsetWidth+e}function PB(n){let e=Bc.getBorderLeftWidth(n)+Bc.getBorderRightWidth(n),t=Bc.getPaddingLeft(n)+Bc.getPaddingRight(n);return n.offsetWidth-e-t}function _De(n){let e=Bc.getBorderTopWidth(n)+Bc.getBorderBottomWidth(n),t=Bc.getPaddingTop(n)+Bc.getPaddingBottom(n);return n.offsetHeight-e-t}function gh(n){let e=Bc.getMarginTop(n)+Bc.getMarginBottom(n);return n.offsetHeight+e}function io(n,e){return!!e?.contains(n)}function hrt(n,e,t){for(;n&&n.nodeType===n.ELEMENT_NODE;){if(n.classList.contains(e))return n;if(t){if(typeof t=="string"){if(n.classList.contains(t))return null}else if(n===t)return null}n=n.parentNode}return null}function OB(n,e,t){return!!hrt(n,e,t)}function bDe(n){return n&&!!n.host&&!!n.mode}function T1(n){return!!fp(n)}function fp(n){for(;n.parentNode;){if(n===n.ownerDocument?.body)return null;n=n.parentNode}return bDe(n)?n:null}function Mo(){let n=q_().activeElement;for(;n?.shadowRoot;)n=n.shadowRoot.activeElement;return n}function D1(n){return Mo()===n}function FB(n){return io(Mo(),n)}function q_(){return crt()<=1?ri.document:Array.from(uDe()).map(({window:e})=>e.document).find(e=>e.hasFocus())??ri.document}function N1(){return q_().defaultView?.window??ri}function BB(){return new eoe}function qr(n=ri.document.head,e,t){let i=document.createElement("style");if(i.type="text/css",i.media="screen",e?.(i),n.appendChild(i),t&&t.add(ge(()=>i.remove())),n===ri.document.head){let o=new Set;noe.set(i,o);for(let{window:r,disposables:s}of uDe()){if(r===ri)continue;let a=s.add(frt(i,o,r));t?.add(a)}}return i}function frt(n,e,t){let i=new H,o=n.cloneNode(!0);t.document.head.appendChild(o),i.add(ge(()=>o.remove()));for(let r of xDe(n))o.sheet?.insertRule(r.cssText,o.sheet?.cssRules.length);return i.add(prt.observe(n,i,{childList:!0})(()=>{o.textContent=n.textContent})),e.add(o),i.add(ge(()=>e.delete(o))),i}function vDe(){return Qne||(Qne=qr()),Qne}function xDe(n){return n?.sheet?.rules?n.sheet.rules:n?.sheet?.cssRules?n.sheet.cssRules:[]}function hL(n,e,t=vDe()){if(!(!t||!e)){t.sheet?.insertRule(`${n} {${e}}`,0);for(let i of noe.get(t)??[])hL(n,e,i)}}function WB(n,e=vDe()){if(!e)return;let t=xDe(e),i=[];for(let o=0;o=0;o--)e.sheet?.deleteRule(i[o]);for(let o of noe.get(e)??[])WB(n,o)}function mrt(n){return typeof n.selectorText=="string"}function _n(n){return n instanceof HTMLElement||n instanceof Me(n).HTMLElement}function ooe(n){return n instanceof HTMLAnchorElement||n instanceof Me(n).HTMLAnchorElement}function wDe(n){return n instanceof SVGElement||n instanceof Me(n).SVGElement}function fL(n){return n instanceof MouseEvent||n instanceof Me(n).MouseEvent}function mf(n){return n instanceof KeyboardEvent||n instanceof Me(n).KeyboardEvent}function yDe(n){let e=n;return!!(e&&typeof e.preventDefault=="function"&&typeof e.stopPropagation=="function")}function CDe(n){let e=[];for(let t=0;n&&n.nodeType===n.ELEMENT_NODE;t++)e[t]=n.scrollTop,n=n.parentNode;return e}function SDe(n,e){for(let t=0;n&&n.nodeType===n.ELEMENT_NODE;t++)n.scrollTop!==e[t]&&(n.scrollTop=e[t]),n=n.parentNode}function ba(n){return new toe(n)}function kDe(n,e){return n.after(e),e}function Q(n,...e){if(n.append(...e),e.length===1&&typeof e[0]!="string")return e[0]}function pL(n,e){return n.insertBefore(e,n.firstChild),e}function oo(n,...e){n.innerText="",Q(n,...e)}function LDe(n,e,t,...i){let o=grt.exec(e);if(!o)throw new Error("Bad use of emmet");let r=o[1]||"div",s;return n!==uA.HTML?s=document.createElementNS(n,r):s=document.createElement(r),o[3]&&(s.id=o[3]),o[4]&&(s.className=o[4].replace(/\./g," ").trim()),t&&Object.entries(t).forEach(([a,l])=>{typeof l>"u"||(/^on\w+$/.test(a)?s[a]=l:a==="selected"?l&&s.setAttribute(a,"true"):s.setAttribute(a,l))}),s.append(...i),s}function J(n,e,...t){return LDe(uA.HTML,n,e,...t)}function IDe(n,...e){n?Is(...e):hs(...e)}function Is(...n){for(let e of n)e.style.display="",e.removeAttribute("aria-hidden")}function hs(...n){for(let e of n)e.style.display="none",e.setAttribute("aria-hidden","true")}function roe(n,e){let t=n.devicePixelRatio*e;return Math.max(1,Math.floor(t))/n.devicePixelRatio}function HB(n){ri.open(n,"_blank","noopener")}function EDe(n,e){let t=()=>{e(),i=us(n,t)},i=us(n,t);return ge(()=>i.dispose())}function _u(n){return n?`url('${U_.uriToBrowserUri(n).toString(!0).replace(/'/g,"%27")}')`:"url('')"}function zB(n){return`'${n.replace(/'/g,"%27")}'`}function _h(n,e){if(n!==void 0){let t=n.match(/^\s*var\((.+)\)$/);if(t){let i=t[1].split(",",2);return i.length===2&&(e=_h(i[1].trim(),e)),`var(${i[0]}, ${e})`}return n}return e}function TDe(n,e=!1){let t=document.createElement("a");return kB("afterSanitizeAttributes",i=>{for(let o of["href","src"])if(i.hasAttribute(o)){let r=i.getAttribute(o);if(o==="href"&&r.startsWith("#"))continue;if(t.href=r,!n.includes(t.protocol.replace(/:$/,""))){if(e&&o==="src"&&t.href.startsWith("data:"))continue;i.removeAttribute(o)}}}),ge(()=>{LB("afterSanitizeAttributes")})}function Et(n,...e){let t,i;Array.isArray(e[0])?(t={},i=e[0]):(t=e[0]||{},i=e[1]);let o=NDe.exec(n);if(!o||!o.groups)throw new Error("Bad use of h");let r=o.groups.tag||"div",s=document.createElement(r);o.groups.id&&(s.id=o.groups.id);let a=[];if(o.groups.class)for(let c of o.groups.class.split("."))c!==""&&a.push(c);if(t.className!==void 0)for(let c of t.className.split("."))c!==""&&a.push(c);a.length>0&&(s.className=a.join(" "));let l={};if(o.groups.name&&(l[o.groups.name]=s),i)for(let c of i)_n(c)?s.appendChild(c):typeof c=="string"?s.append(c):"root"in c&&(Object.assign(l,c),s.appendChild(c.root));for(let[c,d]of Object.entries(t))if(c!=="className")if(c==="style")for(let[u,h]of Object.entries(d))s.style.setProperty(RB(u),typeof h=="number"?h+"px":""+h);else c==="tabIndex"?s.tabIndex=d:s.setAttribute(RB(c),d.toString());return l.root=s,l}function R1(n,...e){let t,i;Array.isArray(e[0])?(t={},i=e[0]):(t=e[0]||{},i=e[1]);let o=NDe.exec(n);if(!o||!o.groups)throw new Error("Bad use of h");let r=o.groups.tag||"div",s=document.createElementNS("http://www.w3.org/2000/svg",r);o.groups.id&&(s.id=o.groups.id);let a=[];if(o.groups.class)for(let c of o.groups.class.split("."))c!==""&&a.push(c);if(t.className!==void 0)for(let c of t.className.split("."))c!==""&&a.push(c);a.length>0&&(s.className=a.join(" "));let l={};if(o.groups.name&&(l[o.groups.name]=s),i)for(let c of i)_n(c)?s.appendChild(c):typeof c=="string"?s.append(c):"root"in c&&(Object.assign(l,c),s.appendChild(c.root));for(let[c,d]of Object.entries(t))if(c!=="className")if(c==="style")for(let[u,h]of Object.entries(d))s.style.setProperty(RB(u),typeof h=="number"?h+"px":""+h);else c==="tabIndex"?s.tabIndex=d:s.setAttribute(RB(c),d.toString());return l.root=s,l}function RB(n){return n.replace(/([a-z])([A-Z])/g,"$1-$2").toLowerCase()}var p3t,Me,m3t,uDe,crt,cL,ioe,g3t,I1,hDe,fDe,Jne,gi,mDe,dL,uL,us,yx,dA,Bc,vi,noe,eoe,prt,Qne,re,Rt,toe,grt,uA,DDe,_3t,j_,NB,NDe,ke=k(()=>{Fc();hB();Ks();pu();ft();je();Ie();IB();j();ds();Bt();wx();Il();({registerWindow:p3t,getWindow:Me,getDocument:m3t,getWindows:uDe,getWindowsCount:crt,getWindowId:cL,getWindowById:ioe,hasWindow:g3t,onDidRegisterWindow:I1,onWillUnregisterWindow:hDe,onDidUnregisterWindow:fDe}=function(){let n=new Map;NTe(ri,1);let e={window:ri,disposables:new H};n.set(ri.vscodeWindowId,e);let t=new A,i=new A,o=new A;function r(s,a){return(typeof s=="number"?n.get(s):void 0)??(a?e:void 0)}return{onDidRegisterWindow:t.event,onWillUnregisterWindow:o.event,onDidUnregisterWindow:i.event,registerWindow(s){if(n.has(s.vscodeWindowId))return D.None;let a=new H,l={window:s,disposables:a.add(new H)};return n.set(s.vscodeWindowId,l),a.add(ge(()=>{n.delete(s.vscodeWindowId),i.fire(s)})),a.add(U(s,re.BEFORE_UNLOAD,()=>{o.fire(s)})),t.fire(l),a},getWindows(){return n.values()},getWindowsCount(){return n.size},getWindowId(s){return s.vscodeWindowId},hasWindow(s){return n.has(s)},getWindowById:r,getWindow(s){let a=s;if(a?.ownerDocument?.defaultView)return a.ownerDocument.defaultView.window;let l=s;return l?.view?l.view.window:ri},getDocument(s){return Me(s).document}}}());Jne=class{constructor(e,t,i,o){this._node=e,this._type=t,this._handler=i,this._options=o||!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)}};gi=function(e,t,i,o){let r=i;return t==="click"||t==="mousedown"||t==="contextmenu"?r=pDe(Me(e),i):(t==="keydown"||t==="keypress"||t==="keyup")&&(r=drt(i)),U(e,t,r,o)},mDe=function(e,t,i){let o=pDe(Me(e),t);return urt(e,o,i)};dL=class extends eA{constructor(e,t){super(e,t)}},yx=class extends vx{constructor(e){super(),this.defaultTarget=e&&Me(e)}cancelAndSet(e,t,i){return super.cancelAndSet(e,t,i??this.defaultTarget)}},dA=class{constructor(e,t=0){this._runner=e,this.priority=t,this._canceled=!1}dispose(){this._canceled=!0}execute(){if(!this._canceled)try{this._runner()}catch(e){Be(e)}}static sort(e,t){return t.priority-e.priority}};(function(){let n=new Map,e=new Map,t=new Map,i=new Map,o=r=>{t.set(r,!1);let s=n.get(r)??[];for(e.set(r,s),n.set(r,[]),i.set(r,!0);s.length>0;)s.sort(dA.sort),s.shift().execute();i.set(r,!1)};us=(r,s,a=0)=>{let l=cL(r),c=new dA(s,a),d=n.get(l);return d||(d=[],n.set(l,d)),d.push(c),t.get(l)||(t.set(l,!0),r.requestAnimationFrame(()=>o(l))),c},uL=(r,s,a)=>{let l=cL(r);if(i.get(l)){let c=new dA(s,a),d=e.get(l);return d||(d=[],e.set(l,d)),d.push(c),c}else return us(r,s,a)}})();Bc=class n{static convertToPixels(e,t){return parseFloat(t)||0}static getDimension(e,t,i){let o=hA(e),r=o?o.getPropertyValue(t):"0";return n.convertToPixels(e,r)}static getBorderLeftWidth(e){return n.getDimension(e,"border-left-width","borderLeftWidth")}static getBorderRightWidth(e){return n.getDimension(e,"border-right-width","borderRightWidth")}static getBorderTopWidth(e){return n.getDimension(e,"border-top-width","borderTopWidth")}static getBorderBottomWidth(e){return n.getDimension(e,"border-bottom-width","borderBottomWidth")}static getPaddingLeft(e){return n.getDimension(e,"padding-left","paddingLeft")}static getPaddingRight(e){return n.getDimension(e,"padding-right","paddingRight")}static getPaddingTop(e){return n.getDimension(e,"padding-top","paddingTop")}static getPaddingBottom(e){return n.getDimension(e,"padding-bottom","paddingBottom")}static getMarginLeft(e){return n.getDimension(e,"margin-left","marginLeft")}static getMarginTop(e){return n.getDimension(e,"margin-top","marginTop")}static getMarginRight(e){return n.getDimension(e,"margin-right","marginRight")}static getMarginBottom(e){return n.getDimension(e,"margin-bottom","marginBottom")}},vi=class n{static{this.None=new n(0,0)}constructor(e,t){this.width=e,this.height=t}with(e=this.width,t=this.height){return e!==this.width||t!==this.height?new n(e,t):this}static is(e){return typeof e=="object"&&typeof e.height=="number"&&typeof e.width=="number"}static lift(e){return e instanceof n?e:new n(e.width,e.height)}static equals(e,t){return e===t?!0:!e||!t?!1:e.width===t.width&&e.height===t.height}};noe=new Map;eoe=class{constructor(){this._currentCssStyle="",this._styleSheet=void 0}setStyle(e){e!==this._currentCssStyle&&(this._currentCssStyle=e,this._styleSheet?this._styleSheet.innerText=e:this._styleSheet=qr(ri.document.head,t=>t.innerText=e))}dispose(){this._styleSheet&&(this._styleSheet.remove(),this._styleSheet=void 0)}};prt=new class{constructor(){this.mutationObservers=new Map}observe(n,e,t){let i=this.mutationObservers.get(n);i||(i=new Map,this.mutationObservers.set(n,i));let o=xx(t),r=i.get(o);if(r)r.users+=1;else{let s=new A,a=new MutationObserver(c=>s.fire(c));a.observe(n,t);let l=r={users:1,observer:a,onDidMutate:s.event};e.add(ge(()=>{l.users-=1,l.users===0&&(s.dispose(),a.disconnect(),i?.delete(o),i?.size===0&&this.mutationObservers.delete(n))})),i.set(o,r)}return r.onDidMutate}},Qne=null;re={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",PASTE:"paste",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:up?"webkitAnimationStart":"animationstart",ANIMATION_END:up?"webkitAnimationEnd":"animationend",ANIMATION_ITERATION:up?"webkitAnimationIteration":"animationiteration"};Rt={stop:(n,e)=>(n.preventDefault(),e&&n.stopPropagation(),n)};toe=class n extends D{static hasFocusWithin(e){if(_n(e)){let t=fp(e),i=t?t.activeElement:e.ownerDocument.activeElement;return io(i,e)}else{let t=e;return io(t.document.activeElement,t.document)}}constructor(e){super(),this._onDidFocus=this._register(new A),this.onDidFocus=this._onDidFocus.event,this._onDidBlur=this._register(new A),this.onDidBlur=this._onDidBlur.event;let t=n.hasFocusWithin(e),i=!1,o=()=>{i=!1,t||(t=!0,this._onDidFocus.fire())},r=()=>{t&&(i=!0,(_n(e)?Me(e):e).setTimeout(()=>{i&&(i=!1,t=!1,this._onDidBlur.fire())},0))};this._refreshStateHandler=()=>{n.hasFocusWithin(e)!==t&&(t?r():o())},this._register(U(e,re.FOCUS,o,!0)),this._register(U(e,re.BLUR,r,!0)),_n(e)&&(this._register(U(e,re.FOCUS_IN,()=>this._refreshStateHandler())),this._register(U(e,re.FOCUS_OUT,()=>this._refreshStateHandler())))}};grt=/([\w\-]+)?(#([\w\-]+))?((\.([\w\-]+))*)/;(function(n){n.HTML="http://www.w3.org/1999/xhtml",n.SVG="http://www.w3.org/2000/svg"})(uA||(uA={}));J.SVG=function(n,e,...t){return LDe(uA.SVG,n,e,...t)};Zne.setPreferredWebSchema(/^https:/.test(ri.location.href)?"https":"http");DDe=Object.freeze(["a","abbr","b","bdo","blockquote","br","caption","cite","code","col","colgroup","dd","del","details","dfn","div","dl","dt","em","figcaption","figure","h1","h2","h3","h4","h5","h6","hr","i","img","input","ins","kbd","label","li","mark","ol","p","pre","q","rp","rt","ruby","samp","small","small","source","span","strike","strong","sub","summary","sup","table","tbody","td","tfoot","th","thead","time","tr","tt","u","ul","var","video","wbr"]),_3t=Object.freeze({ALLOWED_TAGS:["a","button","blockquote","code","div","h1","h2","h3","h4","h5","h6","hr","input","label","li","p","pre","select","small","span","strong","textarea","ul","ol"],ALLOWED_ATTR:["href","data-href","data-command","target","title","name","src","alt","class","id","role","tabindex","style","data-code","width","height","align","x-dispatch","required","checked","placeholder","type","start"],RETURN_DOM:!1,RETURN_DOM_FRAGMENT:!1,RETURN_TRUSTED_TYPE:!0}),j_=class n extends A{constructor(){super(),this._subscriptions=new H,this._keyStatus={altKey:!1,shiftKey:!1,ctrlKey:!1,metaKey:!1},this._subscriptions.add(ne.runAndSubscribe(I1,({window:e,disposables:t})=>this.registerListeners(e,t),{window:ri,disposables:this._subscriptions}))}registerListeners(e,t){t.add(U(e,"keydown",i=>{if(i.defaultPrevented)return;let o=new Xt(i);if(!(o.keyCode===6&&i.repeat)){if(i.altKey&&!this._keyStatus.altKey)this._keyStatus.lastKeyPressed="alt";else if(i.ctrlKey&&!this._keyStatus.ctrlKey)this._keyStatus.lastKeyPressed="ctrl";else if(i.metaKey&&!this._keyStatus.metaKey)this._keyStatus.lastKeyPressed="meta";else if(i.shiftKey&&!this._keyStatus.shiftKey)this._keyStatus.lastKeyPressed="shift";else if(o.keyCode!==6)this._keyStatus.lastKeyPressed=void 0;else return;this._keyStatus.altKey=i.altKey,this._keyStatus.ctrlKey=i.ctrlKey,this._keyStatus.metaKey=i.metaKey,this._keyStatus.shiftKey=i.shiftKey,this._keyStatus.lastKeyPressed&&(this._keyStatus.event=i,this.fire(this._keyStatus))}},!0)),t.add(U(e,"keyup",i=>{i.defaultPrevented||(!i.altKey&&this._keyStatus.altKey?this._keyStatus.lastKeyReleased="alt":!i.ctrlKey&&this._keyStatus.ctrlKey?this._keyStatus.lastKeyReleased="ctrl":!i.metaKey&&this._keyStatus.metaKey?this._keyStatus.lastKeyReleased="meta":!i.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=i.altKey,this._keyStatus.ctrlKey=i.ctrlKey,this._keyStatus.metaKey=i.metaKey,this._keyStatus.shiftKey=i.shiftKey,this._keyStatus.lastKeyReleased&&(this._keyStatus.event=i,this.fire(this._keyStatus)))},!0)),t.add(U(e.document.body,"mousedown",()=>{this._keyStatus.lastKeyPressed=void 0},!0)),t.add(U(e.document.body,"mouseup",()=>{this._keyStatus.lastKeyPressed=void 0},!0)),t.add(U(e.document.body,"mousemove",i=>{i.buttons&&(this._keyStatus.lastKeyPressed=void 0)},!0)),t.add(U(e,"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 n.instance||(n.instance=new n),n.instance}dispose(){super.dispose(),this._subscriptions.dispose()}},NB=class extends D{constructor(e,t){super(),this.element=e,this.callbacks=t,this.counter=0,this.dragStartTime=0,this.registerListeners()}registerListeners(){this.callbacks.onDragStart&&this._register(U(this.element,re.DRAG_START,e=>{this.callbacks.onDragStart?.(e)})),this.callbacks.onDrag&&this._register(U(this.element,re.DRAG,e=>{this.callbacks.onDrag?.(e)})),this._register(U(this.element,re.DRAG_ENTER,e=>{this.counter++,this.dragStartTime=e.timeStamp,this.callbacks.onDragEnter?.(e)})),this._register(U(this.element,re.DRAG_OVER,e=>{e.preventDefault(),this.callbacks.onDragOver?.(e,e.timeStamp-this.dragStartTime)})),this._register(U(this.element,re.DRAG_LEAVE,e=>{this.counter--,this.counter===0&&(this.dragStartTime=0,this.callbacks.onDragLeave?.(e))})),this._register(U(this.element,re.DRAG_END,e=>{this.counter=0,this.dragStartTime=0,this.callbacks.onDragEnd?.(e)})),this._register(U(this.element,re.DROP,e=>{this.counter=0,this.dragStartTime=0,this.callbacks.onDrop?.(e)}))}},NDe=/(?[\w\-]+)?(?:#(?[\w\-]+))?(?(?:\.(?:[\w\-]+))*)(?:@(?(?:[\w\_])+))?/});var soe,aoe,loe,Cx,VB=k(()=>{ke();Ie();j();soe=class extends D{constructor(e){super(),this._onDidChange=this._register(new A),this.onDidChange=this._onDidChange.event,this._listener=()=>this._handleChange(e,!0),this._mediaQueryList=null,this._handleChange(e,!1)}_handleChange(e,t){this._mediaQueryList?.removeEventListener("change",this._listener),this._mediaQueryList=e.matchMedia(`(resolution: ${e.devicePixelRatio}dppx)`),this._mediaQueryList.addEventListener("change",this._listener),t&&this._onDidChange.fire()}},aoe=class extends D{get value(){return this._value}constructor(e){super(),this._onDidChange=this._register(new A),this.onDidChange=this._onDidChange.event,this._value=this._getPixelRatio(e);let t=this._register(new soe(e));this._register(t.onDidChange(()=>{this._value=this._getPixelRatio(e),this._onDidChange.fire(this._value)}))}_getPixelRatio(e){let t=document.createElement("canvas").getContext("2d"),i=e.devicePixelRatio||1,o=t.webkitBackingStorePixelRatio||t.mozBackingStorePixelRatio||t.msBackingStorePixelRatio||t.oBackingStorePixelRatio||t.backingStorePixelRatio||1;return i/o}},loe=class{constructor(){this.mapWindowIdToPixelRatioMonitor=new Map}_getOrCreatePixelRatioMonitor(e){let t=cL(e),i=this.mapWindowIdToPixelRatioMonitor.get(t);return i||(i=lx(new aoe(e)),this.mapWindowIdToPixelRatioMonitor.set(t,i),lx(ne.once(fDe)(({vscodeWindowId:o})=>{o===t&&(i?.dispose(),this.mapWindowIdToPixelRatioMonitor.delete(t))}))),i}getInstance(e){return this._getOrCreatePixelRatioMonitor(e)}},Cx=new loe});function pp(n){return typeof n=="number"?`${n}px`:n}function Pt(n){return new fA(n)}var fA,Kr=k(()=>{fA=class{constructor(e){this.domNode=e,this._maxWidth="",this._width="",this._height="",this._top="",this._left="",this._bottom="",this._right="",this._paddingLeft="",this._fontFamily="",this._fontWeight="",this._fontSize="",this._fontStyle="",this._fontFeatureSettings="",this._fontVariationSettings="",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(e){let t=pp(e);this._maxWidth!==t&&(this._maxWidth=t,this.domNode.style.maxWidth=this._maxWidth)}setWidth(e){let t=pp(e);this._width!==t&&(this._width=t,this.domNode.style.width=this._width)}setHeight(e){let t=pp(e);this._height!==t&&(this._height=t,this.domNode.style.height=this._height)}setTop(e){let t=pp(e);this._top!==t&&(this._top=t,this.domNode.style.top=this._top)}setLeft(e){let t=pp(e);this._left!==t&&(this._left=t,this.domNode.style.left=this._left)}setBottom(e){let t=pp(e);this._bottom!==t&&(this._bottom=t,this.domNode.style.bottom=this._bottom)}setRight(e){let t=pp(e);this._right!==t&&(this._right=t,this.domNode.style.right=this._right)}setPaddingLeft(e){let t=pp(e);this._paddingLeft!==t&&(this._paddingLeft=t,this.domNode.style.paddingLeft=this._paddingLeft)}setFontFamily(e){this._fontFamily!==e&&(this._fontFamily=e,this.domNode.style.fontFamily=this._fontFamily)}setFontWeight(e){this._fontWeight!==e&&(this._fontWeight=e,this.domNode.style.fontWeight=this._fontWeight)}setFontSize(e){let t=pp(e);this._fontSize!==t&&(this._fontSize=t,this.domNode.style.fontSize=this._fontSize)}setFontStyle(e){this._fontStyle!==e&&(this._fontStyle=e,this.domNode.style.fontStyle=this._fontStyle)}setFontFeatureSettings(e){this._fontFeatureSettings!==e&&(this._fontFeatureSettings=e,this.domNode.style.fontFeatureSettings=this._fontFeatureSettings)}setFontVariationSettings(e){this._fontVariationSettings!==e&&(this._fontVariationSettings=e,this.domNode.style.fontVariationSettings=this._fontVariationSettings)}setTextDecoration(e){this._textDecoration!==e&&(this._textDecoration=e,this.domNode.style.textDecoration=this._textDecoration)}setLineHeight(e){let t=pp(e);this._lineHeight!==t&&(this._lineHeight=t,this.domNode.style.lineHeight=this._lineHeight)}setLetterSpacing(e){let t=pp(e);this._letterSpacing!==t&&(this._letterSpacing=t,this.domNode.style.letterSpacing=this._letterSpacing)}setClassName(e){this._className!==e&&(this._className=e,this.domNode.className=this._className)}toggleClassName(e,t){this.domNode.classList.toggle(e,t),this._className=this.domNode.className}setDisplay(e){this._display!==e&&(this._display=e,this.domNode.style.display=this._display)}setPosition(e){this._position!==e&&(this._position=e,this.domNode.style.position=this._position)}setVisibility(e){this._visibility!==e&&(this._visibility=e,this.domNode.style.visibility=this._visibility)}setColor(e){this._color!==e&&(this._color=e,this.domNode.style.color=this._color)}setBackgroundColor(e){this._backgroundColor!==e&&(this._backgroundColor=e,this.domNode.style.backgroundColor=this._backgroundColor)}setLayerHinting(e){this._layerHint!==e&&(this._layerHint=e,this.domNode.style.transform=this._layerHint?"translate3d(0px, 0px, 0px)":"")}setBoxShadow(e){this._boxShadow!==e&&(this._boxShadow=e,this.domNode.style.boxShadow=e)}setContain(e){this._contain!==e&&(this._contain=e,this.domNode.style.contain=this._contain)}setAttribute(e,t){this.domNode.setAttribute(e,t)}removeAttribute(e){this.domNode.removeAttribute(e)}appendChild(e){this.domNode.appendChild(e.domNode)}removeChild(e){this.domNode.removeChild(e.domNode)}}});function Kn(n,e){n instanceof fA?(n.setFontFamily(e.getMassagedFontFamily()),n.setFontWeight(e.fontWeight),n.setFontSize(e.fontSize),n.setFontFeatureSettings(e.fontFeatureSettings),n.setFontVariationSettings(e.fontVariationSettings),n.setLineHeight(e.lineHeight),n.setLetterSpacing(e.letterSpacing)):(n.style.fontFamily=e.getMassagedFontFamily(),n.style.fontWeight=e.fontWeight,n.style.fontSize=e.fontSize+"px",n.style.fontFeatureSettings=e.fontFeatureSettings,n.style.fontVariationSettings=e.fontVariationSettings,n.style.lineHeight=e.lineHeight+"px",n.style.letterSpacing=e.letterSpacing+"px")}var bu=k(()=>{Kr()});function RDe(n,e,t){new coe(e,t).read(n)}var UB,coe,ADe=k(()=>{bu();UB=class{constructor(e,t){this.chr=e,this.type=t,this.width=0}fulfill(e){this.width=e}},coe=class n{constructor(e,t){this._bareFontInfo=e,this._requests=t,this._container=null,this._testElements=null}read(e){this._createDomElements(),e.document.body.appendChild(this._container),this._readFromDomElements(),this._container?.remove(),this._container=null,this._testElements=null}_createDomElements(){let e=document.createElement("div");e.style.position="absolute",e.style.top="-50000px",e.style.width="50000px";let t=document.createElement("div");Kn(t,this._bareFontInfo),e.appendChild(t);let i=document.createElement("div");Kn(i,this._bareFontInfo),i.style.fontWeight="bold",e.appendChild(i);let o=document.createElement("div");Kn(o,this._bareFontInfo),o.style.fontStyle="italic",e.appendChild(o);let r=[];for(let s of this._requests){let a;s.type===0&&(a=t),s.type===2&&(a=i),s.type===1&&(a=o),a.appendChild(document.createElement("br"));let l=document.createElement("span");n._render(l,s),a.appendChild(l),r.push(l)}this._container=e,this._testElements=r}static _render(e,t){if(t.chr===" "){let i="\xA0";for(let o=0;o<8;o++)i+=i;e.innerText=i}else{let i=t.chr;for(let o=0;o<8;o++)i+=i;e.textContent=i}}_readFromDomElements(){for(let e=0,t=this._requests.length;e{Ie();El=new class{constructor(){this._zoomLevel=0,this._onDidChangeZoomLevel=new A,this.onDidChangeZoomLevel=this._onDidChangeZoomLevel.event}getZoomLevel(){return this._zoomLevel}setZoomLevel(n){n=Math.min(Math.max(-5,n),20),this._zoomLevel!==n&&(this._zoomLevel=n,this._onDidChangeZoomLevel.fire(this._zoomLevel))}}});var brt,doe,A1,vrt,M1,$B=k(()=>{Bt();ir();mL();brt=dt?1.5:1.35,doe=8,A1=class n{static createFromValidatedSettings(e,t,i){let o=e.get(49),r=e.get(53),s=e.get(52),a=e.get(51),l=e.get(54),c=e.get(67),d=e.get(64);return n._create(o,r,s,a,l,c,d,t,i)}static _create(e,t,i,o,r,s,a,l,c){s===0?s=brt*i:s{ke();VB();Ie();j();ADe();ir();$B();uoe=class extends D{constructor(){super(...arguments),this._cache=new Map,this._evictUntrustedReadingsTimeout=-1,this._onDidChange=this._register(new A),this.onDidChange=this._onDidChange.event}dispose(){this._evictUntrustedReadingsTimeout!==-1&&(clearTimeout(this._evictUntrustedReadingsTimeout),this._evictUntrustedReadingsTimeout=-1),super.dispose()}clearAllFontInfos(){this._cache.clear(),this._onDidChange.fire()}_ensureCache(e){let t=cL(e),i=this._cache.get(t);return i||(i=new hoe,this._cache.set(t,i)),i}_writeToCache(e,t,i){this._ensureCache(e).put(t,i),!i.isTrusted&&this._evictUntrustedReadingsTimeout===-1&&(this._evictUntrustedReadingsTimeout=e.setTimeout(()=>{this._evictUntrustedReadingsTimeout=-1,this._evictUntrustedReadings(e)},5e3))}_evictUntrustedReadings(e){let t=this._ensureCache(e),i=t.getValues(),o=!1;for(let r of i)r.isTrusted||(o=!0,t.remove(r));o&&this._onDidChange.fire()}readFontInfo(e,t){let i=this._ensureCache(e);if(!i.has(t)){let o=this._actualReadFontInfo(e,t);(o.typicalHalfwidthCharacterWidth<=2||o.typicalFullwidthCharacterWidth<=2||o.spaceWidth<=2||o.maxDigitWidth<=2)&&(o=new M1({pixelRatio:Cx.getInstance(e).value,fontFamily:o.fontFamily,fontWeight:o.fontWeight,fontSize:o.fontSize,fontFeatureSettings:o.fontFeatureSettings,fontVariationSettings:o.fontVariationSettings,lineHeight:o.lineHeight,letterSpacing:o.letterSpacing,isMonospace:o.isMonospace,typicalHalfwidthCharacterWidth:Math.max(o.typicalHalfwidthCharacterWidth,5),typicalFullwidthCharacterWidth:Math.max(o.typicalFullwidthCharacterWidth,5),canUseHalfwidthRightwardsArrow:o.canUseHalfwidthRightwardsArrow,spaceWidth:Math.max(o.spaceWidth,5),middotWidth:Math.max(o.middotWidth,5),wsmiddotWidth:Math.max(o.wsmiddotWidth,5),maxDigitWidth:Math.max(o.maxDigitWidth,5)},!1)),this._writeToCache(e,t,o)}return i.get(t)}_createRequest(e,t,i,o){let r=new UB(e,t);return i.push(r),o?.push(r),r}_actualReadFontInfo(e,t){let i=[],o=[],r=this._createRequest("n",0,i,o),s=this._createRequest("\uFF4D",0,i,null),a=this._createRequest(" ",0,i,o),l=this._createRequest("0",0,i,o),c=this._createRequest("1",0,i,o),d=this._createRequest("2",0,i,o),u=this._createRequest("3",0,i,o),h=this._createRequest("4",0,i,o),f=this._createRequest("5",0,i,o),p=this._createRequest("6",0,i,o),g=this._createRequest("7",0,i,o),_=this._createRequest("8",0,i,o),b=this._createRequest("9",0,i,o),v=this._createRequest("\u2192",0,i,o),x=this._createRequest("\uFFEB",0,i,null),w=this._createRequest("\xB7",0,i,o),y=this._createRequest("\u2E31",0,i,null),C="|/-_ilm%";for(let F=0,q=C.length;F.001){E=!1;break}}let M=!0;return E&&x.width!==N&&(M=!1),x.width>v.width&&(M=!1),new M1({pixelRatio:Cx.getInstance(e).value,fontFamily:t.fontFamily,fontWeight:t.fontWeight,fontSize:t.fontSize,fontFeatureSettings:t.fontFeatureSettings,fontVariationSettings:t.fontVariationSettings,lineHeight:t.lineHeight,letterSpacing:t.letterSpacing,isMonospace:E,typicalHalfwidthCharacterWidth:r.width,typicalFullwidthCharacterWidth:s.width,canUseHalfwidthRightwardsArrow:M,spaceWidth:a.width,middotWidth:w.width,wsmiddotWidth:y.width,maxDigitWidth:L},!0)}},hoe=class{constructor(){this._keys=Object.create(null),this._values=Object.create(null)}has(e){let t=e.getId();return!!this._values[t]}get(e){let t=e.getId();return this._values[t]}put(e,t){let i=e.getId();this._keys[i]=e,this._values[i]=t}remove(e){let t=e.getId();delete this._keys[t],delete this._values[t]}getValues(){return Object.keys(this._keys).map(e=>this._values[e])}},pA=new uoe});function xrt(n,e,t){e[gf.DI_TARGET]===e?e[gf.DI_DEPENDENCIES].push({id:n,index:t}):(e[gf.DI_DEPENDENCIES]=[{id:n,index:t}],e[gf.DI_TARGET]=e)}function We(n){if(gf.serviceIds.has(n))return gf.serviceIds.get(n);let e=function(t,i,o){if(arguments.length!==3)throw new Error("@IServiceName-decorator can only be used to decorate a parameter");xrt(e,t,o)};return e.toString=()=>n,gf.serviceIds.set(n,e),e}var gf,he,Fe=k(()=>{(function(n){n.serviceIds=new Map,n.DI_TARGET="$di$target",n.DI_DEPENDENCIES="$di$dependencies";function e(t){return t[n.DI_DEPENDENCIES]||[]}n.getServiceDependencies=e})(gf||(gf={}));he=We("instantiationService")});var xt,Po=k(()=>{Fe();xt=We("codeEditorService")});var di,va=k(()=>{Fe();di=We("modelService")});var Uo,vu=k(()=>{Fe();Uo=We("textModelService")});function Dm(n){return{id:n.id,label:n.label,tooltip:n.tooltip??n.label,class:n.class,enabled:n.enabled??!0,checked:n.checked,run:async(...e)=>n.run(...e)}}var rr,Td,Gn,bh,jB,Gr=k(()=>{Ie();j();pe();rr=class extends D{constructor(e,t="",i="",o=!0,r){super(),this._onDidChange=this._register(new A),this.onDidChange=this._onDidChange.event,this._enabled=!0,this._id=e,this._label=t,this._cssClass=i,this._enabled=o,this._actionCallback=r}get id(){return this._id}get label(){return this._label}set label(e){this._setLabel(e)}_setLabel(e){this._label!==e&&(this._label=e,this._onDidChange.fire({label:e}))}get tooltip(){return this._tooltip||""}set tooltip(e){this._setTooltip(e)}_setTooltip(e){this._tooltip!==e&&(this._tooltip=e,this._onDidChange.fire({tooltip:e}))}get class(){return this._cssClass}set class(e){this._setClass(e)}_setClass(e){this._cssClass!==e&&(this._cssClass=e,this._onDidChange.fire({class:e}))}get enabled(){return this._enabled}set enabled(e){this._setEnabled(e)}_setEnabled(e){this._enabled!==e&&(this._enabled=e,this._onDidChange.fire({enabled:e}))}get checked(){return this._checked}set checked(e){this._setChecked(e)}_setChecked(e){this._checked!==e&&(this._checked=e,this._onDidChange.fire({checked:e}))}async run(e,t){this._actionCallback&&await this._actionCallback(e)}},Td=class extends D{constructor(){super(...arguments),this._onWillRun=this._register(new A),this.onWillRun=this._onWillRun.event,this._onDidRun=this._register(new A),this.onDidRun=this._onDidRun.event}async run(e,t){if(!e.enabled)return;this._onWillRun.fire({action:e});let i;try{await this.runAction(e,t)}catch(o){i=o}this._onDidRun.fire({action:e,error:i})}async runAction(e,t){await e.run(t)}},Gn=class n{constructor(){this.id=n.ID,this.label="",this.tooltip="",this.class="separator",this.enabled=!1,this.checked=!1}static join(...e){let t=[];for(let i of e)i.length&&(t.length?t=[...t,new n,...i]:t=i);return t}static{this.ID="vs.actions.separator"}async run(){}},bh=class{get actions(){return this._actions}constructor(e,t,i,o){this.tooltip="",this.enabled=!0,this.checked=void 0,this.id=e,this.label=t,this.class=o,this._actions=i}async run(){}},jB=class n extends rr{static{this.ID="vs.actions.empty"}constructor(){super(n.ID,m("submenu.empty","(empty)"),void 0,!1)}}});var poe,Oe,bn=k(()=>{Qi();(function(n){function e(t){return t&&typeof t=="object"&&typeof t.id=="string"}n.isThemeColor=e})(poe||(poe={}));(function(n){n.iconNameSegment="[A-Za-z0-9]+",n.iconNameExpression="[A-Za-z0-9-]+",n.iconModifierExpression="~[A-Za-z]+",n.iconNameCharacter="[A-Za-z0-9~-]";let e=new RegExp(`^(${n.iconNameExpression})(${n.iconModifierExpression})?$`);function t(h){let f=e.exec(h.id);if(!f)return t(oe.error);let[,p,g]=f,_=["codicon","codicon-"+p];return g&&_.push("codicon-modifier-"+g.substring(1)),_}n.asClassNameArray=t;function i(h){return t(h).join(" ")}n.asClassName=i;function o(h){return"."+t(h).join(".")}n.asCSSSelector=o;function r(h){return h&&typeof h=="object"&&typeof h.id=="string"&&(typeof h.color>"u"||poe.isThemeColor(h.color))}n.isThemeIcon=r;let s=new RegExp(`^\\$\\((${n.iconNameExpression}(?:${n.iconModifierExpression})?)\\)$`);function a(h){let f=s.exec(h);if(!f)return;let[,p]=f;return{id:p}}n.fromString=a;function l(h){return{id:h}}n.fromId=l;function c(h,f){let p=h.id,g=p.lastIndexOf("~");return g!==-1&&(p=p.substring(0,g)),f&&(p=`${p}~${f}`),{id:p}}n.modify=c;function d(h){let f=h.id.lastIndexOf("~");if(f!==-1)return h.id.substring(f+1)}n.getModifier=d;function u(h,f){return h.id===f.id&&h.color?.id===f.color?.id}n.isEqual=u})(Oe||(Oe={}))});var $t,wt,Gi=k(()=>{Ie();Cl();j();du();yi();Fe();$t=We("commandService"),wt=new class{constructor(){this._commands=new Map,this._onDidRegisterCommand=new A,this.onDidRegisterCommand=this._onDidRegisterCommand.event}registerCommand(n,e){if(!n)throw new Error("invalid command");if(typeof n=="string"){if(!e)throw new Error("invalid command");return this.registerCommand({id:n,handler:e})}if(n.metadata&&Array.isArray(n.metadata.args)){let s=[];for(let l of n.metadata.args)s.push(l.constraint);let a=n.handler;n.handler=function(l,...c){return VEe(c,s),a(l,...c)}}let{id:t}=n,i=this._commands.get(t);i||(i=new go,this._commands.set(t,i));let o=i.unshift(n),r=ge(()=>{o(),this._commands.get(t)?.isEmpty()&&this._commands.delete(t)});return this._onDidRegisterCommand.fire(t),r}registerCommandAlias(n,e){return wt.registerCommand(n,(t,...i)=>t.get($t).executeCommand(e,...i))}getCommand(n){let e=this._commands.get(n);if(!(!e||e.isEmpty()))return Dt.first(e)}getCommands(){let n=new Map;for(let e of this._commands.keys()){let t=this.getCommand(e);t&&n.set(e,t)}return n}};wt.registerCommand("noop",()=>{})});function moe(...n){switch(n.length){case 1:return m("contextkey.scanner.hint.didYouMean1","Did you mean {0}?",n[0]);case 2:return m("contextkey.scanner.hint.didYouMean2","Did you mean {0} or {1}?",n[0],n[1]);case 3:return m("contextkey.scanner.hint.didYouMean3","Did you mean {0}, {1} or {2}?",n[0],n[1],n[2]);default:return}}var wrt,yrt,Sx,MDe=k(()=>{je();pe();wrt=m("contextkey.scanner.hint.didYouForgetToOpenOrCloseQuote","Did you forget to open or close the quote?"),yrt=m("contextkey.scanner.hint.didYouForgetToEscapeSlash","Did you forget to escape the '/' (slash) character? Put two backslashes before it to escape, e.g., '\\\\/'."),Sx=class n{constructor(){this._input="",this._start=0,this._current=0,this._tokens=[],this._errors=[],this.stringRe=/[a-zA-Z0-9_<>\-\./\\:\*\?\+\[\]\^,#@;"%\$\p{L}-]+/uy}static getLexeme(e){switch(e.type){case 0:return"(";case 1:return")";case 2:return"!";case 3:return e.isTripleEq?"===":"==";case 4:return e.isTripleEq?"!==":"!=";case 5:return"<";case 6:return"<=";case 7:return">=";case 8:return">=";case 9:return"=~";case 10:return e.lexeme;case 11:return"true";case 12:return"false";case 13:return"in";case 14:return"not";case 15:return"&&";case 16:return"||";case 17:return e.lexeme;case 18:return e.lexeme;case 19:return e.lexeme;case 20:return"EOF";default:throw Kk(`unhandled token type: ${JSON.stringify(e)}; have you forgotten to add a case?`)}}static{this._regexFlags=new Set(["i","g","s","m","y","u"].map(e=>e.charCodeAt(0)))}static{this._keywords=new Map([["not",14],["in",13],["false",12],["true",11]])}reset(e){return this._input=e,this._start=0,this._current=0,this._tokens=[],this._errors=[],this}scan(){for(;!this._isAtEnd();)switch(this._start=this._current,this._advance()){case 40:this._addToken(0);break;case 41:this._addToken(1);break;case 33:if(this._match(61)){let t=this._match(61);this._tokens.push({type:4,offset:this._start,isTripleEq:t})}else this._addToken(2);break;case 39:this._quotedString();break;case 47:this._regex();break;case 61:if(this._match(61)){let t=this._match(61);this._tokens.push({type:3,offset:this._start,isTripleEq:t})}else this._match(126)?this._addToken(9):this._error(moe("==","=~"));break;case 60:this._addToken(this._match(61)?6:5);break;case 62:this._addToken(this._match(61)?8:7);break;case 38:this._match(38)?this._addToken(15):this._error(moe("&&"));break;case 124:this._match(124)?this._addToken(16):this._error(moe("||"));break;case 32:case 13:case 9:case 10:case 160:break;default:this._string()}return this._start=this._current,this._addToken(20),Array.from(this._tokens)}_match(e){return this._isAtEnd()||this._input.charCodeAt(this._current)!==e?!1:(this._current++,!0)}_advance(){return this._input.charCodeAt(this._current++)}_peek(){return this._isAtEnd()?0:this._input.charCodeAt(this._current)}_addToken(e){this._tokens.push({type:e,offset:this._start})}_error(e){let t=this._start,i=this._input.substring(this._start,this._current),o={type:19,offset:this._start,lexeme:i};this._errors.push({offset:t,lexeme:i,additionalInfo:e}),this._tokens.push(o)}_string(){this.stringRe.lastIndex=this._start;let e=this.stringRe.exec(this._input);if(e){this._current=this._start+e[0].length;let t=this._input.substring(this._start,this._current),i=n._keywords.get(t);i?this._addToken(i):this._tokens.push({type:17,lexeme:t,offset:this._start})}}_quotedString(){for(;this._peek()!==39&&!this._isAtEnd();)this._advance();if(this._isAtEnd()){this._error(wrt);return}this._advance(),this._tokens.push({type:18,lexeme:this._input.substring(this._start+1,this._current-1),offset:this._start+1})}_regex(){let e=this._current,t=!1,i=!1;for(;;){if(e>=this._input.length){this._current=e,this._error(yrt);return}let r=this._input.charCodeAt(e);if(t)t=!1;else if(r===47&&!i){e++;break}else r===91?i=!0:r===92?t=!0:r===93&&(i=!1);e++}for(;e=this._input.length}}});function BDe(n,e){let t=n?n.substituteConstants():void 0,i=e?e.substituteConstants():void 0;return!t&&!i?!0:!t||!i?!1:t.equals(i)}function mA(n,e){return n.cmp(e)}function t6(n,e){if(typeof n=="string"){let t=parseFloat(n);isNaN(t)||(n=t)}return typeof n=="string"||typeof n=="number"?e(n):rc.INSTANCE}function WDe(n){let e=null;for(let t=0,i=n.length;te?1:0}function B1(n,e,t,i){return nt?1:ei?1:0}function e6(n,e){if(n.type===0||e.type===1)return!0;if(n.type===9)return e.type===9?ODe(n.expr,e.expr):!1;if(e.type===9){for(let t of e.expr)if(e6(n,t))return!0;return!1}if(n.type===6){if(e.type===6)return ODe(e.expr,n.expr);for(let t of n.expr)if(e6(t,e))return!0;return!1}return n.equals(e)}function ODe(n,e){let t=0,i=0;for(;t{Bt();Qe();MDe();Fe();pe();el=new Map;el.set("false",!1);el.set("true",!0);el.set("isMac",dt);el.set("isLinux",Qn);el.set("isWindows",kn);el.set("isWeb",df);el.set("isMacNative",dt&&!df);el.set("isEdge",nTe);el.set("isFirefox",tTe);el.set("isChrome",kie);el.set("isSafari",iTe);Crt=Object.prototype.hasOwnProperty,Srt={regexParsingWithErrorRecovery:!0},krt=m("contextkey.parser.error.emptyString","Empty context key expression"),Lrt=m("contextkey.parser.error.emptyString.hint","Did you forget to write an expression? You can also put 'false' or 'true' to always evaluate to false or true, respectively."),Irt=m("contextkey.parser.error.noInAfterNot","'in' after 'not'."),PDe=m("contextkey.parser.error.closingParenthesis","closing parenthesis ')'"),Ert=m("contextkey.parser.error.unexpectedToken","Unexpected token"),Trt=m("contextkey.parser.error.unexpectedToken.hint","Did you forget to put && or || before the token?"),Drt=m("contextkey.parser.error.unexpectedEOF","Unexpected end of expression"),Nrt=m("contextkey.parser.error.unexpectedEOF.hint","Did you forget to put a context key?"),goe=class n{static{this._parseError=new Error}constructor(e=Srt){this._config=e,this._scanner=new Sx,this._tokens=[],this._current=0,this._parsingErrors=[],this._flagsGYRe=/g|y/g}parse(e){if(e===""){this._parsingErrors.push({message:krt,offset:0,lexeme:"",additionalInfo:Lrt});return}this._tokens=this._scanner.reset(e).scan(),this._current=0,this._parsingErrors=[];try{let t=this._expr();if(!this._isAtEnd()){let i=this._peek(),o=i.type===17?Trt:void 0;throw this._parsingErrors.push({message:Ert,offset:i.offset,lexeme:Sx.getLexeme(i),additionalInfo:o}),n._parseError}return t}catch(t){if(t!==n._parseError)throw t;return}}_expr(){return this._or()}_or(){let e=[this._and()];for(;this._matchOne(16);){let t=this._and();e.push(t)}return e.length===1?e[0]:Y.or(...e)}_and(){let e=[this._term()];for(;this._matchOne(15);){let t=this._term();e.push(t)}return e.length===1?e[0]:Y.and(...e)}_term(){if(this._matchOne(2)){let e=this._peek();switch(e.type){case 11:return this._advance(),rc.INSTANCE;case 12:return this._advance(),Hc.INSTANCE;case 0:{this._advance();let t=this._expr();return this._consume(1,PDe),t?.negate()}case 17:return this._advance(),F1.create(e.lexeme);default:throw this._errExpectedButGot("KEY | true | false | '(' expression ')'",e)}}return this._primary()}_primary(){let e=this._peek();switch(e.type){case 11:return this._advance(),Y.true();case 12:return this._advance(),Y.false();case 0:{this._advance();let t=this._expr();return this._consume(1,PDe),t}case 17:{let t=e.lexeme;if(this._advance(),this._matchOne(9)){let o=this._peek();if(!this._config.regexParsingWithErrorRecovery){if(this._advance(),o.type!==10)throw this._errExpectedButGot("REGEX",o);let r=o.lexeme,s=r.lastIndexOf("/"),a=s===r.length-1?void 0:this._removeFlagsGY(r.substring(s+1)),l;try{l=new RegExp(r.substring(1,s),a)}catch{throw this._errExpectedButGot("REGEX",o)}return gA.create(t,l)}switch(o.type){case 10:case 19:{let r=[o.lexeme];this._advance();let s=this._peek(),a=0;for(let h=0;h=0){let c=r.slice(a+1,l),d=r[l+1]==="i"?"i":"";try{s=new RegExp(c,d)}catch{throw this._errExpectedButGot("REGEX",o)}}}if(s===null)throw this._errExpectedButGot("REGEX",o);return gA.create(t,s)}default:throw this._errExpectedButGot("REGEX",this._peek())}}if(this._matchOne(14)){this._consume(13,Irt);let o=this._value();return Y.notIn(t,o)}switch(this._peek().type){case 3:{this._advance();let o=this._value();if(this._previous().type===18)return Y.equals(t,o);switch(o){case"true":return Y.has(t);case"false":return Y.not(t);default:return Y.equals(t,o)}}case 4:{this._advance();let o=this._value();if(this._previous().type===18)return Y.notEquals(t,o);switch(o){case"true":return Y.not(t);case"false":return Y.has(t);default:return Y.notEquals(t,o)}}case 5:return this._advance(),XB.create(t,this._value());case 6:return this._advance(),QB.create(t,this._value());case 7:return this._advance(),YB.create(t,this._value());case 8:return this._advance(),ZB.create(t,this._value());case 13:return this._advance(),Y.in(t,this._value());default:return Y.has(t)}}case 20:throw this._parsingErrors.push({message:Drt,offset:e.offset,lexeme:"",additionalInfo:Nrt}),n._parseError;default:throw this._errExpectedButGot(`true | false | KEY | KEY '=~' REGEX | KEY ('==' | '!=' | '<' | '<=' | '>' | '>=' | 'in' | 'not' 'in') value`,this._peek())}}_value(){let e=this._peek();switch(e.type){case 17:case 18:return this._advance(),e.lexeme;case 11:return this._advance(),"true";case 12:return this._advance(),"false";case 13:return this._advance(),"in";default:return""}}_removeFlagsGY(e){return e.replaceAll(this._flagsGYRe,"")}_previous(){return this._tokens[this._current-1]}_matchOne(e){return this._check(e)?(this._advance(),!0):!1}_advance(){return this._isAtEnd()||this._current++,this._previous()}_consume(e,t){if(this._check(e))return this._advance();throw this._errExpectedButGot(t,this._peek())}_errExpectedButGot(e,t,i){let o=m("contextkey.parser.error.expectedButGot",`Expected: {0} Received: '{1}'.`,e,Sx.getLexeme(t)),r=t.offset,s=Sx.getLexeme(t);return this._parsingErrors.push({message:o,offset:r,lexeme:s,additionalInfo:i}),n._parseError}_check(e){return this._peek().type===e}_peek(){return this._tokens[this._current]}_isAtEnd(){return this._peek().type===20}},Y=class{static false(){return rc.INSTANCE}static true(){return Hc.INSTANCE}static has(e){return P1.create(e)}static equals(e,t){return O1.create(e,t)}static notEquals(e,t){return GB.create(e,t)}static regex(e,t){return gA.create(e,t)}static in(e,t){return qB.create(e,t)}static notIn(e,t){return KB.create(e,t)}static not(e){return F1.create(e)}static and(...e){return JB.create(e,null,!0)}static or(...e){return _A.create(e,null,!0)}static{this._parser=new goe({regexParsingWithErrorRecovery:!1})}static deserialize(e){return e==null?void 0:this._parser.parse(e)}};rc=class n{static{this.INSTANCE=new n}constructor(){this.type=0}cmp(e){return this.type-e.type}equals(e){return e.type===this.type}substituteConstants(){return this}evaluate(e){return!1}serialize(){return"false"}keys(){return[]}negate(){return Hc.INSTANCE}},Hc=class n{static{this.INSTANCE=new n}constructor(){this.type=1}cmp(e){return this.type-e.type}equals(e){return e.type===this.type}substituteConstants(){return this}evaluate(e){return!0}serialize(){return"true"}keys(){return[]}negate(){return rc.INSTANCE}},P1=class n{static create(e,t=null){let i=el.get(e);return typeof i=="boolean"?i?Hc.INSTANCE:rc.INSTANCE:new n(e,t)}constructor(e,t){this.key=e,this.negated=t,this.type=2}cmp(e){return e.type!==this.type?this.type-e.type:HDe(this.key,e.key)}equals(e){return e.type===this.type?this.key===e.key:!1}substituteConstants(){let e=el.get(this.key);return typeof e=="boolean"?e?Hc.INSTANCE:rc.INSTANCE:this}evaluate(e){return!!e.getValue(this.key)}serialize(){return this.key}keys(){return[this.key]}negate(){return this.negated||(this.negated=F1.create(this.key,this)),this.negated}},O1=class n{static create(e,t,i=null){if(typeof t=="boolean")return t?P1.create(e,i):F1.create(e,i);let o=el.get(e);return typeof o=="boolean"?t===(o?"true":"false")?Hc.INSTANCE:rc.INSTANCE:new n(e,t,i)}constructor(e,t,i){this.key=e,this.value=t,this.negated=i,this.type=4}cmp(e){return e.type!==this.type?this.type-e.type:B1(this.key,this.value,e.key,e.value)}equals(e){return e.type===this.type?this.key===e.key&&this.value===e.value:!1}substituteConstants(){let e=el.get(this.key);if(typeof e=="boolean"){let t=e?"true":"false";return this.value===t?Hc.INSTANCE:rc.INSTANCE}return this}evaluate(e){return e.getValue(this.key)==this.value}serialize(){return`${this.key} == '${this.value}'`}keys(){return[this.key]}negate(){return this.negated||(this.negated=GB.create(this.key,this.value,this)),this.negated}},qB=class n{static create(e,t){return new n(e,t)}constructor(e,t){this.key=e,this.valueKey=t,this.type=10,this.negated=null}cmp(e){return e.type!==this.type?this.type-e.type:B1(this.key,this.valueKey,e.key,e.valueKey)}equals(e){return e.type===this.type?this.key===e.key&&this.valueKey===e.valueKey:!1}substituteConstants(){return this}evaluate(e){let t=e.getValue(this.valueKey),i=e.getValue(this.key);return Array.isArray(t)?t.includes(i):typeof i=="string"&&typeof t=="object"&&t!==null?Crt.call(t,i):!1}serialize(){return`${this.key} in '${this.valueKey}'`}keys(){return[this.key,this.valueKey]}negate(){return this.negated||(this.negated=KB.create(this.key,this.valueKey)),this.negated}},KB=class n{static create(e,t){return new n(e,t)}constructor(e,t){this.key=e,this.valueKey=t,this.type=11,this._negated=qB.create(e,t)}cmp(e){return e.type!==this.type?this.type-e.type:this._negated.cmp(e._negated)}equals(e){return e.type===this.type?this._negated.equals(e._negated):!1}substituteConstants(){return this}evaluate(e){return!this._negated.evaluate(e)}serialize(){return`${this.key} not in '${this.valueKey}'`}keys(){return this._negated.keys()}negate(){return this._negated}},GB=class n{static create(e,t,i=null){if(typeof t=="boolean")return t?F1.create(e,i):P1.create(e,i);let o=el.get(e);return typeof o=="boolean"?t===(o?"true":"false")?rc.INSTANCE:Hc.INSTANCE:new n(e,t,i)}constructor(e,t,i){this.key=e,this.value=t,this.negated=i,this.type=5}cmp(e){return e.type!==this.type?this.type-e.type:B1(this.key,this.value,e.key,e.value)}equals(e){return e.type===this.type?this.key===e.key&&this.value===e.value:!1}substituteConstants(){let e=el.get(this.key);if(typeof e=="boolean"){let t=e?"true":"false";return this.value===t?rc.INSTANCE:Hc.INSTANCE}return this}evaluate(e){return e.getValue(this.key)!=this.value}serialize(){return`${this.key} != '${this.value}'`}keys(){return[this.key]}negate(){return this.negated||(this.negated=O1.create(this.key,this.value,this)),this.negated}},F1=class n{static create(e,t=null){let i=el.get(e);return typeof i=="boolean"?i?rc.INSTANCE:Hc.INSTANCE:new n(e,t)}constructor(e,t){this.key=e,this.negated=t,this.type=3}cmp(e){return e.type!==this.type?this.type-e.type:HDe(this.key,e.key)}equals(e){return e.type===this.type?this.key===e.key:!1}substituteConstants(){let e=el.get(this.key);return typeof e=="boolean"?e?rc.INSTANCE:Hc.INSTANCE:this}evaluate(e){return!e.getValue(this.key)}serialize(){return`!${this.key}`}keys(){return[this.key]}negate(){return this.negated||(this.negated=P1.create(this.key,this)),this.negated}};YB=class n{static create(e,t,i=null){return t6(t,o=>new n(e,o,i))}constructor(e,t,i){this.key=e,this.value=t,this.negated=i,this.type=12}cmp(e){return e.type!==this.type?this.type-e.type:B1(this.key,this.value,e.key,e.value)}equals(e){return e.type===this.type?this.key===e.key&&this.value===e.value:!1}substituteConstants(){return this}evaluate(e){return typeof this.value=="string"?!1:parseFloat(e.getValue(this.key))>this.value}serialize(){return`${this.key} > ${this.value}`}keys(){return[this.key]}negate(){return this.negated||(this.negated=QB.create(this.key,this.value,this)),this.negated}},ZB=class n{static create(e,t,i=null){return t6(t,o=>new n(e,o,i))}constructor(e,t,i){this.key=e,this.value=t,this.negated=i,this.type=13}cmp(e){return e.type!==this.type?this.type-e.type:B1(this.key,this.value,e.key,e.value)}equals(e){return e.type===this.type?this.key===e.key&&this.value===e.value:!1}substituteConstants(){return this}evaluate(e){return typeof this.value=="string"?!1:parseFloat(e.getValue(this.key))>=this.value}serialize(){return`${this.key} >= ${this.value}`}keys(){return[this.key]}negate(){return this.negated||(this.negated=XB.create(this.key,this.value,this)),this.negated}},XB=class n{static create(e,t,i=null){return t6(t,o=>new n(e,o,i))}constructor(e,t,i){this.key=e,this.value=t,this.negated=i,this.type=14}cmp(e){return e.type!==this.type?this.type-e.type:B1(this.key,this.value,e.key,e.value)}equals(e){return e.type===this.type?this.key===e.key&&this.value===e.value:!1}substituteConstants(){return this}evaluate(e){return typeof this.value=="string"?!1:parseFloat(e.getValue(this.key))new n(e,o,i))}constructor(e,t,i){this.key=e,this.value=t,this.negated=i,this.type=15}cmp(e){return e.type!==this.type?this.type-e.type:B1(this.key,this.value,e.key,e.value)}equals(e){return e.type===this.type?this.key===e.key&&this.value===e.value:!1}substituteConstants(){return this}evaluate(e){return typeof this.value=="string"?!1:parseFloat(e.getValue(this.key))<=this.value}serialize(){return`${this.key} <= ${this.value}`}keys(){return[this.key]}negate(){return this.negated||(this.negated=YB.create(this.key,this.value,this)),this.negated}},gA=class n{static create(e,t){return new n(e,t)}constructor(e,t){this.key=e,this.regexp=t,this.type=7,this.negated=null}cmp(e){if(e.type!==this.type)return this.type-e.type;if(this.keye.key)return 1;let t=this.regexp?this.regexp.source:"",i=e.regexp?e.regexp.source:"";return ti?1:0}equals(e){if(e.type===this.type){let t=this.regexp?this.regexp.source:"",i=e.regexp?e.regexp.source:"";return this.key===e.key&&t===i}return!1}substituteConstants(){return this}evaluate(e){let t=e.getValue(this.key);return this.regexp?this.regexp.test(t):!1}serialize(){let e=this.regexp?`/${this.regexp.source}/${this.regexp.flags}`:"/invalid/";return`${this.key} =~ ${e}`}keys(){return[this.key]}negate(){return this.negated||(this.negated=_oe.create(this)),this.negated}},_oe=class n{static create(e){return new n(e)}constructor(e){this._actual=e,this.type=8}cmp(e){return e.type!==this.type?this.type-e.type:this._actual.cmp(e._actual)}equals(e){return e.type===this.type?this._actual.equals(e._actual):!1}substituteConstants(){return this}evaluate(e){return!this._actual.evaluate(e)}serialize(){return`!(${this._actual.serialize()})`}keys(){return this._actual.keys()}negate(){return this._actual}};JB=class n{static create(e,t,i){return n._normalizeArr(e,t,i)}constructor(e,t){this.expr=e,this.negated=t,this.type=6}cmp(e){if(e.type!==this.type)return this.type-e.type;if(this.expr.lengthe.expr.length)return 1;for(let t=0,i=this.expr.length;t1;){let s=o[o.length-1];if(s.type!==9)break;o.pop();let a=o.pop(),l=o.length===0,c=_A.create(s.expr.map(d=>n.create([d,a],null,i)),null,l);c&&(o.push(c),o.sort(mA))}if(o.length===1)return o[0];if(i){for(let s=0;se.serialize()).join(" && ")}keys(){let e=[];for(let t of this.expr)e.push(...t.keys());return e}negate(){if(!this.negated){let e=[];for(let t of this.expr)e.push(t.negate());this.negated=_A.create(e,this,!0)}return this.negated}},_A=class n{static create(e,t,i){return n._normalizeArr(e,t,i)}constructor(e,t){this.expr=e,this.negated=t,this.type=9}cmp(e){if(e.type!==this.type)return this.type-e.type;if(this.expr.lengthe.expr.length)return 1;for(let t=0,i=this.expr.length;te.serialize()).join(" || ")}keys(){let e=[];for(let t of this.expr)e.push(...t.keys());return e}negate(){if(!this.negated){let e=[];for(let t of this.expr)e.push(t.negate());for(;e.length>1;){let t=e.shift(),i=e.shift(),o=[];for(let r of FDe(t))for(let s of FDe(i))o.push(JB.create([r,s],null,!1));e.unshift(n.create(o,null,!1))}this.negated=n.create(e,this,!0)}return this.negated}},me=class n extends P1{static{this._info=[]}static all(){return n._info.values()}constructor(e,t,i){super(e,null),this._defaultValue=t,typeof i=="object"?n._info.push({...i,key:e}):i!==!0&&n._info.push({key:e,description:i,type:t!=null?typeof t:void 0})}bindTo(e){return e.createKey(this.key,this._defaultValue)}getValue(e){return e.getContextKeyValue(this.key)}toNegated(){return this.negate()}isEqualTo(e){return O1.create(this.key,e)}},Le=We("contextKeyService")});function i6(n,e){if(!n)throw new Error(e?`Assertion failed (${e})`:"Assertion Failed")}function kx(n,e="Unreachable"){throw new Error(e)}function boe(n){n||Be(new Nt("Soft Assertion Failed"))}function _f(n){if(!n()){debugger;n(),Be(new Nt("Assertion Failed"))}}function gL(n,e){let t=0;for(;t{je()});var voe,ei,br=k(()=>{bf();yi();voe=class{constructor(){this.data=new Map}add(e,t){i6(Rr(e)),i6(mo(t)),i6(!this.data.has(e),"There is already an extension with this id"),this.data.set(e,t)}as(e){return this.data.get(e)||null}},ei=new voe});function Mrt(n,e){if(n.weight1!==e.weight1)return n.weight1-e.weight1;if(n.command&&e.command){if(n.commande.command)return 1}return n.weight2-e.weight2}var xoe,Mr,Art,K_=k(()=>{S1();Bt();Gi();br();j();du();xoe=class n{constructor(){this._coreKeybindings=new go,this._extensionKeybindings=[],this._cachedMergedKeybindings=null}static bindToCurrentPlatform(e){if(Ur===1){if(e&&e.win)return e.win}else if(Ur===2){if(e&&e.mac)return e.mac}else if(e&&e.linux)return e.linux;return e}registerKeybindingRule(e){let t=n.bindToCurrentPlatform(e),i=new H;if(t&&t.primary){let o=JR(t.primary,Ur);o&&i.add(this._registerDefaultKeybinding(o,e.id,e.args,e.weight,0,e.when))}if(t&&Array.isArray(t.secondary))for(let o=0,r=t.secondary.length;o{a(),this._cachedMergedKeybindings=null})}getDefaultKeybindings(){return this._cachedMergedKeybindings||(this._cachedMergedKeybindings=Array.from(this._coreKeybindings).concat(this._extensionKeybindings),this._cachedMergedKeybindings.sort(Mrt)),this._cachedMergedKeybindings.slice(0)}},Mr=new xoe,Art={EditorModes:"platform.keybindingsRegistry"};ei.add(Art.EditorModes,Mr)});function Lx(n){return n.command!==void 0}function VDe(n){return n.submenu!==void 0}function zi(n){let e=[],t=new n,{f1:i,menu:o,keybinding:r,...s}=t.desc;if(wt.getCommand(s.id))throw new Error(`Cannot register two commands with the same id: ${s.id}`);if(e.push(wt.registerCommand({id:s.id,handler:(a,...l)=>t.run(a,...l),metadata:s.metadata})),Array.isArray(o))for(let a of o)e.push(Lo.appendMenuItem(a.id,{command:{...s,precondition:a.precondition===null?void 0:s.precondition},...a}));else o&&e.push(Lo.appendMenuItem(o.id,{command:{...s,precondition:o.precondition===null?void 0:s.precondition},...o}));if(i&&(e.push(Lo.appendMenuItem(Te.CommandPalette,{command:s,when:s.precondition})),e.push(Lo.addCommand(s))),Array.isArray(r))for(let a of r)e.push(Mr.registerKeybindingRule({...a,id:s.id,when:s.precondition?Y.and(s.precondition,a.when):a.when}));else r&&e.push(Mr.registerKeybindingRule({...r,id:s.id,when:s.precondition?Y.and(s.precondition,r.when):r.when}));return{dispose(){Yt(e)}}}var Prt,zDe,o6,Te,Yr,W1,Lo,vf,Es,vr,an=k(()=>{Gr();bn();Ie();j();du();Gi();it();Fe();K_();Prt=function(n,e,t,i){var o=arguments.length,r=o<3?e:i===null?i=Object.getOwnPropertyDescriptor(e,t):i,s;if(typeof Reflect=="object"&&typeof Reflect.decorate=="function")r=Reflect.decorate(n,e,t,i);else for(var a=n.length-1;a>=0;a--)(s=n[a])&&(r=(o<3?s(r):o>3?s(e,t,r):s(e,t))||r);return o>3&&r&&Object.defineProperty(e,t,r),r},zDe=function(n,e){return function(t,i){e(t,i,n)}};Te=class n{static{this._instances=new Map}static{this.CommandPalette=new n("CommandPalette")}static{this.DebugBreakpointsContext=new n("DebugBreakpointsContext")}static{this.DebugCallStackContext=new n("DebugCallStackContext")}static{this.DebugConsoleContext=new n("DebugConsoleContext")}static{this.DebugVariablesContext=new n("DebugVariablesContext")}static{this.NotebookVariablesContext=new n("NotebookVariablesContext")}static{this.DebugHoverContext=new n("DebugHoverContext")}static{this.DebugWatchContext=new n("DebugWatchContext")}static{this.DebugToolBar=new n("DebugToolBar")}static{this.DebugToolBarStop=new n("DebugToolBarStop")}static{this.DebugCallStackToolbar=new n("DebugCallStackToolbar")}static{this.DebugCreateConfiguration=new n("DebugCreateConfiguration")}static{this.EditorContext=new n("EditorContext")}static{this.SimpleEditorContext=new n("SimpleEditorContext")}static{this.EditorContent=new n("EditorContent")}static{this.EditorLineNumberContext=new n("EditorLineNumberContext")}static{this.EditorContextCopy=new n("EditorContextCopy")}static{this.EditorContextPeek=new n("EditorContextPeek")}static{this.EditorContextShare=new n("EditorContextShare")}static{this.EditorTitle=new n("EditorTitle")}static{this.EditorTitleRun=new n("EditorTitleRun")}static{this.EditorTitleContext=new n("EditorTitleContext")}static{this.EditorTitleContextShare=new n("EditorTitleContextShare")}static{this.EmptyEditorGroup=new n("EmptyEditorGroup")}static{this.EmptyEditorGroupContext=new n("EmptyEditorGroupContext")}static{this.EditorTabsBarContext=new n("EditorTabsBarContext")}static{this.EditorTabsBarShowTabsSubmenu=new n("EditorTabsBarShowTabsSubmenu")}static{this.EditorTabsBarShowTabsZenModeSubmenu=new n("EditorTabsBarShowTabsZenModeSubmenu")}static{this.EditorActionsPositionSubmenu=new n("EditorActionsPositionSubmenu")}static{this.ExplorerContext=new n("ExplorerContext")}static{this.ExplorerContextShare=new n("ExplorerContextShare")}static{this.ExtensionContext=new n("ExtensionContext")}static{this.GlobalActivity=new n("GlobalActivity")}static{this.CommandCenter=new n("CommandCenter")}static{this.CommandCenterCenter=new n("CommandCenterCenter")}static{this.LayoutControlMenuSubmenu=new n("LayoutControlMenuSubmenu")}static{this.LayoutControlMenu=new n("LayoutControlMenu")}static{this.MenubarMainMenu=new n("MenubarMainMenu")}static{this.MenubarAppearanceMenu=new n("MenubarAppearanceMenu")}static{this.MenubarDebugMenu=new n("MenubarDebugMenu")}static{this.MenubarEditMenu=new n("MenubarEditMenu")}static{this.MenubarCopy=new n("MenubarCopy")}static{this.MenubarFileMenu=new n("MenubarFileMenu")}static{this.MenubarGoMenu=new n("MenubarGoMenu")}static{this.MenubarHelpMenu=new n("MenubarHelpMenu")}static{this.MenubarLayoutMenu=new n("MenubarLayoutMenu")}static{this.MenubarNewBreakpointMenu=new n("MenubarNewBreakpointMenu")}static{this.PanelAlignmentMenu=new n("PanelAlignmentMenu")}static{this.PanelPositionMenu=new n("PanelPositionMenu")}static{this.ActivityBarPositionMenu=new n("ActivityBarPositionMenu")}static{this.MenubarPreferencesMenu=new n("MenubarPreferencesMenu")}static{this.MenubarRecentMenu=new n("MenubarRecentMenu")}static{this.MenubarSelectionMenu=new n("MenubarSelectionMenu")}static{this.MenubarShare=new n("MenubarShare")}static{this.MenubarSwitchEditorMenu=new n("MenubarSwitchEditorMenu")}static{this.MenubarSwitchGroupMenu=new n("MenubarSwitchGroupMenu")}static{this.MenubarTerminalMenu=new n("MenubarTerminalMenu")}static{this.MenubarViewMenu=new n("MenubarViewMenu")}static{this.MenubarHomeMenu=new n("MenubarHomeMenu")}static{this.OpenEditorsContext=new n("OpenEditorsContext")}static{this.OpenEditorsContextShare=new n("OpenEditorsContextShare")}static{this.ProblemsPanelContext=new n("ProblemsPanelContext")}static{this.SCMInputBox=new n("SCMInputBox")}static{this.SCMChangesSeparator=new n("SCMChangesSeparator")}static{this.SCMChangesContext=new n("SCMChangesContext")}static{this.SCMIncomingChanges=new n("SCMIncomingChanges")}static{this.SCMIncomingChangesContext=new n("SCMIncomingChangesContext")}static{this.SCMIncomingChangesSetting=new n("SCMIncomingChangesSetting")}static{this.SCMOutgoingChanges=new n("SCMOutgoingChanges")}static{this.SCMOutgoingChangesContext=new n("SCMOutgoingChangesContext")}static{this.SCMOutgoingChangesSetting=new n("SCMOutgoingChangesSetting")}static{this.SCMIncomingChangesAllChangesContext=new n("SCMIncomingChangesAllChangesContext")}static{this.SCMIncomingChangesHistoryItemContext=new n("SCMIncomingChangesHistoryItemContext")}static{this.SCMOutgoingChangesAllChangesContext=new n("SCMOutgoingChangesAllChangesContext")}static{this.SCMOutgoingChangesHistoryItemContext=new n("SCMOutgoingChangesHistoryItemContext")}static{this.SCMChangeContext=new n("SCMChangeContext")}static{this.SCMResourceContext=new n("SCMResourceContext")}static{this.SCMResourceContextShare=new n("SCMResourceContextShare")}static{this.SCMResourceFolderContext=new n("SCMResourceFolderContext")}static{this.SCMResourceGroupContext=new n("SCMResourceGroupContext")}static{this.SCMSourceControl=new n("SCMSourceControl")}static{this.SCMSourceControlInline=new n("SCMSourceControlInline")}static{this.SCMSourceControlTitle=new n("SCMSourceControlTitle")}static{this.SCMHistoryTitle=new n("SCMHistoryTitle")}static{this.SCMTitle=new n("SCMTitle")}static{this.SearchContext=new n("SearchContext")}static{this.SearchActionMenu=new n("SearchActionContext")}static{this.StatusBarWindowIndicatorMenu=new n("StatusBarWindowIndicatorMenu")}static{this.StatusBarRemoteIndicatorMenu=new n("StatusBarRemoteIndicatorMenu")}static{this.StickyScrollContext=new n("StickyScrollContext")}static{this.TestItem=new n("TestItem")}static{this.TestItemGutter=new n("TestItemGutter")}static{this.TestProfilesContext=new n("TestProfilesContext")}static{this.TestMessageContext=new n("TestMessageContext")}static{this.TestMessageContent=new n("TestMessageContent")}static{this.TestPeekElement=new n("TestPeekElement")}static{this.TestPeekTitle=new n("TestPeekTitle")}static{this.TestCallStack=new n("TestCallStack")}static{this.TouchBarContext=new n("TouchBarContext")}static{this.TitleBarContext=new n("TitleBarContext")}static{this.TitleBarTitleContext=new n("TitleBarTitleContext")}static{this.TunnelContext=new n("TunnelContext")}static{this.TunnelPrivacy=new n("TunnelPrivacy")}static{this.TunnelProtocol=new n("TunnelProtocol")}static{this.TunnelPortInline=new n("TunnelInline")}static{this.TunnelTitle=new n("TunnelTitle")}static{this.TunnelLocalAddressInline=new n("TunnelLocalAddressInline")}static{this.TunnelOriginInline=new n("TunnelOriginInline")}static{this.ViewItemContext=new n("ViewItemContext")}static{this.ViewContainerTitle=new n("ViewContainerTitle")}static{this.ViewContainerTitleContext=new n("ViewContainerTitleContext")}static{this.ViewTitle=new n("ViewTitle")}static{this.ViewTitleContext=new n("ViewTitleContext")}static{this.CommentEditorActions=new n("CommentEditorActions")}static{this.CommentThreadTitle=new n("CommentThreadTitle")}static{this.CommentThreadActions=new n("CommentThreadActions")}static{this.CommentThreadAdditionalActions=new n("CommentThreadAdditionalActions")}static{this.CommentThreadTitleContext=new n("CommentThreadTitleContext")}static{this.CommentThreadCommentContext=new n("CommentThreadCommentContext")}static{this.CommentTitle=new n("CommentTitle")}static{this.CommentActions=new n("CommentActions")}static{this.CommentsViewThreadActions=new n("CommentsViewThreadActions")}static{this.InteractiveToolbar=new n("InteractiveToolbar")}static{this.InteractiveCellTitle=new n("InteractiveCellTitle")}static{this.InteractiveCellDelete=new n("InteractiveCellDelete")}static{this.InteractiveCellExecute=new n("InteractiveCellExecute")}static{this.InteractiveInputExecute=new n("InteractiveInputExecute")}static{this.InteractiveInputConfig=new n("InteractiveInputConfig")}static{this.ReplInputExecute=new n("ReplInputExecute")}static{this.IssueReporter=new n("IssueReporter")}static{this.NotebookToolbar=new n("NotebookToolbar")}static{this.NotebookStickyScrollContext=new n("NotebookStickyScrollContext")}static{this.NotebookCellTitle=new n("NotebookCellTitle")}static{this.NotebookCellDelete=new n("NotebookCellDelete")}static{this.NotebookCellInsert=new n("NotebookCellInsert")}static{this.NotebookCellBetween=new n("NotebookCellBetween")}static{this.NotebookCellListTop=new n("NotebookCellTop")}static{this.NotebookCellExecute=new n("NotebookCellExecute")}static{this.NotebookCellExecuteGoTo=new n("NotebookCellExecuteGoTo")}static{this.NotebookCellExecutePrimary=new n("NotebookCellExecutePrimary")}static{this.NotebookDiffCellInputTitle=new n("NotebookDiffCellInputTitle")}static{this.NotebookDiffCellMetadataTitle=new n("NotebookDiffCellMetadataTitle")}static{this.NotebookDiffCellOutputsTitle=new n("NotebookDiffCellOutputsTitle")}static{this.NotebookOutputToolbar=new n("NotebookOutputToolbar")}static{this.NotebookOutlineFilter=new n("NotebookOutlineFilter")}static{this.NotebookOutlineActionMenu=new n("NotebookOutlineActionMenu")}static{this.NotebookEditorLayoutConfigure=new n("NotebookEditorLayoutConfigure")}static{this.NotebookKernelSource=new n("NotebookKernelSource")}static{this.BulkEditTitle=new n("BulkEditTitle")}static{this.BulkEditContext=new n("BulkEditContext")}static{this.TimelineItemContext=new n("TimelineItemContext")}static{this.TimelineTitle=new n("TimelineTitle")}static{this.TimelineTitleContext=new n("TimelineTitleContext")}static{this.TimelineFilterSubMenu=new n("TimelineFilterSubMenu")}static{this.AccountsContext=new n("AccountsContext")}static{this.SidebarTitle=new n("SidebarTitle")}static{this.PanelTitle=new n("PanelTitle")}static{this.AuxiliaryBarTitle=new n("AuxiliaryBarTitle")}static{this.AuxiliaryBarHeader=new n("AuxiliaryBarHeader")}static{this.TerminalInstanceContext=new n("TerminalInstanceContext")}static{this.TerminalEditorInstanceContext=new n("TerminalEditorInstanceContext")}static{this.TerminalNewDropdownContext=new n("TerminalNewDropdownContext")}static{this.TerminalTabContext=new n("TerminalTabContext")}static{this.TerminalTabEmptyAreaContext=new n("TerminalTabEmptyAreaContext")}static{this.TerminalStickyScrollContext=new n("TerminalStickyScrollContext")}static{this.WebviewContext=new n("WebviewContext")}static{this.InlineCompletionsActions=new n("InlineCompletionsActions")}static{this.InlineEditsActions=new n("InlineEditsActions")}static{this.InlineEditActions=new n("InlineEditActions")}static{this.NewFile=new n("NewFile")}static{this.MergeInput1Toolbar=new n("MergeToolbar1Toolbar")}static{this.MergeInput2Toolbar=new n("MergeToolbar2Toolbar")}static{this.MergeBaseToolbar=new n("MergeBaseToolbar")}static{this.MergeInputResultToolbar=new n("MergeToolbarResultToolbar")}static{this.InlineSuggestionToolbar=new n("InlineSuggestionToolbar")}static{this.InlineEditToolbar=new n("InlineEditToolbar")}static{this.ChatContext=new n("ChatContext")}static{this.ChatCodeBlock=new n("ChatCodeblock")}static{this.ChatCompareBlock=new n("ChatCompareBlock")}static{this.ChatMessageTitle=new n("ChatMessageTitle")}static{this.ChatExecute=new n("ChatExecute")}static{this.ChatExecuteSecondary=new n("ChatExecuteSecondary")}static{this.ChatInputSide=new n("ChatInputSide")}static{this.AccessibleView=new n("AccessibleView")}static{this.MultiDiffEditorFileToolbar=new n("MultiDiffEditorFileToolbar")}static{this.DiffEditorHunkToolbar=new n("DiffEditorHunkToolbar")}static{this.DiffEditorSelectionToolbar=new n("DiffEditorSelectionToolbar")}constructor(e){if(n._instances.has(e))throw new TypeError(`MenuId with identifier '${e}' already exists. Use MenuId.for(ident) or a unique identifier`);n._instances.set(e,this),this.id=e}},Yr=We("menuService"),W1=class n{static{this._all=new Map}static for(e){let t=this._all.get(e);return t||(t=new n(e),this._all.set(e,t)),t}static merge(e){let t=new Set;for(let i of e)i instanceof n&&t.add(i.id);return t}constructor(e){this.id=e,this.has=t=>t===e}},Lo=new class{constructor(){this._commands=new Map,this._menuItems=new Map,this._onDidChangeMenu=new K3({merge:W1.merge}),this.onDidChangeMenu=this._onDidChangeMenu.event}addCommand(n){return this._commands.set(n.id,n),this._onDidChangeMenu.fire(W1.for(Te.CommandPalette)),ge(()=>{this._commands.delete(n.id)&&this._onDidChangeMenu.fire(W1.for(Te.CommandPalette))})}getCommand(n){return this._commands.get(n)}getCommands(){let n=new Map;return this._commands.forEach((e,t)=>n.set(t,e)),n}appendMenuItem(n,e){let t=this._menuItems.get(n);t||(t=new go,this._menuItems.set(n,t));let i=t.push(e);return this._onDidChangeMenu.fire(W1.for(n)),ge(()=>{i(),this._onDidChangeMenu.fire(W1.for(n))})}appendMenuItems(n){let e=new H;for(let{id:t,item:i}of n)e.add(this.appendMenuItem(t,i));return e}getMenuItems(n){let e;return this._menuItems.has(n)?e=[...this._menuItems.get(n)]:e=[],n===Te.CommandPalette&&this._appendImplicitItems(e),e}_appendImplicitItems(n){let e=new Set;for(let t of n)Lx(t)&&(e.add(t.command.id),t.alt&&e.add(t.alt.id));this._commands.forEach((t,i)=>{e.has(i)||n.push({command:t})})}},vf=class extends bh{constructor(e,t,i){super(`submenuitem.${e.submenu.id}`,typeof e.title=="string"?e.title:e.title.value,i,"submenu"),this.item=e,this.hideActions=t}},Es=o6=class{static label(e,t){return t?.renderShortTitle&&e.shortTitle?typeof e.shortTitle=="string"?e.shortTitle:e.shortTitle.value:typeof e.title=="string"?e.title:e.title.value}constructor(e,t,i,o,r,s,a){this.hideActions=o,this.menuKeybinding=r,this._commandService=a,this.id=e.id,this.label=o6.label(e,i),this.tooltip=(typeof e.tooltip=="string"?e.tooltip:e.tooltip?.value)??"",this.enabled=!e.precondition||s.contextMatchesRules(e.precondition),this.checked=void 0;let l;if(e.toggled){let c=e.toggled.condition?e.toggled:{condition:e.toggled};this.checked=s.contextMatchesRules(c.condition),this.checked&&c.tooltip&&(this.tooltip=typeof c.tooltip=="string"?c.tooltip:c.tooltip.value),this.checked&&Oe.isThemeIcon(c.icon)&&(l=c.icon),this.checked&&c.title&&(this.label=typeof c.title=="string"?c.title:c.title.value)}l||(l=Oe.isThemeIcon(e.icon)?e.icon:void 0),this.item=e,this.alt=t?new o6(t,void 0,i,o,void 0,s,a):void 0,this._options=i,this.class=l&&Oe.asClassName(l)}run(...e){let t=[];return this._options?.arg&&(t=[...t,this._options.arg]),this._options?.shouldForwardArgs&&(t=[...t,...e]),this._commandService.executeCommand(this.id,...t)}};Es=o6=Prt([zDe(5,Le),zDe(6,$t)],Es);vr=class{constructor(e){this.desc=e}}});var Fn,sc=k(()=>{Fe();Fn=We("telemetryService")});function Ort(n){switch(n){case Ys.Trace:return"trace";case Ys.Debug:return"debug";case Ys.Info:return"info";case Ys.Warning:return"warn";case Ys.Error:return"error";case Ys.Off:return"off"}}var Bn,Ys,UDe,r6,s6,a6,V8t,ac=k(()=>{Ie();j();it();Fe();Bn=We("logService");(function(n){n[n.Off=0]="Off",n[n.Trace=1]="Trace",n[n.Debug=2]="Debug",n[n.Info=3]="Info",n[n.Warning=4]="Warning",n[n.Error=5]="Error"})(Ys||(Ys={}));UDe=Ys.Info,r6=class extends D{constructor(){super(...arguments),this.level=UDe,this._onDidChangeLogLevel=this._register(new A),this.onDidChangeLogLevel=this._onDidChangeLogLevel.event}setLevel(e){this.level!==e&&(this.level=e,this._onDidChangeLogLevel.fire(this.level))}getLevel(){return this.level}checkLogLevel(e){return this.level!==Ys.Off&&this.level<=e}},s6=class extends r6{constructor(e=UDe,t=!0){super(),this.useColors=t,this.setLevel(e)}trace(e,...t){this.checkLogLevel(Ys.Trace)&&(this.useColors?console.log("%cTRACE","color: #888",e,...t):console.log(e,...t))}debug(e,...t){this.checkLogLevel(Ys.Debug)&&(this.useColors?console.log("%cDEBUG","background: #eee; color: #888",e,...t):console.log(e,...t))}info(e,...t){this.checkLogLevel(Ys.Info)&&(this.useColors?console.log("%c INFO","color: #33f",e,...t):console.log(e,...t))}warn(e,...t){this.checkLogLevel(Ys.Warning)&&(this.useColors?console.log("%c WARN","color: #993",e,...t):console.log(e,...t))}error(e,...t){this.checkLogLevel(Ys.Error)&&(this.useColors?console.log("%c ERR","color: #f33",e,...t):console.error(e,...t))}},a6=class extends r6{constructor(e){super(),this.loggers=e,e.length&&this.setLevel(e[0].getLevel())}setLevel(e){for(let t of this.loggers)t.setLevel(e);super.setLevel(e)}trace(e,...t){for(let i of this.loggers)i.trace(e,...t)}debug(e,...t){for(let i of this.loggers)i.debug(e,...t)}info(e,...t){for(let i of this.loggers)i.info(e,...t)}warn(e,...t){for(let i of this.loggers)i.warn(e,...t)}error(e,...t){for(let i of this.loggers)i.error(e,...t)}dispose(){for(let e of this.loggers)e.dispose();super.dispose()}};V8t=new me("logLevel",Ort(Ys.Info))});function Zs(n,e){wt.registerCommand(n,function(t,...i){let o=t.get(he),[r,s]=i;At(Ee.isUri(r)),At(P.isIPosition(s));let a=t.get(di).getModel(r);if(a){let l=P.lift(s);return o.invokeFunction(e,a,l,...i.slice(2))}return t.get(Uo).createModelReference(r).then(l=>new Promise((c,d)=>{try{let u=o.invokeFunction(e,l.object.textEditorModel,P.lift(s),i.slice(2));c(u)}catch(u){d(u)}}).finally(()=>{l.dispose()}))})}function ye(n){return vh.INSTANCE.registerEditorCommand(n),n}function ee(n){let e=new n;return vh.INSTANCE.registerEditorAction(e),e}function woe(n){return vh.INSTANCE.registerEditorAction(n),n}function $De(n){vh.INSTANCE.registerEditorAction(n)}function ze(n,e,t){vh.INSTANCE.registerEditorContribution(n,e,t)}function vA(n){return n.register(),n}var H1,G_,l6,hn,fe,bA,lc,Nm,Frt,vh,yoe,Coe,jDe,mt=k(()=>{pe();Ai();Po();qe();va();vu();an();Gi();it();Fe();K_();br();sc();yi();ac();ke();H1=class{constructor(e){this.id=e.id,this.precondition=e.precondition,this._kbOpts=e.kbOpts,this._menuOpts=e.menuOpts,this.metadata=e.metadata}register(){if(Array.isArray(this._menuOpts)?this._menuOpts.forEach(this._registerMenuItem,this):this._menuOpts&&this._registerMenuItem(this._menuOpts),this._kbOpts){let e=Array.isArray(this._kbOpts)?this._kbOpts:[this._kbOpts];for(let t of e){let i=t.kbExpr;this.precondition&&(i?i=Y.and(i,this.precondition):i=this.precondition);let o={id:this.id,weight:t.weight,args:t.args,when:i,primary:t.primary,secondary:t.secondary,win:t.win,linux:t.linux,mac:t.mac};Mr.registerKeybindingRule(o)}}wt.registerCommand({id:this.id,handler:(e,t)=>this.runCommand(e,t),metadata:this.metadata})}_registerMenuItem(e){Lo.appendMenuItem(e.menuId,{group:e.group,command:{id:this.id,title:e.title,icon:e.icon,precondition:this.precondition},when:e.when,order:e.order})}},G_=class extends H1{constructor(){super(...arguments),this._implementations=[]}addImplementation(e,t,i,o){return this._implementations.push({priority:e,name:t,implementation:i,when:o}),this._implementations.sort((r,s)=>s.priority-r.priority),{dispose:()=>{for(let r=0;r{if(a.get(Le).contextMatchesRules(i??void 0))return o(a,s,t)})}runCommand(e,t){return n.runEditorCommand(e,t,this.precondition,(i,o,r)=>this.runEditorCommand(i,o,r))}},fe=class n extends hn{static convertOptions(e){let t;Array.isArray(e.menuOpts)?t=e.menuOpts:e.menuOpts?t=[e.menuOpts]:t=[];function i(o){return o.menuId||(o.menuId=Te.EditorContext),o.title||(o.title=e.label),o.when=Y.and(e.precondition,o.when),o}return Array.isArray(e.contextMenuOpts)?t.push(...e.contextMenuOpts.map(i)):e.contextMenuOpts&&t.push(i(e.contextMenuOpts)),e.menuOpts=t,e}constructor(e){super(n.convertOptions(e)),this.label=e.label,this.alias=e.alias}runEditorCommand(e,t,i){return this.reportTelemetry(e,t),this.run(e,t,i||{})}reportTelemetry(e,t){e.get(Fn).publicLog2("editorActionInvoked",{name:this.label,id:this.id})}},bA=class extends fe{constructor(){super(...arguments),this._implementations=[]}addImplementation(e,t){return this._implementations.push([e,t]),this._implementations.sort((i,o)=>o[0]-i[0]),{dispose:()=>{for(let i=0;i{let s=r.get(Le),a=r.get(Bn);if(!s.contextMatchesRules(this.desc.precondition??void 0)){a.debug("[EditorAction2] NOT running command because its precondition is FALSE",this.desc.id,this.desc.precondition?.serialize());return}return this.runEditorCommand(r,o,...t)})}};(function(n){function e(s){return vh.INSTANCE.getEditorCommand(s)}n.getEditorCommand=e;function t(){return vh.INSTANCE.getEditorActions()}n.getEditorActions=t;function i(){return vh.INSTANCE.getEditorContributions()}n.getEditorContributions=i;function o(s){return vh.INSTANCE.getEditorContributions().filter(a=>s.indexOf(a.id)>=0)}n.getSomeEditorContributions=o;function r(){return vh.INSTANCE.getDiffEditorContributions()}n.getDiffEditorContributions=r})(Nm||(Nm={}));Frt={EditorCommonContributions:"editor.contributions"},vh=class n{static{this.INSTANCE=new n}constructor(){this.editorContributions=[],this.diffEditorContributions=[],this.editorActions=[],this.editorCommands=Object.create(null)}registerEditorContribution(e,t,i){this.editorContributions.push({id:e,ctor:t,instantiation:i})}getEditorContributions(){return this.editorContributions.slice(0)}getDiffEditorContributions(){return this.diffEditorContributions.slice(0)}registerEditorAction(e){e.register(),this.editorActions.push(e)}getEditorActions(){return this.editorActions}registerEditorCommand(e){e.register(),this.editorCommands[e.id]=e}getEditorCommand(e){return this.editorCommands[e]||null}};ei.add(Frt.EditorCommonContributions,vh.INSTANCE);yoe=vA(new G_({id:"undo",precondition:void 0,kbOpts:{weight:0,primary:2104},menuOpts:[{menuId:Te.MenubarEditMenu,group:"1_do",title:m({key:"miUndo",comment:["&& denotes a mnemonic"]},"&&Undo"),order:1},{menuId:Te.CommandPalette,group:"",title:m("undo","Undo"),order:1}]}));vA(new l6(yoe,{id:"default:undo",precondition:void 0}));Coe=vA(new G_({id:"redo",precondition:void 0,kbOpts:{weight:0,primary:2103,secondary:[3128],mac:{primary:3128}},menuOpts:[{menuId:Te.MenubarEditMenu,group:"1_do",title:m({key:"miRedo",comment:["&& denotes a mnemonic"]},"&&Redo"),order:2},{menuId:Te.CommandPalette,group:"",title:m("redo","Redo"),order:1}]}));vA(new l6(Coe,{id:"default:redo",precondition:void 0}));jDe=vA(new G_({id:"editor.action.selectAll",precondition:void 0,kbOpts:{weight:0,kbExpr:null,primary:2079},menuOpts:[{menuId:Te.MenubarSelectionMenu,group:"1_basic",title:m({key:"miSelectAll",comment:["&& denotes a mnemonic"]},"&&Select All"),order:1},{menuId:Te.CommandPalette,group:"",title:m("selectAll","Select All"),order:1}]}))});function xA(n){df&&(KDe||(KDe=!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(n.message))}function GDe(n){return n[0]==="o"&&n[1]==="n"&&uh(n.charCodeAt(2))}function YDe(n){return/^onDynamic/.test(n)&&uh(n.charCodeAt(9))}var qDe,Brt,KDe,Soe,c6,koe,Loe,Ioe,Eoe,d6,Toe=k(()=>{je();Ie();j();ds();Bt();Qe();qDe="default",Brt="$initialize",KDe=!1;Soe=class{constructor(e,t,i,o,r){this.vsWorker=e,this.req=t,this.channel=i,this.method=o,this.args=r,this.type=0}},c6=class{constructor(e,t,i,o){this.vsWorker=e,this.seq=t,this.res=i,this.err=o,this.type=1}},koe=class{constructor(e,t,i,o,r){this.vsWorker=e,this.req=t,this.channel=i,this.eventName=o,this.arg=r,this.type=2}},Loe=class{constructor(e,t,i){this.vsWorker=e,this.req=t,this.event=i,this.type=3}},Ioe=class{constructor(e,t){this.vsWorker=e,this.req=t,this.type=4}},Eoe=class{constructor(e){this._workerId=-1,this._handler=e,this._lastSentReq=0,this._pendingReplies=Object.create(null),this._pendingEmitters=new Map,this._pendingEvents=new Map}setWorkerId(e){this._workerId=e}sendMessage(e,t,i){let o=String(++this._lastSentReq);return new Promise((r,s)=>{this._pendingReplies[o]={resolve:r,reject:s},this._send(new Soe(this._workerId,o,e,t,i))})}listen(e,t,i){let o=null,r=new A({onWillAddFirstListener:()=>{o=String(++this._lastSentReq),this._pendingEmitters.set(o,r),this._send(new koe(this._workerId,o,e,t,i))},onDidRemoveLastListener:()=>{this._pendingEmitters.delete(o),this._send(new Ioe(this._workerId,o)),o=null}});return r.event}handleMessage(e){!e||!e.vsWorker||this._workerId!==-1&&e.vsWorker!==this._workerId||this._handleMessage(e)}createProxyToRemoteChannel(e,t){let i={get:(o,r)=>(typeof r=="string"&&!o[r]&&(YDe(r)?o[r]=s=>this.listen(e,r,s):GDe(r)?o[r]=this.listen(e,r,void 0):r.charCodeAt(0)===36&&(o[r]=async(...s)=>(await t?.(),this.sendMessage(e,r,s)))),o[r])};return new Proxy(Object.create(null),i)}_handleMessage(e){switch(e.type){case 1:return this._handleReplyMessage(e);case 0:return this._handleRequestMessage(e);case 2:return this._handleSubscribeEventMessage(e);case 3:return this._handleEventMessage(e);case 4:return this._handleUnsubscribeEventMessage(e)}}_handleReplyMessage(e){if(!this._pendingReplies[e.seq]){console.warn("Got reply to unknown seq");return}let t=this._pendingReplies[e.seq];if(delete this._pendingReplies[e.seq],e.err){let i=e.err;e.err.$isError&&(i=new Error,i.name=e.err.name,i.message=e.err.message,i.stack=e.err.stack),t.reject(i);return}t.resolve(e.res)}_handleRequestMessage(e){let t=e.req;this._handler.handleMessage(e.channel,e.method,e.args).then(o=>{this._send(new c6(this._workerId,t,o,void 0))},o=>{o.detail instanceof Error&&(o.detail=une(o.detail)),this._send(new c6(this._workerId,t,void 0,une(o)))})}_handleSubscribeEventMessage(e){let t=e.req,i=this._handler.handleEvent(e.channel,e.eventName,e.arg)(o=>{this._send(new Loe(this._workerId,t,o))});this._pendingEvents.set(t,i)}_handleEventMessage(e){if(!this._pendingEmitters.has(e.req)){console.warn("Got event for unknown req");return}this._pendingEmitters.get(e.req).fire(e.event)}_handleUnsubscribeEventMessage(e){if(!this._pendingEvents.has(e.req)){console.warn("Got unsubscribe for unknown req");return}this._pendingEvents.get(e.req).dispose(),this._pendingEvents.delete(e.req)}_send(e){let t=[];if(e.type===0)for(let i=0;i{this._protocol.handleMessage(r)},r=>{Be(r)})),this._protocol=new Eoe({sendMessage:(r,s)=>{this._worker.postMessage(r,s)},handleMessage:(r,s,a)=>this._handleMessage(r,s,a),handleEvent:(r,s,a)=>this._handleEvent(r,s,a)}),this._protocol.setWorkerId(this._worker.getId());let i=null,o=globalThis.require;typeof o<"u"&&typeof o.getConfig=="function"?i=o.getConfig():typeof globalThis.requirejs<"u"&&(i=globalThis.requirejs.s.contexts._.config),this._onModuleLoaded=this._protocol.sendMessage(qDe,Brt,[this._worker.getId(),JSON.parse(JSON.stringify(i)),t.amdModuleId]),this.proxy=this._protocol.createProxyToRemoteChannel(qDe,async()=>{await this._onModuleLoaded}),this._onModuleLoaded.catch(r=>{this._onError("Worker failed to load "+t.amdModuleId,r)})}_handleMessage(e,t,i){let o=this._localChannels.get(e);if(!o)return Promise.reject(new Error(`Missing channel ${e} on main thread`));if(typeof o[t]!="function")return Promise.reject(new Error(`Missing method ${t} on main thread channel ${e}`));try{return Promise.resolve(o[t].apply(o,i))}catch(r){return Promise.reject(r)}}_handleEvent(e,t,i){let o=this._localChannels.get(e);if(!o)throw new Error(`Missing channel ${e} on main thread`);if(YDe(t)){let r=o[t].call(o,i);if(typeof r!="function")throw new Error(`Missing dynamic event ${t} on main thread channel ${e}.`);return r}if(GDe(t)){let r=o[t];if(typeof r!="function")throw new Error(`Missing event ${t} on main thread channel ${e}.`);return r}throw new Error(`Malformed event name ${t}`)}setChannel(e,t){this._localChannels.set(e,t)}_onError(e,t){console.error(e),console.info(t)}}});function Tl(n,e){let t=globalThis.MonacoEnvironment;if(t?.createTrustedTypesPolicy)try{return t.createTrustedTypesPolicy(n,e)}catch(i){Be(i);return}try{return globalThis.trustedTypes?.createPolicy(n,e)}catch(i){Be(i);return}}var Rm=k(()=>{je()});function Wrt(n,e){let t=globalThis.MonacoEnvironment;if(t){if(typeof t.getWorker=="function")return t.getWorker("workerMain.js",e);if(typeof t.getWorkerUrl=="function"){let i=t.getWorkerUrl("workerMain.js",e);return new Worker(_L?_L.createScriptURL(i):i,{name:e,type:z1?"module":void 0})}}if(n){let i=Hrt(e,n.toString(!0)),o=new Worker(_L?_L.createScriptURL(i):i,{name:e,type:z1?"module":void 0});return z1?zrt(o):o}throw new Error("You must define a function MonacoEnvironment.getWorkerUrl or MonacoEnvironment.getWorker")}function Hrt(n,e,t){let i=/^((http:)|(https:)|(file:)|(vscode-file:))/.test(e);if(!(i&&e.substring(0,globalThis.origin.length)!==globalThis.origin)){let r=e.lastIndexOf("?"),s=e.lastIndexOf("#",r),a=r>0?new URLSearchParams(e.substring(r+1,~s?s:void 0)):new URLSearchParams;EB.addSearchParam(a,!0,!0),a.toString()?e=`${e}?${a.toString()}#${n}`:e=`${e}#${n}`}!z1&&!i&&(e=new URL(e,globalThis.origin).toString());let o=new Blob([ns([`/*${n}*/`,t?`globalThis.MonacoEnvironment = { baseUrl: '${t}' };`:void 0,`globalThis._VSCODE_NLS_MESSAGES = ${JSON.stringify(SR())};`,`globalThis._VSCODE_NLS_LANGUAGE = ${JSON.stringify(u1())};`,`globalThis._VSCODE_FILE_ROOT = '${globalThis._VSCODE_FILE_ROOT}';`,"const ttPolicy = globalThis.trustedTypes?.createPolicy('defaultWorkerFactory', { createScriptURL: value => value });","globalThis.workerttPolicy = ttPolicy;",z1?`await import(ttPolicy?.createScriptURL('${e}') ?? '${e}');`:`importScripts(ttPolicy?.createScriptURL('${e}') ?? '${e}');`,z1?"globalThis.postMessage({ type: 'vscode-worker-ready' });":void 0,`/*${n}*/`]).join("")],{type:"application/javascript"});return URL.createObjectURL(o)}function zrt(n){return new Promise((e,t)=>{n.onmessage=function(i){i.data.type==="vscode-worker-ready"&&(n.onmessage=null,e(n))},n.onerror=t})}function Vrt(n){return typeof n.then=="function"}function ZDe(n,e){let t=typeof n=="string"?new Noe(n,e):n;return new d6(new Roe,t)}var z1,_L,Doe,Noe,Roe,XDe=k(()=>{Rm();je();ds();Toe();j();at();pe();z1=!0;typeof self=="object"&&self.constructor&&self.constructor.name==="DedicatedWorkerGlobalScope"&&globalThis.workerttPolicy!==void 0?_L=globalThis.workerttPolicy:_L=Tl("defaultWorkerFactory",{createScriptURL:n=>n});Doe=class extends D{constructor(e,t,i,o,r,s){super(),this.id=i,this.label=o;let a=Wrt(e,o);Vrt(a)?this.worker=a:this.worker=Promise.resolve(a),this.postMessage(t,[]),this.worker.then(l=>{l.onmessage=function(c){r(c.data)},l.onmessageerror=s,typeof l.addEventListener=="function"&&l.addEventListener("error",s)}),this._register(ge(()=>{this.worker?.then(l=>{l.onmessage=null,l.onmessageerror=null,l.removeEventListener("error",s),l.terminate()}),this.worker=null}))}getId(){return this.id}postMessage(e,t){this.worker?.then(i=>{try{i.postMessage(e,t)}catch(o){Be(o),Be(new Error(`FAILED to post message to '${this.label}'-worker`,{cause:o}))}})}},Noe=class{constructor(e,t){this.amdModuleId=e,this.label=t,this.esmModuleLocation=z1?U_.asBrowserUri(`${e}.esm.js`):void 0}},Roe=class n{static{this.LAST_WORKER_ID=0}constructor(){this._webWorkerFailedBeforeError=!1}create(e,t,i){let o=++n.LAST_WORKER_ID;if(this._webWorkerFailedBeforeError)throw this._webWorkerFailedBeforeError;return new Doe(e.esmModuleLocation,e.amdModuleId,o,e.label||"anonymous"+o,t,r=>{xA(r),this._webWorkerFailedBeforeError=r,i(r)})}}});function wA(n,e,t){n.has(e)?n.get(e).push(t):n.set(e,[t])}var Io,bL,u6,Ix=k(()=>{(function(n){n[n.None=0]="None",n[n.Indent=1]="Indent",n[n.IndentOutdent=2]="IndentOutdent",n[n.Outdent=3]="Outdent"})(Io||(Io={}));bL=class{constructor(e){if(this._neutralCharacter=null,this._neutralCharacterSearched=!1,this.open=e.open,this.close=e.close,this._inString=!0,this._inComment=!0,this._inRegEx=!0,Array.isArray(e.notIn))for(let t=0,i=e.notIn.length;t{Ix();h6=class n{static{this.DEFAULT_AUTOCLOSE_BEFORE_LANGUAGE_DEFINED_QUOTES=`;:.,=}])> `}static{this.DEFAULT_AUTOCLOSE_BEFORE_LANGUAGE_DEFINED_BRACKETS=`'"\`;:.,=}])> `}constructor(e){if(e.autoClosingPairs?this._autoClosingPairs=e.autoClosingPairs.map(t=>new bL(t)):e.brackets?this._autoClosingPairs=e.brackets.map(t=>new bL({open:t[0],close:t[1]})):this._autoClosingPairs=[],e.__electricCharacterSupport&&e.__electricCharacterSupport.docComment){let t=e.__electricCharacterSupport.docComment;this._autoClosingPairs.push(new bL({open:t.open,close:t.close||""}))}this._autoCloseBeforeForQuotes=typeof e.autoCloseBefore=="string"?e.autoCloseBefore:n.DEFAULT_AUTOCLOSE_BEFORE_LANGUAGE_DEFINED_QUOTES,this._autoCloseBeforeForBrackets=typeof e.autoCloseBefore=="string"?e.autoCloseBefore:n.DEFAULT_AUTOCLOSE_BEFORE_LANGUAGE_DEFINED_BRACKETS,this._surroundingPairs=e.surroundingPairs||this._autoClosingPairs}getAutoClosingPairs(){return this._autoClosingPairs}getAutoCloseBeforeSet(e){return e?this._autoCloseBeforeForQuotes:this._autoCloseBeforeForBrackets}getSurroundingPairs(){return this._surroundingPairs}}});function Am(n,e){let t=n.getCount(),i=n.findTokenIndexAtOffset(e),o=n.getLanguageId(i),r=i;for(;r+10&&n.getLanguageId(s-1)===o;)s--;return new Aoe(n,o,s,r+1,n.getStartOffset(s),n.getEndOffset(r))}function xf(n){return(n&3)!==0}var Aoe,vL=k(()=>{Aoe=class{constructor(e,t,i,o,r,s){this._scopedLineTokensBrand=void 0,this._actual=e,this.languageId=t,this._firstTokenIndex=i,this._lastTokenIndex=o,this.firstCharOffset=r,this._lastCharOffset=s,this.languageIdCodec=e.languageIdCodec}getLineContent(){return this._actual.getLineContent().substring(this.firstCharOffset,this._lastCharOffset)}getLineLength(){return this._lastCharOffset-this.firstCharOffset}getActualLineContentBefore(e){return this._actual.getLineContent().substring(0,this.firstCharOffset+e)}getTokenCount(){return this._lastTokenIndex-this._firstTokenIndex}findTokenIndexAtOffset(e){return this._actual.findTokenIndexAtOffset(e+this.firstCharOffset)-this._firstTokenIndex}getStandardTokenType(e){return this._actual.getStandardTokenType(e+this._firstTokenIndex)}toIViewLineTokens(){return this._actual.sliceAndInflate(this.firstCharOffset,this._lastCharOffset,0)}}});function eNe(n,e){return n[e+0]<<0>>>0|n[e+1]<<8>>>0}function tNe(n,e,t){n[t+0]=e&255,e=e>>>8,n[t+1]=e&255}function xh(n,e){return n[e]*2**24+n[e+1]*2**16+n[e+2]*2**8+n[e+3]}function wh(n,e,t){n[t+3]=e,e=e>>>8,n[t+2]=e,e=e>>>8,n[t+1]=e,e=e>>>8,n[t]=e}function Poe(n,e){return n[e]}function Ooe(n,e,t){n[t]=e}var JDe,EBt,Moe,xL,wL=k(()=>{cp();JDe=typeof Buffer<"u",EBt=new or(()=>new Uint8Array(256)),xL=class n{static wrap(e){return JDe&&!Buffer.isBuffer(e)&&(e=Buffer.from(e.buffer,e.byteOffset,e.byteLength)),new n(e)}constructor(e){this.buffer=e,this.byteLength=this.buffer.byteLength}toString(){return JDe?this.buffer.toString():(Moe||(Moe=new TextDecoder),Moe.decode(this.buffer))}}});function iNe(){return Boe||(Boe=new TextDecoder("UTF-16LE")),Boe}function Urt(){return Woe||(Woe=new TextDecoder("UTF-16BE")),Woe}function zoe(){return Hoe||(Hoe=B3()?iNe():Urt()),Hoe}function nNe(n,e,t){let i=new Uint16Array(n.buffer,e,t);return t>0&&(i[0]===65279||i[0]===65534)?$rt(n,e,t):iNe().decode(i)}function $rt(n,e,t){let i=[],o=0;for(let r=0;r{Qe();Bt();wL();xu=class{constructor(e){this._capacity=e|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"";let e=new Uint16Array(this._buffer.buffer,0,this._bufferLength);return zoe().decode(e)}_flushBuffer(){let e=this._buildBuffer();this._bufferLength=0,this._completedStrings===null?this._completedStrings=[e]:this._completedStrings[this._completedStrings.length]=e}appendCharCode(e){let t=this._capacity-this._bufferLength;t<=1&&(t===0||to(e))&&this._flushBuffer(),this._buffer[this._bufferLength++]=e}appendASCIICharCode(e){this._bufferLength===this._capacity&&this._flushBuffer(),this._buffer[this._bufferLength++]=e}appendString(e){let t=e.length;if(this._bufferLength+t>=this._capacity){this._flushBuffer(),this._completedStrings[this._completedStrings.length]=e;return}for(let i=0;i[s[0].toLowerCase(),s[1].toLowerCase()]);let t=[];for(let s=0;s{let[l,c]=s,[d,u]=a;return l===d||l===u||c===d||c===u},o=(s,a)=>{let l=Math.min(s,a),c=Math.max(s,a);for(let d=0;d0&&r.push({open:a,close:l})}return r}function oNe(n,e,t,i){for(let o=0,r=e.length;o=0&&i.push(a);for(let a of s.close)a.indexOf(n)>=0&&i.push(a)}}function rNe(n,e){return n.length-e.length}function p6(n){if(n.length<=1)return n;let e=[],t=new Set;for(let i of n)t.has(i)||(e.push(i),t.add(i));return e}function Krt(n,e,t,i){let o=[];o=o.concat(n),o=o.concat(e);for(let r=0,s=o.length;r{Qe();Y_();we();Voe=class n{constructor(e,t,i,o,r,s){this._richEditBracketBrand=void 0,this.languageId=e,this.index=t,this.open=i,this.close=o,this.forwardRegex=r,this.reversedRegex=s,this._openSet=n._toSet(this.open),this._closeSet=n._toSet(this.close)}isOpen(e){return this._openSet.has(e)}isClose(e){return this._closeSet.has(e)}static _toSet(e){let t=new Set;for(let i of e)t.add(i);return t}};f6=class{constructor(e,t){this._richEditBracketsBrand=void 0;let i=qrt(t);this.brackets=i.map((o,r)=>new Voe(e,r,o.open,o.close,Krt(o.open,o.close,i,r),Grt(o.open,o.close,i,r))),this.forwardRegex=Yrt(this.brackets),this.reversedRegex=Zrt(this.brackets),this.textIsBracket={},this.textIsOpenBracket={},this.maxBracketLength=0;for(let o of this.brackets){for(let r of o.open)this.textIsBracket[r]=o,this.textIsOpenBracket[r]=!0,this.maxBracketLength=Math.max(this.maxBracketLength,r.length);for(let r of o.close)this.textIsBracket[r]=o,this.textIsOpenBracket[r]=!1,this.maxBracketLength=Math.max(this.maxBracketLength,r.length)}}};Uoe=function(){function n(i){let o=new Uint16Array(i.length),r=0;for(let s=i.length-1;s>=0;s--)o[r++]=i.charCodeAt(s);return zoe().decode(o)}let e=null,t=null;return function(o){return e!==o&&(e=o,t=n(e)),t}}(),zc=class{static _findPrevBracketInText(e,t,i,o){let r=i.match(e);if(!r)return null;let s=i.length-(r.index||0),a=r[0].length,l=o+s;return new S(t,l-a+1,t,l+1)}static findPrevBracketInRange(e,t,i,o,r){let a=Uoe(i).substring(i.length-r,i.length-o);return this._findPrevBracketInText(e,t,a,o)}static findNextBracketInText(e,t,i,o){let r=i.match(e);if(!r)return null;let s=r.index||0,a=r[0].length;if(a===0)return null;let l=o+s;return new S(t,l+1,t,l+1+a)}static findNextBracketInRange(e,t,i,o,r){let s=i.substring(o,r);return this.findNextBracketInText(e,t,s,o)}}});var m6,sNe=k(()=>{at();vL();yA();m6=class{constructor(e){this._richEditBrackets=e}getElectricCharacters(){let e=[];if(this._richEditBrackets)for(let t of this._richEditBrackets.brackets)for(let i of t.close){let o=i.charAt(i.length-1);e.push(o)}return Ac(e)}onElectricCharacter(e,t,i){if(!this._richEditBrackets||this._richEditBrackets.brackets.length===0)return null;let o=t.findTokenIndexAtOffset(i-1);if(xf(t.getStandardTokenType(o)))return null;let r=this._richEditBrackets.reversedRegex,s=t.getLineContent().substring(0,i-1)+e,a=zc.findPrevBracketInRange(r,1,s,0,s.length);if(!a)return null;let l=s.substring(a.startColumn-1,a.endColumn-1).toLowerCase();if(this._richEditBrackets.textIsOpenBracket[l])return null;let d=t.getActualLineContentBefore(a.startColumn-1);return/^\s*$/.test(d)?{matchOpenBracket:l}:null}}});function g6(n){return n.global&&(n.lastIndex=0),!0}var _6,aNe=k(()=>{_6=class{constructor(e){this._indentationRules=e}shouldIncrease(e){return!!(this._indentationRules&&this._indentationRules.increaseIndentPattern&&g6(this._indentationRules.increaseIndentPattern)&&this._indentationRules.increaseIndentPattern.test(e))}shouldDecrease(e){return!!(this._indentationRules&&this._indentationRules.decreaseIndentPattern&&g6(this._indentationRules.decreaseIndentPattern)&&this._indentationRules.decreaseIndentPattern.test(e))}shouldIndentNextLine(e){return!!(this._indentationRules&&this._indentationRules.indentNextLinePattern&&g6(this._indentationRules.indentNextLinePattern)&&this._indentationRules.indentNextLinePattern.test(e))}shouldIgnore(e){return!!(this._indentationRules&&this._indentationRules.unIndentedLinePattern&&g6(this._indentationRules.unIndentedLinePattern)&&this._indentationRules.unIndentedLinePattern.test(e))}getIndentMetadata(e){let t=0;return this.shouldIncrease(e)&&(t+=1),this.shouldDecrease(e)&&(t+=2),this.shouldIndentNextLine(e)&&(t+=4),this.shouldIgnore(e)&&(t+=8),t}}});var b6,lNe=k(()=>{je();Qe();Ix();b6=class n{constructor(e){e=e||{},e.brackets=e.brackets||[["(",")"],["{","}"],["[","]"]],this._brackets=[],e.brackets.forEach(t=>{let i=n._createOpenBracketRegExp(t[0]),o=n._createCloseBracketRegExp(t[1]);i&&o&&this._brackets.push({open:t[0],openRegExp:i,close:t[1],closeRegExp:o})}),this._regExpRules=e.onEnterRules||[]}onEnter(e,t,i,o){if(e>=3)for(let r=0,s=this._regExpRules.length;rc.reg?(c.reg.lastIndex=0,c.reg.test(c.text)):!0))return a.action}if(e>=2&&i.length>0&&o.length>0)for(let r=0,s=this._brackets.length;r=2&&i.length>0){for(let r=0,s=this._brackets.length;r"u"?t:r}function uNe(n){return n.replace(/[\[\]]/g,"")}var Ve,en=k(()=>{Fe();Ve=We("configurationService")});var ai,fs=k(()=>{Fe();ai=We("languageService")});var Dd,x6=k(()=>{Dd=class{constructor(e,t=[],i=!1){this.ctor=e,this.staticArguments=t,this.supportsDelayedInstantiation=i}}});function Ct(n,e,t){e instanceof Dd||(e=new Dd(e,[],!!t)),hNe.push([n,e])}function qoe(){return hNe}var hNe,Xs=k(()=>{x6();hNe=[]});var An,Ex=k(()=>{An=Object.freeze({text:"text/plain",binary:"application/octet-stream",unknown:"application/unknown",markdown:"text/markdown",latex:"text/latex",uriList:"text/uri-list"})});function Qrt(n){return n.length>0&&n.charAt(n.length-1)==="#"?n.substring(0,n.length-1):n}var V1,Koe,Jrt,w6=k(()=>{Ie();br();V1={JSONContribution:"base.contributions.json"};Koe=class{constructor(){this._onDidChangeSchema=new A,this.schemasById={}}registerSchema(e,t){this.schemasById[Qrt(e)]=t,this._onDidChangeSchema.fire(e)}notifySchemaChanged(e){this._onDidChangeSchema.fire(e)}},Jrt=new Koe;ei.add(V1.JSONContribution,Jrt)});function SA(n){let e=[];if(Z_.test(n)){let t=pNe.exec(n);for(;t?.length;){let i=t[1].trim();i&&e.push(i),t=pNe.exec(n)}}return Ac(e)}function est(n){switch(Array.isArray(n)?n[0]:n){case"boolean":return!1;case"integer":case"number":return 0;case"string":return"";case"array":return[];case"object":return{};default:return null}}function tst(n,e){return n.trim()?Z_.test(n)?m("config.property.languageDefault","Cannot register '{0}'. This matches property pattern '\\\\[.*\\\\]$' for describing language specific editor settings. Use 'configurationDefaults' contribution.",n):C6.getConfigurationProperties()[n]!==void 0?m("config.property.duplicate","Cannot register '{0}'. This property is already registered.",n):e.policy?.name&&C6.getPolicyConfigurations().get(e.policy?.name)!==void 0?m("config.policy.duplicate","Cannot register '{0}'. The associated policy {1} is already registered with {2}.",n,e.policy?.name,C6.getPolicyConfigurations().get(e.policy?.name)):null:m("config.property.empty","Cannot register an empty property")}var Qs,Goe,Yoe,Zoe,Xoe,Qoe,y6,CA,fNe,Joe,mNe,pNe,U1,Z_,C6,Mm=k(()=>{at();Ie();yi();pe();en();w6();br();Qs={Configuration:"base.contributions.configuration"},Goe={properties:{},patternProperties:{}},Yoe={properties:{},patternProperties:{}},Zoe={properties:{},patternProperties:{}},Xoe={properties:{},patternProperties:{}},Qoe={properties:{},patternProperties:{}},y6={properties:{},patternProperties:{}},CA="vscode://schemas/settings/resourceLanguage",fNe=ei.as(V1.JSONContribution),Joe=class{constructor(){this.registeredConfigurationDefaults=[],this.overrideIdentifiers=new Set,this._onDidSchemaChange=new A,this._onDidUpdateConfiguration=new A,this.configurationDefaultsOverrides=new Map,this.defaultLanguageConfigurationOverridesNode={id:"defaultOverrides",title:m("defaultLanguageConfigurationOverrides.title","Default Language Configuration Overrides"),properties:{}},this.configurationContributors=[this.defaultLanguageConfigurationOverridesNode],this.resourceLanguageSettingsSchema={properties:{},patternProperties:{},additionalProperties:!0,allowTrailingCommas:!0,allowComments:!0},this.configurationProperties={},this.policyConfigurations=new Map,this.excludedConfigurationProperties={},fNe.registerSchema(CA,this.resourceLanguageSettingsSchema),this.registerOverridePropertyPatternKey()}registerConfiguration(e,t=!0){this.registerConfigurations([e],t)}registerConfigurations(e,t=!0){let i=new Set;this.doRegisterConfigurations(e,t,i),fNe.registerSchema(CA,this.resourceLanguageSettingsSchema),this._onDidSchemaChange.fire(),this._onDidUpdateConfiguration.fire({properties:i})}registerDefaultConfigurations(e){let t=new Set;this.doRegisterDefaultConfigurations(e,t),this._onDidSchemaChange.fire(),this._onDidUpdateConfiguration.fire({properties:t,defaultsOverrides:!0})}doRegisterDefaultConfigurations(e,t){this.registeredConfigurationDefaults.push(...e);let i=[];for(let{overrides:o,source:r}of e)for(let s in o){t.add(s);let a=this.configurationDefaultsOverrides.get(s)??this.configurationDefaultsOverrides.set(s,{configurationDefaultOverrides:[]}).get(s),l=o[s];if(a.configurationDefaultOverrides.push({value:l,source:r}),Z_.test(s)){let c=this.mergeDefaultConfigurationsForOverrideIdentifier(s,l,r,a.configurationDefaultOverrideValue);if(!c)continue;a.configurationDefaultOverrideValue=c,this.updateDefaultOverrideProperty(s,c,r),i.push(...SA(s))}else{let c=this.mergeDefaultConfigurationsForConfigurationProperty(s,l,r,a.configurationDefaultOverrideValue);if(!c)continue;a.configurationDefaultOverrideValue=c;let d=this.configurationProperties[s];d&&(this.updatePropertyDefaultValue(s,d),this.updateSchema(s,d))}}this.doRegisterOverrideIdentifiers(i)}updateDefaultOverrideProperty(e,t,i){let o={type:"object",default:t.value,description:m("defaultLanguageConfiguration.description","Configure settings to be overridden for the {0} language.",uNe(e)),$ref:CA,defaultDefaultValue:t.value,source:i,defaultValueSource:i};this.configurationProperties[e]=o,this.defaultLanguageConfigurationOverridesNode.properties[e]=o}mergeDefaultConfigurationsForOverrideIdentifier(e,t,i,o){let r=o?.value||{},s=o?.source??new Map;if(!(s instanceof Map)){console.error("objectConfigurationSources is not a Map");return}for(let a of Object.keys(t)){let l=t[a];if(mo(l)&&(Vr(r[a])||mo(r[a]))){if(r[a]={...r[a]??{},...l},i)for(let d in l)s.set(`${a}.${d}`,i)}else r[a]=l,i?s.set(a,i):s.delete(a)}return{value:r,source:s}}mergeDefaultConfigurationsForConfigurationProperty(e,t,i,o){let r=this.configurationProperties[e],s=o?.value??r?.defaultDefaultValue,a=i;if(mo(t)&&(r!==void 0&&r.type==="object"||r===void 0&&(Vr(s)||mo(s)))){if(a=o?.source??new Map,!(a instanceof Map)){console.error("defaultValueSource is not a Map");return}for(let c in t)i&&a.set(`${e}.${c}`,i);t={...mo(s)?s:{},...t}}return{value:t,source:a}}registerOverrideIdentifiers(e){this.doRegisterOverrideIdentifiers(e),this._onDidSchemaChange.fire()}doRegisterOverrideIdentifiers(e){for(let t of e)this.overrideIdentifiers.add(t);this.updateOverridePropertyPatternKey()}doRegisterConfigurations(e,t,i){e.forEach(o=>{this.validateAndRegisterProperties(o,t,o.extensionInfo,o.restrictedProperties,void 0,i),this.configurationContributors.push(o),this.registerJSONConfiguration(o)})}validateAndRegisterProperties(e,t=!0,i,o,r=3,s){r=Za(e.scope)?r:e.scope;let a=e.properties;if(a)for(let c in a){let d=a[c];if(t&&tst(c,d)){delete a[c];continue}if(d.source=i,d.defaultDefaultValue=a[c].default,this.updatePropertyDefaultValue(c,d),Z_.test(c)?d.scope=void 0:(d.scope=Za(d.scope)?r:d.scope,d.restricted=Za(d.restricted)?!!o?.includes(c):d.restricted),a[c].hasOwnProperty("included")&&!a[c].included){this.excludedConfigurationProperties[c]=a[c],delete a[c];continue}else this.configurationProperties[c]=a[c],a[c].policy?.name&&this.policyConfigurations.set(a[c].policy.name,c);!a[c].deprecationMessage&&a[c].markdownDeprecationMessage&&(a[c].deprecationMessage=a[c].markdownDeprecationMessage),s.add(c)}let l=e.allOf;if(l)for(let c of l)this.validateAndRegisterProperties(c,t,i,o,r,s)}getConfigurationProperties(){return this.configurationProperties}getPolicyConfigurations(){return this.policyConfigurations}registerJSONConfiguration(e){let t=i=>{let o=i.properties;if(o)for(let s in o)this.updateSchema(s,o[s]);i.allOf?.forEach(t)};t(e)}updateSchema(e,t){switch(Goe.properties[e]=t,t.scope){case 1:Yoe.properties[e]=t;break;case 2:Zoe.properties[e]=t;break;case 6:Xoe.properties[e]=t;break;case 3:Qoe.properties[e]=t;break;case 4:y6.properties[e]=t;break;case 5:y6.properties[e]=t,this.resourceLanguageSettingsSchema.properties[e]=t;break}}updateOverridePropertyPatternKey(){for(let e of this.overrideIdentifiers.values()){let t=`[${e}]`,i={type:"object",description:m("overrideSettings.defaultDescription","Configure editor settings to be overridden for a language."),errorMessage:m("overrideSettings.errorMessage","This setting does not support per-language configuration."),$ref:CA};this.updatePropertyDefaultValue(t,i),Goe.properties[t]=i,Yoe.properties[t]=i,Zoe.properties[t]=i,Xoe.properties[t]=i,Qoe.properties[t]=i,y6.properties[t]=i}}registerOverridePropertyPatternKey(){let e={type:"object",description:m("overrideSettings.defaultDescription","Configure editor settings to be overridden for a language."),errorMessage:m("overrideSettings.errorMessage","This setting does not support per-language configuration."),$ref:CA};Goe.patternProperties[U1]=e,Yoe.patternProperties[U1]=e,Zoe.patternProperties[U1]=e,Xoe.patternProperties[U1]=e,Qoe.patternProperties[U1]=e,y6.patternProperties[U1]=e,this._onDidSchemaChange.fire()}updatePropertyDefaultValue(e,t){let i=this.configurationDefaultsOverrides.get(e)?.configurationDefaultOverrideValue,o,r;i&&(!t.disallowConfigurationDefault||!i.source)&&(o=i.value,r=i.source),Vr(o)&&(o=t.defaultDefaultValue,r=void 0),Vr(o)&&(o=est(t.type)),t.default=o,t.defaultValueSource=r}},mNe="\\[([^\\]]+)\\]",pNe=new RegExp(mNe,"g"),U1=`^(${mNe})+$`,Z_=new RegExp(U1);C6=new Joe;ei.add(Qs.Configuration,C6)});var ist,ere,Tx,Oo,nst,Nd=k(()=>{pe();Ie();br();Ex();Mm();ist={ModesRegistry:"editor.modesRegistry"},ere=class{constructor(){this._onDidChangeLanguages=new A,this.onDidChangeLanguages=this._onDidChangeLanguages.event,this._languages=[]}registerLanguage(e){return this._languages.push(e),this._onDidChangeLanguages.fire(void 0),{dispose:()=>{for(let t=0,i=this._languages.length;te!==""&&t!=="")}var S6,k6,tre,ire,_Ne=k(()=>{Tne();yA();S6=class{constructor(e,t){this.languageId=e;let i=t.brackets?gNe(t.brackets):[],o=new qR(a=>{let l=new Set;return{info:new tre(this,a,l),closing:l}}),r=new qR(a=>{let l=new Set,c=new Set;return{info:new ire(this,a,l,c),opening:l,openingColorized:c}});for(let[a,l]of i){let c=o.get(a),d=r.get(l);c.closing.add(d.info),d.opening.add(c.info)}let s=t.colorizedBracketPairs?gNe(t.colorizedBracketPairs):i.filter(a=>!(a[0]==="<"&&a[1]===">"));for(let[a,l]of s){let c=o.get(a),d=r.get(l);c.closing.add(d.info),d.openingColorized.add(c.info),d.opening.add(c.info)}this._openingBrackets=new Map([...o.cachedValues].map(([a,l])=>[a,l.info])),this._closingBrackets=new Map([...r.cachedValues].map(([a,l])=>[a,l.info]))}get openingBrackets(){return[...this._openingBrackets.values()]}get closingBrackets(){return[...this._closingBrackets.values()]}getOpeningBracketInfo(e){return this._openingBrackets.get(e)}getClosingBracketInfo(e){return this._closingBrackets.get(e)}getBracketInfo(e){return this.getOpeningBracketInfo(e)||this.getClosingBracketInfo(e)}getBracketRegExp(e){let t=Array.from([...this._openingBrackets.keys(),...this._closingBrackets.keys()]);return yL(t,e)}};k6=class{constructor(e,t){this.config=e,this.bracketText=t}get languageId(){return this.config.languageId}},tre=class extends k6{constructor(e,t,i){super(e,t),this.openedBrackets=i,this.isOpeningBracket=!0}},ire=class extends k6{constructor(e,t,i,o){super(e,t),this.openingBrackets=i,this.openingColorizedBrackets=o,this.isOpeningBracket=!1}closes(e){return e.config!==this.config?!1:this.openingBrackets.has(e)}closesColorized(e){return e.config!==this.config?!1:this.openingColorizedBrackets.has(e)}getOpeningBrackets(){return[...this.openingBrackets]}}});function rst(n,e,t,i){let o=e.getLanguageConfiguration(n);if(!o){if(!i.isRegisteredLanguageId(n))return new CL(n,{});o=new CL(n,{})}let r=sst(o.languageId,t),s=xNe([o.underlyingConfig,r]);return new CL(o.languageId,s)}function sst(n,e){let t=e.getValue(ore.brackets,{overrideIdentifier:n}),i=e.getValue(ore.colorizedBracketPairs,{overrideIdentifier:n});return{brackets:vNe(t),colorizedBracketPairs:vNe(i)}}function vNe(n){if(Array.isArray(n))return n.map(e=>{if(!(!Array.isArray(e)||e.length!==2))return[e[0],e[1]]}).filter(e=>!!e)}function E6(n,e,t){let i=n.getLineContent(e),o=Ei(i);return o.length>t-1&&(o=o.substring(0,t-1)),o}function xNe(n){let e={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(let t of n)e={comments:t.comments||e.comments,brackets:t.brackets||e.brackets,wordPattern:t.wordPattern||e.wordPattern,indentationRules:t.indentationRules||e.indentationRules,onEnterRules:t.onEnterRules||e.onEnterRules,autoClosingPairs:t.autoClosingPairs||e.autoClosingPairs,surroundingPairs:t.surroundingPairs||e.surroundingPairs,autoCloseBefore:t.autoCloseBefore||e.autoCloseBefore,folding:t.folding||e.folding,colorizedBracketPairs:t.colorizedBracketPairs||e.colorizedBracketPairs,__electricCharacterSupport:t.__electricCharacterSupport||e.__electricCharacterSupport};return e}var ost,bNe,kA,ti,nre,ore,rre,L6,I6,sre,CL,Ko=k(()=>{Ie();j();Qe();h1();Ix();QDe();sNe();aNe();lNe();yA();Fe();en();fs();Xs();Nd();_Ne();ost=function(n,e,t,i){var o=arguments.length,r=o<3?e:i===null?i=Object.getOwnPropertyDescriptor(e,t):i,s;if(typeof Reflect=="object"&&typeof Reflect.decorate=="function")r=Reflect.decorate(n,e,t,i);else for(var a=n.length-1;a>=0;a--)(s=n[a])&&(r=(o<3?s(r):o>3?s(e,t,r):s(e,t))||r);return o>3&&r&&Object.defineProperty(e,t,r),r},bNe=function(n,e){return function(t,i){e(t,i,n)}},kA=class{constructor(e){this.languageId=e}affects(e){return this.languageId?this.languageId===e:!0}},ti=We("languageConfigurationService"),nre=class extends D{constructor(e,t){super(),this.configurationService=e,this.languageService=t,this._registry=this._register(new sre),this.onDidChangeEmitter=this._register(new A),this.onDidChange=this.onDidChangeEmitter.event,this.configurations=new Map;let i=new Set(Object.values(ore));this._register(this.configurationService.onDidChangeConfiguration(o=>{let r=o.change.keys.some(a=>i.has(a)),s=o.change.overrides.filter(([a,l])=>l.some(c=>i.has(c))).map(([a])=>a);if(r)this.configurations.clear(),this.onDidChangeEmitter.fire(new kA(void 0));else for(let a of s)this.languageService.isRegisteredLanguageId(a)&&(this.configurations.delete(a),this.onDidChangeEmitter.fire(new kA(a)))})),this._register(this._registry.onDidChange(o=>{this.configurations.delete(o.languageId),this.onDidChangeEmitter.fire(new kA(o.languageId))}))}register(e,t,i){return this._registry.register(e,t,i)}getLanguageConfiguration(e){let t=this.configurations.get(e);return t||(t=rst(e,this._registry,this.configurationService,this.languageService),this.configurations.set(e,t)),t}};nre=ost([bNe(0,Ve),bNe(1,ai)],nre);ore={brackets:"editor.language.brackets",colorizedBracketPairs:"editor.language.colorizedBracketPairs"};rre=class{constructor(e){this.languageId=e,this._resolved=null,this._entries=[],this._order=0,this._resolved=null}register(e,t){let i=new L6(e,t,++this._order);return this._entries.push(i),this._resolved=null,ge(()=>{for(let o=0;oe.configuration)))}};L6=class{constructor(e,t,i){this.configuration=e,this.priority=t,this.order=i}static cmp(e,t){return e.priority===t.priority?e.order-t.order:e.priority-t.priority}},I6=class{constructor(e){this.languageId=e}},sre=class extends D{constructor(){super(),this._entries=new Map,this._onDidChange=this._register(new A),this.onDidChange=this._onDidChange.event,this._register(this.register(Oo,{brackets:[["(",")"],["[","]"],["{","}"]],surroundingPairs:[{open:"{",close:"}"},{open:"[",close:"]"},{open:"(",close:")"},{open:"<",close:">"},{open:'"',close:'"'},{open:"'",close:"'"},{open:"`",close:"`"}],colorizedBracketPairs:[],folding:{offSide:!0}},0))}register(e,t,i=0){let o=this._entries.get(e);o||(o=new rre(e),this._entries.set(e,o));let r=o.register(t,i);return this._onDidChange.fire(new I6(e)),ge(()=>{r.dispose(),this._onDidChange.fire(new I6(e))})}getLanguageConfiguration(e){return this._entries.get(e)?.getResolvedConfiguration()||null}},CL=class n{constructor(e,t){this.languageId=e,this.underlyingConfig=t,this._brackets=null,this._electricCharacter=null,this._onEnterSupport=this.underlyingConfig.brackets||this.underlyingConfig.indentationRules||this.underlyingConfig.onEnterRules?new b6(this.underlyingConfig):null,this.comments=n._handleComments(this.underlyingConfig),this.characterPair=new h6(this.underlyingConfig),this.wordDefinition=this.underlyingConfig.wordPattern||TR,this.indentationRules=this.underlyingConfig.indentationRules,this.underlyingConfig.indentationRules?this.indentRulesSupport=new _6(this.underlyingConfig.indentationRules):this.indentRulesSupport=null,this.foldingRules=this.underlyingConfig.folding||{},this.bracketsNew=new S6(e,this.underlyingConfig)}getWordDefinition(){return DR(this.wordDefinition)}get brackets(){return!this._brackets&&this.underlyingConfig.brackets&&(this._brackets=new f6(this.languageId,this.underlyingConfig.brackets)),this._brackets}get electricCharacter(){return this._electricCharacter||(this._electricCharacter=new m6(this.brackets)),this._electricCharacter}onEnter(e,t,i,o){return this._onEnterSupport?this._onEnterSupport.onEnter(e,t,i,o):null}getAutoClosingPairs(){return new u6(this.characterPair.getAutoClosingPairs())}getAutoCloseBeforeSet(e){return this.characterPair.getAutoCloseBeforeSet(e)}getSurroundingPairs(){return this.characterPair.getSurroundingPairs()}static _handleComments(e){let t=e.comments;if(!t)return null;let i={};if(t.lineComment&&(i.lineCommentToken=t.lineComment),t.blockComment){let[o,r]=t.blockComment;i.blockCommentStartToken=o,i.blockCommentEndToken=r}return i}};Ct(ti,nre,1)});var mp,wNe=k(()=>{mp=class{constructor(e,t,i,o){this.originalStart=e,this.originalLength=t,this.modifiedStart=i,this.modifiedLength=o}getOriginalEnd(){return this.originalStart+this.originalLength}getModifiedEnd(){return this.modifiedStart+this.modifiedLength}}});function yNe(n,e,t){return new X_(new T6(n),new T6(e)).ComputeDiff(t).changes}var T6,Dx,Nx,D6,X_,LA=k(()=>{wNe();wx();T6=class{constructor(e){this.source=e}getElements(){let e=this.source,t=new Int32Array(e.length);for(let i=0,o=e.length;i0||this.m_modifiedCount>0)&&this.m_changes.push(new mp(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(e,t){this.m_originalStart=Math.min(this.m_originalStart,e),this.m_modifiedStart=Math.min(this.m_modifiedStart,t),this.m_originalCount++}AddModifiedElement(e,t){this.m_originalStart=Math.min(this.m_originalStart,e),this.m_modifiedStart=Math.min(this.m_modifiedStart,t),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}},X_=class n{constructor(e,t,i=null){this.ContinueProcessingPredicate=i,this._originalSequence=e,this._modifiedSequence=t;let[o,r,s]=n._getElements(e),[a,l,c]=n._getElements(t);this._hasStrings=s&&c,this._originalStringElements=o,this._originalElementsOrHash=r,this._modifiedStringElements=a,this._modifiedElementsOrHash=l,this.m_forwardHistory=[],this.m_reverseHistory=[]}static _isStringArray(e){return e.length>0&&typeof e[0]=="string"}static _getElements(e){let t=e.getElements();if(n._isStringArray(t)){let i=new Int32Array(t.length);for(let o=0,r=t.length;o=e&&o>=i&&this.ElementsAreEqual(t,o);)t--,o--;if(e>t||i>o){let u;return i<=o?(Dx.Assert(e===t+1,"originalStart should only be one more than originalEnd"),u=[new mp(e,0,i,o-i+1)]):e<=t?(Dx.Assert(i===o+1,"modifiedStart should only be one more than modifiedEnd"),u=[new mp(e,t-e+1,i,0)]):(Dx.Assert(e===t+1,"originalStart should only be one more than originalEnd"),Dx.Assert(i===o+1,"modifiedStart should only be one more than modifiedEnd"),u=[]),u}let s=[0],a=[0],l=this.ComputeRecursionPoint(e,t,i,o,s,a,r),c=s[0],d=a[0];if(l!==null)return l;if(!r[0]){let u=this.ComputeDiffRecursive(e,c,i,d,r),h=[];return r[0]?h=[new mp(c+1,t-(c+1)+1,d+1,o-(d+1)+1)]:h=this.ComputeDiffRecursive(c+1,t,d+1,o,r),this.ConcatenateChanges(u,h)}return[new mp(e,t-e+1,i,o-i+1)]}WALKTRACE(e,t,i,o,r,s,a,l,c,d,u,h,f,p,g,_,b,v){let x=null,w=null,y=new D6,C=t,L=i,E=f[0]-_[0]-o,N=-1073741824,M=this.m_forwardHistory.length-1;do{let F=E+e;F===C||F=0&&(c=this.m_forwardHistory[M],e=c[0],C=1,L=c.length-1)}while(--M>=-1);if(x=y.getReverseChanges(),v[0]){let F=f[0]+1,q=_[0]+1;if(x!==null&&x.length>0){let te=x[x.length-1];F=Math.max(F,te.getOriginalEnd()),q=Math.max(q,te.getModifiedEnd())}w=[new mp(F,h-F+1,q,g-q+1)]}else{y=new D6,C=s,L=a,E=f[0]-_[0]-l,N=1073741824,M=b?this.m_reverseHistory.length-1:this.m_reverseHistory.length-2;do{let F=E+r;F===C||F=d[F+1]?(u=d[F+1]-1,p=u-E-l,u>N&&y.MarkNextChange(),N=u+1,y.AddOriginalElement(u+1,p+1),E=F+1-r):(u=d[F-1],p=u-E-l,u>N&&y.MarkNextChange(),N=u,y.AddModifiedElement(u+1,p+1),E=F-1-r),M>=0&&(d=this.m_reverseHistory[M],r=d[0],C=1,L=d.length-1)}while(--M>=-1);w=y.getChanges()}return this.ConcatenateChanges(x,w)}ComputeRecursionPoint(e,t,i,o,r,s,a){let l=0,c=0,d=0,u=0,h=0,f=0;e--,i--,r[0]=0,s[0]=0,this.m_forwardHistory=[],this.m_reverseHistory=[];let p=t-e+(o-i),g=p+1,_=new Int32Array(g),b=new Int32Array(g),v=o-i,x=t-e,w=e-i,y=t-o,L=(x-v)%2===0;_[v]=e,b[x]=t,a[0]=!1;for(let E=1;E<=p/2+1;E++){let N=0,M=0;d=this.ClipDiagonalBound(v-E,E,v,g),u=this.ClipDiagonalBound(v+E,E,v,g);for(let q=d;q<=u;q+=2){q===d||qN+M&&(N=l,M=c),!L&&Math.abs(q-x)<=E-1&&l>=b[q])return r[0]=l,s[0]=c,te<=b[q]&&E<=1448?this.WALKTRACE(v,d,u,w,x,h,f,y,_,b,l,t,r,c,o,s,L,a):null}let F=(N-e+(M-i)-E)/2;if(this.ContinueProcessingPredicate!==null&&!this.ContinueProcessingPredicate(N,F))return a[0]=!0,r[0]=N,s[0]=M,F>0&&E<=1448?this.WALKTRACE(v,d,u,w,x,h,f,y,_,b,l,t,r,c,o,s,L,a):(e++,i++,[new mp(e,t-e+1,i,o-i+1)]);h=this.ClipDiagonalBound(x-E,E,x,g),f=this.ClipDiagonalBound(x+E,E,x,g);for(let q=h;q<=f;q+=2){q===h||q=b[q+1]?l=b[q+1]-1:l=b[q-1],c=l-(q-x)-y;let te=l;for(;l>e&&c>i&&this.ElementsAreEqual(l,c);)l--,c--;if(b[q]=l,L&&Math.abs(q-v)<=E&&l<=_[q])return r[0]=l,s[0]=c,te>=_[q]&&E<=1448?this.WALKTRACE(v,d,u,w,x,h,f,y,_,b,l,t,r,c,o,s,L,a):null}if(E<=1447){let q=new Int32Array(u-d+2);q[0]=v-d+1,Nx.Copy2(_,d,q,1,u-d+1),this.m_forwardHistory.push(q),q=new Int32Array(f-h+2),q[0]=x-h+1,Nx.Copy2(b,h,q,1,f-h+1),this.m_reverseHistory.push(q)}}return this.WALKTRACE(v,d,u,w,x,h,f,y,_,b,l,t,r,c,o,s,L,a)}PrettifyChanges(e){for(let t=0;t0,a=i.modifiedLength>0;for(;i.originalStart+i.originalLength=0;t--){let i=e[t],o=0,r=0;if(t>0){let u=e[t-1];o=u.originalStart+u.originalLength,r=u.modifiedStart+u.modifiedLength}let s=i.originalLength>0,a=i.modifiedLength>0,l=0,c=this._boundaryScore(i.originalStart,i.originalLength,i.modifiedStart,i.modifiedLength);for(let u=1;;u++){let h=i.originalStart-u,f=i.modifiedStart-u;if(hc&&(c=g,l=u)}i.originalStart-=l,i.modifiedStart-=l;let d=[null];if(t>0&&this.ChangesOverlap(e[t-1],e[t],d)){e[t-1]=d[0],e.splice(t,1),t++;continue}}if(this._hasStrings)for(let t=1,i=e.length;t0&&f>l&&(l=f,c=u,d=h)}return l>0?[c,d]:null}_contiguousSequenceScore(e,t,i){let o=0;for(let r=0;r=this._originalElementsOrHash.length-1?!0:this._hasStrings&&/^\s*$/.test(this._originalStringElements[e])}_OriginalRegionIsBoundary(e,t){if(this._OriginalIsBoundary(e)||this._OriginalIsBoundary(e-1))return!0;if(t>0){let i=e+t;if(this._OriginalIsBoundary(i-1)||this._OriginalIsBoundary(i))return!0}return!1}_ModifiedIsBoundary(e){return e<=0||e>=this._modifiedElementsOrHash.length-1?!0:this._hasStrings&&/^\s*$/.test(this._modifiedStringElements[e])}_ModifiedRegionIsBoundary(e,t){if(this._ModifiedIsBoundary(e)||this._ModifiedIsBoundary(e-1))return!0;if(t>0){let i=e+t;if(this._ModifiedIsBoundary(i-1)||this._ModifiedIsBoundary(i))return!0}return!1}_boundaryScore(e,t,i,o){let r=this._OriginalRegionIsBoundary(e,t)?1:0,s=this._ModifiedRegionIsBoundary(i,o)?1:0;return r+s}ConcatenateChanges(e,t){let i=[];if(e.length===0||t.length===0)return t.length>0?t:e;if(this.ChangesOverlap(e[e.length-1],t[0],i)){let o=new Array(e.length+t.length-1);return Nx.Copy(e,0,o,0,e.length-1),o[e.length-1]=i[0],Nx.Copy(t,1,o,e.length,t.length-1),o}else{let o=new Array(e.length+t.length);return Nx.Copy(e,0,o,0,e.length),Nx.Copy(t,0,o,e.length,t.length),o}}ChangesOverlap(e,t,i){if(Dx.Assert(e.originalStart<=t.originalStart,"Left change is not less than or equal to right change"),Dx.Assert(e.modifiedStart<=t.modifiedStart,"Left change is not less than or equal to right change"),e.originalStart+e.originalLength>=t.originalStart||e.modifiedStart+e.modifiedLength>=t.modifiedStart){let o=e.originalStart,r=e.originalLength,s=e.modifiedStart,a=e.modifiedLength;return e.originalStart+e.originalLength>=t.originalStart&&(r=t.originalStart+t.originalLength-e.originalStart),e.modifiedStart+e.modifiedLength>=t.modifiedStart&&(a=t.modifiedStart+t.modifiedLength-e.modifiedStart),i[0]=new mp(o,r,s,a),!0}else return i[0]=null,!1}ClipDiagonalBound(e,t,i,o){if(e>=0&&e255?255:n|0}function j1(n){return n<0?0:n>4294967295?4294967295:n|0}var IA=k(()=>{});var Q_,J_,q1=k(()=>{IA();Q_=class n{constructor(e){let t=$1(e);this._defaultValue=t,this._asciiMap=n._createAsciiMap(t),this._map=new Map}static _createAsciiMap(e){let t=new Uint8Array(256);return t.fill(e),t}set(e,t){let i=$1(t);e>=0&&e<256?this._asciiMap[e]=i:this._map.set(e,i)}get(e){return e>=0&&e<256?this._asciiMap[e]:this._map.get(e)||this._defaultValue}clear(){this._asciiMap.fill(this._defaultValue),this._map.clear()}},J_=class{constructor(){this._actual=new Q_(0)}add(e){this._actual.set(e,1)}has(e){return this._actual.get(e)===1}clear(){return this._actual.clear()}}});function ast(){return are===null&&(are=new cre([[1,104,2],[1,72,2],[1,102,6],[1,70,6],[2,116,3],[2,84,3],[3,116,4],[3,84,4],[4,112,5],[4,80,5],[5,115,9],[5,83,9],[5,58,10],[6,105,7],[6,73,7],[7,108,8],[7,76,8],[8,101,9],[8,69,9],[9,58,10],[10,47,11],[11,47,12]])),are}function lst(){if(EA===null){EA=new Q_(0);let n=` <>'"\u3001\u3002\uFF61\uFF64\uFF0C\uFF0E\uFF1A\uFF1B\u2018\u3008\u300C\u300E\u3014\uFF08\uFF3B\uFF5B\uFF62\uFF63\uFF5D\uFF3D\uFF09\u3015\u300F\u300D\u3009\u2019\uFF40\uFF5E\u2026`;for(let t=0;t{q1();lre=class{constructor(e,t,i){let o=new Uint8Array(e*t);for(let r=0,s=e*t;rt&&(t=l),a>i&&(i=a),c>i&&(i=c)}t++,i++;let o=new lre(i,t,0);for(let r=0,s=e.length;r=this._maxCharCode?0:this._states.get(e,t)}},are=null;EA=null;dre=class n{static _createLink(e,t,i,o,r){let s=r-1;do{let a=t.charCodeAt(s);if(e.get(a)!==2)break;s--}while(s>o);if(o>0){let a=t.charCodeAt(o-1),l=t.charCodeAt(s);(a===40&&l===41||a===91&&l===93||a===123&&l===125)&&s--}return{range:{startLineNumber:i,startColumn:o+1,endLineNumber:i,endColumn:s+2},url:t.substring(o,s+1)}}static computeLinks(e,t=ast()){let i=lst(),o=[];for(let r=1,s=e.getLineCount();r<=s;r++){let a=e.getLineContent(r),l=a.length,c=0,d=0,u=0,h=1,f=!1,p=!1,g=!1,_=!1;for(;c{N6=class n{constructor(){this._defaultValueSet=[["true","false"],["True","False"],["Private","Public","Friend","ReadOnly","Partial","Protected","WriteOnly"],["public","protected","private"]]}static{this.INSTANCE=new n}navigateValueSet(e,t,i,o,r){if(e&&t){let s=this.doNavigateValueSet(t,r);if(s)return{range:e,value:s}}if(i&&o){let s=this.doNavigateValueSet(o,r);if(s)return{range:i,value:s}}return null}doNavigateValueSet(e,t){let i=this.numberReplace(e,t);return i!==null?i:this.textReplace(e,t)}numberReplace(e,t){let i=Math.pow(10,e.length-(e.lastIndexOf(".")+1)),o=Number(e),r=parseFloat(e);return!isNaN(o)&&!isNaN(r)&&o===r?o===0&&!t?null:(o=Math.floor(o*i),o+=t?i:-i,String(o/i)):null}textReplace(e,t){return this.valueSetsReplace(this._defaultValueSet,e,t)}valueSetsReplace(e,t,i){let o=null;for(let r=0,s=e.length;o===null&&r=0?(o+=i?1:-1,o<0?o=e.length-1:o%=e.length,e[o]):null}}});var TA,ure=k(()=>{TA=class n{static{this.CHANNEL_NAME="editorWorkerHost"}static getChannel(e){return e.getChannel(n.CHANNEL_NAME)}static setChannel(e,t){e.setChannel(n.CHANNEL_NAME,t)}}});function cst(n){return Array.isArray(n)}var LNe,INe,hre,Fo,fre,pre,Ts,R6,Rx,Ds=k(()=>{hre=class{constructor(e,t){this.uri=e,this.value=t}};Fo=class n{static{this.defaultToKey=e=>e.toString()}constructor(e,t){if(this[LNe]="ResourceMap",e instanceof n)this.map=new Map(e.map),this.toKey=t??n.defaultToKey;else if(cst(e)){this.map=new Map,this.toKey=t??n.defaultToKey;for(let[i,o]of e)this.set(i,o)}else this.map=new Map,this.toKey=e??n.defaultToKey}set(e,t){return this.map.set(this.toKey(e),new hre(e,t)),this}get(e){return this.map.get(this.toKey(e))?.value}has(e){return this.map.has(this.toKey(e))}get size(){return this.map.size}clear(){this.map.clear()}delete(e){return this.map.delete(this.toKey(e))}forEach(e,t){typeof t<"u"&&(e=e.bind(t));for(let[i,o]of this.map)e(o.value,o.uri,this)}*values(){for(let e of this.map.values())yield e.value}*keys(){for(let e of this.map.values())yield e.uri}*entries(){for(let e of this.map.values())yield[e.uri,e.value]}*[(LNe=Symbol.toStringTag,Symbol.iterator)](){for(let[,e]of this.map)yield[e.uri,e.value]}},fre=class{constructor(){this[INe]="LinkedMap",this._map=new Map,this._head=void 0,this._tail=void 0,this._size=0,this._state=0}clear(){this._map.clear(),this._head=void 0,this._tail=void 0,this._size=0,this._state++}isEmpty(){return!this._head&&!this._tail}get size(){return this._size}get first(){return this._head?.value}get last(){return this._tail?.value}has(e){return this._map.has(e)}get(e,t=0){let i=this._map.get(e);if(i)return t!==0&&this.touch(i,t),i.value}set(e,t,i=0){let o=this._map.get(e);if(o)o.value=t,i!==0&&this.touch(o,i);else{switch(o={key:e,value:t,next:void 0,previous:void 0},i){case 0:this.addItemLast(o);break;case 1:this.addItemFirst(o);break;case 2:this.addItemLast(o);break;default:this.addItemLast(o);break}this._map.set(e,o),this._size++}return this}delete(e){return!!this.remove(e)}remove(e){let t=this._map.get(e);if(t)return this._map.delete(e),this.removeItem(t),this._size--,t.value}shift(){if(!this._head&&!this._tail)return;if(!this._head||!this._tail)throw new Error("Invalid list");let e=this._head;return this._map.delete(e.key),this.removeItem(e),this._size--,e.value}forEach(e,t){let i=this._state,o=this._head;for(;o;){if(t?e.bind(t)(o.value,o.key,this):e(o.value,o.key,this),this._state!==i)throw new Error("LinkedMap got modified during iteration.");o=o.next}}keys(){let e=this,t=this._state,i=this._head,o={[Symbol.iterator](){return o},next(){if(e._state!==t)throw new Error("LinkedMap got modified during iteration.");if(i){let r={value:i.key,done:!1};return i=i.next,r}else return{value:void 0,done:!0}}};return o}values(){let e=this,t=this._state,i=this._head,o={[Symbol.iterator](){return o},next(){if(e._state!==t)throw new Error("LinkedMap got modified during iteration.");if(i){let r={value:i.value,done:!1};return i=i.next,r}else return{value:void 0,done:!0}}};return o}entries(){let e=this,t=this._state,i=this._head,o={[Symbol.iterator](){return o},next(){if(e._state!==t)throw new Error("LinkedMap got modified during iteration.");if(i){let r={value:[i.key,i.value],done:!1};return i=i.next,r}else return{value:void 0,done:!0}}};return o}[(INe=Symbol.toStringTag,Symbol.iterator)](){return this.entries()}trimOld(e){if(e>=this.size)return;if(e===0){this.clear();return}let t=this._head,i=this.size;for(;t&&i>e;)this._map.delete(t.key),t=t.next,i--;this._head=t,this._size=i,t&&(t.previous=void 0),this._state++}trimNew(e){if(e>=this.size)return;if(e===0){this.clear();return}let t=this._tail,i=this.size;for(;t&&i>e;)this._map.delete(t.key),t=t.previous,i--;this._tail=t,this._size=i,t&&(t.next=void 0),this._state++}addItemFirst(e){if(!this._head&&!this._tail)this._tail=e;else if(this._head)e.next=this._head,this._head.previous=e;else throw new Error("Invalid list");this._head=e,this._state++}addItemLast(e){if(!this._head&&!this._tail)this._head=e;else if(this._tail)e.previous=this._tail,this._tail.next=e;else throw new Error("Invalid list");this._tail=e,this._state++}removeItem(e){if(e===this._head&&e===this._tail)this._head=void 0,this._tail=void 0;else if(e===this._head){if(!e.next)throw new Error("Invalid list");e.next.previous=void 0,this._head=e.next}else if(e===this._tail){if(!e.previous)throw new Error("Invalid list");e.previous.next=void 0,this._tail=e.previous}else{let t=e.next,i=e.previous;if(!t||!i)throw new Error("Invalid list");t.previous=i,i.next=t}e.next=void 0,e.previous=void 0,this._state++}touch(e,t){if(!this._head||!this._tail)throw new Error("Invalid list");if(!(t!==1&&t!==2)){if(t===1){if(e===this._head)return;let i=e.next,o=e.previous;e===this._tail?(o.next=void 0,this._tail=o):(i.previous=o,o.next=i),e.previous=void 0,e.next=this._head,this._head.previous=e,this._head=e,this._state++}else if(t===2){if(e===this._tail)return;let i=e.next,o=e.previous;e===this._head?(i.previous=void 0,this._head=i):(i.previous=o,o.next=i),e.next=void 0,e.previous=this._tail,this._tail.next=e,this._tail=e,this._state++}}}toJSON(){let e=[];return this.forEach((t,i)=>{e.push([i,t])}),e}fromJSON(e){this.clear();for(let[t,i]of e)this.set(t,i)}},pre=class extends fre{constructor(e,t=1){super(),this._limit=e,this._ratio=Math.min(Math.max(0,t),1)}get limit(){return this._limit}set limit(e){this._limit=e,this.checkTrim()}get(e,t=2){return super.get(e,t)}peek(e){return super.get(e,0)}set(e,t){return super.set(e,t,2),this}checkTrim(){this.size>this._limit&&this.trim(Math.round(this._limit*this._ratio))}},Ts=class extends pre{constructor(e,t=1){super(e,t)}trim(e){this.trimOld(e)}set(e,t){return super.set(e,t),this.checkTrim(),this}},R6=class{constructor(e){if(this._m1=new Map,this._m2=new Map,e)for(let[t,i]of e)this.set(t,i)}clear(){this._m1.clear(),this._m2.clear()}set(e,t){this._m1.set(e,t),this._m2.set(t,e)}get(e){return this._m1.get(e)}getKey(e){return this._m2.get(e)}delete(e){let t=this._m1.get(e);return t===void 0?!1:(this._m1.delete(e),this._m2.delete(t),!0)}keys(){return this._m1.keys()}values(){return this._m1.values()}},Rx=class{constructor(){this.map=new Map}add(e,t){let i=this.map.get(e);i||(i=new Set,this.map.set(e,i)),i.add(t)}delete(e,t){let i=this.map.get(e);i&&(i.delete(t),i.size===0&&this.map.delete(e))}forEach(e,t){let i=this.map.get(e);i&&i.forEach(t)}get(e){let t=this.map.get(e);return t||new Set}}});function Dl(n,e){let t=`${n}/${e.join(",")}`,i=ENe.get(t);return i||(i=new mre(n,e),ENe.set(t,i)),i}var mre,ENe,SL=k(()=>{Ds();q1();mre=class extends Q_{constructor(e,t){super(0),this._segmenter=null,this._cachedLine=null,this._cachedSegments=[],this.intlSegmenterLocales=t,this.intlSegmenterLocales.length>0?this._segmenter=new Intl.Segmenter(this.intlSegmenterLocales,{granularity:"word"}):this._segmenter=null;for(let i=0,o=e.length;it)break;i=o}return i}findNextIntlWordAtOrAfterOffset(e,t){for(let i of this._getIntlSegmenterWordsOnLine(e))if(!(i.index{ec();(function(n){n[n.Left=1]="Left",n[n.Center=2]="Center",n[n.Right=4]="Right",n[n.Full=7]="Full"})(Js||(Js={}));(function(n){n[n.Left=1]="Left",n[n.Center=2]="Center",n[n.Right=3]="Right"})(tl||(tl={}));(function(n){n[n.Both=0]="Both",n[n.Right=1]="Right",n[n.Left=2]="Left",n[n.None=3]="None"})(Vc||(Vc={}));Ax=class{get originalIndentSize(){return this._indentSizeIsTabSize?"tabSize":this.indentSize}constructor(e){this._textModelResolvedOptionsBrand=void 0,this.tabSize=Math.max(1,e.tabSize|0),e.indentSize==="tabSize"?(this.indentSize=this.tabSize,this._indentSizeIsTabSize=!0):(this.indentSize=Math.max(1,e.indentSize|0),this._indentSizeIsTabSize=!1),this.insertSpaces=!!e.insertSpaces,this.defaultEOL=e.defaultEOL|0,this.trimAutoWhitespace=!!e.trimAutoWhitespace,this.bracketPairColorizationOptions=e.bracketPairColorizationOptions}equals(e){return this.tabSize===e.tabSize&&this._indentSizeIsTabSize===e._indentSizeIsTabSize&&this.indentSize===e.indentSize&&this.insertSpaces===e.insertSpaces&&this.defaultEOL===e.defaultEOL&&this.trimAutoWhitespace===e.trimAutoWhitespace&&os(this.bracketPairColorizationOptions,e.bracketPairColorizationOptions)}createChangeEvent(e){return{tabSize:this.tabSize!==e.tabSize,indentSize:this.indentSize!==e.indentSize,insertSpaces:this.insertSpaces!==e.insertSpaces,trimAutoWhitespace:this.trimAutoWhitespace!==e.trimAutoWhitespace}}},Pm=class{constructor(e,t){this._findMatchBrand=void 0,this.range=e,this.matches=t}};kL=class{constructor(e,t,i,o,r,s){this.identifier=e,this.range=t,this.text=i,this.forceMoveMarkers=o,this.isAutoWhitespaceEdit=r,this._isTracked=s}},A6=class{constructor(e,t,i){this.regex=e,this.wordSeparators=t,this.simpleSearch=i}},M6=class{constructor(e,t,i){this.reverseEdits=e,this.changes=t,this.trimAutoWhitespaceLineNumbers=i}}});function hst(n){if(!n||n.length===0)return!1;for(let e=0,t=n.length;e=t)break;let o=n.charCodeAt(e);if(o===110||o===114||o===87)return!0}}return!1}function Mx(n,e,t){if(!t)return new Pm(n,null);let i=[];for(let o=0,r=e.length;o0){let s=e.charCodeAt(i);if(n.get(s)!==0)return!0}return!1}function pst(n,e,t,i,o){if(i+o===t)return!0;let r=e.charCodeAt(i+o);if(n.get(r)!==0||r===13||r===10)return!0;if(o>0){let s=e.charCodeAt(i+o-1);if(n.get(s)!==0)return!0}return!1}function F6(n,e,t,i,o){return fst(n,e,t,i,o)&&pst(n,e,t,i,o)}var ust,gp,O6,K1,Om,DA=k(()=>{Qe();SL();qe();we();Zr();ust=999,gp=class{constructor(e,t,i,o){this.searchString=e,this.isRegex=t,this.matchCase=i,this.wordSeparators=o}parseSearchRequest(){if(this.searchString==="")return null;let e;this.isRegex?e=hst(this.searchString):e=this.searchString.indexOf(` `)>=0;let t=null;try{t=oB(this.searchString,this.isRegex,{matchCase:this.matchCase,wholeWord:!1,multiline:e,global:!0,unicode:!0})}catch{return null}if(!t)return null;let i=!this.isRegex&&!e;return i&&this.searchString.toLowerCase()!==this.searchString.toUpperCase()&&(i=this.matchCase),new A6(t,this.wordSeparators?Dl(this.wordSeparators,[]):null,i?this.searchString:null)}};O6=class{constructor(e){let t=[],i=0;for(let o=0,r=e.length;o>0);t[r]>=e?o=r-1:t[r+1]>=e?(i=r,o=r):i=r+1}return i+1}},K1=class{static findMatches(e,t,i,o,r){let s=t.parseSearchRequest();return s?s.regex.multiline?this._doFindMatchesMultiline(e,i,new Om(s.wordSeparators,s.regex),o,r):this._doFindMatchesLineByLine(e,i,s,o,r):[]}static _getMultilineMatchRange(e,t,i,o,r,s){let a,l=0;o?(l=o.findLineFeedCountBeforeOffset(r),a=t+r+l):a=t+r;let c;if(o){let f=o.findLineFeedCountBeforeOffset(r+s.length)-l;c=a+s.length+f}else c=a+s.length;let d=e.getPositionAt(a),u=e.getPositionAt(c);return new S(d.lineNumber,d.column,u.lineNumber,u.column)}static _doFindMatchesMultiline(e,t,i,o,r){let s=e.getOffsetAt(t.getStartPosition()),a=e.getValueInRange(t,1),l=e.getEOL()===`\r `?new O6(a):null,c=[],d=0,u;for(i.reset(0);u=i.next(a);)if(c[d++]=Mx(this._getMultilineMatchRange(e,s,a,l,u.index,u[0]),u,o),d>=r)return c;return c}static _doFindMatchesLineByLine(e,t,i,o,r){let s=[],a=0;if(t.startLineNumber===t.endLineNumber){let c=e.getLineContent(t.startLineNumber).substring(t.startColumn-1,t.endColumn-1);return a=this._findMatchesInLine(i,c,t.startLineNumber,t.startColumn-1,a,s,o,r),s}let l=e.getLineContent(t.startLineNumber).substring(t.startColumn-1);a=this._findMatchesInLine(i,l,t.startLineNumber,t.startColumn-1,a,s,o,r);for(let c=t.startLineNumber+1;c=l))return r;return r}let d=new Om(e.wordSeparators,e.regex),u;d.reset(0);do if(u=d.next(t),u&&(s[r++]=Mx(new S(i,u.index+1+o,i,u.index+1+u[0].length+o),u,a),r>=l))return r;while(u);return r}static findNextMatch(e,t,i,o){let r=t.parseSearchRequest();if(!r)return null;let s=new Om(r.wordSeparators,r.regex);return r.regex.multiline?this._doFindNextMatchMultiline(e,i,s,o):this._doFindNextMatchLineByLine(e,i,s,o)}static _doFindNextMatchMultiline(e,t,i,o){let r=new P(t.lineNumber,1),s=e.getOffsetAt(r),a=e.getLineCount(),l=e.getValueInRange(new S(r.lineNumber,r.column,a,e.getLineMaxColumn(a)),1),c=e.getEOL()===`\r `?new O6(l):null;i.reset(t.column-1);let d=i.next(l);return d?Mx(this._getMultilineMatchRange(e,s,l,c,d.index,d[0]),d,o):t.lineNumber!==1||t.column!==1?this._doFindNextMatchMultiline(e,new P(1,1),i,o):null}static _doFindNextMatchLineByLine(e,t,i,o){let r=e.getLineCount(),s=t.lineNumber,a=e.getLineContent(s),l=this._findFirstMatchInLine(i,a,s,t.column,o);if(l)return l;for(let c=1;c<=r;c++){let d=(s+c-1)%r,u=e.getLineContent(d+1),h=this._findFirstMatchInLine(i,u,d+1,1,o);if(h)return h}return null}static _findFirstMatchInLine(e,t,i,o,r){e.reset(o-1);let s=e.next(t);return s?Mx(new S(i,s.index+1,i,s.index+1+s[0].length),s,r):null}static findPreviousMatch(e,t,i,o){let r=t.parseSearchRequest();if(!r)return null;let s=new Om(r.wordSeparators,r.regex);return r.regex.multiline?this._doFindPreviousMatchMultiline(e,i,s,o):this._doFindPreviousMatchLineByLine(e,i,s,o)}static _doFindPreviousMatchMultiline(e,t,i,o){let r=this._doFindMatchesMultiline(e,new S(1,1,t.lineNumber,t.column),i,o,10*ust);if(r.length>0)return r[r.length-1];let s=e.getLineCount();return t.lineNumber!==s||t.column!==e.getLineMaxColumn(s)?this._doFindPreviousMatchMultiline(e,new P(s,e.getLineMaxColumn(s)),i,o):null}static _doFindPreviousMatchLineByLine(e,t,i,o){let r=e.getLineCount(),s=t.lineNumber,a=e.getLineContent(s).substring(0,t.column-1),l=this._findLastMatchInLine(i,a,s,o);if(l)return l;for(let c=1;c<=r;c++){let d=(r+s-c-1)%r,u=e.getLineContent(d+1),h=this._findLastMatchInLine(i,u,d+1,o);if(h)return h}return null}static _findLastMatchInLine(e,t,i,o){let r=null,s;for(e.reset(0);s=e.next(t);)r=Mx(new S(i,s.index+1,i,s.index+1+s[0].length),s,o);return r}};Om=class{constructor(e,t){this._wordSeparators=e,this._searchRegex=t,this._prevMatchStartIndex=-1,this._prevMatchLength=0}reset(e){this._searchRegex.lastIndex=e,this._prevMatchStartIndex=-1,this._prevMatchLength=0}next(e){let t=e.length,i;do{if(this._prevMatchStartIndex+this._prevMatchLength===t||(i=this._searchRegex.exec(e),!i))return null;let o=i.index,r=i[0].length;if(o===this._prevMatchStartIndex&&r===this._prevMatchLength){if(r===0){nL(e,t,this._searchRegex.lastIndex)>65535?this._searchRegex.lastIndex+=2:this._searchRegex.lastIndex+=1;continue}return null}if(this._prevMatchStartIndex=o,this._prevMatchLength=r,!this._wordSeparators||F6(this._wordSeparators,e,t,o,r))return i}while(i);return null}}});function mst(n,e){return`[${jr(n.map(i=>String.fromCodePoint(i)).join(""))}]`}function DNe(n){return n===" "||n===` `||n===" "}var G1,B6,gre=k(()=>{we();DA();Qe();bf();h1();G1=class{static computeUnicodeHighlights(e,t,i){let o=i?i.startLineNumber:1,r=i?i.endLineNumber:e.getLineCount(),s=new B6(t),a=s.getCandidateCodePoints(),l;a==="allNonBasicAscii"?l=new RegExp("[^\\t\\n\\r\\x20-\\x7E]","g"):l=new RegExp(`${mst(Array.from(a))}`,"g");let c=new Om(null,l),d=[],u=!1,h,f=0,p=0,g=0;e:for(let _=o,b=r;_<=b;_++){let v=e.getLineContent(_),x=v.length;c.reset(0);do if(h=c.next(v),h){let w=h.index,y=h.index+h[0].length;if(w>0){let N=v.charCodeAt(w-1);to(N)&&w--}if(y+1=1e3){u=!0;break e}d.push(new S(_,w+1,_,y+1))}}while(h)}return{ranges:d,hasMore:u,ambiguousCharacterCount:f,invisibleCharacterCount:p,nonBasicAsciiCharacterCount:g}}static computeUnicodeHighlightReason(e,t){let i=new B6(t);switch(i.shouldHighlightNonBasicASCII(e,null)){case 0:return null;case 2:return{kind:1};case 3:{let r=e.codePointAt(0),s=i.ambiguousCharacters.getPrimaryConfusable(r),a=eL.getLocales().filter(l=>!eL.getInstance(new Set([...t.allowedLocales,l])).isAmbiguous(r));return{kind:0,confusableWith:String.fromCodePoint(s),notAmbiguousInLocales:a}}case 1:return{kind:2}}}};B6=class{constructor(e){this.options=e,this.allowedCodePoints=new Set(e.allowedCodePoints),this.ambiguousCharacters=eL.getInstance(new Set(e.allowedLocales))}getCandidateCodePoints(){if(this.options.nonBasicASCII)return"allNonBasicAscii";let e=new Set;if(this.options.invisibleCharacters)for(let t of W_.codePoints)DNe(String.fromCodePoint(t))||e.add(t);if(this.options.ambiguousCharacters)for(let t of this.ambiguousCharacters.getConfusableCodePoints())e.add(t);for(let t of this.allowedCodePoints)e.delete(t);return e}shouldHighlightNonBasicASCII(e,t){let i=e.codePointAt(0);if(this.allowedCodePoints.has(i))return 0;if(this.options.nonBasicASCII)return 1;let o=!1,r=!1;if(t)for(let s of t){let a=s.codePointAt(0),l=Im(s);o=o||l,!l&&!this.ambiguousCharacters.isAmbiguous(a)&&!W_.isInvisibleCharacter(a)&&(r=!0)}return!o&&r?0:this.options.invisibleCharacters&&!DNe(e)&&W_.isInvisibleCharacter(i)?2:this.options.ambiguousCharacters&&this.ambiguousCharacters.isAmbiguous(i)?3:0}}});var Px,LL,W6=k(()=>{Px=class{constructor(e,t,i){this.changes=e,this.moves=t,this.hitTimeout=i}},LL=class{constructor(e,t){this.lineRangeMapping=e,this.changes=t}}});var Wt,H6,Rd=k(()=>{je();Wt=class n{static addRange(e,t){let i=0;for(;it))return new n(e,t)}static ofLength(e){return new n(0,e)}static ofStartAndLength(e,t){return new n(e,e+t)}constructor(e,t){if(this.start=e,this.endExclusive=t,e>t)throw new Nt(`Invalid range: ${this.toString()}`)}get isEmpty(){return this.start===this.endExclusive}delta(e){return new n(this.start+e,this.endExclusive+e)}deltaStart(e){return new n(this.start+e,this.endExclusive)}deltaEnd(e){return new n(this.start,this.endExclusive+e)}get length(){return this.endExclusive-this.start}toString(){return`[${this.start}, ${this.endExclusive})`}contains(e){return this.start<=e&&e=e.endExclusive}slice(e){return e.slice(this.start,this.endExclusive)}substring(e){return e.substring(this.start,this.endExclusive)}clip(e){if(this.isEmpty)throw new Nt(`Invalid clipping range: ${this.toString()}`);return Math.max(this.start,Math.min(this.endExclusive-1,e))}clipCyclic(e){if(this.isEmpty)throw new Nt(`Invalid clipping range: ${this.toString()}`);return e=this.endExclusive?this.start+(e-this.start)%this.length:e}forEach(e){for(let t=this.start;te.toString()).join(", ")}intersectsStrict(e){let t=0;for(;te+t.length,0)}}});function eb(n,e){let t=gst(n,e);if(t!==-1)return n[t]}function gst(n,e,t=n.length-1){for(let i=t;i>=0;i--){let o=n[i];if(e(o))return i}return-1}function tb(n,e){let t=Y1(n,e);return t===-1?void 0:n[t]}function Y1(n,e,t=0,i=n.length){let o=t,r=i;for(;o0&&(t=o)}return t}function RNe(n,e){if(n.length===0)return;let t=n[0];for(let i=1;i=0&&(t=o)}return t}function ANe(n,e){return RA(n,(t,i)=>-e(t,i))}function MNe(n,e){if(n.length===0)return-1;let t=0;for(let i=1;i0&&(t=i)}return t}function PNe(n,e){for(let t of n){let i=e(t);if(i!==void 0)return i}}var NA,Ad=k(()=>{NA=class n{static{this.assertInvariants=!1}constructor(e){this._array=e,this._findLastMonotonousLastIdx=0}findLastMonotonous(e){if(n.assertInvariants){if(this._prevFindLastPredicate){for(let i of this._array)if(this._prevFindLastPredicate(i)&&!e(i))throw new Error("MonotonousArray: current predicate must be weaker than (or equal to) the previous predicate.")}this._prevFindLastPredicate=e}let t=Y1(this._array,e,this._findLastMonotonousLastIdx);return this._findLastMonotonousLastIdx=t+1,t===-1?void 0:this._array[t]}}});var ut,yh,Nl=k(()=>{je();Rd();we();Ad();ut=class n{static fromRangeInclusive(e){return new n(e.startLineNumber,e.endLineNumber+1)}static joinMany(e){if(e.length===0)return[];let t=new yh(e[0].slice());for(let i=1;it)throw new Nt(`startLineNumber ${e} cannot be after endLineNumberExclusive ${t}`);this.startLineNumber=e,this.endLineNumberExclusive=t}contains(e){return this.startLineNumber<=e&&eo.endLineNumberExclusive>=e.startLineNumber),i=Y1(this._normalizedRanges,o=>o.startLineNumber<=e.endLineNumberExclusive)+1;if(t===i)this._normalizedRanges.splice(t,0,e);else if(t===i-1){let o=this._normalizedRanges[t];this._normalizedRanges[t]=o.join(e)}else{let o=this._normalizedRanges[t].join(this._normalizedRanges[i-1]).join(e);this._normalizedRanges.splice(t,i-t,o)}}contains(e){let t=tb(this._normalizedRanges,i=>i.startLineNumber<=e);return!!t&&t.endLineNumberExclusive>e}intersects(e){let t=tb(this._normalizedRanges,i=>i.startLineNumbere.startLineNumber}getUnion(e){if(this._normalizedRanges.length===0)return e;if(e._normalizedRanges.length===0)return this;let t=[],i=0,o=0,r=null;for(;i=s.startLineNumber?r=new ut(r.startLineNumber,Math.max(r.endLineNumberExclusive,s.endLineNumberExclusive)):(t.push(r),r=s)}return r!==null&&t.push(r),new n(t)}subtractFrom(e){let t=Ox(this._normalizedRanges,s=>s.endLineNumberExclusive>=e.startLineNumber),i=Y1(this._normalizedRanges,s=>s.startLineNumber<=e.endLineNumberExclusive)+1;if(t===i)return new n([e]);let o=[],r=e.startLineNumber;for(let s=t;sr&&o.push(new ut(r,a.startLineNumber)),r=a.endLineNumberExclusive}return re.toString()).join(", ")}getIntersection(e){let t=[],i=0,o=0;for(;it.delta(e)))}}});var xa,ib=k(()=>{qe();we();xa=class n{static{this.zero=new n(0,0)}static betweenPositions(e,t){return e.lineNumber===t.lineNumber?new n(0,t.column-e.column):new n(t.lineNumber-e.lineNumber,t.column-1)}static ofRange(e){return n.betweenPositions(e.getStartPosition(),e.getEndPosition())}static ofText(e){let t=0,i=0;for(let o of e)o===` `?(t++,i=0):i++;return new n(t,i)}constructor(e,t){this.lineCount=e,this.columnCount=t}isGreaterThanOrEqualTo(e){return this.lineCount!==e.lineCount?this.lineCount>e.lineCount:this.columnCount>=e.columnCount}createRange(e){return this.lineCount===0?new S(e.lineNumber,e.column,e.lineNumber,e.column+this.columnCount):new S(e.lineNumber,e.column,e.lineNumber+this.lineCount,this.columnCount+1)}addToPosition(e){return this.lineCount===0?new P(e.lineNumber,e.column+this.columnCount):new P(e.lineNumber+this.lineCount,this.columnCount+1)}toString(){return`${this.lineCount},${this.columnCount}`}}});var z6,ONe=k(()=>{Rd();ib();z6=class{constructor(e){this.text=e,this.lineStartOffsetByLineIdx=[],this.lineStartOffsetByLineIdx.push(0);for(let t=0;t{bf();je();qe();ONe();we();ib();Fx=class{constructor(e){this.edits=e,_f(()=>gL(e,(t,i)=>t.range.getEndPosition().isBeforeOrEqual(i.range.getStartPosition())))}apply(e){let t="",i=new P(1,1);for(let r of this.edits){let s=r.range,a=s.getStartPosition(),l=s.getEndPosition(),c=FNe(i,a);c.isEmpty()||(t+=e.getValueOfRange(c)),t+=r.text,i=l}let o=FNe(i,e.endPositionExclusive);return o.isEmpty()||(t+=e.getValueOfRange(o)),t}applyToString(e){let t=new _re(e);return this.apply(t)}getNewRanges(){let e=[],t=0,i=0,o=0;for(let r of this.edits){let s=xa.ofText(r.text),a=P.lift({lineNumber:r.range.startLineNumber+i,column:r.range.startColumn+(r.range.startLineNumber===t?o:0)}),l=s.createRange(a);e.push(l),i=l.endLineNumber-r.range.endLineNumber,o=l.endColumn-r.range.endColumn,t=r.range.endLineNumber}return e}},il=class{constructor(e,t){this.range=e,this.text=t}toSingleEditOperation(){return{range:this.range,text:this.text}}};AA=class{get endPositionExclusive(){return this.length.addToPosition(new P(1,1))}},_re=class extends AA{constructor(e){super(),this.value=e,this._t=new z6(this.value)}getValueOfRange(e){return this._t.getOffsetRange(e).substring(this.value)}get length(){return this._t.textLength}}});function IL(n,e){if(n.lineNumber<1)return new P(1,1);if(n.lineNumber>e.length)return new P(e.length,e[e.length-1].length+1);let t=e[n.lineNumber-1];return n.column>t.length+1?new P(n.lineNumber,t.length+1):n}function BNe(n,e){return n>=1&&n<=e.length}var ya,Rl,wa,Bm=k(()=>{je();Nl();qe();we();Fm();ya=class n{static inverse(e,t,i){let o=[],r=1,s=1;for(let l of e){let c=new n(new ut(r,l.original.startLineNumber),new ut(s,l.modified.startLineNumber));c.modified.isEmpty||o.push(c),r=l.original.endLineNumberExclusive,s=l.modified.endLineNumberExclusive}let a=new n(new ut(r,t+1),new ut(s,i+1));return a.modified.isEmpty||o.push(a),o}static clip(e,t,i){let o=[];for(let r of e){let s=r.original.intersect(t),a=r.modified.intersect(i);s&&!s.isEmpty&&a&&!a.isEmpty&&o.push(new n(s,a))}return o}constructor(e,t){this.original=e,this.modified=t}toString(){return`{${this.original.toString()}->${this.modified.toString()}}`}flip(){return new n(this.modified,this.original)}join(e){return new n(this.original.join(e.original),this.modified.join(e.modified))}toRangeMapping(){let e=this.original.toInclusiveRange(),t=this.modified.toInclusiveRange();if(e&&t)return new wa(e,t);if(this.original.startLineNumber===1||this.modified.startLineNumber===1){if(!(this.modified.startLineNumber===1&&this.original.startLineNumber===1))throw new Nt("not a valid diff");return new wa(new S(this.original.startLineNumber,1,this.original.endLineNumberExclusive,1),new S(this.modified.startLineNumber,1,this.modified.endLineNumberExclusive,1))}else return new wa(new S(this.original.startLineNumber-1,Number.MAX_SAFE_INTEGER,this.original.endLineNumberExclusive-1,Number.MAX_SAFE_INTEGER),new S(this.modified.startLineNumber-1,Number.MAX_SAFE_INTEGER,this.modified.endLineNumberExclusive-1,Number.MAX_SAFE_INTEGER))}toRangeMapping2(e,t){if(BNe(this.original.endLineNumberExclusive,e)&&BNe(this.modified.endLineNumberExclusive,t))return new wa(new S(this.original.startLineNumber,1,this.original.endLineNumberExclusive,1),new S(this.modified.startLineNumber,1,this.modified.endLineNumberExclusive,1));if(!this.original.isEmpty&&!this.modified.isEmpty)return new wa(S.fromPositions(new P(this.original.startLineNumber,1),IL(new P(this.original.endLineNumberExclusive-1,Number.MAX_SAFE_INTEGER),e)),S.fromPositions(new P(this.modified.startLineNumber,1),IL(new P(this.modified.endLineNumberExclusive-1,Number.MAX_SAFE_INTEGER),t)));if(this.original.startLineNumber>1&&this.modified.startLineNumber>1)return new wa(S.fromPositions(IL(new P(this.original.startLineNumber-1,Number.MAX_SAFE_INTEGER),e),IL(new P(this.original.endLineNumberExclusive-1,Number.MAX_SAFE_INTEGER),e)),S.fromPositions(IL(new P(this.modified.startLineNumber-1,Number.MAX_SAFE_INTEGER),t),IL(new P(this.modified.endLineNumberExclusive-1,Number.MAX_SAFE_INTEGER),t)));throw new Nt}};Rl=class n extends ya{static fromRangeMappings(e){let t=ut.join(e.map(o=>ut.fromRangeInclusive(o.originalRange))),i=ut.join(e.map(o=>ut.fromRangeInclusive(o.modifiedRange)));return new n(t,i,e)}constructor(e,t,i){super(e,t),this.innerChanges=i}flip(){return new n(this.modified,this.original,this.innerChanges?.map(e=>e.flip()))}withInnerChangesFromLineRanges(){return new n(this.original,this.modified,[this.toRangeMapping()])}},wa=class n{static assertSorted(e){for(let t=1;t${this.modifiedRange.toString()}}`}flip(){return new n(this.modifiedRange,this.originalRange)}toTextEdit(e){let t=e.getValueOfRange(this.modifiedRange);return new il(this.originalRange,t)}}});function HNe(n,e,t,i){return new X_(n,e,t).ComputeDiff(i)}function bst(n){if(n.length<=1)return n;let e=[n[0]],t=e[0];for(let i=1,o=n.length;i!0;let e=Date.now();return()=>Date.now()-e{LA();W6();Bm();Qe();we();bf();Nl();_st=3,V6=class{computeDiff(e,t,i){let r=new vre(e,t,{maxComputationTime:i.maxComputationTimeMs,shouldIgnoreTrimWhitespace:i.ignoreTrimWhitespace,shouldComputeCharChanges:!0,shouldMakePrettyDiff:!0,shouldPostProcessCharChanges:!0}).computeDiff(),s=[],a=null;for(let l of r.changes){let c;l.originalEndLineNumber===0?c=new ut(l.originalStartLineNumber+1,l.originalStartLineNumber+1):c=new ut(l.originalStartLineNumber,l.originalEndLineNumber+1);let d;l.modifiedEndLineNumber===0?d=new ut(l.modifiedStartLineNumber+1,l.modifiedStartLineNumber+1):d=new ut(l.modifiedStartLineNumber,l.modifiedEndLineNumber+1);let u=new Rl(c,d,l.charChanges?.map(h=>new wa(new S(h.originalStartLineNumber,h.originalStartColumn,h.originalEndLineNumber,h.originalEndColumn),new S(h.modifiedStartLineNumber,h.modifiedStartColumn,h.modifiedEndLineNumber,h.modifiedEndColumn))));a&&(a.modified.endLineNumberExclusive===u.modified.startLineNumber||a.original.endLineNumberExclusive===u.original.startLineNumber)&&(u=new Rl(a.original.join(u.original),a.modified.join(u.modified),a.innerChanges&&u.innerChanges?a.innerChanges.concat(u.innerChanges):void 0),s.pop()),s.push(u),a=u}return _f(()=>gL(s,(l,c)=>c.original.startLineNumber-l.original.endLineNumberExclusive===c.modified.startLineNumber-l.modified.endLineNumberExclusive&&l.original.endLineNumberExclusive(e===10?"\\n":String.fromCharCode(e))+`-(${this._lineNumbers[t]},${this._columns[t]})`).join(", ")+"]"}_assertIndex(e,t){if(e<0||e>=t.length)throw new Error("Illegal index")}getElements(){return this._charCodes}getStartLineNumber(e){return e>0&&e===this._lineNumbers.length?this.getEndLineNumber(e-1):(this._assertIndex(e,this._lineNumbers),this._lineNumbers[e])}getEndLineNumber(e){return e===-1?this.getStartLineNumber(e+1):(this._assertIndex(e,this._lineNumbers),this._charCodes[e]===10?this._lineNumbers[e]+1:this._lineNumbers[e])}getStartColumn(e){return e>0&&e===this._columns.length?this.getEndColumn(e-1):(this._assertIndex(e,this._columns),this._columns[e])}getEndColumn(e){return e===-1?this.getStartColumn(e+1):(this._assertIndex(e,this._columns),this._charCodes[e]===10?1:this._columns[e]+1)}},EL=class n{constructor(e,t,i,o,r,s,a,l){this.originalStartLineNumber=e,this.originalStartColumn=t,this.originalEndLineNumber=i,this.originalEndColumn=o,this.modifiedStartLineNumber=r,this.modifiedStartColumn=s,this.modifiedEndLineNumber=a,this.modifiedEndColumn=l}static createFromDiffChange(e,t,i){let o=t.getStartLineNumber(e.originalStart),r=t.getStartColumn(e.originalStart),s=t.getEndLineNumber(e.originalStart+e.originalLength-1),a=t.getEndColumn(e.originalStart+e.originalLength-1),l=i.getStartLineNumber(e.modifiedStart),c=i.getStartColumn(e.modifiedStart),d=i.getEndLineNumber(e.modifiedStart+e.modifiedLength-1),u=i.getEndColumn(e.modifiedStart+e.modifiedLength-1);return new n(o,r,s,a,l,c,d,u)}};MA=class n{constructor(e,t,i,o,r){this.originalStartLineNumber=e,this.originalEndLineNumber=t,this.modifiedStartLineNumber=i,this.modifiedEndLineNumber=o,this.charChanges=r}static createFromDiffResult(e,t,i,o,r,s,a){let l,c,d,u,h;if(t.originalLength===0?(l=i.getStartLineNumber(t.originalStart)-1,c=0):(l=i.getStartLineNumber(t.originalStart),c=i.getEndLineNumber(t.originalStart+t.originalLength-1)),t.modifiedLength===0?(d=o.getStartLineNumber(t.modifiedStart)-1,u=0):(d=o.getStartLineNumber(t.modifiedStart),u=o.getEndLineNumber(t.modifiedStart+t.modifiedLength-1)),s&&t.originalLength>0&&t.originalLength<20&&t.modifiedLength>0&&t.modifiedLength<20&&r()){let f=i.createCharSequence(e,t.originalStart,t.originalStart+t.originalLength-1),p=o.createCharSequence(e,t.modifiedStart,t.modifiedStart+t.modifiedLength-1);if(f.getElements().length>0&&p.getElements().length>0){let g=HNe(f,p,r,!0).changes;a&&(g=bst(g)),h=[];for(let _=0,b=g.length;_1&&g>1;){let _=h.charCodeAt(p-2),b=f.charCodeAt(g-2);if(_!==b)break;p--,g--}(p>1||g>1)&&this._pushTrimWhitespaceCharChange(o,r+1,1,p,s+1,1,g)}{let p=wre(h,1),g=wre(f,1),_=h.length+1,b=f.length+1;for(;p<_&&g{at();je();Rd();Hm=class n{static trivial(e,t){return new n([new xr(Wt.ofLength(e.length),Wt.ofLength(t.length))],!1)}static trivialTimedOut(e,t){return new n([new xr(Wt.ofLength(e.length),Wt.ofLength(t.length))],!0)}constructor(e,t){this.diffs=e,this.hitTimeout=t}},xr=class n{static invert(e,t){let i=[];return I3(e,(o,r)=>{i.push(n.fromOffsetPairs(o?o.getEndExclusives():Wm.zero,r?r.getStarts():new Wm(t,(o?o.seq2Range.endExclusive-o.seq1Range.endExclusive:0)+t)))}),i}static fromOffsetPairs(e,t){return new n(new Wt(e.offset1,t.offset1),new Wt(e.offset2,t.offset2))}static assertSorted(e){let t;for(let i of e){if(t&&!(t.seq1Range.endExclusive<=i.seq1Range.start&&t.seq2Range.endExclusive<=i.seq2Range.start))throw new Nt("Sequence diffs must be sorted");t=i}}constructor(e,t){this.seq1Range=e,this.seq2Range=t}swap(){return new n(this.seq2Range,this.seq1Range)}toString(){return`${this.seq1Range} <-> ${this.seq2Range}`}join(e){return new n(this.seq1Range.join(e.seq1Range),this.seq2Range.join(e.seq2Range))}delta(e){return e===0?this:new n(this.seq1Range.delta(e),this.seq2Range.delta(e))}deltaStart(e){return e===0?this:new n(this.seq1Range.deltaStart(e),this.seq2Range.deltaStart(e))}deltaEnd(e){return e===0?this:new n(this.seq1Range.deltaEnd(e),this.seq2Range.deltaEnd(e))}intersect(e){let t=this.seq1Range.intersect(e.seq1Range),i=this.seq2Range.intersect(e.seq2Range);if(!(!t||!i))return new n(t,i)}getStarts(){return new Wm(this.seq1Range.start,this.seq2Range.start)}getEndExclusives(){return new Wm(this.seq1Range.endExclusive,this.seq2Range.endExclusive)}},Wm=class n{static{this.zero=new n(0,0)}static{this.max=new n(Number.MAX_SAFE_INTEGER,Number.MAX_SAFE_INTEGER)}constructor(e,t){this.offset1=e,this.offset2=t}toString(){return`${this.offset1} <-> ${this.offset2}`}delta(e){return e===0?this:new n(this.offset1+e,this.offset2+e)}equals(e){return this.offset1===e.offset1&&this.offset2===e.offset2}},Bx=class n{static{this.instance=new n}isValid(){return!0}},$6=class{constructor(e){if(this.timeout=e,this.startTime=Date.now(),this.valid=!0,e<=0)throw new Nt("timeout must be positive")}isValid(){if(!(Date.now()-this.startTime{DL=class{constructor(e,t){this.width=e,this.height=t,this.array=[],this.array=new Array(e*t)}get(e,t){return this.array[e+t*this.width]}set(e,t,i){this.array[e+t*this.width]=i}};PA=class n{static{this.chrKeys=new Map}static getKey(e){let t=this.chrKeys.get(e);return t===void 0&&(t=this.chrKeys.size,this.chrKeys.set(e,t)),t}constructor(e,t,i){this.range=e,this.lines=t,this.source=i,this.histogram=[];let o=0;for(let r=e.startLineNumber-1;r{Rd();TL();j6();q6=class{compute(e,t,i=Bx.instance,o){if(e.length===0||t.length===0)return Hm.trivial(e,t);let r=new DL(e.length,t.length),s=new DL(e.length,t.length),a=new DL(e.length,t.length);for(let p=0;p0&&g>0&&s.get(p-1,g-1)===3&&(v+=a.get(p-1,g-1)),v+=o?o(p,g):1):v=-1;let x=Math.max(_,b,v);if(x===v){let w=p>0&&g>0?a.get(p-1,g-1):0;a.set(p,g,w+1),s.set(p,g,3)}else x===_?(a.set(p,g,0),s.set(p,g,1)):x===b&&(a.set(p,g,0),s.set(p,g,2));r.set(p,g,x)}let l=[],c=e.length,d=t.length;function u(p,g){(p+1!==c||g+1!==d)&&l.push(new xr(new Wt(p+1,c),new Wt(g+1,d))),c=p,d=g}let h=e.length-1,f=t.length-1;for(;h>=0&&f>=0;)s.get(h,f)===3?(u(h,f),h--,f--):s.get(h,f)===1?h--:f--;return u(-1,-1),l.reverse(),new Hm(l,!1)}}});var NL,K6,yre,Cre,Sre=k(()=>{Rd();TL();NL=class{compute(e,t,i=Bx.instance){if(e.length===0||t.length===0)return Hm.trivial(e,t);let o=e,r=t;function s(g,_){for(;go.length||y>r.length)continue;let C=s(w,y);l.set(d,C);let L=w===v?c.get(d+1):c.get(d-1);if(c.set(d,C!==w?new K6(L,w,y,C-w):L),l.get(d)===o.length&&l.get(d)-d===r.length)break e}}let u=c.get(d),h=[],f=o.length,p=r.length;for(;;){let g=u?u.x+u.length:0,_=u?u.y+u.length:0;if((g!==f||_!==p)&&h.push(new xr(new Wt(g,f),new Wt(_,p))),!u)break;f=u.x,p=u.y,u=u.prev}return h.reverse(),new Hm(h,!1)}},K6=class{constructor(e,t,i,o){this.prev=e,this.x=t,this.y=i,this.length=o}},yre=class{constructor(){this.positiveArr=new Int32Array(10),this.negativeArr=new Int32Array(10)}get(e){return e<0?(e=-e-1,this.negativeArr[e]):this.positiveArr[e]}set(e,t){if(e<0){if(e=-e-1,e>=this.negativeArr.length){let i=this.negativeArr;this.negativeArr=new Int32Array(i.length*2),this.negativeArr.set(i)}this.negativeArr[e]=t}else{if(e>=this.positiveArr.length){let i=this.positiveArr;this.positiveArr=new Int32Array(i.length*2),this.positiveArr.set(i)}this.positiveArr[e]=t}}},Cre=class{constructor(){this.positiveArr=[],this.negativeArr=[]}get(e){return e<0?(e=-e-1,this.negativeArr[e]):this.positiveArr[e]}set(e,t){e<0?(e=-e-1,this.negativeArr[e]=t):this.positiveArr[e]=t}}});function kre(n){return n>=97&&n<=122||n>=65&&n<=90||n>=48&&n<=57}function UNe(n){return vst[n]}function $Ne(n){return n===10?8:n===13?7:OA(n)?6:n>=97&&n<=122?0:n>=65&&n<=90?1:n>=48&&n<=57?2:n===-1?3:n===44||n===59?5:4}var Wx,vst,Lre=k(()=>{Ad();Rd();qe();we();j6();Wx=class{constructor(e,t,i){this.lines=e,this.range=t,this.considerWhitespaceChanges=i,this.elements=[],this.firstElementOffsetByLineIdx=[],this.lineStartOffsets=[],this.trimmedWsLengthsByLineIdx=[],this.firstElementOffsetByLineIdx.push(0);for(let o=this.range.startLineNumber;o<=this.range.endLineNumber;o++){let r=e[o-1],s=0;o===this.range.startLineNumber&&this.range.startColumn>1&&(s=this.range.startColumn-1,r=r.substring(s)),this.lineStartOffsets.push(s);let a=0;if(!i){let c=r.trimStart();a=r.length-c.length,r=c.trimEnd()}this.trimmedWsLengthsByLineIdx.push(a);let l=o===this.range.endLineNumber?Math.min(this.range.endColumn-1-s-a,r.length):r.length;for(let c=0;cString.fromCharCode(t)).join("")}getElement(e){return this.elements[e]}get length(){return this.elements.length}getBoundaryScore(e){let t=$Ne(e>0?this.elements[e-1]:-1),i=$Ne(er<=e),o=e-this.firstElementOffsetByLineIdx[i];return new P(this.range.startLineNumber+i,1+this.lineStartOffsets[i]+o+(o===0&&t==="left"?0:this.trimmedWsLengthsByLineIdx[i]))}translateRange(e){let t=this.translateOffset(e.start,"right"),i=this.translateOffset(e.endExclusive,"left");return i.isBefore(t)?S.fromPositions(i,i):S.fromPositions(t,i)}findWordContaining(e){if(e<0||e>=this.elements.length||!kre(this.elements[e]))return;let t=e;for(;t>0&&kre(this.elements[t-1]);)t--;let i=e;for(;io<=e.start)??0,i=NNe(this.firstElementOffsetByLineIdx,o=>e.endExclusive<=o)??this.elements.length;return new Wt(t,i)}};vst={0:0,1:0,2:0,3:10,4:2,5:30,6:3,7:10,8:10}});function qNe(n,e,t,i,o,r){let{moves:s,excludedChanges:a}=wst(n,e,t,r);if(!r.isValid())return[];let l=n.filter(d=>!a.has(d)),c=yst(l,i,o,e,t,r);return yR(s,c),s=Cst(s),s=s.filter(d=>{let u=d.original.toOffsetRange().slice(e).map(f=>f.trim());return u.join(` `).length>=15&&xst(u,f=>f.length>=2)>=2}),s=Sst(n,s),s}function xst(n,e){let t=0;for(let i of n)e(i)&&t++;return t}function wst(n,e,t,i){let o=[],r=n.filter(l=>l.modified.isEmpty&&l.original.length>=3).map(l=>new PA(l.original,e,l)),s=new Set(n.filter(l=>l.original.isEmpty&&l.modified.length>=3).map(l=>new PA(l.modified,t,l))),a=new Set;for(let l of r){let c=-1,d;for(let u of s){let h=l.computeSimilarity(u);h>c&&(c=h,d=u)}if(c>.9&&d&&(s.delete(d),o.push(new ya(l.range,d.range)),a.add(l.source),a.add(d.source)),!i.isValid())return{moves:o,excludedChanges:a}}return{moves:o,excludedChanges:a}}function yst(n,e,t,i,o,r){let s=[],a=new Rx;for(let h of n)for(let f=h.original.startLineNumber;fh.modified.startLineNumber,yl));for(let h of n){let f=[];for(let p=h.modified.startLineNumber;p{for(let w of f)if(w.originalLineRange.endLineNumberExclusive+1===v.endLineNumberExclusive&&w.modifiedLineRange.endLineNumberExclusive+1===_.endLineNumberExclusive){w.originalLineRange=new ut(w.originalLineRange.startLineNumber,v.endLineNumberExclusive),w.modifiedLineRange=new ut(w.modifiedLineRange.startLineNumber,_.endLineNumberExclusive),b.push(w);return}let x={modifiedLineRange:_,originalLineRange:v};l.push(x),b.push(x)}),f=b}if(!r.isValid())return[]}l.sort(D3(mr(h=>h.modifiedLineRange.length,yl)));let c=new yh,d=new yh;for(let h of l){let f=h.modifiedLineRange.startLineNumber-h.originalLineRange.startLineNumber,p=c.subtractFrom(h.modifiedLineRange),g=d.subtractFrom(h.originalLineRange).getWithDelta(f),_=p.getIntersection(g);for(let b of _.ranges){if(b.length<3)continue;let v=b,x=b.delta(-f);s.push(new ya(x,v)),c.addRange(v),d.addRange(x)}}s.sort(mr(h=>h.original.startLineNumber,yl));let u=new NA(n);for(let h=0;hC.original.startLineNumber<=f.original.startLineNumber),g=tb(n,C=>C.modified.startLineNumber<=f.modified.startLineNumber),_=Math.max(f.original.startLineNumber-p.original.startLineNumber,f.modified.startLineNumber-g.modified.startLineNumber),b=u.findLastMonotonous(C=>C.original.startLineNumberC.modified.startLineNumberi.length||L>o.length||c.contains(L)||d.contains(C)||!jNe(i[C-1],o[L-1],r))break}w>0&&(d.addRange(new ut(f.original.startLineNumber-w,f.original.startLineNumber)),c.addRange(new ut(f.modified.startLineNumber-w,f.modified.startLineNumber)));let y;for(y=0;yi.length||L>o.length||c.contains(L)||d.contains(C)||!jNe(i[C-1],o[L-1],r))break}y>0&&(d.addRange(new ut(f.original.endLineNumberExclusive,f.original.endLineNumberExclusive+y)),c.addRange(new ut(f.modified.endLineNumberExclusive,f.modified.endLineNumberExclusive+y))),(w>0||y>0)&&(s[h]=new ya(new ut(f.original.startLineNumber-w,f.original.endLineNumberExclusive+y),new ut(f.modified.startLineNumber-w,f.modified.endLineNumberExclusive+y)))}return s}function jNe(n,e,t){if(n.trim()===e.trim())return!0;if(n.length>300&&e.length>300)return!1;let o=new NL().compute(new Wx([n],new S(1,1,1,n.length),!1),new Wx([e],new S(1,1,1,e.length),!1),t),r=0,s=xr.invert(o.diffs,n.length);for(let d of s)d.seq1Range.forEach(u=>{OA(n.charCodeAt(u))||r++});function a(d){let u=0;for(let h=0;he.length?n:e);return r/l>.6&&l>10}function Cst(n){if(n.length===0)return n;n.sort(mr(t=>t.original.startLineNumber,yl));let e=[n[0]];for(let t=1;t=0&&s>=0&&r+s<=2){e[e.length-1]=i.join(o);continue}e.push(o)}return e}function Sst(n,e){let t=new NA(n);return e=e.filter(i=>{let o=t.findLastMonotonous(a=>a.original.startLineNumbera.modified.startLineNumber{TL();Bm();at();Ad();Ds();Nl();Lre();j6();Sre();we()});function FA(n,e,t){let i=t;return i=GNe(n,e,i),i=GNe(n,e,i),i=kst(n,e,i),i}function GNe(n,e,t){if(t.length===0)return t;let i=[];i.push(t[0]);for(let r=1;r0&&(a=a.delta(c))}o.push(a)}return i.length>0&&o.push(i[i.length-1]),o}function kst(n,e,t){if(!n.getBoundaryScore||!e.getBoundaryScore)return t;for(let i=0;i0?t[i-1]:void 0,r=t[i],s=i+1=i.start&&n.seq2Range.start-s>=o.start&&t.isStronglyEqual(n.seq2Range.start-s,n.seq2Range.endExclusive-s)&&s<100;)s++;s--;let a=0;for(;n.seq1Range.start+ac&&(c=p,l=d)}return n.delta(l)}function ZNe(n,e,t){let i=[];for(let o of t){let r=i[i.length-1];if(!r){i.push(o);continue}o.seq1Range.start-r.seq1Range.endExclusive<=2||o.seq2Range.start-r.seq2Range.endExclusive<=2?i[i.length-1]=new xr(r.seq1Range.join(o.seq1Range),r.seq2Range.join(o.seq2Range)):i.push(o)}return i}function XNe(n,e,t){let i=xr.invert(t,n.length),o=[],r=new Wm(0,0);function s(l,c){if(l.offset10;){let _=i[0];if(!(_.seq1Range.intersects(h.seq1Range)||_.seq2Range.intersects(h.seq2Range)))break;let v=n.findWordContaining(_.seq1Range.start),x=e.findWordContaining(_.seq2Range.start),w=new xr(v,x),y=w.intersect(_);if(p+=y.seq1Range.length,g+=y.seq2Range.length,h=h.join(w),h.seq1Range.endExclusive>=_.seq1Range.endExclusive)i.shift();else break}p+g<(h.seq1Range.length+h.seq2Range.length)*2/3&&o.push(h),r=h.getEndExclusives()}for(;i.length>0;){let l=i.shift();l.seq1Range.isEmpty||(s(l.getStarts(),l),s(l.getEndExclusives().delta(-1),l))}return Lst(t,o)}function Lst(n,e){let t=[];for(;n.length>0||e.length>0;){let i=n[0],o=e[0],r;i&&(!o||i.seq1Range.start0&&t[t.length-1].seq1Range.endExclusive>=r.seq1Range.start?t[t.length-1]=t[t.length-1].join(r):t.push(r)}return t}function QNe(n,e,t){let i=t;if(i.length===0)return i;let o=0,r;do{r=!1;let s=[i[0]];for(let a=1;a5||f.seq1Range.length+f.seq2Range.length>5)},l=i[a],c=s[s.length-1];d(c,l)?(r=!0,s[s.length-1]=s[s.length-1].join(l)):s.push(l)}i=s}while(o++<10&&r);return i}function JNe(n,e,t){let i=t;if(i.length===0)return i;let o=0,r;do{r=!1;let a=[i[0]];for(let l=1;l5||g.length>500)return!1;let b=n.getText(g).trim();if(b.length>20||b.split(/\r\n|\r|\n/).length>1)return!1;let v=n.countLinesIn(f.seq1Range),x=f.seq1Range.length,w=e.countLinesIn(f.seq2Range),y=f.seq2Range.length,C=n.countLinesIn(p.seq1Range),L=p.seq1Range.length,E=e.countLinesIn(p.seq2Range),N=p.seq2Range.length,M=2*40+50;function F(q){return Math.min(q,M)}return Math.pow(Math.pow(F(v*40+x),1.5)+Math.pow(F(w*40+y),1.5),1.5)+Math.pow(Math.pow(F(C*40+L),1.5)+Math.pow(F(E*40+N),1.5),1.5)>(M**1.5)**1.5*1.3},c=i[l],d=a[a.length-1];u(d,c)?(r=!0,a[a.length-1]=a[a.length-1].join(c)):a.push(c)}i=a}while(o++<10&&r);let s=[];return FEe(i,(a,l,c)=>{let d=l;function u(b){return b.length>0&&b.trim().length<=3&&l.seq1Range.length+l.seq2Range.length>100}let h=n.extendToFullLines(l.seq1Range),f=n.getText(new Wt(h.start,l.seq1Range.start));u(f)&&(d=d.deltaStart(-f.length));let p=n.getText(new Wt(l.seq1Range.endExclusive,h.endExclusive));u(p)&&(d=d.deltaEnd(p.length));let g=xr.fromOffsetPairs(a?a.getEndExclusives():Wm.zero,c?c.getStarts():Wm.max),_=d.intersect(g);s.length>0&&_.getStarts().equals(s[s.length-1].getEndExclusives())?s[s.length-1]=s[s.length-1].join(_):s.push(_)}),s}var Ire=k(()=>{at();Rd();TL()});function eRe(n){let e=0;for(;e{BA=class{constructor(e,t){this.trimmedHash=e,this.lines=t}getElement(e){return this.trimmedHash[e]}get length(){return this.trimmedHash.length}getBoundaryScore(e){let t=e===0?0:eRe(this.lines[e-1]),i=e===this.lines.length?0:eRe(this.lines[e]);return 1e3-(t+i)}getText(e){return this.lines.slice(e.start,e.endExclusive).join(` `)}isStronglyEqual(e,t){return this.lines[e]===this.lines[t]}}});function iRe(n,e,t,i=!1){let o=[];for(let r of Bk(n.map(s=>Ist(s,e,t)),(s,a)=>s.original.overlapOrTouch(a.original)||s.modified.overlapOrTouch(a.modified))){let s=r[0],a=r[r.length-1];o.push(new Rl(s.original.join(a.original),s.modified.join(a.modified),r.map(l=>l.innerChanges[0])))}return _f(()=>!i&&o.length>0&&(o[0].modified.startLineNumber!==o[0].original.startLineNumber||t.length-o[o.length-1].modified.endLineNumberExclusive!==e.length-o[o.length-1].original.endLineNumberExclusive)?!1:gL(o,(r,s)=>s.original.startLineNumber-r.original.endLineNumberExclusive===s.modified.startLineNumber-r.modified.endLineNumberExclusive&&r.original.endLineNumberExclusive=t[n.modifiedRange.startLineNumber-1].length&&n.originalRange.startColumn-1>=e[n.originalRange.startLineNumber-1].length&&n.originalRange.startLineNumber<=n.originalRange.endLineNumber+o&&n.modifiedRange.startLineNumber<=n.modifiedRange.endLineNumber+o&&(i=1);let r=new ut(n.originalRange.startLineNumber+i,n.originalRange.endLineNumber+1+o),s=new ut(n.modifiedRange.startLineNumber+i,n.modifiedRange.endLineNumber+1+o);return new Rl(r,s,[n])}function Est(n){return new ya(new ut(n.seq1Range.start+1,n.seq1Range.endExclusive+1),new ut(n.seq2Range.start+1,n.seq2Range.endExclusive+1))}var RL,Ere=k(()=>{at();bf();Nl();Rd();we();TL();VNe();Sre();KNe();Ire();tRe();Lre();W6();Bm();RL=class{constructor(){this.dynamicProgrammingDiffing=new q6,this.myersDiffingAlgorithm=new NL}computeDiff(e,t,i){if(e.length<=1&&oi(e,t,(y,C)=>y===C))return new Px([],[],!1);if(e.length===1&&e[0].length===0||t.length===1&&t[0].length===0)return new Px([new Rl(new ut(1,e.length+1),new ut(1,t.length+1),[new wa(new S(1,1,e.length,e[e.length-1].length+1),new S(1,1,t.length,t[t.length-1].length+1))])],[],!1);let o=i.maxComputationTimeMs===0?Bx.instance:new $6(i.maxComputationTimeMs),r=!i.ignoreTrimWhitespace,s=new Map;function a(y){let C=s.get(y);return C===void 0&&(C=s.size,s.set(y,C)),C}let l=e.map(y=>a(y.trim())),c=t.map(y=>a(y.trim())),d=new BA(l,e),u=new BA(c,t),h=d.length+u.length<1700?this.dynamicProgrammingDiffing.compute(d,u,o,(y,C)=>e[y]===t[C]?t[C].length===0?.1:1+Math.log(1+t[C].length):.99):this.myersDiffingAlgorithm.compute(d,u,o),f=h.diffs,p=h.hitTimeout;f=FA(d,u,f),f=QNe(d,u,f);let g=[],_=y=>{if(r)for(let C=0;Cy.seq1Range.start-b===y.seq2Range.start-v);let C=y.seq1Range.start-b;_(C),b=y.seq1Range.endExclusive,v=y.seq2Range.endExclusive;let L=this.refineDiff(e,t,y,o,r);L.hitTimeout&&(p=!0);for(let E of L.mappings)g.push(E)}_(e.length-b);let x=iRe(g,e,t),w=[];return i.computeMoves&&(w=this.computeMoves(x,e,t,l,c,o,r)),_f(()=>{function y(L,E){if(L.lineNumber<1||L.lineNumber>E.length)return!1;let N=E[L.lineNumber-1];return!(L.column<1||L.column>N.length+1)}function C(L,E){return!(L.startLineNumber<1||L.startLineNumber>E.length+1||L.endLineNumberExclusive<1||L.endLineNumberExclusive>E.length+1)}for(let L of x){if(!L.innerChanges)return!1;for(let E of L.innerChanges)if(!(y(E.modifiedRange.getStartPosition(),t)&&y(E.modifiedRange.getEndPosition(),t)&&y(E.originalRange.getStartPosition(),e)&&y(E.originalRange.getEndPosition(),e)))return!1;if(!C(L.modified,t)||!C(L.original,e))return!1}return!0}),new Px(x,w,p)}computeMoves(e,t,i,o,r,s,a){return qNe(e,t,i,o,r,s).map(d=>{let u=this.refineDiff(t,i,new xr(d.original.toOffsetRange(),d.modified.toOffsetRange()),s,a),h=iRe(u.mappings,t,i,!0);return new LL(d,h)})}refineDiff(e,t,i,o,r){let a=Est(i).toRangeMapping2(e,t),l=new Wx(e,a.originalRange,r),c=new Wx(t,a.modifiedRange,r),d=l.length+c.length<500?this.dynamicProgrammingDiffing.compute(l,c,o):this.myersDiffingAlgorithm.compute(l,c,o),u=!1,h=d.diffs;u&&xr.assertSorted(h),h=FA(l,c,h),u&&xr.assertSorted(h),h=XNe(l,c,h),u&&xr.assertSorted(h),h=ZNe(l,c,h),u&&xr.assertSorted(h),h=JNe(l,c,h),u&&xr.assertSorted(h);let f=h.map(p=>new wa(l.translateRange(p.seq1Range),c.translateRange(p.seq2Range)));return u&&wa.assertSorted(f),{mappings:f,hitTimeout:d.hitTimeout}}}});var Tre,nRe=k(()=>{zNe();Ere();Tre={getLegacy:()=>new V6,getDefault:()=>new RL}});function Hx(n,e){let t=Math.pow(10,e);return Math.round(n*t)/t}var Ut,zm,_p,Z,vo=k(()=>{Ut=class{constructor(e,t,i,o=1){this._rgbaBrand=void 0,this.r=Math.min(255,Math.max(0,e))|0,this.g=Math.min(255,Math.max(0,t))|0,this.b=Math.min(255,Math.max(0,i))|0,this.a=Hx(Math.max(Math.min(1,o),0),3)}static equals(e,t){return e.r===t.r&&e.g===t.g&&e.b===t.b&&e.a===t.a}},zm=class n{constructor(e,t,i,o){this._hslaBrand=void 0,this.h=Math.max(Math.min(360,e),0)|0,this.s=Hx(Math.max(Math.min(1,t),0),3),this.l=Hx(Math.max(Math.min(1,i),0),3),this.a=Hx(Math.max(Math.min(1,o),0),3)}static equals(e,t){return e.h===t.h&&e.s===t.s&&e.l===t.l&&e.a===t.a}static fromRGBA(e){let t=e.r/255,i=e.g/255,o=e.b/255,r=e.a,s=Math.max(t,i,o),a=Math.min(t,i,o),l=0,c=0,d=(a+s)/2,u=s-a;if(u>0){switch(c=Math.min(d<=.5?u/(2*d):u/(2-2*d),1),s){case t:l=(i-o)/u+(i1&&(i-=1),i<1/6?e+(t-e)*6*i:i<1/2?t:i<2/3?e+(t-e)*(2/3-i)*6:e}static toRGBA(e){let t=e.h/360,{s:i,l:o,a:r}=e,s,a,l;if(i===0)s=a=l=o;else{let c=o<.5?o*(1+i):o+i-o*i,d=2*o-c;s=n._hue2rgb(d,c,t+1/3),a=n._hue2rgb(d,c,t),l=n._hue2rgb(d,c,t-1/3)}return new Ut(Math.round(s*255),Math.round(a*255),Math.round(l*255),r)}},_p=class n{constructor(e,t,i,o){this._hsvaBrand=void 0,this.h=Math.max(Math.min(360,e),0)|0,this.s=Hx(Math.max(Math.min(1,t),0),3),this.v=Hx(Math.max(Math.min(1,i),0),3),this.a=Hx(Math.max(Math.min(1,o),0),3)}static equals(e,t){return e.h===t.h&&e.s===t.s&&e.v===t.v&&e.a===t.a}static fromRGBA(e){let t=e.r/255,i=e.g/255,o=e.b/255,r=Math.max(t,i,o),s=Math.min(t,i,o),a=r-s,l=r===0?0:a/r,c;return a===0?c=0:r===t?c=((i-o)/a%6+6)%6:r===i?c=(o-t)/a+2:c=(t-i)/a+4,new n(Math.round(c*60),l,r,e.a)}static toRGBA(e){let{h:t,s:i,v:o,a:r}=e,s=o*i,a=s*(1-Math.abs(t/60%2-1)),l=o-s,[c,d,u]=[0,0,0];return t<60?(c=s,d=a):t<120?(c=a,d=s):t<180?(d=s,u=a):t<240?(d=a,u=s):t<300?(c=a,u=s):t<=360&&(c=s,u=a),c=Math.round((c+l)*255),d=Math.round((d+l)*255),u=Math.round((u+l)*255),new Ut(c,d,u,r)}},Z=class n{static fromHex(e){return n.Format.CSS.parseHex(e)||n.red}static equals(e,t){return!e&&!t?!0:!e||!t?!1:e.equals(t)}get hsla(){return this._hsla?this._hsla:zm.fromRGBA(this.rgba)}get hsva(){return this._hsva?this._hsva:_p.fromRGBA(this.rgba)}constructor(e){if(e)if(e instanceof Ut)this.rgba=e;else if(e instanceof zm)this._hsla=e,this.rgba=zm.toRGBA(e);else if(e instanceof _p)this._hsva=e,this.rgba=_p.toRGBA(e);else throw new Error("Invalid color ctor argument");else throw new Error("Color needs a value")}equals(e){return!!e&&Ut.equals(this.rgba,e.rgba)&&zm.equals(this.hsla,e.hsla)&&_p.equals(this.hsva,e.hsva)}getRelativeLuminance(){let e=n._relativeLuminanceForComponent(this.rgba.r),t=n._relativeLuminanceForComponent(this.rgba.g),i=n._relativeLuminanceForComponent(this.rgba.b),o=.2126*e+.7152*t+.0722*i;return Hx(o,4)}static _relativeLuminanceForComponent(e){let t=e/255;return t<=.03928?t/12.92:Math.pow((t+.055)/1.055,2.4)}isLighter(){return(this.rgba.r*299+this.rgba.g*587+this.rgba.b*114)/1e3>=128}isLighterThan(e){let t=this.getRelativeLuminance(),i=e.getRelativeLuminance();return t>i}isDarkerThan(e){let t=this.getRelativeLuminance(),i=e.getRelativeLuminance();return t0)for(let o of i){let r=o.filter(c=>c!==void 0),s=r[1],a=r[2];if(!a)continue;let l;if(s==="rgb"){let c=/^\(\s*(25[0-5]|2[0-4][0-9]|1[0-9]{2}|[1-9][0-9]|[0-9])\s*,\s*(25[0-5]|2[0-4][0-9]|1[0-9]{2}|[1-9][0-9]|[0-9])\s*,\s*(25[0-5]|2[0-4][0-9]|1[0-9]{2}|[1-9][0-9]|[0-9])\s*\)$/gm;l=oRe(WA(n,o),HA(a,c),!1)}else if(s==="rgba"){let c=/^\(\s*(25[0-5]|2[0-4][0-9]|1[0-9]{2}|[1-9][0-9]|[0-9])\s*,\s*(25[0-5]|2[0-4][0-9]|1[0-9]{2}|[1-9][0-9]|[0-9])\s*,\s*(25[0-5]|2[0-4][0-9]|1[0-9]{2}|[1-9][0-9]|[0-9])\s*,\s*(0[.][0-9]+|[.][0-9]+|[01][.]|[01])\s*\)$/gm;l=oRe(WA(n,o),HA(a,c),!0)}else if(s==="hsl"){let c=/^\(\s*(36[0]|3[0-5][0-9]|[12][0-9][0-9]|[1-9]?[0-9])\s*,\s*(100|\d{1,2}[.]\d*|\d{1,2})%\s*,\s*(100|\d{1,2}[.]\d*|\d{1,2})%\s*\)$/gm;l=rRe(WA(n,o),HA(a,c),!1)}else if(s==="hsla"){let c=/^\(\s*(36[0]|3[0-5][0-9]|[12][0-9][0-9]|[1-9]?[0-9])\s*,\s*(100|\d{1,2}[.]\d*|\d{1,2})%\s*,\s*(100|\d{1,2}[.]\d*|\d{1,2})%\s*,\s*(0[.][0-9]+|[.][0-9]+|[01][.]|[01])\s*\)$/gm;l=rRe(WA(n,o),HA(a,c),!0)}else s==="#"&&(l=Tst(WA(n,o),s+a));l&&e.push(l)}return e}function aRe(n){return!n||typeof n.getValue!="function"||typeof n.positionAt!="function"?[]:Dst(n)}var lRe=k(()=>{vo()});function dRe(n,e){let t=[];if(e.findRegionSectionHeaders&&e.foldingRules?.markers){let i=Rst(n,e);t=t.concat(i)}if(e.findMarkSectionHeaders){let i=Ast(n);t=t.concat(i)}return t}function Rst(n,e){let t=[],i=n.getLineCount();for(let o=1;o<=i;o++){let r=n.getLineContent(o),s=r.match(e.foldingRules.markers.start);if(s){let a={startLineNumber:o,startColumn:s[0].length+1,endLineNumber:o,endColumn:r.length+1};if(a.endColumn>a.startColumn){let l={range:a,...uRe(r.substring(s[0].length)),shouldBeInComments:!1};(l.text||l.hasSeparatorLine)&&t.push(l)}}}return t}function Ast(n){let e=[],t=n.getLineCount();for(let i=1;i<=t;i++){let o=n.getLineContent(i);Mst(o,i,e)}return e}function Mst(n,e,t){cRe.lastIndex=0;let i=cRe.exec(n);if(i){let o=i.indices[1][0]+1,r=i.indices[1][1]+1,s={startLineNumber:e,startColumn:o,endLineNumber:e,endColumn:r};if(s.endColumn>s.startColumn){let a={range:s,...uRe(i[1]),shouldBeInComments:!0};(a.text||a.hasSeparatorLine)&&t.push(a)}}}function uRe(n){n=n.trim();let e=n.startsWith("-");return n=n.replace(Nst,""),{text:n,hasSeparatorLine:e}}var cRe,Nst,hRe=k(()=>{cRe=new RegExp("\\bMARK:\\s*(.*)$","d"),Nst=/^-+|-+$/g});var G6,Y6,Z6,Nre=k(()=>{at();IA();G6=class{constructor(e){this.values=e,this.prefixSum=new Uint32Array(e.length),this.prefixSumValidIndex=new Int32Array(1),this.prefixSumValidIndex[0]=-1}insertValues(e,t){e=j1(e);let i=this.values,o=this.prefixSum,r=t.length;return r===0?!1:(this.values=new Uint32Array(i.length+r),this.values.set(i.subarray(0,e),0),this.values.set(i.subarray(e),e+r),this.values.set(t,e),e-1=0&&this.prefixSum.set(o.subarray(0,this.prefixSumValidIndex[0]+1)),!0)}setValue(e,t){return e=j1(e),t=j1(t),this.values[e]===t?!1:(this.values[e]=t,e-1=i.length)return!1;let r=i.length-e;return t>=r&&(t=r),t===0?!1:(this.values=new Uint32Array(i.length-t),this.values.set(i.subarray(0,e),0),this.values.set(i.subarray(e+t),e),this.prefixSum=new Uint32Array(this.values.length),e-1=0&&this.prefixSum.set(o.subarray(0,this.prefixSumValidIndex[0]+1)),!0)}getTotalSum(){return this.values.length===0?0:this._getPrefixSum(this.values.length-1)}getPrefixSum(e){return e<0?0:(e=j1(e),this._getPrefixSum(e))}_getPrefixSum(e){if(e<=this.prefixSumValidIndex[0])return this.prefixSum[e];let t=this.prefixSumValidIndex[0]+1;t===0&&(this.prefixSum[0]=this.values[0],t++),e>=this.values.length&&(e=this.values.length-1);for(let i=t;i<=e;i++)this.prefixSum[i]=this.prefixSum[i-1]+this.values[i];return this.prefixSumValidIndex[0]=Math.max(this.prefixSumValidIndex[0],e),this.prefixSum[e]}getIndexOf(e){e=Math.floor(e),this.getTotalSum();let t=0,i=this.values.length-1,o=0,r=0,s=0;for(;t<=i;)if(o=t+(i-t)/2|0,r=this.prefixSum[o],s=r-this.values[o],e=r)t=o+1;else break;return new Z6(o,e-s)}},Y6=class{constructor(e){this._values=e,this._isValid=!1,this._validEndIndex=-1,this._prefixSum=[],this._indexBySum=[]}getTotalSum(){return this._ensureValid(),this._indexBySum.length}getPrefixSum(e){return this._ensureValid(),e===0?0:this._prefixSum[e-1]}getIndexOf(e){this._ensureValid();let t=this._indexBySum[e],i=t>0?this._prefixSum[t-1]:0;return new Z6(t,e-i)}removeValues(e,t){this._values.splice(e,t),this._invalidate(e)}insertValues(e,t){this._values=Jv(this._values,e,t),this._invalidate(e)}_invalidate(e){this._isValid=!1,this._validEndIndex=Math.min(this._validEndIndex,e-1)}_ensureValid(){if(!this._isValid){for(let e=this._validEndIndex+1,t=this._values.length;e0?this._prefixSum[e-1]:0;this._prefixSum[e]=o+i;for(let r=0;r{Qe();qe();Nre();X6=class{constructor(e,t,i,o){this._uri=e,this._lines=t,this._eol=i,this._versionId=o,this._lineStarts=null,this._cachedTextValue=null}dispose(){this._lines.length=0}get version(){return this._versionId}getText(){return this._cachedTextValue===null&&(this._cachedTextValue=this._lines.join(this._eol)),this._cachedTextValue}onEvents(e){e.eol&&e.eol!==this._eol&&(this._eol=e.eol,this._lineStarts=null);let t=e.changes;for(let i of t)this._acceptDeleteRange(i.range),this._acceptInsertText(new P(i.range.startLineNumber,i.range.startColumn),i.text);this._versionId=e.versionId,this._cachedTextValue=null}_ensureLineStarts(){if(!this._lineStarts){let e=this._eol.length,t=this._lines.length,i=new Uint32Array(t);for(let o=0;o{ft();j();Ai();qe();we();h1();fRe();pRe=60*1e3,Q6=class extends D{constructor(e,t,i=!1){if(super(),this._syncedModels=Object.create(null),this._syncedModelsLastUsedTime=Object.create(null),this._proxy=e,this._modelService=t,!i){let o=new vx;o.cancelAndSet(()=>this._checkStopModelSync(),Math.round(pRe/2)),this._register(o)}}dispose(){for(let e in this._syncedModels)Yt(this._syncedModels[e]);this._syncedModels=Object.create(null),this._syncedModelsLastUsedTime=Object.create(null),super.dispose()}ensureSyncedResources(e,t=!1){for(let i of e){let o=i.toString();this._syncedModels[o]||this._beginModelSync(i,t),this._syncedModels[o]&&(this._syncedModelsLastUsedTime[o]=new Date().getTime())}}_checkStopModelSync(){let e=new Date().getTime(),t=[];for(let i in this._syncedModelsLastUsedTime)e-this._syncedModelsLastUsedTime[i]>pRe&&t.push(i);for(let i of t)this._stopModelSync(i)}_beginModelSync(e,t){let i=this._modelService.getModel(e);if(!i||!t&&i.isTooLargeForSyncing())return;let o=e.toString();this._proxy.$acceptNewModel({url:i.uri.toString(),lines:i.getLinesContent(),EOL:i.getEOL(),versionId:i.getVersionId()});let r=new H;r.add(i.onDidChangeContent(s=>{this._proxy.$acceptModelChanged(o.toString(),s)})),r.add(i.onWillDispose(()=>{this._stopModelSync(o)})),r.add(ge(()=>{this._proxy.$acceptRemovedModel(o)})),this._syncedModels[o]=r}_stopModelSync(e){let t=this._syncedModels[e];delete this._syncedModels[e],delete this._syncedModelsLastUsedTime[e],Yt(t)}},J6=class{constructor(){this._models=Object.create(null)}getModel(e){return this._models[e]}getModels(){let e=[];return Object.keys(this._models).forEach(t=>e.push(this._models[t])),e}$acceptNewModel(e){this._models[e.url]=new Rre(Ee.parse(e.url),e.lines,e.EOL,e.versionId)}$acceptModelChanged(e,t){if(!this._models[e])return;this._models[e].onEvents(t)}$acceptRemovedModel(e){this._models[e]&&delete this._models[e]}},Rre=class extends X6{get uri(){return this._uri}get eol(){return this._eol}getValue(){return this.getText()}findMatches(e){let t=[];for(let i=0;ithis._lines.length)t=this._lines.length,i=this._lines[t-1].length+1,o=!0;else{let r=this._lines[t-1].length+1;i<1?(i=1,o=!0):i>r&&(i=r,o=!0)}return o?{lineNumber:t,column:i}:e}}});var Pst,Mre,Z1,mRe=k(()=>{LA();we();SNe();kNe();Ene();ure();kl();gre();nRe();ec();ds();lRe();hRe();Are();Pst=!0,Mre=class{constructor(){this._workerTextModelSyncServer=new J6}dispose(){}_getModel(e){return this._workerTextModelSyncServer.getModel(e)}_getModels(){return this._workerTextModelSyncServer.getModels()}$acceptNewModel(e){this._workerTextModelSyncServer.$acceptNewModel(e)}$acceptModelChanged(e,t){this._workerTextModelSyncServer.$acceptModelChanged(e,t)}$acceptRemovedModel(e){this._workerTextModelSyncServer.$acceptRemovedModel(e)}async $computeUnicodeHighlights(e,t,i){let o=this._getModel(e);return o?G1.computeUnicodeHighlights(o,t,i):{ranges:[],hasMore:!1,ambiguousCharacterCount:0,invisibleCharacterCount:0,nonBasicAsciiCharacterCount:0}}async $findSectionHeaders(e,t){let i=this._getModel(e);return i?dRe(i,t):[]}async $computeDiff(e,t,i,o){let r=this._getModel(e),s=this._getModel(t);return!r||!s?null:Z1.computeDiff(r,s,i,o)}static computeDiff(e,t,i,o){let r=o==="advanced"?Tre.getDefault():Tre.getLegacy(),s=e.getLinesContent(),a=t.getLinesContent(),l=r.computeDiff(s,a,i),c=l.changes.length>0?!1:this._modelsAreIdentical(e,t);function d(u){return u.map(h=>[h.original.startLineNumber,h.original.endLineNumberExclusive,h.modified.startLineNumber,h.modified.endLineNumberExclusive,h.innerChanges?.map(f=>[f.originalRange.startLineNumber,f.originalRange.startColumn,f.originalRange.endLineNumber,f.originalRange.endColumn,f.modifiedRange.startLineNumber,f.modifiedRange.startColumn,f.modifiedRange.endLineNumber,f.modifiedRange.endColumn])])}return{identical:c,quitEarly:l.hitTimeout,changes:d(l.changes),moves:l.moves.map(u=>[u.lineRangeMapping.original.startLineNumber,u.lineRangeMapping.original.endLineNumberExclusive,u.lineRangeMapping.modified.startLineNumber,u.lineRangeMapping.modified.endLineNumberExclusive,d(u.changes)])}}static _modelsAreIdentical(e,t){let i=e.getLineCount(),o=t.getLineCount();if(i!==o)return!1;for(let r=1;r<=i;r++){let s=e.getLineContent(r),a=t.getLineContent(r);if(s!==a)return!1}return!0}static{this._diffLimit=1e5}async $computeMoreMinimalEdits(e,t,i){let o=this._getModel(e);if(!o)return t;let r=[],s;t=t.slice(0).sort((l,c)=>{if(l.range&&c.range)return S.compareRangesUsingStarts(l.range,c.range);let d=l.range?0:1,u=c.range?0:1;return d-u});let a=0;for(let l=1;lZ1._diffLimit){r.push({range:l,text:c});continue}let h=yNe(u,c,i),f=o.offsetAt(S.lift(l).getStartPosition());for(let p of h){let g=o.positionAt(f+p.originalStart),_=o.positionAt(f+p.originalStart+p.originalLength),b={text:c.substr(p.modifiedStart,p.modifiedLength),range:{startLineNumber:g.lineNumber,startColumn:g.column,endLineNumber:_.lineNumber,endColumn:_.column}};o.getValueInRange(b.range)!==b.text&&r.push(b)}}return typeof s=="number"&&r.push({eol:s,text:"",range:{startLineNumber:0,startColumn:0,endLineNumber:0,endColumn:0}}),r}async $computeLinks(e){let t=this._getModel(e);return t?CNe(t):null}async $computeDefaultDocumentColors(e){let t=this._getModel(e);return t?aRe(t):null}static{this._suggestionsLimit=1e4}async $textualSuggest(e,t,i,o){let r=new cn,s=new RegExp(i,o),a=new Set;e:for(let l of e){let c=this._getModel(l);if(c){for(let d of c.words(s))if(!(d===t||!isNaN(Number(d)))&&(a.add(d),a.size>Z1._suggestionsLimit))break e}}return{words:Array.from(a),duration:r.elapsed()}}async $computeWordRanges(e,t,i,o){let r=this._getModel(e);if(!r)return Object.create(null);let s=new RegExp(i,o),a=Object.create(null);for(let l=t.startLineNumber;lthis._host.$fhr(a,l)),getMirrorModels:()=>this._getModels()};return this._foreignModuleFactory?(this._foreignModule=this._foreignModuleFactory(s,t),Promise.resolve(CR(this._foreignModule))):new Promise((a,l)=>{let c=d=>{this._foreignModule=d.create(s,t),a(CR(this._foreignModule))};Pst?import(`${U_.asBrowserUri(`${e}.js`).toString(!0)}`).then(c).catch(l):u1e([`${e}`],c,l)})}$fmr(e,t){if(!this._foreignModule||typeof this._foreignModule[e]!="function")return Promise.reject(new Error("Missing requestHandler or method: "+e));try{return Promise.resolve(this._foreignModule[e].apply(this._foreignModule,t))}catch(i){return Promise.reject(i)}}};typeof importScripts=="function"&&(globalThis.monaco=eB())});var X1,e9,zA=k(()=>{Fe();X1=We("textResourceConfigurationService"),e9=We("textResourcePropertiesService")});var le,Qt=k(()=>{Fe();le=We("ILanguageFeaturesService")});function J1(n,e){let t=n.getModel(e);return!(!t||t.isTooLargeForSyncing())}var Bre,Q1,gRe,t9,Pre,Ore,Fre,VA,Wre=k(()=>{ft();j();Toe();XDe();we();Ko();mRe();va();zA();at();ac();kl();je();Qt();W6();Bm();Nl();Il();ke();Are();ure();Bre=function(n,e,t,i){var o=arguments.length,r=o<3?e:i===null?i=Object.getOwnPropertyDescriptor(e,t):i,s;if(typeof Reflect=="object"&&typeof Reflect.decorate=="function")r=Reflect.decorate(n,e,t,i);else for(var a=n.length-1;a>=0;a--)(s=n[a])&&(r=(o<3?s(r):o>3?s(e,t,r):s(e,t))||r);return o>3&&r&&Object.defineProperty(e,t,r),r},Q1=function(n,e){return function(t,i){e(t,i,n)}},gRe=5*60*1e3;t9=class extends D{constructor(e,t,i,o,r,s){super(),this._languageConfigurationService=r,this._modelService=t,this._workerManager=this._register(new Ore(e,this._modelService)),this._logService=o,this._register(s.linkProvider.register({language:"*",hasAccessToAllModels:!0},{provideLinks:async(a,l)=>{if(!J1(this._modelService,a.uri))return Promise.resolve({links:[]});let d=await(await this._workerWithResources([a.uri])).$computeLinks(a.uri.toString());return d&&{links:d}}})),this._register(s.completionProvider.register("*",new Pre(this._workerManager,i,this._modelService,this._languageConfigurationService)))}dispose(){super.dispose()}canComputeUnicodeHighlights(e){return J1(this._modelService,e)}async computedUnicodeHighlights(e,t,i){return(await this._workerWithResources([e])).$computeUnicodeHighlights(e.toString(),t,i)}async computeDiff(e,t,i,o){let s=await(await this._workerWithResources([e,t],!0)).$computeDiff(e.toString(),t.toString(),i,o);if(!s)return null;return{identical:s.identical,quitEarly:s.quitEarly,changes:l(s.changes),moves:s.moves.map(c=>new LL(new ya(new ut(c[0],c[1]),new ut(c[2],c[3])),l(c[4])))};function l(c){return c.map(d=>new Rl(new ut(d[0],d[1]),new ut(d[2],d[3]),d[4]?.map(u=>new wa(new S(u[0],u[1],u[2],u[3]),new S(u[4],u[5],u[6],u[7])))))}}async computeMoreMinimalEdits(e,t,i=!1){if(So(t)){if(!J1(this._modelService,e))return Promise.resolve(t);let o=cn.create(),r=this._workerWithResources([e]).then(s=>s.$computeMoreMinimalEdits(e.toString(),t,i));return r.finally(()=>this._logService.trace("FORMAT#computeMoreMinimalEdits",e.toString(!0),o.elapsed())),Promise.race([r,oc(1e3).then(()=>t)])}else return Promise.resolve(void 0)}canNavigateValueSet(e){return J1(this._modelService,e)}async navigateValueSet(e,t,i){let o=this._modelService.getModel(e);if(!o)return null;let r=this._languageConfigurationService.getLanguageConfiguration(o.getLanguageId()).getWordDefinition(),s=r.source,a=r.flags;return(await this._workerWithResources([e])).$navigateValueSet(e.toString(),t,i,s,a)}canComputeWordRanges(e){return J1(this._modelService,e)}async computeWordRanges(e,t){let i=this._modelService.getModel(e);if(!i)return Promise.resolve(null);let o=this._languageConfigurationService.getLanguageConfiguration(i.getLanguageId()).getWordDefinition(),r=o.source,s=o.flags;return(await this._workerWithResources([e])).$computeWordRanges(e.toString(),t,r,s)}async findSectionHeaders(e,t){return(await this._workerWithResources([e])).$findSectionHeaders(e.toString(),t)}async computeDefaultDocumentColors(e){return(await this._workerWithResources([e])).$computeDefaultDocumentColors(e.toString())}async _workerWithResources(e,t=!1){return await(await this._workerManager.withWorker()).workerWithSyncedResources(e,t)}};t9=Bre([Q1(1,di),Q1(2,X1),Q1(3,Bn),Q1(4,ti),Q1(5,le)],t9);Pre=class{constructor(e,t,i,o){this.languageConfigurationService=o,this._debugDisplayName="wordbasedCompletions",this._workerManager=e,this._configurationService=t,this._modelService=i}async provideCompletionItems(e,t){let i=this._configurationService.getValue(e.uri,t,"editor");if(i.wordBasedSuggestions==="off")return;let o=[];if(i.wordBasedSuggestions==="currentDocument")J1(this._modelService,e.uri)&&o.push(e.uri);else for(let u of this._modelService.getModels())J1(this._modelService,u.uri)&&(u===e?o.unshift(u.uri):(i.wordBasedSuggestions==="allDocuments"||u.getLanguageId()===e.getLanguageId())&&o.push(u.uri));if(o.length===0)return;let r=this.languageConfigurationService.getLanguageConfiguration(e.getLanguageId()).getWordDefinition(),s=e.getWordAtPosition(t),a=s?new S(t.lineNumber,s.startColumn,t.lineNumber,s.endColumn):S.fromPositions(t),l=a.setEndPosition(t.lineNumber,t.column),d=await(await this._workerManager.withWorker()).textualSuggest(o,s?.word,r);if(d)return{duration:d.duration,suggestions:d.words.map(u=>({kind:18,label:u,insertText:u,range:{insert:l,replace:a}}))}}},Ore=class extends D{constructor(e,t){super(),this._workerDescriptor=e,this._modelService=t,this._editorWorkerClient=null,this._lastWorkerUsedTime=new Date().getTime(),this._register(new yx).cancelAndSet(()=>this._checkStopIdleWorker(),Math.round(gRe/2),ri),this._register(this._modelService.onModelRemoved(o=>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>gRe&&(this._editorWorkerClient.dispose(),this._editorWorkerClient=null)}withWorker(){return this._lastWorkerUsedTime=new Date().getTime(),this._editorWorkerClient||(this._editorWorkerClient=new VA(this._workerDescriptor,!1,this._modelService)),Promise.resolve(this._editorWorkerClient)}};Ore=Bre([Q1(1,di)],Ore);Fre=class{constructor(e){this._instance=e,this.proxy=this._instance}dispose(){this._instance.dispose()}setChannel(e,t){throw new Error("Not supported")}},VA=class extends D{constructor(e,t,i){super(),this._workerDescriptor=e,this._disposed=!1,this._modelService=i,this._keepIdleModels=t,this._worker=null,this._modelManager=null}fhr(e,t){throw new Error("Not implemented!")}_getOrCreateWorker(){if(!this._worker)try{this._worker=this._register(ZDe(this._workerDescriptor)),TA.setChannel(this._worker,this._createEditorWorkerHost())}catch(e){xA(e),this._worker=this._createFallbackLocalWorker()}return this._worker}async _getProxy(){try{let e=this._getOrCreateWorker().proxy;return await e.$ping(),e}catch(e){return xA(e),this._worker=this._createFallbackLocalWorker(),this._worker.proxy}}_createFallbackLocalWorker(){return new Fre(new Z1(this._createEditorWorkerHost(),null))}_createEditorWorkerHost(){return{$fhr:(e,t)=>this.fhr(e,t)}}_getOrCreateModelManager(e){return this._modelManager||(this._modelManager=this._register(new Q6(e,this._modelService,this._keepIdleModels))),this._modelManager}async workerWithSyncedResources(e,t=!1){if(this._disposed)return Promise.reject(cTe());let i=await this._getProxy();return this._getOrCreateModelManager(i).ensureSyncedResources(e,t),i}async textualSuggest(e,t,i){let o=await this.workerWithSyncedResources(e),r=i.source,s=i.flags;return o.$textualSuggest(e.map(a=>a.toString()),t,r,s)}dispose(){super.dispose(),this._disposed=!0}};VA=Bre([Q1(2,di)],VA)});function nl(n){return n===Md.HIGH_CONTRAST_DARK||n===Md.HIGH_CONTRAST_LIGHT}function Vm(n){return n===Md.DARK||n===Md.HIGH_CONTRAST_DARK}var Md,wf=k(()=>{(function(n){n.DARK="dark",n.LIGHT="light",n.HIGH_CONTRAST_DARK="hcDark",n.HIGH_CONTRAST_LIGHT="hcLight"})(Md||(Md={}))});function vn(n){return{id:n}}function UA(n){switch(n){case Md.DARK:return"vs-dark";case Md.HIGH_CONTRAST_DARK:return"hc-black";case Md.HIGH_CONTRAST_LIGHT:return"hc-light";default:return"vs"}}function wr(n){return _Re.onColorThemeChange(n)}var Vi,zre,Hre,_Re,i9,Yi=k(()=>{Ie();j();Fe();br();wf();Vi=We("themeService");zre={ThemingContribution:"base.contributions.theming"},Hre=class{constructor(){this.themingParticipants=[],this.themingParticipants=[],this.onThemingParticipantAddedEmitter=new A}onColorThemeChange(e){return this.themingParticipants.push(e),this.onThemingParticipantAddedEmitter.fire(e),ge(()=>{let t=this.themingParticipants.indexOf(e);this.themingParticipants.splice(t,1)})}getThemingParticipants(){return this.themingParticipants}},_Re=new Hre;ei.add(zre.ThemingContribution,_Re);i9=class extends D{constructor(e){super(),this.themeService=e,this.theme=e.getColorTheme(),this._register(this.themeService.onDidColorThemeChange(t=>this.onThemeChange(t)))}onThemeChange(e){this.theme=e,this.updateStyles()}updateStyles(){}}});var Ost,Fst,n9,bRe=k(()=>{Ie();j();du();Yi();Ost=function(n,e,t,i){var o=arguments.length,r=o<3?e:i===null?i=Object.getOwnPropertyDescriptor(e,t):i,s;if(typeof Reflect=="object"&&typeof Reflect.decorate=="function")r=Reflect.decorate(n,e,t,i);else for(var a=n.length-1;a>=0;a--)(s=n[a])&&(r=(o<3?s(r):o>3?s(e,t,r):s(e,t))||r);return o>3&&r&&Object.defineProperty(e,t,r),r},Fst=function(n,e){return function(t,i){e(t,i,n)}},n9=class extends D{constructor(e){super(),this._themeService=e,this._onWillCreateCodeEditor=this._register(new A),this._onCodeEditorAdd=this._register(new A),this.onCodeEditorAdd=this._onCodeEditorAdd.event,this._onCodeEditorRemove=this._register(new A),this.onCodeEditorRemove=this._onCodeEditorRemove.event,this._onWillCreateDiffEditor=this._register(new A),this._onDiffEditorAdd=this._register(new A),this.onDiffEditorAdd=this._onDiffEditorAdd.event,this._onDiffEditorRemove=this._register(new A),this.onDiffEditorRemove=this._onDiffEditorRemove.event,this._decorationOptionProviders=new Map,this._codeEditorOpenHandlers=new go,this._modelProperties=new Map,this._codeEditors=Object.create(null),this._diffEditors=Object.create(null),this._globalStyleSheet=null}willCreateCodeEditor(){this._onWillCreateCodeEditor.fire()}addCodeEditor(e){this._codeEditors[e.getId()]=e,this._onCodeEditorAdd.fire(e)}removeCodeEditor(e){delete this._codeEditors[e.getId()]&&this._onCodeEditorRemove.fire(e)}listCodeEditors(){return Object.keys(this._codeEditors).map(e=>this._codeEditors[e])}willCreateDiffEditor(){this._onWillCreateDiffEditor.fire()}addDiffEditor(e){this._diffEditors[e.getId()]=e,this._onDiffEditorAdd.fire(e)}listDiffEditors(){return Object.keys(this._diffEditors).map(e=>this._diffEditors[e])}getFocusedCodeEditor(){let e=null,t=this.listCodeEditors();for(let i of t){if(i.hasTextFocus())return i;i.hasWidgetFocus()&&(e=i)}return e}removeDecorationType(e){let t=this._decorationOptionProviders.get(e);t&&(t.refCount--,t.refCount<=0&&(this._decorationOptionProviders.delete(e),t.dispose(),this.listCodeEditors().forEach(i=>i.removeDecorationsByType(e))))}setModelProperty(e,t,i){let o=e.toString(),r;this._modelProperties.has(o)?r=this._modelProperties.get(o):(r=new Map,this._modelProperties.set(o,r)),r.set(t,i)}getModelProperty(e,t){let i=e.toString();if(this._modelProperties.has(i))return this._modelProperties.get(i).get(t)}async openCodeEditor(e,t,i){for(let o of this._codeEditorOpenHandlers){let r=await o(e,t,i);if(r!==null)return r}return null}registerCodeEditorOpenHandler(e){let t=this._codeEditorOpenHandlers.unshift(e);return ge(t)}};n9=Ost([Fst(0,Vi)],n9)});var Bst,vRe,$A,Vre=k(()=>{ke();ds();bRe();Po();it();Xs();Yi();Bst=function(n,e,t,i){var o=arguments.length,r=o<3?e:i===null?i=Object.getOwnPropertyDescriptor(e,t):i,s;if(typeof Reflect=="object"&&typeof Reflect.decorate=="function")r=Reflect.decorate(n,e,t,i);else for(var a=n.length-1;a>=0;a--)(s=n[a])&&(r=(o<3?s(r):o>3?s(e,t,r):s(e,t))||r);return o>3&&r&&Object.defineProperty(e,t,r),r},vRe=function(n,e){return function(t,i){e(t,i,n)}},$A=class extends n9{constructor(e,t){super(t),this._register(this.onCodeEditorAdd(()=>this._checkContextKey())),this._register(this.onCodeEditorRemove(()=>this._checkContextKey())),this._editorIsOpen=e.createKey("editorIsOpen",!1),this._activeCodeEditor=null,this._register(this.registerCodeEditorOpenHandler(async(i,o,r)=>o?this.doOpenEditor(o,i):null))}_checkContextKey(){let e=!1;for(let t of this.listCodeEditors())if(!t.isSimpleWidget){e=!0;break}this._editorIsOpen.set(e)}setActiveCodeEditor(e){this._activeCodeEditor=e}getActiveCodeEditor(){return this._activeCodeEditor}doOpenEditor(e,t){if(!this.findModel(e,t.resource)){if(t.resource){let r=t.resource.scheme;if(r===rt.http||r===rt.https)return HB(t.resource.toString()),e}return null}let o=t.options?t.options.selection:null;if(o)if(typeof o.endLineNumber=="number"&&typeof o.endColumn=="number")e.setSelection(o),e.revealRangeInCenter(o,1);else{let r={lineNumber:o.startLineNumber,column:o.startColumn};e.setPosition(r),e.revealPositionInCenter(r,1)}return e}findModel(e,t){let i=e.getModel();return i&&i.uri.toString()!==t.toString()?null:i}};$A=Bst([vRe(0,Le),vRe(1,Vi)],$A);Ct(xt,$A,0)});var Uc,nb=k(()=>{Fe();Uc=We("layoutService")});var xRe,wRe,o9,r9,Ure=k(()=>{ke();Il();at();Ie();Po();Xs();nb();xRe=function(n,e,t,i){var o=arguments.length,r=o<3?e:i===null?i=Object.getOwnPropertyDescriptor(e,t):i,s;if(typeof Reflect=="object"&&typeof Reflect.decorate=="function")r=Reflect.decorate(n,e,t,i);else for(var a=n.length-1;a>=0;a--)(s=n[a])&&(r=(o<3?s(r):o>3?s(e,t,r):s(e,t))||r);return o>3&&r&&Object.defineProperty(e,t,r),r},wRe=function(n,e){return function(t,i){e(t,i,n)}},o9=class{get mainContainer(){return Wk(this._codeEditorService.listCodeEditors())?.getContainerDomNode()??ri.document.body}get activeContainer(){return(this._codeEditorService.getFocusedCodeEditor()??this._codeEditorService.getActiveCodeEditor())?.getContainerDomNode()??this.mainContainer}get mainContainerDimension(){return Wc(this.mainContainer)}get activeContainerDimension(){return Wc(this.activeContainer)}get containers(){return ns(this._codeEditorService.listCodeEditors().map(e=>e.getContainerDomNode()))}getContainer(){return this.activeContainer}whenContainerStylesLoaded(){}focus(){this._codeEditorService.getFocusedCodeEditor()?.focus()}constructor(e){this._codeEditorService=e,this.onDidLayoutMainContainer=ne.None,this.onDidLayoutActiveContainer=ne.None,this.onDidLayoutContainer=ne.None,this.onDidChangeActiveContainer=ne.None,this.onDidAddContainer=ne.None,this.mainContainerOffset={top:0,quickPickTop:0},this.activeContainerOffset={top:0,quickPickTop:0}}};o9=xRe([wRe(0,xt)],o9);r9=class extends o9{get mainContainer(){return this._container}constructor(e,t){super(t),this._container=e}};r9=xRe([wRe(1,xt)],r9);Ct(Uc,o9,1)});var jA,Mn,ob=k(()=>{Qe();(function(n){n[n.Ignore=0]="Ignore",n[n.Info=1]="Info",n[n.Warning=2]="Warning",n[n.Error=3]="Error"})(jA||(jA={}));(function(n){let e="error",t="warning",i="warn",o="info",r="ignore";function s(l){return l?z_(e,l)?n.Error:z_(t,l)||z_(i,l)?n.Warning:z_(o,l)?n.Info:n.Ignore:n.Ignore}n.fromValue=s;function a(l){switch(l){case n.Error:return e;case n.Warning:return t;case n.Info:return o;default:return r}}n.toString=a})(jA||(jA={}));Mn=jA});var Um,AL=k(()=>{Fe();Um=We("dialogService")});var zx,Di,s9,ea=k(()=>{ob();Fe();zx=Mn,Di=We("notificationService"),s9=class{}});var ML,qA,a9,Vx,l9=k(()=>{Fe();ML=We("undoRedoService"),qA=class{constructor(e,t){this.resource=e,this.elements=t}},a9=class n{static{this._ID=0}constructor(){this.id=n._ID++,this.order=1}nextOrder(){return this.id===0?0:this.order++}static{this.None=new n}},Vx=class n{static{this._ID=0}constructor(){this.id=n._ID++,this.order=1}nextOrder(){return this.id===0?0:this.order++}static{this.None=new n}}});function c9(n){return n.scheme===rt.file?n.fsPath:n.path}var Wst,yRe,PL,CRe,OL,d9,u9,$re,h9,KA,SRe,jre,FL,kRe=k(()=>{je();j();ds();ob();pe();AL();Xs();ea();l9();Wst=function(n,e,t,i){var o=arguments.length,r=o<3?e:i===null?i=Object.getOwnPropertyDescriptor(e,t):i,s;if(typeof Reflect=="object"&&typeof Reflect.decorate=="function")r=Reflect.decorate(n,e,t,i);else for(var a=n.length-1;a>=0;a--)(s=n[a])&&(r=(o<3?s(r):o>3?s(e,t,r):s(e,t))||r);return o>3&&r&&Object.defineProperty(e,t,r),r},yRe=function(n,e){return function(t,i){e(t,i,n)}},PL=!1;CRe=0,OL=class{constructor(e,t,i,o,r,s,a){this.id=++CRe,this.type=0,this.actual=e,this.label=e.label,this.confirmBeforeUndo=e.confirmBeforeUndo||!1,this.resourceLabel=t,this.strResource=i,this.resourceLabels=[this.resourceLabel],this.strResources=[this.strResource],this.groupId=o,this.groupOrder=r,this.sourceId=s,this.sourceOrder=a,this.isValid=!0}setValid(e){this.isValid=e}toString(){return`[id:${this.id}] [group:${this.groupId}] [${this.isValid?" VALID":"INVALID"}] ${this.actual.constructor.name} - ${this.actual}`}},d9=class{constructor(e,t){this.resourceLabel=e,this.reason=t}},u9=class{constructor(){this.elements=new Map}createMessage(){let e=[],t=[];for(let[,o]of this.elements)(o.reason===0?e:t).push(o.resourceLabel);let i=[];return e.length>0&&i.push(m({key:"externalRemoval",comment:["{0} is a list of filenames"]},"The following files have been closed and modified on disk: {0}.",e.join(", "))),t.length>0&&i.push(m({key:"noParallelUniverses",comment:["{0} is a list of filenames"]},"The following files have been modified in an incompatible way: {0}.",t.join(", "))),i.join(` `)}get size(){return this.elements.size}has(e){return this.elements.has(e)}set(e,t){this.elements.set(e,t)}delete(e){return this.elements.delete(e)}},$re=class{constructor(e,t,i,o,r,s,a){this.id=++CRe,this.type=1,this.actual=e,this.label=e.label,this.confirmBeforeUndo=e.confirmBeforeUndo||!1,this.resourceLabels=t,this.strResources=i,this.groupId=o,this.groupOrder=r,this.sourceId=s,this.sourceOrder=a,this.removedResources=null,this.invalidatedResources=null}canSplit(){return typeof this.actual.split=="function"}removeResource(e,t,i){this.removedResources||(this.removedResources=new u9),this.removedResources.has(t)||this.removedResources.set(t,new d9(e,i))}setValid(e,t,i){i?this.invalidatedResources&&(this.invalidatedResources.delete(t),this.invalidatedResources.size===0&&(this.invalidatedResources=null)):(this.invalidatedResources||(this.invalidatedResources=new u9),this.invalidatedResources.has(t)||this.invalidatedResources.set(t,new d9(e,0)))}toString(){return`[id:${this.id}] [group:${this.groupId}] [${this.invalidatedResources?"INVALID":" VALID"}] ${this.actual.constructor.name} - ${this.actual}`}},h9=class{constructor(e,t){this.resourceLabel=e,this.strResource=t,this._past=[],this._future=[],this.locked=!1,this.versionId=1}dispose(){for(let e of this._past)e.type===1&&e.removeResource(this.resourceLabel,this.strResource,0);for(let e of this._future)e.type===1&&e.removeResource(this.resourceLabel,this.strResource,0);this.versionId++}toString(){let e=[];e.push(`* ${this.strResource}:`);for(let t=0;t=0;t--)e.push(` * [REDO] ${this._future[t]}`);return e.join(` `)}flushAllElements(){this._past=[],this._future=[],this.versionId++}_setElementValidFlag(e,t){e.type===1?e.setValid(this.resourceLabel,this.strResource,t):e.setValid(t)}setElementsValidFlag(e,t){for(let i of this._past)t(i.actual)&&this._setElementValidFlag(i,e);for(let i of this._future)t(i.actual)&&this._setElementValidFlag(i,e)}pushElement(e){for(let t of this._future)t.type===1&&t.removeResource(this.resourceLabel,this.strResource,1);this._future=[],this._past.push(e),this.versionId++}createSnapshot(e){let t=[];for(let i=0,o=this._past.length;i=0;i--)t.push(this._future[i].id);return new qA(e,t)}restoreSnapshot(e){let t=e.elements.length,i=!0,o=0,r=-1;for(let a=0,l=this._past.length;a=t||c.id!==e.elements[o])&&(i=!1,r=0),!i&&c.type===1&&c.removeResource(this.resourceLabel,this.strResource,0)}let s=-1;for(let a=this._future.length-1;a>=0;a--,o++){let l=this._future[a];i&&(o>=t||l.id!==e.elements[o])&&(i=!1,s=a),!i&&l.type===1&&l.removeResource(this.resourceLabel,this.strResource,0)}r!==-1&&(this._past=this._past.slice(0,r)),s!==-1&&(this._future=this._future.slice(s+1)),this.versionId++}getElements(){let e=[],t=[];for(let i of this._past)e.push(i.actual);for(let i of this._future)t.push(i.actual);return{past:e,future:t}}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(e,t){for(let i=this._past.length-1;i>=0;i--)if(this._past[i]===e){t.has(this.strResource)?this._past[i]=t.get(this.strResource):this._past.splice(i,1);break}this.versionId++}splitFutureWorkspaceElement(e,t){for(let i=this._future.length-1;i>=0;i--)if(this._future[i]===e){t.has(this.strResource)?this._future[i]=t.get(this.strResource):this._future.splice(i,1);break}this.versionId++}moveBackward(e){this._past.pop(),this._future.push(e),this.versionId++}moveForward(e){this._future.pop(),this._past.push(e),this.versionId++}},KA=class{constructor(e){this.editStacks=e,this._versionIds=[];for(let t=0,i=this.editStacks.length;tt.sourceOrder)&&(t=s,i=o)}return[t,i]}canUndo(e){if(e instanceof Vx){let[,i]=this._findClosestUndoElementWithSource(e.id);return!!i}let t=this.getUriComparisonKey(e);return this._editStacks.has(t)?this._editStacks.get(t).hasPastElements():!1}_onError(e,t){Be(e);for(let i of t.strResources)this.removeElements(i);this._notificationService.error(e)}_acquireLocks(e){for(let t of e.editStacks)if(t.locked)throw new Error("Cannot acquire edit stack lock");for(let t of e.editStacks)t.locked=!0;return()=>{for(let t of e.editStacks)t.locked=!1}}_safeInvokeWithLocks(e,t,i,o,r){let s=this._acquireLocks(i),a;try{a=t()}catch(l){return s(),o.dispose(),this._onError(l,e)}return a?a.then(()=>(s(),o.dispose(),r()),l=>(s(),o.dispose(),this._onError(l,e))):(s(),o.dispose(),r())}async _invokeWorkspacePrepare(e){if(typeof e.actual.prepareUndoRedo>"u")return D.None;let t=e.actual.prepareUndoRedo();return typeof t>"u"?D.None:t}_invokeResourcePrepare(e,t){if(e.actual.type!==1||typeof e.actual.prepareUndoRedo>"u")return t(D.None);let i=e.actual.prepareUndoRedo();return i?cx(i)?t(i):i.then(o=>t(o)):t(D.None)}_getAffectedEditStacks(e){let t=[];for(let i of e.strResources)t.push(this._editStacks.get(i)||SRe);return new KA(t)}_tryToSplitAndUndo(e,t,i,o){if(t.canSplit())return this._splitPastWorkspaceElement(t,i),this._notificationService.warn(o),new FL(this._undo(e,0,!0));for(let r of t.strResources)this.removeElements(r);return this._notificationService.warn(o),new FL}_checkWorkspaceUndo(e,t,i,o){if(t.removedResources)return this._tryToSplitAndUndo(e,t,t.removedResources,m({key:"cannotWorkspaceUndo",comment:["{0} is a label for an operation. {1} is another message."]},"Could not undo '{0}' across all files. {1}",t.label,t.removedResources.createMessage()));if(o&&t.invalidatedResources)return this._tryToSplitAndUndo(e,t,t.invalidatedResources,m({key:"cannotWorkspaceUndo",comment:["{0} is a label for an operation. {1} is another message."]},"Could not undo '{0}' across all files. {1}",t.label,t.invalidatedResources.createMessage()));let r=[];for(let a of i.editStacks)a.getClosestPastElement()!==t&&r.push(a.resourceLabel);if(r.length>0)return this._tryToSplitAndUndo(e,t,null,m({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}",t.label,r.join(", ")));let s=[];for(let a of i.editStacks)a.locked&&s.push(a.resourceLabel);return s.length>0?this._tryToSplitAndUndo(e,t,null,m({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}",t.label,s.join(", "))):i.isValid()?null:this._tryToSplitAndUndo(e,t,null,m({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",t.label))}_workspaceUndo(e,t,i){let o=this._getAffectedEditStacks(t),r=this._checkWorkspaceUndo(e,t,o,!1);return r?r.returnValue:this._confirmAndExecuteWorkspaceUndo(e,t,o,i)}_isPartOfUndoGroup(e){if(!e.groupId)return!1;for(let[,t]of this._editStacks){let i=t.getClosestPastElement();if(i){if(i===e){let o=t.getSecondClosestPastElement();if(o&&o.groupId===e.groupId)return!0}if(i.groupId===e.groupId)return!0}}return!1}async _confirmAndExecuteWorkspaceUndo(e,t,i,o){if(t.canSplit()&&!this._isPartOfUndoGroup(t)){let a;(function(d){d[d.All=0]="All",d[d.This=1]="This",d[d.Cancel=2]="Cancel"})(a||(a={}));let{result:l}=await this._dialogService.prompt({type:Mn.Info,message:m("confirmWorkspace","Would you like to undo '{0}' across all files?",t.label),buttons:[{label:m({key:"ok",comment:["{0} denotes a number that is > 1, && denotes a mnemonic"]},"&&Undo in {0} Files",i.editStacks.length),run:()=>a.All},{label:m({key:"nok",comment:["&& denotes a mnemonic"]},"Undo this &&File"),run:()=>a.This}],cancelButton:{run:()=>a.Cancel}});if(l===a.Cancel)return;if(l===a.This)return this._splitPastWorkspaceElement(t,null),this._undo(e,0,!0);let c=this._checkWorkspaceUndo(e,t,i,!1);if(c)return c.returnValue;o=!0}let r;try{r=await this._invokeWorkspacePrepare(t)}catch(a){return this._onError(a,t)}let s=this._checkWorkspaceUndo(e,t,i,!0);if(s)return r.dispose(),s.returnValue;for(let a of i.editStacks)a.moveBackward(t);return this._safeInvokeWithLocks(t,()=>t.actual.undo(),i,r,()=>this._continueUndoInGroup(t.groupId,o))}_resourceUndo(e,t,i){if(!t.isValid){e.flushAllElements();return}if(e.locked){let o=m({key:"cannotResourceUndoDueToInProgressUndoRedo",comment:["{0} is a label for an operation."]},"Could not undo '{0}' because there is already an undo or redo operation running.",t.label);this._notificationService.warn(o);return}return this._invokeResourcePrepare(t,o=>(e.moveBackward(t),this._safeInvokeWithLocks(t,()=>t.actual.undo(),new KA([e]),o,()=>this._continueUndoInGroup(t.groupId,i))))}_findClosestUndoElementInGroup(e){if(!e)return[null,null];let t=null,i=null;for(let[o,r]of this._editStacks){let s=r.getClosestPastElement();s&&s.groupId===e&&(!t||s.groupOrder>t.groupOrder)&&(t=s,i=o)}return[t,i]}_continueUndoInGroup(e,t){if(!e)return;let[,i]=this._findClosestUndoElementInGroup(e);if(i)return this._undo(i,0,t)}undo(e){if(e instanceof Vx){let[,t]=this._findClosestUndoElementWithSource(e.id);return t?this._undo(t,e.id,!1):void 0}return typeof e=="string"?this._undo(e,0,!1):this._undo(this.getUriComparisonKey(e),0,!1)}_undo(e,t=0,i){if(!this._editStacks.has(e))return;let o=this._editStacks.get(e),r=o.getClosestPastElement();if(!r)return;if(r.groupId){let[a,l]=this._findClosestUndoElementInGroup(r.groupId);if(r!==a&&l)return this._undo(l,t,i)}if((r.sourceId!==t||r.confirmBeforeUndo)&&!i)return this._confirmAndContinueUndo(e,t,r);try{return r.type===1?this._workspaceUndo(e,r,i):this._resourceUndo(o,r,i)}finally{PL&&this._print("undo")}}async _confirmAndContinueUndo(e,t,i){if((await this._dialogService.confirm({message:m("confirmDifferentSource","Would you like to undo '{0}'?",i.label),primaryButton:m({key:"confirmDifferentSource.yes",comment:["&& denotes a mnemonic"]},"&&Yes"),cancelButton:m("confirmDifferentSource.no","No")})).confirmed)return this._undo(e,t,!0)}_findClosestRedoElementWithSource(e){if(!e)return[null,null];let t=null,i=null;for(let[o,r]of this._editStacks){let s=r.getClosestFutureElement();s&&s.sourceId===e&&(!t||s.sourceOrder0)return this._tryToSplitAndRedo(e,t,null,m({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}",t.label,r.join(", ")));let s=[];for(let a of i.editStacks)a.locked&&s.push(a.resourceLabel);return s.length>0?this._tryToSplitAndRedo(e,t,null,m({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}",t.label,s.join(", "))):i.isValid()?null:this._tryToSplitAndRedo(e,t,null,m({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",t.label))}_workspaceRedo(e,t){let i=this._getAffectedEditStacks(t),o=this._checkWorkspaceRedo(e,t,i,!1);return o?o.returnValue:this._executeWorkspaceRedo(e,t,i)}async _executeWorkspaceRedo(e,t,i){let o;try{o=await this._invokeWorkspacePrepare(t)}catch(s){return this._onError(s,t)}let r=this._checkWorkspaceRedo(e,t,i,!0);if(r)return o.dispose(),r.returnValue;for(let s of i.editStacks)s.moveForward(t);return this._safeInvokeWithLocks(t,()=>t.actual.redo(),i,o,()=>this._continueRedoInGroup(t.groupId))}_resourceRedo(e,t){if(!t.isValid){e.flushAllElements();return}if(e.locked){let i=m({key:"cannotResourceRedoDueToInProgressUndoRedo",comment:["{0} is a label for an operation."]},"Could not redo '{0}' because there is already an undo or redo operation running.",t.label);this._notificationService.warn(i);return}return this._invokeResourcePrepare(t,i=>(e.moveForward(t),this._safeInvokeWithLocks(t,()=>t.actual.redo(),new KA([e]),i,()=>this._continueRedoInGroup(t.groupId))))}_findClosestRedoElementInGroup(e){if(!e)return[null,null];let t=null,i=null;for(let[o,r]of this._editStacks){let s=r.getClosestFutureElement();s&&s.groupId===e&&(!t||s.groupOrder{GA=class{constructor(){this._n=1,this._val=0}update(e){return this._val=this._val+(e-this._val)/this._n,this._n+=1,this._val}get value(){return this._val}},f9=class{constructor(e){this._n=0,this._val=0,this._values=[],this._index=0,this._sum=0,this._values=new Array(e),this._values.fill(0,0,e)}update(e){let t=this._values[this._index];return this._values[this._index]=e,this._index=(this._index+1)%this._values.length,this._sum-=t,this._sum+=e,this._n{Fe();BL=We("environmentService")});var Hst,LRe,yr,m9,qre,Kre,Gre,wu=k(()=>{wx();Ds();eC();p9();Xs();Fe();ac();ds();Hst=function(n,e,t,i){var o=arguments.length,r=o<3?e:i===null?i=Object.getOwnPropertyDescriptor(e,t):i,s;if(typeof Reflect=="object"&&typeof Reflect.decorate=="function")r=Reflect.decorate(n,e,t,i);else for(var a=n.length-1;a>=0;a--)(s=n[a])&&(r=(o<3?s(r):o>3?s(e,t,r):s(e,t))||r);return o>3&&r&&Object.defineProperty(e,t,r),r},LRe=function(n,e){return function(t,i){e(t,i,n)}},yr=We("ILanguageFeatureDebounceService");(function(n){let e=new WeakMap,t=0;function i(o){let r=e.get(o);return r===void 0&&(r=++t,e.set(o,r)),r}n.of=i})(m9||(m9={}));qre=class{constructor(e){this._default=e}get(e){return this._default}update(e,t){return this._default}default(){return this._default}},Kre=class{constructor(e,t,i,o,r,s){this._logService=e,this._name=t,this._registry=i,this._default=o,this._min=r,this._max=s,this._cache=new Ts(50,.7)}_key(e){return e.id+this._registry.all(e).reduce((t,i)=>cA(m9.of(i),t),0)}get(e){let t=this._key(e),i=this._cache.get(t);return i?ps(i.value,this._min,this._max):this.default()}update(e,t){let i=this._key(e),o=this._cache.get(i);o||(o=new f9(6),this._cache.set(i,o));let r=ps(o.update(t),this._min,this._max);return L1(e.uri,"output")||this._logService.trace(`[DEBOUNCE: ${this._name}] for ${e.uri.toString()} is ${r}ms`),r}_overall(){let e=new GA;for(let[,t]of this._cache)e.update(t.value);return e.value}default(){let e=this._overall()|0||this._default;return ps(e,this._min,this._max)}},Gre=class{constructor(e,t){this._logService=e,this._data=new Map,this._isDev=t.isExtensionDevelopment||!t.isBuilt}for(e,t,i){let o=i?.min??50,r=i?.max??o**2,s=i?.key??void 0,a=`${m9.of(e)},${o}${s?","+s:""}`,l=this._data.get(a);return l||(this._isDev?(this._logService.debug(`[DEBOUNCE: ${t}] is disabled in developed mode`),l=new qre(o*1.5)):l=new Kre(this._logService,t,e,this._overallAverage()|0||o*1.5,o,r),this._data.set(a,l)),l}_overallAverage(){let e=new GA;for(let t of this._data.values())e.update(t.default());return e.value}};Gre=Hst([LRe(0,Bn),LRe(1,BL)],Gre);Ct(yr,Gre,1)});var Go,tC=k(()=>{Go=class{static getLanguageId(e){return(e&255)>>>0}static getTokenType(e){return(e&768)>>>8}static containsBalancedBrackets(e){return(e&1024)!==0}static getFontStyle(e){return(e&30720)>>>11}static getForeground(e){return(e&16744448)>>>15}static getBackground(e){return(e&4278190080)>>>24}static getClassNameFromMetadata(e){let i="mtk"+this.getForeground(e),o=this.getFontStyle(e);return o&1&&(i+=" mtki"),o&2&&(i+=" mtkb"),o&4&&(i+=" mtku"),o&8&&(i+=" mtks"),i}static getInlineStyleFromMetadata(e,t){let i=this.getForeground(e),o=this.getFontStyle(e),r=`color: ${t[i]};`;o&1&&(r+="font-style: italic;"),o&2&&(r+="font-weight: bold;");let s="";return o&4&&(s+=" underline"),o&8&&(s+=" line-through"),s&&(r+=`text-decoration:${s};`),r}static getPresentationFromMetadata(e){let t=this.getForeground(e),i=this.getFontStyle(e);return{foreground:t,italic:!!(i&1),bold:!!(i&2),underline:!!(i&4),strikethrough:!!(i&8)}}}});function yu(n){let e=0,t=0,i=0,o=0;for(let r=0,s=n.length;r{});var g9,Yre,_9,IRe=k(()=>{qe();we();iC();g9=class n{static create(e,t){return new n(e,new Yre(t))}get startLineNumber(){return this._startLineNumber}get endLineNumber(){return this._endLineNumber}constructor(e,t){this._startLineNumber=e,this._tokens=t,this._endLineNumber=this._startLineNumber+this._tokens.getMaxDeltaLine()}toString(){return this._tokens.toString(this._startLineNumber)}_updateEndLineNumber(){this._endLineNumber=this._startLineNumber+this._tokens.getMaxDeltaLine()}isEmpty(){return this._tokens.isEmpty()}getLineTokens(e){return this._startLineNumber<=e&&e<=this._endLineNumber?this._tokens.getLineTokens(e-this._startLineNumber):null}getRange(){let e=this._tokens.getRange();return e&&new S(this._startLineNumber+e.startLineNumber,e.startColumn,this._startLineNumber+e.endLineNumber,e.endColumn)}removeTokens(e){let t=e.startLineNumber-this._startLineNumber,i=e.endLineNumber-this._startLineNumber;this._startLineNumber+=this._tokens.removeTokens(t,e.startColumn-1,i,e.endColumn-1),this._updateEndLineNumber()}split(e){let t=e.startLineNumber-this._startLineNumber,i=e.endLineNumber-this._startLineNumber,[o,r,s]=this._tokens.split(t,e.startColumn-1,i,e.endColumn-1);return[new n(this._startLineNumber,o),new n(this._startLineNumber+s,r)]}applyEdit(e,t){let[i,o,r]=yu(t);this.acceptEdit(e,i,o,r,t.length>0?t.charCodeAt(0):0)}acceptEdit(e,t,i,o,r){this._acceptDeleteRange(e),this._acceptInsertText(new P(e.startLineNumber,e.startColumn),t,i,o,r),this._updateEndLineNumber()}_acceptDeleteRange(e){if(e.startLineNumber===e.endLineNumber&&e.startColumn===e.endColumn)return;let t=e.startLineNumber-this._startLineNumber,i=e.endLineNumber-this._startLineNumber;if(i<0){let r=i-t;this._startLineNumber-=r;return}let o=this._tokens.getMaxDeltaLine();if(!(t>=o+1)){if(t<0&&i>=o+1){this._startLineNumber=0,this._tokens.clear();return}if(t<0){let r=-t;this._startLineNumber-=r,this._tokens.acceptDeleteRange(e.startColumn-1,0,0,i,e.endColumn-1)}else this._tokens.acceptDeleteRange(0,t,e.startColumn-1,i,e.endColumn-1)}}_acceptInsertText(e,t,i,o,r){if(t===0&&i===0)return;let s=e.lineNumber-this._startLineNumber;if(s<0){this._startLineNumber+=t;return}let a=this._tokens.getMaxDeltaLine();s>=a+1||this._tokens.acceptInsertText(s,e.column-1,t,i,o,r)}},Yre=class n{constructor(e){this._tokens=e,this._tokenCount=e.length/4}toString(e){let t=[];for(let i=0;ie)i=o-1;else{let s=o;for(;s>t&&this._getDeltaLine(s-1)===e;)s--;let a=o;for(;ae||h===e&&p>=t)&&(he||p===e&&_>=t){if(pr?g-=r-i:g=i;else if(f===t&&p===i)if(f===o&&g>r)g-=r-i;else{d=!0;continue}else if(fr)f=t,p=i,g=p+(g-r);else{d=!0;continue}else if(f>o){if(l===0&&!d){c=a;break}f-=l}else if(f===o&&p>=r)e&&f===0&&(p+=e,g+=e),f-=l,p-=r-i,g-=r-i;else throw new Error("Not possible!");let b=4*c;s[b]=f,s[b+1]=p,s[b+2]=g,s[b+3]=_,c++}this._tokenCount=c}acceptInsertText(e,t,i,o,r,s){let a=i===0&&o===1&&(s>=48&&s<=57||s>=65&&s<=90||s>=97&&s<=122),l=this._tokens,c=this._tokenCount;for(let d=0;dd&&i[5*v]===0;)v--;if(v-1===d){let x=u;for(;x+1C)e.warnOverlappingSemanticTokens(y,C+1);else{let F=e.getMetadata(N,M,t);F!==2147483647&&(p===0&&(p=y),h[f]=y-p,h[f+1]=C,h[f+2]=E,h[f+3]=F,f+=4,g=y,_=E)}l=y,c=C,a++}f!==h.length&&(h=h.subarray(0,f));let b=g9.create(p,h);s.push(b)}return s}var zst,Zre,b9,v9,Xre,Qre,w9=k(()=>{tC();Yi();ac();IRe();fs();zst=function(n,e,t,i){var o=arguments.length,r=o<3?e:i===null?i=Object.getOwnPropertyDescriptor(e,t):i,s;if(typeof Reflect=="object"&&typeof Reflect.decorate=="function")r=Reflect.decorate(n,e,t,i);else for(var a=n.length-1;a>=0;a--)(s=n[a])&&(r=(o<3?s(r):o>3?s(e,t,r):s(e,t))||r);return o>3&&r&&Object.defineProperty(e,t,r),r},Zre=function(n,e){return function(t,i){e(t,i,n)}},b9=!1,v9=class{constructor(e,t,i,o){this._legend=e,this._themeService=t,this._languageService=i,this._logService=o,this._hasWarnedOverlappingTokens=!1,this._hasWarnedInvalidLengthTokens=!1,this._hasWarnedInvalidEditStart=!1,this._hashTable=new Qre}getMetadata(e,t,i){let o=this._languageService.languageIdCodec.encodeLanguageId(i),r=this._hashTable.get(e,t,o),s;if(r)s=r.metadata,b9&&this._logService.getLevel()===Ys.Trace&&this._logService.trace(`SemanticTokensProviderStyling [CACHED] ${e} / ${t}: foreground ${Go.getForeground(s)}, fontStyle ${Go.getFontStyle(s).toString(2)}`);else{let a=this._legend.tokenTypes[e],l=[];if(a){let c=t;for(let u=0;c>0&&u>1;b9&&c>0&&this._logService.getLevel()===Ys.Trace&&(this._logService.trace(`SemanticTokensProviderStyling: unknown token modifier index: ${t.toString(2)} for legend: ${JSON.stringify(this._legend.tokenModifiers)}`),l.push("not-in-legend"));let d=this._themeService.getColorTheme().getTokenStyleMetadata(a,l,i);if(typeof d>"u")s=2147483647;else{if(s=0,typeof d.italic<"u"){let u=(d.italic?1:0)<<11;s|=u|1}if(typeof d.bold<"u"){let u=(d.bold?2:0)<<11;s|=u|2}if(typeof d.underline<"u"){let u=(d.underline?4:0)<<11;s|=u|4}if(typeof d.strikethrough<"u"){let u=(d.strikethrough?8:0)<<11;s|=u|8}if(d.foreground){let u=d.foreground<<15;s|=u|16}s===0&&(s=2147483647)}}else b9&&this._logService.getLevel()===Ys.Trace&&this._logService.trace(`SemanticTokensProviderStyling: unknown token type index: ${e} for legend: ${JSON.stringify(this._legend.tokenTypes)}`),s=2147483647,a="not-in-legend";this._hashTable.add(e,t,o,s),b9&&this._logService.getLevel()===Ys.Trace&&this._logService.trace(`SemanticTokensProviderStyling ${e} (${a}) / ${t} (${l.join(" ")}): foreground ${Go.getForeground(s)}, fontStyle ${Go.getFontStyle(s).toString(2)}`)}return s}warnOverlappingSemanticTokens(e,t){this._hasWarnedOverlappingTokens||(this._hasWarnedOverlappingTokens=!0,this._logService.warn(`Overlapping semantic tokens detected at lineNumber ${e}, column ${t}`))}warnInvalidLengthSemanticTokens(e,t){this._hasWarnedInvalidLengthTokens||(this._hasWarnedInvalidLengthTokens=!0,this._logService.warn(`Semantic token with invalid length detected at lineNumber ${e}, column ${t}`))}warnInvalidEditStart(e,t,i,o,r){this._hasWarnedInvalidEditStart||(this._hasWarnedInvalidEditStart=!0,this._logService.warn(`Invalid semantic tokens edit detected (previousResultId: ${e}, resultId: ${t}) at edit #${i}: The provided start offset ${o} is outside the previous data (length ${r}).`))}};v9=zst([Zre(1,Vi),Zre(2,ai),Zre(3,Bn)],v9);Xre=class{constructor(e,t,i,o){this.tokenTypeIndex=e,this.tokenModifierSet=t,this.languageId=i,this.metadata=o,this.next=null}},Qre=class n{static{this._SIZES=[3,7,13,31,61,127,251,509,1021,2039,4093,8191,16381,32749,65521,131071,262139,524287,1048573,2097143]}constructor(){this._elementsCount=0,this._currentLengthIndex=0,this._currentLength=n._SIZES[this._currentLengthIndex],this._growCount=Math.round(this._currentLengthIndex+1=this._growCount){let r=this._elements;this._currentLengthIndex++,this._currentLength=n._SIZES[this._currentLengthIndex],this._growCount=Math.round(this._currentLengthIndex+1{Fe();nC=We("semanticTokensStylingService")});var Vst,Jre,ese,ERe=k(()=>{j();fs();Yi();ac();w9();y9();Xs();Vst=function(n,e,t,i){var o=arguments.length,r=o<3?e:i===null?i=Object.getOwnPropertyDescriptor(e,t):i,s;if(typeof Reflect=="object"&&typeof Reflect.decorate=="function")r=Reflect.decorate(n,e,t,i);else for(var a=n.length-1;a>=0;a--)(s=n[a])&&(r=(o<3?s(r):o>3?s(e,t,r):s(e,t))||r);return o>3&&r&&Object.defineProperty(e,t,r),r},Jre=function(n,e){return function(t,i){e(t,i,n)}},ese=class extends D{constructor(e,t,i){super(),this._themeService=e,this._logService=t,this._languageService=i,this._caches=new WeakMap,this._register(this._themeService.onDidColorThemeChange(()=>{this._caches=new WeakMap}))}getStyling(e){return this._caches.has(e)||this._caches.set(e,new v9(e.getLegend(),this._themeService,this._languageService,this._logService)),this._caches.get(e)}};ese=Vst([Jre(0,Vi),Jre(1,Bn),Jre(2,ai)],ese);Ct(nC,ese,1)});function Ux(n){return n===47||n===92}function tse(n){return n.replace(/[\\/]/g,eo.sep)}function TRe(n){return n.indexOf("/")===-1&&(n=tse(n)),/^[a-zA-Z]:(\/|$)/.test(n)&&(n="/"+n),n}function ise(n,e=eo.sep){if(!n)return"";let t=n.length,i=n.charCodeAt(0);if(Ux(i)){if(Ux(n.charCodeAt(1))&&!Ux(n.charCodeAt(2))){let r=3,s=r;for(;rn.length)return!1;if(t){if(!iL(n,e))return!1;if(e.length===n.length)return!0;let r=e.length;return e.charAt(e.length-1)===i&&r--,n.charAt(r)===i}return e.charAt(e.length-1)!==i&&(e+=i),n.indexOf(e)===0}function DRe(n){return n>=65&&n<=90||n>=97&&n<=122}function NRe(n,e=kn){return e?DRe(n.charCodeAt(0))&&n.charCodeAt(1)===58:!1}var C9=k(()=>{sp();Bt();Qe()});function ARe(n,e){switch(n){case 0:return"";case 1:return`${L9}*?`;default:return`(?:${k9}|${L9}+${k9}${e?`|${k9}${L9}+`:""})*?`}}function MRe(n,e){if(!n)return[];let t=[],i=!1,o=!1,r="";for(let s of n){switch(s){case e:if(!i&&!o){t.push(r),r="";continue}break;case"{":i=!0;break;case"}":i=!1;break;case"[":o=!0;break;case"]":o=!1;break}r+=s}return r&&t.push(r),t}function WRe(n){if(!n)return"";let e="",t=MRe(n,RRe);if(t.every(i=>i===S9))e=".*";else{let i=!1;t.forEach((o,r)=>{if(o===S9){if(i)return;e+=ARe(2,r===t.length-1)}else{let s=!1,a="",l=!1,c="";for(let d of o){if(d!=="}"&&s){a+=d;continue}if(l&&(d!=="]"||!c)){let u;d==="-"?u=d:(d==="^"||d==="!")&&!c?u="^":d===RRe?u="":u=jr(d),c+=u;continue}switch(d){case"{":s=!0;continue;case"[":l=!0;continue;case"}":{let h=`(?:${MRe(a,",").map(f=>WRe(f)).join("|")})`;e+=h,s=!1,a="";break}case"]":{e+="["+c+"]",l=!1,c="";break}case"?":e+=L9;continue;case"*":e+=ARe(1);continue;default:e+=jr(d)}}rose(a,e)).filter(a=>a!==$m),n),i=t.length;if(!i)return $m;if(i===1)return t[0];let o=function(a,l){for(let c=0,d=t.length;c!!a.allBasenames);r&&(o.allBasenames=r.allBasenames);let s=t.reduce((a,l)=>l.allPaths?a.concat(l.allPaths):a,[]);return s.length&&(o.allPaths=s),o}function BRe(n,e,t){let i=Cd===eo.sep,o=i?n:n.replace($st,Cd),r=Cd+o,s=eo.sep+n,a;return t?a=function(l,c){return typeof l=="string"&&(l===o||l.endsWith(r)||!i&&(l===n||l.endsWith(s)))?e:null}:a=function(l,c){return typeof l=="string"&&(l===o||!i&&l===n)?e:null},a.allPaths=[(t?"*/":"./")+n],a}function eat(n){try{let e=new RegExp(`^${WRe(n)}$`);return function(t){return e.lastIndex=0,typeof t=="string"&&e.test(t)?n:null}}catch{return $m}}function HRe(n,e,t){return!n||typeof e!="string"?!1:rse(n)(e,void 0,t)}function rse(n,e={}){if(!n)return ORe;if(typeof n=="string"||tat(n)){let t=ose(n,e);if(t===$m)return ORe;let i=function(o,r){return!!t(o,r)};return t.allBasenames&&(i.allBasenames=t.allBasenames),t.allPaths&&(i.allPaths=t.allPaths),i}return iat(n,e)}function tat(n){let e=n;return e?typeof e.base=="string"&&typeof e.pattern=="string":!1}function iat(n,e){let t=zRe(Object.getOwnPropertyNames(n).map(a=>nat(a,n[a],e)).filter(a=>a!==$m)),i=t.length;if(!i)return $m;if(!t.some(a=>!!a.requiresSiblings)){if(i===1)return t[0];let a=function(d,u){let h;for(let f=0,p=t.length;f{for(let f of h){let p=await f;if(typeof p=="string")return p}return null})():null},l=t.find(d=>!!d.allBasenames);l&&(a.allBasenames=l.allBasenames);let c=t.reduce((d,u)=>u.allPaths?d.concat(u.allPaths):d,[]);return c.length&&(a.allPaths=c),a}let o=function(a,l,c){let d,u;for(let h=0,f=t.length;h{for(let h of u){let f=await h;if(typeof f=="string")return f}return null})():null},r=t.find(a=>!!a.allBasenames);r&&(o.allBasenames=r.allBasenames);let s=t.reduce((a,l)=>l.allPaths?a.concat(l.allPaths):a,[]);return s.length&&(o.allPaths=s),o}function nat(n,e,t){if(e===!1)return $m;let i=ose(n,t);if(i===$m)return $m;if(typeof e=="boolean")return i;if(e){let o=e.when;if(typeof o=="string"){let r=(s,a,l,c)=>{if(!c||!i(s,a))return null;let d=o.replace("$(basename)",()=>l),u=c(d);return xB(u)?u.then(h=>h?n:null):u?n:null};return r.requiresSiblings=!0,r}}return i}function zRe(n,e){let t=n.filter(a=>!!a.basenames);if(t.length<2)return n;let i=t.reduce((a,l)=>{let c=l.basenames;return c?a.concat(c):a},[]),o;if(e){o=[];for(let a=0,l=i.length;a{let c=l.patterns;return c?a.concat(c):a},[]);let r=function(a,l){if(typeof a!="string")return null;if(!l){let d;for(d=a.length;d>0;d--){let u=a.charCodeAt(d-1);if(u===47||u===92)break}l=a.substr(d)}let c=i.indexOf(l);return c!==-1?o[c]:null};r.basenames=i,r.patterns=o,r.allBasenames=i;let s=n.filter(a=>!a.basenames);return s.push(r),s}var S9,RRe,k9,L9,$st,jst,qst,Kst,Gst,Yst,Zst,PRe,ORe,$m,sse=k(()=>{ft();C9();Ds();sp();Bt();Qe();S9="**",RRe="/",k9="[/\\\\]",L9="[^/\\\\]",$st=/\//g;jst=/^\*\*\/\*\.[\w\.-]+$/,qst=/^\*\*\/([\w\.-]+)\/?$/,Kst=/^{\*\*\/\*?[\w\.-]+\/?(,\*\*\/\*?[\w\.-]+\/?)*}$/,Gst=/^{\*\*\/\*?[\w\.-]+(\/(\*\*)?)?(,\*\*\/\*?[\w\.-]+(\/(\*\*)?)?)*}$/,Yst=/^\*\*((\/[\w\.-]+)+)\/?$/,Zst=/^([\w\.-]+(\/[\w\.-]+)*)\/?$/,PRe=new Ts(1e4),ORe=function(){return!1},$m=function(){return null}});function ZA(n,e,t,i,o,r){if(Array.isArray(n)){let s=0;for(let a of n){let l=ZA(a,e,t,i,o,r);if(l===10)return l;l>s&&(s=l)}return s}else{if(typeof n=="string")return i?n==="*"?5:n===t?10:0:0;if(n){let{language:s,pattern:a,scheme:l,hasAccessToAllModels:c,notebookType:d}=n;if(!i&&!c)return 0;d&&o&&(e=o);let u=0;if(l)if(l===e.scheme)u=10;else if(l==="*")u=5;else return 0;if(s)if(s===t)u=10;else if(s==="*")u=Math.max(u,5);else return 0;if(d)if(d===r)u=10;else if(d==="*"&&r!==void 0)u=Math.max(u,5);else return 0;if(a){let h;if(typeof a=="string"?h=a:h={...a,base:J3(a.base)},h===e.fsPath||HRe(h,e.fsPath))u=10;else return 0}return u}else return 0}}var ase=k(()=>{sse();sp()});function VRe(n){return typeof n=="string"?!1:Array.isArray(n)?n.every(VRe):!!n.exclusive}function XA(n){return typeof n=="string"?!1:Array.isArray(n)?n.some(XA):!!n.isBuiltin}var I9,ro,URe=k(()=>{Ie();j();Zr();ase();I9=class{constructor(e,t,i,o,r){this.uri=e,this.languageId=t,this.notebookUri=i,this.notebookType=o,this.recursive=r}equals(e){return this.notebookType===e.notebookType&&this.languageId===e.languageId&&this.uri.toString()===e.uri.toString()&&this.notebookUri?.toString()===e.notebookUri?.toString()&&this.recursive===e.recursive}},ro=class n{constructor(e){this._notebookInfoResolver=e,this._clock=0,this._entries=[],this._onDidChange=new A,this.onDidChange=this._onDidChange.event}register(e,t){let i={selector:e,provider:t,_score:-1,_time:this._clock++};return this._entries.push(i),this._lastCandidate=void 0,this._onDidChange.fire(this._entries.length),ge(()=>{if(i){let o=this._entries.indexOf(i);o>=0&&(this._entries.splice(o,1),this._lastCandidate=void 0,this._onDidChange.fire(this._entries.length),i=void 0)}})}has(e){return this.all(e).length>0}all(e){if(!e)return[];this._updateScores(e,!1);let t=[];for(let i of this._entries)i._score>0&&t.push(i.provider);return t}ordered(e,t=!1){let i=[];return this._orderedForEach(e,t,o=>i.push(o.provider)),i}orderedGroups(e){let t=[],i,o;return this._orderedForEach(e,!1,r=>{i&&o===r._score?i.push(r.provider):(o=r._score,i=[r.provider],t.push(i))}),t}_orderedForEach(e,t,i){this._updateScores(e,t);for(let o of this._entries)o._score>0&&i(o)}_updateScores(e,t){let i=this._notebookInfoResolver?.(e.uri),o=i?new I9(e.uri,e.getLanguageId(),i.uri,i.type,t):new I9(e.uri,e.getLanguageId(),void 0,void 0,t);if(!this._lastCandidate?.equals(o)){this._lastCandidate=o;for(let r of this._entries)if(r._score=ZA(r.selector,o.uri,o.languageId,P6(e),o.notebookUri,o.notebookType),VRe(r.selector)&&r._score>0)if(t)r._score=0;else{for(let s of this._entries)s._score=0;r._score=1e3;break}this._entries.sort(n._compareByScoreAndTime)}}static _compareByScoreAndTime(e,t){return e._scoret._score?-1:XA(e.selector)&&!XA(t.selector)?1:!XA(e.selector)&&XA(t.selector)?-1:e._timet._time?-1:0}}});var lse,$Re=k(()=>{URe();Qt();Xs();lse=class{constructor(){this.referenceProvider=new ro(this._score.bind(this)),this.renameProvider=new ro(this._score.bind(this)),this.newSymbolNamesProvider=new ro(this._score.bind(this)),this.codeActionProvider=new ro(this._score.bind(this)),this.definitionProvider=new ro(this._score.bind(this)),this.typeDefinitionProvider=new ro(this._score.bind(this)),this.declarationProvider=new ro(this._score.bind(this)),this.implementationProvider=new ro(this._score.bind(this)),this.documentSymbolProvider=new ro(this._score.bind(this)),this.inlayHintsProvider=new ro(this._score.bind(this)),this.colorProvider=new ro(this._score.bind(this)),this.codeLensProvider=new ro(this._score.bind(this)),this.documentFormattingEditProvider=new ro(this._score.bind(this)),this.documentRangeFormattingEditProvider=new ro(this._score.bind(this)),this.onTypeFormattingEditProvider=new ro(this._score.bind(this)),this.signatureHelpProvider=new ro(this._score.bind(this)),this.hoverProvider=new ro(this._score.bind(this)),this.documentHighlightProvider=new ro(this._score.bind(this)),this.multiDocumentHighlightProvider=new ro(this._score.bind(this)),this.selectionRangeProvider=new ro(this._score.bind(this)),this.foldingRangeProvider=new ro(this._score.bind(this)),this.linkProvider=new ro(this._score.bind(this)),this.inlineCompletionsProvider=new ro(this._score.bind(this)),this.inlineEditProvider=new ro(this._score.bind(this)),this.completionProvider=new ro(this._score.bind(this)),this.linkedEditingRangeProvider=new ro(this._score.bind(this)),this.documentRangeSemanticTokensProvider=new ro(this._score.bind(this)),this.documentSemanticTokensProvider=new ro(this._score.bind(this)),this.documentDropEditProvider=new ro(this._score.bind(this)),this.documentPasteEditProvider=new ro(this._score.bind(this))}_score(e){return this._notebookTypeResolver?.(e)}};Ct(le,lse,1)});function E9(n){return`--vscode-${n.replace(/\./g,"-")}`}function De(n){return`var(${E9(n)})`}function qRe(n,e){return`var(${E9(n)}, ${e})`}function oat(n){return n!==null&&typeof n=="object"&&"light"in n&&"dark"in n}function R(n,e,t,i,o){return T9.registerColor(n,e,t,i,o)}function sat(n,e){switch(n.op){case 0:return bp(n.value,e)?.darken(n.factor);case 1:return bp(n.value,e)?.lighten(n.factor);case 2:return bp(n.value,e)?.transparent(n.factor);case 3:{let t=bp(n.background,e);return t?bp(n.value,e)?.makeOpaque(t):bp(n.value,e)}case 4:for(let t of n.values){let i=bp(t,e);if(i)return i}return;case 6:return bp(e.defines(n.if)?n.then:n.else,e);case 5:{let t=bp(n.value,e);if(!t)return;let i=bp(n.background,e);return i?t.isDarkerThan(i)?Z.getLighterColor(t,i,n.factor).transparent(n.transparency):Z.getDarkerColor(t,i,n.factor).transparent(n.transparency):t.transparent(n.factor*n.transparency)}default:throw kx(n)}}function jm(n,e){return{op:0,value:n,factor:e}}function Cu(n,e){return{op:1,value:n,factor:e}}function It(n,e){return{op:2,value:n,factor:e}}function oC(...n){return{op:4,values:n}}function KRe(n,e,t){return{op:6,if:n,then:e,else:t}}function use(n,e,t,i){return{op:5,value:n,background:e,factor:t,transparency:i}}function bp(n,e){if(n!==null){if(typeof n=="string")return n[0]==="#"?Z.fromHex(n):e.getColor(n);if(n instanceof Z)return n;if(typeof n=="object")return sat(n,e)}}var dse,rat,cse,T9,GRe,YRe,jRe,Ch=k(()=>{bf();ft();vo();Ie();w6();br();pe();dse={ColorContribution:"base.contributions.colors"},rat="default",cse=class{constructor(){this._onDidChangeSchema=new A,this.onDidChangeSchema=this._onDidChangeSchema.event,this.colorSchema={type:"object",properties:{}},this.colorReferenceSchema={type:"string",enum:[],enumDescriptions:[]},this.colorsById={}}registerColor(e,t,i,o=!1,r){let s={id:e,description:i,defaults:t,needsTransparency:o,deprecationMessage:r};this.colorsById[e]=s;let a={type:"string",format:"color-hex",defaultSnippets:[{body:"${1:#ff0000}"}]};return r&&(a.deprecationMessage=r),o&&(a.pattern="^#(?:(?[0-9a-fA-f]{3}[0-9a-eA-E])|(?:[0-9a-fA-F]{6}(?:(?![fF]{2})(?:[0-9a-fA-F]{2}))))?$",a.patternErrorMessage=m("transparecyRequired","This color must be transparent or it will obscure content")),this.colorSchema.properties[e]={description:i,oneOf:[a,{type:"string",const:rat,description:m("useDefault","Use the default color.")}]},this.colorReferenceSchema.enum.push(e),this.colorReferenceSchema.enumDescriptions.push(i),this._onDidChangeSchema.fire(),e}getColors(){return Object.keys(this.colorsById).map(e=>this.colorsById[e])}resolveDefaultColor(e,t){let i=this.colorsById[e];if(i?.defaults){let o=oat(i.defaults)?i.defaults[t.type]:i.defaults;return bp(o,t)}}getColorSchema(){return this.colorSchema}toString(){let e=(t,i)=>{let o=t.indexOf(".")===-1?0:1,r=i.indexOf(".")===-1?0:1;return o!==r?o-r:t.localeCompare(i)};return Object.keys(this.colorsById).sort(e).map(t=>`- \`${t}\`: ${this.colorsById[t].description}`).join(` `)}},T9=new cse;ei.add(dse.ColorContribution,T9);GRe="vscode://schemas/workbench-colors",YRe=ei.as(V1.JSONContribution);YRe.registerSchema(GRe,T9.getColorSchema());jRe=new Lt(()=>YRe.notifySchemaChanged(GRe),200);T9.onDidChangeSchema(()=>{jRe.isScheduled()||jRe.schedule()})});var Ht,Zzt,Xzt,Qzt,rC,Su,jt,Zi,Jzt,ZRe,eVt,tVt,iVt,nVt,oVt,rVt,sVt,rb=k(()=>{pe();vo();Ch();Ht=R("foreground",{dark:"#CCCCCC",light:"#616161",hcDark:"#FFFFFF",hcLight:"#292929"},m("foreground","Overall foreground color. This color is only used if not overridden by a component.")),Zzt=R("disabledForeground",{dark:"#CCCCCC80",light:"#61616180",hcDark:"#A5A5A5",hcLight:"#7F7F7F"},m("disabledForeground","Overall foreground for disabled elements. This color is only used if not overridden by a component.")),Xzt=R("errorForeground",{dark:"#F48771",light:"#A1260D",hcDark:"#F48771",hcLight:"#B5200D"},m("errorForeground","Overall foreground color for error messages. This color is only used if not overridden by a component.")),Qzt=R("descriptionForeground",{light:"#717171",dark:It(Ht,.7),hcDark:It(Ht,.7),hcLight:It(Ht,.7)},m("descriptionForeground","Foreground color for description text providing additional information, for example for a label.")),rC=R("icon.foreground",{dark:"#C5C5C5",light:"#424242",hcDark:"#FFFFFF",hcLight:"#292929"},m("iconForeground","The default color for icons in the workbench.")),Su=R("focusBorder",{dark:"#007FD4",light:"#0090F1",hcDark:"#F38518",hcLight:"#006BBD"},m("focusBorder","Overall border color for focused elements. This color is only used if not overridden by a component.")),jt=R("contrastBorder",{light:null,dark:null,hcDark:"#6FC3DF",hcLight:"#0F4A85"},m("contrastBorder","An extra border around elements to separate them from others for greater contrast.")),Zi=R("contrastActiveBorder",{light:null,dark:null,hcDark:Su,hcLight:Su},m("activeContrastBorder","An extra border around active elements to separate them from others for greater contrast.")),Jzt=R("selection.background",null,m("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.")),ZRe=R("textLink.foreground",{light:"#006AB1",dark:"#3794FF",hcDark:"#21A6FF",hcLight:"#0F4A85"},m("textLinkForeground","Foreground color for links in text.")),eVt=R("textLink.activeForeground",{light:"#006AB1",dark:"#3794FF",hcDark:"#21A6FF",hcLight:"#0F4A85"},m("textLinkActiveForeground","Foreground color for links in text when clicked on and on mouse hover.")),tVt=R("textSeparator.foreground",{light:"#0000002e",dark:"#ffffff2e",hcDark:Z.black,hcLight:"#292929"},m("textSeparatorForeground","Color for text separators.")),iVt=R("textPreformat.foreground",{light:"#A31515",dark:"#D7BA7D",hcDark:"#000000",hcLight:"#FFFFFF"},m("textPreformatForeground","Foreground color for preformatted text segments.")),nVt=R("textPreformat.background",{light:"#0000001A",dark:"#FFFFFF1A",hcDark:"#FFFFFF",hcLight:"#09345f"},m("textPreformatBackground","Background color for preformatted text segments.")),oVt=R("textBlockQuote.background",{light:"#f2f2f2",dark:"#222222",hcDark:null,hcLight:"#F2F2F2"},m("textBlockQuoteBackground","Background color for block quotes in text.")),rVt=R("textBlockQuote.border",{light:"#007acc80",dark:"#007acc80",hcDark:Z.white,hcLight:"#292929"},m("textBlockQuoteBorder","Border color for block quotes in text.")),sVt=R("textCodeBlock.background",{light:"#dcdcdc66",dark:"#0a0a0a66",hcDark:Z.black,hcLight:"#F2F2F2"},m("textCodeBlockBackground","Background color for code blocks in text."))});var uVt,WL,XRe,QA,D9,N9,R9,QRe,A9=k(()=>{pe();vo();Ch();rb();uVt=R("sash.hoverBorder",Su,m("sashActiveBorder","Border color of active sashes.")),WL=R("badge.background",{dark:"#4D4D4D",light:"#C4C4C4",hcDark:Z.black,hcLight:"#0F4A85"},m("badgeBackground","Badge background color. Badges are small information labels, e.g. for search results count.")),XRe=R("badge.foreground",{dark:Z.white,light:"#333",hcDark:Z.white,hcLight:Z.white},m("badgeForeground","Badge foreground color. Badges are small information labels, e.g. for search results count.")),QA=R("scrollbar.shadow",{dark:"#000000",light:"#DDDDDD",hcDark:null,hcLight:null},m("scrollbarShadow","Scrollbar shadow to indicate that the view is scrolled.")),D9=R("scrollbarSlider.background",{dark:Z.fromHex("#797979").transparent(.4),light:Z.fromHex("#646464").transparent(.4),hcDark:It(jt,.6),hcLight:It(jt,.4)},m("scrollbarSliderBackground","Scrollbar slider background color.")),N9=R("scrollbarSlider.hoverBackground",{dark:Z.fromHex("#646464").transparent(.7),light:Z.fromHex("#646464").transparent(.7),hcDark:It(jt,.8),hcLight:It(jt,.8)},m("scrollbarSliderHoverBackground","Scrollbar slider background color when hovering.")),R9=R("scrollbarSlider.activeBackground",{dark:Z.fromHex("#BFBFBF").transparent(.4),light:Z.fromHex("#000000").transparent(.6),hcDark:jt,hcLight:jt},m("scrollbarSliderActiveBackground","Scrollbar slider background color when clicked on.")),QRe=R("progressBar.background",{dark:Z.fromHex("#0E70C0"),light:Z.fromHex("#0E70C0"),hcDark:jt,hcLight:jt},m("progressBarBackground","Background color of the progress bar that can show for long running operations."))});var $c,ku,_Vt,bVt,vVt,xVt,Ca,sC,eM,wVt,yVt,aC,nAe,oAe,Lu,$x,CVt,jc,jx,rAe,SVt,sAe,sb,aAe,mse,tM,kVt,LVt,lAe,Sh,cAe,IVt,EVt,yf,dAe,TVt,JA,DVt,O9,NVt,F9,B9,uAe,hAe,fAe,pAe,aat,RVt,AVt,MVt,PVt,OVt,FVt,M9,P9,mAe,gAe,BVt,WVt,HVt,zVt,_Ae,bAe,VVt,UVt,$Vt,jVt,qVt,KVt,GVt,qm,W9,JRe,YVt,ZVt,vAe,xAe,gse,wAe,XVt,yAe,eAe,tAe,iAe,_se,HL,hse,QVt,fse,JVt,pse,eUt,zL,tUt,iUt,nUt,H9,bse,CAe,SAe,kAe,qx=k(()=>{pe();vo();Ch();rb();A9();$c=R("editor.background",{light:"#ffffff",dark:"#1E1E1E",hcDark:Z.black,hcLight:Z.white},m("editorBackground","Editor background color.")),ku=R("editor.foreground",{light:"#333333",dark:"#BBBBBB",hcDark:Z.white,hcLight:Ht},m("editorForeground","Editor default foreground color.")),_Vt=R("editorStickyScroll.background",$c,m("editorStickyScrollBackground","Background color of sticky scroll in the editor")),bVt=R("editorStickyScrollHover.background",{dark:"#2A2D2E",light:"#F0F0F0",hcDark:null,hcLight:Z.fromHex("#0F4A85").transparent(.1)},m("editorStickyScrollHoverBackground","Background color of sticky scroll on hover in the editor")),vVt=R("editorStickyScroll.border",{dark:null,light:null,hcDark:jt,hcLight:jt},m("editorStickyScrollBorder","Border color of sticky scroll in the editor")),xVt=R("editorStickyScroll.shadow",QA,m("editorStickyScrollShadow"," Shadow color of sticky scroll in the editor")),Ca=R("editorWidget.background",{dark:"#252526",light:"#F3F3F3",hcDark:"#0C141F",hcLight:Z.white},m("editorWidgetBackground","Background color of editor widgets, such as find/replace.")),sC=R("editorWidget.foreground",Ht,m("editorWidgetForeground","Foreground color of editor widgets, such as find/replace.")),eM=R("editorWidget.border",{dark:"#454545",light:"#C8C8C8",hcDark:jt,hcLight:jt},m("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.")),wVt=R("editorWidget.resizeBorder",null,m("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.")),yVt=R("editorError.background",null,m("editorError.background","Background color of error text in the editor. The color must not be opaque so as not to hide underlying decorations."),!0),aC=R("editorError.foreground",{dark:"#F14C4C",light:"#E51400",hcDark:"#F48771",hcLight:"#B5200D"},m("editorError.foreground","Foreground color of error squigglies in the editor.")),nAe=R("editorError.border",{dark:null,light:null,hcDark:Z.fromHex("#E47777").transparent(.8),hcLight:"#B5200D"},m("errorBorder","If set, color of double underlines for errors in the editor.")),oAe=R("editorWarning.background",null,m("editorWarning.background","Background color of warning text in the editor. The color must not be opaque so as not to hide underlying decorations."),!0),Lu=R("editorWarning.foreground",{dark:"#CCA700",light:"#BF8803",hcDark:"#FFD370",hcLight:"#895503"},m("editorWarning.foreground","Foreground color of warning squigglies in the editor.")),$x=R("editorWarning.border",{dark:null,light:null,hcDark:Z.fromHex("#FFCC00").transparent(.8),hcLight:Z.fromHex("#FFCC00").transparent(.8)},m("warningBorder","If set, color of double underlines for warnings in the editor.")),CVt=R("editorInfo.background",null,m("editorInfo.background","Background color of info text in the editor. The color must not be opaque so as not to hide underlying decorations."),!0),jc=R("editorInfo.foreground",{dark:"#3794FF",light:"#1a85ff",hcDark:"#3794FF",hcLight:"#1a85ff"},m("editorInfo.foreground","Foreground color of info squigglies in the editor.")),jx=R("editorInfo.border",{dark:null,light:null,hcDark:Z.fromHex("#3794FF").transparent(.8),hcLight:"#292929"},m("infoBorder","If set, color of double underlines for infos in the editor.")),rAe=R("editorHint.foreground",{dark:Z.fromHex("#eeeeee").transparent(.7),light:"#6c6c6c",hcDark:null,hcLight:null},m("editorHint.foreground","Foreground color of hint squigglies in the editor.")),SVt=R("editorHint.border",{dark:null,light:null,hcDark:Z.fromHex("#eeeeee").transparent(.8),hcLight:"#292929"},m("hintBorder","If set, color of double underlines for hints in the editor.")),sAe=R("editorLink.activeForeground",{dark:"#4E94CE",light:Z.blue,hcDark:Z.cyan,hcLight:"#292929"},m("activeLinkForeground","Color of active links.")),sb=R("editor.selectionBackground",{light:"#ADD6FF",dark:"#264F78",hcDark:"#f3f518",hcLight:"#0F4A85"},m("editorSelectionBackground","Color of the editor selection.")),aAe=R("editor.selectionForeground",{light:null,dark:null,hcDark:"#000000",hcLight:Z.white},m("editorSelectionForeground","Color of the selected text for high contrast.")),mse=R("editor.inactiveSelectionBackground",{light:It(sb,.5),dark:It(sb,.5),hcDark:It(sb,.7),hcLight:It(sb,.5)},m("editorInactiveSelection","Color of the selection in an inactive editor. The color must not be opaque so as not to hide underlying decorations."),!0),tM=R("editor.selectionHighlightBackground",{light:use(sb,$c,.3,.6),dark:use(sb,$c,.3,.6),hcDark:null,hcLight:null},m("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),kVt=R("editor.selectionHighlightBorder",{light:null,dark:null,hcDark:Zi,hcLight:Zi},m("editorSelectionHighlightBorder","Border color for regions with the same content as the selection.")),LVt=R("editor.findMatchBackground",{light:"#A8AC94",dark:"#515C6A",hcDark:null,hcLight:null},m("editorFindMatch","Color of the current search match.")),lAe=R("editor.findMatchForeground",null,m("editorFindMatchForeground","Text color of the current search match.")),Sh=R("editor.findMatchHighlightBackground",{light:"#EA5C0055",dark:"#EA5C0055",hcDark:null,hcLight:null},m("findMatchHighlight","Color of the other search matches. The color must not be opaque so as not to hide underlying decorations."),!0),cAe=R("editor.findMatchHighlightForeground",null,m("findMatchHighlightForeground","Foreground color of the other search matches."),!0),IVt=R("editor.findRangeHighlightBackground",{dark:"#3a3d4166",light:"#b4b4b44d",hcDark:null,hcLight:null},m("findRangeHighlight","Color of the range limiting the search. The color must not be opaque so as not to hide underlying decorations."),!0),EVt=R("editor.findMatchBorder",{light:null,dark:null,hcDark:Zi,hcLight:Zi},m("editorFindMatchBorder","Border color of the current search match.")),yf=R("editor.findMatchHighlightBorder",{light:null,dark:null,hcDark:Zi,hcLight:Zi},m("findMatchHighlightBorder","Border color of the other search matches.")),dAe=R("editor.findRangeHighlightBorder",{dark:null,light:null,hcDark:It(Zi,.4),hcLight:It(Zi,.4)},m("findRangeHighlightBorder","Border color of the range limiting the search. The color must not be opaque so as not to hide underlying decorations."),!0),TVt=R("editor.hoverHighlightBackground",{light:"#ADD6FF26",dark:"#264f7840",hcDark:"#ADD6FF26",hcLight:null},m("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),JA=R("editorHoverWidget.background",Ca,m("hoverBackground","Background color of the editor hover.")),DVt=R("editorHoverWidget.foreground",sC,m("hoverForeground","Foreground color of the editor hover.")),O9=R("editorHoverWidget.border",eM,m("hoverBorder","Border color of the editor hover.")),NVt=R("editorHoverWidget.statusBarBackground",{dark:Cu(JA,.2),light:jm(JA,.05),hcDark:Ca,hcLight:Ca},m("statusBarBackground","Background color of the editor hover status bar.")),F9=R("editorInlayHint.foreground",{dark:"#969696",light:"#969696",hcDark:Z.white,hcLight:Z.black},m("editorInlayHintForeground","Foreground color of inline hints")),B9=R("editorInlayHint.background",{dark:It(WL,.1),light:It(WL,.1),hcDark:It(Z.white,.1),hcLight:It(WL,.1)},m("editorInlayHintBackground","Background color of inline hints")),uAe=R("editorInlayHint.typeForeground",F9,m("editorInlayHintForegroundTypes","Foreground color of inline hints for types")),hAe=R("editorInlayHint.typeBackground",B9,m("editorInlayHintBackgroundTypes","Background color of inline hints for types")),fAe=R("editorInlayHint.parameterForeground",F9,m("editorInlayHintForegroundParameter","Foreground color of inline hints for parameters")),pAe=R("editorInlayHint.parameterBackground",B9,m("editorInlayHintBackgroundParameter","Background color of inline hints for parameters")),aat=R("editorLightBulb.foreground",{dark:"#FFCC00",light:"#DDB100",hcDark:"#FFCC00",hcLight:"#007ACC"},m("editorLightBulbForeground","The color used for the lightbulb actions icon.")),RVt=R("editorLightBulbAutoFix.foreground",{dark:"#75BEFF",light:"#007ACC",hcDark:"#75BEFF",hcLight:"#007ACC"},m("editorLightBulbAutoFixForeground","The color used for the lightbulb auto fix actions icon.")),AVt=R("editorLightBulbAi.foreground",aat,m("editorLightBulbAiForeground","The color used for the lightbulb AI icon.")),MVt=R("editor.snippetTabstopHighlightBackground",{dark:new Z(new Ut(124,124,124,.3)),light:new Z(new Ut(10,50,100,.2)),hcDark:new Z(new Ut(124,124,124,.3)),hcLight:new Z(new Ut(10,50,100,.2))},m("snippetTabstopHighlightBackground","Highlight background color of a snippet tabstop.")),PVt=R("editor.snippetTabstopHighlightBorder",null,m("snippetTabstopHighlightBorder","Highlight border color of a snippet tabstop.")),OVt=R("editor.snippetFinalTabstopHighlightBackground",null,m("snippetFinalTabstopHighlightBackground","Highlight background color of the final tabstop of a snippet.")),FVt=R("editor.snippetFinalTabstopHighlightBorder",{dark:"#525252",light:new Z(new Ut(10,50,100,.5)),hcDark:"#525252",hcLight:"#292929"},m("snippetFinalTabstopHighlightBorder","Highlight border color of the final tabstop of a snippet.")),M9=new Z(new Ut(155,185,85,.2)),P9=new Z(new Ut(255,0,0,.2)),mAe=R("diffEditor.insertedTextBackground",{dark:"#9ccc2c33",light:"#9ccc2c40",hcDark:null,hcLight:null},m("diffEditorInserted","Background color for text that got inserted. The color must not be opaque so as not to hide underlying decorations."),!0),gAe=R("diffEditor.removedTextBackground",{dark:"#ff000033",light:"#ff000033",hcDark:null,hcLight:null},m("diffEditorRemoved","Background color for text that got removed. The color must not be opaque so as not to hide underlying decorations."),!0),BVt=R("diffEditor.insertedLineBackground",{dark:M9,light:M9,hcDark:null,hcLight:null},m("diffEditorInsertedLines","Background color for lines that got inserted. The color must not be opaque so as not to hide underlying decorations."),!0),WVt=R("diffEditor.removedLineBackground",{dark:P9,light:P9,hcDark:null,hcLight:null},m("diffEditorRemovedLines","Background color for lines that got removed. The color must not be opaque so as not to hide underlying decorations."),!0),HVt=R("diffEditorGutter.insertedLineBackground",null,m("diffEditorInsertedLineGutter","Background color for the margin where lines got inserted.")),zVt=R("diffEditorGutter.removedLineBackground",null,m("diffEditorRemovedLineGutter","Background color for the margin where lines got removed.")),_Ae=R("diffEditorOverview.insertedForeground",null,m("diffEditorOverviewInserted","Diff overview ruler foreground for inserted content.")),bAe=R("diffEditorOverview.removedForeground",null,m("diffEditorOverviewRemoved","Diff overview ruler foreground for removed content.")),VVt=R("diffEditor.insertedTextBorder",{dark:null,light:null,hcDark:"#33ff2eff",hcLight:"#374E06"},m("diffEditorInsertedOutline","Outline color for the text that got inserted.")),UVt=R("diffEditor.removedTextBorder",{dark:null,light:null,hcDark:"#FF008F",hcLight:"#AD0707"},m("diffEditorRemovedOutline","Outline color for text that got removed.")),$Vt=R("diffEditor.border",{dark:null,light:null,hcDark:jt,hcLight:jt},m("diffEditorBorder","Border color between the two text editors.")),jVt=R("diffEditor.diagonalFill",{dark:"#cccccc33",light:"#22222233",hcDark:null,hcLight:null},m("diffDiagonalFill","Color of the diff editor's diagonal fill. The diagonal fill is used in side-by-side diff views.")),qVt=R("diffEditor.unchangedRegionBackground","sideBar.background",m("diffEditor.unchangedRegionBackground","The background color of unchanged blocks in the diff editor.")),KVt=R("diffEditor.unchangedRegionForeground","foreground",m("diffEditor.unchangedRegionForeground","The foreground color of unchanged blocks in the diff editor.")),GVt=R("diffEditor.unchangedCodeBackground",{dark:"#74747429",light:"#b8b8b829",hcDark:null,hcLight:null},m("diffEditor.unchangedCodeBackground","The background color of unchanged code in the diff editor.")),qm=R("widget.shadow",{dark:It(Z.black,.36),light:It(Z.black,.16),hcDark:null,hcLight:null},m("widgetShadow","Shadow color of widgets such as find/replace inside the editor.")),W9=R("widget.border",{dark:null,light:null,hcDark:jt,hcLight:jt},m("widgetBorder","Border color of widgets such as find/replace inside the editor.")),JRe=R("toolbar.hoverBackground",{dark:"#5a5d5e50",light:"#b8b8b850",hcDark:null,hcLight:null},m("toolbarHoverBackground","Toolbar background when hovering over actions using the mouse")),YVt=R("toolbar.hoverOutline",{dark:null,light:null,hcDark:Zi,hcLight:Zi},m("toolbarHoverOutline","Toolbar outline when hovering over actions using the mouse")),ZVt=R("toolbar.activeBackground",{dark:Cu(JRe,.1),light:jm(JRe,.1),hcDark:null,hcLight:null},m("toolbarActiveBackground","Toolbar background when holding the mouse over actions")),vAe=R("breadcrumb.foreground",It(Ht,.8),m("breadcrumbsFocusForeground","Color of focused breadcrumb items.")),xAe=R("breadcrumb.background",$c,m("breadcrumbsBackground","Background color of breadcrumb items.")),gse=R("breadcrumb.focusForeground",{light:jm(Ht,.2),dark:Cu(Ht,.1),hcDark:Cu(Ht,.1),hcLight:Cu(Ht,.1)},m("breadcrumbsFocusForeground","Color of focused breadcrumb items.")),wAe=R("breadcrumb.activeSelectionForeground",{light:jm(Ht,.2),dark:Cu(Ht,.1),hcDark:Cu(Ht,.1),hcLight:Cu(Ht,.1)},m("breadcrumbsSelectedForeground","Color of selected breadcrumb items.")),XVt=R("breadcrumbPicker.background",Ca,m("breadcrumbsSelectedBackground","Background color of breadcrumb item picker.")),yAe=.5,eAe=Z.fromHex("#40C8AE").transparent(yAe),tAe=Z.fromHex("#40A6FF").transparent(yAe),iAe=Z.fromHex("#606060").transparent(.4),_se=.4,HL=1,hse=R("merge.currentHeaderBackground",{dark:eAe,light:eAe,hcDark:null,hcLight:null},m("mergeCurrentHeaderBackground","Current header background in inline merge-conflicts. The color must not be opaque so as not to hide underlying decorations."),!0),QVt=R("merge.currentContentBackground",It(hse,_se),m("mergeCurrentContentBackground","Current content background in inline merge-conflicts. The color must not be opaque so as not to hide underlying decorations."),!0),fse=R("merge.incomingHeaderBackground",{dark:tAe,light:tAe,hcDark:null,hcLight:null},m("mergeIncomingHeaderBackground","Incoming header background in inline merge-conflicts. The color must not be opaque so as not to hide underlying decorations."),!0),JVt=R("merge.incomingContentBackground",It(fse,_se),m("mergeIncomingContentBackground","Incoming content background in inline merge-conflicts. The color must not be opaque so as not to hide underlying decorations."),!0),pse=R("merge.commonHeaderBackground",{dark:iAe,light:iAe,hcDark:null,hcLight:null},m("mergeCommonHeaderBackground","Common ancestor header background in inline merge-conflicts. The color must not be opaque so as not to hide underlying decorations."),!0),eUt=R("merge.commonContentBackground",It(pse,_se),m("mergeCommonContentBackground","Common ancestor content background in inline merge-conflicts. The color must not be opaque so as not to hide underlying decorations."),!0),zL=R("merge.border",{dark:null,light:null,hcDark:"#C3DF6F",hcLight:"#007ACC"},m("mergeBorder","Border color on headers and the splitter in inline merge-conflicts.")),tUt=R("editorOverviewRuler.currentContentForeground",{dark:It(hse,HL),light:It(hse,HL),hcDark:zL,hcLight:zL},m("overviewRulerCurrentContentForeground","Current overview ruler foreground for inline merge-conflicts.")),iUt=R("editorOverviewRuler.incomingContentForeground",{dark:It(fse,HL),light:It(fse,HL),hcDark:zL,hcLight:zL},m("overviewRulerIncomingContentForeground","Incoming overview ruler foreground for inline merge-conflicts.")),nUt=R("editorOverviewRuler.commonContentForeground",{dark:It(pse,HL),light:It(pse,HL),hcDark:zL,hcLight:zL},m("overviewRulerCommonContentForeground","Common ancestor overview ruler foreground for inline merge-conflicts.")),H9=R("editorOverviewRuler.findMatchForeground",{dark:"#d186167e",light:"#d186167e",hcDark:"#AB5A00",hcLight:"#AB5A00"},m("overviewRulerFindMatchForeground","Overview ruler marker color for find matches. The color must not be opaque so as not to hide underlying decorations."),!0),bse=R("editorOverviewRuler.selectionHighlightForeground","#A0A0A0CC",m("overviewRulerSelectionHighlightForeground","Overview ruler marker color for selection highlights. The color must not be opaque so as not to hide underlying decorations."),!0),CAe=R("problemsErrorIcon.foreground",aC,m("problemsErrorIconForeground","The color used for the problems error icon.")),SAe=R("problemsWarningIcon.foreground",Lu,m("problemsWarningIconForeground","The color used for the problems warning icon.")),kAe=R("problemsInfoIcon.foreground",jc,m("problemsInfoIconForeground","The color used for the problems info icon."))});var iM,nM,vse,LAe,IAe,EAe,TAe,DAe,cUt,dUt,uUt,xse=k(()=>{pe();vo();Ch();qx();A9();iM=R("minimap.findMatchHighlight",{light:"#d18616",dark:"#d18616",hcDark:"#AB5A00",hcLight:"#0F4A85"},m("minimapFindMatchHighlight","Minimap marker color for find matches."),!0),nM=R("minimap.selectionOccurrenceHighlight",{light:"#c9c9c9",dark:"#676767",hcDark:"#ffffff",hcLight:"#0F4A85"},m("minimapSelectionOccurrenceHighlight","Minimap marker color for repeating editor selections."),!0),vse=R("minimap.selectionHighlight",{light:"#ADD6FF",dark:"#264F78",hcDark:"#ffffff",hcLight:"#0F4A85"},m("minimapSelectionHighlight","Minimap marker color for the editor selection."),!0),LAe=R("minimap.infoHighlight",{dark:jc,light:jc,hcDark:jx,hcLight:jx},m("minimapInfo","Minimap marker color for infos.")),IAe=R("minimap.warningHighlight",{dark:Lu,light:Lu,hcDark:$x,hcLight:$x},m("overviewRuleWarning","Minimap marker color for warnings.")),EAe=R("minimap.errorHighlight",{dark:new Z(new Ut(255,18,18,.7)),light:new Z(new Ut(255,18,18,.7)),hcDark:new Z(new Ut(255,50,50,1)),hcLight:"#B5200D"},m("minimapError","Minimap marker color for errors.")),TAe=R("minimap.background",null,m("minimapBackground","Minimap background color.")),DAe=R("minimap.foregroundOpacity",Z.fromHex("#000f"),m("minimapForegroundOpacity",'Opacity of foreground elements rendered in the minimap. For example, "#000000c0" will render the elements with 75% opacity.')),cUt=R("minimapSlider.background",It(D9,.5),m("minimapSliderBackground","Minimap slider background color.")),dUt=R("minimapSlider.hoverBackground",It(N9,.5),m("minimapSliderHoverBackground","Minimap slider background color when hovering.")),uUt=R("minimapSlider.activeBackground",It(R9,.5),m("minimapSliderActiveBackground","Minimap slider background color when clicked on."))});var _Ut,bUt,vUt,xUt,wUt,yUt,CUt,SUt,NAe=k(()=>{pe();Ch();rb();qx();xse();_Ut=R("charts.foreground",Ht,m("chartsForeground","The foreground color used in charts.")),bUt=R("charts.lines",It(Ht,.5),m("chartsLines","The color used for horizontal lines in charts.")),vUt=R("charts.red",aC,m("chartsRed","The red color used in chart visualizations.")),xUt=R("charts.blue",jc,m("chartsBlue","The blue color used in chart visualizations.")),wUt=R("charts.yellow",Lu,m("chartsYellow","The yellow color used in chart visualizations.")),yUt=R("charts.orange",iM,m("chartsOrange","The orange color used in chart visualizations.")),CUt=R("charts.green",{dark:"#89D185",light:"#388A34",hcDark:"#89D185",hcLight:"#374e06"},m("chartsGreen","The green color used in chart visualizations.")),SUt=R("charts.purple",{dark:"#B180D7",light:"#652D90",hcDark:"#B180D7",hcLight:"#652D90"},m("chartsPurple","The purple color used in chart visualizations."))});var oM,V9,U9,lC,lat,ab,cC,DUt,RAe,AAe,MAe,PAe,OAe,FAe,BAe,WAe,HAe,$L,zAe,rM,sM,wse,VAe,VL,UAe,$Ae,jAe,z9,qAe,UL,KAe,GAe,YAe,ZAe,XAe,QAe,JAe,NUt,eMe,tMe,RUt,iMe,nMe,oMe,rMe,yse=k(()=>{pe();vo();Ch();rb();qx();oM=R("input.background",{dark:"#3C3C3C",light:Z.white,hcDark:Z.black,hcLight:Z.white},m("inputBoxBackground","Input box background.")),V9=R("input.foreground",Ht,m("inputBoxForeground","Input box foreground.")),U9=R("input.border",{dark:null,light:null,hcDark:jt,hcLight:jt},m("inputBoxBorder","Input box border.")),lC=R("inputOption.activeBorder",{dark:"#007ACC",light:"#007ACC",hcDark:jt,hcLight:jt},m("inputBoxActiveOptionBorder","Border color of activated options in input fields.")),lat=R("inputOption.hoverBackground",{dark:"#5a5d5e80",light:"#b8b8b850",hcDark:null,hcLight:null},m("inputOption.hoverBackground","Background color of activated options in input fields.")),ab=R("inputOption.activeBackground",{dark:It(Su,.4),light:It(Su,.2),hcDark:Z.transparent,hcLight:Z.transparent},m("inputOption.activeBackground","Background hover color of options in input fields.")),cC=R("inputOption.activeForeground",{dark:Z.white,light:Z.black,hcDark:Ht,hcLight:Ht},m("inputOption.activeForeground","Foreground color of activated options in input fields.")),DUt=R("input.placeholderForeground",{light:It(Ht,.5),dark:It(Ht,.5),hcDark:It(Ht,.7),hcLight:It(Ht,.7)},m("inputPlaceholderForeground","Input box foreground color for placeholder text.")),RAe=R("inputValidation.infoBackground",{dark:"#063B49",light:"#D6ECF2",hcDark:Z.black,hcLight:Z.white},m("inputValidationInfoBackground","Input validation background color for information severity.")),AAe=R("inputValidation.infoForeground",{dark:null,light:null,hcDark:null,hcLight:Ht},m("inputValidationInfoForeground","Input validation foreground color for information severity.")),MAe=R("inputValidation.infoBorder",{dark:"#007acc",light:"#007acc",hcDark:jt,hcLight:jt},m("inputValidationInfoBorder","Input validation border color for information severity.")),PAe=R("inputValidation.warningBackground",{dark:"#352A05",light:"#F6F5D2",hcDark:Z.black,hcLight:Z.white},m("inputValidationWarningBackground","Input validation background color for warning severity.")),OAe=R("inputValidation.warningForeground",{dark:null,light:null,hcDark:null,hcLight:Ht},m("inputValidationWarningForeground","Input validation foreground color for warning severity.")),FAe=R("inputValidation.warningBorder",{dark:"#B89500",light:"#B89500",hcDark:jt,hcLight:jt},m("inputValidationWarningBorder","Input validation border color for warning severity.")),BAe=R("inputValidation.errorBackground",{dark:"#5A1D1D",light:"#F2DEDE",hcDark:Z.black,hcLight:Z.white},m("inputValidationErrorBackground","Input validation background color for error severity.")),WAe=R("inputValidation.errorForeground",{dark:null,light:null,hcDark:null,hcLight:Ht},m("inputValidationErrorForeground","Input validation foreground color for error severity.")),HAe=R("inputValidation.errorBorder",{dark:"#BE1100",light:"#BE1100",hcDark:jt,hcLight:jt},m("inputValidationErrorBorder","Input validation border color for error severity.")),$L=R("dropdown.background",{dark:"#3C3C3C",light:Z.white,hcDark:Z.black,hcLight:Z.white},m("dropdownBackground","Dropdown background.")),zAe=R("dropdown.listBackground",{dark:null,light:null,hcDark:Z.black,hcLight:Z.white},m("dropdownListBackground","Dropdown list background.")),rM=R("dropdown.foreground",{dark:"#F0F0F0",light:Ht,hcDark:Z.white,hcLight:Ht},m("dropdownForeground","Dropdown foreground.")),sM=R("dropdown.border",{dark:$L,light:"#CECECE",hcDark:jt,hcLight:jt},m("dropdownBorder","Dropdown border.")),wse=R("button.foreground",Z.white,m("buttonForeground","Button foreground color.")),VAe=R("button.separator",It(wse,.4),m("buttonSeparator","Button separator color.")),VL=R("button.background",{dark:"#0E639C",light:"#007ACC",hcDark:null,hcLight:"#0F4A85"},m("buttonBackground","Button background color.")),UAe=R("button.hoverBackground",{dark:Cu(VL,.2),light:jm(VL,.2),hcDark:VL,hcLight:VL},m("buttonHoverBackground","Button background color when hovering.")),$Ae=R("button.border",jt,m("buttonBorder","Button border color.")),jAe=R("button.secondaryForeground",{dark:Z.white,light:Z.white,hcDark:Z.white,hcLight:Ht},m("buttonSecondaryForeground","Secondary button foreground color.")),z9=R("button.secondaryBackground",{dark:"#3A3D41",light:"#5F6A79",hcDark:null,hcLight:Z.white},m("buttonSecondaryBackground","Secondary button background color.")),qAe=R("button.secondaryHoverBackground",{dark:Cu(z9,.2),light:jm(z9,.2),hcDark:null,hcLight:null},m("buttonSecondaryHoverBackground","Secondary button background color when hovering.")),UL=R("radio.activeForeground",cC,m("radioActiveForeground","Foreground color of active radio option.")),KAe=R("radio.activeBackground",ab,m("radioBackground","Background color of active radio option.")),GAe=R("radio.activeBorder",lC,m("radioActiveBorder","Border color of the active radio option.")),YAe=R("radio.inactiveForeground",null,m("radioInactiveForeground","Foreground color of inactive radio option.")),ZAe=R("radio.inactiveBackground",null,m("radioInactiveBackground","Background color of inactive radio option.")),XAe=R("radio.inactiveBorder",{light:It(UL,.2),dark:It(UL,.2),hcDark:It(UL,.4),hcLight:It(UL,.2)},m("radioInactiveBorder","Border color of the inactive radio option.")),QAe=R("radio.inactiveHoverBackground",lat,m("radioHoverBackground","Background color of inactive active radio option when hovering.")),JAe=R("checkbox.background",$L,m("checkbox.background","Background color of checkbox widget.")),NUt=R("checkbox.selectBackground",Ca,m("checkbox.select.background","Background color of checkbox widget when the element it's in is selected.")),eMe=R("checkbox.foreground",rM,m("checkbox.foreground","Foreground color of checkbox widget.")),tMe=R("checkbox.border",sM,m("checkbox.border","Border color of checkbox widget.")),RUt=R("checkbox.selectBorder",rC,m("checkbox.select.border","Border color of checkbox widget when the element it's in is selected.")),iMe=R("keybindingLabel.background",{dark:new Z(new Ut(128,128,128,.17)),light:new Z(new Ut(221,221,221,.4)),hcDark:Z.transparent,hcLight:Z.transparent},m("keybindingLabelBackground","Keybinding label background color. The keybinding label is used to represent a keyboard shortcut.")),nMe=R("keybindingLabel.foreground",{dark:Z.fromHex("#CCCCCC"),light:Z.fromHex("#555555"),hcDark:Z.white,hcLight:Ht},m("keybindingLabelForeground","Keybinding label foreground color. The keybinding label is used to represent a keyboard shortcut.")),oMe=R("keybindingLabel.border",{dark:new Z(new Ut(51,51,51,.6)),light:new Z(new Ut(204,204,204,.4)),hcDark:new Z(new Ut(111,195,223)),hcLight:jt},m("keybindingLabelBorder","Keybinding label border color. The keybinding label is used to represent a keyboard shortcut.")),rMe=R("keybindingLabel.bottomBorder",{dark:new Z(new Ut(68,68,68,.6)),light:new Z(new Ut(187,187,187,.4)),hcDark:new Z(new Ut(111,195,223)),hcLight:Ht},m("keybindingLabelBottomBorder","Keybinding label border bottom color. The keybinding label is used to represent a keyboard shortcut."))});var sMe,aMe,lMe,cMe,Km,Gx,$9,dMe,uMe,hMe,fMe,pMe,Cse,Sse,mMe,gMe,Kx,_Me,BUt,WUt,HUt,bMe,vMe,xMe,wMe,zUt,VUt,UUt,kse,yMe,CMe,SMe,$Ut,jUt,qUt,KUt,j9=k(()=>{pe();vo();Ch();rb();qx();sMe=R("list.focusBackground",null,m("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.")),aMe=R("list.focusForeground",null,m("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.")),lMe=R("list.focusOutline",{dark:Su,light:Su,hcDark:Zi,hcLight:Zi},m("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.")),cMe=R("list.focusAndSelectionOutline",null,m("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.")),Km=R("list.activeSelectionBackground",{dark:"#04395E",light:"#0060C0",hcDark:null,hcLight:Z.fromHex("#0F4A85").transparent(.1)},m("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.")),Gx=R("list.activeSelectionForeground",{dark:Z.white,light:Z.white,hcDark:null,hcLight:null},m("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.")),$9=R("list.activeSelectionIconForeground",null,m("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.")),dMe=R("list.inactiveSelectionBackground",{dark:"#37373D",light:"#E4E6F1",hcDark:null,hcLight:Z.fromHex("#0F4A85").transparent(.1)},m("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.")),uMe=R("list.inactiveSelectionForeground",null,m("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.")),hMe=R("list.inactiveSelectionIconForeground",null,m("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.")),fMe=R("list.inactiveFocusBackground",null,m("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.")),pMe=R("list.inactiveFocusOutline",null,m("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.")),Cse=R("list.hoverBackground",{dark:"#2A2D2E",light:"#F0F0F0",hcDark:Z.white.transparent(.1),hcLight:Z.fromHex("#0F4A85").transparent(.1)},m("listHoverBackground","List/Tree background when hovering over items using the mouse.")),Sse=R("list.hoverForeground",null,m("listHoverForeground","List/Tree foreground when hovering over items using the mouse.")),mMe=R("list.dropBackground",{dark:"#062F4A",light:"#D6EBFF",hcDark:null,hcLight:null},m("listDropBackground","List/Tree drag and drop background when moving items over other items when using the mouse.")),gMe=R("list.dropBetweenBackground",{dark:rC,light:rC,hcDark:null,hcLight:null},m("listDropBetweenBackground","List/Tree drag and drop border color when moving items between items when using the mouse.")),Kx=R("list.highlightForeground",{dark:"#2AAAFF",light:"#0066BF",hcDark:Su,hcLight:Su},m("highlight","List/Tree foreground color of the match highlights when searching inside the list/tree.")),_Me=R("list.focusHighlightForeground",{dark:Kx,light:KRe(Km,Kx,"#BBE7FF"),hcDark:Kx,hcLight:Kx},m("listFocusHighlightForeground","List/Tree foreground color of the match highlights on actively focused items when searching inside the list/tree.")),BUt=R("list.invalidItemForeground",{dark:"#B89500",light:"#B89500",hcDark:"#B89500",hcLight:"#B5200D"},m("invalidItemForeground","List/Tree foreground color for invalid items, for example an unresolved root in explorer.")),WUt=R("list.errorForeground",{dark:"#F88070",light:"#B01011",hcDark:null,hcLight:null},m("listErrorForeground","Foreground color of list items containing errors.")),HUt=R("list.warningForeground",{dark:"#CCA700",light:"#855F00",hcDark:null,hcLight:null},m("listWarningForeground","Foreground color of list items containing warnings.")),bMe=R("listFilterWidget.background",{light:jm(Ca,0),dark:Cu(Ca,0),hcDark:Ca,hcLight:Ca},m("listFilterWidgetBackground","Background color of the type filter widget in lists and trees.")),vMe=R("listFilterWidget.outline",{dark:Z.transparent,light:Z.transparent,hcDark:"#f38518",hcLight:"#007ACC"},m("listFilterWidgetOutline","Outline color of the type filter widget in lists and trees.")),xMe=R("listFilterWidget.noMatchesOutline",{dark:"#BE1100",light:"#BE1100",hcDark:jt,hcLight:jt},m("listFilterWidgetNoMatchesOutline","Outline color of the type filter widget in lists and trees, when there are no matches.")),wMe=R("listFilterWidget.shadow",qm,m("listFilterWidgetShadow","Shadow color of the type filter widget in lists and trees.")),zUt=R("list.filterMatchBackground",{dark:Sh,light:Sh,hcDark:null,hcLight:null},m("listFilterMatchHighlight","Background color of the filtered match.")),VUt=R("list.filterMatchBorder",{dark:yf,light:yf,hcDark:jt,hcLight:Zi},m("listFilterMatchHighlightBorder","Border color of the filtered match.")),UUt=R("list.deemphasizedForeground",{dark:"#8C8C8C",light:"#8E8E90",hcDark:"#A7A8A9",hcLight:"#666666"},m("listDeemphasizedForeground","List/Tree foreground color for items that are deemphasized.")),kse=R("tree.indentGuidesStroke",{dark:"#585858",light:"#a9a9a9",hcDark:"#a9a9a9",hcLight:"#a5a5a5"},m("treeIndentGuidesStroke","Tree stroke color for the indentation guides.")),yMe=R("tree.inactiveIndentGuidesStroke",It(kse,.4),m("treeInactiveIndentGuidesStroke","Tree stroke color for the indentation guides that are not active.")),CMe=R("tree.tableColumnsBorder",{dark:"#CCCCCC20",light:"#61616120",hcDark:null,hcLight:null},m("tableColumnsBorder","Table border color between columns.")),SMe=R("tree.tableOddRowsBackground",{dark:It(Ht,.04),light:It(Ht,.04),hcDark:null,hcLight:null},m("tableOddRowsBackgroundColor","Background color for odd table rows.")),$Ut=R("editorActionList.background",Ca,m("editorActionListBackground","Action List background color.")),jUt=R("editorActionList.foreground",sC,m("editorActionListForeground","Action List foreground color.")),qUt=R("editorActionList.focusForeground",Gx,m("editorActionListFocusForeground","Action List foreground color for the focused item.")),KUt=R("editorActionList.focusBackground",Km,m("editorActionListFocusBackground","Action List background color for the focused item."))});var kMe,LMe,IMe,EMe,TMe,DMe,NMe,RMe=k(()=>{pe();Ch();rb();yse();j9();kMe=R("menu.border",{dark:null,light:null,hcDark:jt,hcLight:jt},m("menuBorder","Border color of menus.")),LMe=R("menu.foreground",rM,m("menuForeground","Foreground color of menu items.")),IMe=R("menu.background",$L,m("menuBackground","Background color of menu items.")),EMe=R("menu.selectionForeground",Gx,m("menuSelectionForeground","Foreground color of the selected menu item in menus.")),TMe=R("menu.selectionBackground",Km,m("menuSelectionBackground","Background color of the selected menu item in menus.")),DMe=R("menu.selectionBorder",{dark:null,light:null,hcDark:Zi,hcLight:Zi},m("menuSelectionBorder","Border color of the selected menu item in menus.")),NMe=R("menu.separatorBackground",{dark:"#606060",light:"#D4D4D4",hcDark:jt,hcLight:jt},m("menuSeparatorBackground","Color of a separator menu item in menus."))});var Lse,MMe,PMe,q9,OMe,AMe,lb,jL,cb,FMe=k(()=>{pe();vo();Ch();qx();j9();Lse=R("quickInput.background",Ca,m("pickerBackground","Quick picker background color. The quick picker widget is the container for pickers like the command palette.")),MMe=R("quickInput.foreground",sC,m("pickerForeground","Quick picker foreground color. The quick picker widget is the container for pickers like the command palette.")),PMe=R("quickInputTitle.background",{dark:new Z(new Ut(255,255,255,.105)),light:new Z(new Ut(0,0,0,.06)),hcDark:"#000000",hcLight:Z.white},m("pickerTitleBackground","Quick picker title background color. The quick picker widget is the container for pickers like the command palette.")),q9=R("pickerGroup.foreground",{dark:"#3794FF",light:"#0066BF",hcDark:Z.white,hcLight:"#0F4A85"},m("pickerGroupForeground","Quick picker color for grouping labels.")),OMe=R("pickerGroup.border",{dark:"#3F3F46",light:"#CCCEDB",hcDark:Z.white,hcLight:"#0F4A85"},m("pickerGroupBorder","Quick picker color for grouping borders.")),AMe=R("quickInput.list.focusBackground",null,"",void 0,m("quickInput.list.focusBackground deprecation","Please use quickInputList.focusBackground instead")),lb=R("quickInputList.focusForeground",Gx,m("quickInput.listFocusForeground","Quick picker foreground color for the focused item.")),jL=R("quickInputList.focusIconForeground",$9,m("quickInput.listFocusIconForeground","Quick picker icon foreground color for the focused item.")),cb=R("quickInputList.focusBackground",{dark:oC(AMe,Km),light:oC(AMe,Km),hcDark:null,hcLight:null},m("quickInput.listFocusBackground","Quick picker background color for the focused item."))});var l$t,c$t,d$t,BMe=k(()=>{pe();Ch();rb();qx();l$t=R("search.resultsInfoForeground",{light:Ht,dark:It(Ht,.65),hcDark:Ht,hcLight:Ht},m("search.resultsInfoForeground","Color of the text in the search viewlet's completion message.")),c$t=R("searchEditor.findMatchBackground",{light:It(Sh,.66),dark:It(Sh,.66),hcDark:Sh,hcLight:Sh},m("searchEditor.queryMatch","Color of the Search Editor query matches.")),d$t=R("searchEditor.findMatchBorder",{light:It(yf,.66),dark:It(yf,.66),hcDark:yf,hcLight:yf},m("searchEditor.editorFindMatchBorder","Border color of the Search Editor query matches."))});var Wn=k(()=>{Ch();rb();NAe();qx();yse();j9();RMe();xse();A9();FMe();BMe()});var dat,WMe,cc,Gm,db=k(()=>{Fe();j();en();ke();dat=function(n,e,t,i){var o=arguments.length,r=o<3?e:i===null?i=Object.getOwnPropertyDescriptor(e,t):i,s;if(typeof Reflect=="object"&&typeof Reflect.decorate=="function")r=Reflect.decorate(n,e,t,i);else for(var a=n.length-1;a>=0;a--)(s=n[a])&&(r=(o<3?s(r):o>3?s(e,t,r):s(e,t))||r);return o>3&&r&&Object.defineProperty(e,t,r),r},WMe=function(n,e){return function(t,i){e(t,i,n)}},cc=We("hoverService"),Gm=class extends D{get delay(){return this.isInstantlyHovering()?0:this._delay}constructor(e,t,i={},o,r){super(),this.placement=e,this.instantHover=t,this.overrideOptions=i,this.configurationService=o,this.hoverService=r,this.lastHoverHideTime=0,this.timeLimit=200,this.hoverDisposables=this._register(new H),this._delay=this.configurationService.getValue("workbench.hover.delay"),this._register(this.configurationService.onDidChangeConfiguration(s=>{s.affectsConfiguration("workbench.hover.delay")&&(this._delay=this.configurationService.getValue("workbench.hover.delay"))}))}showHover(e,t){let i=typeof this.overrideOptions=="function"?this.overrideOptions(e,t):this.overrideOptions;this.hoverDisposables.clear();let o=_n(e.target)?[e.target]:e.target.targetElements;for(let s of o)this.hoverDisposables.add(gi(s,"keydown",a=>{a.equals(9)&&this.hoverService.hideHover()}));let r=_n(e.content)?void 0:e.content.toString();return this.hoverService.showHover({...e,...i,persistence:{hideOnKeyDown:!0,...i.persistence},id:r,appearance:{...e.appearance,compact:!0,skipFadeInAnimation:this.isInstantlyHovering(),...i.appearance}},t)}isInstantlyHovering(){return this.instantHover&&Date.now()-this.lastHoverHideTime{Fe();dc=We("contextViewService"),sr=We("contextMenuService")});var HMe=k(()=>{});var _t,Pn=k(()=>{Fe();_t=We("keybindingService")});var kh,qL=k(()=>{ke();j();kh=class{constructor(){this._hooks=new H,this._pointerMoveCallback=null,this._onStopCallback=null}dispose(){this.stopMonitoring(!1),this._hooks.dispose()}stopMonitoring(e,t){if(!this.isMonitoring())return;this._hooks.clear(),this._pointerMoveCallback=null;let i=this._onStopCallback;this._onStopCallback=null,e&&i&&i(t)}isMonitoring(){return!!this._pointerMoveCallback}startMonitoring(e,t,i,o,r){this.isMonitoring()&&this.stopMonitoring(!1),this._pointerMoveCallback=o,this._onStopCallback=r;let s=e;try{e.setPointerCapture(t),this._hooks.add(ge(()=>{try{e.releasePointerCapture(t)}catch{}}))}catch{s=Me(e)}this._hooks.add(U(s,re.POINTER_MOVE,a=>{if(a.buttons!==i){this.stopMonitoring(!0);return}a.preventDefault(),this._pointerMoveCallback(a)})),this._hooks.add(U(s,re.POINTER_UP,a=>this.stopMonitoring(!0)))}}});function Hn(n,e,t){let i=null,o=null;if(typeof t.value=="function"?(i="value",o=t.value,o.length!==0&&console.warn("Memoize should only be used in functions with zero parameters")):typeof t.get=="function"&&(i="get",o=t.get),!o)throw new Error("not supported");let r=`$memoize$${e}`;t[i]=function(...s){return this.hasOwnProperty(r)||Object.defineProperty(this,r,{configurable:!1,enumerable:!1,writable:!1,value:o.apply(this,s)}),this[r]}}var Yx=k(()=>{});var uat,Mi,so,Pd=k(()=>{ke();Il();at();Yx();Ie();j();du();uat=function(n,e,t,i){var o=arguments.length,r=o<3?e:i===null?i=Object.getOwnPropertyDescriptor(e,t):i,s;if(typeof Reflect=="object"&&typeof Reflect.decorate=="function")r=Reflect.decorate(n,e,t,i);else for(var a=n.length-1;a>=0;a--)(s=n[a])&&(r=(o<3?s(r):o>3?s(e,t,r):s(e,t))||r);return o>3&&r&&Object.defineProperty(e,t,r),r};(function(n){n.Tap="-monaco-gesturetap",n.Change="-monaco-gesturechange",n.Start="-monaco-gesturestart",n.End="-monaco-gesturesend",n.Contextmenu="-monaco-gesturecontextmenu"})(Mi||(Mi={}));so=class n extends D{static{this.SCROLL_FRICTION=-.005}static{this.HOLD_DELAY=700}static{this.CLEAR_TAP_COUNT_TIME=400}constructor(){super(),this.dispatched=!1,this.targets=new go,this.ignoreTargets=new go,this.activeTouches={},this.handle=null,this._lastSetTapCountTime=0,this._register(ne.runAndSubscribe(I1,({window:e,disposables:t})=>{t.add(U(e.document,"touchstart",i=>this.onTouchStart(i),{passive:!1})),t.add(U(e.document,"touchend",i=>this.onTouchEnd(e,i))),t.add(U(e.document,"touchmove",i=>this.onTouchMove(i),{passive:!1}))},{window:ri,disposables:this._store}))}static addTarget(e){if(!n.isTouchDevice())return D.None;n.INSTANCE||(n.INSTANCE=lx(new n));let t=n.INSTANCE.targets.push(e);return ge(t)}static ignoreTarget(e){if(!n.isTouchDevice())return D.None;n.INSTANCE||(n.INSTANCE=lx(new n));let t=n.INSTANCE.ignoreTargets.push(e);return ge(t)}static isTouchDevice(){return"ontouchstart"in ri||navigator.maxTouchPoints>0}dispose(){this.handle&&(this.handle.dispose(),this.handle=null),super.dispose()}onTouchStart(e){let t=Date.now();this.handle&&(this.handle.dispose(),this.handle=null);for(let i=0,o=e.targetTouches.length;i=n.HOLD_DELAY&&Math.abs(l.initialPageX-lu(l.rollingPageX))<30&&Math.abs(l.initialPageY-lu(l.rollingPageY))<30){let d=this.newGestureEvent(Mi.Contextmenu,l.initialTarget);d.pageX=lu(l.rollingPageX),d.pageY=lu(l.rollingPageY),this.dispatchEvent(d)}else if(o===1){let d=lu(l.rollingPageX),u=lu(l.rollingPageY),h=lu(l.rollingTimestamps)-l.rollingTimestamps[0],f=d-l.rollingPageX[0],p=u-l.rollingPageY[0],g=[...this.targets].filter(_=>l.initialTarget instanceof Node&&_.contains(l.initialTarget));this.inertia(e,g,i,Math.abs(f)/h,f>0?1:-1,d,Math.abs(p)/h,p>0?1:-1,u)}this.dispatchEvent(this.newGestureEvent(Mi.End,l.initialTarget)),delete this.activeTouches[a.identifier]}this.dispatched&&(t.preventDefault(),t.stopPropagation(),this.dispatched=!1)}newGestureEvent(e,t){let i=document.createEvent("CustomEvent");return i.initEvent(e,!1,!0),i.initialTarget=t,i.tapCount=0,i}dispatchEvent(e){if(e.type===Mi.Tap){let t=new Date().getTime(),i=0;t-this._lastSetTapCountTime>n.CLEAR_TAP_COUNT_TIME?i=1:i=2,this._lastSetTapCountTime=t,e.tapCount=i}else(e.type===Mi.Change||e.type===Mi.Contextmenu)&&(this._lastSetTapCountTime=0);if(e.initialTarget instanceof Node){for(let i of this.ignoreTargets)if(i.contains(e.initialTarget))return;let t=[];for(let i of this.targets)if(i.contains(e.initialTarget)){let o=0,r=e.initialTarget;for(;r&&r!==i;)o++,r=r.parentElement;t.push([o,i])}t.sort((i,o)=>i[0]-o[0]);for(let[i,o]of t)o.dispatchEvent(e),this.dispatched=!0}}inertia(e,t,i,o,r,s,a,l,c){this.handle=us(e,()=>{let d=Date.now(),u=d-i,h=0,f=0,p=!0;o+=n.SCROLL_FRICTION*u,a+=n.SCROLL_FRICTION*u,o>0&&(p=!1,h=r*o*u),a>0&&(p=!1,f=l*a*u);let g=this.newGestureEvent(Mi.Change);g.translationX=h,g.translationY=f,t.forEach(_=>_.dispatchEvent(g)),p||this.inertia(e,t,d,o,r,s+h,a,l,c+f)})}onTouchMove(e){let t=Date.now();for(let i=0,o=e.changedTouches.length;i3&&(s.rollingPageX.shift(),s.rollingPageY.shift(),s.rollingTimestamps.shift()),s.rollingPageX.push(r.pageX),s.rollingPageY.push(r.pageY),s.rollingTimestamps.push(t)}this.dispatched&&(e.preventDefault(),e.stopPropagation(),this.dispatched=!1)}};uat([Hn],so,"isTouchDevice",null)});var Yo,Lh=k(()=>{ke();Ks();pu();Pd();j();Yo=class extends D{onclick(e,t){this._register(U(e,re.CLICK,i=>t(new cs(Me(e),i))))}onmousedown(e,t){this._register(U(e,re.MOUSE_DOWN,i=>t(new cs(Me(e),i))))}onmouseover(e,t){this._register(U(e,re.MOUSE_OVER,i=>t(new cs(Me(e),i))))}onmouseleave(e,t){this._register(U(e,re.MOUSE_LEAVE,i=>t(new cs(Me(e),i))))}onkeydown(e,t){this._register(U(e,re.KEY_DOWN,i=>t(new Xt(i))))}onkeyup(e,t){this._register(U(e,re.KEY_UP,i=>t(new Xt(i))))}oninput(e,t){this._register(U(e,re.INPUT,t))}onblur(e,t){this._register(U(e,re.BLUR,t))}onfocus(e,t){this._register(U(e,re.FOCUS,t))}ignoreGesture(e){return so.ignoreTarget(e)}}});var Zx,K9,G9=k(()=>{qL();Lh();ft();bn();ke();Zx=11,K9=class extends Yo{constructor(e){super(),this._onActivate=e.onActivate,this.bgDomNode=document.createElement("div"),this.bgDomNode.className="arrow-background",this.bgDomNode.style.position="absolute",this.bgDomNode.style.width=e.bgWidth+"px",this.bgDomNode.style.height=e.bgHeight+"px",typeof e.top<"u"&&(this.bgDomNode.style.top="0px"),typeof e.left<"u"&&(this.bgDomNode.style.left="0px"),typeof e.bottom<"u"&&(this.bgDomNode.style.bottom="0px"),typeof e.right<"u"&&(this.bgDomNode.style.right="0px"),this.domNode=document.createElement("div"),this.domNode.className=e.className,this.domNode.classList.add(...Oe.asClassNameArray(e.icon)),this.domNode.style.position="absolute",this.domNode.style.width=Zx+"px",this.domNode.style.height=Zx+"px",typeof e.top<"u"&&(this.domNode.style.top=e.top+"px"),typeof e.left<"u"&&(this.domNode.style.left=e.left+"px"),typeof e.bottom<"u"&&(this.domNode.style.bottom=e.bottom+"px"),typeof e.right<"u"&&(this.domNode.style.right=e.right+"px"),this._pointerMoveMonitor=this._register(new kh),this._register(gi(this.bgDomNode,re.POINTER_DOWN,t=>this._arrowPointerDown(t))),this._register(gi(this.domNode,re.POINTER_DOWN,t=>this._arrowPointerDown(t))),this._pointerdownRepeatTimer=this._register(new yx),this._pointerdownScheduleRepeatTimer=this._register(new _r)}_arrowPointerDown(e){if(!e.target||!(e.target instanceof Element))return;let t=()=>{this._pointerdownRepeatTimer.cancelAndSet(()=>this._onActivate(),1e3/24,Me(e))};this._onActivate(),this._pointerdownRepeatTimer.cancel(),this._pointerdownScheduleRepeatTimer.cancelAndSet(t,200),this._pointerMoveMonitor.startMonitoring(e.target,e.pointerId,e.buttons,i=>{},()=>{this._pointerdownRepeatTimer.cancel(),this._pointerdownScheduleRepeatTimer.cancel()}),e.preventDefault()}}});var Y9,zMe=k(()=>{ft();j();Y9=class extends D{constructor(e,t,i){super(),this._visibility=e,this._visibleClassName=t,this._invisibleClassName=i,this._domNode=null,this._isVisible=!1,this._isNeeded=!1,this._rawShouldBeVisible=!1,this._shouldBeVisible=!1,this._revealTimer=this._register(new _r)}setVisibility(e){this._visibility!==e&&(this._visibility=e,this._updateShouldBeVisible())}setShouldBeVisible(e){this._rawShouldBeVisible=e,this._updateShouldBeVisible()}_applyVisibilitySetting(){return this._visibility===2?!1:this._visibility===3?!0:this._rawShouldBeVisible}_updateShouldBeVisible(){let e=this._applyVisibilitySetting();this._shouldBeVisible!==e&&(this._shouldBeVisible=e,this.ensureVisibility())}setIsNeeded(e){this._isNeeded!==e&&(this._isNeeded=e,this.ensureVisibility())}setDomNode(e){this._domNode=e,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(()=>{this._domNode?.setClassName(this._visibleClassName)},0))}_hide(e){this._revealTimer.cancel(),this._isVisible&&(this._isVisible=!1,this._domNode?.setClassName(this._invisibleClassName+(e?" fade":"")))}}});var hat,KL,Ise=k(()=>{ke();Kr();qL();G9();zMe();Lh();Bt();hat=140,KL=class extends Yo{constructor(e){super(),this._lazyRender=e.lazyRender,this._host=e.host,this._scrollable=e.scrollable,this._scrollByPage=e.scrollByPage,this._scrollbarState=e.scrollbarState,this._visibilityController=this._register(new Y9(e.visibility,"visible scrollbar "+e.extraScrollbarClassName,"invisible scrollbar "+e.extraScrollbarClassName)),this._visibilityController.setIsNeeded(this._scrollbarState.isNeeded()),this._pointerMoveMonitor=this._register(new kh),this._shouldRender=!0,this.domNode=Pt(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(U(this.domNode.domNode,re.POINTER_DOWN,t=>this._domNodePointerDown(t)))}_createArrow(e){let t=this._register(new K9(e));this.domNode.domNode.appendChild(t.bgDomNode),this.domNode.domNode.appendChild(t.domNode)}_createSlider(e,t,i,o){this.slider=Pt(document.createElement("div")),this.slider.setClassName("slider"),this.slider.setPosition("absolute"),this.slider.setTop(e),this.slider.setLeft(t),typeof i=="number"&&this.slider.setWidth(i),typeof o=="number"&&this.slider.setHeight(o),this.slider.setLayerHinting(!0),this.slider.setContain("strict"),this.domNode.domNode.appendChild(this.slider.domNode),this._register(U(this.slider.domNode,re.POINTER_DOWN,r=>{r.button===0&&(r.preventDefault(),this._sliderPointerDown(r))})),this.onclick(this.slider.domNode,r=>{r.leftButton&&r.stopPropagation()})}_onElementSize(e){return this._scrollbarState.setVisibleSize(e)&&(this._visibilityController.setIsNeeded(this._scrollbarState.isNeeded()),this._shouldRender=!0,this._lazyRender||this.render()),this._shouldRender}_onElementScrollSize(e){return this._scrollbarState.setScrollSize(e)&&(this._visibilityController.setIsNeeded(this._scrollbarState.isNeeded()),this._shouldRender=!0,this._lazyRender||this.render()),this._shouldRender}_onElementScrollPosition(e){return this._scrollbarState.setScrollPosition(e)&&(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(e){e.target===this.domNode.domNode&&this._onPointerDown(e)}delegatePointerDown(e){let t=this.domNode.domNode.getClientRects()[0].top,i=t+this._scrollbarState.getSliderPosition(),o=t+this._scrollbarState.getSliderPosition()+this._scrollbarState.getSliderSize(),r=this._sliderPointerPosition(e);i<=r&&r<=o?e.button===0&&(e.preventDefault(),this._sliderPointerDown(e)):this._onPointerDown(e)}_onPointerDown(e){let t,i;if(e.target===this.domNode.domNode&&typeof e.offsetX=="number"&&typeof e.offsetY=="number")t=e.offsetX,i=e.offsetY;else{let r=Ci(this.domNode.domNode);t=e.pageX-r.left,i=e.pageY-r.top}let o=this._pointerDownRelativePosition(t,i);this._setDesiredScrollPositionNow(this._scrollByPage?this._scrollbarState.getDesiredScrollPositionFromOffsetPaged(o):this._scrollbarState.getDesiredScrollPositionFromOffset(o)),e.button===0&&(e.preventDefault(),this._sliderPointerDown(e))}_sliderPointerDown(e){if(!e.target||!(e.target instanceof Element))return;let t=this._sliderPointerPosition(e),i=this._sliderOrthogonalPointerPosition(e),o=this._scrollbarState.clone();this.slider.toggleClassName("active",!0),this._pointerMoveMonitor.startMonitoring(e.target,e.pointerId,e.buttons,r=>{let s=this._sliderOrthogonalPointerPosition(r),a=Math.abs(s-i);if(kn&&a>hat){this._setDesiredScrollPositionNow(o.getScrollPosition());return}let c=this._sliderPointerPosition(r)-t;this._setDesiredScrollPositionNow(o.getDesiredScrollPositionFromDelta(c))},()=>{this.slider.toggleClassName("active",!1),this._host.onDragEnd()}),this._host.onDragStart()}_setDesiredScrollPositionNow(e){let t={};this.writeScrollPosition(t,e),this._scrollable.setScrollPositionNow(t)}updateScrollbarSize(e){this._updateScrollbarSize(e),this._scrollbarState.setScrollbarSize(e),this._shouldRender=!0,this._lazyRender||this.render()}isNeeded(){return this._scrollbarState.isNeeded()}}});var Xx,Z9=k(()=>{Xx=class n{constructor(e,t,i,o,r,s){this._scrollbarSize=Math.round(t),this._oppositeScrollbarSize=Math.round(i),this._arrowSize=Math.round(e),this._visibleSize=o,this._scrollSize=r,this._scrollPosition=s,this._computedAvailableSize=0,this._computedIsNeeded=!1,this._computedSliderSize=0,this._computedSliderRatio=0,this._computedSliderPosition=0,this._refreshComputedValues()}clone(){return new n(this._arrowSize,this._scrollbarSize,this._oppositeScrollbarSize,this._visibleSize,this._scrollSize,this._scrollPosition)}setVisibleSize(e){let t=Math.round(e);return this._visibleSize!==t?(this._visibleSize=t,this._refreshComputedValues(),!0):!1}setScrollSize(e){let t=Math.round(e);return this._scrollSize!==t?(this._scrollSize=t,this._refreshComputedValues(),!0):!1}setScrollPosition(e){let t=Math.round(e);return this._scrollPosition!==t?(this._scrollPosition=t,this._refreshComputedValues(),!0):!1}setScrollbarSize(e){this._scrollbarSize=Math.round(e)}setOppositeScrollbarSize(e){this._oppositeScrollbarSize=Math.round(e)}static _computeValues(e,t,i,o,r){let s=Math.max(0,i-e),a=Math.max(0,s-2*t),l=o>0&&o>i;if(!l)return{computedAvailableSize:Math.round(s),computedIsNeeded:l,computedSliderSize:Math.round(a),computedSliderRatio:0,computedSliderPosition:0};let c=Math.round(Math.max(20,Math.floor(i*a/o))),d=(a-c)/(o-i),u=r*d;return{computedAvailableSize:Math.round(s),computedIsNeeded:l,computedSliderSize:Math.round(c),computedSliderRatio:d,computedSliderPosition:Math.round(u)}}_refreshComputedValues(){let e=n._computeValues(this._oppositeScrollbarSize,this._arrowSize,this._visibleSize,this._scrollSize,this._scrollPosition);this._computedAvailableSize=e.computedAvailableSize,this._computedIsNeeded=e.computedIsNeeded,this._computedSliderSize=e.computedSliderSize,this._computedSliderRatio=e.computedSliderRatio,this._computedSliderPosition=e.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(e){if(!this._computedIsNeeded)return 0;let t=e-this._arrowSize-this._computedSliderSize/2;return Math.round(t/this._computedSliderRatio)}getDesiredScrollPositionFromOffsetPaged(e){if(!this._computedIsNeeded)return 0;let t=e-this._arrowSize,i=this._scrollPosition;return t{pu();Ise();G9();Z9();Qi();X9=class extends KL{constructor(e,t,i){let o=e.getScrollDimensions(),r=e.getCurrentScrollPosition();if(super({lazyRender:t.lazyRender,host:i,scrollbarState:new Xx(t.horizontalHasArrows?t.arrowSize:0,t.horizontal===2?0:t.horizontalScrollbarSize,t.vertical===2?0:t.verticalScrollbarSize,o.width,o.scrollWidth,r.scrollLeft),visibility:t.horizontal,extraScrollbarClassName:"horizontal",scrollable:e,scrollByPage:t.scrollByPage}),t.horizontalHasArrows){let s=(t.arrowSize-Zx)/2,a=(t.horizontalScrollbarSize-Zx)/2;this._createArrow({className:"scra",icon:oe.scrollbarButtonLeft,top:a,left:s,bottom:void 0,right:void 0,bgWidth:t.arrowSize,bgHeight:t.horizontalScrollbarSize,onActivate:()=>this._host.onMouseWheel(new ph(null,1,0))}),this._createArrow({className:"scra",icon:oe.scrollbarButtonRight,top:a,left:void 0,bottom:void 0,right:s,bgWidth:t.arrowSize,bgHeight:t.horizontalScrollbarSize,onActivate:()=>this._host.onMouseWheel(new ph(null,-1,0))})}this._createSlider(Math.floor((t.horizontalScrollbarSize-t.horizontalSliderSize)/2),0,void 0,t.horizontalSliderSize)}_updateSlider(e,t){this.slider.setWidth(e),this.slider.setLeft(t)}_renderDomNode(e,t){this.domNode.setWidth(e),this.domNode.setHeight(t),this.domNode.setLeft(0),this.domNode.setBottom(0)}onDidScroll(e){return this._shouldRender=this._onElementScrollSize(e.scrollWidth)||this._shouldRender,this._shouldRender=this._onElementScrollPosition(e.scrollLeft)||this._shouldRender,this._shouldRender=this._onElementSize(e.width)||this._shouldRender,this._shouldRender}_pointerDownRelativePosition(e,t){return e}_sliderPointerPosition(e){return e.pageX}_sliderOrthogonalPointerPosition(e){return e.pageY}_updateScrollbarSize(e){this.slider.setHeight(e)}writeScrollPosition(e,t){e.scrollLeft=t}updateOptions(e){this.updateScrollbarSize(e.horizontal===2?0:e.horizontalScrollbarSize),this._scrollbarState.setOppositeScrollbarSize(e.vertical===2?0:e.verticalScrollbarSize),this._visibilityController.setVisibility(e.horizontal),this._scrollByPage=e.scrollByPage}}});var Q9,UMe=k(()=>{pu();Ise();G9();Z9();Qi();Q9=class extends KL{constructor(e,t,i){let o=e.getScrollDimensions(),r=e.getCurrentScrollPosition();if(super({lazyRender:t.lazyRender,host:i,scrollbarState:new Xx(t.verticalHasArrows?t.arrowSize:0,t.vertical===2?0:t.verticalScrollbarSize,0,o.height,o.scrollHeight,r.scrollTop),visibility:t.vertical,extraScrollbarClassName:"vertical",scrollable:e,scrollByPage:t.scrollByPage}),t.verticalHasArrows){let s=(t.arrowSize-Zx)/2,a=(t.verticalScrollbarSize-Zx)/2;this._createArrow({className:"scra",icon:oe.scrollbarButtonUp,top:s,left:a,bottom:void 0,right:void 0,bgWidth:t.verticalScrollbarSize,bgHeight:t.arrowSize,onActivate:()=>this._host.onMouseWheel(new ph(null,0,1))}),this._createArrow({className:"scra",icon:oe.scrollbarButtonDown,top:void 0,left:a,bottom:s,right:void 0,bgWidth:t.verticalScrollbarSize,bgHeight:t.arrowSize,onActivate:()=>this._host.onMouseWheel(new ph(null,0,-1))})}this._createSlider(0,Math.floor((t.verticalScrollbarSize-t.verticalSliderSize)/2),t.verticalSliderSize,void 0)}_updateSlider(e,t){this.slider.setHeight(e),this.slider.setTop(t)}_renderDomNode(e,t){this.domNode.setWidth(t),this.domNode.setHeight(e),this.domNode.setRight(0),this.domNode.setTop(0)}onDidScroll(e){return this._shouldRender=this._onElementScrollSize(e.scrollHeight)||this._shouldRender,this._shouldRender=this._onElementScrollPosition(e.scrollTop)||this._shouldRender,this._shouldRender=this._onElementSize(e.height)||this._shouldRender,this._shouldRender}_pointerDownRelativePosition(e,t){return t}_sliderPointerPosition(e){return e.pageY}_sliderOrthogonalPointerPosition(e){return e.pageX}_updateScrollbarSize(e){this.slider.setWidth(e)}writeScrollPosition(e,t){e.scrollTop=t}updateOptions(e){this.updateScrollbarSize(e.vertical===2?0:e.verticalScrollbarSize),this._scrollbarState.setOppositeScrollbarSize(0),this._visibilityController.setVisibility(e.vertical),this._scrollByPage=e.scrollByPage}}});function Ese(n,e){let t=e-n;return function(i){return n+t*mat(i)}}function fat(n,e,t){return function(i){return i{Ie();j();Tse=class n{constructor(e,t,i,o,r,s,a){this._forceIntegerValues=e,this._scrollStateBrand=void 0,this._forceIntegerValues&&(t=t|0,i=i|0,o=o|0,r=r|0,s=s|0,a=a|0),this.rawScrollLeft=o,this.rawScrollTop=a,t<0&&(t=0),o+t>i&&(o=i-t),o<0&&(o=0),r<0&&(r=0),a+r>s&&(a=s-r),a<0&&(a=0),this.width=t,this.scrollWidth=i,this.scrollLeft=o,this.height=r,this.scrollHeight=s,this.scrollTop=a}equals(e){return this.rawScrollLeft===e.rawScrollLeft&&this.rawScrollTop===e.rawScrollTop&&this.width===e.width&&this.scrollWidth===e.scrollWidth&&this.scrollLeft===e.scrollLeft&&this.height===e.height&&this.scrollHeight===e.scrollHeight&&this.scrollTop===e.scrollTop}withScrollDimensions(e,t){return new n(this._forceIntegerValues,typeof e.width<"u"?e.width:this.width,typeof e.scrollWidth<"u"?e.scrollWidth:this.scrollWidth,t?this.rawScrollLeft:this.scrollLeft,typeof e.height<"u"?e.height:this.height,typeof e.scrollHeight<"u"?e.scrollHeight:this.scrollHeight,t?this.rawScrollTop:this.scrollTop)}withScrollPosition(e){return new n(this._forceIntegerValues,this.width,this.scrollWidth,typeof e.scrollLeft<"u"?e.scrollLeft:this.rawScrollLeft,this.height,this.scrollHeight,typeof e.scrollTop<"u"?e.scrollTop:this.rawScrollTop)}createScrollEvent(e,t){let i=this.width!==e.width,o=this.scrollWidth!==e.scrollWidth,r=this.scrollLeft!==e.scrollLeft,s=this.height!==e.height,a=this.scrollHeight!==e.scrollHeight,l=this.scrollTop!==e.scrollTop;return{inSmoothScrolling:t,oldWidth:e.width,oldScrollWidth:e.scrollWidth,oldScrollLeft:e.scrollLeft,width:this.width,scrollWidth:this.scrollWidth,scrollLeft:this.scrollLeft,oldHeight:e.height,oldScrollHeight:e.scrollHeight,oldScrollTop:e.scrollTop,height:this.height,scrollHeight:this.scrollHeight,scrollTop:this.scrollTop,widthChanged:i,scrollWidthChanged:o,scrollLeftChanged:r,heightChanged:s,scrollHeightChanged:a,scrollTopChanged:l}}},Ih=class extends D{constructor(e){super(),this._scrollableBrand=void 0,this._onScroll=this._register(new A),this.onScroll=this._onScroll.event,this._smoothScrollDuration=e.smoothScrollDuration,this._scheduleAtNextAnimationFrame=e.scheduleAtNextAnimationFrame,this._state=new Tse(e.forceIntegerValues,0,0,0,0,0,0),this._smoothScrolling=null}dispose(){this._smoothScrolling&&(this._smoothScrolling.dispose(),this._smoothScrolling=null),super.dispose()}setSmoothScrollDuration(e){this._smoothScrollDuration=e}validateScrollPosition(e){return this._state.withScrollPosition(e)}getScrollDimensions(){return this._state}setScrollDimensions(e,t){let i=this._state.withScrollDimensions(e,t);this._setState(i,!!this._smoothScrolling),this._smoothScrolling?.acceptScrollDimensions(this._state)}getFutureScrollPosition(){return this._smoothScrolling?this._smoothScrolling.to:this._state}getCurrentScrollPosition(){return this._state}setScrollPositionNow(e){let t=this._state.withScrollPosition(e);this._smoothScrolling&&(this._smoothScrolling.dispose(),this._smoothScrolling=null),this._setState(t,!1)}setScrollPositionSmooth(e,t){if(this._smoothScrollDuration===0)return this.setScrollPositionNow(e);if(this._smoothScrolling){e={scrollLeft:typeof e.scrollLeft>"u"?this._smoothScrolling.to.scrollLeft:e.scrollLeft,scrollTop:typeof e.scrollTop>"u"?this._smoothScrolling.to.scrollTop:e.scrollTop};let i=this._state.withScrollPosition(e);if(this._smoothScrolling.to.scrollLeft===i.scrollLeft&&this._smoothScrolling.to.scrollTop===i.scrollTop)return;let o;t?o=new e7(this._smoothScrolling.from,i,this._smoothScrolling.startTime,this._smoothScrolling.duration):o=this._smoothScrolling.combine(this._state,i,this._smoothScrollDuration),this._smoothScrolling.dispose(),this._smoothScrolling=o}else{let i=this._state.withScrollPosition(e);this._smoothScrolling=e7.start(this._state,i,this._smoothScrollDuration)}this._smoothScrolling.animationFrameDisposable=this._scheduleAtNextAnimationFrame(()=>{this._smoothScrolling&&(this._smoothScrolling.animationFrameDisposable=null,this._performSmoothScrolling())})}hasPendingScrollAnimation(){return!!this._smoothScrolling}_performSmoothScrolling(){if(!this._smoothScrolling)return;let e=this._smoothScrolling.tick(),t=this._state.withScrollPosition(e);if(this._setState(t,!0),!!this._smoothScrolling){if(e.isDone){this._smoothScrolling.dispose(),this._smoothScrolling=null;return}this._smoothScrolling.animationFrameDisposable=this._scheduleAtNextAnimationFrame(()=>{this._smoothScrolling&&(this._smoothScrolling.animationFrameDisposable=null,this._performSmoothScrolling())})}}_setState(e,t){let i=this._state;i.equals(e)||(this._state=e,this._onScroll.fire(this._state.createScrollEvent(i,t)))}},J9=class{constructor(e,t,i){this.scrollLeft=e,this.scrollTop=t,this.isDone=i}};e7=class n{constructor(e,t,i,o){this.from=e,this.to=t,this.duration=o,this.startTime=i,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(e,t,i){if(Math.abs(e-t)>2.5*i){let r,s;return e{});function _at(n){let e={lazyRender:typeof n.lazyRender<"u"?n.lazyRender:!1,className:typeof n.className<"u"?n.className:"",useShadows:typeof n.useShadows<"u"?n.useShadows:!0,handleMouseWheel:typeof n.handleMouseWheel<"u"?n.handleMouseWheel:!0,flipAxes:typeof n.flipAxes<"u"?n.flipAxes:!1,consumeMouseWheelIfScrollbarIsNeeded:typeof n.consumeMouseWheelIfScrollbarIsNeeded<"u"?n.consumeMouseWheelIfScrollbarIsNeeded:!1,alwaysConsumeMouseWheel:typeof n.alwaysConsumeMouseWheel<"u"?n.alwaysConsumeMouseWheel:!1,scrollYToX:typeof n.scrollYToX<"u"?n.scrollYToX:!1,mouseWheelScrollSensitivity:typeof n.mouseWheelScrollSensitivity<"u"?n.mouseWheelScrollSensitivity:1,fastScrollSensitivity:typeof n.fastScrollSensitivity<"u"?n.fastScrollSensitivity:5,scrollPredominantAxis:typeof n.scrollPredominantAxis<"u"?n.scrollPredominantAxis:!0,mouseWheelSmoothScroll:typeof n.mouseWheelSmoothScroll<"u"?n.mouseWheelSmoothScroll:!0,arrowSize:typeof n.arrowSize<"u"?n.arrowSize:11,listenOnDomNode:typeof n.listenOnDomNode<"u"?n.listenOnDomNode:null,horizontal:typeof n.horizontal<"u"?n.horizontal:1,horizontalScrollbarSize:typeof n.horizontalScrollbarSize<"u"?n.horizontalScrollbarSize:10,horizontalSliderSize:typeof n.horizontalSliderSize<"u"?n.horizontalSliderSize:0,horizontalHasArrows:typeof n.horizontalHasArrows<"u"?n.horizontalHasArrows:!1,vertical:typeof n.vertical<"u"?n.vertical:1,verticalScrollbarSize:typeof n.verticalScrollbarSize<"u"?n.verticalScrollbarSize:10,verticalHasArrows:typeof n.verticalHasArrows<"u"?n.verticalHasArrows:!1,verticalSliderSize:typeof n.verticalSliderSize<"u"?n.verticalSliderSize:0,scrollByPage:typeof n.scrollByPage<"u"?n.scrollByPage:!1};return e.horizontalSliderSize=typeof n.horizontalSliderSize<"u"?n.horizontalSliderSize:e.horizontalScrollbarSize,e.verticalSliderSize=typeof n.verticalSliderSize<"u"?n.verticalSliderSize:e.verticalScrollbarSize,dt&&(e.className+=" mac"),e}var gat,jMe,qMe,Dse,aM,lM,YL,Ym,Cf,Eh=k(()=>{Fc();ke();Kr();pu();VMe();UMe();Lh();ft();Ie();j();Bt();GL();$Me();gat=500,jMe=50,qMe=!0,Dse=class{constructor(e,t,i){this.timestamp=e,this.deltaX=t,this.deltaY=i,this.score=0}},aM=class n{static{this.INSTANCE=new n}constructor(){this._capacity=5,this._memory=[],this._front=-1,this._rear=-1}isPhysicalMouseWheel(){if(this._front===-1&&this._rear===-1)return!1;let e=1,t=0,i=1,o=this._rear;do{let r=o===this._front?e:Math.pow(2,-i);if(e-=r,t+=this._memory[o].score*r,o===this._front)break;o=(this._capacity+o-1)%this._capacity,i++}while(!0);return t<=.5}acceptStandardWheelEvent(e){if(bx){let t=Me(e.browserEvent),i=jTe(t);this.accept(Date.now(),e.deltaX*i,e.deltaY*i)}else this.accept(Date.now(),e.deltaX,e.deltaY)}accept(e,t,i){let o=null,r=new Dse(e,t,i);this._front===-1&&this._rear===-1?(this._memory[0]=r,this._front=0,this._rear=0):(o=this._memory[this._rear],this._rear=(this._rear+1)%this._capacity,this._rear===this._front&&(this._front=(this._front+1)%this._capacity),this._memory[this._rear]=r),r.score=this._computeScore(r,o)}_computeScore(e,t){if(Math.abs(e.deltaX)>0&&Math.abs(e.deltaY)>0)return 1;let i=.5;if((!this._isAlmostInt(e.deltaX)||!this._isAlmostInt(e.deltaY))&&(i+=.25),t){let o=Math.abs(e.deltaX),r=Math.abs(e.deltaY),s=Math.abs(t.deltaX),a=Math.abs(t.deltaY),l=Math.max(Math.min(o,s),1),c=Math.max(Math.min(r,a),1),d=Math.max(o,s),u=Math.max(r,a);d%l===0&&u%c===0&&(i-=.5)}return Math.min(Math.max(i,0),1)}_isAlmostInt(e){return Math.abs(Math.round(e)-e)<.01}},lM=class extends Yo{get options(){return this._options}constructor(e,t,i){super(),this._onScroll=this._register(new A),this.onScroll=this._onScroll.event,this._onWillScroll=this._register(new A),e.style.overflow="hidden",this._options=_at(t),this._scrollable=i,this._register(this._scrollable.onScroll(r=>{this._onWillScroll.fire(r),this._onDidScroll(r),this._onScroll.fire(r)}));let o={onMouseWheel:r=>this._onMouseWheel(r),onDragStart:()=>this._onDragStart(),onDragEnd:()=>this._onDragEnd()};this._verticalScrollbar=this._register(new Q9(this._scrollable,this._options,o)),this._horizontalScrollbar=this._register(new X9(this._scrollable,this._options,o)),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(e),this._domNode.appendChild(this._horizontalScrollbar.domNode.domNode),this._domNode.appendChild(this._verticalScrollbar.domNode.domNode),this._options.useShadows?(this._leftShadowDomNode=Pt(document.createElement("div")),this._leftShadowDomNode.setClassName("shadow"),this._domNode.appendChild(this._leftShadowDomNode.domNode),this._topShadowDomNode=Pt(document.createElement("div")),this._topShadowDomNode.setClassName("shadow"),this._domNode.appendChild(this._topShadowDomNode.domNode),this._topLeftShadowDomNode=Pt(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,r=>this._onMouseOver(r)),this.onmouseleave(this._listenOnDomNode,r=>this._onMouseLeave(r)),this._hideTimeout=this._register(new _r),this._isDragging=!1,this._mouseIsOver=!1,this._shouldRender=!0,this._revealOnScroll=!0}dispose(){this._mouseWheelToDispose=Yt(this._mouseWheelToDispose),super.dispose()}getDomNode(){return this._domNode}getOverviewRulerLayoutInfo(){return{parent:this._domNode,insertBefore:this._verticalScrollbar.domNode.domNode}}delegateVerticalScrollbarPointerDown(e){this._verticalScrollbar.delegatePointerDown(e)}getScrollDimensions(){return this._scrollable.getScrollDimensions()}setScrollDimensions(e){this._scrollable.setScrollDimensions(e,!1)}updateClassName(e){this._options.className=e,dt&&(this._options.className+=" mac"),this._domNode.className="monaco-scrollable-element "+this._options.className}updateOptions(e){typeof e.handleMouseWheel<"u"&&(this._options.handleMouseWheel=e.handleMouseWheel,this._setListeningToMouseWheel(this._options.handleMouseWheel)),typeof e.mouseWheelScrollSensitivity<"u"&&(this._options.mouseWheelScrollSensitivity=e.mouseWheelScrollSensitivity),typeof e.fastScrollSensitivity<"u"&&(this._options.fastScrollSensitivity=e.fastScrollSensitivity),typeof e.scrollPredominantAxis<"u"&&(this._options.scrollPredominantAxis=e.scrollPredominantAxis),typeof e.horizontal<"u"&&(this._options.horizontal=e.horizontal),typeof e.vertical<"u"&&(this._options.vertical=e.vertical),typeof e.horizontalScrollbarSize<"u"&&(this._options.horizontalScrollbarSize=e.horizontalScrollbarSize),typeof e.verticalScrollbarSize<"u"&&(this._options.verticalScrollbarSize=e.verticalScrollbarSize),typeof e.scrollByPage<"u"&&(this._options.scrollByPage=e.scrollByPage),this._horizontalScrollbar.updateOptions(this._options),this._verticalScrollbar.updateOptions(this._options),this._options.lazyRender||this._render()}delegateScrollFromMouseWheelEvent(e){this._onMouseWheel(new ph(e))}_setListeningToMouseWheel(e){if(this._mouseWheelToDispose.length>0!==e&&(this._mouseWheelToDispose=Yt(this._mouseWheelToDispose),e)){let i=o=>{this._onMouseWheel(new ph(o))};this._mouseWheelToDispose.push(U(this._listenOnDomNode,re.MOUSE_WHEEL,i,{passive:!1}))}}_onMouseWheel(e){if(e.browserEvent?.defaultPrevented)return;let t=aM.INSTANCE;qMe&&t.acceptStandardWheelEvent(e);let i=!1;if(e.deltaY||e.deltaX){let r=e.deltaY*this._options.mouseWheelScrollSensitivity,s=e.deltaX*this._options.mouseWheelScrollSensitivity;this._options.scrollPredominantAxis&&(this._options.scrollYToX&&s+r===0?s=r=0:Math.abs(r)>=Math.abs(s)?s=0:r=0),this._options.flipAxes&&([r,s]=[s,r]);let a=!dt&&e.browserEvent&&e.browserEvent.shiftKey;(this._options.scrollYToX||a)&&!s&&(s=r,r=0),e.browserEvent&&e.browserEvent.altKey&&(s=s*this._options.fastScrollSensitivity,r=r*this._options.fastScrollSensitivity);let l=this._scrollable.getFutureScrollPosition(),c={};if(r){let d=jMe*r,u=l.scrollTop-(d<0?Math.floor(d):Math.ceil(d));this._verticalScrollbar.writeScrollPosition(c,u)}if(s){let d=jMe*s,u=l.scrollLeft-(d<0?Math.floor(d):Math.ceil(d));this._horizontalScrollbar.writeScrollPosition(c,u)}c=this._scrollable.validateScrollPosition(c),(l.scrollLeft!==c.scrollLeft||l.scrollTop!==c.scrollTop)&&(qMe&&this._options.mouseWheelSmoothScroll&&t.isPhysicalMouseWheel()?this._scrollable.setScrollPositionSmooth(c):this._scrollable.setScrollPositionNow(c),i=!0)}let o=i;!o&&this._options.alwaysConsumeMouseWheel&&(o=!0),!o&&this._options.consumeMouseWheelIfScrollbarIsNeeded&&(this._verticalScrollbar.isNeeded()||this._horizontalScrollbar.isNeeded())&&(o=!0),o&&(e.preventDefault(),e.stopPropagation())}_onDidScroll(e){this._shouldRender=this._horizontalScrollbar.onDidScroll(e)||this._shouldRender,this._shouldRender=this._verticalScrollbar.onDidScroll(e)||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)){let e=this._scrollable.getCurrentScrollPosition(),t=e.scrollTop>0,i=e.scrollLeft>0,o=i?" left":"",r=t?" top":"",s=i||t?" top-left-corner":"";this._leftShadowDomNode.setClassName(`shadow${o}`),this._topShadowDomNode.setClassName(`shadow${r}`),this._topLeftShadowDomNode.setClassName(`shadow${s}${r}${o}`)}}_onDragStart(){this._isDragging=!0,this._reveal()}_onDragEnd(){this._isDragging=!1,this._hide()}_onMouseLeave(e){this._mouseIsOver=!1,this._hide()}_onMouseOver(e){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(),gat)}},YL=class extends lM{constructor(e,t){t=t||{},t.mouseWheelSmoothScroll=!1;let i=new Ih({forceIntegerValues:!0,smoothScrollDuration:0,scheduleAtNextAnimationFrame:o=>us(Me(e),o)});super(e,t,i),this._register(i)}setScrollPosition(e){this._scrollable.setScrollPositionNow(e)}},Ym=class extends lM{constructor(e,t,i){super(e,t,i)}setScrollPosition(e){e.reuseAnimation?this._scrollable.setScrollPositionSmooth(e,e.reuseAnimation):this._scrollable.setScrollPositionNow(e)}getScrollPosition(){return this._scrollable.getCurrentScrollPosition()}},Cf=class extends lM{constructor(e,t){t=t||{},t.mouseWheelSmoothScroll=!1;let i=new Ih({forceIntegerValues:!1,smoothScrollDuration:0,scheduleAtNextAnimationFrame:o=>us(Me(e),o)});super(e,t,i),this._register(i),this._element=e,this._register(this.onScroll(o=>{o.scrollTopChanged&&(this._element.scrollTop=o.scrollTop),o.scrollLeftChanged&&(this._element.scrollLeft=o.scrollLeft)})),this.scanDomNode()}setScrollPosition(e){this._scrollable.setScrollPositionNow(e)}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})}}});var KMe=k(()=>{});function i7(n,e){return n&&e?m("acessibleViewHint","Inspect this in the accessible view with {0}.",e):n?m("acessibleViewHintNoKbOpen","Inspect this in the accessible view via the command Open Accessible View which is currently not triggerable via keybinding."):""}var t7,Qx,ZL,cM,dM,XL=k(()=>{ke();Ks();Eh();j();KMe();pe();t7=J,Qx=class extends D{constructor(){super(),this.containerDomNode=document.createElement("div"),this.containerDomNode.className="monaco-hover",this.containerDomNode.tabIndex=0,this.containerDomNode.setAttribute("role","tooltip"),this.contentsDomNode=document.createElement("div"),this.contentsDomNode.className="monaco-hover-content",this.scrollbar=this._register(new Cf(this.contentsDomNode,{consumeMouseWheelIfScrollbarIsNeeded:!0})),this.containerDomNode.appendChild(this.scrollbar.getDomNode())}onContentsChanged(){this.scrollbar.scanDomNode()}},ZL=class n extends D{static render(e,t,i){return new n(e,t,i)}constructor(e,t,i){super(),this.actionLabel=t.label,this.actionKeybindingLabel=i,this.actionContainer=Q(e,t7("div.action-container")),this.actionContainer.setAttribute("tabindex","0"),this.action=Q(this.actionContainer,t7("a.action")),this.action.setAttribute("role","button"),t.iconClass&&Q(this.action,t7(`span.icon.${t.iconClass}`));let o=Q(this.action,t7("span"));o.textContent=i?`${t.label} (${i})`:t.label,this._store.add(new cM(this.actionContainer,t.run)),this._store.add(new dM(this.actionContainer,t.run,[3,10])),this.setEnabled(!0)}setEnabled(e){e?(this.actionContainer.classList.remove("disabled"),this.actionContainer.removeAttribute("aria-disabled")):(this.actionContainer.classList.add("disabled"),this.actionContainer.setAttribute("aria-disabled","true"))}};cM=class extends D{constructor(e,t){super(),this._register(U(e,re.CLICK,i=>{i.stopPropagation(),i.preventDefault(),t(e)}))}},dM=class extends D{constructor(e,t,i){super(),this._register(U(e,re.KEY_DOWN,o=>{let r=new Xt(o);i.some(s=>r.equals(s))&&(o.stopPropagation(),o.preventDefault(),t(e))}))}}});function GMe(n){let e,t=/^L?(\d+)(?:,(\d+))?(-L?(\d+)(?:,(\d+))?)?/.exec(n.fragment);return t&&(e={startLineNumber:parseInt(t[1]),startColumn:t[2]?parseInt(t[2]):1,endLineNumber:t[4]?parseInt(t[4]):void 0,endColumn:t[4]?t[5]?parseInt(t[5]):1:void 0},n=n.with({fragment:""})),{selection:e,uri:n}}var xo,Ml=k(()=>{Fe();xo=We("openerService")});var Mt,Sf=k(()=>{Ie();Mt=class{get event(){return this.emitter.event}constructor(e,t,i){let o=r=>this.emitter.fire(r);this.emitter=new A({onWillAddFirstListener:()=>e.addEventListener(t,o,i),onDidRemoveLastListener:()=>e.removeEventListener(t,o,i)})}dispose(){this.emitter.dispose()}}});function YMe(n,e={}){let t=n7(e);return t.textContent=n,t}function ZMe(n,e={}){let t=n7(e);return XMe(t,bat(n,!!e.renderCodeSegments),e.actionHandler,e.renderCodeSegments),t}function n7(n){let e=n.inline?"span":"div",t=document.createElement(e);return n.className&&(t.className=n.className),t}function XMe(n,e,t,i){let o;if(e.type===2)o=document.createTextNode(e.content||"");else if(e.type===3)o=document.createElement("b");else if(e.type===4)o=document.createElement("i");else if(e.type===7&&i)o=document.createElement("code");else if(e.type===5&&t){let r=document.createElement("a");t.disposables.add(gi(r,"click",s=>{t.callback(String(e.index),s)})),o=r}else e.type===8?o=document.createElement("br"):e.type===1&&(o=n);o&&n!==o&&n.appendChild(o),o&&Array.isArray(e.children)&&e.children.forEach(r=>{XMe(o,r,t,i)})}function bat(n,e){let t={type:1,children:[]},i=0,o=t,r=[],s=new Nse(n);for(;!s.eos();){let a=s.next(),l=a==="\\"&&Rse(s.peek(),e)!==0;if(l&&(a=s.next()),!l&&vat(a,e)&&a===s.peek()){s.advance(),o.type===2&&(o=r.pop());let c=Rse(a,e);if(o.type===c||o.type===5&&c===6)o=r.pop();else{let d={type:c,children:[]};c===5&&(d.index=i,i++),o.children.push(d),r.push(o),o=d}}else if(a===` `)o.type===2&&(o=r.pop()),o.children.push({type:8});else if(o.type!==2){let c={type:2,content:a};o.children.push(c),r.push(o),o=c}else o.content+=a}return o.type===2&&(o=r.pop()),r.length,t}function vat(n,e){return Rse(n,e)!==0}function Rse(n,e){switch(n){case"*":return 3;case"_":return 4;case"[":return 5;case"]":return 6;case"`":return e?7:0;default:return 0}}var Nse,Ase=k(()=>{ke();Nse=class{constructor(e){this.source=e,this.index=0}eos(){return this.index>=this.source.length}next(){let e=this.peek();return this.advance(),e}peek(){return this.source[this.index]}advance(){this.index++}}});function Iu(n){let e=new Array,t,i=0,o=0;for(;(t=xat.exec(n))!==null;){o=t.index||0,i{ke();bn();xat=new RegExp(`(\\\\)?\\$\\((${Oe.iconNameExpression}(?:${Oe.iconModifierExpression})?)\\)`,"g")});function QMe(n){let e=wat(n);if(e&&e.length>0)return new Uint32Array(e)}function wat(n){if(Eu=0,Xm(n,Mse,4352),Eu>0||(Xm(n,Pse,4449),Eu>0)||(Xm(n,Ose,4520),Eu>0)||(Xm(n,dC,12593),Eu))return Jx.subarray(0,Eu);if(n>=44032&&n<=55203){let e=n-44032,t=e%588,i=Math.floor(e/588),o=Math.floor(t/28),r=t%28-1;if(i=0&&(r0)return Jx.subarray(0,Eu)}}function Xm(n,e,t){n>=t&&n>8&&(Jx[Eu++]=n>>8&255),n>>16&&(Jx[Eu++]=n>>16&255))}var Eu,Jx,Mse,Pse,Ose,dC,JMe=k(()=>{Eu=0,Jx=new Uint32Array(10);Mse=new Uint8Array([114,82,115,101,69,102,97,113,81,116,84,100,119,87,99,122,120,118,103]),Pse=new Uint16Array([107,111,105,79,106,112,117,80,104,27496,28520,27752,121,110,27246,28782,27758,98,109,27757,108]),Ose=new Uint16Array([114,82,29810,115,30579,26483,101,102,29286,24934,29030,29798,30822,30310,26470,97,113,29809,116,84,100,119,99,122,120,118,103]),dC=new Uint16Array([114,82,29810,115,30579,26483,101,69,102,29286,24934,29030,29798,30822,30310,26470,97,113,81,29809,116,84,100,119,87,99,122,120,118,103,107,111,105,79,106,112,117,80,104,27496,28520,27752,121,110,27246,28782,27758,98,109,27757,108])});function a7(...n){return function(e,t){for(let i=0,o=n.length;i0?[{start:0,end:e.length}]:[]:null}function Use(n,e){let t=e.toLowerCase().indexOf(n.toLowerCase());return t===-1?null:[{start:t,end:t+n.length}]}function $se(n,e){return Wse(n.toLowerCase(),e.toLowerCase(),0,0)}function Wse(n,e,t,i){if(t===n.length)return[];if(i===e.length)return null;if(n[t]===e[i]){let o=null;return(o=Wse(n,e,t+1,i+1))?Kse({start:i,end:i+1},o):null}return Wse(n,e,t,i+1)}function jse(n){return 97<=n&&n<=122}function l7(n){return 65<=n&&n<=90}function qse(n){return 48<=n&&n<=57}function r2e(n){return n===32||n===9||n===10||n===13}function s7(n){return r2e(n)||s2e.has(n)}function e2e(n,e){return n===e||s7(n)&&s7(e)}function t2e(n){if(Fse.has(n))return Fse.get(n);let e,t=QMe(n);return t&&(e=t),Fse.set(n,e),e}function a2e(n){return jse(n)||l7(n)||qse(n)}function Kse(n,e){return e.length===0?e=[n]:n.end===e[0].start?e[0].start=n.start:e.unshift(n),e}function l2e(n,e){for(let t=e;t0&&!a2e(n.charCodeAt(t-1)))return t}return n.length}function Hse(n,e,t,i){if(t===n.length)return[];if(i===e.length)return null;if(n[t]!==e[i].toLowerCase())return null;{let o=null,r=i+1;for(o=Hse(n,e,t+1,i+1);!o&&(r=l2e(e,r)).6}function kat(n){let{upperPercent:e,lowerPercent:t,alphaPercent:i,numericPercent:o}=n;return t>.2&&e<.8&&i>.6&&o<.2}function Lat(n){let e=0,t=0,i=0,o=0;for(let r=0;r60&&(e=e.substring(0,60));let t=Cat(e);if(!kat(t)){if(!Sat(t))return null;e=e.toLowerCase()}let i=null,o=0;for(n=n.toLowerCase();o0&&s7(n.charCodeAt(t-1)))return t;return n.length}function Gse(n,e,t=!1){if(typeof n!="string"||typeof e!="string")return null;let i=i2e.get(n);i||(i=new RegExp(OTe(n),"i"),i2e.set(n,i));let o=i.exec(e);return o?[{start:o.index,end:o.index+o[0].length}]:t?Eat(n,e):Iat(n,e)}function h2e(n,e){let t=Jm(n,n.toLowerCase(),0,e,e.toLowerCase(),0,{firstMatchCanBeWeak:!0,boostFullMatch:!0});return t?iw(t):null}function f2e(n,e,t,i,o,r){let s=Math.min(13,n.length);for(;t"u")return[];let e=[],t=n[1];for(let i=n.length-1;i>1;i--){let o=n[i]+t,r=e[e.length-1];r&&r.end===o?r.end=o+1:e.push({start:o,end:o+1})}return e}function Yse(){let n=[],e=[];for(let t=0;t<=tw;t++)e[t]=0;for(let t=0;t<=tw;t++)n.push(e.slice(0));return n}function p2e(n){let e=[];for(let t=0;t<=n;t++)e[t]=0;return e}function Bse(n,e,t,i,o){function r(a,l,c=" "){for(;a.lengthr(a,3)).join("|")} `;for(let a=0;a<=t;a++)a===0?s+=" |":s+=`${e[a-1]}|`,s+=n[a].slice(0,o+1).map(l=>r(l.toString(),3)).join("|")+` `;return s}function Dat(n,e,t,i){n=n.substr(e),t=t.substr(i),console.log(Bse(ew,n,n.length,t,t.length)),console.log(Bse(uM,n,n.length,t,t.length)),console.log(Bse(Qm,n,n.length,t,t.length))}function o7(n,e){if(e<0||e>=n.length)return!1;let t=n.codePointAt(e);switch(t){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!!XR(t)}}function n2e(n,e){if(e<0||e>=n.length)return!1;switch(n.charCodeAt(e)){case 32:case 9:return!0;default:return!1}}function r7(n,e,t){return e[n]!==t[n]}function Nat(n,e,t,i,o,r,s=!1){for(;etw?tw:n.length,l=i.length>tw?tw:i.length;if(t>=a||r>=l||a-t>l-r||!Nat(e,t,a,o,r,l,!0))return;Rat(a,l,t,r,e,o);let c=1,d=1,u=t,h=r,f=[!1];for(c=1,u=t;uv,N=E?ew[c][d-1]+(Qm[c][d-1]>0?-5:0):0,M=h>v+1&&Qm[c][d-1]>0,F=M?ew[c][d-2]+(Qm[c][d-2]>0?-5:0):0;if(M&&(!E||F>=N)&&(!C||F>=L))ew[c][d]=F,uM[c][d]=3,Qm[c][d]=0;else if(E&&(!C||N>=L))ew[c][d]=N,uM[c][d]=2,Qm[c][d]=0;else if(C)ew[c][d]=L,uM[c][d]=1,Qm[c][d]=Qm[c-1][d-1]+1;else throw new Error("not possible")}}if(Tat&&Dat(n,t,i,r),!f[0]&&!s.firstMatchCanBeWeak)return;c--,d--;let p=[ew[c][d],r],g=0,_=0;for(;c>=1;){let v=d;do{let x=uM[c][v];if(x===3)v=v-2;else if(x===2)v=v-1;else break}while(v>=1);g>1&&e[t+c-1]===o[r+d-1]&&!r7(v+r-1,i,o)&&g+1>Qm[c][v]&&(v=d),v===d?g++:g=1,_||(_=v),c--,d=v-1,p.push(d)}l-r===a&&s.boostFullMatch&&(p[0]+=2);let b=_-a;return p[0]-=b,p}function Rat(n,e,t,i,o,r){let s=n-1,a=e-1;for(;s>=t&&a>=i;)o[s]===r[a]&&(Vse[s]=a,s--),a--}function Aat(n,e,t,i,o,r,s,a,l,c,d){if(e[t]!==r[s])return Number.MIN_SAFE_INTEGER;let u=1,h=!1;return s===t-i?u=n[t]===o[s]?7:5:r7(s,o,r)&&(s===0||!r7(s-1,o,r))?(u=n[t]===o[s]?7:5,h=!0):o7(r,s)&&(s===0||!o7(r,s-1))?u=5:(o7(r,s-1)||n2e(r,s-1))&&(u=5,h=!0),u>1&&t===i&&(d[0]=!0),h||(h=r7(s,o,r)||o7(r,s-1)||n2e(r,s-1)),t===i?s>l&&(u-=h?3:5):c?u+=h?2:0:u+=h?0:1,s+1===a&&(u-=h?3:5),u}function g2e(n,e,t,i,o,r,s){return Mat(n,e,t,i,o,r,!0,s)}function Mat(n,e,t,i,o,r,s,a){let l=Jm(n,e,t,i,o,r,a);if(l&&!s)return l;if(n.length>=3){let c=Math.min(7,n.length-1);for(let d=t+1;dl[0])&&(l=h))}}}return l}function Pat(n,e){if(e+1>=n.length)return;let t=n[e],i=n[e+1];if(t!==i)return n.slice(0,e)+i+t+n.slice(e+2)}var nqt,hC,s2e,Fse,Iat,Eat,i2e,tw,m2e,Vse,Qm,ew,uM,Tat,qc,uC,Th=k(()=>{Ds();JMe();Qe();nqt=o2e.bind(void 0,!1),hC=o2e.bind(void 0,!0);s2e=new Set;"()[]{}<>`'\"-/;:,.?!".split("").forEach(n=>s2e.add(n.charCodeAt(0)));Fse=new Map;Iat=a7(hC,c2e,Use),Eat=a7(hC,c2e,$se),i2e=new Ts(1e4);tw=128;m2e=p2e(2*tw),Vse=p2e(2*tw),Qm=Yse(),ew=Yse(),uM=Yse(),Tat=!1;(function(n){n.Default=[-100,0];function e(t){return!t||t.length===2&&t[0]===-100&&t[1]===0}n.isDefault=e})(qc||(qc={}));uC=class{static{this.default={boostFullMatch:!0,firstMatchCanBeWeak:!1}}constructor(e,t){this.firstMatchCanBeWeak=e,this.boostFullMatch=t}}});function _2e(n){return n.replace(Fat,(e,t)=>t?e:`\\${e}`)}function b2e(n){return n.replace(Bat,e=>`\\${e}`)}function QL(n){return n.indexOf(Oat)===-1?n:n.replace(Wat,(e,t,i,o)=>i?e:t||o||"")}function v2e(n){return n?n.replace(/\$\((.*?)\)/g,(e,t)=>` ${t} `).trim():""}function JL(n){Zse.lastIndex=0;let e="",t=[],i=0;for(;;){let o=Zse.lastIndex,r=Zse.exec(n),s=n.substring(o,r?.index);if(s.length>0){e+=s;for(let a=0;a{Th();Qe();bn();Oat="$(",Xse=new RegExp(`\\$\\(${Oe.iconNameExpression}(?:${Oe.iconModifierExpression})?\\)`,"g"),Fat=new RegExp(`(\\\\)?${Xse.source}`,"g");Bat=new RegExp(`\\\\${Xse.source}`,"g");Wat=new RegExp(`(\\s)?(\\\\)?${Xse.source}(\\s)?`,"g");Zse=new RegExp(`\\$\\(${Oe.iconNameCharacter}+\\)`,"g")});function vp(n){return HR(n,!0)}var hM,zn,fqt,pqt,hb,mqt,gqt,y2e,ta,C2e,nw,S2e,k2e,L2e,Qse,_qt,x2e,w2e,bqt,vqt,eg,ia=k(()=>{C9();ds();sp();Bt();Qe();Ai();hM=class{constructor(e){this._ignorePathCasing=e}compare(e,t,i=!1){return e===t?0:_x(this.getComparisonKey(e,i),this.getComparisonKey(t,i))}isEqual(e,t,i=!1){return e===t?!0:!e||!t?!1:this.getComparisonKey(e,i)===this.getComparisonKey(t,i)}getComparisonKey(e,t=!1){return e.with({path:this._ignorePathCasing(e)?e.path.toLowerCase():void 0,fragment:t?null:void 0}).toString()}isEqualOrParent(e,t,i=!1){if(e.scheme===t.scheme){if(e.scheme===rt.file)return YA(vp(e),vp(t),this._ignorePathCasing(e))&&e.query===t.query&&(i||e.fragment===t.fragment);if(x2e(e.authority,t.authority))return YA(e.path,t.path,this._ignorePathCasing(e),"/")&&e.query===t.query&&(i||e.fragment===t.fragment)}return!1}joinPath(e,...t){return Ee.joinPath(e,...t)}basenameOrAuthority(e){return ta(e)||e.authority}basename(e){return eo.basename(e.path)}extname(e){return eo.extname(e.path)}dirname(e){if(e.path.length===0)return e;let t;return e.scheme===rt.file?t=Ee.file(e8(vp(e))).path:(t=eo.dirname(e.path),e.authority&&t.length&&t.charCodeAt(0)!==47&&(console.error(`dirname("${e.toString})) resulted in a relative path`),t="/")),e.with({path:t})}normalizePath(e){if(!e.path.length)return e;let t;return e.scheme===rt.file?t=Ee.file(J3(vp(e))).path:t=eo.normalize(e.path),e.with({path:t})}relativePath(e,t){if(e.scheme!==t.scheme||!x2e(e.authority,t.authority))return;if(e.scheme===rt.file){let r=vTe(vp(e),vp(t));return kn?tse(r):r}let i=e.path||"/",o=t.path||"/";if(this._ignorePathCasing(e)){let r=0;for(let s=Math.min(i.length,o.length);rise(i).length&&i[i.length-1]===t}else{let i=e.path;return i.length>1&&i.charCodeAt(i.length-1)===47&&!/^[a-zA-Z]:(\/$|\\$)/.test(e.fsPath)}}removeTrailingPathSeparator(e,t=Cd){return w2e(e,t)?e.with({path:e.path.substr(0,e.path.length-1)}):e}addTrailingPathSeparator(e,t=Cd){let i=!1;if(e.scheme===rt.file){let o=vp(e);i=o!==void 0&&o.length===ise(o).length&&o[o.length-1]===t}else{t="/";let o=e.path;i=o.length===1&&o.charCodeAt(o.length-1)===47}return!i&&!w2e(e,t)?e.with({path:e.path+"/"}):e}},zn=new hM(()=>!1),fqt=new hM(n=>n.scheme===rt.file?!Qn:!0),pqt=new hM(n=>!0),hb=zn.isEqual.bind(zn),mqt=zn.isEqualOrParent.bind(zn),gqt=zn.getComparisonKey.bind(zn),y2e=zn.basenameOrAuthority.bind(zn),ta=zn.basename.bind(zn),C2e=zn.extname.bind(zn),nw=zn.dirname.bind(zn),S2e=zn.joinPath.bind(zn),k2e=zn.normalizePath.bind(zn),L2e=zn.relativePath.bind(zn),Qse=zn.resolvePath.bind(zn),_qt=zn.isAbsolutePath.bind(zn),x2e=zn.isEqualAuthority.bind(zn),w2e=zn.hasTrailingPathSeparator.bind(zn),bqt=zn.removeTrailingPathSeparator.bind(zn),vqt=zn.addTrailingPathSeparator.bind(zn);(function(n){n.META_DATA_LABEL="label",n.META_DATA_DESCRIPTION="description",n.META_DATA_SIZE="size",n.META_DATA_MIME="mime";function e(t){let i=new Map;t.path.substring(t.path.indexOf(";")+1,t.path.lastIndexOf(";")).split(";").forEach(s=>{let[a,l]=s.split(":");a&&l&&i.set(a,l)});let r=t.path.substring(0,t.path.indexOf(";"));return r&&i.set(n.META_DATA_MIME,r),i}n.parseMetaData=e})(eg||(eg={}))});function fb(n){return Kc(n)?!n.value:Array.isArray(n)?n.every(fb):!0}function Kc(n){return n instanceof Eo?!0:n&&typeof n=="object"?typeof n.value=="string"&&(typeof n.isTrusted=="boolean"||typeof n.isTrusted=="object"||n.isTrusted===void 0)&&(typeof n.supportThemeIcons=="boolean"||n.supportThemeIcons===void 0):!1}function I2e(n,e){return n===e?!0:!n||!e?!1:n.value===e.value&&n.isTrusted===e.isTrusted&&n.supportThemeIcons===e.supportThemeIcons&&n.supportHtml===e.supportHtml&&(n.baseUri===e.baseUri||!!n.baseUri&&!!e.baseUri&&hb(Ee.from(n.baseUri),Ee.from(e.baseUri)))}function zat(n){return n.replace(/[\\`*_{}[\]()#+\-!~]/g,"\\$&")}function Vat(n,e){let t=n.match(/^`+/gm)?.reduce((o,r)=>o.length>r.length?o:r).length??0,i=t>=3?t+1:3;return[`${"`".repeat(i)}${e}`,n,`${"`".repeat(i)}`].join(` `)}function fM(n){return n.replace(/"/g,""")}function d7(n){return n&&n.replace(/\\([\\`*_{}[\]()#+\-.!~])/g,"$1")}function E2e(n){let e=[],t=n.split("|").map(o=>o.trim());n=t[0];let i=t[1];if(i){let o=/height=(\d+)/.exec(i),r=/width=(\d+)/.exec(i),s=o?o[1]:"",a=r?r[1]:"",l=isFinite(parseInt(a)),c=isFinite(parseInt(s));l&&e.push(`width="${a}"`),c&&e.push(`height="${s}"`)}return{href:n,dimensions:e}}var Eo,Pl=k(()=>{je();fC();ia();Qe();Ai();Eo=class{constructor(e="",t=!1){if(this.value=e,typeof this.value!="string")throw js("value");typeof t=="boolean"?(this.isTrusted=t,this.supportThemeIcons=!1,this.supportHtml=!1):(this.isTrusted=t.isTrusted??void 0,this.supportThemeIcons=t.supportThemeIcons??!1,this.supportHtml=t.supportHtml??!1)}appendText(e,t=0){return this.value+=zat(this.supportThemeIcons?_2e(e):e).replace(/([ \t]+)/g,(i,o)=>" ".repeat(o.length)).replace(/\>/gm,"\\>").replace(/\n/g,t===1?`\\ `:` `),this}appendMarkdown(e){return this.value+=e,this}appendCodeblock(e,t){return this.value+=` ${Vat(t,e)} `,this}appendLink(e,t,i){return this.value+="[",this.value+=this._escape(t,"]"),this.value+="](",this.value+=this._escape(String(e),")"),i&&(this.value+=` "${this._escape(this._escape(i,'"'),")")}"`),this.value+=")",this}_escape(e,t){let i=new RegExp(jr(t),"g");return e.replace(i,(o,r)=>e.charAt(r-1)!=="\\"?`\\${o}`:o)}}});var pC,pM,mM=k(()=>{pC=class{constructor(e){this._prefix=e,this._lastId=0}nextId(){return this._prefix+ ++this._lastId}},pM=new pC("id#")});var ol,Iqt,Eqt,Tqt,Dqt,Jse,Nqt,Rqt,T2e,Aqt,gM,Mqt,Pqt,eae,Oqt,D2e,Fqt,Bqt,Wqt,N2e=k(()=>{ol={};(function(){function n(e,t){t(ol)}n.amd=!0,function(e,t){typeof n=="function"&&n.amd?n(["exports"],t):typeof exports=="object"&&typeof module<"u"?t(exports):(e=typeof globalThis<"u"?globalThis:e||self,t(e.marked={}))}(this,function(e){"use strict";function t(){return{async:!1,breaks:!1,extensions:null,gfm:!0,hooks:null,pedantic:!1,renderer:null,silent:!1,tokenizer:null,walkTokens:null}}e.defaults=t();function i(wi){e.defaults=wi}let o=/[&<>"']/,r=new RegExp(o.source,"g"),s=/[<>"']|&(?!(#\d{1,7}|#[Xx][a-fA-F0-9]{1,6}|\w+);)/,a=new RegExp(s.source,"g"),l={"&":"&","<":"<",">":">",'"':""","'":"'"},c=wi=>l[wi];function d(wi,O){if(O){if(o.test(wi))return wi.replace(r,c)}else if(s.test(wi))return wi.replace(a,c);return wi}let u=/(^|[^\[])\^/g;function h(wi,O){let W=typeof wi=="string"?wi:wi.source;O=O||"";let V={replace:(G,ie)=>{let xe=typeof ie=="string"?ie:ie.source;return xe=xe.replace(u,"$1"),W=W.replace(G,xe),V},getRegex:()=>new RegExp(W,O)};return V}function f(wi){try{wi=encodeURI(wi).replace(/%25/g,"%")}catch{return null}return wi}let p={exec:()=>null};function g(wi,O){let W=wi.replace(/\|/g,(ie,xe,Ne)=>{let pt=!1,Tt=xe;for(;--Tt>=0&&Ne[Tt]==="\\";)pt=!pt;return pt?"|":" |"}),V=W.split(/ \|/),G=0;if(V[0].trim()||V.shift(),V.length>0&&!V[V.length-1].trim()&&V.pop(),O)if(V.length>O)V.splice(O);else for(;V.length{let ie=G.match(/^\s+/);if(ie===null)return G;let[xe]=ie;return xe.length>=V.length?G.slice(V.length):G}).join(` `)}class w{options;rules;lexer;constructor(O){this.options=O||e.defaults}space(O){let W=this.rules.block.newline.exec(O);if(W&&W[0].length>0)return{type:"space",raw:W[0]}}code(O){let W=this.rules.block.code.exec(O);if(W){let V=W[0].replace(/^ {1,4}/gm,"");return{type:"code",raw:W[0],codeBlockStyle:"indented",text:this.options.pedantic?V:_(V,` `)}}}fences(O){let W=this.rules.block.fences.exec(O);if(W){let V=W[0],G=x(V,W[3]||"");return{type:"code",raw:V,lang:W[2]?W[2].trim().replace(this.rules.inline.anyPunctuation,"$1"):W[2],text:G}}}heading(O){let W=this.rules.block.heading.exec(O);if(W){let V=W[2].trim();if(/#$/.test(V)){let G=_(V,"#");(this.options.pedantic||!G||/ $/.test(G))&&(V=G.trim())}return{type:"heading",raw:W[0],depth:W[1].length,text:V,tokens:this.lexer.inline(V)}}}hr(O){let W=this.rules.block.hr.exec(O);if(W)return{type:"hr",raw:_(W[0],` `)}}blockquote(O){let W=this.rules.block.blockquote.exec(O);if(W){let V=_(W[0],` `).split(` `),G="",ie="",xe=[];for(;V.length>0;){let Ne=!1,pt=[],Tt;for(Tt=0;Tt/.test(V[Tt]))pt.push(V[Tt]),Ne=!0;else if(!Ne)pt.push(V[Tt]);else break;V=V.slice(Tt);let hi=pt.join(` `),mn=hi.replace(/\n {0,3}((?:=+|-+) *)(?=\n|$)/g,` $1`).replace(/^ {0,3}>[ \t]?/gm,"");G=G?`${G} ${hi}`:hi,ie=ie?`${ie} ${mn}`:mn;let Tn=this.lexer.state.top;if(this.lexer.state.top=!0,this.lexer.blockTokens(mn,xe,!0),this.lexer.state.top=Tn,V.length===0)break;let xs=xe[xe.length-1];if(xs?.type==="code")break;if(xs?.type==="blockquote"){let qo=xs,fd=qo.raw+` `+V.join(` `),Zu=this.blockquote(fd);xe[xe.length-1]=Zu,G=G.substring(0,G.length-qo.raw.length)+Zu.raw,ie=ie.substring(0,ie.length-qo.text.length)+Zu.text;break}else if(xs?.type==="list"){let qo=xs,fd=qo.raw+` `+V.join(` `),Zu=this.list(fd);xe[xe.length-1]=Zu,G=G.substring(0,G.length-xs.raw.length)+Zu.raw,ie=ie.substring(0,ie.length-qo.raw.length)+Zu.raw,V=fd.substring(xe[xe.length-1].raw.length).split(` `);continue}}return{type:"blockquote",raw:G,tokens:xe,text:ie}}}list(O){let W=this.rules.block.list.exec(O);if(W){let V=W[1].trim(),G=V.length>1,ie={type:"list",raw:"",ordered:G,start:G?+V.slice(0,-1):"",loose:!1,items:[]};V=G?`\\d{1,9}\\${V.slice(-1)}`:`\\${V}`,this.options.pedantic&&(V=G?V:"[*+-]");let xe=new RegExp(`^( {0,3}${V})((?:[ ][^\\n]*)?(?:\\n|$))`),Ne=!1;for(;O;){let pt=!1,Tt="",hi="";if(!(W=xe.exec(O))||this.rules.block.hr.test(O))break;Tt=W[0],O=O.substring(Tt.length);let mn=W[2].split(` `,1)[0].replace(/^\t+/,oN=>" ".repeat(3*oN.length)),Tn=O.split(` `,1)[0],xs=!mn.trim(),qo=0;if(this.options.pedantic?(qo=2,hi=mn.trimStart()):xs?qo=W[1].length+1:(qo=W[2].search(/[^ ]/),qo=qo>4?1:qo,hi=mn.slice(qo),qo+=W[1].length),xs&&/^ *$/.test(Tn)&&(Tt+=Tn+` `,O=O.substring(Tn.length+1),pt=!0),!pt){let oN=new RegExp(`^ {0,${Math.min(3,qo-1)}}(?:[*+-]|\\d{1,9}[.)])((?:[ ][^\\n]*)?(?:\\n|$))`),Zt=new RegExp(`^ {0,${Math.min(3,qo-1)}}((?:- *){3,}|(?:_ *){3,}|(?:\\* *){3,})(?:\\n+|$)`),se=new RegExp(`^ {0,${Math.min(3,qo-1)}}(?:\`\`\`|~~~)`),ot=new RegExp(`^ {0,${Math.min(3,qo-1)}}#`);for(;O;){let Vt=O.split(` `,1)[0];if(Tn=Vt,this.options.pedantic&&(Tn=Tn.replace(/^ {1,4}(?=( {4})*[^ ])/g," ")),se.test(Tn)||ot.test(Tn)||oN.test(Tn)||Zt.test(O))break;if(Tn.search(/[^ ]/)>=qo||!Tn.trim())hi+=` `+Tn.slice(qo);else{if(xs||mn.search(/[^ ]/)>=4||se.test(mn)||ot.test(mn)||Zt.test(mn))break;hi+=` `+Tn}!xs&&!Tn.trim()&&(xs=!0),Tt+=Vt+` `,O=O.substring(Vt.length+1),mn=Tn.slice(qo)}}ie.loose||(Ne?ie.loose=!0:/\n *\n *$/.test(Tt)&&(Ne=!0));let fd=null,Zu;this.options.gfm&&(fd=/^\[[ xX]\] /.exec(hi),fd&&(Zu=fd[0]!=="[ ] ",hi=hi.replace(/^\[[ xX]\] +/,""))),ie.items.push({type:"list_item",raw:Tt,task:!!fd,checked:Zu,loose:!1,text:hi,tokens:[]}),ie.raw+=Tt}ie.items[ie.items.length-1].raw=ie.items[ie.items.length-1].raw.trimEnd(),ie.items[ie.items.length-1].text=ie.items[ie.items.length-1].text.trimEnd(),ie.raw=ie.raw.trimEnd();for(let pt=0;ptmn.type==="space"),hi=Tt.length>0&&Tt.some(mn=>/\n.*\n/.test(mn.raw));ie.loose=hi}if(ie.loose)for(let pt=0;pt$/,"$1").replace(this.rules.inline.anyPunctuation,"$1"):"",ie=W[3]?W[3].substring(1,W[3].length-1).replace(this.rules.inline.anyPunctuation,"$1"):W[3];return{type:"def",tag:V,raw:W[0],href:G,title:ie}}}table(O){let W=this.rules.block.table.exec(O);if(!W||!/[:|]/.test(W[2]))return;let V=g(W[1]),G=W[2].replace(/^\||\| *$/g,"").split("|"),ie=W[3]&&W[3].trim()?W[3].replace(/\n[ \t]*$/,"").split(` `):[],xe={type:"table",raw:W[0],header:[],align:[],rows:[]};if(V.length===G.length){for(let Ne of G)/^ *-+: *$/.test(Ne)?xe.align.push("right"):/^ *:-+: *$/.test(Ne)?xe.align.push("center"):/^ *:-+ *$/.test(Ne)?xe.align.push("left"):xe.align.push(null);for(let Ne=0;Ne({text:pt,tokens:this.lexer.inline(pt),header:!1,align:xe.align[Tt]})));return xe}}lheading(O){let W=this.rules.block.lheading.exec(O);if(W)return{type:"heading",raw:W[0],depth:W[2].charAt(0)==="="?1:2,text:W[1],tokens:this.lexer.inline(W[1])}}paragraph(O){let W=this.rules.block.paragraph.exec(O);if(W){let V=W[1].charAt(W[1].length-1)===` `?W[1].slice(0,-1):W[1];return{type:"paragraph",raw:W[0],text:V,tokens:this.lexer.inline(V)}}}text(O){let W=this.rules.block.text.exec(O);if(W)return{type:"text",raw:W[0],text:W[0],tokens:this.lexer.inline(W[0])}}escape(O){let W=this.rules.inline.escape.exec(O);if(W)return{type:"escape",raw:W[0],text:d(W[1])}}tag(O){let W=this.rules.inline.tag.exec(O);if(W)return!this.lexer.state.inLink&&/^/i.test(W[0])&&(this.lexer.state.inLink=!1),!this.lexer.state.inRawBlock&&/^<(pre|code|kbd|script)(\s|>)/i.test(W[0])?this.lexer.state.inRawBlock=!0:this.lexer.state.inRawBlock&&/^<\/(pre|code|kbd|script)(\s|>)/i.test(W[0])&&(this.lexer.state.inRawBlock=!1),{type:"html",raw:W[0],inLink:this.lexer.state.inLink,inRawBlock:this.lexer.state.inRawBlock,block:!1,text:W[0]}}link(O){let W=this.rules.inline.link.exec(O);if(W){let V=W[2].trim();if(!this.options.pedantic&&/^$/.test(V))return;let xe=_(V.slice(0,-1),"\\");if((V.length-xe.length)%2===0)return}else{let xe=b(W[2],"()");if(xe>-1){let pt=(W[0].indexOf("!")===0?5:4)+W[1].length+xe;W[2]=W[2].substring(0,xe),W[0]=W[0].substring(0,pt).trim(),W[3]=""}}let G=W[2],ie="";if(this.options.pedantic){let xe=/^([^'"]*[^\s])\s+(['"])(.*)\2/.exec(G);xe&&(G=xe[1],ie=xe[3])}else ie=W[3]?W[3].slice(1,-1):"";return G=G.trim(),/^$/.test(V)?G=G.slice(1):G=G.slice(1,-1)),v(W,{href:G&&G.replace(this.rules.inline.anyPunctuation,"$1"),title:ie&&ie.replace(this.rules.inline.anyPunctuation,"$1")},W[0],this.lexer)}}reflink(O,W){let V;if((V=this.rules.inline.reflink.exec(O))||(V=this.rules.inline.nolink.exec(O))){let G=(V[2]||V[1]).replace(/\s+/g," "),ie=W[G.toLowerCase()];if(!ie){let xe=V[0].charAt(0);return{type:"text",raw:xe,text:xe}}return v(V,ie,V[0],this.lexer)}}emStrong(O,W,V=""){let G=this.rules.inline.emStrongLDelim.exec(O);if(!G||G[3]&&V.match(/[\p{L}\p{N}]/u))return;if(!(G[1]||G[2]||"")||!V||this.rules.inline.punctuation.exec(V)){let xe=[...G[0]].length-1,Ne,pt,Tt=xe,hi=0,mn=G[0][0]==="*"?this.rules.inline.emStrongRDelimAst:this.rules.inline.emStrongRDelimUnd;for(mn.lastIndex=0,W=W.slice(-1*O.length+xe);(G=mn.exec(W))!=null;){if(Ne=G[1]||G[2]||G[3]||G[4]||G[5]||G[6],!Ne)continue;if(pt=[...Ne].length,G[3]||G[4]){Tt+=pt;continue}else if((G[5]||G[6])&&xe%3&&!((xe+pt)%3)){hi+=pt;continue}if(Tt-=pt,Tt>0)continue;pt=Math.min(pt,pt+Tt+hi);let Tn=[...G[0]][0].length,xs=O.slice(0,xe+G.index+Tn+pt);if(Math.min(xe,pt)%2){let fd=xs.slice(1,-1);return{type:"em",raw:xs,text:fd,tokens:this.lexer.inlineTokens(fd)}}let qo=xs.slice(2,-2);return{type:"strong",raw:xs,text:qo,tokens:this.lexer.inlineTokens(qo)}}}}codespan(O){let W=this.rules.inline.code.exec(O);if(W){let V=W[2].replace(/\n/g," "),G=/[^ ]/.test(V),ie=/^ /.test(V)&&/ $/.test(V);return G&&ie&&(V=V.substring(1,V.length-1)),V=d(V,!0),{type:"codespan",raw:W[0],text:V}}}br(O){let W=this.rules.inline.br.exec(O);if(W)return{type:"br",raw:W[0]}}del(O){let W=this.rules.inline.del.exec(O);if(W)return{type:"del",raw:W[0],text:W[2],tokens:this.lexer.inlineTokens(W[2])}}autolink(O){let W=this.rules.inline.autolink.exec(O);if(W){let V,G;return W[2]==="@"?(V=d(W[1]),G="mailto:"+V):(V=d(W[1]),G=V),{type:"link",raw:W[0],text:V,href:G,tokens:[{type:"text",raw:V,text:V}]}}}url(O){let W;if(W=this.rules.inline.url.exec(O)){let V,G;if(W[2]==="@")V=d(W[0]),G="mailto:"+V;else{let ie;do ie=W[0],W[0]=this.rules.inline._backpedal.exec(W[0])?.[0]??"";while(ie!==W[0]);V=d(W[0]),W[1]==="www."?G="http://"+W[0]:G=W[0]}return{type:"link",raw:W[0],text:V,href:G,tokens:[{type:"text",raw:V,text:V}]}}}inlineText(O){let W=this.rules.inline.text.exec(O);if(W){let V;return this.lexer.state.inRawBlock?V=W[0]:V=d(W[0]),{type:"text",raw:W[0],text:V}}}}let y=/^(?: *(?:\n|$))+/,C=/^( {4}[^\n]+(?:\n(?: *(?:\n|$))*)?)+/,L=/^ {0,3}(`{3,}(?=[^`\n]*(?:\n|$))|~{3,})([^\n]*)(?:\n|$)(?:|([\s\S]*?)(?:\n|$))(?: {0,3}\1[~`]* *(?=\n|$)|$)/,E=/^ {0,3}((?:-[\t ]*){3,}|(?:_[ \t]*){3,}|(?:\*[ \t]*){3,})(?:\n+|$)/,N=/^ {0,3}(#{1,6})(?=\s|$)(.*)(?:\n+|$)/,M=/(?:[*+-]|\d{1,9}[.)])/,F=h(/^(?!bull |blockCode|fences|blockquote|heading|html)((?:.|\n(?!\s*?\n|bull |blockCode|fences|blockquote|heading|html))+?)\n {0,3}(=+|-+) *(?:\n+|$)/).replace(/bull/g,M).replace(/blockCode/g,/ {4}/).replace(/fences/g,/ {0,3}(?:`{3,}|~{3,})/).replace(/blockquote/g,/ {0,3}>/).replace(/heading/g,/ {0,3}#{1,6}/).replace(/html/g,/ {0,3}<[^\n>]+>\n/).getRegex(),q=/^([^\n]+(?:\n(?!hr|heading|lheading|blockquote|fences|list|html|table| +\n)[^\n]+)*)/,te=/^[^\n]+/,$=/(?!\s*\])(?:\\.|[^\[\]\\])+/,z=h(/^ {0,3}\[(label)\]: *(?:\n *)?([^<\s][^\s]*|<.*?>)(?:(?: +(?:\n *)?| *\n *)(title))? *(?:\n+|$)/).replace("label",$).replace("title",/(?:"(?:\\"?|[^"\\])*"|'[^'\n]*(?:\n[^'\n]+)*\n?'|\([^()]*\))/).getRegex(),ae=h(/^( {0,3}bull)([ \t][^\n]+?)?(?:\n|$)/).replace(/bull/g,M).getRegex(),X="address|article|aside|base|basefont|blockquote|body|caption|center|col|colgroup|dd|details|dialog|dir|div|dl|dt|fieldset|figcaption|figure|footer|form|frame|frameset|h[1-6]|head|header|hr|html|iframe|legend|li|link|main|menu|menuitem|meta|nav|noframes|ol|optgroup|option|p|param|search|section|summary|table|tbody|td|tfoot|th|thead|title|tr|track|ul",ue=/|$))/,ce=h("^ {0,3}(?:<(script|pre|style|textarea)[\\s>][\\s\\S]*?(?:[^\\n]*\\n+|$)|comment[^\\n]*(\\n+|$)|<\\?[\\s\\S]*?(?:\\?>\\n*|$)|\\n*|$)|\\n*|$)|)[\\s\\S]*?(?:(?:\\n *)+\\n|$)|<(?!script|pre|style|textarea)([a-z][\\w-]*)(?:attribute)*? */?>(?=[ \\t]*(?:\\n|$))[\\s\\S]*?(?:(?:\\n *)+\\n|$)|(?=[ \\t]*(?:\\n|$))[\\s\\S]*?(?:(?:\\n *)+\\n|$))","i").replace("comment",ue).replace("tag",X).replace("attribute",/ +[a-zA-Z:_][\w.:-]*(?: *= *"[^"\n]*"| *= *'[^'\n]*'| *= *[^\s"'=<>`]+)?/).getRegex(),B=h(q).replace("hr",E).replace("heading"," {0,3}#{1,6}(?:\\s|$)").replace("|lheading","").replace("|table","").replace("blockquote"," {0,3}>").replace("fences"," {0,3}(?:`{3,}(?=[^`\\n]*\\n)|~{3,})[^\\n]*\\n").replace("list"," {0,3}(?:[*+-]|1[.)]) ").replace("html",")|<(?:script|pre|style|textarea|!--)").replace("tag",X).getRegex(),ni={blockquote:h(/^( {0,3}> ?(paragraph|[^\n]*)(?:\n|$))+/).replace("paragraph",B).getRegex(),code:C,def:z,fences:L,heading:N,hr:E,html:ce,lheading:F,list:ae,newline:y,paragraph:B,table:p,text:te},K=h("^ *([^\\n ].*)\\n {0,3}((?:\\| *)?:?-+:? *(?:\\| *:?-+:? *)*(?:\\| *)?)(?:\\n((?:(?! *\\n|hr|heading|blockquote|code|fences|list|html).*(?:\\n|$))*)\\n*|$)").replace("hr",E).replace("heading"," {0,3}#{1,6}(?:\\s|$)").replace("blockquote"," {0,3}>").replace("code"," {4}[^\\n]").replace("fences"," {0,3}(?:`{3,}(?=[^`\\n]*\\n)|~{3,})[^\\n]*\\n").replace("list"," {0,3}(?:[*+-]|1[.)]) ").replace("html",")|<(?:script|pre|style|textarea|!--)").replace("tag",X).getRegex(),Ni={...ni,table:K,paragraph:h(q).replace("hr",E).replace("heading"," {0,3}#{1,6}(?:\\s|$)").replace("|lheading","").replace("table",K).replace("blockquote"," {0,3}>").replace("fences"," {0,3}(?:`{3,}(?=[^`\\n]*\\n)|~{3,})[^\\n]*\\n").replace("list"," {0,3}(?:[*+-]|1[.)]) ").replace("html",")|<(?:script|pre|style|textarea|!--)").replace("tag",X).getRegex()},ui={...ni,html:h(`^ *(?:comment *(?:\\n|\\s*$)|<(tag)[\\s\\S]+? *(?:\\n{2,}|\\s*$)|\\s]*)*?/?> *(?:\\n{2,}|\\s*$))`).replace("comment",ue).replace(/tag/g,"(?!(?:a|em|strong|small|s|cite|q|dfn|abbr|data|time|code|var|samp|kbd|sub|sup|i|b|u|mark|ruby|rt|rp|bdi|bdo|span|br|wbr|ins|del|img)\\b)\\w+(?!:|[^\\w\\s@]*@)\\b").getRegex(),def:/^ *\[([^\]]+)\]: *]+)>?(?: +(["(][^\n]+[")]))? *(?:\n+|$)/,heading:/^(#{1,6})(.*)(?:\n+|$)/,fences:p,lheading:/^(.+?)\n {0,3}(=+|-+) *(?:\n+|$)/,paragraph:h(q).replace("hr",E).replace("heading",` *#{1,6} *[^ ]`).replace("lheading",F).replace("|table","").replace("blockquote"," {0,3}>").replace("|fences","").replace("|list","").replace("|html","").replace("|tag","").getRegex()},po=/^\\([!"#$%&'()*+,\-./:;<=>?@\[\]\\^_`{|}~])/,Jr=/^(`+)([^`]|[^`][\s\S]*?[^`])\1(?!`)/,Ri=/^( {2,}|\\)\n(?!\s*$)/,vs=/^(`+|[^`])(?:(?= {2,}\n)|[\s\S]*?(?:(?=[\\]*?>/g,Yf=h(/^(?:\*+(?:((?!\*)[punct])|[^\s*]))|^_+(?:((?!_)[punct])|([^\s_]))/,"u").replace(/punct/g,da).getRegex(),Kl=h("^[^_*]*?__[^_*]*?\\*[^_*]*?(?=__)|[^*]+(?=[^*])|(?!\\*)[punct](\\*+)(?=[\\s]|$)|[^punct\\s](\\*+)(?!\\*)(?=[punct\\s]|$)|(?!\\*)[punct\\s](\\*+)(?=[^punct\\s])|[\\s](\\*+)(?!\\*)(?=[punct])|(?!\\*)[punct](\\*+)(?!\\*)(?=[punct])|[^punct\\s](\\*+)(?=[^punct\\s])","gu").replace(/punct/g,da).getRegex(),sm=h("^[^_*]*?\\*\\*[^_*]*?_[^_*]*?(?=\\*\\*)|[^_]+(?=[^_])|(?!_)[punct](_+)(?=[\\s]|$)|[^punct\\s](_+)(?!_)(?=[punct\\s]|$)|(?!_)[punct\\s](_+)(?=[^punct\\s])|[\\s](_+)(?!_)(?=[punct])|(?!_)[punct](_+)(?!_)(?=[punct])","gu").replace(/punct/g,da).getRegex(),am=h(/\\([punct])/,"gu").replace(/punct/g,da).getRegex(),Yu=h(/^<(scheme:[^\s\x00-\x1f<>]*|email)>/).replace("scheme",/[a-zA-Z][a-zA-Z0-9+.-]{1,31}/).replace("email",/[a-zA-Z0-9.!#$%&'*+/=?^_`{|}~-]+(@)[a-zA-Z0-9](?:[a-zA-Z0-9-]{0,61}[a-zA-Z0-9])?(?:\.[a-zA-Z0-9](?:[a-zA-Z0-9-]{0,61}[a-zA-Z0-9])?)+(?![-_])/).getRegex(),gt=h(ue).replace("(?:-->|$)","-->").getRegex(),Ii=h("^comment|^|^<[a-zA-Z][\\w-]*(?:attribute)*?\\s*/?>|^<\\?[\\s\\S]*?\\?>|^|^").replace("comment",gt).replace("attribute",/\s+[a-zA-Z:_][\w.:-]*(?:\s*=\s*"[^"]*"|\s*=\s*'[^']*'|\s*=\s*[^\s"'=<>`]+)?/).getRegex(),un=/(?:\[(?:\\.|[^\[\]\\])*\]|\\.|`[^`]*`|[^\[\]\\`])*?/,Ao=h(/^!?\[(label)\]\(\s*(href)(?:\s+(title))?\s*\)/).replace("label",un).replace("href",/<(?:\\.|[^\n<>\\])+>|[^\s\x00-\x1f]*/).replace("title",/"(?:\\"?|[^"\\])*"|'(?:\\'?|[^'\\])*'|\((?:\\\)?|[^)\\])*\)/).getRegex(),Tr=h(/^!?\[(label)\]\[(ref)\]/).replace("label",un).replace("ref",$).getRegex(),Hr=h(/^!?\[(ref)\](?:\[\])?/).replace("ref",$).getRegex(),Hs=h("reflink|nolink(?!\\()","g").replace("reflink",Tr).replace("nolink",Hr).getRegex(),Gl={_backpedal:p,anyPunctuation:am,autolink:Yu,blockSkip:ql,br:Ri,code:Jr,del:p,emStrongLDelim:Yf,emStrongRDelimAst:Kl,emStrongRDelimUnd:sm,escape:po,link:Ao,nolink:Hr,punctuation:Sc,reflink:Tr,reflinkSearch:Hs,tag:Ii,text:vs,url:p},Re={...Gl,link:h(/^!?\[(label)\]\((.*?)\)/).replace("label",un).getRegex(),reflink:h(/^!?\[(label)\]\s*\[([^\]]*)\]/).replace("label",un).getRegex()},nt={...Gl,escape:h(po).replace("])","~|])").getRegex(),url:h(/^((?:ftp|https?):\/\/|www\.)(?:[a-zA-Z0-9\-]+\.?)+[^\s<]*|^email/,"i").replace("email",/[A-Za-z0-9._+-]+(@)[a-zA-Z0-9-_]+(?:\.[a-zA-Z0-9-_]*[a-zA-Z0-9])+(?![-_])/).getRegex(),_backpedal:/(?:[^?!.,:;*_'"~()&]+|\([^)]*\)|&(?![a-zA-Z0-9]+;$)|[?!.,:;*_'"~)]+(?!$))+/,del:/^(~~?)(?=[^\s~])([\s\S]*?[^\s~])\1(?=[^~]|$)/,text:/^([`~]+|[^`~])(?:(?= {2,}\n)|(?=[a-zA-Z0-9.!#$%&'*+\/=?_`{\|}~-]+@)|[\s\S]*?(?:(?=[\\pt+" ".repeat(Tt.length));let G,ie,xe;for(;O;)if(!(this.options.extensions&&this.options.extensions.block&&this.options.extensions.block.some(Ne=>(G=Ne.call({lexer:this},O,W))?(O=O.substring(G.raw.length),W.push(G),!0):!1))){if(G=this.tokenizer.space(O)){O=O.substring(G.raw.length),G.raw.length===1&&W.length>0?W[W.length-1].raw+=` `:W.push(G);continue}if(G=this.tokenizer.code(O)){O=O.substring(G.raw.length),ie=W[W.length-1],ie&&(ie.type==="paragraph"||ie.type==="text")?(ie.raw+=` `+G.raw,ie.text+=` `+G.text,this.inlineQueue[this.inlineQueue.length-1].src=ie.text):W.push(G);continue}if(G=this.tokenizer.fences(O)){O=O.substring(G.raw.length),W.push(G);continue}if(G=this.tokenizer.heading(O)){O=O.substring(G.raw.length),W.push(G);continue}if(G=this.tokenizer.hr(O)){O=O.substring(G.raw.length),W.push(G);continue}if(G=this.tokenizer.blockquote(O)){O=O.substring(G.raw.length),W.push(G);continue}if(G=this.tokenizer.list(O)){O=O.substring(G.raw.length),W.push(G);continue}if(G=this.tokenizer.html(O)){O=O.substring(G.raw.length),W.push(G);continue}if(G=this.tokenizer.def(O)){O=O.substring(G.raw.length),ie=W[W.length-1],ie&&(ie.type==="paragraph"||ie.type==="text")?(ie.raw+=` `+G.raw,ie.text+=` `+G.raw,this.inlineQueue[this.inlineQueue.length-1].src=ie.text):this.tokens.links[G.tag]||(this.tokens.links[G.tag]={href:G.href,title:G.title});continue}if(G=this.tokenizer.table(O)){O=O.substring(G.raw.length),W.push(G);continue}if(G=this.tokenizer.lheading(O)){O=O.substring(G.raw.length),W.push(G);continue}if(xe=O,this.options.extensions&&this.options.extensions.startBlock){let Ne=1/0,pt=O.slice(1),Tt;this.options.extensions.startBlock.forEach(hi=>{Tt=hi.call({lexer:this},pt),typeof Tt=="number"&&Tt>=0&&(Ne=Math.min(Ne,Tt))}),Ne<1/0&&Ne>=0&&(xe=O.substring(0,Ne+1))}if(this.state.top&&(G=this.tokenizer.paragraph(xe))){ie=W[W.length-1],V&&ie?.type==="paragraph"?(ie.raw+=` `+G.raw,ie.text+=` `+G.text,this.inlineQueue.pop(),this.inlineQueue[this.inlineQueue.length-1].src=ie.text):W.push(G),V=xe.length!==O.length,O=O.substring(G.raw.length);continue}if(G=this.tokenizer.text(O)){O=O.substring(G.raw.length),ie=W[W.length-1],ie&&ie.type==="text"?(ie.raw+=` `+G.raw,ie.text+=` `+G.text,this.inlineQueue.pop(),this.inlineQueue[this.inlineQueue.length-1].src=ie.text):W.push(G);continue}if(O){let Ne="Infinite loop on byte: "+O.charCodeAt(0);if(this.options.silent){console.error(Ne);break}else throw new Error(Ne)}}return this.state.top=!0,W}inline(O,W=[]){return this.inlineQueue.push({src:O,tokens:W}),W}inlineTokens(O,W=[]){let V,G,ie,xe=O,Ne,pt,Tt;if(this.tokens.links){let hi=Object.keys(this.tokens.links);if(hi.length>0)for(;(Ne=this.tokenizer.rules.inline.reflinkSearch.exec(xe))!=null;)hi.includes(Ne[0].slice(Ne[0].lastIndexOf("[")+1,-1))&&(xe=xe.slice(0,Ne.index)+"["+"a".repeat(Ne[0].length-2)+"]"+xe.slice(this.tokenizer.rules.inline.reflinkSearch.lastIndex))}for(;(Ne=this.tokenizer.rules.inline.blockSkip.exec(xe))!=null;)xe=xe.slice(0,Ne.index)+"["+"a".repeat(Ne[0].length-2)+"]"+xe.slice(this.tokenizer.rules.inline.blockSkip.lastIndex);for(;(Ne=this.tokenizer.rules.inline.anyPunctuation.exec(xe))!=null;)xe=xe.slice(0,Ne.index)+"++"+xe.slice(this.tokenizer.rules.inline.anyPunctuation.lastIndex);for(;O;)if(pt||(Tt=""),pt=!1,!(this.options.extensions&&this.options.extensions.inline&&this.options.extensions.inline.some(hi=>(V=hi.call({lexer:this},O,W))?(O=O.substring(V.raw.length),W.push(V),!0):!1))){if(V=this.tokenizer.escape(O)){O=O.substring(V.raw.length),W.push(V);continue}if(V=this.tokenizer.tag(O)){O=O.substring(V.raw.length),G=W[W.length-1],G&&V.type==="text"&&G.type==="text"?(G.raw+=V.raw,G.text+=V.text):W.push(V);continue}if(V=this.tokenizer.link(O)){O=O.substring(V.raw.length),W.push(V);continue}if(V=this.tokenizer.reflink(O,this.tokens.links)){O=O.substring(V.raw.length),G=W[W.length-1],G&&V.type==="text"&&G.type==="text"?(G.raw+=V.raw,G.text+=V.text):W.push(V);continue}if(V=this.tokenizer.emStrong(O,xe,Tt)){O=O.substring(V.raw.length),W.push(V);continue}if(V=this.tokenizer.codespan(O)){O=O.substring(V.raw.length),W.push(V);continue}if(V=this.tokenizer.br(O)){O=O.substring(V.raw.length),W.push(V);continue}if(V=this.tokenizer.del(O)){O=O.substring(V.raw.length),W.push(V);continue}if(V=this.tokenizer.autolink(O)){O=O.substring(V.raw.length),W.push(V);continue}if(!this.state.inLink&&(V=this.tokenizer.url(O))){O=O.substring(V.raw.length),W.push(V);continue}if(ie=O,this.options.extensions&&this.options.extensions.startInline){let hi=1/0,mn=O.slice(1),Tn;this.options.extensions.startInline.forEach(xs=>{Tn=xs.call({lexer:this},mn),typeof Tn=="number"&&Tn>=0&&(hi=Math.min(hi,Tn))}),hi<1/0&&hi>=0&&(ie=O.substring(0,hi+1))}if(V=this.tokenizer.inlineText(ie)){O=O.substring(V.raw.length),V.raw.slice(-1)!=="_"&&(Tt=V.raw.slice(-1)),pt=!0,G=W[W.length-1],G&&G.type==="text"?(G.raw+=V.raw,G.text+=V.text):W.push(V);continue}if(O){let hi="Infinite loop on byte: "+O.charCodeAt(0);if(this.options.silent){console.error(hi);break}else throw new Error(hi)}}return W}}class fl{options;parser;constructor(O){this.options=O||e.defaults}space(O){return""}code({text:O,lang:W,escaped:V}){let G=(W||"").match(/^\S*/)?.[0],ie=O.replace(/\n$/,"")+` `;return G?'
'+(V?ie:d(ie,!0))+`
`:"
"+(V?ie:d(ie,!0))+`
`}blockquote({tokens:O}){return`
${this.parser.parse(O)}
`}html({text:O}){return O}heading({tokens:O,depth:W}){return`${this.parser.parseInline(O)} `}hr(O){return`
`}list(O){let W=O.ordered,V=O.start,G="";for(let Ne=0;Ne `+G+" `}listitem(O){let W="";if(O.task){let V=this.checkbox({checked:!!O.checked});O.loose?O.tokens.length>0&&O.tokens[0].type==="paragraph"?(O.tokens[0].text=V+" "+O.tokens[0].text,O.tokens[0].tokens&&O.tokens[0].tokens.length>0&&O.tokens[0].tokens[0].type==="text"&&(O.tokens[0].tokens[0].text=V+" "+O.tokens[0].tokens[0].text)):O.tokens.unshift({type:"text",raw:V+" ",text:V+" "}):W+=V+" "}return W+=this.parser.parse(O.tokens,!!O.loose),`
  • ${W}
  • `}checkbox({checked:O}){return"'}paragraph({tokens:O}){return`

    ${this.parser.parseInline(O)}

    `}table(O){let W="",V="";for(let ie=0;ie${G}`),` `+W+` `+G+`
    `}tablerow({text:O}){return` ${O} `}tablecell(O){let W=this.parser.parseInline(O.tokens),V=O.header?"th":"td";return(O.align?`<${V} align="${O.align}">`:`<${V}>`)+W+` `}strong({tokens:O}){return`${this.parser.parseInline(O)}`}em({tokens:O}){return`${this.parser.parseInline(O)}`}codespan({text:O}){return`${O}`}br(O){return"
    "}del({tokens:O}){return`${this.parser.parseInline(O)}`}link({href:O,title:W,tokens:V}){let G=this.parser.parseInline(V),ie=f(O);if(ie===null)return G;O=ie;let xe='
    ",xe}image({href:O,title:W,text:V}){let G=f(O);if(G===null)return V;O=G;let ie=`${V}{let Ne=ie[xe].flat(1/0);V=V.concat(this.walkTokens(Ne,W))}):ie.tokens&&(V=V.concat(this.walkTokens(ie.tokens,W)))}}return V}use(...O){let W=this.defaults.extensions||{renderers:{},childTokens:{}};return O.forEach(V=>{let G={...V};if(G.async=this.defaults.async||G.async||!1,V.extensions&&(V.extensions.forEach(ie=>{if(!ie.name)throw new Error("extension name required");if("renderer"in ie){let xe=W.renderers[ie.name];xe?W.renderers[ie.name]=function(...Ne){let pt=ie.renderer.apply(this,Ne);return pt===!1&&(pt=xe.apply(this,Ne)),pt}:W.renderers[ie.name]=ie.renderer}if("tokenizer"in ie){if(!ie.level||ie.level!=="block"&&ie.level!=="inline")throw new Error("extension level must be 'block' or 'inline'");let xe=W[ie.level];xe?xe.unshift(ie.tokenizer):W[ie.level]=[ie.tokenizer],ie.start&&(ie.level==="block"?W.startBlock?W.startBlock.push(ie.start):W.startBlock=[ie.start]:ie.level==="inline"&&(W.startInline?W.startInline.push(ie.start):W.startInline=[ie.start]))}"childTokens"in ie&&ie.childTokens&&(W.childTokens[ie.name]=ie.childTokens)}),G.extensions=W),V.renderer){let ie=this.defaults.renderer||new fl(this.defaults);for(let xe in V.renderer){if(!(xe in ie))throw new Error(`renderer '${xe}' does not exist`);if(["options","parser"].includes(xe))continue;let Ne=xe,pt=V.renderer[Ne],Tt=ie[Ne];ie[Ne]=(...hi)=>{let mn=pt.apply(ie,hi);return mn===!1&&(mn=Tt.apply(ie,hi)),mn||""}}G.renderer=ie}if(V.tokenizer){let ie=this.defaults.tokenizer||new w(this.defaults);for(let xe in V.tokenizer){if(!(xe in ie))throw new Error(`tokenizer '${xe}' does not exist`);if(["options","rules","lexer"].includes(xe))continue;let Ne=xe,pt=V.tokenizer[Ne],Tt=ie[Ne];ie[Ne]=(...hi)=>{let mn=pt.apply(ie,hi);return mn===!1&&(mn=Tt.apply(ie,hi)),mn}}G.tokenizer=ie}if(V.hooks){let ie=this.defaults.hooks||new pl;for(let xe in V.hooks){if(!(xe in ie))throw new Error(`hook '${xe}' does not exist`);if(xe==="options")continue;let Ne=xe,pt=V.hooks[Ne],Tt=ie[Ne];pl.passThroughHooks.has(xe)?ie[Ne]=hi=>{if(this.defaults.async)return Promise.resolve(pt.call(ie,hi)).then(Tn=>Tt.call(ie,Tn));let mn=pt.call(ie,hi);return Tt.call(ie,mn)}:ie[Ne]=(...hi)=>{let mn=pt.apply(ie,hi);return mn===!1&&(mn=Tt.apply(ie,hi)),mn}}G.hooks=ie}if(V.walkTokens){let ie=this.defaults.walkTokens,xe=V.walkTokens;G.walkTokens=function(Ne){let pt=[];return pt.push(xe.call(this,Ne)),ie&&(pt=pt.concat(ie.call(this,Ne))),pt}}this.defaults={...this.defaults,...G}}),this}setOptions(O){return this.defaults={...this.defaults,...O},this}lexer(O,W){return ur.lex(O,W??this.defaults)}parser(O,W){return er.parse(O,W??this.defaults)}parseMarkdown(O,W){return(G,ie)=>{let xe={...ie},Ne={...this.defaults,...xe},pt=this.onError(!!Ne.silent,!!Ne.async);if(this.defaults.async===!0&&xe.async===!1)return pt(new Error("marked(): The async option was set to true by an extension. Remove async: false from the parse options object to return a Promise."));if(typeof G>"u"||G===null)return pt(new Error("marked(): input parameter is undefined or null"));if(typeof G!="string")return pt(new Error("marked(): input parameter is of type "+Object.prototype.toString.call(G)+", string expected"));if(Ne.hooks&&(Ne.hooks.options=Ne),Ne.async)return Promise.resolve(Ne.hooks?Ne.hooks.preprocess(G):G).then(Tt=>O(Tt,Ne)).then(Tt=>Ne.hooks?Ne.hooks.processAllTokens(Tt):Tt).then(Tt=>Ne.walkTokens?Promise.all(this.walkTokens(Tt,Ne.walkTokens)).then(()=>Tt):Tt).then(Tt=>W(Tt,Ne)).then(Tt=>Ne.hooks?Ne.hooks.postprocess(Tt):Tt).catch(pt);try{Ne.hooks&&(G=Ne.hooks.preprocess(G));let Tt=O(G,Ne);Ne.hooks&&(Tt=Ne.hooks.processAllTokens(Tt)),Ne.walkTokens&&this.walkTokens(Tt,Ne.walkTokens);let hi=W(Tt,Ne);return Ne.hooks&&(hi=Ne.hooks.postprocess(hi)),hi}catch(Tt){return pt(Tt)}}}onError(O,W){return V=>{if(V.message+=` Please report this to https://github.com/markedjs/marked.`,O){let G="

    An error occurred:

    "+d(V.message+"",!0)+"
    ";return W?Promise.resolve(G):G}if(W)return Promise.reject(V);throw V}}}let ml=new ua;function Xi(wi,O){return ml.parse(wi,O)}Xi.options=Xi.setOptions=function(wi){return ml.setOptions(wi),Xi.defaults=ml.defaults,i(Xi.defaults),Xi},Xi.getDefaults=t,Xi.defaults=e.defaults,Xi.use=function(...wi){return ml.use(...wi),Xi.defaults=ml.defaults,i(Xi.defaults),Xi},Xi.walkTokens=function(wi,O){return ml.walkTokens(wi,O)},Xi.parseInline=ml.parseInline,Xi.Parser=er,Xi.parser=er.parse,Xi.Renderer=fl,Xi.TextRenderer=qa,Xi.Lexer=ur,Xi.lexer=ur.lex,Xi.Tokenizer=w,Xi.Hooks=pl,Xi.parse=Xi;let Ey=Xi.options,RX=Xi.setOptions,AX=Xi.use,ha=Xi.walkTokens,bv=Xi.parseInline,MX=Xi,X4=er.parse,nN=ur.lex;e.Hooks=pl,e.Lexer=ur,e.Marked=ua,e.Parser=er,e.Renderer=fl,e.TextRenderer=qa,e.Tokenizer=w,e.getDefaults=t,e.lexer=nN,e.marked=Xi,e.options=Ey,e.parse=MX,e.parseInline=bv,e.parser=X4,e.setOptions=RX,e.use=AX,e.walkTokens=ha})})();Iqt=ol.Hooks||exports.Hooks,Eqt=ol.Lexer||exports.Lexer,Tqt=ol.Marked||exports.Marked,Dqt=ol.Parser||exports.Parser,Jse=ol.Renderer||exports.Renderer,Nqt=ol.TextRenderer||exports.TextRenderer,Rqt=ol.Tokenizer||exports.Tokenizer,T2e=ol.defaults||exports.defaults,Aqt=ol.getDefaults||exports.getDefaults,gM=ol.lexer||exports.lexer,Mqt=ol.marked||exports.marked,Pqt=ol.options||exports.options,eae=ol.parse||exports.parse,Oqt=ol.parseInline||exports.parseInline,D2e=ol.parser||exports.parser,Fqt=ol.setOptions||exports.setOptions,Bqt=ol.use||exports.use,Wqt=ol.walkTokens||exports.walkTokens});function R2e(n){return JSON.stringify(n,$at)}function _M(n){let e=JSON.parse(n);return e=tae(e),e}function $at(n,e){return e instanceof RegExp?{$mid:2,source:e.source,flags:e.flags}:e}function tae(n,e=0){if(!n||e>200)return n;if(typeof n=="object"){switch(n.$mid){case 1:return Ee.revive(n);case 2:return new RegExp(n.source,n.flags);case 17:return new Date(n.source)}if(n instanceof xL||n instanceof Uint8Array)return n;if(Array.isArray(n))for(let t=0;t{wL();Ai()});function ow(n,e={},t={}){let i=new H,o=!1,r=n7(e),s=function(g){let _;try{_=_M(decodeURIComponent(g))}catch{}return _?(_=R3(_,b=>{if(n.uris&&n.uris[b])return Ee.revive(n.uris[b])}),encodeURIComponent(JSON.stringify(_))):g},a=function(g,_){let b=n.uris&&n.uris[g],v=Ee.revive(b);return _?g.startsWith(rt.data+":")?g:(v||(v=Ee.parse(g)),U_.uriToBrowserUri(v).toString(!0)):!v||Ee.parse(g).toString()===v.toString()?g:(v.query&&(v=v.with({query:s(v.query)})),v.toString())},l=new Jse;l.image=iae.image,l.link=iae.link,l.paragraph=iae.paragraph;let c=[],d=[];if(e.codeBlockRendererSync?l.code=({text:g,lang:_})=>{let b=pM.nextId(),v=e.codeBlockRendererSync(A2e(_),g);return d.push([b,v]),`
    ${gx(g)}
    `}:e.codeBlockRenderer&&(l.code=({text:g,lang:_})=>{let b=pM.nextId(),v=e.codeBlockRenderer(A2e(_),g);return c.push(v.then(x=>[b,x])),`
    ${gx(g)}
    `}),e.actionHandler){let g=function(v){let x=v.target;if(!(x.tagName!=="A"&&(x=x.parentElement,!x||x.tagName!=="A")))try{let w=x.dataset.href;w&&(n.baseUri&&(w=nae(Ee.from(n.baseUri),w)),e.actionHandler.callback(w,v))}catch(w){Be(w)}finally{v.preventDefault()}},_=e.actionHandler.disposables.add(new Mt(r,"click")),b=e.actionHandler.disposables.add(new Mt(r,"auxclick"));e.actionHandler.disposables.add(ne.any(_.event,b.event)(v=>{let x=new cs(Me(r),v);!x.leftButton&&!x.middleButton||g(x)})),e.actionHandler.disposables.add(U(r,"keydown",v=>{let x=new Xt(v);!x.equals(10)&&!x.equals(3)||g(x)}))}n.supportHtml||(l.html=({text:g})=>e.sanitizerOptions?.replaceWithPlaintext?gx(g):(n.isTrusted?g.match(/^(]+>)|(<\/\s*span>)$/):void 0)?g:""),t.renderer=l;let u=n.value??"";u.length>1e5&&(u=`${u.substr(0,1e5)}\u2026`),n.supportThemeIcons&&(u=b2e(u));let h;if(e.fillInIncompleteTokens){let g={...T2e,...t},_=gM(u,g),b=ilt(_);h=D2e(b,g)}else h=eae(u,{...t,async:!1});n.supportThemeIcons&&(h=Iu(h).map(_=>typeof _=="string"?_:_.outerHTML).join(""));let p=new DOMParser().parseFromString(oae({isTrusted:n.isTrusted,...e.sanitizerOptions},h),"text/html");if(p.body.querySelectorAll("img, audio, video, source").forEach(g=>{let _=g.getAttribute("src");if(_){let b=_;try{n.baseUri&&(b=nae(Ee.from(n.baseUri),b))}catch{}if(g.setAttribute("src",a(b,!0)),e.remoteImageIsAllowed){let v=Ee.parse(b);v.scheme!==rt.file&&v.scheme!==rt.data&&!e.remoteImageIsAllowed(v)&&g.replaceWith(J("",void 0,g.outerHTML))}}}),p.body.querySelectorAll("a").forEach(g=>{let _=g.getAttribute("href");if(g.setAttribute("href",""),!_||/^data:|javascript:/i.test(_)||/^command:/i.test(_)&&!n.isTrusted||/^command:(\/\/\/)?_workbench\.downloadResource/i.test(_))g.replaceWith(...g.childNodes);else{let b=a(_,!1);n.baseUri&&(b=nae(Ee.from(n.baseUri),_)),g.dataset.href=b}}),r.innerHTML=oae({isTrusted:n.isTrusted,...e.sanitizerOptions},p.body.innerHTML),c.length>0)Promise.all(c).then(g=>{if(o)return;let _=new Map(g),b=r.querySelectorAll("div[data-code]");for(let v of b){let x=_.get(v.dataset.code??"");x&&oo(v,x)}e.asyncRenderCallback?.()});else if(d.length>0){let g=new Map(d),_=r.querySelectorAll("div[data-code]");for(let b of _){let v=g.get(b.dataset.code??"");v&&oo(b,v)}}if(e.asyncRenderCallback)for(let g of r.getElementsByTagName("img")){let _=i.add(U(g,"load",()=>{_.dispose(),e.asyncRenderCallback()}))}return{element:r,dispose:()=>{o=!0,i.dispose()}}}function A2e(n){if(!n)return"";let e=n.split(/[\s+|:|,|\{|\?]/,1);return e.length?e[0]:n}function nae(n,e){return/^\w[\w\d+.-]*:/.test(e)?e:n.path.endsWith("/")?Qse(n,e).toString():Qse(nw(n),e).toString()}function oae(n,e){let{config:t,allowedSchemes:i}=Kat(n),o=new H;o.add(M2e("uponSanitizeAttribute",(r,s)=>{if(s.attrName==="style"||s.attrName==="class"){if(r.tagName==="SPAN"){if(s.attrName==="style"){s.keepAttr=/^(color\:(#[0-9a-fA-F]+|var\(--vscode(-[a-zA-Z]+)+\));)?(background-color\:(#[0-9a-fA-F]+|var\(--vscode(-[a-zA-Z]+)+\));)?(border-radius:[0-9]+px;)?$/.test(s.attrValue);return}else if(s.attrName==="class"){s.keepAttr=/^codicon codicon-[a-z\-]+( codicon-modifier-[a-z\-]+)?$/.test(s.attrValue);return}}s.keepAttr=!1;return}else if(r.tagName==="INPUT"&&r.attributes.getNamedItem("type")?.value==="checkbox"){if(s.attrName==="type"&&s.attrValue==="checkbox"||s.attrName==="disabled"||s.attrName==="checked"){s.keepAttr=!0;return}s.keepAttr=!1}})),o.add(M2e("uponSanitizeElement",(r,s)=>{if(s.tagName==="input"&&(r.attributes.getNamedItem("type")?.value==="checkbox"?r.setAttribute("disabled",""):n.replaceWithPlaintext||r.remove()),n.replaceWithPlaintext&&!s.allowedTags[s.tagName]&&s.tagName!=="body"&&r.parentElement){let a,l;if(s.tagName==="#comment")a=``;else{let h=jat.includes(s.tagName),f=r.attributes.length?" "+Array.from(r.attributes).map(p=>`${p.name}="${p.value}"`).join(" "):"";a=`<${s.tagName}${f}>`,h||(l=``)}let c=document.createDocumentFragment(),d=r.parentElement.ownerDocument.createTextNode(a);c.appendChild(d);let u=l?r.parentElement.ownerDocument.createTextNode(l):void 0;for(;r.firstChild;)c.appendChild(r.firstChild);u&&c.appendChild(u),r.nodeType===Node.COMMENT_NODE?r.parentElement.insertBefore(c,r):r.parentElement.replaceChild(c,r)}})),o.add(TDe(i));try{return SB(e,{...t,RETURN_TRUSTED_TYPE:!0})}finally{o.dispose()}}function Kat(n){let e=[rt.http,rt.https,rt.mailto,rt.data,rt.file,rt.vscodeFileResource,rt.vscodeRemote,rt.vscodeRemoteResource];return n.isTrusted&&e.push(rt.command),{config:{ALLOWED_TAGS:n.allowedTags??[...DDe],ALLOWED_ATTR:qat,ALLOW_UNKNOWN_PROTOCOLS:!0},allowedSchemes:e}}function P2e(n){return typeof n=="string"?n:Gat(n)}function Gat(n,e){let t=n.value??"";t.length>1e5&&(t=`${t.substr(0,1e5)}\u2026`);let i=eae(t,{async:!1,renderer:e?Xat.value:Zat.value}).replace(/&(#\d+|[a-zA-Z]+);/g,o=>Yat.get(o)??o);return oae({isTrusted:!1},i).toString()}function O2e(){let n=new Jse;return n.code=({text:e})=>e,n.blockquote=({text:e})=>e+` `,n.html=e=>"",n.heading=function({tokens:e}){return this.parser.parseInline(e)+` `},n.hr=()=>"",n.list=function({items:e}){return e.map(t=>this.listitem(t)).join(` `)+` `},n.listitem=({text:e})=>e+` `,n.paragraph=function({tokens:e}){return this.parser.parseInline(e)+` `},n.table=function({header:e,rows:t}){return e.map(i=>this.tablecell(i)).join(" ")+` `+t.map(i=>i.map(o=>this.tablecell(o)).join(" ")).join(` `)+` `},n.tablerow=({text:e})=>e,n.tablecell=function({tokens:e}){return this.parser.parseInline(e)},n.strong=({text:e})=>e,n.em=({text:e})=>e,n.codespan=({text:e})=>e,n.br=e=>` `,n.del=({text:e})=>e,n.image=e=>"",n.text=({text:e})=>e,n.link=({text:e})=>e,n}function h7(n){let e="";return n.forEach(t=>{e+=t.raw}),e}function F2e(n){if(n.tokens)for(let e=n.tokens.length-1;e>=0;e--){let t=n.tokens[e];if(t.type==="text"){let i=t.raw.split(` `),o=i[i.length-1];if(o.includes("`"))return olt(n);if(o.includes("**"))return dlt(n);if(o.match(/\*\w/))return rlt(n);if(o.match(/(^|\s)__\w/))return ult(n);if(o.match(/(^|\s)_\w/))return slt(n);if(Qat(o)||Jat(o)&&n.tokens.slice(0,e).some(r=>r.type==="text"&&r.raw.match(/\[[^\]]*$/))){let r=n.tokens.slice(e+1);return r[0]?.type==="link"&&r[1]?.type==="text"&&r[1].raw.match(/^ *"[^"]*$/)||o.match(/^[^"]* +"[^"]*$/)?llt(n):alt(n)}else if(o.match(/(^|\s)\[\w*/))return clt(n)}}}function Qat(n){return!!n.match(/(^|\s)\[.*\]\(\w*/)}function Jat(n){return!!n.match(/^[^\[]*\]\([^\)]*$/)}function elt(n){let e=n.items[n.items.length-1],t=e.tokens?e.tokens[e.tokens.length-1]:void 0,i;if(t?.type==="text"&&!("inRawBlock"in e)&&(i=F2e(t)),!i||i.type!=="paragraph")return;let o=h7(n.items.slice(0,-1)),r=e.raw.match(/^(\s*(-|\d+\.|\*) +)/)?.[0];if(!r)return;let s=r+h7(e.tokens.slice(0,-1))+i.raw,a=gM(o+s)[0];if(a.type==="list")return a}function ilt(n){for(let e=0;e"u"&&s.match(/^\s*\|/)){let a=s.match(/(\|[^\|]+)(?=\||$)/g);a&&(i=a.length)}else if(typeof i=="number")if(s.match(/^\s*\|/)){if(r!==t.length-1)return;o=!0}else return}if(typeof i=="number"&&i>0){let r=o?t.slice(0,-1).join(` `):e,s=!!r.match(/\|\s*$/),a=r+(s?"":"|")+` |${" --- |".repeat(i)}`;return gM(a)}}function M2e(n,e){return kB(n,e),ge(()=>LB(n))}var iae,jat,qat,Yat,Zat,Xat,tlt,bM=k(()=>{ke();IB();Sf();Ase();Ks();pu();ub();je();Ie();Pl();fC();mM();cp();j();N2e();u7();ds();ec();ia();Qe();Ai();iae=Object.freeze({image:({href:n,title:e,text:t})=>{let i=[],o=[];return n&&({href:n,dimensions:i}=E2e(n),o.push(`src="${fM(n)}"`)),t&&o.push(`alt="${fM(t)}"`),e&&o.push(`title="${fM(e)}"`),i.length&&(o=o.concat(i)),""},paragraph({tokens:n}){return`

    ${this.parser.parseInline(n)}

    `},link({href:n,title:e,tokens:t}){let i=this.parser.parseInline(t);return typeof n!="string"?"":(n===i&&(i=d7(i)),e=typeof e=="string"?fM(d7(e)):"",n=d7(n),n=n.replace(/&/g,"&").replace(//g,">").replace(/"/g,""").replace(/'/g,"'"),`
    ${i}`)}});jat=["area","base","br","col","command","embed","hr","img","input","keygen","link","meta","param","source","track","wbr"];qat=["align","autoplay","alt","checked","class","colspan","controls","data-code","data-href","disabled","draggable","height","href","loop","muted","playsinline","poster","rowspan","src","style","target","title","type","width","start"];Yat=new Map([[""",'"'],[" "," "],["&","&"],["'","'"],["<","<"],[">",">"]]);Zat=new or(n=>O2e()),Xat=new or(()=>{let n=O2e();return n.code=({text:e})=>` \`\`\` ${e} \`\`\` `,n});tlt=3});var B2e=k(()=>{});function W2e(n,e){let t=e.lineNumber;if(!n.tokenization.isCheapToTokenize(t))return;n.tokenization.forceTokenization(t);let i=n.tokenization.getLineTokens(t),o=i.findTokenIndexAtOffset(e.column-1);return i.getStandardTokenType(o)}var ao,rae,Dh=k(()=>{tC();ao=class n{static{this.defaultTokenMetadata=(32768|2<<24)>>>0}static createEmpty(e,t){let i=n.defaultTokenMetadata,o=new Uint32Array(2);return o[0]=e.length,o[1]=i,new n(o,e,t)}static createFromTextAndMetadata(e,t){let i=0,o="",r=new Array;for(let{text:s,metadata:a}of e)r.push(i+s.length,a),i+=s.length,o+=s;return new n(new Uint32Array(r),o,t)}constructor(e,t,i){this._lineTokensBrand=void 0,this._tokens=e,this._tokensCount=this._tokens.length>>>1,this._text=t,this.languageIdCodec=i}equals(e){return e instanceof n?this.slicedEquals(e,0,this._tokensCount):!1}slicedEquals(e,t,i){if(this._text!==e._text||this._tokensCount!==e._tokensCount)return!1;let o=t<<1,r=o+(i<<1);for(let s=o;s0?this._tokens[e-1<<1]:0}getMetadata(e){return this._tokens[(e<<1)+1]}getLanguageId(e){let t=this._tokens[(e<<1)+1],i=Go.getLanguageId(t);return this.languageIdCodec.decodeLanguageId(i)}getStandardTokenType(e){let t=this._tokens[(e<<1)+1];return Go.getTokenType(t)}getForeground(e){let t=this._tokens[(e<<1)+1];return Go.getForeground(t)}getClassName(e){let t=this._tokens[(e<<1)+1];return Go.getClassNameFromMetadata(t)}getInlineStyle(e,t){let i=this._tokens[(e<<1)+1];return Go.getInlineStyleFromMetadata(i,t)}getPresentation(e){let t=this._tokens[(e<<1)+1];return Go.getPresentationFromMetadata(t)}getEndOffset(e){return this._tokens[e<<1]}findTokenIndexAtOffset(e){return n.findIndexInTokensArray(this._tokens,e)}inflate(){return this}sliceAndInflate(e,t,i){return new rae(this,e,t,i)}static convertToEndOffset(e,t){let o=(e.length>>>1)-1;for(let r=0;r>>1)-1;for(;it&&(o=r)}return i}withInserted(e){if(e.length===0)return this;let t=0,i=0,o="",r=new Array,s=0;for(;;){let a=ts){o+=this._text.substring(s,l.offset);let c=this._tokens[(t<<1)+1];r.push(o.length,c),s=l.offset}o+=l.text,r.push(o.length,l.tokenMetadata),i++}else break}return new n(new Uint32Array(r),o,this.languageIdCodec)}getTokenText(e){let t=this.getStartOffset(e),i=this.getEndOffset(e);return this._text.substring(t,i)}forEach(e){let t=this.getCount();for(let i=0;i=i);r++)this._tokensCount++}getMetadata(e){return this._source.getMetadata(this._firstTokenIndex+e)}getLanguageId(e){return this._source.getLanguageId(this._firstTokenIndex+e)}getLineContent(){return this._source.getLineContent().substring(this._startOffset,this._endOffset)}equals(e){return e instanceof n?this._startOffset===e._startOffset&&this._endOffset===e._endOffset&&this._deltaOffset===e._deltaOffset&&this._source.slicedEquals(e._source,this._firstTokenIndex,this._tokensCount):!1}getCount(){return this._tokensCount}getStandardTokenType(e){return this._source.getStandardTokenType(this._firstTokenIndex+e)}getForeground(e){return this._source.getForeground(this._firstTokenIndex+e)}getEndOffset(e){let t=this._source.getEndOffset(this._firstTokenIndex+e);return Math.min(this._endOffset,t)-this._startOffset+this._deltaOffset}getClassName(e){return this._source.getClassName(this._firstTokenIndex+e)}getInlineStyle(e,t){return this._source.getInlineStyle(this._firstTokenIndex+e,t)}getPresentation(e){return this._source.getPresentation(this._firstTokenIndex+e)}findTokenIndexAtOffset(e){return this._source.findTokenIndexAtOffset(e+this._startOffset-this._deltaOffset)-this._firstTokenIndex}getTokenText(e){let t=this._firstTokenIndex+e,i=this._source.getStartOffset(t),o=this._source.getEndOffset(t),r=this._source.getTokenText(t);return ithis._endOffset&&(r=r.substring(0,r.length-(o-this._endOffset))),r}forEach(e){for(let t=0;t>>0,new B_(t,e===null?tg:e)}var tg,tI=k(()=>{Ji();tg=new class{clone(){return this}equals(n){return this===n}}});async function V2e(n,e,t){if(!t)return z2e(e,n.languageIdCodec,H2e);let i=await $i.getOrCreate(t);return z2e(e,n.languageIdCodec,i||H2e)}function U2e(n,e,t,i,o,r,s){let a="
    ",l=i,c=0,d=!0;for(let u=0,h=e.getCount();u0;)s&&d?(p+=" ",d=!1):(p+=" ",d=!0),_--;break}case 60:p+="<",d=!1;break;case 62:p+=">",d=!1;break;case 38:p+="&",d=!1;break;case 0:p+="�",d=!1;break;case 65279:case 8232:case 8233:case 133:p+="\uFFFD",d=!1;break;case 13:p+="​",d=!1;break;case 32:s&&d?(p+=" ",d=!1):(p+=" ",d=!0);break;default:p+=String.fromCharCode(g),d=!1}}if(a+=`${p}`,f>o||l>=o)break}return a+="
    ",a}function z2e(n,e,t){let i='
    ',o=Qa(n),r=t.getInitialState();for(let s=0,a=o.length;s0&&(i+="
    ");let c=t.tokenizeEncoded(l,!0,r);ao.convertToEndOffset(c.tokens,l.length);let u=new ao(c.tokens,l,e).inflate(),h=0;for(let f=0,p=u.getCount();f${gx(l.substring(h,_))}`,h=_}r=c.endState}return i+="
    ",i}var H2e,sae=k(()=>{Qe();Dh();Ji();tI();H2e={getInitialState:()=>tg,tokenizeEncoded:(n,e,t)=>sw(0,t)}});async function vM(n,e,t){try{return await n.open(e,{fromUserGesture:!0,allowContributedOpeners:!0,allowCommands:plt(t)})}catch(i){return Be(i),!1}}function plt(n){return n===!0?!0:n&&Array.isArray(n.enabledCommands)?n.enabledCommands:!1}var flt,$2e,aae,Gc,pb=k(()=>{bM();Rm();je();Ie();j();B2e();bu();fs();Nd();sae();Ml();flt=function(n,e,t,i){var o=arguments.length,r=o<3?e:i===null?i=Object.getOwnPropertyDescriptor(e,t):i,s;if(typeof Reflect=="object"&&typeof Reflect.decorate=="function")r=Reflect.decorate(n,e,t,i);else for(var a=n.length-1;a>=0;a--)(s=n[a])&&(r=(o<3?s(r):o>3?s(e,t,r):s(e,t))||r);return o>3&&r&&Object.defineProperty(e,t,r),r},$2e=function(n,e){return function(t,i){e(t,i,n)}},Gc=class{static{aae=this}static{this._ttpTokenizer=Tl("tokenizeToString",{createHTML(e){return e}})}constructor(e,t,i){this._options=e,this._languageService=t,this._openerService=i,this._onDidRenderAsync=new A,this.onDidRenderAsync=this._onDidRenderAsync.event}dispose(){this._onDidRenderAsync.dispose()}render(e,t,i){if(!e)return{element:document.createElement("span"),dispose:()=>{}};let o=new H,r=o.add(ow(e,{...this._getRenderOptions(e,o),...t},i));return r.element.classList.add("rendered-markdown"),{element:r.element,dispose:()=>o.dispose()}}_getRenderOptions(e,t){return{codeBlockRenderer:async(i,o)=>{let r;i?r=this._languageService.getLanguageIdByLanguageName(i):this._options.editor&&(r=this._options.editor.getModel()?.getLanguageId()),r||(r=Oo);let s=await V2e(this._languageService,o,r),a=document.createElement("span");if(a.innerHTML=aae._ttpTokenizer?.createHTML(s)??s,this._options.editor){let l=this._options.editor.getOption(50);Kn(a,l)}else this._options.codeBlockFontFamily&&(a.style.fontFamily=this._options.codeBlockFontFamily);return this._options.codeBlockFontSize!==void 0&&(a.style.fontSize=this._options.codeBlockFontSize),a},asyncRenderCallback:()=>this._onDidRenderAsync.fire(),actionHandler:{callback:i=>vM(this._openerService,i,e.isTrusted),disposables:t}}}};Gc=aae=flt([$2e(1,ai),$2e(2,xo)],Gc)});var $o,mC,uc=k(()=>{it();Fe();$o=We("accessibilityService"),mC=new me("accessibilityModeEnabled",!1)});var j2e=k(()=>{});function K2e(n){gC=document.createElement("div"),gC.className="monaco-aria-container";let e=()=>{let i=document.createElement("div");return i.className="monaco-alert",i.setAttribute("role","alert"),i.setAttribute("aria-atomic","true"),gC.appendChild(i),i};f7=e(),lae=e();let t=()=>{let i=document.createElement("div");return i.className="monaco-status",i.setAttribute("aria-live","polite"),i.setAttribute("aria-atomic","true"),gC.appendChild(i),i};p7=t(),cae=t(),n.appendChild(gC)}function Bo(n){gC&&(f7.textContent!==n?(no(lae),m7(f7,n)):(no(f7),m7(lae,n)))}function Ol(n){gC&&(p7.textContent!==n?(no(cae),m7(p7,n)):(no(p7),m7(cae,n)))}function m7(n,e){no(n),e.length>q2e&&(e=e.substr(0,q2e)),n.textContent=e,n.style.visibility="hidden",n.style.visibility="visible"}var q2e,gC,f7,lae,p7,cae,Ns=k(()=>{ke();j2e();q2e=2e4});var mlt,wM,ig,g7,_7,dae,G2e=k(()=>{HMe();j();Ie();ke();Pn();en();ir();XL();Lh();Ml();Fe();pb();Pl();pe();Bt();uc();Ns();mlt=function(n,e,t,i){var o=arguments.length,r=o<3?e:i===null?i=Object.getOwnPropertyDescriptor(e,t):i,s;if(typeof Reflect=="object"&&typeof Reflect.decorate=="function")r=Reflect.decorate(n,e,t,i);else for(var a=n.length-1;a>=0;a--)(s=n[a])&&(r=(o<3?s(r):o>3?s(e,t,r):s(e,t))||r);return o>3&&r&&Object.defineProperty(e,t,r),r},wM=function(n,e){return function(t,i){e(t,i,n)}},ig=J,g7=class extends Yo{get _targetWindow(){return Me(this._target.targetElements[0])}get _targetDocumentElement(){return Me(this._target.targetElements[0]).document.documentElement}get isDisposed(){return this._isDisposed}get isMouseIn(){return this._lockMouseTracker.isMouseIn}get domNode(){return this._hover.containerDomNode}get onDispose(){return this._onDispose.event}get onRequestLayout(){return this._onRequestLayout.event}get anchor(){return this._hoverPosition===2?0:1}get x(){return this._x}get y(){return this._y}get isLocked(){return this._isLocked}set isLocked(e){this._isLocked!==e&&(this._isLocked=e,this._hoverContainer.classList.toggle("locked",this._isLocked))}constructor(e,t,i,o,r,s){super(),this._keybindingService=t,this._configurationService=i,this._openerService=o,this._instantiationService=r,this._accessibilityService=s,this._messageListeners=new H,this._isDisposed=!1,this._forcePosition=!1,this._x=0,this._y=0,this._isLocked=!1,this._enableFocusTraps=!1,this._addedFocusTrap=!1,this._onDispose=this._register(new A),this._onRequestLayout=this._register(new A),this._linkHandler=e.linkHandler||(h=>vM(this._openerService,h,Kc(e.content)?e.content.isTrusted:void 0)),this._target="targetElements"in e.target?e.target:new dae(e.target),this._hoverPointer=e.appearance?.showPointer?ig("div.workbench-hover-pointer"):void 0,this._hover=this._register(new Qx),this._hover.containerDomNode.classList.add("workbench-hover","fadeIn"),e.appearance?.compact&&this._hover.containerDomNode.classList.add("workbench-hover","compact"),e.appearance?.skipFadeInAnimation&&this._hover.containerDomNode.classList.add("skip-fade-in"),e.additionalClasses&&this._hover.containerDomNode.classList.add(...e.additionalClasses),e.position?.forcePosition&&(this._forcePosition=!0),e.trapFocus&&(this._enableFocusTraps=!0),this._hoverPosition=e.position?.hoverPosition??3,this.onmousedown(this._hover.containerDomNode,h=>h.stopPropagation()),this.onkeydown(this._hover.containerDomNode,h=>{h.equals(9)&&this.dispose()}),this._register(U(this._targetWindow,"blur",()=>this.dispose()));let a=ig("div.hover-row.markdown-hover"),l=ig("div.hover-contents");if(typeof e.content=="string")l.textContent=e.content,l.style.whiteSpace="pre-wrap";else if(_n(e.content))l.appendChild(e.content),l.classList.add("html-hover-contents");else{let h=e.content,f=this._instantiationService.createInstance(Gc,{codeBlockFontFamily:this._configurationService.getValue("editor").fontFamily||as.fontFamily}),{element:p}=f.render(h,{actionHandler:{callback:g=>this._linkHandler(g),disposables:this._messageListeners},asyncRenderCallback:()=>{l.classList.add("code-hover-contents"),this.layout(),this._onRequestLayout.fire()}});l.appendChild(p)}if(a.appendChild(l),this._hover.contentsDomNode.appendChild(a),e.actions&&e.actions.length>0){let h=ig("div.hover-row.status-bar"),f=ig("div.actions");e.actions.forEach(p=>{let g=this._keybindingService.lookupKeybinding(p.commandId),_=g?g.getLabel():null;ZL.render(f,{label:p.label,commandId:p.commandId,run:b=>{p.run(b),this.dispose()},iconClass:p.iconClass},_)}),h.appendChild(f),this._hover.containerDomNode.appendChild(h)}this._hoverContainer=ig("div.workbench-hover-container"),this._hoverPointer&&this._hoverContainer.appendChild(this._hoverPointer),this._hoverContainer.appendChild(this._hover.containerDomNode);let c;if(e.actions&&e.actions.length>0?c=!1:e.persistence?.hideOnHover===void 0?c=typeof e.content=="string"||Kc(e.content)&&!e.content.value.includes("](")&&!e.content.value.includes(""):c=e.persistence.hideOnHover,e.appearance?.showHoverHint){let h=ig("div.hover-row.status-bar"),f=ig("div.info");f.textContent=m("hoverhint","Hold {0} key to mouse over",dt?"Option":"Alt"),h.appendChild(f),this._hover.containerDomNode.appendChild(h)}let d=[...this._target.targetElements];c||d.push(this._hoverContainer);let u=this._register(new _7(d));if(this._register(u.onMouseOut(()=>{this._isLocked||this.dispose()})),c){let h=[...this._target.targetElements,this._hoverContainer];this._lockMouseTracker=this._register(new _7(h)),this._register(this._lockMouseTracker.onMouseOut(()=>{this._isLocked||this.dispose()}))}else this._lockMouseTracker=u}addFocusTrap(){if(!this._enableFocusTraps||this._addedFocusTrap)return;this._addedFocusTrap=!0;let e=this._hover.containerDomNode,t=this.findLastFocusableChild(this._hover.containerDomNode);if(t){let i=pL(this._hoverContainer,ig("div")),o=Q(this._hoverContainer,ig("div"));i.tabIndex=0,o.tabIndex=0,this._register(U(o,"focus",r=>{e.focus(),r.preventDefault()})),this._register(U(i,"focus",r=>{t.focus(),r.preventDefault()}))}}findLastFocusableChild(e){if(e.hasChildNodes())for(let t=0;t=0)return r}let o=this.findLastFocusableChild(i);if(o)return o}}render(e){e.appendChild(this._hoverContainer);let i=this._hoverContainer.contains(this._hoverContainer.ownerDocument.activeElement)&&i7(this._configurationService.getValue("accessibility.verbosity.hover")===!0&&this._accessibilityService.isScreenReaderOptimized(),this._keybindingService.lookupKeybinding("editor.action.accessibleView")?.getAriaLabel());i&&Ol(i),this.layout(),this.addFocusTrap()}layout(){this._hover.containerDomNode.classList.remove("right-aligned"),this._hover.contentsDomNode.style.maxHeight="";let e=d=>{let u=MB(d),h=d.getBoundingClientRect();return{top:h.top*u,bottom:h.bottom*u,right:h.right*u,left:h.left*u}},t=this._target.targetElements.map(d=>e(d)),{top:i,right:o,bottom:r,left:s}=t[0],a=o-s,l=r-i,c={top:i,right:o,bottom:r,left:s,width:a,height:l,center:{x:s+a/2,y:i+l/2}};if(this.adjustHorizontalHoverPosition(c),this.adjustVerticalHoverPosition(c),this.adjustHoverMaxHeight(c),this._hoverContainer.style.padding="",this._hoverContainer.style.margin="",this._hoverPointer){switch(this._hoverPosition){case 1:c.left+=3,c.right+=3,this._hoverContainer.style.paddingLeft="3px",this._hoverContainer.style.marginLeft="-3px";break;case 0:c.left-=3,c.right-=3,this._hoverContainer.style.paddingRight="3px",this._hoverContainer.style.marginRight="-3px";break;case 2:c.top+=3,c.bottom+=3,this._hoverContainer.style.paddingTop="3px",this._hoverContainer.style.marginTop="-3px";break;case 3:c.top-=3,c.bottom-=3,this._hoverContainer.style.paddingBottom="3px",this._hoverContainer.style.marginBottom="-3px";break}c.center.x=c.left+a/2,c.center.y=c.top+l/2}this.computeXCordinate(c),this.computeYCordinate(c),this._hoverPointer&&(this._hoverPointer.classList.remove("top"),this._hoverPointer.classList.remove("left"),this._hoverPointer.classList.remove("right"),this._hoverPointer.classList.remove("bottom"),this.setHoverPointerPosition(c)),this._hover.onContentsChanged()}computeXCordinate(e){let t=this._hover.containerDomNode.clientWidth+2;this._target.x!==void 0?this._x=this._target.x:this._hoverPosition===1?this._x=e.right:this._hoverPosition===0?this._x=e.left-t:(this._hoverPointer?this._x=e.center.x-this._hover.containerDomNode.clientWidth/2:this._x=e.left,this._x+t>=this._targetDocumentElement.clientWidth&&(this._hover.containerDomNode.classList.add("right-aligned"),this._x=Math.max(this._targetDocumentElement.clientWidth-t-2,this._targetDocumentElement.clientLeft))),this._xthis._targetWindow.innerHeight&&(this._y=e.bottom)}adjustHorizontalHoverPosition(e){if(this._target.x!==void 0)return;let t=this._hoverPointer?3:0;if(this._forcePosition){let i=t+2;this._hoverPosition===1?this._hover.containerDomNode.style.maxWidth=`${this._targetDocumentElement.clientWidth-e.right-i}px`:this._hoverPosition===0&&(this._hover.containerDomNode.style.maxWidth=`${e.left-i}px`);return}this._hoverPosition===1?this._targetDocumentElement.clientWidth-e.right=this._hover.containerDomNode.clientWidth+t?this._hoverPosition=0:this._hoverPosition=2):this._hoverPosition===0&&(e.left=this._hover.containerDomNode.clientWidth+t?this._hoverPosition=1:this._hoverPosition=2),e.left-this._hover.containerDomNode.clientWidth-t<=this._targetDocumentElement.clientLeft&&(this._hoverPosition=1))}adjustVerticalHoverPosition(e){if(this._target.y!==void 0||this._forcePosition)return;let t=this._hoverPointer?3:0;this._hoverPosition===3?e.top-this._hover.containerDomNode.clientHeight-t<0&&(this._hoverPosition=2):this._hoverPosition===2&&e.bottom+this._hover.containerDomNode.clientHeight+t>this._targetWindow.innerHeight&&(this._hoverPosition=3)}adjustHoverMaxHeight(e){let t=this._targetWindow.innerHeight/2;if(this._forcePosition){let i=(this._hoverPointer?3:0)+2;this._hoverPosition===3?t=Math.min(t,e.top-i):this._hoverPosition===2&&(t=Math.min(t,this._targetWindow.innerHeight-e.bottom-i))}if(this._hover.containerDomNode.style.maxHeight=`${t}px`,this._hover.contentsDomNode.clientHeighte.height?this._hoverPointer.style.top=`${e.center.y-(this._y-t)-3}px`:this._hoverPointer.style.top=`${Math.round(t/2)-3}px`;break}case 3:case 2:{this._hoverPointer.classList.add(this._hoverPosition===3?"bottom":"top");let t=this._hover.containerDomNode.clientWidth,i=Math.round(t/2)-3,o=this._x+i;(oe.right)&&(i=e.center.x-this._x-3),this._hoverPointer.style.left=`${i}px`;break}}}focus(){this._hover.containerDomNode.focus()}dispose(){this._isDisposed||(this._onDispose.fire(),this._hoverContainer.remove(),this._messageListeners.dispose(),this._target.dispose(),super.dispose()),this._isDisposed=!0}};g7=mlt([wM(1,_t),wM(2,Ve),wM(3,xo),wM(4,he),wM(5,$o)],g7);_7=class extends Yo{get onMouseOut(){return this._onMouseOut.event}get isMouseIn(){return this._isMouseIn}constructor(e){super(),this._elements=e,this._isMouseIn=!0,this._onMouseOut=this._register(new A),this._elements.forEach(t=>this.onmouseover(t,()=>this._onTargetMouseOver(t))),this._elements.forEach(t=>this.onmouseleave(t,()=>this._onTargetMouseLeave(t)))}_onTargetMouseOver(e){this._isMouseIn=!0,this._clearEvaluateMouseStateTimeout(e)}_onTargetMouseLeave(e){this._isMouseIn=!1,this._evaluateMouseState(e)}_evaluateMouseState(e){this._clearEvaluateMouseStateTimeout(e),this._mouseTimeout=Me(e).setTimeout(()=>this._fireIfMouseOutside(),0)}_clearEvaluateMouseStateTimeout(e){this._mouseTimeout&&(Me(e).clearTimeout(this._mouseTimeout),this._mouseTimeout=void 0)}_fireIfMouseOutside(){this._isMouseIn||this._onMouseOut.fire()}},dae=class{constructor(e){this._element=e,this.targetElements=[this._element]}dispose(){}}});var ms,yM=k(()=>{(function(n){function e(r,s){if(r.start>=s.end||s.start>=r.end)return{start:0,end:0};let a=Math.max(r.start,s.start),l=Math.min(r.end,s.end);return l-a<=0?{start:0,end:0}:{start:a,end:l}}n.intersect=e;function t(r){return r.end-r.start<=0}n.isEmpty=t;function i(r,s){return!t(e(r,s))}n.intersects=i;function o(r,s){let a=[],l={start:r.start,end:Math.min(s.start,r.end)},c={start:Math.max(s.end,r.start),end:r.end};return t(l)||a.push(l),t(c)||a.push(c),a}n.relativeComplement=o})(ms||(ms={}))});var Y2e=k(()=>{});function glt(n){let e=n;return!!e&&typeof e.x=="number"&&typeof e.y=="number"}function _C(n,e,t){let i=t.mode===aw.ALIGN?t.offset:t.offset+t.size,o=t.mode===aw.ALIGN?t.offset+t.size:t.offset;return t.position===0?e<=n-i?i:e<=o?o-e:Math.max(n-e,0):e<=o?o-e:e<=n-i?i:0}var aw,b7,_lt,uae=k(()=>{hB();ke();j();Bt();yM();Y2e();(function(n){n[n.AVOID=0]="AVOID",n[n.ALIGN=1]="ALIGN"})(aw||(aw={}));b7=class n extends D{static{this.BUBBLE_UP_EVENTS=["click","keydown","focus","blur"]}static{this.BUBBLE_DOWN_EVENTS=["click"]}constructor(e,t){super(),this.container=null,this.useFixedPosition=!1,this.useShadowDOM=!1,this.delegate=null,this.toDisposeOnClean=D.None,this.toDisposeOnSetContainer=D.None,this.shadowRoot=null,this.shadowRootHostElement=null,this.view=J(".context-view"),hs(this.view),this.setContainer(e,t),this._register(ge(()=>this.setContainer(null,1)))}setContainer(e,t){this.useFixedPosition=t!==1;let i=this.useShadowDOM;if(this.useShadowDOM=t===3,!(e===this.container&&i===this.useShadowDOM)&&(this.container&&(this.toDisposeOnSetContainer.dispose(),this.view.remove(),this.shadowRoot&&(this.shadowRoot=null,this.shadowRootHostElement?.remove(),this.shadowRootHostElement=null),this.container=null),e)){if(this.container=e,this.useShadowDOM){this.shadowRootHostElement=J(".shadow-root-host"),this.container.appendChild(this.shadowRootHostElement),this.shadowRoot=this.shadowRootHostElement.attachShadow({mode:"open"});let r=document.createElement("style");r.textContent=_lt,this.shadowRoot.appendChild(r),this.shadowRoot.appendChild(this.view),this.shadowRoot.appendChild(J("slot"))}else this.container.appendChild(this.view);let o=new H;n.BUBBLE_UP_EVENTS.forEach(r=>{o.add(gi(this.container,r,s=>{this.onDOMEvent(s,!1)}))}),n.BUBBLE_DOWN_EVENTS.forEach(r=>{o.add(gi(this.container,r,s=>{this.onDOMEvent(s,!0)},!0))}),this.toDisposeOnSetContainer=o}}show(e){this.isVisible()&&this.hide(),no(this.view),this.view.className="context-view monaco-component",this.view.style.top="0px",this.view.style.left="0px",this.view.style.zIndex=`${2575+(e.layer??0)}`,this.view.style.position=this.useFixedPosition?"fixed":"absolute",Is(this.view),this.toDisposeOnClean=e.render(this.view)||D.None,this.delegate=e,this.doLayout(),this.delegate.focus?.()}getViewElement(){return this.view}layout(){if(this.isVisible()){if(this.delegate.canRelayout===!1&&!(Xa&&sL.pointerEvents)){this.hide();return}this.delegate?.layout?.(),this.doLayout()}}doLayout(){if(!this.isVisible())return;let e=this.delegate.getAnchor(),t;if(_n(e)){let h=Ci(e),f=MB(e);t={top:h.top*f,left:h.left*f,width:h.width*f,height:h.height*f}}else glt(e)?t={top:e.y,left:e.x,width:e.width||1,height:e.height||2}:t={top:e.posy,left:e.posx,width:2,height:2};let i=Gs(this.view),o=gh(this.view),r=this.delegate.anchorPosition||0,s=this.delegate.anchorAlignment||0,a=this.delegate.anchorAxisAlignment||0,l,c,d=N1();if(a===0){let h={offset:t.top-d.pageYOffset,size:t.height,position:r===0?0:1},f={offset:t.left,size:t.width,position:s===0?0:1,mode:aw.ALIGN};l=_C(d.innerHeight,o,h)+d.pageYOffset,ms.intersects({start:l,end:l+o},{start:h.offset,end:h.offset+h.size})&&(f.mode=aw.AVOID),c=_C(d.innerWidth,i,f)}else{let h={offset:t.left,size:t.width,position:s===0?0:1},f={offset:t.top,size:t.height,position:r===0?0:1,mode:aw.ALIGN};c=_C(d.innerWidth,i,h),ms.intersects({start:c,end:c+i},{start:h.offset,end:h.offset+h.size})&&(f.mode=aw.AVOID),l=_C(d.innerHeight,o,f)+d.pageYOffset}this.view.classList.remove("top","bottom","left","right"),this.view.classList.add(r===0?"bottom":"top"),this.view.classList.add(s===0?"left":"right"),this.view.classList.toggle("fixed",this.useFixedPosition);let u=Ci(this.container);this.view.style.top=`${l-(this.useFixedPosition?Ci(this.view).top:u.top)}px`,this.view.style.left=`${c-(this.useFixedPosition?Ci(this.view).left:u.left)}px`,this.view.style.width="initial"}hide(e){let t=this.delegate;this.delegate=null,t?.onHide&&t.onHide(e),this.toDisposeOnClean.dispose(),hs(this.view)}isVisible(){return!!this.delegate}onDOMEvent(e,t){this.delegate&&(this.delegate.onDOMEvent?this.delegate.onDOMEvent(e,Me(e).document.activeElement):t&&!io(e.target,this.container)&&this.hide())}dispose(){this.hide(),super.dispose()}},_lt=` :host { all: initial; /* 1st rule so subsequent properties are reset. */ } .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 blt,vlt,CM,v7,hae=k(()=>{uae();j();nb();ke();blt=function(n,e,t,i){var o=arguments.length,r=o<3?e:i===null?i=Object.getOwnPropertyDescriptor(e,t):i,s;if(typeof Reflect=="object"&&typeof Reflect.decorate=="function")r=Reflect.decorate(n,e,t,i);else for(var a=n.length-1;a>=0;a--)(s=n[a])&&(r=(o<3?s(r):o>3?s(e,t,r):s(e,t))||r);return o>3&&r&&Object.defineProperty(e,t,r),r},vlt=function(n,e){return function(t,i){e(t,i,n)}},CM=class extends D{constructor(e){super(),this.layoutService=e,this.contextView=this._register(new b7(this.layoutService.mainContainer,1)),this.layout(),this._register(e.onDidLayoutContainer(()=>this.layout()))}showContextView(e,t,i){let o;t?t===this.layoutService.getContainer(Me(t))?o=1:i?o=3:o=2:o=1,this.contextView.setContainer(t??this.layoutService.activeContainer,o),this.contextView.show(e);let r={close:()=>{this.openContextView===r&&this.hideContextView()}};return this.openContextView=r,r}layout(){this.contextView.layout()}hideContextView(e){this.contextView.hide(e),this.openContextView=void 0}};CM=blt([vlt(0,Uc)],CM);v7=class extends CM{getContextViewElement(){return this.contextView.getViewElement()}}});var x7,Z2e=k(()=>{ke();ci();Pl();yi();pe();x7=class{constructor(e,t,i){this.hoverDelegate=e,this.target=t,this.fadeInAnimation=i}async update(e,t,i){if(this._cancellationTokenSource&&(this._cancellationTokenSource.dispose(!0),this._cancellationTokenSource=void 0),this.isDisposed)return;let o;if(e===void 0||Rr(e)||_n(e))o=e;else if(!ex(e.markdown))o=e.markdown??e.markdownNotSupportedFallback;else{this._hoverWidget||this.show(m("iconLabel.loading","Loading..."),t,i),this._cancellationTokenSource=new qt;let r=this._cancellationTokenSource.token;if(o=await e.markdown(r),o===void 0&&(o=e.markdownNotSupportedFallback),this.isDisposed||r.isCancellationRequested)return}this.show(o,t,i)}show(e,t,i){let o=this._hoverWidget;if(this.hasContent(e)){let r={content:e,target:this.target,actions:i?.actions,linkHandler:i?.linkHandler,trapFocus:i?.trapFocus,appearance:{showPointer:this.hoverDelegate.placement==="element",skipFadeInAnimation:!this.fadeInAnimation||!!o,showHoverHint:i?.appearance?.showHoverHint},position:{hoverPosition:2}};this._hoverWidget=this.hoverDelegate.showHover(r,t)}o?.dispose()}hasContent(e){return e?Kc(e)?!!e.value:!0:!1}get isDisposed(){return this._hoverWidget?.isDisposed}dispose(){this._hoverWidget?.dispose(),this._cancellationTokenSource?.dispose(!0),this._cancellationTokenSource=void 0}}});function X2e(n){if(n!==void 0)return n?.id??n}function Q2e(n,e){for(e=e??Me(n).document.body;!n.hasAttribute("custom-hover")&&n!==e;)n=n.parentElement;return n}var xlt,SM,fae,pae,J2e=k(()=>{Xs();Yi();Wn();db();Al();Fe();G2e();j();ke();Pn();Ks();uc();nb();Il();hae();Z2e();ft();xlt=function(n,e,t,i){var o=arguments.length,r=o<3?e:i===null?i=Object.getOwnPropertyDescriptor(e,t):i,s;if(typeof Reflect=="object"&&typeof Reflect.decorate=="function")r=Reflect.decorate(n,e,t,i);else for(var a=n.length-1;a>=0;a--)(s=n[a])&&(r=(o<3?s(r):o>3?s(e,t,r):s(e,t))||r);return o>3&&r&&Object.defineProperty(e,t,r),r},SM=function(n,e){return function(t,i){e(t,i,n)}},fae=class extends D{constructor(e,t,i,o,r){super(),this._instantiationService=e,this._keybindingService=i,this._layoutService=o,this._accessibilityService=r,this._managedHovers=new Map,t.onDidShowContextMenu(()=>this.hideHover()),this._contextViewHandler=this._register(new CM(this._layoutService))}showHover(e,t,i){if(X2e(this._currentHoverOptions)===X2e(e)||this._currentHover&&this._currentHoverOptions?.persistence?.sticky)return;this._currentHoverOptions=e,this._lastHoverOptions=e;let o=e.trapFocus||this._accessibilityService.isScreenReaderOptimized(),r=Mo();i||(o&&r?r.classList.contains("monaco-hover")||(this._lastFocusedElementBeforeOpen=r):this._lastFocusedElementBeforeOpen=void 0);let s=new H,a=this._instantiationService.createInstance(g7,e);if(e.persistence?.sticky&&(a.isLocked=!0),a.onDispose(()=>{this._currentHover?.domNode&&FB(this._currentHover.domNode)&&this._lastFocusedElementBeforeOpen?.focus(),this._currentHoverOptions===e&&(this._currentHoverOptions=void 0),s.dispose()},void 0,s),!e.container){let l=_n(e.target)?e.target:e.target.targetElements[0];e.container=this._layoutService.getContainer(Me(l))}if(this._contextViewHandler.showContextView(new pae(a,t),e.container),a.onRequestLayout(()=>this._contextViewHandler.layout(),void 0,s),e.persistence?.sticky)s.add(U(Me(e.container).document,re.MOUSE_DOWN,l=>{io(l.target,a.domNode)||this.doHideHover()}));else{if("targetElements"in e.target)for(let c of e.target.targetElements)s.add(U(c,re.CLICK,()=>this.hideHover()));else s.add(U(e.target,re.CLICK,()=>this.hideHover()));let l=Mo();if(l){let c=Me(l).document;s.add(U(l,re.KEY_DOWN,d=>this._keyDown(d,a,!!e.persistence?.hideOnKeyDown))),s.add(U(c,re.KEY_DOWN,d=>this._keyDown(d,a,!!e.persistence?.hideOnKeyDown))),s.add(U(l,re.KEY_UP,d=>this._keyUp(d,a))),s.add(U(c,re.KEY_UP,d=>this._keyUp(d,a)))}}if("IntersectionObserver"in ri){let l=new IntersectionObserver(d=>this._intersectionChange(d,a),{threshold:0}),c="targetElements"in e.target?e.target.targetElements[0]:e.target;l.observe(c),s.add(ge(()=>l.disconnect()))}return this._currentHover=a,a}hideHover(){this._currentHover?.isLocked||!this._currentHoverOptions||this.doHideHover()}doHideHover(){this._currentHover=void 0,this._currentHoverOptions=void 0,this._contextViewHandler.hideContextView()}_intersectionChange(e,t){e[e.length-1].isIntersecting||t.dispose()}showAndFocusLastHover(){this._lastHoverOptions&&this.showHover(this._lastHoverOptions,!0,!0)}_keyDown(e,t,i){if(e.key==="Alt"){t.isLocked=!0;return}let o=new Xt(e);this._keybindingService.resolveKeyboardEvent(o).getSingleModifierDispatchChords().some(s=>!!s)||this._keybindingService.softDispatch(o,o.target).kind!==0||i&&(!this._currentHoverOptions?.trapFocus||e.key!=="Tab")&&(this.hideHover(),this._lastFocusedElementBeforeOpen?.focus())}_keyUp(e,t){e.key==="Alt"&&(t.isLocked=!1,t.isMouseIn||(this.hideHover(),this._lastFocusedElementBeforeOpen?.focus()))}setupManagedHover(e,t,i,o){t.setAttribute("custom-hover","true"),t.title!==""&&(console.warn("HTML element already has a title attribute, which will conflict with the custom hover. Please remove the title attribute."),console.trace("Stack trace:",t.title),t.title="");let r,s,a=(x,w)=>{let y=s!==void 0;x&&(s?.dispose(),s=void 0),w&&(r?.dispose(),r=void 0),y&&(e.onDidHideHover?.(),s=void 0)},l=(x,w,y,C)=>new _r(async()=>{(!s||s.isDisposed)&&(s=new x7(e,y||t,x>0),await s.update(typeof i=="function"?i():i,w,{...o,trapFocus:C}))},x),c=!1,d=U(t,re.MOUSE_DOWN,()=>{c=!0,a(!0,!0)},!0),u=U(t,re.MOUSE_UP,()=>{c=!1},!0),h=U(t,re.MOUSE_LEAVE,x=>{c=!1,a(!1,x.fromElement===t)},!0),f=x=>{if(r)return;let w=new H,y={targetElements:[t],dispose:()=>{}};if(e.placement===void 0||e.placement==="mouse"){let C=L=>{y.x=L.x+10,_n(L.target)&&Q2e(L.target,t)!==t&&a(!0,!0)};w.add(U(t,re.MOUSE_MOVE,C,!0))}r=w,!(_n(x.target)&&Q2e(x.target,t)!==t)&&w.add(l(e.delay,!1,y))},p=U(t,re.MOUSE_OVER,f,!0),g=()=>{if(c||r)return;let x={targetElements:[t],dispose:()=>{}},w=new H,y=()=>a(!0,!0);w.add(U(t,re.BLUR,y,!0)),w.add(l(e.delay,!1,x)),r=w},_,b=t.tagName.toLowerCase();b!=="input"&&b!=="textarea"&&(_=U(t,re.FOCUS,g,!0));let v={show:x=>{a(!1,!0),l(0,x,void 0,x)},hide:()=>{a(!0,!0)},update:async(x,w)=>{i=x,await s?.update(i,void 0,w)},dispose:()=>{this._managedHovers.delete(t),p.dispose(),h.dispose(),d.dispose(),u.dispose(),_?.dispose(),a(!0,!0)}};return this._managedHovers.set(t,v),v}showManagedHover(e){let t=this._managedHovers.get(e);t&&t.show(!0)}dispose(){this._managedHovers.forEach(e=>e.dispose()),super.dispose()}};fae=xlt([SM(0,he),SM(1,sr),SM(2,_t),SM(3,Uc),SM(4,$o)],fae);pae=class{get anchorPosition(){return this._hover.anchor}constructor(e,t=!1){this._hover=e,this._focus=t,this.layer=1}render(e){return this._hover.render(e),this._focus&&this._hover.focus(),this._hover}getAnchor(){return{x:this._hover.x,y:this._hover.y}}layout(){this._hover.layout()}};Ct(cc,fae,1);wr((n,e)=>{let t=n.getColor(O9);t&&(e.addRule(`.monaco-workbench .workbench-hover .hover-row:not(:first-child):not(:empty) { border-top: 1px solid ${t.transparent(.5)}; }`),e.addRule(`.monaco-workbench .workbench-hover hr { border-top: 1px solid ${t.transparent(.5)}; }`))})});var ng,iI,lw,w7,bC=k(()=>{Fe();Ai();yi();ng=We("IWorkspaceEditService"),iI=class{constructor(e){this.metadata=e}static convert(e){return e.edits.map(t=>{if(lw.is(t))return lw.lift(t);if(w7.is(t))return w7.lift(t);throw new Error("Unsupported edit")})}},lw=class n extends iI{static is(e){return e instanceof n?!0:mo(e)&&Ee.isUri(e.resource)&&mo(e.textEdit)}static lift(e){return e instanceof n?e:new n(e.resource,e.textEdit,e.versionId,e.metadata)}constructor(e,t,i=void 0,o){super(o),this.resource=e,this.textEdit=t,this.versionId=i}},w7=class n extends iI{static is(e){return e instanceof n?!0:mo(e)&&(!!e.newResource||!!e.oldResource)}static lift(e){return e instanceof n?e:new n(e.oldResource,e.newResource,e.options,e.metadata)}constructor(e,t,i={},o){super(o),this.oldResource=e,this.newResource=t,this.options=i}}});var Rs,mae=k(()=>{Rs={enableSplitViewResizing:!0,splitViewDefaultRatio:.5,renderSideBySide:!0,renderMarginRevertIcon:!0,renderGutterMenu:!0,maxComputationTime:5e3,maxFileSize:50,ignoreTrimWhitespace:!0,renderIndicators:!0,originalEditable:!1,diffCodeLens:!1,renderOverviewRuler:!0,diffWordWrap:"inherit",diffAlgorithm:"advanced",accessibilityVerbose:!1,experimental:{showMoves:!1,showEmptyDecorations:!0,useTrueInlineView:!1},hideUnchangedRegions:{enabled:!1,contextLineCount:3,minimumLineCount:3,revealLineCount:20},isInEmbeddedEditor:!1,onlyShowAccessibleDiffViewer:!1,renderSideBySideInlineBreakpoint:900,useInlineViewWhenSpaceIsLimited:!0,compactMode:!1}});function wlt(n){return typeof n.type<"u"||typeof n.anyOf<"u"}function ePe(){return y7===null&&(y7=Object.create(null),Object.keys(C7.properties).forEach(n=>{y7[n]=!0})),y7}function tPe(n){return ePe()[`editor.${n}`]||!1}function iPe(n){return ePe()[`diffEditor.${n}`]||!1}var vC,C7,y7,ylt,S7=k(()=>{mae();ir();ER();pe();Mm();br();vC=Object.freeze({id:"editor",order:5,type:"object",title:m("editorConfigurationTitle","Editor"),scope:5}),C7={...vC,properties:{"editor.tabSize":{type:"number",default:rs.tabSize,minimum:1,markdownDescription:m("tabSize","The number of spaces a tab is equal to. This setting is overridden based on the file contents when {0} is on.","`#editor.detectIndentation#`")},"editor.indentSize":{anyOf:[{type:"string",enum:["tabSize"]},{type:"number",minimum:1}],default:"tabSize",markdownDescription:m("indentSize",'The number of spaces used for indentation or `"tabSize"` to use the value from `#editor.tabSize#`. This setting is overridden based on the file contents when `#editor.detectIndentation#` is on.')},"editor.insertSpaces":{type:"boolean",default:rs.insertSpaces,markdownDescription:m("insertSpaces","Insert spaces when pressing `Tab`. This setting is overridden based on the file contents when {0} is on.","`#editor.detectIndentation#`")},"editor.detectIndentation":{type:"boolean",default:rs.detectIndentation,markdownDescription:m("detectIndentation","Controls whether {0} and {1} will be automatically detected when a file is opened based on the file contents.","`#editor.tabSize#`","`#editor.insertSpaces#`")},"editor.trimAutoWhitespace":{type:"boolean",default:rs.trimAutoWhitespace,description:m("trimAutoWhitespace","Remove trailing auto inserted whitespace.")},"editor.largeFileOptimizations":{type:"boolean",default:rs.largeFileOptimizations,description:m("largeFileOptimizations","Special handling for large files to disable certain memory intensive features.")},"editor.wordBasedSuggestions":{enum:["off","currentDocument","matchingDocuments","allDocuments"],default:"matchingDocuments",enumDescriptions:[m("wordBasedSuggestions.off","Turn off Word Based Suggestions."),m("wordBasedSuggestions.currentDocument","Only suggest words from the active document."),m("wordBasedSuggestions.matchingDocuments","Suggest words from all open documents of the same language."),m("wordBasedSuggestions.allDocuments","Suggest words from all open documents.")],description:m("wordBasedSuggestions","Controls whether completions should be computed based on words in the document and from which documents they are computed.")},"editor.semanticHighlighting.enabled":{enum:[!0,!1,"configuredByTheme"],enumDescriptions:[m("semanticHighlighting.true","Semantic highlighting enabled for all color themes."),m("semanticHighlighting.false","Semantic highlighting disabled for all color themes."),m("semanticHighlighting.configuredByTheme","Semantic highlighting is configured by the current color theme's `semanticHighlighting` setting.")],default:"configuredByTheme",description:m("semanticHighlighting.enabled","Controls whether the semanticHighlighting is shown for the languages that support it.")},"editor.stablePeek":{type:"boolean",default:!1,markdownDescription:m("stablePeek","Keep peek editors open even when double-clicking their content or when hitting `Escape`.")},"editor.maxTokenizationLineLength":{type:"integer",default:2e4,description:m("maxTokenizationLineLength","Lines above this length will not be tokenized for performance reasons")},"editor.experimental.asyncTokenization":{type:"boolean",default:!0,description:m("editor.experimental.asyncTokenization","Controls whether the tokenization should happen asynchronously on a web worker."),tags:["experimental"]},"editor.experimental.asyncTokenizationLogging":{type:"boolean",default:!1,description:m("editor.experimental.asyncTokenizationLogging","Controls whether async tokenization should be logged. For debugging only.")},"editor.experimental.asyncTokenizationVerification":{type:"boolean",default:!1,description:m("editor.experimental.asyncTokenizationVerification","Controls whether async tokenization should be verified against legacy background tokenization. Might slow down tokenization. For debugging only."),tags:["experimental"]},"editor.experimental.treeSitterTelemetry":{type:"boolean",default:!1,markdownDescription:m("editor.experimental.treeSitterTelemetry","Controls whether tree sitter parsing should be turned on and telemetry collected. Setting `editor.experimental.preferTreeSitter` for specific languages will take precedence."),tags:["experimental"]},"editor.language.brackets":{type:["array","null"],default:null,description:m("schema.brackets","Defines the bracket symbols that increase or decrease the indentation."),items:{type:"array",items:[{type:"string",description:m("schema.openBracket","The opening bracket character or string sequence.")},{type:"string",description:m("schema.closeBracket","The closing bracket character or string sequence.")}]}},"editor.language.colorizedBracketPairs":{type:["array","null"],default:null,description:m("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:m("schema.openBracket","The opening bracket character or string sequence.")},{type:"string",description:m("schema.closeBracket","The closing bracket character or string sequence.")}]}},"diffEditor.maxComputationTime":{type:"number",default:Rs.maxComputationTime,description:m("maxComputationTime","Timeout in milliseconds after which diff computation is cancelled. Use 0 for no timeout.")},"diffEditor.maxFileSize":{type:"number",default:Rs.maxFileSize,description:m("maxFileSize","Maximum file size in MB for which to compute diffs. Use 0 for no limit.")},"diffEditor.renderSideBySide":{type:"boolean",default:Rs.renderSideBySide,description:m("sideBySide","Controls whether the diff editor shows the diff side by side or inline.")},"diffEditor.renderSideBySideInlineBreakpoint":{type:"number",default:Rs.renderSideBySideInlineBreakpoint,description:m("renderSideBySideInlineBreakpoint","If the diff editor width is smaller than this value, the inline view is used.")},"diffEditor.useInlineViewWhenSpaceIsLimited":{type:"boolean",default:Rs.useInlineViewWhenSpaceIsLimited,description:m("useInlineViewWhenSpaceIsLimited","If enabled and the editor width is too small, the inline view is used.")},"diffEditor.renderMarginRevertIcon":{type:"boolean",default:Rs.renderMarginRevertIcon,description:m("renderMarginRevertIcon","When enabled, the diff editor shows arrows in its glyph margin to revert changes.")},"diffEditor.renderGutterMenu":{type:"boolean",default:Rs.renderGutterMenu,description:m("renderGutterMenu","When enabled, the diff editor shows a special gutter for revert and stage actions.")},"diffEditor.ignoreTrimWhitespace":{type:"boolean",default:Rs.ignoreTrimWhitespace,description:m("ignoreTrimWhitespace","When enabled, the diff editor ignores changes in leading or trailing whitespace.")},"diffEditor.renderIndicators":{type:"boolean",default:Rs.renderIndicators,description:m("renderIndicators","Controls whether the diff editor shows +/- indicators for added/removed changes.")},"diffEditor.codeLens":{type:"boolean",default:Rs.diffCodeLens,description:m("codeLens","Controls whether the editor shows CodeLens.")},"diffEditor.wordWrap":{type:"string",enum:["off","on","inherit"],default:Rs.diffWordWrap,markdownEnumDescriptions:[m("wordWrap.off","Lines will never wrap."),m("wordWrap.on","Lines will wrap at the viewport width."),m("wordWrap.inherit","Lines will wrap according to the {0} setting.","`#editor.wordWrap#`")]},"diffEditor.diffAlgorithm":{type:"string",enum:["legacy","advanced"],default:Rs.diffAlgorithm,markdownEnumDescriptions:[m("diffAlgorithm.legacy","Uses the legacy diffing algorithm."),m("diffAlgorithm.advanced","Uses the advanced diffing algorithm.")],tags:["experimental"]},"diffEditor.hideUnchangedRegions.enabled":{type:"boolean",default:Rs.hideUnchangedRegions.enabled,markdownDescription:m("hideUnchangedRegions.enabled","Controls whether the diff editor shows unchanged regions.")},"diffEditor.hideUnchangedRegions.revealLineCount":{type:"integer",default:Rs.hideUnchangedRegions.revealLineCount,markdownDescription:m("hideUnchangedRegions.revealLineCount","Controls how many lines are used for unchanged regions."),minimum:1},"diffEditor.hideUnchangedRegions.minimumLineCount":{type:"integer",default:Rs.hideUnchangedRegions.minimumLineCount,markdownDescription:m("hideUnchangedRegions.minimumLineCount","Controls how many lines are used as a minimum for unchanged regions."),minimum:1},"diffEditor.hideUnchangedRegions.contextLineCount":{type:"integer",default:Rs.hideUnchangedRegions.contextLineCount,markdownDescription:m("hideUnchangedRegions.contextLineCount","Controls how many lines are used as context when comparing unchanged regions."),minimum:1},"diffEditor.experimental.showMoves":{type:"boolean",default:Rs.experimental.showMoves,markdownDescription:m("showMoves","Controls whether the diff editor should show detected code moves.")},"diffEditor.experimental.showEmptyDecorations":{type:"boolean",default:Rs.experimental.showEmptyDecorations,description:m("showEmptyDecorations","Controls whether the diff editor shows empty decorations to see where characters got inserted or deleted.")},"diffEditor.experimental.useTrueInlineView":{type:"boolean",default:Rs.experimental.useTrueInlineView,description:m("useTrueInlineView","If enabled and the editor uses the inline view, word changes are rendered inline.")}}};for(let n of rx){let e=n.schema;if(typeof e<"u")if(wlt(e))C7.properties[`editor.${n.name}`]=e;else for(let t in e)Object.hasOwnProperty.call(e,t)&&(C7.properties[t]=e[t])}y7=null;ylt=ei.as(Qs.Configuration);ylt.registerConfiguration(C7)});var Pi,Tu=k(()=>{we();Pi=class{static insert(e,t){return{range:new S(e.lineNumber,e.column,e.lineNumber,e.column),text:t,forceMoveMarkers:!0}}static delete(e){return{range:e,text:null}}static replace(e,t){return{range:e,text:t}}static replaceMove(e,t){return{range:e,text:t,forceMoveMarkers:!0}}}});function k7(n){return Object.isFrozen(n)?n:UEe(n)}var Fl,gae,_ae,kM,L7,bae=k(()=>{at();Ds();ec();yi();Ai();en();Mm();br();Fl=class n{static createEmptyModel(e){return new n({},[],[],void 0,e)}constructor(e,t,i,o,r){this._contents=e,this._keys=t,this._overrides=i,this.raw=o,this.logService=r,this.overrideConfigurations=new Map}get rawConfiguration(){if(!this._rawConfiguration)if(this.raw?.length){let e=this.raw.map(t=>{if(t instanceof n)return t;let i=new gae("",this.logService);return i.parseRaw(t),i.configurationModel});this._rawConfiguration=e.reduce((t,i)=>i===t?i:t.merge(i),e[0])}else this._rawConfiguration=this;return this._rawConfiguration}get contents(){return this._contents}get overrides(){return this._overrides}get keys(){return this._keys}isEmpty(){return this._keys.length===0&&Object.keys(this._contents).length===0&&this._overrides.length===0}getValue(e){return e?joe(this.contents,e):this.contents}inspect(e,t){let i=this;return{get value(){return k7(i.rawConfiguration.getValue(e))},get override(){return t?k7(i.rawConfiguration.getOverrideValue(e,t)):void 0},get merged(){return k7(t?i.rawConfiguration.override(t).getValue(e):i.rawConfiguration.getValue(e))},get overrides(){let o=[];for(let{contents:r,identifiers:s,keys:a}of i.rawConfiguration.overrides){let l=new n(r,a,[],void 0,i.logService).getValue(e);l!==void 0&&o.push({identifiers:s,value:l})}return o.length?k7(o):void 0}}}getOverrideValue(e,t){let i=this.getContentsForOverrideIdentifer(t);return i?e?joe(i,e):i:void 0}override(e){let t=this.overrideConfigurations.get(e);return t||(t=this.createOverrideConfigurationModel(e),this.overrideConfigurations.set(e,t)),t}merge(...e){let t=cf(this.contents),i=cf(this.overrides),o=[...this.keys],r=this.raw?.length?[...this.raw]:[this];for(let s of e)if(r.push(...s.raw?.length?s.raw:[s]),!s.isEmpty()){this.mergeContents(t,s.contents);for(let a of s.overrides){let[l]=i.filter(c=>oi(c.identifiers,a.identifiers));l?(this.mergeContents(l.contents,a.contents),l.keys.push(...a.keys),l.keys=Ac(l.keys)):i.push(cf(a))}for(let a of s.keys)o.indexOf(a)===-1&&o.push(a)}return new n(t,o,i,r.every(s=>s instanceof n)?void 0:r,this.logService)}createOverrideConfigurationModel(e){let t=this.getContentsForOverrideIdentifer(e);if(!t||typeof t!="object"||!Object.keys(t).length)return this;let i={};for(let o of Ac([...Object.keys(this.contents),...Object.keys(t)])){let r=this.contents[o],s=t[o];s&&(typeof r=="object"&&typeof s=="object"?(r=cf(r),this.mergeContents(r,s)):r=s),i[o]=r}return new n(i,this.keys,this.overrides,void 0,this.logService)}mergeContents(e,t){for(let i of Object.keys(t)){if(i in e&&mo(e[i])&&mo(t[i])){this.mergeContents(e[i],t[i]);continue}e[i]=cf(t[i])}}getContentsForOverrideIdentifer(e){let t=null,i=null,o=r=>{r&&(i?this.mergeContents(i,r):i=cf(r))};for(let r of this.overrides)r.identifiers.length===1&&r.identifiers[0]===e?t=r.contents:r.identifiers.includes(e)&&o(r.contents);return o(t),i}toJSON(){return{contents:this.contents,overrides:this.overrides,keys:this.keys}}setValue(e,t){this.updateValue(e,t,!1)}removeValue(e){let t=this.keys.indexOf(e);t!==-1&&(this.keys.splice(t,1),cNe(this.contents,e),Z_.test(e)&&this.overrides.splice(this.overrides.findIndex(i=>oi(i.identifiers,SA(e))),1))}updateValue(e,t,i){if($oe(this.contents,e,t,o=>this.logService.error(o)),i=i||this.keys.indexOf(e)===-1,i&&this.keys.push(e),Z_.test(e)){let o=SA(e),r={identifiers:o,keys:Object.keys(this.contents[e]),contents:v6(this.contents[e],a=>this.logService.error(a))},s=this.overrides.findIndex(a=>oi(a.identifiers,o));s!==-1?this.overrides[s]=r:this.overrides.push(r)}}},gae=class{constructor(e,t){this._name=e,this.logService=t,this._raw=null,this._configurationModel=null,this._restrictedConfigurations=[]}get configurationModel(){return this._configurationModel||Fl.createEmptyModel(this.logService)}parseRaw(e,t){this._raw=e;let{contents:i,keys:o,overrides:r,restricted:s,hasExcludedProperties:a}=this.doParseRaw(e,t);this._configurationModel=new Fl(i,o,r,a?[e]:void 0,this.logService),this._restrictedConfigurations=s||[]}doParseRaw(e,t){let i=ei.as(Qs.Configuration).getConfigurationProperties(),o=this.filter(e,i,!0,t);e=o.raw;let r=v6(e,l=>this.logService.error(`Conflict in settings file ${this._name}: ${l}`)),s=Object.keys(e),a=this.toOverrides(e,l=>this.logService.error(`Conflict in settings file ${this._name}: ${l}`));return{contents:r,keys:s,overrides:a,restricted:o.restricted,hasExcludedProperties:o.hasExcludedProperties}}filter(e,t,i,o){let r=!1;if(!o?.scopes&&!o?.skipRestricted&&!o?.exclude?.length)return{raw:e,restricted:[],hasExcludedProperties:r};let s={},a=[];for(let l in e)if(Z_.test(l)&&i){let c=this.filter(e[l],t,!1,o);s[l]=c.raw,r=r||c.hasExcludedProperties,a.push(...c.restricted)}else{let c=t[l],d=c?typeof c.scope<"u"?c.scope:3:void 0;c?.restricted&&a.push(l),!o.exclude?.includes(l)&&(o.include?.includes(l)||(d===void 0||o.scopes===void 0||o.scopes.includes(d))&&!(o.skipRestricted&&c?.restricted))?s[l]=e[l]:r=!0}return{raw:s,restricted:a,hasExcludedProperties:r}}toOverrides(e,t){let i=[];for(let o of Object.keys(e))if(Z_.test(o)){let r={};for(let s in e[o])r[s]=e[o][s];i.push({identifiers:SA(o),keys:Object.keys(r),contents:v6(r,t)})}return i}},_ae=class{constructor(e,t,i,o,r,s,a,l,c,d,u,h,f){this.key=e,this.overrides=t,this._value=i,this.overrideIdentifiers=o,this.defaultConfiguration=r,this.policyConfiguration=s,this.applicationConfiguration=a,this.userConfiguration=l,this.localUserConfiguration=c,this.remoteUserConfiguration=d,this.workspaceConfiguration=u,this.folderConfigurationModel=h,this.memoryConfigurationModel=f}toInspectValue(e){return e?.value!==void 0||e?.override!==void 0||e?.overrides!==void 0?e:void 0}get userInspectValue(){return this._userInspectValue||(this._userInspectValue=this.userConfiguration.inspect(this.key,this.overrides.overrideIdentifier)),this._userInspectValue}get user(){return this.toInspectValue(this.userInspectValue)}},kM=class n{constructor(e,t,i,o,r,s,a,l,c,d){this._defaultConfiguration=e,this._policyConfiguration=t,this._applicationConfiguration=i,this._localUserConfiguration=o,this._remoteUserConfiguration=r,this._workspaceConfiguration=s,this._folderConfigurations=a,this._memoryConfiguration=l,this._memoryConfigurationByResource=c,this.logService=d,this._workspaceConsolidatedConfiguration=null,this._foldersConsolidatedConfigurations=new Fo,this._userConfiguration=null}getValue(e,t,i){return this.getConsolidatedConfigurationModel(e,t,i).getValue(e)}updateValue(e,t,i={}){let o;i.resource?(o=this._memoryConfigurationByResource.get(i.resource),o||(o=Fl.createEmptyModel(this.logService),this._memoryConfigurationByResource.set(i.resource,o))):o=this._memoryConfiguration,t===void 0?o.removeValue(e):o.setValue(e,t),i.resource||(this._workspaceConsolidatedConfiguration=null)}inspect(e,t,i){let o=this.getConsolidatedConfigurationModel(e,t,i),r=this.getFolderConfigurationModelForResource(t.resource,i),s=t.resource?this._memoryConfigurationByResource.get(t.resource)||this._memoryConfiguration:this._memoryConfiguration,a=new Set;for(let l of o.overrides)for(let c of l.identifiers)o.getOverrideValue(e,c)!==void 0&&a.add(c);return new _ae(e,t,o.getValue(e),a.size?[...a]:void 0,this._defaultConfiguration,this._policyConfiguration.isEmpty()?void 0:this._policyConfiguration,this.applicationConfiguration.isEmpty()?void 0:this.applicationConfiguration,this.userConfiguration,this.localUserConfiguration,this.remoteUserConfiguration,i?this._workspaceConfiguration:void 0,r||void 0,s)}get applicationConfiguration(){return this._applicationConfiguration}get userConfiguration(){return this._userConfiguration||(this._userConfiguration=this._remoteUserConfiguration.isEmpty()?this._localUserConfiguration:this._localUserConfiguration.merge(this._remoteUserConfiguration)),this._userConfiguration}get localUserConfiguration(){return this._localUserConfiguration}get remoteUserConfiguration(){return this._remoteUserConfiguration}getConsolidatedConfigurationModel(e,t,i){let o=this.getConsolidatedConfigurationModelForResource(t,i);return t.overrideIdentifier&&(o=o.override(t.overrideIdentifier)),!this._policyConfiguration.isEmpty()&&this._policyConfiguration.getValue(e)!==void 0&&(o=o.merge(this._policyConfiguration)),o}getConsolidatedConfigurationModelForResource({resource:e},t){let i=this.getWorkspaceConsolidatedConfiguration();if(t&&e){let o=t.getFolder(e);o&&(i=this.getFolderConsolidatedConfiguration(o.uri)||i);let r=this._memoryConfigurationByResource.get(e);r&&(i=i.merge(r))}return i}getWorkspaceConsolidatedConfiguration(){return this._workspaceConsolidatedConfiguration||(this._workspaceConsolidatedConfiguration=this._defaultConfiguration.merge(this.applicationConfiguration,this.userConfiguration,this._workspaceConfiguration,this._memoryConfiguration)),this._workspaceConsolidatedConfiguration}getFolderConsolidatedConfiguration(e){let t=this._foldersConsolidatedConfigurations.get(e);if(!t){let i=this.getWorkspaceConsolidatedConfiguration(),o=this._folderConfigurations.get(e);o?(t=i.merge(o),this._foldersConsolidatedConfigurations.set(e,t)):t=i}return t}getFolderConfigurationModelForResource(e,t){if(t&&e){let i=t.getFolder(e);if(i)return this._folderConfigurations.get(i.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((e,t)=>{let{contents:i,overrides:o,keys:r}=this._folderConfigurations.get(t);return e.push([t,{contents:i,overrides:o,keys:r}]),e},[])}}static parse(e,t){let i=this.parseConfigurationModel(e.defaults,t),o=this.parseConfigurationModel(e.policy,t),r=this.parseConfigurationModel(e.application,t),s=this.parseConfigurationModel(e.user,t),a=this.parseConfigurationModel(e.workspace,t),l=e.folders.reduce((c,d)=>(c.set(Ee.revive(d[0]),this.parseConfigurationModel(d[1],t)),c),new Fo);return new n(i,o,r,s,Fl.createEmptyModel(t),a,l,Fl.createEmptyModel(t),new Fo,t)}static parseConfigurationModel(e,t){return new Fl(e.contents,e.keys,e.overrides,void 0,t)}},L7=class{constructor(e,t,i,o,r){this.change=e,this.previous=t,this.currentConfiguraiton=i,this.currentWorkspace=o,this.logService=r,this._marker=` `,this._markerCode1=this._marker.charCodeAt(0),this._markerCode2=46,this.affectedKeys=new Set,this._previousConfiguration=void 0;for(let s of e.keys)this.affectedKeys.add(s);for(let[,s]of e.overrides)for(let a of s)this.affectedKeys.add(a);this._affectsConfigStr=this._marker;for(let s of this.affectedKeys)this._affectsConfigStr+=s+this._marker}get previousConfiguration(){return!this._previousConfiguration&&this.previous&&(this._previousConfiguration=kM.parse(this.previous.data,this.logService)),this._previousConfiguration}affectsConfiguration(e,t){let i=this._marker+e,o=this._affectsConfigStr.indexOf(i);if(o<0)return!1;let r=o+i.length;if(r>=this._affectsConfigStr.length)return!1;let s=this._affectsConfigStr.charCodeAt(r);if(s!==this._markerCode1&&s!==this._markerCode2)return!1;if(t){let a=this.previousConfiguration?this.previousConfiguration.getValue(e,t,this.previous?.workspace):void 0,l=this.currentConfiguraiton.getValue(e,t,this.currentWorkspace);return!os(a,l)}return!0}}});var vae,xC,xae=k(()=>{Ie();vae=class{constructor(){this._onDidChange=new A,this.onDidChange=this._onDidChange.event,this._enabled=!0}get enabled(){return this._enabled}enable(){this._enabled=!0,this._onDidChange.fire()}disable(){this._enabled=!1,this._onDidChange.fire()}},xC=new vae});function Slt(n,e,t){return{kind:2,commandId:n,commandArgs:e,isBubble:t}}function nPe(n){return n?`${n.serialize()}`:"no when condition"}function oPe(n){return n.extensionId?n.isBuiltinExtension?`built-in extension ${n.extensionId}`:`user extension ${n.extensionId}`:n.isDefault?"built-in":"user"}var LM,Clt,I7,wae=k(()=>{it();LM={kind:0},Clt={kind:1};I7=class n{constructor(e,t,i){this._log=i,this._defaultKeybindings=e,this._defaultBoundCommands=new Map;for(let o of e){let r=o.command;r&&r.charAt(0)!=="-"&&this._defaultBoundCommands.set(r,!0)}this._map=new Map,this._lookupMap=new Map,this._keybindings=n.handleRemovals([].concat(e).concat(t));for(let o=0,r=this._keybindings.length;o"u"){this._map.set(e,[t]),this._addToLookupMap(t);return}for(let o=i.length-1;o>=0;o--){let r=i[o];if(r.command===t.command)continue;let s=!0;for(let a=1;a"u"?(t=[e],this._lookupMap.set(e.command,t)):t.push(e)}_removeFromLookupMap(e){if(!e.command)return;let t=this._lookupMap.get(e.command);if(!(typeof t>"u")){for(let i=0,o=t.length;i"u"||i.length===0)return null;if(i.length===1)return i[0];for(let o=i.length-1;o>=0;o--){let r=i[o];if(t.contextMatchesRules(r.when))return r}return i[i.length-1]}resolve(e,t,i){let o=[...t,i];this._log(`| Resolving ${o}`);let r=this._map.get(o[0]);if(r===void 0)return this._log("\\ No keybinding entries."),LM;let s=null;if(o.length<2)s=r;else{s=[];for(let l=0,c=r.length;ld.chords.length)continue;let u=!0;for(let h=1;h=0;i--){let o=t[i];if(n._contextMatchesRules(e,o.when))return o}return null}static _contextMatchesRules(e,t){return t?t.evaluate(e):!0}}});var klt,E7,nI,rPe=k(()=>{ft();je();Ie();xae();j();pe();wae();klt=/^(cursor|delete|undo|redo|tab|editor\.action\.clipboard)/,E7=class extends D{get onDidUpdateKeybindings(){return this._onDidUpdateKeybindings?this._onDidUpdateKeybindings.event:ne.None}get inChordMode(){return this._currentChords.length>0}constructor(e,t,i,o,r){super(),this._contextKeyService=e,this._commandService=t,this._telemetryService=i,this._notificationService=o,this._logService=r,this._onDidUpdateKeybindings=this._register(new A),this._currentChords=[],this._currentChordChecker=new vx,this._currentChordStatusMessage=null,this._ignoreSingleModifiers=nI.EMPTY,this._currentSingleModifier=null,this._currentSingleModifierClearTimeout=new _r,this._currentlyDispatchingCommandId=null,this._logging=!1}dispose(){super.dispose()}_log(e){this._logging&&this._logService.info(`[KeybindingService]: ${e}`)}getKeybindings(){return this._getResolver().getKeybindings()}lookupKeybinding(e,t){let i=this._getResolver().lookupPrimaryKeybinding(e,t||this._contextKeyService);if(i)return i.resolvedKeybinding}dispatchEvent(e,t){return this._dispatch(e,t)}softDispatch(e,t){this._log("/ Soft dispatching keyboard event");let i=this.resolveKeyboardEvent(e);if(i.hasMultipleChords())return console.warn("keyboard event should not be mapped to multiple chords"),LM;let[o]=i.getDispatchChords();if(o===null)return this._log("\\ Keyboard event cannot be dispatched"),LM;let r=this._contextKeyService.getContext(t),s=this._currentChords.map(({keypress:a})=>a);return this._getResolver().resolve(r,s,o)}_scheduleLeaveChordMode(){let e=Date.now();this._currentChordChecker.cancelAndSet(()=>{if(!this._documentHasFocus()){this._leaveChordMode();return}Date.now()-e>5e3&&this._leaveChordMode()},500)}_expectAnotherChord(e,t){switch(this._currentChords.push({keypress:e,label:t}),this._currentChords.length){case 0:throw Kk("impossible");case 1:this._currentChordStatusMessage=this._notificationService.status(m("first.chord","({0}) was pressed. Waiting for second key of chord...",t));break;default:{let i=this._currentChords.map(({label:o})=>o).join(", ");this._currentChordStatusMessage=this._notificationService.status(m("next.chord","({0}) was pressed. Waiting for next key of chord...",i))}}this._scheduleLeaveChordMode(),xC.enabled&&xC.disable()}_leaveChordMode(){this._currentChordStatusMessage&&(this._currentChordStatusMessage.dispose(),this._currentChordStatusMessage=null),this._currentChordChecker.cancel(),this._currentChords=[],xC.enable()}_dispatch(e,t){return this._doDispatch(this.resolveKeyboardEvent(e),t,!1)}_singleModifierDispatch(e,t){let i=this.resolveKeyboardEvent(e),[o]=i.getSingleModifierDispatchChords();if(o)return this._ignoreSingleModifiers.has(o)?(this._log(`+ Ignoring single modifier ${o} due to it being pressed together with other keys.`),this._ignoreSingleModifiers=nI.EMPTY,this._currentSingleModifierClearTimeout.cancel(),this._currentSingleModifier=null,!1):(this._ignoreSingleModifiers=nI.EMPTY,this._currentSingleModifier===null?(this._log(`+ Storing single modifier for possible chord ${o}.`),this._currentSingleModifier=o,this._currentSingleModifierClearTimeout.cancelAndSet(()=>{this._log("+ Clearing single modifier due to 300ms elapsed."),this._currentSingleModifier=null},300),!1):o===this._currentSingleModifier?(this._log(`/ Dispatching single modifier chord ${o} ${o}`),this._currentSingleModifierClearTimeout.cancel(),this._currentSingleModifier=null,this._doDispatch(i,t,!0)):(this._log(`+ Clearing single modifier due to modifier mismatch: ${this._currentSingleModifier} ${o}`),this._currentSingleModifierClearTimeout.cancel(),this._currentSingleModifier=null,!1));let[r]=i.getChords();return this._ignoreSingleModifiers=new nI(r),this._currentSingleModifier!==null&&this._log("+ Clearing single modifier due to other key up."),this._currentSingleModifierClearTimeout.cancel(),this._currentSingleModifier=null,!1}_doDispatch(e,t,i=!1){let o=!1;if(e.hasMultipleChords())return console.warn("Unexpected keyboard event mapped to multiple chords"),!1;let r=null,s=null;if(i){let[d]=e.getSingleModifierDispatchChords();r=d,s=d?[d]:[]}else[r]=e.getDispatchChords(),s=this._currentChords.map(({keypress:d})=>d);if(r===null)return this._log("\\ Keyboard event cannot be dispatched in keydown phase."),o;let a=this._contextKeyService.getContext(t),l=e.getLabel(),c=this._getResolver().resolve(a,s,r);switch(c.kind){case 0:{if(this._logService.trace("KeybindingService#dispatch",l,"[ No matching keybinding ]"),this.inChordMode){let d=this._currentChords.map(({label:u})=>u).join(", ");this._log(`+ Leaving multi-chord mode: Nothing bound to "${d}, ${l}".`),this._notificationService.status(m("missing.chord","The key combination ({0}, {1}) is not a command.",d,l),{hideAfter:10*1e3}),this._leaveChordMode(),o=!0}return o}case 1:return this._logService.trace("KeybindingService#dispatch",l,"[ Several keybindings match - more chords needed ]"),o=!0,this._expectAnotherChord(r,l),this._log(this._currentChords.length===1?"+ Entering multi-chord mode...":"+ Continuing multi-chord mode..."),o;case 2:{if(this._logService.trace("KeybindingService#dispatch",l,`[ Will dispatch command ${c.commandId} ]`),c.commandId===null||c.commandId===""){if(this.inChordMode){let d=this._currentChords.map(({label:u})=>u).join(", ");this._log(`+ Leaving chord mode: Nothing bound to "${d}, ${l}".`),this._notificationService.status(m("missing.chord","The key combination ({0}, {1}) is not a command.",d,l),{hideAfter:10*1e3}),this._leaveChordMode(),o=!0}}else{this.inChordMode&&this._leaveChordMode(),c.isBubble||(o=!0),this._log(`+ Invoking command ${c.commandId}.`),this._currentlyDispatchingCommandId=c.commandId;try{typeof c.commandArgs>"u"?this._commandService.executeCommand(c.commandId).then(void 0,d=>this._notificationService.warn(d)):this._commandService.executeCommand(c.commandId,c.commandArgs).then(void 0,d=>this._notificationService.warn(d))}finally{this._currentlyDispatchingCommandId=null}klt.test(c.commandId)||this._telemetryService.publicLog2("workbenchActionExecuted",{id:c.commandId,from:"keybinding",detail:e.getUserSettingsLabel()??void 0})}return o}}}mightProducePrintableCharacter(e){return e.ctrlKey||e.metaKey?!1:e.keyCode>=31&&e.keyCode<=56||e.keyCode>=21&&e.keyCode<=30}},nI=class n{static{this.EMPTY=new n(null)}constructor(e){this._ctrlKey=e?e.ctrlKey:!1,this._shiftKey=e?e.shiftKey:!1,this._altKey=e?e.altKey:!1,this._metaKey=e?e.metaKey:!1}has(e){switch(e){case"ctrl":return this._ctrlKey;case"shift":return this._shiftKey;case"alt":return this._altKey;case"meta":return this._metaKey}}}});function T7(n){let e=[];for(let t=0,i=n.length;t{IM=class{constructor(e,t,i,o,r,s,a){this._resolvedKeybindingItemBrand=void 0,this.resolvedKeybinding=e,this.chords=e?T7(e.getDispatchChords()):[],e&&this.chords.length===0&&(this.chords=T7(e.getSingleModifierDispatchChords())),this.bubble=t?t.charCodeAt(0)===94:!1,this.command=this.bubble?t.substr(1):t,this.commandArgs=i,this.when=o,this.isDefault=r,this.extensionId=s,this.isBuiltinExtension=a}}});function Llt(n,e,t){if(e===null)return"";let i=[];return n.ctrlKey&&i.push(t.ctrlKey),n.shiftKey&&i.push(t.shiftKey),n.altKey&&i.push(t.altKey),n.metaKey&&i.push(t.metaKey),e!==""&&i.push(e),i.join(t.separator)}var oI,rI,sPe,aPe,lPe,D7=k(()=>{pe();oI=class{constructor(e,t,i=t){this.modifierLabels=[null],this.modifierLabels[2]=e,this.modifierLabels[1]=t,this.modifierLabels[3]=i}toLabel(e,t,i){if(t.length===0)return null;let o=[];for(let r=0,s=t.length;r{je();D7();S1();N7=class extends mB{constructor(e,t){if(super(),t.length===0)throw js("chords");this._os=e,this._chords=t}getLabel(){return rI.toLabel(this._os,this._chords,e=>this._getLabel(e))}getAriaLabel(){return sPe.toLabel(this._os,this._chords,e=>this._getAriaLabel(e))}getElectronAccelerator(){return this._chords.length>1||this._chords[0].isDuplicateModifierCase()?null:aPe.toLabel(this._os,this._chords,e=>this._getElectronAccelerator(e))}getUserSettingsLabel(){return lPe.toLabel(this._os,this._chords,e=>this._getUserSettingsLabel(e))}hasMultipleChords(){return this._chords.length>1}getChords(){return this._chords.map(e=>this._getChord(e))}_getChord(e){return new pB(e.ctrlKey,e.shiftKey,e.altKey,e.metaKey,this._getLabel(e),this._getAriaLabel(e))}getDispatchChords(){return this._chords.map(e=>this._getChordDispatch(e))}getSingleModifierDispatchChords(){return this._chords.map(e=>this._getSingleModifierChordDispatch(e))}}});var EM,dPe=k(()=>{hu();S1();cPe();yae();EM=class n extends N7{constructor(e,t){super(t,e)}_keyCodeToUILabel(e){if(this._os===2)switch(e){case 15:return"\u2190";case 16:return"\u2191";case 17:return"\u2192";case 18:return"\u2193"}return hf.toString(e)}_getLabel(e){return e.isDuplicateModifierCase()?"":this._keyCodeToUILabel(e.keyCode)}_getAriaLabel(e){return e.isDuplicateModifierCase()?"":hf.toString(e.keyCode)}_getElectronAccelerator(e){return hf.toElectronAccelerator(e.keyCode)}_getUserSettingsLabel(e){if(e.isDuplicateModifierCase())return"";let t=hf.toUserSettingsUS(e.keyCode);return t&&t.toLowerCase()}_getChordDispatch(e){return n.getDispatchStr(e)}static getDispatchStr(e){if(e.isModifierKey())return null;let t="";return e.ctrlKey&&(t+="ctrl+"),e.shiftKey&&(t+="shift+"),e.altKey&&(t+="alt+"),e.metaKey&&(t+="meta+"),t+=hf.toString(e.keyCode),t}_getSingleModifierChordDispatch(e){return e.keyCode===5&&!e.shiftKey&&!e.altKey&&!e.metaKey?"ctrl":e.keyCode===4&&!e.ctrlKey&&!e.altKey&&!e.metaKey?"shift":e.keyCode===6&&!e.ctrlKey&&!e.shiftKey&&!e.metaKey?"alt":e.keyCode===57&&!e.ctrlKey&&!e.shiftKey&&!e.altKey?"meta":null}static _scanCodeToKeyCode(e){let t=Z3[e];if(t!==-1)return t;switch(e){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 88;case 52:return 86;case 53:return 92;case 54:return 94;case 55:return 93;case 56:return 0;case 57:return 85;case 58:return 95;case 59:return 91;case 60:return 87;case 61:return 89;case 62:return 90;case 106:return 97}return 0}static _toKeyCodeChord(e){if(!e)return null;if(e instanceof fh)return e;let t=this._scanCodeToKeyCode(e.scanCode);return t===0?null:new fh(e.ctrlKey,e.shiftKey,e.altKey,e.metaKey,t)}static resolveKeybinding(e,t){let i=T7(e.chords.map(o=>this._toKeyCodeChord(o)));return i.length>0?[new n(i,t)]:[]}}});var xp,sI=k(()=>{Fe();xp=We("labelService")});var R7,NYt,Od,Fd,kf=k(()=>{Fe();R7=We("progressService"),NYt=Object.freeze({total(){},worked(){},done(){}}),Od=class{static{this.None=Object.freeze({report(){}})}constructor(e){this.callback=e}report(e){this._value=e,this.callback(this._value)}},Fd=We("editorProgressService")});var Cae,Sae,kae,Lae,aI,wC,A7=k(()=>{Qe();Cae=class{constructor(){this._value="",this._pos=0}reset(e){return this._value=e,this._pos=0,this}next(){return this._pos+=1,this}hasNext(){return this._pos=0;t--,this._valueLen--){let i=this._value.charCodeAt(t);if(!(i===47||this._splitOnBackslash&&i===92))break}return this.next()}hasNext(){return this._to!1,t=()=>!1){return new n(new Lae(e,t))}static forStrings(){return new n(new Cae)}static forConfigKeys(){return new n(new Sae)}constructor(e){this._iter=e}clear(){this._root=void 0}set(e,t){let i=this._iter.reset(e),o;this._root||(this._root=new aI,this._root.segment=i.value());let r=[];for(o=this._root;;){let a=i.cmp(o.segment);if(a>0)o.left||(o.left=new aI,o.left.segment=i.value()),r.push([-1,o]),o=o.left;else if(a<0)o.right||(o.right=new aI,o.right.segment=i.value()),r.push([1,o]),o=o.right;else if(i.hasNext())i.next(),o.mid||(o.mid=new aI,o.mid.segment=i.value()),r.push([0,o]),o=o.mid;else break}let s=o.value;o.value=t,o.key=e;for(let a=r.length-1;a>=0;a--){let l=r[a][1];l.updateHeight();let c=l.balanceFactor();if(c<-1||c>1){let d=r[a][0],u=r[a+1][0];if(d===1&&u===1)r[a][1]=l.rotateLeft();else if(d===-1&&u===-1)r[a][1]=l.rotateRight();else if(d===1&&u===-1)l.right=r[a+1][1]=r[a+1][1].rotateRight(),r[a][1]=l.rotateLeft();else if(d===-1&&u===1)l.left=r[a+1][1]=r[a+1][1].rotateLeft(),r[a][1]=l.rotateRight();else throw new Error;if(a>0)switch(r[a-1][0]){case-1:r[a-1][1].left=r[a][1];break;case 1:r[a-1][1].right=r[a][1];break;case 0:r[a-1][1].mid=r[a][1];break}else this._root=r[0][1]}}return s}get(e){return this._getNode(e)?.value}_getNode(e){let t=this._iter.reset(e),i=this._root;for(;i;){let o=t.cmp(i.segment);if(o>0)i=i.left;else if(o<0)i=i.right;else if(t.hasNext())t.next(),i=i.mid;else break}return i}has(e){let t=this._getNode(e);return!(t?.value===void 0&&t?.mid===void 0)}delete(e){return this._delete(e,!1)}deleteSuperstr(e){return this._delete(e,!0)}_delete(e,t){let i=this._iter.reset(e),o=[],r=this._root;for(;r;){let s=i.cmp(r.segment);if(s>0)o.push([-1,r]),r=r.left;else if(s<0)o.push([1,r]),r=r.right;else if(i.hasNext())i.next(),o.push([0,r]),r=r.mid;else break}if(r){if(t?(r.left=void 0,r.mid=void 0,r.right=void 0,r.height=1):(r.key=void 0,r.value=void 0),!r.mid&&!r.value)if(r.left&&r.right){let s=this._min(r.right);if(s.key){let{key:a,value:l,segment:c}=s;this._delete(s.key,!1),r.key=a,r.value=l,r.segment=c}}else{let s=r.left??r.right;if(o.length>0){let[a,l]=o[o.length-1];switch(a){case-1:l.left=s;break;case 0:l.mid=s;break;case 1:l.right=s;break}}else this._root=s}for(let s=o.length-1;s>=0;s--){let a=o[s][1];a.updateHeight();let l=a.balanceFactor();if(l>1?(a.right.balanceFactor()>=0||(a.right=a.right.rotateRight()),o[s][1]=a.rotateLeft()):l<-1&&(a.left.balanceFactor()<=0||(a.left=a.left.rotateLeft()),o[s][1]=a.rotateRight()),s>0)switch(o[s-1][0]){case-1:o[s-1][1].left=o[s][1];break;case 1:o[s-1][1].right=o[s][1];break;case 0:o[s-1][1].mid=o[s][1];break}else this._root=o[0][1]}}}_min(e){for(;e.left;)e=e.left;return e}findSubstr(e){let t=this._iter.reset(e),i=this._root,o;for(;i;){let r=t.cmp(i.segment);if(r>0)i=i.left;else if(r<0)i=i.right;else if(t.hasNext())t.next(),o=i.value||o,i=i.mid;else break}return i&&i.value||o}findSuperstr(e){return this._findSuperstrOrElement(e,!1)}_findSuperstrOrElement(e,t){let i=this._iter.reset(e),o=this._root;for(;o;){let r=i.cmp(o.segment);if(r>0)o=o.left;else if(r<0)o=o.right;else if(i.hasNext())i.next(),o=o.mid;else return o.mid?this._entries(o.mid):t?o.value:void 0}}forEach(e){for(let[t,i]of this)e(i,t)}*[Symbol.iterator](){yield*this._entries(this._root)}_entries(e){let t=[];return this._dfsEntries(e,t),t[Symbol.iterator]()}_dfsEntries(e,t){e&&(e.left&&this._dfsEntries(e.left,t),e.value&&t.push([e.key,e.value]),e.mid&&this._dfsEntries(e.mid,t),e.right&&this._dfsEntries(e.right,t))}}});function P7(n){let e=n;return typeof e?.id=="string"&&Ee.isUri(e.uri)}function uPe(n){return typeof n?.id=="string"&&!P7(n)&&!Tlt(n)}function hPe(n,e){if(typeof n=="string"||typeof n>"u")return typeof n=="string"?{id:ff(n)}:e?Ilt:Elt;let t=n;return t.configuration?{id:t.id,configPath:t.configuration}:t.folders.length===1?{id:t.id,uri:t.folders[0].uri}:{id:t.id}}function Tlt(n){let e=n;return typeof e?.id=="string"&&Ee.isUri(e.configPath)}function fPe(n){return n.id===Iae}var wp,Ilt,Elt,M7,O7,HYt,Iae,lI=k(()=>{pe();sp();A7();Ai();Fe();wp=We("contextService");Ilt={id:"ext-dev"},Elt={id:"empty-window"};M7=class{constructor(e,t){this.raw=t,this.uri=e.uri,this.index=e.index,this.name=e.name}toJSON(){return{uri:this.uri,name:this.name,index:this.index}}},O7="code-workspace",HYt=[{name:m("codeWorkspace","Code Workspace"),extensions:[O7]}],Iae="4064f6ec-cb38-4ad0-af64-ee6467e63c82"});var F7,TM,B7,DM,cI,W7,H7,z7,og=k(()=>{pe();(function(n){n.inspectTokensAction=m("inspectTokens","Developer: Inspect Tokens")})(F7||(F7={}));(function(n){n.gotoLineActionLabel=m("gotoLineActionLabel","Go to Line/Column...")})(TM||(TM={}));(function(n){n.helpQuickAccessActionLabel=m("helpQuickAccess","Show all Quick Access Providers")})(B7||(B7={}));(function(n){n.quickCommandActionLabel=m("quickCommandActionLabel","Command Palette"),n.quickCommandHelp=m("quickCommandActionHelp","Show And Run Commands")})(DM||(DM={}));(function(n){n.quickOutlineActionLabel=m("quickOutlineActionLabel","Go to Symbol..."),n.quickOutlineByCategoryActionLabel=m("quickOutlineByCategoryActionLabel","Go to Symbol by Category...")})(cI||(cI={}));(function(n){n.editorViewAccessibleLabel=m("editorViewAccessibleLabel","Editor content")})(W7||(W7={}));(function(n){n.toggleHighContrast=m("toggleHighContrast","Toggle High Contrast Theme")})(H7||(H7={}));(function(n){n.bulkEditServiceSummary=m("bulkEditServiceSummary","Made {0} edits in {1} files")})(z7||(z7={}))});var V7,Eae=k(()=>{Fe();V7=We("workspaceTrustManagementService")});function NM(n,e=!1){Dlt(n,!1,e)}function Dlt(n,e,t){let i=Nlt(n,e);dI.push(i),i.userConfigured?mPe.push(i):Tae.push(i),t&&!i.userConfigured&&dI.forEach(o=>{o.mime===i.mime||o.userConfigured||(i.extension&&o.extension===i.extension&&console.warn(`Overwriting extension <<${i.extension}>> to now point to mime <<${i.mime}>>`),i.filename&&o.filename===i.filename&&console.warn(`Overwriting filename <<${i.filename}>> to now point to mime <<${i.mime}>>`),i.filepattern&&o.filepattern===i.filepattern&&console.warn(`Overwriting filepattern <<${i.filepattern}>> to now point to mime <<${i.mime}>>`),i.firstline&&o.firstline===i.firstline&&console.warn(`Overwriting firstline <<${i.firstline}>> to now point to mime <<${i.mime}>>`))})}function Nlt(n,e){return{id:n.id,mime:n.mime,filename:n.filename,extension:n.extension,filepattern:n.filepattern,firstline:n.firstline,userConfigured:e,filenameLowercase:n.filename?n.filename.toLowerCase():void 0,extensionLowercase:n.extension?n.extension.toLowerCase():void 0,filepatternLowercase:n.filepattern?rse(n.filepattern.toLowerCase()):void 0,filepatternOnPath:n.filepattern?n.filepattern.indexOf(eo.sep)>=0:!1}}function gPe(){dI=dI.filter(n=>n.userConfigured),Tae=[]}function _Pe(n,e){return Rlt(n,e).map(t=>t.id)}function Rlt(n,e){let t;if(n)switch(n.scheme){case rt.file:t=n.fsPath;break;case rt.data:{t=eg.parseMetaData(n).get(eg.META_DATA_LABEL);break}case rt.vscodeNotebookCell:t=void 0;break;default:t=n.path}if(!t)return[{id:"unknown",mime:An.unknown}];t=t.toLowerCase();let i=ff(t),o=pPe(t,i,mPe);if(o)return[o,{id:Oo,mime:An.text}];let r=pPe(t,i,Tae);if(r)return[r,{id:Oo,mime:An.text}];if(e){let s=Alt(e);if(s)return[s,{id:Oo,mime:An.text}]}return[{id:"unknown",mime:An.unknown}]}function pPe(n,e,t){let i,o,r;for(let s=t.length-1;s>=0;s--){let a=t[s];if(e===a.filenameLowercase){i=a;break}if(a.filepattern&&(!o||a.filepattern.length>o.filepattern.length)){let l=a.filepatternOnPath?n:e;a.filepatternLowercase?.(l)&&(o=a)}a.extension&&(!r||a.extension.length>r.extension.length)&&e.endsWith(a.extensionLowercase)&&(r=a)}if(i)return i;if(o)return o;if(r)return r}function Alt(n){if(oL(n)&&(n=n.substr(1)),n.length>0)for(let e=dI.length-1;e>=0;e--){let t=dI[e];if(!t.firstline)continue;let i=n.match(t.firstline);if(i&&i.length>0)return t}}var dI,Tae,mPe,bPe=k(()=>{sse();Ex();ds();sp();ia();Qe();Nd();dI=[],Tae=[],mPe=[]});var U7,vPe,Dae,$7,xPe=k(()=>{Ie();j();Qe();bPe();Nd();Mm();br();U7=Object.prototype.hasOwnProperty,vPe="vs.editor.nullLanguage",Dae=class{constructor(){this._languageIdToLanguage=[],this._languageToLanguageId=new Map,this._register(vPe,0),this._register(Oo,1),this._nextLanguageId=2}_register(e,t){this._languageIdToLanguage[t]=e,this._languageToLanguageId.set(e,t)}register(e){if(this._languageToLanguageId.has(e))return;let t=this._nextLanguageId++;this._register(e,t)}encodeLanguageId(e){return this._languageToLanguageId.get(e)||0}decodeLanguageId(e){return this._languageIdToLanguage[e]||vPe}},$7=class n extends D{static{this.instanceCount=0}constructor(e=!0,t=!1){super(),this._onDidChange=this._register(new A),this.onDidChange=this._onDidChange.event,n.instanceCount++,this._warnOnOverwrite=t,this.languageIdCodec=new Dae,this._dynamicLanguages=[],this._languages={},this._mimeTypesMap={},this._nameMap={},this._lowercaseNameMap={},e&&(this._initializeFromRegistry(),this._register(Tx.onDidChangeLanguages(i=>{this._initializeFromRegistry()})))}dispose(){n.instanceCount--,super.dispose()}_initializeFromRegistry(){this._languages={},this._mimeTypesMap={},this._nameMap={},this._lowercaseNameMap={},gPe();let e=[].concat(Tx.getLanguages()).concat(this._dynamicLanguages);this._registerLanguages(e)}_registerLanguages(e){for(let t of e)this._registerLanguage(t);this._mimeTypesMap={},this._nameMap={},this._lowercaseNameMap={},Object.keys(this._languages).forEach(t=>{let i=this._languages[t];i.name&&(this._nameMap[i.name]=i.identifier),i.aliases.forEach(o=>{this._lowercaseNameMap[o.toLowerCase()]=i.identifier}),i.mimetypes.forEach(o=>{this._mimeTypesMap[o]=i.identifier})}),ei.as(Qs.Configuration).registerOverrideIdentifiers(this.getRegisteredLanguageIds()),this._onDidChange.fire()}_registerLanguage(e){let t=e.id,i;U7.call(this._languages,t)?i=this._languages[t]:(this.languageIdCodec.register(t),i={identifier:t,name:null,mimetypes:[],aliases:[],extensions:[],filenames:[],configurationFiles:[],icons:[]},this._languages[t]=i),this._mergeLanguage(i,e)}_mergeLanguage(e,t){let i=t.id,o=null;if(Array.isArray(t.mimetypes)&&t.mimetypes.length>0&&(e.mimetypes.push(...t.mimetypes),o=t.mimetypes[0]),o||(o=`text/x-${i}`,e.mimetypes.push(o)),Array.isArray(t.extensions)){t.configuration?e.extensions=t.extensions.concat(e.extensions):e.extensions=e.extensions.concat(t.extensions);for(let a of t.extensions)NM({id:i,mime:o,extension:a},this._warnOnOverwrite)}if(Array.isArray(t.filenames))for(let a of t.filenames)NM({id:i,mime:o,filename:a},this._warnOnOverwrite),e.filenames.push(a);if(Array.isArray(t.filenamePatterns))for(let a of t.filenamePatterns)NM({id:i,mime:o,filepattern:a},this._warnOnOverwrite);if(typeof t.firstLine=="string"&&t.firstLine.length>0){let a=t.firstLine;a.charAt(0)!=="^"&&(a="^"+a);try{let l=new RegExp(a);BTe(l)||NM({id:i,mime:o,firstline:l},this._warnOnOverwrite)}catch(l){console.warn(`[${t.id}]: Invalid regular expression \`${a}\`: `,l)}}e.aliases.push(i);let r=null;if(typeof t.aliases<"u"&&Array.isArray(t.aliases)&&(t.aliases.length===0?r=[null]:r=t.aliases),r!==null)for(let a of r)!a||a.length===0||e.aliases.push(a);let s=r!==null&&r.length>0;if(!(s&&r[0]===null)){let a=(s?r[0]:null)||i;(s||!e.name)&&(e.name=a)}t.configuration&&e.configurationFiles.push(t.configuration),t.icon&&e.icons.push(t.icon)}isRegisteredLanguageId(e){return e?U7.call(this._languages,e):!1}getRegisteredLanguageIds(){return Object.keys(this._languages)}getLanguageIdByLanguageName(e){let t=e.toLowerCase();return U7.call(this._lowercaseNameMap,t)?this._lowercaseNameMap[t]:null}getLanguageIdByMimeType(e){return e&&U7.call(this._mimeTypesMap,e)?this._mimeTypesMap[e]:null}guessLanguageIdByFilepathOrFirstLine(e,t){return!e&&!t?[]:_Pe(e,t)}}});function yC(n=Bl){return(e,t)=>oi(e,t,n)}function wPe(){return(n,e)=>n.equals(e)}function RM(n,e,t){if(t!==void 0){let i=n;return i==null||e===void 0||e===null?e===i:t(i,e)}else{let i=n;return(o,r)=>o==null||r===void 0||r===null?r===o:i(o,r)}}function uI(n,e){if(n===e)return!0;if(Array.isArray(n)&&Array.isArray(e)){if(n.length!==e.length)return!1;for(let t=0;t{at();Bl=(n,e)=>n===e});function Mlt(n,e){let t=Nae.get(n);if(t)return t;let i=Plt(n,e);if(i){let o=yPe.get(i)??0;o++,yPe.set(i,o);let r=o===1?i:`${i}#${o}`;return Nae.set(n,r),r}}function Plt(n,e){let t=Nae.get(n);if(t)return t;let i=e.owner?Flt(e.owner)+".":"",o,r=e.debugNameSource;if(r!==void 0)if(typeof r=="function"){if(o=r(),o!==void 0)return i+o}else return i+r;let s=e.referenceFn;if(s!==void 0&&(o=j7(s),o!==void 0))return i+o;if(e.owner!==void 0){let a=Olt(e.owner,n);if(a!==void 0)return i+a}}function Olt(n,e){for(let t in n)if(n[t]===e)return t}function Flt(n){let e=SPe.get(n);if(e)return e;let t=Blt(n),i=CPe.get(t)??0;i++,CPe.set(t,i);let o=i===1?t:`${t}#${i}`;return SPe.set(n,o),o}function Blt(n){let e=n.constructor;return e?e.name:"Object"}function j7(n){let e=n.toString(),i=/\/\*\*\s*@description\s*([^*]*)\*\//.exec(e);return(i?i[1]:void 0)?.trim()}var Cr,yPe,Nae,CPe,SPe,hI=k(()=>{Cr=class{constructor(e,t,i){this.owner=e,this.debugNameSource=t,this.referenceFn=i}getDebugName(e){return Mlt(e,this)}},yPe=new Map,Nae=new WeakMap;CPe=new Map,SPe=new WeakMap});function LPe(n){kPe=n}function Du(){return kPe}function Wlt(n){let e=new Array,t=[],i="";function o(s){if("length"in s)for(let a of s)a&&o(a);else"text"in s?(i+=`%c${s.text}`,e.push(s.style),s.data&&t.push(...s.data)):"data"in s&&t.push(...s.data)}o(n);let r=[i,...e];return r.push(...t),r}function fI(n){return yp(n,{color:"black"})}function AM(n){return yp(Ult(`${n}: `,10),{color:"black",bold:!0})}function yp(n,e={color:"black"}){function t(o){return Object.entries(o).reduce((r,[s,a])=>`${r}${s}:${a};`,"")}let i={color:e.color};return e.strikeThrough&&(i["text-decoration"]="line-through"),e.bold&&(i["font-weight"]="bold"),{text:n,style:t(i)}}function MM(n,e){switch(typeof n){case"number":return""+n;case"string":return n.length+2<=e?`"${n}"`:`"${n.substr(0,e-7)}"+...`;case"boolean":return n?"true":"false";case"undefined":return"undefined";case"object":return n===null?"null":Array.isArray(n)?Hlt(n,e):zlt(n,e);case"symbol":return n.toString();case"function":return`[[Function${n.name?" "+n.name:""}]]`;default:return""+n}}function Hlt(n,e){let t="[ ",i=!0;for(let o of n){if(i||(t+=", "),t.length-5>e){t+="...";break}i=!1,t+=`${MM(o,e-t.length)}`}return t+=" ]",t}function zlt(n,e){let t="{ ",i=!0;for(let[o,r]of Object.entries(n)){if(i||(t+=", "),t.length-5>e){t+="...";break}i=!1,t+=`${o}: ${MM(r,e-t.length)}`}return t+=" }",t}function Vlt(n,e){let t="";for(let i=1;i<=e;i++)t+=n;return t}function Ult(n,e){for(;n.length{q7=class{constructor(){this.indentation=0,this.changedObservablesSets=new WeakMap}textToConsoleArgs(e){return Wlt([fI(Vlt("| ",this.indentation)),e])}formatInfo(e){return e.hadValue?e.didChange?[fI(" "),yp(MM(e.oldValue,70),{color:"red",strikeThrough:!0}),fI(" "),yp(MM(e.newValue,60),{color:"green"})]:[fI(" (unchanged)")]:[fI(" "),yp(MM(e.newValue,60),{color:"green"}),fI(" (initial)")]}handleObservableChanged(e,t){console.log(...this.textToConsoleArgs([AM("observable value changed"),yp(e.debugName,{color:"BlueViolet"}),...this.formatInfo(t)]))}formatChanges(e){if(e.size!==0)return yp(" (changed deps: "+[...e].map(t=>t.debugName).join(", ")+")",{color:"gray"})}handleDerivedCreated(e){let t=e.handleChange;this.changedObservablesSets.set(e,new Set),e.handleChange=(i,o)=>(this.changedObservablesSets.get(e).add(i),t.apply(e,[i,o]))}handleDerivedRecomputed(e,t){let i=this.changedObservablesSets.get(e);console.log(...this.textToConsoleArgs([AM("derived recomputed"),yp(e.debugName,{color:"BlueViolet"}),...this.formatInfo(t),this.formatChanges(i),{data:[{fn:e._debugNameData.referenceFn??e._computeFn}]}])),i.clear()}handleFromEventObservableTriggered(e,t){console.log(...this.textToConsoleArgs([AM("observable from event triggered"),yp(e.debugName,{color:"BlueViolet"}),...this.formatInfo(t),{data:[{fn:e._getValue}]}]))}handleAutorunCreated(e){let t=e.handleChange;this.changedObservablesSets.set(e,new Set),e.handleChange=(i,o)=>(this.changedObservablesSets.get(e).add(i),t.apply(e,[i,o]))}handleAutorunTriggered(e){let t=this.changedObservablesSets.get(e);console.log(...this.textToConsoleArgs([AM("autorun"),yp(e.debugName,{color:"BlueViolet"}),this.formatChanges(t),{data:[{fn:e._debugNameData.referenceFn??e._runFn}]}])),t.clear(),this.indentation++}handleAutorunFinished(e){this.indentation--}handleBeginTransaction(e){let t=e.getDebugName();t===void 0&&(t=""),console.log(...this.textToConsoleArgs([AM("transaction"),yp(t,{color:"BlueViolet"}),{data:[{fn:e._fn}]}])),this.indentation++}handleEndTransaction(){this.indentation--}}});function EPe(n){IPe=n}function DPe(n){TPe=n}function NPe(n){Rae=n}function xi(n,e){let t=new sg(n,e);try{n(t)}finally{t.finish()}}function CC(n){if(K7)n(K7);else{let e=new sg(n,void 0);K7=e;try{n(e)}finally{e.finish(),K7=void 0}}}async function G7(n,e){let t=new sg(n,e);try{await n(t)}finally{t.finish()}}function Nh(n,e,t){n?e(n):xi(e,t)}function lt(n,e){let t;return typeof n=="string"?t=new Cr(void 0,n,void 0):t=new Cr(n,void 0,void 0),new mI(t,e,Bl)}function ag(n,e){let t;return typeof n=="string"?t=new Cr(void 0,n,void 0):t=new Cr(n,void 0,void 0),new Aae(t,e,Bl)}var IPe,TPe,Rae,PM,Cp,K7,sg,mI,Aae,Lf=k(()=>{rg();hI();pI();PM=class{get TChange(){return null}reportChanges(){this.get()}read(e){return e?e.readObservable(this):this.get()}map(e,t){let i=t===void 0?void 0:e,o=t===void 0?e:t;return Rae({owner:i,debugName:()=>{let r=j7(o);if(r!==void 0)return r;let a=/^\s*\(?\s*([a-zA-Z_$][a-zA-Z_$0-9]*)\s*\)?\s*=>\s*\1(?:\??)\.([a-zA-Z_$][a-zA-Z_$0-9]*)\s*$/.exec(o.toString());if(a)return`${this.debugName}.${a[2]}`;if(!i)return`${this.debugName} (mapped)`},debugReferenceFn:o},r=>o(this.read(r),r))}flatten(){return Rae({owner:void 0,debugName:()=>`${this.debugName} (flattened)`},e=>this.read(e).read(e))}recomputeInitiallyAndOnChange(e,t){return e.add(IPe(this,t)),this}keepObserved(e){return e.add(TPe(this)),this}},Cp=class extends PM{constructor(){super(...arguments),this.observers=new Set}addObserver(e){let t=this.observers.size;this.observers.add(e),t===0&&this.onFirstObserverAdded()}removeObserver(e){this.observers.delete(e)&&this.observers.size===0&&this.onLastObserverRemoved()}onFirstObserverAdded(){}onLastObserverRemoved(){}};sg=class{constructor(e,t){this._fn=e,this._getDebugName=t,this.updatingObservers=[],Du()?.handleBeginTransaction(this)}getDebugName(){return this._getDebugName?this._getDebugName():j7(this._fn)}updateObserver(e,t){this.updatingObservers.push({observer:e,observable:t}),e.beginUpdate(t)}finish(){let e=this.updatingObservers;for(let t=0;t{},()=>`Setting ${this.debugName}`));try{let r=this._value;this._setValue(e),Du()?.handleObservableChanged(this,{oldValue:r,newValue:e,change:i,didChange:!0,hadValue:!0});for(let s of this.observers)t.updateObserver(s,this),s.handleChange(this,i)}finally{o&&o.finish()}}toString(){return`${this.debugName}: ${this._value}`}_setValue(e){this._value=e}};Aae=class extends mI{_setValue(e){this._value!==e&&(this._value&&this._value.dispose(),this._value=e)}dispose(){this._value?.dispose()}}});function Pe(n,e){return e!==void 0?new mb(new Cr(n,void 0,e),e,void 0,void 0,void 0,Bl):new mb(new Cr(void 0,void 0,n),n,void 0,void 0,void 0,Bl)}function lg(n,e,t){return new Mae(new Cr(n,void 0,e),e,void 0,void 0,void 0,Bl,t)}function As(n,e){return new mb(new Cr(n.owner,n.debugName,n.debugReferenceFn),e,void 0,void 0,n.onLastObserverRemoved,n.equalsFn??Bl)}function OM(n,e){return new mb(new Cr(n.owner,n.debugName,void 0),e,n.createEmptyChangeSummary,n.handleChange,void 0,n.equalityComparer??Bl)}function hc(n,e){let t,i;e===void 0?(t=n,i=void 0):(i=n,t=e);let o=new H;return new mb(new Cr(i,void 0,t),r=>(o.clear(),t(r,o)),void 0,void 0,()=>o.dispose(),Bl)}function Sr(n,e){let t,i;e===void 0?(t=n,i=void 0):(i=n,t=e);let o;return new mb(new Cr(i,void 0,t),r=>{o?o.clear():o=new H;let s=t(r);return s&&o.add(s),s},void 0,void 0,()=>{o&&(o.dispose(),o=void 0)},Bl)}var mb,Mae,Yc=k(()=>{bf();rg();j();Lf();hI();pI();NPe(As);mb=class extends Cp{get debugName(){return this._debugNameData.getDebugName(this)??"(anonymous)"}constructor(e,t,i,o,r=void 0,s){super(),this._debugNameData=e,this._computeFn=t,this.createChangeSummary=i,this._handleChange=o,this._handleLastObserverRemoved=r,this._equalityComparator=s,this.state=0,this.value=void 0,this.updateCount=0,this.dependencies=new Set,this.dependenciesToBeRemoved=new Set,this.changeSummary=void 0,this.changeSummary=this.createChangeSummary?.(),Du()?.handleDerivedCreated(this)}onLastObserverRemoved(){this.state=0,this.value=void 0;for(let e of this.dependencies)e.removeObserver(this);this.dependencies.clear(),this._handleLastObserverRemoved?.()}get(){if(this.observers.size===0){let e=this._computeFn(this,this.createChangeSummary?.());return this.onLastObserverRemoved(),e}else{do{if(this.state===1){for(let e of this.dependencies)if(e.reportChanges(),this.state===2)break}this.state===1&&(this.state=3),this._recomputeIfNeeded()}while(this.state!==3);return this.value}}_recomputeIfNeeded(){if(this.state===3)return;let e=this.dependenciesToBeRemoved;this.dependenciesToBeRemoved=this.dependencies,this.dependencies=e;let t=this.state!==0,i=this.value;this.state=3;let o=this.changeSummary;this.changeSummary=this.createChangeSummary?.();try{this.value=this._computeFn(this,o)}finally{for(let s of this.dependenciesToBeRemoved)s.removeObserver(this);this.dependenciesToBeRemoved.clear()}let r=t&&!this._equalityComparator(i,this.value);if(Du()?.handleDerivedRecomputed(this,{oldValue:i,newValue:this.value,change:void 0,didChange:r,hadValue:t}),r)for(let s of this.observers)s.handleChange(this,void 0)}toString(){return`LazyDerived<${this.debugName}>`}beginUpdate(e){this.updateCount++;let t=this.updateCount===1;if(this.state===3&&(this.state=1,!t))for(let i of this.observers)i.handlePossibleChange(this);if(t)for(let i of this.observers)i.beginUpdate(this)}endUpdate(e){if(this.updateCount--,this.updateCount===0){let t=[...this.observers];for(let i of t)i.endUpdate(this)}_f(()=>this.updateCount>=0)}handlePossibleChange(e){if(this.state===3&&this.dependencies.has(e)&&!this.dependenciesToBeRemoved.has(e)){this.state=1;for(let t of this.observers)t.handlePossibleChange(this)}}handleChange(e,t){if(this.dependencies.has(e)&&!this.dependenciesToBeRemoved.has(e)){let i=this._handleChange?this._handleChange({changedObservable:e,change:t,didChange:r=>r===e},this.changeSummary):!0,o=this.state===3;if(i&&(this.state===1||o)&&(this.state=2,o))for(let r of this.observers)r.handlePossibleChange(this)}}readObservable(e){e.addObserver(this);let t=e.get();return this.dependencies.add(e),this.dependenciesToBeRemoved.delete(e),t}addObserver(e){let t=!this.observers.has(e)&&this.updateCount>0;super.addObserver(e),t&&e.beginUpdate(this)}removeObserver(e){let t=this.observers.has(e)&&this.updateCount>0;super.removeObserver(e),t&&e.endUpdate(this)}},Mae=class extends mb{constructor(e,t,i,o,r=void 0,s,a){super(e,t,i,o,r,s),this.set=a}}});function He(n){return new gI(new Cr(void 0,void 0,n),n,void 0,void 0)}function cg(n,e){return new gI(new Cr(n.owner,n.debugName,n.debugReferenceFn??e),e,void 0,void 0)}function gb(n,e){return new gI(new Cr(n.owner,n.debugName,n.debugReferenceFn??e),e,n.createEmptyChangeSummary,n.handleChange)}function Pae(n,e){let t=new H,i=gb({owner:n.owner,debugName:n.debugName,debugReferenceFn:n.debugReferenceFn??e,createEmptyChangeSummary:n.createEmptyChangeSummary,handleChange:n.handleChange},(o,r)=>{t.clear(),e(o,r,t)});return ge(()=>{i.dispose(),t.dispose()})}function To(n){let e=new H,t=cg({owner:void 0,debugName:void 0,debugReferenceFn:n},i=>{e.clear(),n(i,e)});return ge(()=>{t.dispose(),e.dispose()})}var gI,Oae=k(()=>{bf();j();hI();pI();gI=class{get debugName(){return this._debugNameData.getDebugName(this)??"(anonymous)"}constructor(e,t,i,o){this._debugNameData=e,this._runFn=t,this.createChangeSummary=i,this._handleChange=o,this.state=2,this.updateCount=0,this.disposed=!1,this.dependencies=new Set,this.dependenciesToBeRemoved=new Set,this.changeSummary=this.createChangeSummary?.(),Du()?.handleAutorunCreated(this),this._runIfNeeded(),g1(this)}dispose(){this.disposed=!0;for(let e of this.dependencies)e.removeObserver(this);this.dependencies.clear(),_1(this)}_runIfNeeded(){if(this.state===3)return;let e=this.dependenciesToBeRemoved;this.dependenciesToBeRemoved=this.dependencies,this.dependencies=e,this.state=3;let t=this.disposed;try{if(!t){Du()?.handleAutorunTriggered(this);let i=this.changeSummary;this.changeSummary=this.createChangeSummary?.(),this._runFn(this,i)}}finally{t||Du()?.handleAutorunFinished(this);for(let i of this.dependenciesToBeRemoved)i.removeObserver(this);this.dependenciesToBeRemoved.clear()}}toString(){return`Autorun<${this.debugName}>`}beginUpdate(){this.state===3&&(this.state=1),this.updateCount++}endUpdate(){if(this.updateCount===1)do{if(this.state===1){this.state=3;for(let e of this.dependencies)if(e.reportChanges(),this.state===2)break}this._runIfNeeded()}while(this.state!==3);this.updateCount--,_f(()=>this.updateCount>=0)}handlePossibleChange(e){this.state===3&&this.dependencies.has(e)&&!this.dependenciesToBeRemoved.has(e)&&(this.state=1)}handleChange(e,t){this.dependencies.has(e)&&!this.dependenciesToBeRemoved.has(e)&&(!this._handleChange||this._handleChange({changedObservable:e,change:t,didChange:o=>o===e},this.changeSummary))&&(this.state=2)}readObservable(e){if(this.disposed)return e.get();e.addObserver(this);let t=e.get();return this.dependencies.add(e),this.dependenciesToBeRemoved.delete(e),t}};(function(n){n.Observer=gI})(He||(He={}))});function Ms(n){return new Fae(n)}function Kt(...n){let e,t,i;return n.length===3?[e,t,i]=n:[t,i]=n,new dg(new Cr(e,void 0,i),t,i,()=>dg.globalTransaction,Bl)}function RPe(n,e,t){return new dg(new Cr(n.owner,n.debugName,n.debugReferenceFn??t),e,t,()=>dg.globalTransaction,n.equalsFn??Bl)}function Wo(n,e){return new Bae(n,e)}function Rh(n){return typeof n=="string"?new Y7(n):new Y7(void 0,n)}function APe(n){let e=new Z7(!1,void 0);return n.addObserver(e),ge(()=>{n.removeObserver(e)})}function If(n,e){let t=new Z7(!0,e);return n.addObserver(t),e?e(n.get()):n.reportChanges(),ge(()=>{n.removeObserver(t)})}function ug(n,e){let t;return As({owner:n,debugReferenceFn:e},o=>(t=e(o,t),t))}function MPe(n,e,t,i){let o=new X7(t,i);return As({debugReferenceFn:t,owner:n,onLastObserverRemoved:()=>{o.dispose(),o=new X7(t)}},s=>(o.setItems(e.read(s)),o.getItems()))}function PPe(n,e){return ug(n,(t,i)=>i??e(t))}var Fae,dg,Bae,Y7,Z7,X7,FM=k(()=>{Ie();j();Lf();hI();Yc();pI();rg();Fae=class extends PM{constructor(e){super(),this.value=e}get debugName(){return this.toString()}get(){return this.value}addObserver(e){}removeObserver(e){}toString(){return`Const: ${this.value}`}};dg=class extends Cp{constructor(e,t,i,o,r){super(),this._debugNameData=e,this.event=t,this._getValue=i,this._getTransaction=o,this._equalityComparator=r,this.hasValue=!1,this.handleEvent=s=>{let a=this._getValue(s),l=this.value,c=!this.hasValue||!this._equalityComparator(l,a),d=!1;c&&(this.value=a,this.hasValue&&(d=!0,Nh(this._getTransaction(),u=>{Du()?.handleFromEventObservableTriggered(this,{oldValue:l,newValue:a,change:void 0,didChange:c,hadValue:this.hasValue});for(let h of this.observers)u.updateObserver(h,this),h.handleChange(this,void 0)},()=>{let u=this.getDebugName();return"Event fired"+(u?`: ${u}`:"")})),this.hasValue=!0),d||Du()?.handleFromEventObservableTriggered(this,{oldValue:l,newValue:a,change:void 0,didChange:c,hadValue:this.hasValue})}}getDebugName(){return this._debugNameData.getDebugName(this)}get debugName(){let e=this.getDebugName();return"From Event"+(e?`: ${e}`:"")}onFirstObserverAdded(){this.subscription=this.event(this.handleEvent)}onLastObserverRemoved(){this.subscription.dispose(),this.subscription=void 0,this.hasValue=!1,this.value=void 0}get(){return this.subscription?(this.hasValue||this.handleEvent(void 0),this.value):this._getValue(void 0)}};(function(n){n.Observer=dg;function e(t,i){let o=!1;dg.globalTransaction===void 0&&(dg.globalTransaction=t,o=!0);try{i()}finally{o&&(dg.globalTransaction=void 0)}}n.batchEventsGlobally=e})(Kt||(Kt={}));Bae=class extends Cp{constructor(e,t){super(),this.debugName=e,this.event=t,this.handleEvent=()=>{xi(i=>{for(let o of this.observers)i.updateObserver(o,this),o.handleChange(this,void 0)},()=>this.debugName)}}onFirstObserverAdded(){this.subscription=this.event(this.handleEvent)}onLastObserverRemoved(){this.subscription.dispose(),this.subscription=void 0}get(){}};Y7=class extends Cp{get debugName(){return new Cr(this._owner,this._debugName,void 0).getDebugName(this)??"Observable Signal"}toString(){return this.debugName}constructor(e,t){super(),this._debugName=e,this._owner=t}trigger(e,t){if(!e){xi(i=>{this.trigger(i,t)},()=>`Trigger signal ${this.debugName}`);return}for(let i of this.observers)e.updateObserver(i,this),i.handleChange(this,t)}get(){}};DPe(APe);EPe(If);Z7=class{constructor(e,t){this._forceRecompute=e,this._handleValue=t,this._counter=0}beginUpdate(e){this._counter++}endUpdate(e){this._counter--,this._counter===0&&this._forceRecompute&&(this._handleValue?this._handleValue(e.get()):e.reportChanges())}handlePossibleChange(e){}handleChange(e,t){}};X7=class{constructor(e,t){this._map=e,this._keySelector=t,this._cache=new Map,this._items=[]}dispose(){this._cache.forEach(e=>e.store.dispose()),this._cache.clear()}setItems(e){let t=[],i=new Set(this._cache.keys());for(let o of e){let r=this._keySelector?this._keySelector(o):o,s=this._cache.get(r);if(s)i.delete(r);else{let a=new H;s={out:this._map(o,a),store:a},this._cache.set(r,s)}t.push(s.out)}for(let o of i)this._cache.get(o).store.dispose(),this._cache.delete(o);this._items=t}getItems(){return this._items}}});function WM(n,e,t,i){return e||(e=o=>o!=null),new Promise((o,r)=>{let s=!0,a=!1,l=n.map(d=>({isFinished:e(d),error:t?t(d):!1,state:d})),c=He(d=>{let{isFinished:u,error:h,state:f}=l.read(d);(u||h)&&(s?a=!0:c.dispose(),h?r(h===!0?f:h):o(f))});if(i){let d=i.onCancellationRequested(()=>{c.dispose(),d.dispose(),r(new ga)});if(i.isCancellationRequested){c.dispose(),d.dispose(),r(new ga);return}}s=!1,a&&c.dispose()})}var SC,BM,OPe=k(()=>{Oae();Lf();je();SC=class n{static fromFn(e){return new n(e())}constructor(e){this._value=lt(this,void 0),this.promiseResult=this._value,this.promise=e.then(t=>(xi(i=>{this._value.set(new BM(t,void 0),i)}),t),t=>{throw xi(i=>{this._value.set(new BM(void 0,t),i)}),t})}},BM=class{constructor(e,t){this.data=e,this.error=t}}});var Q7,FPe=k(()=>{Lf();Q7=class extends Cp{get debugName(){return this._debugNameData.getDebugName(this)??"LazyObservableValue"}constructor(e,t,i){super(),this._debugNameData=e,this._equalityComparator=i,this._isUpToDate=!0,this._deltas=[],this._updateCounter=0,this._value=t}get(){return this._update(),this._value}_update(){if(!this._isUpToDate)if(this._isUpToDate=!0,this._deltas.length>0){for(let e of this.observers)for(let t of this._deltas)e.handleChange(this,t);this._deltas.length=0}else for(let e of this.observers)e.handleChange(this,void 0)}_beginUpdate(){if(this._updateCounter++,this._updateCounter===1)for(let e of this.observers)e.beginUpdate(this)}_endUpdate(){if(this._updateCounter--,this._updateCounter===0){this._update();let e=[...this.observers];for(let t of e)t.endUpdate(this)}}addObserver(e){let t=!this.observers.has(e)&&this._updateCounter>0;super.addObserver(e),t&&e.beginUpdate(this)}removeObserver(e){let t=this.observers.has(e)&&this._updateCounter>0;super.removeObserver(e),t&&e.endUpdate(this)}set(e,t,i){if(i===void 0&&this._equalityComparator(this._value,e))return;let o;t||(t=o=new sg(()=>{},()=>`Setting ${this.debugName}`));try{if(this._isUpToDate=!1,this._setValue(e),i!==void 0&&this._deltas.push(i),t.updateObserver({beginUpdate:()=>this._beginUpdate(),endUpdate:()=>this._endUpdate(),handleChange:(r,s)=>{},handlePossibleChange:r=>{}},this),this._updateCounter>1)for(let r of this.observers)r.handlePossibleChange(this)}finally{o&&o.finish()}}toString(){return`${this.debugName}: ${this._value}`}_setValue(e){this._value=e}}});function _I(n,e){return n.lazy?new Q7(new Cr(n.owner,n.debugName,void 0),e,n.equalsFn??Bl):new mI(new Cr(n.owner,n.debugName,void 0),e,n.equalsFn??Bl)}var BPe=k(()=>{rg();Lf();hI();FPe()});var $lt,Oi=k(()=>{Lf();Yc();Oae();FM();OPe();BPe();pI();$lt=!1;$lt&&LPe(new q7)});var J7,eW,WPe=k(()=>{Ie();j();xPe();at();Ji();Nd();Oi();J7=class n extends D{static{this.instanceCount=0}constructor(e=!1){super(),this._onDidRequestBasicLanguageFeatures=this._register(new A),this.onDidRequestBasicLanguageFeatures=this._onDidRequestBasicLanguageFeatures.event,this._onDidRequestRichLanguageFeatures=this._register(new A),this.onDidRequestRichLanguageFeatures=this._onDidRequestRichLanguageFeatures.event,this._onDidChange=this._register(new A({leakWarningThreshold:200})),this.onDidChange=this._onDidChange.event,this._requestedBasicLanguages=new Set,this._requestedRichLanguages=new Set,n.instanceCount++,this._registry=this._register(new $7(!0,e)),this.languageIdCodec=this._registry.languageIdCodec,this._register(this._registry.onDidChange(()=>this._onDidChange.fire()))}dispose(){n.instanceCount--,super.dispose()}isRegisteredLanguageId(e){return this._registry.isRegisteredLanguageId(e)}getLanguageIdByLanguageName(e){return this._registry.getLanguageIdByLanguageName(e)}getLanguageIdByMimeType(e){return this._registry.getLanguageIdByMimeType(e)}guessLanguageIdByFilepathOrFirstLine(e,t){let i=this._registry.guessLanguageIdByFilepathOrFirstLine(e,t);return Wk(i,null)}createById(e){return new eW(this.onDidChange,()=>this._createAndGetLanguageIdentifier(e))}createByFilepathOrFirstLine(e,t){return new eW(this.onDidChange,()=>{let i=this.guessLanguageIdByFilepathOrFirstLine(e,t);return this._createAndGetLanguageIdentifier(i)})}_createAndGetLanguageIdentifier(e){return(!e||!this.isRegisteredLanguageId(e))&&(e=Oo),e}requestBasicLanguageFeatures(e){this._requestedBasicLanguages.has(e)||(this._requestedBasicLanguages.add(e),this._onDidRequestBasicLanguageFeatures.fire(e))}requestRichLanguageFeatures(e){this._requestedRichLanguages.has(e)||(this._requestedRichLanguages.add(e),this.requestBasicLanguageFeatures(e),$i.getOrCreate(e),this._onDidRequestRichLanguageFeatures.fire(e))}},eW=class{constructor(e,t){this._value=Kt(this,e,()=>t()),this.onDidChange=ne.fromObservable(this._value)}get languageId(){return this._value.get()}}});var cw,tW=k(()=>{Ex();cw={RESOURCES:"ResourceURLs",DOWNLOAD_URL:"DownloadURL",FILES:"Files",TEXT:An.text,INTERNAL_URI_LIST:"application/vnd.code.uri-list"}});function HPe(n){iW=n}function lo(n){return n==="element"?Klt.value:qlt.value}function Ef(){return iW("element",!0)}var jlt,iW,qlt,Klt,Ps=k(()=>{cp();jlt=()=>({get delay(){return-1},dispose:()=>{},showHover:()=>{}}),iW=jlt,qlt=new or(()=>iW("mouse",!1)),Klt=new or(()=>iW("element",!1))});function VPe(n){zPe=n}function Os(){return zPe}var zPe,Ah=k(()=>{zPe={showHover:()=>{},hideHover:()=>{},showAndFocusLastHover:()=>{},setupManagedHover:()=>null,showManagedHover:()=>{}}});var nW,UPe=k(()=>{nW=class{constructor(e){this.spliceables=e}splice(e,t,i){this.spliceables.forEach(o=>o.splice(e,t,i))}}});var Wae=k(()=>{});var hg,$Pe=k(()=>{hg=class extends Error{constructor(e,t){super(`ListError [${e}] ${t}`)}}});function jPe(n,e){let t=[];for(let i of e){if(n.start>=i.range.end)continue;if(n.ende.concat(t),[]))}var oW,qPe=k(()=>{yM();oW=class{get paddingTop(){return this._paddingTop}set paddingTop(e){this._size=this._size+e-this._paddingTop,this._paddingTop=e}constructor(e){this.groups=[],this._size=0,this._paddingTop=0,this._paddingTop=e??0,this._size=this._paddingTop}splice(e,t,i=[]){let o=i.length-t,r=jPe({start:0,end:e},this.groups),s=jPe({start:e+t,end:Number.POSITIVE_INFINITY},this.groups).map(l=>({range:rW(l.range,o),size:l.size})),a=i.map((l,c)=>({range:{start:e+c,end:e+c+1},size:l.size}));this.groups=Ylt(r,a,s),this._size=this._paddingTop+this.groups.reduce((l,c)=>l+c.size*(c.range.end-c.range.start),0)}get count(){let e=this.groups.length;return e?this.groups[e-1].range.end:0}get size(){return this._size}indexAt(e){if(e<0)return-1;if(e{ke();sW=class{constructor(e){this.renderers=e,this.cache=new Map,this.transactionNodesPendingRemoval=new Set,this.inTransaction=!1}alloc(e){let t=this.getTemplateCache(e).pop(),i=!1;if(t)i=this.transactionNodesPendingRemoval.has(t.domNode),i&&this.transactionNodesPendingRemoval.delete(t.domNode);else{let o=J(".monaco-list-row"),s=this.getRenderer(e).renderTemplate(o);t={domNode:o,templateId:e,templateData:s}}return{row:t,isReusingConnectedDomNode:i}}release(e){e&&this.releaseRow(e)}transact(e){if(this.inTransaction)throw new Error("Already in transaction");this.inTransaction=!0;try{e()}finally{for(let t of this.transactionNodesPendingRemoval)this.doRemoveNode(t);this.transactionNodesPendingRemoval.clear(),this.inTransaction=!1}}releaseRow(e){let{domNode:t,templateId:i}=e;t&&(this.inTransaction?this.transactionNodesPendingRemoval.add(t):this.doRemoveNode(t)),this.getTemplateCache(i).push(e)}doRemoveNode(e){e.classList.remove("scrolling"),e.remove()}getTemplateCache(e){let t=this.cache.get(e);return t||(t=[],this.cache.set(e,t)),t}dispose(){this.cache.forEach((e,t)=>{for(let i of e)this.getRenderer(t).disposeTemplate(i.templateData),i.templateData=null}),this.cache.clear(),this.transactionNodesPendingRemoval.clear()}getRenderer(e){let t=this.renderers.get(e);if(!t)throw new Error(`No renderer found for ${e}`);return t}}});function Zlt(n,e){return Array.isArray(n)&&Array.isArray(e)?oi(n,e):n===e}var bb,kC,fg,_b,Hae,zae,Vae,Mh,aW=k(()=>{tW();ke();Sf();Pd();Eh();at();ft();Yx();Ie();j();yM();GL();qPe();KPe();je();eC();bb=function(n,e,t,i){var o=arguments.length,r=o<3?e:i===null?i=Object.getOwnPropertyDescriptor(e,t):i,s;if(typeof Reflect=="object"&&typeof Reflect.decorate=="function")r=Reflect.decorate(n,e,t,i);else for(var a=n.length-1;a>=0;a--)(s=n[a])&&(r=(o<3?s(r):o>3?s(e,t,r):s(e,t))||r);return o>3&&r&&Object.defineProperty(e,t,r),r},kC={CurrentDragAndDropData:void 0},fg={useShadows:!0,verticalScrollMode:1,setRowLineHeight:!0,setRowHeight:!0,supportDynamicHeights:!1,dnd:{getDragElements(n){return[n]},getDragURI(){return null},onDragStart(){},onDragOver(){return!1},drop(){},dispose(){}},horizontalScrolling:!1,transformOptimization:!0,alwaysConsumeMouseWheel:!0},_b=class{constructor(e){this.elements=e}update(){}getData(){return this.elements}},Hae=class{constructor(e){this.elements=e}update(){}getData(){return this.elements}},zae=class{constructor(){this.types=[],this.files=[]}update(e){if(e.types&&this.types.splice(0,this.types.length,...e.types),e.files){this.files.splice(0,this.files.length);for(let t=0;to,e?.getPosInSet?this.getPosInSet=e.getPosInSet.bind(e):this.getPosInSet=(t,i)=>i+1,e?.getRole?this.getRole=e.getRole.bind(e):this.getRole=t=>"listitem",e?.isChecked?this.isChecked=e.isChecked.bind(e):this.isChecked=t=>{}}},Mh=class n{static{this.InstanceCount=0}get contentHeight(){return this.rangeMap.size}get onDidScroll(){return this.scrollableElement.onScroll}get scrollableElementDomNode(){return this.scrollableElement.getDomNode()}get horizontalScrolling(){return this._horizontalScrolling}set horizontalScrolling(e){if(e!==this._horizontalScrolling){if(e&&this.supportDynamicHeights)throw new Error("Horizontal scrolling and dynamic heights not supported simultaneously");if(this._horizontalScrolling=e,this.domNode.classList.toggle("horizontal-scrolling",this._horizontalScrolling),this._horizontalScrolling){for(let t of this.items)this.measureItemWidth(t);this.updateScrollWidth(),this.scrollableElement.setScrollDimensions({width:PB(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=""}}constructor(e,t,i,o=fg){if(this.virtualDelegate=t,this.domId=`list_id_${++n.InstanceCount}`,this.renderers=new Map,this.renderWidth=0,this._scrollHeight=0,this.scrollableElementUpdateDisposable=null,this.scrollableElementWidthDelayer=new gr(50),this.splicing=!1,this.dragOverAnimationStopDisposable=D.None,this.dragOverMouseY=0,this.canDrop=!1,this.currentDragFeedbackDisposable=D.None,this.onDragLeaveTimeout=D.None,this.disposables=new H,this._onDidChangeContentHeight=new A,this._onDidChangeContentWidth=new A,this.onDidChangeContentHeight=ne.latch(this._onDidChangeContentHeight.event,void 0,this.disposables),this._horizontalScrolling=!1,o.horizontalScrolling&&o.supportDynamicHeights)throw new Error("Horizontal scrolling and dynamic heights not supported simultaneously");this.items=[],this.itemId=0,this.rangeMap=this.createRangeMap(o.paddingTop??0);for(let s of i)this.renderers.set(s.templateId,s);this.cache=this.disposables.add(new sW(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 o.mouseSupport=="boolean"?o.mouseSupport:!0),this._horizontalScrolling=o.horizontalScrolling??fg.horizontalScrolling,this.domNode.classList.toggle("horizontal-scrolling",this._horizontalScrolling),this.paddingBottom=typeof o.paddingBottom>"u"?0:o.paddingBottom,this.accessibilityProvider=new Vae(o.accessibilityProvider),this.rowsContainer=document.createElement("div"),this.rowsContainer.className="monaco-list-rows",(o.transformOptimization??fg.transformOptimization)&&(this.rowsContainer.style.transform="translate3d(0px, 0px, 0px)",this.rowsContainer.style.overflow="hidden",this.rowsContainer.style.contain="strict"),this.disposables.add(so.addTarget(this.rowsContainer)),this.scrollable=this.disposables.add(new Ih({forceIntegerValues:!0,smoothScrollDuration:o.smoothScrolling??!1?125:0,scheduleAtNextAnimationFrame:s=>us(Me(this.domNode),s)})),this.scrollableElement=this.disposables.add(new Ym(this.rowsContainer,{alwaysConsumeMouseWheel:o.alwaysConsumeMouseWheel??fg.alwaysConsumeMouseWheel,horizontal:1,vertical:o.verticalScrollMode??fg.verticalScrollMode,useShadows:o.useShadows??fg.useShadows,mouseWheelScrollSensitivity:o.mouseWheelScrollSensitivity,fastScrollSensitivity:o.fastScrollSensitivity,scrollByPage:o.scrollByPage},this.scrollable)),this.domNode.appendChild(this.scrollableElement.getDomNode()),e.appendChild(this.domNode),this.scrollableElement.onScroll(this.onScroll,this,this.disposables),this.disposables.add(U(this.rowsContainer,Mi.Change,s=>this.onTouchChange(s))),this.disposables.add(U(this.scrollableElement.getDomNode(),"scroll",s=>s.target.scrollTop=0)),this.disposables.add(U(this.domNode,"dragover",s=>this.onDragOver(this.toDragEvent(s)))),this.disposables.add(U(this.domNode,"drop",s=>this.onDrop(this.toDragEvent(s)))),this.disposables.add(U(this.domNode,"dragleave",s=>this.onDragLeave(this.toDragEvent(s)))),this.disposables.add(U(this.domNode,"dragend",s=>this.onDragEnd(s))),this.setRowLineHeight=o.setRowLineHeight??fg.setRowLineHeight,this.setRowHeight=o.setRowHeight??fg.setRowHeight,this.supportDynamicHeights=o.supportDynamicHeights??fg.supportDynamicHeights,this.dnd=o.dnd??this.disposables.add(fg.dnd),this.layout(o.initialSize?.height,o.initialSize?.width)}updateOptions(e){e.paddingBottom!==void 0&&(this.paddingBottom=e.paddingBottom,this.scrollableElement.setScrollDimensions({scrollHeight:this.scrollHeight})),e.smoothScrolling!==void 0&&this.scrollable.setSmoothScrollDuration(e.smoothScrolling?125:0),e.horizontalScrolling!==void 0&&(this.horizontalScrolling=e.horizontalScrolling);let t;if(e.scrollByPage!==void 0&&(t={...t??{},scrollByPage:e.scrollByPage}),e.mouseWheelScrollSensitivity!==void 0&&(t={...t??{},mouseWheelScrollSensitivity:e.mouseWheelScrollSensitivity}),e.fastScrollSensitivity!==void 0&&(t={...t??{},fastScrollSensitivity:e.fastScrollSensitivity}),t&&this.scrollableElement.updateOptions(t),e.paddingTop!==void 0&&e.paddingTop!==this.rangeMap.paddingTop){let i=this.getRenderRange(this.lastRenderTop,this.lastRenderHeight),o=e.paddingTop-this.rangeMap.paddingTop;this.rangeMap.paddingTop=e.paddingTop,this.render(i,Math.max(0,this.lastRenderTop+o),this.lastRenderHeight,void 0,void 0,!0),this.setScrollTop(this.lastRenderTop),this.eventuallyUpdateScrollDimensions(),this.supportDynamicHeights&&this._rerender(this.lastRenderTop,this.lastRenderHeight)}}createRangeMap(e){return new oW(e)}splice(e,t,i=[]){if(this.splicing)throw new Error("Can't run recursive splices.");this.splicing=!0;try{return this._splice(e,t,i)}finally{this.splicing=!1,this._onDidChangeContentHeight.fire(this.contentHeight)}}_splice(e,t,i=[]){let o=this.getRenderRange(this.lastRenderTop,this.lastRenderHeight),r={start:e,end:e+t},s=ms.intersect(o,r),a=new Map;for(let y=s.end-1;y>=s.start;y--){let C=this.items[y];if(C.dragStartDisposable.dispose(),C.checkedDisposable.dispose(),C.row){let L=a.get(C.templateId);L||(L=[],a.set(C.templateId,L));let E=this.renderers.get(C.templateId);E&&E.disposeElement&&E.disposeElement(C.element,y,C.row.templateData,C.size),L.unshift(C.row)}C.row=null,C.stale=!0}let l={start:e+t,end:this.items.length},c=ms.intersect(l,o),d=ms.relativeComplement(l,o),u=i.map(y=>({id:String(this.itemId++),element:y,templateId:this.virtualDelegate.getTemplateId(y),size:this.virtualDelegate.getHeight(y),width:void 0,hasDynamicHeight:!!this.virtualDelegate.hasDynamicHeight&&this.virtualDelegate.hasDynamicHeight(y),lastDynamicHeightWidth:void 0,row:null,uri:void 0,dropTarget:!1,dragStartDisposable:D.None,checkedDisposable:D.None,stale:!1})),h;e===0&&t>=this.items.length?(this.rangeMap=this.createRangeMap(this.rangeMap.paddingTop),this.rangeMap.splice(0,0,u),h=this.items,this.items=u):(this.rangeMap.splice(e,t,u),h=this.items.splice(e,t,...u));let f=i.length-t,p=this.getRenderRange(this.lastRenderTop,this.lastRenderHeight),g=rW(c,f),_=ms.intersect(p,g);for(let y=_.start;y<_.end;y++)this.updateItemInDOM(this.items[y],y);let b=ms.relativeComplement(g,p);for(let y of b)for(let C=y.start;CrW(y,f)),w=[{start:e,end:e+i.length},...v].map(y=>ms.intersect(p,y)).reverse();for(let y of w)for(let C=y.end-1;C>=y.start;C--){let L=this.items[C],N=a.get(L.templateId)?.pop();this.insertItemInDOM(C,N)}for(let y of a.values())for(let C of y)this.cache.release(C);return this.eventuallyUpdateScrollDimensions(),this.supportDynamicHeights&&this._rerender(this.scrollTop,this.renderHeight),h.map(y=>y.element)}eventuallyUpdateScrollDimensions(){this._scrollHeight=this.contentHeight,this.rowsContainer.style.height=`${this._scrollHeight}px`,this.scrollableElementUpdateDisposable||(this.scrollableElementUpdateDisposable=us(Me(this.domNode),()=>{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 e=0;for(let t of this.items)typeof t.width<"u"&&(e=Math.max(e,t.width));this.scrollWidth=e,this.scrollableElement.setScrollDimensions({scrollWidth:e===0?0:e+10}),this._onDidChangeContentWidth.fire(this.scrollWidth)}rerender(){if(this.supportDynamicHeights){for(let e of this.items)e.lastDynamicHeightWidth=void 0;this._rerender(this.lastRenderTop,this.lastRenderHeight)}}get length(){return this.items.length}get renderHeight(){return this.scrollableElement.getScrollDimensions().height}get firstVisibleIndex(){return this.getRenderRange(this.lastRenderTop,this.lastRenderHeight).start}element(e){return this.items[e].element}indexOf(e){return this.items.findIndex(t=>t.element===e)}domElement(e){let t=this.items[e].row;return t&&t.domNode}elementHeight(e){return this.items[e].size}elementTop(e){return this.rangeMap.positionAt(e)}indexAt(e){return this.rangeMap.indexAt(e)}indexAfter(e){return this.rangeMap.indexAfter(e)}layout(e,t){let i={height:typeof e=="number"?e:_De(this.domNode)};this.scrollableElementUpdateDisposable&&(this.scrollableElementUpdateDisposable.dispose(),this.scrollableElementUpdateDisposable=null,i.scrollHeight=this.scrollHeight),this.scrollableElement.setScrollDimensions(i),typeof t<"u"&&(this.renderWidth=t,this.supportDynamicHeights&&this._rerender(this.scrollTop,this.renderHeight)),this.horizontalScrolling&&this.scrollableElement.setScrollDimensions({width:typeof t=="number"?t:PB(this.domNode)})}render(e,t,i,o,r,s=!1){let a=this.getRenderRange(t,i),l=ms.relativeComplement(a,e).reverse(),c=ms.relativeComplement(e,a);if(s){let d=ms.intersect(e,a);for(let u=d.start;u{for(let d of c)for(let u=d.start;u=d.start;u--)this.insertItemInDOM(u)}),o!==void 0&&(this.rowsContainer.style.left=`-${o}px`),this.rowsContainer.style.top=`-${t}px`,this.horizontalScrolling&&r!==void 0&&(this.rowsContainer.style.width=`${Math.max(r,this.renderWidth)}px`),this.lastRenderTop=t,this.lastRenderHeight=i}insertItemInDOM(e,t){let i=this.items[e];if(!i.row)if(t)i.row=t,i.stale=!0;else{let l=this.cache.alloc(i.templateId);i.row=l.row,i.stale||=l.isReusingConnectedDomNode}let o=this.accessibilityProvider.getRole(i.element)||"listitem";i.row.domNode.setAttribute("role",o);let r=this.accessibilityProvider.isChecked(i.element);if(typeof r=="boolean")i.row.domNode.setAttribute("aria-checked",String(!!r));else if(r){let l=c=>i.row.domNode.setAttribute("aria-checked",String(!!c));l(r.value),i.checkedDisposable=r.onDidChange(()=>l(r.value))}if(i.stale||!i.row.domNode.parentElement){let l=this.items.at(e+1)?.row?.domNode??null;(i.row.domNode.parentElement!==this.rowsContainer||i.row.domNode.nextElementSibling!==l)&&this.rowsContainer.insertBefore(i.row.domNode,l),i.stale=!1}this.updateItemInDOM(i,e);let s=this.renderers.get(i.templateId);if(!s)throw new Error(`No renderer found for template id ${i.templateId}`);s?.renderElement(i.element,e,i.row.templateData,i.size);let a=this.dnd.getDragURI(i.element);i.dragStartDisposable.dispose(),i.row.domNode.draggable=!!a,a&&(i.dragStartDisposable=U(i.row.domNode,"dragstart",l=>this.onDragStart(i.element,a,l))),this.horizontalScrolling&&(this.measureItemWidth(i),this.eventuallyUpdateScrollWidth())}measureItemWidth(e){if(!e.row||!e.row.domNode)return;e.row.domNode.style.width="fit-content",e.width=PB(e.row.domNode);let t=Me(e.row.domNode).getComputedStyle(e.row.domNode);t.paddingLeft&&(e.width+=parseFloat(t.paddingLeft)),t.paddingRight&&(e.width+=parseFloat(t.paddingRight)),e.row.domNode.style.width=""}updateItemInDOM(e,t){e.row.domNode.style.top=`${this.elementTop(t)}px`,this.setRowHeight&&(e.row.domNode.style.height=`${e.size}px`),this.setRowLineHeight&&(e.row.domNode.style.lineHeight=`${e.size}px`),e.row.domNode.setAttribute("data-index",`${t}`),e.row.domNode.setAttribute("data-last-element",t===this.length-1?"true":"false"),e.row.domNode.setAttribute("data-parity",t%2===0?"even":"odd"),e.row.domNode.setAttribute("aria-setsize",String(this.accessibilityProvider.getSetSize(e.element,t,this.length))),e.row.domNode.setAttribute("aria-posinset",String(this.accessibilityProvider.getPosInSet(e.element,t))),e.row.domNode.setAttribute("id",this.getElementDomId(t)),e.row.domNode.classList.toggle("drop-target",e.dropTarget)}removeItemFromDOM(e){let t=this.items[e];if(t.dragStartDisposable.dispose(),t.checkedDisposable.dispose(),t.row){let i=this.renderers.get(t.templateId);i&&i.disposeElement&&i.disposeElement(t.element,e,t.row.templateData,t.size),this.cache.release(t.row),t.row=null}this.horizontalScrolling&&this.eventuallyUpdateScrollWidth()}getScrollTop(){return this.scrollableElement.getScrollPosition().scrollTop}setScrollTop(e,t){this.scrollableElementUpdateDisposable&&(this.scrollableElementUpdateDisposable.dispose(),this.scrollableElementUpdateDisposable=null,this.scrollableElement.setScrollDimensions({scrollHeight:this.scrollHeight})),this.scrollableElement.setScrollPosition({scrollTop:e,reuseAnimation:t})}get scrollTop(){return this.getScrollTop()}set scrollTop(e){this.setScrollTop(e)}get scrollHeight(){return this._scrollHeight+(this.horizontalScrolling?10:0)+this.paddingBottom}get onMouseClick(){return ne.map(this.disposables.add(new Mt(this.domNode,"click")).event,e=>this.toMouseEvent(e),this.disposables)}get onMouseDblClick(){return ne.map(this.disposables.add(new Mt(this.domNode,"dblclick")).event,e=>this.toMouseEvent(e),this.disposables)}get onMouseMiddleClick(){return ne.filter(ne.map(this.disposables.add(new Mt(this.domNode,"auxclick")).event,e=>this.toMouseEvent(e),this.disposables),e=>e.browserEvent.button===1,this.disposables)}get onMouseDown(){return ne.map(this.disposables.add(new Mt(this.domNode,"mousedown")).event,e=>this.toMouseEvent(e),this.disposables)}get onMouseOver(){return ne.map(this.disposables.add(new Mt(this.domNode,"mouseover")).event,e=>this.toMouseEvent(e),this.disposables)}get onMouseOut(){return ne.map(this.disposables.add(new Mt(this.domNode,"mouseout")).event,e=>this.toMouseEvent(e),this.disposables)}get onContextMenu(){return ne.any(ne.map(this.disposables.add(new Mt(this.domNode,"contextmenu")).event,e=>this.toMouseEvent(e),this.disposables),ne.map(this.disposables.add(new Mt(this.domNode,Mi.Contextmenu)).event,e=>this.toGestureEvent(e),this.disposables))}get onTouchStart(){return ne.map(this.disposables.add(new Mt(this.domNode,"touchstart")).event,e=>this.toTouchEvent(e),this.disposables)}get onTap(){return ne.map(this.disposables.add(new Mt(this.rowsContainer,Mi.Tap)).event,e=>this.toGestureEvent(e),this.disposables)}toMouseEvent(e){let t=this.getItemIndexFromEventTarget(e.target||null),i=typeof t>"u"?void 0:this.items[t],o=i&&i.element;return{browserEvent:e,index:t,element:o}}toTouchEvent(e){let t=this.getItemIndexFromEventTarget(e.target||null),i=typeof t>"u"?void 0:this.items[t],o=i&&i.element;return{browserEvent:e,index:t,element:o}}toGestureEvent(e){let t=this.getItemIndexFromEventTarget(e.initialTarget||null),i=typeof t>"u"?void 0:this.items[t],o=i&&i.element;return{browserEvent:e,index:t,element:o}}toDragEvent(e){let t=this.getItemIndexFromEventTarget(e.target||null),i=typeof t>"u"?void 0:this.items[t],o=i&&i.element,r=this.getTargetSector(e,t);return{browserEvent:e,index:t,element:o,sector:r}}onScroll(e){try{let t=this.getRenderRange(this.lastRenderTop,this.lastRenderHeight);this.render(t,e.scrollTop,e.height,e.scrollLeft,e.scrollWidth),this.supportDynamicHeights&&this._rerender(e.scrollTop,e.height,e.inSmoothScrolling)}catch(t){throw console.error("Got bad scroll event:",e),t}}onTouchChange(e){e.preventDefault(),e.stopPropagation(),this.scrollTop-=e.translationY}onDragStart(e,t,i){if(!i.dataTransfer)return;let o=this.dnd.getDragElements(e);if(i.dataTransfer.effectAllowed="copyMove",i.dataTransfer.setData(cw.TEXT,t),i.dataTransfer.setDragImage){let r;this.dnd.getDragLabel&&(r=this.dnd.getDragLabel(o,i)),typeof r>"u"&&(r=String(o.length));let s=J(".monaco-drag-image");s.textContent=r,(c=>{for(;c&&!c.classList.contains("monaco-workbench");)c=c.parentElement;return c||this.domNode.ownerDocument})(this.domNode).appendChild(s),i.dataTransfer.setDragImage(s,-10,-10),setTimeout(()=>s.remove(),0)}this.domNode.classList.add("dragging"),this.currentDragData=new _b(o),kC.CurrentDragAndDropData=new Hae(o),this.dnd.onDragStart?.(this.currentDragData,i)}onDragOver(e){if(e.browserEvent.preventDefault(),this.onDragLeaveTimeout.dispose(),kC.CurrentDragAndDropData&&kC.CurrentDragAndDropData.getData()==="vscode-ui"||(this.setupDragAndDropScrollTopAnimation(e.browserEvent),!e.browserEvent.dataTransfer))return!1;if(!this.currentDragData)if(kC.CurrentDragAndDropData)this.currentDragData=kC.CurrentDragAndDropData;else{if(!e.browserEvent.dataTransfer.types)return!1;this.currentDragData=new zae}let t=this.dnd.onDragOver(this.currentDragData,e.element,e.index,e.sector,e.browserEvent);if(this.canDrop=typeof t=="boolean"?t:t.accept,!this.canDrop)return this.currentDragFeedback=void 0,this.currentDragFeedbackDisposable.dispose(),!1;e.browserEvent.dataTransfer.dropEffect=typeof t!="boolean"&&t.effect?.type===0?"copy":"move";let i;typeof t!="boolean"&&t.feedback?i=t.feedback:typeof e.index>"u"?i=[-1]:i=[e.index],i=Ac(i).filter(r=>r>=-1&&rr-s),i=i[0]===-1?[-1]:i;let o=typeof t!="boolean"&&t.effect&&t.effect.position?t.effect.position:"drop-target";if(Zlt(this.currentDragFeedback,i)&&this.currentDragFeedbackPosition===o)return!0;if(this.currentDragFeedback=i,this.currentDragFeedbackPosition=o,this.currentDragFeedbackDisposable.dispose(),i[0]===-1)this.domNode.classList.add(o),this.rowsContainer.classList.add(o),this.currentDragFeedbackDisposable=ge(()=>{this.domNode.classList.remove(o),this.rowsContainer.classList.remove(o)});else{if(i.length>1&&o!=="drop-target")throw new Error("Can't use multiple feedbacks with position different than 'over'");o==="drop-target-after"&&i[0]{for(let r of i){let s=this.items[r];s.dropTarget=!1,s.row?.domNode.classList.remove(o)}})}return!0}onDragLeave(e){this.onDragLeaveTimeout.dispose(),this.onDragLeaveTimeout=gu(()=>this.clearDragOverFeedback(),100,this.disposables),this.currentDragData&&this.dnd.onDragLeave?.(this.currentDragData,e.element,e.index,e.browserEvent)}onDrop(e){if(!this.canDrop)return;let t=this.currentDragData;this.teardownDragAndDropScrollTopAnimation(),this.clearDragOverFeedback(),this.domNode.classList.remove("dragging"),this.currentDragData=void 0,kC.CurrentDragAndDropData=void 0,!(!t||!e.browserEvent.dataTransfer)&&(e.browserEvent.preventDefault(),t.update(e.browserEvent.dataTransfer),this.dnd.drop(t,e.element,e.index,e.sector,e.browserEvent))}onDragEnd(e){this.canDrop=!1,this.teardownDragAndDropScrollTopAnimation(),this.clearDragOverFeedback(),this.domNode.classList.remove("dragging"),this.currentDragData=void 0,kC.CurrentDragAndDropData=void 0,this.dnd.onDragEnd?.(e)}clearDragOverFeedback(){this.currentDragFeedback=void 0,this.currentDragFeedbackPosition=void 0,this.currentDragFeedbackDisposable.dispose(),this.currentDragFeedbackDisposable=D.None}setupDragAndDropScrollTopAnimation(e){if(!this.dragOverAnimationDisposable){let t=AB(this.domNode).top;this.dragOverAnimationDisposable=EDe(Me(this.domNode),this.animateDragAndDropScrollTop.bind(this,t))}this.dragOverAnimationStopDisposable.dispose(),this.dragOverAnimationStopDisposable=gu(()=>{this.dragOverAnimationDisposable&&(this.dragOverAnimationDisposable.dispose(),this.dragOverAnimationDisposable=void 0)},1e3,this.disposables),this.dragOverMouseY=e.pageY}animateDragAndDropScrollTop(e){if(this.dragOverMouseY===void 0)return;let t=this.dragOverMouseY-e,i=this.renderHeight-35;t<35?this.scrollTop+=Math.max(-14,Math.floor(.3*(t-35))):t>i&&(this.scrollTop+=Math.min(14,Math.floor(.3*(t-i))))}teardownDragAndDropScrollTopAnimation(){this.dragOverAnimationStopDisposable.dispose(),this.dragOverAnimationDisposable&&(this.dragOverAnimationDisposable.dispose(),this.dragOverAnimationDisposable=void 0)}getTargetSector(e,t){if(t===void 0)return;let i=e.offsetY/this.items[t].size,o=Math.floor(i/.25);return ps(o,0,3)}getItemIndexFromEventTarget(e){let t=this.scrollableElement.getDomNode(),i=e;for(;(_n(i)||wDe(i))&&i!==this.rowsContainer&&t.contains(i);){let o=i.getAttribute("data-index");if(o){let r=Number(o);if(!isNaN(r))return r}i=i.parentElement}}getRenderRange(e,t){return{start:this.rangeMap.indexAt(e),end:this.rangeMap.indexAfter(e+t-1)}}_rerender(e,t,i){let o=this.getRenderRange(e,t),r,s;e===this.elementTop(o.start)?(r=o.start,s=0):o.end-o.start>1&&(r=o.start+1,s=this.elementTop(r)-e);let a=0;for(;;){let l=this.getRenderRange(e,t),c=!1;for(let d=l.start;d=h.start;f--)this.insertItemInDOM(f);for(let h=l.start;h=0&&n[o]===e-(t-o);)i.push(n[o--]);for(i.reverse(),o=t;o=n.length)t.push(e[o++]);else if(o>=e.length)t.push(n[i++]);else if(n[i]===e[o]){t.push(n[i]),i++,o++;continue}else n[i]=n.length)t.push(e[o++]);else if(o>=e.length)t.push(n[i++]);else if(n[i]===e[o]){i++,o++;continue}else n[i]{ke();Sf();Ks();Pd();Ns();UPe();at();ft();vo();Yx();Ie();Th();j();eC();Bt();yi();Wae();$Pe();aW();pu();Oi();dw=function(n,e,t,i){var o=arguments.length,r=o<3?e:i===null?i=Object.getOwnPropertyDescriptor(e,t):i,s;if(typeof Reflect=="object"&&typeof Reflect.decorate=="function")r=Reflect.decorate(n,e,t,i);else for(var a=n.length-1;a>=0;a--)(s=n[a])&&(r=(o<3?s(r):o>3?s(e,t,r):s(e,t))||r);return o>3&&r&&Object.defineProperty(e,t,r),r},Uae=class{constructor(e){this.trait=e,this.renderedElements=[]}get templateId(){return`template:${this.trait.name}`}renderTemplate(e){return e}renderElement(e,t,i){let o=this.renderedElements.findIndex(r=>r.templateData===i);if(o>=0){let r=this.renderedElements[o];this.trait.unrender(i),r.index=t}else{let r={index:t,templateData:i};this.renderedElements.push(r)}this.trait.renderIndex(t,i)}splice(e,t,i){let o=[];for(let r of this.renderedElements)r.index=e+t&&o.push({index:r.index+i-t,templateData:r.templateData});this.renderedElements=o}renderIndexes(e){for(let{index:t,templateData:i}of this.renderedElements)e.indexOf(t)>-1&&this.trait.renderIndex(t,i)}disposeTemplate(e){let t=this.renderedElements.findIndex(i=>i.templateData===e);t<0||this.renderedElements.splice(t,1)}},xI=class{get name(){return this._trait}get renderer(){return new Uae(this)}constructor(e){this._trait=e,this.indexes=[],this.sortedIndexes=[],this._onChange=new A,this.onChange=this._onChange.event}splice(e,t,i){let o=i.length-t,r=e+t,s=[],a=0;for(;a=r;)s.push(this.sortedIndexes[a++]+o);this.renderer.splice(e,t,i.length),this._set(s,s)}renderIndex(e,t){t.classList.toggle(this._trait,this.contains(e))}unrender(e){e.classList.remove(this._trait)}set(e,t){return this._set(e,[...e].sort(YPe),t)}_set(e,t,i){let o=this.indexes,r=this.sortedIndexes;this.indexes=e,this.sortedIndexes=t;let s=Kae(r,e);return this.renderer.renderIndexes(s),this._onChange.fire({indexes:e,browserEvent:i}),o}get(){return this.indexes}contains(e){return M_(this.sortedIndexes,e,YPe)>=0}dispose(){Yt(this._onChange)}};dw([Hn],xI.prototype,"renderer",null);$ae=class extends xI{constructor(e){super("selected"),this.setAriaSelected=e}renderIndex(e,t){super.renderIndex(e,t),this.setAriaSelected&&(this.contains(e)?t.setAttribute("aria-selected","true"):t.setAttribute("aria-selected","false"))}},HM=class{constructor(e,t,i){this.trait=e,this.view=t,this.identityProvider=i}splice(e,t,i){if(!this.identityProvider)return this.trait.splice(e,t,new Array(i.length).fill(!1));let o=this.trait.get().map(a=>this.identityProvider.getId(this.view.element(a)).toString());if(o.length===0)return this.trait.splice(e,t,new Array(i.length).fill(!1));let r=new Set(o),s=i.map(a=>r.has(this.identityProvider.getId(a).toString()));this.trait.splice(e,t,s)}};lW=class{get onKeyDown(){return ne.chain(this.disposables.add(new Mt(this.view.domNode,"keydown")).event,e=>e.filter(t=>!vb(t.target)).map(t=>new Xt(t)))}constructor(e,t,i){this.list=e,this.view=t,this.disposables=new H,this.multipleSelectionDisposables=new H,this.multipleSelectionSupport=i.multipleSelectionSupport,this.disposables.add(this.onKeyDown(o=>{switch(o.keyCode){case 3:return this.onEnter(o);case 16:return this.onUpArrow(o);case 18:return this.onDownArrow(o);case 11:return this.onPageUpArrow(o);case 12:return this.onPageDownArrow(o);case 9:return this.onEscape(o);case 31:this.multipleSelectionSupport&&(dt?o.metaKey:o.ctrlKey)&&this.onCtrlA(o)}}))}updateOptions(e){e.multipleSelectionSupport!==void 0&&(this.multipleSelectionSupport=e.multipleSelectionSupport)}onEnter(e){e.preventDefault(),e.stopPropagation(),this.list.setSelection(this.list.getFocus(),e.browserEvent)}onUpArrow(e){e.preventDefault(),e.stopPropagation(),this.list.focusPrevious(1,!1,e.browserEvent);let t=this.list.getFocus()[0];this.list.setAnchor(t),this.list.reveal(t),this.view.domNode.focus()}onDownArrow(e){e.preventDefault(),e.stopPropagation(),this.list.focusNext(1,!1,e.browserEvent);let t=this.list.getFocus()[0];this.list.setAnchor(t),this.list.reveal(t),this.view.domNode.focus()}onPageUpArrow(e){e.preventDefault(),e.stopPropagation(),this.list.focusPreviousPage(e.browserEvent);let t=this.list.getFocus()[0];this.list.setAnchor(t),this.list.reveal(t),this.view.domNode.focus()}onPageDownArrow(e){e.preventDefault(),e.stopPropagation(),this.list.focusNextPage(e.browserEvent);let t=this.list.getFocus()[0];this.list.setAnchor(t),this.list.reveal(t),this.view.domNode.focus()}onCtrlA(e){e.preventDefault(),e.stopPropagation(),this.list.setSelection(ma(this.list.length),e.browserEvent),this.list.setAnchor(void 0),this.view.domNode.focus()}onEscape(e){this.list.getSelection().length&&(e.preventDefault(),e.stopPropagation(),this.list.setSelection([],e.browserEvent),this.list.setAnchor(void 0),this.view.domNode.focus())}dispose(){this.disposables.dispose(),this.multipleSelectionDisposables.dispose()}};dw([Hn],lW.prototype,"onKeyDown",null);(function(n){n[n.Automatic=0]="Automatic",n[n.Trigger=1]="Trigger"})(Sp||(Sp={}));(function(n){n[n.Idle=0]="Idle",n[n.Typing=1]="Typing"})(vI||(vI={}));Xlt=new class{mightProducePrintableCharacter(n){return n.ctrlKey||n.metaKey||n.altKey?!1:n.keyCode>=31&&n.keyCode<=56||n.keyCode>=21&&n.keyCode<=30||n.keyCode>=98&&n.keyCode<=107||n.keyCode>=85&&n.keyCode<=95}},jae=class{constructor(e,t,i,o,r){this.list=e,this.view=t,this.keyboardNavigationLabelProvider=i,this.keyboardNavigationEventFilter=o,this.delegate=r,this.enabled=!1,this.state=vI.Idle,this.mode=Sp.Automatic,this.triggered=!1,this.previouslyFocused=-1,this.enabledDisposables=new H,this.disposables=new H,this.updateOptions(e.options)}updateOptions(e){e.typeNavigationEnabled??!0?this.enable():this.disable(),this.mode=e.typeNavigationMode??Sp.Automatic}enable(){if(this.enabled)return;let e=!1,t=ne.chain(this.enabledDisposables.add(new Mt(this.view.domNode,"keydown")).event,r=>r.filter(s=>!vb(s.target)).filter(()=>this.mode===Sp.Automatic||this.triggered).map(s=>new Xt(s)).filter(s=>e||this.keyboardNavigationEventFilter(s)).filter(s=>this.delegate.mightProducePrintableCharacter(s)).forEach(s=>Rt.stop(s,!0)).map(s=>s.browserEvent.key)),i=ne.debounce(t,()=>null,800,void 0,void 0,void 0,this.enabledDisposables);ne.reduce(ne.any(t,i),(r,s)=>s===null?null:(r||"")+s,void 0,this.enabledDisposables)(this.onInput,this,this.enabledDisposables),i(this.onClear,this,this.enabledDisposables),t(()=>e=!0,void 0,this.enabledDisposables),i(()=>e=!1,void 0,this.enabledDisposables),this.enabled=!0,this.triggered=!1}disable(){this.enabled&&(this.enabledDisposables.clear(),this.enabled=!1,this.triggered=!1)}onClear(){let e=this.list.getFocus();if(e.length>0&&e[0]===this.previouslyFocused){let t=this.list.options.accessibilityProvider?.getAriaLabel(this.list.element(e[0]));typeof t=="string"?Bo(t):t&&Bo(t.get())}this.previouslyFocused=-1}onInput(e){if(!e){this.state=vI.Idle,this.triggered=!1;return}let t=this.list.getFocus(),i=t.length>0?t[0]:0,o=this.state===vI.Idle?1:0;this.state=vI.Typing;for(let r=0;r1&&c.length===1){this.previouslyFocused=i,this.list.setFocus([s]),this.list.reveal(s);return}}}else if(typeof l>"u"||hC(e,l)){this.previouslyFocused=i,this.list.setFocus([s]),this.list.reveal(s);return}}}dispose(){this.disable(),this.enabledDisposables.dispose(),this.disposables.dispose()}},qae=class{constructor(e,t){this.list=e,this.view=t,this.disposables=new H;let i=ne.chain(this.disposables.add(new Mt(t.domNode,"keydown")).event,r=>r.filter(s=>!vb(s.target)).map(s=>new Xt(s)));ne.chain(i,r=>r.filter(s=>s.keyCode===2&&!s.ctrlKey&&!s.metaKey&&!s.shiftKey&&!s.altKey))(this.onTab,this,this.disposables)}onTab(e){if(e.target!==this.view.domNode)return;let t=this.list.getFocus();if(t.length===0)return;let i=this.view.domElement(t[0]);if(!i)return;let o=i.querySelector("[tabIndex]");if(!o||!_n(o)||o.tabIndex===-1)return;let r=Me(o).getComputedStyle(o);r.visibility==="hidden"||r.display==="none"||(e.preventDefault(),e.stopPropagation(),o.focus())}dispose(){this.disposables.dispose()}};GPe={isSelectionSingleChangeEvent:Qae,isSelectionRangeChangeEvent:Jae},zM=class{constructor(e){this.list=e,this.disposables=new H,this._onPointer=new A,this.onPointer=this._onPointer.event,e.options.multipleSelectionSupport!==!1&&(this.multipleSelectionController=this.list.options.multipleSelectionController||GPe),this.mouseSupport=typeof e.options.mouseSupport>"u"||!!e.options.mouseSupport,this.mouseSupport&&(e.onMouseDown(this.onMouseDown,this,this.disposables),e.onContextMenu(this.onContextMenu,this,this.disposables),e.onMouseDblClick(this.onDoubleClick,this,this.disposables),e.onTouchStart(this.onMouseDown,this,this.disposables),this.disposables.add(so.addTarget(e.getHTMLElement()))),ne.any(e.onMouseClick,e.onMouseMiddleClick,e.onTap)(this.onViewPointer,this,this.disposables)}updateOptions(e){e.multipleSelectionSupport!==void 0&&(this.multipleSelectionController=void 0,e.multipleSelectionSupport&&(this.multipleSelectionController=this.list.options.multipleSelectionController||GPe))}isSelectionSingleChangeEvent(e){return this.multipleSelectionController?this.multipleSelectionController.isSelectionSingleChangeEvent(e):!1}isSelectionRangeChangeEvent(e){return this.multipleSelectionController?this.multipleSelectionController.isSelectionRangeChangeEvent(e):!1}isSelectionChangeEvent(e){return this.isSelectionSingleChangeEvent(e)||this.isSelectionRangeChangeEvent(e)}onMouseDown(e){bI(e.browserEvent.target)||Mo()!==e.browserEvent.target&&this.list.domFocus()}onContextMenu(e){if(vb(e.browserEvent.target)||bI(e.browserEvent.target))return;let t=typeof e.index>"u"?[]:[e.index];this.list.setFocus(t,e.browserEvent)}onViewPointer(e){if(!this.mouseSupport||vb(e.browserEvent.target)||bI(e.browserEvent.target)||e.browserEvent.isHandledByList)return;e.browserEvent.isHandledByList=!0;let t=e.index;if(typeof t>"u"){this.list.setFocus([],e.browserEvent),this.list.setSelection([],e.browserEvent),this.list.setAnchor(void 0);return}if(this.isSelectionChangeEvent(e))return this.changeSelection(e);this.list.setFocus([t],e.browserEvent),this.list.setAnchor(t),Qlt(e.browserEvent)||this.list.setSelection([t],e.browserEvent),this._onPointer.fire(e)}onDoubleClick(e){if(vb(e.browserEvent.target)||bI(e.browserEvent.target)||this.isSelectionChangeEvent(e)||e.browserEvent.isHandledByList)return;e.browserEvent.isHandledByList=!0;let t=this.list.getFocus();this.list.setSelection(t,e.browserEvent)}changeSelection(e){let t=e.index,i=this.list.getAnchor();if(this.isSelectionRangeChangeEvent(e)){typeof i>"u"&&(i=this.list.getFocus()[0]??t,this.list.setAnchor(i));let o=Math.min(i,t),r=Math.max(i,t),s=ma(o,r+1),a=this.list.getSelection(),l=ect(Kae(a,[i]),i);if(l.length===0)return;let c=Kae(s,tct(a,l));this.list.setSelection(c,e.browserEvent),this.list.setFocus([t],e.browserEvent)}else if(this.isSelectionSingleChangeEvent(e)){let o=this.list.getSelection(),r=o.filter(s=>s!==t);this.list.setFocus([t]),this.list.setAnchor(t),o.length===r.length?this.list.setSelection([...r,t],e.browserEvent):this.list.setSelection(r,e.browserEvent)}}dispose(){this.disposables.dispose()}},VM=class{constructor(e,t){this.styleElement=e,this.selectorSuffix=t}style(e){let t=this.selectorSuffix&&`.${this.selectorSuffix}`,i=[];e.listBackground&&i.push(`.monaco-list${t} .monaco-list-rows { background: ${e.listBackground}; }`),e.listFocusBackground&&(i.push(`.monaco-list${t}:focus .monaco-list-row.focused { background-color: ${e.listFocusBackground}; }`),i.push(`.monaco-list${t}:focus .monaco-list-row.focused:hover { background-color: ${e.listFocusBackground}; }`)),e.listFocusForeground&&i.push(`.monaco-list${t}:focus .monaco-list-row.focused { color: ${e.listFocusForeground}; }`),e.listActiveSelectionBackground&&(i.push(`.monaco-list${t}:focus .monaco-list-row.selected { background-color: ${e.listActiveSelectionBackground}; }`),i.push(`.monaco-list${t}:focus .monaco-list-row.selected:hover { background-color: ${e.listActiveSelectionBackground}; }`)),e.listActiveSelectionForeground&&i.push(`.monaco-list${t}:focus .monaco-list-row.selected { color: ${e.listActiveSelectionForeground}; }`),e.listActiveSelectionIconForeground&&i.push(`.monaco-list${t}:focus .monaco-list-row.selected .codicon { color: ${e.listActiveSelectionIconForeground}; }`),e.listFocusAndSelectionBackground&&i.push(` .monaco-drag-image, .monaco-list${t}:focus .monaco-list-row.selected.focused { background-color: ${e.listFocusAndSelectionBackground}; } `),e.listFocusAndSelectionForeground&&i.push(` .monaco-drag-image, .monaco-list${t}:focus .monaco-list-row.selected.focused { color: ${e.listFocusAndSelectionForeground}; } `),e.listInactiveFocusForeground&&(i.push(`.monaco-list${t} .monaco-list-row.focused { color: ${e.listInactiveFocusForeground}; }`),i.push(`.monaco-list${t} .monaco-list-row.focused:hover { color: ${e.listInactiveFocusForeground}; }`)),e.listInactiveSelectionIconForeground&&i.push(`.monaco-list${t} .monaco-list-row.focused .codicon { color: ${e.listInactiveSelectionIconForeground}; }`),e.listInactiveFocusBackground&&(i.push(`.monaco-list${t} .monaco-list-row.focused { background-color: ${e.listInactiveFocusBackground}; }`),i.push(`.monaco-list${t} .monaco-list-row.focused:hover { background-color: ${e.listInactiveFocusBackground}; }`)),e.listInactiveSelectionBackground&&(i.push(`.monaco-list${t} .monaco-list-row.selected { background-color: ${e.listInactiveSelectionBackground}; }`),i.push(`.monaco-list${t} .monaco-list-row.selected:hover { background-color: ${e.listInactiveSelectionBackground}; }`)),e.listInactiveSelectionForeground&&i.push(`.monaco-list${t} .monaco-list-row.selected { color: ${e.listInactiveSelectionForeground}; }`),e.listHoverBackground&&i.push(`.monaco-list${t}:not(.drop-target):not(.dragging) .monaco-list-row:hover:not(.selected):not(.focused) { background-color: ${e.listHoverBackground}; }`),e.listHoverForeground&&i.push(`.monaco-list${t}:not(.drop-target):not(.dragging) .monaco-list-row:hover:not(.selected):not(.focused) { color: ${e.listHoverForeground}; }`);let o=_h(e.listFocusAndSelectionOutline,_h(e.listSelectionOutline,e.listFocusOutline??""));o&&i.push(`.monaco-list${t}:focus .monaco-list-row.focused.selected { outline: 1px solid ${o}; outline-offset: -1px;}`),e.listFocusOutline&&i.push(` .monaco-drag-image, .monaco-list${t}:focus .monaco-list-row.focused { outline: 1px solid ${e.listFocusOutline}; outline-offset: -1px; } .monaco-workbench.context-menu-visible .monaco-list${t}.last-focused .monaco-list-row.focused { outline: 1px solid ${e.listFocusOutline}; outline-offset: -1px; } `);let r=_h(e.listSelectionOutline,e.listInactiveFocusOutline??"");r&&i.push(`.monaco-list${t} .monaco-list-row.focused.selected { outline: 1px dotted ${r}; outline-offset: -1px; }`),e.listSelectionOutline&&i.push(`.monaco-list${t} .monaco-list-row.selected { outline: 1px dotted ${e.listSelectionOutline}; outline-offset: -1px; }`),e.listInactiveFocusOutline&&i.push(`.monaco-list${t} .monaco-list-row.focused { outline: 1px dotted ${e.listInactiveFocusOutline}; outline-offset: -1px; }`),e.listHoverOutline&&i.push(`.monaco-list${t} .monaco-list-row:hover { outline: 1px dashed ${e.listHoverOutline}; outline-offset: -1px; }`),e.listDropOverBackground&&i.push(` .monaco-list${t}.drop-target, .monaco-list${t} .monaco-list-rows.drop-target, .monaco-list${t} .monaco-list-row.drop-target { background-color: ${e.listDropOverBackground} !important; color: inherit !important; } `),e.listDropBetweenBackground&&(i.push(` .monaco-list${t} .monaco-list-rows.drop-target-before .monaco-list-row:first-child::before, .monaco-list${t} .monaco-list-row.drop-target-before::before { content: ""; position: absolute; top: 0px; left: 0px; width: 100%; height: 1px; background-color: ${e.listDropBetweenBackground}; }`),i.push(` .monaco-list${t} .monaco-list-rows.drop-target-after .monaco-list-row:last-child::after, .monaco-list${t} .monaco-list-row.drop-target-after::after { content: ""; position: absolute; bottom: 0px; left: 0px; width: 100%; height: 1px; background-color: ${e.listDropBetweenBackground}; }`)),e.tableColumnsBorder&&i.push(` .monaco-table > .monaco-split-view2, .monaco-table > .monaco-split-view2 .monaco-sash.vertical::before, .monaco-workbench:not(.reduce-motion) .monaco-table:hover > .monaco-split-view2, .monaco-workbench:not(.reduce-motion) .monaco-table:hover > .monaco-split-view2 .monaco-sash.vertical::before { border-color: ${e.tableColumnsBorder}; } .monaco-workbench:not(.reduce-motion) .monaco-table > .monaco-split-view2, .monaco-workbench:not(.reduce-motion) .monaco-table > .monaco-split-view2 .monaco-sash.vertical::before { border-color: transparent; } `),e.tableOddRowsBackgroundColor&&i.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: ${e.tableOddRowsBackgroundColor}; } `),this.styleElement.textContent=i.join(` `)}},QPe={listFocusBackground:"#7FB0D0",listActiveSelectionBackground:"#0E639C",listActiveSelectionForeground:"#FFFFFF",listActiveSelectionIconForeground:"#FFFFFF",listFocusAndSelectionOutline:"#90C2F9",listFocusAndSelectionBackground:"#094771",listFocusAndSelectionForeground:"#FFFFFF",listInactiveSelectionBackground:"#3F3F46",listInactiveSelectionIconForeground:"#FFFFFF",listHoverBackground:"#2A2D2E",listDropOverBackground:"#383B3D",listDropBetweenBackground:"#EEEEEE",treeIndentGuidesStroke:"#a9a9a9",treeInactiveIndentGuidesStroke:Z.fromHex("#a9a9a9").transparent(.4).toString(),tableColumnsBorder:Z.fromHex("#cccccc").transparent(.2).toString(),tableOddRowsBackgroundColor:Z.fromHex("#cccccc").transparent(.04).toString(),listBackground:void 0,listFocusForeground:void 0,listInactiveSelectionForeground:void 0,listInactiveFocusForeground:void 0,listInactiveFocusBackground:void 0,listHoverForeground:void 0,listFocusOutline:void 0,listInactiveFocusOutline:void 0,listSelectionOutline:void 0,listHoverOutline:void 0,treeStickyScrollBackground:void 0,treeStickyScrollBorder:void 0,treeStickyScrollShadow:void 0},Jlt={keyboardSupport:!0,mouseSupport:!0,multipleSelectionSupport:!0,dnd:{getDragURI(){return null},onDragStart(){},onDragOver(){return!1},drop(){},dispose(){}}};YPe=(n,e)=>n-e,Gae=class{constructor(e,t){this._templateId=e,this.renderers=t}get templateId(){return this._templateId}renderTemplate(e){return this.renderers.map(t=>t.renderTemplate(e))}renderElement(e,t,i,o){let r=0;for(let s of this.renderers)s.renderElement(e,t,i[r++],o)}disposeElement(e,t,i,o){let r=0;for(let s of this.renderers)s.disposeElement?.(e,t,i[r],o),r+=1}disposeTemplate(e){let t=0;for(let i of this.renderers)i.disposeTemplate(e[t++])}},Yae=class{constructor(e){this.accessibilityProvider=e,this.templateId="a18n"}renderTemplate(e){return{container:e,disposables:new H}}renderElement(e,t,i){let o=this.accessibilityProvider.getAriaLabel(e),r=o&&typeof o!="string"?o:Ms(o);i.disposables.add(He(a=>{this.setAriaLabel(a.readObservable(r),i.container)}));let s=this.accessibilityProvider.getAriaLevel&&this.accessibilityProvider.getAriaLevel(e);typeof s=="number"?i.container.setAttribute("aria-level",`${s}`):i.container.removeAttribute("aria-level")}setAriaLabel(e,t){e?t.setAttribute("aria-label",e):t.removeAttribute("aria-label")}disposeElement(e,t,i,o){i.disposables.clear()}disposeTemplate(e){e.disposables.dispose()}},Zae=class{constructor(e,t){this.list=e,this.dnd=t}getDragElements(e){let t=this.list.getSelectedElements();return t.indexOf(e)>-1?t:[e]}getDragURI(e){return this.dnd.getDragURI(e)}getDragLabel(e,t){if(this.dnd.getDragLabel)return this.dnd.getDragLabel(e,t)}onDragStart(e,t){this.dnd.onDragStart?.(e,t)}onDragOver(e,t,i,o,r){return this.dnd.onDragOver(e,t,i,o,r)}onDragLeave(e,t,i,o){this.dnd.onDragLeave?.(e,t,i,o)}onDragEnd(e){this.dnd.onDragEnd?.(e)}drop(e,t,i,o,r){this.dnd.drop(e,t,i,o,r)}dispose(){this.dnd.dispose()}},Xr=class{get onDidChangeFocus(){return ne.map(this.eventBufferer.wrapEvent(this.focus.onChange),e=>this.toListEvent(e),this.disposables)}get onDidChangeSelection(){return ne.map(this.eventBufferer.wrapEvent(this.selection.onChange),e=>this.toListEvent(e),this.disposables)}get domId(){return this.view.domId}get onDidScroll(){return this.view.onDidScroll}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 onMouseOut(){return this.view.onMouseOut}get onTouchStart(){return this.view.onTouchStart}get onTap(){return this.view.onTap}get onContextMenu(){let e=!1,t=ne.chain(this.disposables.add(new Mt(this.view.domNode,"keydown")).event,r=>r.map(s=>new Xt(s)).filter(s=>e=s.keyCode===58||s.shiftKey&&s.keyCode===68).map(s=>Rt.stop(s,!0)).filter(()=>!1)),i=ne.chain(this.disposables.add(new Mt(this.view.domNode,"keyup")).event,r=>r.forEach(()=>e=!1).map(s=>new Xt(s)).filter(s=>s.keyCode===58||s.shiftKey&&s.keyCode===68).map(s=>Rt.stop(s,!0)).map(({browserEvent:s})=>{let a=this.getFocus(),l=a.length?a[0]:void 0,c=typeof l<"u"?this.view.element(l):void 0,d=typeof l<"u"?this.view.domElement(l):this.view.domNode;return{index:l,element:c,anchor:d,browserEvent:s}})),o=ne.chain(this.view.onContextMenu,r=>r.filter(s=>!e).map(({element:s,index:a,browserEvent:l})=>({element:s,index:a,anchor:new cs(Me(this.view.domNode),l),browserEvent:l})));return ne.any(t,i,o)}get onKeyDown(){return this.disposables.add(new Mt(this.view.domNode,"keydown")).event}get onDidFocus(){return ne.signal(this.disposables.add(new Mt(this.view.domNode,"focus",!0)).event)}get onDidBlur(){return ne.signal(this.disposables.add(new Mt(this.view.domNode,"blur",!0)).event)}constructor(e,t,i,o,r=Jlt){this.user=e,this._options=r,this.focus=new xI("focused"),this.anchor=new xI("anchor"),this.eventBufferer=new uf,this._ariaLabel="",this.disposables=new H,this._onDidDispose=new A,this.onDidDispose=this._onDidDispose.event;let s=this._options.accessibilityProvider&&this._options.accessibilityProvider.getWidgetRole?this._options.accessibilityProvider?.getWidgetRole():"list";this.selection=new $ae(s!=="listbox");let a=[this.focus.renderer,this.selection.renderer];this.accessibilityProvider=r.accessibilityProvider,this.accessibilityProvider&&(a.push(new Yae(this.accessibilityProvider)),this.accessibilityProvider.onDidChangeActiveDescendant?.(this.onDidChangeActiveDescendant,this,this.disposables)),o=o.map(c=>new Gae(c.templateId,[...a,c]));let l={...r,dnd:r.dnd&&new Zae(this,r.dnd)};if(this.view=this.createListView(t,i,o,l),this.view.domNode.setAttribute("role",s),r.styleController)this.styleController=r.styleController(this.view.domId);else{let c=qr(this.view.domNode);this.styleController=new VM(c,this.view.domId)}if(this.spliceable=new nW([new HM(this.focus,this.view,r.identityProvider),new HM(this.selection,this.view,r.identityProvider),new HM(this.anchor,this.view,r.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 qae(this,this.view)),(typeof r.keyboardSupport!="boolean"||r.keyboardSupport)&&(this.keyboardController=new lW(this,this.view,r),this.disposables.add(this.keyboardController)),r.keyboardNavigationLabelProvider){let c=r.keyboardNavigationDelegate||Xlt;this.typeNavigationController=new jae(this,this.view,r.keyboardNavigationLabelProvider,r.keyboardNavigationEventFilter??(()=>!0),c),this.disposables.add(this.typeNavigationController)}this.mouseController=this.createMouseController(r),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")}createListView(e,t,i,o){return new Mh(e,t,i,o)}createMouseController(e){return new zM(this)}updateOptions(e={}){this._options={...this._options,...e},this.typeNavigationController?.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(e),this.keyboardController?.updateOptions(e),this.view.updateOptions(e)}get options(){return this._options}splice(e,t,i=[]){if(e<0||e>this.view.length)throw new hg(this.user,`Invalid start index: ${e}`);if(t<0)throw new hg(this.user,`Invalid delete count: ${t}`);t===0&&i.length===0||this.eventBufferer.bufferEvents(()=>this.spliceable.splice(e,t,i))}rerender(){this.view.rerender()}element(e){return this.view.element(e)}indexOf(e){return this.view.indexOf(e)}indexAt(e){return this.view.indexAt(e)}get length(){return this.view.length}get contentHeight(){return this.view.contentHeight}get onDidChangeContentHeight(){return this.view.onDidChangeContentHeight}get scrollTop(){return this.view.getScrollTop()}set scrollTop(e){this.view.setScrollTop(e)}get scrollHeight(){return this.view.scrollHeight}get renderHeight(){return this.view.renderHeight}get firstVisibleIndex(){return this.view.firstVisibleIndex}get ariaLabel(){return this._ariaLabel}set ariaLabel(e){this._ariaLabel=e,this.view.domNode.setAttribute("aria-label",e)}domFocus(){this.view.domNode.focus({preventScroll:!0})}layout(e,t){this.view.layout(e,t)}setSelection(e,t){for(let i of e)if(i<0||i>=this.length)throw new hg(this.user,`Invalid index ${i}`);this.selection.set(e,t)}getSelection(){return this.selection.get()}getSelectedElements(){return this.getSelection().map(e=>this.view.element(e))}setAnchor(e){if(typeof e>"u"){this.anchor.set([]);return}if(e<0||e>=this.length)throw new hg(this.user,`Invalid index ${e}`);this.anchor.set([e])}getAnchor(){return Wk(this.anchor.get(),void 0)}getAnchorElement(){let e=this.getAnchor();return typeof e>"u"?void 0:this.element(e)}setFocus(e,t){for(let i of e)if(i<0||i>=this.length)throw new hg(this.user,`Invalid index ${i}`);this.focus.set(e,t)}focusNext(e=1,t=!1,i,o){if(this.length===0)return;let r=this.focus.get(),s=this.findNextIndex(r.length>0?r[0]+e:0,t,o);s>-1&&this.setFocus([s],i)}focusPrevious(e=1,t=!1,i,o){if(this.length===0)return;let r=this.focus.get(),s=this.findPreviousIndex(r.length>0?r[0]-e:0,t,o);s>-1&&this.setFocus([s],i)}async focusNextPage(e,t){let i=this.view.indexAt(this.view.getScrollTop()+this.view.renderHeight);i=i===0?0:i-1;let o=this.getFocus()[0];if(o!==i&&(o===void 0||i>o)){let r=this.findPreviousIndex(i,!1,t);r>-1&&o!==r?this.setFocus([r],e):this.setFocus([i],e)}else{let r=this.view.getScrollTop(),s=r+this.view.renderHeight;i>o&&(s-=this.view.elementHeight(i)),this.view.setScrollTop(s),this.view.getScrollTop()!==r&&(this.setFocus([]),await oc(0),await this.focusNextPage(e,t))}}async focusPreviousPage(e,t,i=()=>0){let o,r=i(),s=this.view.getScrollTop()+r;s===0?o=this.view.indexAt(s):o=this.view.indexAfter(s-1);let a=this.getFocus()[0];if(a!==o&&(a===void 0||a>=o)){let l=this.findNextIndex(o,!1,t);l>-1&&a!==l?this.setFocus([l],e):this.setFocus([o],e)}else{let l=s;this.view.setScrollTop(s-this.view.renderHeight-r),this.view.getScrollTop()+i()!==l&&(this.setFocus([]),await oc(0),await this.focusPreviousPage(e,t,i))}}focusLast(e,t){if(this.length===0)return;let i=this.findPreviousIndex(this.length-1,!1,t);i>-1&&this.setFocus([i],e)}focusFirst(e,t){this.focusNth(0,e,t)}focusNth(e,t,i){if(this.length===0)return;let o=this.findNextIndex(e,!1,i);o>-1&&this.setFocus([o],t)}findNextIndex(e,t=!1,i){for(let o=0;o=this.length&&!t)return-1;if(e=e%this.length,!i||i(this.element(e)))return e;e++}return-1}findPreviousIndex(e,t=!1,i){for(let o=0;othis.view.element(e))}reveal(e,t,i=0){if(e<0||e>=this.length)throw new hg(this.user,`Invalid index ${e}`);let o=this.view.getScrollTop(),r=this.view.elementTop(e),s=this.view.elementHeight(e);if(cu(t)){let a=s-this.view.renderHeight+i;this.view.setScrollTop(a*ps(t,0,1)+r-i)}else{let a=r+s,l=o+this.view.renderHeight;r=l||(r=l&&s>=this.view.renderHeight?this.view.setScrollTop(r-i):a>=l&&this.view.setScrollTop(a-this.view.renderHeight))}}getRelativeTop(e,t=0){if(e<0||e>=this.length)throw new hg(this.user,`Invalid index ${e}`);let i=this.view.getScrollTop(),o=this.view.elementTop(e),r=this.view.elementHeight(e);if(oi+this.view.renderHeight)return null;let s=r-this.view.renderHeight+t;return Math.abs((i+t-o)/s)}getHTMLElement(){return this.view.domNode}getScrollableElement(){return this.view.scrollableElementDomNode}getElementID(e){return this.view.getElementDomId(e)}getElementTop(e){return this.view.elementTop(e)}style(e){this.styleController.style(e)}toListEvent({indexes:e,browserEvent:t}){return{indexes:e,elements:e.map(i=>this.view.element(i)),browserEvent:t}}_onFocusChange(){let e=this.focus.get();this.view.domNode.classList.toggle("element-focused",e.length>0),this.onDidChangeActiveDescendant()}onDidChangeActiveDescendant(){let e=this.focus.get();if(e.length>0){let t;this.accessibilityProvider?.getActiveDescendantId&&(t=this.accessibilityProvider.getActiveDescendantId(this.view.element(e[0]))),this.view.domNode.setAttribute("aria-activedescendant",t||this.view.getElementDomId(e[0]))}else this.view.domNode.removeAttribute("aria-activedescendant")}_onSelectionChange(){let e=this.selection.get();this.view.domNode.classList.toggle("selection-none",e.length===0),this.view.domNode.classList.toggle("selection-single",e.length===1),this.view.domNode.classList.toggle("selection-multiple",e.length>1)}dispose(){this._onDidDispose.fire(),this.disposables.dispose(),this._onDidDispose.dispose()}};dw([Hn],Xr.prototype,"onDidChangeFocus",null);dw([Hn],Xr.prototype,"onDidChangeSelection",null);dw([Hn],Xr.prototype,"onContextMenu",null);dw([Hn],Xr.prototype,"onKeyDown",null);dw([Hn],Xr.prototype,"onDidFocus",null);dw([Hn],Xr.prototype,"onDidBlur",null)});var JPe=k(()=>{});var LC,eOe,ele,cW,tOe=k(()=>{ke();Sf();Ks();bM();Ah();Ps();xb();at();Ie();hu();j();Bt();JPe();pe();LC=J,eOe="selectOption.entry.template",ele=class{get templateId(){return eOe}renderTemplate(e){let t=Object.create(null);return t.root=e,t.text=Q(e,LC(".option-text")),t.detail=Q(e,LC(".option-detail")),t.decoratorRight=Q(e,LC(".option-decorator-right")),t}renderElement(e,t,i){let o=i,r=e.text,s=e.detail,a=e.decoratorRight,l=e.isDisabled;o.text.textContent=r,o.detail.textContent=s||"",o.decoratorRight.innerText=a||"",l?o.root.classList.add("option-disabled"):o.root.classList.remove("option-disabled")}disposeTemplate(e){}},cW=class n extends D{static{this.DEFAULT_DROPDOWN_MINIMUM_BOTTOM_MARGIN=32}static{this.DEFAULT_DROPDOWN_MINIMUM_TOP_MARGIN=2}static{this.DEFAULT_MINIMUM_VISIBLE_OPTIONS=3}constructor(e,t,i,o,r){super(),this.options=[],this._currentSelection=0,this._hasDetails=!1,this._skipLayout=!1,this._sticky=!1,this._isVisible=!1,this.styles=o,this.selectBoxOptions=r||Object.create(null),typeof this.selectBoxOptions.minBottomMargin!="number"?this.selectBoxOptions.minBottomMargin=n.DEFAULT_DROPDOWN_MINIMUM_BOTTOM_MARGIN:this.selectBoxOptions.minBottomMargin<0&&(this.selectBoxOptions.minBottomMargin=0),this.selectElement=document.createElement("select"),this.selectElement.className="monaco-select-box monaco-select-box-dropdown-padding",typeof this.selectBoxOptions.ariaLabel=="string"&&this.selectElement.setAttribute("aria-label",this.selectBoxOptions.ariaLabel),typeof this.selectBoxOptions.ariaDescription=="string"&&this.selectElement.setAttribute("aria-description",this.selectBoxOptions.ariaDescription),this._onDidSelect=new A,this._register(this._onDidSelect),this.registerListeners(),this.constructSelectDropDown(i),this.selected=t||0,e&&this.setOptions(e,t),this.initStyleSheet()}setTitle(e){!this._hover&&e?this._hover=this._register(Os().setupManagedHover(lo("mouse"),this.selectElement,e)):this._hover&&this._hover.update(e)}getHeight(){return 22}getTemplateId(){return eOe}constructSelectDropDown(e){this.contextViewProvider=e,this.selectDropDownContainer=J(".monaco-select-box-dropdown-container"),this.selectDropDownContainer.classList.add("monaco-select-box-dropdown-padding"),this.selectionDetailsPane=Q(this.selectDropDownContainer,LC(".select-box-details-pane"));let t=Q(this.selectDropDownContainer,LC(".select-box-dropdown-container-width-control")),i=Q(t,LC(".width-control-div"));this.widthControlElement=document.createElement("span"),this.widthControlElement.className="option-text-width-control",Q(i,this.widthControlElement),this._dropDownPosition=0,this.styleElement=qr(this.selectDropDownContainer),this.selectDropDownContainer.setAttribute("draggable","true"),this._register(U(this.selectDropDownContainer,re.DRAG_START,o=>{Rt.stop(o,!0)}))}registerListeners(){this._register(gi(this.selectElement,"change",t=>{this.selected=t.target.selectedIndex,this._onDidSelect.fire({index:t.target.selectedIndex,selected:t.target.value}),this.options[this.selected]&&this.options[this.selected].text&&this.setTitle(this.options[this.selected].text)})),this._register(U(this.selectElement,re.CLICK,t=>{Rt.stop(t),this._isVisible?this.hideSelectDropDown(!0):this.showSelectDropDown()})),this._register(U(this.selectElement,re.MOUSE_DOWN,t=>{Rt.stop(t)}));let e;this._register(U(this.selectElement,"touchstart",t=>{e=this._isVisible})),this._register(U(this.selectElement,"touchend",t=>{Rt.stop(t),e?this.hideSelectDropDown(!0):this.showSelectDropDown()})),this._register(U(this.selectElement,re.KEY_DOWN,t=>{let i=new Xt(t),o=!1;dt?(i.keyCode===18||i.keyCode===16||i.keyCode===10||i.keyCode===3)&&(o=!0):(i.keyCode===18&&i.altKey||i.keyCode===16&&i.altKey||i.keyCode===10||i.keyCode===3)&&(o=!0),o&&(this.showSelectDropDown(),Rt.stop(t,!0))}))}get onDidSelect(){return this._onDidSelect.event}setOptions(e,t){oi(this.options,e)||(this.options=e,this.selectElement.options.length=0,this._hasDetails=!1,this._cachedMaxDetailsHeight=void 0,this.options.forEach((i,o)=>{this.selectElement.add(this.createOption(i.text,o,i.isDisabled)),typeof i.description=="string"&&(this._hasDetails=!0)})),t!==void 0&&(this.select(t),this._currentSelection=this.selected)}setOptionsList(){this.selectList?.splice(0,this.selectList.length,this.options)}select(e){e>=0&&ethis.options.length-1?this.select(this.options.length-1):this.selected<0&&(this.selected=0),this.selectElement.selectedIndex=this.selected,this.options[this.selected]&&this.options[this.selected].text&&this.setTitle(this.options[this.selected].text)}focus(){this.selectElement&&(this.selectElement.tabIndex=0,this.selectElement.focus())}blur(){this.selectElement&&(this.selectElement.tabIndex=-1,this.selectElement.blur())}setFocusable(e){this.selectElement.tabIndex=e?0:-1}render(e){this.container=e,e.classList.add("select-container"),e.appendChild(this.selectElement),this.styleSelectElement()}initStyleSheet(){let e=[];this.styles.listFocusBackground&&e.push(`.monaco-select-box-dropdown-container > .select-box-dropdown-list-container .monaco-list .monaco-list-row.focused { background-color: ${this.styles.listFocusBackground} !important; }`),this.styles.listFocusForeground&&e.push(`.monaco-select-box-dropdown-container > .select-box-dropdown-list-container .monaco-list .monaco-list-row.focused { color: ${this.styles.listFocusForeground} !important; }`),this.styles.decoratorRightForeground&&e.push(`.monaco-select-box-dropdown-container > .select-box-dropdown-list-container .monaco-list .monaco-list-row:not(.focused) .option-decorator-right { color: ${this.styles.decoratorRightForeground}; }`),this.styles.selectBackground&&this.styles.selectBorder&&this.styles.selectBorder!==this.styles.selectBackground?(e.push(`.monaco-select-box-dropdown-container { border: 1px solid ${this.styles.selectBorder} } `),e.push(`.monaco-select-box-dropdown-container > .select-box-details-pane.border-top { border-top: 1px solid ${this.styles.selectBorder} } `),e.push(`.monaco-select-box-dropdown-container > .select-box-details-pane.border-bottom { border-bottom: 1px solid ${this.styles.selectBorder} } `)):this.styles.selectListBorder&&(e.push(`.monaco-select-box-dropdown-container > .select-box-details-pane.border-top { border-top: 1px solid ${this.styles.selectListBorder} } `),e.push(`.monaco-select-box-dropdown-container > .select-box-details-pane.border-bottom { border-bottom: 1px solid ${this.styles.selectListBorder} } `)),this.styles.listHoverForeground&&e.push(`.monaco-select-box-dropdown-container > .select-box-dropdown-list-container .monaco-list .monaco-list-row:not(.option-disabled):not(.focused):hover { color: ${this.styles.listHoverForeground} !important; }`),this.styles.listHoverBackground&&e.push(`.monaco-select-box-dropdown-container > .select-box-dropdown-list-container .monaco-list .monaco-list-row:not(.option-disabled):not(.focused):hover { background-color: ${this.styles.listHoverBackground} !important; }`),this.styles.listFocusOutline&&e.push(`.monaco-select-box-dropdown-container > .select-box-dropdown-list-container .monaco-list .monaco-list-row.focused { outline: 1.6px dotted ${this.styles.listFocusOutline} !important; outline-offset: -1.6px !important; }`),this.styles.listHoverOutline&&e.push(`.monaco-select-box-dropdown-container > .select-box-dropdown-list-container .monaco-list .monaco-list-row:not(.option-disabled):not(.focused):hover { outline: 1.6px dashed ${this.styles.listHoverOutline} !important; outline-offset: -1.6px !important; }`),e.push(".monaco-select-box-dropdown-container > .select-box-dropdown-list-container .monaco-list .monaco-list-row.option-disabled.focused { background-color: transparent !important; color: inherit !important; outline: none !important; }"),e.push(".monaco-select-box-dropdown-container > .select-box-dropdown-list-container .monaco-list .monaco-list-row.option-disabled:hover { background-color: transparent !important; color: inherit !important; outline: none !important; }"),this.styleElement.textContent=e.join(` `)}styleSelectElement(){let e=this.styles.selectBackground??"",t=this.styles.selectForeground??"",i=this.styles.selectBorder??"";this.selectElement.style.backgroundColor=e,this.selectElement.style.color=t,this.selectElement.style.borderColor=i}styleList(){let e=this.styles.selectBackground??"",t=_h(this.styles.selectListBackground,e);this.selectDropDownListContainer.style.backgroundColor=t,this.selectionDetailsPane.style.backgroundColor=t;let i=this.styles.focusBorder??"";this.selectDropDownContainer.style.outlineColor=i,this.selectDropDownContainer.style.outlineOffset="-1px",this.selectList.style(this.styles)}createOption(e,t,i){let o=document.createElement("option");return o.value=e,o.text=e,o.disabled=!!i,o}showSelectDropDown(){this.selectionDetailsPane.innerText="",!(!this.contextViewProvider||this._isVisible)&&(this.createSelectList(this.selectDropDownContainer),this.setOptionsList(),this.contextViewProvider.showContextView({getAnchor:()=>this.selectElement,render:e=>this.renderSelectDropDown(e,!0),layout:()=>{this.layoutSelectDropDown()},onHide:()=>{this.selectDropDownContainer.classList.remove("visible"),this.selectElement.classList.remove("synthetic-focus")},anchorPosition:this._dropDownPosition},this.selectBoxOptions.optionsAsChildren?this.container:void 0),this._isVisible=!0,this.hideSelectDropDown(!1),this.contextViewProvider.showContextView({getAnchor:()=>this.selectElement,render:e=>this.renderSelectDropDown(e),layout:()=>this.layoutSelectDropDown(),onHide:()=>{this.selectDropDownContainer.classList.remove("visible"),this.selectElement.classList.remove("synthetic-focus")},anchorPosition:this._dropDownPosition},this.selectBoxOptions.optionsAsChildren?this.container:void 0),this._currentSelection=this.selected,this._isVisible=!0,this.selectElement.setAttribute("aria-expanded","true"))}hideSelectDropDown(e){!this.contextViewProvider||!this._isVisible||(this._isVisible=!1,this.selectElement.setAttribute("aria-expanded","false"),e&&this.selectElement.focus(),this.contextViewProvider.hideContextView())}renderSelectDropDown(e,t){return e.appendChild(this.selectDropDownContainer),this.layoutSelectDropDown(t),{dispose:()=>{this.selectDropDownContainer.remove()}}}measureMaxDetailsHeight(){let e=0;return this.options.forEach((t,i)=>{this.updateDetail(i),this.selectionDetailsPane.offsetHeight>e&&(e=this.selectionDetailsPane.offsetHeight)}),e}layoutSelectDropDown(e){if(this._skipLayout)return!1;if(this.selectList){this.selectDropDownContainer.classList.add("visible");let t=Me(this.selectElement),i=Ci(this.selectElement),o=Me(this.selectElement).getComputedStyle(this.selectElement),r=parseFloat(o.getPropertyValue("--dropdown-padding-top"))+parseFloat(o.getPropertyValue("--dropdown-padding-bottom")),s=t.innerHeight-i.top-i.height-(this.selectBoxOptions.minBottomMargin||0),a=i.top-n.DEFAULT_DROPDOWN_MINIMUM_TOP_MARGIN,l=this.selectElement.offsetWidth,c=this.setWidthControlElement(this.widthControlElement),d=Math.max(c,Math.round(l)).toString()+"px";this.selectDropDownContainer.style.width=d,this.selectList.getHTMLElement().style.height="",this.selectList.layout();let u=this.selectList.contentHeight;this._hasDetails&&this._cachedMaxDetailsHeight===void 0&&(this._cachedMaxDetailsHeight=this.measureMaxDetailsHeight());let h=this._hasDetails?this._cachedMaxDetailsHeight:0,f=u+r+h,p=Math.floor((s-r-h)/this.getHeight()),g=Math.floor((a-r-h)/this.getHeight());if(e)return i.top+i.height>t.innerHeight-22||i.topp&&this.options.length>p?(this._dropDownPosition=1,this.selectDropDownListContainer.remove(),this.selectionDetailsPane.remove(),this.selectDropDownContainer.appendChild(this.selectionDetailsPane),this.selectDropDownContainer.appendChild(this.selectDropDownListContainer),this.selectionDetailsPane.classList.remove("border-top"),this.selectionDetailsPane.classList.add("border-bottom")):(this._dropDownPosition=0,this.selectDropDownListContainer.remove(),this.selectionDetailsPane.remove(),this.selectDropDownContainer.appendChild(this.selectDropDownListContainer),this.selectDropDownContainer.appendChild(this.selectionDetailsPane),this.selectionDetailsPane.classList.remove("border-bottom"),this.selectionDetailsPane.classList.add("border-top")),!0);if(i.top+i.height>t.innerHeight-22||i.tops&&(u=p*this.getHeight())}else f>a&&(u=g*this.getHeight());return this.selectList.layout(u),this.selectList.domFocus(),this.selectList.length>0&&(this.selectList.setFocus([this.selected||0]),this.selectList.reveal(this.selectList.getFocus()[0]||0)),this._hasDetails?(this.selectList.getHTMLElement().style.height=u+r+"px",this.selectDropDownContainer.style.height=""):this.selectDropDownContainer.style.height=u+r+"px",this.updateDetail(this.selected),this.selectDropDownContainer.style.width=d,this.selectDropDownListContainer.setAttribute("tabindex","0"),this.selectElement.classList.add("synthetic-focus"),this.selectDropDownContainer.classList.add("synthetic-focus"),!0}else return!1}setWidthControlElement(e){let t=0;if(e){let i=0,o=0;this.options.forEach((r,s)=>{let a=r.detail?r.detail.length:0,l=r.decoratorRight?r.decoratorRight.length:0,c=r.text.length+a+l;c>o&&(i=s,o=c)}),e.textContent=this.options[i].text+(this.options[i].decoratorRight?this.options[i].decoratorRight+" ":""),t=Gs(e)}return t}createSelectList(e){if(this.selectList)return;this.selectDropDownListContainer=Q(e,LC(".select-box-dropdown-list-container")),this.listRenderer=new ele,this.selectList=this._register(new Xr("SelectBoxCustom",this.selectDropDownListContainer,this,[this.listRenderer],{useShadows:!1,verticalScrollMode:3,keyboardSupport:!1,mouseSupport:!1,accessibilityProvider:{getAriaLabel:o=>{let r=o.text;return o.detail&&(r+=`. ${o.detail}`),o.decoratorRight&&(r+=`. ${o.decoratorRight}`),o.description&&(r+=`. ${o.description}`),r},getWidgetAriaLabel:()=>m({key:"selectBox",comment:["Behave like native select dropdown element."]},"Select Box"),getRole:()=>dt?"":"option",getWidgetRole:()=>"listbox"}})),this.selectBoxOptions.ariaLabel&&(this.selectList.ariaLabel=this.selectBoxOptions.ariaLabel);let t=this._register(new Mt(this.selectDropDownListContainer,"keydown")),i=ne.chain(t.event,o=>o.filter(()=>this.selectList.length>0).map(r=>new Xt(r)));this._register(ne.chain(i,o=>o.filter(r=>r.keyCode===3))(this.onEnter,this)),this._register(ne.chain(i,o=>o.filter(r=>r.keyCode===2))(this.onEnter,this)),this._register(ne.chain(i,o=>o.filter(r=>r.keyCode===9))(this.onEscape,this)),this._register(ne.chain(i,o=>o.filter(r=>r.keyCode===16))(this.onUpArrow,this)),this._register(ne.chain(i,o=>o.filter(r=>r.keyCode===18))(this.onDownArrow,this)),this._register(ne.chain(i,o=>o.filter(r=>r.keyCode===12))(this.onPageDown,this)),this._register(ne.chain(i,o=>o.filter(r=>r.keyCode===11))(this.onPageUp,this)),this._register(ne.chain(i,o=>o.filter(r=>r.keyCode===14))(this.onHome,this)),this._register(ne.chain(i,o=>o.filter(r=>r.keyCode===13))(this.onEnd,this)),this._register(ne.chain(i,o=>o.filter(r=>r.keyCode>=21&&r.keyCode<=56||r.keyCode>=85&&r.keyCode<=113))(this.onCharacter,this)),this._register(U(this.selectList.getHTMLElement(),re.POINTER_UP,o=>this.onPointerUp(o))),this._register(this.selectList.onMouseOver(o=>typeof o.index<"u"&&this.selectList.setFocus([o.index]))),this._register(this.selectList.onDidChangeFocus(o=>this.onListFocus(o))),this._register(U(this.selectDropDownContainer,re.FOCUS_OUT,o=>{!this._isVisible||io(o.relatedTarget,this.selectDropDownContainer)||this.onListBlur()})),this.selectList.getHTMLElement().setAttribute("aria-label",this.selectBoxOptions.ariaLabel||""),this.selectList.getHTMLElement().setAttribute("aria-expanded","true"),this.styleList()}onPointerUp(e){if(!this.selectList.length)return;Rt.stop(e);let t=e.target;if(!t||t.classList.contains("slider"))return;let i=t.closest(".monaco-list-row");if(!i)return;let o=Number(i.getAttribute("data-index")),r=i.classList.contains("option-disabled");o>=0&&o{for(let s=0;sthis.selected+2)this.selected+=2;else{if(t)return;this.selected++}this.select(this.selected),this.selectList.setFocus([this.selected]),this.selectList.reveal(this.selectList.getFocus()[0])}}onUpArrow(e){this.selected>0&&(Rt.stop(e,!0),this.options[this.selected-1].isDisabled&&this.selected>1?this.selected-=2:this.selected--,this.select(this.selected),this.selectList.setFocus([this.selected]),this.selectList.reveal(this.selectList.getFocus()[0]))}onPageUp(e){Rt.stop(e),this.selectList.focusPreviousPage(),setTimeout(()=>{this.selected=this.selectList.getFocus()[0],this.options[this.selected].isDisabled&&this.selected{this.selected=this.selectList.getFocus()[0],this.options[this.selected].isDisabled&&this.selected>0&&(this.selected--,this.selectList.setFocus([this.selected])),this.selectList.reveal(this.selected),this.select(this.selected)},1)}onHome(e){Rt.stop(e),!(this.options.length<2)&&(this.selected=0,this.options[this.selected].isDisabled&&this.selected>1&&this.selected++,this.selectList.setFocus([this.selected]),this.selectList.reveal(this.selected),this.select(this.selected))}onEnd(e){Rt.stop(e),!(this.options.length<2)&&(this.selected=this.options.length-1,this.options[this.selected].isDisabled&&this.selected>1&&this.selected--,this.selectList.setFocus([this.selected]),this.selectList.reveal(this.selected),this.select(this.selected))}onCharacter(e){let t=hf.toString(e.keyCode),i=-1;for(let o=0;o{ke();Pd();at();Ie();j();Bt();dW=class extends D{constructor(e,t,i,o){super(),this.selected=0,this.selectBoxOptions=o||Object.create(null),this.options=[],this.selectElement=document.createElement("select"),this.selectElement.className="monaco-select-box",typeof this.selectBoxOptions.ariaLabel=="string"&&this.selectElement.setAttribute("aria-label",this.selectBoxOptions.ariaLabel),typeof this.selectBoxOptions.ariaDescription=="string"&&this.selectElement.setAttribute("aria-description",this.selectBoxOptions.ariaDescription),this._onDidSelect=this._register(new A),this.styles=i,this.registerListeners(),this.setOptions(e,t)}registerListeners(){this._register(so.addTarget(this.selectElement)),[Mi.Tap].forEach(e=>{this._register(U(this.selectElement,e,t=>{this.selectElement.focus()}))}),this._register(gi(this.selectElement,"click",e=>{Rt.stop(e,!0)})),this._register(gi(this.selectElement,"change",e=>{this.selectElement.title=e.target.value,this._onDidSelect.fire({index:e.target.selectedIndex,selected:e.target.value})})),this._register(gi(this.selectElement,"keydown",e=>{let t=!1;dt?(e.keyCode===18||e.keyCode===16||e.keyCode===10)&&(t=!0):(e.keyCode===18&&e.altKey||e.keyCode===10||e.keyCode===3)&&(t=!0),t&&e.stopPropagation()}))}get onDidSelect(){return this._onDidSelect.event}setOptions(e,t){(!this.options||!oi(this.options,e))&&(this.options=e,this.selectElement.options.length=0,this.options.forEach((i,o)=>{this.selectElement.add(this.createOption(i.text,o,i.isDisabled))})),t!==void 0&&this.select(t)}select(e){this.options.length===0?this.selected=0:e>=0&&ethis.options.length-1?this.select(this.options.length-1):this.selected<0&&(this.selected=0),this.selectElement.selectedIndex=this.selected,this.selected{});var uW,oOe=k(()=>{tOe();iOe();Lh();Bt();nOe();uW=class extends Yo{constructor(e,t,i,o,r){super(),dt&&!r?.useCustomDrawn?this.selectBoxDelegate=new dW(e,t,o,r):this.selectBoxDelegate=new cW(e,t,i,o,r),this._register(this.selectBoxDelegate)}get onDidSelect(){return this.selectBoxDelegate.onDidSelect}setOptions(e,t){this.selectBoxDelegate.setOptions(e,t)}select(e){this.selectBoxDelegate.select(e)}focus(){this.selectBoxDelegate.focus()}blur(){this.selectBoxDelegate.blur()}setFocusable(e){this.selectBoxDelegate.setFocusable(e)}render(e){this.selectBoxDelegate.render(e)}}});var tle=k(()=>{});var fc,Ph,hW,IC=k(()=>{Fc();tW();ke();Pd();Ps();oOe();Gr();j();Bt();yi();tle();pe();Ah();fc=class extends D{get action(){return this._action}constructor(e,t,i={}){super(),this.options=i,this._context=e||this,this._action=t,t instanceof rr&&this._register(t.onDidChange(o=>{this.element&&this.handleActionChangeEvent(o)}))}handleActionChangeEvent(e){e.enabled!==void 0&&this.updateEnabled(),e.checked!==void 0&&this.updateChecked(),e.class!==void 0&&this.updateClass(),e.label!==void 0&&(this.updateLabel(),this.updateTooltip()),e.tooltip!==void 0&&this.updateTooltip()}get actionRunner(){return this._actionRunner||(this._actionRunner=this._register(new Td)),this._actionRunner}set actionRunner(e){this._actionRunner=e}isEnabled(){return this._action.enabled}setActionContext(e){this._context=e}render(e){let t=this.element=e;this._register(so.addTarget(e));let i=this.options&&this.options.draggable;i&&(e.draggable=!0,ls&&this._register(U(e,re.DRAG_START,o=>o.dataTransfer?.setData(cw.TEXT,this._action.label)))),this._register(U(t,Mi.Tap,o=>this.onClick(o,!0))),this._register(U(t,re.MOUSE_DOWN,o=>{i||Rt.stop(o,!0),this._action.enabled&&o.button===0&&t.classList.add("active")})),dt&&this._register(U(t,re.CONTEXT_MENU,o=>{o.button===0&&o.ctrlKey===!0&&this.onClick(o)})),this._register(U(t,re.CLICK,o=>{Rt.stop(o,!0),this.options&&this.options.isMenu||this.onClick(o)})),this._register(U(t,re.DBLCLICK,o=>{Rt.stop(o,!0)})),[re.MOUSE_UP,re.MOUSE_OUT].forEach(o=>{this._register(U(t,o,r=>{Rt.stop(r),t.classList.remove("active")}))})}onClick(e,t=!1){Rt.stop(e,!0);let i=Za(this._context)?this.options?.useEventAsContext?e:{preserveFocus:t}:this._context;this.actionRunner.run(this._action,i)}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(e){this.element&&(this.element.tabIndex=e?0:-1)}get trapsArrowNavigation(){return!1}updateEnabled(){}updateLabel(){}getClass(){return this.action.class}getTooltip(){return this.action.tooltip}updateTooltip(){if(!this.element)return;let e=this.getTooltip()??"";if(this.updateAriaLabel(),this.options.hoverDelegate?.showNativeHover)this.element.title=e;else if(!this.customHover&&e!==""){let t=this.options.hoverDelegate??lo("element");this.customHover=this._store.add(Os().setupManagedHover(t,this.element,e))}else this.customHover&&this.customHover.update(e)}updateAriaLabel(){if(this.element){let e=this.getTooltip()??"";this.element.setAttribute("aria-label",e)}}updateClass(){}updateChecked(){}dispose(){this.element&&(this.element.remove(),this.element=void 0),this._context=void 0,super.dispose()}},Ph=class extends fc{constructor(e,t,i){super(e,t,i),this.options=i,this.options.icon=i.icon!==void 0?i.icon:!1,this.options.label=i.label!==void 0?i.label:!0,this.cssClass=""}render(e){super.render(e),At(this.element);let t=document.createElement("a");if(t.classList.add("action-label"),t.setAttribute("role",this.getDefaultAriaRole()),this.label=t,this.element.appendChild(t),this.options.label&&this.options.keybinding){let i=document.createElement("span");i.classList.add("keybinding"),i.textContent=this.options.keybinding,this.element.appendChild(i)}this.updateClass(),this.updateLabel(),this.updateTooltip(),this.updateEnabled(),this.updateChecked()}getDefaultAriaRole(){return this._action.id===Gn.ID?"presentation":this.options.isMenu?"menuitem":this.options.isTabList?"tab":"button"}focus(){this.label&&(this.label.tabIndex=0,this.label.focus())}blur(){this.label&&(this.label.tabIndex=-1)}setFocusable(e){this.label&&(this.label.tabIndex=e?0:-1)}updateLabel(){this.options.label&&this.label&&(this.label.textContent=this.action.label)}getTooltip(){let e=null;return this.action.tooltip?e=this.action.tooltip:!this.options.label&&this.action.label&&this.options.icon&&(e=this.action.label,this.options.keybinding&&(e=m({key:"titleLabel",comment:["action title","action keybinding"]},"{0} ({1})",e,this.options.keybinding))),e??void 0}updateClass(){this.cssClass&&this.label&&this.label.classList.remove(...this.cssClass.split(" ")),this.options.icon?(this.cssClass=this.getClass(),this.label&&(this.label.classList.add("codicon"),this.cssClass&&this.label.classList.add(...this.cssClass.split(" "))),this.updateEnabled()):this.label?.classList.remove("codicon")}updateEnabled(){this.action.enabled?(this.label&&(this.label.removeAttribute("aria-disabled"),this.label.classList.remove("disabled")),this.element?.classList.remove("disabled")):(this.label&&(this.label.setAttribute("aria-disabled","true"),this.label.classList.add("disabled")),this.element?.classList.add("disabled"))}updateAriaLabel(){if(this.label){let e=this.getTooltip()??"";this.label.setAttribute("aria-label",e)}}updateChecked(){this.label&&(this.action.checked!==void 0?(this.label.classList.toggle("checked",this.action.checked),this.options.isTabList?this.label.setAttribute("aria-selected",this.action.checked?"true":"false"):(this.label.setAttribute("aria-checked",this.action.checked?"true":"false"),this.label.setAttribute("role","checkbox"))):(this.label.classList.remove("checked"),this.label.removeAttribute(this.options.isTabList?"aria-selected":"aria-checked"),this.label.setAttribute("role",this.getDefaultAriaRole())))}},hW=class extends fc{constructor(e,t,i,o,r,s,a){super(e,t),this.selectBox=new uW(i,o,r,s,a),this.selectBox.setFocusable(!1),this._register(this.selectBox),this.registerListeners()}select(e){this.selectBox.select(e)}registerListeners(){this._register(this.selectBox.onDidSelect(e=>this.runAction(e.selected,e.index)))}runAction(e,t){this.actionRunner.run(this._action,this.getActionContext(e,t))}getActionContext(e,t){return e}setFocusable(e){this.selectBox.setFocusable(e)}focus(){this.selectBox?.focus()}blur(){this.selectBox?.blur()}render(e){this.selectBox.render(e)}}});var ile=k(()=>{});var nle,fW,rOe=k(()=>{ke();Ks();Pd();Gr();Ie();ile();nle=class extends Td{constructor(e,t){super(),this._onDidChangeVisibility=this._register(new A),this.onDidChangeVisibility=this._onDidChangeVisibility.event,this._element=Q(e,J(".monaco-dropdown")),this._label=Q(this._element,J(".dropdown-label"));let i=t.labelRenderer;i||(i=r=>(r.textContent=t.label||"",null));for(let r of[re.CLICK,re.MOUSE_DOWN,Mi.Tap])this._register(U(this.element,r,s=>Rt.stop(s,!0)));for(let r of[re.MOUSE_DOWN,Mi.Tap])this._register(U(this._label,r,s=>{fL(s)&&(s.detail>1||s.button!==0)||(this.visible?this.hide():this.show())}));this._register(U(this._label,re.KEY_UP,r=>{let s=new Xt(r);(s.equals(3)||s.equals(10))&&(Rt.stop(r,!0),this.visible?this.hide():this.show())}));let o=i(this._label);o&&this._register(o),this._register(so.addTarget(this._label))}get element(){return this._element}show(){this.visible||(this.visible=!0,this._onDidChangeVisibility.fire(!0))}hide(){this.visible&&(this.visible=!1,this._onDidChangeVisibility.fire(!1))}dispose(){super.dispose(),this.hide(),this.boxContainer&&(this.boxContainer.remove(),this.boxContainer=void 0),this.contents&&(this.contents.remove(),this.contents=void 0),this._label&&(this._label.remove(),this._label=void 0)}},fW=class extends nle{constructor(e,t){super(e,t),this._options=t,this._actions=[],this.actions=t.actions||[]}set menuOptions(e){this._menuOptions=e}get menuOptions(){return this._menuOptions}get actions(){return this._options.actionProvider?this._options.actionProvider.getActions():this._actions}set actions(e){this._actions=e}show(){super.show(),this.element.classList.add("active"),this._options.contextMenuProvider.showContextMenu({getAnchor:()=>this.element,getActions:()=>this.actions,getActionsContext:()=>this.menuOptions?this.menuOptions.context:null,getActionViewItem:(e,t)=>this.menuOptions&&this.menuOptions.actionViewItemProvider?this.menuOptions.actionViewItemProvider(e,t):void 0,getKeyBinding:e=>this.menuOptions&&this.menuOptions.getKeyBinding?this.menuOptions.getKeyBinding(e):void 0,getMenuClassName:()=>this._options.menuClassName||"",onHide:()=>this.onHide(),actionRunner:this.menuOptions?this.menuOptions.actionRunner:void 0,anchorAlignment:this.menuOptions?this.menuOptions.anchorAlignment:0,domForShadowRoot:this._options.menuAsChild?this.element:void 0,skipTelemetry:this._options.skipTelemetry})}hide(){super.hide()}onHide(){this.hide(),this.element.classList.remove("active")}}});var uw,ole=k(()=>{ke();IC();rOe();Ie();ile();Ps();Ah();uw=class extends fc{constructor(e,t,i,o=Object.create(null)){super(null,e,o),this.actionItem=null,this._onDidChangeVisibility=this._register(new A),this.onDidChangeVisibility=this._onDidChangeVisibility.event,this.menuActionsOrProvider=t,this.contextMenuProvider=i,this.options=o,this.options.actionRunner&&(this.actionRunner=this.options.actionRunner)}render(e){this.actionItem=e;let t=r=>{this.element=Q(r,J("a.action-label"));let s=[];return typeof this.options.classNames=="string"?s=this.options.classNames.split(/\s+/g).filter(a=>!!a):this.options.classNames&&(s=this.options.classNames),s.find(a=>a==="icon")||s.push("codicon"),this.element.classList.add(...s),this.element.setAttribute("role","button"),this.element.setAttribute("aria-haspopup","true"),this.element.setAttribute("aria-expanded","false"),this._action.label&&this._register(Os().setupManagedHover(this.options.hoverDelegate??lo("mouse"),this.element,this._action.label)),this.element.ariaLabel=this._action.label||"",null},i=Array.isArray(this.menuActionsOrProvider),o={contextMenuProvider:this.contextMenuProvider,labelRenderer:t,menuAsChild:this.options.menuAsChild,actions:i?this.menuActionsOrProvider:void 0,actionProvider:i?void 0:this.menuActionsOrProvider,skipTelemetry:this.options.skipTelemetry};if(this.dropdownMenu=this._register(new fW(e,o)),this._register(this.dropdownMenu.onDidChangeVisibility(r=>{this.element?.setAttribute("aria-expanded",`${r}`),this._onDidChangeVisibility.fire(r)})),this.dropdownMenu.menuOptions={actionViewItemProvider:this.options.actionViewItemProvider,actionRunner:this.actionRunner,getKeyBinding:this.options.keybindingProvider,context:this._context},this.options.anchorAlignmentProvider){let r=this;this.dropdownMenu.menuOptions={...this.dropdownMenu.menuOptions,get anchorAlignment(){return r.options.anchorAlignmentProvider()}}}this.updateTooltip(),this.updateEnabled()}getTooltip(){let e=null;return this.action.tooltip?e=this.action.tooltip:this.action.label&&(e=this.action.label),e??void 0}setActionContext(e){super.setActionContext(e),this.dropdownMenu&&(this.dropdownMenu.menuOptions?this.dropdownMenu.menuOptions.context=e:this.dropdownMenu.menuOptions={context:e})}show(){this.dropdownMenu?.show()}updateEnabled(){let e=!this.action.enabled;this.actionItem?.classList.toggle("disabled",e),this.element?.classList.toggle("disabled",e)}}});var sOe=k(()=>{});function aOe(n){return n&&typeof n=="object"&&typeof n.original=="string"&&typeof n.value=="string"}function lOe(n){return n?n.condition!==void 0:!1}var rle=k(()=>{});var EC,CI,SI,kI,cOe=k(()=>{ft();Ie();j();u7();yi();(function(n){n[n.STORAGE_DOES_NOT_EXIST=0]="STORAGE_DOES_NOT_EXIST",n[n.STORAGE_IN_MEMORY=1]="STORAGE_IN_MEMORY"})(EC||(EC={}));(function(n){n[n.None=0]="None",n[n.Initialized=1]="Initialized",n[n.Closed=2]="Closed"})(CI||(CI={}));SI=class n extends D{static{this.DEFAULT_FLUSH_DELAY=100}constructor(e,t=Object.create(null)){super(),this.database=e,this.options=t,this._onDidChangeStorage=this._register(new lh),this.onDidChangeStorage=this._onDidChangeStorage.event,this.state=CI.None,this.cache=new Map,this.flushDelayer=this._register(new lL(n.DEFAULT_FLUSH_DELAY)),this.pendingDeletes=new Set,this.pendingInserts=new Map,this.whenFlushedCallbacks=[],this.registerListeners()}registerListeners(){this._register(this.database.onDidChangeItemsExternal(e=>this.onDidChangeItemsExternal(e)))}onDidChangeItemsExternal(e){this._onDidChangeStorage.pause();try{e.changed?.forEach((t,i)=>this.acceptExternal(i,t)),e.deleted?.forEach(t=>this.acceptExternal(t,void 0))}finally{this._onDidChangeStorage.resume()}}acceptExternal(e,t){if(this.state===CI.Closed)return;let i=!1;Za(t)?i=this.cache.delete(e):this.cache.get(e)!==t&&(this.cache.set(e,t),i=!0),i&&this._onDidChangeStorage.fire({key:e,external:!0})}get(e,t){let i=this.cache.get(e);return Za(i)?t:i}getBoolean(e,t){let i=this.get(e);return Za(i)?t:i==="true"}getNumber(e,t){let i=this.get(e);return Za(i)?t:parseInt(i,10)}async set(e,t,i=!1){if(this.state===CI.Closed)return;if(Za(t))return this.delete(e,i);let o=mo(t)||Array.isArray(t)?R2e(t):String(t);if(this.cache.get(e)!==o)return this.cache.set(e,o),this.pendingInserts.set(e,o),this.pendingDeletes.delete(e),this._onDidChangeStorage.fire({key:e,external:i}),this.doFlush()}async delete(e,t=!1){if(!(this.state===CI.Closed||!this.cache.delete(e)))return this.pendingDeletes.has(e)||this.pendingDeletes.add(e),this.pendingInserts.delete(e),this._onDidChangeStorage.fire({key:e,external:t}),this.doFlush()}get hasPending(){return this.pendingInserts.size>0||this.pendingDeletes.size>0}async flushPending(){if(!this.hasPending)return;let e={insert:this.pendingInserts,delete:this.pendingDeletes};return this.pendingDeletes=new Set,this.pendingInserts=new Map,this.database.updateItems(e).finally(()=>{if(!this.hasPending)for(;this.whenFlushedCallbacks.length;)this.whenFlushedCallbacks.pop()?.()})}async doFlush(e){return this.options.hint===EC.STORAGE_IN_MEMORY?this.flushPending():this.flushDelayer.trigger(()=>this.flushPending(),e)}},kI=class{constructor(){this.onDidChangeItemsExternal=ne.None,this.items=new Map}async updateItems(e){e.insert?.forEach((t,i)=>this.items.set(i,t)),e.delete?.forEach(t=>this.items.delete(t))}}});function ict(n){let e=n.get(pW);if(e)try{return JSON.parse(e)}catch{}return Object.create(null)}var pW,Fs,hw,sle,mW,kp=k(()=>{Ie();j();yi();cOe();Fe();pW="__$__targetStorageMarker",Fs=We("storageService");(function(n){n[n.NONE=0]="NONE",n[n.SHUTDOWN=1]="SHUTDOWN"})(hw||(hw={}));sle=class n extends D{static{this.DEFAULT_FLUSH_INTERVAL=60*1e3}constructor(e={flushInterval:n.DEFAULT_FLUSH_INTERVAL}){super(),this.options=e,this._onDidChangeValue=this._register(new lh),this._onDidChangeTarget=this._register(new lh),this._onWillSaveState=this._register(new A),this.onWillSaveState=this._onWillSaveState.event,this._workspaceKeyTargets=void 0,this._profileKeyTargets=void 0,this._applicationKeyTargets=void 0}onDidChangeValue(e,t,i){return ne.filter(this._onDidChangeValue.event,o=>o.scope===e&&(t===void 0||o.key===t),i)}emitDidChangeValue(e,t){let{key:i,external:o}=t;if(i===pW){switch(e){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:e})}else this._onDidChangeValue.fire({scope:e,key:i,target:this.getKeyTargets(e)[i],external:o})}get(e,t,i){return this.getStorage(t)?.get(e,i)}getBoolean(e,t,i){return this.getStorage(t)?.getBoolean(e,i)}getNumber(e,t,i){return this.getStorage(t)?.getNumber(e,i)}store(e,t,i,o,r=!1){if(Za(t)){this.remove(e,i,r);return}this.withPausedEmitters(()=>{this.updateKeyTarget(e,i,o),this.getStorage(i)?.set(e,t,r)})}remove(e,t,i=!1){this.withPausedEmitters(()=>{this.updateKeyTarget(e,t,void 0),this.getStorage(t)?.delete(e,i)})}withPausedEmitters(e){this._onDidChangeValue.pause(),this._onDidChangeTarget.pause();try{e()}finally{this._onDidChangeValue.resume(),this._onDidChangeTarget.resume()}}updateKeyTarget(e,t,i,o=!1){let r=this.getKeyTargets(t);typeof i=="number"?r[e]!==i&&(r[e]=i,this.getStorage(t)?.set(pW,JSON.stringify(r),o)):typeof r[e]=="number"&&(delete r[e],this.getStorage(t)?.set(pW,JSON.stringify(r),o))}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(e){switch(e){case-1:return this.applicationKeyTargets;case 0:return this.profileKeyTargets;default:return this.workspaceKeyTargets}}loadKeyTargets(e){let t=this.getStorage(e);return t?ict(t):Object.create(null)}},mW=class extends sle{constructor(){super(),this.applicationStorage=this._register(new SI(new kI,{hint:EC.STORAGE_IN_MEMORY})),this.profileStorage=this._register(new SI(new kI,{hint:EC.STORAGE_IN_MEMORY})),this.workspaceStorage=this._register(new SI(new kI,{hint:EC.STORAGE_IN_MEMORY})),this._register(this.workspaceStorage.onDidChangeStorage(e=>this.emitDidChangeValue(1,e))),this._register(this.profileStorage.onDidChangeStorage(e=>this.emitDidChangeValue(0,e))),this._register(this.applicationStorage.onDidChangeStorage(e=>this.emitDidChangeValue(-1,e)))}getStorage(e){switch(e){case-1:return this.applicationStorage;case 0:return this.profileStorage;default:return this.workspaceStorage}}}});function nct(n,e){let t={...e};for(let i in n){let o=n[i];t[i]=o!==void 0?De(o):void 0}return t}function Lp(n){return nct(n,wb)}var dOe,uOe,hOe,LI,IJt,EJt,TJt,II,fOe,gW,DJt,wb,pOe,mOe,pg=k(()=>{Wn();vo();dOe={keybindingLabelBackground:De(iMe),keybindingLabelForeground:De(nMe),keybindingLabelBorder:De(oMe),keybindingLabelBottomBorder:De(rMe),keybindingLabelShadow:De(qm)},uOe={buttonForeground:De(wse),buttonSeparator:De(VAe),buttonBackground:De(VL),buttonHoverBackground:De(UAe),buttonSecondaryForeground:De(jAe),buttonSecondaryBackground:De(z9),buttonSecondaryHoverBackground:De(qAe),buttonBorder:De($Ae)},hOe={progressBarBackground:De(QRe)},LI={inputActiveOptionBorder:De(lC),inputActiveOptionForeground:De(cC),inputActiveOptionBackground:De(ab)},IJt={activeForeground:De(UL),activeBackground:De(KAe),activeBorder:De(GAe),inactiveForeground:De(YAe),inactiveBackground:De(ZAe),inactiveBorder:De(XAe),inactiveHoverBackground:De(QAe)},EJt={checkboxBackground:De(JAe),checkboxBorder:De(tMe),checkboxForeground:De(eMe)},TJt={dialogBackground:De(Ca),dialogForeground:De(sC),dialogShadow:De(qm),dialogBorder:De(jt),errorIconForeground:De(CAe),warningIconForeground:De(SAe),infoIconForeground:De(kAe),textLinkForeground:De(ZRe)},II={inputBackground:De(oM),inputForeground:De(V9),inputBorder:De(U9),inputValidationInfoBorder:De(MAe),inputValidationInfoBackground:De(RAe),inputValidationInfoForeground:De(AAe),inputValidationWarningBorder:De(FAe),inputValidationWarningBackground:De(PAe),inputValidationWarningForeground:De(OAe),inputValidationErrorBorder:De(HAe),inputValidationErrorBackground:De(BAe),inputValidationErrorForeground:De(WAe)},fOe={listFilterWidgetBackground:De(bMe),listFilterWidgetOutline:De(vMe),listFilterWidgetNoMatchesOutline:De(xMe),listFilterWidgetShadow:De(wMe),inputBoxStyles:II,toggleStyles:LI},gW={badgeBackground:De(WL),badgeForeground:De(XRe),badgeBorder:De(jt)},DJt={breadcrumbsBackground:De(xAe),breadcrumbsForeground:De(vAe),breadcrumbsHoverForeground:De(gse),breadcrumbsFocusForeground:De(gse),breadcrumbsFocusAndSelectionForeground:De(wAe)},wb={listBackground:void 0,listInactiveFocusForeground:void 0,listFocusBackground:De(sMe),listFocusForeground:De(aMe),listFocusOutline:De(lMe),listActiveSelectionBackground:De(Km),listActiveSelectionForeground:De(Gx),listActiveSelectionIconForeground:De($9),listFocusAndSelectionOutline:De(cMe),listFocusAndSelectionBackground:De(Km),listFocusAndSelectionForeground:De(Gx),listInactiveSelectionBackground:De(dMe),listInactiveSelectionIconForeground:De(hMe),listInactiveSelectionForeground:De(uMe),listInactiveFocusBackground:De(fMe),listInactiveFocusOutline:De(pMe),listHoverBackground:De(Cse),listHoverForeground:De(Sse),listDropOverBackground:De(mMe),listDropBetweenBackground:De(gMe),listSelectionOutline:De(Zi),listHoverOutline:De(Zi),treeIndentGuidesStroke:De(kse),treeInactiveIndentGuidesStroke:De(yMe),treeStickyScrollBackground:void 0,treeStickyScrollBorder:void 0,treeStickyScrollShadow:De(QA),tableColumnsBorder:De(CMe),tableOddRowsBackgroundColor:De(SMe)};pOe={selectBackground:De($L),selectListBackground:De(zAe),selectForeground:De(rM),decoratorRightForeground:De(q9),selectBorder:De(sM),focusBorder:De(Su),listFocusBackground:De(cb),listInactiveSelectionIconForeground:De(jL),listFocusForeground:De(lb),listFocusOutline:qRe(Zi,Z.transparent.toString()),listHoverBackground:De(Cse),listHoverForeground:De(Sse),listHoverOutline:De(Zi),selectListBorder:De(eM),listBackground:void 0,listActiveSelectionBackground:void 0,listActiveSelectionForeground:void 0,listActiveSelectionIconForeground:void 0,listFocusAndSelectionBackground:void 0,listDropOverBackground:void 0,listDropBetweenBackground:void 0,listInactiveSelectionBackground:void 0,listInactiveSelectionForeground:void 0,listInactiveFocusBackground:void 0,listInactiveFocusOutline:void 0,listSelectionOutline:void 0,listFocusAndSelectionForeground:void 0,listFocusAndSelectionOutline:void 0,listInactiveFocusForeground:void 0,tableColumnsBorder:void 0,tableOddRowsBackgroundColor:void 0,treeIndentGuidesStroke:void 0,treeInactiveIndentGuidesStroke:void 0,treeStickyScrollBackground:void 0,treeStickyScrollBorder:void 0,treeStickyScrollShadow:void 0},mOe={shadowColor:De(qm),borderColor:De(kMe),foregroundColor:De(LMe),backgroundColor:De(IMe),selectionForegroundColor:De(EMe),selectionBackgroundColor:De(TMe),selectionBorderColor:De(DMe),separatorColor:De(NMe),scrollbarShadow:De(QA),scrollbarSliderBackground:De(D9),scrollbarSliderHoverBackground:De(N9),scrollbarSliderActiveBackground:De(R9)}});function gOe(n,e,t,i){let o,r,s;if(Array.isArray(n))s=n,o=e,r=t;else{let c=e;s=n.getActions(c),o=t,r=i}let a=j_.getInstance(),l=a.keyStatus.altKey||(kn||Qn)&&a.keyStatus.shiftKey;_Oe(s,o,l,r?c=>c===r:c=>c==="navigation")}function fw(n,e,t,i,o,r){let s,a,l,c,d;if(Array.isArray(n))d=n,s=e,a=t,l=i,c=o;else{let h=e;d=n.getActions(h),s=t,a=i,l=o,c=r}_Oe(d,s,!1,typeof a=="string"?h=>h===a:a,l,c)}function _Oe(n,e,t,i=s=>s==="navigation",o=()=>!1,r=!1){let s,a;Array.isArray(e)?(s=e,a=e):(s=e.primary,a=e.secondary);let l=new Set;for(let[c,d]of n){let u;i(c)?(u=s,u.length>0&&r&&u.push(new Gn)):(u=a,u.length>0&&u.push(new Gn));for(let h of d){t&&(h=h instanceof Es&&h.alt?h.alt:h);let f=u.push(h);h instanceof bh&&l.add({group:c,action:h,index:f-1})}}for(let{group:c,action:d,index:u}of l){let h=i(c)?s:a,f=d.actions;o(d,c,h.length)&&h.splice(u,1,...f)}}function vW(n,e,t){return e instanceof Es?n.createInstance(mg,e,t):e instanceof vf?e.item.isSelection?n.createInstance(cle,e):e.item.rememberDefaultAction?n.createInstance(lle,e,{...t,persistLastActionId:!0}):n.createInstance(ale,e,t):void 0}var bW,Zc,mg,_W,ale,lle,cle,yb=k(()=>{ke();Ks();IC();ole();Gr();D7();j();Bt();sOe();pe();an();rle();it();Al();Fe();Pn();ea();kp();Yi();bn();wf();yi();Wn();pg();uc();bW=function(n,e,t,i){var o=arguments.length,r=o<3?e:i===null?i=Object.getOwnPropertyDescriptor(e,t):i,s;if(typeof Reflect=="object"&&typeof Reflect.decorate=="function")r=Reflect.decorate(n,e,t,i);else for(var a=n.length-1;a>=0;a--)(s=n[a])&&(r=(o<3?s(r):o>3?s(e,t,r):s(e,t))||r);return o>3&&r&&Object.defineProperty(e,t,r),r},Zc=function(n,e){return function(t,i){e(t,i,n)}};mg=class extends Ph{constructor(e,t,i,o,r,s,a,l){super(void 0,e,{icon:!!(e.class||e.item.icon),label:!e.class&&!e.item.icon,draggable:t?.draggable,keybinding:t?.keybinding,hoverDelegate:t?.hoverDelegate}),this._options=t,this._keybindingService=i,this._notificationService=o,this._contextKeyService=r,this._themeService=s,this._contextMenuService=a,this._accessibilityService=l,this._wantsAltCommand=!1,this._itemClassDispose=this._register(new Hi),this._altKey=j_.getInstance()}get _menuItemAction(){return this._action}get _commandAction(){return this._wantsAltCommand&&this._menuItemAction.alt||this._menuItemAction}async onClick(e){e.preventDefault(),e.stopPropagation();try{await this.actionRunner.run(this._commandAction,this._context)}catch(t){this._notificationService.error(t)}}render(e){if(super.render(e),e.classList.add("menu-entry"),this.options.icon&&this._updateItemClass(this._menuItemAction.item),this._menuItemAction.alt){let t=!1,i=()=>{let o=!!this._menuItemAction.alt?.enabled&&(!this._accessibilityService.isMotionReduced()||t)&&(this._altKey.keyStatus.altKey||this._altKey.keyStatus.shiftKey&&t);o!==this._wantsAltCommand&&(this._wantsAltCommand=o,this.updateLabel(),this.updateTooltip(),this.updateClass())};this._register(this._altKey.event(i)),this._register(U(e,"mouseleave",o=>{t=!1,i()})),this._register(U(e,"mouseenter",o=>{t=!0,i()})),i()}}updateLabel(){this.options.label&&this.label&&(this.label.textContent=this._commandAction.label)}getTooltip(){let e=this._keybindingService.lookupKeybinding(this._commandAction.id,this._contextKeyService),t=e&&e.getLabel(),i=this._commandAction.tooltip||this._commandAction.label,o=t?m("titleAndKb","{0} ({1})",i,t):i;if(!this._wantsAltCommand&&this._menuItemAction.alt?.enabled){let r=this._menuItemAction.alt.tooltip||this._menuItemAction.alt.label,s=this._keybindingService.lookupKeybinding(this._menuItemAction.alt.id,this._contextKeyService),a=s&&s.getLabel(),l=a?m("titleAndKb","{0} ({1})",r,a):r;o=m("titleAndKbAndAlt",`{0} [{1}] {2}`,o,rI.modifierLabels[Ur].altKey,l)}return o}updateClass(){this.options.icon&&(this._commandAction!==this._menuItemAction?this._menuItemAction.alt&&this._updateItemClass(this._menuItemAction.alt.item):this._updateItemClass(this._menuItemAction.item))}_updateItemClass(e){this._itemClassDispose.value=void 0;let{element:t,label:i}=this;if(!t||!i)return;let o=this._commandAction.checked&&lOe(e.toggled)&&e.toggled.icon?e.toggled.icon:e.icon;if(o)if(Oe.isThemeIcon(o)){let r=Oe.asClassNameArray(o);i.classList.add(...r),this._itemClassDispose.value=ge(()=>{i.classList.remove(...r)})}else i.style.backgroundImage=Vm(this._themeService.getColorTheme().type)?_u(o.dark):_u(o.light),i.classList.add("icon"),this._itemClassDispose.value=qs(ge(()=>{i.style.backgroundImage="",i.classList.remove("icon")}),this._themeService.onDidColorThemeChange(()=>{this.updateClass()}))}};mg=bW([Zc(2,_t),Zc(3,Di),Zc(4,Le),Zc(5,Vi),Zc(6,sr),Zc(7,$o)],mg);_W=class n extends mg{render(e){this.options.label=!0,this.options.icon=!1,super.render(e),e.classList.add("text-only"),e.classList.toggle("use-comma",this._options?.useComma??!1)}updateLabel(){let e=this._keybindingService.lookupKeybinding(this._action.id,this._contextKeyService);if(!e)return super.updateLabel();if(this.label){let t=n._symbolPrintEnter(e);this._options?.conversational?this.label.textContent=m({key:"content2",comment:['A label with keybindg like "ESC to dismiss"']},"{1} to {0}",this._action.label,t):this.label.textContent=m({key:"content",comment:["A label","A keybinding"]},"{0} ({1})",this._action.label,t)}}static _symbolPrintEnter(e){return e.getLabel()?.replace(/\benter\b/gi,"\u23CE").replace(/\bEscape\b/gi,"Esc")}},ale=class extends uw{constructor(e,t,i,o,r){let s={...t,menuAsChild:t?.menuAsChild??!1,classNames:t?.classNames??(Oe.isThemeIcon(e.item.icon)?Oe.asClassName(e.item.icon):void 0),keybindingProvider:t?.keybindingProvider??(a=>i.lookupKeybinding(a.id))};super(e,{getActions:()=>e.actions},o,s),this._keybindingService=i,this._contextMenuService=o,this._themeService=r}render(e){super.render(e),At(this.element),e.classList.add("menu-entry");let t=this._action,{icon:i}=t.item;if(i&&!Oe.isThemeIcon(i)){this.element.classList.add("icon");let o=()=>{this.element&&(this.element.style.backgroundImage=Vm(this._themeService.getColorTheme().type)?_u(i.dark):_u(i.light))};o(),this._register(this._themeService.onDidColorThemeChange(()=>{o()}))}}};ale=bW([Zc(2,_t),Zc(3,sr),Zc(4,Vi)],ale);lle=class extends fc{constructor(e,t,i,o,r,s,a,l){super(null,e),this._keybindingService=i,this._notificationService=o,this._contextMenuService=r,this._menuService=s,this._instaService=a,this._storageService=l,this._container=null,this._options=t,this._storageKey=`${e.item.submenu.id}_lastActionId`;let c,d=t?.persistLastActionId?l.get(this._storageKey,1):void 0;d&&(c=e.actions.find(h=>d===h.id)),c||(c=e.actions[0]),this._defaultAction=this._instaService.createInstance(mg,c,{keybinding:this._getDefaultActionKeybindingLabel(c)});let u={keybindingProvider:h=>this._keybindingService.lookupKeybinding(h.id),...t,menuAsChild:t?.menuAsChild??!0,classNames:t?.classNames??["codicon","codicon-chevron-down"],actionRunner:t?.actionRunner??new Td};this._dropdown=new uw(e,e.actions,this._contextMenuService,u),this._register(this._dropdown.actionRunner.onDidRun(h=>{h.action instanceof Es&&this.update(h.action)}))}update(e){this._options?.persistLastActionId&&this._storageService.store(this._storageKey,e.id,1,1),this._defaultAction.dispose(),this._defaultAction=this._instaService.createInstance(mg,e,{keybinding:this._getDefaultActionKeybindingLabel(e)}),this._defaultAction.actionRunner=new class extends Td{async runAction(t,i){await t.run(void 0)}},this._container&&this._defaultAction.render(pL(this._container,J(".action-container")))}_getDefaultActionKeybindingLabel(e){let t;if(this._options?.renderKeybindingWithDefaultActionLabel){let i=this._keybindingService.lookupKeybinding(e.id);i&&(t=`(${i.getLabel()})`)}return t}setActionContext(e){super.setActionContext(e),this._defaultAction.setActionContext(e),this._dropdown.setActionContext(e)}render(e){this._container=e,super.render(this._container),this._container.classList.add("monaco-dropdown-with-default");let t=J(".action-container");this._defaultAction.render(Q(this._container,t)),this._register(U(t,re.KEY_DOWN,o=>{let r=new Xt(o);r.equals(17)&&(this._defaultAction.element.tabIndex=-1,this._dropdown.focus(),r.stopPropagation())}));let i=J(".dropdown-action-container");this._dropdown.render(Q(this._container,i)),this._register(U(i,re.KEY_DOWN,o=>{let r=new Xt(o);r.equals(15)&&(this._defaultAction.element.tabIndex=0,this._dropdown.setFocusable(!1),this._defaultAction.element?.focus(),r.stopPropagation())}))}focus(e){e?this._dropdown.focus():(this._defaultAction.element.tabIndex=0,this._defaultAction.element.focus())}blur(){this._defaultAction.element.tabIndex=-1,this._dropdown.blur(),this._container.blur()}setFocusable(e){e?this._defaultAction.element.tabIndex=0:(this._defaultAction.element.tabIndex=-1,this._dropdown.setFocusable(!1))}dispose(){this._defaultAction.dispose(),this._dropdown.dispose(),super.dispose()}};lle=bW([Zc(2,_t),Zc(3,Di),Zc(4,sr),Zc(5,Yr),Zc(6,he),Zc(7,Fs)],lle);cle=class extends hW{constructor(e,t){super(null,e,e.actions.map(i=>({text:i.id===Gn.ID?"\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500":i.label,isDisabled:!i.enabled})),0,t,pOe,{ariaLabel:e.tooltip,optionsAsChildren:!0}),this.select(Math.max(0,e.actions.findIndex(i=>i.checked)))}render(e){super.render(e),e.style.borderColor=De(sM)}runAction(e,t){let i=this.action.actions[t];i&&this.actionRunner.run(i)}};cle=bW([Zc(1,dc)],cle)});var Zo,Oh=k(()=>{ke();Ks();IC();Ps();Gr();Ie();j();yi();tle();Zo=class extends D{constructor(e,t={}){super(),this._actionRunnerDisposables=this._register(new H),this.viewItemDisposables=this._register(new ax),this.triggerKeyDown=!1,this.focusable=!0,this._onDidBlur=this._register(new A),this.onDidBlur=this._onDidBlur.event,this._onDidCancel=this._register(new A({onWillAddFirstListener:()=>this.cancelHasListener=!0})),this.onDidCancel=this._onDidCancel.event,this.cancelHasListener=!1,this._onDidRun=this._register(new A),this.onDidRun=this._onDidRun.event,this._onWillRun=this._register(new A),this.onWillRun=this._onWillRun.event,this.options=t,this._context=t.context??null,this._orientation=this.options.orientation??0,this._triggerKeys={keyDown:this.options.triggerKeys?.keyDown??!1,keys:this.options.triggerKeys?.keys??[3,10]},this._hoverDelegate=t.hoverDelegate??this._register(Ef()),this.options.actionRunner?this._actionRunner=this.options.actionRunner:(this._actionRunner=new Td,this._actionRunnerDisposables.add(this._actionRunner)),this._actionRunnerDisposables.add(this._actionRunner.onDidRun(r=>this._onDidRun.fire(r))),this._actionRunnerDisposables.add(this._actionRunner.onWillRun(r=>this._onWillRun.fire(r))),this.viewItems=[],this.focusedItem=void 0,this.domNode=document.createElement("div"),this.domNode.className="monaco-action-bar";let i,o;switch(this._orientation){case 0:i=[15],o=[17];break;case 1:i=[16],o=[18],this.domNode.className+=" vertical";break}this._register(U(this.domNode,re.KEY_DOWN,r=>{let s=new Xt(r),a=!0,l=typeof this.focusedItem=="number"?this.viewItems[this.focusedItem]:void 0;i&&(s.equals(i[0])||s.equals(i[1]))?a=this.focusPrevious():o&&(s.equals(o[0])||s.equals(o[1]))?a=this.focusNext():s.equals(9)&&this.cancelHasListener?this._onDidCancel.fire():s.equals(14)?a=this.focusFirst():s.equals(13)?a=this.focusLast():s.equals(2)&&l instanceof fc&&l.trapsArrowNavigation?a=this.focusNext(void 0,!0):this.isTriggerKeyEvent(s)?this._triggerKeys.keyDown?this.doTrigger(s):this.triggerKeyDown=!0:a=!1,a&&(s.preventDefault(),s.stopPropagation())})),this._register(U(this.domNode,re.KEY_UP,r=>{let s=new Xt(r);this.isTriggerKeyEvent(s)?(!this._triggerKeys.keyDown&&this.triggerKeyDown&&(this.triggerKeyDown=!1,this.doTrigger(s)),s.preventDefault(),s.stopPropagation()):(s.equals(2)||s.equals(1026)||s.equals(16)||s.equals(18)||s.equals(15)||s.equals(17))&&this.updateFocusedItem()})),this.focusTracker=this._register(ba(this.domNode)),this._register(this.focusTracker.onDidBlur(()=>{(Mo()===this.domNode||!io(Mo(),this.domNode))&&(this._onDidBlur.fire(),this.previouslyFocusedItem=this.focusedItem,this.focusedItem=void 0,this.triggerKeyDown=!1)})),this._register(this.focusTracker.onDidFocus(()=>this.updateFocusedItem())),this.actionsList=document.createElement("ul"),this.actionsList.className="actions-container",this.options.highlightToggledItems&&this.actionsList.classList.add("highlight-toggled"),this.actionsList.setAttribute("role",this.options.ariaRole||"toolbar"),this.options.ariaLabel&&this.actionsList.setAttribute("aria-label",this.options.ariaLabel),this.domNode.appendChild(this.actionsList),e.appendChild(this.domNode)}refreshRole(){this.length()>=1?this.actionsList.setAttribute("role",this.options.ariaRole||"toolbar"):this.actionsList.setAttribute("role","presentation")}setFocusable(e){if(this.focusable=e,this.focusable){let t=this.viewItems.find(i=>i instanceof fc&&i.isEnabled());t instanceof fc&&t.setFocusable(!0)}else this.viewItems.forEach(t=>{t instanceof fc&&t.setFocusable(!1)})}isTriggerKeyEvent(e){let t=!1;return this._triggerKeys.keys.forEach(i=>{t=t||e.equals(i)}),t}updateFocusedItem(){for(let e=0;et.setActionContext(e))}get actionRunner(){return this._actionRunner}set actionRunner(e){this._actionRunner=e,this._actionRunnerDisposables.clear(),this._actionRunnerDisposables.add(this._actionRunner.onDidRun(t=>this._onDidRun.fire(t))),this._actionRunnerDisposables.add(this._actionRunner.onWillRun(t=>this._onWillRun.fire(t))),this.viewItems.forEach(t=>t.actionRunner=e)}getContainer(){return this.domNode}getAction(e){if(typeof e=="number")return this.viewItems[e]?.action;if(_n(e)){for(;e.parentElement!==this.actionsList;){if(!e.parentElement)return;e=e.parentElement}for(let t=0;t{let s=document.createElement("li");s.className="action-item",s.setAttribute("role","presentation");let a,l={hoverDelegate:this._hoverDelegate,...t,isTabList:this.options.ariaRole==="tablist"};this.options.actionViewItemProvider&&(a=this.options.actionViewItemProvider(r,l)),a||(a=new Ph(this.context,r,l)),this.options.allowContextMenu||this.viewItemDisposables.set(a,U(s,re.CONTEXT_MENU,c=>{Rt.stop(c,!0)})),a.actionRunner=this._actionRunner,a.setActionContext(this.context),a.render(s),this.focusable&&a instanceof fc&&this.viewItems.length===0&&a.setFocusable(!0),o===null||o<0||o>=this.actionsList.children.length?(this.actionsList.appendChild(s),this.viewItems.push(a)):(this.actionsList.insertBefore(s,this.actionsList.children[o]),this.viewItems.splice(o,0,a),o++)}),typeof this.focusedItem=="number"&&this.focus(this.focusedItem),this.refreshRole()}clear(){this.isEmpty()||(this.viewItems=Yt(this.viewItems),this.viewItemDisposables.clearAndDisposeAll(),no(this.actionsList),this.refreshRole())}length(){return this.viewItems.length}isEmpty(){return this.viewItems.length===0}focus(e){let t=!1,i;if(e===void 0?t=!0:typeof e=="number"?i=e:typeof e=="boolean"&&(t=e),t&&typeof this.focusedItem>"u"){let o=this.viewItems.findIndex(r=>r.isEnabled());this.focusedItem=o===-1?void 0:o,this.updateFocus(void 0,void 0,!0)}else i!==void 0&&(this.focusedItem=i),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(e,t){if(typeof this.focusedItem>"u")this.focusedItem=this.viewItems.length-1;else if(this.viewItems.length<=1)return!1;let i=this.focusedItem,o;do{if(!e&&this.options.preventLoopNavigation&&this.focusedItem+1>=this.viewItems.length)return this.focusedItem=i,!1;this.focusedItem=(this.focusedItem+1)%this.viewItems.length,o=this.viewItems[this.focusedItem]}while(this.focusedItem!==i&&(this.options.focusOnlyEnabledItems&&!o.isEnabled()||o.action.id===Gn.ID));return this.updateFocus(void 0,void 0,t),!0}focusPrevious(e){if(typeof this.focusedItem>"u")this.focusedItem=0;else if(this.viewItems.length<=1)return!1;let t=this.focusedItem,i;do{if(this.focusedItem=this.focusedItem-1,this.focusedItem<0){if(!e&&this.options.preventLoopNavigation)return this.focusedItem=t,!1;this.focusedItem=this.viewItems.length-1}i=this.viewItems[this.focusedItem]}while(this.focusedItem!==t&&(this.options.focusOnlyEnabledItems&&!i.isEnabled()||i.action.id===Gn.ID));return this.updateFocus(!0),!0}updateFocus(e,t,i=!1){typeof this.focusedItem>"u"&&this.actionsList.focus({preventScroll:t}),this.previouslyFocusedItem!==void 0&&this.previouslyFocusedItem!==this.focusedItem&&this.viewItems[this.previouslyFocusedItem]?.blur();let o=this.focusedItem!==void 0?this.viewItems[this.focusedItem]:void 0;if(o){let r=!0;ex(o.focus)||(r=!1),this.options.focusOnlyEnabledItems&&ex(o.isEnabled)&&!o.isEnabled()&&(r=!1),o.action.id===Gn.ID&&(r=!1),r?(i||this.previouslyFocusedItem!==this.focusedItem)&&(o.focus(e),this.previouslyFocusedItem=this.focusedItem):(this.actionsList.focus({preventScroll:t}),this.previouslyFocusedItem=void 0),r&&o.showHover?.()}}doTrigger(e){if(typeof this.focusedItem>"u")return;let t=this.viewItems[this.focusedItem];if(t instanceof fc){let i=t._context===null||t._context===void 0?e:t._context;this.run(t._action,i)}}async run(e,t){await this._actionRunner.run(e,t)}dispose(){this._context=void 0,this.viewItems=Yt(this.viewItems),this.getContainer().remove(),super.dispose()}}});function oct(n){let e=ule,t=e.exec(n);if(!t)return n;let i=!t[1];return n.replace(e,i?"$2$3":"").trim()}function bOe(n){let e=n8()[n.id];return`.codicon-${n.id}:before { content: '\\${e.toString(16)}'; }`}function rct(n,e){let t=` .monaco-menu { font-size: 13px; border-radius: 5px; min-width: 160px; } ${bOe(oe.menuSelection)} ${bOe(oe.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 .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; margin: 0 4px; border-radius: 4px; } .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: 4px 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; max-height: 100%; } .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(e){t+=` /* 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; } `;let i=n.scrollbarShadow;i&&(t+=` .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; } `);let o=n.scrollbarSliderBackground;o&&(t+=` .monaco-scrollable-element > .scrollbar > .slider { background: ${o}; } `);let r=n.scrollbarSliderHoverBackground;r&&(t+=` .monaco-scrollable-element > .scrollbar > .slider:hover { background: ${r}; } `);let s=n.scrollbarSliderActiveBackground;s&&(t+=` .monaco-scrollable-element > .scrollbar > .slider.active { background: ${s}; } `)}return t}var ule,dle,xW,hle,$M,wW,yW,CW,vOe=k(()=>{Fc();Pd();ke();Ks();pu();Oh();IC();uae();Eh();Gr();ft();Qi();zR();bn();fC();j();Bt();Qe();ule=/\(&([^\s&])\)|(^|[^&])&([^\s&])/,dle=/(&)?(&)([^\s&])/g;(function(n){n[n.Right=0]="Right",n[n.Left=1]="Left"})(xW||(xW={}));(function(n){n[n.Above=0]="Above",n[n.Below=1]="Below"})(hle||(hle={}));$M=class n extends Zo{constructor(e,t,i,o){e.classList.add("monaco-menu-container"),e.setAttribute("role","presentation");let r=document.createElement("div");r.classList.add("monaco-menu"),r.setAttribute("role","presentation"),super(r,{orientation:1,actionViewItemProvider:c=>this.doGetActionViewItem(c,i,s),context:i.context,actionRunner:i.actionRunner,ariaLabel:i.ariaLabel,ariaRole:"menu",focusOnlyEnabledItems:!0,triggerKeys:{keys:[3,...dt||Qn?[10]:[]],keyDown:!0}}),this.menuStyles=o,this.menuElement=r,this.actionsList.tabIndex=0,this.initializeOrUpdateStyleSheet(e,o),this._register(so.addTarget(r)),this._register(U(r,re.KEY_DOWN,c=>{new Xt(c).equals(2)&&c.preventDefault()})),i.enableMnemonics&&this._register(U(r,re.KEY_DOWN,c=>{let d=c.key.toLocaleLowerCase();if(this.mnemonics.has(d)){Rt.stop(c,!0);let u=this.mnemonics.get(d);if(u.length===1&&(u[0]instanceof yW&&u[0].container&&this.focusItemByElement(u[0].container),u[0].onClick(c)),u.length>1){let h=u.shift();h&&h.container&&(this.focusItemByElement(h.container),u.push(h)),this.mnemonics.set(d,u)}}})),Qn&&this._register(U(r,re.KEY_DOWN,c=>{let d=new Xt(c);d.equals(14)||d.equals(11)?(this.focusedItem=this.viewItems.length-1,this.focusNext(),Rt.stop(c,!0)):(d.equals(13)||d.equals(12))&&(this.focusedItem=0,this.focusPrevious(),Rt.stop(c,!0))})),this._register(U(this.domNode,re.MOUSE_OUT,c=>{let d=c.relatedTarget;io(d,this.domNode)||(this.focusedItem=void 0,this.updateFocus(),c.stopPropagation())})),this._register(U(this.actionsList,re.MOUSE_OVER,c=>{let d=c.target;if(!(!d||!io(d,this.actionsList)||d===this.actionsList)){for(;d.parentElement!==this.actionsList&&d.parentElement!==null;)d=d.parentElement;if(d.classList.contains("action-item")){let u=this.focusedItem;this.setFocusedItem(d),u!==this.focusedItem&&this.updateFocus()}}})),this._register(so.addTarget(this.actionsList)),this._register(U(this.actionsList,Mi.Tap,c=>{let d=c.initialTarget;if(!(!d||!io(d,this.actionsList)||d===this.actionsList)){for(;d.parentElement!==this.actionsList&&d.parentElement!==null;)d=d.parentElement;if(d.classList.contains("action-item")){let u=this.focusedItem;this.setFocusedItem(d),u!==this.focusedItem&&this.updateFocus()}}}));let s={parent:this};this.mnemonics=new Map,this.scrollableElement=this._register(new Cf(r,{alwaysConsumeMouseWheel:!0,horizontal:2,vertical:3,verticalScrollbarSize:7,handleMouseWheel:!0,useShadows:!0}));let a=this.scrollableElement.getDomNode();a.style.position="",this.styleScrollElement(a,o),this._register(U(r,Mi.Change,c=>{Rt.stop(c,!0);let d=this.scrollableElement.getScrollPosition().scrollTop;this.scrollableElement.setScrollPosition({scrollTop:d-c.translationY})})),this._register(U(a,re.MOUSE_UP,c=>{c.preventDefault()}));let l=Me(e);r.style.maxHeight=`${Math.max(10,l.innerHeight-e.getBoundingClientRect().top-35)}px`,t=t.filter((c,d)=>i.submenuIds?.has(c.id)?(console.warn(`Found submenu cycle: ${c.id}`),!1):!(c instanceof Gn&&(d===t.length-1||d===0||t[d-1]instanceof Gn))),this.push(t,{icon:!0,label:!0,isMenu:!0}),e.appendChild(this.scrollableElement.getDomNode()),this.scrollableElement.scanDomNode(),this.viewItems.filter(c=>!(c instanceof CW)).forEach((c,d,u)=>{c.updatePositionInSet(d+1,u.length)})}initializeOrUpdateStyleSheet(e,t){this.styleSheet||(T1(e)?this.styleSheet=qr(e):(n.globalStyleSheet||(n.globalStyleSheet=qr()),this.styleSheet=n.globalStyleSheet)),this.styleSheet.textContent=rct(t,T1(e))}styleScrollElement(e,t){let i=t.foregroundColor??"",o=t.backgroundColor??"",r=t.borderColor?`1px solid ${t.borderColor}`:"",s="5px",a=t.shadowColor?`0 2px 8px ${t.shadowColor}`:"";e.style.outline=r,e.style.borderRadius=s,e.style.color=i,e.style.backgroundColor=o,e.style.boxShadow=a}getContainer(){return this.scrollableElement.getDomNode()}get onScroll(){return this.scrollableElement.onScroll}focusItemByElement(e){let t=this.focusedItem;this.setFocusedItem(e),t!==this.focusedItem&&this.updateFocus()}setFocusedItem(e){for(let t=0;t{this.element&&(this._register(U(this.element,re.MOUSE_UP,r=>{if(Rt.stop(r,!0),ls){if(new cs(Me(this.element),r).rightButton)return;this.onClick(r)}else setTimeout(()=>{this.onClick(r)},0)})),this._register(U(this.element,re.CONTEXT_MENU,r=>{Rt.stop(r,!0)})))},100),this._register(this.runOnceToEnableMouseUp)}render(e){super.render(e),this.element&&(this.container=e,this.item=Q(this.element,J("a.action-menu-item")),this._action.id===Gn.ID?this.item.setAttribute("role","presentation"):(this.item.setAttribute("role","menuitem"),this.mnemonic&&this.item.setAttribute("aria-keyshortcuts",`${this.mnemonic}`)),this.check=Q(this.item,J("span.menu-item-check"+Oe.asCSSSelector(oe.menuSelection))),this.check.setAttribute("role","none"),this.label=Q(this.item,J("span.action-label")),this.options.label&&this.options.keybinding&&(Q(this.item,J("span.keybinding")).textContent=this.options.keybinding),this.runOnceToEnableMouseUp.schedule(),this.updateClass(),this.updateLabel(),this.updateTooltip(),this.updateEnabled(),this.updateChecked(),this.applyStyle())}blur(){super.blur(),this.applyStyle()}focus(){super.focus(),this.item?.focus(),this.applyStyle()}updatePositionInSet(e,t){this.item&&(this.item.setAttribute("aria-posinset",`${e}`),this.item.setAttribute("aria-setsize",`${t}`))}updateLabel(){if(this.label&&this.options.label){no(this.label);let e=QL(this.action.label);if(e){let t=oct(e);this.options.enableMnemonics||(e=t),this.label.setAttribute("aria-label",t.replace(/&&/g,"&"));let i=ule.exec(e);if(i){e=gx(e),dle.lastIndex=0;let o=dle.exec(e);for(;o&&o[1];)o=dle.exec(e);let r=s=>s.replace(/&&/g,"&");o?this.label.append(H_(r(e.substr(0,o.index))," "),J("u",{"aria-hidden":"true"},o[3]),Nne(r(e.substr(o.index+o[0].length))," ")):this.label.innerText=r(e).trim(),this.item?.setAttribute("aria-keyshortcuts",(i[1]?i[1]:i[3]).toLocaleLowerCase())}else this.label.innerText=e.replace(/&&/g,"&").trim()}}}updateTooltip(){}updateClass(){this.cssClass&&this.item&&this.item.classList.remove(...this.cssClass.split(" ")),this.options.icon&&this.label?(this.cssClass=this.action.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.action.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;let e=this.action.checked;this.item.classList.toggle("checked",!!e),e!==void 0?(this.item.setAttribute("role","menuitemcheckbox"),this.item.setAttribute("aria-checked",e?"true":"false")):(this.item.setAttribute("role","menuitem"),this.item.setAttribute("aria-checked",""))}getMnemonic(){return this.mnemonic}applyStyle(){let e=this.element&&this.element.classList.contains("focused"),t=e&&this.menuStyle.selectionForegroundColor?this.menuStyle.selectionForegroundColor:this.menuStyle.foregroundColor,i=e&&this.menuStyle.selectionBackgroundColor?this.menuStyle.selectionBackgroundColor:void 0,o=e&&this.menuStyle.selectionBorderColor?`1px solid ${this.menuStyle.selectionBorderColor}`:"",r=e&&this.menuStyle.selectionBorderColor?"-1px":"";this.item&&(this.item.style.color=t??"",this.item.style.backgroundColor=i??"",this.item.style.outline=o,this.item.style.outlineOffset=r),this.check&&(this.check.style.color=t??"")}},yW=class extends wW{constructor(e,t,i,o,r){super(e,e,o,r),this.submenuActions=t,this.parentData=i,this.submenuOptions=o,this.mysubmenu=null,this.submenuDisposables=this._register(new H),this.mouseOver=!1,this.expandDirection=o&&o.expandDirection!==void 0?o.expandDirection:{horizontal:xW.Right,vertical:hle.Below},this.showScheduler=new Lt(()=>{this.mouseOver&&(this.cleanupExistingSubmenu(!1),this.createSubmenu(!1))},250),this.hideScheduler=new Lt(()=>{this.element&&!io(Mo(),this.element)&&this.parentData.submenu===this.mysubmenu&&(this.parentData.parent.focus(!1),this.cleanupExistingSubmenu(!0))},750)}render(e){super.render(e),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=Q(this.item,J("span.submenu-indicator"+Oe.asCSSSelector(oe.menuSubmenu))),this.submenuIndicator.setAttribute("aria-hidden","true")),this._register(U(this.element,re.KEY_UP,t=>{let i=new Xt(t);(i.equals(17)||i.equals(3))&&(Rt.stop(t,!0),this.createSubmenu(!0))})),this._register(U(this.element,re.KEY_DOWN,t=>{let i=new Xt(t);Mo()===this.item&&(i.equals(17)||i.equals(3))&&Rt.stop(t,!0)})),this._register(U(this.element,re.MOUSE_OVER,t=>{this.mouseOver||(this.mouseOver=!0,this.showScheduler.schedule())})),this._register(U(this.element,re.MOUSE_LEAVE,t=>{this.mouseOver=!1})),this._register(U(this.element,re.FOCUS_OUT,t=>{this.element&&!io(Mo(),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(e){Rt.stop(e,!0),this.cleanupExistingSubmenu(!1),this.createSubmenu(!0)}cleanupExistingSubmenu(e){if(this.parentData.submenu&&(e||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(e,t,i,o){let r={top:0,left:0};return r.left=_C(e.width,t.width,{position:o.horizontal===xW.Right?0:1,offset:i.left,size:i.width}),r.left>=i.left&&r.left{new Xt(d).equals(15)&&(Rt.stop(d,!0),this.parentData.parent.focus(),this.cleanupExistingSubmenu(!0))})),this.submenuDisposables.add(U(this.submenuContainer,re.KEY_DOWN,d=>{new Xt(d).equals(15)&&Rt.stop(d,!0)})),this.submenuDisposables.add(this.parentData.submenu.onDidCancel(()=>{this.parentData.parent.focus(),this.cleanupExistingSubmenu(!0)})),this.parentData.submenu.focus(e),this.mysubmenu=this.parentData.submenu}}updateAriaExpanded(e){this.item&&this.item?.setAttribute("aria-expanded",e)}applyStyle(){super.applyStyle();let t=this.element&&this.element.classList.contains("focused")&&this.menuStyle.selectionForegroundColor?this.menuStyle.selectionForegroundColor:this.menuStyle.foregroundColor;this.submenuIndicator&&(this.submenuIndicator.style.color=t??"")}dispose(){super.dispose(),this.hideScheduler.dispose(),this.mysubmenu&&(this.mysubmenu.dispose(),this.mysubmenu=null),this.submenuContainer&&(this.submenuContainer=void 0)}},CW=class extends Ph{constructor(e,t,i,o){super(e,t,i),this.menuStyles=o}render(e){super.render(e),this.label&&(this.label.style.borderBottomColor=this.menuStyles.separatorColor?`${this.menuStyles.separatorColor}`:"")}}});var SW,xOe=k(()=>{ke();pu();vOe();Gr();je();j();pg();SW=class{constructor(e,t,i,o){this.contextViewService=e,this.telemetryService=t,this.notificationService=i,this.keybindingService=o,this.focusToReturn=null,this.lastContainer=null,this.block=null,this.blockDisposable=null,this.options={blockMouse:!0}}configure(e){this.options=e}showContextMenu(e){let t=e.getActions();if(!t.length)return;this.focusToReturn=Mo();let i,o=_n(e.domForShadowRoot)?e.domForShadowRoot:void 0;this.contextViewService.showContextView({getAnchor:()=>e.getAnchor(),canRelayout:!1,anchorAlignment:e.anchorAlignment,anchorAxisAlignment:e.anchorAxisAlignment,render:r=>{this.lastContainer=r;let s=e.getMenuClassName?e.getMenuClassName():"";s&&(r.className+=" "+s),this.options.blockMouse&&(this.block=r.appendChild(J(".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",this.blockDisposable?.dispose(),this.blockDisposable=U(this.block,re.MOUSE_DOWN,d=>d.stopPropagation()));let a=new H,l=e.actionRunner||new Td;l.onWillRun(d=>this.onActionRun(d,!e.skipTelemetry),this,a),l.onDidRun(this.onDidActionRun,this,a),i=new $M(r,t,{actionViewItemProvider:e.getActionViewItem,context:e.getActionsContext?e.getActionsContext():null,actionRunner:l,getKeyBinding:e.getKeyBinding?e.getKeyBinding:d=>this.keybindingService.lookupKeybinding(d.id)},mOe),i.onDidCancel(()=>this.contextViewService.hideContextView(!0),null,a),i.onDidBlur(()=>this.contextViewService.hideContextView(!0),null,a);let c=Me(r);return a.add(U(c,re.BLUR,()=>this.contextViewService.hideContextView(!0))),a.add(U(c,re.MOUSE_DOWN,d=>{if(d.defaultPrevented)return;let u=new cs(c,d),h=u.target;if(!u.rightButton){for(;h;){if(h===r)return;h=h.parentElement}this.contextViewService.hideContextView(!0)}})),qs(a,i)},focus:()=>{i?.focus(!!e.autoSelectFirstItem)},onHide:r=>{e.onHide?.(!!r),this.block&&(this.block.remove(),this.block=null),this.blockDisposable?.dispose(),this.blockDisposable=null,this.lastContainer&&(Mo()===this.lastContainer||io(Mo(),this.lastContainer))&&this.focusToReturn?.focus(),this.lastContainer=null}},o,!!o)}onActionRun(e,t){t&&this.telemetryService.publicLog2("workbenchActionExecuted",{id:e.action.id,from:"contextMenu"}),this.contextViewService.hideContextView(!1)}onDidActionRun(e){e.error&&!$r(e.error)&&this.notificationService.error(e.error)}}});var sct,EI,kW,fle,wOe=k(()=>{ke();Gr();Ie();j();yb();an();it();Pn();ea();sc();xOe();Al();sct=function(n,e,t,i){var o=arguments.length,r=o<3?e:i===null?i=Object.getOwnPropertyDescriptor(e,t):i,s;if(typeof Reflect=="object"&&typeof Reflect.decorate=="function")r=Reflect.decorate(n,e,t,i);else for(var a=n.length-1;a>=0;a--)(s=n[a])&&(r=(o<3?s(r):o>3?s(e,t,r):s(e,t))||r);return o>3&&r&&Object.defineProperty(e,t,r),r},EI=function(n,e){return function(t,i){e(t,i,n)}},kW=class extends D{get contextMenuHandler(){return this._contextMenuHandler||(this._contextMenuHandler=new SW(this.contextViewService,this.telemetryService,this.notificationService,this.keybindingService)),this._contextMenuHandler}constructor(e,t,i,o,r,s){super(),this.telemetryService=e,this.notificationService=t,this.contextViewService=i,this.keybindingService=o,this.menuService=r,this.contextKeyService=s,this._contextMenuHandler=void 0,this._onDidShowContextMenu=this._store.add(new A),this.onDidShowContextMenu=this._onDidShowContextMenu.event,this._onDidHideContextMenu=this._store.add(new A)}configure(e){this.contextMenuHandler.configure(e)}showContextMenu(e){e=fle.transform(e,this.menuService,this.contextKeyService),this.contextMenuHandler.showContextMenu({...e,onHide:t=>{e.onHide?.(t),this._onDidHideContextMenu.fire()}}),j_.getInstance().resetKeyStatus(),this._onDidShowContextMenu.fire()}};kW=sct([EI(0,Fn),EI(1,Di),EI(2,dc),EI(3,_t),EI(4,Yr),EI(5,Le)],kW);(function(n){function e(i){return i&&i.menuId instanceof Te}function t(i,o,r){if(!e(i))return i;let{menuId:s,menuActionOptions:a,contextKeyService:l}=i;return{...i,getActions:()=>{let c=[];if(s){let d=o.getMenuActions(s,l??r,a);gOe(d,c)}return i.getActions?Gn.join(i.getActions(),c):c}}}n.transform=t})(fle||(fle={}))});var jM,yOe=k(()=>{(function(n){n[n.API=0]="API",n[n.USER=1]="USER"})(jM||(jM={}))});var gle,LW,ple,mle,IW,COe=k(()=>{ke();Il();ci();du();Ds();u7();ds();ia();Ai();Po();Gi();yOe();Ml();gle=function(n,e,t,i){var o=arguments.length,r=o<3?e:i===null?i=Object.getOwnPropertyDescriptor(e,t):i,s;if(typeof Reflect=="object"&&typeof Reflect.decorate=="function")r=Reflect.decorate(n,e,t,i);else for(var a=n.length-1;a>=0;a--)(s=n[a])&&(r=(o<3?s(r):o>3?s(e,t,r):s(e,t))||r);return o>3&&r&&Object.defineProperty(e,t,r),r},LW=function(n,e){return function(t,i){e(t,i,n)}},ple=class{constructor(e){this._commandService=e}async open(e,t){if(!L1(e,rt.command))return!1;if(!t?.allowCommands||(typeof e=="string"&&(e=Ee.parse(e)),Array.isArray(t.allowCommands)&&!t.allowCommands.includes(e.path)))return!0;let i=[];try{i=_M(decodeURIComponent(e.query))}catch{try{i=_M(e.query)}catch{}}return Array.isArray(i)||(i=[i]),await this._commandService.executeCommand(e.path,...i),!0}};ple=gle([LW(0,$t)],ple);mle=class{constructor(e){this._editorService=e}async open(e,t){typeof e=="string"&&(e=Ee.parse(e));let{selection:i,uri:o}=GMe(e);return e=o,e.scheme===rt.file&&(e=k2e(e)),await this._editorService.openCodeEditor({resource:e,options:{selection:i,source:t?.fromUserGesture?jM.USER:jM.API,...t?.editorOptions}},this._editorService.getFocusedCodeEditor(),t?.openToSide),!0}};mle=gle([LW(0,xt)],mle);IW=class{constructor(e,t){this._openers=new go,this._validators=new go,this._resolvers=new go,this._resolvedUriTargets=new Fo(i=>i.with({path:null,fragment:null,query:null}).toString()),this._externalOpeners=new go,this._defaultExternalOpener={openExternal:async i=>(aA(i,rt.http,rt.https)?HB(i):ri.location.href=i,!0)},this._openers.push({open:async(i,o)=>o?.openExternal||aA(i,rt.mailto,rt.http,rt.https,rt.vsls)?(await this._doOpenExternal(i,o),!0):!1}),this._openers.push(new ple(t)),this._openers.push(new mle(e))}registerOpener(e){return{dispose:this._openers.unshift(e)}}async open(e,t){let i=typeof e=="string"?Ee.parse(e):e,o=this._resolvedUriTargets.get(i)??e;for(let r of this._validators)if(!await r.shouldOpen(o,t))return!1;for(let r of this._openers)if(await r.open(e,t))return!0;return!1}async resolveExternalUri(e,t){for(let i of this._resolvers)try{let o=await i.resolveExternalUri(e,t);if(o)return this._resolvedUriTargets.has(o.resolved)||this._resolvedUriTargets.set(o.resolved,e),o}catch{}throw new Error("Could not resolve external URI: "+e.toString())}async _doOpenExternal(e,t){let i=typeof e=="string"?Ee.parse(e):e,o;try{o=(await this.resolveExternalUri(i,t)).resolved}catch{o=i}let r;if(typeof e=="string"&&i.toString()===o.toString()?r=e:r=encodeURI(o.toString(!0)),t?.allowContributedOpeners){let s=typeof t?.allowContributedOpeners=="string"?t?.allowContributedOpeners:void 0;for(let a of this._externalOpeners)if(await a.openExternal(r,{sourceUri:i,preferredOpenerId:s},Ze.None))return!0}return this._defaultExternalOpener.openExternal(r,{sourceUri:i},Ze.None)}dispose(){this._validators.clear()}};IW=gle([LW(0,xt),LW(1,$t)],IW)});var kr,Ip=k(()=>{Fe();kr=We("editorWorkerService")});var Vn,qM,Xc,gg=k(()=>{ob();pe();Fe();(function(n){n[n.Hint=1]="Hint",n[n.Info=2]="Info",n[n.Warning=4]="Warning",n[n.Error=8]="Error"})(Vn||(Vn={}));(function(n){function e(s,a){return a-s}n.compare=e;let t=Object.create(null);t[n.Error]=m("sev.error","Error"),t[n.Warning]=m("sev.warning","Warning"),t[n.Info]=m("sev.info","Info");function i(s){return t[s]||""}n.toString=i;function o(s){switch(s){case Mn.Error:return n.Error;case Mn.Warning:return n.Warning;case Mn.Info:return n.Info;case Mn.Ignore:return n.Hint}}n.fromSeverity=o;function r(s){switch(s){case n.Error:return Mn.Error;case n.Warning:return Mn.Warning;case n.Info:return Mn.Info;case n.Hint:return Mn.Ignore}}n.toSeverity=r})(Vn||(Vn={}));(function(n){let e="";function t(o){return i(o,!0)}n.makeKey=t;function i(o,r){let s=[e];return o.source?s.push(o.source.replace("\xA6","\\\xA6")):s.push(e),o.code?typeof o.code=="string"?s.push(o.code.replace("\xA6","\\\xA6")):s.push(o.code.value.replace("\xA6","\\\xA6")):s.push(e),o.severity!==void 0&&o.severity!==null?s.push(Vn.toString(o.severity)):s.push(e),o.message&&r?s.push(o.message.replace("\xA6","\\\xA6")):s.push(e),o.startLineNumber!==void 0&&o.startLineNumber!==null?s.push(o.startLineNumber.toString()):s.push(e),o.startColumn!==void 0&&o.startColumn!==null?s.push(o.startColumn.toString()):s.push(e),o.endLineNumber!==void 0&&o.endLineNumber!==null?s.push(o.endLineNumber.toString()):s.push(e),o.endColumn!==void 0&&o.endColumn!==null?s.push(o.endColumn.toString()):s.push(e),s.push(e),s.join("\xA6")}n.makeKeyOptionalMessage=i})(qM||(qM={}));Xc=We("markerService")});var _le,ble,Tti,Dti,Nti,Rti,TI,EW,TW,SOe,DW,kOe,NW,LOe,act,lct,TC,IOe,EOe,TOe,DOe,NOe,DC,ROe,AOe,MOe,POe,OOe,cct,Ati,FOe,Mti,Pti,Oti,Fti,BOe,WOe,Bti,Wti,HOe,Hti,zOe,zti,dct,RW,VOe,UOe,$Oe,AW,MW,PW,OW,FW,BW,jOe,qOe,KOe,GOe,YOe,ZOe,XOe,QOe,JOe,e4e,t4e,i4e,n4e,Vti,Uti,Nu=k(()=>{pe();vo();Wn();Yi();_le=R("editor.lineHighlightBackground",null,m("lineHighlight","Background color for the highlight of line at the cursor position.")),ble=R("editor.lineHighlightBorder",{dark:"#282828",light:"#eeeeee",hcDark:"#f38518",hcLight:jt},m("lineHighlightBorderBox","Background color for the border around the line at the cursor position.")),Tti=R("editor.rangeHighlightBackground",{dark:"#ffffff0b",light:"#fdff0033",hcDark:null,hcLight:null},m("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),Dti=R("editor.rangeHighlightBorder",{dark:null,light:null,hcDark:Zi,hcLight:Zi},m("rangeHighlightBorder","Background color of the border around highlighted ranges.")),Nti=R("editor.symbolHighlightBackground",{dark:Sh,light:Sh,hcDark:null,hcLight:null},m("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),Rti=R("editor.symbolHighlightBorder",{dark:null,light:null,hcDark:Zi,hcLight:Zi},m("symbolHighlightBorder","Background color of the border around highlighted symbols.")),TI=R("editorCursor.foreground",{dark:"#AEAFAD",light:Z.black,hcDark:Z.white,hcLight:"#0F4A85"},m("caret","Color of the editor cursor.")),EW=R("editorCursor.background",null,m("editorCursorBackground","The background color of the editor cursor. Allows customizing the color of a character overlapped by a block cursor.")),TW=R("editorMultiCursor.primary.foreground",TI,m("editorMultiCursorPrimaryForeground","Color of the primary editor cursor when multiple cursors are present.")),SOe=R("editorMultiCursor.primary.background",EW,m("editorMultiCursorPrimaryBackground","The background color of the primary editor cursor when multiple cursors are present. Allows customizing the color of a character overlapped by a block cursor.")),DW=R("editorMultiCursor.secondary.foreground",TI,m("editorMultiCursorSecondaryForeground","Color of secondary editor cursors when multiple cursors are present.")),kOe=R("editorMultiCursor.secondary.background",EW,m("editorMultiCursorSecondaryBackground","The background color of secondary editor cursors when multiple cursors are present. Allows customizing the color of a character overlapped by a block cursor.")),NW=R("editorWhitespace.foreground",{dark:"#e3e4e229",light:"#33333333",hcDark:"#e3e4e229",hcLight:"#CCCCCC"},m("editorWhitespaces","Color of whitespace characters in the editor.")),LOe=R("editorLineNumber.foreground",{dark:"#858585",light:"#237893",hcDark:Z.white,hcLight:"#292929"},m("editorLineNumbers","Color of editor line numbers.")),act=R("editorIndentGuide.background",NW,m("editorIndentGuides","Color of the editor indentation guides."),!1,m("deprecatedEditorIndentGuides","'editorIndentGuide.background' is deprecated. Use 'editorIndentGuide.background1' instead.")),lct=R("editorIndentGuide.activeBackground",NW,m("editorActiveIndentGuide","Color of the active editor indentation guides."),!1,m("deprecatedEditorActiveIndentGuide","'editorIndentGuide.activeBackground' is deprecated. Use 'editorIndentGuide.activeBackground1' instead.")),TC=R("editorIndentGuide.background1",act,m("editorIndentGuides1","Color of the editor indentation guides (1).")),IOe=R("editorIndentGuide.background2","#00000000",m("editorIndentGuides2","Color of the editor indentation guides (2).")),EOe=R("editorIndentGuide.background3","#00000000",m("editorIndentGuides3","Color of the editor indentation guides (3).")),TOe=R("editorIndentGuide.background4","#00000000",m("editorIndentGuides4","Color of the editor indentation guides (4).")),DOe=R("editorIndentGuide.background5","#00000000",m("editorIndentGuides5","Color of the editor indentation guides (5).")),NOe=R("editorIndentGuide.background6","#00000000",m("editorIndentGuides6","Color of the editor indentation guides (6).")),DC=R("editorIndentGuide.activeBackground1",lct,m("editorActiveIndentGuide1","Color of the active editor indentation guides (1).")),ROe=R("editorIndentGuide.activeBackground2","#00000000",m("editorActiveIndentGuide2","Color of the active editor indentation guides (2).")),AOe=R("editorIndentGuide.activeBackground3","#00000000",m("editorActiveIndentGuide3","Color of the active editor indentation guides (3).")),MOe=R("editorIndentGuide.activeBackground4","#00000000",m("editorActiveIndentGuide4","Color of the active editor indentation guides (4).")),POe=R("editorIndentGuide.activeBackground5","#00000000",m("editorActiveIndentGuide5","Color of the active editor indentation guides (5).")),OOe=R("editorIndentGuide.activeBackground6","#00000000",m("editorActiveIndentGuide6","Color of the active editor indentation guides (6).")),cct=R("editorActiveLineNumber.foreground",{dark:"#c6c6c6",light:"#0B216F",hcDark:Zi,hcLight:Zi},m("editorActiveLineNumber","Color of editor active line number"),!1,m("deprecatedEditorActiveLineNumber","Id is deprecated. Use 'editorLineNumber.activeForeground' instead.")),Ati=R("editorLineNumber.activeForeground",cct,m("editorActiveLineNumber","Color of editor active line number")),FOe=R("editorLineNumber.dimmedForeground",null,m("editorDimmedLineNumber","Color of the final editor line when editor.renderFinalNewline is set to dimmed.")),Mti=R("editorRuler.foreground",{dark:"#5A5A5A",light:Z.lightgrey,hcDark:Z.white,hcLight:"#292929"},m("editorRuler","Color of the editor rulers.")),Pti=R("editorCodeLens.foreground",{dark:"#999999",light:"#919191",hcDark:"#999999",hcLight:"#292929"},m("editorCodeLensForeground","Foreground color of editor CodeLens")),Oti=R("editorBracketMatch.background",{dark:"#0064001a",light:"#0064001a",hcDark:"#0064001a",hcLight:"#0000"},m("editorBracketMatchBackground","Background color behind matching brackets")),Fti=R("editorBracketMatch.border",{dark:"#888",light:"#B9B9B9",hcDark:jt,hcLight:jt},m("editorBracketMatchBorder","Color for matching brackets boxes")),BOe=R("editorOverviewRuler.border",{dark:"#7f7f7f4d",light:"#7f7f7f4d",hcDark:"#7f7f7f4d",hcLight:"#666666"},m("editorOverviewRulerBorder","Color of the overview ruler border.")),WOe=R("editorOverviewRuler.background",null,m("editorOverviewRulerBackground","Background color of the editor overview ruler.")),Bti=R("editorGutter.background",$c,m("editorGutter","Background color of the editor gutter. The gutter contains the glyph margins and the line numbers.")),Wti=R("editorUnnecessaryCode.border",{dark:null,light:null,hcDark:Z.fromHex("#fff").transparent(.8),hcLight:jt},m("unnecessaryCodeBorder","Border color of unnecessary (unused) source code in the editor.")),HOe=R("editorUnnecessaryCode.opacity",{dark:Z.fromHex("#000a"),light:Z.fromHex("#0007"),hcDark:null,hcLight:null},m("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.`)),Hti=R("editorGhostText.border",{dark:null,light:null,hcDark:Z.fromHex("#fff").transparent(.8),hcLight:Z.fromHex("#292929").transparent(.8)},m("editorGhostTextBorder","Border color of ghost text in the editor.")),zOe=R("editorGhostText.foreground",{dark:Z.fromHex("#ffffff56"),light:Z.fromHex("#0007"),hcDark:null,hcLight:null},m("editorGhostTextForeground","Foreground color of the ghost text in the editor.")),zti=R("editorGhostText.background",null,m("editorGhostTextBackground","Background color of the ghost text in the editor.")),dct=new Z(new Ut(0,122,204,.6)),RW=R("editorOverviewRuler.rangeHighlightForeground",dct,m("overviewRulerRangeHighlight","Overview ruler marker color for range highlights. The color must not be opaque so as not to hide underlying decorations."),!0),VOe=R("editorOverviewRuler.errorForeground",{dark:new Z(new Ut(255,18,18,.7)),light:new Z(new Ut(255,18,18,.7)),hcDark:new Z(new Ut(255,50,50,1)),hcLight:"#B5200D"},m("overviewRuleError","Overview ruler marker color for errors.")),UOe=R("editorOverviewRuler.warningForeground",{dark:Lu,light:Lu,hcDark:$x,hcLight:$x},m("overviewRuleWarning","Overview ruler marker color for warnings.")),$Oe=R("editorOverviewRuler.infoForeground",{dark:jc,light:jc,hcDark:jx,hcLight:jx},m("overviewRuleInfo","Overview ruler marker color for infos.")),AW=R("editorBracketHighlight.foreground1",{dark:"#FFD700",light:"#0431FAFF",hcDark:"#FFD700",hcLight:"#0431FAFF"},m("editorBracketHighlightForeground1","Foreground color of brackets (1). Requires enabling bracket pair colorization.")),MW=R("editorBracketHighlight.foreground2",{dark:"#DA70D6",light:"#319331FF",hcDark:"#DA70D6",hcLight:"#319331FF"},m("editorBracketHighlightForeground2","Foreground color of brackets (2). Requires enabling bracket pair colorization.")),PW=R("editorBracketHighlight.foreground3",{dark:"#179FFF",light:"#7B3814FF",hcDark:"#87CEFA",hcLight:"#7B3814FF"},m("editorBracketHighlightForeground3","Foreground color of brackets (3). Requires enabling bracket pair colorization.")),OW=R("editorBracketHighlight.foreground4","#00000000",m("editorBracketHighlightForeground4","Foreground color of brackets (4). Requires enabling bracket pair colorization.")),FW=R("editorBracketHighlight.foreground5","#00000000",m("editorBracketHighlightForeground5","Foreground color of brackets (5). Requires enabling bracket pair colorization.")),BW=R("editorBracketHighlight.foreground6","#00000000",m("editorBracketHighlightForeground6","Foreground color of brackets (6). Requires enabling bracket pair colorization.")),jOe=R("editorBracketHighlight.unexpectedBracket.foreground",{dark:new Z(new Ut(255,18,18,.8)),light:new Z(new Ut(255,18,18,.8)),hcDark:"new Color(new RGBA(255, 50, 50, 1))",hcLight:"#B5200D"},m("editorBracketHighlightUnexpectedBracketForeground","Foreground color of unexpected brackets.")),qOe=R("editorBracketPairGuide.background1","#00000000",m("editorBracketPairGuide.background1","Background color of inactive bracket pair guides (1). Requires enabling bracket pair guides.")),KOe=R("editorBracketPairGuide.background2","#00000000",m("editorBracketPairGuide.background2","Background color of inactive bracket pair guides (2). Requires enabling bracket pair guides.")),GOe=R("editorBracketPairGuide.background3","#00000000",m("editorBracketPairGuide.background3","Background color of inactive bracket pair guides (3). Requires enabling bracket pair guides.")),YOe=R("editorBracketPairGuide.background4","#00000000",m("editorBracketPairGuide.background4","Background color of inactive bracket pair guides (4). Requires enabling bracket pair guides.")),ZOe=R("editorBracketPairGuide.background5","#00000000",m("editorBracketPairGuide.background5","Background color of inactive bracket pair guides (5). Requires enabling bracket pair guides.")),XOe=R("editorBracketPairGuide.background6","#00000000",m("editorBracketPairGuide.background6","Background color of inactive bracket pair guides (6). Requires enabling bracket pair guides.")),QOe=R("editorBracketPairGuide.activeBackground1","#00000000",m("editorBracketPairGuide.activeBackground1","Background color of active bracket pair guides (1). Requires enabling bracket pair guides.")),JOe=R("editorBracketPairGuide.activeBackground2","#00000000",m("editorBracketPairGuide.activeBackground2","Background color of active bracket pair guides (2). Requires enabling bracket pair guides.")),e4e=R("editorBracketPairGuide.activeBackground3","#00000000",m("editorBracketPairGuide.activeBackground3","Background color of active bracket pair guides (3). Requires enabling bracket pair guides.")),t4e=R("editorBracketPairGuide.activeBackground4","#00000000",m("editorBracketPairGuide.activeBackground4","Background color of active bracket pair guides (4). Requires enabling bracket pair guides.")),i4e=R("editorBracketPairGuide.activeBackground5","#00000000",m("editorBracketPairGuide.activeBackground5","Background color of active bracket pair guides (5). Requires enabling bracket pair guides.")),n4e=R("editorBracketPairGuide.activeBackground6","#00000000",m("editorBracketPairGuide.activeBackground6","Background color of active bracket pair guides (6). Requires enabling bracket pair guides.")),Vti=R("editorUnicodeHighlight.border",Lu,m("editorUnicodeHighlight.border","Border color used to highlight unicode characters.")),Uti=R("editorUnicodeHighlight.background",oAe,m("editorUnicodeHighlight.background","Background color used to highlight unicode characters."));wr((n,e)=>{let t=n.getColor($c),i=n.getColor(_le),o=i&&!i.isTransparent()?i:t;o&&e.addRule(`.monaco-editor .inputarea.ime-input { background-color: ${o}; }`)})});function o4e(n,e){let t=[],i=[];for(let o of n)e.has(o)||t.push(o);for(let o of e)n.has(o)||i.push(o);return{removed:t,added:i}}function r4e(n,e){let t=new Set;for(let i of e)n.has(i)&&t.add(i);return t}var vle=k(()=>{});var uct,s4e,WW,xle,a4e=k(()=>{gg();j();Zr();Yi();Nu();va();we();ds();Ie();Wn();Ds();vle();uct=function(n,e,t,i){var o=arguments.length,r=o<3?e:i===null?i=Object.getOwnPropertyDescriptor(e,t):i,s;if(typeof Reflect=="object"&&typeof Reflect.decorate=="function")r=Reflect.decorate(n,e,t,i);else for(var a=n.length-1;a>=0;a--)(s=n[a])&&(r=(o<3?s(r):o>3?s(e,t,r):s(e,t))||r);return o>3&&r&&Object.defineProperty(e,t,r),r},s4e=function(n,e){return function(t,i){e(t,i,n)}},WW=class extends D{constructor(e,t){super(),this._markerService=t,this._onDidChangeMarker=this._register(new A),this._markerDecorations=new Fo,e.getModels().forEach(i=>this._onModelAdded(i)),this._register(e.onModelAdded(this._onModelAdded,this)),this._register(e.onModelRemoved(this._onModelRemoved,this)),this._register(this._markerService.onMarkerChanged(this._handleMarkerChange,this))}dispose(){super.dispose(),this._markerDecorations.forEach(e=>e.dispose()),this._markerDecorations.clear()}getMarker(e,t){let i=this._markerDecorations.get(e);return i&&i.getMarker(t)||null}_handleMarkerChange(e){e.forEach(t=>{let i=this._markerDecorations.get(t);i&&this._updateDecorations(i)})}_onModelAdded(e){let t=new xle(e);this._markerDecorations.set(e.uri,t),this._updateDecorations(t)}_onModelRemoved(e){let t=this._markerDecorations.get(e.uri);t&&(t.dispose(),this._markerDecorations.delete(e.uri)),(e.uri.scheme===rt.inMemory||e.uri.scheme===rt.internal||e.uri.scheme===rt.vscode)&&this._markerService?.read({resource:e.uri}).map(i=>i.owner).forEach(i=>this._markerService.remove(i,[e.uri]))}_updateDecorations(e){let t=this._markerService.read({resource:e.model.uri,take:500});e.update(t)&&this._onDidChangeMarker.fire(e.model)}};WW=uct([s4e(0,di),s4e(1,Xc)],WW);xle=class extends D{constructor(e){super(),this.model=e,this._map=new R6,this._register(ge(()=>{this.model.deltaDecorations([...this._map.values()],[]),this._map.clear()}))}update(e){let{added:t,removed:i}=o4e(new Set(this._map.keys()),new Set(e));if(t.length===0&&i.length===0)return!1;let o=i.map(a=>this._map.get(a)),r=t.map(a=>({range:this._createDecorationRange(this.model,a),options:this._createDecorationOption(a)})),s=this.model.deltaDecorations(o,r);for(let a of i)this._map.delete(a);for(let a=0;a=o)return i;let r=e.getWordAtPosition(i.getStartPosition());r&&(i=new S(i.startLineNumber,r.startColumn,i.endLineNumber,r.endColumn))}else if(t.endColumn===Number.MAX_VALUE&&t.startColumn===1&&i.startLineNumber===i.endLineNumber){let o=e.getLineFirstNonWhitespaceColumn(t.startLineNumber);o=0:!1}}});var DI,HW=k(()=>{Fe();DI=We("markerDecorationsService")});var Un,Tf=k(()=>{Qe();Un=class n{static _nextVisibleColumn(e,t,i){return e===9?n.nextRenderTabStop(t,i):hh(e)||XR(e)?t+2:t+1}static visibleColumnFromColumn(e,t,i){let o=Math.min(t-1,e.length),r=e.substring(0,o),s=new y1(r),a=0;for(;!s.eol();){let l=nL(r,o,s.offset);s.nextGraphemeLength(),a=this._nextVisibleColumn(l,a,i)}return a}static columnFromVisibleColumn(e,t,i){if(t<=0)return 1;let o=e.length,r=new y1(e),s=0,a=1;for(;!r.eol();){let l=nL(e,o,r.offset);r.nextGraphemeLength();let c=this._nextVisibleColumn(l,s,i),d=r.offset+1;if(c>=t){let u=t-s;return c-t{Qe();Tf()});var KM,wle,VW,l4e=k(()=>{KM=class{constructor(e,t,i,o){this.range=e,this.nestingLevel=t,this.nestingLevelOfEqualBracketType=i,this.isInvalid=o}},wle=class{constructor(e,t,i,o,r,s){this.range=e,this.openingBracketRange=t,this.closingBracketRange=i,this.nestingLevel=o,this.nestingLevelOfEqualBracketType=r,this.bracketPairNode=s}get openingBracketInfo(){return this.bracketPairNode.openingBracket.bracketInfo}},VW=class extends wle{constructor(e,t,i,o,r,s,a){super(e,t,i,o,r,s),this.minVisibleColumnIndentation=a}}});function c4e(n,e,t,i){return n!==t?Do(t-n,i):Do(0,i-e)}function RI(n){return n===0}function Do(n,e){return n*Ru+e}function pc(n){let e=n,t=Math.floor(e/Ru),i=e-t*Ru;return new xa(t,i)}function d4e(n){return Math.floor(n/Ru)}function En(n,e){let t=n+e;return e>=Ru&&(t=t-n%Ru),t}function u4e(n,e){return n.reduce((t,i)=>En(t,e(i)),gs)}function yle(n,e){return n===e}function NC(n,e){let t=n,i=e;if(i-t<=0)return gs;let r=Math.floor(t/Ru),s=Math.floor(i/Ru),a=i-s*Ru;if(r===s){let l=t-r*Ru;return Do(0,a-l)}else return Do(s-r,a)}function Cb(n,e){return n=e}function mw(n){return Do(n.lineNumber-1,n.column-1)}function gw(n,e){let t=n,i=Math.floor(t/Ru),o=t-i*Ru,r=e,s=Math.floor(r/Ru),a=r-s*Ru;return new S(i+1,o+1,s+1,a+1)}function h4e(n){let e=Qa(n);return Do(e.length-1,e[e.length-1].length)}var gs,Ru,_g=k(()=>{Qe();we();ib();gs=0;Ru=2**26});var Df,UW,Cle,GM=k(()=>{we();_g();Df=class n{static fromModelContentChanges(e){return e.map(i=>{let o=S.lift(i.range);return new n(mw(o.getStartPosition()),mw(o.getEndPosition()),h4e(i.text))}).reverse()}constructor(e,t,i){this.startOffset=e,this.endOffset=t,this.newLength=i}toString(){return`[${pc(this.startOffset)}...${pc(this.endOffset)}) -> ${pc(this.newLength)}`}},UW=class{constructor(e){this.nextEditIdx=0,this.deltaOldToNewLineCount=0,this.deltaOldToNewColumnCount=0,this.deltaLineIdxInOld=-1,this.edits=e.map(t=>Cle.from(t))}getOffsetBeforeChange(e){return this.adjustNextEdit(e),this.translateCurToOld(e)}getDistanceToNextChange(e){this.adjustNextEdit(e);let t=this.edits[this.nextEditIdx],i=t?this.translateOldToCur(t.offsetObj):null;return i===null?null:NC(e,i)}translateOldToCur(e){return e.lineCount===this.deltaLineIdxInOld?Do(e.lineCount+this.deltaOldToNewLineCount,e.columnCount+this.deltaOldToNewColumnCount):Do(e.lineCount+this.deltaOldToNewLineCount,e.columnCount)}translateCurToOld(e){let t=pc(e);return t.lineCount-this.deltaOldToNewLineCount===this.deltaLineIdxInOld?Do(t.lineCount-this.deltaOldToNewLineCount,t.columnCount-this.deltaOldToNewColumnCount):Do(t.lineCount-this.deltaOldToNewLineCount,t.columnCount)}adjustNextEdit(e){for(;this.nextEditIdx{$W=[],rl=class n{static{this.cache=new Array(129)}static create(e,t){if(e<=128&&t.length===0){let i=n.cache[e];return i||(i=new n(e,t),n.cache[e]=i),i}return new n(e,t)}static{this.empty=n.create(0,$W)}static getEmpty(){return this.empty}constructor(e,t){this.items=e,this.additionalItems=t}add(e,t){let i=t.getKey(e),o=i>>5;if(o===0){let s=1<{je();Tf();_g();RC();YM=class{get length(){return this._length}constructor(e){this._length=e}},ZM=class n extends YM{static create(e,t,i){let o=e.length;return t&&(o=En(o,t.length)),i&&(o=En(o,i.length)),new n(o,e,t,i,t?t.missingOpeningBracketIds:rl.getEmpty())}get kind(){return 2}get listHeight(){return 0}get childrenLength(){return 3}getChild(e){switch(e){case 0:return this.openingBracket;case 1:return this.child;case 2:return this.closingBracket}throw new Error("Invalid child index")}get children(){let e=[];return e.push(this.openingBracket),this.child&&e.push(this.child),this.closingBracket&&e.push(this.closingBracket),e}constructor(e,t,i,o,r){super(e),this.openingBracket=t,this.child=i,this.closingBracket=o,this.missingOpeningBracketIds=r}canBeReused(e){return!(this.closingBracket===null||e.intersects(this.missingOpeningBracketIds))}deepClone(){return new n(this.length,this.openingBracket.deepClone(),this.child&&this.child.deepClone(),this.closingBracket&&this.closingBracket.deepClone(),this.missingOpeningBracketIds)}computeMinIndentation(e,t){return this.child?this.child.computeMinIndentation(En(e,this.openingBracket.length),t):Number.MAX_SAFE_INTEGER}},Au=class extends YM{static create23(e,t,i,o=!1){let r=e.length,s=e.missingOpeningBracketIds;if(e.listHeight!==t.listHeight)throw new Error("Invalid list heights");if(r=En(r,t.length),s=s.merge(t.missingOpeningBracketIds),i){if(e.listHeight!==i.listHeight)throw new Error("Invalid list heights");r=En(r,i.length),s=s.merge(i.missingOpeningBracketIds)}return o?new kle(r,e.listHeight+1,e,t,i,s):new XM(r,e.listHeight+1,e,t,i,s)}static getEmpty(){return new Lle(gs,0,[],rl.getEmpty())}get kind(){return 4}get missingOpeningBracketIds(){return this._missingOpeningBracketIds}constructor(e,t,i){super(e),this.listHeight=t,this._missingOpeningBracketIds=i,this.cachedMinIndentation=-1}throwIfImmutable(){}makeLastElementMutable(){this.throwIfImmutable();let e=this.childrenLength;if(e===0)return;let t=this.getChild(e-1),i=t.kind===4?t.toMutable():t;return t!==i&&this.setChild(e-1,i),i}makeFirstElementMutable(){if(this.throwIfImmutable(),this.childrenLength===0)return;let t=this.getChild(0),i=t.kind===4?t.toMutable():t;return t!==i&&this.setChild(0,i),i}canBeReused(e){if(e.intersects(this.missingOpeningBracketIds)||this.childrenLength===0)return!1;let t=this;for(;t.kind===4;){let i=t.childrenLength;if(i===0)throw new Nt;t=t.getChild(i-1)}return t.canBeReused(e)}handleChildrenChanged(){this.throwIfImmutable();let e=this.childrenLength,t=this.getChild(0).length,i=this.getChild(0).missingOpeningBracketIds;for(let o=1;o{je();tC();e2();_g();RC();Tp=class{constructor(e,t,i,o,r){this.length=e,this.kind=t,this.bracketId=i,this.bracketIds=o,this.astNode=r}},PI=class{constructor(e,t){this.textModel=e,this.bracketTokens=t,this.reader=new Ile(this.textModel,this.bracketTokens),this._offset=gs,this.didPeek=!1,this.peeked=null,this.textBufferLineCount=e.getLineCount(),this.textBufferLastLineLength=e.getLineLength(this.textBufferLineCount)}get offset(){return this._offset}get length(){return Do(this.textBufferLineCount-1,this.textBufferLastLineLength)}skip(e){this.didPeek=!1,this._offset=En(this._offset,e);let t=pc(this._offset);this.reader.setPosition(t.lineCount,t.columnCount)}read(){let e;return this.peeked?(this.didPeek=!1,e=this.peeked):e=this.reader.read(),e&&(this._offset=En(this._offset,e.length)),e}peek(){return this.didPeek||(this.peeked=this.reader.read(),this.didPeek=!0),this.peeked}},Ile=class{constructor(e,t){this.textModel=e,this.bracketTokens=t,this.lineIdx=0,this.line=null,this.lineCharOffset=0,this.lineTokens=null,this.lineTokenOffset=0,this.peekedToken=null,this.textBufferLineCount=e.getLineCount(),this.textBufferLastLineLength=e.getLineLength(this.textBufferLineCount)}setPosition(e,t){e===this.lineIdx?(this.lineCharOffset=t,this.line!==null&&(this.lineTokenOffset=this.lineCharOffset===0?0:this.lineTokens.findTokenIndexAtOffset(this.lineCharOffset))):(this.lineIdx=e,this.lineCharOffset=t,this.line=null),this.peekedToken=null}read(){if(this.peekedToken){let r=this.peekedToken;return this.peekedToken=null,this.lineCharOffset+=r.length,r}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));let e=this.lineIdx,t=this.lineCharOffset,i=0;for(;;){let r=this.lineTokens,s=r.getCount(),a=null;if(this.lineTokenOffset1e3))break;if(i>1500)break}let o=c4e(e,t,this.lineIdx,this.lineCharOffset);return new Tp(o,0,-1,rl.getEmpty(),new Ep(o))}},KW=class{constructor(e,t){this.text=e,this._offset=gs,this.idx=0;let i=t.getRegExpStr(),o=i?new RegExp(i+`| `,"gi"):null,r=[],s,a=0,l=0,c=0,d=0,u=[];for(let p=0;p<60;p++)u.push(new Tp(Do(0,p),0,-1,rl.getEmpty(),new Ep(Do(0,p))));let h=[];for(let p=0;p<60;p++)h.push(new Tp(Do(1,p),0,-1,rl.getEmpty(),new Ep(Do(1,p))));if(o)for(o.lastIndex=0;(s=o.exec(e))!==null;){let p=s.index,g=s[0];if(g===` `)a++,l=p+1;else{if(c!==p){let _;if(d===a){let b=p-c;if(b{Qe();e2();_g();RC();GW();Ele=class n{static createFromLanguage(e,t){function i(r){return t.getKey(`${r.languageId}:::${r.bracketText}`)}let o=new Map;for(let r of e.bracketsNew.openingBrackets){let s=Do(0,r.bracketText.length),a=i(r),l=rl.getEmpty().add(a,Sle);o.set(r.bracketText,new Tp(s,1,a,l,JM.create(s,r,l)))}for(let r of e.bracketsNew.closingBrackets){let s=Do(0,r.bracketText.length),a=rl.getEmpty(),l=r.getOpeningBrackets();for(let c of l)a=a.add(i(c),Sle);o.set(r.bracketText,new Tp(s,2,i(l[0]),a,JM.create(s,r,a)))}return new n(o)}constructor(e){this.map=e,this.hasRegExp=!1,this._regExpGlobal=null}getRegExpStr(){if(this.isEmpty)return null;{let e=[...this.map.keys()];return e.sort(),e.reverse(),e.map(t=>mct(t)).join("|")}}get regExpGlobal(){if(!this.hasRegExp){let e=this.getRegExpStr();this._regExpGlobal=e?new RegExp(e,"gi"):null,this.hasRegExp=!0}return this._regExpGlobal}getToken(e){return this.map.get(e.toLowerCase())}findClosingTokenText(e){for(let[t,i]of this.map)if(i.kind===2&&i.bracketIds.intersects(e))return t}get isEmpty(){return this.map.size===0}};OI=class{constructor(e,t){this.denseKeyProvider=e,this.getLanguageConfiguration=t,this.languageIdToBracketTokens=new Map}didLanguageChange(e){return this.languageIdToBracketTokens.has(e)}getSingleLanguageBracketTokens(e){let t=this.languageIdToBracketTokens.get(e);return t||(t=Ele.createFromLanguage(this.getLanguageConfiguration(e),this.denseKeyProvider),this.languageIdToBracketTokens.set(e,t)),t}}});function p4e(n){if(n.length===0)return null;if(n.length===1)return n[0];let e=0;function t(){if(e>=n.length)return null;let s=e,a=n[s].listHeight;for(e++;e=2?Nle(s===0&&e===n.length?n:n.slice(s,e),!1):n[s]}let i=t(),o=t();if(!o)return i;for(let s=t();s;s=t())f4e(i,o)<=f4e(o,s)?(i=Dle(i,o),o=s):o=Dle(o,s);return Dle(i,o)}function Nle(n,e=!1){if(n.length===0)return null;if(n.length===1)return n[0];let t=n.length;for(;t>3;){let i=t>>1;for(let o=0;o=3?n[2]:null,e)}function f4e(n,e){return Math.abs(n.listHeight-e.listHeight)}function Dle(n,e){return n.listHeight===e.listHeight?Au.create23(n,e,null,!1):n.listHeight>e.listHeight?gct(n,e):_ct(e,n)}function gct(n,e){n=n.toMutable();let t=n,i=[],o;for(;;){if(e.listHeight===t.listHeight){o=e;break}if(t.kind!==4)throw new Error("unexpected");i.push(t),t=t.makeLastElementMutable()}for(let r=i.length-1;r>=0;r--){let s=i[r];o?s.childrenLength>=3?o=Au.create23(s.unappendChild(),o,null,!1):(s.appendChildOfSameHeight(o),o=void 0):s.handleChildrenChanged()}return o?Au.create23(n,o,null,!1):n}function _ct(n,e){n=n.toMutable();let t=n,i=[];for(;e.listHeight!==t.listHeight;){if(t.kind!==4)throw new Error("unexpected");i.push(t),t=t.makeFirstElementMutable()}let o=e;for(let r=i.length-1;r>=0;r--){let s=i[r];o?s.childrenLength>=3?o=Au.create23(o,s.unprependChild(),null,!1):(s.prependChildOfSameHeight(o),o=void 0):s.handleChildrenChanged()}return o?Au.create23(o,n,null,!1):n}var m4e=k(()=>{e2()});function Rle(n,e=-1){for(;;){if(e++,e>=n.childrenLength)return-1;if(n.getChild(e))return e}}function t2(n){return n.length>0?n[n.length-1]:void 0}var YW,g4e=k(()=>{_g();YW=class{constructor(e){this.lastOffset=gs,this.nextNodes=[e],this.offsets=[gs],this.idxs=[]}readLongestNodeAt(e,t){if(Cb(e,this.lastOffset))throw new Error("Invalid offset");for(this.lastOffset=e;;){let i=t2(this.nextNodes);if(!i)return;let o=t2(this.offsets);if(Cb(e,o))return;if(Cb(o,e))if(En(o,i.length)<=e)this.nextNodeAfterCurrent();else{let r=Rle(i);r!==-1?(this.nextNodes.push(i.getChild(r)),this.offsets.push(o),this.idxs.push(r)):this.nextNodeAfterCurrent()}else{if(t(i))return this.nextNodeAfterCurrent(),i;{let r=Rle(i);if(r===-1){this.nextNodeAfterCurrent();return}else this.nextNodes.push(i.getChild(r)),this.offsets.push(o),this.idxs.push(r)}}}}nextNodeAfterCurrent(){for(;;){let e=t2(this.offsets),t=t2(this.nextNodes);if(this.nextNodes.pop(),this.offsets.pop(),this.idxs.length===0)break;let i=t2(this.nextNodes),o=Rle(i,this.idxs[this.idxs.length-1]);if(o!==-1){this.nextNodes.push(i.getChild(o)),this.offsets.push(En(e,t.length)),this.idxs[this.idxs.length-1]=o;break}else this.idxs.pop()}}}});function i2(n,e,t,i){return new Ale(n,e,t,i).parseDocument()}var Ale,Mle=k(()=>{e2();GM();RC();_g();m4e();g4e();Ale=class{constructor(e,t,i,o){if(this.tokenizer=e,this.createImmutableLists=o,this._itemsConstructed=0,this._itemsFromCache=0,i&&o)throw new Error("Not supported");this.oldNodeReader=i?new YW(i):void 0,this.positionMapper=new UW(t)}parseDocument(){this._itemsConstructed=0,this._itemsFromCache=0;let e=this.parseList(rl.getEmpty(),0);return e||(e=Au.getEmpty()),e}parseList(e,t){let i=[];for(;;){let r=this.tryReadChildFromCache(e);if(!r){let s=this.tokenizer.peek();if(!s||s.kind===2&&s.bracketIds.intersects(e))break;r=this.parseChild(e,t+1)}r.kind===4&&r.childrenLength===0||i.push(r)}return this.oldNodeReader?p4e(i):Nle(i,this.createImmutableLists)}tryReadChildFromCache(e){if(this.oldNodeReader){let t=this.positionMapper.getDistanceToNextChange(this.tokenizer.offset);if(t===null||!RI(t)){let i=this.oldNodeReader.readLongestNodeAt(this.positionMapper.getOffsetBeforeChange(this.tokenizer.offset),o=>t!==null&&!Cb(o.length,t)?!1:o.canBeReused(e));if(i)return this._itemsFromCache++,this.tokenizer.skip(i.length),i}}}parseChild(e,t){this._itemsConstructed++;let i=this.tokenizer.read();switch(i.kind){case 2:return new qW(i.bracketIds,i.length);case 0:return i.astNode;case 1:{if(t>300)return new Ep(i.length);let o=e.merge(i.bracketIds),r=this.parseList(o,t+1),s=this.tokenizer.peek();return s&&s.kind===2&&(s.bracketId===i.bracketId||s.bracketIds.intersects(i.bracketIds))?(this.tokenizer.read(),ZM.create(i.astNode,r,s.astNode)):ZM.create(i.astNode,r,null)}default:throw new Error("unexpected")}}}});function FI(n,e){if(n.length===0)return e;if(e.length===0)return n;let t=new wl(_4e(n)),i=_4e(e);i.push({modified:!1,lengthBefore:void 0,lengthAfter:void 0});let o=t.dequeue();function r(c){if(c===void 0){let u=t.takeWhile(h=>!0)||[];return o&&u.unshift(o),u}let d=[];for(;o&&!RI(c);){let[u,h]=o.splitAt(c);d.push(u),c=NC(u.lengthAfter,c),o=h??t.dequeue()}return RI(c)||d.push(new n2(!1,c,c)),d}let s=[];function a(c,d,u){if(s.length>0&&yle(s[s.length-1].endOffset,c)){let h=s[s.length-1];s[s.length-1]=new Df(h.startOffset,d,En(h.newLength,u))}else s.push({startOffset:c,endOffset:d,newLength:u})}let l=gs;for(let c of i){let d=r(c.lengthBefore);if(c.modified){let u=u4e(d,f=>f.lengthBefore),h=En(l,u);a(l,h,c.lengthAfter),l=h}else for(let u of d){let h=l;l=En(l,u.lengthBefore),u.modified&&a(h,l,u.lengthAfter)}}return s}function _4e(n){let e=[],t=gs;for(let i of n){let o=NC(t,i.startOffset);RI(o)||e.push(new n2(!1,o,o));let r=NC(i.startOffset,i.endOffset);e.push(new n2(!0,r,i.newLength)),t=i.endOffset}return e}var n2,Ple=k(()=>{at();GM();_g();n2=class n{constructor(e,t,i){this.modified=e,this.lengthBefore=t,this.lengthAfter=i}splitAt(e){let t=NC(e,this.lengthAfter);return yle(t,gs)?[this,void 0]:this.modified?[new n(this.modified,this.lengthBefore,e),new n(this.modified,gs,t)]:[new n(this.modified,e,e),new n(this.modified,t,t)]}toString(){return`${this.modified?"M":"U"}:${pc(this.lengthBefore)} -> ${pc(this.lengthAfter)}`}}});function b4e(n,e,t,i){if(n.kind===4||n.kind===2){let o=[];for(let r of n.children)t=En(e,r.length),o.push({nodeOffsetStart:e,nodeOffsetEnd:t}),e=t;for(let r=o.length-1;r>=0;r--){let{nodeOffsetStart:s,nodeOffsetEnd:a}=o[r];if(Cb(s,i)){let l=b4e(n.children[r],s,a,i);if(l)return l}}return null}else{if(n.kind===3)return null;if(n.kind===1){let o=gw(e,t);return{bracketInfo:n.bracketInfo,range:o}}}return null}function v4e(n,e,t,i){if(n.kind===4||n.kind===2){for(let o of n.children){if(t=En(e,o.length),Cb(i,t)){let r=v4e(o,e,t,i);if(r)return r}e=t}return null}else{if(n.kind===3)return null;if(n.kind===1){let o=gw(e,t);return{bracketInfo:n.bracketInfo,range:o}}}return null}function Ole(n,e,t,i,o,r,s,a,l,c,d=!1){if(s>200)return!0;e:for(;;)switch(n.kind){case 4:{let u=n.childrenLength;for(let h=0;h200)return!0;let l=!0;if(n.kind===2){let c=0;if(a){let h=a.get(n.openingBracket.text);h===void 0&&(h=0),c=h,h++,a.set(n.openingBracket.text,h)}let d=En(e,n.openingBracket.length),u=-1;if(r.includeMinIndentation&&(u=n.computeMinIndentation(e,r.textModel)),l=r.push(new VW(gw(e,t),gw(e,d),n.closingBracket?gw(En(d,n.child?.length||gs),t):void 0,s,c,n,u)),e=d,l&&n.child){let h=n.child;if(t=En(e,h.length),pw(e,o)&&AI(t,i)&&(l=Ble(h,e,t,i,o,r,s+1,a),!l))return!1}a?.set(n.openingBracket.text,c)}else{let c=e;for(let d of n.children){let u=c;if(c=En(c,d.length),pw(u,o)&&pw(i,c)&&(l=Ble(d,u,c,i,o,r,s,a),!l))return!1}}return l}var ZW,Fle,x4e=k(()=>{Ie();j();l4e();GM();Tle();_g();Mle();RC();GW();at();Ple();ZW=class extends D{didLanguageChange(e){return this.brackets.didLanguageChange(e)}constructor(e,t){if(super(),this.textModel=e,this.getLanguageConfiguration=t,this.didChangeEmitter=new A,this.denseKeyProvider=new MI,this.brackets=new OI(this.denseKeyProvider,this.getLanguageConfiguration),this.onDidChange=this.didChangeEmitter.event,this.queuedTextEditsForInitialAstWithoutTokens=[],this.queuedTextEdits=[],e.tokenization.hasTokens)e.tokenization.backgroundTokenizationState===2?(this.initialAstWithoutTokens=void 0,this.astWithTokens=this.parseDocumentFromTextBuffer([],void 0,!1)):(this.initialAstWithoutTokens=this.parseDocumentFromTextBuffer([],void 0,!0),this.astWithTokens=this.initialAstWithoutTokens);else{let i=this.brackets.getSingleLanguageBracketTokens(this.textModel.getLanguageId()),o=new KW(this.textModel.getValue(),i);this.initialAstWithoutTokens=i2(o,[],void 0,!0),this.astWithTokens=this.initialAstWithoutTokens}}handleDidChangeBackgroundTokenizationState(){if(this.textModel.tokenization.backgroundTokenizationState===2){let e=this.initialAstWithoutTokens===void 0;this.initialAstWithoutTokens=void 0,e||this.didChangeEmitter.fire()}}handleDidChangeTokens({ranges:e}){let t=e.map(i=>new Df(Do(i.fromLineNumber-1,0),Do(i.toLineNumber,0),Do(i.toLineNumber-i.fromLineNumber+1,0)));this.handleEdits(t,!0),this.initialAstWithoutTokens||this.didChangeEmitter.fire()}handleContentChanged(e){let t=Df.fromModelContentChanges(e.changes);this.handleEdits(t,!1)}handleEdits(e,t){let i=FI(this.queuedTextEdits,e);this.queuedTextEdits=i,this.initialAstWithoutTokens&&!t&&(this.queuedTextEditsForInitialAstWithoutTokens=FI(this.queuedTextEditsForInitialAstWithoutTokens,e))}flushQueue(){this.queuedTextEdits.length>0&&(this.astWithTokens=this.parseDocumentFromTextBuffer(this.queuedTextEdits,this.astWithTokens,!1),this.queuedTextEdits=[]),this.queuedTextEditsForInitialAstWithoutTokens.length>0&&(this.initialAstWithoutTokens&&(this.initialAstWithoutTokens=this.parseDocumentFromTextBuffer(this.queuedTextEditsForInitialAstWithoutTokens,this.initialAstWithoutTokens,!1)),this.queuedTextEditsForInitialAstWithoutTokens=[])}parseDocumentFromTextBuffer(e,t,i){let r=t,s=new PI(this.textModel,this.brackets);return i2(s,e,r,i)}getBracketsInRange(e,t){this.flushQueue();let i=Do(e.startLineNumber-1,e.startColumn-1),o=Do(e.endLineNumber-1,e.endColumn-1);return new A_(r=>{let s=this.initialAstWithoutTokens||this.astWithTokens;Ole(s,gs,s.length,i,o,r,0,0,new Map,t)})}getBracketPairsInRange(e,t){this.flushQueue();let i=mw(e.getStartPosition()),o=mw(e.getEndPosition());return new A_(r=>{let s=this.initialAstWithoutTokens||this.astWithTokens,a=new Fle(r,t,this.textModel);Ble(s,gs,s.length,i,o,a,0,new Map)})}getFirstBracketAfter(e){this.flushQueue();let t=this.initialAstWithoutTokens||this.astWithTokens;return v4e(t,gs,t.length,mw(e))}getFirstBracketBefore(e){this.flushQueue();let t=this.initialAstWithoutTokens||this.astWithTokens;return b4e(t,gs,t.length,mw(e))}};Fle=class{constructor(e,t,i){this.push=e,this.includeMinIndentation=t,this.textModel=i}}});function bct(n,e){return{object:n,dispose:()=>e?.dispose()}}function Wle(n){if(typeof n>"u")return()=>!0;{let e=Date.now();return()=>Date.now()-e<=n}}function XW(n){return n instanceof Sb?null:n}var QW,Sb,w4e=k(()=>{at();Ie();j();we();vL();yA();x4e();QW=class extends D{get canBuildAST(){return this.textModel.getValueLength()<=5e6}constructor(e,t){super(),this.textModel=e,this.languageConfigurationService=t,this.bracketPairsTree=this._register(new Hi),this.onDidChangeEmitter=new A,this.onDidChange=this.onDidChangeEmitter.event,this.bracketsRequested=!1}handleLanguageConfigurationServiceChange(e){(!e.languageId||this.bracketPairsTree.value?.object.didLanguageChange(e.languageId))&&(this.bracketPairsTree.clear(),this.updateBracketPairsTree())}handleDidChangeOptions(e){this.bracketPairsTree.clear(),this.updateBracketPairsTree()}handleDidChangeLanguage(e){this.bracketPairsTree.clear(),this.updateBracketPairsTree()}handleDidChangeContent(e){this.bracketPairsTree.value?.object.handleContentChanged(e)}handleDidChangeBackgroundTokenizationState(){this.bracketPairsTree.value?.object.handleDidChangeBackgroundTokenizationState()}handleDidChangeTokens(e){this.bracketPairsTree.value?.object.handleDidChangeTokens(e)}updateBracketPairsTree(){if(this.bracketsRequested&&this.canBuildAST){if(!this.bracketPairsTree.value){let e=new H;this.bracketPairsTree.value=bct(e.add(new ZW(this.textModel,t=>this.languageConfigurationService.getLanguageConfiguration(t))),e),e.add(this.bracketPairsTree.value.object.onDidChange(t=>this.onDidChangeEmitter.fire(t))),this.onDidChangeEmitter.fire()}}else this.bracketPairsTree.value&&(this.bracketPairsTree.clear(),this.onDidChangeEmitter.fire())}getBracketPairsInRange(e){return this.bracketsRequested=!0,this.updateBracketPairsTree(),this.bracketPairsTree.value?.object.getBracketPairsInRange(e,!1)||A_.empty}getBracketPairsInRangeWithMinIndentation(e){return this.bracketsRequested=!0,this.updateBracketPairsTree(),this.bracketPairsTree.value?.object.getBracketPairsInRange(e,!0)||A_.empty}getBracketsInRange(e,t=!1){return this.bracketsRequested=!0,this.updateBracketPairsTree(),this.bracketPairsTree.value?.object.getBracketsInRange(e,t)||A_.empty}findMatchingBracketUp(e,t,i){let o=this.textModel.validatePosition(t),r=this.textModel.getLanguageIdAtPosition(o.lineNumber,o.column);if(this.canBuildAST){let s=this.languageConfigurationService.getLanguageConfiguration(r).bracketsNew.getClosingBracketInfo(e);if(!s)return null;let a=this.getBracketPairsInRange(S.fromPositions(t,t)).findLast(l=>s.closes(l.openingBracketInfo));return a?a.openingBracketRange:null}else{let s=e.toLowerCase(),a=this.languageConfigurationService.getLanguageConfiguration(r).brackets;if(!a)return null;let l=a.textIsBracket[s];return l?XW(this._findMatchingBracketUp(l,o,Wle(i))):null}}matchBracket(e,t){if(this.canBuildAST){let i=this.getBracketPairsInRange(S.fromPositions(e,e)).filter(o=>o.closingBracketRange!==void 0&&(o.openingBracketRange.containsPosition(e)||o.closingBracketRange.containsPosition(e))).findLastMaxBy(mr(o=>o.openingBracketRange.containsPosition(e)?o.openingBracketRange:o.closingBracketRange,S.compareRangesUsingStarts));return i?[i.openingBracketRange,i.closingBracketRange]:null}else{let i=Wle(t);return this._matchBracket(this.textModel.validatePosition(e),i)}}_establishBracketSearchOffsets(e,t,i,o){let r=t.getCount(),s=t.getLanguageId(o),a=Math.max(0,e.column-1-i.maxBracketLength);for(let c=o-1;c>=0;c--){let d=t.getEndOffset(c);if(d<=a)break;if(xf(t.getStandardTokenType(c))||t.getLanguageId(c)!==s){a=d;break}}let l=Math.min(t.getLineContent().length,e.column-1+i.maxBracketLength);for(let c=o+1;c=l)break;if(xf(t.getStandardTokenType(c))||t.getLanguageId(c)!==s){l=d;break}}return{searchStartOffset:a,searchEndOffset:l}}_matchBracket(e,t){let i=e.lineNumber,o=this.textModel.tokenization.getLineTokens(i),r=this.textModel.getLineContent(i),s=o.findTokenIndexAtOffset(e.column-1);if(s<0)return null;let a=this.languageConfigurationService.getLanguageConfiguration(o.getLanguageId(s)).brackets;if(a&&!xf(o.getStandardTokenType(s))){let{searchStartOffset:l,searchEndOffset:c}=this._establishBracketSearchOffsets(e,o,a,s),d=null;for(;;){let u=zc.findNextBracketInRange(a.forwardRegex,i,r,l,c);if(!u)break;if(u.startColumn<=e.column&&e.column<=u.endColumn){let h=r.substring(u.startColumn-1,u.endColumn-1).toLowerCase(),f=this._matchFoundBracket(u,a.textIsBracket[h],a.textIsOpenBracket[h],t);if(f){if(f instanceof Sb)return null;d=f}}l=u.endColumn-1}if(d)return d}if(s>0&&o.getStartOffset(s)===e.column-1){let l=s-1,c=this.languageConfigurationService.getLanguageConfiguration(o.getLanguageId(l)).brackets;if(c&&!xf(o.getStandardTokenType(l))){let{searchStartOffset:d,searchEndOffset:u}=this._establishBracketSearchOffsets(e,o,c,l),h=zc.findPrevBracketInRange(c.reversedRegex,i,r,d,u);if(h&&h.startColumn<=e.column&&e.column<=h.endColumn){let f=r.substring(h.startColumn-1,h.endColumn-1).toLowerCase(),p=this._matchFoundBracket(h,c.textIsBracket[f],c.textIsOpenBracket[f],t);if(p)return p instanceof Sb?null:p}}}return null}_matchFoundBracket(e,t,i,o){if(!t)return null;let r=i?this._findMatchingBracketDown(t,e.getEndPosition(),o):this._findMatchingBracketUp(t,e.getStartPosition(),o);return r?r instanceof Sb?r:[e,r]:null}_findMatchingBracketUp(e,t,i){let o=e.languageId,r=e.reversedRegex,s=-1,a=0,l=(c,d,u,h)=>{for(;;){if(i&&++a%100===0&&!i())return Sb.INSTANCE;let f=zc.findPrevBracketInRange(r,c,d,u,h);if(!f)break;let p=d.substring(f.startColumn-1,f.endColumn-1).toLowerCase();if(e.isOpen(p)?s++:e.isClose(p)&&s--,s===0)return f;h=f.startColumn-1}return null};for(let c=t.lineNumber;c>=1;c--){let d=this.textModel.tokenization.getLineTokens(c),u=d.getCount(),h=this.textModel.getLineContent(c),f=u-1,p=h.length,g=h.length;c===t.lineNumber&&(f=d.findTokenIndexAtOffset(t.column-1),p=t.column-1,g=t.column-1);let _=!0;for(;f>=0;f--){let b=d.getLanguageId(f)===o&&!xf(d.getStandardTokenType(f));if(b)_?p=d.getStartOffset(f):(p=d.getStartOffset(f),g=d.getEndOffset(f));else if(_&&p!==g){let v=l(c,h,p,g);if(v)return v}_=b}if(_&&p!==g){let b=l(c,h,p,g);if(b)return b}}return null}_findMatchingBracketDown(e,t,i){let o=e.languageId,r=e.forwardRegex,s=1,a=0,l=(d,u,h,f)=>{for(;;){if(i&&++a%100===0&&!i())return Sb.INSTANCE;let p=zc.findNextBracketInRange(r,d,u,h,f);if(!p)break;let g=u.substring(p.startColumn-1,p.endColumn-1).toLowerCase();if(e.isOpen(g)?s++:e.isClose(g)&&s--,s===0)return p;h=p.endColumn-1}return null},c=this.textModel.getLineCount();for(let d=t.lineNumber;d<=c;d++){let u=this.textModel.tokenization.getLineTokens(d),h=u.getCount(),f=this.textModel.getLineContent(d),p=0,g=0,_=0;d===t.lineNumber&&(p=u.findTokenIndexAtOffset(t.column-1),g=t.column-1,_=t.column-1);let b=!0;for(;p=1;s--){let a=this.textModel.tokenization.getLineTokens(s),l=a.getCount(),c=this.textModel.getLineContent(s),d=l-1,u=c.length,h=c.length;if(s===t.lineNumber){d=a.findTokenIndexAtOffset(t.column-1),u=t.column-1,h=t.column-1;let p=a.getLanguageId(d);i!==p&&(i=p,o=this.languageConfigurationService.getLanguageConfiguration(i).brackets,r=this.languageConfigurationService.getLanguageConfiguration(i).bracketsNew)}let f=!0;for(;d>=0;d--){let p=a.getLanguageId(d);if(i!==p){if(o&&r&&f&&u!==h){let _=zc.findPrevBracketInRange(o.reversedRegex,s,c,u,h);if(_)return this._toFoundBracket(r,_);f=!1}i=p,o=this.languageConfigurationService.getLanguageConfiguration(i).brackets,r=this.languageConfigurationService.getLanguageConfiguration(i).bracketsNew}let g=!!o&&!xf(a.getStandardTokenType(d));if(g)f?u=a.getStartOffset(d):(u=a.getStartOffset(d),h=a.getEndOffset(d));else if(r&&o&&f&&u!==h){let _=zc.findPrevBracketInRange(o.reversedRegex,s,c,u,h);if(_)return this._toFoundBracket(r,_)}f=g}if(r&&o&&f&&u!==h){let p=zc.findPrevBracketInRange(o.reversedRegex,s,c,u,h);if(p)return this._toFoundBracket(r,p)}}return null}findNextBracket(e){let t=this.textModel.validatePosition(e);if(this.canBuildAST)return this.bracketsRequested=!0,this.updateBracketPairsTree(),this.bracketPairsTree.value?.object.getFirstBracketAfter(t)||null;let i=this.textModel.getLineCount(),o=null,r=null,s=null;for(let a=t.lineNumber;a<=i;a++){let l=this.textModel.tokenization.getLineTokens(a),c=l.getCount(),d=this.textModel.getLineContent(a),u=0,h=0,f=0;if(a===t.lineNumber){u=l.findTokenIndexAtOffset(t.column-1),h=t.column-1,f=t.column-1;let g=l.getLanguageId(u);o!==g&&(o=g,r=this.languageConfigurationService.getLanguageConfiguration(o).brackets,s=this.languageConfigurationService.getLanguageConfiguration(o).bracketsNew)}let p=!0;for(;ug.closingBracketRange!==void 0&&g.range.strictContainsRange(f));return p?[p.openingBracketRange,p.closingBracketRange]:null}let o=Wle(t),r=this.textModel.getLineCount(),s=new Map,a=[],l=(f,p)=>{if(!s.has(f)){let g=[];for(let _=0,b=p?p.brackets.length:0;_{for(;;){if(o&&++c%100===0&&!o())return Sb.INSTANCE;let v=zc.findNextBracketInRange(f.forwardRegex,p,g,_,b);if(!v)break;let x=g.substring(v.startColumn-1,v.endColumn-1).toLowerCase(),w=f.textIsBracket[x];if(w&&(w.isOpen(x)?a[w.index]++:w.isClose(x)&&a[w.index]--,a[w.index]===-1))return this._matchFoundBracket(v,w,!1,o);_=v.endColumn-1}return null},u=null,h=null;for(let f=i.lineNumber;f<=r;f++){let p=this.textModel.tokenization.getLineTokens(f),g=p.getCount(),_=this.textModel.getLineContent(f),b=0,v=0,x=0;if(f===i.lineNumber){b=p.findTokenIndexAtOffset(i.column-1),v=i.column-1,x=i.column-1;let y=p.getLanguageId(b);u!==y&&(u=y,h=this.languageConfigurationService.getLanguageConfiguration(u).brackets,l(u,h))}let w=!0;for(;b{Ie();j();we();Nu();Yi();JW=class extends D{constructor(e){super(),this.textModel=e,this.colorProvider=new eH,this.onDidChangeEmitter=new A,this.onDidChange=this.onDidChangeEmitter.event,this.colorizationOptions=e.getOptions().bracketPairColorizationOptions,this._register(e.bracketPairs.onDidChange(t=>{this.onDidChangeEmitter.fire()}))}handleDidChangeOptions(e){this.colorizationOptions=this.textModel.getOptions().bracketPairColorizationOptions}getDecorationsInRange(e,t,i,o){return o?[]:t===void 0?[]:this.colorizationOptions.enabled?this.textModel.bracketPairs.getBracketsInRange(e,!0).map(s=>({id:`bracket${s.range.toString()}-${s.nestingLevel}`,options:{description:"BracketPairColorization",inlineClassName:this.colorProvider.getInlineClassName(s,this.colorizationOptions.independentColorPoolPerBracketType)},ownerId:0,range:s.range})).toArray():[]}getAllDecorations(e,t){return e===void 0?[]:this.colorizationOptions.enabled?this.getDecorationsInRange(new S(1,1,this.textModel.getLineCount(),1),e,t):[]}},eH=class{constructor(){this.unexpectedClosingBracketClassName="unexpected-closing-bracket"}getInlineClassName(e,t){return e.isInvalid?this.unexpectedClosingBracketClassName:this.getInlineClassNameOfLevel(t?e.nestingLevelOfEqualBracketType:e.nestingLevel)}getInlineClassNameOfLevel(e){return`bracket-highlighting-${e%30}`}};wr((n,e)=>{let t=[AW,MW,PW,OW,FW,BW],i=new eH;e.addRule(`.monaco-editor .${i.unexpectedClosingBracketClassName} { color: ${n.getColor(jOe)}; }`);let o=t.map(r=>n.getColor(r)).filter(r=>!!r).filter(r=>!r.isTransparent());for(let r=0;r<30;r++){let s=o[r%o.length];e.addRule(`.monaco-editor .${i.getInlineClassNameOfLevel(r)} { color: ${s}; }`)}})});function tH(n){return n.replace(/\n/g,"\\n").replace(/\r/g,"\\r")}function C4e(n,e){return n===null||n.length===0?e:new Hle(n,e).compress()}var Mu,Hle,zle=k(()=>{wL();Y_();Mu=class n{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}constructor(e,t,i,o){this.oldPosition=e,this.oldText=t,this.newPosition=i,this.newText=o}toString(){return this.oldText.length===0?`(insert@${this.oldPosition} "${tH(this.newText)}")`:this.newText.length===0?`(delete@${this.oldPosition} "${tH(this.oldText)}")`:`(replace@${this.oldPosition} "${tH(this.oldText)}" with "${tH(this.newText)}")`}static _writeStringSize(e){return 4+2*e.length}static _writeString(e,t,i){let o=t.length;wh(e,o,i),i+=4;for(let r=0;r{pe();je();Ui();Ai();zle();wL();ia();Bd=class n{static create(e,t){let i=e.getAlternativeVersionId(),o=Ule(e);return new n(i,i,o,o,t,t,[])}constructor(e,t,i,o,r,s,a){this.beforeVersionId=e,this.afterVersionId=t,this.beforeEOL=i,this.afterEOL=o,this.beforeCursorState=r,this.afterCursorState=s,this.changes=a}append(e,t,i,o,r){t.length>0&&(this.changes=C4e(this.changes,t)),this.afterEOL=i,this.afterVersionId=o,this.afterCursorState=r}static _writeSelectionsSize(e){return 4+4*4*(e?e.length:0)}static _writeSelections(e,t,i){if(wh(e,t?t.length:0,i),i+=4,t)for(let o of t)wh(e,o.selectionStartLineNumber,i),i+=4,wh(e,o.selectionStartColumn,i),i+=4,wh(e,o.positionLineNumber,i),i+=4,wh(e,o.positionColumn,i),i+=4;return i}static _readSelections(e,t,i){let o=xh(e,t);t+=4;for(let r=0;rt.toString()).join(", ")}matchesResource(e){return(Ee.isUri(this.model)?this.model:this.model.uri).toString()===e.toString()}setModel(e){this.model=e}canAppend(e){return this.model===e&&this._data instanceof Bd}append(e,t,i,o,r){this._data instanceof Bd&&this._data.append(e,t,i,o,r)}close(){this._data instanceof Bd&&(this._data=this._data.serialize())}open(){this._data instanceof Bd||(this._data=Bd.deserialize(this._data))}undo(){if(Ee.isUri(this.model))throw new Error("Invalid SingleModelEditStackElement");this._data instanceof Bd&&(this._data=this._data.serialize());let e=Bd.deserialize(this._data);this.model._applyUndo(e.changes,e.beforeEOL,e.beforeVersionId,e.beforeCursorState)}redo(){if(Ee.isUri(this.model))throw new Error("Invalid SingleModelEditStackElement");this._data instanceof Bd&&(this._data=this._data.serialize());let e=Bd.deserialize(this._data);this.model._applyRedo(e.changes,e.afterEOL,e.afterVersionId,e.afterCursorState)}heapSize(){return this._data instanceof Bd&&(this._data=this._data.serialize()),this._data.byteLength+168}},Vle=class{get resources(){return this._editStackElementsArr.map(e=>e.resource)}constructor(e,t,i){this.label=e,this.code=t,this.type=1,this._isOpen=!0,this._editStackElementsArr=i.slice(0),this._editStackElementsMap=new Map;for(let o of this._editStackElementsArr){let r=BI(o.resource);this._editStackElementsMap.set(r,o)}this._delegate=null}prepareUndoRedo(){if(this._delegate)return this._delegate.prepareUndoRedo(this)}matchesResource(e){let t=BI(e);return this._editStackElementsMap.has(t)}setModel(e){let t=BI(Ee.isUri(e)?e:e.uri);this._editStackElementsMap.has(t)&&this._editStackElementsMap.get(t).setModel(e)}canAppend(e){if(!this._isOpen)return!1;let t=BI(e.uri);return this._editStackElementsMap.has(t)?this._editStackElementsMap.get(t).canAppend(e):!1}append(e,t,i,o,r){let s=BI(e.uri);this._editStackElementsMap.get(s).append(e,t,i,o,r)}close(){this._isOpen=!1}open(){}undo(){this._isOpen=!1;for(let e of this._editStackElementsArr)e.undo()}redo(){for(let e of this._editStackElementsArr)e.redo()}heapSize(e){let t=BI(e);return this._editStackElementsMap.has(t)?this._editStackElementsMap.get(t).heapSize():0}split(){return this._editStackElementsArr}toString(){let e=[];for(let t of this._editStackElementsArr)e.push(`${ta(t.resource)}: ${t}`);return`{${e.join(", ")}}`}};nH=class n{constructor(e,t){this._model=e,this._undoRedoService=t}pushStackElement(){let e=this._undoRedoService.getLastElement(this._model.uri);bg(e)&&e.close()}popStackElement(){let e=this._undoRedoService.getLastElement(this._model.uri);bg(e)&&e.open()}clear(){this._undoRedoService.removeElements(this._model.uri)}_getOrCreateEditStackElement(e,t){let i=this._undoRedoService.getLastElement(this._model.uri);if(bg(i)&&i.canAppend(this._model))return i;let o=new iH(m("edit","Typing"),"undoredo.textBufferEdit",this._model,e);return this._undoRedoService.pushElement(o,t),o}pushEOL(e){let t=this._getOrCreateEditStackElement(null,void 0);this._model.setEOL(e),t.append(this._model,[],Ule(this._model),this._model.getAlternativeVersionId(),null)}pushEditOperation(e,t,i,o){let r=this._getOrCreateEditStackElement(e,o),s=this._model.applyEdits(t,!0),a=n._computeCursorState(i,s),l=s.map((c,d)=>({index:d,textChange:c.textChange}));return l.sort((c,d)=>c.textChange.oldPosition===d.textChange.oldPosition?c.index-d.index:c.textChange.oldPosition-d.textChange.oldPosition),r.append(this._model,l.map(c=>c.textChange),Ule(this._model),this._model.getAlternativeVersionId(),a),a}static _computeCursorState(e,t){try{return e?e(t):null}catch(i){return Be(i),null}}}});var WI,jle=k(()=>{j();WI=class extends D{constructor(){super(...arguments),this._isDisposed=!1}dispose(){super.dispose(),this._isDisposed=!0}assertNotDisposed(){if(this._isDisposed)throw new Error("TextModelPart is disposed!")}}});function AC(n,e){let t=0,i=0,o=n.length;for(;i{});var kb,Nf,Lb,rH=k(()=>{(function(n){n[n.Disabled=0]="Disabled",n[n.EnabledForActive=1]="EnabledForActive",n[n.Enabled=2]="Enabled"})(kb||(kb={}));Nf=class{constructor(e,t,i,o,r,s){if(this.visibleColumn=e,this.column=t,this.className=i,this.horizontalLine=o,this.forWrappedLinesAfterColumn=r,this.forWrappedLinesBeforeOrAtColumn=s,e!==-1==(t!==-1))throw new Error}},Lb=class{constructor(e,t){this.top=e,this.endColumn=t}}});var sH,o2,qle=k(()=>{Ad();Qe();Tf();we();jle();oH();rH();je();sH=class extends WI{constructor(e,t){super(),this.textModel=e,this.languageConfigurationService=t}getLanguageConfiguration(e){return this.languageConfigurationService.getLanguageConfiguration(e)}_computeIndentLevel(e){return AC(this.textModel.getLineContent(e+1),this.textModel.getOptions().tabSize)}getActiveIndentGuide(e,t,i){this.assertNotDisposed();let o=this.textModel.getLineCount();if(e<1||e>o)throw new Nt("Illegal value for lineNumber");let r=this.getLanguageConfiguration(this.textModel.getLanguageId()).foldingRules,s=!!(r&&r.offSide),a=-2,l=-1,c=-2,d=-1,u=L=>{if(a!==-1&&(a===-2||a>L-1)){a=-1,l=-1;for(let E=L-2;E>=0;E--){let N=this._computeIndentLevel(E);if(N>=0){a=E,l=N;break}}}if(c===-2){c=-1,d=-1;for(let E=L;E=0){c=E,d=N;break}}}},h=-2,f=-1,p=-2,g=-1,_=L=>{if(h===-2){h=-1,f=-1;for(let E=L-2;E>=0;E--){let N=this._computeIndentLevel(E);if(N>=0){h=E,f=N;break}}}if(p!==-1&&(p===-2||p=0){p=E,g=N;break}}}},b=0,v=!0,x=0,w=!0,y=0,C=0;for(let L=0;v||w;L++){let E=e-L,N=e+L;L>1&&(E<1||E1&&(N>o||N>i)&&(w=!1),L>5e4&&(v=!1,w=!1);let M=-1;if(v&&E>=1){let q=this._computeIndentLevel(E-1);q>=0?(c=E-1,d=q,M=Math.ceil(q/this.textModel.getOptions().indentSize)):(u(E),M=this._getIndentLevelForWhitespaceLine(s,l,d))}let F=-1;if(w&&N<=o){let q=this._computeIndentLevel(N-1);q>=0?(h=N-1,f=q,F=Math.ceil(q/this.textModel.getOptions().indentSize)):(_(N),F=this._getIndentLevelForWhitespaceLine(s,f,g))}if(L===0){C=M;continue}if(L===1){if(N<=o&&F>=0&&C+1===F){v=!1,b=N,x=N,y=F;continue}if(E>=1&&M>=0&&M-1===C){w=!1,b=E,x=E,y=M;continue}if(b=e,x=e,y=C,y===0)return{startLineNumber:b,endLineNumber:x,indent:y}}v&&(M>=y?b=E:v=!1),w&&(F>=y?x=N:w=!1)}return{startLineNumber:b,endLineNumber:x,indent:y}}getLinesBracketGuides(e,t,i,o){let r=[];for(let u=e;u<=t;u++)r.push([]);let s=!0,a=this.textModel.bracketPairs.getBracketPairsInRangeWithMinIndentation(new S(e,1,t,this.textModel.getLineMaxColumn(t))).toArray(),l;if(i&&a.length>0){let u=(e<=i.lineNumber&&i.lineNumber<=t?a:this.textModel.bracketPairs.getBracketPairsInRange(S.fromPositions(i)).toArray()).filter(h=>S.strictContainsPosition(h.range,i));l=eb(u,h=>s||h.range.startLineNumber!==h.range.endLineNumber)?.range}let c=this.textModel.getOptions().bracketPairColorizationOptions.independentColorPoolPerBracketType,d=new o2;for(let u of a){if(!u.closingBracketRange)continue;let h=l&&u.range.equalsRange(l);if(!h&&!o.includeInactive)continue;let f=d.getInlineClassName(u.nestingLevel,u.nestingLevelOfEqualBracketType,c)+(o.highlightActive&&h?" "+d.activeClassName:""),p=u.openingBracketRange.getStartPosition(),g=u.closingBracketRange.getStartPosition(),_=o.horizontalGuides===kb.Enabled||o.horizontalGuides===kb.EnabledForActive&&h;if(u.range.startLineNumber===u.range.endLineNumber){s&&_&&r[u.range.startLineNumber-e].push(new Nf(-1,u.openingBracketRange.getEndPosition().column,f,new Lb(!1,g.column),-1,-1));continue}let b=this.getVisibleColumnFromPosition(g),v=this.getVisibleColumnFromPosition(u.openingBracketRange.getStartPosition()),x=Math.min(v,b,u.minVisibleColumnIndentation+1),w=!1;bo(this.textModel.getLineContent(u.closingBracketRange.startLineNumber))=e&&v>x&&r[p.lineNumber-e].push(new Nf(x,-1,f,new Lb(!1,p.column),-1,-1)),g.lineNumber<=t&&b>x&&r[g.lineNumber-e].push(new Nf(x,-1,f,new Lb(!w,g.column),-1,-1)))}for(let u of r)u.sort((h,f)=>h.visibleColumn-f.visibleColumn);return r}getVisibleColumnFromPosition(e){return Un.visibleColumnFromColumn(this.textModel.getLineContent(e.lineNumber),e.column,this.textModel.getOptions().tabSize)+1}getLinesIndentGuides(e,t){this.assertNotDisposed();let i=this.textModel.getLineCount();if(e<1||e>i)throw new Error("Illegal value for startLineNumber");if(t<1||t>i)throw new Error("Illegal value for endLineNumber");let o=this.textModel.getOptions(),r=this.getLanguageConfiguration(this.textModel.getLanguageId()).foldingRules,s=!!(r&&r.offSide),a=new Array(t-e+1),l=-2,c=-1,d=-2,u=-1;for(let h=e;h<=t;h++){let f=h-e,p=this._computeIndentLevel(h-1);if(p>=0){l=h-1,c=p,a[f]=Math.ceil(p/o.indentSize);continue}if(l===-2){l=-1,c=-1;for(let g=h-2;g>=0;g--){let _=this._computeIndentLevel(g);if(_>=0){l=g,c=_;break}}}if(d!==-1&&(d===-2||d=0){d=g,u=_;break}}}a[f]=this._getIndentLevelForWhitespaceLine(s,c,u)}return a}_getIndentLevelForWhitespaceLine(e,t,i){let o=this.textModel.getOptions();return t===-1||i===-1?0:t0&&a>0||l>0&&c>0)return;let d=Math.abs(a-c),u=Math.abs(s-l);if(d===0){o.spacesDiff=u,u>0&&0<=l-1&&l-10?o++:w>1&&r++,vct(s,a,_,x,u),u.looksLikeAlignment&&!(t&&e===u.spacesDiff)))continue;let C=u.spacesDiff;C<=c&&d[C]++,s=_,a=x}let h=t;o!==r&&(h=o{let _=d[g];_>p&&(p=_,f=g)}),f===4&&d[4]>0&&d[2]>0&&d[2]>=d[4]/2&&(f=2)}return{insertSpaces:h,tabSize:f}}var Kle,S4e=k(()=>{Kle=class{constructor(){this.spacesDiff=0,this.looksLikeAlignment=!1}}});function Qc(n){return(n.metadata&1)>>>0}function Yn(n,e){n.metadata=n.metadata&254|e<<0}function Sa(n){return(n.metadata&2)>>>1===1}function $n(n,e){n.metadata=n.metadata&253|(e?1:0)<<1}function N4e(n){return(n.metadata&4)>>>2===1}function k4e(n,e){n.metadata=n.metadata&251|(e?1:0)<<2}function R4e(n){return(n.metadata&64)>>>6===1}function L4e(n,e){n.metadata=n.metadata&191|(e?1:0)<<6}function xct(n){return(n.metadata&24)>>>3}function I4e(n,e){n.metadata=n.metadata&231|e<<3}function wct(n){return(n.metadata&32)>>>5===1}function E4e(n,e){n.metadata=n.metadata&223|(e?1:0)<<5}function yct(n){let e=n.root,t=0;for(;e!==ii;){if(e.left!==ii&&!Sa(e.left)){e=e.left;continue}if(e.right!==ii&&!Sa(e.right)){t+=e.delta,e=e.right;continue}e.start=t+e.start,e.end=t+e.end,e.delta=0,Ib(e),$n(e,!0),$n(e.left,!1),$n(e.right,!1),e===e.parent.right&&(t-=e.parent.delta),e=e.parent}$n(n.root,!1)}function HI(n,e,t,i){return nt||i===1?!1:i===2?!0:e}function Cct(n,e,t,i,o){let r=xct(n),s=r===0||r===2,a=r===1||r===2,l=t-e,c=i,d=Math.min(l,c),u=n.start,h=!1,f=n.end,p=!1;e<=u&&f<=t&&wct(n)&&(n.start=e,h=!0,n.end=e,p=!0);{let _=o?1:l>0?2:0;!h&&HI(u,s,e,_)&&(h=!0),!p&&HI(f,a,e,_)&&(p=!0)}if(d>0&&!o){let _=l>c?2:0;!h&&HI(u,s,e+d,_)&&(h=!0),!p&&HI(f,a,e+d,_)&&(p=!0)}{let _=o?1:0;!h&&HI(u,s,t,_)&&(n.start=e+c,h=!0),!p&&HI(f,a,t,_)&&(n.end=e+c,p=!0)}let g=c-l;h||(n.start=Math.max(0,u+g)),p||(n.end=Math.max(0,f+g)),n.start>n.end&&(n.end=n.start)}function Sct(n,e,t){let i=n.root,o=0,r=0,s=0,a=0,l=[],c=0;for(;i!==ii;){if(Sa(i)){$n(i.left,!1),$n(i.right,!1),i===i.parent.right&&(o-=i.parent.delta),i=i.parent;continue}if(!Sa(i.left)){if(r=o+i.maxEnd,rt){$n(i,!0);continue}if(a=o+i.end,a>=e&&(i.setCachedOffsets(s,a,0),l[c++]=i),$n(i,!0),i.right!==ii&&!Sa(i.right)){o+=i.delta,i=i.right;continue}}return $n(n.root,!1),l}function kct(n,e,t,i){let o=n.root,r=0,s=0,a=0,l=i-(t-e);for(;o!==ii;){if(Sa(o)){$n(o.left,!1),$n(o.right,!1),o===o.parent.right&&(r-=o.parent.delta),Ib(o),o=o.parent;continue}if(!Sa(o.left)){if(s=r+o.maxEnd,st){o.start+=l,o.end+=l,o.delta+=l,(o.delta<-1073741824||o.delta>1073741824)&&(n.requestNormalizeDelta=!0),$n(o,!0);continue}if($n(o,!0),o.right!==ii&&!Sa(o.right)){r+=o.delta,o=o.right;continue}}$n(n.root,!1)}function Lct(n,e){let t=n.root,i=[],o=0;for(;t!==ii;){if(Sa(t)){$n(t.left,!1),$n(t.right,!1),t=t.parent;continue}if(t.left!==ii&&!Sa(t.left)){t=t.left;continue}if(t.ownerId===e&&(i[o++]=t),$n(t,!0),t.right!==ii&&!Sa(t.right)){t=t.right;continue}}return $n(n.root,!1),i}function Ict(n){let e=n.root,t=[],i=0;for(;e!==ii;){if(Sa(e)){$n(e.left,!1),$n(e.right,!1),e=e.parent;continue}if(e.left!==ii&&!Sa(e.left)){e=e.left;continue}if(e.right!==ii&&!Sa(e.right)){e=e.right;continue}t[i++]=e,$n(e,!0)}return $n(n.root,!1),t}function Ect(n,e,t,i,o){let r=n.root,s=0,a=0,l=0,c=[],d=0;for(;r!==ii;){if(Sa(r)){$n(r.left,!1),$n(r.right,!1),r===r.parent.right&&(s-=r.parent.delta),r=r.parent;continue}if(r.left!==ii&&!Sa(r.left)){r=r.left;continue}a=s+r.start,l=s+r.end,r.setCachedOffsets(a,l,i);let u=!0;if(e&&r.ownerId&&r.ownerId!==e&&(u=!1),t&&N4e(r)&&(u=!1),o&&!R4e(r)&&(u=!1),u&&(c[d++]=r),$n(r,!0),r.right!==ii&&!Sa(r.right)){s+=r.delta,r=r.right;continue}}return $n(n.root,!1),c}function Tct(n,e,t,i,o,r,s){let a=n.root,l=0,c=0,d=0,u=0,h=[],f=0;for(;a!==ii;){if(Sa(a)){$n(a.left,!1),$n(a.right,!1),a===a.parent.right&&(l-=a.parent.delta),a=a.parent;continue}if(!Sa(a.left)){if(c=l+a.maxEnd,ct){$n(a,!0);continue}if(u=l+a.end,u>=e){a.setCachedOffsets(d,u,r);let p=!0;i&&a.ownerId&&a.ownerId!==i&&(p=!1),o&&N4e(a)&&(p=!1),s&&!R4e(a)&&(p=!1),p&&(h[f++]=a)}if($n(a,!0),a.right!==ii&&!Sa(a.right)){l+=a.delta,a=a.right;continue}}return $n(n.root,!1),h}function T4e(n,e){if(n.root===ii)return e.parent=ii,e.left=ii,e.right=ii,Yn(e,0),n.root=e,n.root;Dct(n,e),_w(e.parent);let t=e;for(;t!==n.root&&Qc(t.parent)===1;)if(t.parent===t.parent.parent.left){let i=t.parent.parent.right;Qc(i)===1?(Yn(t.parent,0),Yn(i,0),Yn(t.parent.parent,1),t=t.parent.parent):(t===t.parent.right&&(t=t.parent,r2(n,t)),Yn(t.parent,0),Yn(t.parent.parent,1),s2(n,t.parent.parent))}else{let i=t.parent.parent.left;Qc(i)===1?(Yn(t.parent,0),Yn(i,0),Yn(t.parent.parent,1),t=t.parent.parent):(t===t.parent.left&&(t=t.parent,s2(n,t)),Yn(t.parent,0),Yn(t.parent.parent,1),r2(n,t.parent.parent))}return Yn(n.root,0),e}function Dct(n,e){let t=0,i=n.root,o=e.start,r=e.end;for(;;)if(Rct(o,r,i.start+t,i.end+t)<0)if(i.left===ii){e.start-=t,e.end-=t,e.maxEnd-=t,i.left=e;break}else i=i.left;else if(i.right===ii){e.start-=t+i.delta,e.end-=t+i.delta,e.maxEnd-=t+i.delta,i.right=e;break}else t+=i.delta,i=i.right;e.parent=i,e.left=ii,e.right=ii,Yn(e,1)}function D4e(n,e){let t,i;if(e.left===ii?(t=e.right,i=e,t.delta+=e.delta,(t.delta<-1073741824||t.delta>1073741824)&&(n.requestNormalizeDelta=!0),t.start+=e.delta,t.end+=e.delta):e.right===ii?(t=e.left,i=e):(i=Nct(e.right),t=i.right,t.start+=i.delta,t.end+=i.delta,t.delta+=i.delta,(t.delta<-1073741824||t.delta>1073741824)&&(n.requestNormalizeDelta=!0),i.start+=e.delta,i.end+=e.delta,i.delta=e.delta,(i.delta<-1073741824||i.delta>1073741824)&&(n.requestNormalizeDelta=!0)),i===n.root){n.root=t,Yn(t,0),e.detach(),Yle(),Ib(t),n.root.parent=ii;return}let o=Qc(i)===1;if(i===i.parent.left?i.parent.left=t:i.parent.right=t,i===e?t.parent=i.parent:(i.parent===e?t.parent=i:t.parent=i.parent,i.left=e.left,i.right=e.right,i.parent=e.parent,Yn(i,Qc(e)),e===n.root?n.root=i:e===e.parent.left?e.parent.left=i:e.parent.right=i,i.left!==ii&&(i.left.parent=i),i.right!==ii&&(i.right.parent=i)),e.detach(),o){_w(t.parent),i!==e&&(_w(i),_w(i.parent)),Yle();return}_w(t),_w(t.parent),i!==e&&(_w(i),_w(i.parent));let r;for(;t!==n.root&&Qc(t)===0;)t===t.parent.left?(r=t.parent.right,Qc(r)===1&&(Yn(r,0),Yn(t.parent,1),r2(n,t.parent),r=t.parent.right),Qc(r.left)===0&&Qc(r.right)===0?(Yn(r,1),t=t.parent):(Qc(r.right)===0&&(Yn(r.left,0),Yn(r,1),s2(n,r),r=t.parent.right),Yn(r,Qc(t.parent)),Yn(t.parent,0),Yn(r.right,0),r2(n,t.parent),t=n.root)):(r=t.parent.left,Qc(r)===1&&(Yn(r,0),Yn(t.parent,1),s2(n,t.parent),r=t.parent.left),Qc(r.left)===0&&Qc(r.right)===0?(Yn(r,1),t=t.parent):(Qc(r.left)===0&&(Yn(r.right,0),Yn(r,1),r2(n,r),r=t.parent.left),Yn(r,Qc(t.parent)),Yn(t.parent,0),Yn(r.left,0),s2(n,t.parent),t=n.root));Yn(t,0),Yle()}function Nct(n){for(;n.left!==ii;)n=n.left;return n}function Yle(){ii.parent=ii,ii.delta=0,ii.start=0,ii.end=0}function r2(n,e){let t=e.right;t.delta+=e.delta,(t.delta<-1073741824||t.delta>1073741824)&&(n.requestNormalizeDelta=!0),t.start+=e.delta,t.end+=e.delta,e.right=t.left,t.left!==ii&&(t.left.parent=e),t.parent=e.parent,e.parent===ii?n.root=t:e===e.parent.left?e.parent.left=t:e.parent.right=t,t.left=e,e.parent=t,Ib(e),Ib(t)}function s2(n,e){let t=e.left;e.delta-=t.delta,(e.delta<-1073741824||e.delta>1073741824)&&(n.requestNormalizeDelta=!0),e.start-=t.delta,e.end-=t.delta,e.left=t.right,t.right!==ii&&(t.right.parent=e),t.parent=e.parent,e.parent===ii?n.root=t:e===e.parent.right?e.parent.right=t:e.parent.left=t,t.right=e,e.parent=t,Ib(e),Ib(t)}function A4e(n){let e=n.end;if(n.left!==ii){let t=n.left.maxEnd;t>e&&(e=t)}if(n.right!==ii){let t=n.right.maxEnd+n.delta;t>e&&(e=t)}return e}function Ib(n){n.maxEnd=A4e(n)}function _w(n){for(;n!==ii;){let e=A4e(n);if(n.maxEnd===e)return;n.maxEnd=e,n=n.parent}}function Rct(n,e,t,i){return n===t?e-i:n-t}var a2,ii,zI,M4e=k(()=>{a2=class{constructor(e,t,i){this.metadata=0,this.parent=this,this.left=this,this.right=this,Yn(this,1),this.start=t,this.end=i,this.delta=0,this.maxEnd=i,this.id=e,this.ownerId=0,this.options=null,k4e(this,!1),L4e(this,!1),I4e(this,1),E4e(this,!1),this.cachedVersionId=0,this.cachedAbsoluteStart=t,this.cachedAbsoluteEnd=i,this.range=null,$n(this,!1)}reset(e,t,i,o){this.start=t,this.end=i,this.maxEnd=i,this.cachedVersionId=e,this.cachedAbsoluteStart=t,this.cachedAbsoluteEnd=i,this.range=o}setOptions(e){this.options=e;let t=this.options.className;k4e(this,t==="squiggly-error"||t==="squiggly-warning"||t==="squiggly-info"),L4e(this,this.options.glyphMarginClassName!==null),I4e(this,this.options.stickiness),E4e(this,this.options.collapseOnReplaceEdit)}setCachedOffsets(e,t,i){this.cachedVersionId!==i&&(this.range=null),this.cachedVersionId=i,this.cachedAbsoluteStart=e,this.cachedAbsoluteEnd=t}detach(){this.parent=null,this.left=null,this.right=null}},ii=new a2(null,0,0);ii.parent=ii;ii.left=ii;ii.right=ii;Yn(ii,0);zI=class{constructor(){this.root=ii,this.requestNormalizeDelta=!1}intervalSearch(e,t,i,o,r,s){return this.root===ii?[]:Tct(this,e,t,i,o,r,s)}search(e,t,i,o){return this.root===ii?[]:Ect(this,e,t,i,o)}collectNodesFromOwner(e){return Lct(this,e)}collectNodesPostOrder(){return Ict(this)}insert(e){T4e(this,e),this._normalizeDeltaIfNecessary()}delete(e){D4e(this,e),this._normalizeDeltaIfNecessary()}resolveNode(e,t){let i=e,o=0;for(;e!==this.root;)e===e.parent.right&&(o+=e.parent.delta),e=e.parent;let r=i.start+o,s=i.end+o;i.setCachedOffsets(r,s,t)}acceptReplace(e,t,i,o){let r=Sct(this,e,e+t);for(let s=0,a=r.length;s{VI=class{constructor(e,t){this.piece=e,this.color=t,this.size_left=0,this.lf_left=0,this.parent=this,this.left=this,this.right=this}next(){if(this.right!==Ot)return aH(this.right);let e=this;for(;e.parent!==Ot&&e.parent.left!==e;)e=e.parent;return e.parent===Ot?Ot:e.parent}prev(){if(this.left!==Ot)return Xle(this.left);let e=this;for(;e.parent!==Ot&&e.parent.right!==e;)e=e.parent;return e.parent===Ot?Ot:e.parent}detach(){this.parent=null,this.left=null,this.right=null}},Ot=new VI(null,0);Ot.parent=Ot;Ot.left=Ot;Ot.right=Ot;Ot.color=0});function O4e(n){let e;return n[n.length-1]<65536?e=new Uint16Array(n.length):e=new Uint32Array(n.length),e.set(n,0),e}function xg(n,e=!0){let t=[0],i=1;for(let o=0,r=n.length;o126)&&(s=!1)}let a=new tce(O4e(n),i,o,r,s);return n.length=0,a}var Eb,tce,mc,wg,ice,nce,lH,oce=k(()=>{qe();we();Zr();P4e();DA();Eb=65535;tce=class{constructor(e,t,i,o,r){this.lineStarts=e,this.cr=t,this.lf=i,this.crlf=o,this.isBasicASCII=r}};mc=class{constructor(e,t,i,o,r){this.bufferIndex=e,this.start=t,this.end=i,this.lineFeedCnt=o,this.length=r}},wg=class{constructor(e,t){this.buffer=e,this.lineStarts=t}},ice=class{constructor(e,t){this._pieces=[],this._tree=e,this._BOM=t,this._index=0,e.root!==Ot&&e.iterate(e.root,i=>(i!==Ot&&this._pieces.push(i.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++])}},nce=class{constructor(e){this._limit=e,this._cache=[]}get(e){for(let t=this._cache.length-1;t>=0;t--){let i=this._cache[t];if(i.nodeStartOffset<=e&&i.nodeStartOffset+i.node.piece.length>=e)return i}return null}get2(e){for(let t=this._cache.length-1;t>=0;t--){let i=this._cache[t];if(i.nodeStartLineNumber&&i.nodeStartLineNumber=e)return i}return null}set(e){this._cache.length>=this._limit&&this._cache.shift(),this._cache.push(e)}validate(e){let t=!1,i=this._cache;for(let o=0;o=e){i[o]=null,t=!0;continue}}if(t){let o=[];for(let r of i)r!==null&&o.push(r);this._cache=o}}},lH=class{constructor(e,t,i){this.create(e,t,i)}create(e,t,i){this._buffers=[new wg("",[0])],this._lastChangeBufferPos={line:0,column:0},this.root=Ot,this._lineCnt=1,this._length=0,this._EOL=t,this._EOLLength=t.length,this._EOLNormalized=i;let o=null;for(let r=0,s=e.length;r0){e[r].lineStarts||(e[r].lineStarts=xg(e[r].buffer));let a=new mc(r+1,{line:0,column:0},{line:e[r].lineStarts.length-1,column:e[r].buffer.length-e[r].lineStarts[e[r].lineStarts.length-1]},e[r].lineStarts.length-1,e[r].buffer.length);this._buffers.push(e[r]),o=this.rbInsertRight(o,a)}this._searchCache=new nce(1),this._lastVisitedLine={lineNumber:0,value:""},this.computeBufferMetadata()}normalizeEOL(e){let t=Eb,i=t-Math.floor(t/3),o=i*2,r="",s=0,a=[];if(this.iterate(this.root,l=>{let c=this.getNodeContent(l),d=c.length;if(s<=i||s+d0){let l=r.replace(/\r\n|\r|\n/g,e);a.push(new wg(l,xg(l)))}this.create(a,e,!0)}getEOL(){return this._EOL}setEOL(e){this._EOL=e,this._EOLLength=this._EOL.length,this.normalizeEOL(e)}createSnapshot(e){return new ice(this,e)}getOffsetAt(e,t){let i=0,o=this.root;for(;o!==Ot;)if(o.left!==Ot&&o.lf_left+1>=e)o=o.left;else if(o.lf_left+o.piece.lineFeedCnt+1>=e){i+=o.size_left;let r=this.getAccumulatedValue(o,e-o.lf_left-2);return i+=r+t-1}else e-=o.lf_left+o.piece.lineFeedCnt,i+=o.size_left+o.piece.length,o=o.right;return i}getPositionAt(e){e=Math.floor(e),e=Math.max(0,e);let t=this.root,i=0,o=e;for(;t!==Ot;)if(t.size_left!==0&&t.size_left>=e)t=t.left;else if(t.size_left+t.piece.length>=e){let r=this.getIndexOf(t,e-t.size_left);if(i+=t.lf_left+r.index,r.index===0){let s=this.getOffsetAt(i+1,1),a=o-s;return new P(i+1,a+1)}return new P(i+1,r.remainder+1)}else if(e-=t.size_left+t.piece.length,i+=t.lf_left+t.piece.lineFeedCnt,t.right===Ot){let r=this.getOffsetAt(i+1,1),s=o-e-r;return new P(i+1,s+1)}else t=t.right;return new P(1,1)}getValueInRange(e,t){if(e.startLineNumber===e.endLineNumber&&e.startColumn===e.endColumn)return"";let i=this.nodeAt2(e.startLineNumber,e.startColumn),o=this.nodeAt2(e.endLineNumber,e.endColumn),r=this.getValueInRange2(i,o);return t?t!==this._EOL||!this._EOLNormalized?r.replace(/\r\n|\r|\n/g,t):t===this.getEOL()&&this._EOLNormalized?r:r.replace(/\r\n|\r|\n/g,t):r}getValueInRange2(e,t){if(e.node===t.node){let a=e.node,l=this._buffers[a.piece.bufferIndex].buffer,c=this.offsetInBuffer(a.piece.bufferIndex,a.piece.start);return l.substring(c+e.remainder,c+t.remainder)}let i=e.node,o=this._buffers[i.piece.bufferIndex].buffer,r=this.offsetInBuffer(i.piece.bufferIndex,i.piece.start),s=o.substring(r+e.remainder,r+i.piece.length);for(i=i.next();i!==Ot;){let a=this._buffers[i.piece.bufferIndex].buffer,l=this.offsetInBuffer(i.piece.bufferIndex,i.piece.start);if(i===t.node){s+=a.substring(l,l+t.remainder);break}else s+=a.substr(l,i.piece.length);i=i.next()}return s}getLinesContent(){let e=[],t=0,i="",o=!1;return this.iterate(this.root,r=>{if(r===Ot)return!0;let s=r.piece,a=s.length;if(a===0)return!0;let l=this._buffers[s.bufferIndex].buffer,c=this._buffers[s.bufferIndex].lineStarts,d=s.start.line,u=s.end.line,h=c[d]+s.start.column;if(o&&(l.charCodeAt(h)===10&&(h++,a--),e[t++]=i,i="",o=!1,a===0))return!0;if(d===u)return!this._EOLNormalized&&l.charCodeAt(h+a-1)===13?(o=!0,i+=l.substr(h,a-1)):i+=l.substr(h,a),!0;i+=this._EOLNormalized?l.substring(h,Math.max(h,c[d+1]-this._EOLLength)):l.substring(h,c[d+1]).replace(/(\r\n|\r|\n)$/,""),e[t++]=i;for(let f=d+1;fw+p,t.reset(0)):(v=h.buffer,x=w=>w,t.reset(p));do if(_=t.next(v),_){if(x(_.index)>=g)return d;this.positionInBuffer(e,x(_.index)-f,b);let w=this.getLineFeedCnt(e.piece.bufferIndex,r,b),y=b.line===r.line?b.column-r.column+o:b.column+1,C=y+_[0].length;if(u[d++]=Mx(new S(i+w,y,i+w,C),_,l),x(_.index)+_[0].length>=g||d>=c)return d}while(_);return d}findMatchesLineByLine(e,t,i,o){let r=[],s=0,a=new Om(t.wordSeparators,t.regex),l=this.nodeAt2(e.startLineNumber,e.startColumn);if(l===null)return[];let c=this.nodeAt2(e.endLineNumber,e.endColumn);if(c===null)return[];let d=this.positionInBuffer(l.node,l.remainder),u=this.positionInBuffer(c.node,c.remainder);if(l.node===c.node)return this.findMatchesInNode(l.node,a,e.startLineNumber,e.startColumn,d,u,t,i,o,s,r),r;let h=e.startLineNumber,f=l.node;for(;f!==c.node;){let g=this.getLineFeedCnt(f.piece.bufferIndex,d,f.piece.end);if(g>=1){let b=this._buffers[f.piece.bufferIndex].lineStarts,v=this.offsetInBuffer(f.piece.bufferIndex,f.piece.start),x=b[d.line+g],w=h===e.startLineNumber?e.startColumn:1;if(s=this.findMatchesInNode(f,a,h,w,d,this.positionInBuffer(f,x-v),t,i,o,s,r),s>=o)return r;h+=g}let _=h===e.startLineNumber?e.startColumn-1:0;if(h===e.endLineNumber){let b=this.getLineContent(h).substring(_,e.endColumn-1);return s=this._findMatchesInLine(t,a,b,e.endLineNumber,_,s,r,i,o),r}if(s=this._findMatchesInLine(t,a,this.getLineContent(h).substr(_),h,_,s,r,i,o),s>=o)return r;h++,l=this.nodeAt2(h,1),f=l.node,d=this.positionInBuffer(l.node,l.remainder)}if(h===e.endLineNumber){let g=h===e.startLineNumber?e.startColumn-1:0,_=this.getLineContent(h).substring(g,e.endColumn-1);return s=this._findMatchesInLine(t,a,_,e.endLineNumber,g,s,r,i,o),r}let p=h===e.startLineNumber?e.startColumn:1;return s=this.findMatchesInNode(c.node,a,h,p,d,u,t,i,o,s,r),r}_findMatchesInLine(e,t,i,o,r,s,a,l,c){let d=e.wordSeparators;if(!l&&e.simpleSearch){let h=e.simpleSearch,f=h.length,p=i.length,g=-f;for(;(g=i.indexOf(h,g+f))!==-1;)if((!d||F6(d,i,p,g,f))&&(a[s++]=new Pm(new S(o,g+1+r,o,g+1+f+r),null),s>=c))return s;return s}let u;t.reset(0);do if(u=t.next(i),u&&(a[s++]=Mx(new S(o,u.index+1+r,o,u.index+1+u[0].length+r),u,l),s>=c))return s;while(u);return s}insert(e,t,i=!1){if(this._EOLNormalized=this._EOLNormalized&&i,this._lastVisitedLine.lineNumber=0,this._lastVisitedLine.value="",this.root!==Ot){let{node:o,remainder:r,nodeStartOffset:s}=this.nodeAt(e),a=o.piece,l=a.bufferIndex,c=this.positionInBuffer(o,r);if(o.piece.bufferIndex===0&&a.end.line===this._lastChangeBufferPos.line&&a.end.column===this._lastChangeBufferPos.column&&s+a.length===e&&t.lengthe){let d=[],u=new mc(a.bufferIndex,c,a.end,this.getLineFeedCnt(a.bufferIndex,c,a.end),this.offsetInBuffer(l,a.end)-this.offsetInBuffer(l,c));if(this.shouldCheckCRLF()&&this.endWithCR(t)&&this.nodeCharCodeAt(o,r)===10){let g={line:u.start.line+1,column:0};u=new mc(u.bufferIndex,g,u.end,this.getLineFeedCnt(u.bufferIndex,g,u.end),u.length-1),t+=` `}if(this.shouldCheckCRLF()&&this.startWithLF(t))if(this.nodeCharCodeAt(o,r-1)===13){let g=this.positionInBuffer(o,r-1);this.deleteNodeTail(o,g),t="\r"+t,o.piece.length===0&&d.push(o)}else this.deleteNodeTail(o,c);else this.deleteNodeTail(o,c);let h=this.createNewPieces(t);u.length>0&&this.rbInsertRight(o,u);let f=o;for(let p=0;p=0;s--)r=this.rbInsertLeft(r,o[s]);this.validateCRLFWithPrevNode(r),this.deleteNodes(i)}insertContentToNodeRight(e,t){this.adjustCarriageReturnFromNext(e,t)&&(e+=` `);let i=this.createNewPieces(e),o=this.rbInsertRight(t,i[0]),r=o;for(let s=1;s=h)c=u+1;else break;return i?(i.line=u,i.column=l-f,null):{line:u,column:l-f}}getLineFeedCnt(e,t,i){if(i.column===0)return i.line-t.line;let o=this._buffers[e].lineStarts;if(i.line===o.length-1)return i.line-t.line;let r=o[i.line+1],s=o[i.line]+i.column;if(r>s+1)return i.line-t.line;let a=s-1;return this._buffers[e].buffer.charCodeAt(a)===13?i.line-t.line+1:i.line-t.line}offsetInBuffer(e,t){return this._buffers[e].lineStarts[t.line]+t.column}deleteNodes(e){for(let t=0;tEb){let d=[];for(;e.length>Eb;){let h=e.charCodeAt(Eb-1),f;h===13||h>=55296&&h<=56319?(f=e.substring(0,Eb-1),e=e.substring(Eb-1)):(f=e.substring(0,Eb),e=e.substring(Eb));let p=xg(f);d.push(new mc(this._buffers.length,{line:0,column:0},{line:p.length-1,column:f.length-p[p.length-1]},p.length-1,f.length)),this._buffers.push(new wg(f,p))}let u=xg(e);return d.push(new mc(this._buffers.length,{line:0,column:0},{line:u.length-1,column:e.length-u[u.length-1]},u.length-1,e.length)),this._buffers.push(new wg(e,u)),d}let t=this._buffers[0].buffer.length,i=xg(e,!1),o=this._lastChangeBufferPos;if(this._buffers[0].lineStarts[this._buffers[0].lineStarts.length-1]===t&&t!==0&&this.startWithLF(e)&&this.endWithCR(this._buffers[0].buffer)){this._lastChangeBufferPos={line:this._lastChangeBufferPos.line,column:this._lastChangeBufferPos.column+1},o=this._lastChangeBufferPos;for(let d=0;d=e-1)i=i.left;else if(i.lf_left+i.piece.lineFeedCnt>e-1){let l=this.getAccumulatedValue(i,e-i.lf_left-2),c=this.getAccumulatedValue(i,e-i.lf_left-1),d=this._buffers[i.piece.bufferIndex].buffer,u=this.offsetInBuffer(i.piece.bufferIndex,i.piece.start);return s+=i.size_left,this._searchCache.set({node:i,nodeStartOffset:s,nodeStartLineNumber:a-(e-1-i.lf_left)}),d.substring(u+l,u+c-t)}else if(i.lf_left+i.piece.lineFeedCnt===e-1){let l=this.getAccumulatedValue(i,e-i.lf_left-2),c=this._buffers[i.piece.bufferIndex].buffer,d=this.offsetInBuffer(i.piece.bufferIndex,i.piece.start);o=c.substring(d+l,d+i.piece.length);break}else e-=i.lf_left+i.piece.lineFeedCnt,s+=i.size_left+i.piece.length,i=i.right}for(i=i.next();i!==Ot;){let s=this._buffers[i.piece.bufferIndex].buffer;if(i.piece.lineFeedCnt>0){let a=this.getAccumulatedValue(i,0),l=this.offsetInBuffer(i.piece.bufferIndex,i.piece.start);return o+=s.substring(l,l+a-t),o}else{let a=this.offsetInBuffer(i.piece.bufferIndex,i.piece.start);o+=s.substr(a,i.piece.length)}i=i.next()}return o}computeBufferMetadata(){let e=this.root,t=1,i=0;for(;e!==Ot;)t+=e.lf_left+e.piece.lineFeedCnt,i+=e.size_left+e.piece.length,e=e.right;this._lineCnt=t,this._length=i,this._searchCache.validate(this._length)}getIndexOf(e,t){let i=e.piece,o=this.positionInBuffer(e,t),r=o.line-i.start.line;if(this.offsetInBuffer(i.bufferIndex,i.end)-this.offsetInBuffer(i.bufferIndex,i.start)===t){let s=this.getLineFeedCnt(e.piece.bufferIndex,i.start,o);if(s!==r)return{index:s,remainder:0}}return{index:r,remainder:o.column}}getAccumulatedValue(e,t){if(t<0)return 0;let i=e.piece,o=this._buffers[i.bufferIndex].lineStarts,r=i.start.line+t+1;return r>i.end.line?o[i.end.line]+i.end.column-o[i.start.line]-i.start.column:o[r]-o[i.start.line]-i.start.column}deleteNodeTail(e,t){let i=e.piece,o=i.lineFeedCnt,r=this.offsetInBuffer(i.bufferIndex,i.end),s=t,a=this.offsetInBuffer(i.bufferIndex,s),l=this.getLineFeedCnt(i.bufferIndex,i.start,s),c=l-o,d=a-r,u=i.length+d;e.piece=new mc(i.bufferIndex,i.start,s,l,u),vg(this,e,d,c)}deleteNodeHead(e,t){let i=e.piece,o=i.lineFeedCnt,r=this.offsetInBuffer(i.bufferIndex,i.start),s=t,a=this.getLineFeedCnt(i.bufferIndex,s,i.end),l=this.offsetInBuffer(i.bufferIndex,s),c=a-o,d=r-l,u=i.length+d;e.piece=new mc(i.bufferIndex,s,i.end,a,u),vg(this,e,d,c)}shrinkNode(e,t,i){let o=e.piece,r=o.start,s=o.end,a=o.length,l=o.lineFeedCnt,c=t,d=this.getLineFeedCnt(o.bufferIndex,o.start,c),u=this.offsetInBuffer(o.bufferIndex,t)-this.offsetInBuffer(o.bufferIndex,r);e.piece=new mc(o.bufferIndex,o.start,c,d,u),vg(this,e,u-a,d-l);let h=new mc(o.bufferIndex,i,s,this.getLineFeedCnt(o.bufferIndex,i,s),this.offsetInBuffer(o.bufferIndex,s)-this.offsetInBuffer(o.bufferIndex,i)),f=this.rbInsertRight(e,h);this.validateCRLFWithPrevNode(f)}appendToNode(e,t){this.adjustCarriageReturnFromNext(t,e)&&(t+=` `);let i=this.shouldCheckCRLF()&&this.startWithLF(t)&&this.endWithCR(e),o=this._buffers[0].buffer.length;this._buffers[0].buffer+=t;let r=xg(t,!1);for(let f=0;fe)t=t.left;else if(t.size_left+t.piece.length>=e){o+=t.size_left;let r={node:t,remainder:e-t.size_left,nodeStartOffset:o};return this._searchCache.set(r),r}else e-=t.size_left+t.piece.length,o+=t.size_left+t.piece.length,t=t.right;return null}nodeAt2(e,t){let i=this.root,o=0;for(;i!==Ot;)if(i.left!==Ot&&i.lf_left>=e-1)i=i.left;else if(i.lf_left+i.piece.lineFeedCnt>e-1){let r=this.getAccumulatedValue(i,e-i.lf_left-2),s=this.getAccumulatedValue(i,e-i.lf_left-1);return o+=i.size_left,{node:i,remainder:Math.min(r+t-1,s),nodeStartOffset:o}}else if(i.lf_left+i.piece.lineFeedCnt===e-1){let r=this.getAccumulatedValue(i,e-i.lf_left-2);if(r+t-1<=i.piece.length)return{node:i,remainder:r+t-1,nodeStartOffset:o};t-=i.piece.length-r;break}else e-=i.lf_left+i.piece.lineFeedCnt,o+=i.size_left+i.piece.length,i=i.right;for(i=i.next();i!==Ot;){if(i.piece.lineFeedCnt>0){let r=this.getAccumulatedValue(i,0),s=this.offsetOfNode(i);return{node:i,remainder:Math.min(t-1,r),nodeStartOffset:s}}else if(i.piece.length>=t-1){let r=this.offsetOfNode(i);return{node:i,remainder:t-1,nodeStartOffset:r}}else t-=i.piece.length;i=i.next()}return null}nodeCharCodeAt(e,t){if(e.piece.lineFeedCnt<1)return-1;let i=this._buffers[e.piece.bufferIndex],o=this.offsetInBuffer(e.piece.bufferIndex,e.piece.start)+t;return i.buffer.charCodeAt(o)}offsetOfNode(e){if(!e)return 0;let t=e.size_left;for(;e!==this.root;)e.parent.right===e&&(t+=e.parent.size_left+e.parent.piece.length),e=e.parent;return t}shouldCheckCRLF(){return!(this._EOLNormalized&&this._EOL===` `)}startWithLF(e){if(typeof e=="string")return e.charCodeAt(0)===10;if(e===Ot||e.piece.lineFeedCnt===0)return!1;let t=e.piece,i=this._buffers[t.bufferIndex].lineStarts,o=t.start.line,r=i[o]+t.start.column;return o===i.length-1||i[o+1]>r+1?!1:this._buffers[t.bufferIndex].buffer.charCodeAt(r)===10}endWithCR(e){return typeof e=="string"?e.charCodeAt(e.length-1)===13:e===Ot||e.piece.lineFeedCnt===0?!1:this.nodeCharCodeAt(e,e.piece.length-1)===13}validateCRLFWithPrevNode(e){if(this.shouldCheckCRLF()&&this.startWithLF(e)){let t=e.prev();this.endWithCR(t)&&this.fixCRLF(t,e)}}validateCRLFWithNextNode(e){if(this.shouldCheckCRLF()&&this.endWithCR(e)){let t=e.next();this.startWithLF(t)&&this.fixCRLF(e,t)}}fixCRLF(e,t){let i=[],o=this._buffers[e.piece.bufferIndex].lineStarts,r;e.piece.end.column===0?r={line:e.piece.end.line-1,column:o[e.piece.end.line]-o[e.piece.end.line-1]-1}:r={line:e.piece.end.line,column:e.piece.end.column-1};let s=e.piece.length-1,a=e.piece.lineFeedCnt-1;e.piece=new mc(e.piece.bufferIndex,e.piece.start,r,a,s),vg(this,e,-1,-1),e.piece.length===0&&i.push(e);let l={line:t.piece.start.line+1,column:0},c=t.piece.length-1,d=this.getLineFeedCnt(t.piece.bufferIndex,l,t.piece.end);t.piece=new mc(t.piece.bufferIndex,l,t.piece.end,d,c),vg(this,t,-1,-1),t.piece.length===0&&i.push(t);let u=this.createNewPieces(`\r `);this.rbInsertRight(e,u[0]);for(let h=0;h{Ie();Qe();we();Zr();oce();iC();zle();j();UI=class n extends D{constructor(e,t,i,o,r,s,a){super(),this._onDidChangeContent=this._register(new A),this._BOM=t,this._mightContainNonBasicASCII=!s,this._mightContainRTL=o,this._mightContainUnusualLineTerminators=r,this._pieceTree=new lH(e,i,a)}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(e){return this._pieceTree.createSnapshot(e?this._BOM:"")}getOffsetAt(e,t){return this._pieceTree.getOffsetAt(e,t)}getPositionAt(e){return this._pieceTree.getPositionAt(e)}getRangeAt(e,t){let i=e+t,o=this.getPositionAt(e),r=this.getPositionAt(i);return new S(o.lineNumber,o.column,r.lineNumber,r.column)}getValueInRange(e,t=0){if(e.isEmpty())return"";let i=this._getEndOfLine(t);return this._pieceTree.getValueInRange(e,i)}getValueLengthInRange(e,t=0){if(e.isEmpty())return 0;if(e.startLineNumber===e.endLineNumber)return e.endColumn-e.startColumn;let i=this.getOffsetAt(e.startLineNumber,e.startColumn),o=this.getOffsetAt(e.endLineNumber,e.endColumn),r=0,s=this._getEndOfLine(t),a=this.getEOL();if(s.length!==a.length){let l=s.length-a.length,c=e.endLineNumber-e.startLineNumber;r=l*c}return o-i+r}getCharacterCountInRange(e,t=0){if(this._mightContainNonBasicASCII){let i=0,o=e.startLineNumber,r=e.endLineNumber;for(let s=o;s<=r;s++){let a=this.getLineContent(s),l=s===o?e.startColumn-1:0,c=s===r?e.endColumn-1:a.length;for(let d=l;d_.sortIndex-b.sortIndex)}this._mightContainRTL=o,this._mightContainUnusualLineTerminators=r,this._mightContainNonBasicASCII=s;let f=this._doApplyEdits(l),p=null;if(t&&u.length>0){u.sort((g,_)=>_.lineNumber-g.lineNumber),p=[];for(let g=0,_=u.length;g<_;g++){let b=u[g].lineNumber;if(g>0&&u[g-1].lineNumber===b)continue;let v=u[g].oldContent,x=this.getLineContent(b);x.length===0||x===v||bo(x)!==-1||p.push(b)}}return this._onDidChangeContent.fire(),new M6(h,f,p)}_reduceOperations(e){return e.length<1e3?e:[this._toSingleEditOperation(e)]}_toSingleEditOperation(e){let t=!1,i=e[0].range,o=e[e.length-1].range,r=new S(i.startLineNumber,i.startColumn,o.endLineNumber,o.endColumn),s=i.startLineNumber,a=i.startColumn,l=[];for(let f=0,p=e.length;f0&&l.push(g.text),s=_.endLineNumber,a=_.endColumn}let c=l.join(""),[d,u,h]=yu(c);return{sortIndex:0,identifier:e[0].identifier,range:r,rangeOffset:this.getOffsetAt(r.startLineNumber,r.startColumn),rangeLength:this.getValueLengthInRange(r,0),text:c,eolCount:d,firstLineLength:u,lastLineLength:h,forceMoveMarkers:t,isAutoWhitespaceEdit:!1}}_doApplyEdits(e){e.sort(n._sortOpsDescending);let t=[];for(let i=0;i0){let h=l.eolCount+1;h===1?u=new S(c,d,c,d+l.firstLineLength):u=new S(c,d,c+h-1,l.lastLineLength+1)}else u=new S(c,d,c,d);i=u.endLineNumber,o=u.endColumn,t.push(u),r=l}return t}static _sortOpsAscending(e,t){let i=S.compareRangesUsingEnds(e.range,t.range);return i===0?e.sortIndex-t.sortIndex:i}static _sortOpsDescending(e,t){let i=S.compareRangesUsingEnds(e.range,t.range);return i===0?t.sortIndex-e.sortIndex:-i}}});var sce,h2,B4e=k(()=>{Qe();oce();rce();sce=class{constructor(e,t,i,o,r,s,a,l,c){this._chunks=e,this._bom=t,this._cr=i,this._lf=o,this._crlf=r,this._containsRTL=s,this._containsUnusualLineTerminators=a,this._isBasicASCII=l,this._normalizeEOL=c}_getEOL(e){let t=this._cr+this._lf+this._crlf,i=this._cr+this._crlf;return t===0?e===1?` `:`\r `:i>t/2?`\r `:` `}create(e){let t=this._getEOL(e),i=this._chunks;if(this._normalizeEOL&&(t===`\r `&&(this._cr>0||this._lf>0)||t===` `&&(this._cr>0||this._crlf>0)))for(let r=0,s=i.length;r=55296&&t<=56319?(this._acceptChunk1(e.substr(0,e.length-1),!1),this._hasPreviousChar=!0,this._previousChar=t):(this._acceptChunk1(e,!1),this._hasPreviousChar=!1,this._previousChar=t)}_acceptChunk1(e,t){!t&&e.length===0||(this._hasPreviousChar?this._acceptChunk2(String.fromCharCode(this._previousChar)+e):this._acceptChunk2(e))}_acceptChunk2(e){let t=F4e(this._tmpLineStarts,e);this.chunks.push(new wg(e,t.lineStarts)),this.cr+=t.cr,this.lf+=t.lf,this.crlf+=t.crlf,t.isBasicASCII||(this.isBasicASCII=!1,this.containsRTL||(this.containsRTL=dp(e)),this.containsUnusualLineTerminators||(this.containsUnusualLineTerminators=aB(e)))}finish(e=!0){return this._finish(),new sce(this.chunks,this.BOM,this.cr,this.lf,this.crlf,this.containsRTL,this.containsUnusualLineTerminators,this.isBasicASCII,e)}_finish(){if(this.chunks.length===0&&this._acceptChunk1("",!0),this._hasPreviousChar){this._hasPreviousChar=!1;let e=this.chunks[this.chunks.length-1];e.buffer+=String.fromCharCode(this._previousChar);let t=xg(e.buffer);e.lineStarts=t,this._previousChar===13&&this.cr++}}}});function Act(n,e){let t=[];for(let i=0;i{at();cH=class{constructor(e){this._default=e,this._store=[]}get(e){return e=this._store.length;)this._store[this._store.length]=this._default;this._store[e]=t}replace(e,t,i){if(e>=this._store.length)return;if(t===0){this.insert(e,i);return}else if(i===0){this.delete(e,t);return}let o=this._store.slice(0,e),r=this._store.slice(e+t),s=Act(i,this._default);this._store=o.concat(s,r)}delete(e,t){t===0||e>=this._store.length||this._store.splice(e,t)}insert(e,t){if(t===0||e>=this._store.length)return;let i=[];for(let o=0;o{dH=class{get startLineNumber(){return this._startLineNumber}get endLineNumber(){return this._startLineNumber+this._tokens.length-1}constructor(e,t){this._startLineNumber=e,this._tokens=t}getLineTokens(e){return this._tokens[e-this._startLineNumber]}appendLineTokens(e){this._tokens.push(e)}}});var MC,ace=k(()=>{H4e();MC=class{constructor(){this._tokens=[]}add(e,t){if(this._tokens.length>0){let i=this._tokens[this._tokens.length-1];if(i.endLineNumber+1===e){i.appendLineTokens(t);return}}this._tokens.push(new dH(e,[t]))}finalize(){return this._tokens}}});function f2(n,e,t,i,o,r){let s=null;if(t)try{s=t.tokenizeEncoded(i,o,r.clone())}catch(a){Be(a)}return s||(s=sw(n.encodeLanguageId(e),r)),ao.convertToEndOffset(s.tokens,i.length),s}var lce,uH,$I,cce,dce,hH,z4e=k(()=>{ft();je();Bt();kl();iC();Nl();Rd();tI();W4e();ace();Dh();lce=class{constructor(e,t){this.tokenizationSupport=t,this.initialState=this.tokenizationSupport.getInitialState(),this.store=new $I(e)}getStartState(e){return this.store.getStartState(e,this.initialState)}getFirstInvalidLine(){return this.store.getFirstInvalidLine(this.initialState)}},uH=class extends lce{constructor(e,t,i,o){super(e,t),this._textModel=i,this._languageIdCodec=o}updateTokensUntilLine(e,t){let i=this._textModel.getLanguageId();for(;;){let o=this.getFirstInvalidLine();if(!o||o.lineNumber>t)break;let r=this._textModel.getLineContent(o.lineNumber),s=f2(this._languageIdCodec,i,this.tokenizationSupport,r,!0,o.startState);e.add(o.lineNumber,s.tokens),this.store.setEndState(o.lineNumber,s.endState)}}getTokenTypeIfInsertingCharacter(e,t){let i=this.getStartState(e.lineNumber);if(!i)return 0;let o=this._textModel.getLanguageId(),r=this._textModel.getLineContent(e.lineNumber),s=r.substring(0,e.column-1)+t+r.substring(e.column-1),a=f2(this._languageIdCodec,o,this.tokenizationSupport,s,!0,i),l=new ao(a.tokens,s,this._languageIdCodec);if(l.getCount()===0)return 0;let c=l.findTokenIndexAtOffset(e.column-1);return l.getStandardTokenType(c)}tokenizeLineWithEdit(e,t,i){let o=e.lineNumber,r=e.column,s=this.getStartState(o);if(!s)return null;let a=this._textModel.getLineContent(o),l=a.substring(0,r-1)+i+a.substring(r-1+t),c=this._textModel.getLanguageIdAtPosition(o,0),d=f2(this._languageIdCodec,c,this.tokenizationSupport,l,!0,s);return new ao(d.tokens,l,this._languageIdCodec)}hasAccurateTokensForLine(e){let t=this.store.getFirstInvalidEndStateLineNumberOrMax();return e1&&a>=1;a--){let l=this._textModel.getLineFirstNonWhitespaceColumn(a);if(l!==0&&l0&&i>0&&(i--,t--),this._lineEndStates.replace(e.startLineNumber,i,t)}},dce=class{constructor(){this._ranges=[]}get min(){return this._ranges.length===0?null:this._ranges[0].start}delete(e){let t=this._ranges.findIndex(i=>i.contains(e));if(t!==-1){let i=this._ranges[t];i.start===e?i.endExclusive===e+1?this._ranges.splice(t,1):this._ranges[t]=new Wt(e+1,i.endExclusive):i.endExclusive===e+1?this._ranges[t]=new Wt(i.start,e):this._ranges.splice(t,1,new Wt(i.start,e),new Wt(e+1,i.endExclusive))}}addRange(e){Wt.addRange(e,this._ranges)}addRangeAndResize(e,t){let i=0;for(;!(i>=this._ranges.length||e.start<=this._ranges[i].endExclusive);)i++;let o=i;for(;!(o>=this._ranges.length||e.endExclusivee.toString()).join(" + ")}};hH=class{constructor(e,t){this._tokenizerWithStateStore=e,this._backgroundTokenStore=t,this._isDisposed=!1,this._isScheduled=!1}dispose(){this._isDisposed=!0}handleChanges(){this._beginBackgroundTokenization()}_beginBackgroundTokenization(){this._isScheduled||!this._tokenizerWithStateStore._textModel.isAttachedToEditor()||!this._hasLinesToTokenize()||(this._isScheduled=!0,Hne(e=>{this._isScheduled=!1,this._backgroundTokenizeWithDeadline(e)}))}_backgroundTokenizeWithDeadline(e){let t=Date.now()+e.timeRemaining(),i=()=>{this._isDisposed||!this._tokenizerWithStateStore._textModel.isAttachedToEditor()||!this._hasLinesToTokenize()||(this._backgroundTokenizeForAtLeast1ms(),Date.now()1||this._tokenizeOneInvalidLine(t)>=e)break;while(this._hasLinesToTokenize());this._backgroundTokenStore.setTokens(t.finalize()),this.checkFinished()}_hasLinesToTokenize(){return this._tokenizerWithStateStore?!this._tokenizerWithStateStore.store.allStatesValid():!1}_tokenizeOneInvalidLine(e){let t=this._tokenizerWithStateStore?.getFirstInvalidLine();return t?(this._tokenizerWithStateStore.updateTokensUntilLine(e,t.lineNumber),t.lineNumber):this._tokenizerWithStateStore._textModel.getLineCount()+1}checkFinished(){this._isDisposed||this._tokenizerWithStateStore.store.allStatesValid()&&this._backgroundTokenStore.backgroundTokenizationFinished()}requestTokens(e,t){this._tokenizerWithStateStore.store.invalidateEndStateRange(new ut(e,t))}}});var fH,uce,pH,jI,mH=k(()=>{at();ft();Ie();j();Nl();fH=class{constructor(){this._onDidChangeVisibleRanges=new A,this.onDidChangeVisibleRanges=this._onDidChangeVisibleRanges.event,this._views=new Set}attachView(){let e=new uce(t=>{this._onDidChangeVisibleRanges.fire({view:e,state:t})});return this._views.add(e),e}detachView(e){this._views.delete(e),this._onDidChangeVisibleRanges.fire({view:e,state:void 0})}},uce=class{constructor(e){this.handleStateChange=e}setVisibleLines(e,t){let i=e.map(o=>new ut(o.startLineNumber,o.endLineNumber+1));this.handleStateChange({visibleLineRanges:i,stabilized:t})}},pH=class extends D{get lineRanges(){return this._lineRanges}constructor(e){super(),this._refreshTokens=e,this.runner=this._register(new Lt(()=>this.update(),50)),this._computedLineRanges=[],this._lineRanges=[]}update(){oi(this._computedLineRanges,this._lineRanges,(e,t)=>e.equals(t))||(this._computedLineRanges=this._lineRanges,this._refreshTokens())}handleStateChange(e){this._lineRanges=e.visibleLineRanges,e.stabilized?(this.runner.cancel(),this.update()):this.runner.schedule()}},jI=class extends D{get backgroundTokenizationState(){return this._backgroundTokenizationState}constructor(e,t,i){super(),this._languageIdCodec=e,this._textModel=t,this.getLanguageId=i,this._backgroundTokenizationState=1,this._onDidChangeBackgroundTokenizationState=this._register(new A),this.onDidChangeBackgroundTokenizationState=this._onDidChangeBackgroundTokenizationState.event,this._onDidChangeTokens=this._register(new A),this.onDidChangeTokens=this._onDidChangeTokens.event}tokenizeIfCheap(e){this.isCheapToTokenize(e)&&this.forceTokenization(e)}}});var p2,V4e=k(()=>{Ji();Dh();mH();p2=class extends jI{constructor(e,t,i,o){super(t,i,o),this._treeSitterService=e,this._tokenizationSupport=null,this._initialize()}_initialize(){let e=this.getLanguageId();(!this._tokenizationSupport||this._lastLanguageId!==e)&&(this._lastLanguageId=e,this._tokenizationSupport=jR.get(e))}getLineTokens(e){let t=this._textModel.getLineContent(e);if(this._tokenizationSupport){let i=this._tokenizationSupport.tokenizeEncoded(e,this._textModel);if(i)return new ao(i,t,this._languageIdCodec)}return ao.createEmpty(t,this._languageIdCodec)}resetTokenization(e=!0){e&&this._onDidChangeTokens.fire({semanticTokensApplied:!1,ranges:[{fromLineNumber:1,toLineNumber:this._textModel.getLineCount()}]}),this._initialize()}handleDidChangeAttached(){}handleDidChangeContent(e){e.isFlush&&this.resetTokenization(!1)}forceTokenization(e){}hasAccurateTokensForLine(e){return!0}isCheapToTokenize(e){return!0}getTokenTypeIfInsertingCharacter(e,t,i){return 0}tokenizeLineWithEdit(e,t,i){return null}get hasTokens(){return this._treeSitterService.getParseResult(this._textModel)!==void 0}}});var gH,hce=k(()=>{Fe();gH=We("treeSitterParserService")});function Cg(n){return n instanceof Uint32Array?n:new Uint32Array(n)}var yg,Sg,U4e=k(()=>{Dh();yg=new Uint32Array(0).buffer,Sg=class n{static deleteBeginning(e,t){return e===null||e===yg?e:n.delete(e,0,t)}static deleteEnding(e,t){if(e===null||e===yg)return e;let i=Cg(e),o=i[i.length-2];return n.delete(e,t,o)}static delete(e,t,i){if(e===null||e===yg||t===i)return e;let o=Cg(e),r=o.length>>>1;if(t===0&&o[o.length-2]===i)return yg;let s=ao.findIndexInTokensArray(o,t),a=s>0?o[s-1<<1]:0,l=o[s<<1];if(id&&(o[c++]=p,o[c++]=o[(f<<1)+1],d=p)}if(c===o.length)return e;let h=new Uint32Array(c);return h.set(o.subarray(0,c),0),h.buffer}static append(e,t){if(t===yg)return e;if(e===yg)return t;if(e===null)return e;if(t===null)return null;let i=Cg(e),o=Cg(t),r=o.length>>>1,s=new Uint32Array(i.length+o.length);s.set(i,0);let a=i.length,l=i[i.length-2];for(let c=0;c>>1,s=ao.findIndexInTokensArray(o,t);s>0&&o[s-1<<1]===t&&s--;for(let a=s;a>>0}var m2,j4e=k(()=>{at();qe();U4e();Dh();tC();m2=class n{constructor(e){this._lineTokens=[],this._len=0,this._languageIdCodec=e}flush(){this._lineTokens=[],this._len=0}get hasTokens(){return this._lineTokens.length>0}getTokens(e,t,i){let o=null;if(t1&&(r=Go.getLanguageId(o[1])!==e),!r)return yg}if(!o||o.length===0){let r=new Uint32Array(2);return r[0]=t,r[1]=$4e(e),r.buffer}return o[o.length-2]=t,o.byteOffset===0&&o.byteLength===o.buffer.byteLength?o.buffer:o}_ensureLine(e){for(;e>=this._len;)this._lineTokens[this._len]=null,this._len++}_deleteLines(e,t){t!==0&&(e+t>this._len&&(t=this._len-e),this._lineTokens.splice(e,t),this._len-=t)}_insertLines(e,t){if(t===0)return;let i=[];for(let o=0;o=this._len)return;if(e.startLineNumber===e.endLineNumber){if(e.startColumn===e.endColumn)return;this._lineTokens[t]=Sg.delete(this._lineTokens[t],e.startColumn-1,e.endColumn-1);return}this._lineTokens[t]=Sg.deleteEnding(this._lineTokens[t],e.startColumn-1);let i=e.endLineNumber-1,o=null;i=this._len)){if(t===0){this._lineTokens[o]=Sg.insert(this._lineTokens[o],e.column-1,i);return}this._lineTokens[o]=Sg.deleteEnding(this._lineTokens[o],e.column-1),this._lineTokens[o]=Sg.insert(this._lineTokens[o],e.column-1,i),this._insertLines(e.lineNumber,t)}}setMultilineTokens(e,t){if(e.length===0)return{changes:[]};let i=[];for(let o=0,r=e.length;o{at();Dh();_H=class n{constructor(e){this._pieces=[],this._isComplete=!1,this._languageIdCodec=e}flush(){this._pieces=[],this._isComplete=!1}isEmpty(){return this._pieces.length===0}set(e,t){this._pieces=e||[],this._isComplete=t}setPartial(e,t){let i=e;if(t.length>0){let r=t[0].getRange(),s=t[t.length-1].getRange();if(!r||!s)return e;i=e.plusRange(r).plusRange(s)}let o=null;for(let r=0,s=this._pieces.length;ri.endLineNumber){o=o||{index:r};break}if(a.removeTokens(i),a.isEmpty()){this._pieces.splice(r,1),r--,s--;continue}if(a.endLineNumberi.endLineNumber){o=o||{index:r};continue}let[l,c]=a.split(i);if(l.isEmpty()){o=o||{index:r};continue}c.isEmpty()||(this._pieces.splice(r,1,l,c),r++,s++,o=o||{index:r})}return o=o||{index:this._pieces.length},t.length>0&&(this._pieces=Jv(this._pieces,o.index,t)),i}isComplete(){return this._isComplete}addSparseTokens(e,t){if(t.getLineContent().length===0)return t;let i=this._pieces;if(i.length===0)return t;let o=n._findFirstPieceWithLine(i,e),r=i[o].getLineTokens(e);if(!r)return t;let s=t.getCount(),a=r.getCount(),l=0,c=[],d=0,u=0,h=(f,p)=>{f!==u&&(u=f,c[d++]=f,c[d++]=p)};for(let f=0;f>>0,v=~b>>>0;for(;lt)o=r-1;else{for(;r>i&&e[r-1].startLineNumber<=t&&t<=e[r-1].endLineNumber;)r--;return r}}return i}acceptEdit(e,t,i,o,r){for(let s of this._pieces)s.acceptEdit(e,t,i,o,r)}}});var Mct,fce,bH,vH,xH,K4e=k(()=>{je();Ie();j();iC();Nl();qe();h1();Ji();fs();Ko();jle();z4e();mH();V4e();hce();ace();j4e();q4e();Mct=function(n,e,t,i){var o=arguments.length,r=o<3?e:i===null?i=Object.getOwnPropertyDescriptor(e,t):i,s;if(typeof Reflect=="object"&&typeof Reflect.decorate=="function")r=Reflect.decorate(n,e,t,i);else for(var a=n.length-1;a>=0;a--)(s=n[a])&&(r=(o<3?s(r):o>3?s(e,t,r):s(e,t))||r);return o>3&&r&&Object.defineProperty(e,t,r),r},fce=function(n,e){return function(t,i){e(t,i,n)}},vH=bH=class extends WI{constructor(e,t,i,o,r,s,a){super(),this._textModel=e,this._bracketPairsTextModelPart=t,this._languageId=i,this._attachedViews=o,this._languageService=r,this._languageConfigurationService=s,this._treeSitterService=a,this._semanticTokens=new _H(this._languageService.languageIdCodec),this._onDidChangeLanguage=this._register(new A),this.onDidChangeLanguage=this._onDidChangeLanguage.event,this._onDidChangeLanguageConfiguration=this._register(new A),this.onDidChangeLanguageConfiguration=this._onDidChangeLanguageConfiguration.event,this._onDidChangeTokens=this._register(new A),this.onDidChangeTokens=this._onDidChangeTokens.event,this._tokensDisposables=this._register(new H),this._register(this._languageConfigurationService.onDidChange(l=>{l.affects(this._languageId)&&this._onDidChangeLanguageConfiguration.fire({})})),this._register(ne.filter(jR.onDidChange,l=>l.changedLanguages.includes(this._languageId))(()=>{this.createPreferredTokenProvider()})),this.createPreferredTokenProvider()}createGrammarTokens(){return this._register(new xH(this._languageService.languageIdCodec,this._textModel,()=>this._languageId,this._attachedViews))}createTreeSitterTokens(){return this._register(new p2(this._treeSitterService,this._languageService.languageIdCodec,this._textModel,()=>this._languageId))}createTokens(e){let t=this._tokens!==void 0;this._tokens?.dispose(),this._tokens=e?this.createTreeSitterTokens():this.createGrammarTokens(),this._tokensDisposables.clear(),this._tokensDisposables.add(this._tokens.onDidChangeTokens(i=>{this._emitModelTokensChangedEvent(i)})),this._tokensDisposables.add(this._tokens.onDidChangeBackgroundTokenizationState(i=>{this._bracketPairsTextModelPart.handleDidChangeBackgroundTokenizationState()})),t&&this._tokens.resetTokenization()}createPreferredTokenProvider(){jR.get(this._languageId)?this._tokens instanceof p2||this.createTokens(!0):this._tokens instanceof xH||this.createTokens(!1)}handleLanguageConfigurationServiceChange(e){e.affects(this._languageId)&&this._onDidChangeLanguageConfiguration.fire({})}handleDidChangeContent(e){if(e.isFlush)this._semanticTokens.flush();else if(!e.isEolChange)for(let t of e.changes){let[i,o,r]=yu(t.text);this._semanticTokens.acceptEdit(t.range,i,o,r,t.text.length>0?t.text.charCodeAt(0):0)}this._tokens.handleDidChangeContent(e)}handleDidChangeAttached(){this._tokens.handleDidChangeAttached()}getLineTokens(e){this.validateLineNumber(e);let t=this._tokens.getLineTokens(e);return this._semanticTokens.addSparseTokens(e,t)}_emitModelTokensChangedEvent(e){this._textModel._isDisposing()||(this._bracketPairsTextModelPart.handleDidChangeTokens(e),this._onDidChangeTokens.fire(e))}validateLineNumber(e){if(e<1||e>this._textModel.getLineCount())throw new Nt("Illegal value for lineNumber")}get hasTokens(){return this._tokens.hasTokens}resetTokenization(){this._tokens.resetTokenization()}get backgroundTokenizationState(){return this._tokens.backgroundTokenizationState}forceTokenization(e){this.validateLineNumber(e),this._tokens.forceTokenization(e)}hasAccurateTokensForLine(e){return this.validateLineNumber(e),this._tokens.hasAccurateTokensForLine(e)}isCheapToTokenize(e){return this.validateLineNumber(e),this._tokens.isCheapToTokenize(e)}tokenizeIfCheap(e){this.validateLineNumber(e),this._tokens.tokenizeIfCheap(e)}getTokenTypeIfInsertingCharacter(e,t,i){return this._tokens.getTokenTypeIfInsertingCharacter(e,t,i)}tokenizeLineWithEdit(e,t,i){return this._tokens.tokenizeLineWithEdit(e,t,i)}setSemanticTokens(e,t){this._semanticTokens.set(e,t),this._emitModelTokensChangedEvent({semanticTokensApplied:e!==null,ranges:[{fromLineNumber:1,toLineNumber:this._textModel.getLineCount()}]})}hasCompleteSemanticTokens(){return this._semanticTokens.isComplete()}hasSomeSemanticTokens(){return!this._semanticTokens.isEmpty()}setPartialSemanticTokens(e,t){if(this.hasCompleteSemanticTokens())return;let i=this._textModel.validateRange(this._semanticTokens.setPartial(e,t));this._emitModelTokensChangedEvent({semanticTokensApplied:!0,ranges:[{fromLineNumber:i.startLineNumber,toLineNumber:i.endLineNumber}]})}getWordAtPosition(e){this.assertNotDisposed();let t=this._textModel.validatePosition(e),i=this._textModel.getLineContent(t.lineNumber),o=this.getLineTokens(t.lineNumber),r=o.findTokenIndexAtOffset(t.column-1),[s,a]=bH._findLanguageBoundaries(o,r),l=tx(t.column,this.getLanguageConfiguration(o.getLanguageId(r)).getWordDefinition(),i.substring(s,a),s);if(l&&l.startColumn<=e.column&&e.column<=l.endColumn)return l;if(r>0&&s===t.column-1){let[c,d]=bH._findLanguageBoundaries(o,r-1),u=tx(t.column,this.getLanguageConfiguration(o.getLanguageId(r-1)).getWordDefinition(),i.substring(c,d),c);if(u&&u.startColumn<=e.column&&e.column<=u.endColumn)return u}return null}getLanguageConfiguration(e){return this._languageConfigurationService.getLanguageConfiguration(e)}static _findLanguageBoundaries(e,t){let i=e.getLanguageId(t),o=0;for(let s=t;s>=0&&e.getLanguageId(s)===i;s--)o=e.getStartOffset(s);let r=e.getLineContent().length;for(let s=t,a=e.getCount();s{let s=this.getLanguageId();r.changedLanguages.indexOf(s)!==-1&&this.resetTokenization()})),this.resetTokenization(),this._register(o.onDidChangeVisibleRanges(({view:r,state:s})=>{if(s){let a=this._attachedViewStates.get(r);a||(a=new pH(()=>this.refreshRanges(a.lineRanges)),this._attachedViewStates.set(r,a)),a.handleStateChange(s)}else this._attachedViewStates.deleteAndDispose(r)}))}resetTokenization(e=!0){this._tokens.flush(),this._debugBackgroundTokens?.flush(),this._debugBackgroundStates&&(this._debugBackgroundStates=new $I(this._textModel.getLineCount())),e&&this._onDidChangeTokens.fire({semanticTokensApplied:!1,ranges:[{fromLineNumber:1,toLineNumber:this._textModel.getLineCount()}]});let t=()=>{if(this._textModel.isTooLargeForTokenization())return[null,null];let r=$i.get(this.getLanguageId());if(!r)return[null,null];let s;try{s=r.getInitialState()}catch(a){return Be(a),[null,null]}return[r,s]},[i,o]=t();if(i&&o?this._tokenizer=new uH(this._textModel.getLineCount(),i,this._textModel,this._languageIdCodec):this._tokenizer=null,this._backgroundTokenizer.clear(),this._defaultBackgroundTokenizer=null,this._tokenizer){let r={setTokens:s=>{this.setTokens(s)},backgroundTokenizationFinished:()=>{if(this._backgroundTokenizationState===2)return;let s=2;this._backgroundTokenizationState=s,this._onDidChangeBackgroundTokenizationState.fire()},setEndState:(s,a)=>{if(!this._tokenizer)return;let l=this._tokenizer.store.getFirstInvalidEndStateLineNumber();l!==null&&s>=l&&this._tokenizer?.store.setEndState(s,a)}};i&&i.createBackgroundTokenizer&&!i.backgroundTokenizerShouldOnlyVerifyTokens&&(this._backgroundTokenizer.value=i.createBackgroundTokenizer(this._textModel,r)),!this._backgroundTokenizer.value&&!this._textModel.isTooLargeForTokenization()&&(this._backgroundTokenizer.value=this._defaultBackgroundTokenizer=new hH(this._tokenizer,r),this._defaultBackgroundTokenizer.handleChanges()),i?.backgroundTokenizerShouldOnlyVerifyTokens&&i.createBackgroundTokenizer?(this._debugBackgroundTokens=new m2(this._languageIdCodec),this._debugBackgroundStates=new $I(this._textModel.getLineCount()),this._debugBackgroundTokenizer.clear(),this._debugBackgroundTokenizer.value=i.createBackgroundTokenizer(this._textModel,{setTokens:s=>{this._debugBackgroundTokens?.setMultilineTokens(s,this._textModel)},backgroundTokenizationFinished(){},setEndState:(s,a)=>{this._debugBackgroundStates?.setEndState(s,a)}})):(this._debugBackgroundTokens=void 0,this._debugBackgroundStates=void 0,this._debugBackgroundTokenizer.value=void 0)}this.refreshAllVisibleLineTokens()}handleDidChangeAttached(){this._defaultBackgroundTokenizer?.handleChanges()}handleDidChangeContent(e){if(e.isFlush)this.resetTokenization(!1);else if(!e.isEolChange){for(let t of e.changes){let[i,o]=yu(t.text);this._tokens.acceptEdit(t.range,i,o),this._debugBackgroundTokens?.acceptEdit(t.range,i,o)}this._debugBackgroundStates?.acceptChanges(e.changes),this._tokenizer&&this._tokenizer.store.acceptChanges(e.changes),this._defaultBackgroundTokenizer?.handleChanges()}}setTokens(e){let{changes:t}=this._tokens.setMultilineTokens(e,this._textModel);return t.length>0&&this._onDidChangeTokens.fire({semanticTokensApplied:!1,ranges:t}),{changes:t}}refreshAllVisibleLineTokens(){let e=ut.joinMany([...this._attachedViewStates].map(([t,i])=>i.lineRanges));this.refreshRanges(e)}refreshRanges(e){for(let t of e)this.refreshRange(t.startLineNumber,t.endLineNumberExclusive-1)}refreshRange(e,t){if(!this._tokenizer)return;e=Math.max(1,Math.min(this._textModel.getLineCount(),e)),t=Math.min(this._textModel.getLineCount(),t);let i=new MC,{heuristicTokens:o}=this._tokenizer.tokenizeHeuristically(i,e,t),r=this.setTokens(i.finalize());if(o)for(let s of r.changes)this._backgroundTokenizer.value?.requestTokens(s.fromLineNumber,s.toLineNumber+1);this._defaultBackgroundTokenizer?.checkFinished()}forceTokenization(e){let t=new MC;this._tokenizer?.updateTokensUntilLine(t,e),this.setTokens(t.finalize()),this._defaultBackgroundTokenizer?.checkFinished()}hasAccurateTokensForLine(e){return this._tokenizer?this._tokenizer.hasAccurateTokensForLine(e):!0}isCheapToTokenize(e){return this._tokenizer?this._tokenizer.isCheapToTokenize(e):!0}getLineTokens(e){let t=this._textModel.getLineContent(e),i=this._tokens.getTokens(this._textModel.getLanguageId(),e-1,t);if(this._debugBackgroundTokens&&this._debugBackgroundStates&&this._tokenizer&&this._debugBackgroundStates.getFirstInvalidEndStateLineNumberOrMax()>e&&this._tokenizer.store.getFirstInvalidEndStateLineNumberOrMax()>e){let o=this._debugBackgroundTokens.getTokens(this._textModel.getLanguageId(),e-1,t);!i.equals(o)&&this._debugBackgroundTokenizer.value?.reportMismatchingTokens&&this._debugBackgroundTokenizer.value.reportMismatchingTokens(e)}return i}getTokenTypeIfInsertingCharacter(e,t,i){if(!this._tokenizer)return 0;let o=this._textModel.validatePosition(new P(e,t));return this.forceTokenization(o.lineNumber),this._tokenizer.getTokenTypeIfInsertingCharacter(o,i)}tokenizeLineWithEdit(e,t,i){if(!this._tokenizer)return null;let o=this._textModel.validatePosition(e);return this.forceTokenization(o.lineNumber),this._tokenizer.tokenizeLineWithEdit(o,t,i)}get hasTokens(){return this._tokens.hasTokens}}});var wH,Wd,g2,yH,CH,SH,PC,qI,bw,vw=k(()=>{wH=class{constructor(){this.changeType=1}},Wd=class n{static applyInjectedText(e,t){if(!t||t.length===0)return e;let i="",o=0;for(let r of t)i+=e.substring(o,r.column-1),o=r.column-1,i+=r.options.content;return i+=e.substring(o),i}static fromDecorations(e){let t=[];for(let i of e)i.options.before&&i.options.before.content.length>0&&t.push(new n(i.ownerId,i.range.startLineNumber,i.range.startColumn,i.options.before,0)),i.options.after&&i.options.after.content.length>0&&t.push(new n(i.ownerId,i.range.endLineNumber,i.range.endColumn,i.options.after,1));return t.sort((i,o)=>i.lineNumber===o.lineNumber?i.column===o.column?i.order-o.order:i.column-o.column:i.lineNumber-o.lineNumber),t}constructor(e,t,i,o,r){this.ownerId=e,this.lineNumber=t,this.column=i,this.options=o,this.order=r}},g2=class{constructor(e,t,i){this.changeType=2,this.lineNumber=e,this.detail=t,this.injectedText=i}},yH=class{constructor(e,t){this.changeType=3,this.fromLineNumber=e,this.toLineNumber=t}},CH=class{constructor(e,t,i,o){this.changeType=4,this.injectedTexts=o,this.fromLineNumber=e,this.toLineNumber=t,this.detail=i}},SH=class{constructor(){this.changeType=5}},PC=class n{constructor(e,t,i,o){this.changes=e,this.versionId=t,this.isUndoing=i,this.isRedoing=o,this.resultingSelection=null}containsEvent(e){for(let t=0,i=this.changes.length;t{at();vo();je();Ie();j();Qe();Ai();iC();zW();qe();we();Ui();ER();fs();Ko();Zr();w4e();y4e();$le();qle();S4e();M4e();rce();B4e();DA();K4e();mH();vw();Fe();l9();Oct=function(n,e,t,i){var o=arguments.length,r=o<3?e:i===null?i=Object.getOwnPropertyDescriptor(e,t):i,s;if(typeof Reflect=="object"&&typeof Reflect.decorate=="function")r=Reflect.decorate(n,e,t,i);else for(var a=n.length-1;a>=0;a--)(s=n[a])&&(r=(o<3?s(r):o>3?s(e,t,r):s(e,t))||r);return o>3&&r&&Object.defineProperty(e,t,r),r},kH=function(n,e){return function(t,i){e(t,i,n)}};LH=0,Wct=999,Hct=1e4,mce=class{constructor(e){this._source=e,this._eos=!1}read(){if(this._eos)return null;let e=[],t=0,i=0;do{let o=this._source.read();if(o===null)return this._eos=!0,t===0?null:e.join("");if(o.length>0&&(e[t++]=o,i+=o.length),i>=64*1024)return e.join("")}while(!0)}},_2=()=>{throw new Error("Invalid change accessor")},Hd=class extends D{static{OC=this}static{this._MODEL_SYNC_LIMIT=50*1024*1024}static{this.LARGE_FILE_SIZE_THRESHOLD=20*1024*1024}static{this.LARGE_FILE_LINE_COUNT_THRESHOLD=300*1e3}static{this.LARGE_FILE_HEAP_OPERATION_THRESHOLD=256*1024*1024}static{this.DEFAULT_CREATION_OPTIONS={isForSimpleWidget:!1,tabSize:rs.tabSize,indentSize:rs.indentSize,insertSpaces:rs.insertSpaces,detectIndentation:!1,defaultEOL:1,trimAutoWhitespace:rs.trimAutoWhitespace,largeFileOptimizations:rs.largeFileOptimizations,bracketPairColorizationOptions:rs.bracketPairColorizationOptions}}static resolveOptions(e,t){if(t.detectIndentation){let i=Gle(e,t.tabSize,t.insertSpaces);return new Ax({tabSize:i.tabSize,indentSize:"tabSize",insertSpaces:i.insertSpaces,trimAutoWhitespace:t.trimAutoWhitespace,defaultEOL:t.defaultEOL,bracketPairColorizationOptions:t.bracketPairColorizationOptions})}return new Ax(t)}get onDidChangeLanguage(){return this._tokenizationTextModelPart.onDidChangeLanguage}get onDidChangeLanguageConfiguration(){return this._tokenizationTextModelPart.onDidChangeLanguageConfiguration}get onDidChangeTokens(){return this._tokenizationTextModelPart.onDidChangeTokens}onDidChangeContent(e){return this._eventEmitter.slowEvent(t=>e(t.contentChangedEvent))}onDidChangeContentOrInjectedText(e){return qs(this._eventEmitter.fastEvent(t=>e(t)),this._onDidChangeInjectedText.event(t=>e(t)))}_isDisposing(){return this.__isDisposing}get tokenization(){return this._tokenizationTextModelPart}get bracketPairs(){return this._bracketPairs}get guides(){return this._guidesTextModelPart}constructor(e,t,i,o=null,r,s,a,l){super(),this._undoRedoService=r,this._languageService=s,this._languageConfigurationService=a,this.instantiationService=l,this._onWillDispose=this._register(new A),this.onWillDispose=this._onWillDispose.event,this._onDidChangeDecorations=this._register(new vce(p=>this.handleBeforeFireDecorationsChangedEvent(p))),this.onDidChangeDecorations=this._onDidChangeDecorations.event,this._onDidChangeOptions=this._register(new A),this.onDidChangeOptions=this._onDidChangeOptions.event,this._onDidChangeAttached=this._register(new A),this.onDidChangeAttached=this._onDidChangeAttached.event,this._onDidChangeInjectedText=this._register(new A),this._eventEmitter=this._register(new xce),this._languageSelectionListener=this._register(new Hi),this._deltaDecorationCallCnt=0,this._attachedViews=new fH,LH++,this.id="$model"+LH,this.isForSimpleWidget=i.isForSimpleWidget,typeof o>"u"||o===null?this._associatedResource=Ee.parse("inmemory://model/"+LH):this._associatedResource=o,this._attachedEditorCount=0;let{textBuffer:c,disposable:d}=G4e(e,i.defaultEOL);this._buffer=c,this._bufferDisposable=d,this._options=OC.resolveOptions(this._buffer,i);let u=typeof t=="string"?t:t.languageId;typeof t!="string"&&(this._languageSelectionListener.value=t.onDidChange(()=>this._setLanguage(t.languageId))),this._bracketPairs=this._register(new QW(this,this._languageConfigurationService)),this._guidesTextModelPart=this._register(new sH(this,this._languageConfigurationService)),this._decorationProvider=this._register(new JW(this)),this._tokenizationTextModelPart=this.instantiationService.createInstance(vH,this,this._bracketPairs,u,this._attachedViews);let h=this._buffer.getLineCount(),f=this._buffer.getValueLengthInRange(new S(1,1,h,this._buffer.getLineLength(h)+1),0);i.largeFileOptimizations?(this._isTooLargeForTokenization=f>OC.LARGE_FILE_SIZE_THRESHOLD||h>OC.LARGE_FILE_LINE_COUNT_THRESHOLD,this._isTooLargeForHeapOperation=f>OC.LARGE_FILE_HEAP_OPERATION_THRESHOLD):(this._isTooLargeForTokenization=!1,this._isTooLargeForHeapOperation=!1),this._isTooLargeForSyncing=f>OC._MODEL_SYNC_LIMIT,this._versionId=1,this._alternativeVersionId=1,this._initialUndoRedoSnapshot=null,this._isDisposed=!1,this.__isDisposing=!1,this._instanceId=lB(LH),this._lastDecorationId=0,this._decorations=Object.create(null),this._decorationsTree=new EH,this._commandManager=new nH(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()})),this._languageService.requestRichLanguageFeatures(u),this._register(this._languageConfigurationService.onDidChange(p=>{this._bracketPairs.handleLanguageConfigurationServiceChange(p),this._tokenizationTextModelPart.handleLanguageConfigurationServiceChange(p)}))}dispose(){this.__isDisposing=!0,this._onWillDispose.fire(),this._tokenizationTextModelPart.dispose(),this._isDisposed=!0,super.dispose(),this._bufferDisposable.dispose(),this.__isDisposing=!1;let e=new UI([],"",` `,!1,!1,!0,!0);e.dispose(),this._buffer=e,this._bufferDisposable=D.None}_assertNotDisposed(){if(this._isDisposed)throw new Nt("Model is disposed!")}_emitContentChangedEvent(e,t){this.__isDisposing||(this._tokenizationTextModelPart.handleDidChangeContent(t),this._bracketPairs.handleDidChangeContent(t),this._eventEmitter.fire(new bw(e,t)))}setValue(e){if(this._assertNotDisposed(),e==null)throw js();let{textBuffer:t,disposable:i}=G4e(e,this._options.defaultEOL);this._setValueFromTextBuffer(t,i)}_createContentChanged2(e,t,i,o,r,s,a,l){return{changes:[{range:e,rangeOffset:t,rangeLength:i,text:o}],eol:this._buffer.getEOL(),isEolChange:l,versionId:this.getVersionId(),isUndoing:r,isRedoing:s,isFlush:a}}_setValueFromTextBuffer(e,t){this._assertNotDisposed();let i=this.getFullModelRange(),o=this.getValueLengthInRange(i),r=this.getLineCount(),s=this.getLineMaxColumn(r);this._buffer=e,this._bufferDisposable.dispose(),this._bufferDisposable=t,this._increaseVersionId(),this._decorations=Object.create(null),this._decorationsTree=new EH,this._commandManager.clear(),this._trimAutoWhitespaceLines=null,this._emitContentChangedEvent(new PC([new wH],this._versionId,!1,!1),this._createContentChanged2(new S(1,1,r,s),0,o,this.getValue(),!1,!1,!0,!1))}setEOL(e){this._assertNotDisposed();let t=e===1?`\r `:` `;if(this._buffer.getEOL()===t)return;let i=this.getFullModelRange(),o=this.getValueLengthInRange(i),r=this.getLineCount(),s=this.getLineMaxColumn(r);this._onBeforeEOLChange(),this._buffer.setEOL(t),this._increaseVersionId(),this._onAfterEOLChange(),this._emitContentChangedEvent(new PC([new SH],this._versionId,!1,!1),this._createContentChanged2(new S(1,1,r,s),0,o,this.getValue(),!1,!1,!1,!0))}_onBeforeEOLChange(){this._decorationsTree.ensureAllNodesHaveRanges(this)}_onAfterEOLChange(){let e=this.getVersionId(),t=this._decorationsTree.collectNodesPostOrder();for(let i=0,o=t.length;i0}getAttachedEditorCount(){return this._attachedEditorCount}isTooLargeForSyncing(){return this._isTooLargeForSyncing}isTooLargeForTokenization(){return this._isTooLargeForTokenization}isTooLargeForHeapOperation(){return this._isTooLargeForHeapOperation}isDisposed(){return this._isDisposed}isDominatedByLongLines(){if(this._assertNotDisposed(),this.isTooLargeForTokenization())return!1;let e=0,t=0,i=this._buffer.getLineCount();for(let o=1;o<=i;o++){let r=this._buffer.getLineLength(o);r>=Hct?t+=r:e+=r}return t>e}get uri(){return this._associatedResource}getOptions(){return this._assertNotDisposed(),this._options}getFormattingOptions(){return{tabSize:this._options.indentSize,insertSpaces:this._options.insertSpaces}}updateOptions(e){this._assertNotDisposed();let t=typeof e.tabSize<"u"?e.tabSize:this._options.tabSize,i=typeof e.indentSize<"u"?e.indentSize:this._options.originalIndentSize,o=typeof e.insertSpaces<"u"?e.insertSpaces:this._options.insertSpaces,r=typeof e.trimAutoWhitespace<"u"?e.trimAutoWhitespace:this._options.trimAutoWhitespace,s=typeof e.bracketColorizationOptions<"u"?e.bracketColorizationOptions:this._options.bracketPairColorizationOptions,a=new Ax({tabSize:t,indentSize:i,insertSpaces:o,defaultEOL:this._options.defaultEOL,trimAutoWhitespace:r,bracketPairColorizationOptions:s});if(this._options.equals(a))return;let l=this._options.createChangeEvent(a);this._options=a,this._bracketPairs.handleDidChangeOptions(l),this._decorationProvider.handleDidChangeOptions(l),this._onDidChangeOptions.fire(l)}detectIndentation(e,t){this._assertNotDisposed();let i=Gle(this._buffer,t,e);this.updateOptions({insertSpaces:i.insertSpaces,tabSize:i.tabSize,indentSize:i.tabSize})}normalizeIndentation(e){return this._assertNotDisposed(),NI(e,this._options.indentSize,this._options.insertSpaces)}getVersionId(){return this._assertNotDisposed(),this._versionId}mightContainRTL(){return this._buffer.mightContainRTL()}mightContainUnusualLineTerminators(){return this._buffer.mightContainUnusualLineTerminators()}removeUnusualLineTerminators(e=null){let t=this.findMatches(Ane.source,!1,!0,!1,null,!1,1073741824);this._buffer.resetMightContainUnusualLineTerminators(),this.pushEditOperations(e,t.map(i=>({range:i.range,text:null})),()=>null)}mightContainNonBasicASCII(){return this._buffer.mightContainNonBasicASCII()}getAlternativeVersionId(){return this._assertNotDisposed(),this._alternativeVersionId}getInitialUndoRedoSnapshot(){return this._assertNotDisposed(),this._initialUndoRedoSnapshot}getOffsetAt(e){this._assertNotDisposed();let t=this._validatePosition(e.lineNumber,e.column,0);return this._buffer.getOffsetAt(t.lineNumber,t.column)}getPositionAt(e){this._assertNotDisposed();let t=Math.min(this._buffer.getLength(),Math.max(0,e));return this._buffer.getPositionAt(t)}_increaseVersionId(){this._versionId=this._versionId+1,this._alternativeVersionId=this._versionId}_overwriteVersionId(e){this._versionId=e}_overwriteAlternativeVersionId(e){this._alternativeVersionId=e}_overwriteInitialUndoRedoSnapshot(e){this._initialUndoRedoSnapshot=e}getValue(e,t=!1){if(this._assertNotDisposed(),this.isTooLargeForHeapOperation())throw new Nt("Operation would exceed heap memory limits");let i=this.getFullModelRange(),o=this.getValueInRange(i,e);return t?this._buffer.getBOM()+o:o}createSnapshot(e=!1){return new mce(this._buffer.createSnapshot(e))}getValueLength(e,t=!1){this._assertNotDisposed();let i=this.getFullModelRange(),o=this.getValueLengthInRange(i,e);return t?this._buffer.getBOM().length+o:o}getValueInRange(e,t=0){return this._assertNotDisposed(),this._buffer.getValueInRange(this.validateRange(e),t)}getValueLengthInRange(e,t=0){return this._assertNotDisposed(),this._buffer.getValueLengthInRange(this.validateRange(e),t)}getCharacterCountInRange(e,t=0){return this._assertNotDisposed(),this._buffer.getCharacterCountInRange(this.validateRange(e),t)}getLineCount(){return this._assertNotDisposed(),this._buffer.getLineCount()}getLineContent(e){if(this._assertNotDisposed(),e<1||e>this.getLineCount())throw new Nt("Illegal value for lineNumber");return this._buffer.getLineContent(e)}getLineLength(e){if(this._assertNotDisposed(),e<1||e>this.getLineCount())throw new Nt("Illegal value for lineNumber");return this._buffer.getLineLength(e)}getLinesContent(){if(this._assertNotDisposed(),this.isTooLargeForHeapOperation())throw new Nt("Operation would exceed heap memory limits");return this._buffer.getLinesContent()}getEOL(){return this._assertNotDisposed(),this._buffer.getEOL()}getEndOfLineSequence(){return this._assertNotDisposed(),this._buffer.getEOL()===` `?0:1}getLineMinColumn(e){return this._assertNotDisposed(),1}getLineMaxColumn(e){if(this._assertNotDisposed(),e<1||e>this.getLineCount())throw new Nt("Illegal value for lineNumber");return this._buffer.getLineLength(e)+1}getLineFirstNonWhitespaceColumn(e){if(this._assertNotDisposed(),e<1||e>this.getLineCount())throw new Nt("Illegal value for lineNumber");return this._buffer.getLineFirstNonWhitespaceColumn(e)}getLineLastNonWhitespaceColumn(e){if(this._assertNotDisposed(),e<1||e>this.getLineCount())throw new Nt("Illegal value for lineNumber");return this._buffer.getLineLastNonWhitespaceColumn(e)}_validateRangeRelaxedNoAllocations(e){let t=this._buffer.getLineCount(),i=e.startLineNumber,o=e.startColumn,r=Math.floor(typeof i=="number"&&!isNaN(i)?i:1),s=Math.floor(typeof o=="number"&&!isNaN(o)?o:1);if(r<1)r=1,s=1;else if(r>t)r=t,s=this.getLineMaxColumn(r);else if(s<=1)s=1;else{let u=this.getLineMaxColumn(r);s>=u&&(s=u)}let a=e.endLineNumber,l=e.endColumn,c=Math.floor(typeof a=="number"&&!isNaN(a)?a:1),d=Math.floor(typeof l=="number"&&!isNaN(l)?l:1);if(c<1)c=1,d=1;else if(c>t)c=t,d=this.getLineMaxColumn(c);else if(d<=1)d=1;else{let u=this.getLineMaxColumn(c);d>=u&&(d=u)}return i===r&&o===s&&a===c&&l===d&&e instanceof S&&!(e instanceof Se)?e:new S(r,s,c,d)}_isValidPosition(e,t,i){if(typeof e!="number"||typeof t!="number"||isNaN(e)||isNaN(t)||e<1||t<1||(e|0)!==e||(t|0)!==t)return!1;let o=this._buffer.getLineCount();if(e>o)return!1;if(t===1)return!0;let r=this.getLineMaxColumn(e);if(t>r)return!1;if(i===1){let s=this._buffer.getLineCharCode(e,t-2);if(to(s))return!1}return!0}_validatePosition(e,t,i){let o=Math.floor(typeof e=="number"&&!isNaN(e)?e:1),r=Math.floor(typeof t=="number"&&!isNaN(t)?t:1),s=this._buffer.getLineCount();if(o<1)return new P(1,1);if(o>s)return new P(s,this.getLineMaxColumn(s));if(r<=1)return new P(o,1);let a=this.getLineMaxColumn(o);if(r>=a)return new P(o,a);if(i===1){let l=this._buffer.getLineCharCode(o,r-2);if(to(l))return new P(o,r-1)}return new P(o,r)}validatePosition(e){return this._assertNotDisposed(),e instanceof P&&this._isValidPosition(e.lineNumber,e.column,1)?e:this._validatePosition(e.lineNumber,e.column,1)}_isValidRange(e,t){let i=e.startLineNumber,o=e.startColumn,r=e.endLineNumber,s=e.endColumn;if(!this._isValidPosition(i,o,0)||!this._isValidPosition(r,s,0))return!1;if(t===1){let a=o>1?this._buffer.getLineCharCode(i,o-2):0,l=s>1&&s<=this._buffer.getLineLength(r)?this._buffer.getLineCharCode(r,s-2):0,c=to(a),d=to(l);return!c&&!d}return!0}validateRange(e){if(this._assertNotDisposed(),e instanceof S&&!(e instanceof Se)&&this._isValidRange(e,1))return e;let i=this._validatePosition(e.startLineNumber,e.startColumn,0),o=this._validatePosition(e.endLineNumber,e.endColumn,0),r=i.lineNumber,s=i.column,a=o.lineNumber,l=o.column;{let c=s>1?this._buffer.getLineCharCode(r,s-2):0,d=l>1&&l<=this._buffer.getLineLength(a)?this._buffer.getLineCharCode(a,l-2):0,u=to(c),h=to(d);return!u&&!h?new S(r,s,a,l):r===a&&s===l?new S(r,s-1,a,l-1):u&&h?new S(r,s-1,a,l+1):u?new S(r,s-1,a,l):new S(r,s,a,l+1)}return new S(r,s,a,l)}modifyPosition(e,t){this._assertNotDisposed();let i=this.getOffsetAt(e)+t;return this.getPositionAt(Math.min(this._buffer.getLength(),Math.max(0,i)))}getFullModelRange(){this._assertNotDisposed();let e=this.getLineCount();return new S(1,1,e,this.getLineMaxColumn(e))}findMatchesLineByLine(e,t,i,o){return this._buffer.findMatchesLineByLine(e,t,i,o)}findMatches(e,t,i,o,r,s,a=Wct){this._assertNotDisposed();let l=null;t!==null&&(Array.isArray(t)||(t=[t]),t.every(u=>S.isIRange(u))&&(l=t.map(u=>this.validateRange(u)))),l===null&&(l=[this.getFullModelRange()]),l=l.sort((u,h)=>u.startLineNumber-h.startLineNumber||u.startColumn-h.startColumn);let c=[];c.push(l.reduce((u,h)=>S.areIntersecting(u,h)?u.plusRange(h):(c.push(u),h)));let d;if(!i&&e.indexOf(` `)<0){let h=new gp(e,i,o,r).parseSearchRequest();if(!h)return[];d=f=>this.findMatchesLineByLine(f,h,s,a)}else d=u=>K1.findMatches(this,new gp(e,i,o,r),u,s,a);return c.map(d).reduce((u,h)=>u.concat(h),[])}findNextMatch(e,t,i,o,r,s){this._assertNotDisposed();let a=this.validatePosition(t);if(!i&&e.indexOf(` `)<0){let c=new gp(e,i,o,r).parseSearchRequest();if(!c)return null;let d=this.getLineCount(),u=new S(a.lineNumber,a.column,d,this.getLineMaxColumn(d)),h=this.findMatchesLineByLine(u,c,s,1);return K1.findNextMatch(this,new gp(e,i,o,r),a,s),h.length>0||(u=new S(1,1,a.lineNumber,this.getLineMaxColumn(a.lineNumber)),h=this.findMatchesLineByLine(u,c,s,1),h.length>0)?h[0]:null}return K1.findNextMatch(this,new gp(e,i,o,r),a,s)}findPreviousMatch(e,t,i,o,r,s){this._assertNotDisposed();let a=this.validatePosition(t);return K1.findPreviousMatch(this,new gp(e,i,o,r),a,s)}pushStackElement(){this._commandManager.pushStackElement()}popStackElement(){this._commandManager.popStackElement()}pushEOL(e){if((this.getEOL()===` `?0:1)!==e)try{this._onDidChangeDecorations.beginDeferredEmit(),this._eventEmitter.beginDeferredEmit(),this._initialUndoRedoSnapshot===null&&(this._initialUndoRedoSnapshot=this._undoRedoService.createSnapshot(this.uri)),this._commandManager.pushEOL(e)}finally{this._eventEmitter.endDeferredEmit(),this._onDidChangeDecorations.endDeferredEmit()}}_validateEditOperation(e){return e instanceof kL?e:new kL(e.identifier||null,this.validateRange(e.range),e.text,e.forceMoveMarkers||!1,e.isAutoWhitespaceEdit||!1,e._isTracked||!1)}_validateEditOperations(e){let t=[];for(let i=0,o=e.length;i({range:this.validateRange(a.range),text:a.text})),s=!0;if(e)for(let a=0,l=e.length;ac.endLineNumber,g=c.startLineNumber>f.endLineNumber;if(!p&&!g){d=!0;break}}if(!d){s=!1;break}}if(s)for(let a=0,l=this._trimAutoWhitespaceLines.length;ap.endLineNumber)&&!(c===p.startLineNumber&&p.startColumn===d&&p.isEmpty()&&g&&g.length>0&&g.charAt(0)===` `)&&!(c===p.startLineNumber&&p.startColumn===1&&p.isEmpty()&&g&&g.length>0&&g.charAt(g.length-1)===` `)){u=!1;break}}if(u){let h=new S(c,1,c,d);t.push(new kL(null,h,null,!1,!1,!1))}}this._trimAutoWhitespaceLines=null}return this._initialUndoRedoSnapshot===null&&(this._initialUndoRedoSnapshot=this._undoRedoService.createSnapshot(this.uri)),this._commandManager.pushEditOperation(e,t,i,o)}_applyUndo(e,t,i,o){let r=e.map(s=>{let a=this.getPositionAt(s.newPosition),l=this.getPositionAt(s.newEnd);return{range:new S(a.lineNumber,a.column,l.lineNumber,l.column),text:s.oldText}});this._applyUndoRedoEdits(r,t,!0,!1,i,o)}_applyRedo(e,t,i,o){let r=e.map(s=>{let a=this.getPositionAt(s.oldPosition),l=this.getPositionAt(s.oldEnd);return{range:new S(a.lineNumber,a.column,l.lineNumber,l.column),text:s.newText}});this._applyUndoRedoEdits(r,t,!1,!0,i,o)}_applyUndoRedoEdits(e,t,i,o,r,s){try{this._onDidChangeDecorations.beginDeferredEmit(),this._eventEmitter.beginDeferredEmit(),this._isUndoing=i,this._isRedoing=o,this.applyEdits(e,!1),this.setEOL(t),this._overwriteAlternativeVersionId(r)}finally{this._isUndoing=!1,this._isRedoing=!1,this._eventEmitter.endDeferredEmit(s),this._onDidChangeDecorations.endDeferredEmit()}}applyEdits(e,t=!1){try{this._onDidChangeDecorations.beginDeferredEmit(),this._eventEmitter.beginDeferredEmit();let i=this._validateEditOperations(e);return this._doApplyEdits(i,t)}finally{this._eventEmitter.endDeferredEmit(),this._onDidChangeDecorations.endDeferredEmit()}}_doApplyEdits(e,t){let i=this._buffer.getLineCount(),o=this._buffer.applyEdits(e,this._options.trimAutoWhitespace,t),r=this._buffer.getLineCount(),s=o.changes;if(this._trimAutoWhitespaceLines=o.trimAutoWhitespaceLineNumbers,s.length!==0){for(let c=0,d=s.length;c=0;N--){let M=f+N,F=x+N;E.takeFromEndWhile(te=>te.lineNumber>F);let q=E.takeFromEndWhile(te=>te.lineNumber===F);a.push(new g2(M,this.getLineContent(F),q))}if(bX.lineNumberX.lineNumber===ae)}a.push(new CH(M+1,f+_,$,te))}l+=v}this._emitContentChangedEvent(new PC(a,this.getVersionId(),this._isUndoing,this._isRedoing),{changes:s,eol:this._buffer.getEOL(),isEolChange:!1,versionId:this.getVersionId(),isUndoing:this._isUndoing,isRedoing:this._isRedoing,isFlush:!1})}return o.reverseEdits===null?void 0:o.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(e){if(e===null||e.size===0)return;let i=Array.from(e).map(o=>new g2(o,this.getLineContent(o),this._getInjectedTextInLine(o)));this._onDidChangeInjectedText.fire(new qI(i))}changeDecorations(e,t=0){this._assertNotDisposed();try{return this._onDidChangeDecorations.beginDeferredEmit(),this._changeDecorations(t,e)}finally{this._onDidChangeDecorations.endDeferredEmit()}}_changeDecorations(e,t){let i={addDecoration:(r,s)=>this._deltaDecorationsImpl(e,[],[{range:r,options:s}])[0],changeDecoration:(r,s)=>{this._changeDecorationImpl(r,s)},changeDecorationOptions:(r,s)=>{this._changeDecorationOptionsImpl(r,Z4e(s))},removeDecoration:r=>{this._deltaDecorationsImpl(e,[r],[])},deltaDecorations:(r,s)=>r.length===0&&s.length===0?[]:this._deltaDecorationsImpl(e,r,s)},o=null;try{o=t(i)}catch(r){Be(r)}return i.addDecoration=_2,i.changeDecoration=_2,i.changeDecorationOptions=_2,i.removeDecoration=_2,i.deltaDecorations=_2,o}deltaDecorations(e,t,i=0){if(this._assertNotDisposed(),e||(e=[]),e.length===0&&t.length===0)return[];try{return this._deltaDecorationCallCnt++,this._deltaDecorationCallCnt>1&&(console.warn("Invoking deltaDecorations recursively could lead to leaking decorations."),Be(new Error("Invoking deltaDecorations recursively could lead to leaking decorations."))),this._onDidChangeDecorations.beginDeferredEmit(),this._deltaDecorationsImpl(i,e,t)}finally{this._onDidChangeDecorations.endDeferredEmit(),this._deltaDecorationCallCnt--}}_getTrackedRange(e){return this.getDecorationRange(e)}_setTrackedRange(e,t,i){let o=e?this._decorations[e]:null;if(!o)return t?this._deltaDecorationsImpl(0,[],[{range:t,options:Y4e[i]}],!0)[0]:null;if(!t)return this._decorationsTree.delete(o),delete this._decorations[o.id],null;let r=this._validateRangeRelaxedNoAllocations(t),s=this._buffer.getOffsetAt(r.startLineNumber,r.startColumn),a=this._buffer.getOffsetAt(r.endLineNumber,r.endColumn);return this._decorationsTree.delete(o),o.reset(this.getVersionId(),s,a,r),o.setOptions(Y4e[i]),this._decorationsTree.insert(o),o.id}removeAllDecorationsWithOwnerId(e){if(this._isDisposed)return;let t=this._decorationsTree.collectNodesFromOwner(e);for(let i=0,o=t.length;ithis.getLineCount()?[]:this.getLinesDecorations(e,e,t,i)}getLinesDecorations(e,t,i=0,o=!1,r=!1){let s=this.getLineCount(),a=Math.min(s,Math.max(1,e)),l=Math.min(s,Math.max(1,t)),c=this.getLineMaxColumn(l),d=new S(a,1,l,c),u=this._getDecorationsInRange(d,i,o,r);return yR(u,this._decorationProvider.getDecorationsInRange(d,i,o)),u}getDecorationsInRange(e,t=0,i=!1,o=!1,r=!1){let s=this.validateRange(e),a=this._getDecorationsInRange(s,t,i,r);return yR(a,this._decorationProvider.getDecorationsInRange(s,t,i,o)),a}getOverviewRulerDecorations(e=0,t=!1){return this._decorationsTree.getAll(this,e,t,!0,!1)}getInjectedTextDecorations(e=0){return this._decorationsTree.getAllInjectedText(this,e)}_getInjectedTextInLine(e){let t=this._buffer.getOffsetAt(e,1),i=t+this._buffer.getLineLength(e),o=this._decorationsTree.getInjectedTextInInterval(this,t,i,0);return Wd.fromDecorations(o).filter(r=>r.lineNumber===e)}getAllDecorations(e=0,t=!1){let i=this._decorationsTree.getAll(this,e,t,!1,!1);return i=i.concat(this._decorationProvider.getAllDecorations(e,t)),i}getAllMarginDecorations(e=0){return this._decorationsTree.getAll(this,e,!1,!1,!0)}_getDecorationsInRange(e,t,i,o){let r=this._buffer.getOffsetAt(e.startLineNumber,e.startColumn),s=this._buffer.getOffsetAt(e.endLineNumber,e.endColumn);return this._decorationsTree.getAllInInterval(this,r,s,t,i,o)}getRangeAt(e,t){return this._buffer.getRangeAt(e,t-e)}_changeDecorationImpl(e,t){let i=this._decorations[e];if(!i)return;if(i.options.after){let a=this.getDecorationRange(e);this._onDidChangeDecorations.recordLineAffectedByInjectedText(a.endLineNumber)}if(i.options.before){let a=this.getDecorationRange(e);this._onDidChangeDecorations.recordLineAffectedByInjectedText(a.startLineNumber)}let o=this._validateRangeRelaxedNoAllocations(t),r=this._buffer.getOffsetAt(o.startLineNumber,o.startColumn),s=this._buffer.getOffsetAt(o.endLineNumber,o.endColumn);this._decorationsTree.delete(i),i.reset(this.getVersionId(),r,s,o),this._decorationsTree.insert(i),this._onDidChangeDecorations.checkAffectedAndFire(i.options),i.options.after&&this._onDidChangeDecorations.recordLineAffectedByInjectedText(o.endLineNumber),i.options.before&&this._onDidChangeDecorations.recordLineAffectedByInjectedText(o.startLineNumber)}_changeDecorationOptionsImpl(e,t){let i=this._decorations[e];if(!i)return;let o=!!(i.options.overviewRuler&&i.options.overviewRuler.color),r=!!(t.overviewRuler&&t.overviewRuler.color);if(this._onDidChangeDecorations.checkAffectedAndFire(i.options),this._onDidChangeDecorations.checkAffectedAndFire(t),i.options.after||t.after){let l=this._decorationsTree.getNodeRange(this,i);this._onDidChangeDecorations.recordLineAffectedByInjectedText(l.endLineNumber)}if(i.options.before||t.before){let l=this._decorationsTree.getNodeRange(this,i);this._onDidChangeDecorations.recordLineAffectedByInjectedText(l.startLineNumber)}let s=o!==r,a=Vct(t)!==IH(i);s||a?(this._decorationsTree.delete(i),i.setOptions(t),this._decorationsTree.insert(i)):i.setOptions(t)}_deltaDecorationsImpl(e,t,i,o=!1){let r=this.getVersionId(),s=t.length,a=0,l=i.length,c=0;this._onDidChangeDecorations.beginDeferredEmit();try{let d=new Array(l);for(;athis._setLanguage(e.languageId,t)),this._setLanguage(e.languageId,t))}_setLanguage(e,t){this.tokenization.setLanguageId(e,t),this._languageService.requestRichLanguageFeatures(e)}getLanguageIdAtPosition(e,t){return this.tokenization.getLanguageIdAtPosition(e,t)}getWordAtPosition(e){return this._tokenizationTextModelPart.getWordAtPosition(e)}getWordUntilPosition(e){return this._tokenizationTextModelPart.getWordUntilPosition(e)}normalizePosition(e,t){return e}getLineIndentColumn(e){return zct(this.getLineContent(e))+1}};Hd=OC=Oct([kH(4,ML),kH(5,ai),kH(6,ti),kH(7,he)],Hd);EH=class{constructor(){this._decorationsTree0=new zI,this._decorationsTree1=new zI,this._injectedTextDecorationsTree=new zI}ensureAllNodesHaveRanges(e){this.getAll(e,0,!1,!1,!1)}_ensureNodesHaveRanges(e,t){for(let i of t)i.range===null&&(i.range=e.getRangeAt(i.cachedAbsoluteStart,i.cachedAbsoluteEnd));return t}getAllInInterval(e,t,i,o,r,s){let a=e.getVersionId(),l=this._intervalSearch(t,i,o,r,a,s);return this._ensureNodesHaveRanges(e,l)}_intervalSearch(e,t,i,o,r,s){let a=this._decorationsTree0.intervalSearch(e,t,i,o,r,s),l=this._decorationsTree1.intervalSearch(e,t,i,o,r,s),c=this._injectedTextDecorationsTree.intervalSearch(e,t,i,o,r,s);return a.concat(l).concat(c)}getInjectedTextInInterval(e,t,i,o){let r=e.getVersionId(),s=this._injectedTextDecorationsTree.intervalSearch(t,i,o,!1,r,!1);return this._ensureNodesHaveRanges(e,s).filter(a=>a.options.showIfCollapsed||!a.range.isEmpty())}getAllInjectedText(e,t){let i=e.getVersionId(),o=this._injectedTextDecorationsTree.search(t,!1,i,!1);return this._ensureNodesHaveRanges(e,o).filter(r=>r.options.showIfCollapsed||!r.range.isEmpty())}getAll(e,t,i,o,r){let s=e.getVersionId(),a=this._search(t,i,o,s,r);return this._ensureNodesHaveRanges(e,a)}_search(e,t,i,o,r){if(i)return this._decorationsTree1.search(e,t,o,r);{let s=this._decorationsTree0.search(e,t,o,r),a=this._decorationsTree1.search(e,t,o,r),l=this._injectedTextDecorationsTree.search(e,t,o,r);return s.concat(a).concat(l)}}collectNodesFromOwner(e){let t=this._decorationsTree0.collectNodesFromOwner(e),i=this._decorationsTree1.collectNodesFromOwner(e),o=this._injectedTextDecorationsTree.collectNodesFromOwner(e);return t.concat(i).concat(o)}collectNodesPostOrder(){let e=this._decorationsTree0.collectNodesPostOrder(),t=this._decorationsTree1.collectNodesPostOrder(),i=this._injectedTextDecorationsTree.collectNodesPostOrder();return e.concat(t).concat(i)}insert(e){IH(e)?this._injectedTextDecorationsTree.insert(e):pce(e)?this._decorationsTree1.insert(e):this._decorationsTree0.insert(e)}delete(e){IH(e)?this._injectedTextDecorationsTree.delete(e):pce(e)?this._decorationsTree1.delete(e):this._decorationsTree0.delete(e)}getNodeRange(e,t){let i=e.getVersionId();return t.cachedVersionId!==i&&this._resolveNode(t,i),t.range===null&&(t.range=e.getRangeAt(t.cachedAbsoluteStart,t.cachedAbsoluteEnd)),t.range}_resolveNode(e,t){IH(e)?this._injectedTextDecorationsTree.resolveNode(e,t):pce(e)?this._decorationsTree1.resolveNode(e,t):this._decorationsTree0.resolveNode(e,t)}acceptReplace(e,t,i,o){this._decorationsTree0.acceptReplace(e,t,i,o),this._decorationsTree1.acceptReplace(e,t,i,o),this._injectedTextDecorationsTree.acceptReplace(e,t,i,o)}};TH=class{constructor(e){this.color=e.color||"",this.darkColor=e.darkColor||""}},gce=class extends TH{constructor(e){super(e),this._resolvedColor=null,this.position=typeof e.position=="number"?e.position:Js.Center}getColor(e){return this._resolvedColor||(e.type!=="light"&&this.darkColor?this._resolvedColor=this._resolveColor(this.darkColor,e):this._resolvedColor=this._resolveColor(this.color,e)),this._resolvedColor}invalidateCachedColor(){this._resolvedColor=null}_resolveColor(e,t){if(typeof e=="string")return e;let i=e?t.getColor(e.id):null;return i?i.toString():""}},_ce=class{constructor(e){this.position=e?.position??tl.Center,this.persistLane=e?.persistLane}},bce=class extends TH{constructor(e){super(e),this.position=e.position,this.sectionHeaderStyle=e.sectionHeaderStyle??null,this.sectionHeaderText=e.sectionHeaderText??null}getColor(e){return this._resolvedColor||(e.type!=="light"&&this.darkColor?this._resolvedColor=this._resolveColor(this.darkColor,e):this._resolvedColor=this._resolveColor(this.color,e)),this._resolvedColor}invalidateCachedColor(){this._resolvedColor=void 0}_resolveColor(e,t){return typeof e=="string"?Z.fromHex(e):t.getColor(e.id)}},Lg=class n{static from(e){return e instanceof n?e:new n(e)}constructor(e){this.content=e.content||"",this.inlineClassName=e.inlineClassName||null,this.inlineClassNameAffectsLetterSpacing=e.inlineClassNameAffectsLetterSpacing||!1,this.attachedData=e.attachedData||null,this.cursorStops=e.cursorStops||null}},tt=class n{static register(e){return new n(e)}static createDynamic(e){return new n(e)}constructor(e){this.description=e.description,this.blockClassName=e.blockClassName?kg(e.blockClassName):null,this.blockDoesNotCollapse=e.blockDoesNotCollapse??null,this.blockIsAfterEnd=e.blockIsAfterEnd??null,this.blockPadding=e.blockPadding??null,this.stickiness=e.stickiness||0,this.zIndex=e.zIndex||0,this.className=e.className?kg(e.className):null,this.shouldFillLineOnLineBreak=e.shouldFillLineOnLineBreak??null,this.hoverMessage=e.hoverMessage||null,this.glyphMarginHoverMessage=e.glyphMarginHoverMessage||null,this.lineNumberHoverMessage=e.lineNumberHoverMessage||null,this.isWholeLine=e.isWholeLine||!1,this.showIfCollapsed=e.showIfCollapsed||!1,this.collapseOnReplaceEdit=e.collapseOnReplaceEdit||!1,this.overviewRuler=e.overviewRuler?new gce(e.overviewRuler):null,this.minimap=e.minimap?new bce(e.minimap):null,this.glyphMargin=e.glyphMarginClassName?new _ce(e.glyphMargin):null,this.glyphMarginClassName=e.glyphMarginClassName?kg(e.glyphMarginClassName):null,this.linesDecorationsClassName=e.linesDecorationsClassName?kg(e.linesDecorationsClassName):null,this.lineNumberClassName=e.lineNumberClassName?kg(e.lineNumberClassName):null,this.linesDecorationsTooltip=e.linesDecorationsTooltip?MTe(e.linesDecorationsTooltip):null,this.firstLineDecorationClassName=e.firstLineDecorationClassName?kg(e.firstLineDecorationClassName):null,this.marginClassName=e.marginClassName?kg(e.marginClassName):null,this.inlineClassName=e.inlineClassName?kg(e.inlineClassName):null,this.inlineClassNameAffectsLetterSpacing=e.inlineClassNameAffectsLetterSpacing||!1,this.beforeContentClassName=e.beforeContentClassName?kg(e.beforeContentClassName):null,this.afterContentClassName=e.afterContentClassName?kg(e.afterContentClassName):null,this.after=e.after?Lg.from(e.after):null,this.before=e.before?Lg.from(e.before):null,this.hideInCommentTokens=e.hideInCommentTokens??!1,this.hideInStringTokens=e.hideInStringTokens??!1}};tt.EMPTY=tt.register({description:"empty"});Y4e=[tt.register({description:"tracked-range-always-grows-when-typing-at-edges",stickiness:0}),tt.register({description:"tracked-range-never-grows-when-typing-at-edges",stickiness:1}),tt.register({description:"tracked-range-grows-only-when-typing-before",stickiness:2}),tt.register({description:"tracked-range-grows-only-when-typing-after",stickiness:3})];vce=class extends D{constructor(e){super(),this.handleBeforeFire=e,this._actual=this._register(new A),this.event=this._actual.event,this._affectedInjectedTextLines=null,this._deferredCnt=0,this._shouldFireDeferred=!1,this._affectsMinimap=!1,this._affectsOverviewRuler=!1,this._affectsGlyphMargin=!1,this._affectsLineNumber=!1}beginDeferredEmit(){this._deferredCnt++}endDeferredEmit(){this._deferredCnt--,this._deferredCnt===0&&(this._shouldFireDeferred&&this.doFire(),this._affectedInjectedTextLines?.clear(),this._affectedInjectedTextLines=null)}recordLineAffectedByInjectedText(e){this._affectedInjectedTextLines||(this._affectedInjectedTextLines=new Set),this._affectedInjectedTextLines.add(e)}checkAffectedAndFire(e){this._affectsMinimap||=!!e.minimap?.position,this._affectsOverviewRuler||=!!e.overviewRuler?.color,this._affectsGlyphMargin||=!!e.glyphMarginClassName,this._affectsLineNumber||=!!e.lineNumberClassName,this.tryFire()}fire(){this._affectsMinimap=!0,this._affectsOverviewRuler=!0,this._affectsGlyphMargin=!0,this.tryFire()}tryFire(){this._deferredCnt===0?this.doFire():this._shouldFireDeferred=!0}doFire(){this.handleBeforeFire(this._affectedInjectedTextLines);let e={affectsMinimap:this._affectsMinimap,affectsOverviewRuler:this._affectsOverviewRuler,affectsGlyphMargin:this._affectsGlyphMargin,affectsLineNumber:this._affectsLineNumber};this._shouldFireDeferred=!1,this._affectsMinimap=!1,this._affectsOverviewRuler=!1,this._affectsGlyphMargin=!1,this._actual.fire(e)}},xce=class extends D{constructor(){super(),this._fastEmitter=this._register(new A),this.fastEvent=this._fastEmitter.event,this._slowEmitter=this._register(new A),this.slowEvent=this._slowEmitter.event,this._deferredCnt=0,this._deferredEvent=null}beginDeferredEmit(){this._deferredCnt++}endDeferredEmit(e=null){if(this._deferredCnt--,this._deferredCnt===0&&this._deferredEvent!==null){this._deferredEvent.rawContentChangedEvent.resultingSelection=e;let t=this._deferredEvent;this._deferredEvent=null,this._fastEmitter.fire(t),this._slowEmitter.fire(t)}}fire(e){if(this._deferredCnt>0){this._deferredEvent?this._deferredEvent=this._deferredEvent.merge(e):this._deferredEvent=e;return}this._fastEmitter.fire(e),this._slowEmitter.fire(e)}}});function FC(n){return n.toString()}var Uct,DH,KI,wce,$ct,yce,NH,Cce,X4e=k(()=>{Ie();j();Bt();Ho();ER();Nd();zA();en();l9();wx();$le();ds();ec();Fe();Uct=function(n,e,t,i){var o=arguments.length,r=o<3?e:i===null?i=Object.getOwnPropertyDescriptor(e,t):i,s;if(typeof Reflect=="object"&&typeof Reflect.decorate=="function")r=Reflect.decorate(n,e,t,i);else for(var a=n.length-1;a>=0;a--)(s=n[a])&&(r=(o<3?s(r):o>3?s(e,t,r):s(e,t))||r);return o>3&&r&&Object.defineProperty(e,t,r),r},DH=function(n,e){return function(t,i){e(t,i,n)}};wce=class{constructor(e,t,i){this.model=e,this._modelEventListeners=new H,this.model=e,this._modelEventListeners.add(e.onWillDispose(()=>t(e))),this._modelEventListeners.add(e.onDidChangeLanguage(o=>i(e,o)))}dispose(){this._modelEventListeners.dispose()}},$ct=Qn||dt?1:2,yce=class{constructor(e,t,i,o,r,s,a,l){this.uri=e,this.initialUndoRedoSnapshot=t,this.time=i,this.sharesUndoRedoStack=o,this.heapSize=r,this.sha1=s,this.versionId=a,this.alternativeVersionId=l}},NH=class extends D{static{KI=this}static{this.MAX_MEMORY_FOR_CLOSED_FILES_UNDO_STACK=20*1024*1024}constructor(e,t,i,o){super(),this._configurationService=e,this._resourcePropertiesService=t,this._undoRedoService=i,this._instantiationService=o,this._onModelAdded=this._register(new A),this.onModelAdded=this._onModelAdded.event,this._onModelRemoved=this._register(new A),this.onModelRemoved=this._onModelRemoved.event,this._onModelModeChanged=this._register(new A),this.onModelLanguageChanged=this._onModelModeChanged.event,this._modelCreationOptionsByLanguageAndResource=Object.create(null),this._models={},this._disposedModels=new Map,this._disposedModelsHeapSize=0,this._register(this._configurationService.onDidChangeConfiguration(r=>this._updateModelOptions(r))),this._updateModelOptions(void 0)}static _readModelOptions(e,t){let i=rs.tabSize;if(e.editor&&typeof e.editor.tabSize<"u"){let h=parseInt(e.editor.tabSize,10);isNaN(h)||(i=h),i<1&&(i=1)}let o="tabSize";if(e.editor&&typeof e.editor.indentSize<"u"&&e.editor.indentSize!=="tabSize"){let h=parseInt(e.editor.indentSize,10);isNaN(h)||(o=Math.max(h,1))}let r=rs.insertSpaces;e.editor&&typeof e.editor.insertSpaces<"u"&&(r=e.editor.insertSpaces==="false"?!1:!!e.editor.insertSpaces);let s=$ct,a=e.eol;a===`\r `?s=2:a===` `&&(s=1);let l=rs.trimAutoWhitespace;e.editor&&typeof e.editor.trimAutoWhitespace<"u"&&(l=e.editor.trimAutoWhitespace==="false"?!1:!!e.editor.trimAutoWhitespace);let c=rs.detectIndentation;e.editor&&typeof e.editor.detectIndentation<"u"&&(c=e.editor.detectIndentation==="false"?!1:!!e.editor.detectIndentation);let d=rs.largeFileOptimizations;e.editor&&typeof e.editor.largeFileOptimizations<"u"&&(d=e.editor.largeFileOptimizations==="false"?!1:!!e.editor.largeFileOptimizations);let u=rs.bracketPairColorizationOptions;return e.editor?.bracketPairColorization&&typeof e.editor.bracketPairColorization=="object"&&(u={enabled:!!e.editor.bracketPairColorization.enabled,independentColorPoolPerBracketType:!!e.editor.bracketPairColorization.independentColorPoolPerBracketType}),{isForSimpleWidget:t,tabSize:i,indentSize:o,insertSpaces:r,detectIndentation:c,defaultEOL:s,trimAutoWhitespace:l,largeFileOptimizations:d,bracketPairColorizationOptions:u}}_getEOL(e,t){if(e)return this._resourcePropertiesService.getEOL(e,t);let i=this._configurationService.getValue("files.eol",{overrideIdentifier:t});return i&&typeof i=="string"&&i!=="auto"?i:Ur===3||Ur===2?` `:`\r `}_shouldRestoreUndoStack(){let e=this._configurationService.getValue("files.restoreUndoStack");return typeof e=="boolean"?e:!0}getCreationOptions(e,t,i){let o=typeof e=="string"?e:e.languageId,r=this._modelCreationOptionsByLanguageAndResource[o+t];if(!r){let s=this._configurationService.getValue("editor",{overrideIdentifier:o,resource:t}),a=this._getEOL(t,o);r=KI._readModelOptions({editor:s,eol:a},i),this._modelCreationOptionsByLanguageAndResource[o+t]=r}return r}_updateModelOptions(e){let t=this._modelCreationOptionsByLanguageAndResource;this._modelCreationOptionsByLanguageAndResource=Object.create(null);let i=Object.keys(this._models);for(let o=0,r=i.length;oe){let t=[];for(this._disposedModels.forEach(i=>{i.sharesUndoRedoStack||t.push(i)}),t.sort((i,o)=>i.time-o.time);t.length>0&&this._disposedModelsHeapSize>e;){let i=t.shift();this._removeDisposedModel(i.uri),i.initialUndoRedoSnapshot!==null&&this._undoRedoService.restoreSnapshot(i.initialUndoRedoSnapshot)}}}_createModelData(e,t,i,o){let r=this.getCreationOptions(t,i,o),s=this._instantiationService.createInstance(Hd,e,t,r,i);if(i&&this._disposedModels.has(FC(i))){let c=this._removeDisposedModel(i),d=this._undoRedoService.getElements(i),u=this._getSHA1Computer(),h=u.canComputeSHA1(s)?u.computeSHA1(s)===c.sha1:!1;if(h||c.sharesUndoRedoStack){for(let f of d.past)bg(f)&&f.matchesResource(i)&&f.setModel(s);for(let f of d.future)bg(f)&&f.matchesResource(i)&&f.setModel(s);this._undoRedoService.setElementsValidFlag(i,!0,f=>bg(f)&&f.matchesResource(i)),h&&(s._overwriteVersionId(c.versionId),s._overwriteAlternativeVersionId(c.alternativeVersionId),s._overwriteInitialUndoRedoSnapshot(c.initialUndoRedoSnapshot))}else c.initialUndoRedoSnapshot!==null&&this._undoRedoService.restoreSnapshot(c.initialUndoRedoSnapshot)}let a=FC(s.uri);if(this._models[a])throw new Error("ModelService: Cannot add model because it already exists!");let l=new wce(s,c=>this._onWillDispose(c),(c,d)=>this._onDidChangeLanguage(c,d));return this._models[a]=l,l}createModel(e,t,i,o=!1){let r;return t?r=this._createModelData(e,t,i,o):r=this._createModelData(e,Oo,i,o),this._onModelAdded.fire(r.model),r.model}getModels(){let e=[],t=Object.keys(this._models);for(let i=0,o=t.length;i0||c.future.length>0){for(let d of c.past)bg(d)&&d.matchesResource(e.uri)&&(r=!0,s+=d.heapSize(e.uri),d.setModel(e.uri));for(let d of c.future)bg(d)&&d.matchesResource(e.uri)&&(r=!0,s+=d.heapSize(e.uri),d.setModel(e.uri))}}let a=KI.MAX_MEMORY_FOR_CLOSED_FILES_UNDO_STACK,l=this._getSHA1Computer();if(r)if(!o&&(s>a||!l.canComputeSHA1(e))){let c=i.model.getInitialUndoRedoSnapshot();c!==null&&this._undoRedoService.restoreSnapshot(c)}else this._ensureDisposedModelsHeapSize(a-s),this._undoRedoService.setElementsValidFlag(e.uri,!1,c=>bg(c)&&c.matchesResource(e.uri)),this._insertDisposedModel(new yce(e.uri,i.model.getInitialUndoRedoSnapshot(),Date.now(),o,s,l.computeSHA1(e),e.getVersionId(),e.getAlternativeVersionId()));else if(!o){let c=i.model.getInitialUndoRedoSnapshot();c!==null&&this._undoRedoService.restoreSnapshot(c)}delete this._models[t],i.dispose(),delete this._modelCreationOptionsByLanguageAndResource[e.getLanguageId()+e.uri],this._onModelRemoved.fire(e)}_onDidChangeLanguage(e,t){let i=t.oldLanguage,o=e.getLanguageId(),r=this.getCreationOptions(i,e.uri,e.isForSimpleWidget),s=this.getCreationOptions(o,e.uri,e.isForSimpleWidget);KI._setModelOptionsForModel(e,s,r),this._onModelModeChanged.fire({model:e,oldLanguageId:i})}_getSHA1Computer(){return new Cce}};NH=KI=Uct([DH(0,Ve),DH(1,e9),DH(2,ML),DH(3,he)],NH);Cce=class n{static{this.MAX_MODEL_SIZE=10*1024*1024}canComputeSHA1(e){return e.getValueLength()<=n.MAX_MODEL_SIZE}computeSHA1(e){let t=new TB,i=e.createSnapshot(),o;for(;o=i.read();)t.update(o);return t.digest()}}});var Q4e=k(()=>{});var RH,Fh,Sce,BC=k(()=>{at();j();br();(function(n){n[n.PRESERVE=0]="PRESERVE",n[n.LAST=1]="LAST"})(RH||(RH={}));Fh={Quickaccess:"workbench.contributions.quickaccess"},Sce=class{constructor(){this.providers=[],this.defaultProvider=void 0}registerQuickAccessProvider(e){return e.prefix.length===0?this.defaultProvider=e:this.providers.push(e),this.providers.sort((t,i)=>i.prefix.length-t.prefix.length),ge(()=>{this.providers.splice(this.providers.indexOf(e),1),this.defaultProvider===e&&(this.defaultProvider=void 0)})}getQuickAccessProviders(){return ns([this.defaultProvider,...this.providers])}getQuickAccessProvider(e){return e&&this.providers.find(i=>e.startsWith(i.prefix))||void 0||this.defaultProvider}};ei.add(Fh.Quickaccess,new Sce)});var J4e,xw,Pu,xn,b2,kce,hsi,Pr,Jc=k(()=>{Fe();J4e={ctrlCmd:!1,alt:!1};(function(n){n[n.Blur=1]="Blur",n[n.Gesture=2]="Gesture",n[n.Other=3]="Other"})(xw||(xw={}));(function(n){n[n.NONE=0]="NONE",n[n.FIRST=1]="FIRST",n[n.SECOND=2]="SECOND",n[n.LAST=3]="LAST"})(Pu||(Pu={}));(function(n){n[n.First=1]="First",n[n.Second=2]="Second",n[n.Last=3]="Last",n[n.Next=4]="Next",n[n.Previous=5]="Previous",n[n.NextPage=6]="NextPage",n[n.PreviousPage=7]="PreviousPage",n[n.NextSeparator=8]="NextSeparator",n[n.PreviousSeparator=9]="PreviousSeparator"})(xn||(xn={}));(function(n){n[n.Title=1]="Title",n[n.Inline=2]="Inline"})(b2||(b2={}));kce=class{constructor(e){this.options=e}},hsi=new kce,Pr=We("quickInputService")});var jct,eFe,AH,tFe=k(()=>{ft();ci();Ie();j();Fe();BC();Jc();br();jct=function(n,e,t,i){var o=arguments.length,r=o<3?e:i===null?i=Object.getOwnPropertyDescriptor(e,t):i,s;if(typeof Reflect=="object"&&typeof Reflect.decorate=="function")r=Reflect.decorate(n,e,t,i);else for(var a=n.length-1;a>=0;a--)(s=n[a])&&(r=(o<3?s(r):o>3?s(e,t,r):s(e,t))||r);return o>3&&r&&Object.defineProperty(e,t,r),r},eFe=function(n,e){return function(t,i){e(t,i,n)}},AH=class extends D{constructor(e,t){super(),this.quickInputService=e,this.instantiationService=t,this.registry=ei.as(Fh.Quickaccess),this.mapProviderToDescriptor=new Map,this.lastAcceptedPickerValues=new Map,this.visibleQuickAccess=void 0}show(e="",t){this.doShowOrPick(e,!1,t)}doShowOrPick(e,t,i){let[o,r]=this.getOrInstantiateProvider(e,i?.enabledProviderPrefixes),s=this.visibleQuickAccess,a=s?.descriptor;if(s&&r&&a===r){e!==r.prefix&&!i?.preserveValue&&(s.picker.value=e),this.adjustValueSelection(s.picker,r,i);return}if(r&&!i?.preserveValue){let p;if(s&&a&&a!==r){let g=s.value.substr(a.prefix.length);g&&(p=`${r.prefix}${g}`)}if(!p){let g=o?.defaultFilterValue;g===RH.LAST?p=this.lastAcceptedPickerValues.get(r):typeof g=="string"&&(p=`${r.prefix}${g}`)}typeof p=="string"&&(e=p)}let l=s?.picker?.valueSelection,c=s?.picker?.value,d=new H,u=d.add(this.quickInputService.createQuickPick({useSeparators:!0}));u.value=e,this.adjustValueSelection(u,r,i),u.placeholder=i?.placeholder??r?.placeholder,u.quickNavigate=i?.quickNavigateConfiguration,u.hideInput=!!u.quickNavigate&&!s,(typeof i?.itemActivation=="number"||i?.quickNavigateConfiguration)&&(u.itemActivation=i?.itemActivation??Pu.SECOND),u.contextKey=r?.contextKey,u.filterValue=p=>p.substring(r?r.prefix.length:0);let h;t&&(h=new mu,d.add(ne.once(u.onWillAccept)(p=>{p.veto(),u.hide()}))),d.add(this.registerPickerListeners(u,o,r,e,i));let f=d.add(new qt);if(o&&d.add(o.provide(u,f.token,i?.providerOptions)),ne.once(u.onDidHide)(()=>{u.selectedItems.length===0&&f.cancel(),d.dispose(),h?.complete(u.selectedItems.slice(0))}),u.show(),l&&c===e&&(u.valueSelection=l),t)return h?.p}adjustValueSelection(e,t,i){let o;i?.preserveValue?o=[e.value.length,e.value.length]:o=[t?.prefix.length??0,e.value.length],e.valueSelection=o}registerPickerListeners(e,t,i,o,r){let s=new H,a=this.visibleQuickAccess={picker:e,descriptor:i,value:o};return s.add(ge(()=>{a===this.visibleQuickAccess&&(this.visibleQuickAccess=void 0)})),s.add(e.onDidChangeValue(l=>{let[c]=this.getOrInstantiateProvider(l,r?.enabledProviderPrefixes);c!==t?this.show(l,{enabledProviderPrefixes:r?.enabledProviderPrefixes,preserveValue:!0,providerOptions:r?.providerOptions}):a.value=l})),i&&s.add(e.onDidAccept(()=>{this.lastAcceptedPickerValues.set(i,e.value)})),s}getOrInstantiateProvider(e,t){let i=this.registry.getQuickAccessProvider(e);if(!i||t&&!t?.includes(i.prefix))return[void 0,void 0];let o=this.mapProviderToDescriptor.get(i);return o||(o=this.instantiationService.createInstance(i.ctor),this.mapProviderToDescriptor.set(i,o)),[o,i]}};AH=jct([eFe(0,Pr),eFe(1,he)],AH)});var iFe=k(()=>{});var Bh,GI=k(()=>{Lh();bn();Ie();iFe();Ps();Ah();Bh=class extends Yo{constructor(e){super(),this._onChange=this._register(new A),this.onChange=this._onChange.event,this._onKeyDown=this._register(new A),this.onKeyDown=this._onKeyDown.event,this._opts=e,this._checked=this._opts.isChecked;let t=["monaco-custom-toggle"];this._opts.icon&&(this._icon=this._opts.icon,t.push(...Oe.asClassNameArray(this._icon))),this._opts.actionClassName&&t.push(...this._opts.actionClassName.split(" ")),this._checked&&t.push("checked"),this.domNode=document.createElement("div"),this._hover=this._register(Os().setupManagedHover(e.hoverDelegate??lo("mouse"),this.domNode,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,i=>{this.enabled&&(this.checked=!this._checked,this._onChange.fire(!1),i.preventDefault())}),this._register(this.ignoreGesture(this.domNode)),this.onkeydown(this.domNode,i=>{if(i.keyCode===10||i.keyCode===3){this.checked=!this._checked,this._onChange.fire(!0),i.preventDefault(),i.stopPropagation();return}this._onKeyDown.fire(i)})}get enabled(){return this.domNode.getAttribute("aria-disabled")!=="true"}focus(){this.domNode.focus()}get checked(){return this._checked}set checked(e){this._checked=e,this.domNode.setAttribute("aria-checked",String(this._checked)),this.domNode.classList.toggle("checked",this._checked),this.applyStyles()}width(){return 22}applyStyles(){this.domNode&&(this.domNode.style.borderColor=this._checked&&this._opts.inputActiveOptionBorder||"",this.domNode.style.color=this._checked&&this._opts.inputActiveOptionForeground||"inherit",this.domNode.style.backgroundColor=this._checked&&this._opts.inputActiveOptionBackground||"")}enable(){this.domNode.setAttribute("aria-disabled",String(!1))}disable(){this.domNode.setAttribute("aria-disabled",String(!0))}}});var MH=k(()=>{});function nFe(n){let e=[],t=0,i;for(;i=Kct.exec(n);){i.index-t>0&&e.push(n.substring(t,i.index));let[,o,r,,s]=i;s?e.push({label:o,href:r,title:s}):e.push({label:o,href:r}),t=i.index+i[0].length}return t{Yx();qct=function(n,e,t,i){var o=arguments.length,r=o<3?e:i===null?i=Object.getOwnPropertyDescriptor(e,t):i,s;if(typeof Reflect=="object"&&typeof Reflect.decorate=="function")r=Reflect.decorate(n,e,t,i);else for(var a=n.length-1;a>=0;a--)(s=n[a])&&(r=(o<3?s(r):o>3?s(e,t,r):s(e,t))||r);return o>3&&r&&Object.defineProperty(e,t,r),r},PH=class{constructor(e){this.nodes=e}toString(){return this.nodes.map(e=>typeof e=="string"?e:e.label).join("")}};qct([Hn],PH.prototype,"toString",null);Kct=/\[([^\]]+)\]\(((?:https?:\/\/|command:|file:)[^\)\s]+)(?: (["'])(.+?)(\3))?\)/gi});function Yct(n){if(!n)return;let e,t=n.dark.toString();return Lce[t]?e=Lce[t]:(e=Gct.nextId(),hL(`.${e}, .hc-light .${e}`,`background-image: ${_u(n.light||n.dark)}`),hL(`.vs-dark .${e}, .hc-black .${e}`,`background-image: ${_u(n.dark)}`),Lce[t]=e),e}function WC(n,e,t){let i=n.iconClass||Yct(n.iconPath);return n.alwaysVisible&&(i=i?`${i} always-visible`:"always-visible"),{id:e,label:"",tooltip:n.tooltip||"",class:i,enabled:!0,run:t}}function rFe(n,e,t){oo(e);let i=nFe(n),o=0;for(let r of i.nodes)if(typeof r=="string")e.append(...Iu(r));else{let s=r.title;!s&&r.href.startsWith("command:")?s=m("executeCommand","Click to execute command '{0}'",r.href.substring(8)):s||(s=r.href);let a=J("a",{href:r.href,title:s,tabIndex:o++},r.label);a.style.textDecoration="underline";let l=f=>{yDe(f)&&Rt.stop(f,!0),t.callback(r.href)},c=t.disposables.add(new Mt(a,re.CLICK)).event,d=t.disposables.add(new Mt(a,re.KEY_DOWN)).event,u=ne.chain(d,f=>f.filter(p=>{let g=new Xt(p);return g.equals(10)||g.equals(3)}));t.disposables.add(so.addTarget(a));let h=t.disposables.add(new Mt(a,Mi.Tap)).event;ne.any(c,h,u)(l,null,t.disposables),e.appendChild(a)}}var Lce,Gct,Ice=k(()=>{ke();Sf();Ie();Ks();Pd();ub();mM();oFe();MH();pe();Lce={},Gct=new pC("quick-input-button-icon-")});var Zct,sFe,aFe,lFe,cFe,Ece,dFe,uFe,hFe,fFe,OH,FH,v2,BH,WH,HH=k(()=>{ke();Ks();GI();at();ft();Qi();Ie();j();Bt();ob();bn();MH();pe();Jc();Ice();en();db();it();Zct=function(n,e,t,i){var o=arguments.length,r=o<3?e:i===null?i=Object.getOwnPropertyDescriptor(e,t):i,s;if(typeof Reflect=="object"&&typeof Reflect.decorate=="function")r=Reflect.decorate(n,e,t,i);else for(var a=n.length-1;a>=0;a--)(s=n[a])&&(r=(o<3?s(r):o>3?s(e,t,r):s(e,t))||r);return o>3&&r&&Object.defineProperty(e,t,r),r},sFe=function(n,e){return function(t,i){e(t,i,n)}},aFe="inQuickInput",lFe=new me(aFe,!1,m("inQuickInput","Whether keyboard focus is inside the quick input control")),cFe=Y.has(aFe),Ece="quickInputType",dFe=new me(Ece,void 0,m("quickInputType","The type of the currently visible quick input")),uFe="cursorAtEndOfQuickInputBox",hFe=new me(uFe,!1,m("cursorAtEndOfQuickInputBox","Whether the cursor in the quick input is at the end of the input box")),fFe=Y.has(uFe),OH={iconClass:Oe.asClassName(oe.quickInputBack),tooltip:m("quickInput.back","Back"),handle:-1},FH=class n extends D{static{this.noPromptMessage=m("inputModeEntry","Press 'Enter' to confirm your input or 'Escape' to cancel")}constructor(e){super(),this.ui=e,this._widgetUpdated=!1,this.visible=!1,this._enabled=!0,this._busy=!1,this._ignoreFocusOut=!1,this._leftButtons=[],this._rightButtons=[],this._inlineButtons=[],this.buttonsUpdated=!1,this._toggles=[],this.togglesUpdated=!1,this.noValidationMessage=n.noPromptMessage,this._severity=Mn.Ignore,this.onDidTriggerButtonEmitter=this._register(new A),this.onDidHideEmitter=this._register(new A),this.onWillHideEmitter=this._register(new A),this.onDisposeEmitter=this._register(new A),this.visibleDisposables=this._register(new H),this.onDidHide=this.onDidHideEmitter.event}get title(){return this._title}set title(e){this._title=e,this.update()}get description(){return this._description}set description(e){this._description=e,this.update()}get step(){return this._steps}set step(e){this._steps=e,this.update()}get totalSteps(){return this._totalSteps}set totalSteps(e){this._totalSteps=e,this.update()}get enabled(){return this._enabled}set enabled(e){this._enabled=e,this.update()}get contextKey(){return this._contextKey}set contextKey(e){this._contextKey=e,this.update()}get busy(){return this._busy}set busy(e){this._busy=e,this.update()}get ignoreFocusOut(){return this._ignoreFocusOut}set ignoreFocusOut(e){let t=this._ignoreFocusOut!==e&&!Xa;this._ignoreFocusOut=e&&!Xa,t&&this.update()}get titleButtons(){return this._leftButtons.length?[...this._leftButtons,this._rightButtons]:this._rightButtons}get buttons(){return[...this._leftButtons,...this._rightButtons,...this._inlineButtons]}set buttons(e){this._leftButtons=e.filter(t=>t===OH),this._rightButtons=e.filter(t=>t!==OH&&t.location!==b2.Inline),this._inlineButtons=e.filter(t=>t.location===b2.Inline),this.buttonsUpdated=!0,this.update()}get toggles(){return this._toggles}set toggles(e){this._toggles=e??[],this.togglesUpdated=!0,this.update()}get validationMessage(){return this._validationMessage}set validationMessage(e){this._validationMessage=e,this.update()}get severity(){return this._severity}set severity(e){this._severity=e,this.update()}show(){this.visible||(this.visibleDisposables.add(this.ui.onDidTriggerButton(e=>{this.buttons.indexOf(e)!==-1&&this.onDidTriggerButtonEmitter.fire(e)})),this.ui.show(this),this.visible=!0,this._lastValidationMessage=void 0,this._lastSeverity=void 0,this.buttons.length&&(this.buttonsUpdated=!0),this.toggles.length&&(this.togglesUpdated=!0),this.update())}hide(){this.visible&&this.ui.hide()}didHide(e=xw.Other){this.visible=!1,this.visibleDisposables.clear(),this.onDidHideEmitter.fire({reason:e})}willHide(e=xw.Other){this.onWillHideEmitter.fire({reason:e})}update(){if(!this.visible)return;let e=this.getTitle();e&&this.ui.title.textContent!==e?this.ui.title.textContent=e:!e&&this.ui.title.innerHTML!==" "&&(this.ui.title.innerText="\xA0");let t=this.getDescription();if(this.ui.description1.textContent!==t&&(this.ui.description1.textContent=t),this.ui.description2.textContent!==t&&(this.ui.description2.textContent=t),this._widgetUpdated&&(this._widgetUpdated=!1,this._widget?oo(this.ui.widget,this._widget):oo(this.ui.widget)),this.busy&&!this.busyDelay&&(this.busyDelay=new _r,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();let o=this._leftButtons.map((a,l)=>WC(a,`id-${l}`,async()=>this.onDidTriggerButtonEmitter.fire(a)));this.ui.leftActionBar.push(o,{icon:!0,label:!1}),this.ui.rightActionBar.clear();let r=this._rightButtons.map((a,l)=>WC(a,`id-${l}`,async()=>this.onDidTriggerButtonEmitter.fire(a)));this.ui.rightActionBar.push(r,{icon:!0,label:!1}),this.ui.inlineActionBar.clear();let s=this._inlineButtons.map((a,l)=>WC(a,`id-${l}`,async()=>this.onDidTriggerButtonEmitter.fire(a)));this.ui.inlineActionBar.push(s,{icon:!0,label:!1})}if(this.togglesUpdated){this.togglesUpdated=!1;let o=this.toggles?.filter(r=>r instanceof Bh)??[];this.ui.inputBox.toggles=o}this.ui.ignoreFocusOut=this.ignoreFocusOut,this.ui.setEnabled(this.enabled),this.ui.setContextKey(this.contextKey);let i=this.validationMessage||this.noValidationMessage;this._lastValidationMessage!==i&&(this._lastValidationMessage=i,oo(this.ui.message),rFe(i,this.ui.message,{callback:o=>{this.ui.linkOpenerDelegate(o)},disposables:this.visibleDisposables})),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?m("quickInput.steps","{0}/{1}",this.step,this.totalSteps):this.step?String(this.step):""}showMessageDecoration(e){if(this.ui.inputBox.showDecoration(e),e!==Mn.Ignore){let t=this.ui.inputBox.stylesForType(e);this.ui.message.style.color=t.foreground?`${t.foreground}`:"",this.ui.message.style.backgroundColor=t.background?`${t.background}`:"",this.ui.message.style.border=t.border?`1px solid ${t.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()}},v2=class n extends FH{constructor(){super(...arguments),this._value="",this.onDidChangeValueEmitter=this._register(new A),this.onWillAcceptEmitter=this._register(new A),this.onDidAcceptEmitter=this._register(new A),this.onDidCustomEmitter=this._register(new A),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._keepScrollPosition=!1,this._itemActivation=Pu.FIRST,this._activeItems=[],this.activeItemsUpdated=!1,this.activeItemsToConfirm=[],this.onDidChangeActiveEmitter=this._register(new A),this._selectedItems=[],this.selectedItemsUpdated=!1,this.selectedItemsToConfirm=[],this.onDidChangeSelectionEmitter=this._register(new A),this.onDidTriggerItemButtonEmitter=this._register(new A),this.onDidTriggerSeparatorButtonEmitter=this._register(new A),this.valueSelectionUpdated=!0,this._ok="default",this._customButton=!1,this._focusEventBufferer=new uf,this.type="quickPick",this.filterValue=e=>e,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,this.onDidTriggerSeparatorButton=this.onDidTriggerSeparatorButtonEmitter.event}static{this.DEFAULT_ARIA_LABEL=m("quickInputBox.ariaLabel","Type to narrow down results.")}get quickNavigate(){return this._quickNavigate}set quickNavigate(e){this._quickNavigate=e,this.update()}get value(){return this._value}set value(e){this.doSetValue(e)}doSetValue(e,t){this._value!==e&&(this._value=e,t||this.update(),this.visible&&this.ui.list.filter(this.filterValue(this._value))&&this.trySelectFirst(),this.onDidChangeValueEmitter.fire(this._value))}set ariaLabel(e){this._ariaLabel=e,this.update()}get ariaLabel(){return this._ariaLabel}get placeholder(){return this._placeholder}set placeholder(e){this._placeholder=e,this.update()}get items(){return this._items}get scrollTop(){return this.ui.list.scrollTop}set scrollTop(e){this.ui.list.scrollTop=e}set items(e){this._items=e,this.itemsUpdated=!0,this.update()}get canSelectMany(){return this._canSelectMany}set canSelectMany(e){this._canSelectMany=e,this.update()}get canAcceptInBackground(){return this._canAcceptInBackground}set canAcceptInBackground(e){this._canAcceptInBackground=e}get matchOnDescription(){return this._matchOnDescription}set matchOnDescription(e){this._matchOnDescription=e,this.update()}get matchOnDetail(){return this._matchOnDetail}set matchOnDetail(e){this._matchOnDetail=e,this.update()}get matchOnLabel(){return this._matchOnLabel}set matchOnLabel(e){this._matchOnLabel=e,this.update()}get matchOnLabelMode(){return this._matchOnLabelMode}set matchOnLabelMode(e){this._matchOnLabelMode=e,this.update()}get sortByLabel(){return this._sortByLabel}set sortByLabel(e){this._sortByLabel=e,this.update()}get keepScrollPosition(){return this._keepScrollPosition}set keepScrollPosition(e){this._keepScrollPosition=e}get itemActivation(){return this._itemActivation}set itemActivation(e){this._itemActivation=e}get activeItems(){return this._activeItems}set activeItems(e){this._activeItems=e,this.activeItemsUpdated=!0,this.update()}get selectedItems(){return this._selectedItems}set selectedItems(e){this._selectedItems=e,this.selectedItemsUpdated=!0,this.update()}get keyMods(){return this._quickNavigate?J4e:this.ui.keyMods}get valueSelection(){let e=this.ui.inputBox.getSelection();if(e)return[e.start,e.end]}set valueSelection(e){this._valueSelection=e,this.valueSelectionUpdated=!0,this.update()}get customButton(){return this._customButton}set customButton(e){this._customButton=e,this.update()}get customLabel(){return this._customButtonLabel}set customLabel(e){this._customButtonLabel=e,this.update()}get customHover(){return this._customButtonHover}set customHover(e){this._customButtonHover=e,this.update()}get ok(){return this._ok}set ok(e){this._ok=e,this.update()}get hideInput(){return!!this._hideInput}set hideInput(e){this._hideInput=e,this.update()}trySelectFirst(){this.canSelectMany||this.ui.list.focus(xn.First)}show(){this.visible||(this.visibleDisposables.add(this.ui.inputBox.onDidChange(e=>{this.doSetValue(e,!0)})),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._focusEventBufferer.wrapEvent(this.ui.list.onDidChangeFocus,(e,t)=>t)(e=>{this.activeItemsUpdated||this.activeItemsToConfirm!==this._activeItems&&oi(e,this._activeItems,(t,i)=>t===i)||(this._activeItems=e,this.onDidChangeActiveEmitter.fire(e))})),this.visibleDisposables.add(this.ui.list.onDidChangeSelection(({items:e,event:t})=>{if(this.canSelectMany){e.length&&this.ui.list.setSelectedElements([]);return}this.selectedItemsToConfirm!==this._selectedItems&&oi(e,this._selectedItems,(i,o)=>i===o)||(this._selectedItems=e,this.onDidChangeSelectionEmitter.fire(e),e.length&&this.handleAccept(fL(t)&&t.button===1))})),this.visibleDisposables.add(this.ui.list.onChangedCheckedElements(e=>{!this.canSelectMany||!this.visible||this.selectedItemsToConfirm!==this._selectedItems&&oi(e,this._selectedItems,(t,i)=>t===i)||(this._selectedItems=e,this.onDidChangeSelectionEmitter.fire(e))})),this.visibleDisposables.add(this.ui.list.onButtonTriggered(e=>this.onDidTriggerItemButtonEmitter.fire(e))),this.visibleDisposables.add(this.ui.list.onSeparatorButtonTriggered(e=>this.onDidTriggerSeparatorButtonEmitter.fire(e))),this.visibleDisposables.add(this.registerQuickNavigation()),this.valueSelectionUpdated=!0),super.show()}handleAccept(e){let t=!1;this.onWillAcceptEmitter.fire({veto:()=>t=!0}),t||this.onDidAcceptEmitter.fire({inBackground:e})}registerQuickNavigation(){return U(this.ui.container,re.KEY_UP,e=>{if(this.canSelectMany||!this._quickNavigate)return;let t=new Xt(e),i=t.keyCode;this._quickNavigate.keybindings.some(s=>{let a=s.getChords();return a.length>1?!1:a[0].shiftKey&&i===4?!(t.ctrlKey||t.altKey||t.metaKey):!!(a[0].altKey&&i===6||a[0].ctrlKey&&i===5||a[0].metaKey&&i===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;let e=this.keepScrollPosition?this.scrollTop:0,t=!!this.description,i={title:!!this.title||!!this.step||!!this.titleButtons.length,description:t,checkAll:this.canSelectMany&&!this._hideCheckAll,checkBox:this.canSelectMany,inputBox:!this._hideInput,progressBar:!this._hideInput||t,visibleCount:!0,count:this.canSelectMany&&!this._hideCountBadge,ok:this.ok==="default"?this.canSelectMany:this.ok,list:!0,message:!!this.validationMessage,customButton:this.customButton};this.ui.setVisibilities(i),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 o=this.ariaLabel;!o&&i.inputBox&&(o=this.placeholder||n.DEFAULT_ARIA_LABEL,this.title&&(o+=` - ${this.title}`)),this.ui.list.ariaLabel!==o&&(this.ui.list.ariaLabel=o??null),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&&(this.itemsUpdated=!1,this._focusEventBufferer.bufferEvents(()=>{switch(this.ui.list.setElements(this.items),this.ui.list.shouldLoop=!this.canSelectMany,this.ui.list.filter(this.filterValue(this.ui.inputBox.value)),this._itemActivation){case Pu.NONE:this._itemActivation=Pu.FIRST;break;case Pu.SECOND:this.ui.list.focus(xn.Second),this._itemActivation=Pu.FIRST;break;case Pu.LAST:this.ui.list.focus(xn.Last),this._itemActivation=Pu.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||"",i.inputBox||(this.ui.list.domFocus(),this.canSelectMany&&this.ui.list.focus(xn.First)),this.keepScrollPosition&&(this.scrollTop=e)}focus(e){this.ui.list.focus(e),this.canSelectMany&&this.ui.list.domFocus()}accept(e){e&&!this._canAcceptInBackground||this.activeItems[0]&&(this._selectedItems=[this.activeItems[0]],this.onDidChangeSelectionEmitter.fire(this.selectedItems),this.handleAccept(e??!1))}},BH=class extends FH{constructor(){super(...arguments),this._value="",this.valueSelectionUpdated=!0,this._password=!1,this.onDidValueChangeEmitter=this._register(new A),this.onDidAcceptEmitter=this._register(new A),this.type="inputBox",this.onDidChangeValue=this.onDidValueChangeEmitter.event,this.onDidAccept=this.onDidAcceptEmitter.event}get value(){return this._value}set value(e){this._value=e||"",this.update()}get placeholder(){return this._placeholder}set placeholder(e){this._placeholder=e,this.update()}get password(){return this._password}set password(e){this._password=e,this.update()}show(){this.visible||(this.visibleDisposables.add(this.ui.inputBox.onDidChange(e=>{e!==this.value&&(this._value=e,this.onDidValueChangeEmitter.fire(e))})),this.visibleDisposables.add(this.ui.onDidAccept(()=>this.onDidAcceptEmitter.fire())),this.valueSelectionUpdated=!0),super.show()}update(){if(!this.visible)return;this.ui.container.classList.remove("hidden-input");let e={title:!!this.title||!!this.step||!!this.titleButtons.length,description:!!this.description||!!this.step,inputBox:!0,message:!0,progressBar:!0};this.ui.setVisibilities(e),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||""),this.ui.inputBox.password!==this.password&&(this.ui.inputBox.password=this.password)}},WH=class extends Gm{constructor(e,t){super("element",!1,i=>this.getOverrideOptions(i),e,t)}getOverrideOptions(e){let t=(_n(e.content)?e.content.textContent??"":typeof e.content=="string"?e.content:e.content.value).includes(` `);return{persistence:{hideOnKeyDown:!1},appearance:{showHoverHint:t,skipFadeInAnimation:!0}}}};WH=Zct([sFe(0,Ve),sFe(1,cc)],WH)});var pFe=k(()=>{});var Eai,Tb,zH=k(()=>{ke();IB();Ks();bM();Pd();Ps();ub();vo();Ie();Pl();j();bn();pFe();Ah();Eai={buttonBackground:"#0E639C",buttonHoverBackground:"#006BB3",buttonSeparator:Z.white.toString(),buttonForeground:Z.white.toString(),buttonBorder:void 0,buttonSecondaryBackground:void 0,buttonSecondaryForeground:void 0,buttonSecondaryHoverBackground:void 0},Tb=class extends D{get onDidClick(){return this._onDidClick.event}constructor(e,t){super(),this._label="",this._onDidClick=this._register(new A),this._onDidEscape=this._register(new A),this.options=t,this._element=document.createElement("a"),this._element.classList.add("monaco-button"),this._element.tabIndex=0,this._element.setAttribute("role","button"),this._element.classList.toggle("secondary",!!t.secondary);let i=t.secondary?t.buttonSecondaryBackground:t.buttonBackground,o=t.secondary?t.buttonSecondaryForeground:t.buttonForeground;this._element.style.color=o||"",this._element.style.backgroundColor=i||"",t.supportShortLabel&&(this._labelShortElement=document.createElement("div"),this._labelShortElement.classList.add("monaco-button-label-short"),this._element.appendChild(this._labelShortElement),this._labelElement=document.createElement("div"),this._labelElement.classList.add("monaco-button-label"),this._element.appendChild(this._labelElement),this._element.classList.add("monaco-text-button-with-short-label")),typeof t.title=="string"&&this.setTitle(t.title),typeof t.ariaLabel=="string"&&this._element.setAttribute("aria-label",t.ariaLabel),e.appendChild(this._element),this._register(so.addTarget(this._element)),[re.CLICK,Mi.Tap].forEach(r=>{this._register(U(this._element,r,s=>{if(!this.enabled){Rt.stop(s);return}this._onDidClick.fire(s)}))}),this._register(U(this._element,re.KEY_DOWN,r=>{let s=new Xt(r),a=!1;this.enabled&&(s.equals(3)||s.equals(10))?(this._onDidClick.fire(r),a=!0):s.equals(9)&&(this._onDidEscape.fire(r),this._element.blur(),a=!0),a&&Rt.stop(s,!0)})),this._register(U(this._element,re.MOUSE_OVER,r=>{this._element.classList.contains("disabled")||this.updateBackground(!0)})),this._register(U(this._element,re.MOUSE_OUT,r=>{this.updateBackground(!1)})),this.focusTracker=this._register(ba(this._element)),this._register(this.focusTracker.onDidFocus(()=>{this.enabled&&this.updateBackground(!0)})),this._register(this.focusTracker.onDidBlur(()=>{this.enabled&&this.updateBackground(!1)}))}dispose(){super.dispose(),this._element.remove()}getContentElements(e){let t=[];for(let i of Iu(e))if(typeof i=="string"){if(i=i.trim(),i==="")continue;let o=document.createElement("span");o.textContent=i,t.push(o)}else t.push(i);return t}updateBackground(e){let t;this.options.secondary?t=e?this.options.buttonSecondaryHoverBackground:this.options.buttonSecondaryBackground:t=e?this.options.buttonHoverBackground:this.options.buttonBackground,t&&(this._element.style.backgroundColor=t)}get element(){return this._element}set label(e){if(this._label===e||Kc(this._label)&&Kc(e)&&I2e(this._label,e))return;this._element.classList.add("monaco-text-button");let t=this.options.supportShortLabel?this._labelElement:this._element;if(Kc(e)){let o=ow(e,{inline:!0});o.dispose();let r=o.element.querySelector("p")?.innerHTML;if(r){let s=SB(r,{ADD_TAGS:["b","i","u","code","span"],ALLOWED_ATTR:["class"],RETURN_TRUSTED_TYPE:!0});t.innerHTML=s}else oo(t)}else this.options.supportIcons?oo(t,...this.getContentElements(e)):t.textContent=e;let i="";typeof this.options.title=="string"?i=this.options.title:this.options.title&&(i=P2e(e)),this.setTitle(i),typeof this.options.ariaLabel=="string"?this._element.setAttribute("aria-label",this.options.ariaLabel):this.options.ariaLabel&&this._element.setAttribute("aria-label",i),this._label=e}get label(){return this._label}set icon(e){this._element.classList.add(...Oe.asClassNameArray(e))}set enabled(e){e?(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")}setTitle(e){!this._hover&&e!==""?this._hover=this._register(Os().setupManagedHover(this.options.hoverDelegate??lo("mouse"),this._element,e)):this._hover&&this._hover.update(e)}}});var mFe=k(()=>{});var HC,Tce=k(()=>{ke();Qe();mFe();HC=class{constructor(e,t,i){this.options=t,this.styles=i,this.count=0,this.element=Q(e,J(".monaco-count-badge")),this.countFormat=this.options.countFormat||"{0}",this.titleFormat=this.options.titleFormat||"",this.setCount(this.options.count||0)}setCount(e){this.count=e,this.render()}setTitleFormat(e){this.titleFormat=e,this.render()}render(){this.element.textContent=dh(this.countFormat,this.count),this.element.title=dh(this.titleFormat,this.count),this.element.style.backgroundColor=this.styles.badgeBackground??"",this.element.style.color=this.styles.badgeForeground??"",this.styles.badgeBorder&&(this.element.style.border=`1px solid ${this.styles.badgeBorder}`)}}});var gFe=k(()=>{});var _Fe,bFe,Dce,Nce,vFe,VH,xFe=k(()=>{ke();ft();j();gFe();_Fe="done",bFe="active",Dce="infinite",Nce="infinite-long-running",vFe="discrete",VH=class n extends D{static{this.LONG_RUNNING_INFINITE_THRESHOLD=1e4}constructor(e,t){super(),this.progressSignal=this._register(new Hi),this.workedVal=0,this.showDelayedScheduler=this._register(new Lt(()=>Is(this.element),0)),this.longRunningScheduler=this._register(new Lt(()=>this.infiniteLongRunning(),n.LONG_RUNNING_INFINITE_THRESHOLD)),this.create(e,t)}create(e,t){this.element=document.createElement("div"),this.element.classList.add("monaco-progress-container"),this.element.setAttribute("role","progressbar"),this.element.setAttribute("aria-valuemin","0"),e.appendChild(this.element),this.bit=document.createElement("div"),this.bit.classList.add("progress-bit"),this.bit.style.backgroundColor=t?.progressBarBackground||"#0E70C0",this.element.appendChild(this.bit)}off(){this.bit.style.width="inherit",this.bit.style.opacity="1",this.element.classList.remove(bFe,Dce,Nce,vFe),this.workedVal=0,this.totalWork=void 0,this.longRunningScheduler.cancel(),this.progressSignal.clear()}stop(){return this.doDone(!1)}doDone(e){return this.element.classList.add(_Fe),this.element.classList.contains(Dce)?(this.bit.style.opacity="0",e?setTimeout(()=>this.off(),200):this.off()):(this.bit.style.width="inherit",e?setTimeout(()=>this.off(),200):this.off()),this}infinite(){return this.bit.style.width="2%",this.bit.style.opacity="1",this.element.classList.remove(vFe,_Fe,Nce),this.element.classList.add(bFe,Dce),this.longRunningScheduler.schedule(),this}infiniteLongRunning(){this.element.classList.add(Nce)}getContainer(){return this.element}}});var Xct,Qct,Jct,YI,ZI,XI,Rce=k(()=>{Ps();GI();Qi();pe();Xct=m("caseDescription","Match Case"),Qct=m("wordsDescription","Match Whole Word"),Jct=m("regexDescription","Use Regular Expression"),YI=class extends Bh{constructor(e){super({icon:oe.caseSensitive,title:Xct+e.appendTitle,isChecked:e.isChecked,hoverDelegate:e.hoverDelegate??lo("element"),inputActiveOptionBorder:e.inputActiveOptionBorder,inputActiveOptionForeground:e.inputActiveOptionForeground,inputActiveOptionBackground:e.inputActiveOptionBackground})}},ZI=class extends Bh{constructor(e){super({icon:oe.wholeWord,title:Qct+e.appendTitle,isChecked:e.isChecked,hoverDelegate:e.hoverDelegate??lo("element"),inputActiveOptionBorder:e.inputActiveOptionBorder,inputActiveOptionForeground:e.inputActiveOptionForeground,inputActiveOptionBackground:e.inputActiveOptionBackground})}},XI=class extends Bh{constructor(e){super({icon:oe.regex,title:Jct+e.appendTitle,isChecked:e.isChecked,hoverDelegate:e.hoverDelegate??lo("element"),inputActiveOptionBorder:e.inputActiveOptionBorder,inputActiveOptionForeground:e.inputActiveOptionForeground,inputActiveOptionBackground:e.inputActiveOptionBackground})}}});var UH,wFe=k(()=>{UH=class{constructor(e,t=0,i=e.length,o=t-1){this.items=e,this.start=t,this.end=i,this.index=o}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()}}});var $H,yFe=k(()=>{wFe();$H=class{constructor(e=[],t=10){this._initialize(e),this._limit=t,this._onChange()}getHistory(){return this._elements}add(e){this._history.delete(e),this._history.add(e),this._onChange()}next(){return this._navigator.next()}previous(){return this._currentPosition()!==0?this._navigator.previous():null}current(){return this._navigator.current()}first(){return this._navigator.first()}last(){return this._navigator.last()}isLast(){return this._currentPosition()>=this._elements.length-1}isNowhere(){return this._navigator.current()===null}has(e){return this._history.has(e)}_onChange(){this._reduceToLimit();let e=this._elements;this._navigator=new UH(e,0,e.length,e.length)}_reduceToLimit(){let e=this._elements;e.length>this._limit&&this._initialize(e.slice(e.length-this._limit))}_currentPosition(){let e=this._navigator.current();return e?this._elements.indexOf(e):-1}_initialize(e){this._history=new Set;for(let t of e)this._history.add(t)}get _elements(){let e=[];return this._history.forEach(t=>e.push(t)),e}}});var CFe=k(()=>{});var x2,Ace,QI,jH=k(()=>{ke();Sf();Ase();Oh();Ns();Ah();Ps();Eh();Lh();Ie();yFe();ec();CFe();pe();x2=J,Ace=class extends Yo{constructor(e,t,i){super(),this.state="idle",this.maxHeight=Number.POSITIVE_INFINITY,this._onDidChange=this._register(new A),this.onDidChange=this._onDidChange.event,this._onDidHeightChange=this._register(new A),this.onDidHeightChange=this._onDidHeightChange.event,this.contextViewProvider=t,this.options=i,this.message=null,this.placeholder=this.options.placeholder||"",this.tooltip=this.options.tooltip??(this.placeholder||""),this.ariaLabel=this.options.ariaLabel||"",this.options.validationOptions&&(this.validation=this.options.validationOptions.validation),this.element=Q(e,x2(".monaco-inputbox.idle"));let o=this.options.flexibleHeight?"textarea":"input",r=Q(this.element,x2(".ibwrapper"));if(this.input=Q(r,x2(o+".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=Q(r,x2("div.mirror")),this.mirror.innerText="\xA0",this.scrollableElement=new YL(this.element,{vertical:1}),this.options.flexibleWidth&&(this.input.setAttribute("wrap","off"),this.mirror.style.whiteSpace="pre",this.mirror.style.wordWrap="initial"),Q(e,this.scrollableElement.getDomNode()),this._register(this.scrollableElement),this._register(this.scrollableElement.onScroll(l=>this.input.scrollTop=l.scrollTop));let s=this._register(new Mt(e.ownerDocument,"selectionchange")),a=ne.filter(s.event,()=>e.ownerDocument.getSelection()?.anchorNode===r);this._register(a(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._register(this.ignoreGesture(this.input)),setTimeout(()=>this.updateMirror(),0),this.options.actions&&(this.actionbar=this._register(new Zo(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(e){this.placeholder=e,this.input.setAttribute("placeholder",e)}setTooltip(e){this.tooltip=e,this.hover?this.hover.update(e):this.hover=this._register(Os().setupManagedHover(lo("mouse"),this.input,e))}get inputElement(){return this.input}get value(){return this.input.value}set value(e){this.input.value!==e&&(this.input.value=e,this.onValueChange())}get height(){return typeof this.cachedHeight=="number"?this.cachedHeight:gh(this.element)}focus(){this.input.focus()}blur(){this.input.blur()}hasFocus(){return D1(this.input)}select(e=null){this.input.select(),e&&(this.input.setSelectionRange(e.start,e.end),e.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}getSelection(){let e=this.input.selectionStart;if(e===null)return null;let t=this.input.selectionEnd??e;return{start:e,end:t}}enable(){this.input.removeAttribute("disabled")}disable(){this.blur(),this.input.disabled=!0,this._hideMessage()}set paddingRight(e){this.input.style.width=`calc(100% - ${e}px)`,this.mirror&&(this.mirror.style.paddingRight=e+"px")}updateScrollDimensions(){if(typeof this.cachedContentHeight!="number"||typeof this.cachedHeight!="number"||!this.scrollableElement)return;let e=this.cachedContentHeight,t=this.cachedHeight,i=this.input.scrollTop;this.scrollableElement.setScrollDimensions({scrollHeight:e,height:t}),this.scrollableElement.setScrollPosition({scrollTop:i})}showMessage(e,t){if(this.state==="open"&&os(this.message,e))return;this.message=e,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(e.type));let i=this.stylesForType(this.message.type);this.element.style.border=`1px solid ${_h(i.border,"transparent")}`,this.message.content&&(this.hasFocus()||t)&&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 e=null;return this.validation&&(e=this.validation(this.value),e?(this.inputElement.setAttribute("aria-invalid","true"),this.showMessage(e)):this.inputElement.hasAttribute("aria-invalid")&&(this.inputElement.removeAttribute("aria-invalid"),this.hideMessage())),e?.type}stylesForType(e){let t=this.options.inputBoxStyles;switch(e){case 1:return{border:t.inputValidationInfoBorder,background:t.inputValidationInfoBackground,foreground:t.inputValidationInfoForeground};case 2:return{border:t.inputValidationWarningBorder,background:t.inputValidationWarningBackground,foreground:t.inputValidationWarningForeground};default:return{border:t.inputValidationErrorBorder,background:t.inputValidationErrorBackground,foreground:t.inputValidationErrorForeground}}}classForType(e){switch(e){case 1:return"info";case 2:return"warning";default:return"error"}}_showMessage(){if(!this.contextViewProvider||!this.message)return;let e,t=()=>e.style.width=Gs(this.element)+"px";this.contextViewProvider.showContextView({getAnchor:()=>this.element,anchorAlignment:1,render:o=>{if(!this.message)return null;e=Q(o,x2(".monaco-inputbox-container")),t();let r={inline:!0,className:"monaco-inputbox-message"},s=this.message.formatContent?ZMe(this.message.content,r):YMe(this.message.content,r);s.classList.add(this.classForType(this.message.type));let a=this.stylesForType(this.message.type);return s.style.backgroundColor=a.background??"",s.style.color=a.foreground??"",s.style.border=a.border?`1px solid ${a.border}`:"",Q(e,s),null},onHide:()=>{this.state="closed"},layout:t});let i;this.message.type===3?i=m("alertErrorMessage","Error: {0}",this.message.content):this.message.type===2?i=m("alertWarningMessage","Warning: {0}",this.message.content):i=m("alertInfoMessage","Info: {0}",this.message.content),Bo(i),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;let e=this.value,i=e.charCodeAt(e.length-1)===10?" ":"";(e+i).replace(/\u000c/g,"")?this.mirror.textContent=e+i:this.mirror.innerText="\xA0",this.layout()}applyStyles(){let e=this.options.inputBoxStyles,t=e.inputBackground??"",i=e.inputForeground??"",o=e.inputBorder??"";this.element.style.backgroundColor=t,this.element.style.color=i,this.input.style.backgroundColor="inherit",this.input.style.color=i,this.element.style.border=`1px solid ${_h(o,"transparent")}`}layout(){if(!this.mirror)return;let e=this.cachedContentHeight;this.cachedContentHeight=gh(this.mirror),e!==this.cachedContentHeight&&(this.cachedHeight=Math.min(this.cachedContentHeight,this.maxHeight),this.input.style.height=this.cachedHeight+"px",this._onDidHeightChange.fire(this.cachedContentHeight))}insertAtCursor(e){let t=this.inputElement,i=t.selectionStart,o=t.selectionEnd,r=t.value;i!==null&&o!==null&&(this.value=r.substr(0,i)+e+r.substr(o),t.setSelectionRange(i+1,i+1),this.layout())}dispose(){this._hideMessage(),this.message=null,this.actionbar?.dispose(),super.dispose()}},QI=class extends Ace{constructor(e,t,i){let o=m({key:"history.inputbox.hint.suffix.noparens",comment:['Text is the suffix of an input field placeholder coming after the action the input field performs, this will be used when the input field ends in a closing parenthesis ")", for example "Filter (e.g. text, !exclude)". The character inserted into the final string is \u21C5 to represent the up and down arrow keys.']}," or {0} for history","\u21C5"),r=m({key:"history.inputbox.hint.suffix.inparens",comment:['Text is the suffix of an input field placeholder coming after the action the input field performs, this will be used when the input field does NOT end in a closing parenthesis (eg. "Find"). The character inserted into the final string is \u21C5 to represent the up and down arrow keys.']}," ({0} for history)","\u21C5");super(e,t,i),this._onDidFocus=this._register(new A),this.onDidFocus=this._onDidFocus.event,this._onDidBlur=this._register(new A),this.onDidBlur=this._onDidBlur.event,this.history=new $H(i.history,100);let s=()=>{if(i.showHistoryHint&&i.showHistoryHint()&&!this.placeholder.endsWith(o)&&!this.placeholder.endsWith(r)&&this.history.getHistory().length){let a=this.placeholder.endsWith(")")?o:r,l=this.placeholder+a;i.showPlaceholderOnFocus&&!D1(this.input)?this.placeholder=l:this.setPlaceHolder(l)}};this.observer=new MutationObserver((a,l)=>{a.forEach(c=>{c.target.textContent||s()})}),this.observer.observe(this.input,{attributeFilter:["class"]}),this.onfocus(this.input,()=>s()),this.onblur(this.input,()=>{let a=l=>{if(this.placeholder.endsWith(l)){let c=this.placeholder.slice(0,this.placeholder.length-l.length);return i.showPlaceholderOnFocus?this.placeholder=c:this.setPlaceHolder(c),!0}else return!1};a(r)||a(o)})}dispose(){super.dispose(),this.observer&&(this.observer.disconnect(),this.observer=void 0)}addToHistory(e){this.value&&(e||this.value!==this.getCurrentValue())&&this.history.add(this.value)}isAtLastInHistory(){return this.history.isLast()}isNowhereInHistory(){return this.history.isNowhere()}showNextValue(){this.history.has(this.value)||this.addToHistory();let e=this.getNextValue();e&&(e=e===this.value?this.getNextValue():e),this.value=e??"",Ol(this.value?this.value:m("clearedInput","Cleared Input"))}showPreviousValue(){this.history.has(this.value)||this.addToHistory();let e=this.getPreviousValue();e&&(e=e===this.value?this.getPreviousValue():e),e&&(this.value=e,Ol(this.value))}setPlaceHolder(e){super.setPlaceHolder(e),this.setTooltip(e)}onBlur(){super.onBlur(),this._onDidBlur.fire()}onFocus(){super.onFocus(),this._onDidFocus.fire()}getCurrentValue(){let e=this.history.current();return e||(e=this.history.last(),this.history.next()),e}getPreviousValue(){return this.history.previous()||this.history.first()}getNextValue(){return this.history.next()}}});var Mce=k(()=>{});var edt,zC,qH=k(()=>{ke();Rce();jH();Lh();Ie();Mce();pe();j();Ps();edt=m("defaultLabel","input"),zC=class extends Yo{constructor(e,t,i){super(),this.fixFocusOnOptionClickEnabled=!0,this.imeSessionInProgress=!1,this.additionalTogglesDisposables=this._register(new Hi),this.additionalToggles=[],this._onDidOptionChange=this._register(new A),this.onDidOptionChange=this._onDidOptionChange.event,this._onKeyDown=this._register(new A),this.onKeyDown=this._onKeyDown.event,this._onMouseDown=this._register(new A),this.onMouseDown=this._onMouseDown.event,this._onInput=this._register(new A),this._onKeyUp=this._register(new A),this._onCaseSensitiveKeyDown=this._register(new A),this.onCaseSensitiveKeyDown=this._onCaseSensitiveKeyDown.event,this._onRegexKeyDown=this._register(new A),this.onRegexKeyDown=this._onRegexKeyDown.event,this._lastHighlightFindOptions=0,this.placeholder=i.placeholder||"",this.validation=i.validation,this.label=i.label||edt,this.showCommonFindToggles=!!i.showCommonFindToggles;let o=i.appendCaseSensitiveLabel||"",r=i.appendWholeWordsLabel||"",s=i.appendRegexLabel||"",a=i.history||[],l=!!i.flexibleHeight,c=!!i.flexibleWidth,d=i.flexibleMaxHeight;this.domNode=document.createElement("div"),this.domNode.classList.add("monaco-findInput"),this.inputBox=this._register(new QI(this.domNode,t,{placeholder:this.placeholder||"",ariaLabel:this.label||"",validationOptions:{validation:this.validation},history:a,showHistoryHint:i.showHistoryHint,flexibleHeight:l,flexibleWidth:c,flexibleMaxHeight:d,inputBoxStyles:i.inputBoxStyles}));let u=this._register(Ef());if(this.showCommonFindToggles){this.regex=this._register(new XI({appendTitle:s,isChecked:!1,hoverDelegate:u,...i.toggleStyles})),this._register(this.regex.onChange(f=>{this._onDidOptionChange.fire(f),!f&&this.fixFocusOnOptionClickEnabled&&this.inputBox.focus(),this.validate()})),this._register(this.regex.onKeyDown(f=>{this._onRegexKeyDown.fire(f)})),this.wholeWords=this._register(new ZI({appendTitle:r,isChecked:!1,hoverDelegate:u,...i.toggleStyles})),this._register(this.wholeWords.onChange(f=>{this._onDidOptionChange.fire(f),!f&&this.fixFocusOnOptionClickEnabled&&this.inputBox.focus(),this.validate()})),this.caseSensitive=this._register(new YI({appendTitle:o,isChecked:!1,hoverDelegate:u,...i.toggleStyles})),this._register(this.caseSensitive.onChange(f=>{this._onDidOptionChange.fire(f),!f&&this.fixFocusOnOptionClickEnabled&&this.inputBox.focus(),this.validate()})),this._register(this.caseSensitive.onKeyDown(f=>{this._onCaseSensitiveKeyDown.fire(f)}));let h=[this.caseSensitive.domNode,this.wholeWords.domNode,this.regex.domNode];this.onkeydown(this.domNode,f=>{if(f.equals(15)||f.equals(17)||f.equals(9)){let p=h.indexOf(this.domNode.ownerDocument.activeElement);if(p>=0){let g=-1;f.equals(17)?g=(p+1)%h.length:f.equals(15)&&(p===0?g=h.length-1:g=p-1),f.equals(9)?(h[p].blur(),this.inputBox.focus()):g>=0&&h[g].focus(),Rt.stop(f,!0)}}})}this.controls=document.createElement("div"),this.controls.className="controls",this.controls.style.display=this.showCommonFindToggles?"":"none",this.caseSensitive&&this.controls.append(this.caseSensitive.domNode),this.wholeWords&&this.controls.appendChild(this.wholeWords.domNode),this.regex&&this.controls.appendChild(this.regex.domNode),this.setAdditionalToggles(i?.additionalToggles),this.controls&&this.domNode.appendChild(this.controls),e?.appendChild(this.domNode),this._register(U(this.inputBox.inputElement,"compositionstart",h=>{this.imeSessionInProgress=!0})),this._register(U(this.inputBox.inputElement,"compositionend",h=>{this.imeSessionInProgress=!1,this._onInput.fire()})),this.onkeydown(this.inputBox.inputElement,h=>this._onKeyDown.fire(h)),this.onkeyup(this.inputBox.inputElement,h=>this._onKeyUp.fire(h)),this.oninput(this.inputBox.inputElement,h=>this._onInput.fire()),this.onmousedown(this.inputBox.inputElement,h=>this._onMouseDown.fire(h))}get onDidChange(){return this.inputBox.onDidChange}layout(e){this.inputBox.layout(),this.updateInputBoxPadding(e.collapsedFindWidget)}enable(){this.domNode.classList.remove("disabled"),this.inputBox.enable(),this.regex?.enable(),this.wholeWords?.enable(),this.caseSensitive?.enable();for(let e of this.additionalToggles)e.enable()}disable(){this.domNode.classList.add("disabled"),this.inputBox.disable(),this.regex?.disable(),this.wholeWords?.disable(),this.caseSensitive?.disable();for(let e of this.additionalToggles)e.disable()}setFocusInputOnOptionClick(e){this.fixFocusOnOptionClickEnabled=e}setEnabled(e){e?this.enable():this.disable()}setAdditionalToggles(e){for(let t of this.additionalToggles)t.domNode.remove();this.additionalToggles=[],this.additionalTogglesDisposables.value=new H;for(let t of e??[])this.additionalTogglesDisposables.value.add(t),this.controls.appendChild(t.domNode),this.additionalTogglesDisposables.value.add(t.onChange(i=>{this._onDidOptionChange.fire(i),!i&&this.fixFocusOnOptionClickEnabled&&this.inputBox.focus()})),this.additionalToggles.push(t);this.additionalToggles.length>0&&(this.controls.style.display=""),this.updateInputBoxPadding()}updateInputBoxPadding(e=!1){e?this.inputBox.paddingRight=0:this.inputBox.paddingRight=(this.caseSensitive?.width()??0)+(this.wholeWords?.width()??0)+(this.regex?.width()??0)+this.additionalToggles.reduce((t,i)=>t+i.width(),0)}getValue(){return this.inputBox.value}setValue(e){this.inputBox.value!==e&&(this.inputBox.value=e)}select(){this.inputBox.select()}focus(){this.inputBox.focus()}getCaseSensitive(){return this.caseSensitive?.checked??!1}setCaseSensitive(e){this.caseSensitive&&(this.caseSensitive.checked=e)}getWholeWords(){return this.wholeWords?.checked??!1}setWholeWords(e){this.wholeWords&&(this.wholeWords.checked=e)}getRegex(){return this.regex?.checked??!1}setRegex(e){this.regex&&(this.regex.checked=e,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(e){this.inputBox.showMessage(e)}clearMessage(){this.inputBox.hideMessage()}}});var tdt,KH,SFe=k(()=>{ke();qH();j();ob();MH();tdt=J,KH=class extends D{constructor(e,t,i){super(),this.parent=e,this.onKeyDown=r=>gi(this.findInput.inputBox.inputElement,re.KEY_DOWN,r),this.onDidChange=r=>this.findInput.onDidChange(r),this.container=Q(this.parent,tdt(".quick-input-box")),this.findInput=this._register(new zC(this.container,void 0,{label:"",inputBoxStyles:t,toggleStyles:i}));let o=this.findInput.inputBox.inputElement;o.role="combobox",o.ariaHasPopup="menu",o.ariaAutoComplete="list",o.ariaExpanded="true"}get value(){return this.findInput.getValue()}set value(e){this.findInput.setValue(e)}select(e=null){this.findInput.inputBox.select(e)}getSelection(){return this.findInput.inputBox.getSelection()}isSelectionAtEnd(){return this.findInput.inputBox.isSelectionAtEnd()}get placeholder(){return this.findInput.inputBox.inputElement.getAttribute("placeholder")||""}set placeholder(e){this.findInput.inputBox.setPlaceHolder(e)}get password(){return this.findInput.inputBox.inputElement.type==="password"}set password(e){this.findInput.inputBox.inputElement.type=e?"password":"text"}set enabled(e){this.findInput.inputBox.inputElement.toggleAttribute("readonly",!e)}set toggles(e){this.findInput.setAdditionalToggles(e)}setAttribute(e,t){this.findInput.inputBox.inputElement.setAttribute(e,t)}showDecoration(e){e===Mn.Ignore?this.findInput.clearMessage():this.findInput.showMessage({type:e===Mn.Info?1:e===Mn.Warning?2:3,content:""})}stylesForType(e){return this.findInput.inputBox.stylesForType(e===Mn.Info?1:e===Mn.Warning?2:3)}setFocus(){this.findInput.focus()}layout(){this.findInput.inputBox.layout()}}});function idt(n,e){return{...e,accessibilityProvider:e.accessibilityProvider&&new Oce(n,e.accessibilityProvider)}}var Pce,Oce,GH,kFe=k(()=>{at();ci();Ie();j();Wae();xb();Pce=class{get templateId(){return this.renderer.templateId}constructor(e,t){this.renderer=e,this.modelProvider=t}renderTemplate(e){return{data:this.renderer.renderTemplate(e),disposable:D.None}}renderElement(e,t,i,o){if(i.disposable?.dispose(),!i.data)return;let r=this.modelProvider();if(r.isResolved(e))return this.renderer.renderElement(r.get(e),e,i.data,o);let s=new qt,a=r.resolve(e,s.token);i.disposable={dispose:()=>s.cancel()},this.renderer.renderPlaceholder(e,i.data),a.then(l=>this.renderer.renderElement(l,e,i.data,o))}disposeTemplate(e){e.disposable&&(e.disposable.dispose(),e.disposable=void 0),e.data&&(this.renderer.disposeTemplate(e.data),e.data=void 0)}},Oce=class{constructor(e,t){this.modelProvider=e,this.accessibilityProvider=t}getWidgetAriaLabel(){return this.accessibilityProvider.getWidgetAriaLabel()}getAriaLabel(e){let t=this.modelProvider();return t.isResolved(e)?this.accessibilityProvider.getAriaLabel(t.get(e)):null}};GH=class{constructor(e,t,i,o,r={}){let s=()=>this.model,a=o.map(l=>new Pce(l,s));this.list=new Xr(e,t,i,a,idt(s,r))}updateOptions(e){this.list.updateOptions(e)}getHTMLElement(){return this.list.getHTMLElement()}get onDidFocus(){return this.list.onDidFocus}get widget(){return this.list}get onDidDispose(){return this.list.onDidDispose}get onMouseDblClick(){return ne.map(this.list.onMouseDblClick,({element:e,index:t,browserEvent:i})=>({element:e===void 0?void 0:this._model.get(e),index:t,browserEvent:i}))}get onPointer(){return ne.map(this.list.onPointer,({element:e,index:t,browserEvent:i})=>({element:e===void 0?void 0:this._model.get(e),index:t,browserEvent:i}))}get onDidChangeSelection(){return ne.map(this.list.onDidChangeSelection,({elements:e,indexes:t,browserEvent:i})=>({elements:e.map(o=>this._model.get(o)),indexes:t,browserEvent:i}))}get model(){return this._model}set model(e){this._model=e,this.list.splice(0,this.list.length,ma(e.length))}getFocus(){return this.list.getFocus()}getSelection(){return this.list.getSelection()}getSelectedElements(){return this.getSelection().map(e=>this.model.get(e))}style(e){this.list.style(e)}dispose(){this.list.dispose()}}});var LFe=k(()=>{});var eE,ndt,w2,odt,rdt,sdt,adt,y2,C2,JI,IFe,ed,tE=k(()=>{ke();Sf();Pd();ft();Yx();Ie();j();Bt();LFe();eE=function(n,e,t,i){var o=arguments.length,r=o<3?e:i===null?i=Object.getOwnPropertyDescriptor(e,t):i,s;if(typeof Reflect=="object"&&typeof Reflect.decorate=="function")r=Reflect.decorate(n,e,t,i);else for(var a=n.length-1;a>=0;a--)(s=n[a])&&(r=(o<3?s(r):o>3?s(e,t,r):s(e,t))||r);return o>3&&r&&Object.defineProperty(e,t,r),r},ndt=!1;(function(n){n.North="north",n.South="south",n.East="east",n.West="west"})(w2||(w2={}));odt=4,rdt=new A,sdt=300,adt=new A,y2=class{constructor(e){this.el=e,this.disposables=new H}get onPointerMove(){return this.disposables.add(new Mt(Me(this.el),"mousemove")).event}get onPointerUp(){return this.disposables.add(new Mt(Me(this.el),"mouseup")).event}dispose(){this.disposables.dispose()}};eE([Hn],y2.prototype,"onPointerMove",null);eE([Hn],y2.prototype,"onPointerUp",null);C2=class{get onPointerMove(){return this.disposables.add(new Mt(this.el,Mi.Change)).event}get onPointerUp(){return this.disposables.add(new Mt(this.el,Mi.End)).event}constructor(e){this.el=e,this.disposables=new H}dispose(){this.disposables.dispose()}};eE([Hn],C2.prototype,"onPointerMove",null);eE([Hn],C2.prototype,"onPointerUp",null);JI=class{get onPointerMove(){return this.factory.onPointerMove}get onPointerUp(){return this.factory.onPointerUp}constructor(e){this.factory=e}dispose(){}};eE([Hn],JI.prototype,"onPointerMove",null);eE([Hn],JI.prototype,"onPointerUp",null);IFe="pointer-events-disabled",ed=class n extends D{get state(){return this._state}get orthogonalStartSash(){return this._orthogonalStartSash}get orthogonalEndSash(){return this._orthogonalEndSash}set state(e){this._state!==e&&(this.el.classList.toggle("disabled",e===0),this.el.classList.toggle("minimum",e===1),this.el.classList.toggle("maximum",e===2),this._state=e,this.onDidEnablementChange.fire(e))}set orthogonalStartSash(e){if(this._orthogonalStartSash!==e){if(this.orthogonalStartDragHandleDisposables.clear(),this.orthogonalStartSashDisposables.clear(),e){let t=i=>{this.orthogonalStartDragHandleDisposables.clear(),i!==0&&(this._orthogonalStartDragHandle=Q(this.el,J(".orthogonal-drag-handle.start")),this.orthogonalStartDragHandleDisposables.add(ge(()=>this._orthogonalStartDragHandle.remove())),this.orthogonalStartDragHandleDisposables.add(new Mt(this._orthogonalStartDragHandle,"mouseenter")).event(()=>n.onMouseEnter(e),void 0,this.orthogonalStartDragHandleDisposables),this.orthogonalStartDragHandleDisposables.add(new Mt(this._orthogonalStartDragHandle,"mouseleave")).event(()=>n.onMouseLeave(e),void 0,this.orthogonalStartDragHandleDisposables))};this.orthogonalStartSashDisposables.add(e.onDidEnablementChange.event(t,this)),t(e.state)}this._orthogonalStartSash=e}}set orthogonalEndSash(e){if(this._orthogonalEndSash!==e){if(this.orthogonalEndDragHandleDisposables.clear(),this.orthogonalEndSashDisposables.clear(),e){let t=i=>{this.orthogonalEndDragHandleDisposables.clear(),i!==0&&(this._orthogonalEndDragHandle=Q(this.el,J(".orthogonal-drag-handle.end")),this.orthogonalEndDragHandleDisposables.add(ge(()=>this._orthogonalEndDragHandle.remove())),this.orthogonalEndDragHandleDisposables.add(new Mt(this._orthogonalEndDragHandle,"mouseenter")).event(()=>n.onMouseEnter(e),void 0,this.orthogonalEndDragHandleDisposables),this.orthogonalEndDragHandleDisposables.add(new Mt(this._orthogonalEndDragHandle,"mouseleave")).event(()=>n.onMouseLeave(e),void 0,this.orthogonalEndDragHandleDisposables))};this.orthogonalEndSashDisposables.add(e.onDidEnablementChange.event(t,this)),t(e.state)}this._orthogonalEndSash=e}}constructor(e,t,i){super(),this.hoverDelay=sdt,this.hoverDelayer=this._register(new gr(this.hoverDelay)),this._state=3,this.onDidEnablementChange=this._register(new A),this._onDidStart=this._register(new A),this._onDidChange=this._register(new A),this._onDidReset=this._register(new A),this._onDidEnd=this._register(new A),this.orthogonalStartSashDisposables=this._register(new H),this.orthogonalStartDragHandleDisposables=this._register(new H),this.orthogonalEndSashDisposables=this._register(new H),this.orthogonalEndDragHandleDisposables=this._register(new H),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=Q(e,J(".monaco-sash")),i.orthogonalEdge&&this.el.classList.add(`orthogonal-edge-${i.orthogonalEdge}`),dt&&this.el.classList.add("mac");let o=this._register(new Mt(this.el,"mousedown")).event;this._register(o(u=>this.onPointerStart(u,new y2(e)),this));let r=this._register(new Mt(this.el,"dblclick")).event;this._register(r(this.onPointerDoublePress,this));let s=this._register(new Mt(this.el,"mouseenter")).event;this._register(s(()=>n.onMouseEnter(this)));let a=this._register(new Mt(this.el,"mouseleave")).event;this._register(a(()=>n.onMouseLeave(this))),this._register(so.addTarget(this.el));let l=this._register(new Mt(this.el,Mi.Start)).event;this._register(l(u=>this.onPointerStart(u,new C2(this.el)),this));let c=this._register(new Mt(this.el,Mi.Tap)).event,d;this._register(c(u=>{if(d){clearTimeout(d),d=void 0,this.onPointerDoublePress(u);return}clearTimeout(d),d=setTimeout(()=>d=void 0,250)},this)),typeof i.size=="number"?(this.size=i.size,i.orientation===0?this.el.style.width=`${this.size}px`:this.el.style.height=`${this.size}px`):(this.size=odt,this._register(rdt.event(u=>{this.size=u,this.layout()}))),this._register(adt.event(u=>this.hoverDelay=u)),this.layoutProvider=t,this.orthogonalStartSash=i.orthogonalStartSash,this.orthogonalEndSash=i.orthogonalEndSash,this.orientation=i.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",ndt),this.layout()}onPointerStart(e,t){Rt.stop(e);let i=!1;if(!e.__orthogonalSashEvent){let p=this.getOrthogonalSash(e);p&&(i=!0,e.__orthogonalSashEvent=!0,p.onPointerStart(e,new JI(t)))}if(this.linkedSash&&!e.__linkedSashEvent&&(e.__linkedSashEvent=!0,this.linkedSash.onPointerStart(e,new JI(t))),!this.state)return;let o=this.el.ownerDocument.getElementsByTagName("iframe");for(let p of o)p.classList.add(IFe);let r=e.pageX,s=e.pageY,a=e.altKey,l={startX:r,currentX:r,startY:s,currentY:s,altKey:a};this.el.classList.add("active"),this._onDidStart.fire(l);let c=qr(this.el),d=()=>{let p="";i?p="all-scroll":this.orientation===1?this.state===1?p="s-resize":this.state===2?p="n-resize":p=dt?"row-resize":"ns-resize":this.state===1?p="e-resize":this.state===2?p="w-resize":p=dt?"col-resize":"ew-resize",c.textContent=`* { cursor: ${p} !important; }`},u=new H;d(),i||this.onDidEnablementChange.event(d,null,u);let h=p=>{Rt.stop(p,!1);let g={startX:r,currentX:p.pageX,startY:s,currentY:p.pageY,altKey:a};this._onDidChange.fire(g)},f=p=>{Rt.stop(p,!1),c.remove(),this.el.classList.remove("active"),this._onDidEnd.fire(),u.dispose();for(let g of o)g.classList.remove(IFe)};t.onPointerMove(h,null,u),t.onPointerUp(f,null,u),u.add(t)}onPointerDoublePress(e){let t=this.getOrthogonalSash(e);t&&t._onDidReset.fire(),this.linkedSash&&this.linkedSash._onDidReset.fire(),this._onDidReset.fire()}static onMouseEnter(e,t=!1){e.el.classList.contains("active")?(e.hoverDelayer.cancel(),e.el.classList.add("hover")):e.hoverDelayer.trigger(()=>e.el.classList.add("hover"),e.hoverDelay).then(void 0,()=>{}),!t&&e.linkedSash&&n.onMouseEnter(e.linkedSash,!0)}static onMouseLeave(e,t=!1){e.hoverDelayer.cancel(),e.el.classList.remove("hover"),!t&&e.linkedSash&&n.onMouseLeave(e.linkedSash,!0)}clearSashHoverState(){n.onMouseLeave(this)}layout(){if(this.orientation===0){let e=this.layoutProvider;this.el.style.left=e.getVerticalSashLeft(this)-this.size/2+"px",e.getVerticalSashTop&&(this.el.style.top=e.getVerticalSashTop(this)+"px"),e.getVerticalSashHeight&&(this.el.style.height=e.getVerticalSashHeight(this)+"px")}else{let e=this.layoutProvider;this.el.style.top=e.getHorizontalSashTop(this)-this.size/2+"px",e.getHorizontalSashLeft&&(this.el.style.left=e.getHorizontalSashLeft(this)+"px"),e.getHorizontalSashWidth&&(this.el.style.width=e.getHorizontalSashWidth(this)+"px")}}getOrthogonalSash(e){let t=e.initialTarget??e.target;if(!(!t||!_n(t))&&t.classList.contains("orthogonal-drag-handle"))return t.classList.contains("start")?this.orthogonalStartSash:this.orthogonalEndSash}dispose(){super.dispose(),this.el.remove()}}});var EFe=k(()=>{});var ldt,YH,Fce,Bce,Db,S2,iE,Wce=k(()=>{ke();Sf();tE();Eh();at();vo();Ie();j();eC();GL();yi();EFe();ldt={separatorBorder:Z.transparent},YH=class{set size(e){this._size=e}get size(){return this._size}get visible(){return typeof this._cachedVisibleSize>"u"}setVisible(e,t){if(e!==this.visible){e?(this.size=ps(this._cachedVisibleSize,this.viewMinimumSize,this.viewMaximumSize),this._cachedVisibleSize=void 0):(this._cachedVisibleSize=typeof t=="number"?t:this.size,this.size=0),this.container.classList.toggle("visible",e);try{this.view.setVisible?.(e)}catch(i){console.error("Splitview: Failed to set visible view"),console.error(i)}}}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 proportionalLayout(){return this.view.proportionalLayout??!0}get snap(){return!!this.view.snap}set enabled(e){this.container.style.pointerEvents=e?"":"none"}constructor(e,t,i,o){this.container=e,this.view=t,this.disposable=o,this._cachedVisibleSize=void 0,typeof i=="number"?(this._size=i,this._cachedVisibleSize=void 0,e.classList.add("visible")):(this._size=0,this._cachedVisibleSize=i.cachedVisibleSize)}layout(e,t){this.layoutContainer(e);try{this.view.layout(this.size,e,t)}catch(i){console.error("Splitview: Failed to layout view"),console.error(i)}}dispose(){this.disposable.dispose()}},Fce=class extends YH{layoutContainer(e){this.container.style.top=`${e}px`,this.container.style.height=`${this.size}px`}},Bce=class extends YH{layoutContainer(e){this.container.style.left=`${e}px`,this.container.style.width=`${this.size}px`}};(function(n){n[n.Idle=0]="Idle",n[n.Busy=1]="Busy"})(Db||(Db={}));(function(n){n.Distribute={type:"distribute"};function e(o){return{type:"split",index:o}}n.Split=e;function t(o){return{type:"auto",index:o}}n.Auto=t;function i(o){return{type:"invisible",cachedVisibleSize:o}}n.Invisible=i})(S2||(S2={}));iE=class extends D{get orthogonalStartSash(){return this._orthogonalStartSash}get orthogonalEndSash(){return this._orthogonalEndSash}get startSnappingEnabled(){return this._startSnappingEnabled}get endSnappingEnabled(){return this._endSnappingEnabled}set orthogonalStartSash(e){for(let t of this.sashItems)t.sash.orthogonalStartSash=e;this._orthogonalStartSash=e}set orthogonalEndSash(e){for(let t of this.sashItems)t.sash.orthogonalEndSash=e;this._orthogonalEndSash=e}set startSnappingEnabled(e){this._startSnappingEnabled!==e&&(this._startSnappingEnabled=e,this.updateSashEnablement())}set endSnappingEnabled(e){this._endSnappingEnabled!==e&&(this._endSnappingEnabled=e,this.updateSashEnablement())}constructor(e,t={}){super(),this.size=0,this._contentSize=0,this.proportions=void 0,this.viewItems=[],this.sashItems=[],this.state=Db.Idle,this._onDidSashChange=this._register(new A),this._onDidSashReset=this._register(new A),this._startSnappingEnabled=!0,this._endSnappingEnabled=!0,this.onDidSashChange=this._onDidSashChange.event,this.onDidSashReset=this._onDidSashReset.event,this.orientation=t.orientation??0,this.inverseAltBehavior=t.inverseAltBehavior??!1,this.proportionalLayout=t.proportionalLayout??!0,this.getSashOrthogonalSize=t.getSashOrthogonalSize,this.el=document.createElement("div"),this.el.classList.add("monaco-split-view2"),this.el.classList.add(this.orientation===0?"vertical":"horizontal"),e.appendChild(this.el),this.sashContainer=Q(this.el,J(".sash-container")),this.viewContainer=J(".split-view-container"),this.scrollable=this._register(new Ih({forceIntegerValues:!0,smoothScrollDuration:125,scheduleAtNextAnimationFrame:o=>us(Me(this.el),o)})),this.scrollableElement=this._register(new Ym(this.viewContainer,{vertical:this.orientation===0?t.scrollbarVisibility??1:2,horizontal:this.orientation===1?t.scrollbarVisibility??1:2},this.scrollable));let i=this._register(new Mt(this.viewContainer,"scroll")).event;this._register(i(o=>{let r=this.scrollableElement.getScrollPosition(),s=Math.abs(this.viewContainer.scrollLeft-r.scrollLeft)<=1?void 0:this.viewContainer.scrollLeft,a=Math.abs(this.viewContainer.scrollTop-r.scrollTop)<=1?void 0:this.viewContainer.scrollTop;(s!==void 0||a!==void 0)&&this.scrollableElement.setScrollPosition({scrollLeft:s,scrollTop:a})})),this.onDidScroll=this.scrollableElement.onScroll,this._register(this.onDidScroll(o=>{o.scrollTopChanged&&(this.viewContainer.scrollTop=o.scrollTop),o.scrollLeftChanged&&(this.viewContainer.scrollLeft=o.scrollLeft)})),Q(this.el,this.scrollableElement.getDomNode()),this.style(t.styles||ldt),t.descriptor&&(this.size=t.descriptor.size,t.descriptor.views.forEach((o,r)=>{let s=Vr(o.visible)||o.visible?o.size:{type:"invisible",cachedVisibleSize:o.size},a=o.view;this.doAddView(a,s,r,!0)}),this._contentSize=this.viewItems.reduce((o,r)=>o+r.size,0),this.saveProportions())}style(e){e.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",e.separatorBorder.toString()))}addView(e,t,i=this.viewItems.length,o){this.doAddView(e,t,i,o)}layout(e,t){let i=Math.max(this.size,this._contentSize);if(this.size=e,this.layoutContext=t,this.proportions){let o=0;for(let r=0;r0&&(s.size=ps(Math.round(a*e/o),s.minimumSize,s.maximumSize))}}else{let o=ma(this.viewItems.length),r=o.filter(a=>this.viewItems[a].priority===1),s=o.filter(a=>this.viewItems[a].priority===2);this.resize(this.viewItems.length-1,e-i,void 0,r,s)}this.distributeEmptySpace(),this.layoutViews()}saveProportions(){this.proportionalLayout&&this._contentSize>0&&(this.proportions=this.viewItems.map(e=>e.proportionalLayout&&e.visible?e.size/this._contentSize:void 0))}onSashStart({sash:e,start:t,alt:i}){for(let a of this.viewItems)a.enabled=!1;let o=this.sashItems.findIndex(a=>a.sash===e),r=qs(U(this.el.ownerDocument.body,"keydown",a=>s(this.sashDragState.current,a.altKey)),U(this.el.ownerDocument.body,"keyup",()=>s(this.sashDragState.current,!1))),s=(a,l)=>{let c=this.viewItems.map(p=>p.size),d=Number.NEGATIVE_INFINITY,u=Number.POSITIVE_INFINITY;if(this.inverseAltBehavior&&(l=!l),l)if(o===this.sashItems.length-1){let g=this.viewItems[o];d=(g.minimumSize-g.size)/2,u=(g.maximumSize-g.size)/2}else{let g=this.viewItems[o+1];d=(g.size-g.maximumSize)/2,u=(g.size-g.minimumSize)/2}let h,f;if(!l){let p=ma(o,-1),g=ma(o+1,this.viewItems.length),_=p.reduce((E,N)=>E+(this.viewItems[N].minimumSize-c[N]),0),b=p.reduce((E,N)=>E+(this.viewItems[N].viewMaximumSize-c[N]),0),v=g.length===0?Number.POSITIVE_INFINITY:g.reduce((E,N)=>E+(c[N]-this.viewItems[N].minimumSize),0),x=g.length===0?Number.NEGATIVE_INFINITY:g.reduce((E,N)=>E+(c[N]-this.viewItems[N].viewMaximumSize),0),w=Math.max(_,x),y=Math.min(v,b),C=this.findFirstSnapIndex(p),L=this.findFirstSnapIndex(g);if(typeof C=="number"){let E=this.viewItems[C],N=Math.floor(E.viewMinimumSize/2);h={index:C,limitDelta:E.visible?w-N:w+N,size:E.size}}if(typeof L=="number"){let E=this.viewItems[L],N=Math.floor(E.viewMinimumSize/2);f={index:L,limitDelta:E.visible?y+N:y-N,size:E.size}}}this.sashDragState={start:a,current:a,index:o,sizes:c,minDelta:d,maxDelta:u,alt:l,snapBefore:h,snapAfter:f,disposable:r}};s(t,i)}onSashChange({current:e}){let{index:t,start:i,sizes:o,alt:r,minDelta:s,maxDelta:a,snapBefore:l,snapAfter:c}=this.sashDragState;this.sashDragState.current=e;let d=e-i,u=this.resize(t,d,o,void 0,void 0,s,a,l,c);if(r){let h=t===this.sashItems.length-1,f=this.viewItems.map(x=>x.size),p=h?t:t+1,g=this.viewItems[p],_=g.size-g.maximumSize,b=g.size-g.minimumSize,v=h?t-1:t+1;this.resize(v,-u,f,void 0,void 0,_,b)}this.distributeEmptySpace(),this.layoutViews()}onSashEnd(e){this._onDidSashChange.fire(e),this.sashDragState.disposable.dispose(),this.saveProportions();for(let t of this.viewItems)t.enabled=!0}onViewChange(e,t){let i=this.viewItems.indexOf(e);i<0||i>=this.viewItems.length||(t=typeof t=="number"?t:e.size,t=ps(t,e.minimumSize,e.maximumSize),this.inverseAltBehavior&&i>0?(this.resize(i-1,Math.floor((e.size-t)/2)),this.distributeEmptySpace(),this.layoutViews()):(e.size=t,this.relayout([i],void 0)))}resizeView(e,t){if(!(e<0||e>=this.viewItems.length)){if(this.state!==Db.Idle)throw new Error("Cant modify splitview");this.state=Db.Busy;try{let i=ma(this.viewItems.length).filter(a=>a!==e),o=[...i.filter(a=>this.viewItems[a].priority===1),e],r=i.filter(a=>this.viewItems[a].priority===2),s=this.viewItems[e];t=Math.round(t),t=ps(t,s.minimumSize,Math.min(s.maximumSize,this.size)),s.size=t,this.relayout(o,r)}finally{this.state=Db.Idle}}}distributeViewSizes(){let e=[],t=0;for(let a of this.viewItems)a.maximumSize-a.minimumSize>0&&(e.push(a),t+=a.size);let i=Math.floor(t/e.length);for(let a of e)a.size=ps(i,a.minimumSize,a.maximumSize);let o=ma(this.viewItems.length),r=o.filter(a=>this.viewItems[a].priority===1),s=o.filter(a=>this.viewItems[a].priority===2);this.relayout(r,s)}getViewSize(e){return e<0||e>=this.viewItems.length?-1:this.viewItems[e].size}doAddView(e,t,i=this.viewItems.length,o){if(this.state!==Db.Idle)throw new Error("Cant modify splitview");this.state=Db.Busy;try{let r=J(".split-view-view");i===this.viewItems.length?this.viewContainer.appendChild(r):this.viewContainer.insertBefore(r,this.viewContainer.children.item(i));let s=e.onDidChange(h=>this.onViewChange(d,h)),a=ge(()=>r.remove()),l=qs(s,a),c;typeof t=="number"?c=t:(t.type==="auto"&&(this.areViewsDistributed()?t={type:"distribute"}:t={type:"split",index:t.index}),t.type==="split"?c=this.getViewSize(t.index)/2:t.type==="invisible"?c={cachedVisibleSize:t.cachedVisibleSize}:c=e.minimumSize);let d=this.orientation===0?new Fce(r,e,c,l):new Bce(r,e,c,l);if(this.viewItems.splice(i,0,d),this.viewItems.length>1){let h={orthogonalStartSash:this.orthogonalStartSash,orthogonalEndSash:this.orthogonalEndSash},f=this.orientation===0?new ed(this.sashContainer,{getHorizontalSashTop:E=>this.getSashPosition(E),getHorizontalSashWidth:this.getSashOrthogonalSize},{...h,orientation:1}):new ed(this.sashContainer,{getVerticalSashLeft:E=>this.getSashPosition(E),getVerticalSashHeight:this.getSashOrthogonalSize},{...h,orientation:0}),p=this.orientation===0?E=>({sash:f,start:E.startY,current:E.currentY,alt:E.altKey}):E=>({sash:f,start:E.startX,current:E.currentX,alt:E.altKey}),_=ne.map(f.onDidStart,p)(this.onSashStart,this),v=ne.map(f.onDidChange,p)(this.onSashChange,this),w=ne.map(f.onDidEnd,()=>this.sashItems.findIndex(E=>E.sash===f))(this.onSashEnd,this),y=f.onDidReset(()=>{let E=this.sashItems.findIndex(te=>te.sash===f),N=ma(E,-1),M=ma(E+1,this.viewItems.length),F=this.findFirstSnapIndex(N),q=this.findFirstSnapIndex(M);typeof F=="number"&&!this.viewItems[F].visible||typeof q=="number"&&!this.viewItems[q].visible||this._onDidSashReset.fire(E)}),C=qs(_,v,w,y,f),L={sash:f,disposable:C};this.sashItems.splice(i-1,0,L)}r.appendChild(e.element);let u;typeof t!="number"&&t.type==="split"&&(u=[t.index]),o||this.relayout([i],u),!o&&typeof t!="number"&&t.type==="distribute"&&this.distributeViewSizes()}finally{this.state=Db.Idle}}relayout(e,t){let i=this.viewItems.reduce((o,r)=>o+r.size,0);this.resize(this.viewItems.length-1,this.size-i,void 0,e,t),this.distributeEmptySpace(),this.layoutViews(),this.saveProportions()}resize(e,t,i=this.viewItems.map(d=>d.size),o,r,s=Number.NEGATIVE_INFINITY,a=Number.POSITIVE_INFINITY,l,c){if(e<0||e>=this.viewItems.length)return 0;let d=ma(e,-1),u=ma(e+1,this.viewItems.length);if(r)for(let L of r)T3(d,L),T3(u,L);if(o)for(let L of o)wR(d,L),wR(u,L);let h=d.map(L=>this.viewItems[L]),f=d.map(L=>i[L]),p=u.map(L=>this.viewItems[L]),g=u.map(L=>i[L]),_=d.reduce((L,E)=>L+(this.viewItems[E].minimumSize-i[E]),0),b=d.reduce((L,E)=>L+(this.viewItems[E].maximumSize-i[E]),0),v=u.length===0?Number.POSITIVE_INFINITY:u.reduce((L,E)=>L+(i[E]-this.viewItems[E].minimumSize),0),x=u.length===0?Number.NEGATIVE_INFINITY:u.reduce((L,E)=>L+(i[E]-this.viewItems[E].maximumSize),0),w=Math.max(_,x,s),y=Math.min(v,b,a),C=!1;if(l){let L=this.viewItems[l.index],E=t>=l.limitDelta;C=E!==L.visible,L.setVisible(E,l.size)}if(!C&&c){let L=this.viewItems[c.index],E=ta+l.size,0),i=this.size-t,o=ma(this.viewItems.length-1,-1),r=o.filter(a=>this.viewItems[a].priority===1),s=o.filter(a=>this.viewItems[a].priority===2);for(let a of s)T3(o,a);for(let a of r)wR(o,a);typeof e=="number"&&wR(o,e);for(let a=0;i!==0&&at+i.size,0);let e=0;for(let t of this.viewItems)t.layout(e,this.layoutContext),e+=t.size;this.sashItems.forEach(t=>t.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 e=!1,t=this.viewItems.map(l=>e=l.size-l.minimumSize>0||e);e=!1;let i=this.viewItems.map(l=>e=l.maximumSize-l.size>0||e),o=[...this.viewItems].reverse();e=!1;let r=o.map(l=>e=l.size-l.minimumSize>0||e).reverse();e=!1;let s=o.map(l=>e=l.maximumSize-l.size>0||e).reverse(),a=0;for(let l=0;l0||this.startSnappingEnabled)?c.state=1:v&&t[l]&&(a0)return;if(!i.visible&&i.snap)return t}}areViewsDistributed(){let e,t;for(let i of this.viewItems)if(e=e===void 0?i.size:Math.min(e,i.size),t=t===void 0?i.size:Math.max(t,i.size),t-e>2)return!1;return!0}dispose(){this.sashDragState?.disposable.dispose(),Yt(this.viewItems),this.viewItems=[],this.sashItems.forEach(e=>e.disposable.dispose()),this.sashItems=[],super.dispose()}}});var TFe=k(()=>{});function cdt(n){return{getHeight(e){return n.getHeight(e)},getTemplateId(){return ZH.TemplateId}}}var ZH,Hce,XH,DFe=k(()=>{ke();Ah();Ps();xb();Wce();Ie();j();TFe();ZH=class n{static{this.TemplateId="row"}constructor(e,t,i){this.columns=e,this.getColumnSize=i,this.templateId=n.TemplateId,this.renderedTemplates=new Set;let o=new Map(t.map(r=>[r.templateId,r]));this.renderers=[];for(let r of e){let s=o.get(r.templateId);if(!s)throw new Error(`Table cell renderer for template id ${r.templateId} not found.`);this.renderers.push(s)}}renderTemplate(e){let t=Q(e,J(".monaco-table-tr")),i=[],o=[];for(let s=0;sthis.disposables.add(new Hce(d,u))),l={size:a.reduce((d,u)=>d+u.column.weight,0),views:a.map(d=>({size:d.column.weight,view:d}))};this.splitview=this.disposables.add(new iE(this.domNode,{orientation:1,scrollbarVisibility:2,getSashOrthogonalSize:()=>this.cachedHeight,descriptor:l})),this.splitview.el.style.height=`${i.headerRowHeight}px`,this.splitview.el.style.lineHeight=`${i.headerRowHeight}px`;let c=new ZH(o,r,d=>this.splitview.getViewSize(d));this.list=this.disposables.add(new Xr(e,this.domNode,cdt(i),[c],s)),ne.any(...a.map(d=>d.onDidLayout))(([d,u])=>c.layoutColumn(d,u),null,this.disposables),this.splitview.onDidSashReset(d=>{let u=o.reduce((f,p)=>f+p.weight,0),h=o[d].weight/u*this.cachedWidth;this.splitview.resizeView(d,h)},null,this.disposables),this.styleElement=qr(this.domNode),this.style(QPe)}updateOptions(e){this.list.updateOptions(e)}splice(e,t,i=[]){this.list.splice(e,t,i)}getHTMLElement(){return this.domNode}style(e){let t=[];t.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=t.join(` `),this.list.style(e)}getSelectedElements(){return this.list.getSelectedElements()}getSelection(){return this.list.getSelection()}getFocus(){return this.list.getFocus()}dispose(){this.disposables.dispose()}}});var td,ww,ka,VC,nE=k(()=>{(function(n){n[n.Expanded=0]="Expanded",n[n.Collapsed=1]="Collapsed",n[n.PreserveOrExpanded=2]="PreserveOrExpanded",n[n.PreserveOrCollapsed=3]="PreserveOrCollapsed"})(td||(td={}));(function(n){n[n.Unknown=0]="Unknown",n[n.Twistie=1]="Twistie",n[n.Element=2]="Element",n[n.Filter=3]="Filter"})(ww||(ww={}));ka=class extends Error{constructor(e,t){super(`TreeError [${e}] ${t}`)}},VC=class{constructor(e){this.fn=e,this._map=new WeakMap}map(e){let t=this._map.get(e);return t||(t=this.fn(e),this._map.set(e,t)),t}}});function k2(n){return typeof n=="object"&&"visibility"in n&&"data"in n}function UC(n){switch(n){case!0:return 1;case!1:return 0;default:return n}}function zce(n){return typeof n.collapsible=="boolean"}var QH,JH=k(()=>{nE();at();ft();Fne();LA();Ie();Cl();QH=class{constructor(e,t,i,o={}){this.user=e,this.list=t,this.rootRef=[],this.eventBufferer=new uf,this._onDidChangeCollapseState=new A,this.onDidChangeCollapseState=this.eventBufferer.wrapEvent(this._onDidChangeCollapseState.event),this._onDidChangeRenderNodeCount=new A,this.onDidChangeRenderNodeCount=this.eventBufferer.wrapEvent(this._onDidChangeRenderNodeCount.event),this._onDidSplice=new A,this.onDidSplice=this._onDidSplice.event,this.refilterDelayer=new gr(_B),this.collapseByDefault=typeof o.collapseByDefault>"u"?!1:o.collapseByDefault,this.allowNonCollapsibleParents=o.allowNonCollapsibleParents??!1,this.filter=o.filter,this.autoExpandSingleChildren=typeof o.autoExpandSingleChildren>"u"?!1:o.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(e,t,i=Dt.empty(),o={}){if(e.length===0)throw new ka(this.user,"Invalid tree location");o.diffIdentityProvider?this.spliceSmart(o.diffIdentityProvider,e,t,i,o):this.spliceSimple(e,t,i,o)}spliceSmart(e,t,i,o=Dt.empty(),r,s=r.diffDepth??0){let{parentNode:a}=this.getParentNodeWithListIndex(t);if(!a.lastDiffIds)return this.spliceSimple(t,i,o,r);let l=[...o],c=t[t.length-1],d=new X_({getElements:()=>a.lastDiffIds},{getElements:()=>[...a.children.slice(0,c),...l,...a.children.slice(c+i)].map(g=>e.getId(g.element).toString())}).ComputeDiff(!1);if(d.quitEarly)return a.lastDiffIds=void 0,this.spliceSimple(t,i,l,r);let u=t.slice(0,-1),h=(g,_,b)=>{if(s>0)for(let v=0;vb.originalStart-_.originalStart))h(f,p,f-(g.originalStart+g.originalLength)),f=g.originalStart,p=g.modifiedStart-c,this.spliceSimple([...u,f],g.originalLength,Dt.slice(l,p,p+g.modifiedLength),r);h(f,p,f)}spliceSimple(e,t,i=Dt.empty(),{onDidCreateNode:o,onDidDeleteNode:r,diffIdentityProvider:s}){let{parentNode:a,listIndex:l,revealed:c,visible:d}=this.getParentNodeWithListIndex(e),u=[],h=Dt.map(i,y=>this.createTreeNode(y,a,a.visible?1:0,c,u,o)),f=e[e.length-1],p=0;for(let y=f;y>=0&&ys.getId(y.element).toString())):a.lastDiffIds=a.children.map(y=>s.getId(y.element).toString()):a.lastDiffIds=void 0;let x=0;for(let y of v)y.visible&&x++;if(x!==0)for(let y=f+g.length;yC+(L.visible?L.renderNodeCount:0),0);this._updateAncestorsRenderNodeCount(a,b-y),this.list.splice(l,y,u)}if(v.length>0&&r){let y=C=>{r(C),C.children.forEach(y)};v.forEach(y)}this._onDidSplice.fire({insertedNodes:g,deletedNodes:v});let w=a;for(;w;){if(w.visibility===2){this.refilterDelayer.trigger(()=>this.refilter());break}w=w.parent}}rerender(e){if(e.length===0)throw new ka(this.user,"Invalid tree location");let{node:t,listIndex:i,revealed:o}=this.getTreeNodeWithListIndex(e);t.visible&&o&&this.list.splice(i,1,[t])}has(e){return this.hasTreeNode(e)}getListIndex(e){let{listIndex:t,visible:i,revealed:o}=this.getTreeNodeWithListIndex(e);return i&&o?t:-1}getListRenderCount(e){return this.getTreeNode(e).renderNodeCount}isCollapsible(e){return this.getTreeNode(e).collapsible}setCollapsible(e,t){let i=this.getTreeNode(e);typeof t>"u"&&(t=!i.collapsible);let o={collapsible:t};return this.eventBufferer.bufferEvents(()=>this._setCollapseState(e,o))}isCollapsed(e){return this.getTreeNode(e).collapsed}setCollapsed(e,t,i){let o=this.getTreeNode(e);typeof t>"u"&&(t=!o.collapsed);let r={collapsed:t,recursive:i||!1};return this.eventBufferer.bufferEvents(()=>this._setCollapseState(e,r))}_setCollapseState(e,t){let{node:i,listIndex:o,revealed:r}=this.getTreeNodeWithListIndex(e),s=this._setListNodeCollapseState(i,o,r,t);if(i!==this.root&&this.autoExpandSingleChildren&&s&&!zce(t)&&i.collapsible&&!i.collapsed&&!t.recursive){let a=-1;for(let l=0;l-1){a=-1;break}else a=l;a>-1&&this._setCollapseState([...e,a],t)}return s}_setListNodeCollapseState(e,t,i,o){let r=this._setNodeCollapseState(e,o,!1);if(!i||!e.visible||!r)return r;let s=e.renderNodeCount,a=this.updateNodeAfterCollapseChange(e),l=s-(t===-1?0:1);return this.list.splice(t+1,l,a.slice(1)),r}_setNodeCollapseState(e,t,i){let o;if(e===this.root?o=!1:(zce(t)?(o=e.collapsible!==t.collapsible,e.collapsible=t.collapsible):e.collapsible?(o=e.collapsed!==t.collapsed,e.collapsed=t.collapsed):o=!1,o&&this._onDidChangeCollapseState.fire({node:e,deep:i})),!zce(t)&&t.recursive)for(let r of e.children)o=this._setNodeCollapseState(r,t,!0)||o;return o}expandTo(e){this.eventBufferer.bufferEvents(()=>{let t=this.getTreeNode(e);for(;t.parent;)t=t.parent,e=e.slice(0,e.length-1),t.collapsed&&this._setCollapseState(e,{collapsed:!1,recursive:!1})})}refilter(){let e=this.root.renderNodeCount,t=this.updateNodeAfterFilterChange(this.root);this.list.splice(0,e,t),this.refilterDelayer.cancel()}createTreeNode(e,t,i,o,r,s){let a={parent:t,element:e.element,children:[],depth:t.depth+1,visibleChildrenCount:0,visibleChildIndex:-1,collapsible:typeof e.collapsible=="boolean"?e.collapsible:typeof e.collapsed<"u",collapsed:typeof e.collapsed>"u"?this.collapseByDefault:e.collapsed,renderNodeCount:1,visibility:1,visible:!0,filterData:void 0},l=this._filterNode(a,i);a.visibility=l,o&&r.push(a);let c=e.children||Dt.empty(),d=o&&l!==0&&!a.collapsed,u=0,h=1;for(let f of c){let p=this.createTreeNode(f,a,l,d,r,s);a.children.push(p),h+=p.renderNodeCount,p.visible&&(p.visibleChildIndex=u++)}return this.allowNonCollapsibleParents||(a.collapsible=a.collapsible||a.children.length>0),a.visibleChildrenCount=u,a.visible=l===2?u>0:l===1,a.visible?a.collapsed||(a.renderNodeCount=h):(a.renderNodeCount=0,o&&r.pop()),s?.(a),a}updateNodeAfterCollapseChange(e){let t=e.renderNodeCount,i=[];return this._updateNodeAfterCollapseChange(e,i),this._updateAncestorsRenderNodeCount(e.parent,i.length-t),i}_updateNodeAfterCollapseChange(e,t){if(e.visible===!1)return 0;if(t.push(e),e.renderNodeCount=1,!e.collapsed)for(let i of e.children)e.renderNodeCount+=this._updateNodeAfterCollapseChange(i,t);return this._onDidChangeRenderNodeCount.fire(e),e.renderNodeCount}updateNodeAfterFilterChange(e){let t=e.renderNodeCount,i=[];return this._updateNodeAfterFilterChange(e,e.visible?1:0,i),this._updateAncestorsRenderNodeCount(e.parent,i.length-t),i}_updateNodeAfterFilterChange(e,t,i,o=!0){let r;if(e!==this.root){if(r=this._filterNode(e,t),r===0)return e.visible=!1,e.renderNodeCount=0,!1;o&&i.push(e)}let s=i.length;e.renderNodeCount=e===this.root?0:1;let a=!1;if(!e.collapsed||r!==0){let l=0;for(let c of e.children)a=this._updateNodeAfterFilterChange(c,r,i,o&&!e.collapsed)||a,c.visible&&(c.visibleChildIndex=l++);e.visibleChildrenCount=l}else e.visibleChildrenCount=0;return e!==this.root&&(e.visible=r===2?a:r===1,e.visibility=r),e.visible?e.collapsed||(e.renderNodeCount+=i.length-s):(e.renderNodeCount=0,o&&i.pop()),this._onDidChangeRenderNodeCount.fire(e),e.visible}_updateAncestorsRenderNodeCount(e,t){if(t!==0)for(;e;)e.renderNodeCount+=t,this._onDidChangeRenderNodeCount.fire(e),e=e.parent}_filterNode(e,t){let i=this.filter?this.filter.filter(e.element,t):1;return typeof i=="boolean"?(e.filterData=void 0,i?1:0):k2(i)?(e.filterData=i.data,UC(i.visibility)):(e.filterData=void 0,UC(i))}hasTreeNode(e,t=this.root){if(!e||e.length===0)return!0;let[i,...o]=e;return i<0||i>t.children.length?!1:this.hasTreeNode(o,t.children[i])}getTreeNode(e,t=this.root){if(!e||e.length===0)return t;let[i,...o]=e;if(i<0||i>t.children.length)throw new ka(this.user,"Invalid tree location");return this.getTreeNode(o,t.children[i])}getTreeNodeWithListIndex(e){if(e.length===0)return{node:this.root,listIndex:-1,revealed:!0,visible:!1};let{parentNode:t,listIndex:i,revealed:o,visible:r}=this.getParentNodeWithListIndex(e),s=e[e.length-1];if(s<0||s>t.children.length)throw new ka(this.user,"Invalid tree location");let a=t.children[s];return{node:a,listIndex:i,revealed:o,visible:r&&a.visible}}getParentNodeWithListIndex(e,t=this.root,i=0,o=!0,r=!0){let[s,...a]=e;if(s<0||s>t.children.length)throw new ka(this.user,"Invalid tree location");for(let l=0;l{});function Vce(n){return n instanceof _b?new Uce(n):n}function ddt(n,e){return e&&{...e,identityProvider:e.identityProvider&&{getId(t){return e.identityProvider.getId(t.element)}},dnd:e.dnd&&new $ce(n,e.dnd),multipleSelectionController:e.multipleSelectionController&&{isSelectionSingleChangeEvent(t){return e.multipleSelectionController.isSelectionSingleChangeEvent({...t,element:t.element})},isSelectionRangeChangeEvent(t){return e.multipleSelectionController.isSelectionRangeChangeEvent({...t,element:t.element})}},accessibilityProvider:e.accessibilityProvider&&{...e.accessibilityProvider,getSetSize(t){let i=n(),o=i.getNodeLocation(t),r=i.getParentNodeLocation(o);return i.getNode(r).visibleChildrenCount},getPosInSet(t){return t.visibleChildIndex+1},isChecked:e.accessibilityProvider&&e.accessibilityProvider.isChecked?t=>e.accessibilityProvider.isChecked(t.element):void 0,getRole:e.accessibilityProvider&&e.accessibilityProvider.getRole?t=>e.accessibilityProvider.getRole(t.element):()=>"treeitem",getAriaLabel(t){return e.accessibilityProvider.getAriaLabel(t.element)},getWidgetAriaLabel(){return e.accessibilityProvider.getWidgetAriaLabel()},getWidgetRole:e.accessibilityProvider&&e.accessibilityProvider.getWidgetRole?()=>e.accessibilityProvider.getWidgetRole():()=>"tree",getAriaLevel:e.accessibilityProvider&&e.accessibilityProvider.getAriaLevel?t=>e.accessibilityProvider.getAriaLevel(t.element):t=>t.depth,getActiveDescendantId:e.accessibilityProvider.getActiveDescendantId&&(t=>e.accessibilityProvider.getActiveDescendantId(t.element))},keyboardNavigationLabelProvider:e.keyboardNavigationLabelProvider&&{...e.keyboardNavigationLabelProvider,getKeyboardNavigationLabel(t){return e.keyboardNavigationLabelProvider.getKeyboardNavigationLabel(t.element)}}}}function udt(n,e){return n.position===e.position&&RFe(n,e)}function RFe(n,e){return n.node.element===e.node.element&&n.startIndex===e.startIndex&&n.height===e.height&&n.endIndex===e.endIndex}function ez(n){let e=ww.Unknown;return OB(n.browserEvent.target,"monaco-tl-twistie","monaco-tl-row")?e=ww.Twistie:OB(n.browserEvent.target,"monaco-tl-contents","monaco-tl-row")?e=ww.Element:OB(n.browserEvent.target,"monaco-tree-type-filter","monaco-list")&&(e=ww.Filter),{browserEvent:n.browserEvent,element:n.element?n.element.element:null,target:e}}function hdt(n){let e=yI(n.browserEvent.target);return{element:n.element?n.element.element:null,browserEvent:n.browserEvent,anchor:n.anchor,isStickyScroll:e}}function tz(n,e){e(n),n.children.forEach(t=>tz(t,e))}var Uce,$ce,oE,$C,jce,qce,Kce,Ig,yw,Gce,Yce,Zce,iz,Xce,Qce,L2,Jce,ede,rE,sE=k(()=>{ke();Sf();Ks();Oh();qH();jH();aW();xb();GI();JH();nE();Gr();at();ft();Qi();bn();Ds();Ie();Th();j();eC();yi();NFe();pe();Ps();Oi();Ns();Uce=class extends _b{constructor(e){super(e.elements.map(t=>t.element)),this.data=e}};$ce=class{constructor(e,t){this.modelProvider=e,this.dnd=t,this.autoExpandDisposable=D.None,this.disposables=new H}getDragURI(e){return this.dnd.getDragURI(e.element)}getDragLabel(e,t){if(this.dnd.getDragLabel)return this.dnd.getDragLabel(e.map(i=>i.element),t)}onDragStart(e,t){this.dnd.onDragStart?.(Vce(e),t)}onDragOver(e,t,i,o,r,s=!0){let a=this.dnd.onDragOver(Vce(e),t&&t.element,i,o,r),l=this.autoExpandNode!==t;if(l&&(this.autoExpandDisposable.dispose(),this.autoExpandNode=t),typeof t>"u")return a;if(l&&typeof a!="boolean"&&a.autoExpand&&(this.autoExpandDisposable=gu(()=>{let f=this.modelProvider(),p=f.getNodeLocation(t);f.isCollapsed(p)&&f.setCollapsed(p,!1),this.autoExpandNode=void 0},500,this.disposables)),typeof a=="boolean"||!a.accept||typeof a.bubble>"u"||a.feedback){if(!s){let f=typeof a=="boolean"?a:a.accept,p=typeof a=="boolean"?void 0:a.effect;return{accept:f,effect:p,feedback:[i]}}return a}if(a.bubble===1){let f=this.modelProvider(),p=f.getNodeLocation(t),g=f.getParentNodeLocation(p),_=f.getNode(g),b=g&&f.getListIndex(g);return this.onDragOver(e,_,b,o,r,!1)}let c=this.modelProvider(),d=c.getNodeLocation(t),u=c.getListIndex(d),h=c.getListRenderCount(d);return{...a,feedback:ma(u,u+h)}}drop(e,t,i,o,r){this.autoExpandDisposable.dispose(),this.autoExpandNode=void 0,this.dnd.drop(Vce(e),t&&t.element,i,o,r)}onDragEnd(e){this.dnd.onDragEnd?.(e)}dispose(){this.disposables.dispose(),this.dnd.dispose()}};oE=class{constructor(e){this.delegate=e}getHeight(e){return this.delegate.getHeight(e.element)}getTemplateId(e){return this.delegate.getTemplateId(e.element)}hasDynamicHeight(e){return!!this.delegate.hasDynamicHeight&&this.delegate.hasDynamicHeight(e.element)}setDynamicHeight(e,t){this.delegate.setDynamicHeight?.(e.element,t)}};(function(n){n.None="none",n.OnHover="onHover",n.Always="always"})($C||($C={}));jce=class{get elements(){return this._elements}constructor(e,t=[]){this._elements=t,this.disposables=new H,this.onDidChange=ne.forEach(e,i=>this._elements=i,this.disposables)}dispose(){this.disposables.dispose()}},qce=class n{static{this.DefaultIndent=8}constructor(e,t,i,o,r,s={}){this.renderer=e,this.modelProvider=t,this.activeNodes=o,this.renderedIndentGuides=r,this.renderedElements=new Map,this.renderedNodes=new Map,this.indent=n.DefaultIndent,this.hideTwistiesOfChildlessElements=!1,this.shouldRenderIndentGuides=!1,this.activeIndentNodes=new Set,this.indentGuidesDisposable=D.None,this.disposables=new H,this.templateId=e.templateId,this.updateOptions(s),ne.map(i,a=>a.node)(this.onDidChangeNodeTwistieState,this,this.disposables),e.onDidChangeTwistieState?.(this.onDidChangeTwistieState,this,this.disposables)}updateOptions(e={}){if(typeof e.indent<"u"){let t=ps(e.indent,0,40);if(t!==this.indent){this.indent=t;for(let[i,o]of this.renderedNodes)this.renderTreeElement(i,o)}}if(typeof e.renderIndentGuides<"u"){let t=e.renderIndentGuides!==$C.None;if(t!==this.shouldRenderIndentGuides){this.shouldRenderIndentGuides=t;for(let[i,o]of this.renderedNodes)this._renderIndentGuides(i,o);if(this.indentGuidesDisposable.dispose(),t){let i=new H;this.activeNodes.onDidChange(this._onDidChangeActiveNodes,this,i),this.indentGuidesDisposable=i,this._onDidChangeActiveNodes(this.activeNodes.elements)}}}typeof e.hideTwistiesOfChildlessElements<"u"&&(this.hideTwistiesOfChildlessElements=e.hideTwistiesOfChildlessElements)}renderTemplate(e){let t=Q(e,J(".monaco-tl-row")),i=Q(t,J(".monaco-tl-indent")),o=Q(t,J(".monaco-tl-twistie")),r=Q(t,J(".monaco-tl-contents")),s=this.renderer.renderTemplate(r);return{container:e,indent:i,twistie:o,indentGuidesDisposable:D.None,templateData:s}}renderElement(e,t,i,o){this.renderedNodes.set(e,i),this.renderedElements.set(e.element,e),this.renderTreeElement(e,i),this.renderer.renderElement(e,t,i.templateData,o)}disposeElement(e,t,i,o){i.indentGuidesDisposable.dispose(),this.renderer.disposeElement?.(e,t,i.templateData,o),typeof o=="number"&&(this.renderedNodes.delete(e),this.renderedElements.delete(e.element))}disposeTemplate(e){this.renderer.disposeTemplate(e.templateData)}onDidChangeTwistieState(e){let t=this.renderedElements.get(e);t&&this.onDidChangeNodeTwistieState(t)}onDidChangeNodeTwistieState(e){let t=this.renderedNodes.get(e);t&&(this._onDidChangeActiveNodes(this.activeNodes.elements),this.renderTreeElement(e,t))}renderTreeElement(e,t){let i=n.DefaultIndent+(e.depth-1)*this.indent;t.twistie.style.paddingLeft=`${i}px`,t.indent.style.width=`${i+this.indent-16}px`,e.collapsible?t.container.setAttribute("aria-expanded",String(!e.collapsed)):t.container.removeAttribute("aria-expanded"),t.twistie.classList.remove(...Oe.asClassNameArray(oe.treeItemExpanded));let o=!1;this.renderer.renderTwistie&&(o=this.renderer.renderTwistie(e.element,t.twistie)),e.collapsible&&(!this.hideTwistiesOfChildlessElements||e.visibleChildrenCount>0)?(o||t.twistie.classList.add(...Oe.asClassNameArray(oe.treeItemExpanded)),t.twistie.classList.add("collapsible"),t.twistie.classList.toggle("collapsed",e.collapsed)):t.twistie.classList.remove("collapsible","collapsed"),this._renderIndentGuides(e,t)}_renderIndentGuides(e,t){if(no(t.indent),t.indentGuidesDisposable.dispose(),!this.shouldRenderIndentGuides)return;let i=new H,o=this.modelProvider();for(;;){let r=o.getNodeLocation(e),s=o.getParentNodeLocation(r);if(!s)break;let a=o.getNode(s),l=J(".indent-guide",{style:`width: ${this.indent}px`});this.activeIndentNodes.has(a)&&l.classList.add("active"),t.indent.childElementCount===0?t.indent.appendChild(l):t.indent.insertBefore(l,t.indent.firstElementChild),this.renderedIndentGuides.add(a,l),i.add(ge(()=>this.renderedIndentGuides.delete(a,l))),e=a}t.indentGuidesDisposable=i}_onDidChangeActiveNodes(e){if(!this.shouldRenderIndentGuides)return;let t=new Set,i=this.modelProvider();e.forEach(o=>{let r=i.getNodeLocation(o);try{let s=i.getParentNodeLocation(r);o.collapsible&&o.children.length>0&&!o.collapsed?t.add(o):s&&t.add(i.getNode(s))}catch{}}),this.activeIndentNodes.forEach(o=>{t.has(o)||this.renderedIndentGuides.forEach(o,r=>r.classList.remove("active"))}),t.forEach(o=>{this.activeIndentNodes.has(o)||this.renderedIndentGuides.forEach(o,r=>r.classList.add("active"))}),this.activeIndentNodes=t}dispose(){this.renderedNodes.clear(),this.renderedElements.clear(),this.indentGuidesDisposable.dispose(),Yt(this.disposables)}},Kce=class{get totalCount(){return this._totalCount}get matchCount(){return this._matchCount}constructor(e,t,i){this.tree=e,this.keyboardNavigationLabelProvider=t,this._filter=i,this._totalCount=0,this._matchCount=0,this._pattern="",this._lowercasePattern="",this.disposables=new H,e.onWillRefilter(this.reset,this,this.disposables)}filter(e,t){let i=1;if(this._filter){let s=this._filter.filter(e,t);if(typeof s=="boolean"?i=s?1:0:k2(s)?i=UC(s.visibility):i=s,i===0)return!1}if(this._totalCount++,!this._pattern)return this._matchCount++,{data:qc.Default,visibility:i};let o=this.keyboardNavigationLabelProvider.getKeyboardNavigationLabel(e),r=Array.isArray(o)?o:[o];for(let s of r){let a=s&&s.toString();if(typeof a>"u")return{data:qc.Default,visibility:i};let l;if(this.tree.findMatchType===yw.Contiguous){let c=a.toLowerCase().indexOf(this._lowercasePattern);if(c>-1){l=[Number.MAX_SAFE_INTEGER,0];for(let d=this._lowercasePattern.length;d>0;d--)l.push(c+d-1)}}else l=Jm(this._pattern,this._lowercasePattern,0,a,a.toLowerCase(),0,{firstMatchCanBeWeak:!0,boostFullMatch:!0});if(l)return this._matchCount++,r.length===1?{data:l,visibility:i}:{data:{label:a,score:l},visibility:i}}return this.tree.findMode===Ig.Filter?typeof this.tree.options.defaultFindVisibility=="number"?this.tree.options.defaultFindVisibility:this.tree.options.defaultFindVisibility?this.tree.options.defaultFindVisibility(e):2:{data:qc.Default,visibility:i}}reset(){this._totalCount=0,this._matchCount=0}dispose(){Yt(this.disposables)}};(function(n){n[n.Highlight=0]="Highlight",n[n.Filter=1]="Filter"})(Ig||(Ig={}));(function(n){n[n.Fuzzy=0]="Fuzzy",n[n.Contiguous=1]="Contiguous"})(yw||(yw={}));Gce=class{get pattern(){return this._pattern}get mode(){return this._mode}set mode(e){e!==this._mode&&(this._mode=e,this.widget&&(this.widget.mode=this._mode),this.tree.refilter(),this.render(),this._onDidChangeMode.fire(e))}get matchType(){return this._matchType}set matchType(e){e!==this._matchType&&(this._matchType=e,this.widget&&(this.widget.matchType=this._matchType),this.tree.refilter(),this.render(),this._onDidChangeMatchType.fire(e))}constructor(e,t,i,o,r,s={}){this.tree=e,this.view=i,this.filter=o,this.contextViewProvider=r,this.options=s,this._pattern="",this.width=0,this._onDidChangeMode=new A,this.onDidChangeMode=this._onDidChangeMode.event,this._onDidChangeMatchType=new A,this.onDidChangeMatchType=this._onDidChangeMatchType.event,this._onDidChangePattern=new A,this._onDidChangeOpenState=new A,this.onDidChangeOpenState=this._onDidChangeOpenState.event,this.enabledDisposables=new H,this.disposables=new H,this._mode=e.options.defaultFindMode??Ig.Highlight,this._matchType=e.options.defaultFindMatchType??yw.Fuzzy,t.onDidSplice(this.onDidSpliceModel,this,this.disposables)}updateOptions(e={}){e.defaultFindMode!==void 0&&(this.mode=e.defaultFindMode),e.defaultFindMatchType!==void 0&&(this.matchType=e.defaultFindMatchType)}onDidSpliceModel(){!this.widget||this.pattern.length===0||(this.tree.refilter(),this.render())}render(){let e=this.filter.totalCount>0&&this.filter.matchCount===0;this.pattern&&e?(Bo(m("replFindNoResults","No results")),this.tree.options.showNotFoundMessage??!0?this.widget?.showMessage({type:2,content:m("not found","No elements found.")}):this.widget?.showMessage({type:2})):(this.widget?.clearMessage(),this.pattern&&Bo(m("replFindResults","{0} results",this.filter.matchCount)))}shouldAllowFocus(e){return!this.widget||!this.pattern||this.filter.totalCount>0&&this.filter.matchCount<=1?!0:!qc.isDefault(e.filterData)}layout(e){this.width=e,this.widget?.layout(e)}dispose(){this._history=void 0,this._onDidChangePattern.dispose(),this.enabledDisposables.dispose(),this.disposables.dispose()}};Yce=class{constructor(e=[]){this.stickyNodes=e}get count(){return this.stickyNodes.length}equal(e){return oi(this.stickyNodes,e.stickyNodes,udt)}lastNodePartiallyVisible(){if(this.count===0)return!1;let e=this.stickyNodes[this.count-1];if(this.count===1)return e.position!==0;let t=this.stickyNodes[this.count-2];return t.position+t.height!==e.position}animationStateChanged(e){if(!oi(this.stickyNodes,e.stickyNodes,RFe)||this.count===0)return!1;let t=this.stickyNodes[this.count-1],i=e.stickyNodes[e.count-1];return t.position!==i.position}},Zce=class{constrainStickyScrollNodes(e,t,i){for(let o=0;oi||o>=t)return e.slice(0,o)}return e}},iz=class extends D{constructor(e,t,i,o,r,s={}){super(),this.tree=e,this.model=t,this.view=i,this.treeDelegate=r,this.maxWidgetViewRatio=.4;let a=this.validateStickySettings(s);this.stickyScrollMaxItemCount=a.stickyScrollMaxItemCount,this.stickyScrollDelegate=s.stickyScrollDelegate??new Zce,this._widget=this._register(new Xce(i.getScrollableElement(),i,e,o,r,s.accessibilityProvider)),this.onDidChangeHasFocus=this._widget.onDidChangeHasFocus,this.onContextMenu=this._widget.onContextMenu,this._register(i.onDidScroll(()=>this.update())),this._register(i.onDidChangeContentHeight(()=>this.update())),this._register(e.onDidChangeCollapseState(()=>this.update())),this.update()}get height(){return this._widget.height}getNodeAtHeight(e){let t;if(e===0?t=this.view.firstVisibleIndex:t=this.view.indexAt(e+this.view.scrollTop),!(t<0||t>=this.view.length))return this.view.element(t)}update(){let e=this.getNodeAtHeight(0);if(!e||this.tree.scrollTop===0){this._widget.setState(void 0);return}let t=this.findStickyState(e);this._widget.setState(t)}findStickyState(e){let t=[],i=e,o=0,r=this.getNextStickyNode(i,void 0,o);for(;r&&(t.push(r),o+=r.height,!(t.length<=this.stickyScrollMaxItemCount&&(i=this.getNextVisibleNode(r),!i)));)r=this.getNextStickyNode(i,r.node,o);let s=this.constrainStickyNodes(t);return s.length?new Yce(s):void 0}getNextVisibleNode(e){return this.getNodeAtHeight(e.position+e.height)}getNextStickyNode(e,t,i){let o=this.getAncestorUnderPrevious(e,t);if(o&&!(o===e&&(!this.nodeIsUncollapsedParent(e)||this.nodeTopAlignsWithStickyNodesBottom(e,i))))return this.createStickyScrollNode(o,i)}nodeTopAlignsWithStickyNodesBottom(e,t){let i=this.getNodeIndex(e),o=this.view.getElementTop(i),r=t;return this.view.scrollTop===o-r}createStickyScrollNode(e,t){let i=this.treeDelegate.getHeight(e),{startIndex:o,endIndex:r}=this.getNodeRange(e),s=this.calculateStickyNodePosition(r,t,i);return{node:e,position:s,height:i,startIndex:o,endIndex:r}}getAncestorUnderPrevious(e,t=void 0){let i=e,o=this.getParentNode(i);for(;o;){if(o===t)return i;i=o,o=this.getParentNode(i)}if(t===void 0)return i}calculateStickyNodePosition(e,t,i){let o=this.view.getRelativeTop(e);if(o===null&&this.view.firstVisibleIndex===e&&e+1l&&t<=l?l-i:t}constrainStickyNodes(e){if(e.length===0)return[];let t=this.view.renderHeight*this.maxWidgetViewRatio,i=e[e.length-1];if(e.length<=this.stickyScrollMaxItemCount&&i.position+i.height<=t)return e;let o=this.stickyScrollDelegate.constrainStickyScrollNodes(e,this.stickyScrollMaxItemCount,t);if(!o.length)return[];let r=o[o.length-1];if(o.length>this.stickyScrollMaxItemCount||r.position+r.height>t)throw new Error("stickyScrollDelegate violates constraints");return o}getParentNode(e){let t=this.model.getNodeLocation(e),i=this.model.getParentNodeLocation(t);return i?this.model.getNode(i):void 0}nodeIsUncollapsedParent(e){let t=this.model.getNodeLocation(e);return this.model.getListRenderCount(t)>1}getNodeIndex(e){let t=this.model.getNodeLocation(e);return this.model.getListIndex(t)}getNodeRange(e){let t=this.model.getNodeLocation(e),i=this.model.getListIndex(t);if(i<0)throw new Error("Node not found in tree");let o=this.model.getListRenderCount(t),r=i+o-1;return{startIndex:i,endIndex:r}}nodePositionTopBelowWidget(e){let t=[],i=this.getParentNode(e);for(;i;)t.push(i),i=this.getParentNode(i);let o=0;for(let r=0;r0,i=!!e&&e.count>0;if(!t&&!i||t&&i&&this._previousState.equal(e))return;if(t!==i&&this.setVisible(i),!i){this._previousState=void 0,this._previousElements=[],this._previousStateDisposables.clear();return}let o=e.stickyNodes[e.count-1];if(this._previousState&&e.animationStateChanged(this._previousState))this._previousElements[this._previousState.count-1].style.top=`${o.position}px`;else{this._previousStateDisposables.clear();let r=Array(e.count);for(let s=e.count-1;s>=0;s--){let a=e.stickyNodes[s],{element:l,disposable:c}=this.createElement(a,s,e.count);r[s]=l,this._rootDomNode.appendChild(l),this._previousStateDisposables.add(c)}this.stickyScrollFocus.updateElements(r,e),this._previousElements=r}this._previousState=e,this._rootDomNode.style.height=`${o.position+o.height}px`}createElement(e,t,i){let o=e.startIndex,r=document.createElement("div");r.style.top=`${e.position}px`,this.tree.options.setRowHeight!==!1&&(r.style.height=`${e.height}px`),this.tree.options.setRowLineHeight!==!1&&(r.style.lineHeight=`${e.height}px`),r.classList.add("monaco-tree-sticky-row"),r.classList.add("monaco-list-row"),r.setAttribute("data-index",`${o}`),r.setAttribute("data-parity",o%2===0?"even":"odd"),r.setAttribute("id",this.view.getElementID(o));let s=this.setAccessibilityAttributes(r,e.node.element,t,i),a=this.treeDelegate.getTemplateId(e.node),l=this.treeRenderers.find(h=>h.templateId===a);if(!l)throw new Error(`No renderer found for template id ${a}`);let c=e.node;c===this.tree.getNode(this.tree.getNodeLocation(e.node))&&(c=new Proxy(e.node,{}));let d=l.renderTemplate(r);l.renderElement(c,e.startIndex,d,e.height);let u=ge(()=>{s.dispose(),l.disposeElement(c,e.startIndex,d,e.height),l.disposeTemplate(d),r.remove()});return{element:r,disposable:u}}setAccessibilityAttributes(e,t,i,o){if(!this.accessibilityProvider)return D.None;this.accessibilityProvider.getSetSize&&e.setAttribute("aria-setsize",String(this.accessibilityProvider.getSetSize(t,i,o))),this.accessibilityProvider.getPosInSet&&e.setAttribute("aria-posinset",String(this.accessibilityProvider.getPosInSet(t,i))),this.accessibilityProvider.getRole&&e.setAttribute("role",this.accessibilityProvider.getRole(t)??"treeitem");let r=this.accessibilityProvider.getAriaLabel(t),s=r&&typeof r!="string"?r:Ms(r),a=He(c=>{let d=c.readObservable(s);d?e.setAttribute("aria-label",d):e.removeAttribute("aria-label")});typeof r=="string"||r&&e.setAttribute("aria-label",r.get());let l=this.accessibilityProvider.getAriaLevel&&this.accessibilityProvider.getAriaLevel(t);return typeof l=="number"&&e.setAttribute("aria-level",`${l}`),e.setAttribute("aria-selected",String(!1)),a}setVisible(e){this._rootDomNode.classList.toggle("empty",!e),e||this.stickyScrollFocus.updateElements([],void 0)}domFocus(){this.stickyScrollFocus.domFocus()}focusedLast(){return this.stickyScrollFocus.focusedLast()}dispose(){this.stickyScrollFocus.dispose(),this._previousStateDisposables.dispose(),this._rootDomNode.remove()}},Qce=class extends D{get domHasFocus(){return this._domHasFocus}set domHasFocus(e){e!==this._domHasFocus&&(this._onDidChangeHasFocus.fire(e),this._domHasFocus=e)}constructor(e,t){super(),this.container=e,this.view=t,this.focusedIndex=-1,this.elements=[],this._onDidChangeHasFocus=new A,this.onDidChangeHasFocus=this._onDidChangeHasFocus.event,this._onContextMenu=new A,this.onContextMenu=this._onContextMenu.event,this._domHasFocus=!1,this._register(U(this.container,"focus",()=>this.onFocus())),this._register(U(this.container,"blur",()=>this.onBlur())),this._register(this.view.onDidFocus(()=>this.toggleStickyScrollFocused(!1))),this._register(this.view.onKeyDown(i=>this.onKeyDown(i))),this._register(this.view.onMouseDown(i=>this.onMouseDown(i))),this._register(this.view.onContextMenu(i=>this.handleContextMenu(i)))}handleContextMenu(e){let t=e.browserEvent.target;if(!yI(t)&&!wI(t)){this.focusedLast()&&this.view.domFocus();return}if(!mf(e.browserEvent)){if(!this.state)throw new Error("Context menu should not be triggered when state is undefined");let s=this.state.stickyNodes.findIndex(a=>a.node.element===e.element?.element);if(s===-1)throw new Error("Context menu should not be triggered when element is not in sticky scroll widget");this.container.focus(),this.setFocus(s);return}if(!this.state||this.focusedIndex<0)throw new Error("Context menu key should not be triggered when focus is not in sticky scroll widget");let o=this.state.stickyNodes[this.focusedIndex].node.element,r=this.elements[this.focusedIndex];this._onContextMenu.fire({element:o,anchor:r,browserEvent:e.browserEvent,isStickyScroll:!0})}onKeyDown(e){if(this.domHasFocus&&this.state){if(e.key==="ArrowUp")this.setFocusedElement(Math.max(0,this.focusedIndex-1)),e.preventDefault(),e.stopPropagation();else if(e.key==="ArrowDown"||e.key==="ArrowRight"){if(this.focusedIndex>=this.state.count-1){let t=this.state.stickyNodes[this.state.count-1].startIndex+1;this.view.domFocus(),this.view.setFocus([t]),this.scrollNodeUnderWidget(t,this.state)}else this.setFocusedElement(this.focusedIndex+1);e.preventDefault(),e.stopPropagation()}}}onMouseDown(e){let t=e.browserEvent.target;!yI(t)&&!wI(t)||(e.browserEvent.preventDefault(),e.browserEvent.stopPropagation())}updateElements(e,t){if(t&&t.count===0)throw new Error("Sticky scroll state must be undefined when there are no sticky nodes");if(t&&t.count!==e.length)throw new Error("Sticky scroll focus received illigel state");let i=this.focusedIndex;if(this.removeFocus(),this.elements=e,this.state=t,t){let o=ps(i,0,t.count-1);this.setFocus(o)}else this.domHasFocus&&this.view.domFocus();this.container.tabIndex=t?0:-1}setFocusedElement(e){let t=this.state;if(!t)throw new Error("Cannot set focus when state is undefined");if(this.setFocus(e),!(e1?t.stickyNodes[t.count-2]:void 0,r=this.view.getElementTop(e),s=o?o.position+o.height+i.height:i.height;this.view.scrollTop=r-s}domFocus(){if(!this.state)throw new Error("Cannot focus when state is undefined");this.container.focus()}focusedLast(){return this.state?this.view.getHTMLElement().classList.contains("sticky-scroll-focused"):!1}removeFocus(){this.focusedIndex!==-1&&(this.toggleElementFocus(this.elements[this.focusedIndex],!1),this.focusedIndex=-1)}setFocus(e){if(0>e)throw new Error("addFocus() can not remove focus");if(!this.state&&e>=0)throw new Error("Cannot set focus index when state is undefined");if(this.state&&e>=this.state.count)throw new Error("Cannot set focus index to an index that does not exist");let t=this.focusedIndex;t>=0&&this.toggleElementFocus(this.elements[t],!1),e>=0&&this.toggleElementFocus(this.elements[e],!0),this.focusedIndex=e}toggleElementFocus(e,t){this.toggleElementActiveFocus(e,t&&this.domHasFocus),this.toggleElementPassiveFocus(e,t)}toggleCurrentElementActiveFocus(e){this.focusedIndex!==-1&&this.toggleElementActiveFocus(this.elements[this.focusedIndex],e)}toggleElementActiveFocus(e,t){e.classList.toggle("focused",t)}toggleElementPassiveFocus(e,t){e.classList.toggle("passive-focused",t)}toggleStickyScrollFocused(e){this.view.getHTMLElement().classList.toggle("sticky-scroll-focused",e)}onFocus(){if(!this.state||this.elements.length===0)throw new Error("Cannot focus when state is undefined or elements are empty");this.domHasFocus=!0,this.toggleStickyScrollFocused(!0),this.toggleCurrentElementActiveFocus(!0),this.focusedIndex===-1&&this.setFocus(0)}onBlur(){this.domHasFocus=!1,this.toggleCurrentElementActiveFocus(!1)}dispose(){this.toggleStickyScrollFocused(!1),this._onDidChangeHasFocus.fire(!1),super.dispose()}};L2=class{get nodeSet(){return this._nodeSet||(this._nodeSet=this.createNodeSet()),this._nodeSet}constructor(e,t){this.getFirstViewElementWithTrait=e,this.identityProvider=t,this.nodes=[],this._onDidChange=new A,this.onDidChange=this._onDidChange.event}set(e,t){!t?.__forceEvent&&oi(this.nodes,e)||this._set(e,!1,t)}_set(e,t,i){if(this.nodes=[...e],this.elements=void 0,this._nodeSet=void 0,!t){let o=this;this._onDidChange.fire({get elements(){return o.get()},browserEvent:i})}}get(){return this.elements||(this.elements=this.nodes.map(e=>e.element)),[...this.elements]}getNodes(){return this.nodes}has(e){return this.nodeSet.has(e)}onDidModelSplice({insertedNodes:e,deletedNodes:t}){if(!this.identityProvider){let l=this.createNodeSet(),c=d=>l.delete(d);t.forEach(d=>tz(d,c)),this.set([...l.values()]);return}let i=new Set,o=l=>i.add(this.identityProvider.getId(l.element).toString());t.forEach(l=>tz(l,o));let r=new Map,s=l=>r.set(this.identityProvider.getId(l.element).toString(),l);e.forEach(l=>tz(l,s));let a=[];for(let l of this.nodes){let c=this.identityProvider.getId(l.element).toString();if(!i.has(c))a.push(l);else{let u=r.get(c);u&&u.visible&&a.push(u)}}if(this.nodes.length>0&&a.length===0){let l=this.getFirstViewElementWithTrait();l&&a.push(l)}this._set(a,!0)}createNodeSet(){let e=new Set;for(let t of this.nodes)e.add(t);return e}},Jce=class extends zM{constructor(e,t,i){super(e),this.tree=t,this.stickyScrollProvider=i}onViewPointer(e){if(Xae(e.browserEvent.target)||vb(e.browserEvent.target)||bI(e.browserEvent.target)||e.browserEvent.isHandledByList)return;let t=e.element;if(!t)return super.onViewPointer(e);if(this.isSelectionRangeChangeEvent(e)||this.isSelectionSingleChangeEvent(e))return super.onViewPointer(e);let i=e.browserEvent.target,o=i.classList.contains("monaco-tl-twistie")||i.classList.contains("monaco-icon-label")&&i.classList.contains("folder-icon")&&e.browserEvent.offsetX<16,r=wI(e.browserEvent.target),s=!1;if(r?s=!0:typeof this.tree.expandOnlyOnTwistieClick=="function"?s=this.tree.expandOnlyOnTwistieClick(t.element):s=!!this.tree.expandOnlyOnTwistieClick,r)this.handleStickyScrollMouseEvent(e,t);else{if(s&&!o&&e.browserEvent.detail!==2)return super.onViewPointer(e);if(!this.tree.expandOnDoubleClick&&e.browserEvent.detail===2)return super.onViewPointer(e)}if(t.collapsible&&(!r||o)){let a=this.tree.getNodeLocation(t),l=e.browserEvent.altKey;if(this.tree.setFocus([a]),this.tree.toggleCollapsed(a,l),o){e.browserEvent.isHandledByList=!0;return}}r||super.onViewPointer(e)}handleStickyScrollMouseEvent(e,t){if(ZPe(e.browserEvent.target)||XPe(e.browserEvent.target))return;let i=this.stickyScrollProvider();if(!i)throw new Error("Sticky scroll controller not found");let o=this.list.indexOf(t),r=this.list.getElementTop(o),s=i.nodePositionTopBelowWidget(t);this.tree.scrollTop=r-s,this.list.domFocus(),this.list.setFocus([o]),this.list.setSelection([o])}onDoubleClick(e){e.browserEvent.target.classList.contains("monaco-tl-twistie")||!this.tree.expandOnDoubleClick||e.browserEvent.isHandledByList||super.onDoubleClick(e)}onMouseDown(e){let t=e.browserEvent.target;if(!yI(t)&&!wI(t)){super.onMouseDown(e);return}}onContextMenu(e){let t=e.browserEvent.target;if(!yI(t)&&!wI(t)){super.onContextMenu(e);return}}},ede=class extends Xr{constructor(e,t,i,o,r,s,a,l){super(e,t,i,o,l),this.focusTrait=r,this.selectionTrait=s,this.anchorTrait=a}createMouseController(e){return new Jce(this,e.tree,e.stickyScrollProvider)}splice(e,t,i=[]){if(super.splice(e,t,i),i.length===0)return;let o=[],r=[],s;i.forEach((a,l)=>{this.focusTrait.has(a)&&o.push(e+l),this.selectionTrait.has(a)&&r.push(e+l),this.anchorTrait.has(a)&&(s=e+l)}),o.length>0&&super.setFocus(Ac([...super.getFocus(),...o])),r.length>0&&super.setSelection(Ac([...super.getSelection(),...r])),typeof s=="number"&&super.setAnchor(s)}setFocus(e,t,i=!1){super.setFocus(e,t),i||this.focusTrait.set(e.map(o=>this.element(o)),t)}setSelection(e,t,i=!1){super.setSelection(e,t),i||this.selectionTrait.set(e.map(o=>this.element(o)),t)}setAnchor(e,t=!1){super.setAnchor(e),t||(typeof e>"u"?this.anchorTrait.set([]):this.anchorTrait.set([this.element(e)]))}},rE=class{get onDidScroll(){return this.view.onDidScroll}get onDidChangeFocus(){return this.eventBufferer.wrapEvent(this.focus.onDidChange)}get onDidChangeSelection(){return this.eventBufferer.wrapEvent(this.selection.onDidChange)}get onMouseDblClick(){return ne.filter(ne.map(this.view.onMouseDblClick,ez),e=>e.target!==ww.Filter)}get onMouseOver(){return ne.map(this.view.onMouseOver,ez)}get onMouseOut(){return ne.map(this.view.onMouseOut,ez)}get onContextMenu(){return ne.any(ne.filter(ne.map(this.view.onContextMenu,hdt),e=>!e.isStickyScroll),this.stickyScrollController?.onContextMenu??ne.None)}get onPointer(){return ne.map(this.view.onPointer,ez)}get onKeyDown(){return this.view.onKeyDown}get onDidFocus(){return this.view.onDidFocus}get onDidChangeModel(){return ne.signal(this.model.onDidSplice)}get onDidChangeCollapseState(){return this.model.onDidChangeCollapseState}get findMode(){return this.findController?.mode??Ig.Highlight}set findMode(e){this.findController&&(this.findController.mode=e)}get findMatchType(){return this.findController?.matchType??yw.Fuzzy}set findMatchType(e){this.findController&&(this.findController.matchType=e)}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}constructor(e,t,i,o,r={}){this._user=e,this._options=r,this.eventBufferer=new uf,this.onDidChangeFindOpenState=ne.None,this.onDidChangeStickyScrollFocused=ne.None,this.disposables=new H,this._onWillRefilter=new A,this.onWillRefilter=this._onWillRefilter.event,this._onDidUpdateOptions=new A,this.treeDelegate=new oE(i);let s=new PR,a=new PR,l=this.disposables.add(new jce(a.event)),c=new Rx;this.renderers=o.map(p=>new qce(p,()=>this.model,s.event,l,c,r));for(let p of this.renderers)this.disposables.add(p);let d;r.keyboardNavigationLabelProvider&&(d=new Kce(this,r.keyboardNavigationLabelProvider,r.filter),r={...r,filter:d},this.disposables.add(d)),this.focus=new L2(()=>this.view.getFocusedElements()[0],r.identityProvider),this.selection=new L2(()=>this.view.getSelectedElements()[0],r.identityProvider),this.anchor=new L2(()=>this.view.getAnchorElement(),r.identityProvider),this.view=new ede(e,t,this.treeDelegate,this.renderers,this.focus,this.selection,this.anchor,{...ddt(()=>this.model,r),tree:this,stickyScrollProvider:()=>this.stickyScrollController}),this.model=this.createModel(e,this.view,r),s.input=this.model.onDidChangeCollapseState;let u=ne.forEach(this.model.onDidSplice,p=>{this.eventBufferer.bufferEvents(()=>{this.focus.onDidModelSplice(p),this.selection.onDidModelSplice(p)})},this.disposables);u(()=>null,null,this.disposables);let h=this.disposables.add(new A),f=this.disposables.add(new gr(0));if(this.disposables.add(ne.any(u,this.focus.onDidChange,this.selection.onDidChange)(()=>{f.trigger(()=>{let p=new Set;for(let g of this.focus.getNodes())p.add(g);for(let g of this.selection.getNodes())p.add(g);h.fire([...p.values()])})})),a.input=h.event,r.keyboardSupport!==!1){let p=ne.chain(this.view.onKeyDown,g=>g.filter(_=>!vb(_.target)).map(_=>new Xt(_)));ne.chain(p,g=>g.filter(_=>_.keyCode===15))(this.onLeftArrow,this,this.disposables),ne.chain(p,g=>g.filter(_=>_.keyCode===17))(this.onRightArrow,this,this.disposables),ne.chain(p,g=>g.filter(_=>_.keyCode===10))(this.onSpace,this,this.disposables)}if((r.findWidgetEnabled??!0)&&r.keyboardNavigationLabelProvider&&r.contextViewProvider){let p=this.options.findWidgetStyles?{styles:this.options.findWidgetStyles}:void 0;this.findController=new Gce(this,this.model,this.view,d,r.contextViewProvider,p),this.focusNavigationFilter=g=>this.findController.shouldAllowFocus(g),this.onDidChangeFindOpenState=this.findController.onDidChangeOpenState,this.disposables.add(this.findController),this.onDidChangeFindMode=this.findController.onDidChangeMode,this.onDidChangeFindMatchType=this.findController.onDidChangeMatchType}else this.onDidChangeFindMode=ne.None,this.onDidChangeFindMatchType=ne.None;r.enableStickyScroll&&(this.stickyScrollController=new iz(this,this.model,this.view,this.renderers,this.treeDelegate,r),this.onDidChangeStickyScrollFocused=this.stickyScrollController.onDidChangeHasFocus),this.styleElement=qr(this.view.getHTMLElement()),this.getHTMLElement().classList.toggle("always",this._options.renderIndentGuides===$C.Always)}updateOptions(e={}){this._options={...this._options,...e};for(let t of this.renderers)t.updateOptions(e);this.view.updateOptions(this._options),this.findController?.updateOptions(e),this.updateStickyScroll(e),this._onDidUpdateOptions.fire(this._options),this.getHTMLElement().classList.toggle("always",this._options.renderIndentGuides===$C.Always)}get options(){return this._options}updateStickyScroll(e){!this.stickyScrollController&&this._options.enableStickyScroll?(this.stickyScrollController=new iz(this,this.model,this.view,this.renderers,this.treeDelegate,this._options),this.onDidChangeStickyScrollFocused=this.stickyScrollController.onDidChangeHasFocus):this.stickyScrollController&&!this._options.enableStickyScroll&&(this.onDidChangeStickyScrollFocused=ne.None,this.stickyScrollController.dispose(),this.stickyScrollController=void 0),this.stickyScrollController?.updateOptions(e)}getHTMLElement(){return this.view.getHTMLElement()}get scrollTop(){return this.view.scrollTop}set scrollTop(e){this.view.scrollTop=e}get scrollHeight(){return this.view.scrollHeight}get renderHeight(){return this.view.renderHeight}get ariaLabel(){return this.view.ariaLabel}set ariaLabel(e){this.view.ariaLabel=e}domFocus(){this.stickyScrollController?.focusedLast()?this.stickyScrollController.domFocus():this.view.domFocus()}layout(e,t){this.view.layout(e,t),cu(t)&&this.findController?.layout(t)}style(e){let t=`.${this.view.domId}`,i=[];e.treeIndentGuidesStroke&&(i.push(`.monaco-list${t}:hover .monaco-tl-indent > .indent-guide, .monaco-list${t}.always .monaco-tl-indent > .indent-guide { border-color: ${e.treeInactiveIndentGuidesStroke}; }`),i.push(`.monaco-list${t} .monaco-tl-indent > .indent-guide.active { border-color: ${e.treeIndentGuidesStroke}; }`));let o=e.treeStickyScrollBackground??e.listBackground;o&&(i.push(`.monaco-list${t} .monaco-scrollable-element .monaco-tree-sticky-container { background-color: ${o}; }`),i.push(`.monaco-list${t} .monaco-scrollable-element .monaco-tree-sticky-container .monaco-tree-sticky-row { background-color: ${o}; }`)),e.treeStickyScrollBorder&&i.push(`.monaco-list${t} .monaco-scrollable-element .monaco-tree-sticky-container { border-bottom: 1px solid ${e.treeStickyScrollBorder}; }`),e.treeStickyScrollShadow&&i.push(`.monaco-list${t} .monaco-scrollable-element .monaco-tree-sticky-container .monaco-tree-sticky-container-shadow { box-shadow: ${e.treeStickyScrollShadow} 0 6px 6px -6px inset; height: 3px; }`),e.listFocusForeground&&(i.push(`.monaco-list${t}.sticky-scroll-focused .monaco-scrollable-element .monaco-tree-sticky-container:focus .monaco-list-row.focused { color: ${e.listFocusForeground}; }`),i.push(`.monaco-list${t}:not(.sticky-scroll-focused) .monaco-scrollable-element .monaco-tree-sticky-container .monaco-list-row.focused { color: inherit; }`));let r=_h(e.listFocusAndSelectionOutline,_h(e.listSelectionOutline,e.listFocusOutline??""));r&&(i.push(`.monaco-list${t}.sticky-scroll-focused .monaco-scrollable-element .monaco-tree-sticky-container:focus .monaco-list-row.focused.selected { outline: 1px solid ${r}; outline-offset: -1px;}`),i.push(`.monaco-list${t}:not(.sticky-scroll-focused) .monaco-scrollable-element .monaco-tree-sticky-container .monaco-list-row.focused.selected { outline: inherit;}`)),e.listFocusOutline&&(i.push(`.monaco-list${t}.sticky-scroll-focused .monaco-scrollable-element .monaco-tree-sticky-container:focus .monaco-list-row.focused { outline: 1px solid ${e.listFocusOutline}; outline-offset: -1px; }`),i.push(`.monaco-list${t}:not(.sticky-scroll-focused) .monaco-scrollable-element .monaco-tree-sticky-container .monaco-list-row.focused { outline: inherit; }`),i.push(`.monaco-workbench.context-menu-visible .monaco-list${t}.last-focused.sticky-scroll-focused .monaco-scrollable-element .monaco-tree-sticky-container .monaco-list-row.passive-focused { outline: 1px solid ${e.listFocusOutline}; outline-offset: -1px; }`),i.push(`.monaco-workbench.context-menu-visible .monaco-list${t}.last-focused.sticky-scroll-focused .monaco-list-rows .monaco-list-row.focused { outline: inherit; }`),i.push(`.monaco-workbench.context-menu-visible .monaco-list${t}.last-focused:not(.sticky-scroll-focused) .monaco-tree-sticky-container .monaco-list-rows .monaco-list-row.focused { outline: inherit; }`)),this.styleElement.textContent=i.join(` `),this.view.style(e)}getParentElement(e){let t=this.model.getParentNodeLocation(e);return this.model.getNode(t).element}getFirstElementChild(e){return this.model.getFirstElementChild(e)}getNode(e){return this.model.getNode(e)}getNodeLocation(e){return this.model.getNodeLocation(e)}collapse(e,t=!1){return this.model.setCollapsed(e,!0,t)}expand(e,t=!1){return this.model.setCollapsed(e,!1,t)}toggleCollapsed(e,t=!1){return this.model.setCollapsed(e,void 0,t)}isCollapsible(e){return this.model.isCollapsible(e)}setCollapsible(e,t){return this.model.setCollapsible(e,t)}isCollapsed(e){return this.model.isCollapsed(e)}refilter(){this._onWillRefilter.fire(void 0),this.model.refilter()}setSelection(e,t){this.eventBufferer.bufferEvents(()=>{let i=e.map(r=>this.model.getNode(r));this.selection.set(i,t);let o=e.map(r=>this.model.getListIndex(r)).filter(r=>r>-1);this.view.setSelection(o,t,!0)})}getSelection(){return this.selection.get()}setFocus(e,t){this.eventBufferer.bufferEvents(()=>{let i=e.map(r=>this.model.getNode(r));this.focus.set(i,t);let o=e.map(r=>this.model.getListIndex(r)).filter(r=>r>-1);this.view.setFocus(o,t,!0)})}focusNext(e=1,t=!1,i,o=mf(i)&&i.altKey?void 0:this.focusNavigationFilter){this.view.focusNext(e,t,i,o)}focusPrevious(e=1,t=!1,i,o=mf(i)&&i.altKey?void 0:this.focusNavigationFilter){this.view.focusPrevious(e,t,i,o)}focusNextPage(e,t=mf(e)&&e.altKey?void 0:this.focusNavigationFilter){return this.view.focusNextPage(e,t)}focusPreviousPage(e,t=mf(e)&&e.altKey?void 0:this.focusNavigationFilter){return this.view.focusPreviousPage(e,t,()=>this.stickyScrollController?.height??0)}focusLast(e,t=mf(e)&&e.altKey?void 0:this.focusNavigationFilter){this.view.focusLast(e,t)}focusFirst(e,t=mf(e)&&e.altKey?void 0:this.focusNavigationFilter){this.view.focusFirst(e,t)}getFocus(){return this.focus.get()}reveal(e,t){this.model.expandTo(e);let i=this.model.getListIndex(e);if(i!==-1)if(!this.stickyScrollController)this.view.reveal(i,t);else{let o=this.stickyScrollController.nodePositionTopBelowWidget(this.getNode(e));this.view.reveal(i,t,o)}}onLeftArrow(e){e.preventDefault(),e.stopPropagation();let t=this.view.getFocusedElements();if(t.length===0)return;let i=t[0],o=this.model.getNodeLocation(i);if(!this.model.setCollapsed(o,!0)){let s=this.model.getParentNodeLocation(o);if(!s)return;let a=this.model.getListIndex(s);this.view.reveal(a),this.view.setFocus([a])}}onRightArrow(e){e.preventDefault(),e.stopPropagation();let t=this.view.getFocusedElements();if(t.length===0)return;let i=t[0],o=this.model.getNodeLocation(i);if(!this.model.setCollapsed(o,!1)){if(!i.children.some(l=>l.visible))return;let[s]=this.view.getFocus(),a=s+1;this.view.reveal(a),this.view.setFocus([a])}}onSpace(e){e.preventDefault(),e.stopPropagation();let t=this.view.getFocusedElements();if(t.length===0)return;let i=t[0],o=this.model.getNodeLocation(i),r=e.browserEvent.altKey;this.model.setCollapsed(o,void 0,r)}dispose(){Yt(this.disposables),this.stickyScrollController?.dispose(),this.view.dispose()}}});var Cw,nz=k(()=>{JH();nE();Cl();Cw=class{constructor(e,t,i={}){this.user=e,this.rootRef=null,this.nodes=new Map,this.nodesByIdentity=new Map,this.model=new QH(e,t,null,i),this.onDidSplice=this.model.onDidSplice,this.onDidChangeCollapseState=this.model.onDidChangeCollapseState,this.onDidChangeRenderNodeCount=this.model.onDidChangeRenderNodeCount,i.sorter&&(this.sorter={compare(o,r){return i.sorter.compare(o.element,r.element)}}),this.identityProvider=i.identityProvider}setChildren(e,t=Dt.empty(),i={}){let o=this.getElementLocation(e);this._setChildren(o,this.preserveCollapseState(t),i)}_setChildren(e,t=Dt.empty(),i){let o=new Set,r=new Set,s=l=>{if(l.element===null)return;let c=l;if(o.add(c.element),this.nodes.set(c.element,c),this.identityProvider){let d=this.identityProvider.getId(c.element).toString();r.add(d),this.nodesByIdentity.set(d,c)}i.onDidCreateNode?.(c)},a=l=>{if(l.element===null)return;let c=l;if(o.has(c.element)||this.nodes.delete(c.element),this.identityProvider){let d=this.identityProvider.getId(c.element).toString();r.has(d)||this.nodesByIdentity.delete(d)}i.onDidDeleteNode?.(c)};this.model.splice([...e,0],Number.MAX_VALUE,t,{...i,onDidCreateNode:s,onDidDeleteNode:a})}preserveCollapseState(e=Dt.empty()){return this.sorter&&(e=[...e].sort(this.sorter.compare.bind(this.sorter))),Dt.map(e,t=>{let i=this.nodes.get(t.element);if(!i&&this.identityProvider){let s=this.identityProvider.getId(t.element).toString();i=this.nodesByIdentity.get(s)}if(!i){let s;return typeof t.collapsed>"u"?s=void 0:t.collapsed===td.Collapsed||t.collapsed===td.PreserveOrCollapsed?s=!0:t.collapsed===td.Expanded||t.collapsed===td.PreserveOrExpanded?s=!1:s=!!t.collapsed,{...t,children:this.preserveCollapseState(t.children),collapsed:s}}let o=typeof t.collapsible=="boolean"?t.collapsible:i.collapsible,r;return typeof t.collapsed>"u"||t.collapsed===td.PreserveOrCollapsed||t.collapsed===td.PreserveOrExpanded?r=i.collapsed:t.collapsed===td.Collapsed?r=!0:t.collapsed===td.Expanded?r=!1:r=!!t.collapsed,{...t,collapsible:o,collapsed:r,children:this.preserveCollapseState(t.children)}})}rerender(e){let t=this.getElementLocation(e);this.model.rerender(t)}getFirstElementChild(e=null){let t=this.getElementLocation(e);return this.model.getFirstElementChild(t)}has(e){return this.nodes.has(e)}getListIndex(e){let t=this.getElementLocation(e);return this.model.getListIndex(t)}getListRenderCount(e){let t=this.getElementLocation(e);return this.model.getListRenderCount(t)}isCollapsible(e){let t=this.getElementLocation(e);return this.model.isCollapsible(t)}setCollapsible(e,t){let i=this.getElementLocation(e);return this.model.setCollapsible(i,t)}isCollapsed(e){let t=this.getElementLocation(e);return this.model.isCollapsed(t)}setCollapsed(e,t,i){let o=this.getElementLocation(e);return this.model.setCollapsed(o,t,i)}expandTo(e){let t=this.getElementLocation(e);this.model.expandTo(t)}refilter(){this.model.refilter()}getNode(e=null){if(e===null)return this.model.getNode(this.model.rootRef);let t=this.nodes.get(e);if(!t)throw new ka(this.user,`Tree element not found: ${e}`);return t}getNodeLocation(e){return e.element}getParentNodeLocation(e){if(e===null)throw new ka(this.user,"Invalid getParentNodeLocation call");let t=this.nodes.get(e);if(!t)throw new ka(this.user,`Tree element not found: ${e}`);let i=this.model.getNodeLocation(t),o=this.model.getParentNodeLocation(i);return this.model.getNode(o).element}getElementLocation(e){if(e===null)return[];let t=this.nodes.get(e);if(!t)throw new ka(this.user,`Tree element not found: ${e}`);return this.model.getNodeLocation(t)}}});function oz(n){let e=[n.element],t=n.incompressible||!1;return{element:{elements:e,incompressible:t},children:Dt.map(Dt.from(n.children),oz),collapsible:n.collapsible,collapsed:n.collapsed}}function rz(n){let e=[n.element],t=n.incompressible||!1,i,o;for(;[o,i]=Dt.consume(Dt.from(n.children),2),!(o.length!==1||o[0].incompressible);)n=o[0],e.push(n.element);return{element:{elements:e,incompressible:t},children:Dt.map(Dt.concat(o,i),rz),collapsible:n.collapsible,collapsed:n.collapsed}}function tde(n,e=0){let t;return etde(i,0)),e===0&&n.element.incompressible?{element:n.element.elements[e],children:t,incompressible:!0,collapsible:n.collapsible,collapsed:n.collapsed}:{element:n.element.elements[e],children:t,collapsible:n.collapsible,collapsed:n.collapsed}}function AFe(n){return tde(n,0)}function MFe(n,e,t){return n.element===e?{...n,children:t}:{...n,children:Dt.map(Dt.from(n.children),i=>MFe(i,e,t))}}function mdt(n,e){return{splice(t,i,o){e.splice(t,i,o.map(r=>n.map(r)))},updateElementHeight(t,i){e.updateElementHeight(t,i)}}}function gdt(n,e){return{...e,identityProvider:e.identityProvider&&{getId(t){return e.identityProvider.getId(n(t))}},sorter:e.sorter&&{compare(t,i){return e.sorter.compare(t.elements[0],i.elements[0])}},filter:e.filter&&{filter(t,i){return e.filter.filter(n(t),i)}}}}var fdt,ide,pdt,nde,sz,PFe=k(()=>{nz();nE();at();Ie();Cl();fdt=n=>({getId(e){return e.elements.map(t=>n.getId(t).toString()).join("\0")}}),ide=class{get onDidSplice(){return this.model.onDidSplice}get onDidChangeCollapseState(){return this.model.onDidChangeCollapseState}get onDidChangeRenderNodeCount(){return this.model.onDidChangeRenderNodeCount}constructor(e,t,i={}){this.user=e,this.rootRef=null,this.nodes=new Map,this.model=new Cw(e,t,i),this.enabled=typeof i.compressionEnabled>"u"?!0:i.compressionEnabled,this.identityProvider=i.identityProvider}setChildren(e,t=Dt.empty(),i){let o=i.diffIdentityProvider&&fdt(i.diffIdentityProvider);if(e===null){let p=Dt.map(t,this.enabled?rz:oz);this._setChildren(null,p,{diffIdentityProvider:o,diffDepth:1/0});return}let r=this.nodes.get(e);if(!r)throw new ka(this.user,"Unknown compressed tree node");let s=this.model.getNode(r),a=this.model.getParentNodeLocation(r),l=this.model.getNode(a),c=AFe(s),d=MFe(c,e,t),u=(this.enabled?rz:oz)(d),h=i.diffIdentityProvider?(p,g)=>i.diffIdentityProvider.getId(p)===i.diffIdentityProvider.getId(g):void 0;if(oi(u.element.elements,s.element.elements,h)){this._setChildren(r,u.children||Dt.empty(),{diffIdentityProvider:o,diffDepth:1});return}let f=l.children.map(p=>p===s?u:p);this._setChildren(l.element,f,{diffIdentityProvider:o,diffDepth:s.depth-l.depth})}isCompressionEnabled(){return this.enabled}setCompressionEnabled(e){if(e===this.enabled)return;this.enabled=e;let i=this.model.getNode().children,o=Dt.map(i,AFe),r=Dt.map(o,e?rz:oz);this._setChildren(null,r,{diffIdentityProvider:this.identityProvider,diffDepth:1/0})}_setChildren(e,t,i){let o=new Set,r=a=>{for(let l of a.element.elements)o.add(l),this.nodes.set(l,a.element)},s=a=>{for(let l of a.element.elements)o.has(l)||this.nodes.delete(l)};this.model.setChildren(e,t,{...i,onDidCreateNode:r,onDidDeleteNode:s})}has(e){return this.nodes.has(e)}getListIndex(e){let t=this.getCompressedNode(e);return this.model.getListIndex(t)}getListRenderCount(e){let t=this.getCompressedNode(e);return this.model.getListRenderCount(t)}getNode(e){if(typeof e>"u")return this.model.getNode();let t=this.getCompressedNode(e);return this.model.getNode(t)}getNodeLocation(e){let t=this.model.getNodeLocation(e);return t===null?null:t.elements[t.elements.length-1]}getParentNodeLocation(e){let t=this.getCompressedNode(e),i=this.model.getParentNodeLocation(t);return i===null?null:i.elements[i.elements.length-1]}getFirstElementChild(e){let t=this.getCompressedNode(e);return this.model.getFirstElementChild(t)}isCollapsible(e){let t=this.getCompressedNode(e);return this.model.isCollapsible(t)}setCollapsible(e,t){let i=this.getCompressedNode(e);return this.model.setCollapsible(i,t)}isCollapsed(e){let t=this.getCompressedNode(e);return this.model.isCollapsed(t)}setCollapsed(e,t,i){let o=this.getCompressedNode(e);return this.model.setCollapsed(o,t,i)}expandTo(e){let t=this.getCompressedNode(e);this.model.expandTo(t)}rerender(e){let t=this.getCompressedNode(e);this.model.rerender(t)}refilter(){this.model.refilter()}getCompressedNode(e){if(e===null)return null;let t=this.nodes.get(e);if(!t)throw new ka(this.user,`Tree element not found: ${e}`);return t}},pdt=n=>n[n.length-1],nde=class n{get element(){return this.node.element===null?null:this.unwrapper(this.node.element)}get children(){return this.node.children.map(e=>new n(this.unwrapper,e))}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}constructor(e,t){this.unwrapper=e,this.node=t}};sz=class{get onDidSplice(){return ne.map(this.model.onDidSplice,({insertedNodes:e,deletedNodes:t})=>({insertedNodes:e.map(i=>this.nodeMapper.map(i)),deletedNodes:t.map(i=>this.nodeMapper.map(i))}))}get onDidChangeCollapseState(){return ne.map(this.model.onDidChangeCollapseState,({node:e,deep:t})=>({node:this.nodeMapper.map(e),deep:t}))}get onDidChangeRenderNodeCount(){return ne.map(this.model.onDidChangeRenderNodeCount,e=>this.nodeMapper.map(e))}constructor(e,t,i={}){this.rootRef=null,this.elementMapper=i.elementMapper||pdt;let o=r=>this.elementMapper(r.elements);this.nodeMapper=new VC(r=>new nde(o,r)),this.model=new ide(e,mdt(this.nodeMapper,t),gdt(o,i))}setChildren(e,t=Dt.empty(),i={}){this.model.setChildren(e,t,i)}isCompressionEnabled(){return this.model.isCompressionEnabled()}setCompressionEnabled(e){this.model.setCompressionEnabled(e)}has(e){return this.model.has(e)}getListIndex(e){return this.model.getListIndex(e)}getListRenderCount(e){return this.model.getListRenderCount(e)}getNode(e){return this.nodeMapper.map(this.model.getNode(e))}getNodeLocation(e){return e.element}getParentNodeLocation(e){return this.model.getParentNodeLocation(e)}getFirstElementChild(e){let t=this.model.getFirstElementChild(e);return t===null||typeof t>"u"?t:this.elementMapper(t.elements)}isCollapsible(e){return this.model.isCollapsible(e)}setCollapsible(e,t){return this.model.setCollapsible(e,t)}isCollapsed(e){return this.model.isCollapsed(e)}setCollapsed(e,t,i){return this.model.setCollapsed(e,t,i)}expandTo(e){return this.model.expandTo(e)}rerender(e){return this.model.rerender(e)}refilter(){return this.model.refilter()}getCompressedTreeNode(e=null){return this.model.getNode(e)}}});function bdt(n,e){return e&&{...e,keyboardNavigationLabelProvider:e.keyboardNavigationLabelProvider&&{getKeyboardNavigationLabel(t){let i;try{i=n().getCompressedTreeNode(t)}catch{return e.keyboardNavigationLabelProvider.getKeyboardNavigationLabel(t)}return i.element.elements.length===1?e.keyboardNavigationLabelProvider.getKeyboardNavigationLabel(t):e.keyboardNavigationLabelProvider.getCompressedNodeKeyboardNavigationLabel(i.element.elements)}}}}var _dt,jC,az,ode,aE,rde=k(()=>{sE();PFe();nz();Yx();Cl();_dt=function(n,e,t,i){var o=arguments.length,r=o<3?e:i===null?i=Object.getOwnPropertyDescriptor(e,t):i,s;if(typeof Reflect=="object"&&typeof Reflect.decorate=="function")r=Reflect.decorate(n,e,t,i);else for(var a=n.length-1;a>=0;a--)(s=n[a])&&(r=(o<3?s(r):o>3?s(e,t,r):s(e,t))||r);return o>3&&r&&Object.defineProperty(e,t,r),r},jC=class extends rE{get onDidChangeCollapseState(){return this.model.onDidChangeCollapseState}constructor(e,t,i,o,r={}){super(e,t,i,o,r),this.user=e}setChildren(e,t=Dt.empty(),i){this.model.setChildren(e,t,i)}rerender(e){if(e===void 0){this.view.rerender();return}this.model.rerender(e)}hasElement(e){return this.model.has(e)}createModel(e,t,i){return new Cw(e,t,i)}},az=class{get compressedTreeNodeProvider(){return this._compressedTreeNodeProvider()}constructor(e,t,i){this._compressedTreeNodeProvider=e,this.stickyScrollDelegate=t,this.renderer=i,this.templateId=i.templateId,i.onDidChangeTwistieState&&(this.onDidChangeTwistieState=i.onDidChangeTwistieState)}renderTemplate(e){return{compressedTreeNode:void 0,data:this.renderer.renderTemplate(e)}}renderElement(e,t,i,o){let r=this.stickyScrollDelegate.getCompressedNode(e);r||(r=this.compressedTreeNodeProvider.getCompressedTreeNode(e.element)),r.element.elements.length===1?(i.compressedTreeNode=void 0,this.renderer.renderElement(e,t,i.data,o)):(i.compressedTreeNode=r,this.renderer.renderCompressedElements(r,t,i.data,o))}disposeElement(e,t,i,o){i.compressedTreeNode?this.renderer.disposeCompressedElements?.(i.compressedTreeNode,t,i.data,o):this.renderer.disposeElement?.(e,t,i.data,o)}disposeTemplate(e){this.renderer.disposeTemplate(e.data)}renderTwistie(e,t){return this.renderer.renderTwistie?this.renderer.renderTwistie(e,t):!1}};_dt([Hn],az.prototype,"compressedTreeNodeProvider",null);ode=class{constructor(e){this.modelProvider=e,this.compressedStickyNodes=new Map}getCompressedNode(e){return this.compressedStickyNodes.get(e)}constrainStickyScrollNodes(e,t,i){if(this.compressedStickyNodes.clear(),e.length===0)return[];for(let o=0;oi||o>=t-1&&tthis,a=new ode(()=>this.model),l=o.map(c=>new az(s,a,c));super(e,t,i,l,{...bdt(s,r),stickyScrollDelegate:a})}setChildren(e,t=Dt.empty(),i){this.model.setChildren(e,t,i)}createModel(e,t,i){return new sz(e,t,i)}updateOptions(e={}){super.updateOptions(e),typeof e.compressionEnabled<"u"&&this.model.setCompressionEnabled(e.compressionEnabled)}getCompressedTreeNode(e=null){return this.model.getCompressedTreeNode(e)}}});function sde(n){return{...n,children:[],refreshPromise:void 0,stale:!0,slow:!1,forceExpanded:!1}}function lde(n,e){return e.parent?e.parent===n?!0:lde(n,e.parent):!1}function vdt(n,e){return n===e||lde(n,e)||lde(e,n)}function OFe(n){return{browserEvent:n.browserEvent,elements:n.elements.map(e=>e.element)}}function FFe(n){return{browserEvent:n.browserEvent,element:n.element&&n.element.element,target:n.target}}function ade(n){return n instanceof _b?new ude(n):n}function BFe(n){return n&&{...n,collapseByDefault:!0,identityProvider:n.identityProvider&&{getId(e){return n.identityProvider.getId(e.element)}},dnd:n.dnd&&new hde(n.dnd),multipleSelectionController:n.multipleSelectionController&&{isSelectionSingleChangeEvent(e){return n.multipleSelectionController.isSelectionSingleChangeEvent({...e,element:e.element})},isSelectionRangeChangeEvent(e){return n.multipleSelectionController.isSelectionRangeChangeEvent({...e,element:e.element})}},accessibilityProvider:n.accessibilityProvider&&{...n.accessibilityProvider,getPosInSet:void 0,getSetSize:void 0,getRole:n.accessibilityProvider.getRole?e=>n.accessibilityProvider.getRole(e.element):()=>"treeitem",isChecked:n.accessibilityProvider.isChecked?e=>!!n.accessibilityProvider?.isChecked(e.element):void 0,getAriaLabel(e){return n.accessibilityProvider.getAriaLabel(e.element)},getWidgetAriaLabel(){return n.accessibilityProvider.getWidgetAriaLabel()},getWidgetRole:n.accessibilityProvider.getWidgetRole?()=>n.accessibilityProvider.getWidgetRole():()=>"tree",getAriaLevel:n.accessibilityProvider.getAriaLevel&&(e=>n.accessibilityProvider.getAriaLevel(e.element)),getActiveDescendantId:n.accessibilityProvider.getActiveDescendantId&&(e=>n.accessibilityProvider.getActiveDescendantId(e.element))},filter:n.filter&&{filter(e,t){return n.filter.filter(e.element,t)}},keyboardNavigationLabelProvider:n.keyboardNavigationLabelProvider&&{...n.keyboardNavigationLabelProvider,getKeyboardNavigationLabel(e){return n.keyboardNavigationLabelProvider.getKeyboardNavigationLabel(e.element)}},sorter:void 0,expandOnlyOnTwistieClick:typeof n.expandOnlyOnTwistieClick>"u"?void 0:typeof n.expandOnlyOnTwistieClick!="function"?n.expandOnlyOnTwistieClick:e=>n.expandOnlyOnTwistieClick(e.element),defaultFindVisibility:e=>e.hasChildren&&e.stale?1:typeof n.defaultFindVisibility=="number"?n.defaultFindVisibility:typeof n.defaultFindVisibility>"u"?2:n.defaultFindVisibility(e.element)}}function fde(n,e){e(n),n.children.forEach(t=>fde(t,e))}function xdt(n){let e=n&&BFe(n);return e&&{...e,keyboardNavigationLabelProvider:e.keyboardNavigationLabelProvider&&{...e.keyboardNavigationLabelProvider,getCompressedNodeKeyboardNavigationLabel(t){return n.keyboardNavigationLabelProvider.getCompressedNodeKeyboardNavigationLabel(t.map(i=>i.element))}}}}function wdt(n){return typeof n=="boolean"?n?1:0:k2(n)?UC(n.visibility):UC(n)}var cde,dde,ude,hde,I2,pde,mde,lz,WFe=k(()=>{aW();sE();JH();rde();nE();ft();Qi();bn();je();Ie();Cl();j();yi();cde=class n{get element(){return this.node.element.element}get children(){return this.node.children.map(e=>new n(e))}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}constructor(e){this.node=e}},dde=class{constructor(e,t,i){this.renderer=e,this.nodeMapper=t,this.onDidChangeTwistieState=i,this.renderedNodes=new Map,this.templateId=e.templateId}renderTemplate(e){return{templateData:this.renderer.renderTemplate(e)}}renderElement(e,t,i,o){this.renderer.renderElement(this.nodeMapper.map(e),t,i.templateData,o)}renderTwistie(e,t){return e.slow?(t.classList.add(...Oe.asClassNameArray(oe.treeItemLoading)),!0):(t.classList.remove(...Oe.asClassNameArray(oe.treeItemLoading)),!1)}disposeElement(e,t,i,o){this.renderer.disposeElement?.(this.nodeMapper.map(e),t,i.templateData,o)}disposeTemplate(e){this.renderer.disposeTemplate(e.templateData)}dispose(){this.renderedNodes.clear()}};ude=class extends _b{constructor(e){super(e.elements.map(t=>t.element)),this.data=e}};hde=class{constructor(e){this.dnd=e}getDragURI(e){return this.dnd.getDragURI(e.element)}getDragLabel(e,t){if(this.dnd.getDragLabel)return this.dnd.getDragLabel(e.map(i=>i.element),t)}onDragStart(e,t){this.dnd.onDragStart?.(ade(e),t)}onDragOver(e,t,i,o,r,s=!0){return this.dnd.onDragOver(ade(e),t&&t.element,i,o,r)}drop(e,t,i,o,r){this.dnd.drop(ade(e),t&&t.element,i,o,r)}onDragEnd(e){this.dnd.onDragEnd?.(e)}dispose(){this.dnd.dispose()}};I2=class{get onDidScroll(){return this.tree.onDidScroll}get onDidChangeFocus(){return ne.map(this.tree.onDidChangeFocus,OFe)}get onDidChangeSelection(){return ne.map(this.tree.onDidChangeSelection,OFe)}get onMouseDblClick(){return ne.map(this.tree.onMouseDblClick,FFe)}get onPointer(){return ne.map(this.tree.onPointer,FFe)}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 onDidChangeStickyScrollFocused(){return this.tree.onDidChangeStickyScrollFocused}get onDidDispose(){return this.tree.onDidDispose}constructor(e,t,i,o,r,s={}){this.user=e,this.dataSource=r,this.nodes=new Map,this.subTreeRefreshPromises=new Map,this.refreshPromises=new Map,this._onDidRender=new A,this._onDidChangeNodeSlowState=new A,this.nodeMapper=new VC(a=>new cde(a)),this.disposables=new H,this.identityProvider=s.identityProvider,this.autoExpandSingleChildren=typeof s.autoExpandSingleChildren>"u"?!1:s.autoExpandSingleChildren,this.sorter=s.sorter,this.getDefaultCollapseState=a=>s.collapseByDefault?s.collapseByDefault(a)?td.PreserveOrCollapsed:td.PreserveOrExpanded:void 0,this.tree=this.createTree(e,t,i,o,s),this.onDidChangeFindMode=this.tree.onDidChangeFindMode,this.onDidChangeFindMatchType=this.tree.onDidChangeFindMatchType,this.root=sde({element:void 0,parent:null,hasChildren:!0,defaultCollapseState:void 0}),this.identityProvider&&(this.root={...this.root,id:null}),this.nodes.set(null,this.root),this.tree.onDidChangeCollapseState(this._onDidChangeCollapseState,this,this.disposables)}createTree(e,t,i,o,r){let s=new oE(i),a=o.map(c=>new dde(c,this.nodeMapper,this._onDidChangeNodeSlowState.event)),l=BFe(r)||{};return new jC(e,t,s,a,l)}updateOptions(e={}){this.tree.updateOptions(e)}getHTMLElement(){return this.tree.getHTMLElement()}get scrollTop(){return this.tree.scrollTop}set scrollTop(e){this.tree.scrollTop=e}get scrollHeight(){return this.tree.scrollHeight}get renderHeight(){return this.tree.renderHeight}domFocus(){this.tree.domFocus()}layout(e,t){this.tree.layout(e,t)}style(e){this.tree.style(e)}getInput(){return this.root.element}async setInput(e,t){this.refreshPromises.forEach(o=>o.cancel()),this.refreshPromises.clear(),this.root.element=e;let i=t&&{viewState:t,focus:[],selection:[]};await this._updateChildren(e,!0,!1,i),i&&(this.tree.setFocus(i.focus),this.tree.setSelection(i.selection)),t&&typeof t.scrollTop=="number"&&(this.scrollTop=t.scrollTop)}async _updateChildren(e=this.root.element,t=!0,i=!1,o,r){if(typeof this.root.element>"u")throw new ka(this.user,"Tree input not set");this.root.refreshPromise&&(await this.root.refreshPromise,await ne.toPromise(this._onDidRender.event));let s=this.getDataNode(e);if(await this.refreshAndRenderNode(s,t,o,r),i)try{this.tree.rerender(s)}catch{}}rerender(e){if(e===void 0||e===this.root.element){this.tree.rerender();return}let t=this.getDataNode(e);this.tree.rerender(t)}getNode(e=this.root.element){let t=this.getDataNode(e),i=this.tree.getNode(t===this.root?null:t);return this.nodeMapper.map(i)}collapse(e,t=!1){let i=this.getDataNode(e);return this.tree.collapse(i===this.root?null:i,t)}async expand(e,t=!1){if(typeof this.root.element>"u")throw new ka(this.user,"Tree input not set");this.root.refreshPromise&&(await this.root.refreshPromise,await ne.toPromise(this._onDidRender.event));let i=this.getDataNode(e);if(this.tree.hasElement(i)&&!this.tree.isCollapsible(i)||(i.refreshPromise&&(await this.root.refreshPromise,await ne.toPromise(this._onDidRender.event)),i!==this.root&&!i.refreshPromise&&!this.tree.isCollapsed(i)))return!1;let o=this.tree.expand(i===this.root?null:i,t);return i.refreshPromise&&(await this.root.refreshPromise,await ne.toPromise(this._onDidRender.event)),o}setSelection(e,t){let i=e.map(o=>this.getDataNode(o));this.tree.setSelection(i,t)}getSelection(){return this.tree.getSelection().map(t=>t.element)}setFocus(e,t){let i=e.map(o=>this.getDataNode(o));this.tree.setFocus(i,t)}getFocus(){return this.tree.getFocus().map(t=>t.element)}reveal(e,t){this.tree.reveal(this.getDataNode(e),t)}getParentElement(e){let t=this.tree.getParentElement(this.getDataNode(e));return t&&t.element}getFirstElementChild(e=this.root.element){let t=this.getDataNode(e),i=this.tree.getFirstElementChild(t===this.root?null:t);return i&&i.element}getDataNode(e){let t=this.nodes.get(e===this.root.element?null:e);if(!t)throw new ka(this.user,`Data tree node not found: ${e}`);return t}async refreshAndRenderNode(e,t,i,o){await this.refreshNode(e,t,i),!this.disposables.isDisposed&&this.render(e,i,o)}async refreshNode(e,t,i){let o;if(this.subTreeRefreshPromises.forEach((r,s)=>{!o&&vdt(s,e)&&(o=r.then(()=>this.refreshNode(e,t,i)))}),o)return o;if(e!==this.root&&this.tree.getNode(e).collapsed){e.hasChildren=!!this.dataSource.hasChildren(e.element),e.stale=!0,this.setChildren(e,[],t,i);return}return this.doRefreshSubTree(e,t,i)}async doRefreshSubTree(e,t,i){let o;e.refreshPromise=new Promise(r=>o=r),this.subTreeRefreshPromises.set(e,e.refreshPromise),e.refreshPromise.finally(()=>{e.refreshPromise=void 0,this.subTreeRefreshPromises.delete(e)});try{let r=await this.doRefreshNode(e,t,i);e.stale=!1,await vB.settled(r.map(s=>this.doRefreshSubTree(s,t,i)))}finally{o()}}async doRefreshNode(e,t,i){e.hasChildren=!!this.dataSource.hasChildren(e.element);let o;if(!e.hasChildren)o=Promise.resolve(Dt.empty());else{let r=this.doGetChildren(e);if(vie(r))o=Promise.resolve(r);else{let s=oc(800);s.then(()=>{e.slow=!0,this._onDidChangeNodeSlowState.fire(e)},a=>null),o=r.finally(()=>s.cancel())}}try{let r=await o;return this.setChildren(e,r,t,i)}catch(r){if(e!==this.root&&this.tree.hasElement(e)&&this.tree.collapse(e),$r(r))return[];throw r}finally{e.slow&&(e.slow=!1,this._onDidChangeNodeSlowState.fire(e))}}doGetChildren(e){let t=this.refreshPromises.get(e);if(t)return t;let i=this.dataSource.getChildren(e.element);return vie(i)?this.processChildren(i):(t=sn(async()=>this.processChildren(await i)),this.refreshPromises.set(e,t),t.finally(()=>{this.refreshPromises.delete(e)}))}_onDidChangeCollapseState({node:e,deep:t}){e.element!==null&&!e.collapsed&&e.element.stale&&(t?this.collapse(e.element.element):this.refreshAndRenderNode(e.element,!1).catch(Be))}setChildren(e,t,i,o){let r=[...t];if(e.children.length===0&&r.length===0)return[];let s=new Map,a=new Map;for(let d of e.children)s.set(d.element,d),this.identityProvider&&a.set(d.id,{node:d,collapsed:this.tree.hasElement(d)&&this.tree.isCollapsed(d)});let l=[],c=r.map(d=>{let u=!!this.dataSource.hasChildren(d);if(!this.identityProvider){let g=sde({element:d,parent:e,hasChildren:u,defaultCollapseState:this.getDefaultCollapseState(d)});return u&&g.defaultCollapseState===td.PreserveOrExpanded&&l.push(g),g}let h=this.identityProvider.getId(d).toString(),f=a.get(h);if(f){let g=f.node;return s.delete(g.element),this.nodes.delete(g.element),this.nodes.set(d,g),g.element=d,g.hasChildren=u,i?f.collapsed?(g.children.forEach(_=>fde(_,b=>this.nodes.delete(b.element))),g.children.splice(0,g.children.length),g.stale=!0):l.push(g):u&&!f.collapsed&&l.push(g),g}let p=sde({element:d,parent:e,id:h,hasChildren:u,defaultCollapseState:this.getDefaultCollapseState(d)});return o&&o.viewState.focus&&o.viewState.focus.indexOf(h)>-1&&o.focus.push(p),o&&o.viewState.selection&&o.viewState.selection.indexOf(h)>-1&&o.selection.push(p),(o&&o.viewState.expanded&&o.viewState.expanded.indexOf(h)>-1||u&&p.defaultCollapseState===td.PreserveOrExpanded)&&l.push(p),p});for(let d of s.values())fde(d,u=>this.nodes.delete(u.element));for(let d of c)this.nodes.set(d.element,d);return e.children.splice(0,e.children.length,...c),e!==this.root&&this.autoExpandSingleChildren&&c.length===1&&l.length===0&&(c[0].forceExpanded=!0,l.push(c[0])),l}render(e,t,i){let o=e.children.map(s=>this.asTreeElement(s,t)),r=i&&{...i,diffIdentityProvider:i.diffIdentityProvider&&{getId(s){return i.diffIdentityProvider.getId(s.element)}}};this.tree.setChildren(e===this.root?null:e,o,r),e!==this.root&&this.tree.setCollapsible(e,e.hasChildren),this._onDidRender.fire()}asTreeElement(e,t){if(e.stale)return{element:e,collapsible:e.hasChildren,collapsed:!0};let i;return t&&t.viewState.expanded&&e.id&&t.viewState.expanded.indexOf(e.id)>-1?i=!1:e.forceExpanded?(i=!1,e.forceExpanded=!1):i=e.defaultCollapseState,{element:e,children:e.hasChildren?Dt.map(e.children,o=>this.asTreeElement(o,t)):[],collapsible:e.hasChildren,collapsed:i}}processChildren(e){return this.sorter&&(e=[...e].sort(this.sorter.compare.bind(this.sorter))),e}dispose(){this.disposables.dispose(),this.tree.dispose()}},pde=class n{get element(){return{elements:this.node.element.elements.map(e=>e.element),incompressible:this.node.element.incompressible}}get children(){return this.node.children.map(e=>new n(e))}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}constructor(e){this.node=e}},mde=class{constructor(e,t,i,o){this.renderer=e,this.nodeMapper=t,this.compressibleNodeMapperProvider=i,this.onDidChangeTwistieState=o,this.renderedNodes=new Map,this.disposables=[],this.templateId=e.templateId}renderTemplate(e){return{templateData:this.renderer.renderTemplate(e)}}renderElement(e,t,i,o){this.renderer.renderElement(this.nodeMapper.map(e),t,i.templateData,o)}renderCompressedElements(e,t,i,o){this.renderer.renderCompressedElements(this.compressibleNodeMapperProvider().map(e),t,i.templateData,o)}renderTwistie(e,t){return e.slow?(t.classList.add(...Oe.asClassNameArray(oe.treeItemLoading)),!0):(t.classList.remove(...Oe.asClassNameArray(oe.treeItemLoading)),!1)}disposeElement(e,t,i,o){this.renderer.disposeElement?.(this.nodeMapper.map(e),t,i.templateData,o)}disposeCompressedElements(e,t,i,o){this.renderer.disposeCompressedElements?.(this.compressibleNodeMapperProvider().map(e),t,i.templateData,o)}disposeTemplate(e){this.renderer.disposeTemplate(e.templateData)}dispose(){this.renderedNodes.clear(),this.disposables=Yt(this.disposables)}};lz=class extends I2{constructor(e,t,i,o,r,s,a={}){super(e,t,i,r,s,a),this.compressionDelegate=o,this.compressibleNodeMapper=new VC(l=>new pde(l)),this.filter=a.filter}createTree(e,t,i,o,r){let s=new oE(i),a=o.map(c=>new mde(c,this.nodeMapper,()=>this.compressibleNodeMapper,this._onDidChangeNodeSlowState.event)),l=xdt(r)||{};return new aE(e,t,s,a,l)}asTreeElement(e,t){return{incompressible:this.compressionDelegate.isIncompressible(e.element),...super.asTreeElement(e,t)}}updateOptions(e={}){this.tree.updateOptions(e)}render(e,t,i){if(!this.identityProvider)return super.render(e,t);let o=f=>this.identityProvider.getId(f).toString(),r=f=>{let p=new Set;for(let g of f){let _=this.tree.getCompressedTreeNode(g===this.root?null:g);if(_.element)for(let b of _.element.elements)p.add(o(b.element))}return p},s=r(this.tree.getSelection()),a=r(this.tree.getFocus());super.render(e,t,i);let l=this.getSelection(),c=!1,d=this.getFocus(),u=!1,h=f=>{let p=f.element;if(p)for(let g=0;g{let i=this.filter.filter(t,1),o=wdt(i);if(o===2)throw new Error("Recursive tree visibility not supported in async data compressed trees");return o===1})),super.processChildren(e)}}});var cz,HFe=k(()=>{sE();nz();cz=class extends rE{constructor(e,t,i,o,r,s={}){super(e,t,i,o,s),this.user=e,this.dataSource=r,this.identityProvider=s.identityProvider}createModel(e,t,i){return new Cw(e,t,i)}}});var Bdi,Wdi,E2,gde,Hdi,zdi,Vdi,Udi,$di,_de,dz,lE=k(()=>{Bt();pe();it();Bdi=new me("isMac",dt,m("isMac","Whether the operating system is macOS")),Wdi=new me("isLinux",Qn,m("isLinux","Whether the operating system is Linux")),E2=new me("isWindows",kn,m("isWindows","Whether the operating system is Windows")),gde=new me("isWeb",df,m("isWeb","Whether the platform is a web browser")),Hdi=new me("isMacNative",dt&&!df,m("isMacNative","Whether the operating system is macOS on a non-browser platform")),zdi=new me("isIOS",Xa,m("isIOS","Whether the operating system is iOS")),Vdi=new me("isMobile",O3,m("isMobile","Whether the platform is a mobile web browser")),Udi=new me("isDevelopment",!1,!0),$di=new me("productQualityType","",m("productQualityType","Quality type of VS Code")),_de="inputFocus",dz=new me(_de,!1,m("inputFocus","Whether keyboard focus is inside an input box"))});function kz(n,e){let t=n.createScoped(e.getHTMLElement());return KFe.bindTo(t),t}function Lz(n,e){let t=T2.bindTo(n),i=()=>{let o=e.scrollTop===0,r=e.scrollHeight-e.renderHeight-e.scrollTop<1;o&&r?t.set("both"):o?t.set("top"):r?t.set("bottom"):t.set("none")};return i(),e.onDidScroll(i)}function Dg(n){return n.getValue(KC)==="alt"}function Iz(n,e){let t=n.get(Ve),i=n.get(_t),o=new H;return[{...e,keyboardNavigationDelegate:{mightProducePrintableCharacter(s){return i.mightProducePrintableCharacter(s)}},smoothScrolling:!!t.getValue(Np),mouseWheelScrollSensitivity:t.getValue(Eg),fastScrollSensitivity:t.getValue(Tg),multipleSelectionController:e.multipleSelectionController??o.add(new bde(t)),keyboardNavigationEventFilter:Ldt(i),scrollByPage:!!t.getValue(Dp)},o]}function Ldt(n){let e=!1;return t=>{if(t.toKeyCodeChord().isModifierKey())return!1;if(e)return e=!1,!1;let i=n.softDispatch(t,t.target);return i.kind===1?(e=!0,!1):(e=!1,i.kind===0)}}function XFe(n){let e=n.getValue(kde);if(e==="highlight")return Ig.Highlight;if(e==="filter")return Ig.Filter;let t=n.getValue(fz);if(t==="simple"||t==="highlight")return Ig.Highlight;if(t==="filter")return Ig.Filter}function QFe(n){let e=n.getValue(Ide);if(e==="fuzzy")return yw.Fuzzy;if(e==="contiguous")return yw.Contiguous}function R2(n,e){let t=n.get(Ve),i=n.get(dc),o=n.get(Le),r=n.get(he),s=()=>{let h=o.getContextKeyValue(YFe);if(h==="automatic")return Sp.Automatic;if(h==="trigger")return Sp.Trigger;if(o.getContextKeyValue(ZFe)===!1)return Sp.Trigger;let p=t.getValue(Lde);if(p==="automatic")return Sp.Automatic;if(p==="trigger")return Sp.Trigger},a=e.horizontalScrolling!==void 0?e.horizontalScrolling:!!t.getValue(Wh),[l,c]=r.invokeFunction(Iz,e),d=e.paddingBottom,u=e.renderIndentGuides!==void 0?e.renderIndentGuides:t.getValue(pz);return{getTypeNavigationMode:s,disposable:c,options:{keyboardSupport:!1,...l,indent:typeof t.getValue(D2)=="number"?t.getValue(D2):void 0,renderIndentGuides:u,smoothScrolling:!!t.getValue(Np),defaultFindMode:XFe(t),defaultFindMatchType:QFe(t),horizontalScrolling:a,scrollByPage:!!t.getValue(Dp),paddingBottom:d,hideTwistiesOfChildlessElements:e.hideTwistiesOfChildlessElements,expandOnlyOnTwistieClick:e.expandOnlyOnTwistieClick??t.getValue(mz)==="doubleClick",contextViewProvider:i,findWidgetStyles:fOe,enableStickyScroll:!!t.getValue(gz),stickyScrollMaxItemCount:Number(t.getValue(_z))}}}var Nb,jn,zd,hz,T2,hui,fui,KFe,GFe,wz,wde,yde,Cde,Sde,yz,ydt,Cz,Cdt,Sz,Sdt,kdt,YFe,ZFe,KC,uz,Wh,kde,Lde,fz,Dp,Ide,D2,pz,Np,Eg,Tg,mz,gz,_z,bde,zFe,VFe,UFe,N2,bz,vde,xde,vz,$Fe,jFe,xz,qFe,qC,Idt,A2=k(()=>{ke();kFe();xb();DFe();sE();WFe();HFe();rde();Ie();j();pe();en();Mm();it();lE();Al();Fe();Pn();br();pg();Nb=function(n,e,t,i){var o=arguments.length,r=o<3?e:i===null?i=Object.getOwnPropertyDescriptor(e,t):i,s;if(typeof Reflect=="object"&&typeof Reflect.decorate=="function")r=Reflect.decorate(n,e,t,i);else for(var a=n.length-1;a>=0;a--)(s=n[a])&&(r=(o<3?s(r):o>3?s(e,t,r):s(e,t))||r);return o>3&&r&&Object.defineProperty(e,t,r),r},jn=function(n,e){return function(t,i){e(t,i,n)}},zd=We("listService"),hz=class{get lastFocusedList(){return this._lastFocusedWidget}constructor(){this.disposables=new H,this.lists=[],this._lastFocusedWidget=void 0,this._hasCreatedStyleController=!1}setLastFocusedList(e){e!==this._lastFocusedWidget&&(this._lastFocusedWidget?.getHTMLElement().classList.remove("last-focused"),this._lastFocusedWidget=e,this._lastFocusedWidget?.getHTMLElement().classList.add("last-focused"))}register(e,t){if(this._hasCreatedStyleController||(this._hasCreatedStyleController=!0,new VM(qr(),"").style(wb)),this.lists.some(o=>o.widget===e))throw new Error("Cannot register the same widget multiple times");let i={widget:e,extraContextKeys:t};return this.lists.push(i),D1(e.getHTMLElement())&&this.setLastFocusedList(e),qs(e.onDidFocus(()=>this.setLastFocusedList(e)),ge(()=>this.lists.splice(this.lists.indexOf(i),1)),e.onDidDispose(()=>{this.lists=this.lists.filter(o=>o!==i),this._lastFocusedWidget===e&&this.setLastFocusedList(void 0)}))}dispose(){this.disposables.dispose()}},T2=new me("listScrollAtBoundary","none"),hui=Y.or(T2.isEqualTo("top"),T2.isEqualTo("both")),fui=Y.or(T2.isEqualTo("bottom"),T2.isEqualTo("both")),KFe=new me("listFocus",!0),GFe=new me("treestickyScrollFocused",!1),wz=new me("listSupportsMultiselect",!0),wde=Y.and(KFe,Y.not(_de),GFe.negate()),yde=new me("listHasSelectionOrFocus",!1),Cde=new me("listDoubleSelection",!1),Sde=new me("listMultiSelection",!1),yz=new me("listSelectionNavigation",!1),ydt=new me("listSupportsFind",!0),Cz=new me("treeElementCanCollapse",!1),Cdt=new me("treeElementHasParent",!1),Sz=new me("treeElementCanExpand",!1),Sdt=new me("treeElementHasChild",!1),kdt=new me("treeFindOpen",!1),YFe="listTypeNavigationMode",ZFe="listAutomaticKeyboardNavigation";KC="workbench.list.multiSelectModifier",uz="workbench.list.openMode",Wh="workbench.list.horizontalScrolling",kde="workbench.list.defaultFindMode",Lde="workbench.list.typeNavigationMode",fz="workbench.list.keyboardNavigation",Dp="workbench.list.scrollByPage",Ide="workbench.list.defaultFindMatchType",D2="workbench.tree.indent",pz="workbench.tree.renderIndentGuides",Np="workbench.list.smoothScrolling",Eg="workbench.list.mouseWheelScrollSensitivity",Tg="workbench.list.fastScrollSensitivity",mz="workbench.tree.expandMode",gz="workbench.tree.enableStickyScroll",_z="workbench.tree.stickyScrollMaxItemCount";bde=class extends D{constructor(e){super(),this.configurationService=e,this.useAltAsMultipleSelectionModifier=Dg(e),this.registerListeners()}registerListeners(){this._register(this.configurationService.onDidChangeConfiguration(e=>{e.affectsConfiguration(KC)&&(this.useAltAsMultipleSelectionModifier=Dg(this.configurationService))}))}isSelectionSingleChangeEvent(e){return this.useAltAsMultipleSelectionModifier?e.browserEvent.altKey:Qae(e)}isSelectionRangeChangeEvent(e){return Jae(e)}};zFe=class extends Xr{constructor(e,t,i,o,r,s,a,l,c){let d=typeof r.horizontalScrolling<"u"?r.horizontalScrolling:!!l.getValue(Wh),[u,h]=c.invokeFunction(Iz,r);super(e,t,i,o,{keyboardSupport:!1,...u,horizontalScrolling:d}),this.disposables.add(h),this.contextKeyService=kz(s,this),this.disposables.add(Lz(this.contextKeyService,this)),this.listSupportsMultiSelect=wz.bindTo(this.contextKeyService),this.listSupportsMultiSelect.set(r.multipleSelectionSupport!==!1),yz.bindTo(this.contextKeyService).set(!!r.selectionNavigation),this.listHasSelectionOrFocus=yde.bindTo(this.contextKeyService),this.listDoubleSelection=Cde.bindTo(this.contextKeyService),this.listMultiSelection=Sde.bindTo(this.contextKeyService),this.horizontalScrolling=r.horizontalScrolling,this._useAltAsMultipleSelectionModifier=Dg(l),this.disposables.add(this.contextKeyService),this.disposables.add(a.register(this)),this.updateStyles(r.overrideStyles),this.disposables.add(this.onDidChangeSelection(()=>{let p=this.getSelection(),g=this.getFocus();this.contextKeyService.bufferChangeEvents(()=>{this.listHasSelectionOrFocus.set(p.length>0||g.length>0),this.listMultiSelection.set(p.length>1),this.listDoubleSelection.set(p.length===2)})})),this.disposables.add(this.onDidChangeFocus(()=>{let p=this.getSelection(),g=this.getFocus();this.listHasSelectionOrFocus.set(p.length>0||g.length>0)})),this.disposables.add(l.onDidChangeConfiguration(p=>{p.affectsConfiguration(KC)&&(this._useAltAsMultipleSelectionModifier=Dg(l));let g={};if(p.affectsConfiguration(Wh)&&this.horizontalScrolling===void 0){let _=!!l.getValue(Wh);g={...g,horizontalScrolling:_}}if(p.affectsConfiguration(Dp)){let _=!!l.getValue(Dp);g={...g,scrollByPage:_}}if(p.affectsConfiguration(Np)){let _=!!l.getValue(Np);g={...g,smoothScrolling:_}}if(p.affectsConfiguration(Eg)){let _=l.getValue(Eg);g={...g,mouseWheelScrollSensitivity:_}}if(p.affectsConfiguration(Tg)){let _=l.getValue(Tg);g={...g,fastScrollSensitivity:_}}Object.keys(g).length>0&&this.updateOptions(g)})),this.navigator=new bz(this,{configurationService:l,...r}),this.disposables.add(this.navigator)}updateOptions(e){super.updateOptions(e),e.overrideStyles!==void 0&&this.updateStyles(e.overrideStyles),e.multipleSelectionSupport!==void 0&&this.listSupportsMultiSelect.set(!!e.multipleSelectionSupport)}updateStyles(e){this.style(e?Lp(e):wb)}};zFe=Nb([jn(5,Le),jn(6,zd),jn(7,Ve),jn(8,he)],zFe);VFe=class extends GH{constructor(e,t,i,o,r,s,a,l,c){let d=typeof r.horizontalScrolling<"u"?r.horizontalScrolling:!!l.getValue(Wh),[u,h]=c.invokeFunction(Iz,r);super(e,t,i,o,{keyboardSupport:!1,...u,horizontalScrolling:d}),this.disposables=new H,this.disposables.add(h),this.contextKeyService=kz(s,this),this.disposables.add(Lz(this.contextKeyService,this.widget)),this.horizontalScrolling=r.horizontalScrolling,this.listSupportsMultiSelect=wz.bindTo(this.contextKeyService),this.listSupportsMultiSelect.set(r.multipleSelectionSupport!==!1),yz.bindTo(this.contextKeyService).set(!!r.selectionNavigation),this._useAltAsMultipleSelectionModifier=Dg(l),this.disposables.add(this.contextKeyService),this.disposables.add(a.register(this)),this.updateStyles(r.overrideStyles),this.disposables.add(l.onDidChangeConfiguration(p=>{p.affectsConfiguration(KC)&&(this._useAltAsMultipleSelectionModifier=Dg(l));let g={};if(p.affectsConfiguration(Wh)&&this.horizontalScrolling===void 0){let _=!!l.getValue(Wh);g={...g,horizontalScrolling:_}}if(p.affectsConfiguration(Dp)){let _=!!l.getValue(Dp);g={...g,scrollByPage:_}}if(p.affectsConfiguration(Np)){let _=!!l.getValue(Np);g={...g,smoothScrolling:_}}if(p.affectsConfiguration(Eg)){let _=l.getValue(Eg);g={...g,mouseWheelScrollSensitivity:_}}if(p.affectsConfiguration(Tg)){let _=l.getValue(Tg);g={...g,fastScrollSensitivity:_}}Object.keys(g).length>0&&this.updateOptions(g)})),this.navigator=new bz(this,{configurationService:l,...r}),this.disposables.add(this.navigator)}updateOptions(e){super.updateOptions(e),e.overrideStyles!==void 0&&this.updateStyles(e.overrideStyles),e.multipleSelectionSupport!==void 0&&this.listSupportsMultiSelect.set(!!e.multipleSelectionSupport)}updateStyles(e){this.style(e?Lp(e):wb)}dispose(){this.disposables.dispose(),super.dispose()}};VFe=Nb([jn(5,Le),jn(6,zd),jn(7,Ve),jn(8,he)],VFe);UFe=class extends XH{constructor(e,t,i,o,r,s,a,l,c,d){let u=typeof s.horizontalScrolling<"u"?s.horizontalScrolling:!!c.getValue(Wh),[h,f]=d.invokeFunction(Iz,s);super(e,t,i,o,r,{keyboardSupport:!1,...h,horizontalScrolling:u}),this.disposables.add(f),this.contextKeyService=kz(a,this),this.disposables.add(Lz(this.contextKeyService,this)),this.listSupportsMultiSelect=wz.bindTo(this.contextKeyService),this.listSupportsMultiSelect.set(s.multipleSelectionSupport!==!1),yz.bindTo(this.contextKeyService).set(!!s.selectionNavigation),this.listHasSelectionOrFocus=yde.bindTo(this.contextKeyService),this.listDoubleSelection=Cde.bindTo(this.contextKeyService),this.listMultiSelection=Sde.bindTo(this.contextKeyService),this.horizontalScrolling=s.horizontalScrolling,this._useAltAsMultipleSelectionModifier=Dg(c),this.disposables.add(this.contextKeyService),this.disposables.add(l.register(this)),this.updateStyles(s.overrideStyles),this.disposables.add(this.onDidChangeSelection(()=>{let g=this.getSelection(),_=this.getFocus();this.contextKeyService.bufferChangeEvents(()=>{this.listHasSelectionOrFocus.set(g.length>0||_.length>0),this.listMultiSelection.set(g.length>1),this.listDoubleSelection.set(g.length===2)})})),this.disposables.add(this.onDidChangeFocus(()=>{let g=this.getSelection(),_=this.getFocus();this.listHasSelectionOrFocus.set(g.length>0||_.length>0)})),this.disposables.add(c.onDidChangeConfiguration(g=>{g.affectsConfiguration(KC)&&(this._useAltAsMultipleSelectionModifier=Dg(c));let _={};if(g.affectsConfiguration(Wh)&&this.horizontalScrolling===void 0){let b=!!c.getValue(Wh);_={..._,horizontalScrolling:b}}if(g.affectsConfiguration(Dp)){let b=!!c.getValue(Dp);_={..._,scrollByPage:b}}if(g.affectsConfiguration(Np)){let b=!!c.getValue(Np);_={..._,smoothScrolling:b}}if(g.affectsConfiguration(Eg)){let b=c.getValue(Eg);_={..._,mouseWheelScrollSensitivity:b}}if(g.affectsConfiguration(Tg)){let b=c.getValue(Tg);_={..._,fastScrollSensitivity:b}}Object.keys(_).length>0&&this.updateOptions(_)})),this.navigator=new vde(this,{configurationService:c,...s}),this.disposables.add(this.navigator)}updateOptions(e){super.updateOptions(e),e.overrideStyles!==void 0&&this.updateStyles(e.overrideStyles),e.multipleSelectionSupport!==void 0&&this.listSupportsMultiSelect.set(!!e.multipleSelectionSupport)}updateStyles(e){this.style(e?Lp(e):wb)}dispose(){this.disposables.dispose(),super.dispose()}};UFe=Nb([jn(6,Le),jn(7,zd),jn(8,Ve),jn(9,he)],UFe);N2=class extends D{constructor(e,t){super(),this.widget=e,this._onDidOpen=this._register(new A),this.onDidOpen=this._onDidOpen.event,this._register(ne.filter(this.widget.onDidChangeSelection,i=>mf(i.browserEvent))(i=>this.onSelectionFromKeyboard(i))),this._register(this.widget.onPointer(i=>this.onPointer(i.element,i.browserEvent))),this._register(this.widget.onMouseDblClick(i=>this.onMouseDblClick(i.element,i.browserEvent))),typeof t?.openOnSingleClick!="boolean"&&t?.configurationService?(this.openOnSingleClick=t?.configurationService.getValue(uz)!=="doubleClick",this._register(t?.configurationService.onDidChangeConfiguration(i=>{i.affectsConfiguration(uz)&&(this.openOnSingleClick=t?.configurationService.getValue(uz)!=="doubleClick")}))):this.openOnSingleClick=t?.openOnSingleClick??!0}onSelectionFromKeyboard(e){if(e.elements.length!==1)return;let t=e.browserEvent,i=typeof t.preserveFocus=="boolean"?t.preserveFocus:!0,o=typeof t.pinned=="boolean"?t.pinned:!i;this._open(this.getSelectedElement(),i,o,!1,e.browserEvent)}onPointer(e,t){if(!this.openOnSingleClick||t.detail===2)return;let o=t.button===1,r=!0,s=o,a=t.ctrlKey||t.metaKey||t.altKey;this._open(e,r,s,a,t)}onMouseDblClick(e,t){if(!t)return;let i=t.target;if(i.classList.contains("monaco-tl-twistie")||i.classList.contains("monaco-icon-label")&&i.classList.contains("folder-icon")&&t.offsetX<16)return;let r=!1,s=!0,a=t.ctrlKey||t.metaKey||t.altKey;this._open(e,r,s,a,t)}_open(e,t,i,o,r){e&&this._onDidOpen.fire({editorOptions:{preserveFocus:t,pinned:i,revealIfVisible:!0},sideBySide:o,element:e,browserEvent:r})}},bz=class extends N2{constructor(e,t){super(e,t),this.widget=e}getSelectedElement(){return this.widget.getSelectedElements()[0]}},vde=class extends N2{constructor(e,t){super(e,t)}getSelectedElement(){return this.widget.getSelectedElements()[0]}},xde=class extends N2{constructor(e,t){super(e,t)}getSelectedElement(){return this.widget.getSelection()[0]??void 0}};vz=class extends jC{constructor(e,t,i,o,r,s,a,l,c){let{options:d,getTypeNavigationMode:u,disposable:h}=s.invokeFunction(R2,r);super(e,t,i,o,d),this.disposables.add(h),this.internals=new qC(this,r,u,r.overrideStyles,a,l,c),this.disposables.add(this.internals)}updateOptions(e){super.updateOptions(e),this.internals.updateOptions(e)}};vz=Nb([jn(5,he),jn(6,Le),jn(7,zd),jn(8,Ve)],vz);$Fe=class extends aE{constructor(e,t,i,o,r,s,a,l,c){let{options:d,getTypeNavigationMode:u,disposable:h}=s.invokeFunction(R2,r);super(e,t,i,o,d),this.disposables.add(h),this.internals=new qC(this,r,u,r.overrideStyles,a,l,c),this.disposables.add(this.internals)}updateOptions(e={}){super.updateOptions(e),e.overrideStyles&&this.internals.updateStyleOverrides(e.overrideStyles),this.internals.updateOptions(e)}};$Fe=Nb([jn(5,he),jn(6,Le),jn(7,zd),jn(8,Ve)],$Fe);jFe=class extends cz{constructor(e,t,i,o,r,s,a,l,c,d){let{options:u,getTypeNavigationMode:h,disposable:f}=a.invokeFunction(R2,s);super(e,t,i,o,r,u),this.disposables.add(f),this.internals=new qC(this,s,h,s.overrideStyles,l,c,d),this.disposables.add(this.internals)}updateOptions(e={}){super.updateOptions(e),e.overrideStyles!==void 0&&this.internals.updateStyleOverrides(e.overrideStyles),this.internals.updateOptions(e)}};jFe=Nb([jn(6,he),jn(7,Le),jn(8,zd),jn(9,Ve)],jFe);xz=class extends I2{get onDidOpen(){return this.internals.onDidOpen}constructor(e,t,i,o,r,s,a,l,c,d){let{options:u,getTypeNavigationMode:h,disposable:f}=a.invokeFunction(R2,s);super(e,t,i,o,r,u),this.disposables.add(f),this.internals=new qC(this,s,h,s.overrideStyles,l,c,d),this.disposables.add(this.internals)}updateOptions(e={}){super.updateOptions(e),e.overrideStyles&&this.internals.updateStyleOverrides(e.overrideStyles),this.internals.updateOptions(e)}};xz=Nb([jn(6,he),jn(7,Le),jn(8,zd),jn(9,Ve)],xz);qFe=class extends lz{constructor(e,t,i,o,r,s,a,l,c,d,u){let{options:h,getTypeNavigationMode:f,disposable:p}=l.invokeFunction(R2,a);super(e,t,i,o,r,s,h),this.disposables.add(p),this.internals=new qC(this,a,f,a.overrideStyles,c,d,u),this.disposables.add(this.internals)}updateOptions(e){super.updateOptions(e),this.internals.updateOptions(e)}};qFe=Nb([jn(7,he),jn(8,Le),jn(9,zd),jn(10,Ve)],qFe);qC=class{get onDidOpen(){return this.navigator.onDidOpen}constructor(e,t,i,o,r,s,a){this.tree=e,this.disposables=[],this.contextKeyService=kz(r,e),this.disposables.push(Lz(this.contextKeyService,e)),this.listSupportsMultiSelect=wz.bindTo(this.contextKeyService),this.listSupportsMultiSelect.set(t.multipleSelectionSupport!==!1),yz.bindTo(this.contextKeyService).set(!!t.selectionNavigation),this.listSupportFindWidget=ydt.bindTo(this.contextKeyService),this.listSupportFindWidget.set(t.findWidgetEnabled??!0),this.hasSelectionOrFocus=yde.bindTo(this.contextKeyService),this.hasDoubleSelection=Cde.bindTo(this.contextKeyService),this.hasMultiSelection=Sde.bindTo(this.contextKeyService),this.treeElementCanCollapse=Cz.bindTo(this.contextKeyService),this.treeElementHasParent=Cdt.bindTo(this.contextKeyService),this.treeElementCanExpand=Sz.bindTo(this.contextKeyService),this.treeElementHasChild=Sdt.bindTo(this.contextKeyService),this.treeFindOpen=kdt.bindTo(this.contextKeyService),this.treeStickyScrollFocused=GFe.bindTo(this.contextKeyService),this._useAltAsMultipleSelectionModifier=Dg(a),this.updateStyleOverrides(o);let c=()=>{let u=e.getFocus()[0];if(!u)return;let h=e.getNode(u);this.treeElementCanCollapse.set(h.collapsible&&!h.collapsed),this.treeElementHasParent.set(!!e.getParentElement(u)),this.treeElementCanExpand.set(h.collapsible&&h.collapsed),this.treeElementHasChild.set(!!e.getFirstElementChild(u))},d=new Set;d.add(YFe),d.add(ZFe),this.disposables.push(this.contextKeyService,s.register(e),e.onDidChangeSelection(()=>{let u=e.getSelection(),h=e.getFocus();this.contextKeyService.bufferChangeEvents(()=>{this.hasSelectionOrFocus.set(u.length>0||h.length>0),this.hasMultiSelection.set(u.length>1),this.hasDoubleSelection.set(u.length===2)})}),e.onDidChangeFocus(()=>{let u=e.getSelection(),h=e.getFocus();this.hasSelectionOrFocus.set(u.length>0||h.length>0),c()}),e.onDidChangeCollapseState(c),e.onDidChangeModel(c),e.onDidChangeFindOpenState(u=>this.treeFindOpen.set(u)),e.onDidChangeStickyScrollFocused(u=>this.treeStickyScrollFocused.set(u)),a.onDidChangeConfiguration(u=>{let h={};if(u.affectsConfiguration(KC)&&(this._useAltAsMultipleSelectionModifier=Dg(a)),u.affectsConfiguration(D2)){let f=a.getValue(D2);h={...h,indent:f}}if(u.affectsConfiguration(pz)&&t.renderIndentGuides===void 0){let f=a.getValue(pz);h={...h,renderIndentGuides:f}}if(u.affectsConfiguration(Np)){let f=!!a.getValue(Np);h={...h,smoothScrolling:f}}if(u.affectsConfiguration(kde)||u.affectsConfiguration(fz)){let f=XFe(a);h={...h,defaultFindMode:f}}if(u.affectsConfiguration(Lde)||u.affectsConfiguration(fz)){let f=i();h={...h,typeNavigationMode:f}}if(u.affectsConfiguration(Ide)){let f=QFe(a);h={...h,defaultFindMatchType:f}}if(u.affectsConfiguration(Wh)&&t.horizontalScrolling===void 0){let f=!!a.getValue(Wh);h={...h,horizontalScrolling:f}}if(u.affectsConfiguration(Dp)){let f=!!a.getValue(Dp);h={...h,scrollByPage:f}}if(u.affectsConfiguration(mz)&&t.expandOnlyOnTwistieClick===void 0&&(h={...h,expandOnlyOnTwistieClick:a.getValue(mz)==="doubleClick"}),u.affectsConfiguration(gz)){let f=a.getValue(gz);h={...h,enableStickyScroll:f}}if(u.affectsConfiguration(_z)){let f=Math.max(1,a.getValue(_z));h={...h,stickyScrollMaxItemCount:f}}if(u.affectsConfiguration(Eg)){let f=a.getValue(Eg);h={...h,mouseWheelScrollSensitivity:f}}if(u.affectsConfiguration(Tg)){let f=a.getValue(Tg);h={...h,fastScrollSensitivity:f}}Object.keys(h).length>0&&e.updateOptions(h)}),this.contextKeyService.onDidChangeContext(u=>{u.affectsSome(d)&&e.updateOptions({typeNavigationMode:i()})})),this.navigator=new xde(e,{configurationService:a,...t}),this.disposables.push(this.navigator)}updateOptions(e){e.multipleSelectionSupport!==void 0&&this.listSupportsMultiSelect.set(!!e.multipleSelectionSupport)}updateStyleOverrides(e){this.tree.style(e?Lp(e):wb)}dispose(){this.disposables=Yt(this.disposables)}};qC=Nb([jn(4,Le),jn(5,zd),jn(6,Ve)],qC);Idt=ei.as(Qs.Configuration);Idt.registerConfiguration({id:"workbench",order:7,title:m("workbenchConfigurationTitle","Workbench"),type:"object",properties:{[KC]:{type:"string",enum:["ctrlCmd","alt"],markdownEnumDescriptions:[m("multiSelectModifier.ctrlCmd","Maps to `Control` on Windows and Linux and to `Command` on macOS."),m("multiSelectModifier.alt","Maps to `Alt` on Windows and Linux and to `Option` on macOS.")],default:"ctrlCmd",description:m({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.")},[uz]:{type:"string",enum:["singleClick","doubleClick"],default:"singleClick",description:m({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.")},[Wh]:{type:"boolean",default:!1,description:m("horizontalScrolling setting","Controls whether lists and trees support horizontal scrolling in the workbench. Warning: turning on this setting has a performance implication.")},[Dp]:{type:"boolean",default:!1,description:m("list.scrollByPage","Controls whether clicks in the scrollbar scroll page by page.")},[D2]:{type:"number",default:8,minimum:4,maximum:40,description:m("tree indent setting","Controls tree indentation in pixels.")},[pz]:{type:"string",enum:["none","onHover","always"],default:"onHover",description:m("render tree indent guides","Controls whether the tree should render indent guides.")},[Np]:{type:"boolean",default:!1,description:m("list smoothScrolling setting","Controls whether lists and trees have smooth scrolling.")},[Eg]:{type:"number",default:1,markdownDescription:m("Mouse Wheel Scroll Sensitivity","A multiplier to be used on the `deltaX` and `deltaY` of mouse wheel scroll events.")},[Tg]:{type:"number",default:5,markdownDescription:m("Fast Scroll Sensitivity","Scrolling speed multiplier when pressing `Alt`.")},[kde]:{type:"string",enum:["highlight","filter"],enumDescriptions:[m("defaultFindModeSettingKey.highlight","Highlight elements when searching. Further up and down navigation will traverse only the highlighted elements."),m("defaultFindModeSettingKey.filter","Filter elements when searching.")],default:"highlight",description:m("defaultFindModeSettingKey","Controls the default find mode for lists and trees in the workbench.")},[fz]:{type:"string",enum:["simple","highlight","filter"],enumDescriptions:[m("keyboardNavigationSettingKey.simple","Simple keyboard navigation focuses elements which match the keyboard input. Matching is done only on prefixes."),m("keyboardNavigationSettingKey.highlight","Highlight keyboard navigation highlights elements which match the keyboard input. Further up and down navigation will traverse only the highlighted elements."),m("keyboardNavigationSettingKey.filter","Filter keyboard navigation will filter out and hide all the elements which do not match the keyboard input.")],default:"highlight",description:m("keyboardNavigationSettingKey","Controls the keyboard navigation style for lists and trees in the workbench. Can be simple, highlight and filter."),deprecated:!0,deprecationMessage:m("keyboardNavigationSettingKeyDeprecated","Please use 'workbench.list.defaultFindMode' and 'workbench.list.typeNavigationMode' instead.")},[Ide]:{type:"string",enum:["fuzzy","contiguous"],enumDescriptions:[m("defaultFindMatchTypeSettingKey.fuzzy","Use fuzzy matching when searching."),m("defaultFindMatchTypeSettingKey.contiguous","Use contiguous matching when searching.")],default:"fuzzy",description:m("defaultFindMatchTypeSettingKey","Controls the type of matching used when searching lists and trees in the workbench.")},[mz]:{type:"string",enum:["singleClick","doubleClick"],default:"singleClick",description:m("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.")},[gz]:{type:"boolean",default:!0,description:m("sticky scroll","Controls whether sticky scrolling is enabled in trees.")},[_z]:{type:"number",minimum:1,default:7,markdownDescription:m("sticky scroll maximum items","Controls the number of sticky elements displayed in the tree when {0} is enabled.","`#workbench.tree.enableStickyScroll#`")},[Lde]:{type:"string",enum:["automatic","trigger"],default:"automatic",markdownDescription:m("typeNavigationMode2","Controls how type navigation works in lists and trees in the workbench. When set to `trigger`, type navigation begins once the `list.triggerTypeNavigation` command is run.")}}})});var JFe=k(()=>{});var Ng,Ede=k(()=>{ke();Ah();Ps();ub();j();ec();Ng=class n extends D{constructor(e,t){super(),this.options=t,this.text="",this.title="",this.highlights=[],this.didEverRender=!1,this.supportIcons=t?.supportIcons??!1,this.domNode=Q(e,J("span.monaco-highlighted-label"))}get element(){return this.domNode}set(e,t=[],i="",o){e||(e=""),o&&(e=n.escapeNewLines(e,t)),!(this.didEverRender&&this.text===e&&this.title===i&&os(this.highlights,t))&&(this.text=e,this.title=i,this.highlights=t,this.render())}render(){let e=[],t=0;for(let i of this.highlights){if(i.end===i.start)continue;if(t{o=r===`\r `?-1:0,s+=i;for(let a of t)a.end<=s||(a.start>=s&&(a.start+=o),a.end>=s&&(a.end+=o));return i+=o,"\u23CE"})}}});function Edt(n,e,t){if(!t)return;let i=0;return n.map(o=>{let r={start:i,end:i+o.length},s=t.map(a=>ms.intersect(r,a)).filter(a=>!ms.isEmpty(a)).map(({start:a,end:l})=>({start:a-i,end:l-i}));return i=r.end+e.length,s})}var GC,Rb,Tde,Dde,Ez=k(()=>{JFe();ke();Ede();j();ec();yM();Ps();Ah();yi();fC();GC=class{constructor(e){this._element=e}get element(){return this._element}set textContent(e){this.disposed||e===this._textContent||(this._textContent=e,this._element.textContent=e)}set classNames(e){this.disposed||os(e,this._classNames)||(this._classNames=e,this._element.classList.value="",this._element.classList.add(...e))}set empty(e){this.disposed||e===this._empty||(this._empty=e,this._element.style.marginLeft=e?"0":"")}dispose(){this.disposed=!0}},Rb=class extends D{constructor(e,t){super(),this.customHovers=new Map,this.creationOptions=t,this.domNode=this._register(new GC(Q(e,J(".monaco-icon-label")))),this.labelContainer=Q(this.domNode.element,J(".monaco-icon-label-container")),this.nameContainer=Q(this.labelContainer,J("span.monaco-icon-name-container")),t?.supportHighlights||t?.supportIcons?this.nameNode=this._register(new Dde(this.nameContainer,!!t.supportIcons)):this.nameNode=new Tde(this.nameContainer),this.hoverDelegate=t?.hoverDelegate??lo("mouse")}get element(){return this.domNode.element}setLabel(e,t,i){let o=["monaco-icon-label"],r=["monaco-icon-label-container"],s="";i&&(i.extraClasses&&o.push(...i.extraClasses),i.italic&&o.push("italic"),i.strikethrough&&o.push("strikethrough"),i.disabledCommand&&r.push("disabled"),i.title&&(typeof i.title=="string"?s+=i.title:s+=e));let a=this.domNode.element.querySelector(".monaco-icon-label-iconpath");if(i?.iconPath){let l;!a||!_n(a)?(l=J(".monaco-icon-label-iconpath"),this.domNode.element.prepend(l)):l=a,l.style.backgroundImage=_u(i?.iconPath)}else a&&a.remove();if(this.domNode.classNames=o,this.domNode.element.setAttribute("aria-label",s),this.labelContainer.classList.value="",this.labelContainer.classList.add(...r),this.setupHover(i?.descriptionTitle?this.labelContainer:this.element,i?.title),this.nameNode.setLabel(e,i),t||this.descriptionNode){let l=this.getOrCreateDescriptionNode();l instanceof Ng?(l.set(t||"",i?i.descriptionMatches:void 0,void 0,i?.labelEscapeNewLines),this.setupHover(l.element,i?.descriptionTitle)):(l.textContent=t&&i?.labelEscapeNewLines?Ng.escapeNewLines(t,[]):t||"",this.setupHover(l.element,i?.descriptionTitle||""),l.empty=!t)}if(i?.suffix||this.suffixNode){let l=this.getOrCreateSuffixNode();l.textContent=i?.suffix??""}}setupHover(e,t){let i=this.customHovers.get(e);if(i&&(i.dispose(),this.customHovers.delete(e)),!t){e.removeAttribute("title");return}if(this.hoverDelegate.showNativeHover)(function(r,s){Rr(s)?r.title=QL(s):s?.markdownNotSupportedFallback?r.title=s.markdownNotSupportedFallback:r.removeAttribute("title")})(e,t);else{let o=Os().setupManagedHover(this.hoverDelegate,e,t);o&&this.customHovers.set(e,o)}}dispose(){super.dispose();for(let e of this.customHovers.values())e.dispose();this.customHovers.clear()}getOrCreateSuffixNode(){if(!this.suffixNode){let e=this._register(new GC(kDe(this.nameContainer,J("span.monaco-icon-suffix-container"))));this.suffixNode=this._register(new GC(Q(e.element,J("span.label-suffix"))))}return this.suffixNode}getOrCreateDescriptionNode(){if(!this.descriptionNode){let e=this._register(new GC(Q(this.labelContainer,J("span.monaco-icon-description-container"))));this.creationOptions?.supportDescriptionHighlights?this.descriptionNode=this._register(new Ng(Q(e.element,J("span.label-description")),{supportIcons:!!this.creationOptions.supportIcons})):this.descriptionNode=this._register(new GC(Q(e.element,J("span.label-description"))))}return this.descriptionNode}},Tde=class{constructor(e){this.container=e,this.label=void 0,this.singleLabel=void 0}setLabel(e,t){if(!(this.label===e&&os(this.options,t)))if(this.label=e,this.options=t,typeof e=="string")this.singleLabel||(this.container.innerText="",this.container.classList.remove("multiple"),this.singleLabel=Q(this.container,J("a.label-name",{id:t?.domId}))),this.singleLabel.textContent=e;else{this.container.innerText="",this.container.classList.add("multiple"),this.singleLabel=void 0;for(let i=0;i{});var Tz,Dz,Rg,M2=k(()=>{ke();Ah();Ps();D7();j();ec();e5e();pe();Tz=J,Dz={keybindingLabelBackground:void 0,keybindingLabelForeground:void 0,keybindingLabelBorder:void 0,keybindingLabelBottomBorder:void 0,keybindingLabelShadow:void 0},Rg=class n extends D{constructor(e,t,i){super(),this.os=t,this.keyElements=new Set,this.options=i||Object.create(null);let o=this.options.keybindingLabelForeground;this.domNode=Q(e,Tz(".monaco-keybinding")),o&&(this.domNode.style.color=o),this.hover=this._register(Os().setupManagedHover(lo("mouse"),this.domNode,"")),this.didEverRender=!1,e.appendChild(this.domNode)}get element(){return this.domNode}set(e,t){this.didEverRender&&this.keybinding===e&&n.areSame(this.matches,t)||(this.keybinding=e,this.matches=t,this.render())}render(){if(this.clear(),this.keybinding){let e=this.keybinding.getChords();e[0]&&this.renderChord(this.domNode,e[0],this.matches?this.matches.firstPart:null);for(let i=1;io.length)return 1}return 0}var t5e,Qui,Jui,n5e=k(()=>{cp();t5e=new or(()=>{let n=new Intl.Collator(void 0,{numeric:!0,sensitivity:"base"});return{collator:n,collatorIsNumeric:n.resolvedOptions().numeric}}),Qui=new or(()=>({collator:new Intl.Collator(void 0,{numeric:!0})})),Jui=new or(()=>({collator:new Intl.Collator(void 0,{numeric:!0,sensitivity:"accent"})}))});function Ndt(n,e){let{text:t,iconOffsets:i}=e;if(!i||i.length===0)return o5e(n,t);let o=H_(t," "),r=t.length-o.length,s=o5e(n,o);if(s)for(let a of s){let l=i[a.start+r]+r;a.start+=l,a.end+=l}return s}function o5e(n,e){let t=e.toLowerCase().indexOf(n.toLowerCase());return t!==-1?[{start:t,end:t+n.length}]:null}function Rdt(n,e,t){let i=n.labelHighlights||[],o=e.labelHighlights||[];return i.length&&!o.length?-1:!i.length&&o.length?1:i.length===0&&o.length===0?0:i5e(n.saneSortLabel,e.saneSortLabel,t)}var Pz,Nde,Rde,Rp,Nz,Bs,Ag,Ab,Ade,Mde,Rz,Az,Mz,cE,r5e=k(()=>{ke();Ie();pe();Fe();A2();Yi();j();Jc();Ks();Bt();Yx();Ez();M2();Oh();wf();Ai();Ice();cp();fC();n5e();Qe();sE();ft();je();uc();Oi();at();Pz=function(n,e,t,i){var o=arguments.length,r=o<3?e:i===null?i=Object.getOwnPropertyDescriptor(e,t):i,s;if(typeof Reflect=="object"&&typeof Reflect.decorate=="function")r=Reflect.decorate(n,e,t,i);else for(var a=n.length-1;a>=0;a--)(s=n[a])&&(r=(o<3?s(r):o>3?s(e,t,r):s(e,t))||r);return o>3&&r&&Object.defineProperty(e,t,r),r},Nde=function(n,e){return function(t,i){e(t,i,n)}},Rp=J,Nz=class{constructor(e,t,i){this.index=e,this.hasCheckbox=t,this._hidden=!1,this._init=new or(()=>{let o=i.label??"",r=JL(o).text.trim(),s=i.ariaLabel||[o,this.saneDescription,this.saneDetail].map(a=>v2e(a)).filter(a=>!!a).join(", ");return{saneLabel:o,saneSortLabel:r,saneAriaLabel:s}}),this._saneDescription=i.description,this._saneTooltip=i.tooltip}get saneLabel(){return this._init.value.saneLabel}get saneSortLabel(){return this._init.value.saneSortLabel}get saneAriaLabel(){return this._init.value.saneAriaLabel}get element(){return this._element}set element(e){this._element=e}get hidden(){return this._hidden}set hidden(e){this._hidden=e}get saneDescription(){return this._saneDescription}set saneDescription(e){this._saneDescription=e}get saneDetail(){return this._saneDetail}set saneDetail(e){this._saneDetail=e}get saneTooltip(){return this._saneTooltip}set saneTooltip(e){this._saneTooltip=e}get labelHighlights(){return this._labelHighlights}set labelHighlights(e){this._labelHighlights=e}get descriptionHighlights(){return this._descriptionHighlights}set descriptionHighlights(e){this._descriptionHighlights=e}get detailHighlights(){return this._detailHighlights}set detailHighlights(e){this._detailHighlights=e}},Bs=class extends Nz{constructor(e,t,i,o,r,s){super(e,t,r),this.fireButtonTriggered=i,this._onChecked=o,this.item=r,this._separator=s,this._checked=!1,this.onChecked=t?ne.map(ne.filter(this._onChecked.event,a=>a.element===this),a=>a.checked):ne.None,this._saneDetail=r.detail,this._labelHighlights=r.highlights?.label,this._descriptionHighlights=r.highlights?.description,this._detailHighlights=r.highlights?.detail}get separator(){return this._separator}set separator(e){this._separator=e}get checked(){return this._checked}set checked(e){e!==this._checked&&(this._checked=e,this._onChecked.fire({element:this,checked:e}))}get checkboxDisabled(){return!!this.item.disabled}};(function(n){n[n.NONE=0]="NONE",n[n.MOUSE_HOVER=1]="MOUSE_HOVER",n[n.ACTIVE_ITEM=2]="ACTIVE_ITEM"})(Ag||(Ag={}));Ab=class extends Nz{constructor(e,t,i){super(e,!1,i),this.fireSeparatorButtonTriggered=t,this.separator=i,this.children=new Array,this.focusInsideSeparator=Ag.NONE}},Ade=class{getHeight(e){return e instanceof Ab?30:e.saneDetail?44:22}getTemplateId(e){return e instanceof Bs?Az.ID:Mz.ID}},Mde=class{getWidgetAriaLabel(){return m("quickInput","Quick Input")}getAriaLabel(e){return e.separator?.label?`${e.saneAriaLabel}, ${e.separator.label}`:e.saneAriaLabel}getWidgetRole(){return"listbox"}getRole(e){return e.hasCheckbox?"checkbox":"option"}isChecked(e){if(!(!e.hasCheckbox||!(e instanceof Bs)))return{get value(){return e.checked},onDidChange:t=>e.onChecked(()=>t())}}},Rz=class{constructor(e){this.hoverDelegate=e}renderTemplate(e){let t=Object.create(null);t.toDisposeElement=new H,t.toDisposeTemplate=new H,t.entry=Q(e,Rp(".quick-input-list-entry"));let i=Q(t.entry,Rp("label.quick-input-list-label"));t.toDisposeTemplate.add(gi(i,re.CLICK,c=>{t.checkbox.offsetParent||c.preventDefault()})),t.checkbox=Q(i,Rp("input.quick-input-list-checkbox")),t.checkbox.type="checkbox";let o=Q(i,Rp(".quick-input-list-rows")),r=Q(o,Rp(".quick-input-list-row")),s=Q(o,Rp(".quick-input-list-row"));t.label=new Rb(r,{supportHighlights:!0,supportDescriptionHighlights:!0,supportIcons:!0,hoverDelegate:this.hoverDelegate}),t.toDisposeTemplate.add(t.label),t.icon=pL(t.label.element,Rp(".quick-input-list-icon"));let a=Q(r,Rp(".quick-input-list-entry-keybinding"));t.keybinding=new Rg(a,Ur),t.toDisposeTemplate.add(t.keybinding);let l=Q(s,Rp(".quick-input-list-label-meta"));return t.detail=new Rb(l,{supportHighlights:!0,supportIcons:!0,hoverDelegate:this.hoverDelegate}),t.toDisposeTemplate.add(t.detail),t.separator=Q(t.entry,Rp(".quick-input-list-separator")),t.actionBar=new Zo(t.entry,this.hoverDelegate?{hoverDelegate:this.hoverDelegate}:void 0),t.actionBar.domNode.classList.add("quick-input-list-entry-action-bar"),t.toDisposeTemplate.add(t.actionBar),t}disposeTemplate(e){e.toDisposeElement.dispose(),e.toDisposeTemplate.dispose()}disposeElement(e,t,i){i.toDisposeElement.clear(),i.actionBar.clear()}},Az=class extends Rz{static{Rde=this}static{this.ID="quickpickitem"}constructor(e,t){super(e),this.themeService=t,this._itemsWithSeparatorsFrequency=new Map}get templateId(){return Rde.ID}renderTemplate(e){let t=super.renderTemplate(e);return t.toDisposeTemplate.add(gi(t.checkbox,re.CHANGE,i=>{t.element.checked=t.checkbox.checked})),t}renderElement(e,t,i){let o=e.element;i.element=o,o.element=i.entry??void 0;let r=o.item;i.checkbox.checked=o.checked,i.toDisposeElement.add(o.onChecked(h=>i.checkbox.checked=h)),i.checkbox.disabled=o.checkboxDisabled;let{labelHighlights:s,descriptionHighlights:a,detailHighlights:l}=o;if(r.iconPath){let h=Vm(this.themeService.getColorTheme().type)?r.iconPath.dark:r.iconPath.light??r.iconPath.dark,f=Ee.revive(h);i.icon.className="quick-input-list-icon",i.icon.style.backgroundImage=_u(f)}else i.icon.style.backgroundImage="",i.icon.className=r.iconClass?`quick-input-list-icon ${r.iconClass}`:"";let c;!o.saneTooltip&&o.saneDescription&&(c={markdown:{value:o.saneDescription,supportThemeIcons:!0},markdownNotSupportedFallback:o.saneDescription});let d={matches:s||[],descriptionTitle:c,descriptionMatches:a||[],labelEscapeNewLines:!0};if(d.extraClasses=r.iconClasses,d.italic=r.italic,d.strikethrough=r.strikethrough,i.entry.classList.remove("quick-input-list-separator-as-item"),i.label.setLabel(o.saneLabel,o.saneDescription,d),i.keybinding.set(r.keybinding),o.saneDetail){let h;o.saneTooltip||(h={markdown:{value:o.saneDetail,supportThemeIcons:!0},markdownNotSupportedFallback:o.saneDetail}),i.detail.element.style.display="",i.detail.setLabel(o.saneDetail,void 0,{matches:l,title:h,labelEscapeNewLines:!0})}else i.detail.element.style.display="none";o.separator?.label?(i.separator.textContent=o.separator.label,i.separator.style.display="",this.addItemWithSeparator(o)):i.separator.style.display="none",i.entry.classList.toggle("quick-input-list-separator-border",!!o.separator);let u=r.buttons;u&&u.length?(i.actionBar.push(u.map((h,f)=>WC(h,`id-${f}`,()=>o.fireButtonTriggered({button:h,item:o.item}))),{icon:!0,label:!1}),i.entry.classList.add("has-actions")):i.entry.classList.remove("has-actions")}disposeElement(e,t,i){this.removeItemWithSeparator(e.element),super.disposeElement(e,t,i)}isItemWithSeparatorVisible(e){return this._itemsWithSeparatorsFrequency.has(e)}addItemWithSeparator(e){this._itemsWithSeparatorsFrequency.set(e,(this._itemsWithSeparatorsFrequency.get(e)||0)+1)}removeItemWithSeparator(e){let t=this._itemsWithSeparatorsFrequency.get(e)||0;t>1?this._itemsWithSeparatorsFrequency.set(e,t-1):this._itemsWithSeparatorsFrequency.delete(e)}};Az=Rde=Pz([Nde(1,Vi)],Az);Mz=class n extends Rz{constructor(){super(...arguments),this._visibleSeparatorsFrequency=new Map}static{this.ID="quickpickseparator"}get templateId(){return n.ID}get visibleSeparators(){return[...this._visibleSeparatorsFrequency.keys()]}isSeparatorVisible(e){return this._visibleSeparatorsFrequency.has(e)}renderTemplate(e){let t=super.renderTemplate(e);return t.checkbox.style.display="none",t}renderElement(e,t,i){let o=e.element;i.element=o,o.element=i.entry??void 0,o.element.classList.toggle("focus-inside",!!o.focusInsideSeparator);let r=o.separator,{labelHighlights:s,descriptionHighlights:a,detailHighlights:l}=o;i.icon.style.backgroundImage="",i.icon.className="";let c;!o.saneTooltip&&o.saneDescription&&(c={markdown:{value:o.saneDescription,supportThemeIcons:!0},markdownNotSupportedFallback:o.saneDescription});let d={matches:s||[],descriptionTitle:c,descriptionMatches:a||[],labelEscapeNewLines:!0};if(i.entry.classList.add("quick-input-list-separator-as-item"),i.label.setLabel(o.saneLabel,o.saneDescription,d),o.saneDetail){let h;o.saneTooltip||(h={markdown:{value:o.saneDetail,supportThemeIcons:!0},markdownNotSupportedFallback:o.saneDetail}),i.detail.element.style.display="",i.detail.setLabel(o.saneDetail,void 0,{matches:l,title:h,labelEscapeNewLines:!0})}else i.detail.element.style.display="none";i.separator.style.display="none",i.entry.classList.add("quick-input-list-separator-border");let u=r.buttons;u&&u.length?(i.actionBar.push(u.map((h,f)=>WC(h,`id-${f}`,()=>o.fireSeparatorButtonTriggered({button:h,separator:o.separator}))),{icon:!0,label:!1}),i.entry.classList.add("has-actions")):i.entry.classList.remove("has-actions"),this.addSeparator(o)}disposeElement(e,t,i){this.removeSeparator(e.element),this.isSeparatorVisible(e.element)||e.element.element?.classList.remove("focus-inside"),super.disposeElement(e,t,i)}addSeparator(e){this._visibleSeparatorsFrequency.set(e,(this._visibleSeparatorsFrequency.get(e)||0)+1)}removeSeparator(e){let t=this._visibleSeparatorsFrequency.get(e)||0;t>1?this._visibleSeparatorsFrequency.set(e,t-1):this._visibleSeparatorsFrequency.delete(e)}},cE=class extends D{constructor(e,t,i,o,r,s){super(),this.parent=e,this.hoverDelegate=t,this.linkOpenerDelegate=i,this.accessibilityService=s,this._onKeyDown=new A,this._onLeave=new A,this.onLeave=this._onLeave.event,this._visibleCountObservable=lt("VisibleCount",0),this.onChangedVisibleCount=ne.fromObservable(this._visibleCountObservable,this._store),this._allVisibleCheckedObservable=lt("AllVisibleChecked",!1),this.onChangedAllVisibleChecked=ne.fromObservable(this._allVisibleCheckedObservable,this._store),this._checkedCountObservable=lt("CheckedCount",0),this.onChangedCheckedCount=ne.fromObservable(this._checkedCountObservable,this._store),this._checkedElementsObservable=_I({equalsFn:oi},new Array),this.onChangedCheckedElements=ne.fromObservable(this._checkedElementsObservable,this._store),this._onButtonTriggered=new A,this.onButtonTriggered=this._onButtonTriggered.event,this._onSeparatorButtonTriggered=new A,this.onSeparatorButtonTriggered=this._onSeparatorButtonTriggered.event,this._elementChecked=new A,this._elementCheckedEventBufferer=new uf,this._hasCheckboxes=!1,this._inputElements=new Array,this._elementTree=new Array,this._itemElements=new Array,this._elementDisposable=this._register(new H),this._matchOnDescription=!1,this._matchOnDetail=!1,this._matchOnLabel=!0,this._matchOnLabelMode="fuzzy",this._sortByLabel=!0,this._shouldLoop=!0,this._container=Q(this.parent,Rp(".quick-input-list")),this._separatorRenderer=new Mz(t),this._itemRenderer=r.createInstance(Az,t),this._tree=this._register(r.createInstance(vz,"QuickInput",this._container,new Ade,[this._itemRenderer,this._separatorRenderer],{filter:{filter(a){return a.hidden?0:a instanceof Ab?2:1}},sorter:{compare:(a,l)=>{if(!this.sortByLabel||!this._lastQueryString)return 0;let c=this._lastQueryString.toLowerCase();return Rdt(a,l,c)}},accessibilityProvider:new Mde,setRowLineHeight:!1,multipleSelectionSupport:!1,hideTwistiesOfChildlessElements:!0,renderIndentGuides:$C.None,findWidgetEnabled:!1,indent:0,horizontalScrolling:!1,allowNonCollapsibleParents:!0,alwaysConsumeMouseWheel:!0})),this._tree.getHTMLElement().id=o,this._registerListeners()}get onDidChangeFocus(){return ne.map(this._tree.onDidChangeFocus,e=>e.elements.filter(t=>t instanceof Bs).map(t=>t.item),this._store)}get onDidChangeSelection(){return ne.map(this._tree.onDidChangeSelection,e=>({items:e.elements.filter(t=>t instanceof Bs).map(t=>t.item),event:e.browserEvent}),this._store)}get displayed(){return this._container.style.display!=="none"}set displayed(e){this._container.style.display=e?"":"none"}get scrollTop(){return this._tree.scrollTop}set scrollTop(e){this._tree.scrollTop=e}get ariaLabel(){return this._tree.ariaLabel}set ariaLabel(e){this._tree.ariaLabel=e??""}set enabled(e){this._tree.getHTMLElement().style.pointerEvents=e?"":"none"}get matchOnDescription(){return this._matchOnDescription}set matchOnDescription(e){this._matchOnDescription=e}get matchOnDetail(){return this._matchOnDetail}set matchOnDetail(e){this._matchOnDetail=e}get matchOnLabel(){return this._matchOnLabel}set matchOnLabel(e){this._matchOnLabel=e}get matchOnLabelMode(){return this._matchOnLabelMode}set matchOnLabelMode(e){this._matchOnLabelMode=e}get sortByLabel(){return this._sortByLabel}set sortByLabel(e){this._sortByLabel=e}get shouldLoop(){return this._shouldLoop}set shouldLoop(e){this._shouldLoop=e}_registerListeners(){this._registerOnKeyDown(),this._registerOnContainerClick(),this._registerOnMouseMiddleClick(),this._registerOnTreeModelChanged(),this._registerOnElementChecked(),this._registerOnContextMenu(),this._registerHoverListeners(),this._registerSelectionChangeListener(),this._registerSeparatorActionShowingListeners()}_registerOnKeyDown(){this._register(this._tree.onKeyDown(e=>{let t=new Xt(e);switch(t.keyCode){case 10:this.toggleCheckbox();break}this._onKeyDown.fire(t)}))}_registerOnContainerClick(){this._register(U(this._container,re.CLICK,e=>{(e.x||e.y)&&this._onLeave.fire()}))}_registerOnMouseMiddleClick(){this._register(U(this._container,re.AUXCLICK,e=>{e.button===1&&this._onLeave.fire()}))}_registerOnTreeModelChanged(){this._register(this._tree.onDidChangeModel(()=>{let e=this._itemElements.filter(t=>!t.hidden).length;this._visibleCountObservable.set(e,void 0),this._hasCheckboxes&&this._updateCheckedObservables()}))}_registerOnElementChecked(){this._register(this._elementCheckedEventBufferer.wrapEvent(this._elementChecked.event,(e,t)=>t)(e=>this._updateCheckedObservables()))}_registerOnContextMenu(){this._register(this._tree.onContextMenu(e=>{e.element&&(e.browserEvent.preventDefault(),this._tree.setSelection([e.element]))}))}_registerHoverListeners(){let e=this._register(new lL(this.hoverDelegate.delay));this._register(this._tree.onMouseOver(async t=>{if(ooe(t.browserEvent.target)){e.cancel();return}if(!(!ooe(t.browserEvent.relatedTarget)&&io(t.browserEvent.relatedTarget,t.element?.element)))try{await e.trigger(async()=>{t.element instanceof Bs&&this.showHover(t.element)})}catch(i){if(!$r(i))throw i}})),this._register(this._tree.onMouseOut(t=>{io(t.browserEvent.relatedTarget,t.element?.element)||e.cancel()}))}_registerSeparatorActionShowingListeners(){this._register(this._tree.onDidChangeFocus(e=>{let t=e.elements[0]?this._tree.getParentElement(e.elements[0]):null;for(let i of this._separatorRenderer.visibleSeparators){let o=i===t;!!(i.focusInsideSeparator&Ag.ACTIVE_ITEM)!==o&&(o?i.focusInsideSeparator|=Ag.ACTIVE_ITEM:i.focusInsideSeparator&=~Ag.ACTIVE_ITEM,this._tree.rerender(i))}})),this._register(this._tree.onMouseOver(e=>{let t=e.element?this._tree.getParentElement(e.element):null;for(let i of this._separatorRenderer.visibleSeparators){if(i!==t)continue;!!(i.focusInsideSeparator&Ag.MOUSE_HOVER)||(i.focusInsideSeparator|=Ag.MOUSE_HOVER,this._tree.rerender(i))}})),this._register(this._tree.onMouseOut(e=>{let t=e.element?this._tree.getParentElement(e.element):null;for(let i of this._separatorRenderer.visibleSeparators){if(i!==t)continue;!!(i.focusInsideSeparator&Ag.MOUSE_HOVER)&&(i.focusInsideSeparator&=~Ag.MOUSE_HOVER,this._tree.rerender(i))}}))}_registerSelectionChangeListener(){this._register(this._tree.onDidChangeSelection(e=>{let t=e.elements.filter(i=>i instanceof Bs);t.length!==e.elements.length&&(e.elements.length===1&&e.elements[0]instanceof Ab&&(this._tree.setFocus([e.elements[0].children[0]]),this._tree.reveal(e.elements[0],0)),this._tree.setSelection(t))}))}setAllVisibleChecked(e){this._elementCheckedEventBufferer.bufferEvents(()=>{this._itemElements.forEach(t=>{!t.hidden&&!t.checkboxDisabled&&(t.checked=e)})})}setElements(e){this._elementDisposable.clear(),this._lastQueryString=void 0,this._inputElements=e,this._hasCheckboxes=this.parent.classList.contains("show-checkboxes");let t;this._itemElements=new Array,this._elementTree=e.reduce((i,o,r)=>{let s;if(o.type==="separator"){if(!o.buttons)return i;t=new Ab(r,a=>this._onSeparatorButtonTriggered.fire(a),o),s=t}else{let a=r>0?e[r-1]:void 0,l;a&&a.type==="separator"&&!a.buttons&&(t=void 0,l=a);let c=new Bs(r,this._hasCheckboxes,d=>this._onButtonTriggered.fire(d),this._elementChecked,o,l);if(this._itemElements.push(c),t)return t.children.push(c),i;s=c}return i.push(s),i},new Array),this._setElementsToTree(this._elementTree),this.accessibilityService.isScreenReaderOptimized()&&setTimeout(()=>{let i=this._tree.getHTMLElement().querySelector(".monaco-list-row.focused"),o=i?.parentNode;if(i&&o){let r=i.nextSibling;i.remove(),o.insertBefore(i,r)}},0)}setFocusedElements(e){let t=e.map(i=>this._itemElements.find(o=>o.item===i)).filter(i=>!!i).filter(i=>!i.hidden);if(this._tree.setFocus(t),e.length>0){let i=this._tree.getFocus()[0];i&&this._tree.reveal(i)}}getActiveDescendant(){return this._tree.getHTMLElement().getAttribute("aria-activedescendant")}setSelectedElements(e){let t=e.map(i=>this._itemElements.find(o=>o.item===i)).filter(i=>!!i);this._tree.setSelection(t)}getCheckedElements(){return this._itemElements.filter(e=>e.checked).map(e=>e.item)}setCheckedElements(e){this._elementCheckedEventBufferer.bufferEvents(()=>{let t=new Set;for(let i of e)t.add(i);for(let i of this._itemElements)i.checked=t.has(i.item)})}focus(e){if(this._itemElements.length)switch(e===xn.Second&&this._itemElements.length<2&&(e=xn.First),e){case xn.First:this._tree.scrollTop=0,this._tree.focusFirst(void 0,t=>t.element instanceof Bs);break;case xn.Second:{this._tree.scrollTop=0;let t=!1;this._tree.focusFirst(void 0,i=>i.element instanceof Bs?t?!0:(t=!t,!1):!1);break}case xn.Last:this._tree.scrollTop=this._tree.scrollHeight,this._tree.focusLast(void 0,t=>t.element instanceof Bs);break;case xn.Next:{let t=this._tree.getFocus();this._tree.focusNext(void 0,this._shouldLoop,void 0,o=>o.element instanceof Bs?(this._tree.reveal(o.element),!0):!1);let i=this._tree.getFocus();t.length&&t[0]===i[0]&&t[0]===this._itemElements[this._itemElements.length-1]&&this._onLeave.fire();break}case xn.Previous:{let t=this._tree.getFocus();this._tree.focusPrevious(void 0,this._shouldLoop,void 0,o=>{if(!(o.element instanceof Bs))return!1;let r=this._tree.getParentElement(o.element);return r===null||r.children[0]!==o.element?this._tree.reveal(o.element):this._tree.reveal(r),!0});let i=this._tree.getFocus();t.length&&t[0]===i[0]&&t[0]===this._itemElements[0]&&this._onLeave.fire();break}case xn.NextPage:this._tree.focusNextPage(void 0,t=>t.element instanceof Bs?(this._tree.reveal(t.element),!0):!1);break;case xn.PreviousPage:this._tree.focusPreviousPage(void 0,t=>{if(!(t.element instanceof Bs))return!1;let i=this._tree.getParentElement(t.element);return i===null||i.children[0]!==t.element?this._tree.reveal(t.element):this._tree.reveal(i),!0});break;case xn.NextSeparator:{let t=!1,i=this._tree.getFocus()[0];this._tree.focusNext(void 0,!0,void 0,r=>{if(t)return!0;if(r.element instanceof Ab)t=!0,this._separatorRenderer.isSeparatorVisible(r.element)?this._tree.reveal(r.element.children[0]):this._tree.reveal(r.element,0);else if(r.element instanceof Bs){if(r.element.separator)return this._itemRenderer.isItemWithSeparatorVisible(r.element)?this._tree.reveal(r.element):this._tree.reveal(r.element,0),!0;if(r.element===this._elementTree[0])return this._tree.reveal(r.element,0),!0}return!1});let o=this._tree.getFocus()[0];i===o&&(this._tree.scrollTop=this._tree.scrollHeight,this._tree.focusLast(void 0,r=>r.element instanceof Bs));break}case xn.PreviousSeparator:{let t,i=!!this._tree.getFocus()[0]?.separator;this._tree.focusPrevious(void 0,!0,void 0,o=>{if(o.element instanceof Ab)i?t||(this._separatorRenderer.isSeparatorVisible(o.element)?this._tree.reveal(o.element):this._tree.reveal(o.element,0),t=o.element.children[0]):i=!0;else if(o.element instanceof Bs&&!t){if(o.element.separator)this._itemRenderer.isItemWithSeparatorVisible(o.element)?this._tree.reveal(o.element):this._tree.reveal(o.element,0),t=o.element;else if(o.element===this._elementTree[0])return this._tree.reveal(o.element,0),!0}return!1}),t&&this._tree.setFocus([t]);break}}}clearFocus(){this._tree.setFocus([])}domFocus(){this._tree.domFocus()}layout(e){this._tree.getHTMLElement().style.maxHeight=e?`${Math.floor(e/44)*44+6}px`:"",this._tree.layout()}filter(e){if(this._lastQueryString=e,!(this._sortByLabel||this._matchOnLabel||this._matchOnDescription||this._matchOnDetail))return this._tree.layout(),!1;let t=e;if(e=e.trim(),!e||!(this.matchOnLabel||this.matchOnDescription||this.matchOnDetail))this._itemElements.forEach(i=>{i.labelHighlights=void 0,i.descriptionHighlights=void 0,i.detailHighlights=void 0,i.hidden=!1;let o=i.index&&this._inputElements[i.index-1];i.item&&(i.separator=o&&o.type==="separator"&&!o.buttons?o:void 0)});else{let i;this._itemElements.forEach(o=>{let r;this.matchOnLabelMode==="fuzzy"?r=this.matchOnLabel?c7(e,JL(o.saneLabel))??void 0:void 0:r=this.matchOnLabel?Ndt(t,JL(o.saneLabel))??void 0:void 0;let s=this.matchOnDescription?c7(e,JL(o.saneDescription||""))??void 0:void 0,a=this.matchOnDetail?c7(e,JL(o.saneDetail||""))??void 0:void 0;if(r||s||a?(o.labelHighlights=r,o.descriptionHighlights=s,o.detailHighlights=a,o.hidden=!1):(o.labelHighlights=void 0,o.descriptionHighlights=void 0,o.detailHighlights=void 0,o.hidden=o.item?!o.item.alwaysShow:!0),o.item?o.separator=void 0:o.separator&&(o.hidden=!0),!this.sortByLabel){let l=o.index&&this._inputElements[o.index-1]||void 0;l?.type==="separator"&&!l.buttons&&(i=l),i&&!o.hidden&&(o.separator=i,i=void 0)}})}return this._setElementsToTree(this._sortByLabel&&e?this._itemElements:this._elementTree),this._tree.layout(),!0}toggleCheckbox(){this._elementCheckedEventBufferer.bufferEvents(()=>{let e=this._tree.getFocus().filter(i=>i instanceof Bs),t=this._allVisibleChecked(e);for(let i of e)i.checkboxDisabled||(i.checked=!t)})}style(e){this._tree.style(e)}toggleHover(){let e=this._tree.getFocus()[0];if(!e?.saneTooltip||!(e instanceof Bs))return;if(this._lastHover&&!this._lastHover.isDisposed){this._lastHover.dispose();return}this.showHover(e);let t=new H;t.add(this._tree.onDidChangeFocus(i=>{i.elements[0]instanceof Bs&&this.showHover(i.elements[0])})),this._lastHover&&t.add(this._lastHover),this._elementDisposable.add(t)}_setElementsToTree(e){let t=new Array;for(let i of e)i instanceof Ab?t.push({element:i,collapsible:!1,collapsed:!1,children:i.children.map(o=>({element:o,collapsible:!1,collapsed:!1}))}):t.push({element:i,collapsible:!1,collapsed:!1});this._tree.setChildren(null,t)}_allVisibleChecked(e,t=!0){for(let i=0,o=e.length;i{this._allVisibleCheckedObservable.set(this._allVisibleChecked(this._itemElements,!1),e);let t=this._itemElements.filter(i=>i.checked).length;this._checkedCountObservable.set(t,e),this._checkedElementsObservable.set(this.getCheckedElements(),e)})}showHover(e){this._lastHover&&!this._lastHover.isDisposed&&(this.hoverDelegate.onDidHideHover?.(),this._lastHover?.dispose()),!(!e.element||!e.saneTooltip)&&(this._lastHover=this.hoverDelegate.showHover({content:e.saneTooltip,target:e.element,linkHandler:t=>{this.linkOpenerDelegate(t)},appearance:{showPointer:!0},container:this._container,position:{hoverPosition:1}},!1))}};Pz([Hn],cE.prototype,"onDidChangeFocus",null);Pz([Hn],cE.prototype,"onDidChangeSelection",null);cE=Pz([Nde(4,he),Nde(5,$o)],cE)});function Vd(n,e={}){Mr.registerCommandAndKeybindingRule({...l5e,...n,secondary:Adt(n.primary,n.secondary??[],e)})}function Adt(n,e,t={}){return t.withAltMod&&e.push(512+n),t.withCtrlMod&&(e.push(Oz+n),t.withAltMod&&e.push(512+Oz+n)),t.withCmdMod&&dt&&(e.push(2048+n),t.withCtrlMod&&e.push(2304+n),t.withAltMod&&(e.push(2560+n),t.withCtrlMod&&e.push(2816+n))),e}function Ou(n,e){return t=>{let i=t.get(Pr).currentQuickInput;if(i)return e&&i.quickNavigate?i.focus(e):i.focus(n)}}var l5e,Oz,s5e,a5e,c5e=k(()=>{Bt();pe();it();lE();K_();HH();Jc();l5e={weight:200,when:Y.and(Y.equals(Ece,"quickPick"),cFe),metadata:{description:m("quickPick","Used while in the context of the quick pick. If you change one keybinding for this command, you should change all of the other keybindings (modifier variants) of this command as well.")}};Oz=dt?256:2048;Vd({id:"quickInput.pageNext",primary:12,handler:Ou(xn.NextPage)},{withAltMod:!0,withCtrlMod:!0,withCmdMod:!0});Vd({id:"quickInput.pagePrevious",primary:11,handler:Ou(xn.PreviousPage)},{withAltMod:!0,withCtrlMod:!0,withCmdMod:!0});Vd({id:"quickInput.first",primary:Oz+14,handler:Ou(xn.First)},{withAltMod:!0,withCmdMod:!0});Vd({id:"quickInput.last",primary:Oz+13,handler:Ou(xn.Last)},{withAltMod:!0,withCmdMod:!0});Vd({id:"quickInput.next",primary:18,handler:Ou(xn.Next)},{withCtrlMod:!0});Vd({id:"quickInput.previous",primary:16,handler:Ou(xn.Previous)},{withCtrlMod:!0});s5e=m("quickInput.nextSeparatorWithQuickAccessFallback","If we're in quick access mode, this will navigate to the next item. If we are not in quick access mode, this will navigate to the next separator."),a5e=m("quickInput.previousSeparatorWithQuickAccessFallback","If we're in quick access mode, this will navigate to the previous item. If we are not in quick access mode, this will navigate to the previous separator.");dt?(Vd({id:"quickInput.nextSeparatorWithQuickAccessFallback",primary:2066,handler:Ou(xn.NextSeparator,xn.Next),metadata:{description:s5e}}),Vd({id:"quickInput.nextSeparator",primary:2578,secondary:[2322],handler:Ou(xn.NextSeparator)},{withCtrlMod:!0}),Vd({id:"quickInput.previousSeparatorWithQuickAccessFallback",primary:2064,handler:Ou(xn.PreviousSeparator,xn.Previous),metadata:{description:a5e}}),Vd({id:"quickInput.previousSeparator",primary:2576,secondary:[2320],handler:Ou(xn.PreviousSeparator)},{withCtrlMod:!0})):(Vd({id:"quickInput.nextSeparatorWithQuickAccessFallback",primary:530,handler:Ou(xn.NextSeparator,xn.Next),metadata:{description:s5e}}),Vd({id:"quickInput.nextSeparator",primary:2578,handler:Ou(xn.NextSeparator)}),Vd({id:"quickInput.previousSeparatorWithQuickAccessFallback",primary:528,handler:Ou(xn.PreviousSeparator,xn.Previous),metadata:{description:a5e}}),Vd({id:"quickInput.previousSeparator",primary:2576,handler:Ou(xn.PreviousSeparator)}));Vd({id:"quickInput.acceptInBackground",when:Y.and(l5e.when,Y.or(dz.negate(),fFe)),primary:17,weight:250,handler:n=>{n.get(Pr).currentQuickInput?.accept(!0)}},{withAltMod:!0,withCtrlMod:!0,withCmdMod:!0})});var Mdt,Pde,Ode,Ud,Fz,d5e=k(()=>{ke();Oh();zH();Tce();xFe();ci();Ie();j();ob();pe();Jc();SFe();HH();nb();Il();Fe();r5e();it();c5e();Mdt=function(n,e,t,i){var o=arguments.length,r=o<3?e:i===null?i=Object.getOwnPropertyDescriptor(e,t):i,s;if(typeof Reflect=="object"&&typeof Reflect.decorate=="function")r=Reflect.decorate(n,e,t,i);else for(var a=n.length-1;a>=0;a--)(s=n[a])&&(r=(o<3?s(r):o>3?s(e,t,r):s(e,t))||r);return o>3&&r&&Object.defineProperty(e,t,r),r},Pde=function(n,e){return function(t,i){e(t,i,n)}},Ud=J,Fz=class extends D{static{Ode=this}static{this.MAX_WIDTH=600}get currentQuickInput(){return this.controller??void 0}get container(){return this._container}constructor(e,t,i,o){super(),this.options=e,this.layoutService=t,this.instantiationService=i,this.contextKeyService=o,this.enabled=!0,this.onDidAcceptEmitter=this._register(new A),this.onDidCustomEmitter=this._register(new A),this.onDidTriggerButtonEmitter=this._register(new A),this.keyMods={ctrlCmd:!1,alt:!1},this.controller=null,this.onShowEmitter=this._register(new A),this.onShow=this.onShowEmitter.event,this.onHideEmitter=this._register(new A),this.onHide=this.onHideEmitter.event,this.inQuickInputContext=lFe.bindTo(this.contextKeyService),this.quickInputTypeContext=dFe.bindTo(this.contextKeyService),this.endOfQuickInputBoxContext=hFe.bindTo(this.contextKeyService),this.idPrefix=e.idPrefix,this._container=e.container,this.styles=e.styles,this._register(ne.runAndSubscribe(I1,({window:r,disposables:s})=>this.registerKeyModsListeners(r,s),{window:ri,disposables:this._store})),this._register(hDe(r=>{this.ui&&Me(this.ui.container)===r&&(this.reparentUI(this.layoutService.mainContainer),this.layout(this.layoutService.mainContainerDimension,this.layoutService.mainContainerOffset.quickPickTop))}))}registerKeyModsListeners(e,t){let i=o=>{this.keyMods.ctrlCmd=o.ctrlKey||o.metaKey,this.keyMods.alt=o.altKey};for(let o of[re.KEY_DOWN,re.KEY_UP,re.MOUSE_DOWN])t.add(U(e,o,i,!0))}getUI(e){if(this.ui)return e&&Me(this._container)!==Me(this.layoutService.activeContainer)&&(this.reparentUI(this.layoutService.activeContainer),this.layout(this.layoutService.activeContainerDimension,this.layoutService.activeContainerOffset.quickPickTop)),this.ui;let t=Q(this._container,Ud(".quick-input-widget.show-file-icons"));t.tabIndex=-1,t.style.display="none";let i=qr(t),o=Q(t,Ud(".quick-input-titlebar")),r=this._register(new Zo(o,{hoverDelegate:this.options.hoverDelegate}));r.domNode.classList.add("quick-input-left-action-bar");let s=Q(o,Ud(".quick-input-title")),a=this._register(new Zo(o,{hoverDelegate:this.options.hoverDelegate}));a.domNode.classList.add("quick-input-right-action-bar");let l=Q(t,Ud(".quick-input-header")),c=Q(l,Ud("input.quick-input-check-all"));c.type="checkbox",c.setAttribute("aria-label",m("quickInput.checkAll","Toggle all checkboxes")),this._register(gi(c,re.CHANGE,$=>{let z=c.checked;q.setAllVisibleChecked(z)})),this._register(U(c,re.CLICK,$=>{($.x||$.y)&&f.setFocus()}));let d=Q(l,Ud(".quick-input-description")),u=Q(l,Ud(".quick-input-and-message")),h=Q(u,Ud(".quick-input-filter")),f=this._register(new KH(h,this.styles.inputBox,this.styles.toggle));f.setAttribute("aria-describedby",`${this.idPrefix}message`);let p=Q(h,Ud(".quick-input-visible-count"));p.setAttribute("aria-live","polite"),p.setAttribute("aria-atomic","true");let g=new HC(p,{countFormat:m({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")},this.styles.countBadge),_=Q(h,Ud(".quick-input-count"));_.setAttribute("aria-live","polite");let b=new HC(_,{countFormat:m({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")},this.styles.countBadge),v=this._register(new Zo(l,{hoverDelegate:this.options.hoverDelegate}));v.domNode.classList.add("quick-input-inline-action-bar");let x=Q(l,Ud(".quick-input-action")),w=this._register(new Tb(x,this.styles.button));w.label=m("ok","OK"),this._register(w.onDidClick($=>{this.onDidAcceptEmitter.fire()}));let y=Q(l,Ud(".quick-input-action")),C=this._register(new Tb(y,{...this.styles.button,supportIcons:!0}));C.label=m("custom","Custom"),this._register(C.onDidClick($=>{this.onDidCustomEmitter.fire()}));let L=Q(u,Ud(`#${this.idPrefix}message.quick-input-message`)),E=this._register(new VH(t,this.styles.progressBar));E.getContainer().classList.add("quick-input-progress");let N=Q(t,Ud(".quick-input-html-widget"));N.tabIndex=-1;let M=Q(t,Ud(".quick-input-description")),F=this.idPrefix+"list",q=this._register(this.instantiationService.createInstance(cE,t,this.options.hoverDelegate,this.options.linkOpenerDelegate,F));f.setAttribute("aria-controls",F),this._register(q.onDidChangeFocus(()=>{f.setAttribute("aria-activedescendant",q.getActiveDescendant()??"")})),this._register(q.onChangedAllVisibleChecked($=>{c.checked=$})),this._register(q.onChangedVisibleCount($=>{g.setCount($)})),this._register(q.onChangedCheckedCount($=>{b.setCount($)})),this._register(q.onLeave(()=>{setTimeout(()=>{this.controller&&(f.setFocus(),this.controller instanceof v2&&this.controller.canSelectMany&&q.clearFocus())},0)}));let te=ba(t);return this._register(te),this._register(U(t,re.FOCUS,$=>{let z=this.getUI();if(io($.relatedTarget,z.inputContainer)){let ae=z.inputBox.isSelectionAtEnd();this.endOfQuickInputBoxContext.get()!==ae&&this.endOfQuickInputBoxContext.set(ae)}io($.relatedTarget,z.container)||(this.inQuickInputContext.set(!0),this.previousFocusElement=_n($.relatedTarget)?$.relatedTarget:void 0)},!0)),this._register(te.onDidBlur(()=>{!this.getUI().ignoreFocusOut&&!this.options.ignoreFocusOut()&&this.hide(xw.Blur),this.inQuickInputContext.set(!1),this.endOfQuickInputBoxContext.set(!1),this.previousFocusElement=void 0})),this._register(f.onKeyDown($=>{let z=this.getUI().inputBox.isSelectionAtEnd();this.endOfQuickInputBoxContext.get()!==z&&this.endOfQuickInputBoxContext.set(z)})),this._register(U(t,re.FOCUS,$=>{f.setFocus()})),this._register(gi(t,re.KEY_DOWN,$=>{if(!io($.target,N))switch($.keyCode){case 3:Rt.stop($,!0),this.enabled&&this.onDidAcceptEmitter.fire();break;case 9:Rt.stop($,!0),this.hide(xw.Gesture);break;case 2:if(!$.altKey&&!$.ctrlKey&&!$.metaKey){let z=[".quick-input-list .monaco-action-bar .always-visible",".quick-input-list-entry:hover .monaco-action-bar",".monaco-list-row.focused .monaco-action-bar"];if(t.classList.contains("show-checkboxes")?z.push("input"):z.push("input[type=text]"),this.getUI().list.displayed&&z.push(".monaco-list"),this.getUI().message&&z.push(".quick-input-message a"),this.getUI().widget){if(io($.target,this.getUI().widget))break;z.push(".quick-input-html-widget")}let ae=t.querySelectorAll(z.join(", "));$.shiftKey&&$.target===ae[0]?(Rt.stop($,!0),q.clearFocus()):!$.shiftKey&&io($.target,ae[ae.length-1])&&(Rt.stop($,!0),ae[0].focus())}break;case 10:$.ctrlKey&&(Rt.stop($,!0),this.getUI().list.toggleHover());break}})),this.ui={container:t,styleSheet:i,leftActionBar:r,titleBar:o,title:s,description1:M,description2:d,widget:N,rightActionBar:a,inlineActionBar:v,checkAll:c,inputContainer:u,filterContainer:h,inputBox:f,visibleCountContainer:p,visibleCount:g,countContainer:_,count:b,okContainer:x,ok:w,message:L,customButtonContainer:y,customButton:C,list:q,progressBar:E,onDidAccept:this.onDidAcceptEmitter.event,onDidCustom:this.onDidCustomEmitter.event,onDidTriggerButton:this.onDidTriggerButtonEmitter.event,ignoreFocusOut:!1,keyMods:this.keyMods,show:$=>this.show($),hide:()=>this.hide(),setVisibilities:$=>this.setVisibilities($),setEnabled:$=>this.setEnabled($),setContextKey:$=>this.options.setContextKey($),linkOpenerDelegate:$=>this.options.linkOpenerDelegate($)},this.updateStyles(),this.ui}reparentUI(e){this.ui&&(this._container=e,Q(this._container,this.ui.container))}pick(e,t={},i=Ze.None){return new Promise((o,r)=>{let s=d=>{s=o,t.onKeyMods?.(a.keyMods),o(d)};if(i.isCancellationRequested){s(void 0);return}let a=this.createQuickPick({useSeparators:!0}),l,c=[a,a.onDidAccept(()=>{if(a.canSelectMany)s(a.selectedItems.slice()),a.hide();else{let d=a.activeItems[0];d&&(s(d),a.hide())}}),a.onDidChangeActive(d=>{let u=d[0];u&&t.onDidFocus&&t.onDidFocus(u)}),a.onDidChangeSelection(d=>{if(!a.canSelectMany){let u=d[0];u&&(s(u),a.hide())}}),a.onDidTriggerItemButton(d=>t.onDidTriggerItemButton&&t.onDidTriggerItemButton({...d,removeItem:()=>{let u=a.items.indexOf(d.item);if(u!==-1){let h=a.items.slice(),f=h.splice(u,1),p=a.activeItems.filter(_=>_!==f[0]),g=a.keepScrollPosition;a.keepScrollPosition=!0,a.items=h,p&&(a.activeItems=p),a.keepScrollPosition=g}}})),a.onDidTriggerSeparatorButton(d=>t.onDidTriggerSeparatorButton?.(d)),a.onDidChangeValue(d=>{l&&!d&&(a.activeItems.length!==1||a.activeItems[0]!==l)&&(a.activeItems=[l])}),i.onCancellationRequested(()=>{a.hide()}),a.onDidHide(()=>{Yt(c),s(void 0)})];a.title=t.title,t.value&&(a.value=t.value),a.canSelectMany=!!t.canPickMany,a.placeholder=t.placeHolder,a.ignoreFocusOut=!!t.ignoreFocusLost,a.matchOnDescription=!!t.matchOnDescription,a.matchOnDetail=!!t.matchOnDetail,a.matchOnLabel=t.matchOnLabel===void 0||t.matchOnLabel,a.quickNavigate=t.quickNavigate,a.hideInput=!!t.hideInput,a.contextKey=t.contextKey,a.busy=!0,Promise.all([e,t.activeItem]).then(([d,u])=>{l=u,a.busy=!1,a.items=d,a.canSelectMany&&(a.selectedItems=d.filter(h=>h.type!=="separator"&&h.picked)),l&&(a.activeItems=[l])}),a.show(),Promise.resolve(e).then(void 0,d=>{r(d),a.hide()})})}createQuickPick(e={useSeparators:!1}){let t=this.getUI(!0);return new v2(t)}createInputBox(){let e=this.getUI(!0);return new BH(e)}show(e){let t=this.getUI(!0);this.onShowEmitter.fire();let i=this.controller;this.controller=e,i?.didHide(),this.setEnabled(!0),t.leftActionBar.clear(),t.title.textContent="",t.description1.textContent="",t.description2.textContent="",oo(t.widget),t.rightActionBar.clear(),t.inlineActionBar.clear(),t.checkAll.checked=!1,t.inputBox.placeholder="",t.inputBox.password=!1,t.inputBox.showDecoration(Mn.Ignore),t.visibleCount.setCount(0),t.count.setCount(0),oo(t.message),t.progressBar.stop(),t.list.setElements([]),t.list.matchOnDescription=!1,t.list.matchOnDetail=!1,t.list.matchOnLabel=!0,t.list.sortByLabel=!0,t.ignoreFocusOut=!1,t.inputBox.toggles=void 0;let o=this.options.backKeybindingLabel();OH.tooltip=o?m("quickInput.backWithKeybinding","Back ({0})",o):m("quickInput.back","Back"),t.container.style.display="",this.updateLayout(),t.inputBox.setFocus(),this.quickInputTypeContext.set(e.type)}isVisible(){return!!this.ui&&this.ui.container.style.display!=="none"}setVisibilities(e){let t=this.getUI();t.title.style.display=e.title?"":"none",t.description1.style.display=e.description&&(e.inputBox||e.checkAll)?"":"none",t.description2.style.display=e.description&&!(e.inputBox||e.checkAll)?"":"none",t.checkAll.style.display=e.checkAll?"":"none",t.inputContainer.style.display=e.inputBox?"":"none",t.filterContainer.style.display=e.inputBox?"":"none",t.visibleCountContainer.style.display=e.visibleCount?"":"none",t.countContainer.style.display=e.count?"":"none",t.okContainer.style.display=e.ok?"":"none",t.customButtonContainer.style.display=e.customButton?"":"none",t.message.style.display=e.message?"":"none",t.progressBar.getContainer().style.display=e.progressBar?"":"none",t.list.displayed=!!e.list,t.container.classList.toggle("show-checkboxes",!!e.checkBox),t.container.classList.toggle("hidden-input",!e.inputBox&&!e.description),this.updateLayout()}setEnabled(e){if(e!==this.enabled){this.enabled=e;for(let t of this.getUI().leftActionBar.viewItems)t.action.enabled=e;for(let t of this.getUI().rightActionBar.viewItems)t.action.enabled=e;this.getUI().checkAll.disabled=!e,this.getUI().inputBox.enabled=e,this.getUI().ok.enabled=e,this.getUI().list.enabled=e}}hide(e){let t=this.controller;if(!t)return;t.willHide(e);let i=this.ui?.container,o=i&&!FB(i);if(this.controller=null,this.onHideEmitter.fire(),i&&(i.style.display="none"),!o){let r=this.previousFocusElement;for(;r&&!r.offsetParent;)r=r.parentElement??void 0;r?.offsetParent?(r.focus(),this.previousFocusElement=void 0):this.options.returnFocus()}t.didHide(e)}layout(e,t){this.dimension=e,this.titleBarOffset=t,this.updateLayout()}updateLayout(){if(this.ui&&this.isVisible()){this.ui.container.style.top=`${this.titleBarOffset}px`;let e=this.ui.container.style,t=Math.min(this.dimension.width*.62,Ode.MAX_WIDTH);e.width=t+"px",e.marginLeft="-"+t/2+"px",this.ui.inputBox.layout(),this.ui.list.layout(this.dimension&&this.dimension.height*.4)}}applyStyles(e){this.styles=e,this.updateStyles()}updateStyles(){if(this.ui){let{quickInputTitleBackground:e,quickInputBackground:t,quickInputForeground:i,widgetBorder:o,widgetShadow:r}=this.styles.widget;this.ui.titleBar.style.backgroundColor=e??"",this.ui.container.style.backgroundColor=t??"",this.ui.container.style.color=i??"",this.ui.container.style.border=o?`1px solid ${o}`:"",this.ui.container.style.boxShadow=r?`0 0 8px 2px ${r}`:"",this.ui.list.style(this.styles.list);let s=[];this.styles.pickerGroup.pickerGroupBorder&&s.push(`.quick-input-list .quick-input-list-entry { border-top-color: ${this.styles.pickerGroup.pickerGroupBorder}; }`),this.styles.pickerGroup.pickerGroupForeground&&s.push(`.quick-input-list .quick-input-list-separator { color: ${this.styles.pickerGroup.pickerGroupForeground}; }`),this.styles.pickerGroup.pickerGroupForeground&&s.push(".quick-input-list .quick-input-list-separator-as-item { color: var(--vscode-descriptionForeground); }"),(this.styles.keybindingLabel.keybindingLabelBackground||this.styles.keybindingLabel.keybindingLabelBorder||this.styles.keybindingLabel.keybindingLabelBottomBorder||this.styles.keybindingLabel.keybindingLabelShadow||this.styles.keybindingLabel.keybindingLabelForeground)&&(s.push(".quick-input-list .monaco-keybinding > .monaco-keybinding-key {"),this.styles.keybindingLabel.keybindingLabelBackground&&s.push(`background-color: ${this.styles.keybindingLabel.keybindingLabelBackground};`),this.styles.keybindingLabel.keybindingLabelBorder&&s.push(`border-color: ${this.styles.keybindingLabel.keybindingLabelBorder};`),this.styles.keybindingLabel.keybindingLabelBottomBorder&&s.push(`border-bottom-color: ${this.styles.keybindingLabel.keybindingLabelBottomBorder};`),this.styles.keybindingLabel.keybindingLabelShadow&&s.push(`box-shadow: inset 0 -1px 0 ${this.styles.keybindingLabel.keybindingLabelShadow};`),this.styles.keybindingLabel.keybindingLabelForeground&&s.push(`color: ${this.styles.keybindingLabel.keybindingLabelForeground};`),s.push("}"));let a=s.join(` `);a!==this.ui.styleSheet.textContent&&(this.ui.styleSheet.textContent=a)}}};Fz=Ode=Mdt([Pde(1,Uc),Pde(2,he),Pde(3,Le)],Fz)});var Pdt,P2,Bz,u5e=k(()=>{ci();Ie();it();Fe();nb();Ml();tFe();pg();Wn();Yi();HH();d5e();en();ke();Pdt=function(n,e,t,i){var o=arguments.length,r=o<3?e:i===null?i=Object.getOwnPropertyDescriptor(e,t):i,s;if(typeof Reflect=="object"&&typeof Reflect.decorate=="function")r=Reflect.decorate(n,e,t,i);else for(var a=n.length-1;a>=0;a--)(s=n[a])&&(r=(o<3?s(r):o>3?s(e,t,r):s(e,t))||r);return o>3&&r&&Object.defineProperty(e,t,r),r},P2=function(n,e){return function(t,i){e(t,i,n)}},Bz=class extends i9{get controller(){return this._controller||(this._controller=this._register(this.createController())),this._controller}get hasController(){return!!this._controller}get currentQuickInput(){return this.controller.currentQuickInput}get quickAccess(){return this._quickAccess||(this._quickAccess=this._register(this.instantiationService.createInstance(AH))),this._quickAccess}constructor(e,t,i,o,r){super(i),this.instantiationService=e,this.contextKeyService=t,this.layoutService=o,this.configurationService=r,this._onShow=this._register(new A),this._onHide=this._register(new A),this.contexts=new Map}createController(e=this.layoutService,t){let i={idPrefix:"quickInput_",container:e.activeContainer,ignoreFocusOut:()=>!1,backKeybindingLabel:()=>{},setContextKey:r=>this.setContextKey(r),linkOpenerDelegate:r=>{this.instantiationService.invokeFunction(s=>{s.get(xo).open(r,{allowCommands:!0,fromUserGesture:!0})})},returnFocus:()=>e.focus(),styles:this.computeStyles(),hoverDelegate:this._register(this.instantiationService.createInstance(WH))},o=this._register(this.instantiationService.createInstance(Fz,{...i,...t}));return o.layout(e.activeContainerDimension,e.activeContainerOffset.quickPickTop),this._register(e.onDidLayoutActiveContainer(r=>{Me(e.activeContainer)===Me(o.container)&&o.layout(r,e.activeContainerOffset.quickPickTop)})),this._register(e.onDidChangeActiveContainer(()=>{o.isVisible()||o.layout(e.activeContainerDimension,e.activeContainerOffset.quickPickTop)})),this._register(o.onShow(()=>{this.resetContextKeys(),this._onShow.fire()})),this._register(o.onHide(()=>{this.resetContextKeys(),this._onHide.fire()})),o}setContextKey(e){let t;e&&(t=this.contexts.get(e),t||(t=new me(e,!1).bindTo(this.contextKeyService),this.contexts.set(e,t))),!(t&&t.get())&&(this.resetContextKeys(),t?.set(!0))}resetContextKeys(){this.contexts.forEach(e=>{e.get()&&e.reset()})}pick(e,t,i=Ze.None){return this.controller.pick(e,t,i)}createQuickPick(e={useSeparators:!1}){return this.controller.createQuickPick(e)}createInputBox(){return this.controller.createInputBox()}updateStyles(){this.hasController&&this.controller.applyStyles(this.computeStyles())}computeStyles(){return{widget:{quickInputBackground:De(Lse),quickInputForeground:De(MMe),quickInputTitleBackground:De(PMe),widgetBorder:De(W9),widgetShadow:De(qm)},inputBox:II,toggle:LI,countBadge:gW,button:uOe,progressBar:hOe,keybindingLabel:dOe,list:Lp({listBackground:Lse,listFocusBackground:cb,listFocusForeground:lb,listInactiveFocusForeground:lb,listInactiveSelectionIconForeground:jL,listInactiveFocusBackground:cb,listFocusOutline:Zi,listInactiveFocusOutline:Zi}),pickerGroup:{pickerGroupBorder:De(OMe),pickerGroupForeground:De(q9)}}}};Bz=Pdt([P2(0,he),P2(1,Le),P2(2,Vi),P2(3,Uc),P2(4,Ve)],Bz)});var h5e,YC,Fde,Wz,O2,Bde,f5e=k(()=>{Q4e();Ie();mt();Yi();ci();Fe();it();Ure();Po();u5e();sx();en();h5e=function(n,e,t,i){var o=arguments.length,r=o<3?e:i===null?i=Object.getOwnPropertyDescriptor(e,t):i,s;if(typeof Reflect=="object"&&typeof Reflect.decorate=="function")r=Reflect.decorate(n,e,t,i);else for(var a=n.length-1;a>=0;a--)(s=n[a])&&(r=(o<3?s(r):o>3?s(e,t,r):s(e,t))||r);return o>3&&r&&Object.defineProperty(e,t,r),r},YC=function(n,e){return function(t,i){e(t,i,n)}},Fde=class extends Bz{constructor(e,t,i,o,r,s){super(t,i,o,new r9(e.getContainerDomNode(),r),s),this.host=void 0;let a=O2.get(e);if(a){let l=a.widget;this.host={_serviceBrand:void 0,get mainContainer(){return l.getDomNode()},getContainer(){return l.getDomNode()},whenContainerStylesLoaded(){},get containers(){return[l.getDomNode()]},get activeContainer(){return l.getDomNode()},get mainContainerDimension(){return e.getLayoutInfo()},get activeContainerDimension(){return e.getLayoutInfo()},get onDidLayoutMainContainer(){return e.onDidLayoutChange},get onDidLayoutActiveContainer(){return e.onDidLayoutChange},get onDidLayoutContainer(){return ne.map(e.onDidLayoutChange,c=>({container:l.getDomNode(),dimension:c}))},get onDidChangeActiveContainer(){return ne.None},get onDidAddContainer(){return ne.None},get mainContainerOffset(){return{top:0,quickPickTop:0}},get activeContainerOffset(){return{top:0,quickPickTop:0}},focus:()=>e.focus()}}else this.host=void 0}createController(){return super.createController(this.host)}};Fde=h5e([YC(1,he),YC(2,Le),YC(3,Vi),YC(4,xt),YC(5,Ve)],Fde);Wz=class{get activeService(){let e=this.codeEditorService.getFocusedCodeEditor();if(!e)throw new Error("Quick input service needs a focused editor to work.");let t=this.mapEditorToService.get(e);if(!t){let i=t=this.instantiationService.createInstance(Fde,e);this.mapEditorToService.set(e,t),yd(e.onDidDispose)(()=>{i.dispose(),this.mapEditorToService.delete(e)})}return t}get currentQuickInput(){return this.activeService.currentQuickInput}get quickAccess(){return this.activeService.quickAccess}constructor(e,t){this.instantiationService=e,this.codeEditorService=t,this.mapEditorToService=new Map}pick(e,t,i=Ze.None){return this.activeService.pick(e,t,i)}createQuickPick(e={useSeparators:!1}){return this.activeService.createQuickPick(e)}createInputBox(){return this.activeService.createInputBox()}};Wz=h5e([YC(0,he),YC(1,xt)],Wz);O2=class n{static{this.ID="editor.controller.quickInput"}static get(e){return e.getContribution(n.ID)}constructor(e){this.editor=e,this.widget=new Bde(this.editor)}dispose(){this.widget.dispose()}},Bde=class n{static{this.ID="editor.contrib.quickInputWidget"}constructor(e){this.codeEditor=e,this.domNode=document.createElement("div"),this.codeEditor.addOverlayWidget(this)}getId(){return n.ID}getDomNode(){return this.domNode}getPosition(){return{preference:2}}dispose(){this.codeEditor.removeOverlayWidget(this)}};ze(O2.ID,O2,4)});function Odt(n){if(!n||!Array.isArray(n))return[];let e=[],t=0;for(let i=0,o=n.length;i{let h=zdt(d.token,u.token);return h!==0?h:d.index-u.index});let t=0,i="000000",o="ffffff";for(;n.length>=1&&n[0].token==="";){let d=n.shift();d.fontStyle!==-1&&(t=d.fontStyle),d.foreground!==null&&(i=d.foreground),d.background!==null&&(o=d.background)}let r=new Hde;for(let d of e)r.getId(d);let s=r.getId(i),a=r.getId(o),l=new zde(t,s,a),c=new Vde(l);for(let d=0,u=n.length;de?1:0}function p5e(n){let e=[];for(let t=1,i=n.length;t{vo();Wde=class{constructor(e,t,i,o,r){this._parsedThemeRuleBrand=void 0,this.token=e,this.index=t,this.fontStyle=i,this.foreground=o,this.background=r}};Bdt=/^#?([0-9A-Fa-f]{6})([0-9A-Fa-f]{2})?$/,Hde=class{constructor(){this._lastColorId=0,this._id2color=[],this._color2id=new Map}getId(e){if(e===null)return 0;let t=e.match(Bdt);if(!t)throw new Error("Illegal value for token color: "+e);e=t[1].toUpperCase();let i=this._color2id.get(e);return i||(i=++this._lastColorId,this._color2id.set(e,i),this._id2color[i]=Z.fromHex("#"+e),i)}getColorMap(){return this._id2color.slice(0)}},F2=class{static createFromRawTokenTheme(e,t){return this.createFromParsedTokenTheme(Odt(e),t)}static createFromParsedTokenTheme(e,t){return Fdt(e,t)}constructor(e,t){this._colorMap=e,this._root=t,this._cache=new Map}getColorMap(){return this._colorMap.getColorMap()}_match(e){return this._root.match(e)}match(e,t){let i=this._cache.get(t);if(typeof i>"u"){let o=this._match(t),r=Hdt(t);i=(o.metadata|r<<8)>>>0,this._cache.set(t,i)}return(i|e<<0)>>>0}},Wdt=/\b(comment|string|regex|regexp)\b/;zde=class n{constructor(e,t,i){this._themeTrieElementRuleBrand=void 0,this._fontStyle=e,this._foreground=t,this._background=i,this.metadata=(this._fontStyle<<11|this._foreground<<15|this._background<<24)>>>0}clone(){return new n(this._fontStyle,this._foreground,this._background)}acceptOverwrite(e,t,i){e!==-1&&(this._fontStyle=e),t!==0&&(this._foreground=t),i!==0&&(this._background=i),this.metadata=(this._fontStyle<<11|this._foreground<<15|this._background<<24)>>>0}},Vde=class n{constructor(e){this._themeTrieElementBrand=void 0,this._mainRule=e,this._children=new Map}match(e){if(e==="")return this._mainRule;let t=e.indexOf("."),i,o;t===-1?(i=e,o=""):(i=e.substring(0,t),o=e.substring(t+1));let r=this._children.get(i);return typeof r<"u"?r.match(o):this._mainRule}insert(e,t,i,o){if(e===""){this._mainRule.acceptOverwrite(t,i,o);return}let r=e.indexOf("."),s,a;r===-1?(s=e,a=""):(s=e.substring(0,r),a=e.substring(r+1));let l=this._children.get(s);typeof l>"u"&&(l=new n(this._mainRule.clone()),this._children.set(s,l)),l.insert(a,t,i,o)}}});var g5e,_5e,b5e,v5e,x5e=k(()=>{Nu();Wn();g5e={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:{[$c]:"#FFFFFE",[ku]:"#000000",[mse]:"#E5EBF1",[TC]:"#D3D3D3",[DC]:"#939393",[tM]:"#ADD6FF4D"}},_5e={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:{[$c]:"#1E1E1E",[ku]:"#D4D4D4",[mse]:"#3A3D41",[TC]:"#404040",[DC]:"#707070",[tM]:"#ADD6FF26"}},b5e={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:{[$c]:"#000000",[ku]:"#FFFFFF",[TC]:"#FFFFFF",[DC]:"#FFFFFF"}},v5e={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:{[$c]:"#FFFFFF",[ku]:"#292929",[TC]:"#292929",[DC]:"#292929"}}});function Fi(n,e,t,i){return ZC.registerIcon(n,e,t,i)}function $de(){return ZC}function Udt(){let n=n8();for(let e in n){let t="\\"+n[e].toString(16);ZC.registerIcon(e,{fontCharacter:t})}}var Vdt,w5e,y5e,Ude,ZC,S5e,k5e,C5e,Hz,Gfi,Yfi,Zfi,Xfi,$d=k(()=>{ft();Qi();zR();bn();Ie();yi();Ai();pe();w6();br();Vdt={IconContribution:"base.contributions.icons"};(function(n){function e(t,i){let o=t.defaults;for(;Oe.isThemeIcon(o);){let r=ZC.getIcon(o.id);if(!r)return;o=r.defaults}return o}n.getDefinition=e})(w5e||(w5e={}));(function(n){function e(i){return{weight:i.weight,style:i.style,src:i.src.map(o=>({format:o.format,location:o.location.toString()}))}}n.toJSONObject=e;function t(i){let o=r=>Rr(r)?r:void 0;if(i&&Array.isArray(i.src)&&i.src.every(r=>Rr(r.format)&&Rr(r.location)))return{weight:o(i.weight),style:o(i.style),src:i.src.map(r=>({format:r.format,location:Ee.parse(r.location)}))}}n.fromJSONObject=t})(y5e||(y5e={}));Ude=class{constructor(){this._onDidChange=new A,this.onDidChange=this._onDidChange.event,this.iconSchema={definitions:{icons:{type:"object",properties:{fontId:{type:"string",description:m("iconDefinition.fontId","The id of the font to use. If not set, the font that is defined first is used.")},fontCharacter:{type:"string",description:m("iconDefinition.fontCharacter","The font character associated with the icon definition.")}},additionalProperties:!1,defaultSnippets:[{body:{fontCharacter:"\\\\e030"}}]}},type:"object",properties:{}},this.iconReferenceSchema={type:"string",pattern:`^${Oe.iconNameExpression}$`,enum:[],enumDescriptions:[]},this.iconsById={},this.iconFontsById={}}registerIcon(e,t,i,o){let r=this.iconsById[e];if(r){if(i&&!r.description){r.description=i,this.iconSchema.properties[e].markdownDescription=`${i} $(${e})`;let l=this.iconReferenceSchema.enum.indexOf(e);l!==-1&&(this.iconReferenceSchema.enumDescriptions[l]=i),this._onDidChange.fire()}return r}let s={id:e,description:i,defaults:t,deprecationMessage:o};this.iconsById[e]=s;let a={$ref:"#/definitions/icons"};return o&&(a.deprecationMessage=o),i&&(a.markdownDescription=`${i}: $(${e})`),this.iconSchema.properties[e]=a,this.iconReferenceSchema.enum.push(e),this.iconReferenceSchema.enumDescriptions.push(i||""),this._onDidChange.fire(),{id:e}}getIcons(){return Object.keys(this.iconsById).map(e=>this.iconsById[e])}getIcon(e){return this.iconsById[e]}getIconSchema(){return this.iconSchema}toString(){let e=(r,s)=>r.id.localeCompare(s.id),t=r=>{for(;Oe.isThemeIcon(r.defaults);)r=this.iconsById[r.defaults.id];return`codicon codicon-${r?r.id:""}`},i=[];i.push("| preview | identifier | default codicon ID | description"),i.push("| ----------- | --------------------------------- | --------------------------------- | --------------------------------- |");let o=Object.keys(this.iconsById).map(r=>this.iconsById[r]);for(let r of o.filter(s=>!!s.description).sort(e))i.push(`||${r.id}|${Oe.isThemeIcon(r.defaults)?r.defaults.id:r.id}|${r.description||""}|`);i.push("| preview | identifier "),i.push("| ----------- | --------------------------------- |");for(let r of o.filter(s=>!Oe.isThemeIcon(s.defaults)).sort(e))i.push(`||${r.id}|`);return i.join(` `)}},ZC=new Ude;ei.add(Vdt.IconContribution,ZC);Udt();S5e="vscode://schemas/icons",k5e=ei.as(V1.JSONContribution);k5e.registerSchema(S5e,ZC.getIconSchema());C5e=new Lt(()=>k5e.notifySchemaChanged(S5e),200);ZC.onDidChange(()=>{C5e.isScheduled()||C5e.schedule()});Hz=Fi("widget-close",oe.close,m("widgetClose","Icon for the close action in widgets.")),Gfi=Fi("goto-previous-location",oe.arrowUp,m("previousChangeIcon","Icon for goto previous editor location.")),Yfi=Fi("goto-next-location",oe.arrowDown,m("nextChangeIcon","Icon for goto next editor location.")),Zfi=Oe.modify(oe.sync,"spin"),Xfi=Oe.modify(oe.loading,"spin")});function L5e(n){let e=new H,t=e.add(new A),i=$de();return e.add(i.onDidChange(()=>t.fire())),n&&e.add(n.onDidProductIconThemeChange(()=>t.fire())),{dispose:()=>e.dispose(),onDidChange:t.event,getCSS(){let o=n?n.getProductIconTheme():new B2,r={},s=[],a=[];for(let l of i.getIcons()){let c=o.getIcon(l);if(!c)continue;let d=c.font,u=`--vscode-icon-${l.id}-font-family`,h=`--vscode-icon-${l.id}-content`;d?(r[d.id]=d.definition,a.push(`${u}: ${zB(d.id)};`,`${h}: '${c.fontCharacter}';`),s.push(`.codicon-${l.id}:before { content: '${c.fontCharacter}'; font-family: ${zB(d.id)}; }`)):(a.push(`${h}: '${c.fontCharacter}'; ${u}: 'codicon';`),s.push(`.codicon-${l.id}:before { content: '${c.fontCharacter}'; }`))}for(let l in r){let c=r[l],d=c.weight?`font-weight: ${c.weight};`:"",u=c.style?`font-style: ${c.style};`:"",h=c.src.map(f=>`${_u(f.location)} format('${f.format}')`).join(", ");s.push(`@font-face { src: ${h}; font-family: ${zB(l)};${d}${u} font-display: block; }`)}return s.push(`:root { ${a.join(" ")} }`),s.join(` `)}}}var B2,I5e=k(()=>{ke();Ie();j();bn();$d();B2=class{getIcon(e){let t=$de(),i=e.defaults;for(;Oe.isThemeIcon(i);){let o=t.getIcon(i.id);if(!o)return;i=o.defaults}return i}}});function Vz(n){return n===Mg||n===XC||n===Sw||n===kw}function jde(n){switch(n){case Mg:return g5e;case XC:return _5e;case Sw:return b5e;case kw:return v5e}}function zz(n){let e=jde(n);return new Uz(n,e)}var Mg,XC,Sw,kw,E5e,$dt,Uz,$z,qde=k(()=>{ke();Fc();vo();Ie();Ji();tC();m5e();x5e();br();Wn();Yi();j();wf();I5e();Il();Mg="vs",XC="vs-dark",Sw="hc-black",kw="hc-light",E5e=ei.as(dse.ColorContribution),$dt=ei.as(zre.ThemingContribution),Uz=class{constructor(e,t){this.semanticHighlighting=!1,this.themeData=t;let i=t.base;e.length>0?(Vz(e)?this.id=e:this.id=i+" "+e,this.themeName=e):(this.id=i,this.themeName=i),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){let e=new Map;for(let t in this.themeData.colors)e.set(t,Z.fromHex(this.themeData.colors[t]));if(this.themeData.inherit){let t=jde(this.themeData.base);for(let i in t.colors)e.has(i)||e.set(i,Z.fromHex(t.colors[i]))}this.colors=e}return this.colors}getColor(e,t){let i=this.getColors().get(e);if(i)return i;if(t!==!1)return this.getDefault(e)}getDefault(e){let t=this.defaultColors[e];return t||(t=E5e.resolveDefaultColor(e,this),this.defaultColors[e]=t,t)}defines(e){return this.getColors().has(e)}get type(){switch(this.base){case Mg:return Md.LIGHT;case Sw:return Md.HIGH_CONTRAST_DARK;case kw:return Md.HIGH_CONTRAST_LIGHT;default:return Md.DARK}}get tokenTheme(){if(!this._tokenTheme){let e=[],t=[];if(this.themeData.inherit){let r=jde(this.themeData.base);e=r.rules,r.encodedTokensColors&&(t=r.encodedTokensColors)}let i=this.themeData.colors["editor.foreground"],o=this.themeData.colors["editor.background"];if(i||o){let r={token:""};i&&(r.foreground=i),o&&(r.background=o),e.push(r)}e=e.concat(this.themeData.rules),this.themeData.encodedTokensColors&&(t=this.themeData.encodedTokensColors),this._tokenTheme=F2.createFromRawTokenTheme(e,t)}return this._tokenTheme}getTokenStyleMetadata(e,t,i){let r=this.tokenTheme._match([e].concat(t).join(".")).metadata,s=Go.getForeground(r),a=Go.getFontStyle(r);return{foreground:s,italic:!!(a&1),bold:!!(a&2),underline:!!(a&4),strikethrough:!!(a&8)}}};$z=class extends D{constructor(){super(),this._onColorThemeChange=this._register(new A),this.onDidColorThemeChange=this._onColorThemeChange.event,this._onProductIconThemeChange=this._register(new A),this.onDidProductIconThemeChange=this._onProductIconThemeChange.event,this._environment=Object.create(null),this._builtInProductIconTheme=new B2,this._autoDetectHighContrast=!0,this._knownThemes=new Map,this._knownThemes.set(Mg,zz(Mg)),this._knownThemes.set(XC,zz(XC)),this._knownThemes.set(Sw,zz(Sw)),this._knownThemes.set(kw,zz(kw));let e=this._register(L5e(this));this._codiconCSS=e.getCSS(),this._themeCSS="",this._allCSS=`${this._codiconCSS} ${this._themeCSS}`,this._globalStyleElement=null,this._styleElements=[],this._colorMapOverride=null,this.setTheme(Mg),this._onOSSchemeChanged(),this._register(e.onDidChange(()=>{this._codiconCSS=e.getCSS(),this._updateCSS()})),Pne(ri,"(forced-colors: active)",()=>{this._onOSSchemeChanged()})}registerEditorContainer(e){return T1(e)?this._registerShadowDomContainer(e):this._registerRegularEditorContainer()}_registerRegularEditorContainer(){return this._globalStyleElement||(this._globalStyleElement=qr(void 0,e=>{e.className="monaco-colors",e.textContent=this._allCSS}),this._styleElements.push(this._globalStyleElement)),D.None}_registerShadowDomContainer(e){let t=qr(e,i=>{i.className="monaco-colors",i.textContent=this._allCSS});return this._styleElements.push(t),{dispose:()=>{for(let i=0;i{i.base===e&&i.notifyBaseUpdated()}),this._theme.themeName===e&&this.setTheme(e)}getColorTheme(){return this._theme}setColorMapOverride(e){this._colorMapOverride=e,this._updateThemeOrColorMap()}setTheme(e){let t;this._knownThemes.has(e)?t=this._knownThemes.get(e):t=this._knownThemes.get(Mg),this._updateActualTheme(t)}_updateActualTheme(e){!e||this._theme===e||(this._theme=e,this._updateThemeOrColorMap())}_onOSSchemeChanged(){if(this._autoDetectHighContrast){let e=ri.matchMedia("(forced-colors: active)").matches;if(e!==nl(this._theme.type)){let t;Vm(this._theme.type)?t=e?Sw:XC:t=e?kw:Mg,this._updateActualTheme(this._knownThemes.get(t))}}}setAutoDetectHighContrast(e){this._autoDetectHighContrast=e,this._onOSSchemeChanged()}_updateThemeOrColorMap(){let e=[],t={},i={addRule:s=>{t[s]||(e.push(s),t[s]=!0)}};$dt.getThemingParticipants().forEach(s=>s(this._theme,i,this._environment));let o=[];for(let s of E5e.getColors()){let a=this._theme.getColor(s.id,!0);a&&o.push(`${E9(s.id)}: ${a.toString()};`)}i.addRule(`.monaco-editor, .monaco-diff-editor, .monaco-component { ${o.join(` `)} }`);let r=this._colorMapOverride||this._theme.tokenTheme.getColorMap();i.addRule(p5e(r)),this._themeCSS=e.join(` `),this._updateCSS(),$i.setColorMap(r),this._onColorThemeChange.fire(this._theme)}_updateCSS(){this._allCSS=`${this._codiconCSS} ${this._themeCSS}`,this._styleElements.forEach(e=>e.textContent=this._allCSS)}getFileIconTheme(){return{hasFileIcons:!1,hasFolderIcons:!1,hidesExplorerArrows:!1}}getProductIconTheme(){return this._builtInProductIconTheme}}});var La,QC=k(()=>{Fe();La=We("themeService")});var jdt,Kde,jz,T5e=k(()=>{ke();Il();Ie();j();uc();en();it();nb();jdt=function(n,e,t,i){var o=arguments.length,r=o<3?e:i===null?i=Object.getOwnPropertyDescriptor(e,t):i,s;if(typeof Reflect=="object"&&typeof Reflect.decorate=="function")r=Reflect.decorate(n,e,t,i);else for(var a=n.length-1;a>=0;a--)(s=n[a])&&(r=(o<3?s(r):o>3?s(e,t,r):s(e,t))||r);return o>3&&r&&Object.defineProperty(e,t,r),r},Kde=function(n,e){return function(t,i){e(t,i,n)}},jz=class extends D{constructor(e,t,i){super(),this._contextKeyService=e,this._layoutService=t,this._configurationService=i,this._accessibilitySupport=0,this._onDidChangeScreenReaderOptimized=new A,this._onDidChangeReducedMotion=new A,this._onDidChangeLinkUnderline=new A,this._accessibilityModeEnabledContext=mC.bindTo(this._contextKeyService);let o=()=>this._accessibilityModeEnabledContext.set(this.isScreenReaderOptimized());this._register(this._configurationService.onDidChangeConfiguration(s=>{s.affectsConfiguration("editor.accessibilitySupport")&&(o(),this._onDidChangeScreenReaderOptimized.fire()),s.affectsConfiguration("workbench.reduceMotion")&&(this._configMotionReduced=this._configurationService.getValue("workbench.reduceMotion"),this._onDidChangeReducedMotion.fire())})),o(),this._register(this.onDidChangeScreenReaderOptimized(()=>o()));let r=ri.matchMedia("(prefers-reduced-motion: reduce)");this._systemMotionReduced=r.matches,this._configMotionReduced=this._configurationService.getValue("workbench.reduceMotion"),this._linkUnderlinesEnabled=this._configurationService.getValue("accessibility.underlineLinks"),this.initReducedMotionListeners(r),this.initLinkUnderlineListeners()}initReducedMotionListeners(e){this._register(U(e,"change",()=>{this._systemMotionReduced=e.matches,this._configMotionReduced==="auto"&&this._onDidChangeReducedMotion.fire()}));let t=()=>{let i=this.isMotionReduced();this._layoutService.mainContainer.classList.toggle("reduce-motion",i),this._layoutService.mainContainer.classList.toggle("enable-motion",!i)};t(),this._register(this.onDidChangeReducedMotion(()=>t()))}initLinkUnderlineListeners(){this._register(this._configurationService.onDidChangeConfiguration(t=>{if(t.affectsConfiguration("accessibility.underlineLinks")){let i=this._configurationService.getValue("accessibility.underlineLinks");this._linkUnderlinesEnabled=i,this._onDidChangeLinkUnderline.fire()}}));let e=()=>{let t=this._linkUnderlinesEnabled;this._layoutService.mainContainer.classList.toggle("underline-links",t)};e(),this._register(this.onDidChangeLinkUnderlines(()=>e()))}onDidChangeLinkUnderlines(e){return this._onDidChangeLinkUnderline.event(e)}get onDidChangeScreenReaderOptimized(){return this._onDidChangeScreenReaderOptimized.event}isScreenReaderOptimized(){let e=this._configurationService.getValue("editor.accessibilitySupport");return e==="on"||e==="auto"&&this._accessibilitySupport===2}get onDidChangeReducedMotion(){return this._onDidChangeReducedMotion.event}isMotionReduced(){let e=this._configMotionReduced;return e==="on"||e==="auto"&&this._systemMotionReduced}getAccessibilitySupport(){return this._accessibilitySupport}};jz=jdt([Kde(0,Le),Kde(1,Uc),Kde(2,Ve)],jz)});function qdt(n,e,t){let i=VDe(e)?e.submenu.id:e.id,o=typeof e.title=="string"?e.title:e.title.value,r=Dm({id:`hide/${n.id}/${i}`,label:m("hide.label","Hide '{0}'",o),run(){t.updateHidden(n,i,!0)}}),s=Dm({id:`toggle/${n.id}/${i}`,label:o,get checked(){return!t.isHidden(n,i)},run(){t.updateHidden(n,i,!!this.checked)}});return{hide:r,toggle:s,get isHidden(){return!s.checked}}}function Xde(n,e,t,i=void 0,o=!0){return Dm({id:`configureKeybinding/${t}`,label:m("configure keybinding","Configure Keybinding"),enabled:o,run(){let s=!!!e.lookupKeybinding(t)&&i?i.serialize():void 0;n.executeCommand("workbench.action.openGlobalKeybindings",`@command:${t}`+(s?` +when:${s}`:""))}})}var Gz,Pg,dE,W2,qz,Gde,Yde,Zde,Kz,Qde=k(()=>{ft();Ie();j();an();Gi();it();Gr();kp();at();pe();Pn();Gz=function(n,e,t,i){var o=arguments.length,r=o<3?e:i===null?i=Object.getOwnPropertyDescriptor(e,t):i,s;if(typeof Reflect=="object"&&typeof Reflect.decorate=="function")r=Reflect.decorate(n,e,t,i);else for(var a=n.length-1;a>=0;a--)(s=n[a])&&(r=(o<3?s(r):o>3?s(e,t,r):s(e,t))||r);return o>3&&r&&Object.defineProperty(e,t,r),r},Pg=function(n,e){return function(t,i){e(t,i,n)}},qz=class{constructor(e,t,i){this._commandService=e,this._keybindingService=t,this._hiddenStates=new Gde(i)}createMenu(e,t,i){return new Kz(e,this._hiddenStates,{emitEventsForSubmenuChanges:!1,eventDebounceDelay:50,...i},this._commandService,this._keybindingService,t)}getMenuActions(e,t,i){let o=new Kz(e,this._hiddenStates,{emitEventsForSubmenuChanges:!1,eventDebounceDelay:50,...i},this._commandService,this._keybindingService,t),r=o.getActions(i);return o.dispose(),r}resetHiddenStates(e){this._hiddenStates.reset(e)}};qz=Gz([Pg(0,$t),Pg(1,_t),Pg(2,Fs)],qz);Gde=class{static{dE=this}static{this._key="menu.hiddenCommands"}constructor(e){this._storageService=e,this._disposables=new H,this._onDidChange=new A,this.onDidChange=this._onDidChange.event,this._ignoreChangeEvent=!1,this._hiddenByDefaultCache=new Map;try{let t=e.get(dE._key,0,"{}");this._data=JSON.parse(t)}catch{this._data=Object.create(null)}this._disposables.add(e.onDidChangeValue(0,dE._key,this._disposables)(()=>{if(!this._ignoreChangeEvent)try{let t=e.get(dE._key,0,"{}");this._data=JSON.parse(t)}catch(t){console.log("FAILED to read storage after UPDATE",t)}this._onDidChange.fire()}))}dispose(){this._onDidChange.dispose(),this._disposables.dispose()}_isHiddenByDefault(e,t){return this._hiddenByDefaultCache.get(`${e.id}/${t}`)??!1}setDefaultState(e,t,i){this._hiddenByDefaultCache.set(`${e.id}/${t}`,i)}isHidden(e,t){let i=this._isHiddenByDefault(e,t),o=this._data[e.id]?.includes(t)??!1;return i?!o:o}updateHidden(e,t,i){this._isHiddenByDefault(e,t)&&(i=!i);let r=this._data[e.id];if(i)r?r.indexOf(t)<0&&r.push(t):this._data[e.id]=[t];else if(r){let s=r.indexOf(t);s>=0&&OEe(r,s),r.length===0&&delete this._data[e.id]}this._persist()}reset(e){if(e===void 0)this._data=Object.create(null),this._persist();else{for(let{id:t}of e)this._data[t]&&delete this._data[t];this._persist()}}_persist(){try{this._ignoreChangeEvent=!0;let e=JSON.stringify(this._data);this._storageService.store(dE._key,e,0,0)}finally{this._ignoreChangeEvent=!1}}};Gde=dE=Gz([Pg(0,Fs)],Gde);Yde=class n{constructor(e,t){this._id=e,this._collectContextKeysForSubmenus=t,this._menuGroups=[],this._allMenuIds=new Set,this._structureContextKeys=new Set,this._preconditionContextKeys=new Set,this._toggledContextKeys=new Set,this.refresh()}get allMenuIds(){return this._allMenuIds}get structureContextKeys(){return this._structureContextKeys}get preconditionContextKeys(){return this._preconditionContextKeys}get toggledContextKeys(){return this._toggledContextKeys}refresh(){this._menuGroups.length=0,this._allMenuIds.clear(),this._structureContextKeys.clear(),this._preconditionContextKeys.clear(),this._toggledContextKeys.clear();let e=this._sort(Lo.getMenuItems(this._id)),t;for(let i of e){let o=i.group||"";(!t||t[0]!==o)&&(t=[o,[]],this._menuGroups.push(t)),t[1].push(i),this._collectContextKeysAndSubmenuIds(i)}this._allMenuIds.add(this._id)}_sort(e){return e}_collectContextKeysAndSubmenuIds(e){if(n._fillInKbExprKeys(e.when,this._structureContextKeys),Lx(e)){if(e.command.precondition&&n._fillInKbExprKeys(e.command.precondition,this._preconditionContextKeys),e.command.toggled){let t=e.command.toggled.condition||e.command.toggled;n._fillInKbExprKeys(t,this._toggledContextKeys)}}else this._collectContextKeysForSubmenus&&(Lo.getMenuItems(e.submenu).forEach(this._collectContextKeysAndSubmenuIds,this),this._allMenuIds.add(e.submenu))}static _fillInKbExprKeys(e,t){if(e)for(let i of e.keys())t.add(i)}},Zde=W2=class extends Yde{constructor(e,t,i,o,r,s){super(e,i),this._hiddenStates=t,this._commandService=o,this._keybindingService=r,this._contextKeyService=s,this.refresh()}createActionGroups(e){let t=[];for(let i of this._menuGroups){let[o,r]=i,s;for(let a of r)if(this._contextKeyService.contextMatchesRules(a.when)){let l=Lx(a);l&&this._hiddenStates.setDefaultState(this._id,a.command.id,!!a.isHiddenByDefault);let c=qdt(this._id,l?a.command:a,this._hiddenStates);if(l){let d=Xde(this._commandService,this._keybindingService,a.command.id,a.when);(s??=[]).push(new Es(a.command,a.alt,e,c,d,this._contextKeyService,this._commandService))}else{let d=new W2(a.submenu,this._hiddenStates,this._collectContextKeysForSubmenus,this._commandService,this._keybindingService,this._contextKeyService).createActionGroups(e),u=Gn.join(...d.map(h=>h[1]));u.length>0&&(s??=[]).push(new vf(a,c,u))}}s&&s.length>0&&t.push([o,s])}return t}_sort(e){return e.sort(W2._compareMenuItems)}static _compareMenuItems(e,t){let i=e.group,o=t.group;if(i!==o){if(i){if(!o)return-1}else return 1;if(i==="navigation")return-1;if(o==="navigation")return 1;let a=i.localeCompare(o);if(a!==0)return a}let r=e.order||0,s=t.order||0;return rs?1:W2._compareTitles(Lx(e)?e.command.title:e.title,Lx(t)?t.command.title:t.title)}static _compareTitles(e,t){let i=typeof e=="string"?e:e.original,o=typeof t=="string"?t:t.original;return i.localeCompare(o)}};Zde=W2=Gz([Pg(3,$t),Pg(4,_t),Pg(5,Le)],Zde);Kz=class{constructor(e,t,i,o,r,s){this._disposables=new H,this._menuInfo=new Zde(e,t,i.emitEventsForSubmenuChanges,o,r,s);let a=new Lt(()=>{this._menuInfo.refresh(),this._onDidChange.fire({menu:this,isStructuralChange:!0,isEnablementChange:!0,isToggleChange:!0})},i.eventDebounceDelay);this._disposables.add(a),this._disposables.add(Lo.onDidChangeMenu(u=>{for(let h of this._menuInfo.allMenuIds)if(u.has(h)){a.schedule();break}}));let l=this._disposables.add(new H),c=u=>{let h=!1,f=!1,p=!1;for(let g of u)if(h=h||g.isStructuralChange,f=f||g.isEnablementChange,p=p||g.isToggleChange,h&&f&&p)break;return{menu:this,isStructuralChange:h,isEnablementChange:f,isToggleChange:p}},d=()=>{l.add(s.onDidChangeContext(u=>{let h=u.affectsSome(this._menuInfo.structureContextKeys),f=u.affectsSome(this._menuInfo.preconditionContextKeys),p=u.affectsSome(this._menuInfo.toggledContextKeys);(h||f||p)&&this._onDidChange.fire({menu:this,isStructuralChange:h,isEnablementChange:f,isToggleChange:p})})),l.add(t.onDidChange(u=>{this._onDidChange.fire({menu:this,isStructuralChange:!0,isEnablementChange:!1,isToggleChange:!1})}))};this._onDidChange=new Yk({onWillAddFirstListener:d,onDidRemoveLastListener:l.clear.bind(l),delay:i.eventDebounceDelay,merge:c}),this.onDidChange=this._onDidChange.event}getActions(e){return this._menuInfo.createActionGroups(e)}dispose(){this._disposables.dispose(),this._onDidChange.dispose()}};Kz=Gz([Pg(3,$t),Pg(4,_t),Pg(5,Le)],Kz)});var Kdt,D5e,Jde,N5e,Yz,R5e=k(()=>{Fc();ke();Il();ft();Ie();wx();j();Ai();nb();ac();Kdt=function(n,e,t,i){var o=arguments.length,r=o<3?e:i===null?i=Object.getOwnPropertyDescriptor(e,t):i,s;if(typeof Reflect=="object"&&typeof Reflect.decorate=="function")r=Reflect.decorate(n,e,t,i);else for(var a=n.length-1;a>=0;a--)(s=n[a])&&(r=(o<3?s(r):o>3?s(e,t,r):s(e,t))||r);return o>3&&r&&Object.defineProperty(e,t,r),r},D5e=function(n,e){return function(t,i){e(t,i,n)}},N5e="application/vnd.code.resources",Yz=class extends D{static{Jde=this}constructor(e,t){super(),this.layoutService=e,this.logService=t,this.mapTextToType=new Map,this.findText="",this.resources=[],this.resourcesStateHash=void 0,(Ld||uB)&&this.installWebKitWriteTextWorkaround(),this._register(ne.runAndSubscribe(I1,({window:i,disposables:o})=>{o.add(U(i.document,"copy",()=>this.clearResourcesState()))},{window:ri,disposables:this._store}))}installWebKitWriteTextWorkaround(){let e=()=>{let t=new mu;this.webKitPendingClipboardWritePromise&&!this.webKitPendingClipboardWritePromise.isSettled&&this.webKitPendingClipboardWritePromise.cancel(),this.webKitPendingClipboardWritePromise=t,N1().navigator.clipboard.write([new ClipboardItem({"text/plain":t.p})]).catch(async i=>{(!(i instanceof Error)||i.name!=="NotAllowedError"||!t.isRejected)&&this.logService.error(i)})};this._register(ne.runAndSubscribe(this.layoutService.onDidAddContainer,({container:t,disposables:i})=>{i.add(U(t,"click",e)),i.add(U(t,"keydown",e))},{container:this.layoutService.mainContainer,disposables:this._store}))}async writeText(e,t){if(this.clearResourcesState(),t){this.mapTextToType.set(t,e);return}if(this.webKitPendingClipboardWritePromise)return this.webKitPendingClipboardWritePromise.complete(e);try{return await N1().navigator.clipboard.writeText(e)}catch(i){console.error(i)}this.fallbackWriteText(e)}fallbackWriteText(e){let t=q_(),i=t.activeElement,o=t.body.appendChild(J("textarea",{"aria-hidden":!0}));o.style.height="1px",o.style.width="1px",o.style.position="absolute",o.value=e,o.focus(),o.select(),t.execCommand("copy"),_n(i)&&i.focus(),o.remove()}async readText(e){if(e)return this.mapTextToType.get(e)||"";try{return await N1().navigator.clipboard.readText()}catch(t){console.error(t)}return""}async readFindText(){return this.findText}async writeFindText(e){this.findText=e}static{this.MAX_RESOURCE_STATE_SOURCE_LENGTH=1e3}async readResources(){try{let t=await N1().navigator.clipboard.read();for(let i of t)if(i.types.includes(`web ${N5e}`)){let o=await i.getType(`web ${N5e}`);return JSON.parse(await o.text()).map(s=>Ee.from(s))}}catch{}let e=await this.computeResourcesStateHash();return this.resourcesStateHash!==e&&this.clearResourcesState(),this.resources}async computeResourcesStateHash(){if(this.resources.length===0)return;let e=await this.readText();return xx(e.substring(0,Jde.MAX_RESOURCE_STATE_SOURCE_LENGTH))}clearInternalState(){this.clearResourcesState()}clearResourcesState(){this.resources=[],this.resourcesStateHash=void 0}};Yz=Jde=Kdt([D5e(0,Uc),D5e(1,Bn)],Yz)});var gc,Mb=k(()=>{Fe();gc=We("clipboardService")});function Zdt(n,e){return n.allKeysContainedIn(new Set(Object.keys(e)))}function Xdt(n){for(;n;){if(n.hasAttribute(H2)){let e=n.getAttribute(H2);return e?parseInt(e,10):NaN}n=n.parentElement}return 0}function Qdt(n,e,t){n.get(Le).createKey(String(e),Jdt(t))}function Jdt(n){return R3(n,e=>{if(typeof e=="object"&&e.$mid===1)return Ee.revive(e).toString();if(e instanceof Ee)return e.toString()})}var Gdt,Ydt,H2,z2,uE,eue,tue,Zz,Xz,iue,Qz,Jz,nue,A5e=k(()=>{Ie();Cl();j();ec();A7();Ai();pe();Gi();en();it();Gdt=function(n,e,t,i){var o=arguments.length,r=o<3?e:i===null?i=Object.getOwnPropertyDescriptor(e,t):i,s;if(typeof Reflect=="object"&&typeof Reflect.decorate=="function")r=Reflect.decorate(n,e,t,i);else for(var a=n.length-1;a>=0;a--)(s=n[a])&&(r=(o<3?s(r):o>3?s(e,t,r):s(e,t))||r);return o>3&&r&&Object.defineProperty(e,t,r),r},Ydt=function(n,e){return function(t,i){e(t,i,n)}},H2="data-keybinding-context",z2=class{constructor(e,t){this._id=e,this._parent=t,this._value=Object.create(null),this._value._contextId=e}get value(){return{...this._value}}setValue(e,t){return this._value[e]!==t?(this._value[e]=t,!0):!1}removeValue(e){return e in this._value?(delete this._value[e],!0):!1}getValue(e){let t=this._value[e];return typeof t>"u"&&this._parent?this._parent.getValue(e):t}},uE=class n extends z2{static{this.INSTANCE=new n}constructor(){super(-1,null)}setValue(e,t){return!1}removeValue(e){return!1}getValue(e){}},eue=class n extends z2{static{this._keyPrefix="config."}constructor(e,t,i){super(e,null),this._configurationService=t,this._values=wC.forConfigKeys(),this._listener=this._configurationService.onDidChangeConfiguration(o=>{if(o.source===7){let r=Array.from(this._values,([s])=>s);this._values.clear(),i.fire(new Xz(r))}else{let r=[];for(let s of o.affectedKeys){let a=`config.${s}`,l=this._values.findSuperstr(a);l!==void 0&&(r.push(...Dt.map(l,([c])=>c)),this._values.deleteSuperstr(a)),this._values.has(a)&&(r.push(a),this._values.delete(a))}i.fire(new Xz(r))}})}dispose(){this._listener.dispose()}getValue(e){if(e.indexOf(n._keyPrefix)!==0)return super.getValue(e);if(this._values.has(e))return this._values.get(e);let t=e.substr(n._keyPrefix.length),i=this._configurationService.getValue(t),o;switch(typeof i){case"number":case"boolean":case"string":o=i;break;default:Array.isArray(i)?o=JSON.stringify(i):o=i}return this._values.set(e,o),o}setValue(e,t){return super.setValue(e,t)}removeValue(e){return super.removeValue(e)}},tue=class{constructor(e,t,i){this._service=e,this._key=t,this._defaultValue=i,this.reset()}set(e){this._service.setContext(this._key,e)}reset(){typeof this._defaultValue>"u"?this._service.removeContext(this._key):this._service.setContext(this._key,this._defaultValue)}get(){return this._service.getContextKeyValue(this._key)}},Zz=class{constructor(e){this.key=e}affectsSome(e){return e.has(this.key)}allKeysContainedIn(e){return this.affectsSome(e)}},Xz=class{constructor(e){this.keys=e}affectsSome(e){for(let t of this.keys)if(e.has(t))return!0;return!1}allKeysContainedIn(e){return this.keys.every(t=>e.has(t))}},iue=class{constructor(e){this.events=e}affectsSome(e){for(let t of this.events)if(t.affectsSome(e))return!0;return!1}allKeysContainedIn(e){return this.events.every(t=>t.allKeysContainedIn(e))}};Qz=class extends D{constructor(e){super(),this._onDidChangeContext=this._register(new lh({merge:t=>new iue(t)})),this.onDidChangeContext=this._onDidChangeContext.event,this._isDisposed=!1,this._myContextId=e}createKey(e,t){if(this._isDisposed)throw new Error("AbstractContextKeyService has been disposed");return new tue(this,e,t)}bufferChangeEvents(e){this._onDidChangeContext.pause();try{e()}finally{this._onDidChangeContext.resume()}}createScoped(e){if(this._isDisposed)throw new Error("AbstractContextKeyService has been disposed");return new nue(this,e)}contextMatchesRules(e){if(this._isDisposed)throw new Error("AbstractContextKeyService has been disposed");let t=this.getContextValuesContainer(this._myContextId);return e?e.evaluate(t):!0}getContextKeyValue(e){if(!this._isDisposed)return this.getContextValuesContainer(this._myContextId).getValue(e)}setContext(e,t){if(this._isDisposed)return;let i=this.getContextValuesContainer(this._myContextId);i&&i.setValue(e,t)&&this._onDidChangeContext.fire(new Zz(e))}removeContext(e){this._isDisposed||this.getContextValuesContainer(this._myContextId).removeValue(e)&&this._onDidChangeContext.fire(new Zz(e))}getContext(e){return this._isDisposed?uE.INSTANCE:this.getContextValuesContainer(Xdt(e))}dispose(){super.dispose(),this._isDisposed=!0}},Jz=class extends Qz{constructor(e){super(0),this._contexts=new Map,this._lastContextId=0;let t=this._register(new eue(this._myContextId,e,this._onDidChangeContext));this._contexts.set(this._myContextId,t)}getContextValuesContainer(e){return this._isDisposed?uE.INSTANCE:this._contexts.get(e)||uE.INSTANCE}createChildContext(e=this._myContextId){if(this._isDisposed)throw new Error("ContextKeyService has been disposed");let t=++this._lastContextId;return this._contexts.set(t,new z2(t,this.getContextValuesContainer(e))),t}disposeContext(e){this._isDisposed||this._contexts.delete(e)}};Jz=Gdt([Ydt(0,Ve)],Jz);nue=class extends Qz{constructor(e,t){if(super(e.createChildContext()),this._parentChangeListener=this._register(new Hi),this._parent=e,this._updateParentChangeListener(),this._domNode=t,this._domNode.hasAttribute(H2)){let i="";this._domNode.classList&&(i=Array.from(this._domNode.classList.values()).join(", ")),console.error(`Element already has context attribute${i?": "+i:""}`)}this._domNode.setAttribute(H2,String(this._myContextId))}_updateParentChangeListener(){this._parentChangeListener.value=this._parent.onDidChangeContext(e=>{let i=this._parent.getContextValuesContainer(this._myContextId).value;Zdt(e,i)||this._onDidChangeContext.fire(e)})}dispose(){this._isDisposed||(this._parent.disposeContext(this._myContextId),this._domNode.removeAttribute(H2),super.dispose())}getContextValuesContainer(e){return this._isDisposed?uE.INSTANCE:this._parent.getContextValuesContainer(e)}createChildContext(e=this._myContextId){if(this._isDisposed)throw new Error("ScopedContextKeyService has been disposed");return this._parent.createChildContext(e)}disposeContext(e){this._isDisposed||this._parent.disposeContext(e)}};wt.registerCommand("_setContext",Qdt);wt.registerCommand({id:"getContextKeyInfo",handler(){return[...me.all()].sort((n,e)=>n.key.localeCompare(e.key))},metadata:{description:m("getContextKeyInfo","A command that returns information about context keys"),args:[]}});wt.registerCommand("_generateContextKeyInfo",function(){let n=[],e=new Set;for(let t of me.all())e.has(t.key)||(e.add(t.key),n.push(t));n.sort((t,i)=>t.key.localeCompare(i.key)),console.log(JSON.stringify(n,void 0,2))})});var oue,V2,M5e=k(()=>{oue=class{constructor(e,t){this.key=e,this.data=t,this.incoming=new Map,this.outgoing=new Map}},V2=class{constructor(e){this._hashFn=e,this._nodes=new Map}roots(){let e=[];for(let t of this._nodes.values())t.outgoing.size===0&&e.push(t);return e}insertEdge(e,t){let i=this.lookupOrInsertNode(e),o=this.lookupOrInsertNode(t);i.outgoing.set(o.key,o),o.incoming.set(i.key,i)}removeNode(e){let t=this._hashFn(e);this._nodes.delete(t);for(let i of this._nodes.values())i.outgoing.delete(t),i.incoming.delete(t)}lookupOrInsertNode(e){let t=this._hashFn(e),i=this._nodes.get(t);return i||(i=new oue(t,e),this._nodes.set(t,i)),i}isEmpty(){return this._nodes.size===0}toString(){let e=[];for(let[t,i]of this._nodes)e.push(`${t} (-> incoming)[${[...i.incoming.keys()].join(", ")}] (outgoing ->)[${[...i.outgoing.keys()].join(",")}] `);return e.join(` `)}findCycleSlow(){for(let[e,t]of this._nodes){let i=new Set([e]),o=this._findCycle(t,i);if(o)return o}}_findCycle(e,t){for(let[i,o]of e.outgoing){if(t.has(i))return[...t,i].join(" -> ");t.add(i);let r=this._findCycle(o,t);if(r)return r;t.delete(i)}}}});var Fu,JC=k(()=>{Fu=class{constructor(...e){this._entries=new Map;for(let[t,i]of e)this.set(t,i)}set(e,t){let i=this._entries.get(e);return this._entries.set(e,t),i}get(e){return this._entries.get(e)}}});var eut,eV,tV,U2,P5e=k(()=>{ft();je();j();x6();M5e();Fe();JC();du();eut=!1,eV=class extends Error{constructor(e){super("cyclic dependency between services"),this.message=e.findCycleSlow()??`UNABLE to detect cycle, dumping graph: ${e.toString()}`}},tV=class n{constructor(e=new Fu,t=!1,i,o=eut){this._services=e,this._strict=t,this._parent=i,this._enableTracing=o,this._isDisposed=!1,this._servicesToMaybeDispose=new Set,this._children=new Set,this._activeInstantiations=new Set,this._services.set(he,this),this._globalGraph=o?i?._globalGraph??new V2(r=>r):void 0}dispose(){if(!this._isDisposed){this._isDisposed=!0,Yt(this._children),this._children.clear();for(let e of this._servicesToMaybeDispose)cx(e)&&e.dispose();this._servicesToMaybeDispose.clear()}}_throwIfDisposed(){if(this._isDisposed)throw new Error("InstantiationService has been disposed")}createChild(e,t){this._throwIfDisposed();let i=this,o=new class extends n{dispose(){i._children.delete(o),super.dispose()}}(e,this._strict,this,this._enableTracing);return this._children.add(o),t?.add(o),o}invokeFunction(e,...t){this._throwIfDisposed();let i=U2.traceInvocation(this._enableTracing,e),o=!1;try{return e({get:s=>{if(o)throw Kk("service accessor is only valid during the invocation of its target method");let a=this._getOrCreateServiceInstance(s,i);if(!a)throw new Error(`[invokeFunction] unknown service '${s}'`);return a}},...t)}finally{o=!0,i.stop()}}createInstance(e,...t){this._throwIfDisposed();let i,o;return e instanceof Dd?(i=U2.traceCreation(this._enableTracing,e.ctor),o=this._createInstance(e.ctor,e.staticArguments.concat(t),i)):(i=U2.traceCreation(this._enableTracing,e),o=this._createInstance(e,t,i)),i.stop(),o}_createInstance(e,t=[],i){let o=gf.getServiceDependencies(e).sort((a,l)=>a.index-l.index),r=[];for(let a of o){let l=this._getOrCreateServiceInstance(a.id,i);l||this._throwIfStrict(`[createInstance] ${e.name} depends on UNKNOWN service ${a.id}.`,!1),r.push(l)}let s=o.length>0?o[0].index:t.length;if(t.length!==s){console.trace(`[createInstance] First service dependency of ${e.name} at position ${s+1} conflicts with ${t.length} static arguments`);let a=s-t.length;a>0?t=t.concat(new Array(a)):t=t.slice(0,s)}return Reflect.construct(e,t.concat(r))}_setCreatedServiceInstance(e,t){if(this._services.get(e)instanceof Dd)this._services.set(e,t);else if(this._parent)this._parent._setCreatedServiceInstance(e,t);else throw new Error("illegalState - setting UNKNOWN service instance")}_getServiceInstanceOrDescriptor(e){let t=this._services.get(e);return!t&&this._parent?this._parent._getServiceInstanceOrDescriptor(e):t}_getOrCreateServiceInstance(e,t){this._globalGraph&&this._globalGraphImplicitDependency&&this._globalGraph.insertEdge(this._globalGraphImplicitDependency,String(e));let i=this._getServiceInstanceOrDescriptor(e);return i instanceof Dd?this._safeCreateAndCacheServiceInstance(e,i,t.branch(e,!0)):(t.branch(e,!1),i)}_safeCreateAndCacheServiceInstance(e,t,i){if(this._activeInstantiations.has(e))throw new Error(`illegal state - RECURSIVELY instantiating service '${e}'`);this._activeInstantiations.add(e);try{return this._createAndCacheServiceInstance(e,t,i)}finally{this._activeInstantiations.delete(e)}}_createAndCacheServiceInstance(e,t,i){let o=new V2(l=>l.id.toString()),r=0,s=[{id:e,desc:t,_trace:i}],a=new Set;for(;s.length;){let l=s.pop();if(!a.has(String(l.id))){if(a.add(String(l.id)),o.lookupOrInsertNode(l),r++>1e3)throw new eV(o);for(let c of gf.getServiceDependencies(l.desc.ctor)){let d=this._getServiceInstanceOrDescriptor(c.id);if(d||this._throwIfStrict(`[createInstance] ${e} depends on ${c.id} which is NOT registered.`,!0),this._globalGraph?.insertEdge(String(l.id),String(c.id)),d instanceof Dd){let u={id:c.id,desc:d,_trace:l._trace.branch(c.id,!0)};o.insertEdge(l,u),s.push(u)}}}}for(;;){let l=o.roots();if(l.length===0){if(!o.isEmpty())throw new eV(o);break}for(let{data:c}of l){if(this._getServiceInstanceOrDescriptor(c.id)instanceof Dd){let u=this._createServiceInstanceWithOwner(c.id,c.desc.ctor,c.desc.staticArguments,c.desc.supportsDelayedInstantiation,c._trace);this._setCreatedServiceInstance(c.id,u)}o.removeNode(c)}}return this._getServiceInstanceOrDescriptor(e)}_createServiceInstanceWithOwner(e,t,i=[],o,r){if(this._services.get(e)instanceof Dd)return this._createServiceInstance(e,t,i,o,r,this._servicesToMaybeDispose);if(this._parent)return this._parent._createServiceInstanceWithOwner(e,t,i,o,r);throw new Error(`illegalState - creating UNKNOWN service instance ${t.name}`)}_createServiceInstance(e,t,i=[],o,r,s){if(o){let a=new n(void 0,this._strict,this,this._enableTracing);a._globalGraphImplicitDependency=String(e);let l=new Map,c=new bB(()=>{let d=a._createInstance(t,i,r);for(let[u,h]of l){let f=d[u];if(typeof f=="function")for(let p of h)p.disposable=f.apply(d,p.listener)}return l.clear(),s.add(d),d});return new Proxy(Object.create(null),{get(d,u){if(!c.isInitialized&&typeof u=="string"&&(u.startsWith("onDid")||u.startsWith("onWill"))){let p=l.get(u);return p||(p=new go,l.set(u,p)),(_,b,v)=>{if(c.isInitialized)return c.value[u](_,b,v);{let x={listener:[_,b,v],disposable:void 0},w=p.push(x);return ge(()=>{w(),x.disposable?.dispose()})}}}if(u in d)return d[u];let h=c.value,f=h[u];return typeof f!="function"||(f=f.bind(h),d[u]=f),f},set(d,u,h){return c.value[u]=h,!0},getPrototypeOf(d){return t.prototype}})}else{let a=this._createInstance(t,i,r);return s.add(a),a}}_throwIfStrict(e,t){if(t&&console.warn(e),this._strict)throw new Error(e)}},U2=class n{static{this.all=new Set}static{this._None=new class extends n{constructor(){super(0,null)}stop(){}branch(){return this}}}static traceInvocation(e,t){return e?new n(2,t.name||new Error().stack.split(` `).slice(3,4).join(` `)):n._None}static traceCreation(e,t){return e?new n(1,t.name):n._None}static{this._totals=0}constructor(e,t){this.type=e,this.name=t,this._start=Date.now(),this._dep=[]}branch(e,t){let i=new n(3,e.toString());return this._dep.push([e,t,i]),i}stop(){let e=Date.now()-this._start;n._totals+=e;let t=!1;function i(r,s){let a=[],l=new Array(r+1).join(" ");for(let[c,d,u]of s._dep)if(d&&u){t=!0,a.push(`${l}CREATES -> ${c}`);let h=i(r+1,u);h&&a.push(h)}else a.push(`${l}uses -> ${c}`);return a.join(` `)}let o=[`${this.type===1?"CREATE":"CALL"} ${this.name}`,`${i(1,this)}`,`DONE, took ${e.toFixed(2)}ms (grand total ${n._totals.toFixed(2)}ms)`];(e>2||t)&&n.all.add(o.join(` `))}}});var tut,rue,sue,iV,O5e=k(()=>{at();Ie();Cl();Ds();ds();Ai();gg();tut=new Set([rt.inMemory,rt.vscodeSourceControl,rt.walkThrough,rt.walkThroughSnippet,rt.vscodeChatCodeBlock]),rue=class{constructor(){this._byResource=new Fo,this._byOwner=new Map}set(e,t,i){let o=this._byResource.get(e);o||(o=new Map,this._byResource.set(e,o)),o.set(t,i);let r=this._byOwner.get(t);r||(r=new Fo,this._byOwner.set(t,r)),r.set(e,i)}get(e,t){return this._byResource.get(e)?.get(t)}delete(e,t){let i=!1,o=!1,r=this._byResource.get(e);r&&(i=r.delete(t));let s=this._byOwner.get(t);if(s&&(o=s.delete(e)),i!==o)throw new Error("illegal state");return i&&o}values(e){return typeof e=="string"?this._byOwner.get(e)?.values()??Dt.empty():Ee.isUri(e)?this._byResource.get(e)?.values()??Dt.empty():Dt.map(Dt.concat(...this._byOwner.values()),t=>t[1])}},sue=class{constructor(e){this.errors=0,this.infos=0,this.warnings=0,this.unknowns=0,this._data=new Fo,this._service=e,this._subscription=e.onMarkerChanged(this._update,this)}dispose(){this._subscription.dispose()}_update(e){for(let t of e){let i=this._data.get(t);i&&this._substract(i);let o=this._resourceStats(t);this._add(o),this._data.set(t,o)}}_resourceStats(e){let t={errors:0,warnings:0,infos:0,unknowns:0};if(tut.has(e.scheme))return t;for(let{severity:i}of this._service.read({resource:e}))i===Vn.Error?t.errors+=1:i===Vn.Warning?t.warnings+=1:i===Vn.Info?t.infos+=1:t.unknowns+=1;return t}_substract(e){this.errors-=e.errors,this.warnings-=e.warnings,this.infos-=e.infos,this.unknowns-=e.unknowns}_add(e){this.errors+=e.errors,this.warnings+=e.warnings,this.infos+=e.infos,this.unknowns+=e.unknowns}},iV=class n{constructor(){this._onMarkerChanged=new Yk({delay:0,merge:n._merge}),this.onMarkerChanged=this._onMarkerChanged.event,this._data=new rue,this._stats=new sue(this)}dispose(){this._stats.dispose(),this._onMarkerChanged.dispose()}remove(e,t){for(let i of t||[])this.changeOne(e,i,[])}changeOne(e,t,i){if(E3(i))this._data.delete(t,e)&&this._onMarkerChanged.fire([t]);else{let o=[];for(let r of i){let s=n._toMarker(e,t,r);s&&o.push(s)}this._data.set(t,e,o),this._onMarkerChanged.fire([t])}}static _toMarker(e,t,i){let{code:o,severity:r,message:s,source:a,startLineNumber:l,startColumn:c,endLineNumber:d,endColumn:u,relatedInformation:h,tags:f}=i;if(s)return l=l>0?l:1,c=c>0?c:1,d=d>=l?d:l,u=u>0?u:c,{resource:t,owner:e,code:o,severity:r,message:s,source:a,startLineNumber:l,startColumn:c,endLineNumber:d,endColumn:u,relatedInformation:h,tags:f}}changeAll(e,t){let i=[],o=this._data.values(e);if(o)for(let r of o){let s=Dt.first(r);s&&(i.push(s.resource),this._data.delete(s.resource,e))}if(So(t)){let r=new Fo;for(let{resource:s,marker:a}of t){let l=n._toMarker(e,s,a);if(!l)continue;let c=r.get(s);c?c.push(l):(r.set(s,[l]),i.push(s))}for(let[s,a]of r)this._data.set(s,e,a)}i.length>0&&this._onMarkerChanged.fire(i)}read(e=Object.create(null)){let{owner:t,resource:i,severities:o,take:r}=e;if((!r||r<0)&&(r=-1),t&&i){let s=this._data.get(i,t);if(s){let a=[];for(let l of s)if(n._accept(l,o)){let c=a.push(l);if(r>0&&c===r)break}return a}else return[]}else if(!t&&!i){let s=[];for(let a of this._data.values())for(let l of a)if(n._accept(l,o)){let c=s.push(l);if(r>0&&c===r)return s}return s}else{let s=this._data.values(i??t),a=[];for(let l of s)for(let c of l)if(n._accept(c,o)){let d=a.push(c);if(r>0&&d===r)return a}return a}}static _accept(e,t){return t===void 0||(t&e.severity)===e.severity}static _merge(e){let t=new Fo;for(let i of e)for(let o of i)t.set(o,!0);return Array.from(t.keys())}}});var nV,F5e=k(()=>{j();bae();Mm();br();nV=class extends D{get configurationModel(){return this._configurationModel}constructor(e){super(),this.logService=e,this._configurationModel=Fl.createEmptyModel(this.logService)}reload(){return this.resetConfigurationModel(),this.configurationModel}getConfigurationDefaultOverrides(){return{}}resetConfigurationModel(){this._configurationModel=Fl.createEmptyModel(this.logService);let e=ei.as(Qs.Configuration).getConfigurationProperties();this.updateConfigurationModel(Object.keys(e),e)}updateConfigurationModel(e,t){let i=this.getConfigurationDefaultOverrides();for(let o of e){let r=i[o],s=t[o];r!==void 0?this._configurationModel.setValue(o,r):s?this._configurationModel.setValue(o,s.default):this._configurationModel.removeValue(o)}}}});var jd,Gmi,co,aue,sl,Lw=k(()=>{pe();Fe();jd=We("accessibilitySignalService"),Gmi=Symbol("AcknowledgeDocCommentsToken"),co=class n{static register(e){return new n(e.fileName)}static{this.error=n.register({fileName:"error.mp3"})}static{this.warning=n.register({fileName:"warning.mp3"})}static{this.success=n.register({fileName:"success.mp3"})}static{this.foldedArea=n.register({fileName:"foldedAreas.mp3"})}static{this.break=n.register({fileName:"break.mp3"})}static{this.quickFixes=n.register({fileName:"quickFixes.mp3"})}static{this.taskCompleted=n.register({fileName:"taskCompleted.mp3"})}static{this.taskFailed=n.register({fileName:"taskFailed.mp3"})}static{this.terminalBell=n.register({fileName:"terminalBell.mp3"})}static{this.diffLineInserted=n.register({fileName:"diffLineInserted.mp3"})}static{this.diffLineDeleted=n.register({fileName:"diffLineDeleted.mp3"})}static{this.diffLineModified=n.register({fileName:"diffLineModified.mp3"})}static{this.chatRequestSent=n.register({fileName:"chatRequestSent.mp3"})}static{this.chatResponseReceived1=n.register({fileName:"chatResponseReceived1.mp3"})}static{this.chatResponseReceived2=n.register({fileName:"chatResponseReceived2.mp3"})}static{this.chatResponseReceived3=n.register({fileName:"chatResponseReceived3.mp3"})}static{this.chatResponseReceived4=n.register({fileName:"chatResponseReceived4.mp3"})}static{this.clear=n.register({fileName:"clear.mp3"})}static{this.save=n.register({fileName:"save.mp3"})}static{this.format=n.register({fileName:"format.mp3"})}static{this.voiceRecordingStarted=n.register({fileName:"voiceRecordingStarted.mp3"})}static{this.voiceRecordingStopped=n.register({fileName:"voiceRecordingStopped.mp3"})}static{this.progress=n.register({fileName:"progress.mp3"})}constructor(e){this.fileName=e}},aue=class{constructor(e){this.randomOneOf=e}},sl=class n{constructor(e,t,i,o,r,s){this.sound=e,this.name=t,this.legacySoundSettingsKey=i,this.settingsKey=o,this.legacyAnnouncementSettingsKey=r,this.announcementMessage=s}static{this._signals=new Set}static register(e){let t=new aue("randomOneOf"in e.sound?e.sound.randomOneOf:[e.sound]),i=new n(t,e.name,e.legacySoundSettingsKey,e.settingsKey,e.legacyAnnouncementSettingsKey,e.announcementMessage);return n._signals.add(i),i}static{this.errorAtPosition=n.register({name:m("accessibilitySignals.positionHasError.name","Error at Position"),sound:co.error,announcementMessage:m("accessibility.signals.positionHasError","Error"),settingsKey:"accessibility.signals.positionHasError",delaySettingsKey:"accessibility.signalOptions.delays.errorAtPosition"})}static{this.warningAtPosition=n.register({name:m("accessibilitySignals.positionHasWarning.name","Warning at Position"),sound:co.warning,announcementMessage:m("accessibility.signals.positionHasWarning","Warning"),settingsKey:"accessibility.signals.positionHasWarning",delaySettingsKey:"accessibility.signalOptions.delays.warningAtPosition"})}static{this.errorOnLine=n.register({name:m("accessibilitySignals.lineHasError.name","Error on Line"),sound:co.error,legacySoundSettingsKey:"audioCues.lineHasError",legacyAnnouncementSettingsKey:"accessibility.alert.error",announcementMessage:m("accessibility.signals.lineHasError","Error on Line"),settingsKey:"accessibility.signals.lineHasError"})}static{this.warningOnLine=n.register({name:m("accessibilitySignals.lineHasWarning.name","Warning on Line"),sound:co.warning,legacySoundSettingsKey:"audioCues.lineHasWarning",legacyAnnouncementSettingsKey:"accessibility.alert.warning",announcementMessage:m("accessibility.signals.lineHasWarning","Warning on Line"),settingsKey:"accessibility.signals.lineHasWarning"})}static{this.foldedArea=n.register({name:m("accessibilitySignals.lineHasFoldedArea.name","Folded Area on Line"),sound:co.foldedArea,legacySoundSettingsKey:"audioCues.lineHasFoldedArea",legacyAnnouncementSettingsKey:"accessibility.alert.foldedArea",announcementMessage:m("accessibility.signals.lineHasFoldedArea","Folded"),settingsKey:"accessibility.signals.lineHasFoldedArea"})}static{this.break=n.register({name:m("accessibilitySignals.lineHasBreakpoint.name","Breakpoint on Line"),sound:co.break,legacySoundSettingsKey:"audioCues.lineHasBreakpoint",legacyAnnouncementSettingsKey:"accessibility.alert.breakpoint",announcementMessage:m("accessibility.signals.lineHasBreakpoint","Breakpoint"),settingsKey:"accessibility.signals.lineHasBreakpoint"})}static{this.inlineSuggestion=n.register({name:m("accessibilitySignals.lineHasInlineSuggestion.name","Inline Suggestion on Line"),sound:co.quickFixes,legacySoundSettingsKey:"audioCues.lineHasInlineSuggestion",settingsKey:"accessibility.signals.lineHasInlineSuggestion"})}static{this.terminalQuickFix=n.register({name:m("accessibilitySignals.terminalQuickFix.name","Terminal Quick Fix"),sound:co.quickFixes,legacySoundSettingsKey:"audioCues.terminalQuickFix",legacyAnnouncementSettingsKey:"accessibility.alert.terminalQuickFix",announcementMessage:m("accessibility.signals.terminalQuickFix","Quick Fix"),settingsKey:"accessibility.signals.terminalQuickFix"})}static{this.onDebugBreak=n.register({name:m("accessibilitySignals.onDebugBreak.name","Debugger Stopped on Breakpoint"),sound:co.break,legacySoundSettingsKey:"audioCues.onDebugBreak",legacyAnnouncementSettingsKey:"accessibility.alert.onDebugBreak",announcementMessage:m("accessibility.signals.onDebugBreak","Breakpoint"),settingsKey:"accessibility.signals.onDebugBreak"})}static{this.noInlayHints=n.register({name:m("accessibilitySignals.noInlayHints","No Inlay Hints on Line"),sound:co.error,legacySoundSettingsKey:"audioCues.noInlayHints",legacyAnnouncementSettingsKey:"accessibility.alert.noInlayHints",announcementMessage:m("accessibility.signals.noInlayHints","No Inlay Hints"),settingsKey:"accessibility.signals.noInlayHints"})}static{this.taskCompleted=n.register({name:m("accessibilitySignals.taskCompleted","Task Completed"),sound:co.taskCompleted,legacySoundSettingsKey:"audioCues.taskCompleted",legacyAnnouncementSettingsKey:"accessibility.alert.taskCompleted",announcementMessage:m("accessibility.signals.taskCompleted","Task Completed"),settingsKey:"accessibility.signals.taskCompleted"})}static{this.taskFailed=n.register({name:m("accessibilitySignals.taskFailed","Task Failed"),sound:co.taskFailed,legacySoundSettingsKey:"audioCues.taskFailed",legacyAnnouncementSettingsKey:"accessibility.alert.taskFailed",announcementMessage:m("accessibility.signals.taskFailed","Task Failed"),settingsKey:"accessibility.signals.taskFailed"})}static{this.terminalCommandFailed=n.register({name:m("accessibilitySignals.terminalCommandFailed","Terminal Command Failed"),sound:co.error,legacySoundSettingsKey:"audioCues.terminalCommandFailed",legacyAnnouncementSettingsKey:"accessibility.alert.terminalCommandFailed",announcementMessage:m("accessibility.signals.terminalCommandFailed","Command Failed"),settingsKey:"accessibility.signals.terminalCommandFailed"})}static{this.terminalCommandSucceeded=n.register({name:m("accessibilitySignals.terminalCommandSucceeded","Terminal Command Succeeded"),sound:co.success,announcementMessage:m("accessibility.signals.terminalCommandSucceeded","Command Succeeded"),settingsKey:"accessibility.signals.terminalCommandSucceeded"})}static{this.terminalBell=n.register({name:m("accessibilitySignals.terminalBell","Terminal Bell"),sound:co.terminalBell,legacySoundSettingsKey:"audioCues.terminalBell",legacyAnnouncementSettingsKey:"accessibility.alert.terminalBell",announcementMessage:m("accessibility.signals.terminalBell","Terminal Bell"),settingsKey:"accessibility.signals.terminalBell"})}static{this.notebookCellCompleted=n.register({name:m("accessibilitySignals.notebookCellCompleted","Notebook Cell Completed"),sound:co.taskCompleted,legacySoundSettingsKey:"audioCues.notebookCellCompleted",legacyAnnouncementSettingsKey:"accessibility.alert.notebookCellCompleted",announcementMessage:m("accessibility.signals.notebookCellCompleted","Notebook Cell Completed"),settingsKey:"accessibility.signals.notebookCellCompleted"})}static{this.notebookCellFailed=n.register({name:m("accessibilitySignals.notebookCellFailed","Notebook Cell Failed"),sound:co.taskFailed,legacySoundSettingsKey:"audioCues.notebookCellFailed",legacyAnnouncementSettingsKey:"accessibility.alert.notebookCellFailed",announcementMessage:m("accessibility.signals.notebookCellFailed","Notebook Cell Failed"),settingsKey:"accessibility.signals.notebookCellFailed"})}static{this.diffLineInserted=n.register({name:m("accessibilitySignals.diffLineInserted","Diff Line Inserted"),sound:co.diffLineInserted,legacySoundSettingsKey:"audioCues.diffLineInserted",settingsKey:"accessibility.signals.diffLineInserted"})}static{this.diffLineDeleted=n.register({name:m("accessibilitySignals.diffLineDeleted","Diff Line Deleted"),sound:co.diffLineDeleted,legacySoundSettingsKey:"audioCues.diffLineDeleted",settingsKey:"accessibility.signals.diffLineDeleted"})}static{this.diffLineModified=n.register({name:m("accessibilitySignals.diffLineModified","Diff Line Modified"),sound:co.diffLineModified,legacySoundSettingsKey:"audioCues.diffLineModified",settingsKey:"accessibility.signals.diffLineModified"})}static{this.chatRequestSent=n.register({name:m("accessibilitySignals.chatRequestSent","Chat Request Sent"),sound:co.chatRequestSent,legacySoundSettingsKey:"audioCues.chatRequestSent",legacyAnnouncementSettingsKey:"accessibility.alert.chatRequestSent",announcementMessage:m("accessibility.signals.chatRequestSent","Chat Request Sent"),settingsKey:"accessibility.signals.chatRequestSent"})}static{this.chatResponseReceived=n.register({name:m("accessibilitySignals.chatResponseReceived","Chat Response Received"),legacySoundSettingsKey:"audioCues.chatResponseReceived",sound:{randomOneOf:[co.chatResponseReceived1,co.chatResponseReceived2,co.chatResponseReceived3,co.chatResponseReceived4]},settingsKey:"accessibility.signals.chatResponseReceived"})}static{this.progress=n.register({name:m("accessibilitySignals.progress","Progress"),sound:co.progress,legacySoundSettingsKey:"audioCues.chatResponsePending",legacyAnnouncementSettingsKey:"accessibility.alert.progress",announcementMessage:m("accessibility.signals.progress","Progress"),settingsKey:"accessibility.signals.progress"})}static{this.clear=n.register({name:m("accessibilitySignals.clear","Clear"),sound:co.clear,legacySoundSettingsKey:"audioCues.clear",legacyAnnouncementSettingsKey:"accessibility.alert.clear",announcementMessage:m("accessibility.signals.clear","Clear"),settingsKey:"accessibility.signals.clear"})}static{this.save=n.register({name:m("accessibilitySignals.save","Save"),sound:co.save,legacySoundSettingsKey:"audioCues.save",legacyAnnouncementSettingsKey:"accessibility.alert.save",announcementMessage:m("accessibility.signals.save","Save"),settingsKey:"accessibility.signals.save"})}static{this.format=n.register({name:m("accessibilitySignals.format","Format"),sound:co.format,legacySoundSettingsKey:"audioCues.format",legacyAnnouncementSettingsKey:"accessibility.alert.format",announcementMessage:m("accessibility.signals.format","Format"),settingsKey:"accessibility.signals.format"})}static{this.voiceRecordingStarted=n.register({name:m("accessibilitySignals.voiceRecordingStarted","Voice Recording Started"),sound:co.voiceRecordingStarted,legacySoundSettingsKey:"audioCues.voiceRecordingStarted",settingsKey:"accessibility.signals.voiceRecordingStarted"})}static{this.voiceRecordingStopped=n.register({name:m("accessibilitySignals.voiceRecordingStopped","Voice Recording Stopped"),sound:co.voiceRecordingStopped,legacySoundSettingsKey:"audioCues.voiceRecordingStopped",settingsKey:"accessibility.signals.voiceRecordingStopped"})}}});var oV,B5e=k(()=>{j();ac();oV=class extends D{constructor(e,t=[]){super(),this.logger=new a6([e,...t]),this._register(e.onDidChangeLogLevel(i=>this.setLevel(i)))}get onDidChangeLogLevel(){return this.logger.onDidChangeLogLevel}setLevel(e){this.logger.setLevel(e)}getLevel(){return this.logger.getLevel()}trace(e,...t){this.logger.trace(e,...t)}debug(e,...t){this.logger.debug(e,...t)}info(e,...t){this.logger.info(e,...t)}warn(e,...t){this.logger.warn(e,...t)}error(e,...t){this.logger.error(e,...t)}}});function Rf(n){W5e.push(n)}function H5e(){return W5e.slice(0)}var W5e,Iw=k(()=>{W5e=[]});var rV,z5e=k(()=>{rV=class{getParseResult(e){}}});function V5e(n){return n&&typeof n=="object"&&(!n.overrideIdentifier||typeof n.overrideIdentifier=="string")&&(!n.resource||n.resource instanceof Ee)}function $2(n,e,t){if(!e||!(n instanceof sV))return;let i=[];Object.keys(e).forEach(o=>{tPe(o)&&i.push([`editor.${o}`,e[o]]),t&&iPe(o)&&i.push([`diffEditor.${o}`,e[o]])}),i.length>0&&n.updateValues(i)}var Og,ar,lue,cue,due,uue,hue,fue,pue,mue,Ew,gue,sV,_ue,bue,vue,xue,wue,yue,Cue,Sue,kue,Lue,Iue,aV,Eue,Tue,bt,j2=k(()=>{Vre();Ure();kRe();wu();ERe();$Re();J2e();Qe();ke();Ks();Ie();S1();j();Bt();ob();Ai();bC();S7();Tu();qe();we();va();vu();zA();Gi();en();bae();it();AL();Fe();rPe();Pn();wae();K_();yae();dPe();sI();ea();kf();sc();lI();nb();og();ia();Po();ac();Eae();Al();hae();WPe();wOe();Xs();COe();Ip();Wre();fs();a4e();HW();X4e();f5e();qde();QC();T5e();uc();an();Qde();R5e();Mb();A5e();x6();P5e();JC();A2();gg();O5e();Ml();Jc();kp();F5e();Lw();Qt();Ko();B5e();Iw();je();p9();Il();Ds();hce();z5e();Og=function(n,e,t,i){var o=arguments.length,r=o<3?e:i===null?i=Object.getOwnPropertyDescriptor(e,t):i,s;if(typeof Reflect=="object"&&typeof Reflect.decorate=="function")r=Reflect.decorate(n,e,t,i);else for(var a=n.length-1;a>=0;a--)(s=n[a])&&(r=(o<3?s(r):o>3?s(e,t,r):s(e,t))||r);return o>3&&r&&Object.defineProperty(e,t,r),r},ar=function(n,e){return function(t,i){e(t,i,n)}},lue=class{constructor(e){this.disposed=!1,this.model=e,this._onWillDispose=new A}get textEditorModel(){return this.model}dispose(){this.disposed=!0,this._onWillDispose.fire()}},cue=class{constructor(e){this.modelService=e}createModelReference(e){let t=this.modelService.getModel(e);return t?Promise.resolve(new $3(new lue(t))):Promise.reject(new Error("Model not found"))}};cue=Og([ar(0,di)],cue);due=class n{static{this.NULL_PROGRESS_RUNNER={done:()=>{},total:()=>{},worked:()=>{}}}show(){return n.NULL_PROGRESS_RUNNER}async showWhile(e,t){await e}},uue=class{withProgress(e,t,i){return t({report:()=>{}})}},hue=class{constructor(){this.isExtensionDevelopment=!1,this.isBuilt=!1}},fue=class{async confirm(e){return{confirmed:this.doConfirm(e.message,e.detail),checkboxChecked:!1}}doConfirm(e,t){let i=e;return t&&(i=i+` `+t),ri.confirm(i)}async prompt(e){let t;if(this.doConfirm(e.message,e.detail)){let o=[...e.buttons??[]];e.cancelButton&&typeof e.cancelButton!="string"&&typeof e.cancelButton!="boolean"&&o.push(e.cancelButton),t=await o[0]?.run({checkboxChecked:!1})}return{result:t}}async error(e,t){await this.prompt({type:Mn.Error,message:e,detail:t})}},pue=class n{static{this.NO_OP=new s9}info(e){return this.notify({severity:Mn.Info,message:e})}warn(e){return this.notify({severity:Mn.Warning,message:e})}error(e){return this.notify({severity:Mn.Error,message:e})}notify(e){switch(e.severity){case Mn.Error:console.error(e.message);break;case Mn.Warning:console.warn(e.message);break;default:console.log(e.message);break}return n.NO_OP}prompt(e,t,i,o){return n.NO_OP}status(e,t){return D.None}},mue=class{constructor(e){this._onWillExecuteCommand=new A,this._onDidExecuteCommand=new A,this.onDidExecuteCommand=this._onDidExecuteCommand.event,this._instantiationService=e}executeCommand(e,...t){let i=wt.getCommand(e);if(!i)return Promise.reject(new Error(`command '${e}' not found`));try{this._onWillExecuteCommand.fire({commandId:e,args:t});let o=this._instantiationService.invokeFunction.apply(this._instantiationService,[i.handler,...t]);return this._onDidExecuteCommand.fire({commandId:e,args:t}),Promise.resolve(o)}catch(o){return Promise.reject(o)}}};mue=Og([ar(0,he)],mue);Ew=class extends E7{constructor(e,t,i,o,r,s){super(e,t,i,o,r),this._cachedResolver=null,this._dynamicKeybindings=[],this._domNodeListeners=[];let a=f=>{let p=new H;p.add(U(f,re.KEY_DOWN,g=>{let _=new Xt(g);this._dispatch(_,_.target)&&(_.preventDefault(),_.stopPropagation())})),p.add(U(f,re.KEY_UP,g=>{let _=new Xt(g);this._singleModifierDispatch(_,_.target)&&_.preventDefault()})),this._domNodeListeners.push(new gue(f,p))},l=f=>{for(let p=0;p{f.getOption(61)||a(f.getContainerDomNode())},d=f=>{f.getOption(61)||l(f.getContainerDomNode())};this._register(s.onCodeEditorAdd(c)),this._register(s.onCodeEditorRemove(d)),s.listCodeEditors().forEach(c);let u=f=>{a(f.getContainerDomNode())},h=f=>{l(f.getContainerDomNode())};this._register(s.onDiffEditorAdd(u)),this._register(s.onDiffEditorRemove(h)),s.listDiffEditors().forEach(u)}addDynamicKeybinding(e,t,i,o){return qs(wt.registerCommand(e,i),this.addDynamicKeybindings([{keybinding:t,command:e,when:o}]))}addDynamicKeybindings(e){let t=e.map(i=>({keybinding:JR(i.keybinding,Ur),command:i.command??null,commandArgs:i.commandArgs,when:i.when,weight1:1e3,weight2:0,extensionId:null,isBuiltinExtension:!1}));return this._dynamicKeybindings=this._dynamicKeybindings.concat(t),this.updateResolver(),ge(()=>{for(let i=0;ithis._log(i))}return this._cachedResolver}_documentHasFocus(){return ri.document.hasFocus()}_toNormalizedKeybindingItems(e,t){let i=[],o=0;for(let r of e){let s=r.when||void 0,a=r.keybinding;if(!a)i[o++]=new IM(void 0,r.command,r.commandArgs,s,t,null,!1);else{let l=EM.resolveKeybinding(a,Ur);for(let c of l)i[o++]=new IM(c,r.command,r.commandArgs,s,t,null,!1)}}return i}resolveKeyboardEvent(e){let t=new fh(e.ctrlKey,e.shiftKey,e.altKey,e.metaKey,e.keyCode);return new EM([t],Ur)}};Ew=Og([ar(0,Le),ar(1,$t),ar(2,Fn),ar(3,Di),ar(4,Bn),ar(5,xt)],Ew);gue=class extends D{constructor(e,t){super(),this.domNode=e,this._register(t)}};sV=class{constructor(e){this.logService=e,this._onDidChangeConfiguration=new A,this.onDidChangeConfiguration=this._onDidChangeConfiguration.event;let t=new nV(e);this._configuration=new kM(t.reload(),Fl.createEmptyModel(e),Fl.createEmptyModel(e),Fl.createEmptyModel(e),Fl.createEmptyModel(e),Fl.createEmptyModel(e),new Fo,Fl.createEmptyModel(e),new Fo,e),t.dispose()}getValue(e,t){let i=typeof e=="string"?e:void 0,o=V5e(e)?e:V5e(t)?t:{};return this._configuration.getValue(i,o,void 0)}updateValues(e){let t={data:this._configuration.toData()},i=[];for(let o of e){let[r,s]=o;this.getValue(r)!==s&&(this._configuration.updateValue(r,s),i.push(r))}if(i.length>0){let o=new L7({keys:i,overrides:[]},t,this._configuration,void 0,this.logService);o.source=8,this._onDidChangeConfiguration.fire(o)}return Promise.resolve()}updateValue(e,t,i,o){return this.updateValues([[e,t]])}inspect(e,t={}){return this._configuration.inspect(e,t,void 0)}};sV=Og([ar(0,Bn)],sV);_ue=class{constructor(e,t,i){this.configurationService=e,this.modelService=t,this.languageService=i,this._onDidChangeConfiguration=new A,this.configurationService.onDidChangeConfiguration(o=>{this._onDidChangeConfiguration.fire({affectedKeys:o.affectedKeys,affectsConfiguration:(r,s)=>o.affectsConfiguration(s)})})}getValue(e,t,i){let o=P.isIPosition(t)?t:null,r=o?typeof i=="string"?i:void 0:typeof t=="string"?t:void 0,s=e?this.getLanguage(e,o):void 0;return typeof r>"u"?this.configurationService.getValue({resource:e,overrideIdentifier:s}):this.configurationService.getValue(r,{resource:e,overrideIdentifier:s})}getLanguage(e,t){let i=this.modelService.getModel(e);return i?t?i.getLanguageIdAtPosition(t.lineNumber,t.column):i.getLanguageId():this.languageService.guessLanguageIdByFilepathOrFirstLine(e)}};_ue=Og([ar(0,Ve),ar(1,di),ar(2,ai)],_ue);bue=class{constructor(e){this.configurationService=e}getEOL(e,t){let i=this.configurationService.getValue("files.eol",{overrideIdentifier:t,resource:e});return i&&typeof i=="string"&&i!=="auto"?i:Qn||dt?` `:`\r `}};bue=Og([ar(0,Ve)],bue);vue=class{publicLog2(){}},xue=class n{static{this.SCHEME="inmemory"}constructor(){let e=Ee.from({scheme:n.SCHEME,authority:"model",path:"/"});this.workspace={id:Iae,folders:[new M7({uri:e,name:"",index:0})]}}getWorkspace(){return this.workspace}getWorkspaceFolder(e){return e&&e.scheme===n.SCHEME?this.workspace.folders[0]:null}};wue=class{constructor(e){this._modelService=e}hasPreviewHandler(){return!1}async apply(e,t){let i=Array.isArray(e)?e:iI.convert(e),o=new Map;for(let a of i){if(!(a instanceof lw))throw new Error("bad edit - only text edits are supported");let l=this._modelService.getModel(a.resource);if(!l)throw new Error("bad edit - model not found");if(typeof a.versionId=="number"&&l.getVersionId()!==a.versionId)throw new Error("bad state - model changed in the meantime");let c=o.get(l);c||(c=[],o.set(l,c)),c.push(Pi.replaceMove(S.lift(a.textEdit.range),a.textEdit.text))}let r=0,s=0;for(let[a,l]of o)a.pushStackElement(),a.pushEditOperations([],l,()=>[]),a.pushStackElement(),s+=1,r+=l.length;return{ariaSummary:dh(z7.bulkEditServiceSummary,r,s),isApplied:r>0}}};wue=Og([ar(0,di)],wue);yue=class{getUriLabel(e,t){return e.scheme==="file"?e.fsPath:e.path}getUriBasenameLabel(e){return ta(e)}},Cue=class extends v7{constructor(e,t){super(e),this._codeEditorService=t}showContextView(e,t,i){if(!t){let o=this._codeEditorService.getFocusedCodeEditor()||this._codeEditorService.getActiveCodeEditor();o&&(t=o.getContainerDomNode())}return super.showContextView(e,t,i)}};Cue=Og([ar(0,Uc),ar(1,xt)],Cue);Sue=class{constructor(){this._neverEmitter=new A,this.onDidChangeTrust=this._neverEmitter.event}isWorkspaceTrusted(){return!0}},kue=class extends J7{constructor(){super()}},Lue=class extends oV{constructor(){super(new s6)}},Iue=class extends kW{constructor(e,t,i,o,r,s){super(e,t,i,o,r,s),this.configure({blockMouse:!1})}};Iue=Og([ar(0,Fn),ar(1,Di),ar(2,dc),ar(3,_t),ar(4,Yr),ar(5,Le)],Iue);aV={amdModuleId:"vs/editor/common/services/editorSimpleWorker",esmModuleLocation:void 0,label:"editorWorkerService"},Eue=class extends t9{constructor(e,t,i,o,r){super(aV,e,t,i,o,r)}};Eue=Og([ar(0,di),ar(1,X1),ar(2,Bn),ar(3,ti),ar(4,le)],Eue);Tue=class{async playSignal(e,t){}};Ct(Bn,Lue,0);Ct(Ve,sV,0);Ct(X1,_ue,0);Ct(e9,bue,0);Ct(wp,xue,0);Ct(xp,yue,0);Ct(Fn,vue,0);Ct(Um,fue,0);Ct(BL,hue,0);Ct(Di,pue,0);Ct(Xc,iV,0);Ct(ai,kue,0);Ct(La,$z,0);Ct(di,NH,0);Ct(DI,WW,0);Ct(Le,Jz,0);Ct(R7,uue,0);Ct(Fd,due,0);Ct(Fs,mW,0);Ct(kr,Eue,0);Ct(ng,wue,0);Ct(V7,Sue,0);Ct(Uo,cue,0);Ct($o,jz,0);Ct(zd,hz,0);Ct($t,mue,0);Ct(_t,Ew,0);Ct(Pr,Wz,0);Ct(dc,Cue,0);Ct(xo,IW,0);Ct(gc,Yz,0);Ct(sr,Iue,0);Ct(Yr,qz,0);Ct(jd,Tue,0);Ct(gH,rV,0);(function(n){let e=new Fu;for(let[l,c]of qoe())e.set(l,c);let t=new tV(e,!0);e.set(he,t);function i(l){o||s({});let c=e.get(l);if(!c)throw new Error("Missing service "+l);return c instanceof Dd?t.invokeFunction(d=>d.get(l)):c}n.get=i;let o=!1,r=new A;function s(l){if(o)return t;o=!0;for(let[d,u]of qoe())e.get(d)||e.set(d,u);for(let d in l)if(l.hasOwnProperty(d)){let u=We(d);e.get(u)instanceof Dd&&e.set(u,l[d])}let c=H5e();for(let d of c)try{t.createInstance(d)}catch(u){Be(u)}return r.fire(),t}n.initialize=s;function a(l){if(o)return l();let c=new H,d=c.add(r.event(()=>{d.dispose(),c.add(l())}));return c}n.withServices=a})(bt||(bt={}))});function U5e(n,e){return new Due(n,e)}var Due,$5e=k(()=>{ec();Wre();j2();Due=class extends VA{constructor(e,t){let i={amdModuleId:aV.amdModuleId,esmModuleLocation:aV.esmModuleLocation,label:t.label};super(i,t.keepIdleModels||!1,e),this._foreignModuleId=t.moduleId,this._foreignModuleCreateData=t.createData||null,this._foreignModuleHost=t.host||null,this._foreignProxy=null}fhr(e,t){if(!this._foreignModuleHost||typeof this._foreignModuleHost[e]!="function")return Promise.reject(new Error("Missing method "+e+" or missing main thread foreign host."));try{return Promise.resolve(this._foreignModuleHost[e].apply(this._foreignModuleHost,t))}catch(i){return Promise.reject(i)}}_getForeignProxy(){return this._foreignProxy||(this._foreignProxy=this._getProxy().then(e=>{let t=this._foreignModuleHost?CR(this._foreignModuleHost):[];return e.$loadForeignModule(this._foreignModuleId,this._foreignModuleCreateData,t).then(i=>{this._foreignModuleCreateData=null;let o=(a,l)=>e.$fmr(a,l),r=(a,l)=>function(){let c=Array.prototype.slice.call(arguments,0);return l(a,c)},s={};for(let a of i)s[a]=r(a,o);return s})})),this._foreignProxy}getProxy(){return this._getForeignProxy()}withSyncedResources(e){return this.workerWithSyncedResources(e).then(t=>this.getProxy())}}});var Pb,q2=k(()=>{Pb={ICodeEditor:"vs.editor.ICodeEditor",IDiffEditor:"vs.editor.IDiffEditor"}});var Ia,lV,Nue,cV,e0=k(()=>{Qe();Ia=class n{constructor(e,t,i,o){this.startColumn=e,this.endColumn=t,this.className=i,this.type=o,this._lineDecorationBrand=void 0}static _equals(e,t){return e.startColumn===t.startColumn&&e.endColumn===t.endColumn&&e.className===t.className&&e.type===t.type}static equalsArr(e,t){let i=e.length,o=t.length;if(i!==o)return!1;for(let r=0;r=r||(a[l++]=new n(Math.max(1,c.startColumn-o+1),Math.min(s+1,c.endColumn-o+1),c.className,c.type));return a}static filter(e,t,i,o){if(e.length===0)return[];let r=[],s=0;for(let a=0,l=e.length;at||d.isEmpty()&&(c.type===0||c.type===3))continue;let u=d.startLineNumber===t?d.startColumn:i,h=d.endLineNumber===t?d.endColumn:o;r[s++]=new n(u,h,c.inlineClassName,c.type)}return r}static _typeCompare(e,t){let i=[2,0,1,3];return i[e]-i[t]}static compare(e,t){if(e.startColumn!==t.startColumn)return e.startColumn-t.startColumn;if(e.endColumn!==t.endColumn)return e.endColumn-t.endColumn;let i=n._typeCompare(e.type,t.type);return i!==0?i:e.className!==t.className?e.className0&&this.stopOffsets[0]0&&t=e){this.stopOffsets.splice(o,0,e),this.classNames.splice(o,0,t),this.metadata.splice(o,0,i);break}this.count++}},cV=class{static normalize(e,t){if(t.length===0)return[];let i=[],o=new Nue,r=0;for(let s=0,a=t.length;s1){let g=e.charCodeAt(c-2);to(g)&&c--}if(d>1){let g=e.charCodeAt(d-2);to(g)&&d--}let f=c-1,p=d-2;r=o.consumeLowerThan(f,r,i),o.count===0&&(r=f),o.insert(p,u,h)}return o.consumeLowerThan(1073741824,r,i),i}}});var Or,q5e=k(()=>{Or=class{constructor(e,t,i,o){this.endIndex=e,this.type=t,this.metadata=i,this.containsRTL=o,this._linePartBrand=void 0}isWhitespace(){return!!(this.metadata&1)}isPseudoAfter(){return!!(this.metadata&4)}}});function Ob(n,e){if(n.lineContent.length===0){if(n.lineDecorations.length>0){e.appendString("");let t=0,i=0,o=0;for(let s of n.lineDecorations)(s.type===1||s.type===2)&&(e.appendString(''),s.type===1&&(o|=1,t++),s.type===2&&(o|=2,i++));e.appendString("");let r=new G2(1,t+i);return r.setColumnInfo(1,t,0,0),new Y2(r,!1,o)}return e.appendString(""),new Y2(new G2(0,0),!1,0)}return lut(iut(n),e)}function fE(n){let e=new xu(1e4),t=Ob(n,e);return new Rue(t.characterMapping,e.build(),t.containsRTL,t.containsForeignElements)}function iut(n){let e=n.lineContent,t,i,o;n.stopRenderingLineAfter!==-1&&n.stopRenderingLineAfter0){for(let a=0,l=n.lineDecorations.length;a0&&(r[s++]=new Or(i,"",0,!1));let a=i;for(let l=0,c=t.getCount();l=o){let f=e?dp(n.substring(a,o)):!1;r[s++]=new Or(o,u,0,f);break}let h=e?dp(n.substring(a,d)):!1;r[s++]=new Or(d,u,0,h),a=d}return r}function out(n,e,t){let i=0,o=[],r=0;if(t)for(let s=0,a=e.length;s=50&&(o[r++]=new Or(f+1,d,u,h),p=f+1,f=-1);p!==c&&(o[r++]=new Or(c,d,u,h))}else o[r++]=l;i=c}else for(let s=0,a=e.length;s50){let u=l.type,h=l.metadata,f=l.containsRTL,p=Math.ceil(d/50);for(let g=1;g=8234&&n<=8238||n>=8294&&n<=8297||n>=8206&&n<=8207||n===1564}function rut(n,e){let t=[],i=new Or(0,"",0,!1),o=0;for(let r of e){let s=r.endIndex;for(;oi.endIndex&&(i=new Or(o,r.type,r.metadata,r.containsRTL),t.push(i)),i=new Or(o+1,"mtkcontrol",r.metadata,!1),t.push(i))}o>i.endIndex&&(i=new Or(s,r.type,r.metadata,r.containsRTL),t.push(i))}return t}function sut(n,e,t,i){let o=n.continuesWithWrappedLine,r=n.fauxIndentLength,s=n.tabSize,a=n.startVisibleColumn,l=n.useMonospaceOptimizations,c=n.selectionsOnLine,d=n.renderWhitespace===1,u=n.renderWhitespace===3,h=n.renderSpaceWidth!==n.spaceWidth,f=[],p=0,g=0,_=i[g].type,b=i[g].containsRTL,v=i[g].endIndex,x=i.length,w=!1,y=bo(e),C;y===-1?(w=!0,y=t,C=t):C=_a(e);let L=!1,E=0,N=c&&c[E],M=a%s;for(let q=r;q=N.endOffset&&(E++,N=c&&c[E]);let $;if(qC)$=!0;else if(te===9)$=!0;else if(te===32)if(d)if(L)$=!0;else{let z=q+1q),$&&u&&($=w||q>C),$&&b&&q>=y&&q<=C&&($=!1),L){if(!$||!l&&M>=s){if(h){let z=p>0?f[p-1].endIndex:r;for(let ae=z+1;ae<=q;ae++)f[p++]=new Or(ae,"mtkw",1,!1)}else f[p++]=new Or(q,"mtkw",1,!1);M=M%s}}else(q===v||$&&q>r)&&(f[p++]=new Or(q,_,0,b),M=M%s);for(te===9?M=s:hh(te)?M+=2:M++,L=$;q===v&&(g++,g0?e.charCodeAt(t-1):0,te=t>1?e.charCodeAt(t-2):0;q===32&&te!==32&&te!==9||(F=!0)}else F=!0;if(F)if(h){let q=p>0?f[p-1].endIndex:r;for(let te=q+1;te<=t;te++)f[p++]=new Or(te,"mtkw",1,!1)}else f[p++]=new Or(t,"mtkw",1,!1);else f[p++]=new Or(t,_,0,b);return f}function aut(n,e,t,i){i.sort(Ia.compare);let o=cV.normalize(n,i),r=o.length,s=0,a=[],l=0,c=0;for(let u=0,h=t.length;uc&&(c=v.startOffset,a[l++]=new Or(c,g,_,b)),v.endOffset+1<=p)c=v.endOffset+1,a[l++]=new Or(c,g+" "+v.className,_|v.metadata,b),s++;else{c=p,a[l++]=new Or(c,g+" "+v.className,_|v.metadata,b);break}}p>c&&(c=p,a[l++]=new Or(c,g,_,b))}let d=t[t.length-1].endIndex;if(s'):e.appendString("");for(let N=0,M=c.length;N=d&&(B+=ni)}}for(ae&&(e.appendString(' style="width:'),e.appendString(String(p*ue)),e.appendString('px"')),e.appendASCIICharCode(62);w1?e.appendCharCode(8594):e.appendCharCode(65515);for(let ni=2;ni<=Je;ni++)e.appendCharCode(160)}else B=2,Je=1,e.appendCharCode(g),e.appendCharCode(8204);C+=B,L+=Je,w>=d&&(y+=Je)}}else for(e.appendASCIICharCode(62);w=d&&(y+=B)}X?E++:E=0,w>=s&&!x&&F.isPseudoAfter()&&(x=!0,v.setColumnInfo(w+1,N,C,L)),e.appendString("")}return x||v.setColumnInfo(s+1,c.length-1,C,L),a&&(e.appendString(''),e.appendString(m("showMore","Show more ({0})",dut(l))),e.appendString("")),e.appendString(""),new Y2(v,f,o)}function cut(n){return n.toString(16).toUpperCase().padStart(4,"0")}function dut(n){return n<1024?m("overflow.chars","{0} chars",n):n<1024*1024?`${(n/1024).toFixed(1)} KB`:`${(n/1024/1024).toFixed(1)} MB`}var hE,id,K2,G2,Y2,Rue,Aue,Tw=k(()=>{pe();Qe();Y_();e0();q5e();hE=class{constructor(e,t){this.startOffset=e,this.endOffset=t}equals(e){return this.startOffset===e.startOffset&&this.endOffset===e.endOffset}},id=class{constructor(e,t,i,o,r,s,a,l,c,d,u,h,f,p,g,_,b,v,x){this.useMonospaceOptimizations=e,this.canUseHalfwidthRightwardsArrow=t,this.lineContent=i,this.continuesWithWrappedLine=o,this.isBasicASCII=r,this.containsRTL=s,this.fauxIndentLength=a,this.lineTokens=l,this.lineDecorations=c.sort(Ia.compare),this.tabSize=d,this.startVisibleColumn=u,this.spaceWidth=h,this.stopRenderingLineAfter=g,this.renderWhitespace=_==="all"?4:_==="boundary"?1:_==="selection"?2:_==="trailing"?3:0,this.renderControlCharacters=b,this.fontLigatures=v,this.selectionsOnLine=x&&x.sort((C,L)=>C.startOffset>>16}static getCharIndex(e){return(e&65535)>>>0}constructor(e,t){this.length=e,this._data=new Uint32Array(this.length),this._horizontalOffset=new Uint32Array(this.length)}setColumnInfo(e,t,i,o){let r=(t<<16|i<<0)>>>0;this._data[e-1]=r,this._horizontalOffset[e-1]=o}getHorizontalOffset(e){return this._horizontalOffset.length===0?0:this._horizontalOffset[e-1]}charOffsetToPartData(e){return this.length===0?0:e<0?this._data[0]:e>=this.length?this._data[this.length-1]:this._data[e]}getDomPosition(e){let t=this.charOffsetToPartData(e-1),i=n.getPartIndex(t),o=n.getCharIndex(t);return new K2(i,o)}getColumn(e,t){return this.partDataToCharOffset(e.partIndex,t,e.charIndex)+1}partDataToCharOffset(e,t,i){if(this.length===0)return 0;let o=(e<<16|i<<0)>>>0,r=0,s=this.length-1;for(;r+1>>1,_=this._data[g];if(_===o)return g;_>o?s=g:r=g}if(r===s)return r;let a=this._data[r],l=this._data[s];if(a===o)return r;if(l===o)return s;let c=n.getPartIndex(a),d=n.getCharIndex(a),u=n.getPartIndex(l),h;c!==u?h=t:h=n.getCharIndex(l);let f=i-d,p=h-i;return f<=p?r:s}},Y2=class{constructor(e,t,i){this._renderLineOutputBrand=void 0,this.characterMapping=e,this.containsRTL=t,this.containsForeignElements=i}};Rue=class{constructor(e,t,i,o){this.characterMapping=e,this.html=t,this.containsRTL=i,this.containsForeignElements=o}};Aue=class{constructor(e,t,i,o,r,s,a,l,c,d,u,h,f,p,g,_){this.fontIsMonospace=e,this.canUseHalfwidthRightwardsArrow=t,this.lineContent=i,this.len=o,this.isOverflowing=r,this.overflowingCharCount=s,this.parts=a,this.containsForeignElements=l,this.fauxIndentLength=c,this.tabSize=d,this.startVisibleColumn=u,this.containsRTL=h,this.spaceWidth=f,this.renderSpaceCharCode=p,this.renderWhitespace=g,this.renderControlCharacters=_}}});var Z2,dV,t0,_c,Fb,uV,pE,i0,Af=k(()=>{at();Qe();we();Z2=class{constructor(e,t,i,o){this._viewportBrand=void 0,this.top=e|0,this.left=t|0,this.width=i|0,this.height=o|0}},dV=class{constructor(e,t){this.tabSize=e,this.data=t}},t0=class{constructor(e,t,i,o,r,s,a){this._viewLineDataBrand=void 0,this.content=e,this.continuesWithWrappedLine=t,this.minColumn=i,this.maxColumn=o,this.startVisibleColumn=r,this.tokens=s,this.inlineDecorations=a}},_c=class n{constructor(e,t,i,o,r,s,a,l,c,d){this.minColumn=e,this.maxColumn=t,this.content=i,this.continuesWithWrappedLine=o,this.isBasicASCII=n.isBasicASCII(i,s),this.containsRTL=n.containsRTL(i,this.isBasicASCII,r),this.tokens=a,this.inlineDecorations=l,this.tabSize=c,this.startVisibleColumn=d}static isBasicASCII(e,t){return t?Im(e):!0}static containsRTL(e,t,i){return!t&&i?dp(e):!1}},Fb=class{constructor(e,t,i){this.range=e,this.inlineClassName=t,this.type=i}},uV=class{constructor(e,t,i,o){this.startOffset=e,this.endOffset=t,this.inlineClassName=i,this.inlineClassNameAffectsLetterSpacing=o}toInlineDecoration(e){return new Fb(new S(e,this.startOffset+1,e,this.endOffset+1),this.inlineClassName,this.inlineClassNameAffectsLetterSpacing?3:0)}},pE=class{constructor(e,t){this._viewModelDecorationBrand=void 0,this.range=e,this.options=t}},i0=class n{constructor(e,t,i){this.color=e,this.zIndex=t,this.data=i}static compareByRenderingProps(e,t){return e.zIndex===t.zIndex?e.colort.color?1:0:e.zIndex-t.zIndex}static equals(e,t){return e.color===t.color&&e.zIndex===t.zIndex&&oi(e.data,t.data)}static equalsArr(e,t){return oi(e,t,n.equals)}}});function uut(n){return Array.isArray(n)}function G5e(n){return!uut(n)}function Mue(n){return typeof n=="string"}function Pue(n){return!Mue(n)}function Dw(n){return!n}function Ap(n,e){return n.ignoreCase&&e?e.toLowerCase():e}function Oue(n){return n.replace(/[&<>'"_]/g,"-")}function Y5e(n,e){console.log(`${n.languageId}: ${e}`)}function On(n,e){return new Error(`${n.languageId}: ${e}`)}function Fg(n,e,t,i,o){let r=/\$((\$)|(#)|(\d\d?)|[sS](\d\d?)|@(\w+))/g,s=null;return e.replace(r,function(a,l,c,d,u,h,f,p,g){return Dw(c)?Dw(d)?!Dw(u)&&u0;){let i=n.tokenizer[t];if(i)return i;let o=t.lastIndexOf(".");o<0?t=null:t=t.substr(0,o)}return null}function X5e(n,e){let t=e;for(;t&&t.length>0;){if(n.stateNames[t])return!0;let o=t.lastIndexOf(".");o<0?t=null:t=t.substr(0,o)}return!1}var Fue=k(()=>{});function put(n,e){if(!e)return null;e=Ap(n,e);let t=n.brackets;for(let i of t){if(i.open===e)return{token:i.token,bracketType:1};if(i.close===e)return{token:i.token,bracketType:-1}}return null}var hut,fut,Bue,J5e,J2,gE,mE,Nw,Q2,Wue,Hue,n0,zue=k(()=>{j();Ji();tI();Fue();en();hut=function(n,e,t,i){var o=arguments.length,r=o<3?e:i===null?i=Object.getOwnPropertyDescriptor(e,t):i,s;if(typeof Reflect=="object"&&typeof Reflect.decorate=="function")r=Reflect.decorate(n,e,t,i);else for(var a=n.length-1;a>=0;a--)(s=n[a])&&(r=(o<3?s(r):o>3?s(e,t,r):s(e,t))||r);return o>3&&r&&Object.defineProperty(e,t,r),r},fut=function(n,e){return function(t,i){e(t,i,n)}},J5e=5,J2=class n{static{this._INSTANCE=new n(J5e)}static create(e,t){return this._INSTANCE.create(e,t)}constructor(e){this._maxCacheDepth=e,this._entries=Object.create(null)}create(e,t){if(e!==null&&e.depth>=this._maxCacheDepth)return new gE(e,t);let i=gE.getStackElementId(e);i.length>0&&(i+="|"),i+=t;let o=this._entries[i];return o||(o=new gE(e,t),this._entries[i]=o,o)}},gE=class n{constructor(e,t){this.parent=e,this.state=t,this.depth=(this.parent?this.parent.depth:0)+1}static getStackElementId(e){let t="";for(;e!==null;)t.length>0&&(t+="|"),t+=e.state,e=e.parent;return t}static _equals(e,t){for(;e!==null&&t!==null;){if(e===t)return!0;if(e.state!==t.state)return!1;e=e.parent,t=t.parent}return e===null&&t===null}equals(e){return n._equals(this,e)}push(e){return J2.create(this,e)}pop(){return this.parent}popall(){let e=this;for(;e.parent;)e=e.parent;return e}switchTo(e){return J2.create(this.parent,e)}},mE=class n{constructor(e,t){this.languageId=e,this.state=t}equals(e){return this.languageId===e.languageId&&this.state.equals(e.state)}clone(){return this.state.clone()===this.state?this:new n(this.languageId,this.state)}},Nw=class n{static{this._INSTANCE=new n(J5e)}static create(e,t){return this._INSTANCE.create(e,t)}constructor(e){this._maxCacheDepth=e,this._entries=Object.create(null)}create(e,t){if(t!==null)return new Q2(e,t);if(e!==null&&e.depth>=this._maxCacheDepth)return new Q2(e,t);let i=gE.getStackElementId(e),o=this._entries[i];return o||(o=new Q2(e,null),this._entries[i]=o,o)}},Q2=class n{constructor(e,t){this.stack=e,this.embeddedLanguageData=t}clone(){return(this.embeddedLanguageData?this.embeddedLanguageData.clone():null)===this.embeddedLanguageData?this:Nw.create(this.stack,this.embeddedLanguageData)}equals(e){return!(e instanceof n)||!this.stack.equals(e.stack)?!1:this.embeddedLanguageData===null&&e.embeddedLanguageData===null?!0:this.embeddedLanguageData===null||e.embeddedLanguageData===null?!1:this.embeddedLanguageData.equals(e.embeddedLanguageData)}},Wue=class{constructor(){this._tokens=[],this._languageId=null,this._lastTokenType=null,this._lastTokenLanguage=null}enterLanguage(e){this._languageId=e}emit(e,t){this._lastTokenType===t&&this._lastTokenLanguage===this._languageId||(this._lastTokenType=t,this._lastTokenLanguage=this._languageId,this._tokens.push(new lp(e,t,this._languageId)))}nestedLanguageTokenize(e,t,i,o){let r=i.languageId,s=i.state,a=$i.get(r);if(!a)return this.enterLanguage(r),this.emit(o,""),s;let l=a.tokenize(e,t,s);if(o!==0)for(let c of l.tokens)this._tokens.push(new lp(c.offset+o,c.type,c.language));else this._tokens=this._tokens.concat(l.tokens);return this._lastTokenType=null,this._lastTokenLanguage=null,this._languageId=null,l.endState}finalize(e){return new px(this._tokens,e)}},Hue=class n{constructor(e,t){this._languageService=e,this._theme=t,this._prependTokens=null,this._tokens=[],this._currentLanguageId=0,this._lastTokenMetadata=0}enterLanguage(e){this._currentLanguageId=this._languageService.languageIdCodec.encodeLanguageId(e)}emit(e,t){let i=this._theme.match(this._currentLanguageId,t)|1024;this._lastTokenMetadata!==i&&(this._lastTokenMetadata=i,this._tokens.push(e),this._tokens.push(i))}static _merge(e,t,i){let o=e!==null?e.length:0,r=t.length,s=i!==null?i.length:0;if(o===0&&r===0&&s===0)return new Uint32Array(0);if(o===0&&r===0)return i;if(r===0&&s===0)return e;let a=new Uint32Array(o+r+s);e!==null&&a.set(e);for(let l=0;l{if(s)return;let l=!1;for(let c=0,d=a.changedLanguages.length;c{a.affectsConfiguration("editor.maxTokenizationLineLength")&&(this._maxTokenizationLineLength=this._configurationService.getValue("editor.maxTokenizationLineLength",{overrideIdentifier:this._languageId}))}))}getLoadStatus(){let e=[];for(let t in this._embeddedLanguages){let i=$i.get(t);if(i){if(i instanceof Bue){let o=i.getLoadStatus();o.loaded===!1&&e.push(o.promise)}continue}$i.isResolved(t)||e.push($i.getOrCreate(t))}return e.length===0?{loaded:!0}:{loaded:!1,promise:Promise.all(e).then(t=>{})}}getInitialState(){let e=J2.create(null,this._lexer.start);return Nw.create(e,null)}tokenize(e,t,i){if(e.length>=this._maxTokenizationLineLength)return eI(this._languageId,i);let o=new Wue,r=this._tokenize(e,t,i,o);return o.finalize(r)}tokenizeEncoded(e,t,i){if(e.length>=this._maxTokenizationLineLength)return sw(this._languageService.languageIdCodec.encodeLanguageId(this._languageId),i);let o=new Hue(this._languageService,this._standaloneThemeService.getColorTheme().tokenTheme),r=this._tokenize(e,t,i,o);return o.finalize(r)}_tokenize(e,t,i,o){return i.embeddedLanguageData?this._nestedTokenize(e,t,i,0,o):this._myTokenize(e,t,i,0,o)}_findLeavingNestedLanguageOffset(e,t){let i=this._lexer.tokenizer[t.stack.state];if(!i&&(i=X2(this._lexer,t.stack.state),!i))throw On(this._lexer,"tokenizer state is not defined: "+t.stack.state);let o=-1,r=!1;for(let s of i){if(!Pue(s.action)||s.action.nextEmbedded!=="@pop")continue;r=!0;let a=s.resolveRegex(t.stack.state),l=a.source;if(l.substr(0,4)==="^(?:"&&l.substr(l.length-1,1)===")"){let d=(a.ignoreCase?"i":"")+(a.unicode?"u":"");a=new RegExp(l.substr(4,l.length-5),d)}let c=e.search(a);c===-1||c!==0&&s.matchOnlyAtLineStart||(o===-1||c0&&r.nestedLanguageTokenize(a,!1,i.embeddedLanguageData,o);let l=e.substring(s);return this._myTokenize(l,t,i,o+s,r)}_safeRuleName(e){return e?e.name:"(unknown)"}_myTokenize(e,t,i,o,r){r.enterLanguage(this._languageId);let s=e.length,a=t&&this._lexer.includeLF?e+` `:e,l=a.length,c=i.embeddedLanguageData,d=i.stack,u=0,h=null,f=!0;for(;f||u=l)break;f=!1;let N=this._lexer.tokenizer[b];if(!N&&(N=X2(this._lexer,b),!N))throw On(this._lexer,"tokenizer state is not defined: "+b);let M=a.substr(u);for(let F of N)if((u===0||!F.matchOnlyAtLineStart)&&(v=M.match(F.resolveRegex(b)),v)){x=v[0],w=F.action;break}}if(v||(v=[""],x=""),w||(u=this._lexer.maxStack)throw On(this._lexer,"maximum tokenizer stack size reached: ["+d.state+","+d.parent.state+",...]");d=d.push(b)}else if(w.next==="@pop"){if(d.depth<=1)throw On(this._lexer,"trying to pop an empty stack in rule: "+this._safeRuleName(y));d=d.pop()}else if(w.next==="@popall")d=d.popall();else{let N=Fg(this._lexer,w.next,x,v,b);if(N[0]==="@"&&(N=N.substr(1)),X2(this._lexer,N))d=d.push(N);else throw On(this._lexer,"trying to set a next state '"+N+"' that is undefined in rule: "+this._safeRuleName(y))}}w.log&&typeof w.log=="string"&&Y5e(this._lexer,this._lexer.languageId+": "+Fg(this._lexer,w.log,x,v,b))}if(L===null)throw On(this._lexer,"lexer rule has no well-defined action in rule: "+this._safeRuleName(y));let E=N=>{let M=this._languageService.getLanguageIdByLanguageName(N)||this._languageService.getLanguageIdByMimeType(N)||N,F=this._getNestedEmbeddedLanguageData(M);if(u0)throw On(this._lexer,"groups cannot be nested: "+this._safeRuleName(y));if(v.length!==L.length+1)throw On(this._lexer,"matched number of groups does not match the number of actions in rule: "+this._safeRuleName(y));let N=0;for(let M=1;M{let s=()=>{let a=_ut(n,e,t,i);if(t instanceof n0){let l=t.getLoadStatus();if(l.loaded===!1){l.promise.then(s,r);return}}o(a)};s()})}function e3e(n,e,t){let i=[],r=new Uint32Array(2);r[0]=0,r[1]=33587200;for(let s=0,a=n.length;s")}return i.join("")}function _ut(n,e,t,i){let o=[],r=t.getInitialState();for(let s=0,a=n.length;s"),r=c.endState}return o.join("")}var mut,_E,t3e=k(()=>{Rm();Qe();Ji();Dh();Tw();Af();zue();mut=Tl("standaloneColorizer",{createHTML:n=>n}),_E=class{static colorizeElement(e,t,i,o){o=o||{};let r=o.theme||"vs",s=o.mimeType||i.getAttribute("lang")||i.getAttribute("data-lang");if(!s)return console.error("Mode not detected"),Promise.resolve();let a=t.getLanguageIdByMimeType(s)||s;e.setTheme(r);let l=i.firstChild?i.firstChild.nodeValue:"";i.className+=" "+r;let c=d=>{let u=mut?.createHTML(d)??d;i.innerHTML=u};return this.colorize(t,l||"",a,o).then(c,d=>console.error(d))}static async colorize(e,t,i,o){let r=e.languageIdCodec,s=4;o&&typeof o.tabSize=="number"&&(s=o.tabSize),oL(t)&&(t=t.substr(1));let a=Qa(t);if(!e.isRegisteredLanguageId(i))return e3e(a,s,r);let l=await $i.getOrCreate(i);return l?gut(a,s,l,r):e3e(a,s,r)}static colorizeLine(e,t,i,o,r=4){let s=_c.isBasicASCII(e,t),a=_c.containsRTL(e,s,i);return fE(new id(!1,!0,e,!1,s,a,0,o,[],r,0,0,0,0,-1,"none",!1,!1,null)).html}static colorizeModelLine(e,t,i=4){let o=e.getLineContent(t);e.tokenization.forceTokenization(t);let s=e.tokenization.getLineTokens(t).inflate();return this.colorizeLine(o,e.mightContainNonBasicASCII(),e.mightContainRTL(),s,i)}}});var but,vut,hV,i3e=k(()=>{HW();mt();but=function(n,e,t,i){var o=arguments.length,r=o<3?e:i===null?i=Object.getOwnPropertyDescriptor(e,t):i,s;if(typeof Reflect=="object"&&typeof Reflect.decorate=="function")r=Reflect.decorate(n,e,t,i);else for(var a=n.length-1;a>=0;a--)(s=n[a])&&(r=(o<3?s(r):o>3?s(e,t,r):s(e,t))||r);return o>3&&r&&Object.defineProperty(e,t,r),r},vut=function(n,e){return function(t,i){e(t,i,n)}},hV=class{static{this.ID="editor.contrib.markerDecorations"}constructor(e,t){}dispose(){}};hV=but([vut(1,DI)],hV);ze(hV.ID,hV,0)});var n3e=k(()=>{});var bE,Vue=k(()=>{j();Ie();ke();bE=class extends D{constructor(e,t){super(),this._onDidChange=this._register(new A),this.onDidChange=this._onDidChange.event,this._referenceDomElement=e,this._width=-1,this._height=-1,this._resizeObserver=null,this.measureReferenceDomElement(!1,t)}dispose(){this.stopObserving(),super.dispose()}getWidth(){return this._width}getHeight(){return this._height}startObserving(){if(!this._resizeObserver&&this._referenceDomElement){let e=null,t=()=>{e?this.observe({width:e.width,height:e.height}):this.observe()},i=!1,o=!1,r=()=>{if(i&&!o)try{i=!1,o=!0,t()}finally{us(Me(this._referenceDomElement),()=>{o=!1,r()})}};this._resizeObserver=new ResizeObserver(s=>{s&&s[0]&&s[0].contentRect?e={width:s[0].contentRect.width,height:s[0].contentRect.height}:e=null,i=!0,r()}),this._resizeObserver.observe(this._referenceDomElement)}}stopObserving(){this._resizeObserver&&(this._resizeObserver.disconnect(),this._resizeObserver=null)}observe(e){this.measureReferenceDomElement(!0,e)}measureReferenceDomElement(e,t){let i=0,o=0;t?(i=t.width,o=t.height):this._referenceDomElement&&(i=this._referenceDomElement.clientWidth,o=this._referenceDomElement.clientHeight),i=Math.max(5,i),o=Math.max(5,o),(this._width!==i||this._height!==o)&&(this._width=i,this._height=o,e&&this._onDidChange.fire())}}});function Mp(n,e){eP.items.push(new eP(n,e))}function qd(n,e){Mp(n,(t,i,o)=>{if(typeof t<"u"){for(let[r,s]of e)if(t===r){o(n,s);return}}})}function o3e(n){eP.items.forEach(e=>e.apply(n))}var eP,xut,r3e=k(()=>{eP=class n{static{this.items=[]}constructor(e,t){this.key=e,this.migrate=t}apply(e){let t=n._read(e,this.key),i=r=>n._read(e,r),o=(r,s)=>n._write(e,r,s);this.migrate(t,i,o)}static _read(e,t){if(typeof e>"u")return;let i=t.indexOf(".");if(i>=0){let o=t.substring(0,i);return this._read(e[o],t.substring(i+1))}return e[t]}static _write(e,t,i){let o=t.indexOf(".");if(o>=0){let r=t.substring(0,o);e[r]=e[r]||{},this._write(e[r],t.substring(o+1),i);return}e[t]=i}};qd("wordWrap",[[!0,"on"],[!1,"off"]]);qd("lineNumbers",[[!0,"on"],[!1,"off"]]);qd("cursorBlinking",[["visible","solid"]]);qd("renderWhitespace",[[!0,"boundary"],[!1,"none"]]);qd("renderLineHighlight",[[!0,"line"],[!1,"none"]]);qd("acceptSuggestionOnEnter",[[!0,"on"],[!1,"off"]]);qd("tabCompletion",[[!1,"off"],[!0,"onlySnippets"]]);qd("hover",[[!0,{enabled:!0}],[!1,{enabled:!1}]]);qd("parameterHints",[[!0,{enabled:!0}],[!1,{enabled:!1}]]);qd("autoIndent",[[!1,"advanced"],[!0,"full"]]);qd("matchBrackets",[[!0,"always"],[!1,"never"]]);qd("renderFinalNewline",[[!0,"on"],[!1,"off"]]);qd("cursorSmoothCaretAnimation",[[!0,"on"],[!1,"off"]]);qd("occurrencesHighlight",[[!0,"singleFile"],[!1,"off"]]);qd("wordBasedSuggestions",[[!0,"matchingDocuments"],[!1,"off"]]);Mp("autoClosingBrackets",(n,e,t)=>{n===!1&&(t("autoClosingBrackets","never"),typeof e("autoClosingQuotes")>"u"&&t("autoClosingQuotes","never"),typeof e("autoSurround")>"u"&&t("autoSurround","never"))});Mp("renderIndentGuides",(n,e,t)=>{typeof n<"u"&&(t("renderIndentGuides",void 0),typeof e("guides.indentation")>"u"&&t("guides.indentation",!!n))});Mp("highlightActiveIndentGuide",(n,e,t)=>{typeof n<"u"&&(t("highlightActiveIndentGuide",void 0),typeof e("guides.highlightActiveIndentation")>"u"&&t("guides.highlightActiveIndentation",!!n))});xut={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"};Mp("suggest.filteredTypes",(n,e,t)=>{if(n&&typeof n=="object"){for(let i of Object.entries(xut))n[i[0]]===!1&&typeof e(`suggest.${i[1]}`)>"u"&&t(`suggest.${i[1]}`,!1);t("suggest.filteredTypes",void 0)}});Mp("quickSuggestions",(n,e,t)=>{if(typeof n=="boolean"){let i=n?"on":"off";t("quickSuggestions",{comments:i,strings:i,other:i})}});Mp("experimental.stickyScroll.enabled",(n,e,t)=>{typeof n=="boolean"&&(t("experimental.stickyScroll.enabled",void 0),typeof e("stickyScroll.enabled")>"u"&&t("stickyScroll.enabled",n))});Mp("experimental.stickyScroll.maxLineCount",(n,e,t)=>{typeof n=="number"&&(t("experimental.stickyScroll.maxLineCount",void 0),typeof e("stickyScroll.maxLineCount")>"u"&&t("stickyScroll.maxLineCount",n))});Mp("codeActionsOnSave",(n,e,t)=>{if(n&&typeof n=="object"){let i=!1,o={};for(let r of Object.entries(n))typeof r[1]=="boolean"?(i=!0,o[r[0]]=r[1]?"explicit":"never"):o[r[0]]=r[1];i&&t("codeActionsOnSave",o)}});Mp("codeActionWidget.includeNearbyQuickfixes",(n,e,t)=>{typeof n=="boolean"&&(t("codeActionWidget.includeNearbyQuickfixes",void 0),typeof e("codeActionWidget.includeNearbyQuickFixes")>"u"&&t("codeActionWidget.includeNearbyQuickFixes",n))});Mp("lightbulb.enabled",(n,e,t)=>{typeof n=="boolean"&&t("lightbulb.enabled",n?void 0:"off")})});var Uue,Bb,fV=k(()=>{Ie();Uue=class{constructor(){this._tabFocus=!1,this._onDidChangeTabFocus=new A,this.onDidChangeTabFocus=this._onDidChangeTabFocus.event}getTabFocusMode(){return this._tabFocus}setTabFocusMode(e){this._tabFocus=e,this._onDidChangeTabFocus.fire(this._tabFocus)}},Bb=new Uue});function Cut(n){let e=0;for(;n;)n=Math.floor(n/10),e++;return e||1}function Sut(){let n="";return!Ld&&!uB&&(n+="no-user-select "),Ld&&(n+="no-minimap-shadow ",n+="enable-user-select "),dt&&(n+="mac "),n}function s3e(n){let e=cf(n);return o3e(e),e}var wut,yut,pV,$ue,jue,o0,a3e=k(()=>{Fc();at();Ie();j();ec();Bt();Vue();foe();r3e();fV();ir();mL();$B();uc();ke();VB();wut=function(n,e,t,i){var o=arguments.length,r=o<3?e:i===null?i=Object.getOwnPropertyDescriptor(e,t):i,s;if(typeof Reflect=="object"&&typeof Reflect.decorate=="function")r=Reflect.decorate(n,e,t,i);else for(var a=n.length-1;a>=0;a--)(s=n[a])&&(r=(o<3?s(r):o>3?s(e,t,r):s(e,t))||r);return o>3&&r&&Object.defineProperty(e,t,r),r},yut=function(n,e){return function(t,i){e(t,i,n)}},pV=class extends D{constructor(e,t,i,o,r){super(),this._accessibilityService=r,this._onDidChange=this._register(new A),this.onDidChange=this._onDidChange.event,this._onDidChangeFast=this._register(new A),this.onDidChangeFast=this._onDidChangeFast.event,this._isDominatedByLongLines=!1,this._viewLineCount=1,this._lineNumbersDigitCount=1,this._reservedHeight=0,this._glyphMarginDecorationLaneCount=1,this._computeOptionsMemory=new NR,this.isSimpleWidget=e,this.contextMenuId=t,this._containerObserver=this._register(new bE(o,i.dimension)),this._targetWindowId=Me(o).vscodeWindowId,this._rawOptions=s3e(i),this._validatedOptions=o0.validateOptions(this._rawOptions),this.options=this._computeOptions(),this.options.get(13)&&this._containerObserver.startObserving(),this._register(El.onDidChangeZoomLevel(()=>this._recomputeOptions())),this._register(Bb.onDidChangeTabFocus(()=>this._recomputeOptions())),this._register(this._containerObserver.onDidChange(()=>this._recomputeOptions())),this._register(pA.onDidChange(()=>this._recomputeOptions())),this._register(Cx.getInstance(Me(o)).onDidChange(()=>this._recomputeOptions())),this._register(this._accessibilityService.onDidChangeScreenReaderOptimized(()=>this._recomputeOptions()))}_recomputeOptions(){let e=this._computeOptions(),t=o0.checkEquals(this.options,e);t!==null&&(this.options=e,this._onDidChangeFast.fire(t),this._onDidChange.fire(t))}_computeOptions(){let e=this._readEnvConfiguration(),t=A1.createFromValidatedSettings(this._validatedOptions,e.pixelRatio,this.isSimpleWidget),i=this._readFontInfo(t),o={memory:this._computeOptionsMemory,outerWidth:e.outerWidth,outerHeight:e.outerHeight-this._reservedHeight,fontInfo:i,extraEditorClassName:e.extraEditorClassName,isDominatedByLongLines:this._isDominatedByLongLines,viewLineCount:this._viewLineCount,lineNumbersDigitCount:this._lineNumbersDigitCount,emptySelectionClipboard:e.emptySelectionClipboard,pixelRatio:e.pixelRatio,tabFocusMode:Bb.getTabFocusMode(),accessibilitySupport:e.accessibilitySupport,glyphMarginDecorationLaneCount:this._glyphMarginDecorationLaneCount};return o0.computeOptions(this._validatedOptions,o)}_readEnvConfiguration(){return{extraEditorClassName:Sut(),outerWidth:this._containerObserver.getWidth(),outerHeight:this._containerObserver.getHeight(),emptySelectionClipboard:up||ls,pixelRatio:Cx.getInstance(ioe(this._targetWindowId,!0).window).value,accessibilitySupport:this._accessibilityService.isScreenReaderOptimized()?2:this._accessibilityService.getAccessibilitySupport()}}_readFontInfo(e){return pA.readFontInfo(ioe(this._targetWindowId,!0).window,e)}getRawOptions(){return this._rawOptions}updateOptions(e){let t=s3e(e);o0.applyUpdate(this._rawOptions,t)&&(this._validatedOptions=o0.validateOptions(this._rawOptions),this._recomputeOptions())}observeContainer(e){this._containerObserver.observe(e)}setIsDominatedByLongLines(e){this._isDominatedByLongLines!==e&&(this._isDominatedByLongLines=e,this._recomputeOptions())}setModelLineCount(e){let t=Cut(e);this._lineNumbersDigitCount!==t&&(this._lineNumbersDigitCount=t,this._recomputeOptions())}setViewLineCount(e){this._viewLineCount!==e&&(this._viewLineCount=e,this._recomputeOptions())}setReservedHeight(e){this._reservedHeight!==e&&(this._reservedHeight=e,this._recomputeOptions())}setGlyphMarginDecorationLaneCount(e){this._glyphMarginDecorationLaneCount!==e&&(this._glyphMarginDecorationLaneCount=e,this._recomputeOptions())}};pV=wut([yut(4,$o)],pV);$ue=class{constructor(){this._values=[]}_read(e){return this._values[e]}get(e){return this._values[e]}_write(e,t){this._values[e]=t}},jue=class{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,t){this._values[e]=t}},o0=class n{static validateOptions(e){let t=new $ue;for(let i of rx){let o=i.name==="_never_"?void 0:e[i.name];t._write(i.id,i.validate(o))}return t}static computeOptions(e,t){let i=new jue;for(let o of rx)i._write(o.id,o.compute(t,i,e._read(o.id)));return i}static _deepEquals(e,t){if(typeof e!="object"||typeof t!="object"||!e||!t)return e===t;if(Array.isArray(e)||Array.isArray(t))return Array.isArray(e)&&Array.isArray(t)?oi(e,t):!1;if(Object.keys(e).length!==Object.keys(t).length)return!1;for(let i in e)if(!n._deepEquals(e[i],t[i]))return!1;return!0}static checkEquals(e,t){let i=[],o=!1;for(let r of rx){let s=!n._deepEquals(e._read(r.id),t._read(r.id));i[r.id]=s,s&&(o=!0)}return o?new jk(i):null}static applyUpdate(e,t){let i=!1;for(let o of rx)if(t.hasOwnProperty(o.name)){let r=o.applyUpdate(e[o.name],t[o.name]);e[o.name]=r.newValue,i=i||r.didChange}return i}}});var Bg,que=k(()=>{(function(n){let e={total:0,min:Number.MAX_VALUE,max:0},t={...e},i={...e},o={...e},r=0,s={keydown:0,input:0,render:0};function a(){b(),performance.mark("inputlatency/start"),performance.mark("keydown/start"),s.keydown=1,queueMicrotask(l)}n.onKeyDown=a;function l(){s.keydown===1&&(performance.mark("keydown/end"),s.keydown=2)}function c(){performance.mark("input/start"),s.input=1,_()}n.onBeforeInput=c;function d(){s.input===0&&c(),queueMicrotask(u)}n.onInput=d;function u(){s.input===1&&(performance.mark("input/end"),s.input=2)}function h(){b()}n.onKeyUp=h;function f(){b()}n.onSelectionChange=f;function p(){s.keydown===2&&s.input===2&&s.render===0&&(performance.mark("render/start"),s.render=1,queueMicrotask(g),_())}n.onRenderStart=p;function g(){s.render===1&&(performance.mark("render/end"),s.render=2)}function _(){setTimeout(b)}function b(){s.keydown===2&&s.input===2&&s.render===2&&(performance.mark("inputlatency/end"),performance.measure("keydown","keydown/start","keydown/end"),performance.measure("input","input/start","input/end"),performance.measure("render","render/start","render/end"),performance.measure("inputlatency","inputlatency/start","inputlatency/end"),v("keydown",e),v("input",t),v("render",i),v("inputlatency",o),r++,x())}function v(L,E){let N=performance.getEntriesByName(L)[0].duration;E.total+=N,E.min=Math.min(E.min,N),E.max=Math.max(E.max,N)}function x(){performance.clearMarks("keydown/start"),performance.clearMarks("keydown/end"),performance.clearMarks("input/start"),performance.clearMarks("input/end"),performance.clearMarks("render/start"),performance.clearMarks("render/end"),performance.clearMarks("inputlatency/start"),performance.clearMarks("inputlatency/end"),performance.clearMeasures("keydown"),performance.clearMeasures("input"),performance.clearMeasures("render"),performance.clearMeasures("inputlatency"),s.keydown=0,s.input=0,s.render=0}function w(){if(r===0)return;let L={keydown:y(e),input:y(t),render:y(i),total:y(o),sampleCount:r};return C(e),C(t),C(i),C(o),r=0,L}n.getAndClearMeasurements=w;function y(L){return{average:L.total/r,max:L.max,min:L.min}}function C(L){L.total=0,L.min=Number.MAX_VALUE,L.max=0}})(Bg||(Bg={}))});function bV(n){let e=Ci(n);return new Kue(e.left,e.top,e.width,e.height)}function vV(n,e,t){let i=e.width/n.offsetWidth,o=e.height/n.offsetHeight,r=(t.x-e.x)/i,s=(t.y-e.y)/o;return new Gue(r,s)}function kut(n){return n.replace(/(^[A-Z])/,([e])=>e.toLowerCase()).replace(/([A-Z])/g,([e])=>`-${e.toLowerCase()}`)}var Rw,tP,Kue,Gue,Mf,mV,gV,_V,vE,Yue,xE=k(()=>{ke();qL();pu();ft();j();Wn();Rw=class{constructor(e,t){this.x=e,this.y=t,this._pageCoordinatesBrand=void 0}toClientCoordinates(e){return new tP(this.x-e.scrollX,this.y-e.scrollY)}},tP=class{constructor(e,t){this.clientX=e,this.clientY=t,this._clientCoordinatesBrand=void 0}toPageCoordinates(e){return new Rw(this.clientX+e.scrollX,this.clientY+e.scrollY)}},Kue=class{constructor(e,t,i,o){this.x=e,this.y=t,this.width=i,this.height=o,this._editorPagePositionBrand=void 0}},Gue=class{constructor(e,t){this.x=e,this.y=t,this._positionRelativeToEditorBrand=void 0}};Mf=class extends cs{constructor(e,t,i){super(Me(i),e),this._editorMouseEventBrand=void 0,this.isFromPointerCapture=t,this.pos=new Rw(this.posx,this.posy),this.editorPos=bV(i),this.relativePos=vV(i,this.editorPos,this.pos)}},mV=class{constructor(e){this._editorViewDomNode=e}_create(e){return new Mf(e,!1,this._editorViewDomNode)}onContextMenu(e,t){return U(e,"contextmenu",i=>{t(this._create(i))})}onMouseUp(e,t){return U(e,"mouseup",i=>{t(this._create(i))})}onMouseDown(e,t){return U(e,re.MOUSE_DOWN,i=>{t(this._create(i))})}onPointerDown(e,t){return U(e,re.POINTER_DOWN,i=>{t(this._create(i),i.pointerId)})}onMouseLeave(e,t){return U(e,re.MOUSE_LEAVE,i=>{t(this._create(i))})}onMouseMove(e,t){return U(e,"mousemove",i=>t(this._create(i)))}},gV=class{constructor(e){this._editorViewDomNode=e}_create(e){return new Mf(e,!1,this._editorViewDomNode)}onPointerUp(e,t){return U(e,"pointerup",i=>{t(this._create(i))})}onPointerDown(e,t){return U(e,re.POINTER_DOWN,i=>{t(this._create(i),i.pointerId)})}onPointerLeave(e,t){return U(e,re.POINTER_LEAVE,i=>{t(this._create(i))})}onPointerMove(e,t){return U(e,"pointermove",i=>t(this._create(i)))}},_V=class extends D{constructor(e){super(),this._editorViewDomNode=e,this._globalPointerMoveMonitor=this._register(new kh),this._keydownListener=null}startMonitoring(e,t,i,o,r){this._keydownListener=gi(e.ownerDocument,"keydown",s=>{s.toKeyCodeChord().isModifierKey()||this._globalPointerMoveMonitor.stopMonitoring(!0,s.browserEvent)},!0),this._globalPointerMoveMonitor.startMonitoring(e,t,i,s=>{o(new Mf(s,!0,this._editorViewDomNode))},s=>{this._keydownListener.dispose(),r(s)})}stopMonitoring(){this._globalPointerMoveMonitor.stopMonitoring(!0)}},vE=class n{static{this._idPool=0}constructor(e){this._editor=e,this._instanceId=++n._idPool,this._counter=0,this._rules=new Map,this._garbageCollectionScheduler=new Lt(()=>this.garbageCollect(),1e3)}createClassNameRef(e){let t=this.getOrCreateRule(e);return t.increaseRefCount(),{className:t.className,dispose:()=>{t.decreaseRefCount(),this._garbageCollectionScheduler.schedule()}}}getOrCreateRule(e){let t=this.computeUniqueKey(e),i=this._rules.get(t);if(!i){let o=this._counter++;i=new Yue(t,`dyn-rule-${this._instanceId}-${o}`,T1(this._editor.getContainerDomNode())?this._editor.getContainerDomNode():void 0,e),this._rules.set(t,i)}return i}computeUniqueKey(e){return JSON.stringify(e)}garbageCollect(){for(let e of this._rules.values())e.hasReferences()||(this._rules.delete(e.key),e.dispose())}},Yue=class{constructor(e,t,i,o){this.key=e,this.className=t,this.properties=o,this._referenceCount=0,this._styleElementDisposables=new H,this._styleElement=qr(i,void 0,this._styleElementDisposables),this._styleElement.textContent=this.getCssText(this.className,this.properties)}getCssText(e,t){let i=`.${e} {`;for(let o in t){let r=t[o],s;typeof r=="object"?s=De(r.id):s=r;let a=kut(o);i+=` ${a}: ${s};`}return i+=` }`,i}dispose(){this._styleElementDisposables.dispose(),this._styleElement=void 0}increaseRefCount(){this._referenceCount++}decreaseRefCount(){this._referenceCount--}hasReferences(){return this._referenceCount>0}}});var Pf,wE=k(()=>{j();Pf=class extends D{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 t=!1;for(let i=0,o=e.length;i{wE();wo=class extends Pf{constructor(e){super(),this._context=e,this._context.addEventHandler(this)}dispose(){this._context.removeEventHandler(this),super.dispose()}},na=class{static write(e,t){e.setAttribute("data-mprt",String(t))}static read(e){let t=e.getAttribute("data-mprt");return t===null?0:parseInt(t,10)}static collect(e,t){let i=[],o=0;for(;e&&e!==e.ownerDocument.body&&e!==t;)e.nodeType===e.ELEMENT_NODE&&(i[o++]=this.read(e)),e=e.parentElement;let r=new Uint8Array(o);for(let s=0;s{Zue=class{constructor(e,t){this._restrictedRenderingContextBrand=void 0,this._viewLayout=e,this.viewportData=t,this.scrollWidth=this._viewLayout.getScrollWidth(),this.scrollHeight=this._viewLayout.getScrollHeight(),this.visibleRange=this.viewportData.visibleRange,this.bigNumbersDelta=this.viewportData.bigNumbersDelta;let i=this._viewLayout.getCurrentViewport();this.scrollTop=i.top,this.scrollLeft=i.left,this.viewportWidth=i.width,this.viewportHeight=i.height}getScrolledTopFromAbsoluteTop(e){return e-this.scrollTop}getVerticalOffsetForLineNumber(e,t){return this._viewLayout.getVerticalOffsetForLineNumber(e,t)}getVerticalOffsetAfterLineNumber(e,t){return this._viewLayout.getVerticalOffsetAfterLineNumber(e,t)}getDecorationsInViewport(){return this.viewportData.getDecorationsInViewport()}},xV=class extends Zue{constructor(e,t,i){super(e,t),this._renderingContextBrand=void 0,this._viewLines=i}linesVisibleRangesForRange(e,t){return this._viewLines.linesVisibleRangesForRange(e,t)}visibleRangeForPosition(e){return this._viewLines.visibleRangeForPosition(e)}},wV=class{constructor(e,t,i,o){this.outsideRenderedLine=e,this.lineNumber=t,this.ranges=i,this.continuesOnNextLine=o}},yE=class n{static from(e){let t=new Array(e.length);for(let i=0,o=e.length;i{CE();r0=class{static _createRange(){return this._handyReadyRange||(this._handyReadyRange=document.createRange()),this._handyReadyRange}static _detachRange(e,t){e.selectNodeContents(t)}static _readClientRects(e,t,i,o,r){let s=this._createRange();try{return s.setStart(e,t),s.setEnd(i,o),s.getClientRects()}catch{return null}finally{this._detachRange(s,r)}}static _mergeAdjacentRanges(e){if(e.length===1)return e;e.sort(Pp.compare);let t=[],i=0,o=e[0];for(let r=1,s=e.length;r=a.left?o.width=Math.max(o.width,a.left+a.width-o.left):(t[i++]=o,o=a)}return t[i++]=o,t}static _createHorizontalRangesFromClientRects(e,t,i){if(!e||e.length===0)return null;let o=[];for(let r=0,s=e.length;rl)return null;if(t=Math.min(l,Math.max(0,t)),o=Math.min(l,Math.max(0,o)),t===o&&i===r&&i===0&&!e.children[t].firstChild){let h=e.children[t].getClientRects();return s.markDidDomLayout(),this._createHorizontalRangesFromClientRects(h,s.clientRectDeltaLeft,s.clientRectScale)}t!==o&&o>0&&r===0&&(o--,r=1073741824);let c=e.children[t].firstChild,d=e.children[o].firstChild;if((!c||!d)&&(!c&&i===0&&t>0&&(c=e.children[t-1].firstChild,i=1073741824),!d&&r===0&&o>0&&(d=e.children[o-1].firstChild,r=1073741824)),!c||!d)return null;i=Math.min(c.textContent.length,Math.max(0,i)),r=Math.min(d.textContent.length,Math.max(0,r));let u=this._readClientRects(c,i,d,r,s.endNode);return s.markDidDomLayout(),this._createHorizontalRangesFromClientRects(u,s.clientRectDeltaLeft,s.clientRectScale)}}});function Iut(n,e,t,i,o){return new Xue(n,e,t,i,o)}function Eut(n,e,t,i,o){return new CV(n,e,t,i,o)}function SV(n,e,t){let i=e.textContent.length,o=-1;for(;e;)e=e.previousSibling,o++;return n.getColumn(new K2(o,t),i)}var Lut,kE,nP,Op,SE,CV,Xue,c3e,kV=k(()=>{Fc();Kr();Bt();l3e();CE();e0();Tw();wf();ir();Lut=function(){return Pc?!0:!(Qn||ls||Ld)}(),kE=!0,nP=class{constructor(e,t){this.themeType=t;let i=e.options,o=i.get(50);i.get(38)==="off"?this.renderWhitespace=i.get(100):this.renderWhitespace="none",this.renderControlCharacters=i.get(95),this.spaceWidth=o.spaceWidth,this.middotWidth=o.middotWidth,this.wsmiddotWidth=o.wsmiddotWidth,this.useMonospaceOptimizations=o.isMonospace&&!i.get(33),this.canUseHalfwidthRightwardsArrow=o.canUseHalfwidthRightwardsArrow,this.lineHeight=i.get(67),this.stopRenderingLineAfter=i.get(118),this.fontLigatures=i.get(51)}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}},Op=class n{static{this.CLASS_NAME="view-line"}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=Pt(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 nl(this._options.themeType)||this._options.renderWhitespace==="selection"?(this._isMaybeInvalid=!0,!0):!1}renderLine(e,t,i,o,r){if(this._isMaybeInvalid===!1)return!1;this._isMaybeInvalid=!1;let s=o.getViewLineRenderingData(e),a=this._options,l=Ia.filter(s.inlineDecorations,e,s.minColumn,s.maxColumn),c=null;if(nl(a.themeType)||this._options.renderWhitespace==="selection"){let f=o.selections;for(let p of f){if(p.endLineNumbere)continue;let g=p.startLineNumber===e?p.startColumn:s.minColumn,_=p.endLineNumber===e?p.endColumn:s.maxColumn;g<_&&(nl(a.themeType)&&l.push(new Ia(g,_,"inline-selected-text",0)),this._options.renderWhitespace==="selection"&&(c||(c=[]),c.push(new hE(g-1,_-1))))}}let d=new id(a.useMonospaceOptimizations,a.canUseHalfwidthRightwardsArrow,s.content,s.continuesWithWrappedLine,s.isBasicASCII,s.containsRTL,s.minColumn-1,s.tokens,l,s.tabSize,s.startVisibleColumn,a.spaceWidth,a.middotWidth,a.wsmiddotWidth,a.stopRenderingLineAfter,a.renderWhitespace,a.renderControlCharacters,a.fontLigatures!==ah.OFF,c);if(this._renderedViewLine&&this._renderedViewLine.input.equals(d))return!1;r.appendString('
    ');let u=Ob(d,r);r.appendString("
    ");let h=null;return kE&&Lut&&s.isBasicASCII&&a.useMonospaceOptimizations&&u.containsForeignElements===0&&(h=new SE(this._renderedViewLine?this._renderedViewLine.domNode:null,d,u.characterMapping)),h||(h=c3e(this._renderedViewLine?this._renderedViewLine.domNode:null,d,u.characterMapping,u.containsRTL,u.containsForeignElements)),this._renderedViewLine=h,!0}layoutLine(e,t,i){this._renderedViewLine&&this._renderedViewLine.domNode&&(this._renderedViewLine.domNode.setTop(t),this._renderedViewLine.domNode.setHeight(i))}getWidth(e){return this._renderedViewLine?this._renderedViewLine.getWidth(e):0}getWidthIsFast(){return this._renderedViewLine?this._renderedViewLine.getWidthIsFast():!0}needsMonospaceFontCheck(){return this._renderedViewLine?this._renderedViewLine instanceof SE:!1}monospaceAssumptionsAreValid(){return this._renderedViewLine&&this._renderedViewLine instanceof SE?this._renderedViewLine.monospaceAssumptionsAreValid():kE}onMonospaceAssumptionsInvalidated(){this._renderedViewLine&&this._renderedViewLine instanceof SE&&(this._renderedViewLine=this._renderedViewLine.toSlowRenderedLine())}getVisibleRangesForRange(e,t,i,o){if(!this._renderedViewLine)return null;t=Math.min(this._renderedViewLine.input.lineContent.length+1,Math.max(1,t)),i=Math.min(this._renderedViewLine.input.lineContent.length+1,Math.max(1,i));let r=this._renderedViewLine.input.stopRenderingLineAfter;if(r!==-1&&t>r+1&&i>r+1)return new iP(!0,[new Pp(this.getWidth(o),0)]);r!==-1&&t>r+1&&(t=r+1),r!==-1&&i>r+1&&(i=r+1);let s=this._renderedViewLine.getVisibleRangesForRange(e,t,i,o);return s&&s.length>0?new iP(!1,s):null}getColumnOfNodeOffset(e,t){return this._renderedViewLine?this._renderedViewLine.getColumnOfNodeOffset(e,t):1}},SE=class{constructor(e,t,i){this._cachedWidth=-1,this.domNode=e,this.input=t;let o=Math.floor(t.lineContent.length/300);if(o>0){this._keyColumnPixelOffsetCache=new Float32Array(o);for(let r=0;r=2&&(console.warn("monospace assumptions have been violated, therefore disabling monospace optimizations!"),kE=!1)}return kE}toSlowRenderedLine(){return c3e(this.domNode,this.input,this._characterMapping,!1,0)}getVisibleRangesForRange(e,t,i,o){let r=this._getColumnPixelOffset(e,t,o),s=this._getColumnPixelOffset(e,i,o);return[new Pp(r,s-r)]}_getColumnPixelOffset(e,t,i){if(t<=300){let c=this._characterMapping.getHorizontalOffset(t);return this._charWidth*c}let o=Math.floor((t-1)/300)-1,r=(o+1)*300+1,s=-1;if(this._keyColumnPixelOffsetCache&&(s=this._keyColumnPixelOffsetCache[o],s===-1&&(s=this._actualReadPixelOffset(e,r,i),this._keyColumnPixelOffsetCache[o]=s)),s===-1){let c=this._characterMapping.getHorizontalOffset(t);return this._charWidth*c}let a=this._characterMapping.getHorizontalOffset(r),l=this._characterMapping.getHorizontalOffset(t);return s+this._charWidth*(l-a)}_getReadingTarget(e){return e.domNode.firstChild}_actualReadPixelOffset(e,t,i){if(!this.domNode)return-1;let o=this._characterMapping.getDomPosition(t),r=r0.readHorizontalRanges(this._getReadingTarget(this.domNode),o.partIndex,o.charIndex,o.partIndex,o.charIndex,i);return!r||r.length===0?-1:r[0].left}getColumnOfNodeOffset(e,t){return SV(this._characterMapping,e,t)}},CV=class{constructor(e,t,i,o,r){if(this.domNode=e,this.input=t,this._characterMapping=i,this._isWhitespaceOnly=/^\s*$/.test(t.lineContent),this._containsForeignElements=r,this._cachedWidth=-1,this._pixelOffsetCache=null,!o||this._characterMapping.length===0){this._pixelOffsetCache=new Float32Array(Math.max(2,this._characterMapping.length+1));for(let s=0,a=this._characterMapping.length;s<=a;s++)this._pixelOffsetCache[s]=-1}}_getReadingTarget(e){return e.domNode.firstChild}getWidth(e){return this.domNode?(this._cachedWidth===-1&&(this._cachedWidth=this._getReadingTarget(this.domNode).offsetWidth,e?.markDidDomLayout()),this._cachedWidth):0}getWidthIsFast(){return this._cachedWidth!==-1}getVisibleRangesForRange(e,t,i,o){if(!this.domNode)return null;if(this._pixelOffsetCache!==null){let r=this._readPixelOffset(this.domNode,e,t,o);if(r===-1)return null;let s=this._readPixelOffset(this.domNode,e,i,o);return s===-1?null:[new Pp(r,s-r)]}return this._readVisibleRangesForRange(this.domNode,e,t,i,o)}_readVisibleRangesForRange(e,t,i,o,r){if(i===o){let s=this._readPixelOffset(e,t,i,r);return s===-1?null:[new Pp(s,0)]}else return this._readRawVisibleRangesForRange(e,i,o,r)}_readPixelOffset(e,t,i,o){if(this._characterMapping.length===0){if(this._containsForeignElements===0||this._containsForeignElements===2)return 0;if(this._containsForeignElements===1)return this.getWidth(o);let r=this._getReadingTarget(e);return r.firstChild?(o.markDidDomLayout(),r.firstChild.offsetWidth):0}if(this._pixelOffsetCache!==null){let r=this._pixelOffsetCache[i];if(r!==-1)return r;let s=this._actualReadPixelOffset(e,t,i,o);return this._pixelOffsetCache[i]=s,s}return this._actualReadPixelOffset(e,t,i,o)}_actualReadPixelOffset(e,t,i,o){if(this._characterMapping.length===0){let l=r0.readHorizontalRanges(this._getReadingTarget(e),0,0,0,0,o);return!l||l.length===0?-1:l[0].left}if(i===this._characterMapping.length&&this._isWhitespaceOnly&&this._containsForeignElements===0)return this.getWidth(o);let r=this._characterMapping.getDomPosition(i),s=r0.readHorizontalRanges(this._getReadingTarget(e),r.partIndex,r.charIndex,r.partIndex,r.charIndex,o);if(!s||s.length===0)return-1;let a=s[0].left;if(this.input.isBasicASCII){let l=this._characterMapping.getHorizontalOffset(i),c=Math.round(this.input.spaceWidth*l);if(Math.abs(c-a)<=1)return c}return a}_readRawVisibleRangesForRange(e,t,i,o){if(t===1&&i===this._characterMapping.length)return[new Pp(0,this.getWidth(o))];let r=this._characterMapping.getDomPosition(t),s=this._characterMapping.getDomPosition(i);return r0.readHorizontalRanges(this._getReadingTarget(e),r.partIndex,r.charIndex,s.partIndex,s.charIndex,o)}getColumnOfNodeOffset(e,t){return SV(this._characterMapping,e,t)}},Xue=class extends CV{_readVisibleRangesForRange(e,t,i,o,r){let s=super._readVisibleRangesForRange(e,t,i,o,r);if(!s||s.length===0||i===o||i===1&&o===this._characterMapping.length)return s;if(!this.input.containsRTL){let a=this._readPixelOffset(e,t,o,r);if(a!==-1){let l=s[s.length-1];l.left{Tf();s0=class n{static whitespaceVisibleColumn(e,t,i){let o=e.length,r=0,s=-1,a=-1;for(let l=0;lr.left+r.width)_=p.length;else{let v=ihe.getInstance();for(let x=0;x{xE();Wl();kV();qe();we();Tf();ke();Que();cp();Wg=class{constructor(e=null){this.hitTarget=e,this.type=0}},LV=class{get hitTarget(){return this.spanNode}constructor(e,t,i){this.position=e,this.spanNode=t,this.injectedText=i,this.type=1}};(function(n){function e(t,i,o){let r=t.getPositionFromDOMInfo(i,o);return r?new LV(r,i,null):new Wg(i)}n.createFromDOMInfo=e})(a0||(a0={}));IV=class{constructor(e,t){this.lastViewCursorsRenderData=e,this.lastTextareaPosition=t}},oa=class{static _deduceRage(e,t=null){return!t&&e?new S(e.lineNumber,e.column,e.lineNumber,e.column):t??null}static createUnknown(e,t,i){return{type:0,element:e,mouseColumn:t,position:i,range:this._deduceRage(i)}}static createTextarea(e,t){return{type:1,element:e,mouseColumn:t,position:null,range:null}}static createMargin(e,t,i,o,r,s){return{type:e,element:t,mouseColumn:i,position:o,range:r,detail:s}}static createViewZone(e,t,i,o,r){return{type:e,element:t,mouseColumn:i,position:o,range:this._deduceRage(o),detail:r}}static createContentText(e,t,i,o,r){return{type:6,element:e,mouseColumn:t,position:i,range:this._deduceRage(i,o),detail:r}}static createContentEmpty(e,t,i,o){return{type:7,element:e,mouseColumn:t,position:i,range:this._deduceRage(i),detail:o}}static createContentWidget(e,t,i){return{type:9,element:e,mouseColumn:t,position:null,range:null,detail:i}}static createScrollbar(e,t,i){return{type:11,element:e,mouseColumn:t,position:i,range:this._deduceRage(i)}}static createOverlayWidget(e,t,i){return{type:12,element:e,mouseColumn:t,position:null,range:null,detail:i}}static createOutsideEditor(e,t,i,o){return{type:13,element:null,mouseColumn:e,position:t,range:this._deduceRage(t),outsidePosition:i,outsideDistance:o}}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)}},al=class{static isTextArea(e){return e.length===2&&e[0]===3&&e[1]===7}static isChildOfViewLines(e){return e.length>=4&&e[0]===3&&e[3]===8}static isStrictChildOfViewLines(e){return e.length>4&&e[0]===3&&e[3]===8}static isChildOfScrollableElement(e){return e.length>=2&&e[0]===3&&e[1]===6}static isChildOfMinimap(e){return e.length>=2&&e[0]===3&&e[1]===9}static isChildOfContentWidgets(e){return e.length>=4&&e[0]===3&&e[3]===1}static isChildOfOverflowGuard(e){return e.length>=1&&e[0]===3}static isChildOfOverflowingContentWidgets(e){return e.length>=1&&e[0]===2}static isChildOfOverlayWidgets(e){return e.length>=2&&e[0]===3&&e[1]===4}static isChildOfOverflowingOverlayWidgets(e){return e.length>=1&&e[0]===5}},LE=class n{constructor(e,t,i){this.viewModel=e.viewModel;let o=e.configuration.options;this.layoutInfo=o.get(146),this.viewDomNode=t.viewDomNode,this.lineHeight=o.get(67),this.stickyTabStops=o.get(117),this.typicalHalfwidthCharacterWidth=o.get(50).typicalHalfwidthCharacterWidth,this.lastRenderData=i,this._context=e,this._viewHelper=t}getZoneAtCoord(e){return n.getZoneAtCoord(this._context,e)}static getZoneAtCoord(e,t){let i=e.viewLayout.getWhitespaceAtVerticalOffset(t);if(i){let o=i.verticalOffset+i.height/2,r=e.viewModel.getLineCount(),s=null,a,l=null;return i.afterLineNumber!==r&&(l=new P(i.afterLineNumber+1,1)),i.afterLineNumber>0&&(s=new P(i.afterLineNumber,e.viewModel.getLineMaxColumn(i.afterLineNumber))),l===null?a=s:s===null?a=l:t=e.layoutInfo.glyphMarginLeft,this.isInContentArea=!this.isInMarginArea,this.mouseColumn=Math.max(0,IE._getMouseColumn(this.mouseContentHorizontalOffset,e.typicalHalfwidthCharacterWidth))}},the=class extends ehe{get target(){return this._useHitTestTarget?this.hitTestResult.value.hitTarget:this._eventTarget}get targetPath(){return this._targetPathCacheElement!==this.target&&(this._targetPathCacheElement=this.target,this._targetPathCacheValue=na.collect(this.target,this._ctx.viewDomNode)),this._targetPathCacheValue}constructor(e,t,i,o,r){super(e,t,i,o),this.hitTestResult=new or(()=>IE.doHitTest(this._ctx,this)),this._targetPathCacheElement=null,this._targetPathCacheValue=new Uint8Array(0),this._ctx=e,this._eventTarget=r;let s=!!this._eventTarget;this._useHitTestTarget=!s}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}`}get wouldBenefitFromHitTestTargetSwitch(){return!this._useHitTestTarget&&this.hitTestResult.value.hitTarget!==null&&this.target!==this.hitTestResult.value.hitTarget}switchToHitTestTarget(){this._useHitTestTarget=!0}_getMouseColumn(e=null){return e&&e.columns.contentLeft+s.width)continue;let a=e.getVerticalOffsetForLineNumber(s.position.lineNumber);if(a<=r&&r<=a+s.height)return t.fulfillContentText(s.position,null,{mightBeForeignElement:!1,injectedText:null})}}return null}static _hitTestViewZone(e,t){let i=e.getZoneAtCoord(t.mouseVerticalOffset);if(i){let o=t.isInContentArea?8:5;return t.fulfillViewZone(o,i.position,i)}return null}static _hitTestTextArea(e,t){return al.isTextArea(t.targetPath)?e.lastRenderData.lastTextareaPosition?t.fulfillContentText(e.lastRenderData.lastTextareaPosition,null,{mightBeForeignElement:!1,injectedText:null}):t.fulfillTextarea():null}static _hitTestMargin(e,t){if(t.isInMarginArea){let i=e.getFullLineRangeAtCoord(t.mouseVerticalOffset),o=i.range.getStartPosition(),r=Math.abs(t.relativePos.x),s={isAfterLines:i.isAfterLines,glyphMarginLeft:e.layoutInfo.glyphMarginLeft,glyphMarginWidth:e.layoutInfo.glyphMarginWidth,lineNumbersWidth:e.layoutInfo.lineNumbersWidth,offsetX:r};if(r-=e.layoutInfo.glyphMarginLeft,r<=e.layoutInfo.glyphMarginWidth){let a=e.viewModel.coordinatesConverter.convertViewPositionToModelPosition(i.range.getStartPosition()),l=e.viewModel.glyphLanes.getLanesAtLine(a.lineNumber);return s.glyphMarginLane=l[Math.floor(r/e.lineHeight)],t.fulfillMargin(2,o,i.range,s)}return r-=e.layoutInfo.glyphMarginWidth,r<=e.layoutInfo.lineNumbersWidth?t.fulfillMargin(3,o,i.range,s):(r-=e.layoutInfo.lineNumbersWidth,t.fulfillMargin(4,o,i.range,s))}return null}static _hitTestViewLines(e,t){if(!al.isChildOfViewLines(t.targetPath))return null;if(e.isInTopPadding(t.mouseVerticalOffset))return t.fulfillContentEmpty(new P(1,1),d3e);if(e.isAfterLines(t.mouseVerticalOffset)||e.isInBottomPadding(t.mouseVerticalOffset)){let o=e.viewModel.getLineCount(),r=e.viewModel.getLineMaxColumn(o);return t.fulfillContentEmpty(new P(o,r),d3e)}if(al.isStrictChildOfViewLines(t.targetPath)){let o=e.getLineNumberAtVerticalOffset(t.mouseVerticalOffset);if(e.viewModel.getLineLength(o)===0){let s=e.getLineWidth(o),a=Jue(t.mouseContentHorizontalOffset-s);return t.fulfillContentEmpty(new P(o,1),a)}let r=e.getLineWidth(o);if(t.mouseContentHorizontalOffset>=r){let s=Jue(t.mouseContentHorizontalOffset-r),a=new P(o,e.viewModel.getLineMaxColumn(o));return t.fulfillContentEmpty(a,s)}}let i=t.hitTestResult.value;return i.type===1?n.createMouseTargetFromHitTestPosition(e,t,i.spanNode,i.position,i.injectedText):t.wouldBenefitFromHitTestTargetSwitch?(t.switchToHitTestTarget(),this._createMouseTarget(e,t)):t.fulfillUnknown()}static _hitTestMinimap(e,t){if(al.isChildOfMinimap(t.targetPath)){let i=e.getLineNumberAtVerticalOffset(t.mouseVerticalOffset),o=e.viewModel.getLineMaxColumn(i);return t.fulfillScrollbar(new P(i,o))}return null}static _hitTestScrollbarSlider(e,t){if(al.isChildOfScrollableElement(t.targetPath)&&t.target&&t.target.nodeType===1){let i=t.target.className;if(i&&/\b(slider|scrollbar)\b/.test(i)){let o=e.getLineNumberAtVerticalOffset(t.mouseVerticalOffset),r=e.viewModel.getLineMaxColumn(o);return t.fulfillScrollbar(new P(o,r))}}return null}static _hitTestScrollbar(e,t){if(al.isChildOfScrollableElement(t.targetPath)){let i=e.getLineNumberAtVerticalOffset(t.mouseVerticalOffset),o=e.viewModel.getLineMaxColumn(i);return t.fulfillScrollbar(new P(i,o))}return null}getMouseColumn(e){let t=this._context.configuration.options,i=t.get(146),o=this._context.viewLayout.getCurrentScrollLeft()+e.x-i.contentLeft;return n._getMouseColumn(o,t.get(50).typicalHalfwidthCharacterWidth)}static _getMouseColumn(e,t){return e<0?1:Math.round(e/t)+1}static createMouseTargetFromHitTestPosition(e,t,i,o,r){let s=o.lineNumber,a=o.column,l=e.getLineWidth(s);if(t.mouseContentHorizontalOffset>l){let b=Jue(t.mouseContentHorizontalOffset-l);return t.fulfillContentEmpty(o,b)}let c=e.visibleRangeForPosition(s,a);if(!c)return t.fulfillUnknown(o);let d=c.left;if(Math.abs(t.mouseContentHorizontalOffset-d)<1)return t.fulfillContentText(o,null,{mightBeForeignElement:!!r,injectedText:r});let u=[];if(u.push({offset:c.left,column:a}),a>1){let b=e.visibleRangeForPosition(s,a-1);b&&u.push({offset:b.left,column:a-1})}let h=e.viewModel.getLineMaxColumn(s);if(ab.offset-v.offset);let f=t.pos.toClientCoordinates(Me(e.viewDomNode)),p=i.getBoundingClientRect(),g=p.left<=f.clientX&&f.clientX<=p.right,_=null;for(let b=1;br)){let a=Math.floor((o+r)/2),l=t.pos.y+(a-t.mouseVerticalOffset);l<=t.editorPos.y&&(l=t.editorPos.y+1),l>=t.editorPos.y+t.editorPos.height&&(l=t.editorPos.y+t.editorPos.height-1);let c=new Rw(t.pos.x,l),d=this._actualDoHitTestWithCaretRangeFromPoint(e,c.toClientCoordinates(Me(e.viewDomNode)));if(d.type===1)return d}return this._actualDoHitTestWithCaretRangeFromPoint(e,t.pos.toClientCoordinates(Me(e.viewDomNode)))}static _actualDoHitTestWithCaretRangeFromPoint(e,t){let i=fp(e.viewDomNode),o;if(i?typeof i.caretRangeFromPoint>"u"?o=Tut(i,t.clientX,t.clientY):o=i.caretRangeFromPoint(t.clientX,t.clientY):o=e.viewDomNode.ownerDocument.caretRangeFromPoint(t.clientX,t.clientY),!o||!o.startContainer)return new Wg;let r=o.startContainer;if(r.nodeType===r.TEXT_NODE){let s=r.parentNode,a=s?s.parentNode:null,l=a?a.parentNode:null;return(l&&l.nodeType===l.ELEMENT_NODE?l.className:null)===Op.CLASS_NAME?a0.createFromDOMInfo(e,s,o.startOffset):new Wg(r.parentNode)}else if(r.nodeType===r.ELEMENT_NODE){let s=r.parentNode,a=s?s.parentNode:null;return(a&&a.nodeType===a.ELEMENT_NODE?a.className:null)===Op.CLASS_NAME?a0.createFromDOMInfo(e,r,r.textContent.length):new Wg(r)}return new Wg}static _doHitTestWithCaretPositionFromPoint(e,t){let i=e.viewDomNode.ownerDocument.caretPositionFromPoint(t.clientX,t.clientY);if(i.offsetNode.nodeType===i.offsetNode.TEXT_NODE){let o=i.offsetNode.parentNode,r=o?o.parentNode:null,s=r?r.parentNode:null;return(s&&s.nodeType===s.ELEMENT_NODE?s.className:null)===Op.CLASS_NAME?a0.createFromDOMInfo(e,i.offsetNode.parentNode,i.offset):new Wg(i.offsetNode.parentNode)}if(i.offsetNode.nodeType===i.offsetNode.ELEMENT_NODE){let o=i.offsetNode.parentNode,r=o&&o.nodeType===o.ELEMENT_NODE?o.className:null,s=o?o.parentNode:null,a=s&&s.nodeType===s.ELEMENT_NODE?s.className:null;if(r===Op.CLASS_NAME){let l=i.offsetNode.childNodes[Math.min(i.offset,i.offsetNode.childNodes.length-1)];if(l)return a0.createFromDOMInfo(e,l,0)}else if(a===Op.CLASS_NAME)return a0.createFromDOMInfo(e,i.offsetNode,0)}return new Wg(i.offsetNode)}static _snapToSoftTabBoundary(e,t){let i=t.getLineContent(e.lineNumber),{tabSize:o}=t.model.getOptions(),r=s0.atomicPosition(i,e.column-1,o,2);return r!==-1?new P(e.lineNumber,r+1):e}static doHitTest(e,t){let i=new Wg;if(typeof e.viewDomNode.ownerDocument.caretRangeFromPoint=="function"?i=this._doHitTestWithCaretRangeFromPoint(e,t):e.viewDomNode.ownerDocument.caretPositionFromPoint&&(i=this._doHitTestWithCaretPositionFromPoint(e,t.pos.toClientCoordinates(Me(e.viewDomNode)))),i.type===1){let o=e.viewModel.getInjectedTextAt(i.position),r=e.viewModel.normalizePosition(i.position,2);(o||!r.equals(i.position))&&(i=new LV(r,i.spanNode,o))}return i}};ihe=class n{static{this._INSTANCE=null}static getInstance(){return n._INSTANCE||(n._INSTANCE=new n),n._INSTANCE}constructor(){this._cache={},this._canvas=document.createElement("canvas")}getCharWidth(e,t){let i=e+t;if(this._cache[i])return this._cache[i];let o=this._canvas.getContext("2d");o.font=t;let s=o.measureText(e).width;return this._cache[i]=s,s}}});var EE,ohe,rhe,she,ahe,u3e=k(()=>{ke();pu();j();Bt();nhe();xE();mL();qe();Ui();wE();Eh();EE=class extends Pf{constructor(e,t,i){super(),this._mouseLeaveMonitor=null,this._context=e,this.viewController=t,this.viewHelper=i,this.mouseTargetFactory=new IE(this._context,i),this._mouseDownOperation=this._register(new ohe(this._context,this.viewController,this.viewHelper,this.mouseTargetFactory,(s,a)=>this._createMouseTarget(s,a),s=>this._getMouseColumn(s))),this.lastMouseLeaveTime=-1,this._height=this._context.configuration.options.get(146).height;let o=new mV(this.viewHelper.viewDomNode);this._register(o.onContextMenu(this.viewHelper.viewDomNode,s=>this._onContextMenu(s,!0))),this._register(o.onMouseMove(this.viewHelper.viewDomNode,s=>{this._onMouseMove(s),this._mouseLeaveMonitor||(this._mouseLeaveMonitor=U(this.viewHelper.viewDomNode.ownerDocument,"mousemove",a=>{this.viewHelper.viewDomNode.contains(a.target)||this._onMouseLeave(new Mf(a,!1,this.viewHelper.viewDomNode))}))})),this._register(o.onMouseUp(this.viewHelper.viewDomNode,s=>this._onMouseUp(s))),this._register(o.onMouseLeave(this.viewHelper.viewDomNode,s=>this._onMouseLeave(s)));let r=0;this._register(o.onPointerDown(this.viewHelper.viewDomNode,(s,a)=>{r=a})),this._register(U(this.viewHelper.viewDomNode,re.POINTER_UP,s=>{this._mouseDownOperation.onPointerUp()})),this._register(o.onMouseDown(this.viewHelper.viewDomNode,s=>this._onMouseDown(s,r))),this._setupMouseWheelZoomListener(),this._context.addEventHandler(this)}_setupMouseWheelZoomListener(){let e=aM.INSTANCE,t=0,i=El.getZoomLevel(),o=!1,r=0,s=l=>{if(this.viewController.emitMouseWheel(l),!this._context.configuration.options.get(76))return;let c=new ph(l);if(e.acceptStandardWheelEvent(c),e.isPhysicalMouseWheel()){if(a(l)){let d=El.getZoomLevel(),u=c.deltaY>0?1:-1;El.setZoomLevel(d+u),c.preventDefault(),c.stopPropagation()}}else Date.now()-t>50&&(i=El.getZoomLevel(),o=a(l),r=0),t=Date.now(),r+=c.deltaY,o&&(El.setZoomLevel(i+r/5),c.preventDefault(),c.stopPropagation())};this._register(U(this.viewHelper.viewDomNode,re.MOUSE_WHEEL,s,{capture:!0,passive:!1}));function a(l){return dt?(l.metaKey||l.ctrlKey)&&!l.shiftKey&&!l.altKey:l.ctrlKey&&!l.metaKey&&!l.shiftKey&&!l.altKey}}dispose(){this._context.removeEventHandler(this),this._mouseLeaveMonitor&&(this._mouseLeaveMonitor.dispose(),this._mouseLeaveMonitor=null),super.dispose()}onConfigurationChanged(e){if(e.hasChanged(146)){let t=this._context.configuration.options.get(146).height;this._height!==t&&(this._height=t,this._mouseDownOperation.onHeightChanged())}return!1}onCursorStateChanged(e){return this._mouseDownOperation.onCursorStateChanged(e),!1}onFocusChanged(e){return!1}getTargetAtClientPoint(e,t){let o=new tP(e,t).toPageCoordinates(Me(this.viewHelper.viewDomNode)),r=bV(this.viewHelper.viewDomNode);if(o.yr.y+r.height||o.xr.x+r.width)return null;let s=vV(this.viewHelper.viewDomNode,r,o);return this.mouseTargetFactory.createMouseTarget(this.viewHelper.getLastRenderData(),r,o,s,null)}_createMouseTarget(e,t){let i=e.target;if(!this.viewHelper.viewDomNode.contains(i)){let o=fp(this.viewHelper.viewDomNode);o&&(i=o.elementsFromPoint(e.posx,e.posy).find(r=>this.viewHelper.viewDomNode.contains(r)))}return this.mouseTargetFactory.createMouseTarget(this.viewHelper.getLastRenderData(),e.editorPos,e.pos,e.relativePos,t?i:null)}_getMouseColumn(e){return this.mouseTargetFactory.getMouseColumn(e.relativePos)}_onContextMenu(e,t){this.viewController.emitContextMenu({event:e,target:this._createMouseTarget(e,t)})}_onMouseMove(e){this.mouseTargetFactory.mouseTargetIsWidget(e)||e.preventDefault(),!(this._mouseDownOperation.isActive()||e.timestamp{e.preventDefault(),this.viewHelper.focusTextArea()};if(d&&(o||s&&a))u(),this._mouseDownOperation.start(i.type,e,t);else if(r)e.preventDefault();else if(l){let h=i.detail;d&&this.viewHelper.shouldSuppressMouseDownOnViewZone(h.viewZoneId)&&(u(),this._mouseDownOperation.start(i.type,e,t),e.preventDefault())}else c&&this.viewHelper.shouldSuppressMouseDownOnWidget(i.detail)&&(u(),e.preventDefault());this.viewController.emitMouseDown({event:e,target:i})}},ohe=class extends D{constructor(e,t,i,o,r,s){super(),this._context=e,this._viewController=t,this._viewHelper=i,this._mouseTargetFactory=o,this._createMouseTarget=r,this._getMouseColumn=s,this._mouseMoveMonitor=this._register(new _V(this._viewHelper.viewDomNode)),this._topBottomDragScrolling=this._register(new rhe(this._context,this._viewHelper,this._mouseTargetFactory,(a,l,c)=>this._dispatchMouse(a,l,c))),this._mouseState=new ahe,this._currentSelection=new Se(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);let t=this._findMousePosition(e,!1);t&&(this._mouseState.isDragAndDrop?this._viewController.emitMouseDrag({event:e,target:t}):t.type===13&&(t.outsidePosition==="above"||t.outsidePosition==="below")?this._topBottomDragScrolling.start(t,e):(this._topBottomDragScrolling.stop(),this._dispatchMouse(t,!0,1)))}start(e,t,i){this._lastMouseEvent=t,this._mouseState.setStartedOnLineNumbers(e===3),this._mouseState.setStartButtons(t),this._mouseState.setModifiers(t);let o=this._findMousePosition(t,!0);if(!o||!o.position)return;this._mouseState.trySetCount(t.detail,o.position),t.detail=this._mouseState.count;let r=this._context.configuration.options;if(!r.get(92)&&r.get(35)&&!r.get(22)&&!this._mouseState.altKey&&t.detail<2&&!this._isActive&&!this._currentSelection.isEmpty()&&o.type===6&&o.position&&this._currentSelection.containsPosition(o.position)){this._mouseState.isDragAndDrop=!0,this._isActive=!0,this._mouseMoveMonitor.startMonitoring(this._viewHelper.viewLinesDomNode,i,t.buttons,s=>this._onMouseDownThenMove(s),s=>{let a=this._findMousePosition(this._lastMouseEvent,!1);mf(s)?this._viewController.emitMouseDropCanceled():this._viewController.emitMouseDrop({event:this._lastMouseEvent,target:a?this._createMouseTarget(this._lastMouseEvent,!0):null}),this._stop()});return}this._mouseState.isDragAndDrop=!1,this._dispatchMouse(o,t.shiftKey,1),this._isActive||(this._isActive=!0,this._mouseMoveMonitor.startMonitoring(this._viewHelper.viewLinesDomNode,i,t.buttons,s=>this._onMouseDownThenMove(s),()=>this._stop()))}_stop(){this._isActive=!1,this._topBottomDragScrolling.stop()}onHeightChanged(){this._mouseMoveMonitor.stopMonitoring()}onPointerUp(){this._mouseMoveMonitor.stopMonitoring()}onCursorStateChanged(e){this._currentSelection=e.selections[0]}_getPositionOutsideEditor(e){let t=e.editorPos,i=this._context.viewModel,o=this._context.viewLayout,r=this._getMouseColumn(e);if(e.posyt.y+t.height){let a=e.posy-t.y-t.height,l=o.getCurrentScrollTop()+e.relativePos.y,c=LE.getZoneAtCoord(this._context,l);if(c){let u=this._helpPositionJumpOverViewZone(c);if(u)return oa.createOutsideEditor(r,u,"below",a)}let d=o.getLineNumberAtVerticalOffset(l);return oa.createOutsideEditor(r,new P(d,i.getLineMaxColumn(d)),"below",a)}let s=o.getLineNumberAtVerticalOffset(o.getCurrentScrollTop()+e.relativePos.y);if(e.posxt.x+t.width){let a=e.posx-t.x-t.width;return oa.createOutsideEditor(r,new P(s,i.getLineMaxColumn(s)),"right",a)}return null}_findMousePosition(e,t){let i=this._getPositionOutsideEditor(e);if(i)return i;let o=this._createMouseTarget(e,t);if(!o.position)return null;if(o.type===8||o.type===5){let s=this._helpPositionJumpOverViewZone(o.detail);if(s)return oa.createViewZone(o.type,o.element,o.mouseColumn,s,o.detail)}return o}_helpPositionJumpOverViewZone(e){let t=new P(this._currentSelection.selectionStartLineNumber,this._currentSelection.selectionStartColumn),i=e.positionBefore,o=e.positionAfter;return i&&o?i.isBefore(t)?i:o:null}_dispatchMouse(e,t,i){e.position&&this._viewController.dispatchMouse({position:e.position,mouseColumn:e.mouseColumn,startedOnLineNumbers:this._mouseState.startedOnLineNumbers,revealType:i,inSelectionMode:t,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})}},rhe=class extends D{constructor(e,t,i,o){super(),this._context=e,this._viewHelper=t,this._mouseTargetFactory=i,this._dispatchMouse=o,this._operation=null}dispose(){super.dispose(),this.stop()}start(e,t){this._operation?this._operation.setPosition(e,t):this._operation=new she(this._context,this._viewHelper,this._mouseTargetFactory,this._dispatchMouse,e,t)}stop(){this._operation&&(this._operation.dispose(),this._operation=null)}},she=class extends D{constructor(e,t,i,o,r,s){super(),this._context=e,this._viewHelper=t,this._mouseTargetFactory=i,this._dispatchMouse=o,this._position=r,this._mouseEvent=s,this._lastTime=Date.now(),this._animationFrameDisposable=us(Me(s.browserEvent),()=>this._execute())}dispose(){this._animationFrameDisposable.dispose(),super.dispose()}setPosition(e,t){this._position=e,this._mouseEvent=t}_tick(){let e=Date.now(),t=e-this._lastTime;return this._lastTime=e,t}_getScrollSpeed(){let e=this._context.configuration.options.get(67),t=this._context.configuration.options.get(146).height/e,i=this._position.outsideDistance/e;return i<=1.5?Math.max(30,t*(1+i)):i<=3?Math.max(60,t*(2+i)):Math.max(200,t*(7+i))}_execute(){let e=this._context.configuration.options.get(67),t=this._getScrollSpeed(),i=this._tick(),o=t*(i/1e3)*e,r=this._position.outsidePosition==="above"?-o:o;this._context.viewModel.viewLayout.deltaScrollNow(0,r),this._viewHelper.renderNow();let s=this._context.viewLayout.getLinesViewportData(),a=this._position.outsidePosition==="above"?s.startLineNumber:s.endLineNumber,l;{let c=bV(this._viewHelper.viewDomNode),d=this._context.configuration.options.get(146).horizontalScrollbarHeight,u=new Rw(this._mouseEvent.pos.x,c.y+c.height-d-.1),h=vV(this._viewHelper.viewDomNode,c,u);l=this._mouseTargetFactory.createMouseTarget(this._viewHelper.getLastRenderData(),c,u,h,null)}(!l.position||l.position.lineNumber!==a)&&(this._position.outsidePosition==="above"?l=oa.createOutsideEditor(this._position.mouseColumn,new P(a,1),"above",this._position.outsideDistance):l=oa.createOutsideEditor(this._position.mouseColumn,new P(a,this._context.viewModel.getLineMaxColumn(a)),"below",this._position.outsideDistance)),this._dispatchMouse(l,!0,2),this._animationFrameDisposable=us(Me(l.element),()=>this._execute())}},ahe=class n{static{this.CLEAR_MOUSE_DOWN_COUNT_TIME=400}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}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 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,t){let i=new Date().getTime();i-this._lastSetMouseDownCountTime>n.CLEAR_MOUSE_DOWN_COUNT_TIME&&(e=1),this._lastSetMouseDownCountTime=i,e>this._lastMouseDownCount+1&&(e=this._lastMouseDownCount+1),this._lastMouseDownPosition&&this._lastMouseDownPosition.equals(t)?this._lastMouseDownPositionEqualCount++:this._lastMouseDownPositionEqualCount=1,this._lastMouseDownPosition=t,this._lastMouseDownCount=Math.min(e,this._lastMouseDownPositionEqualCount)}}});var Kd,Ea,EV,lhe=k(()=>{Qe();we();Kd=!1,Ea=class n{static{this.EMPTY=new n("",0,0,null,void 0)}constructor(e,t,i,o,r){this.value=e,this.selectionStart=t,this.selectionEnd=i,this.selection=o,this.newlineCountBeforeSelection=r}toString(){return`[ <${this.value}>, selectionStart: ${this.selectionStart}, selectionEnd: ${this.selectionEnd}]`}static readFromTextArea(e,t){let i=e.getValue(),o=e.getSelectionStart(),r=e.getSelectionEnd(),s;if(t){let a=i.substring(0,o),l=t.value.substring(0,t.selectionStart);a===l&&(s=t.newlineCountBeforeSelection)}return new n(i,o,r,null,s)}collapseSelection(){return this.selectionStart===this.value.length?this:new n(this.value,this.value.length,this.value.length,null,void 0)}writeToTextArea(e,t,i){Kd&&console.log(`writeToTextArea ${e}: ${this.toString()}`),t.setValue(e,this.value),i&&t.setSelectionRange(e,this.selectionStart,this.selectionEnd)}deduceEditorPosition(e){if(e<=this.selectionStart){let o=this.value.substring(e,this.selectionStart);return this._finishDeduceEditorPosition(this.selection?.getStartPosition()??null,o,-1)}if(e>=this.selectionEnd){let o=this.value.substring(this.selectionEnd,e);return this._finishDeduceEditorPosition(this.selection?.getEndPosition()??null,o,1)}let t=this.value.substring(this.selectionStart,e);if(t.indexOf("\u2026")===-1)return this._finishDeduceEditorPosition(this.selection?.getStartPosition()??null,t,1);let i=this.value.substring(e,this.selectionEnd);return this._finishDeduceEditorPosition(this.selection?.getEndPosition()??null,i,-1)}_finishDeduceEditorPosition(e,t,i){let o=0,r=-1;for(;(r=t.indexOf(` `,r+1))!==-1;)o++;return[e,i*t.length,o]}static deduceInput(e,t,i){if(!e)return{text:"",replacePrevCharCnt:0,replaceNextCharCnt:0,positionDelta:0};Kd&&(console.log("------------------------deduceInput"),console.log(`PREVIOUS STATE: ${e.toString()}`),console.log(`CURRENT STATE: ${t.toString()}`));let o=Math.min(kd(e.value,t.value),e.selectionStart,t.selectionStart),r=Math.min(C1(e.value,t.value),e.value.length-e.selectionEnd,t.value.length-t.selectionEnd),s=e.value.substring(o,e.value.length-r),a=t.value.substring(o,t.value.length-r),l=e.selectionStart-o,c=e.selectionEnd-o,d=t.selectionStart-o,u=t.selectionEnd-o;if(Kd&&(console.log(`AFTER DIFFING PREVIOUS STATE: <${s}>, selectionStart: ${l}, selectionEnd: ${c}`),console.log(`AFTER DIFFING CURRENT STATE: <${a}>, selectionStart: ${d}, selectionEnd: ${u}`)),d===u){let f=e.selectionStart-o;return Kd&&console.log(`REMOVE PREVIOUS: ${f} chars`),{text:a,replacePrevCharCnt:f,replaceNextCharCnt:0,positionDelta:0}}let h=c-l;return{text:a,replacePrevCharCnt:h,replaceNextCharCnt:0,positionDelta:0}}static deduceAndroidCompositionInput(e,t){if(!e)return{text:"",replacePrevCharCnt:0,replaceNextCharCnt:0,positionDelta:0};if(Kd&&(console.log("------------------------deduceAndroidCompositionInput"),console.log(`PREVIOUS STATE: ${e.toString()}`),console.log(`CURRENT STATE: ${t.toString()}`)),e.value===t.value)return{text:"",replacePrevCharCnt:0,replaceNextCharCnt:0,positionDelta:t.selectionEnd-e.selectionEnd};let i=Math.min(kd(e.value,t.value),e.selectionEnd),o=Math.min(C1(e.value,t.value),e.value.length-e.selectionEnd),r=e.value.substring(i,e.value.length-o),s=t.value.substring(i,t.value.length-o),a=e.selectionStart-i,l=e.selectionEnd-i,c=t.selectionStart-i,d=t.selectionEnd-i;return Kd&&(console.log(`AFTER DIFFING PREVIOUS STATE: <${r}>, selectionStart: ${a}, selectionEnd: ${l}`),console.log(`AFTER DIFFING CURRENT STATE: <${s}>, selectionStart: ${c}, selectionEnd: ${d}`)),{text:s,replacePrevCharCnt:l,replaceNextCharCnt:r.length-l,positionDelta:d-s.length}}},EV=class n{static _getPageOfLine(e,t){return Math.floor((e-1)/t)}static _getRangeForPage(e,t){let i=e*t,o=i+1,r=i+t;return new S(o,1,r+1,1)}static fromEditorSelection(e,t,i,o){let s=n._getPageOfLine(t.startLineNumber,i),a=n._getRangeForPage(s,i),l=n._getPageOfLine(t.endLineNumber,i),c=n._getRangeForPage(l,i),d=a.intersectRanges(new S(1,1,t.startLineNumber,t.startColumn));if(o&&e.getValueLengthInRange(d,1)>500){let b=e.modifyPosition(d.getEndPosition(),-500);d=S.fromPositions(b,d.getEndPosition())}let u=e.getValueInRange(d,1),h=e.getLineCount(),f=e.getLineMaxColumn(h),p=c.intersectRanges(new S(t.endLineNumber,t.endColumn,h,f));if(o&&e.getValueLengthInRange(p,1)>500){let b=e.modifyPosition(p.getStartPosition(),500);p=S.fromPositions(p.getStartPosition(),b)}let g=e.getValueInRange(p,1),_;if(s===l||s+1===l)_=e.getValueInRange(t,1);else{let b=a.intersectRanges(t),v=c.intersectRanges(t);_=e.getValueInRange(b,1)+"\u2026"+e.getValueInRange(v,1)}return o&&_.length>2*500&&(_=_.substring(0,500)+"\u2026"+_.substring(_.length-500,_.length)),new Ea(u+_+g,u.length,u.length+_.length,t,d.endLineNumber-d.startLineNumber)}}});var Dut,h3e,oP,rP,TE,che,TV,DV,NV,sP=k(()=>{Fc();ke();Sf();Ks();que();ft();Ie();j();Ex();Qe();lhe();Ui();uc();ac();Dut=function(n,e,t,i){var o=arguments.length,r=o<3?e:i===null?i=Object.getOwnPropertyDescriptor(e,t):i,s;if(typeof Reflect=="object"&&typeof Reflect.decorate=="function")r=Reflect.decorate(n,e,t,i);else for(var a=n.length-1;a>=0;a--)(s=n[a])&&(r=(o<3?s(r):o>3?s(e,t,r):s(e,t))||r);return o>3&&r&&Object.defineProperty(e,t,r),r},h3e=function(n,e){return function(t,i){e(t,i,n)}};(function(n){n.Tap="-monaco-textarea-synthetic-tap"})(oP||(oP={}));rP={forceCopyWithSyntaxHighlighting:!1},TE=class n{static{this.INSTANCE=new n}constructor(){this._lastState=null}set(e,t){this._lastState={lastCopiedValue:e,data:t}}get(e){return this._lastState&&this._lastState.lastCopiedValue===e?this._lastState.data:(this._lastState=null,null)}},che=class{constructor(){this._lastTypeTextLength=0}handleCompositionUpdate(e){e=e||"";let t={text:e,replacePrevCharCnt:this._lastTypeTextLength,replaceNextCharCnt:0,positionDelta:0};return this._lastTypeTextLength=e.length,t}},TV=class extends D{get textAreaState(){return this._textAreaState}constructor(e,t,i,o,r,s){super(),this._host=e,this._textArea=t,this._OS=i,this._browser=o,this._accessibilityService=r,this._logService=s,this._onFocus=this._register(new A),this.onFocus=this._onFocus.event,this._onBlur=this._register(new A),this.onBlur=this._onBlur.event,this._onKeyDown=this._register(new A),this.onKeyDown=this._onKeyDown.event,this._onKeyUp=this._register(new A),this.onKeyUp=this._onKeyUp.event,this._onCut=this._register(new A),this.onCut=this._onCut.event,this._onPaste=this._register(new A),this.onPaste=this._onPaste.event,this._onType=this._register(new A),this.onType=this._onType.event,this._onCompositionStart=this._register(new A),this.onCompositionStart=this._onCompositionStart.event,this._onCompositionUpdate=this._register(new A),this.onCompositionUpdate=this._onCompositionUpdate.event,this._onCompositionEnd=this._register(new A),this.onCompositionEnd=this._onCompositionEnd.event,this._onSelectionChangeRequest=this._register(new A),this.onSelectionChangeRequest=this._onSelectionChangeRequest.event,this._asyncFocusGainWriteScreenReaderContent=this._register(new Hi),this._asyncTriggerCut=this._register(new Lt(()=>this._onCut.fire(),0)),this._textAreaState=Ea.EMPTY,this._selectionChangeListener=null,this._accessibilityService.isScreenReaderOptimized()&&this.writeNativeTextAreaContent("ctor"),this._register(ne.runAndSubscribe(this._accessibilityService.onDidChangeScreenReaderOptimized,()=>{this._accessibilityService.isScreenReaderOptimized()&&!this._asyncFocusGainWriteScreenReaderContent.value?this._asyncFocusGainWriteScreenReaderContent.value=this._register(new Lt(()=>this.writeNativeTextAreaContent("asyncFocusGain"),0)):this._asyncFocusGainWriteScreenReaderContent.clear()})),this._hasFocus=!1,this._currentComposition=null;let a=null;this._register(this._textArea.onKeyDown(l=>{let c=new Xt(l);(c.keyCode===114||this._currentComposition&&c.keyCode===1)&&c.stopPropagation(),c.equals(9)&&c.preventDefault(),a=c,this._onKeyDown.fire(c)})),this._register(this._textArea.onKeyUp(l=>{let c=new Xt(l);this._onKeyUp.fire(c)})),this._register(this._textArea.onCompositionStart(l=>{Kd&&console.log("[compositionstart]",l);let c=new che;if(this._currentComposition){this._currentComposition=c;return}if(this._currentComposition=c,this._OS===2&&a&&a.equals(114)&&this._textAreaState.selectionStart===this._textAreaState.selectionEnd&&this._textAreaState.selectionStart>0&&this._textAreaState.value.substr(this._textAreaState.selectionStart-1,1)===l.data&&(a.code==="ArrowRight"||a.code==="ArrowLeft")){Kd&&console.log("[compositionstart] Handling long press case on macOS + arrow key",l),c.handleCompositionUpdate("x"),this._onCompositionStart.fire({data:l.data});return}if(this._browser.isAndroid){this._onCompositionStart.fire({data:l.data});return}this._onCompositionStart.fire({data:l.data})})),this._register(this._textArea.onCompositionUpdate(l=>{Kd&&console.log("[compositionupdate]",l);let c=this._currentComposition;if(!c)return;if(this._browser.isAndroid){let u=Ea.readFromTextArea(this._textArea,this._textAreaState),h=Ea.deduceAndroidCompositionInput(this._textAreaState,u);this._textAreaState=u,this._onType.fire(h),this._onCompositionUpdate.fire(l);return}let d=c.handleCompositionUpdate(l.data);this._textAreaState=Ea.readFromTextArea(this._textArea,this._textAreaState),this._onType.fire(d),this._onCompositionUpdate.fire(l)})),this._register(this._textArea.onCompositionEnd(l=>{Kd&&console.log("[compositionend]",l);let c=this._currentComposition;if(!c)return;if(this._currentComposition=null,this._browser.isAndroid){let u=Ea.readFromTextArea(this._textArea,this._textAreaState),h=Ea.deduceAndroidCompositionInput(this._textAreaState,u);this._textAreaState=u,this._onType.fire(h),this._onCompositionEnd.fire();return}let d=c.handleCompositionUpdate(l.data);this._textAreaState=Ea.readFromTextArea(this._textArea,this._textAreaState),this._onType.fire(d),this._onCompositionEnd.fire()})),this._register(this._textArea.onInput(l=>{if(Kd&&console.log("[input]",l),this._textArea.setIgnoreSelectionChangeTime("received input event"),this._currentComposition)return;let c=Ea.readFromTextArea(this._textArea,this._textAreaState),d=Ea.deduceInput(this._textAreaState,c,this._OS===2);d.replacePrevCharCnt===0&&d.text.length===1&&(to(d.text.charCodeAt(0))||d.text.charCodeAt(0)===127)||(this._textAreaState=c,(d.text!==""||d.replacePrevCharCnt!==0||d.replaceNextCharCnt!==0||d.positionDelta!==0)&&this._onType.fire(d))})),this._register(this._textArea.onCut(l=>{this._textArea.setIgnoreSelectionChangeTime("received cut event"),this._ensureClipboardGetsEditorSelection(l),this._asyncTriggerCut.schedule()})),this._register(this._textArea.onCopy(l=>{this._ensureClipboardGetsEditorSelection(l)})),this._register(this._textArea.onPaste(l=>{if(this._textArea.setIgnoreSelectionChangeTime("received paste event"),l.preventDefault(),!l.clipboardData)return;let[c,d]=DV.getTextData(l.clipboardData);c&&(d=d||TE.INSTANCE.get(c),this._onPaste.fire({text:c,metadata:d}))})),this._register(this._textArea.onFocus(()=>{let l=this._hasFocus;this._setHasFocus(!0),this._accessibilityService.isScreenReaderOptimized()&&this._browser.isSafari&&!l&&this._hasFocus&&(this._asyncFocusGainWriteScreenReaderContent.value||(this._asyncFocusGainWriteScreenReaderContent.value=new Lt(()=>this.writeNativeTextAreaContent("asyncFocusGain"),0)),this._asyncFocusGainWriteScreenReaderContent.value.schedule())})),this._register(this._textArea.onBlur(()=>{this._currentComposition&&(this._currentComposition=null,this.writeNativeTextAreaContent("blurWithoutCompositionEnd"),this._onCompositionEnd.fire()),this._setHasFocus(!1)})),this._register(this._textArea.onSyntheticTap(()=>{this._browser.isAndroid&&this._currentComposition&&(this._currentComposition=null,this.writeNativeTextAreaContent("tapWithoutCompositionEnd"),this._onCompositionEnd.fire())}))}_installSelectionChangeListener(){let e=0;return U(this._textArea.ownerDocument,"selectionchange",t=>{if(Bg.onSelectionChange(),!this._hasFocus||this._currentComposition||!this._browser.isChrome)return;let i=Date.now(),o=i-e;if(e=i,o<5)return;let r=i-this._textArea.getIgnoreSelectionChangeTime();if(this._textArea.resetSelectionChangeTime(),r<100||!this._textAreaState.selection)return;let s=this._textArea.getValue();if(this._textAreaState.value!==s)return;let a=this._textArea.getSelectionStart(),l=this._textArea.getSelectionEnd();if(this._textAreaState.selectionStart===a&&this._textAreaState.selectionEnd===l)return;let c=this._textAreaState.deduceEditorPosition(a),d=this._host.deduceModelPosition(c[0],c[1],c[2]),u=this._textAreaState.deduceEditorPosition(l),h=this._host.deduceModelPosition(u[0],u[1],u[2]),f=new Se(d.lineNumber,d.column,h.lineNumber,h.column);this._onSelectionChangeRequest.fire(f)})}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(e){this._hasFocus!==e&&(this._hasFocus=e,this._selectionChangeListener&&(this._selectionChangeListener.dispose(),this._selectionChangeListener=null),this._hasFocus&&(this._selectionChangeListener=this._installSelectionChangeListener()),this._hasFocus&&this.writeNativeTextAreaContent("focusgain"),this._hasFocus?this._onFocus.fire():this._onBlur.fire())}_setAndWriteTextAreaState(e,t){this._hasFocus||(t=t.collapseSelection()),t.writeToTextArea(e,this._textArea,this._hasFocus),this._textAreaState=t}writeNativeTextAreaContent(e){!this._accessibilityService.isScreenReaderOptimized()&&e==="render"||this._currentComposition||(this._logService.trace(`writeTextAreaState(reason: ${e})`),this._setAndWriteTextAreaState(e,this._host.getScreenReaderContent()))}_ensureClipboardGetsEditorSelection(e){let t=this._host.getDataToCopy(),i={version:1,isFromEmptySelection:t.isFromEmptySelection,multicursorText:t.multicursorText,mode:t.mode};TE.INSTANCE.set(this._browser.isFirefox?t.text.replace(/\r\n/g,` `):t.text,i),e.preventDefault(),e.clipboardData&&DV.setTextData(e.clipboardData,t.text,t.html,i)}};TV=Dut([h3e(4,$o),h3e(5,Bn)],TV);DV={getTextData(n){let e=n.getData(An.text),t=null,i=n.getData("vscode-editor-data");if(typeof i=="string")try{t=JSON.parse(i),t.version!==1&&(t=null)}catch{}return e.length===0&&t===null&&n.files.length>0?[Array.prototype.slice.call(n.files,0).map(r=>r.name).join(` `),null]:[e,t]},setTextData(n,e,t,i){n.setData(An.text,e),typeof t=="string"&&n.setData("text/html",t),n.setData("vscode-editor-data",JSON.stringify(i))}},NV=class extends D{get ownerDocument(){return this._actual.ownerDocument}constructor(e){super(),this._actual=e,this.onKeyDown=this._register(new Mt(this._actual,"keydown")).event,this.onKeyUp=this._register(new Mt(this._actual,"keyup")).event,this.onCompositionStart=this._register(new Mt(this._actual,"compositionstart")).event,this.onCompositionUpdate=this._register(new Mt(this._actual,"compositionupdate")).event,this.onCompositionEnd=this._register(new Mt(this._actual,"compositionend")).event,this.onBeforeInput=this._register(new Mt(this._actual,"beforeinput")).event,this.onInput=this._register(new Mt(this._actual,"input")).event,this.onCut=this._register(new Mt(this._actual,"cut")).event,this.onCopy=this._register(new Mt(this._actual,"copy")).event,this.onPaste=this._register(new Mt(this._actual,"paste")).event,this.onFocus=this._register(new Mt(this._actual,"focus")).event,this.onBlur=this._register(new Mt(this._actual,"blur")).event,this._onSyntheticTap=this._register(new A),this.onSyntheticTap=this._onSyntheticTap.event,this._ignoreSelectionChangeTime=0,this._register(this.onKeyDown(()=>Bg.onKeyDown())),this._register(this.onBeforeInput(()=>Bg.onBeforeInput())),this._register(this.onInput(()=>Bg.onInput())),this._register(this.onKeyUp(()=>Bg.onKeyUp())),this._register(U(this._actual,oP.Tap,()=>this._onSyntheticTap.fire()))}hasFocus(){let e=fp(this._actual);return e?e.activeElement===this._actual:this._actual.isConnected?Mo()===this._actual:!1}setIgnoreSelectionChangeTime(e){this._ignoreSelectionChangeTime=Date.now()}getIgnoreSelectionChangeTime(){return this._ignoreSelectionChangeTime}resetSelectionChangeTime(){this._ignoreSelectionChangeTime=0}getValue(){return this._actual.value}setValue(e,t){let i=this._actual;i.value!==t&&(this.setIgnoreSelectionChangeTime("setValue"),i.value=t)}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(e,t,i){let o=this._actual,r=null,s=fp(o);s?r=s.activeElement:r=Mo();let a=Me(r),l=r===o,c=o.selectionStart,d=o.selectionEnd;if(l&&c===t&&d===i){ls&&a.parent!==a&&o.focus();return}if(l){this.setIgnoreSelectionChangeTime("setSelectionRange"),o.setSelectionRange(t,i),ls&&a.parent!==a&&o.focus();return}try{let u=CDe(o);this.setIgnoreSelectionChangeTime("setSelectionRange"),o.focus(),o.setSelectionRange(t,i),SDe(o,u)}catch{}}}});var dhe,uhe,RV,f3e=k(()=>{hB();ke();Pd();Il();j();Bt();u3e();sP();xE();dhe=class extends EE{constructor(e,t,i){super(e,t,i),this._register(so.addTarget(this.viewHelper.linesContentDomNode)),this._register(U(this.viewHelper.linesContentDomNode,Mi.Tap,r=>this.onTap(r))),this._register(U(this.viewHelper.linesContentDomNode,Mi.Change,r=>this.onChange(r))),this._register(U(this.viewHelper.linesContentDomNode,Mi.Contextmenu,r=>this._onContextMenu(new Mf(r,!1,this.viewHelper.viewDomNode),!1))),this._lastPointerType="mouse",this._register(U(this.viewHelper.linesContentDomNode,"pointerdown",r=>{let s=r.pointerType;if(s==="mouse"){this._lastPointerType="mouse";return}else s==="touch"?this._lastPointerType="touch":this._lastPointerType="pen"}));let o=new gV(this.viewHelper.viewDomNode);this._register(o.onPointerMove(this.viewHelper.viewDomNode,r=>this._onMouseMove(r))),this._register(o.onPointerUp(this.viewHelper.viewDomNode,r=>this._onMouseUp(r))),this._register(o.onPointerLeave(this.viewHelper.viewDomNode,r=>this._onMouseLeave(r))),this._register(o.onPointerDown(this.viewHelper.viewDomNode,(r,s)=>this._onMouseDown(r,s)))}onTap(e){!e.initialTarget||!this.viewHelper.linesContentDomNode.contains(e.initialTarget)||(e.preventDefault(),this.viewHelper.focusTextArea(),this._dispatchGesture(e,!1))}onChange(e){this._lastPointerType==="touch"&&this._context.viewModel.viewLayout.deltaScrollNow(-e.translationX,-e.translationY),this._lastPointerType==="pen"&&this._dispatchGesture(e,!0)}_dispatchGesture(e,t){let i=this._createMouseTarget(new Mf(e,!1,this.viewHelper.viewDomNode),!1);i.position&&this.viewController.dispatchMouse({position:i.position,mouseColumn:i.position.column,startedOnLineNumbers:!1,revealType:1,mouseDownCount:e.tapCount,inSelectionMode:t,altKey:!1,ctrlKey:!1,metaKey:!1,shiftKey:!1,leftButton:!1,middleButton:!1,onInjectedText:i.type===6&&i.detail.injectedText!==null})}_onMouseDown(e,t){e.browserEvent.pointerType!=="touch"&&super._onMouseDown(e,t)}},uhe=class extends EE{constructor(e,t,i){super(e,t,i),this._register(so.addTarget(this.viewHelper.linesContentDomNode)),this._register(U(this.viewHelper.linesContentDomNode,Mi.Tap,o=>this.onTap(o))),this._register(U(this.viewHelper.linesContentDomNode,Mi.Change,o=>this.onChange(o))),this._register(U(this.viewHelper.linesContentDomNode,Mi.Contextmenu,o=>this._onContextMenu(new Mf(o,!1,this.viewHelper.viewDomNode),!1)))}onTap(e){e.preventDefault(),this.viewHelper.focusTextArea();let t=this._createMouseTarget(new Mf(e,!1,this.viewHelper.viewDomNode),!1);if(t.position){let i=document.createEvent("CustomEvent");i.initEvent(oP.Tap,!1,!0),this.viewHelper.dispatchTextAreaEvent(i),this.viewController.moveTo(t.position,1)}}onChange(e){this._context.viewModel.viewLayout.deltaScrollNow(-e.translationX,-e.translationY)}},RV=class extends D{constructor(e,t,i){super(),(Xa||oTe&&O3)&&sL.pointerEvents?this.handler=this._register(new dhe(e,t,i)):ri.TouchEvent?this.handler=this._register(new uhe(e,t,i)):this.handler=this._register(new EE(e,t,i))}getTargetAtClientPoint(e,t){return this.handler.getTargetAtClientPoint(e,t)}}});var p3e=k(()=>{});var m3e=k(()=>{});var nd,Aw=k(()=>{wE();nd=class extends Pf{}});var DE,hhe=k(()=>{m3e();Bt();Aw();qe();we();Yi();Nu();DE=class n extends nd{static{this.CLASS_NAME="line-numbers"}constructor(e){super(),this._context=e,this._readConfig(),this._lastCursorModelPosition=new P(1,1),this._renderResult=null,this._activeLineNumber=1,this._context.addEventHandler(this)}_readConfig(){let e=this._context.configuration.options;this._lineHeight=e.get(67);let t=e.get(68);this._renderLineNumbers=t.renderType,this._renderCustomLineNumbers=t.renderFn,this._renderFinalNewline=e.get(96);let i=e.get(146);this._lineNumbersLeft=i.lineNumbersLeft,this._lineNumbersWidth=i.lineNumbersWidth}dispose(){this._context.removeEventHandler(this),this._renderResult=null,super.dispose()}onConfigurationChanged(e){return this._readConfig(),!0}onCursorStateChanged(e){let t=e.selections[0].getPosition();this._lastCursorModelPosition=this._context.viewModel.coordinatesConverter.convertViewPositionToModelPosition(t);let i=!1;return this._activeLineNumber!==t.lineNumber&&(this._activeLineNumber=t.lineNumber,i=!0),(this._renderLineNumbers===2||this._renderLineNumbers===3)&&(i=!0),i}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}onDecorationsChanged(e){return e.affectsLineNumber}_getLineRenderLineNumber(e){let t=this._context.viewModel.coordinatesConverter.convertViewPositionToModelPosition(new P(e,1));if(t.column!==1)return"";let i=t.lineNumber;if(this._renderCustomLineNumbers)return this._renderCustomLineNumbers(i);if(this._renderLineNumbers===2){let o=Math.abs(this._lastCursorModelPosition.lineNumber-i);return o===0?''+i+"":String(o)}if(this._renderLineNumbers===3){if(this._lastCursorModelPosition.lineNumber===i||i%10===0)return String(i);let o=this._context.viewModel.getLineCount();return i===o?String(i):""}return String(i)}prepareRender(e){if(this._renderLineNumbers===0){this._renderResult=null;return}let t=Qn?this._lineHeight%2===0?" lh-even":" lh-odd":"",i=e.visibleRange.startLineNumber,o=e.visibleRange.endLineNumber,r=this._context.viewModel.getDecorationsInViewport(e.visibleRange).filter(c=>!!c.options.lineNumberClassName);r.sort((c,d)=>S.compareRangesUsingEnds(c.range,d.range));let s=0,a=this._context.viewModel.getLineCount(),l=[];for(let c=i;c<=o;c++){let d=c-i,u=this._getLineRenderLineNumber(c),h="";for(;s${u}`}this._renderResult=l}render(e,t){if(!this._renderResult)return"";let i=t-e;return i<0||i>=this._renderResult.length?"":this._renderResult[i]}};wr((n,e)=>{let t=n.getColor(LOe),i=n.getColor(FOe);i?e.addRule(`.monaco-editor .line-numbers.dimmed-line-number { color: ${i}; }`):t&&e.addRule(`.monaco-editor .line-numbers.dimmed-line-number { color: ${t.transparent(.4)}; }`)})});var g3e=k(()=>{});var NE,fhe=k(()=>{g3e();Kr();Wl();NE=class n extends wo{static{this.CLASS_NAME="glyph-margin"}static{this.OUTER_CLASS_NAME="margin"}constructor(e){super(e);let t=this._context.configuration.options,i=t.get(146);this._canUseLayerHinting=!t.get(32),this._contentLeft=i.contentLeft,this._glyphMarginLeft=i.glyphMarginLeft,this._glyphMarginWidth=i.glyphMarginWidth,this._domNode=Pt(document.createElement("div")),this._domNode.setClassName(n.OUTER_CLASS_NAME),this._domNode.setPosition("absolute"),this._domNode.setAttribute("role","presentation"),this._domNode.setAttribute("aria-hidden","true"),this._glyphMarginBackgroundDomNode=Pt(document.createElement("div")),this._glyphMarginBackgroundDomNode.setClassName(n.CLASS_NAME),this._domNode.appendChild(this._glyphMarginBackgroundDomNode)}dispose(){super.dispose()}getDomNode(){return this._domNode}onConfigurationChanged(e){let t=this._context.configuration.options,i=t.get(146);return this._canUseLayerHinting=!t.get(32),this._contentLeft=i.contentLeft,this._glyphMarginLeft=i.glyphMarginLeft,this._glyphMarginWidth=i.glyphMarginWidth,!0}onScrollChanged(e){return super.onScrollChanged(e)||e.scrollTopChanged}prepareRender(e){}render(e){this._domNode.setLayerHinting(this._canUseLayerHinting),this._domNode.setContain("strict");let t=e.scrollTop-e.bigNumbersDelta;this._domNode.setTop(-t);let i=Math.min(e.scrollHeight,1e6);this._domNode.setHeight(i),this._domNode.setWidth(this._contentLeft),this._glyphMarginBackgroundDomNode.setLeft(this._glyphMarginLeft),this._glyphMarginBackgroundDomNode.setWidth(this._glyphMarginWidth),this._glyphMarginBackgroundDomNode.setHeight(i)}}});var _3e=k(()=>{});var Wb,AV=k(()=>{_3e();Wb="monaco-mouse-cursor-text"});function Rut(n,e,t,i){if(e.length===0)return 0;let o=n.createElement("div");o.style.position="absolute",o.style.top="-50000px",o.style.width="50000px";let r=n.createElement("span");Kn(r,t),r.style.whiteSpace="pre",r.style.tabSize=`${i*t.spaceWidth}px`,r.append(e),o.appendChild(r),n.body.appendChild(o);let s=r.offsetWidth;return o.remove(),s}var Nut,b3e,mhe,phe,MV,v3e=k(()=>{p3e();pe();Fc();Kr();Bt();Qe();bu();sP();lhe();Wl();hhe();fhe();ir();SL();qe();we();Ui();AV();Ji();vo();xae();Pn();Fe();Nut=function(n,e,t,i){var o=arguments.length,r=o<3?e:i===null?i=Object.getOwnPropertyDescriptor(e,t):i,s;if(typeof Reflect=="object"&&typeof Reflect.decorate=="function")r=Reflect.decorate(n,e,t,i);else for(var a=n.length-1;a>=0;a--)(s=n[a])&&(r=(o<3?s(r):o>3?s(e,t,r):s(e,t))||r);return o>3&&r&&Object.defineProperty(e,t,r),r},b3e=function(n,e){return function(t,i){e(t,i,n)}},mhe=class{constructor(e,t,i,o,r){this._context=e,this.modelLineNumber=t,this.distanceToModelLineStart=i,this.widthOfHiddenLineTextBefore=o,this.distanceToModelLineEnd=r,this._visibleTextAreaBrand=void 0,this.startPosition=null,this.endPosition=null,this.visibleTextareaStart=null,this.visibleTextareaEnd=null,this._previousPresentation=null}prepareRender(e){let t=new P(this.modelLineNumber,this.distanceToModelLineStart+1),i=new P(this.modelLineNumber,this._context.viewModel.model.getLineMaxColumn(this.modelLineNumber)-this.distanceToModelLineEnd);this.startPosition=this._context.viewModel.coordinatesConverter.convertModelPositionToViewPosition(t),this.endPosition=this._context.viewModel.coordinatesConverter.convertModelPositionToViewPosition(i),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}},phe=ls,MV=class extends wo{constructor(e,t,i,o,r){super(e),this._keybindingService=o,this._instantiationService=r,this._primaryCursorPosition=new P(1,1),this._primaryCursorVisibleRange=null,this._viewController=t,this._visibleRangeProvider=i,this._scrollLeft=0,this._scrollTop=0;let s=this._context.configuration.options,a=s.get(146);this._setAccessibilityOptions(s),this._contentLeft=a.contentLeft,this._contentWidth=a.contentWidth,this._contentHeight=a.height,this._fontInfo=s.get(50),this._lineHeight=s.get(67),this._emptySelectionClipboard=s.get(37),this._copyWithSyntaxHighlighting=s.get(25),this._visibleTextArea=null,this._selections=[new Se(1,1,1,1)],this._modelSelections=[new Se(1,1,1,1)],this._lastRenderPosition=null,this.textArea=Pt(document.createElement("textarea")),na.write(this.textArea,7),this.textArea.setClassName(`inputarea ${Wb}`),this.textArea.setAttribute("wrap",this._textAreaWrapping&&!this._visibleTextArea?"on":"off");let{tabSize:l}=this._context.viewModel.model.getOptions();this.textArea.domNode.style.tabSize=`${l*this._fontInfo.spaceWidth}px`,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(s)),this.textArea.setAttribute("aria-required",s.get(5)?"true":"false"),this.textArea.setAttribute("tabindex",String(s.get(125))),this.textArea.setAttribute("role","textbox"),this.textArea.setAttribute("aria-roledescription",m("editor","editor")),this.textArea.setAttribute("aria-multiline","true"),this.textArea.setAttribute("aria-autocomplete",s.get(92)?"none":"both"),this._ensureReadOnlyAttribute(),this.textAreaCover=Pt(document.createElement("div")),this.textAreaCover.setPosition("absolute");let c={getLineCount:()=>this._context.viewModel.getLineCount(),getLineMaxColumn:h=>this._context.viewModel.getLineMaxColumn(h),getValueInRange:(h,f)=>this._context.viewModel.getValueInRange(h,f),getValueLengthInRange:(h,f)=>this._context.viewModel.getValueLengthInRange(h,f),modifyPosition:(h,f)=>this._context.viewModel.modifyPosition(h,f)},d={getDataToCopy:()=>{let h=this._context.viewModel.getPlainTextToCopy(this._modelSelections,this._emptySelectionClipboard,kn),f=this._context.viewModel.model.getEOL(),p=this._emptySelectionClipboard&&this._modelSelections.length===1&&this._modelSelections[0].isEmpty(),g=Array.isArray(h)?h:null,_=Array.isArray(h)?h.join(f):h,b,v=null;if(rP.forceCopyWithSyntaxHighlighting||this._copyWithSyntaxHighlighting&&_.length<65536){let x=this._context.viewModel.getRichTextToCopy(this._modelSelections,this._emptySelectionClipboard);x&&(b=x.html,v=x.mode)}return{isFromEmptySelection:p,multicursorText:g,text:_,html:b,mode:v}},getScreenReaderContent:()=>{if(this._accessibilitySupport===1){let h=this._selections[0];if(dt&&h.isEmpty()){let p=h.getStartPosition(),g=this._getWordBeforePosition(p);if(g.length===0&&(g=this._getCharacterBeforePosition(p)),g.length>0)return new Ea(g,g.length,g.length,S.fromPositions(p),0)}if(dt&&!h.isEmpty()&&c.getValueLengthInRange(h,0)<500){let p=c.getValueInRange(h,0);return new Ea(p,0,p.length,h,0)}if(Ld&&!h.isEmpty()){let p="vscode-placeholder";return new Ea(p,0,p.length,null,void 0)}return Ea.EMPTY}if(One){let h=this._selections[0];if(h.isEmpty()){let f=h.getStartPosition(),[p,g]=this._getAndroidWordAtPosition(f);if(p.length>0)return new Ea(p,g,g,S.fromPositions(f),0)}return Ea.EMPTY}return EV.fromEditorSelection(c,this._selections[0],this._accessibilityPageSize,this._accessibilitySupport===0)},deduceModelPosition:(h,f,p)=>this._context.viewModel.deduceModelPositionRelativeToViewPosition(h,f,p)},u=this._register(new NV(this.textArea.domNode));this._textAreaInput=this._register(this._instantiationService.createInstance(TV,d,u,Ur,{isAndroid:One,isChrome:bx,isFirefox:ls,isSafari:Ld})),this._register(this._textAreaInput.onKeyDown(h=>{this._viewController.emitKeyDown(h)})),this._register(this._textAreaInput.onKeyUp(h=>{this._viewController.emitKeyUp(h)})),this._register(this._textAreaInput.onPaste(h=>{let f=!1,p=null,g=null;h.metadata&&(f=this._emptySelectionClipboard&&!!h.metadata.isFromEmptySelection,p=typeof h.metadata.multicursorText<"u"?h.metadata.multicursorText:null,g=h.metadata.mode),this._viewController.paste(h.text,f,p,g)})),this._register(this._textAreaInput.onCut(()=>{this._viewController.cut()})),this._register(this._textAreaInput.onType(h=>{h.replacePrevCharCnt||h.replaceNextCharCnt||h.positionDelta?(Kd&&console.log(` => compositionType: <<${h.text}>>, ${h.replacePrevCharCnt}, ${h.replaceNextCharCnt}, ${h.positionDelta}`),this._viewController.compositionType(h.text,h.replacePrevCharCnt,h.replaceNextCharCnt,h.positionDelta)):(Kd&&console.log(` => type: <<${h.text}>>`),this._viewController.type(h.text))})),this._register(this._textAreaInput.onSelectionChangeRequest(h=>{this._viewController.setSelection(h)})),this._register(this._textAreaInput.onCompositionStart(h=>{let f=this.textArea.domNode,p=this._modelSelections[0],{distanceToModelLineStart:g,widthOfHiddenTextBefore:_}=(()=>{let v=f.value.substring(0,Math.min(f.selectionStart,f.selectionEnd)),x=v.lastIndexOf(` `),w=v.substring(x+1),y=w.lastIndexOf(" "),C=w.length-y-1,L=p.getStartPosition(),E=Math.min(L.column-1,C),N=L.column-1-E,M=w.substring(0,w.length-E),{tabSize:F}=this._context.viewModel.model.getOptions(),q=Rut(this.textArea.domNode.ownerDocument,M,this._fontInfo,F);return{distanceToModelLineStart:N,widthOfHiddenTextBefore:q}})(),{distanceToModelLineEnd:b}=(()=>{let v=f.value.substring(Math.max(f.selectionStart,f.selectionEnd)),x=v.indexOf(` `),w=x===-1?v:v.substring(0,x),y=w.indexOf(" "),C=y===-1?w.length:w.length-y-1,L=p.getEndPosition(),E=Math.min(this._context.viewModel.model.getLineMaxColumn(L.lineNumber)-L.column,C);return{distanceToModelLineEnd:this._context.viewModel.model.getLineMaxColumn(L.lineNumber)-L.column-E}})();this._context.viewModel.revealRange("keyboard",!0,S.fromPositions(this._selections[0].getStartPosition()),0,1),this._visibleTextArea=new mhe(this._context,p.startLineNumber,g,_,b),this.textArea.setAttribute("wrap",this._textAreaWrapping&&!this._visibleTextArea?"on":"off"),this._visibleTextArea.prepareRender(this._visibleRangeProvider),this._render(),this.textArea.setClassName(`inputarea ${Wb} ime-input`),this._viewController.compositionStart(),this._context.viewModel.onCompositionStart()})),this._register(this._textAreaInput.onCompositionUpdate(h=>{this._visibleTextArea&&(this._visibleTextArea.prepareRender(this._visibleRangeProvider),this._render())})),this._register(this._textAreaInput.onCompositionEnd(()=>{this._visibleTextArea=null,this.textArea.setAttribute("wrap",this._textAreaWrapping&&!this._visibleTextArea?"on":"off"),this._render(),this.textArea.setClassName(`inputarea ${Wb}`),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)})),this._register(xC.onDidChange(()=>{this._ensureReadOnlyAttribute()}))}writeScreenReaderContent(e){this._textAreaInput.writeNativeTextAreaContent(e)}dispose(){super.dispose()}_getAndroidWordAtPosition(e){let t='`~!@#$%^&*()-=+[{]}\\|;:",.<>/?',i=this._context.viewModel.getLineContent(e.lineNumber),o=Dl(t,[]),r=!0,s=e.column,a=!0,l=e.column,c=0;for(;c<50&&(r||a);){if(r&&s<=1&&(r=!1),r){let d=i.charCodeAt(s-2);o.get(d)!==0?r=!1:s--}if(a&&l>i.length&&(a=!1),a){let d=i.charCodeAt(l-1);o.get(d)!==0?a=!1:l++}c++}return[i.substring(s-1,l-1),e.column-s]}_getWordBeforePosition(e){let t=this._context.viewModel.getLineContent(e.lineNumber),i=Dl(this._context.configuration.options.get(132),[]),o=e.column,r=0;for(;o>1;){let s=t.charCodeAt(o-2);if(i.get(s)!==0||r>50)return t.substring(o-1,e.column-1);r++,o--}return t.substring(0,e.column-1)}_getCharacterBeforePosition(e){if(e.column>1){let i=this._context.viewModel.getLineContent(e.lineNumber).charAt(e.column-2);if(!to(i.charCodeAt(0)))return i}return""}_getAriaLabel(e){if(e.get(2)===1){let i=this._keybindingService.lookupKeybinding("editor.action.toggleScreenReaderAccessibilityMode")?.getAriaLabel(),o=this._keybindingService.lookupKeybinding("workbench.action.showCommands")?.getAriaLabel(),r=this._keybindingService.lookupKeybinding("workbench.action.openGlobalKeybindings")?.getAriaLabel(),s=m("accessibilityModeOff","The editor is not accessible at this time.");return i?m("accessibilityOffAriaLabel","{0} To enable screen reader optimized mode, use {1}",s,i):o?m("accessibilityOffAriaLabelNoKb","{0} To enable screen reader optimized mode, open the quick pick with {1} and run the command Toggle Screen Reader Accessibility Mode, which is currently not triggerable via keyboard.",s,o):r?m("accessibilityOffAriaLabelNoKbs","{0} Please assign a keybinding for the command Toggle Screen Reader Accessibility Mode by accessing the keybindings editor with {1} and run it.",s,r):s}return e.get(4)}_setAccessibilityOptions(e){this._accessibilitySupport=e.get(2);let t=e.get(3);this._accessibilitySupport===2&&t===Oc.accessibilityPageSize.defaultValue?this._accessibilityPageSize=500:this._accessibilityPageSize=t;let o=e.get(146).wrappingColumn;if(o!==-1&&this._accessibilitySupport!==1){let r=e.get(50);this._textAreaWrapping=!0,this._textAreaWidth=Math.round(o*r.typicalHalfwidthCharacterWidth)}else this._textAreaWrapping=!1,this._textAreaWidth=phe?0:1}onConfigurationChanged(e){let t=this._context.configuration.options,i=t.get(146);this._setAccessibilityOptions(t),this._contentLeft=i.contentLeft,this._contentWidth=i.contentWidth,this._contentHeight=i.height,this._fontInfo=t.get(50),this._lineHeight=t.get(67),this._emptySelectionClipboard=t.get(37),this._copyWithSyntaxHighlighting=t.get(25),this.textArea.setAttribute("wrap",this._textAreaWrapping&&!this._visibleTextArea?"on":"off");let{tabSize:o}=this._context.viewModel.model.getOptions();return this.textArea.domNode.style.tabSize=`${o*this._fontInfo.spaceWidth}px`,this.textArea.setAttribute("aria-label",this._getAriaLabel(t)),this.textArea.setAttribute("aria-required",t.get(5)?"true":"false"),this.textArea.setAttribute("tabindex",String(t.get(125))),(e.hasChanged(34)||e.hasChanged(92))&&this._ensureReadOnlyAttribute(),e.hasChanged(2)&&this._textAreaInput.writeNativeTextAreaContent("strategy changed"),!0}onCursorStateChanged(e){return this._selections=e.selections.slice(0),this._modelSelections=e.modelSelections.slice(0),this._textAreaInput.writeNativeTextAreaContent("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)}_ensureReadOnlyAttribute(){let e=this._context.configuration.options;!xC.enabled||e.get(34)&&e.get(92)?this.textArea.setAttribute("readonly","true"):this.textArea.removeAttribute("readonly")}prepareRender(e){this._primaryCursorPosition=new P(this._selections[0].positionLineNumber,this._selections[0].positionColumn),this._primaryCursorVisibleRange=e.visibleRangeForPosition(this._primaryCursorPosition),this._visibleTextArea?.prepareRender(e)}render(e){this._textAreaInput.writeNativeTextAreaContent("render"),this._render()}_render(){if(this._visibleTextArea){let i=this._visibleTextArea.visibleTextareaStart,o=this._visibleTextArea.visibleTextareaEnd,r=this._visibleTextArea.startPosition,s=this._visibleTextArea.endPosition;if(r&&s&&i&&o&&o.left>=this._scrollLeft&&i.left<=this._scrollLeft+this._contentWidth){let a=this._context.viewLayout.getVerticalOffsetForLineNumber(this._primaryCursorPosition.lineNumber)-this._scrollTop,l=this._newlinecount(this.textArea.domNode.value.substr(0,this.textArea.domNode.selectionStart)),c=this._visibleTextArea.widthOfHiddenLineTextBefore,d=this._contentLeft+i.left-this._scrollLeft,u=o.left-i.left+1;if(dthis._contentWidth&&(u=this._contentWidth);let h=this._context.viewModel.getViewLineData(r.lineNumber),f=h.tokens.findTokenIndexAtOffset(r.column-1),p=h.tokens.findTokenIndexAtOffset(s.column-1),g=f===p,_=this._visibleTextArea.definePresentation(g?h.tokens.getPresentation(f):null);this.textArea.domNode.scrollTop=l*this._lineHeight,this.textArea.domNode.scrollLeft=c,this._doRender({lastRenderPosition:null,top:a,left:d,width:u,height:this._lineHeight,useCover:!1,color:($i.getColorMap()||[])[_.foreground],italic:_.italic,bold:_.bold,underline:_.underline,strikethrough:_.strikethrough})}return}if(!this._primaryCursorVisibleRange){this._renderAtTopLeft();return}let e=this._contentLeft+this._primaryCursorVisibleRange.left-this._scrollLeft;if(ethis._contentLeft+this._contentWidth){this._renderAtTopLeft();return}let t=this._context.viewLayout.getVerticalOffsetForLineNumber(this._selections[0].positionLineNumber)-this._scrollTop;if(t<0||t>this._contentHeight){this._renderAtTopLeft();return}if(dt||this._accessibilitySupport===2){this._doRender({lastRenderPosition:this._primaryCursorPosition,top:t,left:this._textAreaWrapping?this._contentLeft:e,width:this._textAreaWidth,height:this._lineHeight,useCover:!1}),this.textArea.domNode.scrollLeft=this._primaryCursorVisibleRange.left;let i=this._textAreaInput.textAreaState.newlineCountBeforeSelection??this._newlinecount(this.textArea.domNode.value.substr(0,this.textArea.domNode.selectionStart));this.textArea.domNode.scrollTop=i*this._lineHeight;return}this._doRender({lastRenderPosition:this._primaryCursorPosition,top:t,left:this._textAreaWrapping?this._contentLeft:e,width:this._textAreaWidth,height:phe?0:1,useCover:!1})}_newlinecount(e){let t=0,i=-1;do{if(i=e.indexOf(` `,i+1),i===-1)break;t++}while(!0);return t}_renderAtTopLeft(){this._doRender({lastRenderPosition:null,top:0,left:0,width:this._textAreaWidth,height:phe?0:1,useCover:!0})}_doRender(e){this._lastRenderPosition=e.lastRenderPosition;let t=this.textArea,i=this.textAreaCover;Kn(t,this._fontInfo),t.setTop(e.top),t.setLeft(e.left),t.setWidth(e.width),t.setHeight(e.height),t.setColor(e.color?Z.Format.CSS.formatHex(e.color):""),t.setFontStyle(e.italic?"italic":""),e.bold&&t.setFontWeight("bold"),t.setTextDecoration(`${e.underline?" underline":""}${e.strikethrough?" line-through":""}`),i.setTop(e.useCover?e.top:0),i.setLeft(e.useCover?e.left:0),i.setWidth(e.useCover?e.width:0),i.setHeight(e.useCover?e.height:0);let o=this._context.configuration.options;o.get(57)?i.setClassName("monaco-editor-background textAreaCover "+NE.OUTER_CLASS_NAME):o.get(68).renderType!==0?i.setClassName("monaco-editor-background textAreaCover "+DE.CLASS_NAME):i.setClassName("monaco-editor-background textAreaCover")}};MV=Nut([b3e(3,_t),b3e(4,he)],MV)});function Fp(n){return n==="'"||n==='"'||n==="`"}var Aut,Mut,Put,Hb,Jt,ghe,_he,Qr,Ws,Bu=k(()=>{qe();we();Ui();vL();Tf();zW();Aut=()=>!0,Mut=()=>!1,Put=n=>n===" "||n===" ",Hb=class{static shouldRecreate(e){return e.hasChanged(146)||e.hasChanged(132)||e.hasChanged(37)||e.hasChanged(77)||e.hasChanged(79)||e.hasChanged(80)||e.hasChanged(6)||e.hasChanged(7)||e.hasChanged(11)||e.hasChanged(9)||e.hasChanged(10)||e.hasChanged(14)||e.hasChanged(129)||e.hasChanged(50)||e.hasChanged(92)||e.hasChanged(131)}constructor(e,t,i,o){this.languageConfigurationService=o,this._cursorMoveConfigurationBrand=void 0,this._languageId=e;let r=i.options,s=r.get(146),a=r.get(50);this.readOnly=r.get(92),this.tabSize=t.tabSize,this.indentSize=t.indentSize,this.insertSpaces=t.insertSpaces,this.stickyTabStops=r.get(117),this.lineHeight=a.lineHeight,this.typicalHalfwidthCharacterWidth=a.typicalHalfwidthCharacterWidth,this.pageSize=Math.max(1,Math.floor(s.height/this.lineHeight)-2),this.useTabStops=r.get(129),this.wordSeparators=r.get(132),this.emptySelectionClipboard=r.get(37),this.copyWithSyntaxHighlighting=r.get(25),this.multiCursorMergeOverlapping=r.get(77),this.multiCursorPaste=r.get(79),this.multiCursorLimit=r.get(80),this.autoClosingBrackets=r.get(6),this.autoClosingComments=r.get(7),this.autoClosingQuotes=r.get(11),this.autoClosingDelete=r.get(9),this.autoClosingOvertype=r.get(10),this.autoSurround=r.get(14),this.autoIndent=r.get(12),this.wordSegmenterLocales=r.get(131),this.surroundingPairs={},this._electricChars=null,this.shouldAutoCloseBefore={quote:this._getShouldAutoClose(e,this.autoClosingQuotes,!0),comment:this._getShouldAutoClose(e,this.autoClosingComments,!1),bracket:this._getShouldAutoClose(e,this.autoClosingBrackets,!1)},this.autoClosingPairs=this.languageConfigurationService.getLanguageConfiguration(e).getAutoClosingPairs();let l=this.languageConfigurationService.getLanguageConfiguration(e).getSurroundingPairs();if(l)for(let d of l)this.surroundingPairs[d.open]=d.close;let c=this.languageConfigurationService.getLanguageConfiguration(e).comments;this.blockCommentStartToken=c?.blockCommentStartToken??null}get electricChars(){if(!this._electricChars){this._electricChars={};let e=this.languageConfigurationService.getLanguageConfiguration(this._languageId).electricCharacter?.getElectricCharacters();if(e)for(let t of e)this._electricChars[t]=!0}return this._electricChars}onElectricCharacter(e,t,i){let o=Am(t,i-1),r=this.languageConfigurationService.getLanguageConfiguration(o.languageId).electricCharacter;return r?r.onElectricCharacter(e,o,i-o.firstCharOffset):null}normalizeIndentation(e){return NI(e,this.indentSize,this.insertSpaces)}_getShouldAutoClose(e,t,i){switch(t){case"beforeWhitespace":return Put;case"languageDefined":return this._getLanguageDefinedShouldAutoClose(e,i);case"always":return Aut;case"never":return Mut}}_getLanguageDefinedShouldAutoClose(e,t){let i=this.languageConfigurationService.getLanguageConfiguration(e).getAutoCloseBeforeSet(t);return o=>i.indexOf(o)!==-1}visibleColumnFromColumn(e,t){return Un.visibleColumnFromColumn(e.getLineContent(t.lineNumber),t.column,this.tabSize)}columnFromVisibleColumn(e,t,i){let o=Un.columnFromVisibleColumn(e.getLineContent(t),i,this.tabSize),r=e.getLineMinColumn(t);if(os?s:o}},Jt=class n{static fromModelState(e){return new ghe(e)}static fromViewState(e){return new _he(e)}static fromModelSelection(e){let t=Se.liftSelection(e),i=new Qr(S.fromPositions(t.getSelectionStart()),0,0,t.getPosition(),0);return n.fromModelState(i)}static fromModelSelections(e){let t=[];for(let i=0,o=e.length;i{Bu();qe();we();Mw=class n{static columnSelect(e,t,i,o,r,s){let a=Math.abs(r-i)+1,l=i>r,c=o>s,d=os||bo||_0&&o--,n.columnSelect(e,t,i.fromViewLineNumber,i.fromViewVisualColumn,i.toViewLineNumber,o)}static columnSelectRight(e,t,i){let o=0,r=Math.min(i.fromViewLineNumber,i.toViewLineNumber),s=Math.max(i.fromViewLineNumber,i.toViewLineNumber);for(let l=r;l<=s;l++){let c=t.getLineMaxColumn(l),d=e.visibleColumnFromColumn(t,new P(l,c));o=Math.max(o,d)}let a=i.toViewVisualColumn;return a{Ui();Xo=class{constructor(e,t,i=!1){this._range=e,this._text=t,this.insertsAutoWhitespace=i}getEditOperations(e,t){t.addTrackedEditOperation(this._range,this._text)}computeCursorState(e,t){let o=t.getInverseEditOperations()[0].range;return Se.fromPositions(o.getEndPosition())}},PV=class{constructor(e,t){this._range=e,this._text=t}getEditOperations(e,t){t.addTrackedEditOperation(this._range,this._text)}computeCursorState(e,t){let o=t.getInverseEditOperations()[0].range;return Se.fromRange(o,0)}},l0=class{constructor(e,t,i=!1){this._range=e,this._text=t,this.insertsAutoWhitespace=i}getEditOperations(e,t){t.addTrackedEditOperation(this._range,this._text)}computeCursorState(e,t){let o=t.getInverseEditOperations()[0].range;return Se.fromPositions(o.getStartPosition())}},c0=class{constructor(e,t,i,o,r=!1){this._range=e,this._text=t,this._columnDeltaOffset=o,this._lineNumberDeltaOffset=i,this.insertsAutoWhitespace=r}getEditOperations(e,t){t.addTrackedEditOperation(this._range,this._text)}computeCursorState(e,t){let o=t.getInverseEditOperations()[0].range;return Se.fromPositions(o.getEndPosition().delta(this._lineNumberDeltaOffset,this._columnDeltaOffset))}},Pw=class{constructor(e,t,i,o=!1){this._range=e,this._text=t,this._initialSelection=i,this._forceMoveMarkers=o,this._selectionId=null}getEditOperations(e,t){t.addTrackedEditOperation(this._range,this._text,this._forceMoveMarkers),this._selectionId=t.trackSelection(this._initialSelection)}computeCursorState(e,t){return t.getTrackedSelection(this._selectionId)}}});var aP,yo,OV=k(()=>{Qe();Tf();qe();we();Que();Bu();aP=class{constructor(e,t,i){this._cursorPositionBrand=void 0,this.lineNumber=e,this.column=t,this.leftoverVisibleColumns=i}},yo=class n{static leftPosition(e,t){if(t.column>e.getLineMinColumn(t.lineNumber))return t.delta(void 0,-Rne(e.getLineContent(t.lineNumber),t.column-1));if(t.lineNumber>1){let i=t.lineNumber-1;return new P(i,e.getLineMaxColumn(i))}else return t}static leftPositionAtomicSoftTabs(e,t,i){if(t.column<=e.getLineIndentColumn(t.lineNumber)){let o=e.getLineMinColumn(t.lineNumber),r=e.getLineContent(t.lineNumber),s=s0.atomicPosition(r,t.column-1,i,0);if(s!==-1&&s+1>=o)return new P(t.lineNumber,s+1)}return this.leftPosition(e,t)}static left(e,t,i){let o=e.stickyTabStops?n.leftPositionAtomicSoftTabs(t,i,e.tabSize):n.leftPosition(t,i);return new aP(o.lineNumber,o.column,0)}static moveLeft(e,t,i,o,r){let s,a;if(i.hasSelection()&&!o)s=i.selection.startLineNumber,a=i.selection.startColumn;else{let l=i.position.delta(void 0,-(r-1)),c=t.normalizePosition(n.clipPositionColumn(l,t),0),d=n.left(e,t,c);s=d.lineNumber,a=d.column}return i.move(o,s,a,0)}static clipPositionColumn(e,t){return new P(e.lineNumber,n.clipRange(e.column,t.getLineMinColumn(e.lineNumber),t.getLineMaxColumn(e.lineNumber)))}static clipRange(e,t,i){return ei?i:e}static rightPosition(e,t,i){return id?(i=d,a?o=t.getLineMaxColumn(i):o=Math.min(t.getLineMaxColumn(i),o)):o=e.columnFromVisibleColumn(t,i,c),f?r=0:r=c-Un.visibleColumnFromColumn(t.getLineContent(i),o,e.tabSize),l!==void 0){let p=new P(i,o),g=t.normalizePosition(p,l);r=r+(o-g.column),i=g.lineNumber,o=g.column}return new aP(i,o,r)}static down(e,t,i,o,r,s,a){return this.vertical(e,t,i,o,r,i+s,a,4)}static moveDown(e,t,i,o,r){let s,a;i.hasSelection()&&!o?(s=i.selection.endLineNumber,a=i.selection.endColumn):(s=i.position.lineNumber,a=i.position.column);let l=0,c;do if(c=n.down(e,t,s+l,a,i.leftoverVisibleColumns,r,!0),t.normalizePosition(new P(c.lineNumber,c.column),2).lineNumber>s)break;while(l++<10&&s+l1&&this._isBlankLine(t,r);)r--;for(;r>1&&!this._isBlankLine(t,r);)r--;return i.move(o,r,t.getLineMinColumn(r),0)}static moveToNextBlankLine(e,t,i,o){let r=t.getLineCount(),s=i.position.lineNumber;for(;s{Qe();d0();Bu();Tf();OV();we();qe();zb=class n{static deleteRight(e,t,i,o){let r=[],s=e!==3;for(let a=0,l=o.length;a=h.length+1)return!1;let f=h.charAt(u.column-2),p=o.get(f);if(!p)return!1;if(Fp(f)){if(i==="never")return!1}else if(t==="never")return!1;let g=h.charAt(u.column-1),_=!1;for(let b of p)b.open===f&&b.close===g&&(_=!0);if(!_)return!1;if(e==="auto"){let b=!1;for(let v=0,x=a.length;v1){let r=t.getLineContent(o.lineNumber),s=bo(r),a=s===-1?r.length+1:s+1;if(o.column<=a){let l=i.visibleColumnFromColumn(t,o),c=Un.prevIndentTabStop(l,i.indentSize),d=i.columnFromVisibleColumn(t,o.lineNumber,c);return new S(o.lineNumber,d,o.lineNumber,o.column)}}return S.fromPositions(n.getPositionAfterDeleteLeft(o,t),o)}static getPositionAfterDeleteLeft(e,t){if(e.column>1){let i=UTe(e.column-1,t.getLineContent(e.lineNumber));return e.with(void 0,i+1)}else if(e.lineNumber>1){let i=e.lineNumber-1;return new P(i,t.getLineMaxColumn(i))}else return e}static cut(e,t,i){let o=[],r=null;i.sort((s,a)=>P.compare(s.getStartPosition(),a.getEndPosition()));for(let s=0,a=i.length;s1&&r?.endLineNumber!==c.lineNumber?(d=c.lineNumber-1,u=t.getLineMaxColumn(c.lineNumber-1),h=c.lineNumber,f=t.getLineMaxColumn(c.lineNumber)):(d=c.lineNumber,u=1,h=c.lineNumber,f=t.getLineMaxColumn(c.lineNumber));let p=new S(d,u,h,f);r=p,p.isEmpty()?o[s]=null:o[s]=new Xo(p,"")}else o[s]=null;else o[s]=new Xo(l,"")}return new Ws(0,o,{shouldPushStackElementBefore:!0,shouldPushStackElementAfter:!0})}}});function BV(n){return n.filter(e=>!!e)}var Fr,u0,lP=k(()=>{Qe();Bu();FV();SL();qe();we();Fr=class n{static _createWord(e,t,i,o,r){return{start:o,end:r,wordType:t,nextCharClass:i}}static _createIntlWord(e,t){return{start:e.index,end:e.index+e.segment.length,wordType:1,nextCharClass:t}}static _findPreviousWordOnLine(e,t,i){let o=t.getLineContent(i.lineNumber);return this._doFindPreviousWordOnLine(o,e,i)}static _doFindPreviousWordOnLine(e,t,i){let o=0,r=t.findPrevIntlWordBeforeOrAtOffset(e,i.column-2);for(let s=i.column-2;s>=0;s--){let a=e.charCodeAt(s),l=t.get(a);if(r&&s===r.index)return this._createIntlWord(r,l);if(l===0){if(o===2)return this._createWord(e,o,l,s+1,this._findEndOfWord(e,t,o,s+1));o=1}else if(l===2){if(o===1)return this._createWord(e,o,l,s+1,this._findEndOfWord(e,t,o,s+1));o=2}else if(l===1&&o!==0)return this._createWord(e,o,l,s+1,this._findEndOfWord(e,t,o,s+1))}return o!==0?this._createWord(e,o,1,0,this._findEndOfWord(e,t,o,0)):null}static _findEndOfWord(e,t,i,o){let r=t.findNextIntlWordAtOrAfterOffset(e,o),s=e.length;for(let a=o;a=0;s--){let a=e.charCodeAt(s),l=t.get(a);if(r&&s===r.index)return s;if(l===1||i===1&&l===2||i===2&&l===0)return s+1}return 0}static moveWordLeft(e,t,i,o,r){let s=i.lineNumber,a=i.column;a===1&&s>1&&(s=s-1,a=t.getLineMaxColumn(s));let l=n._findPreviousWordOnLine(e,t,new P(s,a));if(o===0)return new P(s,l?l.start+1:1);if(o===1)return!r&&l&&l.wordType===2&&l.end-l.start===1&&l.nextCharClass===0&&(l=n._findPreviousWordOnLine(e,t,new P(s,l.start+1))),new P(s,l?l.start+1:1);if(o===3){for(;l&&l.wordType===2;)l=n._findPreviousWordOnLine(e,t,new P(s,l.start+1));return new P(s,l?l.start+1:1)}return l&&a<=l.end+1&&(l=n._findPreviousWordOnLine(e,t,new P(s,l.start+1))),new P(s,l?l.end+1:1)}static _moveWordPartLeft(e,t){let i=t.lineNumber,o=e.getLineMaxColumn(i);if(t.column===1)return i>1?new P(i-1,e.getLineMaxColumn(i-1)):t;let r=e.getLineContent(i);for(let s=t.column-1;s>1;s--){let a=r.charCodeAt(s-2),l=r.charCodeAt(s-1);if(a===95&&l!==95)return new P(i,s);if(a===45&&l!==45)return new P(i,s);if((km(a)||YR(a))&&uh(l))return new P(i,s);if(uh(a)&&uh(l)&&s+1=l.start+1&&(l=n._findNextWordOnLine(e,t,new P(r,l.end+1))),l?s=l.start+1:s=t.getLineMaxColumn(r);return new P(r,s)}static _moveWordPartRight(e,t){let i=t.lineNumber,o=e.getLineMaxColumn(i);if(t.column===o)return i1?c=1:(l--,c=o.getLineMaxColumn(l)):(d&&c<=d.end+1&&(d=n._findPreviousWordOnLine(i,o,new P(l,d.start+1))),d?c=d.end+1:c>1?c=1:(l--,c=o.getLineMaxColumn(l))),new S(l,c,a.lineNumber,a.column)}static deleteInsideWord(e,t,i){if(!i.isEmpty())return i;let o=new P(i.positionLineNumber,i.positionColumn),r=this._deleteInsideWordWhitespace(t,o);return r||this._deleteInsideWordDetermineDeleteRange(e,t,o)}static _charAtIsWhitespace(e,t){let i=e.charCodeAt(t);return i===32||i===9}static _deleteInsideWordWhitespace(e,t){let i=e.getLineContent(t.lineNumber),o=i.length;if(o===0)return null;let r=Math.max(t.column-2,0);if(!this._charAtIsWhitespace(i,r))return null;let s=Math.min(t.column-1,o-1);if(!this._charAtIsWhitespace(i,s))return null;for(;r>0&&this._charAtIsWhitespace(i,r-1);)r--;for(;s+11?new S(i.lineNumber-1,t.getLineMaxColumn(i.lineNumber-1),i.lineNumber,1):i.lineNumberu.start+1<=i.column&&i.column<=u.end+1,a=(u,h)=>(u=Math.min(u,i.column),h=Math.max(h,i.column),new S(i.lineNumber,u,i.lineNumber,h)),l=u=>{let h=u.start+1,f=u.end+1,p=!1;for(;f-11&&this._charAtIsWhitespace(o,h-2);)h--;return a(h,f)},c=n._findPreviousWordOnLine(e,t,i);if(c&&s(c))return l(c);let d=n._findNextWordOnLine(e,t,i);return d&&s(d)?l(d):c&&d?a(c.end+1,d.start+1):c?a(c.start+1,c.end+1):d?a(d.start+1,d.end+1):a(1,r+1)}static _deleteWordPartLeft(e,t){if(!t.isEmpty())return t;let i=t.getPosition(),o=n._moveWordPartLeft(e,i);return new S(i.lineNumber,i.column,o.lineNumber,o.column)}static _findFirstNonWhitespaceChar(e,t){let i=e.length;for(let o=t;o=h.start+1&&(h=n._findNextWordOnLine(i,o,new P(l,h.end+1))),h?c=h.start+1:c{yi();Bu();OV();lP();qe();we();Lr=class{static addCursorDown(e,t,i){let o=[],r=0;for(let s=0,a=t.length;sc&&(d=c,u=e.model.getLineMaxColumn(d)),Jt.fromModelState(new Qr(new S(s.lineNumber,1,d,u),2,0,new P(d,u),0))}let l=t.modelState.selectionStart.getStartPosition().lineNumber;if(s.lineNumberl){let c=e.getLineCount(),d=a.lineNumber+1,u=1;return d>c&&(d=c,u=e.getLineMaxColumn(d)),Jt.fromViewState(t.viewState.move(!0,d,u,0))}else{let c=t.modelState.selectionStart.getEndPosition();return Jt.fromModelState(t.modelState.move(!0,c.lineNumber,c.column,0))}}static word(e,t,i,o){let r=e.model.validatePosition(o);return Jt.fromModelState(Fr.word(e.cursorConfig,e.model,t.modelState,i,r))}static cancelSelection(e,t){if(!t.modelState.hasSelection())return new Jt(t.modelState,t.viewState);let i=t.viewState.position.lineNumber,o=t.viewState.position.column;return Jt.fromViewState(new Qr(new S(i,o,i,o),0,0,new P(i,o),0))}static moveTo(e,t,i,o,r){if(i){if(t.modelState.selectionStartKind===1)return this.word(e,t,i,o);if(t.modelState.selectionStartKind===2)return this.line(e,t,i,o,r)}let s=e.model.validatePosition(o),a=r?e.coordinatesConverter.validateViewPosition(new P(r.lineNumber,r.column),s):e.coordinatesConverter.convertModelPositionToViewPosition(s);return Jt.fromViewState(t.viewState.move(i,a.lineNumber,a.column,0))}static simpleMove(e,t,i,o,r,s){switch(i){case 0:return s===4?this._moveHalfLineLeft(e,t,o):this._moveLeft(e,t,o,r);case 1:return s===4?this._moveHalfLineRight(e,t,o):this._moveRight(e,t,o,r);case 2:return s===2?this._moveUpByViewLines(e,t,o,r):this._moveUpByModelLines(e,t,o,r);case 3:return s===2?this._moveDownByViewLines(e,t,o,r):this._moveDownByModelLines(e,t,o,r);case 4:return s===2?t.map(a=>Jt.fromViewState(yo.moveToPrevBlankLine(e.cursorConfig,e,a.viewState,o))):t.map(a=>Jt.fromModelState(yo.moveToPrevBlankLine(e.cursorConfig,e.model,a.modelState,o)));case 5:return s===2?t.map(a=>Jt.fromViewState(yo.moveToNextBlankLine(e.cursorConfig,e,a.viewState,o))):t.map(a=>Jt.fromModelState(yo.moveToNextBlankLine(e.cursorConfig,e.model,a.modelState,o)));case 6:return this._moveToViewMinColumn(e,t,o);case 7:return this._moveToViewFirstNonWhitespaceColumn(e,t,o);case 8:return this._moveToViewCenterColumn(e,t,o);case 9:return this._moveToViewMaxColumn(e,t,o);case 10:return this._moveToViewLastNonWhitespaceColumn(e,t,o);default:return null}}static viewportMove(e,t,i,o,r){let s=e.getCompletelyVisibleViewRange(),a=e.coordinatesConverter.convertViewRangeToModelRange(s);switch(i){case 11:{let l=this._firstLineNumberInRange(e.model,a,r),c=e.model.getLineFirstNonWhitespaceColumn(l);return[this._moveToModelPosition(e,t[0],o,l,c)]}case 13:{let l=this._lastLineNumberInRange(e.model,a,r),c=e.model.getLineFirstNonWhitespaceColumn(l);return[this._moveToModelPosition(e,t[0],o,l,c)]}case 12:{let l=Math.round((a.startLineNumber+a.endLineNumber)/2),c=e.model.getLineFirstNonWhitespaceColumn(l);return[this._moveToModelPosition(e,t[0],o,l,c)]}case 14:{let l=[];for(let c=0,d=t.length;ci.endLineNumber-1?s=i.endLineNumber-1:rJt.fromViewState(yo.moveLeft(e.cursorConfig,e,r.viewState,i,o)))}static _moveHalfLineLeft(e,t,i){let o=[];for(let r=0,s=t.length;rJt.fromViewState(yo.moveRight(e.cursorConfig,e,r.viewState,i,o)))}static _moveHalfLineRight(e,t,i){let o=[];for(let r=0,s=t.length;r{Qe();vL();Dh();h0=class{constructor(e,t,i){this._indentRulesSupport=t,this._indentationLineProcessor=new HV(e,i)}shouldIncrease(e,t){let i=this._indentationLineProcessor.getProcessedLine(e,t);return this._indentRulesSupport.shouldIncrease(i)}shouldDecrease(e,t){let i=this._indentationLineProcessor.getProcessedLine(e,t);return this._indentRulesSupport.shouldDecrease(i)}shouldIgnore(e,t){let i=this._indentationLineProcessor.getProcessedLine(e,t);return this._indentRulesSupport.shouldIgnore(i)}shouldIndentNextLine(e,t){let i=this._indentationLineProcessor.getProcessedLine(e,t);return this._indentRulesSupport.shouldIndentNextLine(i)}},f0=class{constructor(e,t){this.model=e,this.indentationLineProcessor=new HV(e,t)}getProcessedTokenContextAroundRange(e){let t=this._getProcessedTokensBeforeRange(e),i=this._getProcessedTokensAfterRange(e),o=this._getProcessedPreviousLineTokens(e);return{beforeRangeProcessedTokens:t,afterRangeProcessedTokens:i,previousLineProcessedTokens:o}}_getProcessedTokensBeforeRange(e){this.model.tokenization.forceTokenization(e.startLineNumber);let t=this.model.tokenization.getLineTokens(e.startLineNumber),i=Am(t,e.startColumn-1),o;if(zV(this.model,e.getStartPosition())){let s=e.startColumn-1-i.firstCharOffset,a=i.firstCharOffset,l=a+s;o=t.sliceAndInflate(a,l,0)}else{let s=e.startColumn-1;o=t.sliceAndInflate(0,s,0)}return this.indentationLineProcessor.getProcessedTokens(o)}_getProcessedTokensAfterRange(e){let t=e.isEmpty()?e.getStartPosition():e.getEndPosition();this.model.tokenization.forceTokenization(t.lineNumber);let i=this.model.tokenization.getLineTokens(t.lineNumber),o=Am(i,t.column-1),r=t.column-1-o.firstCharOffset,s=o.firstCharOffset+r,a=o.firstCharOffset+o.getLineLength(),l=i.sliceAndInflate(s,a,0);return this.indentationLineProcessor.getProcessedTokens(l)}_getProcessedPreviousLineTokens(e){let t=f=>{this.model.tokenization.forceTokenization(f);let p=this.model.tokenization.getLineTokens(f),g=this.model.getLineMaxColumn(f)-1;return Am(p,g)};this.model.tokenization.forceTokenization(e.startLineNumber);let i=this.model.tokenization.getLineTokens(e.startLineNumber),o=Am(i,e.startColumn-1),r=ao.createEmpty("",o.languageIdCodec),s=e.startLineNumber-1;if(s===0||!(o.firstCharOffset===0))return r;let c=t(s);if(!(o.languageId===c.languageId))return r;let u=c.toIViewLineTokens();return this.indentationLineProcessor.getProcessedTokens(u)}},HV=class{constructor(e,t){this.model=e,this.languageConfigurationService=t}getProcessedLine(e,t){let i=(s,a)=>{let l=Ei(s);return a+s.substring(l.length)};this.model.tokenization.forceTokenization?.(e);let o=this.model.tokenization.getLineTokens(e),r=this.getProcessedTokens(o).getLineContent();return t!==void 0&&(r=i(r,t)),r}getProcessedTokens(e){let t=l=>l===2||l===3||l===1,i=e.getLanguageId(0),r=this.languageConfigurationService.getLanguageConfiguration(i).bracketsNew.getBracketRegExp({global:!0}),s=[];return e.forEach(l=>{let c=e.getStandardTokenType(l),d=e.getTokenText(l);t(c)&&(d=d.replace(r,""));let u=e.getMetadata(l);s.push({text:d,metadata:u})}),ao.createFromTextAndMetadata(s,e.languageIdCodec)}}});function Vb(n,e,t,i){e.tokenization.forceTokenization(t.startLineNumber);let o=e.getLanguageIdAtPosition(t.startLineNumber,t.startColumn),r=i.getLanguageConfiguration(o);if(!r)return null;let a=new f0(e,i).getProcessedTokenContextAroundRange(t),l=a.previousLineProcessedTokens.getLineContent(),c=a.beforeRangeProcessedTokens.getLineContent(),d=a.afterRangeProcessedTokens.getLineContent(),u=r.onEnter(n,l,c,d);if(!u)return null;let h=u.indentAction,f=u.appendText,p=u.removeText||0;f?h===Io.Indent&&(f=" "+f):h===Io.Indent||h===Io.IndentOutdent?f=" ":f="";let g=E6(e,t.startLineNumber,t.startColumn);return p&&(g=g.substring(0,g.length-p)),{indentAction:h,appendText:f,removeText:p,indentation:g}}var UV=k(()=>{Ix();Ko();VV()});function p0(n,e){if(e<=0)return"";bhe[n]||(bhe[n]=["",n]);let t=bhe[n];for(let i=t.length;i<=e;i++)t[i]=t[i-1]+n;return t[e]}var Out,Fut,$V,bhe,Hl,RE=k(()=>{Qe();Tf();we();Ui();UV();Ko();Out=function(n,e,t,i){var o=arguments.length,r=o<3?e:i===null?i=Object.getOwnPropertyDescriptor(e,t):i,s;if(typeof Reflect=="object"&&typeof Reflect.decorate=="function")r=Reflect.decorate(n,e,t,i);else for(var a=n.length-1;a>=0;a--)(s=n[a])&&(r=(o<3?s(r):o>3?s(e,t,r):s(e,t))||r);return o>3&&r&&Object.defineProperty(e,t,r),r},Fut=function(n,e){return function(t,i){e(t,i,n)}},bhe=Object.create(null);Hl=$V=class{static unshiftIndent(e,t,i,o,r){let s=Un.visibleColumnFromColumn(e,t,i);if(r){let a=p0(" ",o),c=Un.prevIndentTabStop(s,o)/o;return p0(a,c)}else{let a=" ",c=Un.prevRenderTabStop(s,i)/i;return p0(a,c)}}static shiftIndent(e,t,i,o,r){let s=Un.visibleColumnFromColumn(e,t,i);if(r){let a=p0(" ",o),c=Un.nextIndentTabStop(s,o)/o;return p0(a,c)}else{let a=" ",c=Un.nextRenderTabStop(s,i)/i;return p0(a,c)}}constructor(e,t,i){this._languageConfigurationService=i,this._opts=t,this._selection=e,this._selectionId=null,this._useLastEditRangeForCursorEndPosition=!1,this._selectionStartColumnStaysPut=!1}_addEditOperation(e,t,i){this._useLastEditRangeForCursorEndPosition?e.addTrackedEditOperation(t,i):e.addEditOperation(t,i)}getEditOperations(e,t){let i=this._selection.startLineNumber,o=this._selection.endLineNumber;this._selection.endColumn===1&&i!==o&&(o=o-1);let{tabSize:r,indentSize:s,insertSpaces:a}=this._opts,l=i===o;if(this._opts.useTabStops){this._selection.isEmpty()&&/^\s*$/.test(e.getLineContent(i))&&(this._useLastEditRangeForCursorEndPosition=!0);let c=0,d=0;for(let u=i;u<=o;u++,c=d){d=0;let h=e.getLineContent(u),f=bo(h);if(this._opts.isUnshift&&(h.length===0||f===0)||!l&&!this._opts.isUnshift&&h.length===0)continue;if(f===-1&&(f=h.length),u>1&&Un.visibleColumnFromColumn(h,f+1,r)%s!==0&&e.tokenization.isCheapToTokenize(u-1)){let _=Vb(this._opts.autoIndent,e,new S(u-1,e.getLineMaxColumn(u-1),u-1,e.getLineMaxColumn(u-1)),this._languageConfigurationService);if(_){if(d=c,_.appendText)for(let b=0,v=_.appendText.length;b{we();Ui();jV=class{constructor(e,t,i){this._range=e,this._charBeforeSelection=t,this._charAfterSelection=i}getEditOperations(e,t){t.addTrackedEditOperation(new S(this._range.startLineNumber,this._range.startColumn,this._range.startLineNumber,this._range.startColumn),this._charBeforeSelection),t.addTrackedEditOperation(new S(this._range.endLineNumber,this._range.endColumn,this._range.endLineNumber,this._range.endColumn),this._charAfterSelection)}computeCursorState(e,t){let i=t.getInverseEditOperations(),o=i[0].range,r=i[1].range;return new Se(o.endLineNumber,o.endColumn,r.endLineNumber,r.endColumn-this._charAfterSelection.length)}},qV=class{constructor(e,t,i){this._position=e,this._text=t,this._charAfter=i}getEditOperations(e,t){t.addTrackedEditOperation(new S(this._position.lineNumber,this._position.column,this._position.lineNumber,this._position.column),this._text+this._charAfter)}computeCursorState(e,t){let o=t.getInverseEditOperations()[0].range;return new Se(o.endLineNumber,o.startColumn,o.endLineNumber,o.endColumn-this._charAfter.length)}}});function But(n,e,t){let i=n.tokenization.getLanguageIdAtPosition(e,0);if(e>1){let o,r=-1;for(o=e-1;o>=1;o--){if(n.tokenization.getLanguageIdAtPosition(o,0)!==i)return r;let s=n.getLineContent(o);if(t.shouldIgnore(o)||/^\s+$/.test(s)||s===""){r=o;continue}return o}}return-1}function AE(n,e,t,i=!0,o){if(n<4)return null;let r=o.getLanguageConfiguration(e.tokenization.getLanguageId()).indentRulesSupport;if(!r)return null;let s=new h0(e,r,o);if(t<=1)return{indentation:"",action:null};for(let l=t-1;l>0&&e.getLineContent(l)==="";l--)if(l===1)return{indentation:"",action:null};let a=But(e,t,s);if(a<0)return null;if(a<1)return{indentation:"",action:null};if(s.shouldIncrease(a)||s.shouldIndentNextLine(a)){let l=e.getLineContent(a);return{indentation:Ei(l),action:Io.Indent,line:a}}else if(s.shouldDecrease(a)){let l=e.getLineContent(a);return{indentation:Ei(l),action:null,line:a}}else{if(a===1)return{indentation:Ei(e.getLineContent(a)),action:null,line:a};let l=a-1,c=r.getIndentMetadata(e.getLineContent(l));if(!(c&3)&&c&4){let d=0;for(let u=l-1;u>0;u--)if(!s.shouldIndentNextLine(u)){d=u;break}return{indentation:Ei(e.getLineContent(d+1)),action:null,line:d+1}}if(i)return{indentation:Ei(e.getLineContent(a)),action:null,line:a};for(let d=a;d>0;d--){if(s.shouldIncrease(d))return{indentation:Ei(e.getLineContent(d)),action:Io.Indent,line:d};if(s.shouldIndentNextLine(d)){let u=0;for(let h=d-1;h>0;h--)if(!s.shouldIndentNextLine(d)){u=h;break}return{indentation:Ei(e.getLineContent(u+1)),action:null,line:u+1}}else if(s.shouldDecrease(d))return{indentation:Ei(e.getLineContent(d)),action:null,line:d}}return{indentation:Ei(e.getLineContent(1)),action:null,line:1}}}function m0(n,e,t,i,o,r){if(n<4)return null;let s=r.getLanguageConfiguration(t);if(!s)return null;let a=r.getLanguageConfiguration(t).indentRulesSupport;if(!a)return null;let l=new h0(e,a,r),c=AE(n,e,i,void 0,r);if(c){let d=c.line;if(d!==void 0){let u=!0;for(let h=d;h0){let b=e.getLineContent(_);if(c.shouldIndentNextLine(b)&&c.shouldIncrease(g)){let x=AE(s,e,t.startLineNumber,!1,r)?.indentation;if(x!==void 0){let w=e.getLineContent(t.startLineNumber),y=Ei(w),L=o.shiftIndent(x)===y,E=/^\s*$/.test(p),N=n.autoClosingPairs.autoClosingPairsOpenByEnd.get(i),F=N&&N.length>0&&E;if(L&&F)return x}}}return null}function KV(n,e,t){let i=t.getLanguageConfiguration(n.getLanguageId()).indentRulesSupport;return!i||e<1||e>n.getLineCount()?null:i.getIndentMetadata(n.getLineContent(e))}function Wut(n,e,t){return{tokenization:{getLineTokens:o=>o===e?t:n.tokenization.getLineTokens(o),getLanguageId:()=>n.getLanguageId(),getLanguageIdAtPosition:(o,r)=>n.getLanguageIdAtPosition(o,r)},getLineContent:o=>o===e?t.getLineContent():n.getLineContent(o)}}var GV=k(()=>{Qe();Ix();VV()});function yhe(n,e){return n===" "?e===5||e===6?6:5:4}function sU(n,e){return S3e(n)&&!S3e(e)?!0:n===5?!1:C3e(n)!==C3e(e)}function C3e(n){return n===6||n===5?"space":n}function S3e(n){return n===4||n===5||n===6}function k3e(n,e,t,i,o){if(n.autoClosingOvertype==="never"||!n.autoClosingPairs.autoClosingPairsCloseSingleChar.has(o))return!1;for(let r=0,s=t.length;r2?c.charCodeAt(l.column-2):0)===92&&u)return!1;if(n.autoClosingOvertype==="auto"){let f=!1;for(let p=0,g=i.length;p{je();Qe();d0();RE();vhe();Bu();SL();we();qe();Ix();Ko();vL();GV();UV();YV=class{static getEdits(e,t,i,o,r){if(!r&&this._isAutoIndentType(e,t,i)){let s=[];for(let l of i){let c=this._findActualIndentationForSelection(e,t,l,o);if(c===null)return;s.push({selection:l,indentation:c})}let a=ME.getAutoClosingPairClose(e,t,i,o,!1);return this._getIndentationAndAutoClosingPairEdits(e,t,s,o,a)}}static _isAutoIndentType(e,t,i){if(e.autoIndent<4)return!1;for(let o=0,r=i.length;oChe(e,a),unshiftIndent:a=>rU(e,a)},e.languageConfigurationService);if(r===null)return null;let s=E6(t,i.startLineNumber,i.startColumn);return r===e.normalizeIndentation(s)?null:r}static _getIndentationAndAutoClosingPairEdits(e,t,i,o,r){let s=i.map(({selection:l,indentation:c})=>{if(r!==null){let d=this._getEditFromIndentationAndSelection(e,t,c,l,o,!1);return new whe(d,l,o,r)}else{let d=this._getEditFromIndentationAndSelection(e,t,c,l,o,!0);return g0(d.range,d.text,!1)}}),a={shouldPushStackElementBefore:!0,shouldPushStackElementAfter:!1};return new Ws(4,s,a)}static _getEditFromIndentationAndSelection(e,t,i,o,r,s=!0){let a=o.startLineNumber,l=t.getLineFirstNonWhitespaceColumn(a),c=e.normalizeIndentation(i);if(l!==0){let u=t.getLineContent(a);c+=u.substring(l-1,o.startColumn-1)}return c+=s?r:"",{range:new S(a,1,o.endLineNumber,o.endColumn),text:c}}},ZV=class{static getEdits(e,t,i,o,r,s){if(k3e(t,i,o,r,s))return this._runAutoClosingOvertype(e,o,s)}static _runAutoClosingOvertype(e,t,i){let o=[];for(let r=0,s=t.length;rnew Xo(new S(a.positionLineNumber,a.positionColumn,a.positionLineNumber,a.positionColumn+1),"",!1));return new Ws(4,s,{shouldPushStackElementBefore:!0,shouldPushStackElementAfter:!1})}}},ME=class{static getEdits(e,t,i,o,r,s){if(!s){let a=this.getAutoClosingPairClose(e,t,i,o,r);if(a!==null)return this._runAutoClosingOpenCharType(i,o,r,a)}}static _runAutoClosingOpenCharType(e,t,i,o){let r=[];for(let s=0,a=e.length;s{let g=p.getPosition();return r?{lineNumber:g.lineNumber,beforeColumn:g.column-o.length,afterColumn:g.column}:{lineNumber:g.lineNumber,beforeColumn:g.column,afterColumn:g.column}}),a=this._findAutoClosingPairOpen(e,t,s.map(p=>new P(p.lineNumber,p.beforeColumn)),o);if(!a)return null;let l,c;if(Fp(o)?(l=e.autoClosingQuotes,c=e.shouldAutoCloseBefore.quote):(e.blockCommentStartToken?a.open.includes(e.blockCommentStartToken):!1)?(l=e.autoClosingComments,c=e.shouldAutoCloseBefore.comment):(l=e.autoClosingBrackets,c=e.shouldAutoCloseBefore.bracket),l==="never")return null;let u=this._findContainedAutoClosingPair(e,a),h=u?u.close:"",f=!0;for(let p of s){let{lineNumber:g,beforeColumn:_,afterColumn:b}=p,v=t.getLineContent(g),x=v.substring(0,_-1),w=v.substring(b-1);if(w.startsWith(h)||(f=!1),w.length>0){let E=w.charAt(0);if(!this._isBeforeClosingBrace(e,w)&&!c(E))return null}if(a.open.length===1&&(o==="'"||o==='"')&&l!=="always"){let E=Dl(e.wordSeparators,[]);if(x.length>0){let N=x.charCodeAt(x.length-1);if(E.get(N)===0)return null}}if(!t.tokenization.isCheapToTokenize(g))return null;t.tokenization.forceTokenization(g);let y=t.tokenization.getLineTokens(g),C=Am(y,_-1);if(!a.shouldAutoClose(C,_-C.firstCharOffset))return null;let L=a.findNeutralCharacter();if(L){let E=t.tokenization.getTokenTypeIfInsertingCharacter(g,_,L);if(!a.isOK(E))return null}}return f?a.close.substring(0,a.close.length-h.length):a.close}static _findContainedAutoClosingPair(e,t){if(t.open.length<=1)return null;let i=t.close.charAt(t.close.length-1),o=e.autoClosingPairs.autoClosingPairsCloseByEnd.get(i)||[],r=null;for(let s of o)s.open!==t.open&&t.open.includes(s.open)&&t.close.endsWith(s.close)&&(!r||s.open.length>r.open.length)&&(r=s);return r}static _findAutoClosingPairOpen(e,t,i,o){let r=e.autoClosingPairs.autoClosingPairsOpenByEnd.get(o);if(!r)return null;let s=null;for(let a of r)if(s===null||a.open.length>s.open.length){let l=!0;for(let c of i)if(t.getValueInRange(new S(c.lineNumber,c.column-a.open.length+1,c.lineNumber,c.column))+o!==a.open){l=!1;break}l&&(s=a)}return s}static _isBeforeClosingBrace(e,t){let i=t.charAt(0),o=e.autoClosingPairs.autoClosingPairsOpenByStart.get(i)||[],r=e.autoClosingPairs.autoClosingPairsCloseByStart.get(i)||[],s=o.some(l=>t.startsWith(l.open)),a=r.some(l=>t.startsWith(l.close));return!s&&a}},QV=class{static getEdits(e,t,i,o,r){if(!r&&this._isSurroundSelectionType(e,t,i,o))return this._runSurroundSelectionType(e,i,o)}static _runSurroundSelectionType(e,t,i){let o=[];for(let r=0,s=t.length;r=4){let l=w3e(e.autoIndent,t,o,{unshiftIndent:c=>rU(e,c),shiftIndent:c=>Che(e,c),normalizeIndentation:c=>e.normalizeIndentation(c)},e.languageConfigurationService);if(l){let c=e.visibleColumnFromColumn(t,o.getEndPosition()),d=o.endColumn,u=t.getLineContent(o.endLineNumber),h=bo(u);if(h>=0?o=o.setEndPosition(o.endLineNumber,Math.max(o.endColumn,h+1)):o=o.setEndPosition(o.endLineNumber,t.getLineMaxColumn(o.endLineNumber)),i)return new l0(o,` `+e.normalizeIndentation(l.afterEnter),!0);{let f=0;return d<=h+1&&(e.insertSpaces||(c=Math.ceil(c/e.indentSize)),f=Math.min(c+1-e.normalizeIndentation(l.afterEnter).length-1,0)),new c0(o,` `+e.normalizeIndentation(l.afterEnter),0,f,!0)}}}return g0(o,` `+e.normalizeIndentation(a),i)}static lineInsertBefore(e,t,i){if(t===null||i===null)return[];let o=[];for(let r=0,s=i.length;rthis._compositionType(i,d,r,s,a,l));return new Ws(4,c,{shouldPushStackElementBefore:sU(e,4),shouldPushStackElementAfter:!1})}static _compositionType(e,t,i,o,r,s){if(!t.isEmpty())return null;let a=t.getPosition(),l=Math.max(1,a.column-o),c=Math.min(e.getLineMaxColumn(a.lineNumber),a.column+r),d=new S(a.lineNumber,l,a.lineNumber,c);return e.getValueInRange(d)===i&&s===0?null:new c0(d,i,0,s)}},nU=class{static getEdits(e,t,i){let o=[];for(let s=0,a=t.length;s1){let a;for(a=i-1;a>=1;a--){let d=t.getLineContent(a);if(_a(d)>=0)break}if(a<1)return null;let l=t.getLineMaxColumn(a),c=Vb(e.autoIndent,t,new S(a,l,a,l),e.languageConfigurationService);c&&(r=c.indentation+c.appendText)}return o&&(o===Io.Indent&&(r=Che(e,r)),o===Io.Outdent&&(r=rU(e,r)),r=e.normalizeIndentation(r)),r||null}static _replaceJumpToNextIndent(e,t,i,o){let r="",s=i.getStartPosition();if(e.insertSpaces){let a=e.visibleColumnFromColumn(t,s),l=e.indentSize,c=l-a%l;for(let d=0;d{RE();vhe();Bu();dP();Hh=class{static indent(e,t,i){if(t===null||i===null)return[];let o=[];for(let r=0,s=i.length;r{pe();it();(function(n){n.editorSimpleInput=new me("editorSimpleInput",!1,!0),n.editorTextFocus=new me("editorTextFocus",!1,m("editorTextFocus","Whether the editor text has focus (cursor is blinking)")),n.focus=new me("editorFocus",!1,m("editorFocus","Whether the editor or an editor widget has focus (e.g. focus is in the find widget)")),n.textInputFocus=new me("textInputFocus",!1,m("textInputFocus","Whether an editor or a rich text input has focus (cursor is blinking)")),n.readOnly=new me("editorReadonly",!1,m("editorReadonly","Whether the editor is read-only")),n.inDiffEditor=new me("inDiffEditor",!1,m("inDiffEditor","Whether the context is a diff editor")),n.isEmbeddedDiffEditor=new me("isEmbeddedDiffEditor",!1,m("isEmbeddedDiffEditor","Whether the context is an embedded diff editor")),n.inMultiDiffEditor=new me("inMultiDiffEditor",!1,m("inMultiDiffEditor","Whether the context is a multi diff editor")),n.multiDiffEditorAllCollapsed=new me("multiDiffEditorAllCollapsed",void 0,m("multiDiffEditorAllCollapsed","Whether all files in multi diff editor are collapsed")),n.hasChanges=new me("diffEditorHasChanges",!1,m("diffEditorHasChanges","Whether the diff editor has changes")),n.comparingMovedCode=new me("comparingMovedCode",!1,m("comparingMovedCode","Whether a moved code block is selected for comparison")),n.accessibleDiffViewerVisible=new me("accessibleDiffViewerVisible",!1,m("accessibleDiffViewerVisible","Whether the accessible diff viewer is visible")),n.diffEditorRenderSideBySideInlineBreakpointReached=new me("diffEditorRenderSideBySideInlineBreakpointReached",!1,m("diffEditorRenderSideBySideInlineBreakpointReached","Whether the diff editor render side by side inline breakpoint is reached")),n.diffEditorInlineMode=new me("diffEditorInlineMode",!1,m("diffEditorInlineMode","Whether inline mode is active")),n.diffEditorOriginalWritable=new me("diffEditorOriginalWritable",!1,m("diffEditorOriginalWritable","Whether modified is writable in the diff editor")),n.diffEditorModifiedWritable=new me("diffEditorModifiedWritable",!1,m("diffEditorModifiedWritable","Whether modified is writable in the diff editor")),n.diffEditorOriginalUri=new me("diffEditorOriginalUri","",m("diffEditorOriginalUri","The uri of the original document")),n.diffEditorModifiedUri=new me("diffEditorModifiedUri","",m("diffEditorModifiedUri","The uri of the modified document")),n.columnSelection=new me("editorColumnSelection",!1,m("editorColumnSelection","Whether `editor.columnSelection` is enabled")),n.writable=n.readOnly.toNegated(),n.hasNonEmptySelection=new me("editorHasSelection",!1,m("editorHasSelection","Whether the editor has text selected")),n.hasOnlyEmptySelection=n.hasNonEmptySelection.toNegated(),n.hasMultipleSelections=new me("editorHasMultipleSelections",!1,m("editorHasMultipleSelections","Whether the editor has multiple selections")),n.hasSingleSelection=n.hasMultipleSelections.toNegated(),n.tabMovesFocus=new me("editorTabMovesFocus",!1,m("editorTabMovesFocus","Whether `Tab` will move focus out of the editor")),n.tabDoesNotMoveFocus=n.tabMovesFocus.toNegated(),n.isInEmbeddedEditor=new me("isInEmbeddedEditor",!1,!0),n.canUndo=new me("canUndo",!1,!0),n.canRedo=new me("canRedo",!1,!0),n.hoverVisible=new me("editorHoverVisible",!1,m("editorHoverVisible","Whether the editor hover is visible")),n.hoverFocused=new me("editorHoverFocused",!1,m("editorHoverFocused","Whether the editor hover is focused")),n.stickyScrollFocused=new me("stickyScrollFocused",!1,m("stickyScrollFocused","Whether the sticky scroll is focused")),n.stickyScrollVisible=new me("stickyScrollVisible",!1,m("stickyScrollVisible","Whether the sticky scroll is visible")),n.standaloneColorPickerVisible=new me("standaloneColorPickerVisible",!1,m("standaloneColorPickerVisible","Whether the standalone color picker is visible")),n.standaloneColorPickerFocused=new me("standaloneColorPickerFocused",!1,m("standaloneColorPickerFocused","Whether the standalone color picker is focused")),n.inCompositeEditor=new me("inCompositeEditor",void 0,m("inCompositeEditor","Whether the editor is part of a larger editor (e.g. notebooks)")),n.notInCompositeEditor=n.inCompositeEditor.toNegated(),n.languageId=new me("editorLangId","",m("editorLangId","The language identifier of the editor")),n.hasCompletionItemProvider=new me("editorHasCompletionItemProvider",!1,m("editorHasCompletionItemProvider","Whether the editor has a completion item provider")),n.hasCodeActionsProvider=new me("editorHasCodeActionsProvider",!1,m("editorHasCodeActionsProvider","Whether the editor has a code actions provider")),n.hasCodeLensProvider=new me("editorHasCodeLensProvider",!1,m("editorHasCodeLensProvider","Whether the editor has a code lens provider")),n.hasDefinitionProvider=new me("editorHasDefinitionProvider",!1,m("editorHasDefinitionProvider","Whether the editor has a definition provider")),n.hasDeclarationProvider=new me("editorHasDeclarationProvider",!1,m("editorHasDeclarationProvider","Whether the editor has a declaration provider")),n.hasImplementationProvider=new me("editorHasImplementationProvider",!1,m("editorHasImplementationProvider","Whether the editor has an implementation provider")),n.hasTypeDefinitionProvider=new me("editorHasTypeDefinitionProvider",!1,m("editorHasTypeDefinitionProvider","Whether the editor has a type definition provider")),n.hasHoverProvider=new me("editorHasHoverProvider",!1,m("editorHasHoverProvider","Whether the editor has a hover provider")),n.hasDocumentHighlightProvider=new me("editorHasDocumentHighlightProvider",!1,m("editorHasDocumentHighlightProvider","Whether the editor has a document highlight provider")),n.hasDocumentSymbolProvider=new me("editorHasDocumentSymbolProvider",!1,m("editorHasDocumentSymbolProvider","Whether the editor has a document symbol provider")),n.hasReferenceProvider=new me("editorHasReferenceProvider",!1,m("editorHasReferenceProvider","Whether the editor has a reference provider")),n.hasRenameProvider=new me("editorHasRenameProvider",!1,m("editorHasRenameProvider","Whether the editor has a rename provider")),n.hasSignatureHelpProvider=new me("editorHasSignatureHelpProvider",!1,m("editorHasSignatureHelpProvider","Whether the editor has a signature help provider")),n.hasInlayHintsProvider=new me("editorHasInlayHintsProvider",!1,m("editorHasInlayHintsProvider","Whether the editor has an inline hints provider")),n.hasDocumentFormattingProvider=new me("editorHasDocumentFormattingProvider",!1,m("editorHasDocumentFormattingProvider","Whether the editor has a document formatting provider")),n.hasDocumentSelectionFormattingProvider=new me("editorHasDocumentSelectionFormattingProvider",!1,m("editorHasDocumentSelectionFormattingProvider","Whether the editor has a document selection formatting provider")),n.hasMultipleDocumentFormattingProvider=new me("editorHasMultipleDocumentFormattingProvider",!1,m("editorHasMultipleDocumentFormattingProvider","Whether the editor has multiple document formatting providers")),n.hasMultipleDocumentSelectionFormattingProvider=new me("editorHasMultipleDocumentSelectionFormattingProvider",!1,m("editorHasMultipleDocumentSelectionFormattingProvider","Whether the editor has multiple document selection formatting providers"))})(T||(T={}))});function FE(n,e){Mr.registerKeybindingRule({id:n,primary:e,when:Hut,weight:Bi+1})}function L3e(n){return n.register(),n}function _0(n,e){L3e(new cU("default:"+n,n)),L3e(new cU(n,n,e))}var Bi,No,Ta,OE,uP,_s,Hut,Ow,cU,hP=k(()=>{pe();Fc();yi();Ns();mt();Po();x3e();Bu();FV();WV();lU();qe();we();Si();it();K_();ke();dP();Bi=0,No=class extends hn{runEditorCommand(e,t,i){let o=t._getViewModel();o&&this.runCoreEditorCommand(o,i||{})}};(function(n){let e=function(i){if(!mo(i))return!1;let o=i;return!(!Rr(o.to)||!Vr(o.by)&&!Rr(o.by)||!Vr(o.value)&&!cu(o.value)||!Vr(o.revealCursor)&&!N3(o.revealCursor))};n.metadata={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:e,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"}}}}]},n.RawDirection={Up:"up",Right:"right",Down:"down",Left:"left"},n.RawUnit={Line:"line",WrappedLine:"wrappedLine",Page:"page",HalfPage:"halfPage",Editor:"editor",Column:"column"};function t(i){let o;switch(i.to){case n.RawDirection.Up:o=1;break;case n.RawDirection.Right:o=2;break;case n.RawDirection.Down:o=3;break;case n.RawDirection.Left:o=4;break;default:return null}let r;switch(i.by){case n.RawUnit.Line:r=1;break;case n.RawUnit.WrappedLine:r=2;break;case n.RawUnit.Page:r=3;break;case n.RawUnit.HalfPage:r=4;break;case n.RawUnit.Editor:r=5;break;case n.RawUnit.Column:r=6;break;default:r=2}let s=Math.floor(i.value||1),a=!!i.revealCursor;return{direction:o,unit:r,value:s,revealCursor:a,select:!!i.select}}n.parse=t})(Ta||(Ta={}));(function(n){let e=function(t){if(!mo(t))return!1;let i=t;return!(!cu(i.lineNumber)&&!Rr(i.lineNumber)||!Vr(i.at)&&!Rr(i.at))};n.metadata={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:e,schema:{type:"object",required:["lineNumber"],properties:{lineNumber:{type:["number","string"]},at:{type:"string",enum:["top","center","bottom"]}}}}]},n.RawAtArgument={Top:"top",Center:"center",Bottom:"bottom"}})(OE||(OE={}));uP=class{constructor(e){e.addImplementation(1e4,"code-editor",(t,i)=>{let o=t.get(xt).getFocusedCodeEditor();return o&&o.hasTextFocus()?this._runEditorCommand(t,o,i):!1}),e.addImplementation(1e3,"generic-dom-input-textarea",(t,i)=>{let o=Mo();return o&&["input","textarea"].indexOf(o.tagName.toLowerCase())>=0?(this.runDOMCommand(o),!0):!1}),e.addImplementation(0,"generic-dom",(t,i)=>{let o=t.get(xt).getActiveCodeEditor();return o?(o.focus(),this._runEditorCommand(t,o,i)):!1})}_runEditorCommand(e,t,i){let o=this.runEditorCommand(e,t,i);return o||!0}};(function(n){class e extends No{constructor(v){super(v),this._inSelectionMode=v.inSelectionMode}runCoreEditorCommand(v,x){if(!x.position)return;v.model.pushStackElement(),v.setCursorStates(x.source,3,[Lr.moveTo(v,v.getPrimaryCursorState(),this._inSelectionMode,x.position,x.viewPosition)])&&x.revealType!==2&&v.revealAllCursors(x.source,!0,!0)}}n.MoveTo=ye(new e({id:"_moveTo",inSelectionMode:!1,precondition:void 0})),n.MoveToSelect=ye(new e({id:"_moveToSelect",inSelectionMode:!0,precondition:void 0}));class t extends No{runCoreEditorCommand(v,x){v.model.pushStackElement();let w=this._getColumnSelectResult(v,v.getPrimaryCursorState(),v.getCursorColumnSelectData(),x);w!==null&&(v.setCursorStates(x.source,3,w.viewStates.map(y=>Jt.fromViewState(y))),v.setCursorColumnSelectData({isReal:!0,fromViewLineNumber:w.fromLineNumber,fromViewVisualColumn:w.fromVisualColumn,toViewLineNumber:w.toLineNumber,toViewVisualColumn:w.toVisualColumn}),w.reversed?v.revealTopMostCursor(x.source):v.revealBottomMostCursor(x.source))}}n.ColumnSelect=ye(new class extends t{constructor(){super({id:"columnSelect",precondition:void 0})}_getColumnSelectResult(b,v,x,w){if(typeof w.position>"u"||typeof w.viewPosition>"u"||typeof w.mouseColumn>"u")return null;let y=b.model.validatePosition(w.position),C=b.coordinatesConverter.validateViewPosition(new P(w.viewPosition.lineNumber,w.viewPosition.column),y),L=w.doColumnSelect?x.fromViewLineNumber:C.lineNumber,E=w.doColumnSelect?x.fromViewVisualColumn:w.mouseColumn-1;return Mw.columnSelect(b.cursorConfig,b,L,E,C.lineNumber,w.mouseColumn-1)}}),n.CursorColumnSelectLeft=ye(new class extends t{constructor(){super({id:"cursorColumnSelectLeft",precondition:void 0,kbOpts:{weight:Bi,kbExpr:T.textInputFocus,primary:3599,linux:{primary:0}}})}_getColumnSelectResult(b,v,x,w){return Mw.columnSelectLeft(b.cursorConfig,b,x)}}),n.CursorColumnSelectRight=ye(new class extends t{constructor(){super({id:"cursorColumnSelectRight",precondition:void 0,kbOpts:{weight:Bi,kbExpr:T.textInputFocus,primary:3601,linux:{primary:0}}})}_getColumnSelectResult(b,v,x,w){return Mw.columnSelectRight(b.cursorConfig,b,x)}});class i extends t{constructor(v){super(v),this._isPaged=v.isPaged}_getColumnSelectResult(v,x,w,y){return Mw.columnSelectUp(v.cursorConfig,v,w,this._isPaged)}}n.CursorColumnSelectUp=ye(new i({isPaged:!1,id:"cursorColumnSelectUp",precondition:void 0,kbOpts:{weight:Bi,kbExpr:T.textInputFocus,primary:3600,linux:{primary:0}}})),n.CursorColumnSelectPageUp=ye(new i({isPaged:!0,id:"cursorColumnSelectPageUp",precondition:void 0,kbOpts:{weight:Bi,kbExpr:T.textInputFocus,primary:3595,linux:{primary:0}}}));class o extends t{constructor(v){super(v),this._isPaged=v.isPaged}_getColumnSelectResult(v,x,w,y){return Mw.columnSelectDown(v.cursorConfig,v,w,this._isPaged)}}n.CursorColumnSelectDown=ye(new o({isPaged:!1,id:"cursorColumnSelectDown",precondition:void 0,kbOpts:{weight:Bi,kbExpr:T.textInputFocus,primary:3602,linux:{primary:0}}})),n.CursorColumnSelectPageDown=ye(new o({isPaged:!0,id:"cursorColumnSelectPageDown",precondition:void 0,kbOpts:{weight:Bi,kbExpr:T.textInputFocus,primary:3596,linux:{primary:0}}}));class r extends No{constructor(){super({id:"cursorMove",precondition:void 0,metadata:cP.metadata})}runCoreEditorCommand(v,x){let w=cP.parse(x);w&&this._runCursorMove(v,x.source,w)}_runCursorMove(v,x,w){v.model.pushStackElement(),v.setCursorStates(x,3,r._move(v,v.getCursorStates(),w)),v.revealAllCursors(x,!0)}static _move(v,x,w){let y=w.select,C=w.value;switch(w.direction){case 0:case 1:case 2:case 3:case 4:case 5:case 6:case 7:case 8:case 9:case 10:return Lr.simpleMove(v,x,w.direction,y,C,w.unit);case 11:case 13:case 12:case 14:return Lr.viewportMove(v,x,w.direction,y,C);default:return null}}}n.CursorMoveImpl=r,n.CursorMove=ye(new r);class s extends No{constructor(v){super(v),this._staticArgs=v.args}runCoreEditorCommand(v,x){let w=this._staticArgs;this._staticArgs.value===-1&&(w={direction:this._staticArgs.direction,unit:this._staticArgs.unit,select:this._staticArgs.select,value:x.pageSize||v.cursorConfig.pageSize}),v.model.pushStackElement(),v.setCursorStates(x.source,3,Lr.simpleMove(v,v.getCursorStates(),w.direction,w.select,w.value,w.unit)),v.revealAllCursors(x.source,!0)}}n.CursorLeft=ye(new s({args:{direction:0,unit:0,select:!1,value:1},id:"cursorLeft",precondition:void 0,kbOpts:{weight:Bi,kbExpr:T.textInputFocus,primary:15,mac:{primary:15,secondary:[288]}}})),n.CursorLeftSelect=ye(new s({args:{direction:0,unit:0,select:!0,value:1},id:"cursorLeftSelect",precondition:void 0,kbOpts:{weight:Bi,kbExpr:T.textInputFocus,primary:1039}})),n.CursorRight=ye(new s({args:{direction:1,unit:0,select:!1,value:1},id:"cursorRight",precondition:void 0,kbOpts:{weight:Bi,kbExpr:T.textInputFocus,primary:17,mac:{primary:17,secondary:[292]}}})),n.CursorRightSelect=ye(new s({args:{direction:1,unit:0,select:!0,value:1},id:"cursorRightSelect",precondition:void 0,kbOpts:{weight:Bi,kbExpr:T.textInputFocus,primary:1041}})),n.CursorUp=ye(new s({args:{direction:2,unit:2,select:!1,value:1},id:"cursorUp",precondition:void 0,kbOpts:{weight:Bi,kbExpr:T.textInputFocus,primary:16,mac:{primary:16,secondary:[302]}}})),n.CursorUpSelect=ye(new s({args:{direction:2,unit:2,select:!0,value:1},id:"cursorUpSelect",precondition:void 0,kbOpts:{weight:Bi,kbExpr:T.textInputFocus,primary:1040,secondary:[3088],mac:{primary:1040},linux:{primary:1040}}})),n.CursorPageUp=ye(new s({args:{direction:2,unit:2,select:!1,value:-1},id:"cursorPageUp",precondition:void 0,kbOpts:{weight:Bi,kbExpr:T.textInputFocus,primary:11}})),n.CursorPageUpSelect=ye(new s({args:{direction:2,unit:2,select:!0,value:-1},id:"cursorPageUpSelect",precondition:void 0,kbOpts:{weight:Bi,kbExpr:T.textInputFocus,primary:1035}})),n.CursorDown=ye(new s({args:{direction:3,unit:2,select:!1,value:1},id:"cursorDown",precondition:void 0,kbOpts:{weight:Bi,kbExpr:T.textInputFocus,primary:18,mac:{primary:18,secondary:[300]}}})),n.CursorDownSelect=ye(new s({args:{direction:3,unit:2,select:!0,value:1},id:"cursorDownSelect",precondition:void 0,kbOpts:{weight:Bi,kbExpr:T.textInputFocus,primary:1042,secondary:[3090],mac:{primary:1042},linux:{primary:1042}}})),n.CursorPageDown=ye(new s({args:{direction:3,unit:2,select:!1,value:-1},id:"cursorPageDown",precondition:void 0,kbOpts:{weight:Bi,kbExpr:T.textInputFocus,primary:12}})),n.CursorPageDownSelect=ye(new s({args:{direction:3,unit:2,select:!0,value:-1},id:"cursorPageDownSelect",precondition:void 0,kbOpts:{weight:Bi,kbExpr:T.textInputFocus,primary:1036}})),n.CreateCursor=ye(new class extends No{constructor(){super({id:"createCursor",precondition:void 0})}runCoreEditorCommand(b,v){if(!v.position)return;let x;v.wholeLine?x=Lr.line(b,b.getPrimaryCursorState(),!1,v.position,v.viewPosition):x=Lr.moveTo(b,b.getPrimaryCursorState(),!1,v.position,v.viewPosition);let w=b.getCursorStates();if(w.length>1){let y=x.modelState?x.modelState.position:null,C=x.viewState?x.viewState.position:null;for(let L=0,E=w.length;LC&&(y=C);let L=new S(y,1,y,b.model.getLineMaxColumn(y)),E=0;if(x.at)switch(x.at){case OE.RawAtArgument.Top:E=3;break;case OE.RawAtArgument.Center:E=1;break;case OE.RawAtArgument.Bottom:E=4;break;default:break}let N=b.coordinatesConverter.convertModelRangeToViewRange(L);b.revealRange(v.source,!1,N,E,0)}}),n.SelectAll=new class extends uP{constructor(){super(jDe)}runDOMCommand(b){ls&&(b.focus(),b.select()),b.ownerDocument.execCommand("selectAll")}runEditorCommand(b,v,x){let w=v._getViewModel();w&&this.runCoreEditorCommand(w,x)}runCoreEditorCommand(b,v){b.model.pushStackElement(),b.setCursorStates("keyboard",3,[Lr.selectAll(b,b.getPrimaryCursorState())])}},n.SetSelection=ye(new class extends No{constructor(){super({id:"setSelection",precondition:void 0})}runCoreEditorCommand(b,v){v.selection&&(b.model.pushStackElement(),b.setCursorStates(v.source,3,[Jt.fromModelSelection(v.selection)]))}})})(_s||(_s={}));Hut=Y.and(T.textInputFocus,T.columnSelection);FE(_s.CursorColumnSelectLeft.id,1039);FE(_s.CursorColumnSelectRight.id,1041);FE(_s.CursorColumnSelectUp.id,1040);FE(_s.CursorColumnSelectPageUp.id,1035);FE(_s.CursorColumnSelectDown.id,1042);FE(_s.CursorColumnSelectPageDown.id,1036);(function(n){class e extends hn{runEditorCommand(i,o,r){let s=o._getViewModel();s&&this.runCoreEditingCommand(o,s,r||{})}}n.CoreEditingCommand=e,n.LineBreakInsert=ye(new class extends e{constructor(){super({id:"lineBreakInsert",precondition:T.writable,kbOpts:{weight:Bi,kbExpr:T.textInputFocus,primary:0,mac:{primary:301}}})}runCoreEditingCommand(t,i,o){t.pushUndoStop(),t.executeCommands(this.id,Ub.lineBreakInsert(i.cursorConfig,i.model,i.getCursorStates().map(r=>r.modelState.selection)))}}),n.Outdent=ye(new class extends e{constructor(){super({id:"outdent",precondition:T.writable,kbOpts:{weight:Bi,kbExpr:Y.and(T.editorTextFocus,T.tabDoesNotMoveFocus),primary:1026}})}runCoreEditingCommand(t,i,o){t.pushUndoStop(),t.executeCommands(this.id,Hh.outdent(i.cursorConfig,i.model,i.getCursorStates().map(r=>r.modelState.selection))),t.pushUndoStop()}}),n.Tab=ye(new class extends e{constructor(){super({id:"tab",precondition:T.writable,kbOpts:{weight:Bi,kbExpr:Y.and(T.editorTextFocus,T.tabDoesNotMoveFocus),primary:2}})}runCoreEditingCommand(t,i,o){t.pushUndoStop(),t.executeCommands(this.id,Hh.tab(i.cursorConfig,i.model,i.getCursorStates().map(r=>r.modelState.selection))),t.pushUndoStop()}}),n.DeleteLeft=ye(new class extends e{constructor(){super({id:"deleteLeft",precondition:void 0,kbOpts:{weight:Bi,kbExpr:T.textInputFocus,primary:1,secondary:[1025],mac:{primary:1,secondary:[1025,294,257]}}})}runCoreEditingCommand(t,i,o){let[r,s]=zb.deleteLeft(i.getPrevEditOperationType(),i.cursorConfig,i.model,i.getCursorStates().map(a=>a.modelState.selection),i.getCursorAutoClosedCharacters());r&&t.pushUndoStop(),t.executeCommands(this.id,s),i.setPrevEditOperationType(2)}}),n.DeleteRight=ye(new class extends e{constructor(){super({id:"deleteRight",precondition:void 0,kbOpts:{weight:Bi,kbExpr:T.textInputFocus,primary:20,mac:{primary:20,secondary:[290,276]}}})}runCoreEditingCommand(t,i,o){let[r,s]=zb.deleteRight(i.getPrevEditOperationType(),i.cursorConfig,i.model,i.getCursorStates().map(a=>a.modelState.selection));r&&t.pushUndoStop(),t.executeCommands(this.id,s),i.setPrevEditOperationType(3)}}),n.Undo=new class extends uP{constructor(){super(yoe)}runDOMCommand(t){t.ownerDocument.execCommand("undo")}runEditorCommand(t,i,o){if(!(!i.hasModel()||i.getOption(92)===!0))return i.getModel().undo()}},n.Redo=new class extends uP{constructor(){super(Coe)}runDOMCommand(t){t.ownerDocument.execCommand("redo")}runEditorCommand(t,i,o){if(!(!i.hasModel()||i.getOption(92)===!0))return i.getModel().redo()}}})(Ow||(Ow={}));cU=class extends H1{constructor(e,t,i){super({id:e,precondition:void 0,metadata:i}),this._handlerId=t}runCommand(e,t){let i=e.get(xt).getFocusedCodeEditor();i&&i.trigger("keyboard",this._handlerId,t)}};_0("type",{description:"Type",args:[{name:"args",schema:{type:"object",required:["text"],properties:{text:{type:"string"}}}}]});_0("replacePreviousChar");_0("compositionType");_0("compositionStart");_0("compositionEnd");_0("paste");_0("cut")});var dU,I3e=k(()=>{hP();qe();Bt();dU=class{constructor(e,t,i,o){this.configuration=e,this.viewModel=t,this.userInputEvents=i,this.commandDelegate=o}paste(e,t,i,o){this.commandDelegate.paste(e,t,i,o)}type(e){this.commandDelegate.type(e)}compositionType(e,t,i,o){this.commandDelegate.compositionType(e,t,i,o)}compositionStart(){this.commandDelegate.startComposition()}compositionEnd(){this.commandDelegate.endComposition()}cut(){this.commandDelegate.cut()}setSelection(e){_s.SetSelection.runCoreEditorCommand(this.viewModel,{source:"keyboard",selection:e})}_validateViewColumn(e){let t=this.viewModel.getLineMinColumn(e.lineNumber);return e.column=4?this._selectAll():e.mouseDownCount===3?this._hasMulticursorModifier(e)?e.inSelectionMode?this._lastCursorLineSelectDrag(e.position,e.revealType):this._lastCursorLineSelect(e.position,e.revealType):e.inSelectionMode?this._lineSelectDrag(e.position,e.revealType):this._lineSelect(e.position,e.revealType):e.mouseDownCount===2?e.onInjectedText||(this._hasMulticursorModifier(e)?this._lastCursorWordSelect(e.position,e.revealType):e.inSelectionMode?this._wordSelectDrag(e.position,e.revealType):this._wordSelect(e.position,e.revealType)):this._hasMulticursorModifier(e)?this._hasNonMulticursorModifier(e)||(e.shiftKey?this._columnSelect(e.position,e.mouseColumn,!0):e.inSelectionMode?this._lastCursorMoveToSelect(e.position,e.revealType):this._createCursor(e.position,!1)):e.inSelectionMode?e.altKey?this._columnSelect(e.position,e.mouseColumn,!0):o?this._columnSelect(e.position,e.mouseColumn,!0):this._moveToSelect(e.position,e.revealType):this.moveTo(e.position,e.revealType)}_usualArgs(e,t){return e=this._validateViewColumn(e),{source:"mouse",position:this._convertViewToModelPosition(e),viewPosition:e,revealType:t}}moveTo(e,t){_s.MoveTo.runCoreEditorCommand(this.viewModel,this._usualArgs(e,t))}_moveToSelect(e,t){_s.MoveToSelect.runCoreEditorCommand(this.viewModel,this._usualArgs(e,t))}_columnSelect(e,t,i){e=this._validateViewColumn(e),_s.ColumnSelect.runCoreEditorCommand(this.viewModel,{source:"mouse",position:this._convertViewToModelPosition(e),viewPosition:e,mouseColumn:t,doColumnSelect:i})}_createCursor(e,t){e=this._validateViewColumn(e),_s.CreateCursor.runCoreEditorCommand(this.viewModel,{source:"mouse",position:this._convertViewToModelPosition(e),viewPosition:e,wholeLine:t})}_lastCursorMoveToSelect(e,t){_s.LastCursorMoveToSelect.runCoreEditorCommand(this.viewModel,this._usualArgs(e,t))}_wordSelect(e,t){_s.WordSelect.runCoreEditorCommand(this.viewModel,this._usualArgs(e,t))}_wordSelectDrag(e,t){_s.WordSelectDrag.runCoreEditorCommand(this.viewModel,this._usualArgs(e,t))}_lastCursorWordSelect(e,t){_s.LastCursorWordSelect.runCoreEditorCommand(this.viewModel,this._usualArgs(e,t))}_lineSelect(e,t){_s.LineSelect.runCoreEditorCommand(this.viewModel,this._usualArgs(e,t))}_lineSelectDrag(e,t){_s.LineSelectDrag.runCoreEditorCommand(this.viewModel,this._usualArgs(e,t))}_lastCursorLineSelect(e,t){_s.LastCursorLineSelect.runCoreEditorCommand(this.viewModel,this._usualArgs(e,t))}_lastCursorLineSelectDrag(e,t){_s.LastCursorLineSelectDrag.runCoreEditorCommand(this.viewModel,this._usualArgs(e,t))}_selectAll(){_s.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)}}});var fP,BE,khe,uU=k(()=>{Kr();Rm();je();Y_();fP=class{constructor(e){this._lineFactory=e,this._set(1,[])}flush(){this._set(1,[])}_set(e,t){this._lines=t,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){let t=e-this._rendLineNumberStart;if(t<0||t>=this._lines.length)throw new Nt("Illegal value for lineNumber");return this._lines[t]}onLinesDeleted(e,t){if(this.getCount()===0)return null;let i=this.getStartLineNumber(),o=this.getEndLineNumber();if(to)return null;let r=0,s=0;for(let l=i;l<=o;l++){let c=l-this._rendLineNumberStart;e<=l&&l<=t&&(s===0?(r=c,s=1):s++)}if(e=o&&a<=r&&(this._lines[a-this._rendLineNumberStart].onContentChanged(),s=!0);return s}onLinesInserted(e,t){if(this.getCount()===0)return null;let i=t-e+1,o=this.getStartLineNumber(),r=this.getEndLineNumber();if(e<=o)return this._rendLineNumberStart+=i,null;if(e>r)return null;if(i+e>r)return this._lines.splice(e-this._rendLineNumberStart,r-e+1);let s=[];for(let u=0;ui)continue;let l=Math.max(t,a.fromLineNumber),c=Math.min(i,a.toLineNumber);for(let d=l;d<=c;d++){let u=d-this._rendLineNumberStart;this._lines[u].onTokensChanged(),o=!0}}return o}},BE=class{constructor(e){this._lineFactory=e,this.domNode=this._createDomNode(),this._linesCollection=new fP(this._lineFactory)}_createDomNode(){let e=Pt(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(146)}onFlushed(e){return this._linesCollection.flush(),!0}onLinesChanged(e){return this._linesCollection.onLinesChanged(e.fromLineNumber,e.count)}onLinesDeleted(e){let t=this._linesCollection.onLinesDeleted(e.fromLineNumber,e.toLineNumber);if(t)for(let i=0,o=t.length;ie})}constructor(e,t,i){this._domNode=e,this._lineFactory=t,this._viewportData=i}render(e,t,i,o){let r={rendLineNumberStart:e.rendLineNumberStart,lines:e.lines.slice(0),linesLength:e.linesLength};if(r.rendLineNumberStart+r.linesLength-1t){let s=t,a=Math.min(i,r.rendLineNumberStart-1);s<=a&&(this._insertLinesBefore(r,s,a,o,t),r.linesLength+=a-s+1)}else if(r.rendLineNumberStart0&&(this._removeLinesBefore(r,s),r.linesLength-=s)}if(r.rendLineNumberStart=t,r.rendLineNumberStart+r.linesLength-1i){let s=Math.max(0,i-r.rendLineNumberStart+1),l=r.linesLength-1-s+1;l>0&&(this._removeLinesAfter(r,l),r.linesLength-=l)}return this._finishRendering(r,!1,o),r}_renderUntouchedLines(e,t,i,o,r){let s=e.rendLineNumberStart,a=e.lines;for(let l=t;l<=i;l++){let c=s+l;a[l].layoutLine(c,o[c-r],this._viewportData.lineHeight)}}_insertLinesBefore(e,t,i,o,r){let s=[],a=0;for(let l=t;l<=i;l++)s[a++]=this._lineFactory.createLine();e.lines=s.concat(e.lines)}_removeLinesBefore(e,t){for(let i=0;i=0;a--){let l=e.lines[a];o[a]&&(l.setDomNode(s),s=s.previousSibling)}}_finishRenderingInvalidLines(e,t,i){let o=document.createElement("div");n._ttPolicy&&(t=n._ttPolicy.createHTML(t)),o.innerHTML=t;for(let r=0;r{Kr();bu();uU();Wl();hU=class extends wo{constructor(e){super(e),this._dynamicOverlays=[],this._isFocused=!1,this._visibleLines=new BE({createLine:()=>new Lhe(this._dynamicOverlays)}),this.domNode=this._visibleLines.domNode;let i=this._context.configuration.options.get(50);Kn(this.domNode,i),this.domNode.setClassName("view-overlays")}shouldRender(){if(super.shouldRender())return!0;for(let e=0,t=this._dynamicOverlays.length;ei.shouldRender());for(let i=0,o=t.length;i'),r.appendString(s),r.appendString(""),!0)}layoutLine(e,t,i){this._domNode&&(this._domNode.setTop(t),this._domNode.setHeight(i))}},fU=class extends hU{constructor(e){super(e);let i=this._context.configuration.options.get(146);this._contentWidth=i.contentWidth,this.domNode.setHeight(0)}onConfigurationChanged(e){let i=this._context.configuration.options.get(146);return this._contentWidth=i.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))}},pU=class extends hU{constructor(e){super(e);let t=this._context.configuration.options,i=t.get(146);this._contentLeft=i.contentLeft,this.domNode.setClassName("margin-view-overlays"),this.domNode.setWidth(1),Kn(this.domNode,t.get(50))}onConfigurationChanged(e){let t=this._context.configuration.options;Kn(this.domNode,t.get(50));let i=t.get(146);return this._contentLeft=i.contentLeft,super.onConfigurationChanged(e)||!0}onScrollChanged(e){return super.onScrollChanged(e)||e.scrollHeightChanged}_viewOverlaysRender(e){super._viewOverlaysRender(e);let t=Math.min(e.scrollHeight,1e6);this.domNode.setHeight(t),this.domNode.setWidth(this._contentLeft)}}});var WE,Ihe=k(()=>{qe();WE=class n{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){this.onKeyDown?.(e)}emitKeyUp(e){this.onKeyUp?.(e)}emitContextMenu(e){this.onContextMenu?.(this._convertViewToModelMouseEvent(e))}emitMouseMove(e){this.onMouseMove?.(this._convertViewToModelMouseEvent(e))}emitMouseLeave(e){this.onMouseLeave?.(this._convertViewToModelMouseEvent(e))}emitMouseDown(e){this.onMouseDown?.(this._convertViewToModelMouseEvent(e))}emitMouseUp(e){this.onMouseUp?.(this._convertViewToModelMouseEvent(e))}emitMouseDrag(e){this.onMouseDrag?.(this._convertViewToModelMouseEvent(e))}emitMouseDrop(e){this.onMouseDrop?.(this._convertViewToModelMouseEvent(e))}emitMouseDropCanceled(){this.onMouseDropCanceled?.()}emitMouseWheel(e){this.onMouseWheel?.(e)}_convertViewToModelMouseEvent(e){return e.target?{event:e.event,target:this._convertViewToModelMouseTarget(e.target)}:e}_convertViewToModelMouseTarget(e){return n.convertViewToModelMouseTarget(e,this._coordinatesConverter)}static convertViewToModelMouseTarget(e,t){let i={...e};return i.position&&(i.position=t.convertViewPositionToModelPosition(i.position)),i.range&&(i.range=t.convertViewRangeToModelRange(i.range)),(i.type===5||i.type===8)&&(i.detail=this.convertViewToModelViewZoneData(i.detail,t)),i}static convertViewToModelViewZoneData(e,t){return{viewZoneId:e.viewZoneId,positionBefore:e.positionBefore?t.convertViewPositionToModelPosition(e.positionBefore):e.positionBefore,positionAfter:e.positionAfter?t.convertViewPositionToModelPosition(e.positionAfter):e.positionAfter,position:t.convertViewPositionToModelPosition(e.position),afterLineNumber:t.convertViewPositionToModelPosition(new P(e.afterLineNumber,1)).lineNumber}}}});var T3e=k(()=>{});var mU,D3e=k(()=>{Kr();T3e();Wl();mU=class extends wo{constructor(e){super(e),this.blocks=[],this.contentWidth=-1,this.contentLeft=0,this.domNode=Pt(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,i=this._context.configuration.options.get(146),o=i.contentWidth-i.verticalScrollbarWidth;this.contentWidth!==o&&(this.contentWidth=o,e=!0);let r=i.contentLeft;return this.contentLeft!==r&&(this.contentLeft=r,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 t=0,i=e.getDecorationsInViewport();for(let o of i){if(!o.options.blockClassName)continue;let r=this.blocks[t];r||(r=this.blocks[t]=Pt(document.createElement("div")),this.domNode.appendChild(r));let s,a;o.options.blockIsAfterEnd?(s=e.getVerticalOffsetAfterLineNumber(o.range.endLineNumber,!1),a=e.getVerticalOffsetAfterLineNumber(o.range.endLineNumber,!0)):(s=e.getVerticalOffsetForLineNumber(o.range.startLineNumber,!0),a=o.range.isEmpty()&&!o.options.blockDoesNotCollapse?e.getVerticalOffsetForLineNumber(o.range.startLineNumber,!1):e.getVerticalOffsetAfterLineNumber(o.range.endLineNumber,!0));let[l,c,d,u]=o.options.blockPadding??[0,0,0,0];r.setClassName("blockDecorations-block "+o.options.blockClassName),r.setLeft(this.contentLeft-u),r.setWidth(this.contentWidth+u+c),r.setTop(s-e.scrollTop-l),r.setHeight(a-s+l+d),t++}for(let o=t;o{ke();Kr();Wl();gU=class extends wo{constructor(e,t){super(e),this._viewDomNode=t,this._widgets={},this.domNode=Pt(document.createElement("div")),na.write(this.domNode,1),this.domNode.setClassName("contentWidgets"),this.domNode.setPosition("absolute"),this.domNode.setTop(0),this.overflowingContentWidgetsDomNode=Pt(document.createElement("div")),na.write(this.overflowingContentWidgetsDomNode,2),this.overflowingContentWidgetsDomNode.setClassName("overflowingContentWidgets")}dispose(){super.dispose(),this._widgets={}}onConfigurationChanged(e){let t=Object.keys(this._widgets);for(let i of t)this._widgets[i].onConfigurationChanged(e);return!0}onDecorationsChanged(e){return!0}onFlushed(e){return!0}onLineMappingChanged(e){return this._updateAnchorsViewPositions(),!0}onLinesChanged(e){return this._updateAnchorsViewPositions(),!0}onLinesDeleted(e){return this._updateAnchorsViewPositions(),!0}onLinesInserted(e){return this._updateAnchorsViewPositions(),!0}onScrollChanged(e){return!0}onZonesChanged(e){return!0}_updateAnchorsViewPositions(){let e=Object.keys(this._widgets);for(let t of e)this._widgets[t].updateAnchorViewPosition()}addWidget(e){let t=new The(this._context,this._viewDomNode,e);this._widgets[t.id]=t,t.allowEditorOverflow?this.overflowingContentWidgetsDomNode.appendChild(t.domNode):this.domNode.appendChild(t.domNode),this.setShouldRender()}setWidgetPosition(e,t,i,o,r){this._widgets[e.getId()].setPosition(t,i,o,r),this.setShouldRender()}removeWidget(e){let t=e.getId();if(this._widgets.hasOwnProperty(t)){let i=this._widgets[t];delete this._widgets[t];let o=i.domNode.domNode;o.remove(),o.removeAttribute("monaco-visible-content-widget"),this.setShouldRender()}}shouldSuppressMouseDownOnWidget(e){return this._widgets.hasOwnProperty(e)?this._widgets[e].suppressMouseDown:!1}onBeforeRender(e){let t=Object.keys(this._widgets);for(let i of t)this._widgets[i].onBeforeRender(e)}prepareRender(e){let t=Object.keys(this._widgets);for(let i of t)this._widgets[i].prepareRender(e)}render(e){let t=Object.keys(this._widgets);for(let i of t)this._widgets[i].render(e)}},The=class{constructor(e,t,i){this._primaryAnchor=new b0(null,null),this._secondaryAnchor=new b0(null,null),this._context=e,this._viewDomNode=t,this._actual=i,this.domNode=Pt(this._actual.getDomNode()),this.id=this._actual.getId(),this.allowEditorOverflow=this._actual.allowEditorOverflow||!1,this.suppressMouseDown=this._actual.suppressMouseDown||!1;let o=this._context.configuration.options,r=o.get(146);this._fixedOverflowWidgets=o.get(42),this._contentWidth=r.contentWidth,this._contentLeft=r.contentLeft,this._lineHeight=o.get(67),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){let t=this._context.configuration.options;if(this._lineHeight=t.get(67),e.hasChanged(146)){let i=t.get(146);this._contentLeft=i.contentLeft,this._contentWidth=i.contentWidth,this._maxWidth=this._getMaxWidth()}}updateAnchorViewPosition(){this._setPosition(this._affinity,this._primaryAnchor.modelPosition,this._secondaryAnchor.modelPosition)}_setPosition(e,t,i){this._affinity=e,this._primaryAnchor=o(t,this._context.viewModel,this._affinity),this._secondaryAnchor=o(i,this._context.viewModel,this._affinity);function o(r,s,a){if(!r)return new b0(null,null);let l=s.model.validatePosition(r);if(s.coordinatesConverter.modelPositionIsVisible(l)){let c=s.coordinatesConverter.convertModelPositionToViewPosition(l,a??void 0);return new b0(r,c)}return new b0(r,null)}}_getMaxWidth(){let e=this.domNode.domNode.ownerDocument,t=e.defaultView;return this.allowEditorOverflow?t?.innerWidth||e.documentElement.offsetWidth||e.body.offsetWidth:this._contentWidth}setPosition(e,t,i,o){this._setPosition(o,e,t),this._preference=i,this._primaryAnchor.viewPosition&&this._preference&&this._preference.length>0?this.domNode.setDisplay("block"):this.domNode.setDisplay("none"),this._cachedDomNodeOffsetWidth=-1,this._cachedDomNodeOffsetHeight=-1}_layoutBoxInViewport(e,t,i,o){let r=e.top,s=r,a=e.top+e.height,l=o.viewportHeight-a,c=r-i,d=s>=i,u=a,h=l>=i,f=e.left;return f+t>o.scrollLeft+o.viewportWidth&&(f=o.scrollLeft+o.viewportWidth-t),fl){let h=u-(l-o);u-=h,i-=h}if(u=g,v=u+i<=h.height-_;return this._fixedOverflowWidgets?{fitsAbove:b,aboveTop:Math.max(d,g),fitsBelow:v,belowTop:u,left:p}:{fitsAbove:b,aboveTop:r,fitsBelow:v,belowTop:s,left:f}}_prepareRenderWidgetAtExactPositionOverflowing(e){return new v0(e.top,e.left+this._contentLeft)}_getAnchorsCoordinates(e){let t=r(this._primaryAnchor.viewPosition,this._affinity,this._lineHeight),i=this._secondaryAnchor.viewPosition?.lineNumber===this._primaryAnchor.viewPosition?.lineNumber?this._secondaryAnchor.viewPosition:null,o=r(i,this._affinity,this._lineHeight);return{primary:t,secondary:o};function r(s,a,l){if(!s)return null;let c=e.visibleRangeForPosition(s);if(!c)return null;let d=s.column===1&&a===3?0:c.left,u=e.getVerticalOffsetForLineNumber(s.lineNumber)-e.scrollTop;return new _U(u,d,l)}}_reduceAnchorCoordinates(e,t,i){if(!t)return e;let o=this._context.configuration.options.get(50),r=t.left;return re.endLineNumber||this.domNode.setMaxWidth(this._maxWidth)}prepareRender(e){this._renderData=this._prepareRenderWidget(e)}render(e){if(!this._renderData||this._renderData.kind==="offViewport"){this._isVisible&&(this.domNode.removeAttribute("monaco-visible-content-widget"),this._isVisible=!1,this._renderData?.kind==="offViewport"&&this._renderData.preserveFocus?this.domNode.setTop(-1e3):this.domNode.setVisibility("hidden")),typeof this._actual.afterRender=="function"&&Ehe(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"&&Ehe(this._actual.afterRender,this._actual,this._renderData.position)}},b0=class{constructor(e,t){this.modelPosition=e,this.viewPosition=t}},v0=class{constructor(e,t){this.top=e,this.left=t,this._coordinateBrand=void 0}},_U=class{constructor(e,t,i){this.top=e,this.left=t,this.height=i,this._anchorCoordinateBrand=void 0}}});var R3e=k(()=>{});var bU,vU,xU,A3e=k(()=>{R3e();Aw();Nu();at();Yi();Ui();wf();qe();bU=class extends nd{constructor(e){super(),this._context=e;let t=this._context.configuration.options,i=t.get(146);this._renderLineHighlight=t.get(97),this._renderLineHighlightOnlyWhenFocus=t.get(98),this._wordWrap=i.isViewportWrapping,this._contentLeft=i.contentLeft,this._contentWidth=i.contentWidth,this._selectionIsEmpty=!0,this._focused=!1,this._cursorLineNumbers=[1],this._selections=[new Se(1,1,1,1)],this._renderData=null,this._context.addEventHandler(this)}dispose(){this._context.removeEventHandler(this),super.dispose()}_readFromSelections(){let e=!1,t=new Set;for(let r of this._selections)t.add(r.positionLineNumber);let i=Array.from(t);i.sort((r,s)=>r-s),oi(this._cursorLineNumbers,i)||(this._cursorLineNumbers=i,e=!0);let o=this._selections.every(r=>r.isEmpty());return this._selectionIsEmpty!==o&&(this._selectionIsEmpty=o,e=!0),e}onThemeChanged(e){return this._readFromSelections()}onConfigurationChanged(e){let t=this._context.configuration.options,i=t.get(146);return this._renderLineHighlight=t.get(97),this._renderLineHighlightOnlyWhenFocus=t.get(98),this._wordWrap=i.isViewportWrapping,this._contentLeft=i.contentLeft,this._contentWidth=i.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}let t=e.visibleRange.startLineNumber,i=e.visibleRange.endLineNumber,o=[];for(let s=t;s<=i;s++){let a=s-t;o[a]=""}if(this._wordWrap){let s=this._renderOne(e,!1);for(let a of this._cursorLineNumbers){let l=this._context.viewModel.coordinatesConverter,c=l.convertViewPositionToModelPosition(new P(a,1)).lineNumber,d=l.convertModelPositionToViewPosition(new P(c,1)).lineNumber,u=l.convertModelPositionToViewPosition(new P(c,this._context.viewModel.model.getLineMaxColumn(c))).lineNumber,h=Math.max(d,t),f=Math.min(u,i);for(let p=h;p<=f;p++){let g=p-t;o[g]=s}}}let r=this._renderOne(e,!0);for(let s of this._cursorLineNumbers){if(si)continue;let a=s-t;o[a]=r}this._renderData=o}render(e,t){if(!this._renderData)return"";let i=t-e;return i>=this._renderData.length?"":this._renderData[i]}_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)}},vU=class extends bU{_renderOne(e,t){return`
    `}_shouldRenderThis(){return this._shouldRenderInContent()}_shouldRenderOther(){return this._shouldRenderInMargin()}},xU=class extends bU{_renderOne(e,t){return`
    `}_shouldRenderThis(){return!0}_shouldRenderOther(){return this._shouldRenderInContent()}};wr((n,e)=>{let t=n.getColor(_le);if(t&&(e.addRule(`.monaco-editor .view-overlays .current-line { background-color: ${t}; }`),e.addRule(`.monaco-editor .margin-view-overlays .current-line-margin { background-color: ${t}; border: none; }`)),!t||t.isTransparent()||n.defines(ble)){let i=n.getColor(ble);i&&(e.addRule(`.monaco-editor .view-overlays .current-line-exact { border: 2px solid ${i}; }`),e.addRule(`.monaco-editor .margin-view-overlays .current-line-exact-margin { border: 2px solid ${i}; }`),nl(n.type)&&(e.addRule(".monaco-editor .view-overlays .current-line-exact { border-width: 1px; }"),e.addRule(".monaco-editor .margin-view-overlays .current-line-exact-margin { border-width: 1px; }")))}})});var M3e=k(()=>{});var wU,P3e=k(()=>{M3e();Aw();CE();we();wU=class extends nd{constructor(e){super(),this._context=e;let t=this._context.configuration.options;this._typicalHalfwidthCharacterWidth=t.get(50).typicalHalfwidthCharacterWidth,this._renderResult=null,this._context.addEventHandler(this)}dispose(){this._context.removeEventHandler(this),this._renderResult=null,super.dispose()}onConfigurationChanged(e){let t=this._context.configuration.options;return this._typicalHalfwidthCharacterWidth=t.get(50).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){let t=e.getDecorationsInViewport(),i=[],o=0;for(let l=0,c=t.length;l{if(l.options.zIndexc.options.zIndex)return 1;let d=l.options.className,u=c.options.className;return du?1:S.compareRangesUsingStarts(l.range,c.range)});let r=e.visibleRange.startLineNumber,s=e.visibleRange.endLineNumber,a=[];for(let l=r;l<=s;l++){let c=l-r;a[c]=""}this._renderWholeLineDecorations(e,i,a),this._renderNormalDecorations(e,i,a),this._renderResult=a}_renderWholeLineDecorations(e,t,i){let o=e.visibleRange.startLineNumber,r=e.visibleRange.endLineNumber;for(let s=0,a=t.length;s',d=Math.max(l.range.startLineNumber,o),u=Math.min(l.range.endLineNumber,r);for(let h=d;h<=u;h++){let f=h-o;i[f]+=c}}}_renderNormalDecorations(e,t,i){let o=e.visibleRange.startLineNumber,r=null,s=!1,a=null,l=!1;for(let c=0,d=t.length;c';a[h]+=b}}}render(e,t){if(!this._renderResult)return"";let i=t-e;return i<0||i>=this._renderResult.length?"":this._renderResult[i]}}});var yU,O3e=k(()=>{ke();Kr();Eh();Wl();Yi();yU=class extends wo{constructor(e,t,i,o){super(e);let r=this._context.configuration.options,s=r.get(104),a=r.get(75),l=r.get(40),c=r.get(107),d={listenOnDomNode:i.domNode,className:"editor-scrollable "+UA(e.theme.type),useShadows:!1,lazyRender:!0,vertical:s.vertical,horizontal:s.horizontal,verticalHasArrows:s.verticalHasArrows,horizontalHasArrows:s.horizontalHasArrows,verticalScrollbarSize:s.verticalScrollbarSize,verticalSliderSize:s.verticalSliderSize,horizontalScrollbarSize:s.horizontalScrollbarSize,horizontalSliderSize:s.horizontalSliderSize,handleMouseWheel:s.handleMouseWheel,alwaysConsumeMouseWheel:s.alwaysConsumeMouseWheel,arrowSize:s.arrowSize,mouseWheelScrollSensitivity:a,fastScrollSensitivity:l,scrollPredominantAxis:c,scrollByPage:s.scrollByPage};this.scrollbar=this._register(new Ym(t.domNode,d,this._context.viewLayout.getScrollable())),na.write(this.scrollbar.getDomNode(),6),this.scrollbarDomNode=Pt(this.scrollbar.getDomNode()),this.scrollbarDomNode.setPosition("absolute"),this._setLayout();let u=(h,f,p)=>{let g={};if(f){let _=h.scrollTop;_&&(g.scrollTop=this._context.viewLayout.getCurrentScrollTop()+_,h.scrollTop=0)}if(p){let _=h.scrollLeft;_&&(g.scrollLeft=this._context.viewLayout.getCurrentScrollLeft()+_,h.scrollLeft=0)}this._context.viewModel.viewLayout.setScrollPosition(g,1)};this._register(U(i.domNode,"scroll",h=>u(i.domNode,!0,!0))),this._register(U(t.domNode,"scroll",h=>u(t.domNode,!0,!1))),this._register(U(o.domNode,"scroll",h=>u(o.domNode,!0,!1))),this._register(U(this.scrollbarDomNode.domNode,"scroll",h=>u(this.scrollbarDomNode.domNode,!0,!1)))}dispose(){super.dispose()}_setLayout(){let e=this._context.configuration.options,t=e.get(146);this.scrollbarDomNode.setLeft(t.contentLeft),e.get(73).side==="right"?this.scrollbarDomNode.setWidth(t.contentWidth+t.minimap.minimapWidth):this.scrollbarDomNode.setWidth(t.contentWidth),this.scrollbarDomNode.setHeight(t.height)}getOverviewRulerLayoutInfo(){return this.scrollbar.getOverviewRulerLayoutInfo()}getDomNode(){return this.scrollbarDomNode}delegateVerticalScrollbarPointerDown(e){this.scrollbar.delegateVerticalScrollbarPointerDown(e)}delegateScrollFromMouseWheelEvent(e){this.scrollbar.delegateScrollFromMouseWheelEvent(e)}onConfigurationChanged(e){if(e.hasChanged(104)||e.hasChanged(75)||e.hasChanged(40)){let t=this._context.configuration.options,i=t.get(104),o=t.get(75),r=t.get(40),s=t.get(107),a={vertical:i.vertical,horizontal:i.horizontal,verticalScrollbarSize:i.verticalScrollbarSize,horizontalScrollbarSize:i.horizontalScrollbarSize,scrollByPage:i.scrollByPage,handleMouseWheel:i.handleMouseWheel,mouseWheelScrollSensitivity:o,fastScrollSensitivity:r,scrollPredominantAxis:s};this.scrollbar.updateOptions(a)}return e.hasChanged(146)&&this._setLayout(),!0}onScrollChanged(e){return!0}onThemeChanged(e){return this.scrollbar.updateClassName("editor-scrollable "+UA(this._context.theme.type)),!0}prepareRender(e){}render(e){this.scrollbar.renderNow()}}});var F3e=k(()=>{});var x0,Dhe,Nhe,HE,CU,Rhe,Ahe,Mhe,SU=k(()=>{Kr();at();F3e();Aw();Wl();qe();we();Zr();x0=class{constructor(e,t,i,o,r){this.startLineNumber=e,this.endLineNumber=t,this.className=i,this.tooltip=o,this._decorationToRenderBrand=void 0,this.zIndex=r??0}},Dhe=class{constructor(e,t,i){this.className=e,this.zIndex=t,this.tooltip=i}},Nhe=class{constructor(){this.decorations=[]}add(e){this.decorations.push(e)}getDecorations(){return this.decorations}},HE=class extends nd{_render(e,t,i){let o=[];for(let a=e;a<=t;a++){let l=a-e;o[l]=new Nhe}if(i.length===0)return o;i.sort((a,l)=>a.className===l.className?a.startLineNumber===l.startLineNumber?a.endLineNumber-l.endLineNumber:a.startLineNumber-l.startLineNumber:a.classNameo)continue;let c=Math.max(a,i),d=this._context.viewModel.coordinatesConverter.convertViewPositionToModelPosition(new P(c,0)),u=this._context.viewModel.glyphLanes.getLanesAtLine(d.lineNumber).indexOf(r.preference.lane);t.push(new Ahe(c,u,r.preference.zIndex,r))}}_collectSortedGlyphRenderRequests(e){let t=[];return this._collectDecorationBasedGlyphRenderRequest(e,t),this._collectWidgetBasedGlyphRenderRequest(e,t),t.sort((i,o)=>i.lineNumber===o.lineNumber?i.laneIndex===o.laneIndex?i.zIndex===o.zIndex?o.type===i.type?i.type===0&&o.type===0?i.className0;){let o=t.peek();if(!o)break;let r=t.takeWhile(a=>a.lineNumber===o.lineNumber&&a.laneIndex===o.laneIndex);if(!r||r.length===0)break;let s=r[0];if(s.type===0){let a=[];for(let l of r){if(l.zIndex!==s.zIndex||l.type!==s.type)break;(a.length===0||a[a.length-1]!==l.className)&&a.push(l.className)}i.push(s.accept(a.join(" ")))}else s.widget.renderInfo={lineNumber:s.lineNumber,laneIndex:s.laneIndex}}this._decorationGlyphsToRender=i}render(e){if(!this._glyphMargin){for(let i of Object.values(this._widgets))i.domNode.setDisplay("none");for(;this._managedDomNodes.length>0;)this._managedDomNodes.pop()?.domNode.remove();return}let t=Math.round(this._glyphMarginWidth/this._glyphMarginDecorationLaneCount);for(let i of Object.values(this._widgets))if(!i.renderInfo)i.domNode.setDisplay("none");else{let o=e.viewportData.relativeVerticalOffset[i.renderInfo.lineNumber-e.viewportData.startLineNumber],r=this._glyphMarginLeft+i.renderInfo.laneIndex*this._lineHeight;i.domNode.setDisplay("block"),i.domNode.setTop(o),i.domNode.setLeft(r),i.domNode.setWidth(t),i.domNode.setHeight(this._lineHeight)}for(let i=0;ithis._decorationGlyphsToRender.length;)this._managedDomNodes.pop()?.domNode.remove()}},Rhe=class{constructor(e,t,i,o){this.lineNumber=e,this.laneIndex=t,this.zIndex=i,this.className=o,this.type=0}accept(e){return new Mhe(this.lineNumber,this.laneIndex,e)}},Ahe=class{constructor(e,t,i,o){this.lineNumber=e,this.laneIndex=t,this.zIndex=i,this.widget=o,this.type=1}},Mhe=class{constructor(e,t,i){this.lineNumber=e,this.laneIndex=t,this.combinedClassName=i}}});var B3e=k(()=>{});function zE(n){if(!(n&&n.isTransparent()))return n}var kU,W3e=k(()=>{B3e();Aw();Nu();Yi();qe();at();yi();qle();rH();kU=class extends nd{constructor(e){super(),this._context=e,this._primaryPosition=null;let t=this._context.configuration.options,i=t.get(147),o=t.get(50);this._spaceWidth=o.spaceWidth,this._maxIndentLeft=i.wrappingColumn===-1?-1:i.wrappingColumn*o.typicalHalfwidthCharacterWidth,this._bracketPairGuideOptions=t.get(16),this._renderResult=null,this._context.addEventHandler(this)}dispose(){this._context.removeEventHandler(this),this._renderResult=null,super.dispose()}onConfigurationChanged(e){let t=this._context.configuration.options,i=t.get(147),o=t.get(50);return this._spaceWidth=o.spaceWidth,this._maxIndentLeft=i.wrappingColumn===-1?-1:i.wrappingColumn*o.typicalHalfwidthCharacterWidth,this._bracketPairGuideOptions=t.get(16),!0}onCursorStateChanged(e){let i=e.selections[0].getPosition();return this._primaryPosition?.equals(i)?!1:(this._primaryPosition=i,!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){if(!this._bracketPairGuideOptions.indentation&&this._bracketPairGuideOptions.bracketPairs===!1){this._renderResult=null;return}let t=e.visibleRange.startLineNumber,i=e.visibleRange.endLineNumber,o=e.scrollWidth,r=this._primaryPosition,s=this.getGuidesByLine(t,Math.min(i+1,this._context.viewModel.getLineCount()),r),a=[];for(let l=t;l<=i;l++){let c=l-t,d=s[c],u="",h=e.visibleRangeForPosition(new P(l,1))?.left??0;for(let f of d){let p=f.column===-1?h+(f.visibleColumn-1)*this._spaceWidth:e.visibleRangeForPosition(new P(l,f.column)).left;if(p>o||this._maxIndentLeft>0&&p>this._maxIndentLeft)break;let g=f.horizontalLine?f.horizontalLine.top?"horizontal-top":"horizontal-bottom":"vertical",_=f.horizontalLine?(e.visibleRangeForPosition(new P(l,f.horizontalLine.endColumn))?.left??p+this._spaceWidth)-p:this._spaceWidth;u+=`
    `}a[c]=u}this._renderResult=a}getGuidesByLine(e,t,i){let o=this._bracketPairGuideOptions.bracketPairs!==!1?this._context.viewModel.getBracketGuidesInRangeByLine(e,t,i,{highlightActive:this._bracketPairGuideOptions.highlightActiveBracketPair,horizontalGuides:this._bracketPairGuideOptions.bracketPairsHorizontal===!0?kb.Enabled:this._bracketPairGuideOptions.bracketPairsHorizontal==="active"?kb.EnabledForActive:kb.Disabled,includeInactive:this._bracketPairGuideOptions.bracketPairs===!0}):null,r=this._bracketPairGuideOptions.indentation?this._context.viewModel.getLinesIndentGuides(e,t):null,s=0,a=0,l=0;if(this._bracketPairGuideOptions.highlightActiveIndentation!==!1&&i){let u=this._context.viewModel.getActiveIndentGuide(i.lineNumber,e,t);s=u.startLineNumber,a=u.endLineNumber,l=u.indent}let{indentSize:c}=this._context.viewModel.model.getOptions(),d=[];for(let u=e;u<=t;u++){let h=new Array;d.push(h);let f=o?o[u-e]:[],p=new wl(f),g=r?r[u-e]:0;for(let _=1;_<=g;_++){let b=(_-1)*c+1,v=(this._bracketPairGuideOptions.highlightActiveIndentation==="always"||f.length===0)&&s<=u&&u<=a&&_===l;h.push(...p.takeWhile(w=>w.visibleColumn!0)||[])}return d}render(e,t){if(!this._renderResult)return"";let i=t-e;return i<0||i>=this._renderResult.length?"":this._renderResult[i]}};wr((n,e)=>{let t=[{bracketColor:AW,guideColor:qOe,guideColorActive:QOe},{bracketColor:MW,guideColor:KOe,guideColorActive:JOe},{bracketColor:PW,guideColor:GOe,guideColorActive:e4e},{bracketColor:OW,guideColor:YOe,guideColorActive:t4e},{bracketColor:FW,guideColor:ZOe,guideColorActive:i4e},{bracketColor:BW,guideColor:XOe,guideColorActive:n4e}],i=new o2,o=[{indentColor:TC,indentColorActive:DC},{indentColor:IOe,indentColorActive:ROe},{indentColor:EOe,indentColorActive:AOe},{indentColor:TOe,indentColorActive:MOe},{indentColor:DOe,indentColorActive:POe},{indentColor:NOe,indentColorActive:OOe}],r=t.map(a=>{let l=n.getColor(a.bracketColor),c=n.getColor(a.guideColor),d=n.getColor(a.guideColorActive),u=zE(zE(c)??l?.transparent(.3)),h=zE(zE(d)??l);if(!(!u||!h))return{guideColor:u,guideColorActive:h}}).filter(xd),s=o.map(a=>{let l=n.getColor(a.indentColor),c=n.getColor(a.indentColorActive),d=zE(l),u=zE(c);if(!(!d||!u))return{indentColor:d,indentColorActive:u}}).filter(xd);if(r.length>0){for(let a=0;a<30;a++){let l=r[a%r.length];e.addRule(`.monaco-editor .${i.getInlineClassNameOfLevel(a).replace(/ /g,".")} { --guide-color: ${l.guideColor}; --guide-color-active: ${l.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.${i.activeClassName} { box-shadow: 1px 0 0 0 var(--guide-color-active) inset; }`),e.addRule(`.monaco-editor .horizontal-top.${i.activeClassName} { border-top: 1px solid var(--guide-color-active); }`),e.addRule(`.monaco-editor .horizontal-bottom.${i.activeClassName} { border-bottom: 1px solid var(--guide-color-active); }`)}if(s.length>0){for(let a=0;a<30;a++){let l=s[a%s.length];e.addRule(`.monaco-editor .lines-content .core-guide-indent.lvl-${a} { --indent-color: ${l.indentColor}; --indent-color-active: ${l.indentColorActive}; }`)}e.addRule(".monaco-editor .lines-content .core-guide-indent { box-shadow: 1px 0 0 0 var(--indent-color) inset; }"),e.addRule(".monaco-editor .lines-content .core-guide-indent.indent-active { box-shadow: 1px 0 0 0 var(--indent-color-active) inset; }")}})});var H3e=k(()=>{});var VE,z3e=k(()=>{VE=class{get didDomLayout(){return this._didDomLayout}readClientRect(){if(!this._clientRectRead){this._clientRectRead=!0;let e=this._domNode.getBoundingClientRect();this.markDidDomLayout(),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}constructor(e,t){this._domNode=e,this.endNode=t,this._didDomLayout=!1,this._clientRectDeltaLeft=0,this._clientRectScale=1,this._clientRectRead=!1}markDidDomLayout(){this._didDomLayout=!0}}});var Phe,Ohe,Fhe,LU,V3e=k(()=>{AV();ft();Bt();H3e();bu();CE();uU();Wl();z3e();kV();qe();we();Phe=class{constructor(){this._currentVisibleRange=new S(1,1,1,1)}getCurrentVisibleRange(){return this._currentVisibleRange}setCurrentVisibleRange(e){this._currentVisibleRange=e}},Ohe=class{constructor(e,t,i,o,r,s,a){this.minimalReveal=e,this.lineNumber=t,this.startColumn=i,this.endColumn=o,this.startScrollTop=r,this.stopScrollTop=s,this.scrollType=a,this.type="range",this.minLineNumber=t,this.maxLineNumber=t}},Fhe=class{constructor(e,t,i,o,r){this.minimalReveal=e,this.selections=t,this.startScrollTop=i,this.stopScrollTop=o,this.scrollType=r,this.type="selections";let s=t[0].startLineNumber,a=t[0].endLineNumber;for(let l=1,c=t.length;lnew Op(this._viewLineOptions)}),this.domNode=this._visibleLines.domNode,na.write(this.domNode,8),this.domNode.setClassName(`view-lines ${Wb}`),Kn(this.domNode,r),this._maxLineWidth=0,this._asyncUpdateLineWidths=new Lt(()=>{this._updateLineWidthsSlow()},200),this._asyncCheckMonospaceFontAssumptions=new Lt(()=>{this._checkMonospaceFontAssumptions()},2e3),this._lastRenderedData=new Phe,this._horizontalRevealRequest=null,this._stickyScrollEnabled=o.get(116).enabled,this._maxNumberStickyLines=o.get(116).maxLineCount}dispose(){this._asyncUpdateLineWidths.dispose(),this._asyncCheckMonospaceFontAssumptions.dispose(),super.dispose()}getDomNode(){return this.domNode}onConfigurationChanged(e){this._visibleLines.onConfigurationChanged(e),e.hasChanged(147)&&(this._maxLineWidth=0);let t=this._context.configuration.options,i=t.get(50),o=t.get(147);return this._lineHeight=t.get(67),this._typicalHalfwidthCharacterWidth=i.typicalHalfwidthCharacterWidth,this._isViewportWrapping=o.isViewportWrapping,this._revealHorizontalRightPadding=t.get(101),this._cursorSurroundingLines=t.get(29),this._cursorSurroundingLinesStyle=t.get(30),this._canUseLayerHinting=!t.get(32),this._stickyScrollEnabled=t.get(116).enabled,this._maxNumberStickyLines=t.get(116).maxLineCount,Kn(this.domNode,i),this._onOptionsMaybeChanged(),e.hasChanged(146)&&(this._maxLineWidth=0),!0}_onOptionsMaybeChanged(){let e=this._context.configuration,t=new nP(e,this._context.theme.type);if(!this._viewLineOptions.equals(t)){this._viewLineOptions=t;let i=this._visibleLines.getStartLineNumber(),o=this._visibleLines.getEndLineNumber();for(let r=i;r<=o;r++)this._visibleLines.getVisibleLine(r).onOptionsChanged(this._viewLineOptions);return!0}return!1}onCursorStateChanged(e){let t=this._visibleLines.getStartLineNumber(),i=this._visibleLines.getEndLineNumber(),o=!1;for(let r=t;r<=i;r++)o=this._visibleLines.getVisibleLine(r).onSelectionChanged()||o;return o}onDecorationsChanged(e){{let t=this._visibleLines.getStartLineNumber(),i=this._visibleLines.getEndLineNumber();for(let o=t;o<=i;o++)this._visibleLines.getVisibleLine(o).onDecorationsChanged()}return!0}onFlushed(e){let t=this._visibleLines.onFlushed(e);return this._maxLineWidth=0,t}onLinesChanged(e){return this._visibleLines.onLinesChanged(e)}onLinesDeleted(e){return this._visibleLines.onLinesDeleted(e)}onLinesInserted(e){return this._visibleLines.onLinesInserted(e)}onRevealRangeRequest(e){let t=this._computeScrollTopToRevealRange(this._context.viewLayout.getFutureViewport(),e.source,e.minimalReveal,e.range,e.selections,e.verticalType);if(t===-1)return!1;let i=this._context.viewLayout.validateScrollPosition({scrollTop:t});e.revealHorizontal?e.range&&e.range.startLineNumber!==e.range.endLineNumber?i={scrollTop:i.scrollTop,scrollLeft:0}:e.range?this._horizontalRevealRequest=new Ohe(e.minimalReveal,e.range.startLineNumber,e.range.startColumn,e.range.endColumn,this._context.viewLayout.getCurrentScrollTop(),i.scrollTop,e.scrollType):e.selections&&e.selections.length>0&&(this._horizontalRevealRequest=new Fhe(e.minimalReveal,e.selections,this._context.viewLayout.getCurrentScrollTop(),i.scrollTop,e.scrollType)):this._horizontalRevealRequest=null;let r=Math.abs(this._context.viewLayout.getCurrentScrollTop()-i.scrollTop)<=this._lineHeight?1:e.scrollType;return this._context.viewModel.viewLayout.setScrollPosition(i,r),!0}onScrollChanged(e){if(this._horizontalRevealRequest&&e.scrollLeftChanged&&(this._horizontalRevealRequest=null),this._horizontalRevealRequest&&e.scrollTopChanged){let t=Math.min(this._horizontalRevealRequest.startScrollTop,this._horizontalRevealRequest.stopScrollTop),i=Math.max(this._horizontalRevealRequest.startScrollTop,this._horizontalRevealRequest.stopScrollTop);(e.scrollTopi)&&(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,t){let i=this._getViewLineDomNode(e);if(i===null)return null;let o=this._getLineNumberFor(i);if(o===-1||o<1||o>this._context.viewModel.getLineCount())return null;if(this._context.viewModel.getLineMaxColumn(o)===1)return new P(o,1);let r=this._visibleLines.getStartLineNumber(),s=this._visibleLines.getEndLineNumber();if(os)return null;let a=this._visibleLines.getVisibleLine(o).getColumnOfNodeOffset(e,t),l=this._context.viewModel.getLineMinColumn(o);return ai)return-1;let o=new VE(this.domNode.domNode,this._textRangeRestingSpot),r=this._visibleLines.getVisibleLine(e).getWidth(o);return this._updateLineWidthsSlowIfDomDidLayout(o),r}linesVisibleRangesForRange(e,t){if(this.shouldRender())return null;let i=e.endLineNumber,o=S.intersectRanges(e,this._lastRenderedData.getCurrentVisibleRange());if(!o)return null;let r=[],s=0,a=new VE(this.domNode.domNode,this._textRangeRestingSpot),l=0;t&&(l=this._context.viewModel.coordinatesConverter.convertViewPositionToModelPosition(new P(o.startLineNumber,1)).lineNumber);let c=this._visibleLines.getStartLineNumber(),d=this._visibleLines.getEndLineNumber();for(let u=o.startLineNumber;u<=o.endLineNumber;u++){if(ud)continue;let h=u===o.startLineNumber?o.startColumn:1,f=u!==o.endLineNumber,p=f?this._context.viewModel.getLineMaxColumn(u):o.endColumn,g=this._visibleLines.getVisibleLine(u).getVisibleRangesForRange(u,h,p,a);if(g){if(t&&uthis._visibleLines.getEndLineNumber())return null;let o=new VE(this.domNode.domNode,this._textRangeRestingSpot),r=this._visibleLines.getVisibleLine(e).getVisibleRangesForRange(e,t,i,o);return this._updateLineWidthsSlowIfDomDidLayout(o),r}visibleRangeForPosition(e){let t=this._visibleRangesForLineRange(e.lineNumber,e.column,e.column);return t?new yV(t.outsideRenderedLine,t.ranges[0].left):null}_updateLineWidthsFast(){return this._updateLineWidths(!0)}_updateLineWidthsSlow(){this._updateLineWidths(!1)}_updateLineWidthsSlowIfDomDidLayout(e){e.didDomLayout&&(this._asyncUpdateLineWidths.isScheduled()||(this._asyncUpdateLineWidths.cancel(),this._updateLineWidthsSlow()))}_updateLineWidths(e){let t=this._visibleLines.getStartLineNumber(),i=this._visibleLines.getEndLineNumber(),o=1,r=!0;for(let s=t;s<=i;s++){let a=this._visibleLines.getVisibleLine(s);if(e&&!a.getWidthIsFast()){r=!1;continue}o=Math.max(o,a.getWidth(null))}return r&&t===1&&i===this._context.viewModel.getLineCount()&&(this._maxLineWidth=0),this._ensureMaxLineWidth(o),r}_checkMonospaceFontAssumptions(){let e=-1,t=-1,i=this._visibleLines.getStartLineNumber(),o=this._visibleLines.getEndLineNumber();for(let r=i;r<=o;r++){let s=this._visibleLines.getVisibleLine(r);if(s.needsMonospaceFontCheck()){let a=s.getWidth(null);a>t&&(t=a,e=r)}}if(e!==-1&&!this._visibleLines.getVisibleLine(e).monospaceAssumptionsAreValid())for(let r=i;r<=o;r++)this._visibleLines.getVisibleLine(r).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){let i=this._horizontalRevealRequest;if(e.startLineNumber<=i.minLineNumber&&i.maxLineNumber<=e.endLineNumber){this._horizontalRevealRequest=null,this.onDidRender();let o=this._computeScrollLeftToReveal(i);o&&(this._isViewportWrapping||this._ensureMaxLineWidth(o.maxHorizontalOffset),this._context.viewModel.viewLayout.setScrollPosition({scrollLeft:o.scrollLeft},i.scrollType))}}if(this._updateLineWidthsFast()?this._asyncUpdateLineWidths.cancel():this._asyncUpdateLineWidths.schedule(),Qn&&!this._asyncCheckMonospaceFontAssumptions.isScheduled()){let i=this._visibleLines.getStartLineNumber(),o=this._visibleLines.getEndLineNumber();for(let r=i;r<=o;r++)if(this._visibleLines.getVisibleLine(r).needsMonospaceFontCheck()){this._asyncCheckMonospaceFontAssumptions.schedule();break}}this._linesContent.setLayerHinting(this._canUseLayerHinting),this._linesContent.setContain("strict");let t=this._context.viewLayout.getCurrentScrollTop()-e.bigNumbersDelta;this._linesContent.setTop(-t),this._linesContent.setLeft(-this._context.viewLayout.getCurrentScrollLeft())}_ensureMaxLineWidth(e){let t=Math.ceil(e);this._maxLineWidth0){let b=r[0].startLineNumber,v=r[0].endLineNumber;for(let x=1,w=r.length;xl){if(!d)return-1;_=u}else if(s===5||s===6)if(s===6&&a<=u&&h<=c)_=a;else{let b=Math.max(5*this._lineHeight,l*.2),v=u-b,x=h-l;_=Math.max(x,v)}else if(s===1||s===2)if(s===2&&a<=u&&h<=c)_=a;else{let b=(u+h)/2;_=Math.max(0,b-l/2)}else _=this._computeMinimumScrolling(a,c,u,h,s===3,s===4);return _}_computeScrollLeftToReveal(e){let t=this._context.viewLayout.getCurrentViewport(),i=this._context.configuration.options.get(146),o=t.left,r=o+t.width-i.verticalScrollbarWidth,s=1073741824,a=0;if(e.type==="range"){let c=this._visibleRangesForLineRange(e.lineNumber,e.startColumn,e.endColumn);if(!c)return null;for(let d of c.ranges)s=Math.min(s,Math.round(d.left)),a=Math.max(a,Math.round(d.left+d.width))}else for(let c of e.selections){if(c.startLineNumber!==c.endLineNumber)return null;let d=this._visibleRangesForLineRange(c.startLineNumber,c.startColumn,c.endColumn);if(!d)return null;for(let u of d.ranges)s=Math.min(s,Math.round(u.left)),a=Math.max(a,Math.round(u.left+u.width))}return e.minimalReveal||(s=Math.max(0,s-n.HORIZONTAL_EXTRA_PX),a+=this._revealHorizontalRightPadding),e.type==="selections"&&a-s>t.width?null:{scrollLeft:this._computeMinimumScrolling(o,r,s,a),maxHorizontalOffset:a}}_computeMinimumScrolling(e,t,i,o,r,s){e=e|0,t=t|0,i=i|0,o=o|0,r=!!r,s=!!s;let a=t-e;if(o-it)return Math.max(0,o-a)}else return i;return e}}});var U3e=k(()=>{});var IU,$3e=k(()=>{U3e();SU();IU=class extends HE{constructor(e){super(),this._context=e;let i=this._context.configuration.options.get(146);this._decorationsLeft=i.decorationsLeft,this._decorationsWidth=i.decorationsWidth,this._renderResult=null,this._context.addEventHandler(this)}dispose(){this._context.removeEventHandler(this),this._renderResult=null,super.dispose()}onConfigurationChanged(e){let i=this._context.configuration.options.get(146);return this._decorationsLeft=i.decorationsLeft,this._decorationsWidth=i.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){let t=e.getDecorationsInViewport(),i=[],o=0;for(let r=0,s=t.length;r',l=[];for(let c=t;c<=i;c++){let d=c-t,u=o[d].getDecorations(),h="";for(let f of u){let p='
    {});var EU,q3e=k(()=>{j3e();SU();EU=class extends HE{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){let t=e.getDecorationsInViewport(),i=[],o=0;for(let r=0,s=t.length;r
    ';r[a]=c}this._renderResult=r}render(e,t){return this._renderResult?this._renderResult[t-e]:""}}});var K3e=k(()=>{});var Bp,Bhe=k(()=>{Bp=class n{static{this.Empty=new n(0,0,0,0)}constructor(e,t,i,o){this._rgba8Brand=void 0,this.r=n._clamp(e),this.g=n._clamp(t),this.b=n._clamp(i),this.a=n._clamp(o)}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}}});var UE,Whe=k(()=>{Ie();j();Bhe();Ji();UE=class n extends D{static{this._INSTANCE=null}static getInstance(){return this._INSTANCE||(this._INSTANCE=lx(new n)),this._INSTANCE}constructor(){super(),this._onDidChange=new A,this.onDidChange=this._onDidChange.event,this._updateColorMap(),this._register($i.onDidChange(e=>{e.changedColorMap&&this._updateColorMap()}))}_updateColorMap(){let e=$i.getColorMap();if(!e){this._colors=[Bp.Empty],this._backgroundIsLight=!0;return}this._colors=[Bp.Empty];for(let i=1;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}}});var G3e,Y3e,Hhe=k(()=>{G3e=(()=>{let n=[];for(let e=32;e<=126;e++)n.push(e);return n.push(65533),n})(),Y3e=(n,e)=>(n-=32,n<0||n>96?e<=2?(n+96)%96:95:n)});var pP,Z3e=k(()=>{Hhe();IA();pP=class n{constructor(e,t){this.scale=t,this._minimapCharRendererBrand=void 0,this.charDataNormal=n.soften(e,12/15),this.charDataLight=n.soften(e,50/60)}static soften(e,t){let i=new Uint8ClampedArray(e.length);for(let o=0,r=e.length;oe.width||i+p>e.height){console.warn("bad render request outside image data");return}let g=d?this.charDataLight:this.charDataNormal,_=Y3e(o,c),b=e.width*4,v=a.r,x=a.g,w=a.b,y=r.r-v,C=r.g-x,L=r.b-w,E=Math.max(s,l),N=e.data,M=_*h*f,F=i*b+t*4;for(let q=0;qe.width||i+u>e.height){console.warn("bad render request outside image data");return}let h=e.width*4,f=.5*(r/255),p=s.r,g=s.g,_=s.b,b=o.r-p,v=o.g-g,x=o.b-_,w=p+b*f,y=g+v*f,C=_+x*f,L=Math.max(r,a),E=e.data,N=i*h+t*4;for(let M=0;M{sx();X3e={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},Q3e=n=>{let e=new Uint8ClampedArray(n.length/2);for(let t=0;t>1]=X3e[n[t]]<<4|X3e[n[t+1]]&15;return e},zhe={1:yd(()=>Q3e("0000511D6300CF609C709645A78432005642574171487021003C451900274D35D762755E8B629C5BA856AF57BA649530C167D1512A272A3F6038604460398526BCA2A968DB6F8957C768BE5FBE2FB467CF5D8D5B795DC7625B5DFF50DE64C466DB2FC47CD860A65E9A2EB96CB54CE06DA763AB2EA26860524D3763536601005116008177A8705E53AB738E6A982F88BAA35B5F5B626D9C636B449B737E5B7B678598869A662F6B5B8542706C704C80736A607578685B70594A49715A4522E792")),2:yd(()=>Q3e("000000000000000055394F383D2800008B8B1F210002000081B1CBCBCC820000847AAF6B9AAF2119BE08B8881AD60000A44FD07DCCF107015338130C00000000385972265F390B406E2437634B4B48031B12B8A0847000001E15B29A402F0000000000004B33460B00007A752C2A0000000000004D3900000084394B82013400ABA5CFC7AD9C0302A45A3E5A98AB000089A43382D97900008BA54AA087A70A0248A6A7AE6DBE0000BF6F94987EA40A01A06DCFA7A7A9030496C32F77891D0000A99FB1A0AFA80603B29AB9CA75930D010C0948354D3900000C0948354F37460D0028BE673D8400000000AF9D7B6E00002B007AA8933400007AA642675C2700007984CFB9C3985B768772A8A6B7B20000CAAECAAFC4B700009F94A6009F840009D09F9BA4CA9C0000CC8FC76DC87F0000C991C472A2000000A894A48CA7B501079BA2C9C69BA20000B19A5D3FA89000005CA6009DA2960901B0A7F0669FB200009D009E00B7890000DAD0F5D092820000D294D4C48BD10000B5A7A4A3B1A50402CAB6CBA6A2000000B5A7A4A3B1A8044FCDADD19D9CB00000B7778F7B8AAE0803C9AB5D3F5D3F00009EA09EA0BAB006039EA0989A8C7900009B9EF4D6B7C00000A9A7816CACA80000ABAC84705D3F000096DA635CDC8C00006F486F266F263D4784006124097B00374F6D2D6D2D6D4A3A95872322000000030000000000008D8939130000000000002E22A5C9CBC70600AB25C0B5C9B400061A2DB04CA67001082AA6BEBEBFC606002321DACBC19E03087AA08B6768380000282FBAC0B8CA7A88AD25BBA5A29900004C396C5894A6000040485A6E356E9442A32CD17EADA70000B4237923628600003E2DE9C1D7B500002F25BBA5A2990000231DB6AFB4A804023025C0B5CAB588062B2CBDBEC0C706882435A75CA20000002326BD6A82A908048B4B9A5A668000002423A09CB4BB060025259C9D8A7900001C1FCAB2C7C700002A2A9387ABA200002626A4A47D6E9D14333163A0C87500004B6F9C2D643A257049364936493647358A34438355497F1A0000A24C1D590000D38DFFBDD4CD3126"))}});var TU,e8e=k(()=>{Z3e();Hhe();J3e();IA();TU=class n{static create(e,t){if(this.lastCreated&&e===this.lastCreated.scale&&t===this.lastFontFamily)return this.lastCreated;let i;return zhe[e]?i=new pP(zhe[e](),e):i=n.createFromSampleData(n.createSampleData(t).data,e),this.lastFontFamily=t,this.lastCreated=i,i}static createSampleData(e){let t=document.createElement("canvas"),i=t.getContext("2d");t.style.height="16px",t.height=16,t.width=96*10,t.style.width=96*10+"px",i.fillStyle="#ffffff",i.font=`bold 16px ${e}`,i.textBaseline="middle";let o=0;for(let r of G3e)i.fillText(String.fromCharCode(r),o,16/2),o+=10;return i.getImageData(0,0,96*10,16)}static createFromSampleData(e,t){if(e.length!==61440)throw new Error("Unexpected source in MinimapCharRenderer");let o=n._downsample(e,t);return new pP(o,t)}static _downsampleChar(e,t,i,o,r){let s=1*r,a=2*r,l=o,c=0;for(let d=0;d0){let c=255/l;for(let d=0;d{Bt();DU=kn?'"Segoe WPC", "Segoe UI", sans-serif':dt?"-apple-system, BlinkMacSystemFont, sans-serif":'system-ui, "Ubuntu", "Droid Sans", sans-serif'});var zut,Vut,NU,Uhe,RU,AU,$he,MU,PU,jhe,OU,t8e=k(()=>{K3e();ke();Kr();qL();j();Bt();Qe();uU();Wl();ir();we();Bhe();Whe();Af();Wn();Ui();Pd();e8e();sx();Ds();Vhe();zut=140,Vut=2,NU=class n{constructor(e,t,i){let o=e.options,r=o.get(144),s=o.get(146),a=s.minimap,l=o.get(50),c=o.get(73);this.renderMinimap=a.renderMinimap,this.size=c.size,this.minimapHeightIsEditorHeight=a.minimapHeightIsEditorHeight,this.scrollBeyondLastLine=o.get(106),this.paddingTop=o.get(84).top,this.paddingBottom=o.get(84).bottom,this.showSlider=c.showSlider,this.autohide=c.autohide,this.pixelRatio=r,this.typicalHalfwidthCharacterWidth=l.typicalHalfwidthCharacterWidth,this.lineHeight=o.get(67),this.minimapLeft=a.minimapLeft,this.minimapWidth=a.minimapWidth,this.minimapHeight=s.height,this.canvasInnerWidth=a.minimapCanvasInnerWidth,this.canvasInnerHeight=a.minimapCanvasInnerHeight,this.canvasOuterWidth=a.minimapCanvasOuterWidth,this.canvasOuterHeight=a.minimapCanvasOuterHeight,this.isSampling=a.minimapIsSampling,this.editorHeight=s.height,this.fontScale=a.minimapScale,this.minimapLineHeight=a.minimapLineHeight,this.minimapCharWidth=1*this.fontScale,this.sectionHeaderFontFamily=DU,this.sectionHeaderFontSize=c.sectionHeaderFontSize*r,this.sectionHeaderLetterSpacing=c.sectionHeaderLetterSpacing,this.sectionHeaderFontColor=n._getSectionHeaderColor(t,i.getColor(1)),this.charRenderer=yd(()=>TU.create(this.fontScale,l.fontFamily)),this.defaultBackgroundColor=i.getColor(2),this.backgroundColor=n._getMinimapBackground(t,this.defaultBackgroundColor),this.foregroundAlpha=n._getMinimapForegroundOpacity(t)}static _getMinimapBackground(e,t){let i=e.getColor(TAe);return i?new Bp(i.rgba.r,i.rgba.g,i.rgba.b,Math.round(255*i.rgba.a)):t}static _getMinimapForegroundOpacity(e){let t=e.getColor(DAe);return t?Bp._clamp(Math.round(255*t.rgba.a)):255}static _getSectionHeaderColor(e,t){let i=e.getColor(ku);return i?new Bp(i.rgba.r,i.rgba.g,i.rgba.b,Math.round(255*i.rgba.a)):t}equals(e){return this.renderMinimap===e.renderMinimap&&this.size===e.size&&this.minimapHeightIsEditorHeight===e.minimapHeightIsEditorHeight&&this.scrollBeyondLastLine===e.scrollBeyondLastLine&&this.paddingTop===e.paddingTop&&this.paddingBottom===e.paddingBottom&&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.sectionHeaderFontSize===e.sectionHeaderFontSize&&this.sectionHeaderLetterSpacing===e.sectionHeaderLetterSpacing&&this.defaultBackgroundColor&&this.defaultBackgroundColor.equals(e.defaultBackgroundColor)&&this.backgroundColor&&this.backgroundColor.equals(e.backgroundColor)&&this.foregroundAlpha===e.foregroundAlpha}},Uhe=class n{constructor(e,t,i,o,r,s,a,l,c){this.scrollTop=e,this.scrollHeight=t,this.sliderNeeded=i,this._computedSliderRatio=o,this.sliderTop=r,this.sliderHeight=s,this.topPaddingLineCount=a,this.startLineNumber=l,this.endLineNumber=c}getDesiredScrollTopFromDelta(e){return Math.round(this.scrollTop+e/this._computedSliderRatio)}getDesiredScrollTopFromTouchLocation(e){return Math.round((e-this.sliderHeight/2)/this._computedSliderRatio)}intersectWithViewport(e){let t=Math.max(this.startLineNumber,e.startLineNumber),i=Math.min(this.endLineNumber,e.endLineNumber);return t>i?null:[t,i]}getYForLineNumber(e,t){return+(e-this.startLineNumber+this.topPaddingLineCount)*t}static create(e,t,i,o,r,s,a,l,c,d,u){let h=e.pixelRatio,f=e.minimapLineHeight,p=Math.floor(e.canvasInnerHeight/f),g=e.lineHeight;if(e.minimapHeightIsEditorHeight){let C=l*e.lineHeight+e.paddingTop+e.paddingBottom;e.scrollBeyondLastLine&&(C+=Math.max(0,r-e.lineHeight-e.paddingBottom));let L=Math.max(1,Math.floor(r*r/C)),E=Math.max(0,e.minimapHeight-L),N=E/(d-r),M=c*N,F=E>0,q=Math.floor(e.canvasInnerHeight/e.minimapLineHeight),te=Math.floor(e.paddingTop/e.lineHeight);return new n(c,d,F,N,M,L,te,1,Math.min(a,q))}let _;if(s&&i!==a){let C=i-t+1;_=Math.floor(C*f/h)}else{let C=r/g;_=Math.floor(C*f/h)}let b=Math.floor(e.paddingTop/g),v=Math.floor(e.paddingBottom/g);if(e.scrollBeyondLastLine){let C=r/g;v=Math.max(v,C-1)}let x;if(v>0){let C=r/g;x=(b+a+v-C-1)*f/h}else x=Math.max(0,(b+a)*f/h-_);x=Math.min(e.minimapHeight-_,x);let w=x/(d-r),y=c*w;if(p>=b+a+v){let C=x>0;return new n(c,d,C,w,y,_,b,1,a)}else{let C;t>1?C=t+b:C=Math.max(1,c/g);let L,E=Math.max(1,Math.floor(C-y*h/f));Ec&&(E=Math.min(E,u.startLineNumber),L=Math.max(L,u.topPaddingLineCount)),u.scrollTop=e.paddingTop?F=(t-E+L+M)*f/h:F=c/e.paddingTop*(L+M)*f/h,new n(c,d,!0,w,F,_,L,E,N)}}},RU=class n{static{this.INVALID=new n(-1)}constructor(e){this.dy=e}onContentChanged(){this.dy=-1}onTokensChanged(){this.dy=-1}},AU=class{constructor(e,t,i){this.renderedLayout=e,this._imageData=t,this._renderedLines=new fP({createLine:()=>RU.INVALID}),this._renderedLines._set(e.startLineNumber,i)}linesEquals(e){if(!this.scrollEquals(e))return!1;let i=this._renderedLines._get().lines;for(let o=0,r=i.length;o1){for(let b=0,v=o-1;b0&&this.minimapLines[i-1]>=e;)i--;let o=this.modelLineToMinimapLine(t)-1;for(;o+1t)return null}return[i+1,o+1]}decorationLineRangeToMinimapLineRange(e,t){let i=this.modelLineToMinimapLine(e),o=this.modelLineToMinimapLine(t);return e!==t&&o===i&&(o===this.minimapLines.length?i>1&&i--:o++),[i,o]}onLinesDeleted(e){let t=e.toLineNumber-e.fromLineNumber+1,i=this.minimapLines.length,o=0;for(let r=this.minimapLines.length-1;r>=0&&!(this.minimapLines[r]=0&&!(this.minimapLines[i]0,scrollWidth:e.scrollWidth,scrollHeight:e.scrollHeight,viewportStartLineNumber:t,viewportEndLineNumber:i,viewportStartLineNumberVerticalOffset:e.getVerticalOffsetForLineNumber(t),scrollTop:e.scrollTop,scrollLeft:e.scrollLeft,viewportWidth:e.viewportWidth,viewportHeight:e.viewportHeight};this._actual.render(o)}_recreateLineSampling(){this._minimapSelections=null;let e=!!this._samplingState,[t,i]=MU.compute(this.options,this._context.viewModel.getLineCount(),this._samplingState);if(this._samplingState=t,e&&this._samplingState)for(let o of i)switch(o.type){case"deleted":this._actual.onLinesDeleted(o.deleteFromLineNumber,o.deleteToLineNumber);break;case"inserted":this._actual.onLinesInserted(o.insertFromLineNumber,o.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,t,i){if(this._samplingState){let o=[];for(let r=0,s=t-e+1;r!o.options.minimap?.sectionHeaderStyle);if(this._samplingState){let o=[];for(let r of i){if(!r.options.minimap)continue;let s=r.range,a=this._samplingState.modelLineToMinimapLine(s.startLineNumber),l=this._samplingState.modelLineToMinimapLine(s.endLineNumber);o.push(new pE(new S(a,s.startColumn,l,s.endColumn),r.options))}return o}return i}getSectionHeaderDecorationsInViewport(e,t){let i=this.options.minimapLineHeight,r=this.options.sectionHeaderFontSize/i;return e=Math.floor(Math.max(1,e-r)),this._getMinimapDecorationsInViewport(e,t).filter(s=>!!s.options.minimap?.sectionHeaderStyle)}_getMinimapDecorationsInViewport(e,t){let i;if(this._samplingState){let o=this._samplingState.minimapLines[e-1],r=this._samplingState.minimapLines[t-1];i=new S(o,1,r,this._context.viewModel.getLineMaxColumn(r))}else i=new S(e,1,t,this._context.viewModel.getLineMaxColumn(t));return this._context.viewModel.getMinimapDecorationsInRange(i)}getSectionHeaderText(e,t){let i=e.options.minimap?.sectionHeaderText;if(!i)return null;let o=this._sectionHeaderCache.get(i);if(o)return o;let r=t(i);return this._sectionHeaderCache.set(i,r),r}getOptions(){return this._context.viewModel.model.getOptions()}revealLineNumber(e){this._samplingState&&(e=this._samplingState.minimapLines[e-1]),this._context.viewModel.revealRange("mouse",!1,new S(e,1,e,1),1,0)}setScrollTop(e){this._context.viewModel.viewLayout.setScrollPosition({scrollTop:e},1)}},jhe=class n extends D{constructor(e,t){super(),this._renderDecorations=!1,this._gestureInProgress=!1,this._theme=e,this._model=t,this._lastRenderData=null,this._buffers=null,this._selectionColor=this._theme.getColor(vse),this._domNode=Pt(document.createElement("div")),na.write(this._domNode,9),this._domNode.setClassName(this._getMinimapDomNodeClassName()),this._domNode.setPosition("absolute"),this._domNode.setAttribute("role","presentation"),this._domNode.setAttribute("aria-hidden","true"),this._shadow=Pt(document.createElement("div")),this._shadow.setClassName("minimap-shadow-hidden"),this._domNode.appendChild(this._shadow),this._canvas=Pt(document.createElement("canvas")),this._canvas.setPosition("absolute"),this._canvas.setLeft(0),this._domNode.appendChild(this._canvas),this._decorationsCanvas=Pt(document.createElement("canvas")),this._decorationsCanvas.setPosition("absolute"),this._decorationsCanvas.setClassName("minimap-decorations-layer"),this._decorationsCanvas.setLeft(0),this._domNode.appendChild(this._decorationsCanvas),this._slider=Pt(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=Pt(document.createElement("div")),this._sliderHorizontal.setPosition("absolute"),this._sliderHorizontal.setClassName("minimap-slider-horizontal"),this._slider.appendChild(this._sliderHorizontal),this._applyLayout(),this._pointerDownListener=gi(this._domNode.domNode,re.POINTER_DOWN,i=>{if(i.preventDefault(),this._model.options.renderMinimap===0||!this._lastRenderData)return;if(this._model.options.size!=="proportional"){if(i.button===0&&this._lastRenderData){let c=Ci(this._slider.domNode),d=c.top+c.height/2;this._startSliderDragging(i,d,this._lastRenderData.renderedLayout)}return}let r=this._model.options.minimapLineHeight,s=this._model.options.canvasInnerHeight/this._model.options.canvasOuterHeight*i.offsetY,l=Math.floor(s/r)+this._lastRenderData.renderedLayout.startLineNumber-this._lastRenderData.renderedLayout.topPaddingLineCount;l=Math.min(l,this._model.getLineCount()),this._model.revealLineNumber(l)}),this._sliderPointerMoveMonitor=new kh,this._sliderPointerDownListener=gi(this._slider.domNode,re.POINTER_DOWN,i=>{i.preventDefault(),i.stopPropagation(),i.button===0&&this._lastRenderData&&this._startSliderDragging(i,i.pageY,this._lastRenderData.renderedLayout)}),this._gestureDisposable=so.addTarget(this._domNode.domNode),this._sliderTouchStartListener=U(this._domNode.domNode,Mi.Start,i=>{i.preventDefault(),i.stopPropagation(),this._lastRenderData&&(this._slider.toggleClassName("active",!0),this._gestureInProgress=!0,this.scrollDueToTouchEvent(i))},{passive:!1}),this._sliderTouchMoveListener=U(this._domNode.domNode,Mi.Change,i=>{i.preventDefault(),i.stopPropagation(),this._lastRenderData&&this._gestureInProgress&&this.scrollDueToTouchEvent(i)},{passive:!1}),this._sliderTouchEndListener=gi(this._domNode.domNode,Mi.End,i=>{i.preventDefault(),i.stopPropagation(),this._gestureInProgress=!1,this._slider.toggleClassName("active",!1)})}_startSliderDragging(e,t,i){if(!e.target||!(e.target instanceof Element))return;let o=e.pageX;this._slider.toggleClassName("active",!0);let r=(s,a)=>{let l=Ci(this._domNode.domNode),c=Math.min(Math.abs(a-o),Math.abs(a-l.left),Math.abs(a-l.left-l.width));if(kn&&c>zut){this._model.setScrollTop(i.scrollTop);return}let d=s-t;this._model.setScrollTop(i.getDesiredScrollTopFromDelta(d))};e.pageY!==t&&r(e.pageY,o),this._sliderPointerMoveMonitor.startMonitoring(e.target,e.pointerId,e.buttons,s=>r(s.pageY,s.pageX),()=>{this._slider.toggleClassName("active",!1)})}scrollDueToTouchEvent(e){let t=this._domNode.domNode.getBoundingClientRect().top,i=this._lastRenderData.renderedLayout.getDesiredScrollTopFromTouchLocation(e.pageY-t);this._model.setScrollTop(i)}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(){let 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 $he(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,t){return this._lastRenderData?this._lastRenderData.onLinesChanged(e,t):!1}onLinesDeleted(e,t){return this._lastRenderData?.onLinesDeleted(e,t),!0}onLinesInserted(e,t){return this._lastRenderData?.onLinesInserted(e,t),!0}onScrollChanged(){return this._renderDecorations=!0,!0}onThemeChanged(){return this._selectionColor=this._theme.getColor(vse),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");let i=Uhe.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(i.sliderNeeded?"block":"none"),this._slider.setTop(i.sliderTop),this._slider.setHeight(i.sliderHeight),this._sliderHorizontal.setLeft(0),this._sliderHorizontal.setWidth(this._model.options.minimapWidth),this._sliderHorizontal.setTop(0),this._sliderHorizontal.setHeight(i.sliderHeight),this.renderDecorations(i),this._lastRenderData=this.renderLines(i)}renderDecorations(e){if(this._renderDecorations){this._renderDecorations=!1;let t=this._model.getSelections();t.sort(S.compareRangesUsingStarts);let i=this._model.getMinimapDecorationsInViewport(e.startLineNumber,e.endLineNumber);i.sort((h,f)=>(h.options.zIndex||0)-(f.options.zIndex||0));let{canvasInnerWidth:o,canvasInnerHeight:r}=this._model.options,s=this._model.options.minimapLineHeight,a=this._model.options.minimapCharWidth,l=this._model.getOptions().tabSize,c=this._decorationsCanvas.domNode.getContext("2d");c.clearRect(0,0,o,r);let d=new OU(e.startLineNumber,e.endLineNumber,!1);this._renderSelectionLineHighlights(c,t,d,e,s),this._renderDecorationsLineHighlights(c,i,d,e,s);let u=new OU(e.startLineNumber,e.endLineNumber,null);this._renderSelectionsHighlights(c,t,u,e,s,l,a,o),this._renderDecorationsHighlights(c,i,u,e,s,l,a,o),this._renderSectionHeaders(e)}}_renderSelectionLineHighlights(e,t,i,o,r){if(!this._selectionColor||this._selectionColor.isTransparent())return;e.fillStyle=this._selectionColor.transparent(.5).toString();let s=0,a=0;for(let l of t){let c=o.intersectWithViewport(l);if(!c)continue;let[d,u]=c;for(let p=d;p<=u;p++)i.set(p,!0);let h=o.getYForLineNumber(d,r),f=o.getYForLineNumber(u,r);a>=h||(a>s&&e.fillRect(rp,s,e.canvas.width,a-s),s=h),a=f}a>s&&e.fillRect(rp,s,e.canvas.width,a-s)}_renderDecorationsLineHighlights(e,t,i,o,r){let s=new Map;for(let a=t.length-1;a>=0;a--){let l=t[a],c=l.options.minimap;if(!c||c.position!==1)continue;let d=o.intersectWithViewport(l.range);if(!d)continue;let[u,h]=d,f=c.getColor(this._theme.value);if(!f||f.isTransparent())continue;let p=s.get(f.toString());p||(p=f.transparent(.5).toString(),s.set(f.toString(),p)),e.fillStyle=p;for(let g=u;g<=h;g++){if(i.has(g))continue;i.set(g,!0);let _=o.getYForLineNumber(u,r);e.fillRect(rp,_,e.canvas.width,r)}}}_renderSelectionsHighlights(e,t,i,o,r,s,a,l){if(!(!this._selectionColor||this._selectionColor.isTransparent()))for(let c of t){let d=o.intersectWithViewport(c);if(!d)continue;let[u,h]=d;for(let f=u;f<=h;f++)this.renderDecorationOnLine(e,i,c,this._selectionColor,o,f,r,r,s,a,l)}}_renderDecorationsHighlights(e,t,i,o,r,s,a,l){for(let c of t){let d=c.options.minimap;if(!d)continue;let u=o.intersectWithViewport(c.range);if(!u)continue;let[h,f]=u,p=d.getColor(this._theme.value);if(!(!p||p.isTransparent()))for(let g=h;g<=f;g++)switch(d.position){case 1:this.renderDecorationOnLine(e,i,c.range,p,o,g,r,r,s,a,l);continue;case 2:{let _=o.getYForLineNumber(g,r);this.renderDecoration(e,p,2,_,Vut,r);continue}}}}renderDecorationOnLine(e,t,i,o,r,s,a,l,c,d,u){let h=r.getYForLineNumber(s,l);if(h+a<0||h>this._model.options.canvasInnerHeight)return;let{startLineNumber:f,endLineNumber:p}=i,g=f===s?i.startColumn:1,_=p===s?i.endColumn:this._model.getLineMaxColumn(s),b=this.getXOffsetForPosition(t,s,g,c,d,u),v=this.getXOffsetForPosition(t,s,_,c,d,u);this.renderDecoration(e,o,b,h,v-b,a)}getXOffsetForPosition(e,t,i,o,r,s){if(i===1)return rp;if((i-1)*r>=s)return s;let l=e.get(t);if(!l){let c=this._model.getLineContent(t);l=[rp];let d=rp;for(let u=1;u=s){l[u]=s;break}l[u]=p,d=p}e.set(t,l)}return i-1g.range.startLineNumber-_.range.startLineNumber);let p=n._fitSectionHeader.bind(null,h,s-rp);for(let g of f){let _=e.getYForLineNumber(g.range.startLineNumber,t)+i,b=_-i,v=b+2,x=this._model.getSectionHeaderText(g,p);n._renderSectionLabel(h,x,g.options.minimap?.sectionHeaderStyle===2,l,d,s,b,r,_,v)}}static _fitSectionHeader(e,t,i){if(!i)return i;let o="\u2026",r=e.measureText(i).width,s=e.measureText(o).width;if(r<=t||r<=s)return i;let a=i.length,l=r/i.length,c=Math.floor((t-s)/l)-1,d=Math.ceil(c/2);for(;d>0&&/\s/.test(i[d-1]);)--d;return i.substring(0,d)+o+i.substring(a-(c-d))}static _renderSectionLabel(e,t,i,o,r,s,a,l,c,d){t&&(e.fillStyle=o,e.fillRect(0,a,s,l),e.fillStyle=r,e.fillText(t,rp,c)),i&&(e.beginPath(),e.moveTo(0,d),e.lineTo(s,d),e.closePath(),e.stroke())}renderLines(e){let t=e.startLineNumber,i=e.endLineNumber,o=this._model.options.minimapLineHeight;if(this._lastRenderData&&this._lastRenderData.linesEquals(e)){let z=this._lastRenderData._get();return new AU(e,z.imageData,z.lines)}let r=this._getBuffer();if(!r)return null;let[s,a,l]=n._renderUntouchedLines(r,e.topPaddingLineCount,t,i,o,this._lastRenderData),c=this._model.getMinimapLinesRenderingData(t,i,l),d=this._model.getOptions().tabSize,u=this._model.options.defaultBackgroundColor,h=this._model.options.backgroundColor,f=this._model.options.foregroundAlpha,p=this._model.tokensColorTracker,g=p.backgroundIsLight(),_=this._model.options.renderMinimap,b=this._model.options.charRenderer(),v=this._model.options.fontScale,x=this._model.options.minimapCharWidth,y=(_===1?2:3)*v,C=o>y?Math.floor((o-y)/2):0,L=h.a/255,E=new Bp(Math.round((h.r-u.r)*L+u.r),Math.round((h.g-u.g)*L+u.g),Math.round((h.b-u.b)*L+u.b),255),N=e.topPaddingLineCount*o,M=[];for(let z=0,ae=i-t+1;z=0&&Fv)return;let q=_.charCodeAt(y);if(q===9){let te=h-(y+C)%h;C+=te-1,w+=te*s}else if(q===32)w+=s;else{let te=hh(q)?2:1;for(let $=0;$v)return}}}}},OU=class{constructor(e,t,i){this._startLineNumber=e,this._endLineNumber=t,this._defaultValue=i,this._values=[];for(let o=0,r=this._endLineNumber-this._startLineNumber+1;othis._endLineNumber||(this._values[e-this._startLineNumber]=t)}get(e){return ethis._endLineNumber?this._defaultValue:this._values[e-this._startLineNumber]}}});var i8e=k(()=>{});var FU,n8e=k(()=>{i8e();Kr();Wl();ke();FU=class extends wo{constructor(e,t){super(e),this._viewDomNode=t;let o=this._context.configuration.options.get(146);this._widgets={},this._verticalScrollbarWidth=o.verticalScrollbarWidth,this._minimapWidth=o.minimap.minimapWidth,this._horizontalScrollbarHeight=o.horizontalScrollbarHeight,this._editorHeight=o.height,this._editorWidth=o.width,this._viewDomNodeRect={top:0,left:0,width:0,height:0},this._domNode=Pt(document.createElement("div")),na.write(this._domNode,4),this._domNode.setClassName("overlayWidgets"),this.overflowingOverlayWidgetsDomNode=Pt(document.createElement("div")),na.write(this.overflowingOverlayWidgetsDomNode,5),this.overflowingOverlayWidgetsDomNode.setClassName("overflowingOverlayWidgets")}dispose(){super.dispose(),this._widgets={}}getDomNode(){return this._domNode}onConfigurationChanged(e){let i=this._context.configuration.options.get(146);return this._verticalScrollbarWidth=i.verticalScrollbarWidth,this._minimapWidth=i.minimap.minimapWidth,this._horizontalScrollbarHeight=i.horizontalScrollbarHeight,this._editorHeight=i.height,this._editorWidth=i.width,!0}addWidget(e){let t=Pt(e.getDomNode());this._widgets[e.getId()]={widget:e,preference:null,domNode:t},t.setPosition("absolute"),t.setAttribute("widgetId",e.getId()),e.allowEditorOverflow?this.overflowingOverlayWidgetsDomNode.appendChild(t):this._domNode.appendChild(t),this.setShouldRender(),this._updateMaxMinWidth()}setWidgetPosition(e,t){let i=this._widgets[e.getId()],o=t?t.preference:null,r=t?.stackOridinal;return i.preference===o&&i.stack===r?(this._updateMaxMinWidth(),!1):(i.preference=o,i.stack=r,this.setShouldRender(),this._updateMaxMinWidth(),!0)}removeWidget(e){let t=e.getId();if(this._widgets.hasOwnProperty(t)){let o=this._widgets[t].domNode.domNode;delete this._widgets[t],o.remove(),this.setShouldRender(),this._updateMaxMinWidth()}}_updateMaxMinWidth(){let e=0,t=Object.keys(this._widgets);for(let i=0,o=t.length;i0);t.sort((o,r)=>(this._widgets[o].stack||0)-(this._widgets[r].stack||0));for(let o=0,r=t.length;o{Kr();vo();Wl();qe();Ji();Nu();Af();at();qhe=class{constructor(e,t){let i=e.options;this.lineHeight=i.get(67),this.pixelRatio=i.get(144),this.overviewRulerLanes=i.get(83),this.renderBorder=i.get(82);let o=t.getColor(BOe);this.borderColor=o?o.toString():null,this.hideCursor=i.get(59);let r=t.getColor(TI);this.cursorColorSingle=r?r.transparent(.7).toString():null;let s=t.getColor(TW);this.cursorColorPrimary=s?s.transparent(.7).toString():null;let a=t.getColor(DW);this.cursorColorSecondary=a?a.transparent(.7).toString():null,this.themeType=t.type;let l=i.get(73),c=l.enabled,d=l.side,u=t.getColor(WOe),h=$i.getDefaultBackground();u?this.backgroundColor=u:c&&d==="right"?this.backgroundColor=h:this.backgroundColor=null;let p=i.get(146).overviewRuler;this.top=p.top,this.right=p.right,this.domWidth=p.width,this.domHeight=p.height,this.overviewRulerLanes===0?(this.canvasWidth=0,this.canvasHeight=0):(this.canvasWidth=this.domWidth*this.pixelRatio|0,this.canvasHeight=this.domHeight*this.pixelRatio|0);let[g,_]=this._initLanes(1,this.canvasWidth,this.overviewRulerLanes);this.x=g,this.w=_}_initLanes(e,t,i){let o=t-e;if(i>=3){let r=Math.floor(o/3),s=Math.floor(o/3),a=o-r-s,l=e,c=l+r,d=l+r+a;return[[0,l,c,l,d,l,c,l],[0,r,a,r+a,s,r+a+s,a+s,r+a+s]]}else if(i===2){let r=Math.floor(o/2),s=o-r,a=e,l=a+r;return[[0,a,a,a,l,a,a,a],[0,r,r,r,s,r+s,r+s,r+s]]}else{let r=e,s=o;return[[0,r,r,r,r,r,r,r],[0,s,s,s,s,s,s,s]]}}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.cursorColorSingle===e.cursorColorSingle&&this.cursorColorPrimary===e.cursorColorPrimary&&this.cursorColorSecondary===e.cursorColorSecondary&&this.themeType===e.themeType&&Z.equals(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}},BU=class extends wo{constructor(e){super(e),this._actualShouldRender=0,this._renderedDecorations=[],this._renderedCursorPositions=[],this._domNode=Pt(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=$i.onDidChange(t=>{t.changedColorMap&&this._updateSettings(!0)}),this._cursorPositions=[{position:new P(1,1),color:this._settings.cursorColorSingle}]}dispose(){super.dispose(),this._tokensColorTrackerListener.dispose()}_updateSettings(e){let t=new qhe(this._context.configuration,this._context.theme);return this._settings&&this._settings.equals(t)?!1:(this._settings=t,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)}_markRenderingIsNeeded(){return this._actualShouldRender=2,!0}_markRenderingIsMaybeNeeded(){return this._actualShouldRender=1,!0}onConfigurationChanged(e){return this._updateSettings(!1)?this._markRenderingIsNeeded():!1}onCursorStateChanged(e){this._cursorPositions=[];for(let t=0,i=e.selections.length;t1&&(o=t===0?this._settings.cursorColorPrimary:this._settings.cursorColorSecondary),this._cursorPositions.push({position:e.selections[t].getPosition(),color:o})}return this._cursorPositions.sort((t,i)=>P.compare(t.position,i.position)),this._markRenderingIsMaybeNeeded()}onDecorationsChanged(e){return e.affectsOverviewRuler?this._markRenderingIsMaybeNeeded():!1}onFlushed(e){return this._markRenderingIsNeeded()}onScrollChanged(e){return e.scrollHeightChanged?this._markRenderingIsNeeded():!1}onZonesChanged(e){return this._markRenderingIsNeeded()}onThemeChanged(e){return this._updateSettings(!1)?this._markRenderingIsNeeded():!1}getDomNode(){return this._domNode.domNode}prepareRender(e){}render(e){this._render(),this._actualShouldRender=0}_render(){let e=this._settings.backgroundColor;if(this._settings.overviewRulerLanes===0){this._domNode.setBackgroundColor(e?Z.Format.CSS.formatHexA(e):""),this._domNode.setDisplay("none");return}let t=this._context.viewModel.getAllOverviewRulerDecorations(this._context.theme);if(t.sort(i0.compareByRenderingProps),this._actualShouldRender===1&&!i0.equalsArr(this._renderedDecorations,t)&&(this._actualShouldRender=2),this._actualShouldRender===1&&!oi(this._renderedCursorPositions,this._cursorPositions,(p,g)=>p.position.lineNumber===g.position.lineNumber&&p.color===g.color)&&(this._actualShouldRender=2),this._actualShouldRender===1)return;this._renderedDecorations=t,this._renderedCursorPositions=this._cursorPositions,this._domNode.setDisplay("block");let i=this._settings.canvasWidth,o=this._settings.canvasHeight,r=this._settings.lineHeight,s=this._context.viewLayout,a=this._context.viewLayout.getScrollHeight(),l=o/a,c=6*this._settings.pixelRatio|0,d=c/2|0,u=this._domNode.domNode.getContext("2d");e?e.isOpaque()?(u.fillStyle=Z.Format.CSS.formatHexA(e),u.fillRect(0,0,i,o)):(u.clearRect(0,0,i,o),u.fillStyle=Z.Format.CSS.formatHexA(e),u.fillRect(0,0,i,o)):u.clearRect(0,0,i,o);let h=this._settings.x,f=this._settings.w;for(let p of t){let g=p.color,_=p.data;u.fillStyle=g;let b=0,v=0,x=0;for(let w=0,y=_.length/3;wo&&(q=o-d),N=q-d,M=q+d}N>x+1||C!==b?(w!==0&&u.fillRect(h[b],v,f[b],x-v),b=C,v=N,x=M):M>x&&(x=M)}u.fillRect(h[b],v,f[b],x-v)}if(!this._settings.hideCursor){let p=2*this._settings.pixelRatio|0,g=p/2|0,_=this._settings.x[7],b=this._settings.w[7],v=-100,x=-100,w=null;for(let y=0,C=this._cursorPositions.length;yo&&(N=o-g);let M=N-g,F=M+p;M>x+1||L!==w?(y!==0&&w&&u.fillRect(_,v,b,x-v),v=M,x=F):F>x&&(x=F),w=L,u.fillStyle=L}w&&u.fillRect(_,v,b,x-v)}this._settings.renderBorder&&this._settings.borderColor&&this._settings.overviewRulerLanes>0&&(u.beginPath(),u.lineWidth=1,u.strokeStyle=this._settings.borderColor,u.moveTo(0,0),u.lineTo(0,o),u.moveTo(1,0),u.lineTo(i,0),u.stroke())}}});var WU,mP,HU,Khe=k(()=>{WU=class{constructor(e,t,i){this._colorZoneBrand=void 0,this.from=e|0,this.to=t|0,this.colorId=i|0}static compare(e,t){return e.colorId===t.colorId?e.from===t.from?e.to-t.to:e.from-t.from:e.colorId-t.colorId}},mP=class{constructor(e,t,i,o){this._overviewRulerZoneBrand=void 0,this.startLineNumber=e,this.endLineNumber=t,this.heightInLines=i,this.color=o,this._colorZone=null}static compare(e,t){return e.color===t.color?e.startLineNumber===t.startLineNumber?e.heightInLines===t.heightInLines?e.endLineNumber-t.endLineNumber:e.heightInLines-t.heightInLines:e.startLineNumber-t.startLineNumber:e.colori&&(g=i-_);let b=d.color,v=this._color2Id[b];v||(v=++this._lastAssignedId,this._color2Id[b]=v,this._id2Color[v]=b);let x=new WU(g-_,g+_,v);d.setColorZone(x),a.push(x)}return this._colorZonesInvalid=!1,a.sort(WU.compare),a}}});var zU,r8e=k(()=>{Kr();Khe();wE();zU=class extends Pf{constructor(e,t){super(),this._context=e;let i=this._context.configuration.options;this._domNode=Pt(document.createElement("canvas")),this._domNode.setClassName(t),this._domNode.setPosition("absolute"),this._domNode.setLayerHinting(!0),this._domNode.setContain("strict"),this._zoneManager=new HU(o=>this._context.viewLayout.getVerticalOffsetForLineNumber(o)),this._zoneManager.setDOMWidth(0),this._zoneManager.setDOMHeight(0),this._zoneManager.setOuterHeight(this._context.viewLayout.getScrollHeight()),this._zoneManager.setLineHeight(i.get(67)),this._zoneManager.setPixelRatio(i.get(144)),this._context.addEventHandler(this)}dispose(){this._context.removeEventHandler(this),super.dispose()}onConfigurationChanged(e){let t=this._context.configuration.options;return e.hasChanged(67)&&(this._zoneManager.setLineHeight(t.get(67)),this._render()),e.hasChanged(144)&&(this._zoneManager.setPixelRatio(t.get(144)),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 t=!1;t=this._zoneManager.setDOMWidth(e.width)||t,t=this._zoneManager.setDOMHeight(e.height)||t,t&&(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;let e=this._zoneManager.getCanvasWidth(),t=this._zoneManager.getCanvasHeight(),i=this._zoneManager.resolveColorZones(),o=this._zoneManager.getId2Color(),r=this._domNode.domNode.getContext("2d");return r.clearRect(0,0,e,t),i.length>0&&this._renderOneLane(r,i,o,e),!0}_renderOneLane(e,t,i,o){let r=0,s=0,a=0;for(let l of t){let c=l.colorId,d=l.from,u=l.to;c!==r?(e.fillRect(0,s,o,a-s),r=c,e.fillStyle=i[r],s=d,a=u):a>=d?a=Math.max(a,u):(e.fillRect(0,s,o,a-s),s=d,a=u)}e.fillRect(0,s,o,a-s)}}});var s8e=k(()=>{});var VU,a8e=k(()=>{s8e();Kr();Wl();VU=class extends wo{constructor(e){super(e),this.domNode=Pt(document.createElement("div")),this.domNode.setAttribute("role","presentation"),this.domNode.setAttribute("aria-hidden","true"),this.domNode.setClassName("view-rulers"),this._renderedRulers=[];let t=this._context.configuration.options;this._rulers=t.get(103),this._typicalHalfwidthCharacterWidth=t.get(50).typicalHalfwidthCharacterWidth}dispose(){super.dispose()}onConfigurationChanged(e){let t=this._context.configuration.options;return this._rulers=t.get(103),this._typicalHalfwidthCharacterWidth=t.get(50).typicalHalfwidthCharacterWidth,!0}onScrollChanged(e){return e.scrollHeightChanged}prepareRender(e){}_ensureRulersCount(){let e=this._renderedRulers.length,t=this._rulers.length;if(e===t)return;if(e0;){let a=Pt(document.createElement("div"));a.setClassName("view-ruler"),a.setWidth(r),this.domNode.appendChild(a),this._renderedRulers.push(a),s--}return}let i=e-t;for(;i>0;){let o=this._renderedRulers.pop();this.domNode.removeChild(o),i--}}render(e){this._ensureRulersCount();for(let t=0,i=this._rulers.length;t{});var UU,c8e=k(()=>{l8e();Kr();Wl();UU=class extends wo{constructor(e){super(e),this._scrollTop=0,this._width=0,this._updateWidth(),this._shouldShow=!1;let i=this._context.configuration.options.get(104);this._useShadows=i.useShadows,this._domNode=Pt(document.createElement("div")),this._domNode.setAttribute("role","presentation"),this._domNode.setAttribute("aria-hidden","true")}dispose(){super.dispose()}_updateShouldShow(){let e=this._useShadows&&this._scrollTop>0;return this._shouldShow!==e?(this._shouldShow=e,!0):!1}getDomNode(){return this._domNode}_updateWidth(){let t=this._context.configuration.options.get(146);t.minimap.renderMinimap===0||t.minimap.minimapWidth>0&&t.minimap.minimapLeft===0?this._width=t.width:this._width=t.width-t.verticalScrollbarWidth}onConfigurationChanged(e){let i=this._context.configuration.options.get(104);return this._useShadows=i.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":"")}}});var d8e=k(()=>{});function Uut(n){return new Ghe(n)}function $ut(n){return new Yhe(n.lineNumber,n.ranges.map(Uut))}function $U(n){return n<0?-n:n}var Ghe,Yhe,jU,u8e=k(()=>{d8e();Aw();Wn();Yi();Ghe=class{constructor(e){this.left=e.left,this.width=e.width,this.startStyle=null,this.endStyle=null}},Yhe=class{constructor(e,t){this.lineNumber=e,this.ranges=t}};jU=class n extends nd{static{this.SELECTION_CLASS_NAME="selected-text"}static{this.SELECTION_TOP_LEFT="top-left-radius"}static{this.SELECTION_BOTTOM_LEFT="bottom-left-radius"}static{this.SELECTION_TOP_RIGHT="top-right-radius"}static{this.SELECTION_BOTTOM_RIGHT="bottom-right-radius"}static{this.EDITOR_BACKGROUND_CLASS_NAME="monaco-editor-background"}static{this.ROUNDED_PIECE_WIDTH=10}constructor(e){super(),this._previousFrameVisibleRangesWithStyle=[],this._context=e;let t=this._context.configuration.options;this._roundedSelection=t.get(102),this._typicalHalfwidthCharacterWidth=t.get(50).typicalHalfwidthCharacterWidth,this._selections=[],this._renderResult=null,this._context.addEventHandler(this)}dispose(){this._context.removeEventHandler(this),this._renderResult=null,super.dispose()}onConfigurationChanged(e){let t=this._context.configuration.options;return this._roundedSelection=t.get(102),this._typicalHalfwidthCharacterWidth=t.get(50).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 t=0,i=e.length;t1)return!0;return!1}_enrichVisibleRangesWithStyle(e,t,i){let o=this._typicalHalfwidthCharacterWidth/4,r=null,s=null;if(i&&i.length>0&&t.length>0){let a=t[0].lineNumber;if(a===e.startLineNumber)for(let c=0;!r&&c=0;c--)i[c].lineNumber===l&&(s=i[c].ranges[0]);r&&!r.startStyle&&(r=null),s&&!s.startStyle&&(s=null)}for(let a=0,l=t.length;a0){let p=t[a-1].ranges[0].left,g=t[a-1].ranges[0].left+t[a-1].ranges[0].width;$U(d-p)p&&(h.top=1),$U(u-g)'}_actualRenderOneSelection(e,t,i,o){if(o.length===0)return;let r=!!o[0].ranges[0].startStyle,s=o[0].lineNumber,a=o[o.length-1].lineNumber;for(let l=0,c=o.length;l1,c)}this._previousFrameVisibleRangesWithStyle=r,this._renderResult=t.map(([s,a])=>s+a)}render(e,t){if(!this._renderResult)return"";let i=t-e;return i<0||i>=this._renderResult.length?"":this._renderResult[i]}};wr((n,e)=>{let t=n.getColor(aAe);t&&!t.isTransparent()&&e.addRule(`.monaco-editor .view-line span.inline-selected-text { color: ${t}; }`)})});var h8e=k(()=>{});var qU,Hg,gP,f8e=k(()=>{ke();Kr();Qe();bu();ir();qe();we();AV();qU=class{constructor(e,t,i,o,r,s,a){this.top=e,this.left=t,this.paddingLeft=i,this.width=o,this.height=r,this.textContent=s,this.textContentClassName=a}};(function(n){n[n.Single=0]="Single",n[n.MultiPrimary=1]="MultiPrimary",n[n.MultiSecondary=2]="MultiSecondary"})(Hg||(Hg={}));gP=class{constructor(e,t){this._context=e;let i=this._context.configuration.options,o=i.get(50);this._cursorStyle=i.get(28),this._lineHeight=i.get(67),this._typicalHalfwidthCharacterWidth=o.typicalHalfwidthCharacterWidth,this._lineCursorWidth=Math.min(i.get(31),this._typicalHalfwidthCharacterWidth),this._isVisible=!0,this._domNode=Pt(document.createElement("div")),this._domNode.setClassName(`cursor ${Wb}`),this._domNode.setHeight(this._lineHeight),this._domNode.setTop(0),this._domNode.setLeft(0),Kn(this._domNode,o),this._domNode.setDisplay("none"),this._position=new P(1,1),this._pluralityClass="",this.setPlurality(t),this._lastRenderedContent="",this._renderData=null}getDomNode(){return this._domNode}getPosition(){return this._position}setPlurality(e){switch(e){default:case Hg.Single:this._pluralityClass="";break;case Hg.MultiPrimary:this._pluralityClass="cursor-primary";break;case Hg.MultiSecondary:this._pluralityClass="cursor-secondary";break}}show(){this._isVisible||(this._domNode.setVisibility("inherit"),this._isVisible=!0)}hide(){this._isVisible&&(this._domNode.setVisibility("hidden"),this._isVisible=!1)}onConfigurationChanged(e){let t=this._context.configuration.options,i=t.get(50);return this._cursorStyle=t.get(28),this._lineHeight=t.get(67),this._typicalHalfwidthCharacterWidth=i.typicalHalfwidthCharacterWidth,this._lineCursorWidth=Math.min(t.get(31),this._typicalHalfwidthCharacterWidth),Kn(this._domNode,i),!0}onCursorPositionChanged(e,t){return t?this._domNode.domNode.style.transitionProperty="none":this._domNode.domNode.style.transitionProperty="",this._position=e,!0}_getGraphemeAwarePosition(){let{lineNumber:e,column:t}=this._position,i=this._context.viewModel.getLineContent(e),[o,r]=HTe(i,t-1);return[new P(e,o+1),i.substring(o,r)]}_prepareRender(e){let t="",i="",[o,r]=this._getGraphemeAwarePosition();if(this._cursorStyle===ss.Line||this._cursorStyle===ss.LineThin){let h=e.visibleRangeForPosition(o);if(!h||h.outsideRenderedLine)return null;let f=Me(this._domNode.domNode),p;this._cursorStyle===ss.Line?(p=roe(f,this._lineCursorWidth>0?this._lineCursorWidth:2),p>2&&(t=r,i=this._getTokenClassName(o))):p=roe(f,1);let g=h.left,_=0;p>=2&&g>=1&&(_=1,g-=_);let b=e.getVerticalOffsetForLineNumber(o.lineNumber)-e.bigNumbersDelta;return new qU(b,g,_,p,this._lineHeight,t,i)}let s=e.linesVisibleRangesForRange(new S(o.lineNumber,o.column,o.lineNumber,o.column+r.length),!1);if(!s||s.length===0)return null;let a=s[0];if(a.outsideRenderedLine||a.ranges.length===0)return null;let l=a.ranges[0],c=r===" "?this._typicalHalfwidthCharacterWidth:l.width<1?this._typicalHalfwidthCharacterWidth:l.width;this._cursorStyle===ss.Block&&(t=r,i=this._getTokenClassName(o));let d=e.getVerticalOffsetForLineNumber(o.lineNumber)-e.bigNumbersDelta,u=this._lineHeight;return(this._cursorStyle===ss.Underline||this._cursorStyle===ss.UnderlineThin)&&(d+=this._lineHeight-2,u=2),new qU(d,l.left,0,c,u,t,i)}_getTokenClassName(e){let t=this._context.viewModel.getViewLineData(e.lineNumber),i=t.tokens.findTokenIndexAtOffset(e.column-1);return t.tokens.getClassName(i)}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 ${this._pluralityClass} ${Wb} ${this._renderData.textContentClassName}`),this._domNode.setDisplay("block"),this._domNode.setTop(this._renderData.top),this._domNode.setLeft(this._renderData.left),this._domNode.setPaddingLeft(this._renderData.paddingLeft),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)}}});var KU,p8e=k(()=>{h8e();Kr();ft();Wl();f8e();ir();Nu();Yi();wf();ke();KU=class n extends wo{static{this.BLINK_INTERVAL=500}constructor(e){super(e);let t=this._context.configuration.options;this._readOnly=t.get(92),this._cursorBlinking=t.get(26),this._cursorStyle=t.get(28),this._cursorSmoothCaretAnimation=t.get(27),this._selectionIsEmpty=!0,this._isComposingInput=!1,this._isVisible=!1,this._primaryCursor=new gP(this._context,Hg.Single),this._secondaryCursors=[],this._renderData=[],this._domNode=Pt(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 _r,this._cursorFlatBlinkInterval=new yx,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){let t=this._context.configuration.options;this._readOnly=t.get(92),this._cursorBlinking=t.get(26),this._cursorStyle=t.get(28),this._cursorSmoothCaretAnimation=t.get(27),this._updateBlinking(),this._updateDomClassName(),this._primaryCursor.onConfigurationChanged(e);for(let i=0,o=this._secondaryCursors.length;it.length){let r=this._secondaryCursors.length-t.length;for(let s=0;s{for(let o=0,r=e.ranges.length;o{this._isVisible?this._hide():this._show()},n.BLINK_INTERVAL,Me(this._domNode.domNode)):this._startCursorBlinkAnimation.setIfNotSet(()=>{this._blinkingEnabled=!0,this._updateDomClassName()},n.BLINK_INTERVAL))}_updateDomClassName(){this._domNode.setClassName(this._getClassName())}_getClassName(){let e="cursors-layer";switch(this._selectionIsEmpty||(e+=" has-selection"),this._cursorStyle){case ss.Line:e+=" cursor-line-style";break;case ss.Block:e+=" cursor-block-style";break;case ss.Underline:e+=" cursor-underline-style";break;case ss.LineThin:e+=" cursor-line-thin-style";break;case ss.BlockOutline:e+=" cursor-block-outline-style";break;case ss.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==="on"||this._cursorSmoothCaretAnimation==="explicit")&&(e+=" cursor-smooth-caret-animation"),e}_show(){this._primaryCursor.show();for(let e=0,t=this._secondaryCursors.length;e{let t=[{class:".cursor",foreground:TI,background:EW},{class:".cursor-primary",foreground:TW,background:SOe},{class:".cursor-secondary",foreground:DW,background:kOe}];for(let i of t){let o=n.getColor(i.foreground);if(o){let r=n.getColor(i.background);r||(r=o.opposite()),e.addRule(`.monaco-editor .cursors-layer ${i.class} { background-color: ${o}; border-color: ${o}; color: ${r}; }`),nl(n.type)&&e.addRule(`.monaco-editor .cursors-layer.has-selection ${i.class} { border-left: 1px solid ${r}; border-right: 1px solid ${r}; }`)}}})});function jut(n,e){try{return n(e)}catch(t){Be(t)}}var Zhe,GU,m8e=k(()=>{Kr();je();Wl();qe();Zhe=()=>{throw new Error("Invalid change accessor")},GU=class extends wo{constructor(e){super(e);let t=this._context.configuration.options,i=t.get(146);this._lineHeight=t.get(67),this._contentWidth=i.contentWidth,this._contentLeft=i.contentLeft,this.domNode=Pt(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=Pt(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(){let e=this._context.viewLayout.getWhitespaces(),t=new Map;for(let o of e)t.set(o.id,o);let i=!1;return this._context.viewModel.changeWhitespace(o=>{let r=Object.keys(this._zones);for(let s=0,a=r.length;s{let o={addZone:r=>(t=!0,this._addZone(i,r)),removeZone:r=>{r&&(t=this._removeZone(i,r)||t)},layoutZone:r=>{r&&(t=this._layoutZone(i,r)||t)}};jut(e,o),o.addZone=Zhe,o.removeZone=Zhe,o.layoutZone=Zhe}),t}_addZone(e,t){let i=this._computeWhitespaceProps(t),r={whitespaceId:e.insertWhitespace(i.afterViewLineNumber,this._getZoneOrdinal(t),i.heightInPx,i.minWidthInPx),delegate:t,isInHiddenArea:i.isInHiddenArea,isVisible:!1,domNode:Pt(t.domNode),marginDomNode:t.marginDomNode?Pt(t.marginDomNode):null};return this._safeCallOnComputedHeight(r.delegate,i.heightInPx),r.domNode.setPosition("absolute"),r.domNode.domNode.style.width="100%",r.domNode.setDisplay("none"),r.domNode.setAttribute("monaco-view-zone",r.whitespaceId),this.domNode.appendChild(r.domNode),r.marginDomNode&&(r.marginDomNode.setPosition("absolute"),r.marginDomNode.domNode.style.width="100%",r.marginDomNode.setDisplay("none"),r.marginDomNode.setAttribute("monaco-view-zone",r.whitespaceId),this.marginDomNode.appendChild(r.marginDomNode)),this._zones[r.whitespaceId]=r,this.setShouldRender(),r.whitespaceId}_removeZone(e,t){if(this._zones.hasOwnProperty(t)){let i=this._zones[t];return delete this._zones[t],e.removeWhitespace(i.whitespaceId),i.domNode.removeAttribute("monaco-visible-view-zone"),i.domNode.removeAttribute("monaco-view-zone"),i.domNode.domNode.remove(),i.marginDomNode&&(i.marginDomNode.removeAttribute("monaco-visible-view-zone"),i.marginDomNode.removeAttribute("monaco-view-zone"),i.marginDomNode.domNode.remove()),this.setShouldRender(),!0}return!1}_layoutZone(e,t){if(this._zones.hasOwnProperty(t)){let i=this._zones[t],o=this._computeWhitespaceProps(i.delegate);return i.isInHiddenArea=o.isInHiddenArea,e.changeOneWhitespace(i.whitespaceId,o.afterViewLineNumber,o.heightInPx),this._safeCallOnComputedHeight(i.delegate,o.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,t){if(typeof e.onComputedHeight=="function")try{e.onComputedHeight(t)}catch(i){Be(i)}}_safeCallOnDomNodeTop(e,t){if(typeof e.onDomNodeTop=="function")try{e.onDomNodeTop(t)}catch(i){Be(i)}}prepareRender(e){}render(e){let t=e.viewportData.whitespaceViewportData,i={},o=!1;for(let s of t)this._zones[s.id].isInHiddenArea||(i[s.id]=s,o=!0);let r=Object.keys(this._zones);for(let s=0,a=r.length;s{});var YU,ZU,_8e=k(()=>{g8e();Aw();Qe();Tw();qe();Nu();YU=class extends nd{constructor(e){super(),this._context=e,this._options=new ZU(this._context.configuration),this._selection=[],this._renderResult=null,this._context.addEventHandler(this)}dispose(){this._context.removeEventHandler(this),this._renderResult=null,super.dispose()}onConfigurationChanged(e){let t=new ZU(this._context.configuration);return this._options.equals(t)?e.hasChanged(146):(this._options=t,!0)}onCursorStateChanged(e){return this._selection=e.selections,this._options.renderWhitespace==="selection"}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}prepareRender(e){if(this._options.renderWhitespace==="none"){this._renderResult=null;return}let t=e.visibleRange.startLineNumber,o=e.visibleRange.endLineNumber-t+1,r=new Array(o);for(let a=0;aa)continue;let f=h.startLineNumber===a?h.startColumn:c.minColumn,p=h.endLineNumber===a?h.endColumn:c.maxColumn;f=M.endOffset&&(N++,M=i&&i[N]),te!==9&&te!==32||h&&!C&&q<=E)continue;if(u&&q>=L&&q<=E&&te===32){let z=q-1>=0?a.charCodeAt(q-1):0,ae=q+1=0?a.charCodeAt(q-1):0;if(te===32&&z!==32&&z!==9)continue}if(i&&(!M||M.startOffset>q||M.endOffset<=q))continue;let $=e.visibleRangeForPosition(new P(t,q+1));$&&(s?(F=Math.max(F,$.left),te===9?y+=this._renderArrow(f,_,$.left):y+=``):te===9?y+=`
    ${w?"\uFFEB":"\u2192"}
    `:y+=`
    ${String.fromCharCode(x)}
    `)}return s?(F=Math.round(F+_),``+y+""):y}_renderArrow(e,t,i){let o=t/7,r=t,s=e/2,a=i,l={x:0,y:o/2},c={x:100/125*r,y:l.y},d={x:c.x-.2*c.x,y:c.y+.2*c.x},u={x:d.x+.1*c.x,y:d.y+.1*c.x},h={x:u.x+.35*c.x,y:u.y-.35*c.x},f={x:h.x,y:-h.y},p={x:u.x,y:-u.y},g={x:d.x,y:-d.y},_={x:c.x,y:-c.y},b={x:l.x,y:-l.y};return``}render(e,t){if(!this._renderResult)return"";let i=t-e;return i<0||i>=this._renderResult.length?"":this._renderResult[i]}},ZU=class{constructor(e){let t=e.options,i=t.get(50),o=t.get(38);o==="off"?(this.renderWhitespace="none",this.renderWithSVG=!1):o==="svg"?(this.renderWhitespace=t.get(100),this.renderWithSVG=!0):(this.renderWhitespace=t.get(100),this.renderWithSVG=!1),this.spaceWidth=i.spaceWidth,this.middotWidth=i.middotWidth,this.wsmiddotWidth=i.wsmiddotWidth,this.canUseHalfwidthRightwardsArrow=i.canUseHalfwidthRightwardsArrow,this.lineHeight=t.get(67),this.stopRenderingLineAfter=t.get(118)}equals(e){return this.renderWhitespace===e.renderWhitespace&&this.renderWithSVG===e.renderWithSVG&&this.spaceWidth===e.spaceWidth&&this.middotWidth===e.middotWidth&&this.wsmiddotWidth===e.wsmiddotWidth&&this.canUseHalfwidthRightwardsArrow===e.canUseHalfwidthRightwardsArrow&&this.lineHeight===e.lineHeight&&this.stopRenderingLineAfter===e.stopRenderingLineAfter}}});var XU,b8e=k(()=>{we();XU=class{constructor(e,t,i,o){this.selections=e,this.startLineNumber=t.startLineNumber|0,this.endLineNumber=t.endLineNumber|0,this.relativeVerticalOffset=t.relativeVerticalOffset,this.bigNumbersDelta=t.bigNumbersDelta|0,this.lineHeight=t.lineHeight|0,this.whitespaceViewportData=i,this._model=o,this.visibleRange=new S(t.startLineNumber,this._model.getLineMinColumn(t.startLineNumber),t.endLineNumber,this._model.getLineMaxColumn(t.endLineNumber))}getViewLineRenderingData(e){return this._model.getViewportViewLineRenderingData(this.visibleRange,e)}getDecorationsInViewport(){return this._model.getDecorationsInViewport(this.visibleRange)}}});var QU,v8e=k(()=>{QU=class{get type(){return this._theme.type}get value(){return this._theme}constructor(e){this._theme=e}update(e){this._theme=e}getColor(e){return this._theme.getColor(e)}}});var JU,x8e=k(()=>{v8e();JU=class{constructor(e,t,i){this.configuration=e,this.theme=new QU(t),this.viewModel=i,this.viewLayout=i.viewLayout}addEventHandler(e){this.viewModel.addViewEventHandler(e)}removeEventHandler(e){this.viewModel.removeViewEventHandler(e)}}});function Fw(n){try{return n()}catch(e){return Be(e),null}}var qut,Kut,e$,Xhe,w8e=k(()=>{ke();Kr();que();je();nhe();f3e();v3e();CE();I3e();E3e();Wl();Ihe();D3e();N3e();A3e();P3e();O3e();SU();W3e();hhe();V3e();$3e();fhe();q3e();t8e();n8e();o8e();r8e();a8e();c8e();u8e();p8e();m8e();_8e();qe();we();Ui();Zr();wE();b8e();x8e();Fe();Yi();qut=function(n,e,t,i){var o=arguments.length,r=o<3?e:i===null?i=Object.getOwnPropertyDescriptor(e,t):i,s;if(typeof Reflect=="object"&&typeof Reflect.decorate=="function")r=Reflect.decorate(n,e,t,i);else for(var a=n.length-1;a>=0;a--)(s=n[a])&&(r=(o<3?s(r):o>3?s(e,t,r):s(e,t))||r);return o>3&&r&&Object.defineProperty(e,t,r),r},Kut=function(n,e){return function(t,i){e(t,i,n)}},e$=class extends Pf{constructor(e,t,i,o,r,s,a){super(),this._instantiationService=a,this._shouldRecomputeGlyphMarginLanes=!1,this._selections=[new Se(1,1,1,1)],this._renderAnimationFrame=null;let l=new dU(t,o,r,e);this._context=new JU(t,i,o),this._context.addEventHandler(this),this._viewParts=[],this._textAreaHandler=this._instantiationService.createInstance(MV,this._context,l,this._createTextAreaHandlerHelper()),this._viewParts.push(this._textAreaHandler),this._linesContent=Pt(document.createElement("div")),this._linesContent.setClassName("lines-content monaco-editor-background"),this._linesContent.setPosition("absolute"),this.domNode=Pt(document.createElement("div")),this.domNode.setClassName(this._getEditorClassName()),this.domNode.setAttribute("role","code"),this._overflowGuardContainer=Pt(document.createElement("div")),na.write(this._overflowGuardContainer,3),this._overflowGuardContainer.setClassName("overflow-guard"),this._scrollbar=new yU(this._context,this._linesContent,this.domNode,this._overflowGuardContainer),this._viewParts.push(this._scrollbar),this._viewLines=new LU(this._context,this._linesContent),this._viewZones=new GU(this._context),this._viewParts.push(this._viewZones);let c=new BU(this._context);this._viewParts.push(c);let d=new UU(this._context);this._viewParts.push(d);let u=new fU(this._context);this._viewParts.push(u),u.addDynamicOverlay(new vU(this._context)),u.addDynamicOverlay(new jU(this._context)),u.addDynamicOverlay(new kU(this._context)),u.addDynamicOverlay(new wU(this._context)),u.addDynamicOverlay(new YU(this._context));let h=new pU(this._context);this._viewParts.push(h),h.addDynamicOverlay(new xU(this._context)),h.addDynamicOverlay(new EU(this._context)),h.addDynamicOverlay(new IU(this._context)),h.addDynamicOverlay(new DE(this._context)),this._glyphMarginWidgets=new CU(this._context),this._viewParts.push(this._glyphMarginWidgets);let f=new NE(this._context);f.getDomNode().appendChild(this._viewZones.marginDomNode),f.getDomNode().appendChild(h.getDomNode()),f.getDomNode().appendChild(this._glyphMarginWidgets.domNode),this._viewParts.push(f),this._contentWidgets=new gU(this._context,this.domNode),this._viewParts.push(this._contentWidgets),this._viewCursors=new KU(this._context),this._viewParts.push(this._viewCursors),this._overlayWidgets=new FU(this._context,this.domNode),this._viewParts.push(this._overlayWidgets);let p=new VU(this._context);this._viewParts.push(p);let g=new mU(this._context);this._viewParts.push(g);let _=new PU(this._context);if(this._viewParts.push(_),c){let b=this._scrollbar.getOverviewRulerLayoutInfo();b.parent.insertBefore(c.getDomNode(),b.insertBefore)}this._linesContent.appendChild(u.getDomNode()),this._linesContent.appendChild(p.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(f.getDomNode()),this._overflowGuardContainer.appendChild(this._scrollbar.getDomNode()),this._overflowGuardContainer.appendChild(d.getDomNode()),this._overflowGuardContainer.appendChild(this._textAreaHandler.textArea),this._overflowGuardContainer.appendChild(this._textAreaHandler.textAreaCover),this._overflowGuardContainer.appendChild(this._overlayWidgets.getDomNode()),this._overflowGuardContainer.appendChild(_.getDomNode()),this._overflowGuardContainer.appendChild(g.domNode),this.domNode.appendChild(this._overflowGuardContainer),s?(s.appendChild(this._contentWidgets.overflowingContentWidgetsDomNode.domNode),s.appendChild(this._overlayWidgets.overflowingOverlayWidgetsDomNode.domNode)):(this.domNode.appendChild(this._contentWidgets.overflowingContentWidgetsDomNode),this.domNode.appendChild(this._overlayWidgets.overflowingOverlayWidgetsDomNode)),this._applyLayout(),this._pointerHandler=this._register(new RV(this._context,l,this._createPointerHandlerHelper()))}_computeGlyphMarginLanes(){let e=this._context.viewModel.model,t=this._context.viewModel.glyphLanes,i=[],o=0;i=i.concat(e.getAllMarginDecorations().map(r=>{let s=r.options.glyphMargin?.position??tl.Center;return o=Math.max(o,r.range.endLineNumber),{range:r.range,lane:s,persist:r.options.glyphMargin?.persistLane}})),i=i.concat(this._glyphMarginWidgets.getWidgets().map(r=>{let s=e.validateRange(r.preference.range);return o=Math.max(o,s.endLineNumber),{range:s,lane:r.preference.lane}})),i.sort((r,s)=>S.compareRangesUsingStarts(r.range,s.range)),t.reset(o);for(let r of i)t.push(r.lane,r.range,r.persist);return t}_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:()=>{let e=this._viewCursors.getLastRenderData()||[],t=this._textAreaHandler.getLastRenderData();return new IV(e,t)},renderNow:()=>{this.render(!0,!1)},shouldSuppressMouseDownOnViewZone:e=>this._viewZones.shouldSuppressMouseDownOnViewZone(e),shouldSuppressMouseDownOnWidget:e=>this._contentWidgets.shouldSuppressMouseDownOnWidget(e),getPositionFromDOMInfo:(e,t)=>(this._flushAccumulatedAndRenderNow(),this._viewLines.getPositionFromDOMInfo(e,t)),visibleRangeForPosition:(e,t)=>(this._flushAccumulatedAndRenderNow(),this._viewLines.visibleRangeForPosition(new P(e,t))),getLineWidth:e=>(this._flushAccumulatedAndRenderNow(),this._viewLines.getLineWidth(e))}}_createTextAreaHandlerHelper(){return{visibleRangeForPosition:e=>(this._flushAccumulatedAndRenderNow(),this._viewLines.visibleRangeForPosition(e))}}_applyLayout(){let t=this._context.configuration.options.get(146);this.domNode.setWidth(t.width),this.domNode.setHeight(t.height),this._overflowGuardContainer.setWidth(t.width),this._overflowGuardContainer.setHeight(t.height),this._linesContent.setWidth(16777216),this._linesContent.setHeight(16777216)}_getEditorClassName(){let e=this._textAreaHandler.isFocused()?" focused":"";return this._context.configuration.options.get(143)+" "+UA(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}onDecorationsChanged(e){return e.affectsGlyphMargin&&(this._shouldRecomputeGlyphMarginLanes=!0),!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(let e of this._viewParts)e.dispose();super.dispose()}_scheduleRender(){if(this._store.isDisposed)throw new Nt;if(this._renderAnimationFrame===null){let e=this._createCoordinatedRendering();this._renderAnimationFrame=Xhe.INSTANCE.scheduleCoordinatedRendering({window:Me(this.domNode?.domNode),prepareRenderText:()=>{if(this._store.isDisposed)throw new Nt;try{return e.prepareRenderText()}finally{this._renderAnimationFrame=null}},renderText:()=>{if(this._store.isDisposed)throw new Nt;return e.renderText()},prepareRender:(t,i)=>{if(this._store.isDisposed)throw new Nt;return e.prepareRender(t,i)},render:(t,i)=>{if(this._store.isDisposed)throw new Nt;return e.render(t,i)}})}}_flushAccumulatedAndRenderNow(){let e=this._createCoordinatedRendering();Fw(()=>e.prepareRenderText());let t=Fw(()=>e.renderText());if(t){let[i,o]=t;Fw(()=>e.prepareRender(i,o)),Fw(()=>e.render(i,o))}}_getViewPartsToRender(){let e=[],t=0;for(let i of this._viewParts)i.shouldRender()&&(e[t++]=i);return e}_createCoordinatedRendering(){return{prepareRenderText:()=>{if(this._shouldRecomputeGlyphMarginLanes){this._shouldRecomputeGlyphMarginLanes=!1;let e=this._computeGlyphMarginLanes();this._context.configuration.setGlyphMarginDecorationLaneCount(e.requiredLanes)}Bg.onRenderStart()},renderText:()=>{if(!this.domNode.domNode.isConnected)return null;let e=this._getViewPartsToRender();if(!this._viewLines.shouldRender()&&e.length===0)return null;let t=this._context.viewLayout.getLinesViewportData();this._context.viewModel.setViewport(t.startLineNumber,t.endLineNumber,t.centeredLineNumber);let i=new XU(this._selections,t,this._context.viewLayout.getWhitespaceViewportData(),this._context.viewModel);return this._contentWidgets.shouldRender()&&this._contentWidgets.onBeforeRender(i),this._viewLines.shouldRender()&&(this._viewLines.renderText(i),this._viewLines.onDidRender(),e=this._getViewPartsToRender()),[e,new xV(this._context.viewLayout,i,this._viewLines)]},prepareRender:(e,t)=>{for(let i of e)i.prepareRender(t)},render:(e,t)=>{for(let i of e)i.render(t),i.onDidRender()}}}delegateVerticalScrollbarPointerDown(e){this._scrollbar.delegateVerticalScrollbarPointerDown(e)}delegateScrollFromMouseWheelEvent(e){this._scrollbar.delegateScrollFromMouseWheelEvent(e)}restoreState(e){this._context.viewModel.viewLayout.setScrollPosition({scrollTop:e.scrollTop,scrollLeft:e.scrollLeft},1),this._context.viewModel.visibleLinesStabilized()}getOffsetForColumn(e,t){let i=this._context.viewModel.model.validatePosition({lineNumber:e,column:t}),o=this._context.viewModel.coordinatesConverter.convertModelPositionToViewPosition(i);this._flushAccumulatedAndRenderNow();let r=this._viewLines.visibleRangeForPosition(new P(o.lineNumber,o.column));return r?r.left:-1}getTargetAtClientPoint(e,t){let i=this._pointerHandler.getTargetAtClientPoint(e,t);return i?WE.convertViewToModelMouseTarget(i,this._context.viewModel.coordinatesConverter):null}createOverviewRuler(e){return new zU(this._context,e)}change(e){this._viewZones.changeViewZones(e),this._scheduleRender()}render(e,t){if(t){this._viewLines.forceShouldRender();for(let i of this._viewParts)i.forceShouldRender()}e?this._flushAccumulatedAndRenderNow():this._scheduleRender()}writeScreenReaderContent(e){this._textAreaHandler.writeScreenReaderContent(e)}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){this._contentWidgets.setWidgetPosition(e.widget,e.position?.position??null,e.position?.secondaryPosition??null,e.position?.preference??null,e.position?.positionAffinity??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){this._overlayWidgets.setWidgetPosition(e.widget,e.position)&&this._scheduleRender()}removeOverlayWidget(e){this._overlayWidgets.removeWidget(e.widget),this._scheduleRender()}addGlyphMarginWidget(e){this._glyphMarginWidgets.addWidget(e.widget),this._shouldRecomputeGlyphMarginLanes=!0,this._scheduleRender()}layoutGlyphMarginWidget(e){let t=e.position;this._glyphMarginWidgets.setWidgetPosition(e.widget,t)&&(this._shouldRecomputeGlyphMarginLanes=!0,this._scheduleRender())}removeGlyphMarginWidget(e){this._glyphMarginWidgets.removeWidget(e.widget),this._shouldRecomputeGlyphMarginLanes=!0,this._scheduleRender()}};e$=qut([Kut(6,he)],e$);Xhe=class n{static{this.INSTANCE=new n}constructor(){this._coordinatedRenderings=[],this._animationFrameRunners=new Map}scheduleCoordinatedRendering(e){return this._coordinatedRenderings.push(e),this._scheduleRender(e.window),{dispose:()=>{let t=this._coordinatedRenderings.indexOf(e);if(t!==-1&&(this._coordinatedRenderings.splice(t,1),this._coordinatedRenderings.length===0)){for(let[i,o]of this._animationFrameRunners)o.dispose();this._animationFrameRunners.clear()}}}}_scheduleRender(e){if(!this._animationFrameRunners.has(e)){let t=()=>{this._animationFrameRunners.delete(e),this._onRenderScheduled()};this._animationFrameRunners.set(e,uL(e,t,100))}}_onRenderScheduled(){let e=this._coordinatedRenderings.slice(0);this._coordinatedRenderings=[];for(let i of e)Fw(()=>i.prepareRenderText());let t=[];for(let i=0,o=e.length;ir.renderText())}for(let i=0,o=e.length;ir.prepareRender(a,l))}for(let i=0,o=e.length;ir.render(a,l))}}}});function y8e(n){return n==null?!0:n===Vc.Right||n===Vc.Both}function C8e(n){return n==null?!0:n===Vc.Left||n===Vc.Both}var $b,$E,Qhe=k(()=>{bf();qe();Zr();$b=class{constructor(e,t,i,o,r){this.injectionOffsets=e,this.injectionOptions=t,this.breakOffsets=i,this.breakOffsetsVisibleColumn=o,this.wrappedTextIndentLength=r}getOutputLineCount(){return this.breakOffsets.length}getMinOutputOffset(e){return e>0?this.wrappedTextIndentLength:0}getLineLength(e){let t=e>0?this.breakOffsets[e-1]:0,o=this.breakOffsets[e]-t;return e>0&&(o+=this.wrappedTextIndentLength),o}getMaxOutputOffset(e){return this.getLineLength(e)}translateToInputOffset(e,t){e>0&&(t=Math.max(0,t-this.wrappedTextIndentLength));let o=e===0?t:this.breakOffsets[e-1]+t;if(this.injectionOffsets!==null)for(let r=0;rthis.injectionOffsets[r];r++)o0?this.breakOffsets[r-1]:0,t===0)if(e<=s)o=r-1;else if(e>l)i=r+1;else break;else if(e=l)i=r+1;else break}let a=e-s;return r>0&&(a+=this.wrappedTextIndentLength),new $E(r,a)}normalizeOutputPosition(e,t,i){if(this.injectionOffsets!==null){let o=this.outputPositionToOffsetInInputWithInjections(e,t),r=this.normalizeOffsetInInputWithInjectionsAroundInjections(o,i);if(r!==o)return this.offsetInInputWithInjectionsToOutputPosition(r,i)}if(i===0){if(e>0&&t===this.getMinOutputOffset(e))return new $E(e-1,this.getMaxOutputOffset(e-1))}else if(i===1){let o=this.getOutputLineCount()-1;if(e0&&(t=Math.max(0,t-this.wrappedTextIndentLength)),(e>0?this.breakOffsets[e-1]:0)+t}normalizeOffsetInInputWithInjectionsAroundInjections(e,t){let i=this.getInjectedTextAtOffset(e);if(!i)return e;if(t===2){if(e===i.offsetInInputWithInjections+i.length&&y8e(this.injectionOptions[i.injectedTextIndex].cursorStops))return i.offsetInInputWithInjections+i.length;{let o=i.offsetInInputWithInjections;if(C8e(this.injectionOptions[i.injectedTextIndex].cursorStops))return o;let r=i.injectedTextIndex-1;for(;r>=0&&this.injectionOffsets[r]===this.injectionOffsets[i.injectedTextIndex]&&!(y8e(this.injectionOptions[r].cursorStops)||(o-=this.injectionOptions[r].content.length,C8e(this.injectionOptions[r].cursorStops)));)r--;return o}}else if(t===1||t===4){let o=i.offsetInInputWithInjections+i.length,r=i.injectedTextIndex;for(;r+1=0&&this.injectionOffsets[r-1]===this.injectionOffsets[r];)o-=this.injectionOptions[r-1].content.length,r--;return o}kx(t)}getInjectedText(e,t){let i=this.outputPositionToOffsetInInputWithInjections(e,t),o=this.getInjectedTextAtOffset(i);return o?{options:this.injectionOptions[o.injectedTextIndex]}:null}getInjectedTextAtOffset(e){let t=this.injectionOffsets,i=this.injectionOptions;if(t!==null){let o=0;for(let r=0;re)break;if(e<=l)return{injectedTextIndex:r,offsetInInputWithInjections:a,length:s};o+=s}}}};$E=class{constructor(e,t){this.outputLineIndex=e,this.outputOffset=t}toString(){return`${this.outputLineIndex}:${this.outputOffset}`}toPosition(e){return new P(e+this.outputLineIndex,this.outputOffset+1)}}});function Yut(n,e,t,i,o,r,s,a){function l(N){let M=a[N];if(M){let F=Wd.applyInjectedText(e[N],M),q=M.map($=>$.options),te=M.map($=>$.column-1);return new $b(te,q,[F.length],[],0)}else return null}if(o===-1){let N=[];for(let M=0,F=e.length;Mc?(F=0,q=0):te=c-ae}let $=M.substr(F),z=Zut($,q,i,te,p,h);g[N]=F,_[N]=q,b[N]=$,v[N]=z[0],x[N]=z[1]}let w=p.build(),y=Gut?.createHTML(w)??w;f.innerHTML=y,f.style.position="absolute",f.style.top="10000",s==="keepAll"?(f.style.wordBreak="keep-all",f.style.overflowWrap="anywhere"):(f.style.wordBreak="inherit",f.style.overflowWrap="break-word"),n.document.body.appendChild(f);let C=document.createRange(),L=Array.prototype.slice.call(f.children,0),E=[];for(let N=0;Nce.options),X=ue.map(ce=>ce.column-1)):(ae=null,X=null),E[N]=new $b(X,ae,F,z,te)}return f.remove(),E}function Zut(n,e,t,i,o,r){if(r!==0){let h=String(r);o.appendString('
    ');let s=n.length,a=e,l=0,c=[],d=[],u=0");for(let h=0;h"),c[h]=l,d[h]=a;let f=u;u=h+1"),c[n.length]=l,d[n.length]=a,o.appendString("
    "),[c,d]}function Xut(n,e,t,i){if(t.length<=1)return null;let o=Array.prototype.slice.call(e.children,0),r=[];try{efe(n,o,i,0,null,t.length-1,null,r)}catch(s){return console.log(s),null}return r.length===0?null:(r.push(t.length),r)}function efe(n,e,t,i,o,r,s,a){if(i===r||(o=o||Jhe(n,e,t[i],t[i+1]),s=s||Jhe(n,e,t[r],t[r+1]),Math.abs(o[0].top-s[0].top)<=.1))return;if(i+1===r){a.push(r);return}let l=i+(r-i)/2|0,c=Jhe(n,e,t[l],t[l+1]);efe(n,e,t,i,o,l,c,a),efe(n,e,t,l,c,r,s,a)}function Jhe(n,e,t,i){return n.setStart(e[t/16384|0].firstChild,t%16384),n.setEnd(e[i/16384|0].firstChild,i%16384),n.getClientRects()}var Gut,t$,S8e=k(()=>{Rm();Qe();yi();bu();Y_();Qhe();vw();Gut=Tl("domLineBreaksComputer",{createHTML:n=>n}),t$=class n{static create(e){return new n(new WeakRef(e))}constructor(e){this.targetWindow=e}createLineBreaksComputer(e,t,i,o,r){let s=[],a=[];return{addRequest:(l,c,d)=>{s.push(l),a.push(c)},finalize:()=>Yut(lf(this.targetWindow.deref()),s,e,t,i,o,r,a)}}}});var i$,k8e=k(()=>{ke();je();j();i$=class extends D{constructor(){super(),this._editor=null,this._instantiationService=null,this._instances=this._register(new ax),this._pending=new Map,this._finishedInstantiation=[],this._finishedInstantiation[0]=!1,this._finishedInstantiation[1]=!1,this._finishedInstantiation[2]=!1,this._finishedInstantiation[3]=!1}initialize(e,t,i){this._editor=e,this._instantiationService=i;for(let o of t){if(this._pending.has(o.id)){Be(new Error(`Cannot have two contributions with the same id ${o.id}`));continue}this._pending.set(o.id,o)}this._instantiateSome(0),this._register(E1(Me(this._editor.getDomNode()),()=>{this._instantiateSome(1)})),this._register(E1(Me(this._editor.getDomNode()),()=>{this._instantiateSome(2)})),this._register(E1(Me(this._editor.getDomNode()),()=>{this._instantiateSome(3)},5e3))}saveViewState(){let e={};for(let[t,i]of this._instances)typeof i.saveViewState=="function"&&(e[t]=i.saveViewState());return e}restoreViewState(e){for(let[t,i]of this._instances)typeof i.restoreViewState=="function"&&i.restoreViewState(e[t])}get(e){return this._instantiateById(e),this._instances.get(e)||null}onBeforeInteractionEvent(){this._instantiateSome(2)}onAfterModelAttached(){return E1(Me(this._editor?.getDomNode()),()=>{this._instantiateSome(1)},50)}_instantiateSome(e){if(this._finishedInstantiation[e])return;this._finishedInstantiation[e]=!0;let t=this._findPendingContributionsByInstantiation(e);for(let i of t)this._instantiateById(i.id)}_findPendingContributionsByInstantiation(e){let t=[];for(let[,i]of this._pending)i.instantiation===e&&t.push(i);return t}_instantiateById(e){let t=this._pending.get(e);if(t){if(this._pending.delete(e),!this._instantiationService||!this._editor)throw new Error("Cannot instantiate contributions before being initialized!");try{let i=this._instantiationService.createInstance(t.ctor,this._editor);this._instances.set(t.id,i),typeof i.restoreViewState=="function"&&t.instantiation!==0&&console.warn(`Editor contribution '${t.id}' should be eager instantiated because it uses saveViewState / restoreViewState.`)}catch(i){Be(i)}}}}});var jE,tfe=k(()=>{jE=class{constructor(e,t,i,o,r,s,a){this.id=e,this.label=t,this.alias=i,this.metadata=o,this._precondition=r,this._run=s,this._contextKeyService=a}isSupported(){return this._contextKeyService.contextMatchesRules(this._precondition)}run(e){return this.isSupported()?this._run(e):Promise.resolve(void 0)}}});function Qut(n,e,t,i,o,r,s,a){if(o===-1)return null;let l=t.length;if(l<=1)return null;let c=a==="keepAll",d=e.breakOffsets,u=e.breakOffsetsVisibleColumn,h=I8e(t,i,o,r,s),f=o-h,p=nfe,g=ofe,_=0,b=0,v=0,x=o,w=d.length,y=0;if(y>=0){let C=Math.abs(u[y]-x);for(;y+1=C)break;C=L,y++}}for(;yC&&(C=b,L=v);let E=0,N=0,M=0,F=0;if(L<=x){let te=L,$=C===0?0:t.charCodeAt(C-1),z=C===0?0:n.get($),ae=!0;for(let X=C;Xb&&rfe($,z,ce,B,c)&&(E=ue,N=te),te+=Je,te>x){ue>b?(M=ue,F=te-Je):(M=X+1,F=te),te-N>f&&(E=0),ae=!1;break}$=ce,z=B}if(ae){_>0&&(p[_]=d[d.length-1],g[_]=u[d.length-1],_++);break}}if(E===0){let te=L,$=t.charCodeAt(C),z=n.get($),ae=!1;for(let X=C-1;X>=b;X--){let ue=X+1,ce=t.charCodeAt(X);if(ce===9){ae=!0;break}let B,Je;if(Lm(ce)?(X--,B=0,Je=2):(B=n.get(ce),Je=hh(ce)?r:1),te<=x){if(M===0&&(M=ue,F=te),te<=x-f)break;if(rfe(ce,B,$,z,c)){E=ue,N=te;break}}te-=Je,$=ce,z=B}if(E!==0){let X=f-(F-N);if(X<=i){let ue=t.charCodeAt(M),ce;to(ue)?ce=2:ce=_P(ue,F,i,r),X-ce<0&&(E=0)}}if(ae){y--;continue}}if(E===0&&(E=M,N=F),E<=b){let te=t.charCodeAt(b);to(te)?(E=b+2,N=v+2):(E=b+1,N=v+_P(te,v,i,r))}for(b=E,p[_]=E,v=N,g[_]=N,_++,x=N+f;y<0||y=q)break;q=te,y++}}return _===0?null:(p.length=_,g.length=_,nfe=e.breakOffsets,ofe=e.breakOffsetsVisibleColumn,e.breakOffsets=p,e.breakOffsetsVisibleColumn=g,e.wrappedTextIndentLength=h,e)}function Jut(n,e,t,i,o,r,s,a){let l=Wd.applyInjectedText(e,t),c,d;if(t&&t.length>0?(c=t.map(N=>N.options),d=t.map(N=>N.column-1)):(c=null,d=null),o===-1)return c?new $b(d,c,[l.length],[],0):null;let u=l.length;if(u<=1)return c?new $b(d,c,[l.length],[],0):null;let h=a==="keepAll",f=I8e(l,i,o,r,s),p=o-f,g=[],_=[],b=0,v=0,x=0,w=o,y=l.charCodeAt(0),C=n.get(y),L=_P(y,0,i,r),E=1;to(y)&&(L+=1,y=l.charCodeAt(1),C=n.get(y),E++);for(let N=E;Nw&&((v===0||L-x>p)&&(v=M,x=L-te),g[b]=v,_[b]=x,b++,w=x+p,v=0),y=F,C=q}return b===0&&(!t||t.length===0)?null:(g[b]=u,_[b]=L,new $b(d,c,g,_,f))}function _P(n,e,t,i){return n===9?t-e%t:hh(n)||n<32?i:1}function L8e(n,e){return e-n%e}function rfe(n,e,t,i,o){return t!==32&&(e===2&&i!==2||e!==1&&i===1||!o&&e===3&&i!==2||!o&&i===3&&e!==1)}function I8e(n,e,t,i,o){let r=0;if(o!==0){let s=bo(n);if(s!==-1){for(let l=0;lt&&(r=0)}}return r}var n$,ife,nfe,ofe,E8e=k(()=>{Qe();q1();vw();Qhe();n$=class n{static create(e){return new n(e.get(135),e.get(134))}constructor(e,t){this.classifier=new ife(e,t)}createLineBreaksComputer(e,t,i,o,r){let s=[],a=[],l=[];return{addRequest:(c,d,u)=>{s.push(c),a.push(d),l.push(u)},finalize:()=>{let c=e.typicalFullwidthCharacterWidth/e.typicalHalfwidthCharacterWidth,d=[];for(let u=0,h=s.length;u=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}},nfe=[],ofe=[]});var bP,T8e=k(()=>{Bu();qe();we();Ui();bP=class n{constructor(e){this._selTrackedRange=null,this._trackSelection=!0,this._setState(e,new Qr(new S(1,1,1,1),0,0,new P(1,1),0),new Qr(new S(1,1,1,1),0,0,new P(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 Jt(this.modelState,this.viewState)}readSelectionFromMarkers(e){let t=e.model._getTrackedRange(this._selTrackedRange);return this.modelState.selection.isEmpty()&&!t.isEmpty()?Se.fromRange(t.collapseToEnd(),this.modelState.selection.getDirection()):Se.fromRange(t,this.modelState.selection.getDirection())}ensureValidState(e){this._setState(e,this.modelState,this.viewState)}setState(e,t,i){this._setState(e,t,i)}static _validatePositionWithCache(e,t,i,o){return t.equals(i)?o:e.normalizePosition(t,2)}static _validateViewState(e,t){let i=t.position,o=t.selectionStart.getStartPosition(),r=t.selectionStart.getEndPosition(),s=e.normalizePosition(i,2),a=this._validatePositionWithCache(e,o,i,s),l=this._validatePositionWithCache(e,r,o,a);return i.equals(s)&&o.equals(a)&&r.equals(l)?t:new Qr(S.fromPositions(a,l),t.selectionStartKind,t.selectionStartLeftoverVisibleColumns+o.column-a.column,s,t.leftoverVisibleColumns+i.column-s.column)}_setState(e,t,i){if(i&&(i=n._validateViewState(e.viewModel,i)),t){let o=e.model.validateRange(t.selectionStart),r=t.selectionStart.equalsRange(o)?t.selectionStartLeftoverVisibleColumns:0,s=e.model.validatePosition(t.position),a=t.position.equals(s)?t.leftoverVisibleColumns:0;t=new Qr(o,t.selectionStartKind,r,s,a)}else{if(!i)return;let o=e.model.validateRange(e.coordinatesConverter.convertViewRangeToModelRange(i.selectionStart)),r=e.model.validatePosition(e.coordinatesConverter.convertViewPositionToModelPosition(i.position));t=new Qr(o,i.selectionStartKind,i.selectionStartLeftoverVisibleColumns,r,i.leftoverVisibleColumns)}if(i){let o=e.coordinatesConverter.validateViewRange(i.selectionStart,t.selectionStart),r=e.coordinatesConverter.validateViewPosition(i.position,t.position);i=new Qr(o,t.selectionStartKind,t.selectionStartLeftoverVisibleColumns,r,t.leftoverVisibleColumns)}else{let o=e.coordinatesConverter.convertModelPositionToViewPosition(new P(t.selectionStart.startLineNumber,t.selectionStart.startColumn)),r=e.coordinatesConverter.convertModelPositionToViewPosition(new P(t.selectionStart.endLineNumber,t.selectionStart.endColumn)),s=new S(o.lineNumber,o.column,r.lineNumber,r.column),a=e.coordinatesConverter.convertModelPositionToViewPosition(t.position);i=new Qr(s,t.selectionStartKind,t.selectionStartLeftoverVisibleColumns,a,t.leftoverVisibleColumns)}this.modelState=t,this.viewState=i,this._updateTrackedRange(e)}}});var vP,D8e=k(()=>{at();Ad();Bu();T8e();qe();we();Ui();vP=class{constructor(e){this.context=e,this.cursors=[new bP(e)],this.lastAddedCursorIndex=0}dispose(){for(let e of this.cursors)e.dispose(this.context)}startTrackingSelections(){for(let e of this.cursors)e.startTrackingSelection(this.context)}stopTrackingSelections(){for(let e of this.cursors)e.stopTrackingSelection(this.context)}updateContext(e){this.context=e}ensureValidState(){for(let 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 ANe(this.cursors,mr(e=>e.viewState.position,P.compare)).viewState.position}getBottomMostViewPosition(){return RNe(this.cursors,mr(e=>e.viewState.position,P.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(Jt.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){let t=this.cursors.length-1,i=e.length;if(ti){let o=t-i;for(let r=0;r=e+1&&this.lastAddedCursorIndex--,this.cursors[e+1].dispose(this.context),this.cursors.splice(e+1,1)}normalize(){if(this.cursors.length===1)return;let e=this.cursors.slice(0),t=[];for(let i=0,o=e.length;ii.selection,S.compareRangesUsingStarts));for(let i=0;iu&&g.index--;e.splice(u,1),t.splice(d,1),this._removeSecondaryCursor(u-1),i--}}}}});var xP,N8e=k(()=>{xP=class{constructor(e,t,i,o){this._cursorContextBrand=void 0,this.model=e,this.viewModel=t,this.coordinatesConverter=i,this.cursorConfig=o}}});var o$,r$,s$,a$,zg,w0,l$,c$,y0,wP,qE,KE,jb,d$,u$,h$,f$,p$,m$=k(()=>{o$=class{constructor(){this.type=0}},r$=class{constructor(){this.type=1}},s$=class{constructor(e){this.type=2,this._source=e}hasChanged(e){return this._source.hasChanged(e)}},a$=class{constructor(e,t,i){this.selections=e,this.modelSelections=t,this.reason=i,this.type=3}},zg=class{constructor(e){this.type=4,e?(this.affectsMinimap=e.affectsMinimap,this.affectsOverviewRuler=e.affectsOverviewRuler,this.affectsGlyphMargin=e.affectsGlyphMargin,this.affectsLineNumber=e.affectsLineNumber):(this.affectsMinimap=!0,this.affectsOverviewRuler=!0,this.affectsGlyphMargin=!0,this.affectsLineNumber=!0)}},w0=class{constructor(){this.type=5}},l$=class{constructor(e){this.type=6,this.isFocused=e}},c$=class{constructor(){this.type=7}},y0=class{constructor(){this.type=8}},wP=class{constructor(e,t){this.fromLineNumber=e,this.count=t,this.type=9}},qE=class{constructor(e,t){this.type=10,this.fromLineNumber=e,this.toLineNumber=t}},KE=class{constructor(e,t){this.type=11,this.fromLineNumber=e,this.toLineNumber=t}},jb=class{constructor(e,t,i,o,r,s,a){this.source=e,this.minimalReveal=t,this.range=i,this.selections=o,this.verticalType=r,this.revealHorizontal=s,this.scrollType=a,this.type=12}},d$=class{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}},u$=class{constructor(e){this.theme=e,this.type=14}},h$=class{constructor(e){this.type=15,this.ranges=e}},f$=class{constructor(){this.type=16}},p$=class{constructor(){this.type=17}}});var g$,sfe,_$,b$,v$,x$,w$,y$,C$,S$,k$,L$,I$,E$,T$,D$=k(()=>{Ie();j();g$=class extends D{constructor(){super(),this._onEvent=this._register(new A),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 t=0,i=this._outgoingEvents.length;t0;){if(this._collector||this._isConsumingViewEventQueue)return;let e=this._outgoingEvents.shift();e.isNoOp()||this._onEvent.fire(e)}}addViewEventHandler(e){for(let t=0,i=this._eventHandlers.length;t0&&this._emitMany(t)}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;){let e=this._viewEventQueue;this._viewEventQueue=null;let t=this._eventHandlers.slice(0);for(let i of t)i.handleEvents(e)}}},sfe=class{constructor(){this.viewEvents=[],this.outgoingEvents=[]}emitViewEvent(e){this.viewEvents.push(e)}emitOutgoingEvent(e){this.outgoingEvents.push(e)}},_$=class n{constructor(e,t,i,o){this.kind=0,this._oldContentWidth=e,this._oldContentHeight=t,this.contentWidth=i,this.contentHeight=o,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 n(this._oldContentWidth,this._oldContentHeight,e.contentWidth,e.contentHeight)}},b$=class n{constructor(e,t){this.kind=1,this.oldHasFocus=e,this.hasFocus=t}isNoOp(){return this.oldHasFocus===this.hasFocus}attemptToMerge(e){return e.kind!==this.kind?null:new n(this.oldHasFocus,e.hasFocus)}},v$=class n{constructor(e,t,i,o,r,s,a,l){this.kind=2,this._oldScrollWidth=e,this._oldScrollLeft=t,this._oldScrollHeight=i,this._oldScrollTop=o,this.scrollWidth=r,this.scrollLeft=s,this.scrollHeight=a,this.scrollTop=l,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 n(this._oldScrollWidth,this._oldScrollLeft,this._oldScrollHeight,this._oldScrollTop,e.scrollWidth,e.scrollLeft,e.scrollHeight,e.scrollTop)}},x$=class{constructor(){this.kind=3}isNoOp(){return!1}attemptToMerge(e){return e.kind!==this.kind?null:this}},w$=class{constructor(){this.kind=4}isNoOp(){return!1}attemptToMerge(e){return e.kind!==this.kind?null:this}},y$=class n{constructor(e,t,i,o,r,s,a){this.kind=6,this.oldSelections=e,this.selections=t,this.oldModelVersionId=i,this.modelVersionId=o,this.source=r,this.reason=s,this.reachedMaxCursorCount=a}static _selectionsAreEqual(e,t){if(!e&&!t)return!0;if(!e||!t)return!1;let i=e.length,o=t.length;if(i!==o)return!1;for(let r=0;r{je();Qe();D8e();Bu();N8e();FV();lU();dP();we();Ui();vw();m$();j();D$();N$=class extends D{constructor(e,t,i,o){super(),this._model=e,this._knownModelVersionId=this._model.getVersionId(),this._viewModel=t,this._coordinatesConverter=i,this.context=new xP(this._model,this._viewModel,this._coordinatesConverter,o),this._cursors=new vP(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=Yt(this._autoClosedActions),super.dispose()}updateConfiguration(e){this.context=new xP(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){let e=this._cursors.getSelections();for(let t=0;ts&&(o=o.slice(0,s),r=!0);let a=yP.from(this._model,this);return this._cursors.setStates(o),this._cursors.normalize(),this._columnSelectData=null,this._validateAutoClosedActions(),this._emitStateChangedIfNecessary(e,t,i,a,r)}setCursorColumnSelectData(e){this._columnSelectData=e}revealAll(e,t,i,o,r,s){let a=this._cursors.getViewPositions(),l=null,c=null;a.length>1?c=this._cursors.getViewSelections():l=S.fromPositions(a[0],a[0]),e.emitViewEvent(new jb(t,i,l,c,o,r,s))}revealPrimary(e,t,i,o,r,s){let l=[this._cursors.getPrimaryCursor().viewState.selection];e.emitViewEvent(new jb(t,i,null,l,o,r,s))}saveState(){let e=[],t=this._cursors.getSelections();for(let i=0,o=t.length;i0){let r=Jt.fromModelSelections(i.resultingSelection);this.setStates(e,"modelChange",i.isUndoing?5:i.isRedoing?6:2,r)&&this.revealAll(e,"modelChange",!1,0,!0,0)}else{let r=this._cursors.readSelectionFromMarkers();this.setStates(e,"modelChange",2,Jt.fromModelSelections(r))}}}getSelection(){return this._cursors.getPrimaryCursor().modelState.selection}getTopMostViewPosition(){return this._cursors.getTopMostViewPosition()}getBottomMostViewPosition(){return this._cursors.getBottomMostViewPosition()}getCursorColumnSelectData(){if(this._columnSelectData)return this._columnSelectData;let e=this._cursors.getPrimaryCursor(),t=e.viewState.selectionStart.getStartPosition(),i=e.viewState.position;return{isReal:!1,fromViewLineNumber:t.lineNumber,fromViewVisualColumn:this.context.cursorConfig.visibleColumnFromColumn(this._viewModel,t),toViewLineNumber:i.lineNumber,toViewVisualColumn:this.context.cursorConfig.visibleColumnFromColumn(this._viewModel,i)}}getSelections(){return this._cursors.getSelections()}setSelections(e,t,i,o){this.setStates(e,t,o,Jt.fromModelSelections(i))}getPrevEditOperationType(){return this._prevEditOperationType}setPrevEditOperationType(e){this._prevEditOperationType=e}_pushAutoClosedAction(e,t){let i=[],o=[];for(let a=0,l=e.length;a0&&this._pushAutoClosedAction(i,o),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,t,i,o,r){let s=yP.from(this._model,this);if(s.equals(o))return!1;let a=this._cursors.getSelections(),l=this._cursors.getViewSelections();if(e.emitViewEvent(new a$(l,a,i)),!o||o.cursorState.length!==s.cursorState.length||s.cursorState.some((c,d)=>!c.modelState.equals(o.cursorState[d].modelState))){let c=o?o.cursorState.map(u=>u.modelState.selection):null,d=o?o.modelVersionId:0;e.emitOutgoingEvent(new y$(c,a,d,s.modelVersionId,t||"keyboard",i,r))}return!0}_findAutoClosingPairs(e){if(!e.length)return null;let t=[];for(let i=0,o=e.length;i=0)return null;let s=r.text.match(/([)\]}>'"`])([^)\]}>'"`]*)$/);if(!s)return null;let a=s[1],l=this.context.cursorConfig.autoClosingPairs.autoClosingPairsCloseSingleChar.get(a);if(!l||l.length!==1)return null;let c=l[0].open,d=r.text.length-s[2].length-1,u=r.text.lastIndexOf(c,d-1);if(u===-1)return null;t.push([u,d])}return t}executeEdits(e,t,i,o){let r=null;t==="snippet"&&(r=this._findAutoClosingPairs(i)),r&&(i[0]._isTracked=!0);let s=[],a=[],l=this._model.pushEditOperations(this.getSelections(),i,c=>{if(r)for(let u=0,h=r.length;u0&&this._pushAutoClosedAction(s,a)}_executeEdit(e,t,i,o=0){if(this.context.cursorConfig.readOnly)return;let r=yP.from(this._model,this);this._cursors.stopTrackingSelections(),this._isHandling=!0;try{this._cursors.ensureValidState(),e()}catch(s){Be(s)}this._isHandling=!1,this._cursors.startTrackingSelections(),this._validateAutoClosedActions(),this._emitStateChangedIfNecessary(t,i,o,r,!1)&&this.revealAll(t,i,!1,0,!0,0)}getAutoClosedCharacters(){return R$.getAllAutoClosedCharacters(this._autoClosedActions)}startComposition(e){this._compositionState=new cfe(this._model,this.getSelections())}endComposition(e,t){let i=this._compositionState?this._compositionState.deduceOutcome(this._model,this.getSelections()):null;this._compositionState=null,this._executeEdit(()=>{t==="keyboard"&&this._executeEditOperation(Hh.compositionEndWithInterceptors(this._prevEditOperationType,this.context.cursorConfig,this._model,i,this.getSelections(),this.getAutoClosedCharacters()))},e,t)}type(e,t,i){this._executeEdit(()=>{if(i==="keyboard"){let o=t.length,r=0;for(;r{let c=l.getPosition();return new Se(c.lineNumber,c.column+r,c.lineNumber,c.column+r)});this.setSelections(e,s,a,0)}return}this._executeEdit(()=>{this._executeEditOperation(Hh.compositionType(this._prevEditOperationType,this.context.cursorConfig,this._model,this.getSelections(),t,i,o,r))},e,s)}paste(e,t,i,o,r){this._executeEdit(()=>{this._executeEditOperation(Hh.paste(this.context.cursorConfig,this._model,this.getSelections(),t,i,o||[]))},e,r,4)}cut(e,t){this._executeEdit(()=>{this._executeEditOperation(zb.cut(this.context.cursorConfig,this._model,this.getSelections()))},e,t)}executeCommand(e,t,i){this._executeEdit(()=>{this._cursors.killSecondaryCursors(),this._executeEditOperation(new Ws(0,[t],{shouldPushStackElementBefore:!1,shouldPushStackElementAfter:!1}))},e,i)}executeCommands(e,t,i){this._executeEdit(()=>{this._executeEditOperation(new Ws(0,t,{shouldPushStackElementBefore:!1,shouldPushStackElementAfter:!1}))},e,i)}},yP=class n{static from(e,t){return new n(e.getVersionId(),t.getCursorStates())}constructor(e,t){this.modelVersionId=e,this.cursorState=t}equals(e){if(!e||this.modelVersionId!==e.modelVersionId||this.cursorState.length!==e.cursorState.length)return!1;for(let t=0,i=this.cursorState.length;t=t.length||!t[i].strictContainsRange(e[i]))return!1;return!0}},afe=class{static executeCommands(e,t,i){let o={model:e,selectionsBefore:t,trackedRanges:[],trackedRangesDirection:[]},r=this._innerExecuteCommands(o,i);for(let s=0,a=o.trackedRanges.length;s0&&(s[0]._isTracked=!0);let a=e.model.pushEditOperations(e.selectionsBefore,s,c=>{let d=[];for(let f=0;ff.identifier.minor-p.identifier.minor,h=[];for(let f=0;f0?(d[f].sort(u),h[f]=t[f].computeCursorState(e.model,{getInverseEditOperations:()=>d[f],getTrackedSelection:p=>{let g=parseInt(p,10),_=e.model._getTrackedRange(e.trackedRanges[g]);return e.trackedRangesDirection[g]===0?new Se(_.startLineNumber,_.startColumn,_.endLineNumber,_.endColumn):new Se(_.endLineNumber,_.endColumn,_.startLineNumber,_.startColumn)}})):h[f]=e.selectionsBefore[f];return h});a||(a=e.selectionsBefore);let l=[];for(let c in r)r.hasOwnProperty(c)&&l.push(parseInt(c,10));l.sort((c,d)=>d-c);for(let c of l)a.splice(c,1);return a}static _arrayIsEmpty(e){for(let t=0,i=e.length;t{S.isEmpty(u)&&h===""||o.push({identifier:{major:t,minor:r++},range:u,text:h,forceMoveMarkers:f,isAutoWhitespaceEdit:i.insertsAutoWhitespace})},a=!1,d={addEditOperation:s,addTrackedEditOperation:(u,h,f)=>{a=!0,s(u,h,f)},trackSelection:(u,h)=>{let f=Se.liftSelection(u),p;if(f.isEmpty())if(typeof h=="boolean")h?p=2:p=3;else{let b=e.model.getLineMaxColumn(f.startLineNumber);f.startColumn===b?p=2:p=3}else p=1;let g=e.trackedRanges.length,_=e.model._setTrackedRange(null,f,p);return e.trackedRanges[g]=_,e.trackedRangesDirection[g]=f.getDirection(),g.toString()}};try{i.getEditOperations(e.model,d)}catch(u){return Be(u),{operations:[],hadTrackedEditOperation:!1}}return{operations:o,hadTrackedEditOperation:a}}static _getLoserCursorMap(e){e=e.slice(0),e.sort((i,o)=>-S.compareRangesUsingEnds(i.range,o.range));let t={};for(let i=1;ir.identifier.major?s=o.identifier.major:s=r.identifier.major,t[s.toString()]=!0;for(let a=0;a0&&i--}}return t}},lfe=class{constructor(e,t,i){this.text=e,this.startSelection=t,this.endSelection=i}},cfe=class n{static _capture(e,t){let i=[];for(let o of t){if(o.startLineNumber!==o.endLineNumber)return null;i.push(new lfe(e.getLineContent(o.startLineNumber),o.startColumn-1,o.endColumn-1))}return i}constructor(e,t){this._original=n._capture(e,t)}deduceOutcome(e,t){if(!this._original)return null;let i=n._capture(e,t);if(!i||this._original.length!==i.length)return null;let o=[];for(let r=0,s=this._original.length;r{Qe();dfe=class{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;let t=this._inserts,i=this._changes,o=this._removes;this._hasPending=!1,this._inserts=[],this._changes=[],this._removes=[],e._commitPendingChanges(t,i,o)}},ufe=class{constructor(e,t,i,o,r){this.id=e,this.afterLineNumber=t,this.ordinal=i,this.height=o,this.minWidth=r,this.prefixSum=0}},A$=class n{static{this.INSTANCE_COUNT=0}constructor(e,t,i,o){this._instanceId=lB(++n.INSTANCE_COUNT),this._pendingChanges=new dfe,this._lastWhitespaceId=0,this._arr=[],this._prefixSumValidIndex=-1,this._minWidth=-1,this._lineCount=e,this._lineHeight=t,this._paddingTop=i,this._paddingBottom=o}static findInsertionIndex(e,t,i){let o=0,r=e.length;for(;o>>1;t===e[s].afterLineNumber?i{t=!0,o=o|0,r=r|0,s=s|0,a=a|0;let l=this._instanceId+ ++this._lastWhitespaceId;return this._pendingChanges.insert(new ufe(l,o,r,s,a)),l},changeOneWhitespace:(o,r,s)=>{t=!0,r=r|0,s=s|0,this._pendingChanges.change({id:o,newAfterLineNumber:r,newHeight:s})},removeWhitespace:o=>{t=!0,this._pendingChanges.remove({id:o})}})}finally{this._pendingChanges.commit(this)}return t}_commitPendingChanges(e,t,i){if((e.length>0||i.length>0)&&(this._minWidth=-1),e.length+t.length+i.length<=1){for(let l of e)this._insertWhitespace(l);for(let l of t)this._changeOneWhitespace(l.id,l.newAfterLineNumber,l.newHeight);for(let l of i){let c=this._findWhitespaceIndex(l.id);c!==-1&&this._removeWhitespace(c)}return}let o=new Set;for(let l of i)o.add(l.id);let r=new Map;for(let l of t)r.set(l.id,l);let s=l=>{let c=[];for(let d of l)if(!o.has(d.id)){if(r.has(d.id)){let u=r.get(d.id);d.afterLineNumber=u.newAfterLineNumber,d.height=u.newHeight}c.push(d)}return c},a=s(this._arr).concat(s(e));a.sort((l,c)=>l.afterLineNumber===c.afterLineNumber?l.ordinal-c.ordinal:l.afterLineNumber-c.afterLineNumber),this._arr=a,this._prefixSumValidIndex=-1}_checkPendingChanges(){this._pendingChanges.mustCommit()&&this._pendingChanges.commit(this)}_insertWhitespace(e){let t=n.findInsertionIndex(this._arr,e.afterLineNumber,e.ordinal);this._arr.splice(t,0,e),this._prefixSumValidIndex=Math.min(this._prefixSumValidIndex,t-1)}_findWhitespaceIndex(e){let t=this._arr;for(let i=0,o=t.length;it&&(this._arr[i].afterLineNumber-=t-e+1)}}onLinesInserted(e,t){this._checkPendingChanges(),e=e|0,t=t|0,this._lineCount+=t-e+1;for(let i=0,o=this._arr.length;i=t.length||t[a+1].afterLineNumber>=e)return a;i=a+1|0}else o=a-1|0}return-1}_findFirstWhitespaceAfterLineNumber(e){e=e|0;let i=this._findLastWhitespaceBeforeLineNumber(e)+1;return i1?i=this._lineHeight*(e-1):i=0;let o=this.getWhitespaceAccumulatedHeightBeforeLineNumber(e-(t?1:0));return i+o+this._paddingTop}getVerticalOffsetAfterLineNumber(e,t=!1){this._checkPendingChanges(),e=e|0;let i=this._lineHeight*e,o=this.getWhitespaceAccumulatedHeightBeforeLineNumber(e+(t?1:0));return i+o+this._paddingTop}getWhitespaceMinWidth(){if(this._checkPendingChanges(),this._minWidth===-1){let e=0;for(let t=0,i=this._arr.length;tt}isInTopPadding(e){return this._paddingTop===0?!1:(this._checkPendingChanges(),e=t-this._paddingBottom}getLineNumberAtOrAfterVerticalOffset(e){if(this._checkPendingChanges(),e=e|0,e<0)return 1;let t=this._lineCount|0,i=this._lineHeight,o=1,r=t;for(;o=a+i)o=s+1;else{if(e>=a)return s;r=s}}return o>t?t:o}getLinesViewportData(e,t){this._checkPendingChanges(),e=e|0,t=t|0;let i=this._lineHeight,o=this.getLineNumberAtOrAfterVerticalOffset(e)|0,r=this.getVerticalOffsetForLineNumber(o)|0,s=this._lineCount|0,a=this.getFirstWhitespaceIndexAfterLineNumber(o)|0,l=this.getWhitespacesCount()|0,c,d;a===-1?(a=l,d=s+1,c=0):(d=this.getAfterLineNumberForWhitespaceIndex(a)|0,c=this.getHeightForWhitespaceIndex(a)|0);let u=r,h=u,f=5e5,p=0;r>=f&&(p=Math.floor(r/f)*f,p=Math.floor(p/i)*i,h-=p);let g=[],_=e+(t-e)/2,b=-1;for(let y=o;y<=s;y++){if(b===-1){let C=u,L=u+i;(C<=_&&__)&&(b=y)}for(u+=i,g[y-o]=h,h+=i;d===y;)h+=c,u+=c,a++,a>=l?d=s+1:(d=this.getAfterLineNumberForWhitespaceIndex(a)|0,c=this.getHeightForWhitespaceIndex(a)|0);if(u>=t){s=y;break}}b===-1&&(b=s);let v=this.getVerticalOffsetForLineNumber(s)|0,x=o,w=s;return xt&&w--,{bigNumbersDelta:p,startLineNumber:o,endLineNumber:s,relativeVerticalOffset:g,centeredLineNumber:b,completelyVisibleStartLineNumber:x,completelyVisibleEndLineNumber:w,lineHeight:this._lineHeight}}getVerticalOffsetForWhitespaceIndex(e){this._checkPendingChanges(),e=e|0;let t=this.getAfterLineNumberForWhitespaceIndex(e),i;t>=1?i=this._lineHeight*t:i=0;let o;return e>0?o=this.getWhitespacesAccumulatedHeight(e-1):o=0,i+o+this._paddingTop}getWhitespaceIndexAtOrAfterVerticallOffset(e){this._checkPendingChanges(),e=e|0;let t=0,i=this.getWhitespacesCount()-1;if(i<0)return-1;let o=this.getVerticalOffsetForWhitespaceIndex(i),r=this.getHeightForWhitespaceIndex(i);if(e>=o+r)return-1;for(;t=a+l)t=s+1;else{if(e>=a)return s;i=s}}return t}getWhitespaceAtVerticalOffset(e){this._checkPendingChanges(),e=e|0;let t=this.getWhitespaceIndexAtOrAfterVerticallOffset(e);if(t<0||t>=this.getWhitespacesCount())return null;let i=this.getVerticalOffsetForWhitespaceIndex(t);if(i>e)return null;let o=this.getHeightForWhitespaceIndex(t),r=this.getIdForWhitespaceIndex(t),s=this.getAfterLineNumberForWhitespaceIndex(t);return{id:r,afterLineNumber:s,verticalOffset:i,height:o}}getWhitespaceViewportData(e,t){this._checkPendingChanges(),e=e|0,t=t|0;let i=this.getWhitespaceIndexAtOrAfterVerticallOffset(e),o=this.getWhitespacesCount()-1;if(i<0)return[];let r=[];for(let s=i;s<=o;s++){let a=this.getVerticalOffsetForWhitespaceIndex(s),l=this.getHeightForWhitespaceIndex(s);if(a>=t)break;r.push({id:this.getIdForWhitespaceIndex(s),afterLineNumber:this.getAfterLineNumberForWhitespaceIndex(s),verticalOffset:a,height:l})}return r}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}}});var eht,C0,hfe,M$,P8e=k(()=>{Ie();j();GL();M8e();Af();D$();eht=125,C0=class{constructor(e,t,i,o){e=e|0,t=t|0,i=i|0,o=o|0,e<0&&(e=0),t<0&&(t=0),i<0&&(i=0),o<0&&(o=0),this.width=e,this.contentWidth=t,this.scrollWidth=Math.max(e,t),this.height=i,this.contentHeight=o,this.scrollHeight=Math.max(i,o)}equals(e){return this.width===e.width&&this.contentWidth===e.contentWidth&&this.height===e.height&&this.contentHeight===e.contentHeight}},hfe=class extends D{constructor(e,t){super(),this._onDidContentSizeChange=this._register(new A),this.onDidContentSizeChange=this._onDidContentSizeChange.event,this._dimensions=new C0(0,0,0,0),this._scrollable=this._register(new Ih({forceIntegerValues:!0,smoothScrollDuration:e,scheduleAtNextAnimationFrame:t})),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;let t=this._dimensions;this._dimensions=e,this._scrollable.setScrollDimensions({width:e.width,scrollWidth:e.scrollWidth,height:e.height,scrollHeight:e.scrollHeight},!0);let i=t.contentWidth!==e.contentWidth,o=t.contentHeight!==e.contentHeight;(i||o)&&this._onDidContentSizeChange.fire(new _$(t.contentWidth,t.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)}hasPendingScrollAnimation(){return this._scrollable.hasPendingScrollAnimation()}},M$=class extends D{constructor(e,t,i){super(),this._configuration=e;let o=this._configuration.options,r=o.get(146),s=o.get(84);this._linesLayout=new A$(t,o.get(67),s.top,s.bottom),this._maxLineWidth=0,this._overlayWidgetsMinWidth=0,this._scrollable=this._register(new hfe(0,i)),this._configureSmoothScrollDuration(),this._scrollable.setScrollDimensions(new C0(r.contentWidth,0,r.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(115)?eht:0)}onConfigurationChanged(e){let t=this._configuration.options;if(e.hasChanged(67)&&this._linesLayout.setLineHeight(t.get(67)),e.hasChanged(84)){let i=t.get(84);this._linesLayout.setPadding(i.top,i.bottom)}if(e.hasChanged(146)){let i=t.get(146),o=i.contentWidth,r=i.height,s=this._scrollable.getScrollDimensions(),a=s.contentWidth;this._scrollable.setScrollDimensions(new C0(o,s.contentWidth,r,this._getContentHeight(o,r,a)))}else this._updateHeight();e.hasChanged(115)&&this._configureSmoothScrollDuration()}onFlushed(e){this._linesLayout.onFlushed(e)}onLinesDeleted(e,t){this._linesLayout.onLinesDeleted(e,t)}onLinesInserted(e,t){this._linesLayout.onLinesInserted(e,t)}_getHorizontalScrollbarHeight(e,t){let o=this._configuration.options.get(104);return o.horizontal===2||e>=t?0:o.horizontalScrollbarSize}_getContentHeight(e,t,i){let o=this._configuration.options,r=this._linesLayout.getLinesTotalHeight();return o.get(106)?r+=Math.max(0,t-o.get(67)-o.get(84).bottom):o.get(104).ignoreHorizontalScrollbarInContentHeight||(r+=this._getHorizontalScrollbarHeight(e,i)),r}_updateHeight(){let e=this._scrollable.getScrollDimensions(),t=e.width,i=e.height,o=e.contentWidth;this._scrollable.setScrollDimensions(new C0(t,e.contentWidth,i,this._getContentHeight(t,i,o)))}getCurrentViewport(){let e=this._scrollable.getScrollDimensions(),t=this._scrollable.getCurrentScrollPosition();return new Z2(t.scrollTop,t.scrollLeft,e.width,e.height)}getFutureViewport(){let e=this._scrollable.getScrollDimensions(),t=this._scrollable.getFutureScrollPosition();return new Z2(t.scrollTop,t.scrollLeft,e.width,e.height)}_computeContentWidth(){let e=this._configuration.options,t=this._maxLineWidth,i=e.get(147),o=e.get(50),r=e.get(146);if(i.isViewportWrapping){let s=e.get(73);return t>r.contentWidth+o.typicalHalfwidthCharacterWidth&&s.enabled&&s.side==="right"?t+r.verticalScrollbarWidth:t}else{let s=e.get(105)*o.typicalHalfwidthCharacterWidth,a=this._linesLayout.getWhitespaceMinWidth();return Math.max(t+s+r.verticalScrollbarWidth,a,this._overlayWidgetsMinWidth)}}setMaxLineWidth(e){this._maxLineWidth=e,this._updateContentWidth()}setOverlayWidgetsMinWidth(e){this._overlayWidgetsMinWidth=e,this._updateContentWidth()}_updateContentWidth(){let e=this._scrollable.getScrollDimensions();this._scrollable.setScrollDimensions(new C0(e.width,this._computeContentWidth(),e.height,e.contentHeight)),this._updateHeight()}saveState(){let e=this._scrollable.getFutureScrollPosition(),t=e.scrollTop,i=this._linesLayout.getLineNumberAtOrAfterVerticalOffset(t),o=this._linesLayout.getWhitespaceAccumulatedHeightBeforeLineNumber(i);return{scrollTop:t,scrollTopWithoutViewZones:t-o,scrollLeft:e.scrollLeft}}changeWhitespace(e){let t=this._linesLayout.changeWhitespace(e);return t&&this.onHeightMaybeChanged(),t}getVerticalOffsetForLineNumber(e,t=!1){return this._linesLayout.getVerticalOffsetForLineNumber(e,t)}getVerticalOffsetAfterLineNumber(e,t=!1){return this._linesLayout.getVerticalOffsetAfterLineNumber(e,t)}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(){let e=this.getCurrentViewport();return this._linesLayout.getLinesViewportData(e.top,e.top+e.height)}getLinesViewportDataAtScrollTop(e){let t=this._scrollable.getScrollDimensions();return e+t.height>t.scrollHeight&&(e=t.scrollHeight-t.height),e<0&&(e=0),this._linesLayout.getLinesViewportData(e,e+t.height)}getWhitespaceViewportData(){let 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,t){t===1?this._scrollable.setScrollPositionNow(e):this._scrollable.setScrollPositionSmooth(e)}hasPendingScrollAnimation(){return this._scrollable.hasPendingScrollAnimation()}deltaScrollNow(e,t){let i=this._scrollable.getCurrentScrollPosition();this._scrollable.setScrollPositionNow({scrollLeft:i.scrollLeft+e,scrollTop:i.scrollTop+t})}}});function O$(n,e){return!(e.options.hideInCommentTokens&&F$(n,e)||e.options.hideInStringTokens&&B$(n,e))}function F$(n,e){return O8e(n,e.range,t=>t===1)}function B$(n,e){return O8e(n,e.range,t=>t===2)}function O8e(n,e,t){for(let i=e.startLineNumber;i<=e.endLineNumber;i++){let o=n.tokenization.getLineTokens(i),r=i===e.startLineNumber,s=i===e.endLineNumber,a=r?o.findTokenIndexAtOffset(e.startColumn-1):0;for(;ae.endColumn-1);){if(!t(o.getStandardTokenType(a)))return!1;a++}}return!0}var P$,ffe=k(()=>{qe();we();Af();ir();P$=class{constructor(e,t,i,o,r){this.editorId=e,this.model=t,this.configuration=i,this._linesCollection=o,this._coordinatesConverter=r,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(e){let t=e.id,i=this._decorationsCache[t];if(!i){let o=e.range,r=e.options,s;if(r.isWholeLine){let a=this._coordinatesConverter.convertModelPositionToViewPosition(new P(o.startLineNumber,1),0,!1,!0),l=this._coordinatesConverter.convertModelPositionToViewPosition(new P(o.endLineNumber,this.model.getLineMaxColumn(o.endLineNumber)),1);s=new S(a.lineNumber,a.column,l.lineNumber,l.column)}else s=this._coordinatesConverter.convertModelRangeToViewRange(o,1);i=new pE(s,r),this._decorationsCache[t]=i}return i}getMinimapDecorationsInRange(e){return this._getDecorationsInRange(e,!0,!1).decorations}getDecorationsViewportData(e){let t=this._cachedModelDecorationsResolver!==null;return t=t&&e.equalsRange(this._cachedModelDecorationsResolverViewRange),t||(this._cachedModelDecorationsResolver=this._getDecorationsInRange(e,!1,!1),this._cachedModelDecorationsResolverViewRange=e),this._cachedModelDecorationsResolver}getInlineDecorationsOnLine(e,t=!1,i=!1){let o=new S(e,this._linesCollection.getViewLineMinColumn(e),e,this._linesCollection.getViewLineMaxColumn(e));return this._getDecorationsInRange(o,t,i).inlineDecorations[0]}_getDecorationsInRange(e,t,i){let o=this._linesCollection.getDecorationsInRange(e,this.editorId,p1(this.configuration.options),t,i),r=e.startLineNumber,s=e.endLineNumber,a=[],l=0,c=[];for(let d=r;d<=s;d++)c[d-r]=[];for(let d=0,u=o.length;d=pfe.length)for(let e=1;e<=n;e++)pfe[e]=tht(e);return pfe[n]}function tht(n){return new Array(n+1).join(" ")}var mfe,W$,H$,pfe,B8e=k(()=>{Dh();qe();vw();Af();mfe=class{constructor(e,t){this._projectionData=e,this._isVisible=t}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,t,i){this._assertVisible();let o=i>0?this._projectionData.breakOffsets[i-1]:0,r=this._projectionData.breakOffsets[i],s;if(this._projectionData.injectionOffsets!==null){let a=this._projectionData.injectionOffsets.map((c,d)=>new Wd(0,0,c+1,this._projectionData.injectionOptions[d],0));s=Wd.applyInjectedText(e.getLineContent(t),a).substring(o,r)}else s=e.getValueInRange({startLineNumber:t,startColumn:o+1,endLineNumber:t,endColumn:r+1});return i>0&&(s=F8e(this._projectionData.wrappedTextIndentLength)+s),s}getViewLineLength(e,t,i){return this._assertVisible(),this._projectionData.getLineLength(i)}getViewLineMinColumn(e,t,i){return this._assertVisible(),this._projectionData.getMinOutputOffset(i)+1}getViewLineMaxColumn(e,t,i){return this._assertVisible(),this._projectionData.getMaxOutputOffset(i)+1}getViewLineData(e,t,i){let o=new Array;return this.getViewLinesData(e,t,i,1,0,[!0],o),o[0]}getViewLinesData(e,t,i,o,r,s,a){this._assertVisible();let l=this._projectionData,c=l.injectionOffsets,d=l.injectionOptions,u=null;if(c){u=[];let f=0,p=0;for(let g=0;g0?l.breakOffsets[g-1]:0,v=l.breakOffsets[g];for(;pv)break;if(b0?l.wrappedTextIndentLength:0,E=L+Math.max(w-b,0),N=L+Math.min(y-b,v-b);E!==N&&_.push(new uV(E,N,C.inlineClassName,C.inlineClassNameAffectsLetterSpacing))}}if(y<=v)f+=x,p++;else break}}}let h;c?h=e.tokenization.getLineTokens(t).withInserted(c.map((f,p)=>({offset:f,text:d[p].content,tokenMetadata:ao.defaultTokenMetadata}))):h=e.tokenization.getLineTokens(t);for(let f=i;f0?o.wrappedTextIndentLength:0,s=i>0?o.breakOffsets[i-1]:0,a=o.breakOffsets[i],l=e.sliceAndInflate(s,a,r),c=l.getLineContent();i>0&&(c=F8e(o.wrappedTextIndentLength)+c);let d=this._projectionData.getMinOutputOffset(i)+1,u=c.length+1,h=i+1o+1?(t.push(new S(i,1,o,1)),i=a.startLineNumber,o=a.endLineNumber):a.endLineNumber>o&&(o=a.endLineNumber)}return t.push(new S(i,1,o,1)),t}var V$,U$,$$,gfe,j$,_fe,W8e=k(()=>{at();qe();we();rH();Ho();vw();m$();B8e();Nre();Af();V$=class{constructor(e,t,i,o,r,s,a,l,c,d){this._editorId=e,this.model=t,this._validModelVersionId=-1,this._domLineBreaksComputerFactory=i,this._monospaceLineBreaksComputerFactory=o,this.fontInfo=r,this.tabSize=s,this.wrappingStrategy=a,this.wrappingColumn=l,this.wrappingIndent=c,this.wordBreak=d,this._constructLines(!0,null)}dispose(){this.hiddenAreasDecorationIds=this.model.deltaDecorations(this.hiddenAreasDecorationIds,[])}createCoordinatesConverter(){return new gfe(this)}_constructLines(e,t){this.modelLineProjections=[],e&&(this.hiddenAreasDecorationIds=this.model.deltaDecorations(this.hiddenAreasDecorationIds,[]));let i=this.model.getLinesContent(),o=this.model.getInjectedTextDecorations(this._editorId),r=i.length,s=this.createLineBreaksComputer(),a=new wl(Wd.fromDecorations(o));for(let g=0;gb.lineNumber===g+1);s.addRequest(i[g],_,t?t[g]:null)}let l=s.finalize(),c=[],d=this.hiddenAreasDecorationIds.map(g=>this.model.getDecorationRange(g)).sort(S.compareRangesUsingStarts),u=1,h=0,f=-1,p=f+1=u&&_<=h,v=z$(l[g],!b);c[g]=v.getViewLineCount(),this.modelLineProjections[g]=v}this._validModelVersionId=this.model.getVersionId(),this.projectedModelLineLineCounts=new Y6(c)}getHiddenAreas(){return this.hiddenAreasDecorationIds.map(e=>this.model.getDecorationRange(e))}setHiddenAreas(e){let t=e.map(h=>this.model.validateRange(h)),i=iht(t),o=this.hiddenAreasDecorationIds.map(h=>this.model.getDecorationRange(h)).sort(S.compareRangesUsingStarts);if(i.length===o.length){let h=!1;for(let f=0;f({range:h,options:tt.EMPTY}));this.hiddenAreasDecorationIds=this.model.deltaDecorations(this.hiddenAreasDecorationIds,r);let s=i,a=1,l=0,c=-1,d=c+1=a&&f<=l?this.modelLineProjections[h].isVisible()&&(this.modelLineProjections[h]=this.modelLineProjections[h].setVisible(!1),p=!0):(u=!0,this.modelLineProjections[h].isVisible()||(this.modelLineProjections[h]=this.modelLineProjections[h].setVisible(!0),p=!0)),p){let g=this.modelLineProjections[h].getViewLineCount();this.projectedModelLineLineCounts.setValue(h,g)}}return u||this.setHiddenAreas([]),!0}modelPositionIsVisible(e,t){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,t,i,o,r){let s=this.fontInfo.equals(e),a=this.wrappingStrategy===t,l=this.wrappingColumn===i,c=this.wrappingIndent===o,d=this.wordBreak===r;if(s&&a&&l&&c&&d)return!1;let u=s&&a&&!l&&c&&d;this.fontInfo=e,this.wrappingStrategy=t,this.wrappingColumn=i,this.wrappingIndent=o,this.wordBreak=r;let h=null;if(u){h=[];for(let f=0,p=this.modelLineProjections.length;f2&&!this.modelLineProjections[t-2].isVisible(),s=t===1?1:this.projectedModelLineLineCounts.getPrefixSum(t-1)+1,a=0,l=[],c=[];for(let d=0,u=o.length;dl?(d=this.projectedModelLineLineCounts.getPrefixSum(t-1)+1,u=d+l-1,p=u+1,g=p+(r-l)-1,c=!0):rt?t:e|0}getActiveIndentGuide(e,t,i){e=this._toValidViewLineNumber(e),t=this._toValidViewLineNumber(t),i=this._toValidViewLineNumber(i);let o=this.convertViewPositionToModelPosition(e,this.getViewLineMinColumn(e)),r=this.convertViewPositionToModelPosition(t,this.getViewLineMinColumn(t)),s=this.convertViewPositionToModelPosition(i,this.getViewLineMinColumn(i)),a=this.model.guides.getActiveIndentGuide(o.lineNumber,r.lineNumber,s.lineNumber),l=this.convertModelPositionToViewPosition(a.startLineNumber,1),c=this.convertModelPositionToViewPosition(a.endLineNumber,this.model.getLineMaxColumn(a.endLineNumber));return{startLineNumber:l.lineNumber,endLineNumber:c.lineNumber,indent:a.indent}}getViewLineInfo(e){e=this._toValidViewLineNumber(e);let t=this.projectedModelLineLineCounts.getIndexOf(e-1),i=t.index,o=t.remainder;return new U$(i+1,o)}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){let t=this.modelLineProjections[e.modelLineNumber-1],i=t.getViewLineMinColumn(this.model,e.modelLineNumber,e.modelLineWrappedLineIdx),o=t.getModelColumnOfViewPosition(e.modelLineWrappedLineIdx,i);return new P(e.modelLineNumber,o)}getModelEndPositionOfViewLine(e){let t=this.modelLineProjections[e.modelLineNumber-1],i=t.getViewLineMaxColumn(this.model,e.modelLineNumber,e.modelLineWrappedLineIdx),o=t.getModelColumnOfViewPosition(e.modelLineWrappedLineIdx,i);return new P(e.modelLineNumber,o)}getViewLineInfosGroupedByModelRanges(e,t){let i=this.getViewLineInfo(e),o=this.getViewLineInfo(t),r=new Array,s=this.getModelStartPositionOfViewLine(i),a=new Array;for(let l=i.modelLineNumber;l<=o.modelLineNumber;l++){let c=this.modelLineProjections[l-1];if(c.isVisible()){let d=l===i.modelLineNumber?i.modelLineWrappedLineIdx:0,u=l===o.modelLineNumber?o.modelLineWrappedLineIdx+1:c.getViewLineCount();for(let h=d;h{if(f.forWrappedLinesAfterColumn!==-1&&this.modelLineProjections[d.modelLineNumber-1].getViewPositionOfModelPosition(0,f.forWrappedLinesAfterColumn).lineNumber>=d.modelLineWrappedLineIdx||f.forWrappedLinesBeforeOrAtColumn!==-1&&this.modelLineProjections[d.modelLineNumber-1].getViewPositionOfModelPosition(0,f.forWrappedLinesBeforeOrAtColumn).lineNumberd.modelLineWrappedLineIdx)return}let g=this.convertModelPositionToViewPosition(d.modelLineNumber,f.horizontalLine.endColumn),_=this.modelLineProjections[d.modelLineNumber-1].getViewPositionOfModelPosition(0,f.horizontalLine.endColumn);return _.lineNumber===d.modelLineWrappedLineIdx?new Nf(f.visibleColumn,p,f.className,new Lb(f.horizontalLine.top,g.column),-1,-1):_.lineNumber!!f))}}return s}getViewLinesIndentGuides(e,t){e=this._toValidViewLineNumber(e),t=this._toValidViewLineNumber(t);let i=this.convertViewPositionToModelPosition(e,this.getViewLineMinColumn(e)),o=this.convertViewPositionToModelPosition(t,this.getViewLineMaxColumn(t)),r=[],s=[],a=[],l=i.lineNumber-1,c=o.lineNumber-1,d=null;for(let p=l;p<=c;p++){let g=this.modelLineProjections[p];if(g.isVisible()){let _=g.getViewLineNumberOfModelPosition(0,p===l?i.column:1),b=g.getViewLineNumberOfModelPosition(0,this.model.getLineMaxColumn(p+1)),v=b-_+1,x=0;v>1&&g.getViewLineMinColumn(this.model,p+1,b)===1&&(x=_===0?1:2),s.push(v),a.push(x),d===null&&(d=new P(p+1,0))}else d!==null&&(r=r.concat(this.model.guides.getLinesIndentGuides(d.lineNumber,p)),d=null)}d!==null&&(r=r.concat(this.model.guides.getLinesIndentGuides(d.lineNumber,o.lineNumber)),d=null);let u=t-e+1,h=new Array(u),f=0;for(let p=0,g=r.length;pt&&(p=!0,f=t-r+1),u.getViewLinesData(this.model,c+1,h,f,r-e,i,l),r+=f,p)break}return l}validateViewPosition(e,t,i){e=this._toValidViewLineNumber(e);let o=this.projectedModelLineLineCounts.getIndexOf(e-1),r=o.index,s=o.remainder,a=this.modelLineProjections[r],l=a.getViewLineMinColumn(this.model,r+1,s),c=a.getViewLineMaxColumn(this.model,r+1,s);tc&&(t=c);let d=a.getModelColumnOfViewPosition(s,t);return this.model.validatePosition(new P(r+1,d)).equals(i)?new P(e,t):this.convertModelPositionToViewPosition(i.lineNumber,i.column)}validateViewRange(e,t){let i=this.validateViewPosition(e.startLineNumber,e.startColumn,t.getStartPosition()),o=this.validateViewPosition(e.endLineNumber,e.endColumn,t.getEndPosition());return new S(i.lineNumber,i.column,o.lineNumber,o.column)}convertViewPositionToModelPosition(e,t){let i=this.getViewLineInfo(e),o=this.modelLineProjections[i.modelLineNumber-1].getModelColumnOfViewPosition(i.modelLineWrappedLineIdx,t);return this.model.validatePosition(new P(i.modelLineNumber,o))}convertViewRangeToModelRange(e){let t=this.convertViewPositionToModelPosition(e.startLineNumber,e.startColumn),i=this.convertViewPositionToModelPosition(e.endLineNumber,e.endColumn);return new S(t.lineNumber,t.column,i.lineNumber,i.column)}convertModelPositionToViewPosition(e,t,i=2,o=!1,r=!1){let s=this.model.validatePosition(new P(e,t)),a=s.lineNumber,l=s.column,c=a-1,d=!1;if(r)for(;c0&&!this.modelLineProjections[c].isVisible();)c--,d=!0;if(c===0&&!this.modelLineProjections[c].isVisible())return new P(o?0:1,1);let u=1+this.projectedModelLineLineCounts.getPrefixSum(c),h;return d?r?h=this.modelLineProjections[c].getViewPositionOfModelPosition(u,1,i):h=this.modelLineProjections[c].getViewPositionOfModelPosition(u,this.model.getLineMaxColumn(c+1),i):h=this.modelLineProjections[a-1].getViewPositionOfModelPosition(u,l,i),h}convertModelRangeToViewRange(e,t=0){if(e.isEmpty()){let i=this.convertModelPositionToViewPosition(e.startLineNumber,e.startColumn,t);return S.fromPositions(i)}else{let i=this.convertModelPositionToViewPosition(e.startLineNumber,e.startColumn,1),o=this.convertModelPositionToViewPosition(e.endLineNumber,e.endColumn,0);return new S(i.lineNumber,i.column,o.lineNumber,o.column)}}getViewLineNumberOfModelPosition(e,t){let i=e-1;if(this.modelLineProjections[i].isVisible()){let r=1+this.projectedModelLineLineCounts.getPrefixSum(i);return this.modelLineProjections[i].getViewLineNumberOfModelPosition(r,t)}for(;i>0&&!this.modelLineProjections[i].isVisible();)i--;if(i===0&&!this.modelLineProjections[i].isVisible())return 1;let o=1+this.projectedModelLineLineCounts.getPrefixSum(i);return this.modelLineProjections[i].getViewLineNumberOfModelPosition(o,this.model.getLineMaxColumn(i+1))}getDecorationsInRange(e,t,i,o,r){let s=this.convertViewPositionToModelPosition(e.startLineNumber,e.startColumn),a=this.convertViewPositionToModelPosition(e.endLineNumber,e.endColumn);if(a.lineNumber-s.lineNumber<=e.endLineNumber-e.startLineNumber)return this.model.getDecorationsInRange(new S(s.lineNumber,1,a.lineNumber,a.column),t,i,o,r);let l=[],c=s.lineNumber-1,d=a.lineNumber-1,u=null;for(let g=c;g<=d;g++)if(this.modelLineProjections[g].isVisible())u===null&&(u=new P(g+1,g===c?s.column:1));else if(u!==null){let b=this.model.getLineMaxColumn(g);l=l.concat(this.model.getDecorationsInRange(new S(u.lineNumber,u.column,g,b),t,i,o)),u=null}u!==null&&(l=l.concat(this.model.getDecorationsInRange(new S(u.lineNumber,u.column,a.lineNumber,a.column),t,i,o)),u=null),l.sort((g,_)=>{let b=S.compareRangesUsingStarts(g.range,_.range);return b===0?g.id<_.id?-1:g.id>_.id?1:0:b});let h=[],f=0,p=null;for(let g of l){let _=g.id;p!==_&&(p=_,h[f++]=g)}return h}getInjectedTextAt(e){let t=this.getViewLineInfo(e.lineNumber);return this.modelLineProjections[t.modelLineNumber-1].getInjectedTextAt(t.modelLineWrappedLineIdx,e.column)}normalizePosition(e,t){let i=this.getViewLineInfo(e.lineNumber);return this.modelLineProjections[i.modelLineNumber-1].normalizePosition(i.modelLineWrappedLineIdx,e,t)}getLineIndentColumn(e){let t=this.getViewLineInfo(e);return t.modelLineWrappedLineIdx===0?this.model.getLineIndentColumn(t.modelLineNumber):0}};U$=class{constructor(e,t){this.modelLineNumber=e,this.modelLineWrappedLineIdx=t}},$$=class{constructor(e,t){this.modelRange=e,this.viewLines=t}},gfe=class{constructor(e){this._lines=e}convertViewPositionToModelPosition(e){return this._lines.convertViewPositionToModelPosition(e.lineNumber,e.column)}convertViewRangeToModelRange(e){return this._lines.convertViewRangeToModelRange(e)}validateViewPosition(e,t){return this._lines.validateViewPosition(e.lineNumber,e.column,t)}validateViewRange(e,t){return this._lines.validateViewRange(e,t)}convertModelPositionToViewPosition(e,t,i,o){return this._lines.convertModelPositionToViewPosition(e.lineNumber,e.column,t,i,o)}convertModelRangeToViewRange(e,t){return this._lines.convertModelRangeToViewRange(e,t)}modelPositionIsVisible(e){return this._lines.modelPositionIsVisible(e.lineNumber,e.column)}getModelLineViewLineCount(e){return this._lines.getModelLineViewLineCount(e)}getViewLineNumberOfModelPosition(e,t){return this._lines.getViewLineNumberOfModelPosition(e,t)}},j$=class{constructor(e){this.model=e}dispose(){}createCoordinatesConverter(){return new _fe(this)}getHiddenAreas(){return[]}setHiddenAreas(e){return!1}setTabSize(e){return!1}setWrappingSettings(e,t,i,o){return!1}createLineBreaksComputer(){let e=[];return{addRequest:(t,i,o)=>{e.push(null)},finalize:()=>e}}onModelFlushed(){}onModelLinesDeleted(e,t,i){return new qE(t,i)}onModelLinesInserted(e,t,i,o){return new KE(t,i)}onModelLineChanged(e,t,i){return[!1,new wP(t,1),null,null]}acceptVersionId(e){}getViewLineCount(){return this.model.getLineCount()}getActiveIndentGuide(e,t,i){return{startLineNumber:e,endLineNumber:e,indent:0}}getViewLinesBracketGuides(e,t,i){return new Array(t-e+1).fill([])}getViewLinesIndentGuides(e,t){let i=t-e+1,o=new Array(i);for(let r=0;rt)}getModelLineViewLineCount(e){return 1}getViewLineNumberOfModelPosition(e,t){return e}}});var S0,q$,H8e=k(()=>{Zr();S0=tl.Right,q$=class{constructor(e){this.persist=0,this._requiredLanes=1,this.lanes=new Uint8Array(Math.ceil((e+1)*S0/8))}reset(e){let t=Math.ceil((e+1)*S0/8);this.lanes.length>>3]|=1<>>3]&1<>>3]&1<{at();ft();vo();j();Bt();Qe();ir();A8e();Bu();qe();we();vw();Ji();Nd();sae();m$();P8e();Whe();Af();ffe();D$();W8e();H8e();nht=!0,K$=class extends D{constructor(e,t,i,o,r,s,a,l,c,d){if(super(),this.languageConfigurationService=a,this._themeService=l,this._attachedView=c,this._transactionalTarget=d,this.hiddenAreasModel=new xfe,this.previousHiddenAreas=[],this._editorId=e,this._configuration=t,this.model=i,this._eventDispatcher=new g$,this.onEvent=this._eventDispatcher.onEvent,this.cursorConfig=new Hb(this.model.getLanguageId(),this.model.getOptions(),this._configuration,this.languageConfigurationService),this._updateConfigurationViewLineCount=this._register(new Lt(()=>this._updateConfigurationViewLineCountNow(),0)),this._hasFocus=!1,this._viewportStart=bfe.create(this.model),this.glyphLanes=new q$(0),nht&&this.model.isTooLargeForTokenization())this._lines=new j$(this.model);else{let u=this._configuration.options,h=u.get(50),f=u.get(140),p=u.get(147),g=u.get(139),_=u.get(130);this._lines=new V$(this._editorId,this.model,o,r,h,this.model.getOptions().tabSize,f,p.wrappingColumn,g,_)}this.coordinatesConverter=this._lines.createCoordinatesConverter(),this._cursor=this._register(new N$(i,this,this.coordinatesConverter,this.cursorConfig)),this.viewLayout=this._register(new M$(this._configuration,this.getLineCount(),s)),this._register(this.viewLayout.onDidScroll(u=>{u.scrollTopChanged&&this._handleVisibleLinesChanged(),u.scrollTopChanged&&this._viewportStart.invalidate(),this._eventDispatcher.emitSingleViewEvent(new d$(u)),this._eventDispatcher.emitOutgoingEvent(new v$(u.oldScrollWidth,u.oldScrollLeft,u.oldScrollHeight,u.oldScrollTop,u.scrollWidth,u.scrollLeft,u.scrollHeight,u.scrollTop))})),this._register(this.viewLayout.onDidContentSizeChange(u=>{this._eventDispatcher.emitOutgoingEvent(u)})),this._decorations=new P$(this._editorId,this.model,this._configuration,this._lines,this.coordinatesConverter),this._registerModelEvents(),this._register(this._configuration.onDidChangeFast(u=>{try{let h=this._eventDispatcher.beginEmitViewEvents();this._onConfigurationChanged(h,u)}finally{this._eventDispatcher.endEmitViewEvents()}})),this._register(UE.getInstance().onDidChange(()=>{this._eventDispatcher.emitSingleViewEvent(new f$)})),this._register(this._themeService.onDidColorThemeChange(u=>{this._invalidateDecorationsColorCache(),this._eventDispatcher.emitSingleViewEvent(new u$(u))})),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())}getModelVisibleRanges(){let e=this.viewLayout.getLinesViewportData(),t=new S(e.startLineNumber,this.getLineMinColumn(e.startLineNumber),e.endLineNumber,this.getLineMaxColumn(e.endLineNumber));return this._toModelVisibleRanges(t)}visibleLinesStabilized(){let e=this.getModelVisibleRanges();this._attachedView.setVisibleLines(e,!0)}_handleVisibleLinesChanged(){let e=this.getModelVisibleRanges();this._attachedView.setVisibleLines(e,!1)}setHasFocus(e){this._hasFocus=e,this._cursor.setHasFocus(e),this._eventDispatcher.emitSingleViewEvent(new l$(e)),this._eventDispatcher.emitOutgoingEvent(new b$(!e,e))}onCompositionStart(){this._eventDispatcher.emitSingleViewEvent(new o$)}onCompositionEnd(){this._eventDispatcher.emitSingleViewEvent(new r$)}_captureStableViewport(){if(this._viewportStart.isValid&&this.viewLayout.getCurrentScrollTop()>0){let e=new P(this._viewportStart.viewLineNumber,this.getLineMinColumn(this._viewportStart.viewLineNumber)),t=this.coordinatesConverter.convertViewPositionToModelPosition(e);return new G$(t,this._viewportStart.startLineDelta)}return new G$(null,0)}_onConfigurationChanged(e,t){let i=this._captureStableViewport(),o=this._configuration.options,r=o.get(50),s=o.get(140),a=o.get(147),l=o.get(139),c=o.get(130);this._lines.setWrappingSettings(r,s,a.wrappingColumn,l,c)&&(e.emitViewEvent(new w0),e.emitViewEvent(new y0),e.emitViewEvent(new zg(null)),this._cursor.onLineMappingChanged(e),this._decorations.onLineMappingChanged(),this.viewLayout.onFlushed(this.getLineCount()),this._updateConfigurationViewLineCount.schedule()),t.hasChanged(92)&&(this._decorations.reset(),e.emitViewEvent(new zg(null))),t.hasChanged(99)&&(this._decorations.reset(),e.emitViewEvent(new zg(null))),e.emitViewEvent(new s$(t)),this.viewLayout.onConfigurationChanged(t),i.recoverViewportStart(this.coordinatesConverter,this.viewLayout),Hb.shouldRecreate(t)&&(this.cursorConfig=new Hb(this.model.getLanguageId(),this.model.getOptions(),this._configuration,this.languageConfigurationService),this._cursor.updateConfiguration(this.cursorConfig))}_registerModelEvents(){this._register(this.model.onDidChangeContentOrInjectedText(e=>{try{let i=this._eventDispatcher.beginEmitViewEvents(),o=!1,r=!1,s=e instanceof bw?e.rawContentChangedEvent.changes:e.changes,a=e instanceof bw?e.rawContentChangedEvent.versionId:null,l=this._lines.createLineBreaksComputer();for(let u of s)switch(u.changeType){case 4:{for(let h=0;h!g.ownerId||g.ownerId===this._editorId)),l.addRequest(f,p,null)}break}case 2:{let h=null;u.injectedText&&(h=u.injectedText.filter(f=>!f.ownerId||f.ownerId===this._editorId)),l.addRequest(u.detail,h,null);break}}let c=l.finalize(),d=new wl(c);for(let u of s)switch(u.changeType){case 1:{this._lines.onModelFlushed(),i.emitViewEvent(new w0),this._decorations.reset(),this.viewLayout.onFlushed(this.getLineCount()),o=!0;break}case 3:{let h=this._lines.onModelLinesDeleted(a,u.fromLineNumber,u.toLineNumber);h!==null&&(i.emitViewEvent(h),this.viewLayout.onLinesDeleted(h.fromLineNumber,h.toLineNumber)),o=!0;break}case 4:{let h=d.takeCount(u.detail.length),f=this._lines.onModelLinesInserted(a,u.fromLineNumber,u.toLineNumber,h);f!==null&&(i.emitViewEvent(f),this.viewLayout.onLinesInserted(f.fromLineNumber,f.toLineNumber)),o=!0;break}case 2:{let h=d.dequeue(),[f,p,g,_]=this._lines.onModelLineChanged(a,u.lineNumber,h);r=f,p&&i.emitViewEvent(p),g&&(i.emitViewEvent(g),this.viewLayout.onLinesInserted(g.fromLineNumber,g.toLineNumber)),_&&(i.emitViewEvent(_),this.viewLayout.onLinesDeleted(_.fromLineNumber,_.toLineNumber));break}case 5:break}a!==null&&this._lines.acceptVersionId(a),this.viewLayout.onHeightMaybeChanged(),!o&&r&&(i.emitViewEvent(new y0),i.emitViewEvent(new zg(null)),this._cursor.onLineMappingChanged(i),this._decorations.onLineMappingChanged())}finally{this._eventDispatcher.endEmitViewEvents()}let t=this._viewportStart.isValid;if(this._viewportStart.invalidate(),this._configuration.setModelLineCount(this.model.getLineCount()),this._updateConfigurationViewLineCountNow(),!this._hasFocus&&this.model.getAttachedEditorCount()>=2&&t){let i=this.model._getTrackedRange(this._viewportStart.modelTrackedRange);if(i){let o=this.coordinatesConverter.convertModelPositionToViewPosition(i.getStartPosition()),r=this.viewLayout.getVerticalOffsetForLineNumber(o.lineNumber);this.viewLayout.setScrollPosition({scrollTop:r+this._viewportStart.startLineDelta},1)}}try{let i=this._eventDispatcher.beginEmitViewEvents();e instanceof bw&&i.emitOutgoingEvent(new I$(e.contentChangedEvent)),this._cursor.onModelContentChanged(i,e)}finally{this._eventDispatcher.endEmitViewEvents()}this._handleVisibleLinesChanged()})),this._register(this.model.onDidChangeTokens(e=>{let t=[];for(let i=0,o=e.ranges.length;i{this._eventDispatcher.emitSingleViewEvent(new c$),this.cursorConfig=new Hb(this.model.getLanguageId(),this.model.getOptions(),this._configuration,this.languageConfigurationService),this._cursor.updateConfiguration(this.cursorConfig),this._eventDispatcher.emitOutgoingEvent(new L$(e))})),this._register(this.model.onDidChangeLanguage(e=>{this.cursorConfig=new Hb(this.model.getLanguageId(),this.model.getOptions(),this._configuration,this.languageConfigurationService),this._cursor.updateConfiguration(this.cursorConfig),this._eventDispatcher.emitOutgoingEvent(new k$(e))})),this._register(this.model.onDidChangeOptions(e=>{if(this._lines.setTabSize(this.model.getOptions().tabSize)){try{let t=this._eventDispatcher.beginEmitViewEvents();t.emitViewEvent(new w0),t.emitViewEvent(new y0),t.emitViewEvent(new zg(null)),this._cursor.onLineMappingChanged(t),this._decorations.onLineMappingChanged(),this.viewLayout.onFlushed(this.getLineCount())}finally{this._eventDispatcher.endEmitViewEvents()}this._updateConfigurationViewLineCount.schedule()}this.cursorConfig=new Hb(this.model.getLanguageId(),this.model.getOptions(),this._configuration,this.languageConfigurationService),this._cursor.updateConfiguration(this.cursorConfig),this._eventDispatcher.emitOutgoingEvent(new E$(e))})),this._register(this.model.onDidChangeDecorations(e=>{this._decorations.onModelDecorationsChanged(),this._eventDispatcher.emitSingleViewEvent(new zg(e)),this._eventDispatcher.emitOutgoingEvent(new S$(e))}))}setHiddenAreas(e,t){this.hiddenAreasModel.setHiddenAreas(t,e);let i=this.hiddenAreasModel.getMergedRanges();if(i===this.previousHiddenAreas)return;this.previousHiddenAreas=i;let o=this._captureStableViewport(),r=!1;try{let s=this._eventDispatcher.beginEmitViewEvents();r=this._lines.setHiddenAreas(i),r&&(s.emitViewEvent(new w0),s.emitViewEvent(new y0),s.emitViewEvent(new zg(null)),this._cursor.onLineMappingChanged(s),this._decorations.onLineMappingChanged(),this.viewLayout.onFlushed(this.getLineCount()),this.viewLayout.onHeightMaybeChanged());let a=o.viewportStartModelPosition?.lineNumber;a&&i.some(c=>c.startLineNumber<=a&&a<=c.endLineNumber)||o.recoverViewportStart(this.coordinatesConverter,this.viewLayout)}finally{this._eventDispatcher.endEmitViewEvents()}this._updateConfigurationViewLineCount.schedule(),r&&this._eventDispatcher.emitOutgoingEvent(new w$)}getVisibleRangesPlusViewportAboveBelow(){let e=this._configuration.options.get(146),t=this._configuration.options.get(67),i=Math.max(20,Math.round(e.height/t)),o=this.viewLayout.getLinesViewportData(),r=Math.max(1,o.completelyVisibleStartLineNumber-i),s=Math.min(this.getLineCount(),o.completelyVisibleEndLineNumber+i);return this._toModelVisibleRanges(new S(r,this.getLineMinColumn(r),s,this.getLineMaxColumn(s)))}getVisibleRanges(){let e=this.getCompletelyVisibleViewRange();return this._toModelVisibleRanges(e)}getHiddenAreas(){return this._lines.getHiddenAreas()}_toModelVisibleRanges(e){let t=this.coordinatesConverter.convertViewRangeToModelRange(e),i=this._lines.getHiddenAreas();if(i.length===0)return[t];let o=[],r=0,s=t.startLineNumber,a=t.startColumn,l=t.endLineNumber,c=t.endColumn;for(let d=0,u=i.length;dl||(s"u")return this._reduceRestoreStateCompatibility(e);let t=this.model.validatePosition(e.firstPosition),i=this.coordinatesConverter.convertModelPositionToViewPosition(t),o=this.viewLayout.getVerticalOffsetForLineNumber(i.lineNumber)-e.firstPositionDeltaTop;return{scrollLeft:e.scrollLeft,scrollTop:o}}_reduceRestoreStateCompatibility(e){return{scrollLeft:e.scrollLeft,scrollTop:e.scrollTopWithoutViewZones}}getTabSize(){return this.model.getOptions().tabSize}getLineCount(){return this._lines.getViewLineCount()}setViewport(e,t,i){this._viewportStart.update(this,e)}getActiveIndentGuide(e,t,i){return this._lines.getActiveIndentGuide(e,t,i)}getLinesIndentGuides(e,t){return this._lines.getViewLinesIndentGuides(e,t)}getBracketGuidesInRangeByLine(e,t,i,o){return this._lines.getViewLinesBracketGuides(e,t,i,o)}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){let t=bo(this.getLineContent(e));return t===-1?0:t+1}getLineLastNonWhitespaceColumn(e){let t=_a(this.getLineContent(e));return t===-1?0:t+2}getMinimapDecorationsInRange(e){return this._decorations.getMinimapDecorationsInRange(e)}getDecorationsInViewport(e){return this._decorations.getDecorationsViewportData(e).decorations}getInjectedTextAt(e){return this._lines.getInjectedTextAt(e)}getViewportViewLineRenderingData(e,t){let o=this._decorations.getDecorationsViewportData(e).inlineDecorations[t-e.startLineNumber];return this._getViewLineRenderingData(t,o)}getViewLineRenderingData(e){let t=this._decorations.getInlineDecorationsOnLine(e);return this._getViewLineRenderingData(e,t)}_getViewLineRenderingData(e,t){let i=this.model.mightContainRTL(),o=this.model.mightContainNonBasicASCII(),r=this.getTabSize(),s=this._lines.getViewLineData(e);return s.inlineDecorations&&(t=[...t,...s.inlineDecorations.map(a=>a.toInlineDecoration(e))]),new _c(s.minColumn,s.maxColumn,s.content,s.continuesWithWrappedLine,i,o,s.tokens,t,r,s.startVisibleColumn)}getViewLineData(e){return this._lines.getViewLineData(e)}getMinimapLinesRenderingData(e,t,i){let o=this._lines.getViewLinesData(e,t,i);return new dV(this.getTabSize(),o)}getAllOverviewRulerDecorations(e){let t=this.model.getOverviewRulerDecorations(this._editorId,p1(this._configuration.options)),i=new vfe;for(let o of t){let r=o.options,s=r.overviewRuler;if(!s)continue;let a=s.position;if(a===0)continue;let l=s.getColor(e.value),c=this.coordinatesConverter.getViewLineNumberOfModelPosition(o.range.startLineNumber,o.range.startColumn),d=this.coordinatesConverter.getViewLineNumberOfModelPosition(o.range.endLineNumber,o.range.endColumn);i.accept(l,r.zIndex,c,d,a)}return i.asArray}_invalidateDecorationsColorCache(){let e=this.model.getOverviewRulerDecorations();for(let t of e)t.options.overviewRuler?.invalidateCachedColor(),t.options.minimap?.invalidateCachedColor()}getValueInRange(e,t){let i=this.coordinatesConverter.convertViewRangeToModelRange(e);return this.model.getValueInRange(i,t)}getValueLengthInRange(e,t){let i=this.coordinatesConverter.convertViewRangeToModelRange(e);return this.model.getValueLengthInRange(i,t)}modifyPosition(e,t){let i=this.coordinatesConverter.convertViewPositionToModelPosition(e),o=this.model.modifyPosition(i,t);return this.coordinatesConverter.convertModelPositionToViewPosition(o)}deduceModelPositionRelativeToViewPosition(e,t,i){let o=this.coordinatesConverter.convertViewPositionToModelPosition(e);this.model.getEOL().length===2&&(t<0?t-=i:t+=i);let s=this.model.getOffsetAt(o)+t;return this.model.getPositionAt(s)}getPlainTextToCopy(e,t,i){let o=i?`\r `:this.model.getEOL();e=e.slice(0),e.sort(S.compareRangesUsingStarts);let r=!1,s=!1;for(let l of e)l.isEmpty()?r=!0:s=!0;if(!s){if(!t)return"";let l=e.map(d=>d.startLineNumber),c="";for(let d=0;d0&&l[d-1]===l[d]||(c+=this.model.getLineContent(l[d])+o);return c}if(r&&t){let l=[],c=0;for(let d of e){let u=d.startLineNumber;d.isEmpty()?u!==c&&l.push(this.model.getLineContent(u)):l.push(this.model.getValueInRange(d,i?2:0)),c=u}return l.length===1?l[0]:l}let a=[];for(let l of e)l.isEmpty()||a.push(this.model.getValueInRange(l,i?2:0));return a.length===1?a[0]:a}getRichTextToCopy(e,t){let i=this.model.getLanguageId();if(i===Oo||e.length!==1)return null;let o=e[0];if(o.isEmpty()){if(!t)return null;let d=o.startLineNumber;o=new S(d,this.model.getLineMinColumn(d),d,this.model.getLineMaxColumn(d))}let r=this._configuration.options.get(50),s=this._getColorMap(),l=/[:;\\\/<>]/.test(r.fontFamily)||r.fontFamily===as.fontFamily,c;return l?c=as.fontFamily:(c=r.fontFamily,c=c.replace(/"/g,"'"),/[,']/.test(c)||/[+ ]/.test(c)&&(c=`'${c}'`),c=`${c}, ${as.fontFamily}`),{mode:i,html:`
    `+this._getHTMLToCopy(o,s)+"
    "}}_getHTMLToCopy(e,t){let i=e.startLineNumber,o=e.startColumn,r=e.endLineNumber,s=e.endColumn,a=this.getTabSize(),l="";for(let c=i;c<=r;c++){let d=this.model.tokenization.getLineTokens(c),u=d.getLineContent(),h=c===i?o-1:0,f=c===r?s-1:u.length;u===""?l+="
    ":l+=U2e(u,d.inflate(),t,h,f,a,kn)}return l}_getColorMap(){let e=$i.getColorMap(),t=["#000000"];if(e)for(let i=1,o=e.length;ithis._cursor.setStates(o,e,t,i))}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,t,i=0){this._withViewEventsCollector(o=>this._cursor.setSelections(o,e,t,i))}saveCursorState(){return this._cursor.saveState()}restoreCursorState(e){this._withViewEventsCollector(t=>this._cursor.restoreState(t,e))}_executeCursorEdit(e){if(this._cursor.context.cursorConfig.readOnly){this._eventDispatcher.emitOutgoingEvent(new C$);return}this._withViewEventsCollector(e)}executeEdits(e,t,i){this._executeCursorEdit(o=>this._cursor.executeEdits(o,e,t,i))}startComposition(){this._executeCursorEdit(e=>this._cursor.startComposition(e))}endComposition(e){this._executeCursorEdit(t=>this._cursor.endComposition(t,e))}type(e,t){this._executeCursorEdit(i=>this._cursor.type(i,e,t))}compositionType(e,t,i,o,r){this._executeCursorEdit(s=>this._cursor.compositionType(s,e,t,i,o,r))}paste(e,t,i,o){this._executeCursorEdit(r=>this._cursor.paste(r,e,t,i,o))}cut(e){this._executeCursorEdit(t=>this._cursor.cut(t,e))}executeCommand(e,t){this._executeCursorEdit(i=>this._cursor.executeCommand(i,e,t))}executeCommands(e,t){this._executeCursorEdit(i=>this._cursor.executeCommands(i,e,t))}revealAllCursors(e,t,i=!1){this._withViewEventsCollector(o=>this._cursor.revealAll(o,e,i,0,t,0))}revealPrimaryCursor(e,t,i=!1){this._withViewEventsCollector(o=>this._cursor.revealPrimary(o,e,i,0,t,0))}revealTopMostCursor(e){let t=this._cursor.getTopMostViewPosition(),i=new S(t.lineNumber,t.column,t.lineNumber,t.column);this._withViewEventsCollector(o=>o.emitViewEvent(new jb(e,!1,i,null,0,!0,0)))}revealBottomMostCursor(e){let t=this._cursor.getBottomMostViewPosition(),i=new S(t.lineNumber,t.column,t.lineNumber,t.column);this._withViewEventsCollector(o=>o.emitViewEvent(new jb(e,!1,i,null,0,!0,0)))}revealRange(e,t,i,o,r){this._withViewEventsCollector(s=>s.emitViewEvent(new jb(e,!1,i,null,o,t,r)))}changeWhitespace(e){this.viewLayout.changeWhitespace(e)&&(this._eventDispatcher.emitSingleViewEvent(new p$),this._eventDispatcher.emitOutgoingEvent(new x$))}_withViewEventsCollector(e){return this._transactionalTarget.batchChanges(()=>{try{let t=this._eventDispatcher.beginEmitViewEvents();return e(t)}finally{this._eventDispatcher.endEmitViewEvents()}})}batchEvents(e){this._withViewEventsCollector(()=>{e()})}normalizePosition(e,t){return this._lines.normalizePosition(e,t)}getLineIndentColumn(e){return this._lines.getLineIndentColumn(e)}},bfe=class n{static create(e){let t=e._setTrackedRange(null,new S(1,1,1,1),1);return new n(e,1,!1,t,0)}get viewLineNumber(){return this._viewLineNumber}get isValid(){return this._isValid}get modelTrackedRange(){return this._modelTrackedRange}get startLineDelta(){return this._startLineDelta}constructor(e,t,i,o,r){this._model=e,this._viewLineNumber=t,this._isValid=i,this._modelTrackedRange=o,this._startLineDelta=r}dispose(){this._model._setTrackedRange(this._modelTrackedRange,null,1)}update(e,t){let i=e.coordinatesConverter.convertViewPositionToModelPosition(new P(t,e.getLineMinColumn(t))),o=e.model._setTrackedRange(this._modelTrackedRange,new S(i.lineNumber,i.column,i.lineNumber,i.column),1),r=e.viewLayout.getVerticalOffsetForLineNumber(t),s=e.viewLayout.getCurrentScrollTop();this._viewLineNumber=t,this._isValid=!0,this._modelTrackedRange=o,this._startLineDelta=s-r}invalidate(){this._isValid=!1}},vfe=class{constructor(){this._asMap=Object.create(null),this.asArray=[]}accept(e,t,i,o,r){let s=this._asMap[e];if(s){let a=s.data,l=a[a.length-3],c=a[a.length-1];if(l===r&&c+1>=i){o>c&&(a[a.length-1]=o);return}a.push(r,i,o)}else{let a=new i0(e,t,[r,i,o]);this._asMap[e]=a,this.asArray.push(a)}}},xfe=class{constructor(){this.hiddenAreas=new Map,this.shouldRecompute=!1,this.ranges=[]}setHiddenAreas(e,t){let i=this.hiddenAreas.get(e);i&&z8e(i,t)||(this.hiddenAreas.set(e,t),this.shouldRecompute=!0)}getMergedRanges(){if(!this.shouldRecompute)return this.ranges;this.shouldRecompute=!1;let e=Array.from(this.hiddenAreas.values()).reduce((t,i)=>oht(t,i),[]);return z8e(this.ranges,e)?this.ranges:(this.ranges=e,this.ranges)}};G$=class{constructor(e,t){this.viewportStartModelPosition=e,this.startLineDelta=t}recoverViewportStart(e,t){if(!this.viewportStartModelPosition)return;let i=e.convertModelPositionToViewPosition(this.viewportStartModelPosition),o=t.getVerticalOffsetForLineNumber(i.lineNumber);t.setScrollPosition({scrollTop:o+this.startLineDelta},1)}}});function wfe(n){return aht+encodeURIComponent(n.toString())+lht}function uht(n){return cht+encodeURIComponent(n.toString())+dht}var rht,qb,k0,Bw,sht,yfe,Y$,Da,Cfe,Sfe,kfe,Lfe,aht,lht,cht,dht,CP=k(()=>{i3e();ke();je();Ie();j();ds();n3e();bu();a3e();fV();mt();Po();w8e();S8e();Ihe();k8e();ir();Tf();Nu();qe();we();Ui();lP();tfe();q2();Si();Ko();Ho();Qt();E8e();V8e();pe();uc();Gi();it();Fe();JC();ea();Wn();Yi();an();rht=function(n,e,t,i){var o=arguments.length,r=o<3?e:i===null?i=Object.getOwnPropertyDescriptor(e,t):i,s;if(typeof Reflect=="object"&&typeof Reflect.decorate=="function")r=Reflect.decorate(n,e,t,i);else for(var a=n.length-1;a>=0;a--)(s=n[a])&&(r=(o<3?s(r):o>3?s(e,t,r):s(e,t))||r);return o>3&&r&&Object.defineProperty(e,t,r),r},qb=function(n,e){return function(t,i){e(t,i,n)}},Bw=class extends D{static{k0=this}static{this.dropIntoEditorDecorationOptions=tt.register({description:"workbench-dnd-target",className:"dnd-target"})}get isSimpleWidget(){return this._configuration.isSimpleWidget}get contextMenuId(){return this._configuration.contextMenuId}constructor(e,t,i,o,r,s,a,l,c,d,u,h){super(),this.languageConfigurationService=u,this._deliveryQueue=fTe(),this._contributions=this._register(new i$),this._onDidDispose=this._register(new A),this.onDidDispose=this._onDidDispose.event,this._onDidChangeModelContent=this._register(new A({deliveryQueue:this._deliveryQueue})),this.onDidChangeModelContent=this._onDidChangeModelContent.event,this._onDidChangeModelLanguage=this._register(new A({deliveryQueue:this._deliveryQueue})),this.onDidChangeModelLanguage=this._onDidChangeModelLanguage.event,this._onDidChangeModelLanguageConfiguration=this._register(new A({deliveryQueue:this._deliveryQueue})),this.onDidChangeModelLanguageConfiguration=this._onDidChangeModelLanguageConfiguration.event,this._onDidChangeModelOptions=this._register(new A({deliveryQueue:this._deliveryQueue})),this.onDidChangeModelOptions=this._onDidChangeModelOptions.event,this._onDidChangeModelDecorations=this._register(new A({deliveryQueue:this._deliveryQueue})),this.onDidChangeModelDecorations=this._onDidChangeModelDecorations.event,this._onDidChangeModelTokens=this._register(new A({deliveryQueue:this._deliveryQueue})),this.onDidChangeModelTokens=this._onDidChangeModelTokens.event,this._onDidChangeConfiguration=this._register(new A({deliveryQueue:this._deliveryQueue})),this.onDidChangeConfiguration=this._onDidChangeConfiguration.event,this._onWillChangeModel=this._register(new A({deliveryQueue:this._deliveryQueue})),this.onWillChangeModel=this._onWillChangeModel.event,this._onDidChangeModel=this._register(new A({deliveryQueue:this._deliveryQueue})),this.onDidChangeModel=this._onDidChangeModel.event,this._onDidChangeCursorPosition=this._register(new A({deliveryQueue:this._deliveryQueue})),this.onDidChangeCursorPosition=this._onDidChangeCursorPosition.event,this._onDidChangeCursorSelection=this._register(new A({deliveryQueue:this._deliveryQueue})),this.onDidChangeCursorSelection=this._onDidChangeCursorSelection.event,this._onDidAttemptReadOnlyEdit=this._register(new Da(this._contributions,this._deliveryQueue)),this.onDidAttemptReadOnlyEdit=this._onDidAttemptReadOnlyEdit.event,this._onDidLayoutChange=this._register(new A({deliveryQueue:this._deliveryQueue})),this.onDidLayoutChange=this._onDidLayoutChange.event,this._editorTextFocus=this._register(new Y$({deliveryQueue:this._deliveryQueue})),this.onDidFocusEditorText=this._editorTextFocus.onDidChangeToTrue,this.onDidBlurEditorText=this._editorTextFocus.onDidChangeToFalse,this._editorWidgetFocus=this._register(new Y$({deliveryQueue:this._deliveryQueue})),this.onDidFocusEditorWidget=this._editorWidgetFocus.onDidChangeToTrue,this.onDidBlurEditorWidget=this._editorWidgetFocus.onDidChangeToFalse,this._onWillType=this._register(new Da(this._contributions,this._deliveryQueue)),this.onWillType=this._onWillType.event,this._onDidType=this._register(new Da(this._contributions,this._deliveryQueue)),this.onDidType=this._onDidType.event,this._onDidCompositionStart=this._register(new Da(this._contributions,this._deliveryQueue)),this.onDidCompositionStart=this._onDidCompositionStart.event,this._onDidCompositionEnd=this._register(new Da(this._contributions,this._deliveryQueue)),this.onDidCompositionEnd=this._onDidCompositionEnd.event,this._onDidPaste=this._register(new Da(this._contributions,this._deliveryQueue)),this.onDidPaste=this._onDidPaste.event,this._onMouseUp=this._register(new Da(this._contributions,this._deliveryQueue)),this.onMouseUp=this._onMouseUp.event,this._onMouseDown=this._register(new Da(this._contributions,this._deliveryQueue)),this.onMouseDown=this._onMouseDown.event,this._onMouseDrag=this._register(new Da(this._contributions,this._deliveryQueue)),this.onMouseDrag=this._onMouseDrag.event,this._onMouseDrop=this._register(new Da(this._contributions,this._deliveryQueue)),this.onMouseDrop=this._onMouseDrop.event,this._onMouseDropCanceled=this._register(new Da(this._contributions,this._deliveryQueue)),this.onMouseDropCanceled=this._onMouseDropCanceled.event,this._onDropIntoEditor=this._register(new Da(this._contributions,this._deliveryQueue)),this.onDropIntoEditor=this._onDropIntoEditor.event,this._onContextMenu=this._register(new Da(this._contributions,this._deliveryQueue)),this.onContextMenu=this._onContextMenu.event,this._onMouseMove=this._register(new Da(this._contributions,this._deliveryQueue)),this.onMouseMove=this._onMouseMove.event,this._onMouseLeave=this._register(new Da(this._contributions,this._deliveryQueue)),this.onMouseLeave=this._onMouseLeave.event,this._onMouseWheel=this._register(new Da(this._contributions,this._deliveryQueue)),this.onMouseWheel=this._onMouseWheel.event,this._onKeyUp=this._register(new Da(this._contributions,this._deliveryQueue)),this.onKeyUp=this._onKeyUp.event,this._onKeyDown=this._register(new Da(this._contributions,this._deliveryQueue)),this.onKeyDown=this._onKeyDown.event,this._onDidContentSizeChange=this._register(new A({deliveryQueue:this._deliveryQueue})),this.onDidContentSizeChange=this._onDidContentSizeChange.event,this._onDidScrollChange=this._register(new A({deliveryQueue:this._deliveryQueue})),this.onDidScrollChange=this._onDidScrollChange.event,this._onDidChangeViewZones=this._register(new A({deliveryQueue:this._deliveryQueue})),this.onDidChangeViewZones=this._onDidChangeViewZones.event,this._onDidChangeHiddenAreas=this._register(new A({deliveryQueue:this._deliveryQueue})),this.onDidChangeHiddenAreas=this._onDidChangeHiddenAreas.event,this._updateCounter=0,this._onBeginUpdate=this._register(new A),this.onBeginUpdate=this._onBeginUpdate.event,this._onEndUpdate=this._register(new A),this.onEndUpdate=this._onEndUpdate.event,this._actions=new Map,this._bannerDomNode=null,this._dropIntoEditorDecorations=this.createDecorationsCollection(),r.willCreateCodeEditor();let f={...t};this._domElement=e,this._overflowWidgetsDomNode=f.overflowWidgetsDomNode,delete f.overflowWidgetsDomNode,this._id=++sht,this._decorationTypeKeysToIds={},this._decorationTypeSubtypes={},this._telemetryData=i.telemetryData,this._configuration=this._register(this._createConfiguration(i.isSimpleWidget||!1,i.contextMenuId??(i.isSimpleWidget?Te.SimpleEditorContext:Te.EditorContext),f,d)),this._register(this._configuration.onDidChange(_=>{this._onDidChangeConfiguration.fire(_);let b=this._configuration.options;if(_.hasChanged(146)){let v=b.get(146);this._onDidLayoutChange.fire(v)}})),this._contextKeyService=this._register(a.createScoped(this._domElement)),this._notificationService=c,this._codeEditorService=r,this._commandService=s,this._themeService=l,this._register(new Cfe(this,this._contextKeyService)),this._register(new Sfe(this,this._contextKeyService,h)),this._instantiationService=this._register(o.createChild(new Fu([Le,this._contextKeyService]))),this._modelData=null,this._focusTracker=new kfe(e,this._overflowWidgetsDomNode),this._register(this._focusTracker.onChange(()=>{this._editorWidgetFocus.setValue(this._focusTracker.hasFocus())})),this._contentWidgets={},this._overlayWidgets={},this._glyphMarginWidgets={};let p;Array.isArray(i.contributions)?p=i.contributions:p=Nm.getEditorContributions(),this._contributions.initialize(this,p,this._instantiationService);for(let _ of Nm.getEditorActions()){if(this._actions.has(_.id)){Be(new Error(`Cannot have two actions with the same id ${_.id}`));continue}let b=new jE(_.id,_.label,_.alias,_.metadata,_.precondition??void 0,v=>this._instantiationService.invokeFunction(x=>Promise.resolve(_.runEditorCommand(x,this,v))),this._contextKeyService);this._actions.set(b.id,b)}let g=()=>!this._configuration.options.get(92)&&this._configuration.options.get(36).enabled;this._register(new NB(this._domElement,{onDragOver:_=>{if(!g())return;let b=this.getTargetAtClientPoint(_.clientX,_.clientY);b?.position&&this.showDropIndicatorAt(b.position)},onDrop:async _=>{if(!g()||(this.removeDropIndicator(),!_.dataTransfer))return;let b=this.getTargetAtClientPoint(_.clientX,_.clientY);b?.position&&this._onDropIntoEditor.fire({position:b.position,event:_})},onDragLeave:()=>{this.removeDropIndicator()},onDragEnd:()=>{this.removeDropIndicator()}})),this._codeEditorService.addCodeEditor(this)}writeScreenReaderContent(e){this._modelData?.view.writeScreenReaderContent(e)}_createConfiguration(e,t,i,o){return new pV(e,t,i,this._domElement,o)}getId(){return this.getEditorType()+":"+this._id}getEditorType(){return Pb.ICodeEditor}dispose(){this._codeEditorService.removeCodeEditor(this),this._focusTracker.dispose(),this._actions.clear(),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?Fr.getWordAtPosition(this._modelData.model,this._configuration.options.get(132),this._configuration.options.get(131),e):null}getValue(e=null){if(!this._modelData)return"";let t=!!(e&&e.preserveBOM),i=0;return e&&e.lineEnding&&e.lineEnding===` `?i=1:e&&e.lineEnding&&e.lineEnding===`\r `&&(i=2),this._modelData.model.getValue(i,t)}setValue(e){try{if(this._beginUpdate(),!this._modelData)return;this._modelData.model.setValue(e)}finally{this._endUpdate()}}getModel(){return this._modelData?this._modelData.model:null}setModel(e=null){try{this._beginUpdate();let t=e;if(this._modelData===null&&t===null||this._modelData&&this._modelData.model===t)return;let i={oldModelUrl:this._modelData?.model.uri||null,newModelUrl:t?.uri||null};this._onWillChangeModel.fire(i);let o=this.hasTextFocus(),r=this._detachModel();this._attachModel(t),o&&this.hasModel()&&this.focus(),this._removeDecorationTypes(),this._onDidChangeModel.fire(i),this._postDetachModelCleanup(r),this._contributionsDisposable=this._contributions.onAfterModelAttached()}finally{this._endUpdate()}}_removeDecorationTypes(){if(this._decorationTypeKeysToIds={},this._decorationTypeSubtypes){for(let e in this._decorationTypeSubtypes){let t=this._decorationTypeSubtypes[e];for(let i in t)this._removeDecorationType(e+"-"+i)}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,t,i,o){let r=e.model.validatePosition({lineNumber:t,column:i}),s=e.viewModel.coordinatesConverter.convertModelPositionToViewPosition(r);return e.viewModel.viewLayout.getVerticalOffsetAfterLineNumber(s.lineNumber,o)}getTopForLineNumber(e,t=!1){return this._modelData?k0._getVerticalOffsetForPosition(this._modelData,e,1,t):-1}getTopForPosition(e,t){return this._modelData?k0._getVerticalOffsetForPosition(this._modelData,e,t,!1):-1}static _getVerticalOffsetForPosition(e,t,i,o=!1){let r=e.model.validatePosition({lineNumber:t,column:i}),s=e.viewModel.coordinatesConverter.convertModelPositionToViewPosition(r);return e.viewModel.viewLayout.getVerticalOffsetForLineNumber(s.lineNumber,o)}getBottomForLineNumber(e,t=!1){if(!this._modelData)return-1;let i=this._modelData.model.getLineMaxColumn(e);return k0._getVerticalOffsetAfterPosition(this._modelData,e,i,t)}setHiddenAreas(e,t){this._modelData?.viewModel.setHiddenAreas(e.map(i=>S.lift(i)),t)}getVisibleColumnFromPosition(e){if(!this._modelData)return e.column;let t=this._modelData.model.validatePosition(e),i=this._modelData.model.getOptions().tabSize;return Un.visibleColumnFromColumn(this._modelData.model.getLineContent(t.lineNumber),t.column,i)+1}getPosition(){return this._modelData?this._modelData.viewModel.getPosition():null}setPosition(e,t="api"){if(this._modelData){if(!P.isIPosition(e))throw new Error("Invalid arguments");this._modelData.viewModel.setSelections(t,[{selectionStartLineNumber:e.lineNumber,selectionStartColumn:e.column,positionLineNumber:e.lineNumber,positionColumn:e.column}])}}_sendRevealRange(e,t,i,o){if(!this._modelData)return;if(!S.isIRange(e))throw new Error("Invalid arguments");let r=this._modelData.model.validateRange(e),s=this._modelData.viewModel.coordinatesConverter.convertModelRangeToViewRange(r);this._modelData.viewModel.revealRange("api",i,s,t,o)}revealLine(e,t=0){this._revealLine(e,0,t)}revealLineInCenter(e,t=0){this._revealLine(e,1,t)}revealLineInCenterIfOutsideViewport(e,t=0){this._revealLine(e,2,t)}revealLineNearTop(e,t=0){this._revealLine(e,5,t)}_revealLine(e,t,i){if(typeof e!="number")throw new Error("Invalid arguments");this._sendRevealRange(new S(e,1,e,1),t,!1,i)}revealPosition(e,t=0){this._revealPosition(e,0,!0,t)}revealPositionInCenter(e,t=0){this._revealPosition(e,1,!0,t)}revealPositionInCenterIfOutsideViewport(e,t=0){this._revealPosition(e,2,!0,t)}revealPositionNearTop(e,t=0){this._revealPosition(e,5,!0,t)}_revealPosition(e,t,i,o){if(!P.isIPosition(e))throw new Error("Invalid arguments");this._sendRevealRange(new S(e.lineNumber,e.column,e.lineNumber,e.column),t,i,o)}getSelection(){return this._modelData?this._modelData.viewModel.getSelection():null}getSelections(){return this._modelData?this._modelData.viewModel.getSelections():null}setSelection(e,t="api"){let i=Se.isISelection(e),o=S.isIRange(e);if(!i&&!o)throw new Error("Invalid arguments");if(i)this._setSelectionImpl(e,t);else if(o){let r={selectionStartLineNumber:e.startLineNumber,selectionStartColumn:e.startColumn,positionLineNumber:e.endLineNumber,positionColumn:e.endColumn};this._setSelectionImpl(r,t)}}_setSelectionImpl(e,t){if(!this._modelData)return;let i=new Se(e.selectionStartLineNumber,e.selectionStartColumn,e.positionLineNumber,e.positionColumn);this._modelData.viewModel.setSelections(t,[i])}revealLines(e,t,i=0){this._revealLines(e,t,0,i)}revealLinesInCenter(e,t,i=0){this._revealLines(e,t,1,i)}revealLinesInCenterIfOutsideViewport(e,t,i=0){this._revealLines(e,t,2,i)}revealLinesNearTop(e,t,i=0){this._revealLines(e,t,5,i)}_revealLines(e,t,i,o){if(typeof e!="number"||typeof t!="number")throw new Error("Invalid arguments");this._sendRevealRange(new S(e,1,t,1),i,!1,o)}revealRange(e,t=0,i=!1,o=!0){this._revealRange(e,i?1:0,o,t)}revealRangeInCenter(e,t=0){this._revealRange(e,1,!0,t)}revealRangeInCenterIfOutsideViewport(e,t=0){this._revealRange(e,2,!0,t)}revealRangeNearTop(e,t=0){this._revealRange(e,5,!0,t)}revealRangeNearTopIfOutsideViewport(e,t=0){this._revealRange(e,6,!0,t)}revealRangeAtTop(e,t=0){this._revealRange(e,3,!0,t)}_revealRange(e,t,i,o){if(!S.isIRange(e))throw new Error("Invalid arguments");this._sendRevealRange(S.lift(e),t,i,o)}setSelections(e,t="api",i=0){if(this._modelData){if(!e||e.length===0)throw new Error("Invalid arguments");for(let o=0,r=e.length;o0&&this._modelData.viewModel.restoreCursorState(i):this._modelData.viewModel.restoreCursorState([i]),this._contributions.restoreViewState(t.contributionsState||{});let o=this._modelData.viewModel.reduceRestoreState(t.viewState);this._modelData.view.restoreState(o)}}handleInitialized(){this._getViewModel()?.visibleLinesStabilized()}getContribution(e){return this._contributions.get(e)}getActions(){return Array.from(this._actions.values())}getSupportedActions(){let e=this.getActions();return e=e.filter(t=>t.isSupported()),e}getAction(e){return this._actions.get(e)||null}trigger(e,t,i){i=i||{};try{switch(this._beginUpdate(),t){case"compositionStart":this._startComposition();return;case"compositionEnd":this._endComposition(e);return;case"type":{let r=i;this._type(e,r.text||"");return}case"replacePreviousChar":{let r=i;this._compositionType(e,r.text||"",r.replaceCharCnt||0,0,0);return}case"compositionType":{let r=i;this._compositionType(e,r.text||"",r.replacePrevCharCnt||0,r.replaceNextCharCnt||0,r.positionDelta||0);return}case"paste":{let r=i;this._paste(e,r.text||"",r.pasteOnNewLine||!1,r.multicursorText||null,r.mode||null,r.clipboardEvent);return}case"cut":this._cut(e);return}let o=this.getAction(t);if(o){Promise.resolve(o.run(i)).then(void 0,Be);return}if(!this._modelData||this._triggerEditorCommand(e,t,i))return;this._triggerCommand(t,i)}finally{this._endUpdate()}}_triggerCommand(e,t){this._commandService.executeCommand(e,t)}_startComposition(){this._modelData&&(this._modelData.viewModel.startComposition(),this._onDidCompositionStart.fire())}_endComposition(e){this._modelData&&(this._modelData.viewModel.endComposition(e),this._onDidCompositionEnd.fire())}_type(e,t){!this._modelData||t.length===0||(e==="keyboard"&&this._onWillType.fire(t),this._modelData.viewModel.type(t,e),e==="keyboard"&&this._onDidType.fire(t))}_compositionType(e,t,i,o,r){this._modelData&&this._modelData.viewModel.compositionType(t,i,o,r,e)}_paste(e,t,i,o,r,s){if(!this._modelData)return;let a=this._modelData.viewModel,l=a.getSelection().getStartPosition();a.paste(t,i,o,e);let c=a.getSelection().getStartPosition();e==="keyboard"&&this._onDidPaste.fire({clipboardEvent:s,range:new S(l.lineNumber,l.column,c.lineNumber,c.column),languageId:r})}_cut(e){this._modelData&&this._modelData.viewModel.cut(e)}_triggerEditorCommand(e,t,i){let o=Nm.getEditorCommand(t);return o?(i=i||{},i.source=e,this._instantiationService.invokeFunction(r=>{Promise.resolve(o.runEditorCommand(r,this,i)).then(void 0,Be)}),!0):!1}_getViewModel(){return this._modelData?this._modelData.viewModel:null}pushUndoStop(){return!this._modelData||this._configuration.options.get(92)?!1:(this._modelData.model.pushStackElement(),!0)}popUndoStop(){return!this._modelData||this._configuration.options.get(92)?!1:(this._modelData.model.popStackElement(),!0)}executeEdits(e,t,i){if(!this._modelData||this._configuration.options.get(92))return!1;let o;return i?Array.isArray(i)?o=()=>i:o=i:o=()=>null,this._modelData.viewModel.executeEdits(e,t,o),!0}executeCommand(e,t){this._modelData&&this._modelData.viewModel.executeCommand(t,e)}executeCommands(e,t){this._modelData&&this._modelData.viewModel.executeCommands(t,e)}createDecorationsCollection(e){return new Lfe(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,p1(this._configuration.options)):null}getDecorationsInRange(e){return this._modelData?this._modelData.model.getDecorationsInRange(e,this._id,p1(this._configuration.options)):null}deltaDecorations(e,t){return this._modelData?e.length===0&&t.length===0?e:this._modelData.model.deltaDecorations(e,t,this._id):[]}removeDecorations(e){!this._modelData||e.length===0||this._modelData.model.changeDecorations(t=>{t.deltaDecorations(e,[])})}removeDecorationsByType(e){let t=this._decorationTypeKeysToIds[e];t&&this.changeDecorations(i=>i.deltaDecorations(t,[])),this._decorationTypeKeysToIds.hasOwnProperty(e)&&delete this._decorationTypeKeysToIds[e],this._decorationTypeSubtypes.hasOwnProperty(e)&&delete this._decorationTypeSubtypes[e]}getLayoutInfo(){return this._configuration.options.get(146)}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)}delegateScrollFromMouseWheelEvent(e){!this._modelData||!this._modelData.hasRealView||this._modelData.view.delegateScrollFromMouseWheelEvent(e)}layout(e,t=!1){this._configuration.observeContainer(e),t||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){let t={widget:e,position:e.getPosition()};this._contentWidgets.hasOwnProperty(e.getId())&&console.warn("Overwriting a content widget with the same id:"+e.getId()),this._contentWidgets[e.getId()]=t,this._modelData&&this._modelData.hasRealView&&this._modelData.view.addContentWidget(t)}layoutContentWidget(e){let t=e.getId();if(this._contentWidgets.hasOwnProperty(t)){let i=this._contentWidgets[t];i.position=e.getPosition(),this._modelData&&this._modelData.hasRealView&&this._modelData.view.layoutContentWidget(i)}}removeContentWidget(e){let t=e.getId();if(this._contentWidgets.hasOwnProperty(t)){let i=this._contentWidgets[t];delete this._contentWidgets[t],this._modelData&&this._modelData.hasRealView&&this._modelData.view.removeContentWidget(i)}}addOverlayWidget(e){let t={widget:e,position:e.getPosition()};this._overlayWidgets.hasOwnProperty(e.getId())&&console.warn("Overwriting an overlay widget with the same id."),this._overlayWidgets[e.getId()]=t,this._modelData&&this._modelData.hasRealView&&this._modelData.view.addOverlayWidget(t)}layoutOverlayWidget(e){let t=e.getId();if(this._overlayWidgets.hasOwnProperty(t)){let i=this._overlayWidgets[t];i.position=e.getPosition(),this._modelData&&this._modelData.hasRealView&&this._modelData.view.layoutOverlayWidget(i)}}removeOverlayWidget(e){let t=e.getId();if(this._overlayWidgets.hasOwnProperty(t)){let i=this._overlayWidgets[t];delete this._overlayWidgets[t],this._modelData&&this._modelData.hasRealView&&this._modelData.view.removeOverlayWidget(i)}}addGlyphMarginWidget(e){let t={widget:e,position:e.getPosition()};this._glyphMarginWidgets.hasOwnProperty(e.getId())&&console.warn("Overwriting a glyph margin widget with the same id."),this._glyphMarginWidgets[e.getId()]=t,this._modelData&&this._modelData.hasRealView&&this._modelData.view.addGlyphMarginWidget(t)}layoutGlyphMarginWidget(e){let t=e.getId();if(this._glyphMarginWidgets.hasOwnProperty(t)){let i=this._glyphMarginWidgets[t];i.position=e.getPosition(),this._modelData&&this._modelData.hasRealView&&this._modelData.view.layoutGlyphMarginWidget(i)}}removeGlyphMarginWidget(e){let t=e.getId();if(this._glyphMarginWidgets.hasOwnProperty(t)){let i=this._glyphMarginWidgets[t];delete this._glyphMarginWidgets[t],this._modelData&&this._modelData.hasRealView&&this._modelData.view.removeGlyphMarginWidget(i)}}changeViewZones(e){!this._modelData||!this._modelData.hasRealView||this._modelData.view.change(e)}getTargetAtClientPoint(e,t){return!this._modelData||!this._modelData.hasRealView?null:this._modelData.view.getTargetAtClientPoint(e,t)}getScrolledVisiblePosition(e){if(!this._modelData||!this._modelData.hasRealView)return null;let t=this._modelData.model.validatePosition(e),i=this._configuration.options,o=i.get(146),r=k0._getVerticalOffsetForPosition(this._modelData,t.lineNumber,t.column)-this.getScrollTop(),s=this._modelData.view.getOffsetForColumn(t.lineNumber,t.column)+o.glyphMarginWidth+o.lineNumbersWidth+o.decorationsWidth-this.getScrollLeft();return{top:r,left:s,height:i.get(67)}}getOffsetForColumn(e,t){return!this._modelData||!this._modelData.hasRealView?-1:this._modelData.view.getOffsetForColumn(e,t)}render(e=!1){!this._modelData||!this._modelData.hasRealView||this._modelData.viewModel.batchEvents(()=>{this._modelData.view.render(!0,e)})}setAriaOptions(e){!this._modelData||!this._modelData.hasRealView||this._modelData.view.setAriaOptions(e)}applyFontInfo(e){Kn(e,this._configuration.options.get(50))}setBanner(e,t){this._bannerDomNode&&this._domElement.contains(this._bannerDomNode)&&this._bannerDomNode.remove(),this._bannerDomNode=e,this._configuration.setReservedHeight(e?t:0),this._bannerDomNode&&this._domElement.prepend(this._bannerDomNode)}_attachModel(e){if(!e){this._modelData=null;return}let t=[];this._domElement.setAttribute("data-mode-id",e.getLanguageId()),this._configuration.setIsDominatedByLongLines(e.isDominatedByLongLines()),this._configuration.setModelLineCount(e.getLineCount());let i=e.onBeforeAttached(),o=new K$(this._id,this._configuration,e,t$.create(Me(this._domElement)),n$.create(this._configuration.options),a=>us(Me(this._domElement),a),this.languageConfigurationService,this._themeService,i,{batchChanges:a=>{try{return this._beginUpdate(),a()}finally{this._endUpdate()}}});t.push(e.onWillDispose(()=>this.setModel(null))),t.push(o.onEvent(a=>{switch(a.kind){case 0:this._onDidContentSizeChange.fire(a);break;case 1:this._editorTextFocus.setValue(a.hasFocus);break;case 2:this._onDidScrollChange.fire(a);break;case 3:this._onDidChangeViewZones.fire();break;case 4:this._onDidChangeHiddenAreas.fire();break;case 5:this._onDidAttemptReadOnlyEdit.fire();break;case 6:{if(a.reachedMaxCursorCount){let u=this.getOption(80),h=m("cursors.maximum","The number of cursors has been limited to {0}. Consider using [find and replace](https://code.visualstudio.com/docs/editor/codebasics#_find-and-replace) for larger changes or increase the editor multi cursor limit setting.",u);this._notificationService.prompt(zx.Warning,h,[{label:"Find and Replace",run:()=>{this._commandService.executeCommand("editor.action.startFindReplaceAction")}},{label:m("goToSetting","Increase Multi Cursor Limit"),run:()=>{this._commandService.executeCommand("workbench.action.openSettings2",{query:"editor.multiCursorLimit"})}}])}let l=[];for(let u=0,h=a.selections.length;u{this._paste("keyboard",r,s,a,l)},type:r=>{this._type("keyboard",r)},compositionType:(r,s,a,l)=>{this._compositionType("keyboard",r,s,a,l)},startComposition:()=>{this._startComposition()},endComposition:()=>{this._endComposition("keyboard")},cut:()=>{this._cut("keyboard")}}:t={paste:(r,s,a,l)=>{let c={text:r,pasteOnNewLine:s,multicursorText:a,mode:l};this._commandService.executeCommand("paste",c)},type:r=>{let s={text:r};this._commandService.executeCommand("type",s)},compositionType:(r,s,a,l)=>{if(a||l){let c={text:r,replacePrevCharCnt:s,replaceNextCharCnt:a,positionDelta:l};this._commandService.executeCommand("compositionType",c)}else{let c={text:r,replaceCharCnt:s};this._commandService.executeCommand("replacePreviousChar",c)}},startComposition:()=>{this._commandService.executeCommand("compositionStart",{})},endComposition:()=>{this._commandService.executeCommand("compositionEnd",{})},cut:()=>{this._commandService.executeCommand("cut",{})}};let i=new WE(e.coordinatesConverter);return i.onKeyDown=r=>this._onKeyDown.fire(r),i.onKeyUp=r=>this._onKeyUp.fire(r),i.onContextMenu=r=>this._onContextMenu.fire(r),i.onMouseMove=r=>this._onMouseMove.fire(r),i.onMouseLeave=r=>this._onMouseLeave.fire(r),i.onMouseDown=r=>this._onMouseDown.fire(r),i.onMouseUp=r=>this._onMouseUp.fire(r),i.onMouseDrag=r=>this._onMouseDrag.fire(r),i.onMouseDrop=r=>this._onMouseDrop.fire(r),i.onMouseDropCanceled=r=>this._onMouseDropCanceled.fire(r),i.onMouseWheel=r=>this._onMouseWheel.fire(r),[new e$(t,this._configuration,this._themeService.getColorTheme(),e,i,this._overflowWidgetsDomNode,this._instantiationService),!0]}_postDetachModelCleanup(e){e?.removeAllDecorationsWithOwnerId(this._id)}_detachModel(){if(this._contributionsDisposable?.dispose(),this._contributionsDisposable=void 0,!this._modelData)return null;let e=this._modelData.model,t=this._modelData.hasRealView?this._modelData.view.domNode.domNode:null;return this._modelData.dispose(),this._modelData=null,this._domElement.removeAttribute("data-mode-id"),t&&this._domElement.contains(t)&&t.remove(),this._bannerDomNode&&this._domElement.contains(this._bannerDomNode)&&this._bannerDomNode.remove(),e}_removeDecorationType(e){this._codeEditorService.removeDecorationType(e)}hasModel(){return this._modelData!==null}showDropIndicatorAt(e){let t=[{range:new S(e.lineNumber,e.column,e.lineNumber,e.column),options:k0.dropIntoEditorDecorationOptions}];this._dropIntoEditorDecorations.set(t),this.revealPosition(e,1)}removeDropIndicator(){this._dropIntoEditorDecorations.clear()}setContextValue(e,t){this._contextKeyService.createKey(e,t)}_beginUpdate(){this._updateCounter++,this._updateCounter===1&&this._onBeginUpdate.fire()}_endUpdate(){this._updateCounter--,this._updateCounter===0&&this._onEndUpdate.fire()}};Bw=k0=rht([qb(3,he),qb(4,xt),qb(5,$t),qb(6,Le),qb(7,Vi),qb(8,Di),qb(9,$o),qb(10,ti),qb(11,le)],Bw);sht=0,yfe=class{constructor(e,t,i,o,r,s){this.model=e,this.viewModel=t,this.view=i,this.hasRealView=o,this.listenersToRemove=r,this.attachedView=s}dispose(){Yt(this.listenersToRemove),this.model.onBeforeDetached(this.attachedView),this.hasRealView&&this.view.dispose(),this.viewModel.dispose()}},Y$=class extends D{constructor(e){super(),this._emitterOptions=e,this._onDidChangeToTrue=this._register(new A(this._emitterOptions)),this.onDidChangeToTrue=this._onDidChangeToTrue.event,this._onDidChangeToFalse=this._register(new A(this._emitterOptions)),this.onDidChangeToFalse=this._onDidChangeToFalse.event,this._value=0}setValue(e){let t=e?2:1;this._value!==t&&(this._value=t,this._value===2?this._onDidChangeToTrue.fire():this._value===1&&this._onDidChangeToFalse.fire())}},Da=class extends A{constructor(e,t){super({deliveryQueue:t}),this._contributions=e}fire(e){this._contributions.onBeforeInteractionEvent(),super.fire(e)}},Cfe=class extends D{constructor(e,t){super(),this._editor=e,t.createKey("editorId",e.getId()),this._editorSimpleInput=T.editorSimpleInput.bindTo(t),this._editorFocus=T.focus.bindTo(t),this._textInputFocus=T.textInputFocus.bindTo(t),this._editorTextFocus=T.editorTextFocus.bindTo(t),this._tabMovesFocus=T.tabMovesFocus.bindTo(t),this._editorReadonly=T.readOnly.bindTo(t),this._inDiffEditor=T.inDiffEditor.bindTo(t),this._editorColumnSelection=T.columnSelection.bindTo(t),this._hasMultipleSelections=T.hasMultipleSelections.bindTo(t),this._hasNonEmptySelection=T.hasNonEmptySelection.bindTo(t),this._canUndo=T.canUndo.bindTo(t),this._canRedo=T.canRedo.bindTo(t),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._register(Bb.onDidChangeTabFocus(i=>this._tabMovesFocus.set(i))),this._updateFromConfig(),this._updateFromSelection(),this._updateFromFocus(),this._updateFromModel(),this._editorSimpleInput.set(this._editor.isSimpleWidget)}_updateFromConfig(){let e=this._editor.getOptions();this._tabMovesFocus.set(Bb.getTabFocusMode()),this._editorReadonly.set(e.get(92)),this._inDiffEditor.set(e.get(61)),this._editorColumnSelection.set(e.get(22))}_updateFromSelection(){let e=this._editor.getSelections();e?(this._hasMultipleSelections.set(e.length>1),this._hasNonEmptySelection.set(e.some(t=>!t.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(){let e=this._editor.getModel();this._canUndo.set(!!(e&&e.canUndo())),this._canRedo.set(!!(e&&e.canRedo()))}},Sfe=class extends D{constructor(e,t,i){super(),this._editor=e,this._contextKeyService=t,this._languageFeaturesService=i,this._langId=T.languageId.bindTo(t),this._hasCompletionItemProvider=T.hasCompletionItemProvider.bindTo(t),this._hasCodeActionsProvider=T.hasCodeActionsProvider.bindTo(t),this._hasCodeLensProvider=T.hasCodeLensProvider.bindTo(t),this._hasDefinitionProvider=T.hasDefinitionProvider.bindTo(t),this._hasDeclarationProvider=T.hasDeclarationProvider.bindTo(t),this._hasImplementationProvider=T.hasImplementationProvider.bindTo(t),this._hasTypeDefinitionProvider=T.hasTypeDefinitionProvider.bindTo(t),this._hasHoverProvider=T.hasHoverProvider.bindTo(t),this._hasDocumentHighlightProvider=T.hasDocumentHighlightProvider.bindTo(t),this._hasDocumentSymbolProvider=T.hasDocumentSymbolProvider.bindTo(t),this._hasReferenceProvider=T.hasReferenceProvider.bindTo(t),this._hasRenameProvider=T.hasRenameProvider.bindTo(t),this._hasSignatureHelpProvider=T.hasSignatureHelpProvider.bindTo(t),this._hasInlayHintsProvider=T.hasInlayHintsProvider.bindTo(t),this._hasDocumentFormattingProvider=T.hasDocumentFormattingProvider.bindTo(t),this._hasDocumentSelectionFormattingProvider=T.hasDocumentSelectionFormattingProvider.bindTo(t),this._hasMultipleDocumentFormattingProvider=T.hasMultipleDocumentFormattingProvider.bindTo(t),this._hasMultipleDocumentSelectionFormattingProvider=T.hasMultipleDocumentSelectionFormattingProvider.bindTo(t),this._isInEmbeddedEditor=T.isInEmbeddedEditor.bindTo(t);let o=()=>this._update();this._register(e.onDidChangeModel(o)),this._register(e.onDidChangeModelLanguage(o)),this._register(i.completionProvider.onDidChange(o)),this._register(i.codeActionProvider.onDidChange(o)),this._register(i.codeLensProvider.onDidChange(o)),this._register(i.definitionProvider.onDidChange(o)),this._register(i.declarationProvider.onDidChange(o)),this._register(i.implementationProvider.onDidChange(o)),this._register(i.typeDefinitionProvider.onDidChange(o)),this._register(i.hoverProvider.onDidChange(o)),this._register(i.documentHighlightProvider.onDidChange(o)),this._register(i.documentSymbolProvider.onDidChange(o)),this._register(i.referenceProvider.onDidChange(o)),this._register(i.renameProvider.onDidChange(o)),this._register(i.documentFormattingEditProvider.onDidChange(o)),this._register(i.documentRangeFormattingEditProvider.onDidChange(o)),this._register(i.signatureHelpProvider.onDidChange(o)),this._register(i.inlayHintsProvider.onDidChange(o)),o()}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._isInEmbeddedEditor.reset()})}_update(){let 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._isInEmbeddedEditor.set(e.uri.scheme===rt.walkThroughSnippet||e.uri.scheme===rt.vscodeChatCodeBlock)})}},kfe=class extends D{constructor(e,t){super(),this._onChange=this._register(new A),this.onChange=this._onChange.event,this._hadFocus=void 0,this._hasDomElementFocus=!1,this._domFocusTracker=this._register(ba(e)),this._overflowWidgetsDomNodeHasFocus=!1,this._register(this._domFocusTracker.onDidFocus(()=>{this._hasDomElementFocus=!0,this._update()})),this._register(this._domFocusTracker.onDidBlur(()=>{this._hasDomElementFocus=!1,this._update()})),t&&(this._overflowWidgetsDomNode=this._register(ba(t)),this._register(this._overflowWidgetsDomNode.onDidFocus(()=>{this._overflowWidgetsDomNodeHasFocus=!0,this._update()})),this._register(this._overflowWidgetsDomNode.onDidBlur(()=>{this._overflowWidgetsDomNodeHasFocus=!1,this._update()})))}_update(){let e=this._hasDomElementFocus||this._overflowWidgetsDomNodeHasFocus;this._hadFocus!==e&&(this._hadFocus=e,this._onChange.fire(void 0))}hasFocus(){return this._hadFocus??!1}},Lfe=class{get length(){return this._decorationIds.length}constructor(e,t){this._editor=e,this._decorationIds=[],this._isChangingDecorations=!1,Array.isArray(t)&&t.length>0&&this.set(t)}onDidChange(e,t,i){return this._editor.onDidChangeModelDecorations(o=>{this._isChangingDecorations||e.call(t,o)},i)}getRange(e){return!this._editor.hasModel()||e>=this._decorationIds.length?null:this._editor.getModel().getDecorationRange(this._decorationIds[e])}getRanges(){if(!this._editor.hasModel())return[];let e=this._editor.getModel(),t=[];for(let i of this._decorationIds){let o=e.getDecorationRange(i);o&&t.push(o)}return t}has(e){return this._decorationIds.includes(e.id)}clear(){this._decorationIds.length!==0&&this.set([])}set(e){try{this._isChangingDecorations=!0,this._editor.changeDecorations(t=>{this._decorationIds=t.deltaDecorations(this._decorationIds,e)})}finally{this._isChangingDecorations=!1}return this._decorationIds}append(e){let t=[];try{this._isChangingDecorations=!0,this._editor.changeDecorations(i=>{t=i.deltaDecorations([],e),this._decorationIds=this._decorationIds.concat(t)})}finally{this._isChangingDecorations=!1}return t}},aht=encodeURIComponent("");cht=encodeURIComponent('');wr((n,e)=>{let t=n.getColor(aC);t&&e.addRule(`.monaco-editor .squiggly-error { background: url("data:image/svg+xml,${wfe(t)}") repeat-x bottom left; }`);let i=n.getColor(Lu);i&&e.addRule(`.monaco-editor .squiggly-warning { background: url("data:image/svg+xml,${wfe(i)}") repeat-x bottom left; }`);let o=n.getColor(jc);o&&e.addRule(`.monaco-editor .squiggly-info { background: url("data:image/svg+xml,${wfe(o)}") repeat-x bottom left; }`);let r=n.getColor(rAe);r&&e.addRule(`.monaco-editor .squiggly-hint { background: url("data:image/svg+xml,${uht(r)}") no-repeat bottom left; }`);let s=n.getColor(HOe);s&&e.addRule(`.monaco-editor.showUnused .squiggly-inline-unnecessary { opacity: ${s.rgba.a}; }`)})});var U8e=k(()=>{});var od,L0=k(()=>{od=class n{static capture(e){if(e.getScrollTop()===0||e.hasPendingScrollAnimation())return new n(e.getScrollTop(),e.getContentHeight(),null,0,null);let t=null,i=0,o=e.getVisibleRanges();if(o.length>0){t=o[0].getStartPosition();let r=e.getTopForPosition(t.lineNumber,t.column);i=e.getScrollTop()-r}return new n(e.getScrollTop(),e.getContentHeight(),t,i,e.getPosition())}constructor(e,t,i,o,r){this._initialScrollTop=e,this._initialContentHeight=t,this._visiblePosition=i,this._visiblePositionScrollDelta=o,this._cursorPosition=r}restore(e){if(!(this._initialContentHeight===e.getContentHeight()&&this._initialScrollTop===e.getScrollTop())&&this._visiblePosition){let t=e.getTopForPosition(this._visiblePosition.lineNumber,this._visiblePosition.column);e.setScrollTop(t+this._visiblePositionScrollDelta)}}restoreRelativeVerticalPositionOfCursor(e){if(this._initialContentHeight===e.getContentHeight()&&this._initialScrollTop===e.getScrollTop())return;let t=e.getPosition();if(!this._cursorPosition||!t)return;let i=e.getTopForLineNumber(t.lineNumber)-e.getTopForLineNumber(this._cursorPosition.lineNumber);e.setScrollTop(e.getScrollTop()+i,1)}}});function $8e(n,e,t,i){if(n.length===0)return e;if(e.length===0)return n;let o=[],r=0,s=0;for(;rd?(o.push(l),s++):(o.push(i(a,l)),r++,s++)}for(;r`Apply decorations from ${e.debugName}`},o=>{let r=e.read(o);i.set(r)})),t.add({dispose:()=>{i.clear()}}),t}function Kb(n,e){return n.appendChild(e),ge(()=>{e.remove()})}function j8e(n,e){return n.prepend(e),ge(()=>{e.remove()})}function Tfe(n,e,t){let i=e.get(),o=i,r=i,s=lt("animatedValue",i),a=-1,l=300,c;t.add(gb({createEmptyChangeSummary:()=>({animate:!1}),handleChange:(u,h)=>(u.didChange(e)&&(h.animate=h.animate||u.change),!0)},(u,h)=>{c!==void 0&&(n.cancelAnimationFrame(c),c=void 0),o=r,i=e.read(u),a=Date.now()-(h.animate?0:l),d()}));function d(){let u=Date.now()-a;r=Math.floor(hht(u,o,i-o,l)),u{for(let[i,o]of Object.entries(e))o&&typeof o=="object"&&"read"in o&&(o=o.read(t)),typeof o=="number"&&(o=`${o}px`),i=i.replace(/[A-Z]/g,r=>"-"+r.toLowerCase()),n.style[i]=o})}function ZE(n,e,t,i){let o=new H,r=[];return o.add(To((s,a)=>{let l=e.read(s),c=new Map,d=new Map;t&&t(!0),n.changeViewZones(u=>{for(let h of r)u.removeZone(h),i?.delete(h);r.length=0;for(let h of l){let f=u.addZone(h);h.setZoneId&&h.setZoneId(f),r.push(f),i?.add(f),c.set(h,f)}}),t&&t(!1),a.add(gb({createEmptyChangeSummary(){return{zoneIds:[]}},handleChange(u,h){let f=d.get(u.changedObservable);return f!==void 0&&h.zoneIds.push(f),!0}},(u,h)=>{for(let f of l)f.onChange&&(d.set(f.onChange,c.get(f)),f.onChange.read(u));t&&t(!0),n.changeViewZones(f=>{for(let p of h.zoneIds)f.layoutZone(p)}),t&&t(!1)}))})),o.add({dispose(){t&&t(!0),n.changeViewZones(s=>{for(let a of r)s.removeZone(a)}),i?.clear(),t&&t(!1)}}),o}function Dfe(n,e){let t=eb(e,o=>o.original.startLineNumber<=n.lineNumber);if(!t)return S.fromPositions(n);if(t.original.endLineNumberExclusive<=n.lineNumber){let o=n.lineNumber-t.original.endLineNumberExclusive+t.modified.endLineNumberExclusive;return S.fromPositions(new P(o,n.column))}if(!t.innerChanges)return S.fromPositions(new P(t.modified.startLineNumber,1));let i=eb(t.innerChanges,o=>o.originalRange.getStartPosition().isBeforeOrEqual(n));if(!i){let o=n.lineNumber-t.original.startLineNumber+t.modified.startLineNumber;return S.fromPositions(new P(o,n.column))}if(i.originalRange.containsPosition(n))return i.modifiedRange;{let o=fht(i.originalRange.getEndPosition(),n);return S.fromPositions(o.addToPosition(i.modifiedRange.getEndPosition()))}}function fht(n,e){return n.lineNumber===e.lineNumber?new xa(0,e.column-n.column):new xa(e.lineNumber-n.lineNumber,e.column-1)}function q8e(n,e){let t;return n.filter(i=>{let o=e(i,t);return t=i,o})}var GE,I0,Vg,Ife,Z$,E0,X$,Efe,zh=k(()=>{Ad();ci();j();Oi();Vue();qe();we();ib();GE=class extends D{get width(){return this._width}get height(){return this._height}get automaticLayout(){return this._automaticLayout}constructor(e,t){super(),this._automaticLayout=!1,this.elementSizeObserver=this._register(new bE(e,t)),this._width=lt(this,this.elementSizeObserver.getWidth()),this._height=lt(this,this.elementSizeObserver.getHeight()),this._register(this.elementSizeObserver.onDidChange(i=>xi(o=>{this._width.set(this.elementSizeObserver.getWidth(),o),this._height.set(this.elementSizeObserver.getHeight(),o)})))}observe(e){this.elementSizeObserver.observe(e)}setAutomaticLayout(e){this._automaticLayout=e,e?this.elementSizeObserver.startObserving():this.elementSizeObserver.stopObserving()}};I0=class extends D{constructor(e,t,i){super(),this._register(new Ife(e,i)),this._register(Gd(i,{height:t.actualHeight,top:t.actualTop}))}},Vg=class{get afterLineNumber(){return this._afterLineNumber.get()}constructor(e,t){this._afterLineNumber=e,this.heightInPx=t,this.domNode=document.createElement("div"),this._actualTop=lt(this,void 0),this._actualHeight=lt(this,void 0),this.actualTop=this._actualTop,this.actualHeight=this._actualHeight,this.showInHiddenAreas=!0,this.onChange=this._afterLineNumber,this.onDomNodeTop=i=>{this._actualTop.set(i,void 0)},this.onComputedHeight=i=>{this._actualHeight.set(i,void 0)}}},Ife=class n{static{this._counter=0}constructor(e,t){this._editor=e,this._domElement=t,this._overlayWidgetId=`managedOverlayWidget-${n._counter++}`,this._overlayWidget={getId:()=>this._overlayWidgetId,getDomNode:()=>this._domElement,getPosition:()=>null},this._editor.addOverlayWidget(this._overlayWidget)}dispose(){this._editor.removeOverlayWidget(this._overlayWidget)}};Z$=class extends qt{dispose(){super.dispose(!0)}};E0=class{static create(e,t=void 0){return new X$(e,e,t)}static createWithDisposable(e,t,i=void 0){let o=new H;return o.add(t),o.add(e),new X$(e,o,i)}},X$=class extends E0{constructor(e,t,i){super(),this.object=e,this._disposable=t,this._debugOwner=i,this._refCount=1,this._isDisposed=!1,this._owners=[],i&&this._addOwner(i)}_addOwner(e){e&&this._owners.push(e)}createNewRef(e){return this._refCount++,e&&this._addOwner(e),new Efe(this,e)}dispose(){this._isDisposed||(this._isDisposed=!0,this._decreaseRefCount(this._debugOwner))}_decreaseRefCount(e){if(this._refCount--,this._refCount===0&&this._disposable.dispose(),e){let t=this._owners.indexOf(e);t!==-1&&this._owners.splice(t,1)}}},Efe=class extends E0{constructor(e,t){super(),this._base=e,this._debugOwner=t,this._isDisposed=!1}get object(){return this._base.object}createNewRef(e){return this._base.createNewRef(e)}dispose(){this._isDisposed||(this._isDisposed=!0,this._base._decreaseRefCount(this._debugOwner))}}});var K8e=k(()=>{});function _ht(n,e,t){let i=[];for(let o of Bk(n,(r,s)=>s.modified.startLineNumber-r.modified.endLineNumberExclusive<2*SP)){let r=[];r.push(new Afe);let s=new ut(Math.max(1,o[0].original.startLineNumber-SP),Math.min(o[o.length-1].original.endLineNumberExclusive+SP,e+1)),a=new ut(Math.max(1,o[0].modified.startLineNumber-SP),Math.min(o[o.length-1].modified.endLineNumberExclusive+SP,t+1));I3(o,(d,u)=>{let h=new ut(d?d.original.endLineNumberExclusive:s.startLineNumber,u?u.original.startLineNumber:s.endLineNumberExclusive),f=new ut(d?d.modified.endLineNumberExclusive:a.startLineNumber,u?u.modified.startLineNumber:a.endLineNumberExclusive);h.forEach(p=>{r.push(new Ofe(p,f.startLineNumber+(p-h.startLineNumber)))}),u&&(u.original.forEach(p=>{r.push(new Mfe(u,p))}),u.modified.forEach(p=>{r.push(new Pfe(u,p))}))});let l=o[0].modified.join(o[o.length-1].modified),c=o[0].original.join(o[o.length-1].original);i.push(new Rfe(new ya(l,c),r))}return i}var Bfe,Wfe,pht,mht,ght,Ww,Nfe,SP,bc,Rfe,Afe,Mfe,Pfe,Ofe,Ffe,Q$,G8e=k(()=>{ke();Rm();Oh();Eh();Gr();at();Qi();j();Oi();bn();bu();zh();ir();Nl();Rd();qe();we();Bm();fs();Dh();Tw();Af();pe();Lw();Fe();$d();K8e();Bfe=function(n,e,t,i){var o=arguments.length,r=o<3?e:i===null?i=Object.getOwnPropertyDescriptor(e,t):i,s;if(typeof Reflect=="object"&&typeof Reflect.decorate=="function")r=Reflect.decorate(n,e,t,i);else for(var a=n.length-1;a>=0;a--)(s=n[a])&&(r=(o<3?s(r):o>3?s(e,t,r):s(e,t))||r);return o>3&&r&&Object.defineProperty(e,t,r),r},Wfe=function(n,e){return function(t,i){e(t,i,n)}},pht=Fi("diff-review-insert",oe.add,m("accessibleDiffViewerInsertIcon","Icon for 'Insert' in accessible diff viewer.")),mht=Fi("diff-review-remove",oe.remove,m("accessibleDiffViewerRemoveIcon","Icon for 'Remove' in accessible diff viewer.")),ght=Fi("diff-review-close",oe.close,m("accessibleDiffViewerCloseIcon","Icon for 'Close' in accessible diff viewer.")),Ww=class extends D{static{this._ttPolicy=Tl("diffReview",{createHTML:e=>e})}constructor(e,t,i,o,r,s,a,l,c){super(),this._parentNode=e,this._visible=t,this._setVisible=i,this._canClose=o,this._width=r,this._height=s,this._diffs=a,this._models=l,this._instantiationService=c,this._state=hc(this,(d,u)=>{let h=this._visible.read(d);if(this._parentNode.style.visibility=h?"visible":"hidden",!h)return null;let f=u.add(this._instantiationService.createInstance(Nfe,this._diffs,this._models,this._setVisible,this._canClose)),p=u.add(this._instantiationService.createInstance(Ffe,this._parentNode,f,this._width,this._height,this._models));return{model:f,view:p}}).recomputeInitiallyAndOnChange(this._store)}next(){xi(e=>{let t=this._visible.get();this._setVisible(!0,e),t&&this._state.get().model.nextGroup(e)})}prev(){xi(e=>{this._setVisible(!0,e),this._state.get().model.previousGroup(e)})}close(){xi(e=>{this._setVisible(!1,e)})}};Ww=Bfe([Wfe(8,he)],Ww);Nfe=class extends D{constructor(e,t,i,o,r){super(),this._diffs=e,this._models=t,this._setVisible=i,this.canClose=o,this._accessibilitySignalService=r,this._groups=lt(this,[]),this._currentGroupIdx=lt(this,0),this._currentElementIdx=lt(this,0),this.groups=this._groups,this.currentGroup=this._currentGroupIdx.map((s,a)=>this._groups.read(a)[s]),this.currentGroupIndex=this._currentGroupIdx,this.currentElement=this._currentElementIdx.map((s,a)=>this.currentGroup.read(a)?.lines[s]),this._register(He(s=>{let a=this._diffs.read(s);if(!a){this._groups.set([],void 0);return}let l=_ht(a,this._models.getOriginalModel().getLineCount(),this._models.getModifiedModel().getLineCount());xi(c=>{let d=this._models.getModifiedPosition();if(d){let u=l.findIndex(h=>d?.lineNumber{let a=this.currentElement.read(s);a?.type===bc.Deleted?this._accessibilitySignalService.playSignal(sl.diffLineDeleted,{source:"accessibleDiffViewer.currentElementChanged"}):a?.type===bc.Added&&this._accessibilitySignalService.playSignal(sl.diffLineInserted,{source:"accessibleDiffViewer.currentElementChanged"})})),this._register(He(s=>{let a=this.currentElement.read(s);if(a&&a.type!==bc.Header){let l=a.modifiedLineNumber??a.diff.modified.startLineNumber;this._models.modifiedSetSelection(S.fromPositions(new P(l,1)))}}))}_goToGroupDelta(e,t){let i=this.groups.get();!i||i.length<=1||Nh(t,o=>{this._currentGroupIdx.set(Wt.ofLength(i.length).clipCyclic(this._currentGroupIdx.get()+e),o),this._currentElementIdx.set(0,o)})}nextGroup(e){this._goToGroupDelta(1,e)}previousGroup(e){this._goToGroupDelta(-1,e)}_goToLineDelta(e){let t=this.currentGroup.get();!t||t.lines.length<=1||xi(i=>{this._currentElementIdx.set(Wt.ofLength(t.lines.length).clip(this._currentElementIdx.get()+e),i)})}goToNextLine(){this._goToLineDelta(1)}goToPreviousLine(){this._goToLineDelta(-1)}goToLine(e){let t=this.currentGroup.get();if(!t)return;let i=t.lines.indexOf(e);i!==-1&&xi(o=>{this._currentElementIdx.set(i,o)})}revealCurrentElementInEditor(){if(!this.canClose.get())return;this._setVisible(!1,void 0);let e=this.currentElement.get();e&&(e.type===bc.Deleted?this._models.originalReveal(S.fromPositions(new P(e.originalLineNumber,1))):this._models.modifiedReveal(e.type!==bc.Header?S.fromPositions(new P(e.modifiedLineNumber,1)):void 0))}close(){this.canClose.get()&&(this._setVisible(!1,void 0),this._models.modifiedFocus())}};Nfe=Bfe([Wfe(4,jd)],Nfe);SP=3;(function(n){n[n.Header=0]="Header",n[n.Unchanged=1]="Unchanged",n[n.Deleted=2]="Deleted",n[n.Added=3]="Added"})(bc||(bc={}));Rfe=class{constructor(e,t){this.range=e,this.lines=t}},Afe=class{constructor(){this.type=bc.Header}},Mfe=class{constructor(e,t){this.diff=e,this.originalLineNumber=t,this.type=bc.Deleted,this.modifiedLineNumber=void 0}},Pfe=class{constructor(e,t){this.diff=e,this.modifiedLineNumber=t,this.type=bc.Added,this.originalLineNumber=void 0}},Ofe=class{constructor(e,t){this.originalLineNumber=e,this.modifiedLineNumber=t,this.type=bc.Unchanged}},Ffe=class extends D{constructor(e,t,i,o,r,s){super(),this._element=e,this._model=t,this._width=i,this._height=o,this._models=r,this._languageService=s,this.domNode=this._element,this.domNode.className="monaco-component diff-review monaco-editor-background";let a=document.createElement("div");a.className="diff-review-actions",this._actionBar=this._register(new Zo(a)),this._register(He(l=>{this._actionBar.clear(),this._model.canClose.read(l)&&this._actionBar.push(new rr("diffreview.close",m("label.close","Close"),"close-diff-review "+Oe.asClassName(ght),!0,async()=>t.close()),{label:!1,icon:!0})})),this._content=document.createElement("div"),this._content.className="diff-review-content",this._content.setAttribute("role","code"),this._scrollbar=this._register(new Cf(this._content,{})),oo(this.domNode,this._scrollbar.getDomNode(),a),this._register(He(l=>{this._height.read(l),this._width.read(l),this._scrollbar.scanDomNode()})),this._register(ge(()=>{oo(this.domNode)})),this._register(Gd(this.domNode,{width:this._width,height:this._height})),this._register(Gd(this._content,{width:this._width,height:this._height})),this._register(To((l,c)=>{this._model.currentGroup.read(l),this._render(c)})),this._register(gi(this.domNode,"keydown",l=>{(l.equals(18)||l.equals(2066)||l.equals(530))&&(l.preventDefault(),this._model.goToNextLine()),(l.equals(16)||l.equals(2064)||l.equals(528))&&(l.preventDefault(),this._model.goToPreviousLine()),(l.equals(9)||l.equals(2057)||l.equals(521)||l.equals(1033))&&(l.preventDefault(),this._model.close()),(l.equals(10)||l.equals(3))&&(l.preventDefault(),this._model.revealCurrentElementInEditor())}))}_render(e){let t=this._models.getOriginalOptions(),i=this._models.getModifiedOptions(),o=document.createElement("div");o.className="diff-review-table",o.setAttribute("role","list"),o.setAttribute("aria-label",m("ariaLabel","Accessible Diff Viewer. Use arrow up and down to navigate.")),Kn(o,i.get(50)),oo(this._content,o);let r=this._models.getOriginalModel(),s=this._models.getModifiedModel();if(!r||!s)return;let a=r.getOptions(),l=s.getOptions(),c=i.get(67),d=this._model.currentGroup.get();for(let u of d?.lines||[]){if(!d)break;let h;if(u.type===bc.Header){let p=document.createElement("div");p.className="diff-review-row",p.setAttribute("role","listitem");let g=d.range,_=this._model.currentGroupIndex.get(),b=this._model.groups.get().length,v=C=>C===0?m("no_lines_changed","no lines changed"):C===1?m("one_line_changed","1 line changed"):m("more_lines_changed","{0} lines changed",C),x=v(g.original.length),w=v(g.modified.length);p.setAttribute("aria-label",m({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}",_+1,b,g.original.startLineNumber,x,g.modified.startLineNumber,w));let y=document.createElement("div");y.className="diff-review-cell diff-review-summary",y.appendChild(document.createTextNode(`${_+1}/${b}: @@ -${g.original.startLineNumber},${g.original.length} +${g.modified.startLineNumber},${g.modified.length} @@`)),p.appendChild(y),h=p}else h=this._createRow(u,c,this._width.get(),t,r,a,i,s,l);o.appendChild(h);let f=Pe(p=>this._model.currentElement.read(p)===u);e.add(He(p=>{let g=f.read(p);h.tabIndex=g?0:-1,g&&h.focus()})),e.add(U(h,"focus",()=>{this._model.goToLine(u)}))}this._scrollbar.scanDomNode()}_createRow(e,t,i,o,r,s,a,l,c){let d=o.get(146),u=d.glyphMarginWidth+d.lineNumbersWidth,h=a.get(146),f=10+h.glyphMarginWidth+h.lineNumbersWidth,p="diff-review-row",g="",_="diff-review-spacer",b=null;switch(e.type){case bc.Added:p="diff-review-row line-insert",g=" char-insert",b=pht;break;case bc.Deleted:p="diff-review-row line-delete",g=" char-delete",b=mht;break}let v=document.createElement("div");v.style.minWidth=i+"px",v.className=p,v.setAttribute("role","listitem"),v.ariaLevel="";let x=document.createElement("div");x.className="diff-review-cell",x.style.height=`${t}px`,v.appendChild(x);let w=document.createElement("span");w.style.width=u+"px",w.style.minWidth=u+"px",w.className="diff-review-line-number"+g,e.originalLineNumber!==void 0?w.appendChild(document.createTextNode(String(e.originalLineNumber))):w.innerText="\xA0",x.appendChild(w);let y=document.createElement("span");y.style.width=f+"px",y.style.minWidth=f+"px",y.style.paddingRight="10px",y.className="diff-review-line-number"+g,e.modifiedLineNumber!==void 0?y.appendChild(document.createTextNode(String(e.modifiedLineNumber))):y.innerText="\xA0",x.appendChild(y);let C=document.createElement("span");if(C.className=_,b){let N=document.createElement("span");N.className=Oe.asClassName(b),N.innerText="\xA0\xA0",C.appendChild(N)}else C.innerText="\xA0\xA0";x.appendChild(C);let L;if(e.modifiedLineNumber!==void 0){let N=this._getLineHtml(l,a,c.tabSize,e.modifiedLineNumber,this._languageService.languageIdCodec);Ww._ttPolicy&&(N=Ww._ttPolicy.createHTML(N)),x.insertAdjacentHTML("beforeend",N),L=l.getLineContent(e.modifiedLineNumber)}else{let N=this._getLineHtml(r,o,s.tabSize,e.originalLineNumber,this._languageService.languageIdCodec);Ww._ttPolicy&&(N=Ww._ttPolicy.createHTML(N)),x.insertAdjacentHTML("beforeend",N),L=r.getLineContent(e.originalLineNumber)}L.length===0&&(L=m("blankLine","blank"));let E="";switch(e.type){case bc.Unchanged:e.originalLineNumber===e.modifiedLineNumber?E=m({key:"unchangedLine",comment:["The placeholders are contents of the line and should not be translated."]},"{0} unchanged line {1}",L,e.originalLineNumber):E=m("equalLine","{0} original line {1} modified line {2}",L,e.originalLineNumber,e.modifiedLineNumber);break;case bc.Added:E=m("insertLine","+ {0} modified line {1}",L,e.modifiedLineNumber);break;case bc.Deleted:E=m("deleteLine","- {0} original line {1}",L,e.originalLineNumber);break}return v.setAttribute("aria-label",E),v}_getLineHtml(e,t,i,o,r){let s=e.getLineContent(o),a=t.get(50),l=ao.createEmpty(s,r),c=_c.isBasicASCII(s,e.mightContainNonBasicASCII()),d=_c.containsRTL(s,c,e.mightContainRTL());return fE(new id(a.isMonospace&&!t.get(33),a.canUseHalfwidthRightwardsArrow,s,!1,c,d,0,l,[],i,0,a.spaceWidth,a.middotWidth,a.wsmiddotWidth,t.get(118),t.get(100),t.get(95),t.get(51)!==ah.OFF,null)).html}};Ffe=Bfe([Wfe(5,ai)],Ffe);Q$=class{constructor(e){this.editors=e}getOriginalModel(){return this.editors.original.getModel()}getOriginalOptions(){return this.editors.original.getOptions()}originalReveal(e){this.editors.original.revealRange(e),this.editors.original.setSelection(e),this.editors.original.focus()}getModifiedModel(){return this.editors.modified.getModel()}getModifiedOptions(){return this.editors.modified.getOptions()}modifiedReveal(e){e&&(this.editors.modified.revealRange(e),this.editors.modified.setSelection(e)),this.editors.modified.focus()}modifiedSetSelection(e){this.editors.modified.setSelection(e)}modifiedFocus(){this.editors.modified.focus()}getModifiedPosition(){return this.editors.modified.getPosition()??void 0}}});var vTi,xTi,wTi,bht,Hfe,T0,Gb,zfe,Vfe,D0,XE,QE,Wp,JE,eT,Hw=k(()=>{Qi();bn();Ho();pe();Wn();$d();vTi=R("diffEditor.move.border","#8b8b8b9c",m("diffEditor.move.border","The border color for text that got moved in the diff editor.")),xTi=R("diffEditor.moveActive.border","#FFA500",m("diffEditor.moveActive.border","The active border color for text that got moved in the diff editor.")),wTi=R("diffEditor.unchangedRegionShadow",{dark:"#000000",light:"#737373BF",hcDark:"#000000",hcLight:"#737373BF"},m("diffEditor.unchangedRegionShadow","The color of the shadow around unchanged region widgets.")),bht=Fi("diff-insert",oe.add,m("diffInsertIcon","Line decoration for inserts in the diff editor.")),Hfe=Fi("diff-remove",oe.remove,m("diffRemoveIcon","Line decoration for removals in the diff editor.")),T0=tt.register({className:"line-insert",description:"line-insert",isWholeLine:!0,linesDecorationsClassName:"insert-sign "+Oe.asClassName(bht),marginClassName:"gutter-insert"}),Gb=tt.register({className:"line-delete",description:"line-delete",isWholeLine:!0,linesDecorationsClassName:"delete-sign "+Oe.asClassName(Hfe),marginClassName:"gutter-delete"}),zfe=tt.register({className:"line-insert",description:"line-insert",isWholeLine:!0,marginClassName:"gutter-insert"}),Vfe=tt.register({className:"line-delete",description:"line-delete",isWholeLine:!0,marginClassName:"gutter-delete"}),D0=tt.register({className:"char-insert",description:"char-insert",shouldFillLineOnLineBreak:!0}),XE=tt.register({className:"char-insert",description:"char-insert",isWholeLine:!0}),QE=tt.register({className:"char-insert diff-range-empty",description:"char-insert diff-range-empty"}),Wp=tt.register({className:"char-delete",description:"char-delete",shouldFillLineOnLineBreak:!0}),JE=tt.register({className:"char-delete",description:"char-delete",isWholeLine:!0}),eT=tt.register({className:"char-delete diff-range-empty",description:"char-delete diff-range-empty"})});var Y8e,Ufe,N0,Yb,$fe,jfe,kP=k(()=>{Xs();Fe();Ie();kl();Nl();Bm();Ip();sc();Y8e=function(n,e,t,i){var o=arguments.length,r=o<3?e:i===null?i=Object.getOwnPropertyDescriptor(e,t):i,s;if(typeof Reflect=="object"&&typeof Reflect.decorate=="function")r=Reflect.decorate(n,e,t,i);else for(var a=n.length-1;a>=0;a--)(s=n[a])&&(r=(o<3?s(r):o>3?s(e,t,r):s(e,t))||r);return o>3&&r&&Object.defineProperty(e,t,r),r},Ufe=function(n,e){return function(t,i){e(t,i,n)}},Yb=We("diffProviderFactoryService"),$fe=class{constructor(e){this.instantiationService=e}createDiffProvider(e){return this.instantiationService.createInstance(jfe,e)}};$fe=Y8e([Ufe(0,he)],$fe);Ct(Yb,$fe,1);jfe=class{static{N0=this}static{this.diffCache=new Map}constructor(e,t,i){this.editorWorkerService=t,this.telemetryService=i,this.onDidChangeEventEmitter=new A,this.onDidChange=this.onDidChangeEventEmitter.event,this.diffAlgorithm="advanced",this.diffAlgorithmOnDidChangeSubscription=void 0,this.setOptions(e)}dispose(){this.diffAlgorithmOnDidChangeSubscription?.dispose()}async computeDiff(e,t,i,o){if(typeof this.diffAlgorithm!="string")return this.diffAlgorithm.computeDiff(e,t,i,o);if(e.isDisposed()||t.isDisposed())return{changes:[],identical:!0,quitEarly:!1,moves:[]};if(e.getLineCount()===1&&e.getLineMaxColumn(1)===1)return t.getLineCount()===1&&t.getLineMaxColumn(1)===1?{changes:[],identical:!0,quitEarly:!1,moves:[]}:{changes:[new Rl(new ut(1,2),new ut(1,t.getLineCount()+1),[new wa(e.getFullModelRange(),t.getFullModelRange())])],identical:!1,quitEarly:!1,moves:[]};let r=JSON.stringify([e.uri.toString(),t.uri.toString()]),s=JSON.stringify([e.id,t.id,e.getAlternativeVersionId(),t.getAlternativeVersionId(),JSON.stringify(i)]),a=N0.diffCache.get(r);if(a&&a.context===s)return a.result;let l=cn.create(),c=await this.editorWorkerService.computeDiff(e.uri,t.uri,i,this.diffAlgorithm),d=l.elapsed();if(this.telemetryService.publicLog2("diffEditor.computeDiff",{timeMs:d,timedOut:c?.quitEarly??!0,detectedMoves:i.computeMoves?c?.moves.length??0:-1}),o.isCancellationRequested)return{changes:[],identical:!1,quitEarly:!0,moves:[]};if(!c)throw new Error("no diff result available");return N0.diffCache.size>10&&N0.diffCache.delete(N0.diffCache.keys().next().value),N0.diffCache.set(r,{result:c,context:s}),c}setOptions(e){let t=!1;e.diffAlgorithm&&this.diffAlgorithm!==e.diffAlgorithm&&(this.diffAlgorithmOnDidChangeSubscription?.dispose(),this.diffAlgorithmOnDidChangeSubscription=void 0,this.diffAlgorithm=e.diffAlgorithm,typeof e.diffAlgorithm!="string"&&(this.diffAlgorithmOnDidChangeSubscription=e.diffAlgorithm.onDidChange(()=>this.onDidChangeEventEmitter.fire())),t=!0),t&&this.onDidChangeEventEmitter.fire()}};jfe=N0=Y8e([Ufe(1,kr),Ufe(2,Fn)],jfe)});function tT(){return WR&&!!WR.VSCODE_DEV}function qfe(n){if(tT()){let e=vht();return e.add(n),{dispose(){e.delete(n)}}}else return{dispose(){}}}function vht(){J$||(J$=new Set);let n=globalThis;return n.$hotReload_applyNewExports||(n.$hotReload_applyNewExports=e=>{let t={config:{mode:void 0},...e},i=[];for(let o of J$){let r=o(t);r&&i.push(r)}if(i.length>0)return o=>{let r=!1;for(let s of i)s(o)&&(r=!0);return r}}),J$}var J$,Kfe=k(()=>{wne();tT()&&qfe(({oldExports:n,newSrc:e,config:t})=>{if(t.mode==="patch-prototype")return i=>{for(let o in i){let r=i[o];if(console.log(`[hot-reload] Patching prototype methods of '${o}'`,{exportedItem:r}),typeof r=="function"&&r.prototype){let s=n[o];if(s){for(let a of Object.getOwnPropertyNames(r.prototype)){let l=Object.getOwnPropertyDescriptor(r.prototype,a),c=Object.getOwnPropertyDescriptor(s.prototype,a);l?.value?.toString()!==c?.value?.toString()&&console.log(`[hot-reload] Patching prototype method '${o}.${a}'`),Object.defineProperty(s.prototype,a,l)}i[o]=s}}}return!0}})});function Na(n,e){return xht([n],e),n}function xht(n,e){tT()&&Wo("reload",i=>qfe(({oldExports:o})=>{if([...Object.values(o)].some(r=>n.includes(r)))return r=>(i(void 0),!0)})).read(e)}var iT=k(()=>{Kfe();Oi()});function Cht(n,e,t){return{changes:n.changes.map(i=>new Rl(i.original,i.modified,i.innerChanges?i.innerChanges.map(o=>Sht(o,e,t)):void 0)),moves:n.moves,identical:n.identical,quitEarly:n.quitEarly}}function Sht(n,e,t){let i=n.originalRange,o=n.modifiedRange;return i.startColumn===1&&o.startColumn===1&&(i.endColumn!==1||o.endColumn!==1)&&i.endColumn===e.getLineMaxColumn(i.endLineNumber)&&o.endColumn===t.getLineMaxColumn(o.endLineNumber)&&i.endLineNumber{ft();ci();j();Oi();kP();zh();iT();Nl();Ere();Bm();GM();Ple();Ire();yi();at();bf();wht=function(n,e,t,i){var o=arguments.length,r=o<3?e:i===null?i=Object.getOwnPropertyDescriptor(e,t):i,s;if(typeof Reflect=="object"&&typeof Reflect.decorate=="function")r=Reflect.decorate(n,e,t,i);else for(var a=n.length-1;a>=0;a--)(s=n[a])&&(r=(o<3?s(r):o>3?s(e,t,r):s(e,t))||r);return o>3&&r&&Object.defineProperty(e,t,r),r},yht=function(n,e){return function(t,i){e(t,i,n)}},ej=class extends D{setActiveMovedText(e){this._activeMovedText.set(e,void 0)}constructor(e,t,i){super(),this.model=e,this._options=t,this._diffProviderFactoryService=i,this._isDiffUpToDate=lt(this,!1),this.isDiffUpToDate=this._isDiffUpToDate,this._diff=lt(this,void 0),this.diff=this._diff,this._unchangedRegions=lt(this,void 0),this.unchangedRegions=Pe(this,a=>this._options.hideUnchangedRegions.read(a)?this._unchangedRegions.read(a)?.regions??[]:(xi(l=>{for(let c of this._unchangedRegions.get()?.regions||[])c.collapseAll(l)}),[])),this.movedTextToCompare=lt(this,void 0),this._activeMovedText=lt(this,void 0),this._hoveredMovedText=lt(this,void 0),this.activeMovedText=Pe(this,a=>this.movedTextToCompare.read(a)??this._hoveredMovedText.read(a)??this._activeMovedText.read(a)),this._cancellationTokenSource=new qt,this._diffProvider=Pe(this,a=>{let l=this._diffProviderFactoryService.createDiffProvider({diffAlgorithm:this._options.diffAlgorithm.read(a)}),c=Wo("onDidChange",l.onDidChange);return{diffProvider:l,onChangeSignal:c}}),this._register(ge(()=>this._cancellationTokenSource.cancel()));let o=Rh("contentChangedSignal"),r=this._register(new Lt(()=>o.trigger(void 0),200));this._register(He(a=>{let l=this._unchangedRegions.read(a);if(!l||l.regions.some(p=>p.isDragged.read(a)))return;let c=l.originalDecorationIds.map(p=>e.original.getDecorationRange(p)).map(p=>p?ut.fromRangeInclusive(p):void 0),d=l.modifiedDecorationIds.map(p=>e.modified.getDecorationRange(p)).map(p=>p?ut.fromRangeInclusive(p):void 0),u=l.regions.map((p,g)=>!c[g]||!d[g]?void 0:new nT(c[g].startLineNumber,d[g].startLineNumber,c[g].length,p.visibleLineCountTop.read(a),p.visibleLineCountBottom.read(a))).filter(xd),h=[],f=!1;for(let p of Bk(u,(g,_)=>g.getHiddenModifiedRange(a).endLineNumberExclusive===_.getHiddenModifiedRange(a).startLineNumber))if(p.length>1){f=!0;let g=p.reduce((b,v)=>b+v.lineCount,0),_=new nT(p[0].originalLineNumber,p[0].modifiedLineNumber,g,p[0].visibleLineCountTop.get(),p[p.length-1].visibleLineCountBottom.get());h.push(_)}else h.push(p[0]);if(f){let p=e.original.deltaDecorations(l.originalDecorationIds,h.map(_=>({range:_.originalUnchangedRange.toInclusiveRange(),options:{description:"unchanged"}}))),g=e.modified.deltaDecorations(l.modifiedDecorationIds,h.map(_=>({range:_.modifiedUnchangedRange.toInclusiveRange(),options:{description:"unchanged"}})));xi(_=>{this._unchangedRegions.set({regions:h,originalDecorationIds:p,modifiedDecorationIds:g},_)})}}));let s=(a,l,c)=>{let d=nT.fromDiffs(a.changes,e.original.getLineCount(),e.modified.getLineCount(),this._options.hideUnchangedRegionsMinimumLineCount.read(c),this._options.hideUnchangedRegionsContextLineCount.read(c)),u,h=this._unchangedRegions.get();if(h){let _=h.originalDecorationIds.map(w=>e.original.getDecorationRange(w)).map(w=>w?ut.fromRangeInclusive(w):void 0),b=h.modifiedDecorationIds.map(w=>e.modified.getDecorationRange(w)).map(w=>w?ut.fromRangeInclusive(w):void 0),x=q8e(h.regions.map((w,y)=>{if(!_[y]||!b[y])return;let C=_[y].length;return new nT(_[y].startLineNumber,b[y].startLineNumber,C,Math.min(w.visibleLineCountTop.get(),C),Math.min(w.visibleLineCountBottom.get(),C-w.visibleLineCountTop.get()))}).filter(xd),(w,y)=>!y||w.modifiedLineNumber>=y.modifiedLineNumber+y.lineCount&&w.originalLineNumber>=y.originalLineNumber+y.lineCount).map(w=>new ya(w.getHiddenOriginalRange(c),w.getHiddenModifiedRange(c)));x=ya.clip(x,ut.ofLength(1,e.original.getLineCount()),ut.ofLength(1,e.modified.getLineCount())),u=ya.inverse(x,e.original.getLineCount(),e.modified.getLineCount())}let f=[];if(u)for(let _ of d){let b=u.filter(v=>v.original.intersectsStrict(_.originalUnchangedRange)&&v.modified.intersectsStrict(_.modifiedUnchangedRange));f.push(..._.setVisibleRanges(b,l))}else f.push(...d);let p=e.original.deltaDecorations(h?.originalDecorationIds||[],f.map(_=>({range:_.originalUnchangedRange.toInclusiveRange(),options:{description:"unchanged"}}))),g=e.modified.deltaDecorations(h?.modifiedDecorationIds||[],f.map(_=>({range:_.modifiedUnchangedRange.toInclusiveRange(),options:{description:"unchanged"}})));this._unchangedRegions.set({regions:f,originalDecorationIds:p,modifiedDecorationIds:g},l)};this._register(e.modified.onDidChangeContent(a=>{if(this._diff.get()){let c=Df.fromModelContentChanges(a.changes),d=(this._lastDiff,e.original,e.modified,void 0);d&&(this._lastDiff=d,xi(u=>{this._diff.set(LP.fromDiffResult(this._lastDiff),u),s(d,u);let h=this.movedTextToCompare.get();this.movedTextToCompare.set(h?this._lastDiff.moves.find(f=>f.lineRangeMapping.modified.intersect(h.lineRangeMapping.modified)):void 0,u)}))}this._isDiffUpToDate.set(!1,void 0),r.schedule()})),this._register(e.original.onDidChangeContent(a=>{if(this._diff.get()){let c=Df.fromModelContentChanges(a.changes),d=(this._lastDiff,e.original,e.modified,void 0);d&&(this._lastDiff=d,xi(u=>{this._diff.set(LP.fromDiffResult(this._lastDiff),u),s(d,u);let h=this.movedTextToCompare.get();this.movedTextToCompare.set(h?this._lastDiff.moves.find(f=>f.lineRangeMapping.modified.intersect(h.lineRangeMapping.modified)):void 0,u)}))}this._isDiffUpToDate.set(!1,void 0),r.schedule()})),this._register(To(async(a,l)=>{this._options.hideUnchangedRegionsMinimumLineCount.read(a),this._options.hideUnchangedRegionsContextLineCount.read(a),r.cancel(),o.read(a);let c=this._diffProvider.read(a);c.onChangeSignal.read(a),Na(RL,a),Na(FA,a),this._isDiffUpToDate.set(!1,void 0);let d=[];l.add(e.original.onDidChangeContent(f=>{let p=Df.fromModelContentChanges(f.changes);d=FI(d,p)}));let u=[];l.add(e.modified.onDidChangeContent(f=>{let p=Df.fromModelContentChanges(f.changes);u=FI(u,p)}));let h=await c.diffProvider.computeDiff(e.original,e.modified,{ignoreTrimWhitespace:this._options.ignoreTrimWhitespace.read(a),maxComputationTimeMs:this._options.maxComputationTimeMs.read(a),computeMoves:this._options.showMoves.read(a)},this._cancellationTokenSource.token);this._cancellationTokenSource.token.isCancellationRequested||e.original.isDisposed()||e.modified.isDisposed()||(h=Cht(h,e.original,e.modified),h=(e.original,e.modified,void 0)??h,h=(e.original,e.modified,void 0)??h,xi(f=>{s(h,f),this._lastDiff=h;let p=LP.fromDiffResult(h);this._diff.set(p,f),this._isDiffUpToDate.set(!0,f);let g=this.movedTextToCompare.get();this.movedTextToCompare.set(g?this._lastDiff.moves.find(_=>_.lineRangeMapping.modified.intersect(g.lineRangeMapping.modified)):void 0,f)}))}))}ensureModifiedLineIsVisible(e,t,i){if(this.diff.get()?.mappings.length===0)return;let o=this._unchangedRegions.get()?.regions||[];for(let r of o)if(r.getHiddenModifiedRange(void 0).contains(e)){r.showModifiedLine(e,t,i);return}}ensureOriginalLineIsVisible(e,t,i){if(this.diff.get()?.mappings.length===0)return;let o=this._unchangedRegions.get()?.regions||[];for(let r of o)if(r.getHiddenOriginalRange(void 0).contains(e)){r.showOriginalLine(e,t,i);return}}async waitForDiff(){await WM(this.isDiffUpToDate,e=>e)}serializeState(){return{collapsedRegions:this._unchangedRegions.get()?.regions.map(t=>({range:t.getHiddenModifiedRange(void 0).serialize()}))}}restoreSerializedState(e){let t=e.collapsedRegions?.map(o=>ut.deserialize(o.range)),i=this._unchangedRegions.get();!i||!t||xi(o=>{for(let r of i.regions)for(let s of t)if(r.modifiedUnchangedRange.intersect(s)){r.setHiddenModifiedRange(s,o);break}})}};ej=wht([yht(2,Yb)],ej);LP=class n{static fromDiffResult(e){return new n(e.changes.map(t=>new IP(t)),e.moves||[],e.identical,e.quitEarly)}constructor(e,t,i,o){this.mappings=e,this.movedTexts=t,this.identical=i,this.quitEarly=o}},IP=class{constructor(e){this.lineRangeMapping=e}},nT=class n{static fromDiffs(e,t,i,o,r){let s=Rl.inverse(e,t,i),a=[];for(let l of s){let c=l.original.startLineNumber,d=l.modified.startLineNumber,u=l.original.length,h=c===1&&d===1,f=c+u===t+1&&d+u===i+1;(h||f)&&u>=r+o?(h&&!f&&(u-=r),f&&!h&&(c+=r,d+=r,u-=r),a.push(new n(c,d,u,0,0))):u>=r*2+o&&(c+=r,d+=r,u-=r*2,a.push(new n(c,d,u,0,0)))}return a}get originalUnchangedRange(){return ut.ofLength(this.originalLineNumber,this.lineCount)}get modifiedUnchangedRange(){return ut.ofLength(this.modifiedLineNumber,this.lineCount)}constructor(e,t,i,o,r){this.originalLineNumber=e,this.modifiedLineNumber=t,this.lineCount=i,this._visibleLineCountTop=lt(this,0),this.visibleLineCountTop=this._visibleLineCountTop,this._visibleLineCountBottom=lt(this,0),this.visibleLineCountBottom=this._visibleLineCountBottom,this._shouldHideControls=Pe(this,l=>this.visibleLineCountTop.read(l)+this.visibleLineCountBottom.read(l)===this.lineCount&&!this.isDragged.read(l)),this.isDragged=lt(this,void 0);let s=Math.max(Math.min(o,this.lineCount),0),a=Math.max(Math.min(r,this.lineCount-o),0);boe(o===s),boe(r===a),this._visibleLineCountTop.set(s,void 0),this._visibleLineCountBottom.set(a,void 0)}setVisibleRanges(e,t){let i=[],o=new yh(e.map(l=>l.modified)).subtractFrom(this.modifiedUnchangedRange),r=this.originalLineNumber,s=this.modifiedLineNumber,a=this.modifiedLineNumber+this.lineCount;if(o.ranges.length===0)this.showAll(t),i.push(this);else{let l=0;for(let c of o.ranges){let d=l===o.ranges.length-1;l++;let u=(d?a:c.endLineNumberExclusive)-s,h=new n(r,s,u,0,0);h.setHiddenModifiedRange(c,t),i.push(h),r=h.originalUnchangedRange.endLineNumberExclusive,s=h.modifiedUnchangedRange.endLineNumberExclusive}}return i}shouldHideControls(e){return this._shouldHideControls.read(e)}getHiddenOriginalRange(e){return ut.ofLength(this.originalLineNumber+this._visibleLineCountTop.read(e),this.lineCount-this._visibleLineCountTop.read(e)-this._visibleLineCountBottom.read(e))}getHiddenModifiedRange(e){return ut.ofLength(this.modifiedLineNumber+this._visibleLineCountTop.read(e),this.lineCount-this._visibleLineCountTop.read(e)-this._visibleLineCountBottom.read(e))}setHiddenModifiedRange(e,t){let i=e.startLineNumber-this.modifiedLineNumber,o=this.modifiedLineNumber+this.lineCount-e.endLineNumberExclusive;this.setState(i,o,t)}getMaxVisibleLineCountTop(){return this.lineCount-this._visibleLineCountBottom.get()}getMaxVisibleLineCountBottom(){return this.lineCount-this._visibleLineCountTop.get()}showMoreAbove(e=10,t){let i=this.getMaxVisibleLineCountTop();this._visibleLineCountTop.set(Math.min(this._visibleLineCountTop.get()+e,i),t)}showMoreBelow(e=10,t){let i=this.lineCount-this._visibleLineCountTop.get();this._visibleLineCountBottom.set(Math.min(this._visibleLineCountBottom.get()+e,i),t)}showAll(e){this._visibleLineCountBottom.set(this.lineCount-this._visibleLineCountTop.get(),e)}showModifiedLine(e,t,i){let o=e+1-(this.modifiedLineNumber+this._visibleLineCountTop.get()),r=this.modifiedLineNumber-this._visibleLineCountBottom.get()+this.lineCount-e;t===0&&o{ke();Gr();Qi();j();Bt();bn();pe();tj=class extends D{get visibility(){return this._visibility}set visibility(e){this._visibility!==e&&(this._visibility=e,this._diffActions.style.visibility=e?"visible":"hidden")}constructor(e,t,i,o,r,s,a,l,c){super(),this._getViewZoneId=e,this._marginDomNode=t,this._modifiedEditor=i,this._diff=o,this._editor=r,this._viewLineCounts=s,this._originalTextModel=a,this._contextMenuService=l,this._clipboardService=c,this._visibility=!1,this._marginDomNode.style.zIndex="10",this._diffActions=document.createElement("div"),this._diffActions.className=Oe.asClassName(oe.lightBulb)+" lightbulb-glyph",this._diffActions.style.position="absolute";let d=this._modifiedEditor.getOption(67);this._diffActions.style.right="0px",this._diffActions.style.visibility="hidden",this._diffActions.style.height=`${d}px`,this._diffActions.style.lineHeight=`${d}px`,this._marginDomNode.appendChild(this._diffActions);let u=0,h=i.getOption(128)&&!Xa,f=(p,g)=>{this._contextMenuService.showContextMenu({domForShadowRoot:h?i.getDomNode()??void 0:void 0,getAnchor:()=>({x:p,y:g}),getActions:()=>{let _=[],b=o.modified.isEmpty;return _.push(new rr("diff.clipboard.copyDeletedContent",b?o.original.length>1?m("diff.clipboard.copyDeletedLinesContent.label","Copy deleted lines"):m("diff.clipboard.copyDeletedLinesContent.single.label","Copy deleted line"):o.original.length>1?m("diff.clipboard.copyChangedLinesContent.label","Copy changed lines"):m("diff.clipboard.copyChangedLinesContent.single.label","Copy changed line"),void 0,!0,async()=>{let x=this._originalTextModel.getValueInRange(o.original.toExclusiveRange());await this._clipboardService.writeText(x)})),o.original.length>1&&_.push(new rr("diff.clipboard.copyDeletedLineContent",b?m("diff.clipboard.copyDeletedLineContent.label","Copy deleted line ({0})",o.original.startLineNumber+u):m("diff.clipboard.copyChangedLineContent.label","Copy changed line ({0})",o.original.startLineNumber+u),void 0,!0,async()=>{let x=this._originalTextModel.getLineContent(o.original.startLineNumber+u);x===""&&(x=this._originalTextModel.getEndOfLineSequence()===0?` `:`\r `),await this._clipboardService.writeText(x)})),i.getOption(92)||_.push(new rr("diff.inline.revertChange",m("diff.inline.revertChange.label","Revert this change"),void 0,!0,async()=>{this._editor.revert(this._diff)})),_},autoSelectFirstItem:!0})};this._register(gi(this._diffActions,"mousedown",p=>{if(!p.leftButton)return;let{top:g,height:_}=Ci(this._diffActions),b=Math.floor(d/3);p.preventDefault(),f(p.posx,g+_+b)})),this._register(i.onMouseMove(p=>{(p.target.type===8||p.target.type===5)&&p.target.detail.viewZoneId===this._getViewZoneId()?(u=this._updateLightBulbPosition(this._marginDomNode,p.event.browserEvent.y,d),this.visibility=!0):this.visibility=!1})),this._register(i.onMouseDown(p=>{p.event.leftButton&&(p.target.type===8||p.target.type===5)&&p.target.detail.viewZoneId===this._getViewZoneId()&&(p.event.preventDefault(),u=this._updateLightBulbPosition(this._marginDomNode,p.event.browserEvent.y,d),f(p.event.posx,p.event.posy+d))}))}_updateLightBulbPosition(e,t,i){let{top:o}=Ci(e),r=t-o,s=Math.floor(r/i),a=s*i;if(this._diffActions.style.top=`${a}px`,this._viewLineCounts){let l=0;for(let c=0;c0,r=new xu(1e4),s=0,a=0,l=[];for(let h=0;h');let l=e.getLineContent(),c=_c.isBasicASCII(l,o),d=_c.containsRTL(l,c,r),u=Ob(new id(s.fontInfo.isMonospace&&!s.disableMonospaceOptimizations,s.fontInfo.canUseHalfwidthRightwardsArrow,l,!1,c,d,0,e,t,s.tabSize,0,s.fontInfo.spaceWidth,s.fontInfo.middotWidth,s.fontInfo.wsmiddotWidth,s.stopRenderingLineAfter,s.renderWhitespace,s.renderControlCharacters,s.fontLigatures!==ah.OFF,null),a);return a.appendString(""),u.characterMapping.getHorizontalOffset(u.characterMapping.length)}var X8e,ij,nj,eBe=k(()=>{Rm();bu();ir();Y_();e0();Tw();Af();X8e=Tl("diffEditorWidget",{createHTML:n=>n});ij=class{constructor(e,t,i,o){this.lineTokens=e,this.lineBreakData=t,this.mightContainNonBasicASCII=i,this.mightContainRTL=o}},nj=class n{static fromEditor(e){let t=e.getOptions(),i=t.get(50),o=t.get(146);return new n(e.getModel()?.getOptions().tabSize||0,i,t.get(33),i.typicalHalfwidthCharacterWidth,t.get(105),t.get(67),o.decorationsWidth,t.get(118),t.get(100),t.get(95),t.get(51))}constructor(e,t,i,o,r,s,a,l,c,d,u){this.tabSize=e,this.fontInfo=t,this.disableMonospaceOptimizations=i,this.typicalHalfwidthCharacterWidth=o,this.scrollBeyondLastColumn=r,this.lineHeight=s,this.lineDecorationsWidth=a,this.stopRenderingLineAfter=l,this.renderWhitespace=c,this.renderControlCharacters=d,this.fontLigatures=u}}});function iBe(n,e,t,i,o,r){let s=new wl(nBe(n,i)),a=new wl(nBe(e,o)),l=n.getOption(67),c=e.getOption(67),d=[],u=0,h=0;function f(p,g){for(;;){let _=s.peek(),b=a.peek();if(_&&_.lineNumber>=p&&(_=void 0),b&&b.lineNumber>=g&&(b=void 0),!_&&!b)break;let v=_?_.lineNumber-u:Number.MAX_VALUE,x=b?b.lineNumber-h:Number.MAX_VALUE;vx?(a.dequeue(),_={lineNumber:b.lineNumber-h+u,heightInPx:0}):(s.dequeue(),a.dequeue()),d.push({originalRange:ut.ofLength(_.lineNumber,1),modifiedRange:ut.ofLength(b.lineNumber,1),originalHeightInPx:l+_.heightInPx,modifiedHeightInPx:c+b.heightInPx,diff:void 0})}}for(let p of t){let x=function(w,y,C=!1){if(wF.lineNumberF+q.heightInPx,0)??0,M=a.takeWhile(F=>F.lineNumberF+q.heightInPx,0)??0;d.push({originalRange:L,modifiedRange:E,originalHeightInPx:L.length*l+N,modifiedHeightInPx:E.length*c+M,diff:p.lineRangeMapping}),v=w,b=y},g=p.lineRangeMapping;f(g.original.startLineNumber,g.modified.startLineNumber);let _=!0,b=g.modified.startLineNumber,v=g.original.startLineNumber;if(r)for(let w of g.innerChanges||[]){w.originalRange.startColumn>1&&w.modifiedRange.startColumn>1&&x(w.originalRange.startLineNumber,w.modifiedRange.startLineNumber);let y=n.getModel(),C=w.originalRange.endLineNumber<=y.getLineCount()?y.getLineMaxColumn(w.originalRange.endLineNumber):Number.MAX_SAFE_INTEGER;w.originalRange.endColumn1&&i.push({lineNumber:l,heightInPx:s*(c-1)})}for(let l of n.getWhitespaces()){if(e.has(l.id))continue;let c=l.afterLineNumber===0?0:r.convertViewPositionToModelPosition(new P(l.afterLineNumber,1)).lineNumber;t.push({lineNumber:c,heightInPx:l.height})}return $8e(t,i,l=>l.lineNumber,(l,c)=>({lineNumber:l.lineNumber,heightInPx:l.heightInPx+c.heightInPx}))}function EP(n){return n.innerChanges?n.innerChanges.every(e=>oBe(e.modifiedRange)&&oBe(e.originalRange)||e.originalRange.equalsRange(new S(1,1,1,1))):!1}function oBe(n){return n.startLineNumber===n.endLineNumber}var kht,tBe,oj,rj=k(()=>{ke();at();ft();Qi();j();Oi();bn();yi();bu();Hw();Gfe();Z8e();eBe();zh();Nl();qe();Af();Mb();Al();we();kht=function(n,e,t,i){var o=arguments.length,r=o<3?e:i===null?i=Object.getOwnPropertyDescriptor(e,t):i,s;if(typeof Reflect=="object"&&typeof Reflect.decorate=="function")r=Reflect.decorate(n,e,t,i);else for(var a=n.length-1;a>=0;a--)(s=n[a])&&(r=(o<3?s(r):o>3?s(e,t,r):s(e,t))||r);return o>3&&r&&Object.defineProperty(e,t,r),r},tBe=function(n,e){return function(t,i){e(t,i,n)}},oj=class extends D{constructor(e,t,i,o,r,s,a,l,c,d){super(),this._targetWindow=e,this._editors=t,this._diffModel=i,this._options=o,this._diffEditorWidget=r,this._canIgnoreViewZoneUpdateEvent=s,this._origViewZonesToIgnore=a,this._modViewZonesToIgnore=l,this._clipboardService=c,this._contextMenuService=d,this._originalTopPadding=lt(this,0),this._originalScrollOffset=lt(this,0),this._originalScrollOffsetAnimated=Tfe(this._targetWindow,this._originalScrollOffset,this._store),this._modifiedTopPadding=lt(this,0),this._modifiedScrollOffset=lt(this,0),this._modifiedScrollOffsetAnimated=Tfe(this._targetWindow,this._modifiedScrollOffset,this._store);let u=lt("invalidateAlignmentsState",0),h=this._register(new Lt(()=>{u.set(u.get()+1,void 0)},0));this._register(this._editors.original.onDidChangeViewZones(x=>{this._canIgnoreViewZoneUpdateEvent()||h.schedule()})),this._register(this._editors.modified.onDidChangeViewZones(x=>{this._canIgnoreViewZoneUpdateEvent()||h.schedule()})),this._register(this._editors.original.onDidChangeConfiguration(x=>{(x.hasChanged(147)||x.hasChanged(67))&&h.schedule()})),this._register(this._editors.modified.onDidChangeConfiguration(x=>{(x.hasChanged(147)||x.hasChanged(67))&&h.schedule()}));let f=this._diffModel.map(x=>x?Kt(this,x.model.original.onDidChangeTokens,()=>x.model.original.tokenization.backgroundTokenizationState===2):void 0).map((x,w)=>x?.read(w)),p=Pe(x=>{let w=this._diffModel.read(x),y=w?.diff.read(x);if(!w||!y)return null;u.read(x);let L=this._options.renderSideBySide.read(x);return iBe(this._editors.original,this._editors.modified,y.mappings,this._origViewZonesToIgnore,this._modViewZonesToIgnore,L)}),g=Pe(x=>{let w=this._diffModel.read(x)?.movedTextToCompare.read(x);if(!w)return null;u.read(x);let y=w.changes.map(C=>new IP(C));return iBe(this._editors.original,this._editors.modified,y,this._origViewZonesToIgnore,this._modViewZonesToIgnore,!0)});function _(){let x=document.createElement("div");return x.className="diagonal-fill",x}let b=this._register(new H);this.viewZones=hc(this,(x,w)=>{b.clear();let y=p.read(x)||[],C=[],L=[],E=this._modifiedTopPadding.read(x);E>0&&L.push({afterLineNumber:0,domNode:document.createElement("div"),heightInPx:E,showInHiddenAreas:!0,suppressMouseDown:!0});let N=this._originalTopPadding.read(x);N>0&&C.push({afterLineNumber:0,domNode:document.createElement("div"),heightInPx:N,showInHiddenAreas:!0,suppressMouseDown:!0});let M=this._options.renderSideBySide.read(x),F=M?void 0:this._editors.modified._getViewModel()?.createLineBreaksComputer();if(F){let ce=this._editors.original.getModel();for(let B of y)if(B.diff)for(let Je=B.originalRange.startLineNumber;Jece.getLineCount())return{orig:C,mod:L};F?.addRequest(ce.getLineContent(Je),null,null)}}let q=F?.finalize()??[],te=0,$=this._editors.modified.getOption(67),z=this._diffModel.read(x)?.movedTextToCompare.read(x),ae=this._editors.original.getModel()?.mightContainNonBasicASCII()??!1,X=this._editors.original.getModel()?.mightContainRTL()??!1,ue=nj.fromEditor(this._editors.modified);for(let ce of y)if(ce.diff&&!M&&(!this._options.useTrueInlineDiffRendering.read(x)||!EP(ce.diff))){if(!ce.originalRange.isEmpty){f.read(x);let Je=document.createElement("div");Je.classList.add("view-lines","line-delete","monaco-mouse-cursor-text");let ni=this._editors.original.getModel();if(ce.originalRange.endLineNumberExclusive-1>ni.getLineCount())return{orig:C,mod:L};let K=new ij(ce.originalRange.mapToLineArray(Ri=>ni.tokenization.getLineTokens(Ri)),ce.originalRange.mapToLineArray(Ri=>q[te++]),ae,X),Ni=[];for(let Ri of ce.diff.innerChanges||[])Ni.push(new Fb(Ri.originalRange.delta(-(ce.diff.original.startLineNumber-1)),Wp.className,0));let ui=J8e(K,ue,Ni,Je),po=document.createElement("div");if(po.className="inline-deleted-margin-view-zone",Kn(po,ue.fontInfo),this._options.renderIndicators.read(x))for(let Ri=0;Rilf(Jr),po,this._editors.modified,ce.diff,this._diffEditorWidget,ui.viewLineCounts,this._editors.original.getModel(),this._contextMenuService,this._clipboardService));for(let Ri=0;Ri1&&C.push({afterLineNumber:ce.originalRange.startLineNumber+Ri,domNode:_(),heightInPx:(vs-1)*$,showInHiddenAreas:!0,suppressMouseDown:!0})}L.push({afterLineNumber:ce.modifiedRange.startLineNumber-1,domNode:Je,heightInPx:ui.heightInLines*$,minWidthInPx:ui.minWidthInPx,marginDomNode:po,setZoneId(Ri){Jr=Ri},showInHiddenAreas:!0,suppressMouseDown:!0})}let B=document.createElement("div");B.className="gutter-delete",C.push({afterLineNumber:ce.originalRange.endLineNumberExclusive-1,domNode:_(),heightInPx:ce.modifiedHeightInPx,marginDomNode:B,showInHiddenAreas:!0,suppressMouseDown:!0})}else{let B=ce.modifiedHeightInPx-ce.originalHeightInPx;if(B>0){if(z?.lineRangeMapping.original.delta(-1).deltaLength(2).contains(ce.originalRange.endLineNumberExclusive-1))continue;C.push({afterLineNumber:ce.originalRange.endLineNumberExclusive-1,domNode:_(),heightInPx:B,showInHiddenAreas:!0,suppressMouseDown:!0})}else{let Je=function(){let K=document.createElement("div");return K.className="arrow-revert-change "+Oe.asClassName(oe.arrowRight),w.add(U(K,"mousedown",Ni=>Ni.stopPropagation())),w.add(U(K,"click",Ni=>{Ni.stopPropagation(),r.revert(ce.diff)})),J("div",{},K)};if(z?.lineRangeMapping.modified.delta(-1).deltaLength(2).contains(ce.modifiedRange.endLineNumberExclusive-1))continue;let ni;ce.diff&&ce.diff.modified.isEmpty&&this._options.shouldRenderOldRevertArrows.read(x)&&(ni=Je()),L.push({afterLineNumber:ce.modifiedRange.endLineNumberExclusive-1,domNode:_(),heightInPx:-B,marginDomNode:ni,showInHiddenAreas:!0,suppressMouseDown:!0})}}for(let ce of g.read(x)??[]){if(!z?.lineRangeMapping.original.intersect(ce.originalRange)||!z?.lineRangeMapping.modified.intersect(ce.modifiedRange))continue;let B=ce.modifiedHeightInPx-ce.originalHeightInPx;B>0?C.push({afterLineNumber:ce.originalRange.endLineNumberExclusive-1,domNode:_(),heightInPx:B,showInHiddenAreas:!0,suppressMouseDown:!0}):L.push({afterLineNumber:ce.modifiedRange.endLineNumberExclusive-1,domNode:_(),heightInPx:-B,showInHiddenAreas:!0,suppressMouseDown:!0})}return{orig:C,mod:L}});let v=!1;this._register(this._editors.original.onDidScrollChange(x=>{x.scrollLeftChanged&&!v&&(v=!0,this._editors.modified.setScrollLeft(x.scrollLeft),v=!1)})),this._register(this._editors.modified.onDidScrollChange(x=>{x.scrollLeftChanged&&!v&&(v=!0,this._editors.original.setScrollLeft(x.scrollLeft),v=!1)})),this._originalScrollTop=Kt(this._editors.original.onDidScrollChange,()=>this._editors.original.getScrollTop()),this._modifiedScrollTop=Kt(this._editors.modified.onDidScrollChange,()=>this._editors.modified.getScrollTop()),this._register(He(x=>{let w=this._originalScrollTop.read(x)-(this._originalScrollOffsetAnimated.get()-this._modifiedScrollOffsetAnimated.read(x))-(this._originalTopPadding.get()-this._modifiedTopPadding.read(x));w!==this._editors.modified.getScrollTop()&&this._editors.modified.setScrollTop(w,1)})),this._register(He(x=>{let w=this._modifiedScrollTop.read(x)-(this._modifiedScrollOffsetAnimated.get()-this._originalScrollOffsetAnimated.read(x))-(this._modifiedTopPadding.get()-this._originalTopPadding.read(x));w!==this._editors.original.getScrollTop()&&this._editors.original.setScrollTop(w,1)})),this._register(He(x=>{let w=this._diffModel.read(x)?.movedTextToCompare.read(x),y=0;if(w){let C=this._editors.original.getTopForLineNumber(w.lineRangeMapping.original.startLineNumber,!0)-this._originalTopPadding.get();y=this._editors.modified.getTopForLineNumber(w.lineRangeMapping.modified.startLineNumber,!0)-this._modifiedTopPadding.get()-C}y>0?(this._modifiedTopPadding.set(0,void 0),this._originalTopPadding.set(y,void 0)):y<0?(this._modifiedTopPadding.set(-y,void 0),this._originalTopPadding.set(0,void 0)):setTimeout(()=>{this._modifiedTopPadding.set(0,void 0),this._originalTopPadding.set(0,void 0)},400),this._editors.modified.hasTextFocus()?this._originalScrollOffset.set(this._modifiedScrollOffset.get()-y,void 0,!0):this._modifiedScrollOffset.set(this._originalScrollOffset.get()+y,void 0,!0)}))}};oj=kht([tBe(8,gc),tBe(9,sr)],oj)});var zw,Yfe,sj,Zfe=k(()=>{ke();Oh();Gr();at();Ad();Qi();j();Oi();bn();zh();Rd();pe();zw=class n extends D{static{this.movedCodeBlockPadding=4}constructor(e,t,i,o,r){super(),this._rootElement=e,this._diffModel=t,this._originalEditorLayoutInfo=i,this._modifiedEditorLayoutInfo=o,this._editors=r,this._originalScrollTop=Kt(this,this._editors.original.onDidScrollChange,()=>this._editors.original.getScrollTop()),this._modifiedScrollTop=Kt(this,this._editors.modified.onDidScrollChange,()=>this._editors.modified.getScrollTop()),this._viewZonesChanged=Wo("onDidChangeViewZones",this._editors.modified.onDidChangeViewZones),this.width=lt(this,0),this._modifiedViewZonesChangedSignal=Wo("modified.onDidChangeViewZones",this._editors.modified.onDidChangeViewZones),this._originalViewZonesChangedSignal=Wo("original.onDidChangeViewZones",this._editors.original.onDidChangeViewZones),this._state=hc(this,(d,u)=>{this._element.replaceChildren();let h=this._diffModel.read(d),f=h?.diff.read(d)?.movedTexts;if(!f||f.length===0){this.width.set(0,void 0);return}this._viewZonesChanged.read(d);let p=this._originalEditorLayoutInfo.read(d),g=this._modifiedEditorLayoutInfo.read(d);if(!p||!g){this.width.set(0,void 0);return}this._modifiedViewZonesChangedSignal.read(d),this._originalViewZonesChangedSignal.read(d);let _=f.map(L=>{function E(X,ue){let ce=ue.getTopForLineNumber(X.startLineNumber,!0),B=ue.getTopForLineNumber(X.endLineNumberExclusive,!0);return(ce+B)/2}let N=E(L.lineRangeMapping.original,this._editors.original),M=this._originalScrollTop.read(d),F=E(L.lineRangeMapping.modified,this._editors.modified),q=this._modifiedScrollTop.read(d),te=N-M,$=F-q,z=Math.min(N,F),ae=Math.max(N,F);return{range:new Wt(z,ae),from:te,to:$,fromWithoutScroll:N,toWithoutScroll:F,move:L}});_.sort(WEe(mr(L=>L.fromWithoutScroll>L.toWithoutScroll,HEe),mr(L=>L.fromWithoutScroll>L.toWithoutScroll?L.fromWithoutScroll:-L.toWithoutScroll,yl)));let b=Yfe.compute(_.map(L=>L.range)),v=10,x=p.verticalScrollbarWidth,w=(b.getTrackCount()-1)*10+v*2,y=x+w+(g.contentLeft-n.movedCodeBlockPadding),C=0;for(let L of _){let E=b.getTrack(C),N=x+v+E*10,M=15,F=15,q=y,te=g.glyphMarginWidth+g.lineNumbersWidth,$=18,z=document.createElementNS("http://www.w3.org/2000/svg","rect");z.classList.add("arrow-rectangle"),z.setAttribute("x",`${q-te}`),z.setAttribute("y",`${L.to-$/2}`),z.setAttribute("width",`${te}`),z.setAttribute("height",`${$}`),this._element.appendChild(z);let ae=document.createElementNS("http://www.w3.org/2000/svg","g"),X=document.createElementNS("http://www.w3.org/2000/svg","path");X.setAttribute("d",`M 0 ${L.from} L ${N} ${L.from} L ${N} ${L.to} L ${q-F} ${L.to}`),X.setAttribute("fill","none"),ae.appendChild(X);let ue=document.createElementNS("http://www.w3.org/2000/svg","polygon");ue.classList.add("arrow"),u.add(He(ce=>{X.classList.toggle("currentMove",L.move===h.activeMovedText.read(ce)),ue.classList.toggle("currentMove",L.move===h.activeMovedText.read(ce))})),ue.setAttribute("points",`${q-F},${L.to-M/2} ${q},${L.to} ${q-F},${L.to+M/2}`),ae.appendChild(ue),this._element.appendChild(ae),C++}this.width.set(w,void 0)}),this._element=document.createElementNS("http://www.w3.org/2000/svg","svg"),this._element.setAttribute("class","moved-blocks-lines"),this._rootElement.appendChild(this._element),this._register(ge(()=>this._element.remove())),this._register(He(d=>{let u=this._originalEditorLayoutInfo.read(d),h=this._modifiedEditorLayoutInfo.read(d);!u||!h||(this._element.style.left=`${u.width-u.verticalScrollbarWidth}px`,this._element.style.height=`${u.height}px`,this._element.style.width=`${u.verticalScrollbarWidth+u.contentLeft-n.movedCodeBlockPadding+this.width.read(d)}px`)})),this._register(If(this._state));let s=Pe(d=>{let h=this._diffModel.read(d)?.diff.read(d);return h?h.movedTexts.map(f=>({move:f,original:new Vg(Ms(f.lineRangeMapping.original.startLineNumber-1),18),modified:new Vg(Ms(f.lineRangeMapping.modified.startLineNumber-1),18)})):[]});this._register(ZE(this._editors.original,s.map(d=>d.map(u=>u.original)))),this._register(ZE(this._editors.modified,s.map(d=>d.map(u=>u.modified)))),this._register(To((d,u)=>{let h=s.read(d);for(let f of h)u.add(new sj(this._editors.original,f.original,f.move,"original",this._diffModel.get())),u.add(new sj(this._editors.modified,f.modified,f.move,"modified",this._diffModel.get()))}));let a=Wo("original.onDidFocusEditorWidget",d=>this._editors.original.onDidFocusEditorWidget(()=>setTimeout(()=>d(void 0),0))),l=Wo("modified.onDidFocusEditorWidget",d=>this._editors.modified.onDidFocusEditorWidget(()=>setTimeout(()=>d(void 0),0))),c="modified";this._register(gb({createEmptyChangeSummary:()=>{},handleChange:(d,u)=>(d.didChange(a)&&(c="original"),d.didChange(l)&&(c="modified"),!0)},d=>{a.read(d),l.read(d);let u=this._diffModel.read(d);if(!u)return;let h=u.diff.read(d),f;if(h&&c==="original"){let p=this._editors.originalCursor.read(d);p&&(f=h.movedTexts.find(g=>g.lineRangeMapping.original.contains(p.lineNumber)))}if(h&&c==="modified"){let p=this._editors.modifiedCursor.read(d);p&&(f=h.movedTexts.find(g=>g.lineRangeMapping.modified.contains(p.lineNumber)))}f!==u.movedTextToCompare.get()&&u.movedTextToCompare.set(void 0,void 0),u.setActiveMovedText(f)}))}},Yfe=class n{static compute(e){let t=[],i=[];for(let o of e){let r=t.findIndex(s=>!s.intersectsStrict(o));r===-1&&(t.length>=6?r=MNe(t,mr(a=>a.intersectWithRangeLength(o),yl)):(r=t.length,t.push(new H6))),t[r].addRange(o),i.push(r)}return new n(t.length,i)}constructor(e,t){this._trackCount=e,this.trackPerLineIdx=t}getTrack(e){return this.trackPerLineIdx[e]}getTrackCount(){return this._trackCount}},sj=class extends I0{constructor(e,t,i,o,r){let s=Et("div.diff-hidden-lines-widget");super(e,t,s.root),this._editor=e,this._move=i,this._kind=o,this._diffModel=r,this._nodes=Et("div.diff-moved-code-block",{style:{marginRight:"4px"}},[Et("div.text-content@textContent"),Et("div.action-bar@actionBar")]),s.root.appendChild(this._nodes.root);let a=Kt(this._editor.onDidLayoutChange,()=>this._editor.getLayoutInfo());this._register(Gd(this._nodes.root,{paddingRight:a.map(h=>h.verticalScrollbarWidth)}));let l;i.changes.length>0?l=this._kind==="original"?m("codeMovedToWithChanges","Code moved with changes to line {0}-{1}",this._move.lineRangeMapping.modified.startLineNumber,this._move.lineRangeMapping.modified.endLineNumberExclusive-1):m("codeMovedFromWithChanges","Code moved with changes from line {0}-{1}",this._move.lineRangeMapping.original.startLineNumber,this._move.lineRangeMapping.original.endLineNumberExclusive-1):l=this._kind==="original"?m("codeMovedTo","Code moved to line {0}-{1}",this._move.lineRangeMapping.modified.startLineNumber,this._move.lineRangeMapping.modified.endLineNumberExclusive-1):m("codeMovedFrom","Code moved from line {0}-{1}",this._move.lineRangeMapping.original.startLineNumber,this._move.lineRangeMapping.original.endLineNumberExclusive-1);let c=this._register(new Zo(this._nodes.actionBar,{highlightToggledItems:!0})),d=new rr("",l,"",!1);c.push(d,{icon:!1,label:!0});let u=new rr("","Compare",Oe.asClassName(oe.compareChanges),!0,()=>{this._editor.focus(),this._diffModel.movedTextToCompare.set(this._diffModel.movedTextToCompare.get()===i?void 0:this._move,void 0)});this._register(He(h=>{let f=this._diffModel.movedTextToCompare.read(h)===i;u.checked=f})),c.push(u,{icon:!1,label:!0})}}});var aj,rBe=k(()=>{j();Oi();rj();Zfe();Hw();zh();aj=class extends D{constructor(e,t,i,o){super(),this._editors=e,this._diffModel=t,this._options=i,this._decorations=Pe(this,r=>{let s=this._diffModel.read(r),a=s?.diff.read(r);if(!a)return null;let l=this._diffModel.read(r).movedTextToCompare.read(r),c=this._options.renderIndicators.read(r),d=this._options.showEmptyDecorations.read(r),u=[],h=[];if(!l)for(let p of a.mappings)if(p.lineRangeMapping.original.isEmpty||u.push({range:p.lineRangeMapping.original.toInclusiveRange(),options:c?Gb:Vfe}),p.lineRangeMapping.modified.isEmpty||h.push({range:p.lineRangeMapping.modified.toInclusiveRange(),options:c?T0:zfe}),p.lineRangeMapping.modified.isEmpty||p.lineRangeMapping.original.isEmpty)p.lineRangeMapping.original.isEmpty||u.push({range:p.lineRangeMapping.original.toInclusiveRange(),options:JE}),p.lineRangeMapping.modified.isEmpty||h.push({range:p.lineRangeMapping.modified.toInclusiveRange(),options:XE});else{let g=this._options.useTrueInlineDiffRendering.read(r)&&EP(p.lineRangeMapping);for(let _ of p.lineRangeMapping.innerChanges||[])if(p.lineRangeMapping.original.contains(_.originalRange.startLineNumber)&&u.push({range:_.originalRange,options:_.originalRange.isEmpty()&&d?eT:Wp}),p.lineRangeMapping.modified.contains(_.modifiedRange.startLineNumber)&&h.push({range:_.modifiedRange,options:_.modifiedRange.isEmpty()&&d&&!g?QE:D0}),g){let b=s.model.original.getValueInRange(_.originalRange);h.push({range:_.modifiedRange,options:{description:"deleted-text",before:{content:b,inlineClassName:"inline-deleted-text"},zIndex:1e5,showIfCollapsed:!0}})}}if(l)for(let p of l.changes){let g=p.original.toInclusiveRange();g&&u.push({range:g,options:c?Gb:Vfe});let _=p.modified.toInclusiveRange();_&&h.push({range:_,options:c?T0:zfe});for(let b of p.innerChanges||[])u.push({range:b.originalRange,options:Wp}),h.push({range:b.modifiedRange,options:D0})}let f=this._diffModel.read(r).activeMovedText.read(r);for(let p of a.movedTexts)u.push({range:p.lineRangeMapping.original.toInclusiveRange(),options:{description:"moved",blockClassName:"movedOriginal"+(p===f?" currentMove":""),blockPadding:[zw.movedCodeBlockPadding,0,zw.movedCodeBlockPadding,zw.movedCodeBlockPadding]}}),h.push({range:p.lineRangeMapping.modified.toInclusiveRange(),options:{description:"moved",blockClassName:"movedModified"+(p===f?" currentMove":""),blockPadding:[4,0,4,4]}});return{originalDecorations:u,modifiedDecorations:h}}),this._register(YE(this._editors.original,this._decorations.map(r=>r?.originalDecorations||[]))),this._register(YE(this._editors.modified,this._decorations.map(r=>r?.modifiedDecorations||[])))}}});var lj,oT,Xfe=k(()=>{tE();j();Oi();Yc();lj=class{resetSash(){this._sashRatio.set(void 0,void 0)}constructor(e,t){this._options=e,this.dimensions=t,this.sashLeft=lg(this,i=>{let o=this._sashRatio.read(i)??this._options.splitViewDefaultRatio.read(i);return this._computeSashLeft(o,i)},(i,o)=>{let r=this.dimensions.width.get();this._sashRatio.set(i/r,o)}),this._sashRatio=lt(this,void 0)}_computeSashLeft(e,t){let i=this.dimensions.width.read(t),o=Math.floor(this._options.splitViewDefaultRatio.read(t)*i),r=this._options.enableSplitViewResizing.read(t)?Math.floor(e*i):o,s=100;return i<=s*2?o:ri-s?i-s:r}},oT=class extends D{constructor(e,t,i,o,r,s){super(),this._domNode=e,this._dimensions=t,this._enabled=i,this._boundarySashes=o,this.sashLeft=r,this._resetSash=s,this._sash=this._register(new ed(this._domNode,{getVerticalSashTop:a=>0,getVerticalSashLeft:a=>this.sashLeft.get(),getVerticalSashHeight:a=>this._dimensions.height.get()},{orientation:0})),this._startSashPosition=void 0,this._register(this._sash.onDidStart(()=>{this._startSashPosition=this.sashLeft.get()})),this._register(this._sash.onDidChange(a=>{this.sashLeft.set(this._startSashPosition+(a.currentX-a.startX),void 0)})),this._register(this._sash.onDidEnd(()=>this._sash.layout())),this._register(this._sash.onDidReset(()=>this._resetSash())),this._register(He(a=>{let l=this._boundarySashes.read(a);l&&(this._sash.orthogonalEndSash=l.bottom)})),this._register(He(a=>{let l=this._enabled.read(a);this._sash.state=l?3:0,this.sashLeft.read(a),this._dimensions.height.read(a),this._sash.layout()}))}}});var cj,Qfe,sBe=k(()=>{ke();j();Oi();Nl();Rd();cj=class extends D{constructor(e,t,i){super(),this._editor=e,this._domNode=t,this.itemProvider=i,this.scrollTop=Kt(this,this._editor.onDidScrollChange,s=>this._editor.getScrollTop()),this.isScrollTopZero=this.scrollTop.map(s=>s===0),this.modelAttached=Kt(this,this._editor.onDidChangeModel,s=>this._editor.hasModel()),this.editorOnDidChangeViewZones=Wo("onDidChangeViewZones",this._editor.onDidChangeViewZones),this.editorOnDidContentSizeChange=Wo("onDidContentSizeChange",this._editor.onDidContentSizeChange),this.domNodeSizeChanged=Rh("domNodeSizeChanged"),this.views=new Map,this._domNode.className="gutter monaco-editor";let o=this._domNode.appendChild(Et("div.scroll-decoration",{role:"presentation",ariaHidden:"true",style:{width:"100%"}}).root),r=new ResizeObserver(()=>{xi(s=>{this.domNodeSizeChanged.trigger(s)})});r.observe(this._domNode),this._register(ge(()=>r.disconnect())),this._register(He(s=>{o.className=this.isScrollTopZero.read(s)?"":"scroll-decoration"})),this._register(He(s=>this.render(s)))}dispose(){super.dispose(),oo(this._domNode)}render(e){if(!this.modelAttached.read(e))return;this.domNodeSizeChanged.read(e),this.editorOnDidChangeViewZones.read(e),this.editorOnDidContentSizeChange.read(e);let t=this.scrollTop.read(e),i=this._editor.getVisibleRanges(),o=new Set(this.views.keys()),r=Wt.ofStartAndLength(0,this._domNode.clientHeight);if(!r.isEmpty)for(let s of i){let a=new ut(s.startLineNumber,s.endLineNumber+1),l=this.itemProvider.getIntersectingGutterItems(a,e);xi(c=>{for(let d of l){if(!d.range.intersect(a))continue;o.delete(d.id);let u=this.views.get(d.id);if(u)u.item.set(d,c);else{let g=document.createElement("div");this._domNode.appendChild(g);let _=lt("item",d),b=this.itemProvider.createView(_,g);u=new Qfe(_,b,g),this.views.set(d.id,u)}let h=d.range.startLineNumber<=this._editor.getModel().getLineCount()?this._editor.getTopForLineNumber(d.range.startLineNumber,!0)-t:this._editor.getBottomForLineNumber(d.range.startLineNumber-1,!1)-t,p=(d.range.endLineNumberExclusive===1?Math.max(h,this._editor.getTopForLineNumber(d.range.startLineNumber,!1)-t):Math.max(h,this._editor.getBottomForLineNumber(d.range.endLineNumberExclusive-1,!0)-t))-h;u.domNode.style.top=`${h}px`,u.domNode.style.height=`${p}px`,u.gutterItemView.layout(Wt.ofStartAndLength(h,p),r)}})}for(let s of o){let a=this.views.get(s);a.gutterItemView.dispose(),a.domNode.remove(),this.views.delete(s)}}},Qfe=class{constructor(e,t,i){this.item=e,this.gutterItemView=t,this.domNode=i}}});var rT,Jfe=k(()=>{Gr();rT=class extends Td{constructor(e){super(),this._getContext=e}runAction(e,t){let i=this._getContext();return super.runAction(e,i)}}});var TP,aBe=k(()=>{Fm();ib();TP=class extends AA{constructor(e){super(),this._textModel=e}getValueOfRange(e){return this._textModel.getValueInRange(e)}get length(){let e=this._textModel.getLineCount(),t=this._textModel.getLineLength(e);return new xa(e-1,t)}}});var lBe=k(()=>{});var dj,sT,cBe=k(()=>{Oh();ole();Gr();Qi();bn();Ie();j();lBe();pe();Ps();dj=class extends D{constructor(e,t,i={orientation:0}){super(),this.submenuActionViewItems=[],this.hasSecondaryActions=!1,this._onDidChangeDropdownVisibility=this._register(new G3),this.onDidChangeDropdownVisibility=this._onDidChangeDropdownVisibility.event,this.disposables=this._register(new H),i.hoverDelegate=i.hoverDelegate??this._register(Ef()),this.options=i,this.toggleMenuAction=this._register(new sT(()=>this.toggleMenuActionViewItem?.show(),i.toggleMenuTitle)),this.element=document.createElement("div"),this.element.className="monaco-toolbar",e.appendChild(this.element),this.actionBar=this._register(new Zo(this.element,{orientation:i.orientation,ariaLabel:i.ariaLabel,actionRunner:i.actionRunner,allowContextMenu:i.allowContextMenu,highlightToggledItems:i.highlightToggledItems,hoverDelegate:i.hoverDelegate,actionViewItemProvider:(o,r)=>{if(o.id===sT.ID)return this.toggleMenuActionViewItem=new uw(o,o.menuActions,t,{actionViewItemProvider:this.options.actionViewItemProvider,actionRunner:this.actionRunner,keybindingProvider:this.options.getKeyBinding,classNames:Oe.asClassNameArray(i.moreIcon??oe.toolBarMore),anchorAlignmentProvider:this.options.anchorAlignmentProvider,menuAsChild:!!this.options.renderDropdownAsChildElement,skipTelemetry:this.options.skipTelemetry,isMenu:!0,hoverDelegate:this.options.hoverDelegate}),this.toggleMenuActionViewItem.setActionContext(this.actionBar.context),this.disposables.add(this._onDidChangeDropdownVisibility.add(this.toggleMenuActionViewItem.onDidChangeVisibility)),this.toggleMenuActionViewItem;if(i.actionViewItemProvider){let s=i.actionViewItemProvider(o,r);if(s)return s}if(o instanceof bh){let s=new uw(o,o.actions,t,{actionViewItemProvider:this.options.actionViewItemProvider,actionRunner:this.actionRunner,keybindingProvider:this.options.getKeyBinding,classNames:o.class,anchorAlignmentProvider:this.options.anchorAlignmentProvider,menuAsChild:!!this.options.renderDropdownAsChildElement,skipTelemetry:this.options.skipTelemetry,hoverDelegate:this.options.hoverDelegate});return s.setActionContext(this.actionBar.context),this.submenuActionViewItems.push(s),this.disposables.add(this._onDidChangeDropdownVisibility.add(s.onDidChangeVisibility)),s}}}))}set actionRunner(e){this.actionBar.actionRunner=e}get actionRunner(){return this.actionBar.actionRunner}getElement(){return this.element}getItemAction(e){return this.actionBar.getAction(e)}setActions(e,t){this.clear();let i=e?e.slice(0):[];this.hasSecondaryActions=!!(t&&t.length>0),this.hasSecondaryActions&&t&&(this.toggleMenuAction.menuActions=t.slice(0),i.push(this.toggleMenuAction)),i.forEach(o=>{this.actionBar.push(o,{icon:this.options.icon??!0,label:this.options.label??!1,keybinding:this.getKeybindingLabel(o)})})}getKeybindingLabel(e){return this.options.getKeyBinding?.(e)?.getLabel()??void 0}clear(){this.submenuActionViewItems=[],this.disposables.clear(),this.actionBar.clear()}dispose(){this.clear(),this.disposables.dispose(),super.dispose()}},sT=class n extends rr{static{this.ID="toolbar.toggle.more"}constructor(e,t){t=t||m("moreActions","More Actions..."),super(n.ID,t,void 0,!0),this._menuActions=[],this.toggleDropdownMenu=e}async run(){this.toggleDropdownMenu()}get menuActions(){return this._menuActions}set menuActions(e){this._menuActions=e}}});var dBe,Of,R0,aT,DP=k(()=>{ke();pu();cBe();Gr();at();vle();je();Ie();Cl();j();pe();yb();an();Qde();Gi();it();Al();Pn();sc();dBe=function(n,e,t,i){var o=arguments.length,r=o<3?e:i===null?i=Object.getOwnPropertyDescriptor(e,t):i,s;if(typeof Reflect=="object"&&typeof Reflect.decorate=="function")r=Reflect.decorate(n,e,t,i);else for(var a=n.length-1;a>=0;a--)(s=n[a])&&(r=(o<3?s(r):o>3?s(e,t,r):s(e,t))||r);return o>3&&r&&Object.defineProperty(e,t,r),r},Of=function(n,e){return function(t,i){e(t,i,n)}},R0=class extends dj{constructor(e,t,i,o,r,s,a,l){super(e,r,{getKeyBinding:d=>s.lookupKeybinding(d.id)??void 0,...t,allowContextMenu:!0,skipTelemetry:typeof t?.telemetrySource=="string"}),this._options=t,this._menuService=i,this._contextKeyService=o,this._contextMenuService=r,this._keybindingService=s,this._commandService=a,this._sessionDisposables=this._store.add(new H);let c=t?.telemetrySource;c&&this._store.add(this.actionBar.onDidRun(d=>l.publicLog2("workbenchActionExecuted",{id:d.action.id,from:c})))}setActions(e,t=[],i){this._sessionDisposables.clear();let o=e.slice(),r=t.slice(),s=[],a=0,l=[],c=!1;if(this._options?.hiddenItemStrategy!==-1)for(let d=0;df?.id)),u=this._options.overflowBehavior.maxItems-d.size,h=0;for(let f=0;f=u&&(o[f]=void 0,l[f]=p))}}_ie(o),_ie(l),super.setActions(o,Gn.join(l,r)),(s.length>0||o.length>0)&&this._sessionDisposables.add(U(this.getElement(),"contextmenu",d=>{let u=new cs(Me(this.getElement()),d),h=this.getItemAction(u.target);if(!h)return;u.preventDefault(),u.stopPropagation();let f=[];if(h instanceof Es&&h.menuKeybinding)f.push(h.menuKeybinding);else if(!(h instanceof vf||h instanceof sT)){let g=!!this._keybindingService.lookupKeybinding(h.id);f.push(Xde(this._commandService,this._keybindingService,h.id,void 0,g))}if(s.length>0){let g=!1;if(a===1&&this._options?.hiddenItemStrategy===0){g=!0;for(let _=0;_this._menuService.resetHiddenStates(i)}))),p.length!==0&&this._contextMenuService.showContextMenu({getAnchor:()=>u,getActions:()=>p,menuId:this._options?.contextMenu,menuActionOptions:{renderShortTitle:!0,...this._options?.menuOptions},skipTelemetry:typeof this._options?.telemetrySource=="string",contextKeyService:this._contextKeyService})}))}};R0=dBe([Of(2,Yr),Of(3,Le),Of(4,sr),Of(5,_t),Of(6,$t),Of(7,Fn)],R0);aT=class extends R0{constructor(e,t,i,o,r,s,a,l,c){super(e,{resetMenu:t,...i},o,r,s,a,l,c),this._onDidChangeMenuItems=this._store.add(new A),this.onDidChangeMenuItems=this._onDidChangeMenuItems.event;let d=this._store.add(o.createMenu(t,r,{emitEventsForSubmenuChanges:!0})),u=()=>{let h=[],f=[];fw(d,i?.menuOptions,{primary:h,secondary:f},i?.toolbarOptions?.primaryGroup,i?.toolbarOptions?.shouldInlineSubmenu,i?.toolbarOptions?.useSeparatorsInPrimaryActions),e.classList.toggle("has-no-actions",h.length===0&&f.length===0),super.setActions(h,f)};this._store.add(d.onDidChange(()=>{u(),this._onDidChangeMenuItems.fire(this)})),u()}setActions(){throw new Nt("This toolbar is populated from a menu.")}};aT=dBe([Of(3,Yr),Of(4,Le),Of(5,sr),Of(6,_t),Of(7,$t),Of(8,Fn)],aT)});var uBe,hj,epe,uj,fj,pj,tpe,hBe=k(()=>{ke();j();Oi();Yc();Xfe();zh();sBe();Jfe();Nl();Rd();we();Fm();Bm();aBe();DP();an();it();db();Fe();uBe=function(n,e,t,i){var o=arguments.length,r=o<3?e:i===null?i=Object.getOwnPropertyDescriptor(e,t):i,s;if(typeof Reflect=="object"&&typeof Reflect.decorate=="function")r=Reflect.decorate(n,e,t,i);else for(var a=n.length-1;a>=0;a--)(s=n[a])&&(r=(o<3?s(r):o>3?s(e,t,r):s(e,t))||r);return o>3&&r&&Object.defineProperty(e,t,r),r},hj=function(n,e){return function(t,i){e(t,i,n)}},epe=[],uj=35,fj=class extends D{constructor(e,t,i,o,r,s,a,l,c){super(),this._diffModel=t,this._editors=i,this._options=o,this._sashLayout=r,this._boundarySashes=s,this._instantiationService=a,this._contextKeyService=l,this._menuService=c,this._menu=this._register(this._menuService.createMenu(Te.DiffEditorHunkToolbar,this._contextKeyService)),this._actions=Kt(this,this._menu.onDidChange,()=>this._menu.getActions()),this._hasActions=this._actions.map(d=>d.length>0),this._showSash=Pe(this,d=>this._options.renderSideBySide.read(d)&&this._hasActions.read(d)),this.width=Pe(this,d=>this._hasActions.read(d)?uj:0),this.elements=Et("div.gutter@gutter",{style:{position:"absolute",height:"100%",width:uj+"px"}},[]),this._currentDiff=Pe(this,d=>{let u=this._diffModel.read(d);if(!u)return;let h=u.diff.read(d)?.mappings,f=this._editors.modifiedCursor.read(d);if(f)return h?.find(p=>p.lineRangeMapping.modified.contains(f.lineNumber))}),this._selectedDiffs=Pe(this,d=>{let h=this._diffModel.read(d)?.diff.read(d);if(!h)return epe;let f=this._editors.modifiedSelections.read(d);if(f.every(b=>b.isEmpty()))return epe;let p=new yh(f.map(b=>ut.fromRangeInclusive(b))),_=h.mappings.filter(b=>b.lineRangeMapping.innerChanges&&p.intersects(b.lineRangeMapping.modified)).map(b=>({mapping:b,rangeMappings:b.lineRangeMapping.innerChanges.filter(v=>f.some(x=>S.areIntersecting(v.modifiedRange,x)))}));return _.length===0||_.every(b=>b.rangeMappings.length===0)?epe:_}),this._register(j8e(e,this.elements.root)),this._register(U(this.elements.root,"click",()=>{this._editors.modified.focus()})),this._register(Gd(this.elements.root,{display:this._hasActions.map(d=>d?"block":"none")})),Sr(this,d=>this._showSash.read(d)?new oT(e,this._sashLayout.dimensions,this._options.enableSplitViewResizing,this._boundarySashes,lg(this,h=>this._sashLayout.sashLeft.read(h)-uj,(h,f)=>this._sashLayout.sashLeft.set(h+uj,f)),()=>this._sashLayout.resetSash()):void 0).recomputeInitiallyAndOnChange(this._store),this._register(new cj(this._editors.modified,this.elements.root,{getIntersectingGutterItems:(d,u)=>{let h=this._diffModel.read(u);if(!h)return[];let f=h.diff.read(u);if(!f)return[];let p=this._selectedDiffs.read(u);if(p.length>0){let _=Rl.fromRangeMappings(p.flatMap(b=>b.rangeMappings));return[new pj(_,!0,Te.DiffEditorSelectionToolbar,void 0,h.model.original.uri,h.model.modified.uri)]}let g=this._currentDiff.read(u);return f.mappings.map(_=>new pj(_.lineRangeMapping.withInnerChangesFromLineRanges(),_.lineRangeMapping===g?.lineRangeMapping,Te.DiffEditorHunkToolbar,void 0,h.model.original.uri,h.model.modified.uri))},createView:(d,u)=>this._instantiationService.createInstance(tpe,d,u,this)})),this._register(U(this.elements.gutter,re.MOUSE_WHEEL,d=>{this._editors.modified.getOption(104).handleMouseWheel&&this._editors.modified.delegateScrollFromMouseWheelEvent(d)},{passive:!1}))}computeStagedValue(e){let t=e.innerChanges??[],i=new TP(this._editors.modifiedModel.get()),o=new TP(this._editors.original.getModel());return new Fx(t.map(a=>a.toTextEdit(i))).apply(o)}layout(e){this.elements.gutter.style.left=e+"px"}};fj=uBe([hj(6,he),hj(7,Le),hj(8,Yr)],fj);pj=class{constructor(e,t,i,o,r,s){this.mapping=e,this.showAlways=t,this.menuId=i,this.rangeOverride=o,this.originalUri=r,this.modifiedUri=s}get id(){return this.mapping.modified.toString()}get range(){return this.rangeOverride??this.mapping.modified}},tpe=class extends D{constructor(e,t,i,o){super(),this._item=e,this._elements=Et("div.gutterItem",{style:{height:"20px",width:"34px"}},[Et("div.background@background",{},[]),Et("div.buttons@buttons",{},[])]),this._showAlways=this._item.map(this,s=>s.showAlways),this._menuId=this._item.map(this,s=>s.menuId),this._isSmall=lt(this,!1),this._lastItemRange=void 0,this._lastViewRange=void 0;let r=this._register(o.createInstance(Gm,"element",!0,{position:{hoverPosition:1}}));this._register(Kb(t,this._elements.root)),this._register(He(s=>{let a=this._showAlways.read(s);this._elements.root.classList.toggle("noTransition",!0),this._elements.root.classList.toggle("showAlways",a),setTimeout(()=>{this._elements.root.classList.toggle("noTransition",!1)},0)})),this._register(To((s,a)=>{this._elements.buttons.replaceChildren();let l=a.add(o.createInstance(aT,this._elements.buttons,this._menuId.read(s),{orientation:1,hoverDelegate:r,toolbarOptions:{primaryGroup:c=>c.startsWith("primary")},overflowBehavior:{maxItems:this._isSmall.read(s)?1:3},hiddenItemStrategy:0,actionRunner:new rT(()=>{let c=this._item.get(),d=c.mapping;return{mapping:d,originalWithModifiedChanges:i.computeStagedValue(d),originalUri:c.originalUri,modifiedUri:c.modifiedUri}}),menuOptions:{shouldForwardArgs:!0}}));a.add(l.onDidChangeMenuItems(()=>{this._lastItemRange&&this.layout(this._lastItemRange,this._lastViewRange)}))}))}layout(e,t){this._lastItemRange=e,this._lastViewRange=t;let i=this._elements.buttons.clientHeight;this._isSmall.set(this._item.get().mapping.original.startLineNumber===1&&e.length<30,void 0),i=this._elements.buttons.clientHeight;let o=e.length/2-i/2,r=i,s=e.start+o,a=Wt.tryCreate(r,t.endExclusive-r-i),l=Wt.tryCreate(e.start+r,e.endExclusive-i-r);l&&a&&l.start({deltas:[],didChange:!1}),handleChange:(t,i)=>{if(t.didChange(n)){let o=t.change;o!==void 0&&i.deltas.push(o),i.didChange=!0}return!0}},(t,i)=>{let o=n.read(t);i.didChange&&e(o,i.deltas)})}function fBe(n,e){let t=new H,i=mj(n,(o,r)=>{t.clear(),e(o,r,t)});return{dispose(){i.dispose(),t.dispose()}}}var ipe,Zb=k(()=>{rg();j();Oi();Lf();Yc();Ui();ipe=class n extends D{static{this._map=new Map}static get(e){let t=n._map.get(e);if(!t){t=new n(e),n._map.set(e,t);let i=e.onDidDispose(()=>{let o=n._map.get(e);o&&(n._map.delete(e),o.dispose(),i.dispose())})}return t}_beginUpdate(){this._updateCounter++,this._updateCounter===1&&(this._currentTransaction=new sg(()=>{}))}_endUpdate(){if(this._updateCounter--,this._updateCounter===0){let e=this._currentTransaction;this._currentTransaction=void 0,e.finish()}}constructor(e){super(),this.editor=e,this._updateCounter=0,this._currentTransaction=void 0,this._model=lt(this,this.editor.getModel()),this.model=this._model,this.isReadonly=Kt(this,this.editor.onDidChangeConfiguration,()=>this.editor.getOption(92)),this._versionId=_I({owner:this,lazy:!0},this.editor.getModel()?.getVersionId()??null),this.versionId=this._versionId,this._selections=_I({owner:this,equalsFn:RM(yC(Se.selectionsEqual)),lazy:!0},this.editor.getSelections()??null),this.selections=this._selections,this.isFocused=Kt(this,t=>{let i=this.editor.onDidFocusEditorWidget(t),o=this.editor.onDidBlurEditorWidget(t);return{dispose(){i.dispose(),o.dispose()}}},()=>this.editor.hasWidgetFocus()),this.value=lg(this,t=>(this.versionId.read(t),this.model.read(t)?.getValue()??""),(t,i)=>{let o=this.model.get();o!==null&&t!==o.getValue()&&o.setValue(t)}),this.valueIsEmpty=Pe(this,t=>(this.versionId.read(t),this.editor.getModel()?.getValueLength()===0)),this.cursorSelection=As({owner:this,equalsFn:RM(Se.selectionsEqual)},t=>this.selections.read(t)?.[0]??null),this.onDidType=Rh(this),this.scrollTop=Kt(this.editor.onDidScrollChange,()=>this.editor.getScrollTop()),this.scrollLeft=Kt(this.editor.onDidScrollChange,()=>this.editor.getScrollLeft()),this.layoutInfo=Kt(this.editor.onDidLayoutChange,()=>this.editor.getLayoutInfo()),this.layoutInfoContentLeft=this.layoutInfo.map(t=>t.contentLeft),this.layoutInfoDecorationsLeft=this.layoutInfo.map(t=>t.decorationsLeft),this.contentWidth=Kt(this.editor.onDidContentSizeChange,()=>this.editor.getContentWidth()),this._overlayWidgetCounter=0,this._register(this.editor.onBeginUpdate(()=>this._beginUpdate())),this._register(this.editor.onEndUpdate(()=>this._endUpdate())),this._register(this.editor.onDidChangeModel(()=>{this._beginUpdate();try{this._model.set(this.editor.getModel(),this._currentTransaction),this._forceUpdate()}finally{this._endUpdate()}})),this._register(this.editor.onDidType(t=>{this._beginUpdate();try{this._forceUpdate(),this.onDidType.trigger(this._currentTransaction,t)}finally{this._endUpdate()}})),this._register(this.editor.onDidChangeModelContent(t=>{this._beginUpdate();try{this._versionId.set(this.editor.getModel()?.getVersionId()??null,this._currentTransaction,t),this._forceUpdate()}finally{this._endUpdate()}})),this._register(this.editor.onDidChangeCursorSelection(t=>{this._beginUpdate();try{this._selections.set(this.editor.getSelections(),this._currentTransaction,t),this._forceUpdate()}finally{this._endUpdate()}}))}forceUpdate(e){this._beginUpdate();try{return this._forceUpdate(),e?e(this._currentTransaction):void 0}finally{this._endUpdate()}}_forceUpdate(){this._beginUpdate();try{this._model.set(this.editor.getModel(),this._currentTransaction),this._versionId.set(this.editor.getModel()?.getVersionId()??null,this._currentTransaction,void 0),this._selections.set(this.editor.getSelections(),this._currentTransaction,void 0)}finally{this._endUpdate()}}getOption(e){return Kt(this,t=>this.editor.onDidChangeConfiguration(i=>{i.hasChanged(e)&&t(void 0)}),()=>this.editor.getOption(e))}setDecorations(e){let t=new H,i=this.editor.createDecorationsCollection();return t.add(cg({owner:this,debugName:()=>`Apply decorations from ${e.debugName}`},o=>{let r=e.read(o);i.set(r)})),t.add({dispose:()=>{i.clear()}}),t}createOverlayWidget(e){let t="observableOverlayWidget"+this._overlayWidgetCounter++,i={getDomNode:()=>e.domNode,getPosition:()=>e.position.get(),getId:()=>t,allowEditorOverflow:e.allowEditorOverflow,getMinContentWidthInPx:()=>e.minContentWidthInPx.get()};this.editor.addOverlayWidget(i);let o=He(r=>{e.position.read(r),e.minContentWidthInPx.read(r),this.editor.layoutOverlayWidget(i)});return ge(()=>{o.dispose(),this.editor.removeOverlayWidget(i)})}}});var Lht,Iht,gj,lT,_j,bj,npe=k(()=>{ke();ub();Qi();Pl();j();Oi();Yc();bn();yi();Zb();zh();Nl();qe();we();Ji();pe();Fe();Lht=function(n,e,t,i){var o=arguments.length,r=o<3?e:i===null?i=Object.getOwnPropertyDescriptor(e,t):i,s;if(typeof Reflect=="object"&&typeof Reflect.decorate=="function")r=Reflect.decorate(n,e,t,i);else for(var a=n.length-1;a>=0;a--)(s=n[a])&&(r=(o<3?s(r):o>3?s(e,t,r):s(e,t))||r);return o>3&&r&&Object.defineProperty(e,t,r),r},Iht=function(n,e){return function(t,i){e(t,i,n)}},lT=class extends D{static{gj=this}static{this._breadcrumbsSourceFactory=lt(gj,()=>({dispose(){},getBreadcrumbItems(e,t){return[]}}))}static setBreadcrumbsSourceFactory(e){this._breadcrumbsSourceFactory.set(e,void 0)}get isUpdatingHiddenAreas(){return this._isUpdatingHiddenAreas}constructor(e,t,i,o){super(),this._editors=e,this._diffModel=t,this._options=i,this._instantiationService=o,this._modifiedOutlineSource=Sr(this,l=>{let c=this._editors.modifiedModel.read(l),d=gj._breadcrumbsSourceFactory.read(l);return!c||!d?void 0:d(c,this._instantiationService)}),this._isUpdatingHiddenAreas=!1,this._register(this._editors.original.onDidChangeCursorPosition(l=>{if(l.reason===1)return;let c=this._diffModel.get();xi(d=>{for(let u of this._editors.original.getSelections()||[])c?.ensureOriginalLineIsVisible(u.getStartPosition().lineNumber,0,d),c?.ensureOriginalLineIsVisible(u.getEndPosition().lineNumber,0,d)})})),this._register(this._editors.modified.onDidChangeCursorPosition(l=>{if(l.reason===1)return;let c=this._diffModel.get();xi(d=>{for(let u of this._editors.modified.getSelections()||[])c?.ensureModifiedLineIsVisible(u.getStartPosition().lineNumber,0,d),c?.ensureModifiedLineIsVisible(u.getEndPosition().lineNumber,0,d)})}));let r=this._diffModel.map((l,c)=>{let d=l?.unchangedRegions.read(c)??[];return d.length===1&&d[0].modifiedLineNumber===1&&d[0].lineCount===this._editors.modifiedModel.read(c)?.getLineCount()?[]:d});this.viewZones=hc(this,(l,c)=>{let d=this._modifiedOutlineSource.read(l);if(!d)return{origViewZones:[],modViewZones:[]};let u=[],h=[],f=this._options.renderSideBySide.read(l),p=this._options.compactMode.read(l),g=r.read(l);for(let _=0;_b.getHiddenOriginalRange(w).startLineNumber-1),x=new Vg(v,12);u.push(x),c.add(new _j(this._editors.original,x,b,!f))}{let v=Pe(this,w=>b.getHiddenModifiedRange(w).startLineNumber-1),x=new Vg(v,12);h.push(x),c.add(new _j(this._editors.modified,x,b))}}else{{let v=Pe(this,w=>b.getHiddenOriginalRange(w).startLineNumber-1),x=new Vg(v,24);u.push(x),c.add(new bj(this._editors.original,x,b,b.originalUnchangedRange,!f,d,w=>this._diffModel.get().ensureModifiedLineIsVisible(w,2,void 0),this._options))}{let v=Pe(this,w=>b.getHiddenModifiedRange(w).startLineNumber-1),x=new Vg(v,24);h.push(x),c.add(new bj(this._editors.modified,x,b,b.modifiedUnchangedRange,!1,d,w=>this._diffModel.get().ensureModifiedLineIsVisible(w,2,void 0),this._options))}}}return{origViewZones:u,modViewZones:h}});let s={description:"unchanged lines",className:"diff-unchanged-lines",isWholeLine:!0},a={description:"Fold Unchanged",glyphMarginHoverMessage:new Eo(void 0,{isTrusted:!0,supportThemeIcons:!0}).appendMarkdown(m("foldUnchanged","Fold Unchanged Region")),glyphMarginClassName:"fold-unchanged "+Oe.asClassName(oe.fold),zIndex:10001};this._register(YE(this._editors.original,Pe(this,l=>{let c=r.read(l),d=c.map(u=>({range:u.originalUnchangedRange.toInclusiveRange(),options:s}));for(let u of c)u.shouldHideControls(l)&&d.push({range:S.fromPositions(new P(u.originalLineNumber,1)),options:a});return d}))),this._register(YE(this._editors.modified,Pe(this,l=>{let c=r.read(l),d=c.map(u=>({range:u.modifiedUnchangedRange.toInclusiveRange(),options:s}));for(let u of c)u.shouldHideControls(l)&&d.push({range:ut.ofLength(u.modifiedLineNumber,1).toInclusiveRange(),options:a});return d}))),this._register(He(l=>{let c=r.read(l);this._isUpdatingHiddenAreas=!0;try{this._editors.original.setHiddenAreas(c.map(d=>d.getHiddenOriginalRange(l).toInclusiveRange()).filter(xd)),this._editors.modified.setHiddenAreas(c.map(d=>d.getHiddenModifiedRange(l).toInclusiveRange()).filter(xd))}finally{this._isUpdatingHiddenAreas=!1}})),this._register(this._editors.modified.onMouseUp(l=>{if(!l.event.rightButton&&l.target.position&&l.target.element?.className.includes("fold-unchanged")){let c=l.target.position.lineNumber,d=this._diffModel.get();if(!d)return;let u=d.unchangedRegions.get().find(h=>h.modifiedUnchangedRange.includes(c));if(!u)return;u.collapseAll(void 0),l.event.stopPropagation(),l.event.preventDefault()}})),this._register(this._editors.original.onMouseUp(l=>{if(!l.event.rightButton&&l.target.position&&l.target.element?.className.includes("fold-unchanged")){let c=l.target.position.lineNumber,d=this._diffModel.get();if(!d)return;let u=d.unchangedRegions.get().find(h=>h.originalUnchangedRange.includes(c));if(!u)return;u.collapseAll(void 0),l.event.stopPropagation(),l.event.preventDefault()}}))}};lT=gj=Lht([Iht(3,he)],lT);_j=class extends I0{constructor(e,t,i,o=!1){let r=Et("div.diff-hidden-lines-widget");super(e,t,r.root),this._unchangedRegion=i,this._hide=o,this._nodes=Et("div.diff-hidden-lines-compact",[Et("div.line-left",[]),Et("div.text@text",[]),Et("div.line-right",[])]),r.root.appendChild(this._nodes.root),this._hide&&this._nodes.root.replaceChildren(),this._register(He(s=>{if(!this._hide){let a=this._unchangedRegion.getHiddenModifiedRange(s).length,l=m("hiddenLines","{0} hidden lines",a);this._nodes.text.innerText=l}}))}},bj=class extends I0{constructor(e,t,i,o,r,s,a,l){let c=Et("div.diff-hidden-lines-widget");super(e,t,c.root),this._editor=e,this._unchangedRegion=i,this._unchangedRegionRange=o,this._hide=r,this._modifiedOutlineSource=s,this._revealModifiedHiddenLine=a,this._options=l,this._nodes=Et("div.diff-hidden-lines",[Et("div.top@top",{title:m("diff.hiddenLines.top","Click or drag to show more above")}),Et("div.center@content",{style:{display:"flex"}},[Et("div@first",{style:{display:"flex",justifyContent:"center",alignItems:"center",flexShrink:"0"}},[J("a",{title:m("showUnchangedRegion","Show Unchanged Region"),role:"button",onclick:()=>{this._unchangedRegion.showAll(void 0)}},...Iu("$(unfold)"))]),Et("div@others",{style:{display:"flex",justifyContent:"center",alignItems:"center"}})]),Et("div.bottom@bottom",{title:m("diff.bottom","Click or drag to show more below"),role:"button"})]),c.root.appendChild(this._nodes.root),this._hide?oo(this._nodes.first):this._register(Gd(this._nodes.first,{width:bs(this._editor).layoutInfoContentLeft})),this._register(He(u=>{let h=this._unchangedRegion.visibleLineCountTop.read(u)+this._unchangedRegion.visibleLineCountBottom.read(u)===this._unchangedRegion.lineCount;this._nodes.bottom.classList.toggle("canMoveTop",!h),this._nodes.bottom.classList.toggle("canMoveBottom",this._unchangedRegion.visibleLineCountBottom.read(u)>0),this._nodes.top.classList.toggle("canMoveTop",this._unchangedRegion.visibleLineCountTop.read(u)>0),this._nodes.top.classList.toggle("canMoveBottom",!h);let f=this._unchangedRegion.isDragged.read(u),p=this._editor.getDomNode();p&&(p.classList.toggle("draggingUnchangedRegion",!!f),f==="top"?(p.classList.toggle("canMoveTop",this._unchangedRegion.visibleLineCountTop.read(u)>0),p.classList.toggle("canMoveBottom",!h)):f==="bottom"?(p.classList.toggle("canMoveTop",!h),p.classList.toggle("canMoveBottom",this._unchangedRegion.visibleLineCountBottom.read(u)>0)):(p.classList.toggle("canMoveTop",!1),p.classList.toggle("canMoveBottom",!1)))}));let d=this._editor;this._register(U(this._nodes.top,"mousedown",u=>{if(u.button!==0)return;this._nodes.top.classList.toggle("dragging",!0),this._nodes.root.classList.toggle("dragging",!0),u.preventDefault();let h=u.clientY,f=!1,p=this._unchangedRegion.visibleLineCountTop.get();this._unchangedRegion.isDragged.set("top",void 0);let g=Me(this._nodes.top),_=U(g,"mousemove",v=>{let w=v.clientY-h;f=f||Math.abs(w)>2;let y=Math.round(w/d.getOption(67)),C=Math.max(0,Math.min(p+y,this._unchangedRegion.getMaxVisibleLineCountTop()));this._unchangedRegion.visibleLineCountTop.set(C,void 0)}),b=U(g,"mouseup",v=>{f||this._unchangedRegion.showMoreAbove(this._options.hideUnchangedRegionsRevealLineCount.get(),void 0),this._nodes.top.classList.toggle("dragging",!1),this._nodes.root.classList.toggle("dragging",!1),this._unchangedRegion.isDragged.set(void 0,void 0),_.dispose(),b.dispose()})})),this._register(U(this._nodes.bottom,"mousedown",u=>{if(u.button!==0)return;this._nodes.bottom.classList.toggle("dragging",!0),this._nodes.root.classList.toggle("dragging",!0),u.preventDefault();let h=u.clientY,f=!1,p=this._unchangedRegion.visibleLineCountBottom.get();this._unchangedRegion.isDragged.set("bottom",void 0);let g=Me(this._nodes.bottom),_=U(g,"mousemove",v=>{let w=v.clientY-h;f=f||Math.abs(w)>2;let y=Math.round(w/d.getOption(67)),C=Math.max(0,Math.min(p-y,this._unchangedRegion.getMaxVisibleLineCountBottom())),L=this._unchangedRegionRange.endLineNumberExclusive>d.getModel().getLineCount()?d.getContentHeight():d.getTopForLineNumber(this._unchangedRegionRange.endLineNumberExclusive);this._unchangedRegion.visibleLineCountBottom.set(C,void 0);let E=this._unchangedRegionRange.endLineNumberExclusive>d.getModel().getLineCount()?d.getContentHeight():d.getTopForLineNumber(this._unchangedRegionRange.endLineNumberExclusive);d.setScrollTop(d.getScrollTop()+(E-L))}),b=U(g,"mouseup",v=>{if(this._unchangedRegion.isDragged.set(void 0,void 0),!f){let x=d.getTopForLineNumber(this._unchangedRegionRange.endLineNumberExclusive);this._unchangedRegion.showMoreBelow(this._options.hideUnchangedRegionsRevealLineCount.get(),void 0);let w=d.getTopForLineNumber(this._unchangedRegionRange.endLineNumberExclusive);d.setScrollTop(d.getScrollTop()+(w-x))}this._nodes.bottom.classList.toggle("dragging",!1),this._nodes.root.classList.toggle("dragging",!1),_.dispose(),b.dispose()})})),this._register(He(u=>{let h=[];if(!this._hide){let f=i.getHiddenModifiedRange(u).length,p=m("hiddenLines","{0} hidden lines",f),g=J("span",{title:m("diff.hiddenLines.expandAll","Double click to unfold")},p);g.addEventListener("dblclick",v=>{v.button===0&&(v.preventDefault(),this._unchangedRegion.showAll(void 0))}),h.push(g);let _=this._unchangedRegion.getHiddenModifiedRange(u),b=this._modifiedOutlineSource.getBreadcrumbItems(_,u);if(b.length>0){h.push(J("span",void 0,"\xA0\xA0|\xA0\xA0"));for(let v=0;v{this._revealModifiedHiddenLine(x.startLineNumber)}}}}oo(this._nodes.others,...h)}))}}});var Eht,Tht,Hp,A0,ope=k(()=>{ke();Kr();Z9();j();Oi();zh();qe();Khe();Wn();Yi();Eht=function(n,e,t,i){var o=arguments.length,r=o<3?e:i===null?i=Object.getOwnPropertyDescriptor(e,t):i,s;if(typeof Reflect=="object"&&typeof Reflect.decorate=="function")r=Reflect.decorate(n,e,t,i);else for(var a=n.length-1;a>=0;a--)(s=n[a])&&(r=(o<3?s(r):o>3?s(e,t,r):s(e,t))||r);return o>3&&r&&Object.defineProperty(e,t,r),r},Tht=function(n,e){return function(t,i){e(t,i,n)}},A0=class extends D{static{Hp=this}static{this.ONE_OVERVIEW_WIDTH=15}static{this.ENTIRE_DIFF_OVERVIEW_WIDTH=this.ONE_OVERVIEW_WIDTH*2}constructor(e,t,i,o,r,s,a){super(),this._editors=e,this._rootElement=t,this._diffModel=i,this._rootWidth=o,this._rootHeight=r,this._modifiedEditorLayoutInfo=s,this._themeService=a,this.width=Hp.ENTIRE_DIFF_OVERVIEW_WIDTH;let l=Kt(this._themeService.onDidColorThemeChange,()=>this._themeService.getColorTheme()),c=Pe(h=>{let f=l.read(h),p=f.getColor(_Ae)||(f.getColor(mAe)||M9).transparent(2),g=f.getColor(bAe)||(f.getColor(gAe)||P9).transparent(2);return{insertColor:p,removeColor:g}}),d=Pt(document.createElement("div"));d.setClassName("diffViewport"),d.setPosition("absolute");let u=Et("div.diffOverview",{style:{position:"absolute",top:"0px",width:Hp.ENTIRE_DIFF_OVERVIEW_WIDTH+"px"}}).root;this._register(Kb(u,d.domNode)),this._register(gi(u,re.POINTER_DOWN,h=>{this._editors.modified.delegateVerticalScrollbarPointerDown(h)})),this._register(U(u,re.MOUSE_WHEEL,h=>{this._editors.modified.delegateScrollFromMouseWheelEvent(h)},{passive:!1})),this._register(Kb(this._rootElement,u)),this._register(To((h,f)=>{let p=this._diffModel.read(h),g=this._editors.original.createOverviewRuler("original diffOverviewRuler");g&&(f.add(g),f.add(Kb(u,g.getDomNode())));let _=this._editors.modified.createOverviewRuler("modified diffOverviewRuler");if(_&&(f.add(_),f.add(Kb(u,_.getDomNode()))),!g||!_)return;let b=Wo("viewZoneChanged",this._editors.original.onDidChangeViewZones),v=Wo("viewZoneChanged",this._editors.modified.onDidChangeViewZones),x=Wo("hiddenRangesChanged",this._editors.original.onDidChangeHiddenAreas),w=Wo("hiddenRangesChanged",this._editors.modified.onDidChangeHiddenAreas);f.add(He(y=>{b.read(y),v.read(y),x.read(y),w.read(y);let C=c.read(y),L=p?.diff.read(y)?.mappings;function E(F,q,te){let $=te._getViewModel();return $?F.filter(z=>z.length>0).map(z=>{let ae=$.coordinatesConverter.convertModelPositionToViewPosition(new P(z.startLineNumber,1)),X=$.coordinatesConverter.convertModelPositionToViewPosition(new P(z.endLineNumberExclusive,1)),ue=X.lineNumber-ae.lineNumber;return new mP(ae.lineNumber,X.lineNumber,ue,q.toString())}):[]}let N=E((L||[]).map(F=>F.lineRangeMapping.original),C.removeColor,this._editors.original),M=E((L||[]).map(F=>F.lineRangeMapping.modified),C.insertColor,this._editors.modified);g?.setZones(N),_?.setZones(M)})),f.add(He(y=>{let C=this._rootHeight.read(y),L=this._rootWidth.read(y),E=this._modifiedEditorLayoutInfo.read(y);if(E){let N=Hp.ENTIRE_DIFF_OVERVIEW_WIDTH-2*Hp.ONE_OVERVIEW_WIDTH;g.setLayout({top:0,height:C,right:N+Hp.ONE_OVERVIEW_WIDTH,width:Hp.ONE_OVERVIEW_WIDTH}),_.setLayout({top:0,height:C,right:0,width:Hp.ONE_OVERVIEW_WIDTH});let M=this._editors.modifiedScrollTop.read(y),F=this._editors.modifiedScrollHeight.read(y),q=this._editors.modified.getOption(104),te=new Xx(q.verticalHasArrows?q.arrowSize:0,q.verticalScrollbarSize,0,E.height,F,M);d.setTop(te.getSliderPosition()),d.setHeight(te.getSliderSize())}else d.setTop(0),d.setHeight(0);u.style.height=C+"px",u.style.left=L-Hp.ENTIRE_DIFF_OVERVIEW_WIDTH+"px",d.setWidth(Hp.ENTIRE_DIFF_OVERVIEW_WIDTH)}))}))}};A0=Hp=Eht([Tht(6,Vi)],A0)});var rpe,vj,xj,pBe=k(()=>{ke();ub();Qi();j();Oi();Nl();we();Bm();Zr();pe();rpe=[],vj=class extends D{constructor(e,t,i,o){super(),this._editors=e,this._diffModel=t,this._options=i,this._widget=o,this._selectedDiffs=Pe(this,r=>{let a=this._diffModel.read(r)?.diff.read(r);if(!a)return rpe;let l=this._editors.modifiedSelections.read(r);if(l.every(h=>h.isEmpty()))return rpe;let c=new yh(l.map(h=>ut.fromRangeInclusive(h))),u=a.mappings.filter(h=>h.lineRangeMapping.innerChanges&&c.intersects(h.lineRangeMapping.modified)).map(h=>({mapping:h,rangeMappings:h.lineRangeMapping.innerChanges.filter(f=>l.some(p=>S.areIntersecting(f.modifiedRange,p)))}));return u.length===0||u.every(h=>h.rangeMappings.length===0)?rpe:u}),this._register(To((r,s)=>{if(!this._options.shouldRenderOldRevertArrows.read(r))return;let a=this._diffModel.read(r),l=a?.diff.read(r);if(!a||!l||a.movedTextToCompare.read(r))return;let c=[],d=this._selectedDiffs.read(r),u=new Set(d.map(h=>h.mapping));if(d.length>0){let h=this._editors.modifiedSelections.read(r),f=s.add(new xj(h[h.length-1].positionLineNumber,this._widget,d.flatMap(p=>p.rangeMappings),!0));this._editors.modified.addGlyphMarginWidget(f),c.push(f)}for(let h of l.mappings)if(!u.has(h)&&!h.lineRangeMapping.modified.isEmpty&&h.lineRangeMapping.innerChanges){let f=s.add(new xj(h.lineRangeMapping.modified.startLineNumber,this._widget,h.lineRangeMapping,!1));this._editors.modified.addGlyphMarginWidget(f),c.push(f)}s.add(ge(()=>{for(let h of c)this._editors.modified.removeGlyphMarginWidget(h)}))}))}},xj=class n extends D{static{this.counter=0}getId(){return this._id}constructor(e,t,i,o){super(),this._lineNumber=e,this._widget=t,this._diffs=i,this._revertSelection=o,this._id=`revertButton${n.counter++}`,this._domNode=Et("div.revertButton",{title:this._revertSelection?m("revertSelectedChanges","Revert Selected Changes"):m("revertChange","Revert Change")},[Zm(oe.arrowRight)]).root,this._register(U(this._domNode,re.MOUSE_DOWN,r=>{r.button!==2&&(r.stopPropagation(),r.preventDefault())})),this._register(U(this._domNode,re.MOUSE_UP,r=>{r.stopPropagation(),r.preventDefault()})),this._register(U(this._domNode,re.CLICK,r=>{this._diffs instanceof ya?this._widget.revert(this._diffs):this._widget.revertRangeMappings(this._diffs),r.stopPropagation(),r.preventDefault()}))}getDomNode(){return this._domNode}getPosition(){return{lane:tl.Right,range:{startColumn:1,startLineNumber:this._lineNumber,endColumn:1,endLineNumber:this._lineNumber},zIndex:10001}}}});function mBe(n,e,t){return RPe({debugName:()=>`Configuration Key "${n}"`},i=>t.onDidChangeConfiguration(o=>{o.affectsConfiguration(n)&&i(o)}),()=>t.getValue(n)??e)}function Vh(n,e,t){let i=n.bindTo(e);return cg({debugName:()=>`Set Context Key "${n.key}"`},o=>{i.set(t(o))})}var spe=k(()=>{Oi();FM()});var Dht,gBe,wj,_Be=k(()=>{Ie();j();Oi();Zb();ope();ir();qe();pe();Fe();Pn();Dht=function(n,e,t,i){var o=arguments.length,r=o<3?e:i===null?i=Object.getOwnPropertyDescriptor(e,t):i,s;if(typeof Reflect=="object"&&typeof Reflect.decorate=="function")r=Reflect.decorate(n,e,t,i);else for(var a=n.length-1;a>=0;a--)(s=n[a])&&(r=(o<3?s(r):o>3?s(e,t,r):s(e,t))||r);return o>3&&r&&Object.defineProperty(e,t,r),r},gBe=function(n,e){return function(t,i){e(t,i,n)}},wj=class extends D{get onDidContentSizeChange(){return this._onDidContentSizeChange.event}constructor(e,t,i,o,r,s,a){super(),this.originalEditorElement=e,this.modifiedEditorElement=t,this._options=i,this._argCodeEditorWidgetOptions=o,this._createInnerEditor=r,this._instantiationService=s,this._keybindingService=a,this.original=this._register(this._createLeftHandSideEditor(this._options.editorOptions.get(),this._argCodeEditorWidgetOptions.originalEditor||{})),this.modified=this._register(this._createRightHandSideEditor(this._options.editorOptions.get(),this._argCodeEditorWidgetOptions.modifiedEditor||{})),this._onDidContentSizeChange=this._register(new A),this.modifiedScrollTop=Kt(this,this.modified.onDidScrollChange,()=>this.modified.getScrollTop()),this.modifiedScrollHeight=Kt(this,this.modified.onDidScrollChange,()=>this.modified.getScrollHeight()),this.modifiedObs=bs(this.modified),this.originalObs=bs(this.original),this.modifiedModel=this.modifiedObs.model,this.modifiedSelections=Kt(this,this.modified.onDidChangeCursorSelection,()=>this.modified.getSelections()??[]),this.modifiedCursor=As({owner:this,equalsFn:P.equals},l=>this.modifiedSelections.read(l)[0]?.getPosition()??new P(1,1)),this.originalCursor=Kt(this,this.original.onDidChangeCursorPosition,()=>this.original.getPosition()??new P(1,1)),this._argCodeEditorWidgetOptions=null,this._register(gb({createEmptyChangeSummary:()=>({}),handleChange:(l,c)=>(l.didChange(i.editorOptions)&&Object.assign(c,l.change.changedOptions),!0)},(l,c)=>{i.editorOptions.read(l),this._options.renderSideBySide.read(l),this.modified.updateOptions(this._adjustOptionsForRightHandSide(l,c)),this.original.updateOptions(this._adjustOptionsForLeftHandSide(l,c))}))}_createLeftHandSideEditor(e,t){let i=this._adjustOptionsForLeftHandSide(void 0,e),o=this._constructInnerEditor(this._instantiationService,this.originalEditorElement,i,t);return o.setContextValue("isInDiffLeftEditor",!0),o}_createRightHandSideEditor(e,t){let i=this._adjustOptionsForRightHandSide(void 0,e),o=this._constructInnerEditor(this._instantiationService,this.modifiedEditorElement,i,t);return o.setContextValue("isInDiffRightEditor",!0),o}_constructInnerEditor(e,t,i,o){let r=this._createInnerEditor(e,t,i,o);return this._register(r.onDidContentSizeChange(s=>{let a=this.original.getContentWidth()+this.modified.getContentWidth()+A0.ENTIRE_DIFF_OVERVIEW_WIDTH,l=Math.max(this.modified.getContentHeight(),this.original.getContentHeight());this._onDidContentSizeChange.fire({contentHeight:l,contentWidth:a,contentHeightChanged:s.contentHeightChanged,contentWidthChanged:s.contentWidthChanged})})),r}_adjustOptionsForLeftHandSide(e,t){let i=this._adjustOptionsForSubEditor(t);return this._options.renderSideBySide.get()?(i.unicodeHighlight=this._options.editorOptions.get().unicodeHighlight||{},i.wordWrapOverride1=this._options.diffWordWrap.get()):(i.wordWrapOverride1="off",i.wordWrapOverride2="off",i.stickyScroll={enabled:!1},i.unicodeHighlight={nonBasicASCII:!1,ambiguousCharacters:!1,invisibleCharacters:!1}),i.glyphMargin=this._options.renderSideBySide.get(),t.originalAriaLabel&&(i.ariaLabel=t.originalAriaLabel),i.ariaLabel=this._updateAriaLabel(i.ariaLabel),i.readOnly=!this._options.originalEditable.get(),i.dropIntoEditor={enabled:!i.readOnly},i.extraEditorClassName="original-in-monaco-diff-editor",i}_adjustOptionsForRightHandSide(e,t){let i=this._adjustOptionsForSubEditor(t);return t.modifiedAriaLabel&&(i.ariaLabel=t.modifiedAriaLabel),i.ariaLabel=this._updateAriaLabel(i.ariaLabel),i.wordWrapOverride1=this._options.diffWordWrap.get(),i.revealHorizontalRightPadding=Oc.revealHorizontalRightPadding.defaultValue+A0.ENTIRE_DIFF_OVERVIEW_WIDTH,i.scrollbar.verticalHasArrows=!1,i.extraEditorClassName="modified-in-monaco-diff-editor",i}_adjustOptionsForSubEditor(e){let t={...e,dimension:{height:0,width:0}};return t.inDiffEditor=!0,t.automaticLayout=!1,t.scrollbar={...t.scrollbar||{}},t.folding=!1,t.codeLens=this._options.diffCodeLens.get(),t.fixedOverflowWidgets=!0,t.minimap={...t.minimap||{}},t.minimap.enabled=!1,this._options.hideUnchangedRegions.get()?t.stickyScroll={enabled:!1}:t.stickyScroll=this._options.editorOptions.get().stickyScroll,t}_updateAriaLabel(e){e||(e="");let t=m("diff-aria-navigation-tip"," use {0} to open the accessibility help.",this._keybindingService.lookupKeybinding("editor.action.accessibilityHelp")?.getAriaLabel());return this._options.accessibilityVerbose.get()?e+t:e?e.replaceAll(t,""):""}};wj=Dht([gBe(5,he),gBe(6,_t)],wj)});var yj,bBe=k(()=>{Ie();j();yj=class n extends D{constructor(){super(...arguments),this._id=++n.idCounter,this._onDidDispose=this._register(new A),this.onDidDispose=this._onDidDispose.event}static{this.idCounter=0}getId(){return this.getEditorType()+":v2:"+this._id}getVisibleColumnFromPosition(e){return this._targetEditor.getVisibleColumnFromPosition(e)}getPosition(){return this._targetEditor.getPosition()}setPosition(e,t="api"){this._targetEditor.setPosition(e,t)}revealLine(e,t=0){this._targetEditor.revealLine(e,t)}revealLineInCenter(e,t=0){this._targetEditor.revealLineInCenter(e,t)}revealLineInCenterIfOutsideViewport(e,t=0){this._targetEditor.revealLineInCenterIfOutsideViewport(e,t)}revealLineNearTop(e,t=0){this._targetEditor.revealLineNearTop(e,t)}revealPosition(e,t=0){this._targetEditor.revealPosition(e,t)}revealPositionInCenter(e,t=0){this._targetEditor.revealPositionInCenter(e,t)}revealPositionInCenterIfOutsideViewport(e,t=0){this._targetEditor.revealPositionInCenterIfOutsideViewport(e,t)}revealPositionNearTop(e,t=0){this._targetEditor.revealPositionNearTop(e,t)}getSelection(){return this._targetEditor.getSelection()}getSelections(){return this._targetEditor.getSelections()}setSelection(e,t="api"){this._targetEditor.setSelection(e,t)}setSelections(e,t="api"){this._targetEditor.setSelections(e,t)}revealLines(e,t,i=0){this._targetEditor.revealLines(e,t,i)}revealLinesInCenter(e,t,i=0){this._targetEditor.revealLinesInCenter(e,t,i)}revealLinesInCenterIfOutsideViewport(e,t,i=0){this._targetEditor.revealLinesInCenterIfOutsideViewport(e,t,i)}revealLinesNearTop(e,t,i=0){this._targetEditor.revealLinesNearTop(e,t,i)}revealRange(e,t=0,i=!1,o=!0){this._targetEditor.revealRange(e,t,i,o)}revealRangeInCenter(e,t=0){this._targetEditor.revealRangeInCenter(e,t)}revealRangeInCenterIfOutsideViewport(e,t=0){this._targetEditor.revealRangeInCenterIfOutsideViewport(e,t)}revealRangeNearTop(e,t=0){this._targetEditor.revealRangeNearTop(e,t)}revealRangeNearTopIfOutsideViewport(e,t=0){this._targetEditor.revealRangeNearTopIfOutsideViewport(e,t)}revealRangeAtTop(e,t=0){this._targetEditor.revealRangeAtTop(e,t)}getSupportedActions(){return this._targetEditor.getSupportedActions()}focus(){this._targetEditor.focus()}trigger(e,t,i){this._targetEditor.trigger(e,t,i)}createDecorationsCollection(e){return this._targetEditor.createDecorationsCollection(e)}changeDecorations(e){return this._targetEditor.changeDecorations(e)}}});function Aht(n,e){return n.mappings.every(t=>Mht(t.lineRangeMapping)||Pht(t.lineRangeMapping)||e&&EP(t.lineRangeMapping))}function Mht(n){return n.original.length===0}function Pht(n){return n.modified.length===0}function vBe(n,e){return{enableSplitViewResizing:$e(n.enableSplitViewResizing,e.enableSplitViewResizing),splitViewDefaultRatio:aTe(n.splitViewDefaultRatio,.5,.1,.9),renderSideBySide:$e(n.renderSideBySide,e.renderSideBySide),renderMarginRevertIcon:$e(n.renderMarginRevertIcon,e.renderMarginRevertIcon),maxComputationTime:ox(n.maxComputationTime,e.maxComputationTime,0,1073741824),maxFileSize:ox(n.maxFileSize,e.maxFileSize,0,1073741824),ignoreTrimWhitespace:$e(n.ignoreTrimWhitespace,e.ignoreTrimWhitespace),renderIndicators:$e(n.renderIndicators,e.renderIndicators),originalEditable:$e(n.originalEditable,e.originalEditable),diffCodeLens:$e(n.diffCodeLens,e.diffCodeLens),renderOverviewRuler:$e(n.renderOverviewRuler,e.renderOverviewRuler),diffWordWrap:ko(n.diffWordWrap,e.diffWordWrap,["off","on","inherit"]),diffAlgorithm:ko(n.diffAlgorithm,e.diffAlgorithm,["legacy","advanced"],{smart:"legacy",experimental:"advanced"}),accessibilityVerbose:$e(n.accessibilityVerbose,e.accessibilityVerbose),experimental:{showMoves:$e(n.experimental?.showMoves,e.experimental.showMoves),showEmptyDecorations:$e(n.experimental?.showEmptyDecorations,e.experimental.showEmptyDecorations),useTrueInlineView:$e(n.experimental?.useTrueInlineView,e.experimental.useTrueInlineView)},hideUnchangedRegions:{enabled:$e(n.hideUnchangedRegions?.enabled??n.experimental?.collapseUnchangedRegions,e.hideUnchangedRegions.enabled),contextLineCount:ox(n.hideUnchangedRegions?.contextLineCount,e.hideUnchangedRegions.contextLineCount,0,1073741824),minimumLineCount:ox(n.hideUnchangedRegions?.minimumLineCount,e.hideUnchangedRegions.minimumLineCount,0,1073741824),revealLineCount:ox(n.hideUnchangedRegions?.revealLineCount,e.hideUnchangedRegions.revealLineCount,0,1073741824)},isInEmbeddedEditor:$e(n.isInEmbeddedEditor,e.isInEmbeddedEditor),onlyShowAccessibleDiffViewer:$e(n.onlyShowAccessibleDiffViewer,e.onlyShowAccessibleDiffViewer),renderSideBySideInlineBreakpoint:ox(n.renderSideBySideInlineBreakpoint,e.renderSideBySideInlineBreakpoint,0,1073741824),useInlineViewWhenSpaceIsLimited:$e(n.useInlineViewWhenSpaceIsLimited,e.useInlineViewWhenSpaceIsLimited),renderGutterMenu:$e(n.renderGutterMenu,e.renderGutterMenu),compactMode:$e(n.compactMode,e.compactMode)}}var Nht,Rht,Cj,xBe=k(()=>{Oi();FM();rj();mae();ir();uc();Nht=function(n,e,t,i){var o=arguments.length,r=o<3?e:i===null?i=Object.getOwnPropertyDescriptor(e,t):i,s;if(typeof Reflect=="object"&&typeof Reflect.decorate=="function")r=Reflect.decorate(n,e,t,i);else for(var a=n.length-1;a>=0;a--)(s=n[a])&&(r=(o<3?s(r):o>3?s(e,t,r):s(e,t))||r);return o>3&&r&&Object.defineProperty(e,t,r),r},Rht=function(n,e){return function(t,i){e(t,i,n)}},Cj=class{get editorOptions(){return this._options}constructor(e,t){this._accessibilityService=t,this._diffEditorWidth=lt(this,0),this._screenReaderMode=Kt(this,this._accessibilityService.onDidChangeScreenReaderOptimized,()=>this._accessibilityService.isScreenReaderOptimized()),this.couldShowInlineViewBecauseOfSize=Pe(this,o=>this._options.read(o).renderSideBySide&&this._diffEditorWidth.read(o)<=this._options.read(o).renderSideBySideInlineBreakpoint),this.renderOverviewRuler=Pe(this,o=>this._options.read(o).renderOverviewRuler),this.renderSideBySide=Pe(this,o=>this.compactMode.read(o)&&this.shouldRenderInlineViewInSmartMode.read(o)?!1:this._options.read(o).renderSideBySide&&!(this._options.read(o).useInlineViewWhenSpaceIsLimited&&this.couldShowInlineViewBecauseOfSize.read(o)&&!this._screenReaderMode.read(o))),this.readOnly=Pe(this,o=>this._options.read(o).readOnly),this.shouldRenderOldRevertArrows=Pe(this,o=>!(!this._options.read(o).renderMarginRevertIcon||!this.renderSideBySide.read(o)||this.readOnly.read(o)||this.shouldRenderGutterMenu.read(o))),this.shouldRenderGutterMenu=Pe(this,o=>this._options.read(o).renderGutterMenu),this.renderIndicators=Pe(this,o=>this._options.read(o).renderIndicators),this.enableSplitViewResizing=Pe(this,o=>this._options.read(o).enableSplitViewResizing),this.splitViewDefaultRatio=Pe(this,o=>this._options.read(o).splitViewDefaultRatio),this.ignoreTrimWhitespace=Pe(this,o=>this._options.read(o).ignoreTrimWhitespace),this.maxComputationTimeMs=Pe(this,o=>this._options.read(o).maxComputationTime),this.showMoves=Pe(this,o=>this._options.read(o).experimental.showMoves&&this.renderSideBySide.read(o)),this.isInEmbeddedEditor=Pe(this,o=>this._options.read(o).isInEmbeddedEditor),this.diffWordWrap=Pe(this,o=>this._options.read(o).diffWordWrap),this.originalEditable=Pe(this,o=>this._options.read(o).originalEditable),this.diffCodeLens=Pe(this,o=>this._options.read(o).diffCodeLens),this.accessibilityVerbose=Pe(this,o=>this._options.read(o).accessibilityVerbose),this.diffAlgorithm=Pe(this,o=>this._options.read(o).diffAlgorithm),this.showEmptyDecorations=Pe(this,o=>this._options.read(o).experimental.showEmptyDecorations),this.onlyShowAccessibleDiffViewer=Pe(this,o=>this._options.read(o).onlyShowAccessibleDiffViewer),this.compactMode=Pe(this,o=>this._options.read(o).compactMode),this.trueInlineDiffRenderingEnabled=Pe(this,o=>this._options.read(o).experimental.useTrueInlineView),this.useTrueInlineDiffRendering=Pe(this,o=>!this.renderSideBySide.read(o)&&this.trueInlineDiffRenderingEnabled.read(o)),this.hideUnchangedRegions=Pe(this,o=>this._options.read(o).hideUnchangedRegions.enabled),this.hideUnchangedRegionsRevealLineCount=Pe(this,o=>this._options.read(o).hideUnchangedRegions.revealLineCount),this.hideUnchangedRegionsContextLineCount=Pe(this,o=>this._options.read(o).hideUnchangedRegions.contextLineCount),this.hideUnchangedRegionsMinimumLineCount=Pe(this,o=>this._options.read(o).hideUnchangedRegions.minimumLineCount),this._model=lt(this,void 0),this.shouldRenderInlineViewInSmartMode=this._model.map(this,o=>PPe(this,r=>{let s=o?.diff.read(r);return s?Aht(s,this.trueInlineDiffRenderingEnabled.read(r)):void 0})).flatten().map(this,o=>!!o),this.inlineViewHideOriginalLineNumbers=this.compactMode;let i={...e,...vBe(e,Rs)};this._options=lt(this,i)}updateOptions(e){let t=vBe(e,this._options.get()),i={...this._options.get(),...e,...t};this._options.set(i,void 0,{changedOptions:e})}setWidth(e){this._diffEditorWidth.set(e,void 0)}setModel(e){this._model.set(e,void 0)}};Cj=Nht([Rht(1,$o)],Cj)});function Fht(n){return n.mappings.map(e=>{let t=e.lineRangeMapping,i,o,r,s,a=t.innerChanges;return t.original.isEmpty?(i=t.original.startLineNumber-1,o=0,a=void 0):(i=t.original.startLineNumber,o=t.original.endLineNumberExclusive-1),t.modified.isEmpty?(r=t.modified.startLineNumber-1,s=0,a=void 0):(r=t.modified.startLineNumber,s=t.modified.endLineNumberExclusive-1),{originalStartLineNumber:i,originalEndLineNumber:o,modifiedStartLineNumber:r,modifiedEndLineNumber:s,charChanges:a?.map(l=>({originalStartLineNumber:l.originalRange.startLineNumber,originalStartColumn:l.originalRange.startColumn,originalEndLineNumber:l.originalRange.endLineNumber,originalEndColumn:l.originalRange.endColumn,modifiedStartLineNumber:l.modifiedRange.startLineNumber,modifiedStartColumn:l.modifiedRange.startColumn,modifiedEndLineNumber:l.modifiedRange.endLineNumber,modifiedEndColumn:l.modifiedRange.endColumn}))}})}var Oht,NP,Ff,Sj=k(()=>{ke();Ad();je();Ie();j();Oi();Yc();U8e();mt();Po();L0();CP();G8e();rBe();Xfe();rj();hBe();npe();Zfe();ope();pBe();zh();iT();spe();qe();we();q2();Si();Lw();it();Fe();JC();kf();_Be();bBe();xBe();Gfe();Oht=function(n,e,t,i){var o=arguments.length,r=o<3?e:i===null?i=Object.getOwnPropertyDescriptor(e,t):i,s;if(typeof Reflect=="object"&&typeof Reflect.decorate=="function")r=Reflect.decorate(n,e,t,i);else for(var a=n.length-1;a>=0;a--)(s=n[a])&&(r=(o<3?s(r):o>3?s(e,t,r):s(e,t))||r);return o>3&&r&&Object.defineProperty(e,t,r),r},NP=function(n,e){return function(t,i){e(t,i,n)}},Ff=class extends yj{get onDidContentSizeChange(){return this._editors.onDidContentSizeChange}constructor(e,t,i,o,r,s,a,l){super(),this._domElement=e,this._parentContextKeyService=o,this._parentInstantiationService=r,this._accessibilitySignalService=a,this._editorProgressService=l,this.elements=Et("div.monaco-diff-editor.side-by-side",{style:{position:"relative",height:"100%"}},[Et("div.editor.original@original",{style:{position:"absolute",height:"100%"}}),Et("div.editor.modified@modified",{style:{position:"absolute",height:"100%"}}),Et("div.accessibleDiffViewer@accessibleDiffViewer",{style:{position:"absolute",height:"100%"}})]),this._diffModelSrc=this._register(ag(this,void 0)),this._diffModel=Pe(this,w=>this._diffModelSrc.read(w)?.object),this.onDidChangeModel=ne.fromObservableLight(this._diffModel),this._contextKeyService=this._register(this._parentContextKeyService.createScoped(this._domElement)),this._instantiationService=this._register(this._parentInstantiationService.createChild(new Fu([Le,this._contextKeyService]))),this._boundarySashes=lt(this,void 0),this._accessibleDiffViewerShouldBeVisible=lt(this,!1),this._accessibleDiffViewerVisible=Pe(this,w=>this._options.onlyShowAccessibleDiffViewer.read(w)?!0:this._accessibleDiffViewerShouldBeVisible.read(w)),this._movedBlocksLinesPart=lt(this,void 0),this._layoutInfo=Pe(this,w=>{let y=this._rootSizeObserver.width.read(w),C=this._rootSizeObserver.height.read(w);this._rootSizeObserver.automaticLayout?this.elements.root.style.height="100%":this.elements.root.style.height=C+"px";let L=this._sash.read(w),E=this._gutter.read(w),N=E?.width.read(w)??0,M=this._overviewRulerPart.read(w)?.width??0,F,q,te,$,z;if(!!L){let X=L.sashLeft.read(w),ue=this._movedBlocksLinesPart.read(w)?.width.read(w)??0;F=0,q=X-N-ue,z=X-N,te=X,$=y-te-M}else{z=0;let X=this._options.inlineViewHideOriginalLineNumbers.read(w);F=N,X?q=0:q=Math.max(5,this._editors.originalObs.layoutInfoDecorationsLeft.read(w)),te=N+q,$=y-te-M}return this.elements.original.style.left=F+"px",this.elements.original.style.width=q+"px",this._editors.original.layout({width:q,height:C},!0),E?.layout(z),this.elements.modified.style.left=te+"px",this.elements.modified.style.width=$+"px",this._editors.modified.layout({width:$,height:C},!0),{modifiedEditor:this._editors.modified.getLayoutInfo(),originalEditor:this._editors.original.getLayoutInfo()}}),this._diffValue=this._diffModel.map((w,y)=>w?.diff.read(y)),this.onDidUpdateDiff=ne.fromObservableLight(this._diffValue),s.willCreateDiffEditor(),this._contextKeyService.createKey("isInDiffEditor",!0),this._domElement.appendChild(this.elements.root),this._register(ge(()=>this.elements.root.remove())),this._rootSizeObserver=this._register(new GE(this.elements.root,t.dimension)),this._rootSizeObserver.setAutomaticLayout(t.automaticLayout??!1),this._options=this._instantiationService.createInstance(Cj,t),this._register(He(w=>{this._options.setWidth(this._rootSizeObserver.width.read(w))})),this._contextKeyService.createKey(T.isEmbeddedDiffEditor.key,!1),this._register(Vh(T.isEmbeddedDiffEditor,this._contextKeyService,w=>this._options.isInEmbeddedEditor.read(w))),this._register(Vh(T.comparingMovedCode,this._contextKeyService,w=>!!this._diffModel.read(w)?.movedTextToCompare.read(w))),this._register(Vh(T.diffEditorRenderSideBySideInlineBreakpointReached,this._contextKeyService,w=>this._options.couldShowInlineViewBecauseOfSize.read(w))),this._register(Vh(T.diffEditorInlineMode,this._contextKeyService,w=>!this._options.renderSideBySide.read(w))),this._register(Vh(T.hasChanges,this._contextKeyService,w=>(this._diffModel.read(w)?.diff.read(w)?.mappings.length??0)>0)),this._editors=this._register(this._instantiationService.createInstance(wj,this.elements.original,this.elements.modified,this._options,i,(w,y,C,L)=>this._createInnerEditor(w,y,C,L))),this._register(Vh(T.diffEditorOriginalWritable,this._contextKeyService,w=>this._options.originalEditable.read(w))),this._register(Vh(T.diffEditorModifiedWritable,this._contextKeyService,w=>!this._options.readOnly.read(w))),this._register(Vh(T.diffEditorOriginalUri,this._contextKeyService,w=>this._diffModel.read(w)?.model.original.uri.toString()??"")),this._register(Vh(T.diffEditorModifiedUri,this._contextKeyService,w=>this._diffModel.read(w)?.model.modified.uri.toString()??"")),this._overviewRulerPart=Sr(this,w=>this._options.renderOverviewRuler.read(w)?this._instantiationService.createInstance(Na(A0,w),this._editors,this.elements.root,this._diffModel,this._rootSizeObserver.width,this._rootSizeObserver.height,this._layoutInfo.map(y=>y.modifiedEditor)):void 0).recomputeInitiallyAndOnChange(this._store);let c={height:this._rootSizeObserver.height,width:this._rootSizeObserver.width.map((w,y)=>w-(this._overviewRulerPart.read(y)?.width??0))};this._sashLayout=new lj(this._options,c),this._sash=Sr(this,w=>{let y=this._options.renderSideBySide.read(w);return this.elements.root.classList.toggle("side-by-side",y),y?new oT(this.elements.root,c,this._options.enableSplitViewResizing,this._boundarySashes,this._sashLayout.sashLeft,()=>this._sashLayout.resetSash()):void 0}).recomputeInitiallyAndOnChange(this._store);let d=Sr(this,w=>this._instantiationService.createInstance(Na(lT,w),this._editors,this._diffModel,this._options)).recomputeInitiallyAndOnChange(this._store);Sr(this,w=>this._instantiationService.createInstance(Na(aj,w),this._editors,this._diffModel,this._options,this)).recomputeInitiallyAndOnChange(this._store);let u=new Set,h=new Set,f=!1,p=Sr(this,w=>this._instantiationService.createInstance(Na(oj,w),Me(this._domElement),this._editors,this._diffModel,this._options,this,()=>f||d.get().isUpdatingHiddenAreas,u,h)).recomputeInitiallyAndOnChange(this._store),g=Pe(this,w=>{let y=p.read(w).viewZones.read(w).orig,C=d.read(w).viewZones.read(w).origViewZones;return y.concat(C)}),_=Pe(this,w=>{let y=p.read(w).viewZones.read(w).mod,C=d.read(w).viewZones.read(w).modViewZones;return y.concat(C)});this._register(ZE(this._editors.original,g,w=>{f=w},u));let b;this._register(ZE(this._editors.modified,_,w=>{f=w,f?b=od.capture(this._editors.modified):(b?.restore(this._editors.modified),b=void 0)},h)),this._accessibleDiffViewer=Sr(this,w=>this._instantiationService.createInstance(Na(Ww,w),this.elements.accessibleDiffViewer,this._accessibleDiffViewerVisible,(y,C)=>this._accessibleDiffViewerShouldBeVisible.set(y,C),this._options.onlyShowAccessibleDiffViewer.map(y=>!y),this._rootSizeObserver.width,this._rootSizeObserver.height,this._diffModel.map((y,C)=>y?.diff.read(C)?.mappings.map(L=>L.lineRangeMapping)),new Q$(this._editors))).recomputeInitiallyAndOnChange(this._store);let v=this._accessibleDiffViewerVisible.map(w=>w?"hidden":"visible");this._register(Gd(this.elements.modified,{visibility:v})),this._register(Gd(this.elements.original,{visibility:v})),this._createDiffEditorContributions(),s.addDiffEditor(this),this._gutter=Sr(this,w=>this._options.shouldRenderGutterMenu.read(w)?this._instantiationService.createInstance(Na(fj,w),this.elements.root,this._diffModel,this._editors,this._options,this._sashLayout,this._boundarySashes):void 0),this._register(If(this._layoutInfo)),Sr(this,w=>new(Na(zw,w))(this.elements.root,this._diffModel,this._layoutInfo.map(y=>y.originalEditor),this._layoutInfo.map(y=>y.modifiedEditor),this._editors)).recomputeInitiallyAndOnChange(this._store,w=>{this._movedBlocksLinesPart.set(w,void 0)}),this._register(ne.runAndSubscribe(this._editors.modified.onDidChangeCursorPosition,w=>this._handleCursorPositionChange(w,!0))),this._register(ne.runAndSubscribe(this._editors.original.onDidChangeCursorPosition,w=>this._handleCursorPositionChange(w,!1)));let x=this._diffModel.map(this,(w,y)=>{if(w)return w.diff.read(y)===void 0&&!w.isDiffUpToDate.read(y)});this._register(To((w,y)=>{if(x.read(w)===!0){let C=this._editorProgressService.show(!0,1e3);y.add(ge(()=>C.done()))}})),this._register(To((w,y)=>{y.add(new(Na(vj,w))(this._editors,this._diffModel,this._options,this))})),this._register(To((w,y)=>{let C=this._diffModel.read(w);if(C)for(let L of[C.model.original,C.model.modified])y.add(L.onWillDispose(E=>{Be(new Nt("TextModel got disposed before DiffEditorWidget model got reset")),this.setModel(null)}))})),this._register(He(w=>{this._options.setModel(this._diffModel.read(w))}))}_createInnerEditor(e,t,i,o){return e.createInstance(Bw,t,i,o)}_createDiffEditorContributions(){let e=Nm.getDiffEditorContributions();for(let t of e)try{this._register(this._instantiationService.createInstance(t.ctor,this))}catch(i){Be(i)}}get _targetEditor(){return this._editors.modified}getEditorType(){return Pb.IDiffEditor}layout(e){this._rootSizeObserver.observe(e)}hasTextFocus(){return this._editors.original.hasTextFocus()||this._editors.modified.hasTextFocus()}saveViewState(){let e=this._editors.original.saveViewState(),t=this._editors.modified.saveViewState();return{original:e,modified:t,modelState:this._diffModel.get()?.serializeState()}}restoreViewState(e){if(e&&e.original&&e.modified){let t=e;this._editors.original.restoreViewState(t.original),this._editors.modified.restoreViewState(t.modified),t.modelState&&this._diffModel.get()?.restoreSerializedState(t.modelState)}}handleInitialized(){this._editors.original.handleInitialized(),this._editors.modified.handleInitialized()}createViewModel(e){return this._instantiationService.createInstance(ej,e,this._options)}getModel(){return this._diffModel.get()?.model??null}setModel(e){let t=e?"model"in e?E0.create(e).createNewRef(this):E0.create(this.createViewModel(e),this):null;this.setDiffModel(t)}setDiffModel(e,t){let i=this._diffModel.get();!e&&i&&this._accessibleDiffViewer.get().close(),this._diffModel.get()!==e?.object&&Nh(t,o=>{let r=e?.object;Kt.batchEventsGlobally(o,()=>{this._editors.original.setModel(r?r.model.original:null),this._editors.modified.setModel(r?r.model.modified:null)});let s=this._diffModelSrc.get()?.createNewRef(this);this._diffModelSrc.set(e?.createNewRef(this),o),setTimeout(()=>{s?.dispose()},0)})}updateOptions(e){this._options.updateOptions(e)}getContainerDomNode(){return this._domElement}getOriginalEditor(){return this._editors.original}getModifiedEditor(){return this._editors.modified}getLineChanges(){let e=this._diffModel.get()?.diff.get();return e?Fht(e):null}revert(e){let t=this._diffModel.get();!t||!t.isDiffUpToDate.get()||this._editors.modified.executeEdits("diffEditor",[{range:e.modified.toExclusiveRange(),text:t.model.original.getValueInRange(e.original.toExclusiveRange())}])}revertRangeMappings(e){let t=this._diffModel.get();if(!t||!t.isDiffUpToDate.get())return;let i=e.map(o=>({range:o.modifiedRange,text:t.model.original.getValueInRange(o.originalRange)}));this._editors.modified.executeEdits("diffEditor",i)}_goTo(e){this._editors.modified.setPosition(new P(e.lineRangeMapping.modified.startLineNumber,1)),this._editors.modified.revealRangeInCenter(e.lineRangeMapping.modified.toExclusiveRange())}goToDiff(e){let t=this._diffModel.get()?.diff.get()?.mappings;if(!t||t.length===0)return;let i=this._editors.modified.getPosition().lineNumber,o;e==="next"?o=t.find(r=>r.lineRangeMapping.modified.startLineNumber>i)??t[0]:o=eb(t,r=>r.lineRangeMapping.modified.startLineNumber{let t=e.diff.get()?.mappings;!t||t.length===0||this._goTo(t[0])})}accessibleDiffViewerNext(){this._accessibleDiffViewer.get().next()}accessibleDiffViewerPrev(){this._accessibleDiffViewer.get().prev()}async waitForDiff(){let e=this._diffModel.get();e&&await e.waitForDiff()}mapToOtherSide(){let e=this._editors.modified.hasWidgetFocus(),t=e?this._editors.modified:this._editors.original,i=e?this._editors.original:this._editors.modified,o,r=t.getSelection();if(r){let s=this._diffModel.get()?.diff.get()?.mappings.map(a=>e?a.lineRangeMapping.flip():a.lineRangeMapping);if(s){let a=Dfe(r.getStartPosition(),s),l=Dfe(r.getEndPosition(),s);o=S.plusRange(a,l)}}return{destination:i,destinationSelection:o}}switchSide(){let{destination:e,destinationSelection:t}=this.mapToOtherSide();e.focus(),t&&e.setSelection(t)}exitCompareMove(){let e=this._diffModel.get();e&&e.movedTextToCompare.set(void 0,void 0)}collapseAllUnchangedRegions(){let e=this._diffModel.get()?.unchangedRegions.get();e&&xi(t=>{for(let i of e)i.collapseAll(t)})}showAllUnchangedRegions(){let e=this._diffModel.get()?.unchangedRegions.get();e&&xi(t=>{for(let i of e)i.showAll(t)})}_handleCursorPositionChange(e,t){if(e?.reason===3){let i=this._diffModel.get()?.diff.get()?.mappings.find(o=>t?o.lineRangeMapping.modified.contains(e.position.lineNumber):o.lineRangeMapping.original.contains(e.position.lineNumber));i?.lineRangeMapping.modified.isEmpty?this._accessibilitySignalService.playSignal(sl.diffLineDeleted,{source:"diffEditor.cursorPositionChanged"}):i?.lineRangeMapping.original.isEmpty?this._accessibilitySignalService.playSignal(sl.diffLineInserted,{source:"diffEditor.cursorPositionChanged"}):i&&this._accessibilitySignalService.playSignal(sl.diffLineModified,{source:"diffEditor.cursorPositionChanged"})}}};Ff=Oht([NP(3,Le),NP(4,he),NP(5,xt),NP(6,jd),NP(7,Fd)],Ff)});function Wht(n){if(!n){if(wBe)return;wBe=!0}K2e(n||ri.document.body)}function lpe(n,e,t,i,o){if(t=t||"",!i){let r=t.indexOf(` `),s=t;return r!==-1&&(s=t.substring(0,r)),yBe(n,t,e.createByFilepathOrFirstLine(o||null,s),o)}return yBe(n,t,e.createById(i),o)}function yBe(n,e,t,i){return n.createModel(e,t,i)}var ape,qn,Bht,wBe,kj,Lj,Ij,CBe=k(()=>{Ns();j();Po();CP();tfe();j2();QC();an();Gi();en();it();Al();Fe();Pn();ea();Yi();uc();og();Mb();kf();va();fs();Vre();Nd();Ko();Qt();Sj();Lw();Il();Ps();db();Ah();ape=function(n,e,t,i){var o=arguments.length,r=o<3?e:i===null?i=Object.getOwnPropertyDescriptor(e,t):i,s;if(typeof Reflect=="object"&&typeof Reflect.decorate=="function")r=Reflect.decorate(n,e,t,i);else for(var a=n.length-1;a>=0;a--)(s=n[a])&&(r=(o<3?s(r):o>3?s(e,t,r):s(e,t))||r);return o>3&&r&&Object.defineProperty(e,t,r),r},qn=function(n,e){return function(t,i){e(t,i,n)}},Bht=0,wBe=!1;kj=class extends Bw{constructor(e,t,i,o,r,s,a,l,c,d,u,h,f){let p={...t};p.ariaLabel=p.ariaLabel||W7.editorViewAccessibleLabel,super(e,p,{},i,o,r,s,c,d,u,h,f),l instanceof Ew?this._standaloneKeybindingService=l:this._standaloneKeybindingService=null,Wht(p.ariaContainerElement),HPe((g,_)=>i.createInstance(Gm,g,_,{})),VPe(a)}addCommand(e,t,i){if(!this._standaloneKeybindingService)return console.warn("Cannot add command because the editor is configured with an unrecognized KeybindingService"),null;let o="DYNAMIC_"+ ++Bht,r=Y.deserialize(i);return this._standaloneKeybindingService.addDynamicKeybinding(o,e,t,r),o}createContextKey(e,t){return this._contextKeyService.createKey(e,t)}addAction(e){if(typeof e.id!="string"||typeof e.label!="string"||typeof e.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"),D.None;let t=e.id,i=e.label,o=Y.and(Y.equals("editorId",this.getId()),Y.deserialize(e.precondition)),r=e.keybindings,s=Y.and(o,Y.deserialize(e.keybindingContext)),a=e.contextMenuGroupId||null,l=e.contextMenuOrder||0,c=(f,...p)=>Promise.resolve(e.run(this,...p)),d=new H,u=this.getId()+":"+t;if(d.add(wt.registerCommand(u,c)),a){let f={command:{id:u,title:i},when:o,group:a,order:l};d.add(Lo.appendMenuItem(Te.EditorContext,f))}if(Array.isArray(r))for(let f of r)d.add(this._standaloneKeybindingService.addDynamicKeybinding(u,f,c,s));let h=new jE(u,i,i,void 0,o,(...f)=>Promise.resolve(e.run(this,...f)),this._contextKeyService);return this._actions.set(t,h),d.add(ge(()=>{this._actions.delete(t)})),d}_triggerCommand(e,t){if(this._codeEditorService instanceof $A)try{this._codeEditorService.setActiveCodeEditor(this),super._triggerCommand(e,t)}finally{this._codeEditorService.setActiveCodeEditor(null)}else super._triggerCommand(e,t)}};kj=ape([qn(2,he),qn(3,xt),qn(4,$t),qn(5,Le),qn(6,cc),qn(7,_t),qn(8,Vi),qn(9,Di),qn(10,$o),qn(11,ti),qn(12,le)],kj);Lj=class extends kj{constructor(e,t,i,o,r,s,a,l,c,d,u,h,f,p,g,_){let b={...t};$2(u,b,!1);let v=c.registerEditorContainer(e);typeof b.theme=="string"&&c.setTheme(b.theme),typeof b.autoDetectHighContrast<"u"&&c.setAutoDetectHighContrast(!!b.autoDetectHighContrast);let x=b.model;delete b.model,super(e,b,i,o,r,s,a,l,c,d,h,g,_),this._configurationService=u,this._standaloneThemeService=c,this._register(v);let w;if(typeof x>"u"){let y=p.getLanguageIdByMimeType(b.language)||b.language||Oo;w=lpe(f,p,b.value||"",y,void 0),this._ownsModel=!0}else w=x,this._ownsModel=!1;if(this._attachModel(w),w){let y={oldModelUrl:null,newModelUrl:w.uri};this._onDidChangeModel.fire(y)}}dispose(){super.dispose()}updateOptions(e){$2(this._configurationService,e,!1),typeof e.theme=="string"&&this._standaloneThemeService.setTheme(e.theme),typeof e.autoDetectHighContrast<"u"&&this._standaloneThemeService.setAutoDetectHighContrast(!!e.autoDetectHighContrast),super.updateOptions(e)}_postDetachModelCleanup(e){super._postDetachModelCleanup(e),e&&this._ownsModel&&(e.dispose(),this._ownsModel=!1)}};Lj=ape([qn(2,he),qn(3,xt),qn(4,$t),qn(5,Le),qn(6,cc),qn(7,_t),qn(8,La),qn(9,Di),qn(10,Ve),qn(11,$o),qn(12,di),qn(13,ai),qn(14,ti),qn(15,le)],Lj);Ij=class extends Ff{constructor(e,t,i,o,r,s,a,l,c,d,u,h){let f={...t};$2(l,f,!0);let p=s.registerEditorContainer(e);typeof f.theme=="string"&&s.setTheme(f.theme),typeof f.autoDetectHighContrast<"u"&&s.setAutoDetectHighContrast(!!f.autoDetectHighContrast),super(e,f,{},o,i,r,h,d),this._configurationService=l,this._standaloneThemeService=s,this._register(p)}dispose(){super.dispose()}updateOptions(e){$2(this._configurationService,e,!0),typeof e.theme=="string"&&this._standaloneThemeService.setTheme(e.theme),typeof e.autoDetectHighContrast<"u"&&this._standaloneThemeService.setAutoDetectHighContrast(!!e.autoDetectHighContrast),super.updateOptions(e)}_createInnerEditor(e,t,i){return e.createInstance(kj,t,i)}getOriginalEditor(){return super.getOriginalEditor()}getModifiedEditor(){return super.getModifiedEditor()}addCommand(e,t,i){return this.getModifiedEditor().addCommand(e,t,i)}createContextKey(e,t){return this.getModifiedEditor().createContextKey(e,t)}addAction(e){return this.getModifiedEditor().addAction(e)}};Ij=ape([qn(2,he),qn(3,Le),qn(4,xt),qn(5,La),qn(6,Di),qn(7,Ve),qn(8,sr),qn(9,Fd),qn(10,gc),qn(11,jd)],Ij)});var SBe=k(()=>{});var Hht,kBe,Ej,cT,cpe=k(()=>{ke();zH();Qi();j();Oi();Lf();Zb();Sj();yb();DP();an();Fe();Jfe();it();JC();Hht=function(n,e,t,i){var o=arguments.length,r=o<3?e:i===null?i=Object.getOwnPropertyDescriptor(e,t):i,s;if(typeof Reflect=="object"&&typeof Reflect.decorate=="function")r=Reflect.decorate(n,e,t,i);else for(var a=n.length-1;a>=0;a--)(s=n[a])&&(r=(o<3?s(r):o>3?s(e,t,r):s(e,t))||r);return o>3&&r&&Object.defineProperty(e,t,r),r},kBe=function(n,e){return function(t,i){e(t,i,n)}},Ej=class{constructor(e,t){this.viewModel=e,this.deltaScrollVertical=t}getId(){return this.viewModel}},cT=class extends D{constructor(e,t,i,o,r){super(),this._container=e,this._overflowWidgetsDomNode=t,this._workbenchUIElementFactory=i,this._instantiationService=o,this._viewModel=lt(this,void 0),this._collapsed=Pe(this,l=>this._viewModel.read(l)?.collapsed.read(l)),this._editorContentHeight=lt(this,500),this.contentHeight=Pe(this,l=>(this._collapsed.read(l)?0:this._editorContentHeight.read(l))+this._outerEditorHeight),this._modifiedContentWidth=lt(this,0),this._modifiedWidth=lt(this,0),this._originalContentWidth=lt(this,0),this._originalWidth=lt(this,0),this.maxScroll=Pe(this,l=>{let c=this._modifiedContentWidth.read(l)-this._modifiedWidth.read(l),d=this._originalContentWidth.read(l)-this._originalWidth.read(l);return c>d?{maxScroll:c,width:this._modifiedWidth.read(l)}:{maxScroll:d,width:this._originalWidth.read(l)}}),this._elements=Et("div.multiDiffEntry",[Et("div.header@header",[Et("div.header-content",[Et("div.collapse-button@collapseButton"),Et("div.file-path",[Et("div.title.modified.show-file-icons@primaryPath",[]),Et("div.status.deleted@status",["R"]),Et("div.title.original.show-file-icons@secondaryPath",[])]),Et("div.actions@actions")])]),Et("div.editorParent",[Et("div.editorContainer@editor")])]),this.editor=this._register(this._instantiationService.createInstance(Ff,this._elements.editor,{overflowWidgetsDomNode:this._overflowWidgetsDomNode},{})),this.isModifedFocused=bs(this.editor.getModifiedEditor()).isFocused,this.isOriginalFocused=bs(this.editor.getOriginalEditor()).isFocused,this.isFocused=Pe(this,l=>this.isModifedFocused.read(l)||this.isOriginalFocused.read(l)),this._resourceLabel=this._workbenchUIElementFactory.createResourceLabel?this._register(this._workbenchUIElementFactory.createResourceLabel(this._elements.primaryPath)):void 0,this._resourceLabel2=this._workbenchUIElementFactory.createResourceLabel?this._register(this._workbenchUIElementFactory.createResourceLabel(this._elements.secondaryPath)):void 0,this._dataStore=this._register(new H),this._headerHeight=40,this._lastScrollTop=-1,this._isSettingScrollTop=!1;let s=new Tb(this._elements.collapseButton,{});this._register(He(l=>{s.element.className="",s.icon=this._collapsed.read(l)?oe.chevronRight:oe.chevronDown})),this._register(s.onDidClick(()=>{this._viewModel.get()?.collapsed.set(!this._collapsed.get(),void 0)})),this._register(He(l=>{this._elements.editor.style.display=this._collapsed.read(l)?"none":"block"})),this._register(this.editor.getModifiedEditor().onDidLayoutChange(l=>{let c=this.editor.getModifiedEditor().getLayoutInfo().contentWidth;this._modifiedWidth.set(c,void 0)})),this._register(this.editor.getOriginalEditor().onDidLayoutChange(l=>{let c=this.editor.getOriginalEditor().getLayoutInfo().contentWidth;this._originalWidth.set(c,void 0)})),this._register(this.editor.onDidContentSizeChange(l=>{CC(c=>{this._editorContentHeight.set(l.contentHeight,c),this._modifiedContentWidth.set(this.editor.getModifiedEditor().getContentWidth(),c),this._originalContentWidth.set(this.editor.getOriginalEditor().getContentWidth(),c)})})),this._register(this.editor.getOriginalEditor().onDidScrollChange(l=>{if(this._isSettingScrollTop||!l.scrollTopChanged||!this._data)return;let c=l.scrollTop-this._lastScrollTop;this._data.deltaScrollVertical(c)})),this._register(He(l=>{let c=this._viewModel.read(l)?.isActive.read(l);this._elements.root.classList.toggle("active",c)})),this._container.appendChild(this._elements.root),this._outerEditorHeight=this._headerHeight,this._contextKeyService=this._register(r.createScoped(this._elements.actions));let a=this._register(this._instantiationService.createChild(new Fu([Le,this._contextKeyService])));this._register(a.createInstance(aT,this._elements.actions,Te.MultiDiffEditorFileToolbar,{actionRunner:this._register(new rT(()=>this._viewModel.get()?.modifiedUri)),menuOptions:{shouldForwardArgs:!0},toolbarOptions:{primaryGroup:l=>l.startsWith("navigation")},actionViewItemProvider:(l,c)=>vW(a,l,c)}))}setScrollLeft(e){this._modifiedContentWidth.get()-this._modifiedWidth.get()>this._originalContentWidth.get()-this._originalWidth.get()?this.editor.getModifiedEditor().setScrollLeft(e):this.editor.getOriginalEditor().setScrollLeft(e)}setData(e){this._data=e;function t(o){return{...o,scrollBeyondLastLine:!1,hideUnchangedRegions:{enabled:!0},scrollbar:{vertical:"hidden",horizontal:"hidden",handleMouseWheel:!1,useShadows:!1},renderOverviewRuler:!1,fixedOverflowWidgets:!0,overviewRulerBorder:!1}}if(!e){CC(o=>{this._viewModel.set(void 0,o),this.editor.setDiffModel(null,o),this._dataStore.clear()});return}let i=e.viewModel.documentDiffItem;if(CC(o=>{this._resourceLabel?.setUri(e.viewModel.modifiedUri??e.viewModel.originalUri,{strikethrough:e.viewModel.modifiedUri===void 0});let r=!1,s=!1,a=!1,l="";e.viewModel.modifiedUri&&e.viewModel.originalUri&&e.viewModel.modifiedUri.path!==e.viewModel.originalUri.path?(l="R",r=!0):e.viewModel.modifiedUri?e.viewModel.originalUri||(l="A",a=!0):(l="D",s=!0),this._elements.status.classList.toggle("renamed",r),this._elements.status.classList.toggle("deleted",s),this._elements.status.classList.toggle("added",a),this._elements.status.innerText=l,this._resourceLabel2?.setUri(r?e.viewModel.originalUri:void 0,{strikethrough:!0}),this._dataStore.clear(),this._viewModel.set(e.viewModel,o),this.editor.setDiffModel(e.viewModel.diffEditorViewModelRef,o),this.editor.updateOptions(t(i.options??{}))}),i.onOptionsDidChange&&this._dataStore.add(i.onOptionsDidChange(()=>{this.editor.updateOptions(t(i.options??{}))})),e.viewModel.isAlive.recomputeInitiallyAndOnChange(this._dataStore,o=>{o||this.setData(void 0)}),e.viewModel.documentDiffItem.contextKeys)for(let[o,r]of Object.entries(e.viewModel.documentDiffItem.contextKeys))this._contextKeyService.createKey(o,r)}render(e,t,i,o){this._elements.root.style.visibility="visible",this._elements.root.style.top=`${e.start}px`,this._elements.root.style.height=`${e.length}px`,this._elements.root.style.width=`${t}px`,this._elements.root.style.position="absolute";let r=e.length-this._headerHeight,s=Math.max(0,Math.min(o.start-e.start,r));this._elements.header.style.transform=`translateY(${s}px)`,CC(a=>{this.editor.layout({width:t-2*8-2*1,height:e.length-this._outerEditorHeight})});try{this._isSettingScrollTop=!0,this._lastScrollTop=i,this.editor.getOriginalEditor().setScrollTop(i)}finally{this._isSettingScrollTop=!1}this._elements.header.classList.toggle("shadow",s>0||i>0),this._elements.header.classList.toggle("collapsed",s===r)}hide(){this._elements.root.style.top="-100000px",this._elements.root.style.visibility="hidden"}};cT=Hht([kBe(3,he),kBe(4,Le)],cT)});var Tj,LBe=k(()=>{Tj=class{constructor(e){this._create=e,this._unused=new Set,this._used=new Set,this._itemData=new Map}getUnusedObj(e){let t;if(this._unused.size===0)t=this._create(e),this._itemData.set(t,e);else{let i=[...this._unused.values()];t=i.find(o=>this._itemData.get(o).getId()===e.getId())??i[0],this._unused.delete(t),this._itemData.set(t,e),t.setData(e)}return this._used.add(t),{object:t,dispose:()=>{this._used.delete(t),this._unused.size>5?t.dispose():this._unused.add(t)}}}dispose(){for(let e of this._used)e.dispose();for(let e of this._unused)e.dispose();this._used.clear(),this._unused.clear()}}});var zht,IBe,Dj,dpe,EBe=k(()=>{ke();Eh();at();Ad();je();j();Oi();Lf();GL();SBe();zh();Rd();Ui();Si();it();Fe();JC();cpe();LBe();pe();zht=function(n,e,t,i){var o=arguments.length,r=o<3?e:i===null?i=Object.getOwnPropertyDescriptor(e,t):i,s;if(typeof Reflect=="object"&&typeof Reflect.decorate=="function")r=Reflect.decorate(n,e,t,i);else for(var a=n.length-1;a>=0;a--)(s=n[a])&&(r=(o<3?s(r):o>3?s(e,t,r):s(e,t))||r);return o>3&&r&&Object.defineProperty(e,t,r),r},IBe=function(n,e){return function(t,i){e(t,i,n)}},Dj=class extends D{constructor(e,t,i,o,r,s){super(),this._element=e,this._dimension=t,this._viewModel=i,this._workbenchUIElementFactory=o,this._parentContextKeyService=r,this._parentInstantiationService=s,this._scrollableElements=Et("div.scrollContent",[Et("div@content",{style:{overflow:"hidden"}}),Et("div.monaco-editor@overflowWidgetsDomNode",{})]),this._scrollable=this._register(new Ih({forceIntegerValues:!1,scheduleAtNextAnimationFrame:l=>us(Me(this._element),l),smoothScrollDuration:100})),this._scrollableElement=this._register(new Ym(this._scrollableElements.root,{vertical:1,horizontal:1,useShadows:!1},this._scrollable)),this._elements=Et("div.monaco-component.multiDiffEditor",{},[Et("div",{},[this._scrollableElement.getDomNode()]),Et("div.placeholder@placeholder",{},[Et("div",[m("noChangedFiles","No Changed Files")])])]),this._sizeObserver=this._register(new GE(this._element,void 0)),this._objectPool=this._register(new Tj(l=>{let c=this._instantiationService.createInstance(cT,this._scrollableElements.content,this._scrollableElements.overflowWidgetsDomNode,this._workbenchUIElementFactory);return c.setData(l),c})),this.scrollTop=Kt(this,this._scrollableElement.onScroll,()=>this._scrollableElement.getScrollPosition().scrollTop),this.scrollLeft=Kt(this,this._scrollableElement.onScroll,()=>this._scrollableElement.getScrollPosition().scrollLeft),this._viewItemsInfo=hc(this,(l,c)=>{let d=this._viewModel.read(l);if(!d)return{items:[],getItem:p=>{throw new Nt}};let u=d.items.read(l),h=new Map;return{items:u.map(p=>{let g=c.add(new dpe(p,this._objectPool,this.scrollLeft,b=>{this._scrollableElement.setScrollPosition({scrollTop:this._scrollableElement.getScrollPosition().scrollTop+b})})),_=this._lastDocStates?.[g.getKey()];return _&&xi(b=>{g.setViewState(_,b)}),h.set(p,g),g}),getItem:p=>h.get(p)}}),this._viewItems=this._viewItemsInfo.map(this,l=>l.items),this._spaceBetweenPx=0,this._totalHeight=this._viewItems.map(this,(l,c)=>l.reduce((d,u)=>d+u.contentHeight.read(c)+this._spaceBetweenPx,0)),this._contextKeyService=this._register(this._parentContextKeyService.createScoped(this._element)),this._instantiationService=this._register(this._parentInstantiationService.createChild(new Fu([Le,this._contextKeyService]))),this._lastDocStates={},this._contextKeyService.createKey(T.inMultiDiffEditor.key,!0),this._register(To((l,c)=>{let d=this._viewModel.read(l);if(d&&d.contextKeys)for(let[u,h]of Object.entries(d.contextKeys)){let f=this._contextKeyService.createKey(u,void 0);f.set(h),c.add(ge(()=>f.reset()))}}));let a=this._parentContextKeyService.createKey(T.multiDiffEditorAllCollapsed.key,!1);this._register(He(l=>{let c=this._viewModel.read(l);if(c){let d=c.items.read(l).every(u=>u.collapsed.read(l));a.set(d)}})),this._register(He(l=>{let c=this._dimension.read(l);this._sizeObserver.observe(c)})),this._register(He(l=>{let c=this._viewItems.read(l);this._elements.placeholder.classList.toggle("visible",c.length===0)})),this._scrollableElements.content.style.position="relative",this._register(He(l=>{let c=this._sizeObserver.height.read(l);this._scrollableElements.root.style.height=`${c}px`;let d=this._totalHeight.read(l);this._scrollableElements.content.style.height=`${d}px`;let u=this._sizeObserver.width.read(l),h=u,f=this._viewItems.read(l),p=RA(f,mr(g=>g.maxScroll.read(l).maxScroll,yl));if(p){let g=p.maxScroll.read(l);h=u+g.maxScroll}this._scrollableElement.setScrollDimensions({width:u,height:c,scrollHeight:d,scrollWidth:h})})),e.replaceChildren(this._elements.root),this._register(ge(()=>{e.replaceChildren()})),this._register(this._register(He(l=>{CC(c=>{this.render(l)})})))}render(e){let t=this.scrollTop.read(e),i=0,o=0,r=0,s=this._sizeObserver.height.read(e),a=Wt.ofStartAndLength(t,s),l=this._sizeObserver.width.read(e);for(let c of this._viewItems.read(e)){let d=c.contentHeight.read(e),u=Math.min(d,s),h=Wt.ofStartAndLength(o,u),f=Wt.ofStartAndLength(r,d);if(f.isBefore(a))i-=d-u,c.hide();else if(f.isAfter(a))c.hide();else{let p=Math.max(0,Math.min(a.start-f.start,d-u));i-=p;let g=Wt.ofStartAndLength(t+i,s);c.render(h,p,l,g)}o+=u+this._spaceBetweenPx,r+=d+this._spaceBetweenPx}this._scrollableElements.content.style.transform=`translateY(${-(t+i)}px)`}};Dj=zht([IBe(4,Le),IBe(5,he)],Dj);dpe=class extends D{constructor(e,t,i,o){super(),this.viewModel=e,this._objectPool=t,this._scrollLeft=i,this._deltaScrollVertical=o,this._templateRef=this._register(ag(this,void 0)),this.contentHeight=Pe(this,r=>this._templateRef.read(r)?.object.contentHeight?.read(r)??this.viewModel.lastTemplateData.read(r).contentHeight),this.maxScroll=Pe(this,r=>this._templateRef.read(r)?.object.maxScroll.read(r)??{maxScroll:0,scrollWidth:0}),this.template=Pe(this,r=>this._templateRef.read(r)?.object),this._isHidden=lt(this,!1),this._isFocused=Pe(this,r=>this.template.read(r)?.isFocused.read(r)??!1),this.viewModel.setIsFocused(this._isFocused,void 0),this._register(He(r=>{let s=this._scrollLeft.read(r);this._templateRef.read(r)?.object.setScrollLeft(s)})),this._register(He(r=>{let s=this._templateRef.read(r);!s||!this._isHidden.read(r)||s.object.isFocused.read(r)||this._clear()}))}dispose(){this._clear(),super.dispose()}toString(){return`VirtualViewItem(${this.viewModel.documentDiffItem.modified?.uri.toString()})`}getKey(){return this.viewModel.getKey()}setViewState(e,t){this.viewModel.collapsed.set(e.collapsed,t),this._updateTemplateData(t);let i=this.viewModel.lastTemplateData.get(),o=e.selections?.map(Se.liftSelection);this.viewModel.lastTemplateData.set({...i,selections:o},t);let r=this._templateRef.get();r&&o&&r.object.editor.setSelections(o)}_updateTemplateData(e){let t=this._templateRef.get();t&&this.viewModel.lastTemplateData.set({contentHeight:t.object.contentHeight.get(),selections:t.object.editor.getSelections()??void 0},e)}_clear(){let e=this._templateRef.get();e&&xi(t=>{this._updateTemplateData(t),e.object.hide(),this._templateRef.set(void 0,t)})}hide(){this._isHidden.set(!0,void 0)}render(e,t,i,o){this._isHidden.set(!1,void 0);let r=this._templateRef.get();if(!r){r=this._objectPool.getUnusedObj(new Ej(this.viewModel,this._deltaScrollVertical)),this._templateRef.set(r,void 0);let s=this.viewModel.lastTemplateData.get().selections;s&&r.object.editor.setSelections(s)}r.object.render(e,i,t,o)}}});var iPi,nPi,oPi,TBe=k(()=>{pe();Wn();iPi=R("multiDiffEditor.headerBackground",{dark:"#262626",light:"tab.inactiveBackground",hcDark:"tab.inactiveBackground",hcLight:"tab.inactiveBackground"},m("multiDiffEditor.headerBackground","The background color of the diff editor's header")),nPi=R("multiDiffEditor.background",$c,m("multiDiffEditor.background","The background color of the multi file diff editor")),oPi=R("multiDiffEditor.border",{dark:"sideBarSectionHeader.border",light:"#cccccc",hcDark:"sideBarSectionHeader.border",hcLight:"#cccccc"},m("multiDiffEditor.border","The border color of the multi file diff editor"))});var Vht,Uht,Nj,DBe=k(()=>{j();Oi();iT();EBe();Fe();TBe();cpe();Vht=function(n,e,t,i){var o=arguments.length,r=o<3?e:i===null?i=Object.getOwnPropertyDescriptor(e,t):i,s;if(typeof Reflect=="object"&&typeof Reflect.decorate=="function")r=Reflect.decorate(n,e,t,i);else for(var a=n.length-1;a>=0;a--)(s=n[a])&&(r=(o<3?s(r):o>3?s(e,t,r):s(e,t))||r);return o>3&&r&&Object.defineProperty(e,t,r),r},Uht=function(n,e){return function(t,i){e(t,i,n)}},Nj=class extends D{constructor(e,t,i){super(),this._element=e,this._workbenchUIElementFactory=t,this._instantiationService=i,this._dimension=lt(this,void 0),this._viewModel=lt(this,void 0),this._widgetImpl=hc(this,(o,r)=>(Na(cT,o),r.add(this._instantiationService.createInstance(Na(Dj,o),this._element,this._dimension,this._viewModel,this._workbenchUIElementFactory)))),this._register(If(this._widgetImpl))}};Nj=Vht([Uht(2,he)],Nj)});function $ht(n,e,t){return bt.initialize(t||{}).createInstance(Lj,n,e)}function jht(n){return bt.get(xt).onCodeEditorAdd(t=>{n(t)})}function qht(n){return bt.get(xt).onDiffEditorAdd(t=>{n(t)})}function Kht(){return bt.get(xt).listCodeEditors()}function Ght(){return bt.get(xt).listDiffEditors()}function Yht(n,e,t){return bt.initialize(t||{}).createInstance(Ij,n,e)}function Zht(n,e){let t=bt.initialize(e||{});return new Nj(n,{},t)}function Xht(n){if(typeof n.id!="string"||typeof n.run!="function")throw new Error("Invalid command descriptor, `id` and `run` are required properties!");return wt.registerCommand(n.id,n.run)}function Qht(n){if(typeof n.id!="string"||typeof n.label!="string"||typeof n.run!="function")throw new Error("Invalid action descriptor, `id`, `label` and `run` are required properties!");let e=Y.deserialize(n.precondition),t=(o,...r)=>hn.runEditorCommand(o,r,e,(s,a,l)=>Promise.resolve(n.run(a,...l))),i=new H;if(i.add(wt.registerCommand(n.id,t)),n.contextMenuGroupId){let o={command:{id:n.id,title:n.label},when:e,group:n.contextMenuGroupId,order:n.contextMenuOrder||0};i.add(Lo.appendMenuItem(Te.EditorContext,o))}if(Array.isArray(n.keybindings)){let o=bt.get(_t);if(!(o instanceof Ew))console.warn("Cannot add keybinding because the editor is configured with an unrecognized KeybindingService");else{let r=Y.and(e,Y.deserialize(n.keybindingContext));i.add(o.addDynamicKeybindings(n.keybindings.map(s=>({keybinding:s,command:n.id,when:r}))))}}return i}function Jht(n){return NBe([n])}function NBe(n){let e=bt.get(_t);return e instanceof Ew?e.addDynamicKeybindings(n.map(t=>({keybinding:t.keybinding,command:t.command,commandArgs:t.commandArgs,when:Y.deserialize(t.when)}))):(console.warn("Cannot add keybinding because the editor is configured with an unrecognized KeybindingService"),D.None)}function eft(n,e,t){let i=bt.get(ai),o=i.getLanguageIdByMimeType(e)||e;return lpe(bt.get(di),i,n,o,t)}function tft(n,e){let t=bt.get(ai),i=t.getLanguageIdByMimeType(e)||e||Oo;n.setLanguage(t.createById(i))}function ift(n,e,t){n&&bt.get(Xc).changeOne(e,n.uri,t)}function nft(n){bt.get(Xc).changeAll(n,[])}function oft(n){return bt.get(Xc).read(n)}function rft(n){return bt.get(Xc).onMarkerChanged(n)}function sft(n){return bt.get(di).getModel(n)}function aft(){return bt.get(di).getModels()}function lft(n){return bt.get(di).onModelAdded(n)}function cft(n){return bt.get(di).onModelRemoved(n)}function dft(n){return bt.get(di).onModelLanguageChanged(t=>{n({model:t.model,oldLanguage:t.oldLanguageId})})}function uft(n){return U5e(bt.get(di),n)}function hft(n,e){let t=bt.get(ai),i=bt.get(La);return _E.colorizeElement(i,t,n,e).then(()=>{i.registerEditorContainer(n)})}function fft(n,e,t){let i=bt.get(ai);return bt.get(La).registerEditorContainer(ri.document.body),_E.colorize(i,n,e,t)}function pft(n,e,t=4){return bt.get(La).registerEditorContainer(ri.document.body),_E.colorizeModelLine(n,e,t)}function mft(n){let e=$i.get(n);return e||{getInitialState:()=>tg,tokenize:(t,i,o)=>eI(n,o)}}function gft(n,e){$i.getOrCreate(e);let t=mft(e),i=Qa(n),o=[],r=t.getInitialState();for(let s=0,a=i.length;s{if(!i)return null;let r=t.options?.selection,s;return r&&typeof r.endLineNumber=="number"&&typeof r.endColumn=="number"?s=r:r&&(s={lineNumber:r.startLineNumber,column:r.startColumn}),await n.openCodeEditor(i,t.resource,s)?i:null})}function RBe(){return{create:$ht,getEditors:Kht,getDiffEditors:Ght,onDidCreateEditor:jht,onDidCreateDiffEditor:qht,createDiffEditor:Yht,addCommand:Xht,addEditorAction:Qht,addKeybindingRule:Jht,addKeybindingRules:NBe,createModel:eft,setModelLanguage:tft,setModelMarkers:ift,getModelMarkers:oft,removeAllMarkers:nft,onDidChangeMarkers:rft,getModels:aft,getModel:sft,onDidCreateModel:lft,onWillDisposeModel:cft,onDidChangeModelLanguage:dft,createWebWorker:uft,colorizeElement:hft,colorize:fft,colorizeModelLine:pft,tokenize:gft,defineTheme:_ft,setTheme:bft,remeasureFonts:vft,registerCommand:xft,registerLinkOpener:wft,registerEditorOpener:yft,AccessibilitySupport:a8,ContentWidgetPositionPreference:f8,CursorChangeReason:p8,DefaultEndOfLine:m8,EditorAutoIndentStrategy:_8,EditorOption:b8,EndOfLinePreference:v8,EndOfLineSequence:x8,MinimapPosition:N8,MinimapSectionHeaderStyle:R8,MouseTargetType:A8,OverlayWidgetPositionPreference:O8,OverviewRulerLane:F8,GlyphMarginLane:w8,RenderLineNumbersType:H8,RenderMinimap:z8,ScrollbarVisibility:U8,ScrollType:V8,TextEditorCursorBlinkingStyle:Y8,TextEditorCursorStyle:Z8,TrackedRangeStickiness:X8,WrappingIndent:Q8,InjectedTextCursorStops:S8,PositionAffinity:W8,ShowLightbulbIconMode:j8,ConfigurationChangedEvent:jk,BareFontInfo:A1,FontInfo:M1,TextModelResolvedOptions:Ax,FindMatch:Pm,ApplyUpdateResult:ix,EditorZoom:El,createMultiFileDiffEditor:Zht,EditorType:Pb,EditorOptions:Oc}}var ABe=k(()=>{Il();j();Qe();Ai();$Te();foe();mt();Po();$5e();ir();mL();$B();q2();Ji();fs();Nd();tI();Zr();va();J8();t3e();CBe();j2();QC();an();Gi();it();Pn();gg();Ml();DBe()});function Cft(n,e){if(!e||!Array.isArray(e))return!1;for(let t of e)if(!n(t))return!1;return!0}function Rj(n,e){return typeof n=="boolean"?n:e}function MBe(n,e){return typeof n=="string"?n:e}function Sft(n){let e={};for(let t of n)e[t]=!0;return e}function PBe(n,e=!1){e&&(n=n.map(function(i){return i.toLowerCase()}));let t=Sft(n);return e?function(i){return t[i.toLowerCase()]!==void 0&&t.hasOwnProperty(i.toLowerCase())}:function(i){return t[i]!==void 0&&t.hasOwnProperty(i)}}function upe(n,e,t){e=e.replace(/@@/g,"");let i=0,o;do o=!1,e=e.replace(/@(\w+)/g,function(s,a){o=!0;let l="";if(typeof n[a]=="string")l=n[a];else if(n[a]&&n[a]instanceof RegExp)l=n[a].source;else throw n[a]===void 0?On(n,"language definition does not contain attribute '"+a+"', used at: "+e):On(n,"attribute reference '"+a+"' must be a string, used at: "+e);return Dw(l)?"":"(?:"+l+")"}),i++;while(o&&i<5);e=e.replace(/\x01/g,"@");let r=(n.ignoreCase?"i":"")+(n.unicode?"u":"");if(t&&e.match(/\$[sS](\d\d?)/g)){let a=null,l=null;return c=>(l&&a===c||(a=c,l=new RegExp(Z5e(n,e,c),r)),l)}return new RegExp(e,r)}function kft(n,e,t,i){if(i<0)return n;if(i=100){i=i-100;let o=t.split(".");if(o.unshift(t),i=0&&(i.tokenSubst=!0),typeof t.bracket=="string")if(t.bracket==="@open")i.bracket=1;else if(t.bracket==="@close")i.bracket=-1;else throw On(n,"a 'bracket' attribute must be either '@open' or '@close', in rule: "+e);if(t.next){if(typeof t.next!="string")throw On(n,"the next state must be a string value in rule: "+e);{let o=t.next;if(!/^(@pop|@push|@popall)$/.test(o)&&(o[0]==="@"&&(o=o.substr(1)),o.indexOf("$")<0&&!X5e(n,Fg(n,o,"",[],""))))throw On(n,"the next state '"+t.next+"' is not defined in rule: "+e);i.next=o}}return typeof t.goBack=="number"&&(i.goBack=t.goBack),typeof t.switchTo=="string"&&(i.switchTo=t.switchTo),typeof t.log=="string"&&(i.log=t.log),typeof t.nextEmbedded=="string"&&(i.nextEmbedded=t.nextEmbedded,n.usesEmbedded=!0),i}}else if(Array.isArray(t)){let i=[];for(let o=0,r=t.length;o=1&&c.length<=3)if(u.setRegex(i,c[0]),c.length>=3)if(typeof c[1]=="string")u.setAction(i,{token:c[1],next:c[2]});else if(typeof c[1]=="object"){let h=c[1];h.next=c[2],u.setAction(i,h)}else throw On(t,"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: "+s);else u.setAction(i,c[1]);else{if(!c.regex)throw On(t,"a rule must either be an array, or an object with a 'regex' or 'include' field at: "+s);c.name&&typeof c.name=="string"&&(u.name=c.name),c.matchOnlyAtStart&&(u.matchOnlyAtLineStart=Rj(c.matchOnlyAtLineStart,!1)),u.setRegex(i,c.regex),u.setAction(i,c.action)}a.push(u)}}}if(!e.tokenizer||typeof e.tokenizer!="object")throw On(t,"a language definition must define the 'tokenizer' attribute as an object");t.tokenizer=[];for(let s in e.tokenizer)if(e.tokenizer.hasOwnProperty(s)){t.start||(t.start=s);let a=e.tokenizer[s];t.tokenizer[s]=new Array,o("tokenizer."+s,t.tokenizer[s],a)}if(t.usesEmbedded=i.usesEmbedded,e.brackets){if(!Array.isArray(e.brackets))throw On(t,"the 'brackets' attribute must be defined as an array")}else e.brackets=[{open:"{",close:"}",token:"delimiter.curly"},{open:"[",close:"]",token:"delimiter.square"},{open:"(",close:")",token:"delimiter.parenthesis"},{open:"<",close:">",token:"delimiter.angle"}];let r=[];for(let s of e.brackets){let a=s;if(a&&Array.isArray(a)&&a.length===3&&(a={token:a[2],open:a[0],close:a[1]}),a.open===a.close)throw On(t,"open and close brackets in a 'brackets' attribute must be different: "+a.open+` hint: use the 'bracket' attribute if matching on equal brackets is required.`);if(typeof a.open=="string"&&typeof a.token=="string"&&typeof a.close=="string")r.push({token:a.token+t.tokenPostfix,open:Ap(t,a.open),close:Ap(t,a.close)});else throw On(t,"every element in the 'brackets' array must be a '{open,close,token}' object or array")}return t.brackets=r,t.noThrow=!0,t}var fpe,OBe=k(()=>{Fue();fpe=class{constructor(e){this.regex=new RegExp(""),this.action={token:""},this.matchOnlyAtLineStart=!1,this.name="",this.name=e}setRegex(e,t){let i;if(typeof t=="string")i=t;else if(t instanceof RegExp)i=t.source;else throw On(e,"rules must start with a match string or regular expression: "+this.name);this.matchOnlyAtLineStart=i.length>0&&i[0]==="^",this.name=this.name+": "+i,this.regex=upe(e,"^(?:"+(this.matchOnlyAtLineStart?i.substr(1):i)+")",!0)}setAction(e,t){this.action=hpe(e,this.name,t)}resolveRegex(e){return this.regex instanceof RegExp?this.regex:this.regex(e)}}});function Ift(n){Tx.registerLanguage(n)}function Eft(){let n=[];return n=n.concat(Tx.getLanguages()),n}function Tft(n){return bt.get(ai).languageIdCodec.encodeLanguageId(n)}function Dft(n,e){return bt.withServices(()=>{let i=bt.get(ai).onDidRequestRichLanguageFeatures(o=>{o===n&&(i.dispose(),e())});return i})}function Nft(n,e){return bt.withServices(()=>{let i=bt.get(ai).onDidRequestBasicLanguageFeatures(o=>{o===n&&(i.dispose(),e())});return i})}function Rft(n,e){if(!bt.get(ai).isRegisteredLanguageId(n))throw new Error(`Cannot set configuration for unknown language ${n}`);return bt.get(ti).register(n,e,100)}function Aft(n){return typeof n.getInitialState=="function"}function Mft(n){return"tokenizeEncoded"in n}function FBe(n){return n&&typeof n.then=="function"}function Pft(n){let e=bt.get(La);if(n){let t=[null];for(let i=1,o=n.length;i{let i=await Promise.resolve(e.create());return i?Aft(i)?BBe(n,i):new n0(bt.get(ai),bt.get(La),n,ppe(n,i),bt.get(Ve)):null});return $i.registerFactory(n,t)}function Oft(n,e){if(!bt.get(ai).isRegisteredLanguageId(n))throw new Error(`Cannot set tokens provider for unknown language ${n}`);return FBe(e)?gpe(n,{create:()=>e}):$i.register(n,BBe(n,e))}function Fft(n,e){let t=i=>new n0(bt.get(ai),bt.get(La),n,ppe(n,i),bt.get(Ve));return FBe(e)?gpe(n,{create:()=>e}):$i.register(n,t(e))}function Bft(n,e){return bt.get(le).referenceProvider.register(n,e)}function Wft(n,e){return bt.get(le).renameProvider.register(n,e)}function Hft(n,e){return bt.get(le).newSymbolNamesProvider.register(n,e)}function zft(n,e){return bt.get(le).signatureHelpProvider.register(n,e)}function Vft(n,e){return bt.get(le).hoverProvider.register(n,{provideHover:async(i,o,r,s)=>{let a=i.getWordAtPosition(o);return Promise.resolve(e.provideHover(i,o,r,s)).then(l=>{if(l)return!l.range&&a&&(l.range=new S(o.lineNumber,a.startColumn,o.lineNumber,a.endColumn)),l.range||(l.range=new S(o.lineNumber,o.column,o.lineNumber,o.column)),l})}})}function Uft(n,e){return bt.get(le).documentSymbolProvider.register(n,e)}function $ft(n,e){return bt.get(le).documentHighlightProvider.register(n,e)}function jft(n,e){return bt.get(le).linkedEditingRangeProvider.register(n,e)}function qft(n,e){return bt.get(le).definitionProvider.register(n,e)}function Kft(n,e){return bt.get(le).implementationProvider.register(n,e)}function Gft(n,e){return bt.get(le).typeDefinitionProvider.register(n,e)}function Yft(n,e){return bt.get(le).codeLensProvider.register(n,e)}function Zft(n,e,t){return bt.get(le).codeActionProvider.register(n,{providedCodeActionKinds:t?.providedCodeActionKinds,documentation:t?.documentation,provideCodeActions:(o,r,s,a)=>{let c=bt.get(Xc).read({resource:o.uri}).filter(d=>S.areIntersectingOrTouching(d,r));return e.provideCodeActions(o,r,{markers:c,only:s.only,trigger:s.trigger},a)},resolveCodeAction:e.resolveCodeAction})}function Xft(n,e){return bt.get(le).documentFormattingEditProvider.register(n,e)}function Qft(n,e){return bt.get(le).documentRangeFormattingEditProvider.register(n,e)}function Jft(n,e){return bt.get(le).onTypeFormattingEditProvider.register(n,e)}function ept(n,e){return bt.get(le).linkProvider.register(n,e)}function tpt(n,e){return bt.get(le).completionProvider.register(n,e)}function ipt(n,e){return bt.get(le).colorProvider.register(n,e)}function npt(n,e){return bt.get(le).foldingRangeProvider.register(n,e)}function opt(n,e){return bt.get(le).declarationProvider.register(n,e)}function rpt(n,e){return bt.get(le).selectionRangeProvider.register(n,e)}function spt(n,e){return bt.get(le).documentSemanticTokensProvider.register(n,e)}function apt(n,e){return bt.get(le).documentRangeSemanticTokensProvider.register(n,e)}function lpt(n,e){return bt.get(le).inlineCompletionsProvider.register(n,e)}function cpt(n,e){return bt.get(le).inlineEditProvider.register(n,e)}function dpt(n,e){return bt.get(le).inlayHintsProvider.register(n,e)}function WBe(){return{register:Ift,getLanguages:Eft,onLanguage:Dft,onLanguageEncountered:Nft,getEncodedLanguageId:Tft,setLanguageConfiguration:Rft,setColorMap:Pft,registerTokensProviderFactory:gpe,setTokensProvider:Oft,setMonarchTokensProvider:Fft,registerReferenceProvider:Bft,registerRenameProvider:Wft,registerNewSymbolNameProvider:Hft,registerCompletionItemProvider:tpt,registerSignatureHelpProvider:zft,registerHoverProvider:Vft,registerDocumentSymbolProvider:Uft,registerDocumentHighlightProvider:$ft,registerLinkedEditingRangeProvider:jft,registerDefinitionProvider:qft,registerImplementationProvider:Kft,registerTypeDefinitionProvider:Gft,registerCodeLensProvider:Yft,registerCodeActionProvider:Zft,registerDocumentFormattingEditProvider:Xft,registerDocumentRangeFormattingEditProvider:Qft,registerOnTypeFormattingEditProvider:Jft,registerLinkProvider:ept,registerColorProvider:ipt,registerFoldingRangeProvider:npt,registerDeclarationProvider:opt,registerSelectionRangeProvider:rpt,registerDocumentSemanticTokensProvider:spt,registerDocumentRangeSemanticTokensProvider:apt,registerInlineCompletionsProvider:lpt,registerInlineEditProvider:cpt,registerInlayHintsProvider:dpt,DocumentHighlightKind:g8,CompletionItemKind:d8,CompletionItemTag:u8,CompletionItemInsertTextRule:c8,SymbolKind:K8,SymbolTag:G8,IndentAction:C8,CompletionTriggerKind:h8,SignatureHelpTriggerKind:q8,InlayHintKind:k8,InlineCompletionTriggerKind:L8,InlineEditTriggerKind:I8,CodeActionTriggerType:l8,NewSymbolNameTag:M8,NewSymbolNameTriggerKind:P8,PartialAcceptTriggerKind:B8,HoverVerbosityAction:y8,FoldingRangeKind:Sm,SelectedSuggestionInfo:Qk}}var mpe,Aj,HBe=k(()=>{vo();we();Ji();fs();Ko();Nd();Qt();J8();j2();OBe();zue();QC();en();gg();mpe=class{constructor(e,t){this._languageId=e,this._actual=t}dispose(){}getInitialState(){return this._actual.getInitialState()}tokenize(e,t,i){if(typeof this._actual.tokenize=="function")return Aj.adaptTokenize(this._languageId,this._actual,e,i);throw new Error("Not supported!")}tokenizeEncoded(e,t,i){let o=this._actual.tokenizeEncoded(e,i);return new B_(o.tokens,o.endState)}},Aj=class n{constructor(e,t,i,o){this._languageId=e,this._actual=t,this._languageService=i,this._standaloneThemeService=o}dispose(){}getInitialState(){return this._actual.getInitialState()}static _toClassicTokens(e,t){let i=[],o=0;for(let r=0,s=e.length;r0&&r[s-1]===h)continue;let f=u.startIndex;c===0?f=0:f{mt();it();ci();du();Fe();Xs();pe();_pe=We("IEditorCancelService"),zBe=new me("cancellableOperation",!1,m("cancellableOperation","Whether the editor runs a cancellable operation, e.g. like 'Peek References'"));Ct(_pe,class{constructor(){this._tokens=new WeakMap}add(n,e){let t=this._tokens.get(n);t||(t=n.invokeWithinContext(o=>{let r=zBe.bindTo(o.get(Le)),s=new go;return{key:r,tokens:s}}),this._tokens.set(n,t));let i;return t.key.set(!0),i=t.tokens.push(e),()=>{i&&(i(),t.key.set(!t.tokens.isEmpty()),i=void 0)}}cancel(n){let e=this._tokens.get(n);if(!e)return;let t=e.tokens.pop();t&&(t.cancel(),e.key.set(!e.tokens.isEmpty()))}},1);Mj=class extends qt{constructor(e,t){super(t),this.editor=e,this._unregister=e.invokeWithinContext(i=>i.get(_pe).add(e,this))}dispose(){this._unregister(),super.dispose()}};ye(new class extends hn{constructor(){super({id:"editor.cancelOperation",kbOpts:{weight:100,primary:9},precondition:zBe})}runEditorCommand(n,e){n.get(_pe).cancel(e)}})});var dT,Yd,M0,Xb=k(()=>{Qe();we();ci();j();VBe();dT=class n{constructor(e,t){if(this.flags=t,(this.flags&1)!==0){let i=e.getModel();this.modelVersionId=i?dh("{0}#{1}",i.uri.toString(),i.getVersionId()):null}else this.modelVersionId=null;(this.flags&4)!==0?this.position=e.getPosition():this.position=null,(this.flags&2)!==0?this.selection=e.getSelection():this.selection=null,(this.flags&8)!==0?(this.scrollLeft=e.getScrollLeft(),this.scrollTop=e.getScrollTop()):(this.scrollLeft=-1,this.scrollTop=-1)}_equals(e){if(!(e instanceof n))return!1;let t=e;return!(this.modelVersionId!==t.modelVersionId||this.scrollLeft!==t.scrollLeft||this.scrollTop!==t.scrollTop||!this.position&&t.position||this.position&&!t.position||this.position&&t.position&&!this.position.equals(t.position)||!this.selection&&t.selection||this.selection&&!t.selection||this.selection&&t.selection&&!this.selection.equalsRange(t.selection))}validate(e){return this._equals(new n(e,this.flags))}},Yd=class extends Mj{constructor(e,t,i,o){super(e,o),this._listener=new H,t&4&&this._listener.add(e.onDidChangeCursorPosition(r=>{(!i||!S.containsPosition(i,r.position))&&this.cancel()})),t&2&&this._listener.add(e.onDidChangeCursorSelection(r=>{(!i||!S.containsRange(i,r.selection))&&this.cancel()})),t&8&&this._listener.add(e.onDidScrollChange(r=>this.cancel())),t&1&&(this._listener.add(e.onDidChangeModel(r=>this.cancel())),this._listener.add(e.onDidChangeModelContent(r=>this.cancel())))}dispose(){this._listener.dispose(),super.dispose()}},M0=class extends qt{constructor(e,t){super(t),this._listener=e.onDidChangeContent(()=>this.cancel())}dispose(){this._listener.dispose(),super.dispose()}}});function Bf(n){return n&&typeof n.getEditorType=="function"?n.getEditorType()===Pb.ICodeEditor:!1}function RP(n){return n&&typeof n.getEditorType=="function"?n.getEditorType()===Pb.IDiffEditor:!1}function upt(n){return!!n&&typeof n=="object"&&typeof n.onDidChangeActiveEditor=="function"}function Pj(n){return Bf(n)?n:RP(n)?n.getModifiedEditor():upt(n)&&Bf(n.activeCodeEditor)?n.activeCodeEditor:null}var uT=k(()=>{q2()});var P0,bpe=k(()=>{Tu();we();L0();P0=class n{static _handleEolEdits(e,t){let i,o=[];for(let r of t)typeof r.eol=="number"&&(i=r.eol),r.range&&typeof r.text=="string"&&o.push(r);return typeof i=="number"&&e.hasModel()&&e.getModel().pushEOL(i),o}static _isFullModelReplaceEdit(e,t){if(!e.hasModel())return!1;let i=e.getModel(),o=i.validateRange(t.range);return i.getFullModelRange().equalsRange(o)}static execute(e,t,i){i&&e.pushUndoStop();let o=od.capture(e),r=n._handleEolEdits(e,t);r.length===1&&n._isFullModelReplaceEdit(e,r[0])?e.executeEdits("formatEditsCommand",r.map(s=>Pi.replace(S.lift(s.range),s.text))):e.executeEdits("formatEditsCommand",r.map(s=>Pi.replaceMove(S.lift(s.range),s.text))),i&&e.pushUndoStop(),o.restoreRelativeVerticalPositionOfCursor(e)}}});var Oj,Fj,UBe=k(()=>{Oj=class{constructor(e){this.value=e,this._lower=e.toLowerCase()}static toKey(e){return typeof e=="string"?e.toLowerCase():e._lower}},Fj=class{constructor(e){if(this._set=new Set,e)for(let t of e)this.add(t)}add(e){this._set.add(Oj.toKey(e))}has(e){return this._set.has(Oj.toKey(e))}}});function $Be(n,e,t){let i=[],o=new Fj,r=n.ordered(t);for(let a of r)i.push(a),a.extensionId&&o.add(a.extensionId);let s=e.ordered(t);for(let a of s){if(a.extensionId){if(o.has(a.extensionId))continue;o.add(a.extensionId)}i.push({displayName:a.displayName,extensionId:a.extensionId,provideDocumentFormattingEdits(l,c,d){return a.provideDocumentRangeFormattingEdits(l,l.getFullModelRange(),c,d)}})}return i}async function vpe(n,e,t,i,o,r,s){let a=n.get(he),{documentRangeFormattingEditProvider:l}=n.get(le),c=Bf(e)?e.getModel():e,d=l.ordered(c),u=await hT.select(d,c,i,2);u&&(o.report(u),await a.invokeFunction(hpt,u,e,t,r,s))}async function hpt(n,e,t,i,o,r){let s=n.get(kr),a=n.get(Bn),l=n.get(jd),c,d;Bf(t)?(c=t.getModel(),d=new Yd(t,5,void 0,o)):(c=t,d=new M0(t,o));let u=[],h=0;for(let b of Hk(i).sort(S.compareRangesUsingStarts))h>0&&S.areIntersectingOrTouching(u[h-1],b)?u[h-1]=S.fromPositions(u[h-1].getStartPosition(),b.getEndPosition()):h=u.push(b);let f=async b=>{a.trace("[format][provideDocumentRangeFormattingEdits] (request)",e.extensionId?.value,b);let v=await e.provideDocumentRangeFormattingEdits(c,b,c.getFormattingOptions(),d.token)||[];return a.trace("[format][provideDocumentRangeFormattingEdits] (response)",e.extensionId?.value,v),v},p=(b,v)=>{if(!b.length||!v.length)return!1;let x=b.reduce((w,y)=>S.plusRange(w,y.range),b[0].range);if(!v.some(w=>S.intersectRanges(x,w.range)))return!1;for(let w of b)for(let y of v)if(S.intersectRanges(w.range,y.range))return!0;return!1},g=[],_=[];try{if(typeof e.provideDocumentRangesFormattingEdits=="function"){a.trace("[format][provideDocumentRangeFormattingEdits] (request)",e.extensionId?.value,u);let b=await e.provideDocumentRangesFormattingEdits(c,u,c.getFormattingOptions(),d.token)||[];a.trace("[format][provideDocumentRangeFormattingEdits] (response)",e.extensionId?.value,b),_.push(b)}else{for(let b of u){if(d.token.isCancellationRequested)return!0;_.push(await f(b))}for(let b=0;b({text:x.text,range:S.lift(x.range),forceMoveMarkers:!0})),x=>{for(let{range:w}of x)if(S.areIntersectingOrTouching(w,v))return[new Se(w.startLineNumber,w.startColumn,w.endLineNumber,w.endColumn)];return null})}return l.playSignal(sl.format,{userGesture:r}),!0}async function jBe(n,e,t,i,o,r){let s=n.get(he),a=n.get(le),l=Bf(e)?e.getModel():e,c=$Be(a.documentFormattingEditProvider,a.documentRangeFormattingEditProvider,l),d=await hT.select(c,l,t,1);d&&(i.report(d),await s.invokeFunction(fpt,d,e,t,o,r))}async function fpt(n,e,t,i,o,r){let s=n.get(kr),a=n.get(jd),l,c;Bf(t)?(l=t.getModel(),c=new Yd(t,5,void 0,o)):(l=t,c=new M0(t,o));let d;try{let u=await e.provideDocumentFormattingEdits(l,l.getFormattingOptions(),c.token);if(d=await s.computeMoreMinimalEdits(l.uri,u),c.token.isCancellationRequested)return!0}finally{c.dispose()}if(!d||d.length===0)return!1;if(Bf(t))P0.execute(t,d,i!==2),i!==2&&t.revealPositionInCenterIfOutsideViewport(t.getPosition(),1);else{let[{range:u}]=d,h=new Se(u.startLineNumber,u.startColumn,u.endLineNumber,u.endColumn);l.pushEditOperations([h],d.map(f=>({text:f.text,range:S.lift(f.range),forceMoveMarkers:!0})),f=>{for(let{range:p}of f)if(S.areIntersectingOrTouching(p,h))return[new Se(p.startLineNumber,p.startColumn,p.endLineNumber,p.endColumn)];return null})}return a.playSignal(sl.format,{userGesture:r}),!0}async function ppt(n,e,t,i,o,r){let s=e.documentRangeFormattingEditProvider.ordered(t);for(let a of s){let l=await Promise.resolve(a.provideDocumentRangeFormattingEdits(t,i,o,r)).catch(mi);if(So(l))return await n.computeMoreMinimalEdits(t.uri,l)}}async function mpt(n,e,t,i,o){let r=$Be(e.documentFormattingEditProvider,e.documentRangeFormattingEditProvider,t);for(let s of r){let a=await Promise.resolve(s.provideDocumentFormattingEdits(t,i,o)).catch(mi);if(So(a))return await n.computeMoreMinimalEdits(t.uri,a)}}function xpe(n,e,t,i,o,r,s){let a=e.onTypeFormattingEditProvider.ordered(t);return a.length===0||a[0].autoFormatTriggerCharacters.indexOf(o)<0?Promise.resolve(void 0):Promise.resolve(a[0].provideOnTypeFormattingEdits(t,i,o,r,s)).catch(mi).then(l=>n.computeMoreMinimalEdits(t.uri,l))}var hT,wpe=k(()=>{at();ci();je();Cl();du();yi();Ai();Xb();uT();qe();we();Ui();Ip();vu();bpe();Gi();UBe();Fe();Qt();ac();Lw();hT=class n{static{this._selectors=new go}static setFormatterSelector(e){return{dispose:n._selectors.unshift(e)}}static async select(e,t,i,o){if(e.length===0)return;let r=Dt.first(n._selectors);if(r)return await r(e,t,i,o)}};wt.registerCommand("_executeFormatRangeProvider",async function(n,...e){let[t,i,o]=e;At(Ee.isUri(t)),At(S.isIRange(i));let r=n.get(Uo),s=n.get(kr),a=n.get(le),l=await r.createModelReference(t);try{return ppt(s,a,l.object.textEditorModel,S.lift(i),o,Ze.None)}finally{l.dispose()}});wt.registerCommand("_executeFormatDocumentProvider",async function(n,...e){let[t,i]=e;At(Ee.isUri(t));let o=n.get(Uo),r=n.get(kr),s=n.get(le),a=await o.createModelReference(t);try{return mpt(r,s,a.object.textEditorModel,i,Ze.None)}finally{a.dispose()}});wt.registerCommand("_executeFormatOnTypeProvider",async function(n,...e){let[t,i,o,r]=e;At(Ee.isUri(t)),At(P.isIPosition(i)),At(typeof o=="string");let s=n.get(Uo),a=n.get(kr),l=n.get(le),c=await s.createModelReference(t);try{return xpe(a,l,c.object.textEditorModel,P.lift(i),o,r,Ze.None)}finally{c.dispose()}})});var fn={};st(fn,{CancellationTokenSource:()=>gpt,Emitter:()=>_pt,KeyCode:()=>bpt,KeyMod:()=>vpt,MarkerSeverity:()=>Spt,MarkerTag:()=>kpt,Position:()=>xpt,Range:()=>wpt,Selection:()=>ypt,SelectionDirection:()=>Cpt,Token:()=>Lpt,Uri:()=>AP,editor:()=>rd,languages:()=>Ipt});var vc,gpt,_pt,bpt,vpt,xpt,wpt,ypt,Cpt,Spt,kpt,AP,Lpt,rd,Ipt,Ept,Ir=k(()=>{ir();Ene();ABe();HBe();wpe();Oc.wrappingIndent.defaultValue=0;Oc.glyphMargin.defaultValue=!1;Oc.autoIndent.defaultValue=3;Oc.overviewRulerLanes.defaultValue=2;hT.setFormatterSelector((n,e,t)=>Promise.resolve(n[0]));vc=eB();vc.editor=RBe();vc.languages=WBe();gpt=vc.CancellationTokenSource,_pt=vc.Emitter,bpt=vc.KeyCode,vpt=vc.KeyMod,xpt=vc.Position,wpt=vc.Range,ypt=vc.Selection,Cpt=vc.SelectionDirection,Spt=vc.MarkerSeverity,kpt=vc.MarkerTag,AP=vc.Uri,Lpt=vc.Token,rd=vc.editor,Ipt=vc.languages,Ept=globalThis.MonacoEnvironment;(Ept?.globalAPI||typeof define=="function"&&define.amd)&&(globalThis.monaco=vc);typeof globalThis.require<"u"&&typeof globalThis.require.config=="function"&&globalThis.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"]})});var YBe={};st(YBe,{conf:()=>Ppt,language:()=>Opt});var Ppt,Opt,ZBe=k(()=>{Ppt={comments:{lineComment:"*"},brackets:[["[","]"],["(",")"]]},Opt={defaultToken:"invalid",ignoreCase:!0,tokenPostfix:".abap",keywords:["abap-source","abbreviated","abstract","accept","accepting","according","activation","actual","add","add-corresponding","adjacent","after","alias","aliases","align","all","allocate","alpha","analysis","analyzer","and","append","appendage","appending","application","archive","area","arithmetic","as","ascending","aspect","assert","assign","assigned","assigning","association","asynchronous","at","attributes","authority","authority-check","avg","back","background","backup","backward","badi","base","before","begin","between","big","binary","bintohex","bit","black","blank","blanks","blob","block","blocks","blue","bound","boundaries","bounds","boxed","break-point","buffer","by","bypassing","byte","byte-order","call","calling","case","cast","casting","catch","center","centered","chain","chain-input","chain-request","change","changing","channels","character","char-to-hex","check","checkbox","ci_","circular","class","class-coding","class-data","class-events","class-methods","class-pool","cleanup","clear","client","clob","clock","close","coalesce","code","coding","col_background","col_group","col_heading","col_key","col_negative","col_normal","col_positive","col_total","collect","color","column","columns","comment","comments","commit","common","communication","comparing","component","components","compression","compute","concat","concat_with_space","concatenate","cond","condense","condition","connect","connection","constants","context","contexts","continue","control","controls","conv","conversion","convert","copies","copy","corresponding","country","cover","cpi","create","creating","critical","currency","currency_conversion","current","cursor","cursor-selection","customer","customer-function","dangerous","data","database","datainfo","dataset","date","dats_add_days","dats_add_months","dats_days_between","dats_is_valid","daylight","dd/mm/yy","dd/mm/yyyy","ddmmyy","deallocate","decimal_shift","decimals","declarations","deep","default","deferred","define","defining","definition","delete","deleting","demand","department","descending","describe","destination","detail","dialog","directory","disconnect","display","display-mode","distinct","divide","divide-corresponding","division","do","dummy","duplicate","duplicates","duration","during","dynamic","dynpro","edit","editor-call","else","elseif","empty","enabled","enabling","encoding","end","endat","endcase","endcatch","endchain","endclass","enddo","endenhancement","end-enhancement-section","endexec","endform","endfunction","endian","endif","ending","endinterface","end-lines","endloop","endmethod","endmodule","end-of-definition","end-of-editing","end-of-file","end-of-page","end-of-selection","endon","endprovide","endselect","end-test-injection","end-test-seam","endtry","endwhile","endwith","engineering","enhancement","enhancement-point","enhancements","enhancement-section","entries","entry","enum","environment","equiv","errormessage","errors","escaping","event","events","exact","except","exception","exceptions","exception-table","exclude","excluding","exec","execute","exists","exit","exit-command","expand","expanding","expiration","explicit","exponent","export","exporting","extend","extended","extension","extract","fail","fetch","field","field-groups","fields","field-symbol","field-symbols","file","filter","filters","filter-table","final","find","first","first-line","fixed-point","fkeq","fkge","flush","font","for","form","format","forward","found","frame","frames","free","friends","from","function","functionality","function-pool","further","gaps","generate","get","giving","gkeq","gkge","global","grant","green","group","groups","handle","handler","harmless","hashed","having","hdb","header","headers","heading","head-lines","help-id","help-request","hextobin","hide","high","hint","hold","hotspot","icon","id","identification","identifier","ids","if","ignore","ignoring","immediately","implementation","implementations","implemented","implicit","import","importing","in","inactive","incl","include","includes","including","increment","index","index-line","infotypes","inheriting","init","initial","initialization","inner","inout","input","insert","instance","instances","instr","intensified","interface","interface-pool","interfaces","internal","intervals","into","inverse","inverted-date","is","iso","job","join","keep","keeping","kernel","key","keys","keywords","kind","language","last","late","layout","leading","leave","left","left-justified","leftplus","leftspace","legacy","length","let","level","levels","like","line","lines","line-count","linefeed","line-selection","line-size","list","listbox","list-processing","little","llang","load","load-of-program","lob","local","locale","locator","logfile","logical","log-point","long","loop","low","lower","lpad","lpi","ltrim","mail","main","major-id","mapping","margin","mark","mask","match","matchcode","max","maximum","medium","members","memory","mesh","message","message-id","messages","messaging","method","methods","min","minimum","minor-id","mm/dd/yy","mm/dd/yyyy","mmddyy","mode","modif","modifier","modify","module","move","move-corresponding","multiply","multiply-corresponding","name","nametab","native","nested","nesting","new","new-line","new-page","new-section","next","no","no-display","no-extension","no-gap","no-gaps","no-grouping","no-heading","no-scrolling","no-sign","no-title","no-topofpage","no-zero","node","nodes","non-unicode","non-unique","not","null","number","object","objects","obligatory","occurrence","occurrences","occurs","of","off","offset","ole","on","only","open","option","optional","options","or","order","other","others","out","outer","output","output-length","overflow","overlay","pack","package","pad","padding","page","pages","parameter","parameters","parameter-table","part","partially","pattern","percentage","perform","performing","person","pf1","pf10","pf11","pf12","pf13","pf14","pf15","pf2","pf3","pf4","pf5","pf6","pf7","pf8","pf9","pf-status","pink","places","pool","pos_high","pos_low","position","pragmas","precompiled","preferred","preserving","primary","print","print-control","priority","private","procedure","process","program","property","protected","provide","public","push","pushbutton","put","queue-only","quickinfo","radiobutton","raise","raising","range","ranges","read","reader","read-only","receive","received","receiver","receiving","red","redefinition","reduce","reduced","ref","reference","refresh","regex","reject","remote","renaming","replace","replacement","replacing","report","request","requested","reserve","reset","resolution","respecting","responsible","result","results","resumable","resume","retry","return","returncode","returning","returns","right","right-justified","rightplus","rightspace","risk","rmc_communication_failure","rmc_invalid_status","rmc_system_failure","role","rollback","rows","rpad","rtrim","run","sap","sap-spool","saving","scale_preserving","scale_preserving_scientific","scan","scientific","scientific_with_leading_zero","scroll","scroll-boundary","scrolling","search","secondary","seconds","section","select","selection","selections","selection-screen","selection-set","selection-sets","selection-table","select-options","send","separate","separated","set","shared","shift","short","shortdump-id","sign_as_postfix","single","size","skip","skipping","smart","some","sort","sortable","sorted","source","specified","split","spool","spots","sql","sqlscript","stable","stamp","standard","starting","start-of-editing","start-of-selection","state","statement","statements","static","statics","statusinfo","step-loop","stop","structure","structures","style","subkey","submatches","submit","subroutine","subscreen","subtract","subtract-corresponding","suffix","sum","summary","summing","supplied","supply","suppress","switch","switchstates","symbol","syncpoints","syntax","syntax-check","syntax-trace","system-call","system-exceptions","system-exit","tab","tabbed","table","tables","tableview","tabstrip","target","task","tasks","test","testing","test-injection","test-seam","text","textpool","then","throw","time","times","timestamp","timezone","tims_is_valid","title","titlebar","title-lines","to","tokenization","tokens","top-lines","top-of-page","trace-file","trace-table","trailing","transaction","transfer","transformation","translate","transporting","trmac","truncate","truncation","try","tstmp_add_seconds","tstmp_current_utctimestamp","tstmp_is_valid","tstmp_seconds_between","type","type-pool","type-pools","types","uline","unassign","under","unicode","union","unique","unit_conversion","unix","unpack","until","unwind","up","update","upper","user","user-command","using","utf-8","valid","value","value-request","values","vary","varying","verification-message","version","via","view","visible","wait","warning","when","whenever","where","while","width","window","windows","with","with-heading","without","with-title","word","work","write","writer","xml","xsd","yellow","yes","yymmdd","zero","zone","abap_system_timezone","abap_user_timezone","access","action","adabas","adjust_numbers","allow_precision_loss","allowed","amdp","applicationuser","as_geo_json","as400","associations","balance","behavior","breakup","bulk","cds","cds_client","check_before_save","child","clients","corr","corr_spearman","cross","cycles","datn_add_days","datn_add_months","datn_days_between","dats_from_datn","dats_tims_to_tstmp","dats_to_datn","db2","db6","ddl","dense_rank","depth","deterministic","discarding","entities","entity","error","failed","finalize","first_value","fltp_to_dec","following","fractional","full","graph","grouping","hierarchy","hierarchy_ancestors","hierarchy_ancestors_aggregate","hierarchy_descendants","hierarchy_descendants_aggregate","hierarchy_siblings","incremental","indicators","lag","last_value","lead","leaves","like_regexpr","link","locale_sap","lock","locks","many","mapped","matched","measures","median","mssqlnt","multiple","nodetype","ntile","nulls","occurrences_regexpr","one","operations","oracle","orphans","over","parent","parents","partition","pcre","period","pfcg_mapping","preceding","privileged","product","projection","rank","redirected","replace_regexpr","reported","response","responses","root","row","row_number","sap_system_date","save","schema","session","sets","shortdump","siblings","spantree","start","stddev","string_agg","subtotal","sybase","tims_from_timn","tims_to_timn","to_blob","to_clob","total","trace-entry","tstmp_to_dats","tstmp_to_dst","tstmp_to_tims","tstmpl_from_utcl","tstmpl_to_utcl","unbounded","utcl_add_seconds","utcl_current","utcl_seconds_between","uuid","var","verbatim"],builtinFunctions:["abs","acos","asin","atan","bit-set","boolc","boolx","ceil","char_off","charlen","cmax","cmin","concat_lines_of","contains","contains_any_not_of","contains_any_of","cos","cosh","count","count_any_not_of","count_any_of","dbmaxlen","distance","escape","exp","find_any_not_of","find_any_of","find_end","floor","frac","from_mixed","ipow","line_exists","line_index","log","log10","matches","nmax","nmin","numofchar","repeat","rescale","reverse","round","segment","shift_left","shift_right","sign","sin","sinh","sqrt","strlen","substring","substring_after","substring_before","substring_from","substring_to","tan","tanh","to_lower","to_mixed","to_upper","trunc","utclong_add","utclong_current","utclong_diff","xsdbool","xstrlen"],typeKeywords:["b","c","d","decfloat16","decfloat34","f","i","int8","n","p","s","string","t","utclong","x","xstring","any","clike","csequence","decfloat","numeric","simple","xsequence","accp","char","clnt","cuky","curr","datn","dats","d16d","d16n","d16r","d34d","d34n","d34r","dec","df16_dec","df16_raw","df34_dec","df34_raw","fltp","geom_ewkb","int1","int2","int4","lang","lchr","lraw","numc","quan","raw","rawstring","sstring","timn","tims","unit","utcl","df16_scl","df34_scl","prec","varc","abap_bool","abap_false","abap_true","abap_undefined","me","screen","space","super","sy","syst","table_line","*sys*"],builtinMethods:["class_constructor","constructor"],derivedTypes:["%CID","%CID_REF","%CONTROL","%DATA","%ELEMENT","%FAIL","%KEY","%MSG","%PARAM","%PID","%PID_ASSOC","%PID_PARENT","%_HINTS"],cdsLanguage:["@AbapAnnotation","@AbapCatalog","@AccessControl","@API","@ClientDependent","@ClientHandling","@CompatibilityContract","@DataAging","@EndUserText","@Environment","@LanguageDependency","@MappingRole","@Metadata","@MetadataExtension","@ObjectModel","@Scope","@Semantics","$EXTENSION","$SELF"],selectors:["->","->*","=>","~","~*"],operators:[" +"," -","/","*","**","div","mod","=","#","@","+=","-=","*=","/=","**=","&&=","?=","&","&&","bit-and","bit-not","bit-or","bit-xor","m","o","z","<"," >","<=",">=","<>","><","=<","=>","bt","byte-ca","byte-cn","byte-co","byte-cs","byte-na","byte-ns","ca","cn","co","cp","cs","eq","ge","gt","le","lt","na","nb","ne","np","ns","*/","*:","--","/*","//"],symbols:/[=>))*/,{cases:{"@typeKeywords":"type","@keywords":"keyword","@cdsLanguage":"annotation","@derivedTypes":"type","@builtinFunctions":"type","@builtinMethods":"type","@operators":"key","@default":"identifier"}}],[/<[\w]+>/,"identifier"],[/##[\w|_]+/,"comment"],{include:"@whitespace"},[/[:,.]/,"delimiter"],[/[{}()\[\]]/,"@brackets"],[/@symbols/,{cases:{"@selectors":"tag","@operators":"key","@default":""}}],[/'/,{token:"string",bracket:"@open",next:"@stringquote"}],[/`/,{token:"string",bracket:"@open",next:"@stringping"}],[/\|/,{token:"string",bracket:"@open",next:"@stringtemplate"}],[/\d+/,"number"]],stringtemplate:[[/[^\\\|]+/,"string"],[/\\\|/,"string"],[/\|/,{token:"string",bracket:"@close",next:"@pop"}]],stringping:[[/[^\\`]+/,"string"],[/`/,{token:"string",bracket:"@close",next:"@pop"}]],stringquote:[[/[^\\']+/,"string"],[/'/,{token:"string",bracket:"@close",next:"@pop"}]],whitespace:[[/[ \t\r\n]+/,""],[/^\*.*$/,"comment"],[/\".*$/,"comment"]]}}});var XBe={};st(XBe,{conf:()=>Fpt,language:()=>Hpt});var Fpt,Bpt,Wpt,Bj,Hpt,QBe=k(()=>{Fpt={wordPattern:/(-?\d*\.\d\w*)|([^\`\~\!\#\%\^\&\*\(\)\-\=\+\[\{\]\}\\\|\;\:\'\"\,\.\<\>\/\?\s]+)/g,comments:{lineComment:"//",blockComment:["/*","*/"]},brackets:[["{","}"],["[","]"],["(",")"]],autoClosingPairs:[{open:"{",close:"}"},{open:"[",close:"]"},{open:"(",close:")"},{open:'"',close:'"'},{open:"'",close:"'"}],surroundingPairs:[{open:"{",close:"}"},{open:"[",close:"]"},{open:"(",close:")"},{open:'"',close:'"'},{open:"'",close:"'"},{open:"<",close:">"}],folding:{markers:{start:new RegExp("^\\s*//\\s*(?:(?:#?region\\b)|(?:))")}}},Bpt=["abstract","activate","and","any","array","as","asc","assert","autonomous","begin","bigdecimal","blob","boolean","break","bulk","by","case","cast","catch","char","class","collect","commit","const","continue","convertcurrency","decimal","default","delete","desc","do","double","else","end","enum","exception","exit","export","extends","false","final","finally","float","for","from","future","get","global","goto","group","having","hint","if","implements","import","in","inner","insert","instanceof","int","interface","into","join","last_90_days","last_month","last_n_days","last_week","like","limit","list","long","loop","map","merge","native","new","next_90_days","next_month","next_n_days","next_week","not","null","nulls","number","object","of","on","or","outer","override","package","parallel","pragma","private","protected","public","retrieve","return","returning","rollback","savepoint","search","select","set","short","sort","stat","static","strictfp","super","switch","synchronized","system","testmethod","then","this","this_month","this_week","throw","throws","today","tolabel","tomorrow","transaction","transient","trigger","true","try","type","undelete","update","upsert","using","virtual","void","volatile","webservice","when","where","while","yesterday"],Wpt=n=>n.charAt(0).toUpperCase()+n.substr(1),Bj=[];Bpt.forEach(n=>{Bj.push(n),Bj.push(n.toUpperCase()),Bj.push(Wpt(n))});Hpt={defaultToken:"",tokenPostfix:".apex",keywords:Bj,operators:["=",">","<","!","~","?",":","==","<=",">=","!=","&&","||","++","--","+","-","*","/","&","|","^","%","<<",">>",">>>","+=","-=","*=","/=","&=","|=","^=","%=","<<=",">>=",">>>="],symbols:/[=>](?!@symbols)/,"@brackets"],[/@symbols/,{cases:{"@operators":"delimiter","@default":""}}],[/@\s*[a-zA-Z_\$][\w\$]*/,"annotation"],[/(@digits)[eE]([\-+]?(@digits))?[fFdD]?/,"number.float"],[/(@digits)\.(@digits)([eE][\-+]?(@digits))?[fFdD]?/,"number.float"],[/(@digits)[fFdD]/,"number.float"],[/(@digits)[lL]?/,"number"],[/[;,.]/,"delimiter"],[/"([^"\\]|\\.)*$/,"string.invalid"],[/'([^'\\]|\\.)*$/,"string.invalid"],[/"/,"string",'@string."'],[/'/,"string","@string.'"],[/'[^\\']'/,"string"],[/(')(@escapes)(')/,["string","string.escape","string"]],[/'/,"string.invalid"]],whitespace:[[/[ \t\r\n]+/,""],[/\/\*\*(?!\/)/,"comment.doc","@apexdoc"],[/\/\*/,"comment","@comment"],[/\/\/.*$/,"comment"]],comment:[[/[^\/*]+/,"comment"],[/\*\//,"comment","@pop"],[/[\/*]/,"comment"]],apexdoc:[[/[^\/*]+/,"comment.doc"],[/\*\//,"comment.doc","@pop"],[/[\/*]/,"comment.doc"]],string:[[/[^\\"']+/,"string"],[/@escapes/,"string.escape"],[/\\./,"string.escape.invalid"],[/["']/,{cases:{"$#==$S2":{token:"string",next:"@pop"},"@default":"string"}}]]}}});var JBe={};st(JBe,{conf:()=>zpt,language:()=>Vpt});var zpt,Vpt,e6e=k(()=>{zpt={comments:{lineComment:"#"}},Vpt={defaultToken:"keyword",ignoreCase:!0,tokenPostfix:".azcli",str:/[^#\s]/,tokenizer:{root:[{include:"@comment"},[/\s-+@str*\s*/,{cases:{"@eos":{token:"key.identifier",next:"@popall"},"@default":{token:"key.identifier",next:"@type"}}}],[/^-+@str*\s*/,{cases:{"@eos":{token:"key.identifier",next:"@popall"},"@default":{token:"key.identifier",next:"@type"}}}]],type:[{include:"@comment"},[/-+@str*\s*/,{cases:{"@eos":{token:"key.identifier",next:"@popall"},"@default":"key.identifier"}}],[/@str+\s*/,{cases:{"@eos":{token:"string",next:"@popall"},"@default":"string"}}]],comment:[[/#.*$/,{cases:{"@eos":{token:"comment",next:"@popall"}}}]]}}});var t6e={};st(t6e,{conf:()=>Upt,language:()=>$pt});var Upt,$pt,i6e=k(()=>{Upt={comments:{lineComment:"REM"},brackets:[["{","}"],["[","]"],["(",")"]],autoClosingPairs:[{open:"{",close:"}"},{open:"[",close:"]"},{open:"(",close:")"},{open:'"',close:'"'}],surroundingPairs:[{open:"[",close:"]"},{open:"(",close:")"},{open:'"',close:'"'}],folding:{markers:{start:new RegExp("^\\s*(::\\s*|REM\\s+)#region"),end:new RegExp("^\\s*(::\\s*|REM\\s+)#endregion")}}},$pt={defaultToken:"",ignoreCase:!0,tokenPostfix:".bat",brackets:[{token:"delimiter.bracket",open:"{",close:"}"},{token:"delimiter.parenthesis",open:"(",close:")"},{token:"delimiter.square",open:"[",close:"]"}],keywords:/call|defined|echo|errorlevel|exist|for|goto|if|pause|set|shift|start|title|not|pushd|popd/,symbols:/[=>Jpt,language:()=>emt});var jpt,qpt,Kpt,Gpt,Ypt,Zpt,Xpt,Qpt,Jpt,emt,o6e=k(()=>{jpt=n=>`\\b${n}\\b`,qpt="[_a-zA-Z]",Kpt="[_a-zA-Z0-9]",Gpt=jpt(`${qpt}${Kpt}*`),Ypt=["targetScope","resource","module","param","var","output","for","in","if","existing"],Zpt=["true","false","null"],Xpt="[ \\t\\r\\n]",Qpt="[0-9]+",Jpt={comments:{lineComment:"//",blockComment:["/*","*/"]},brackets:[["{","}"],["[","]"],["(",")"]],surroundingPairs:[{open:"{",close:"}"},{open:"[",close:"]"},{open:"(",close:")"},{open:"'",close:"'"},{open:"'''",close:"'''"}],autoClosingPairs:[{open:"{",close:"}"},{open:"[",close:"]"},{open:"(",close:")"},{open:"'",close:"'",notIn:["string","comment"]},{open:"'''",close:"'''",notIn:["string","comment"]}],autoCloseBefore:`:.,=}])' `,indentationRules:{increaseIndentPattern:new RegExp("^((?!\\/\\/).)*(\\{[^}\"'`]*|\\([^)\"'`]*|\\[[^\\]\"'`]*)$"),decreaseIndentPattern:new RegExp("^((?!.*?\\/\\*).*\\*/)?\\s*[\\}\\]].*$")}},emt={defaultToken:"",tokenPostfix:".bicep",brackets:[{open:"{",close:"}",token:"delimiter.curly"},{open:"[",close:"]",token:"delimiter.square"},{open:"(",close:")",token:"delimiter.parenthesis"}],symbols:/[=>tmt,language:()=>imt});var tmt,imt,s6e=k(()=>{tmt={comments:{lineComment:"//",blockComment:["(*","*)"]},brackets:[["{","}"],["[","]"],["(",")"],["<",">"]],autoClosingPairs:[{open:"{",close:"}"},{open:"[",close:"]"},{open:"(",close:")"},{open:"<",close:">"},{open:"'",close:"'"},{open:'"',close:'"'},{open:"(*",close:"*)"}],surroundingPairs:[{open:"{",close:"}"},{open:"[",close:"]"},{open:"(",close:")"},{open:"<",close:">"},{open:"'",close:"'"},{open:'"',close:'"'},{open:"(*",close:"*)"}]},imt={defaultToken:"",tokenPostfix:".cameligo",ignoreCase:!0,brackets:[{open:"{",close:"}",token:"delimiter.curly"},{open:"[",close:"]",token:"delimiter.square"},{open:"(",close:")",token:"delimiter.parenthesis"},{open:"<",close:">",token:"delimiter.angle"}],keywords:["abs","assert","block","Bytes","case","Crypto","Current","else","failwith","false","for","fun","if","in","let","let%entry","let%init","List","list","Map","map","match","match%nat","mod","not","operation","Operation","of","record","Set","set","sender","skip","source","String","then","to","true","type","with"],typeKeywords:["int","unit","string","tz","nat","bool"],operators:["=",">","<","<=",">=","<>",":",":=","and","mod","or","+","-","*","/","@","&","^","%","->","<-","&&","||"],symbols:/[=><:@\^&|+\-*\/\^%]+/,tokenizer:{root:[[/[a-zA-Z_][\w]*/,{cases:{"@keywords":{token:"keyword.$0"},"@default":"identifier"}}],{include:"@whitespace"},[/[{}()\[\]]/,"@brackets"],[/[<>](?!@symbols)/,"@brackets"],[/@symbols/,{cases:{"@operators":"delimiter","@default":""}}],[/\d*\.\d+([eE][\-+]?\d+)?/,"number.float"],[/\$[0-9a-fA-F]{1,16}/,"number.hex"],[/\d+/,"number"],[/[;,.]/,"delimiter"],[/'([^'\\]|\\.)*$/,"string.invalid"],[/'/,"string","@string"],[/'[^\\']'/,"string"],[/'/,"string.invalid"],[/\#\d+/,"string"]],comment:[[/[^\(\*]+/,"comment"],[/\*\)/,"comment","@pop"],[/\(\*/,"comment"]],string:[[/[^\\']+/,"string"],[/\\./,"string.escape.invalid"],[/'/,{token:"string.quote",bracket:"@close",next:"@pop"}]],whitespace:[[/[ \t\r\n]+/,"white"],[/\(\*/,"comment","@comment"],[/\/\/.*$/,"comment"]]}}});var a6e={};st(a6e,{conf:()=>nmt,language:()=>omt});var nmt,omt,l6e=k(()=>{nmt={comments:{lineComment:";;"},brackets:[["[","]"],["(",")"],["{","}"]],autoClosingPairs:[{open:"[",close:"]"},{open:'"',close:'"'},{open:"(",close:")"},{open:"{",close:"}"}],surroundingPairs:[{open:"[",close:"]"},{open:'"',close:'"'},{open:"(",close:")"},{open:"{",close:"}"}]},omt={defaultToken:"",ignoreCase:!0,tokenPostfix:".clj",brackets:[{open:"[",close:"]",token:"delimiter.square"},{open:"(",close:")",token:"delimiter.parenthesis"},{open:"{",close:"}",token:"delimiter.curly"}],constants:["true","false","nil"],numbers:/^(?:[+\-]?\d+(?:(?:N|(?:[eE][+\-]?\d+))|(?:\.?\d*(?:M|(?:[eE][+\-]?\d+))?)|\/\d+|[xX][0-9a-fA-F]+|r[0-9a-zA-Z]+)?(?=[\\\[\]\s"#'(),;@^`{}~]|$))/,characters:/^(?:\\(?:backspace|formfeed|newline|return|space|tab|o[0-7]{3}|u[0-9A-Fa-f]{4}|x[0-9A-Fa-f]{4}|.)?(?=[\\\[\]\s"(),;@^`{}~]|$))/,escapes:/^\\(?:["'\\bfnrt]|x[0-9A-Fa-f]{1,4}|u[0-9A-Fa-f]{4}|U[0-9A-Fa-f]{8})/,qualifiedSymbols:/^(?:(?:[^\\\/\[\]\d\s"#'(),;@^`{}~][^\\\[\]\s"(),;@^`{}~]*(?:\.[^\\\/\[\]\d\s"#'(),;@^`{}~][^\\\[\]\s"(),;@^`{}~]*)*\/)?(?:\/|[^\\\/\[\]\d\s"#'(),;@^`{}~][^\\\[\]\s"(),;@^`{}~]*)*(?=[\\\[\]\s"(),;@^`{}~]|$))/,specialForms:[".","catch","def","do","if","monitor-enter","monitor-exit","new","quote","recur","set!","throw","try","var"],coreSymbols:["*","*'","*1","*2","*3","*agent*","*allow-unresolved-vars*","*assert*","*clojure-version*","*command-line-args*","*compile-files*","*compile-path*","*compiler-options*","*data-readers*","*default-data-reader-fn*","*e","*err*","*file*","*flush-on-newline*","*fn-loader*","*in*","*math-context*","*ns*","*out*","*print-dup*","*print-length*","*print-level*","*print-meta*","*print-namespace-maps*","*print-readably*","*read-eval*","*reader-resolver*","*source-path*","*suppress-read*","*unchecked-math*","*use-context-classloader*","*verbose-defrecords*","*warn-on-reflection*","+","+'","-","-'","->","->>","->ArrayChunk","->Eduction","->Vec","->VecNode","->VecSeq","-cache-protocol-fn","-reset-methods","..","/","<","<=","=","==",">",">=","EMPTY-NODE","Inst","StackTraceElement->vec","Throwable->map","accessor","aclone","add-classpath","add-watch","agent","agent-error","agent-errors","aget","alength","alias","all-ns","alter","alter-meta!","alter-var-root","amap","ancestors","and","any?","apply","areduce","array-map","as->","aset","aset-boolean","aset-byte","aset-char","aset-double","aset-float","aset-int","aset-long","aset-short","assert","assoc","assoc!","assoc-in","associative?","atom","await","await-for","await1","bases","bean","bigdec","bigint","biginteger","binding","bit-and","bit-and-not","bit-clear","bit-flip","bit-not","bit-or","bit-set","bit-shift-left","bit-shift-right","bit-test","bit-xor","boolean","boolean-array","boolean?","booleans","bound-fn","bound-fn*","bound?","bounded-count","butlast","byte","byte-array","bytes","bytes?","case","cast","cat","char","char-array","char-escape-string","char-name-string","char?","chars","chunk","chunk-append","chunk-buffer","chunk-cons","chunk-first","chunk-next","chunk-rest","chunked-seq?","class","class?","clear-agent-errors","clojure-version","coll?","comment","commute","comp","comparator","compare","compare-and-set!","compile","complement","completing","concat","cond","cond->","cond->>","condp","conj","conj!","cons","constantly","construct-proxy","contains?","count","counted?","create-ns","create-struct","cycle","dec","dec'","decimal?","declare","dedupe","default-data-readers","definline","definterface","defmacro","defmethod","defmulti","defn","defn-","defonce","defprotocol","defrecord","defstruct","deftype","delay","delay?","deliver","denominator","deref","derive","descendants","destructure","disj","disj!","dissoc","dissoc!","distinct","distinct?","doall","dorun","doseq","dosync","dotimes","doto","double","double-array","double?","doubles","drop","drop-last","drop-while","eduction","empty","empty?","ensure","ensure-reduced","enumeration-seq","error-handler","error-mode","eval","even?","every-pred","every?","ex-data","ex-info","extend","extend-protocol","extend-type","extenders","extends?","false?","ffirst","file-seq","filter","filterv","find","find-keyword","find-ns","find-protocol-impl","find-protocol-method","find-var","first","flatten","float","float-array","float?","floats","flush","fn","fn?","fnext","fnil","for","force","format","frequencies","future","future-call","future-cancel","future-cancelled?","future-done?","future?","gen-class","gen-interface","gensym","get","get-in","get-method","get-proxy-class","get-thread-bindings","get-validator","group-by","halt-when","hash","hash-combine","hash-map","hash-ordered-coll","hash-set","hash-unordered-coll","ident?","identical?","identity","if-let","if-not","if-some","ifn?","import","in-ns","inc","inc'","indexed?","init-proxy","inst-ms","inst-ms*","inst?","instance?","int","int-array","int?","integer?","interleave","intern","interpose","into","into-array","ints","io!","isa?","iterate","iterator-seq","juxt","keep","keep-indexed","key","keys","keyword","keyword?","last","lazy-cat","lazy-seq","let","letfn","line-seq","list","list*","list?","load","load-file","load-reader","load-string","loaded-libs","locking","long","long-array","longs","loop","macroexpand","macroexpand-1","make-array","make-hierarchy","map","map-entry?","map-indexed","map?","mapcat","mapv","max","max-key","memfn","memoize","merge","merge-with","meta","method-sig","methods","min","min-key","mix-collection-hash","mod","munge","name","namespace","namespace-munge","nat-int?","neg-int?","neg?","newline","next","nfirst","nil?","nnext","not","not-any?","not-empty","not-every?","not=","ns","ns-aliases","ns-imports","ns-interns","ns-map","ns-name","ns-publics","ns-refers","ns-resolve","ns-unalias","ns-unmap","nth","nthnext","nthrest","num","number?","numerator","object-array","odd?","or","parents","partial","partition","partition-all","partition-by","pcalls","peek","persistent!","pmap","pop","pop!","pop-thread-bindings","pos-int?","pos?","pr","pr-str","prefer-method","prefers","primitives-classnames","print","print-ctor","print-dup","print-method","print-simple","print-str","printf","println","println-str","prn","prn-str","promise","proxy","proxy-call-with-super","proxy-mappings","proxy-name","proxy-super","push-thread-bindings","pvalues","qualified-ident?","qualified-keyword?","qualified-symbol?","quot","rand","rand-int","rand-nth","random-sample","range","ratio?","rational?","rationalize","re-find","re-groups","re-matcher","re-matches","re-pattern","re-seq","read","read-line","read-string","reader-conditional","reader-conditional?","realized?","record?","reduce","reduce-kv","reduced","reduced?","reductions","ref","ref-history-count","ref-max-history","ref-min-history","ref-set","refer","refer-clojure","reify","release-pending-sends","rem","remove","remove-all-methods","remove-method","remove-ns","remove-watch","repeat","repeatedly","replace","replicate","require","reset!","reset-meta!","reset-vals!","resolve","rest","restart-agent","resultset-seq","reverse","reversible?","rseq","rsubseq","run!","satisfies?","second","select-keys","send","send-off","send-via","seq","seq?","seqable?","seque","sequence","sequential?","set","set-agent-send-executor!","set-agent-send-off-executor!","set-error-handler!","set-error-mode!","set-validator!","set?","short","short-array","shorts","shuffle","shutdown-agents","simple-ident?","simple-keyword?","simple-symbol?","slurp","some","some->","some->>","some-fn","some?","sort","sort-by","sorted-map","sorted-map-by","sorted-set","sorted-set-by","sorted?","special-symbol?","spit","split-at","split-with","str","string?","struct","struct-map","subs","subseq","subvec","supers","swap!","swap-vals!","symbol","symbol?","sync","tagged-literal","tagged-literal?","take","take-last","take-nth","take-while","test","the-ns","thread-bound?","time","to-array","to-array-2d","trampoline","transduce","transient","tree-seq","true?","type","unchecked-add","unchecked-add-int","unchecked-byte","unchecked-char","unchecked-dec","unchecked-dec-int","unchecked-divide-int","unchecked-double","unchecked-float","unchecked-inc","unchecked-inc-int","unchecked-int","unchecked-long","unchecked-multiply","unchecked-multiply-int","unchecked-negate","unchecked-negate-int","unchecked-remainder-int","unchecked-short","unchecked-subtract","unchecked-subtract-int","underive","unquote","unquote-splicing","unreduced","unsigned-bit-shift-right","update","update-in","update-proxy","uri?","use","uuid?","val","vals","var-get","var-set","var?","vary-meta","vec","vector","vector-of","vector?","volatile!","volatile?","vreset!","vswap!","when","when-first","when-let","when-not","when-some","while","with-bindings","with-bindings*","with-in-str","with-loading-context","with-local-vars","with-meta","with-open","with-out-str","with-precision","with-redefs","with-redefs-fn","xml-seq","zero?","zipmap"],tokenizer:{root:[{include:"@whitespace"},[/@numbers/,"number"],[/@characters/,"string"],{include:"@string"},[/[()\[\]{}]/,"@brackets"],[/\/#"(?:\.|(?:")|[^"\n])*"\/g/,"regexp"],[/[#'@^`~]/,"meta"],[/@qualifiedSymbols/,{cases:{"^:.+$":"constant","@specialForms":"keyword","@coreSymbols":"keyword","@constants":"constant","@default":"identifier"}}]],whitespace:[[/[\s,]+/,"white"],[/;.*$/,"comment"],[/\(comment\b/,"comment","@comment"]],comment:[[/\(/,"comment","@push"],[/\)/,"comment","@pop"],[/[^()]/,"comment"]],string:[[/"/,"string","@multiLineString"]],multiLineString:[[/"/,"string","@popall"],[/@escapes/,"string.escape"],[/./,"string"]]}}});var c6e={};st(c6e,{conf:()=>rmt,language:()=>smt});var rmt,smt,d6e=k(()=>{rmt={wordPattern:/(-?\d*\.\d\w*)|([^\`\~\!\@\#%\^\&\*\(\)\=\$\-\+\[\{\]\}\\\|\;\:\'\"\,\.\<\>\/\?\s]+)/g,comments:{blockComment:["###","###"],lineComment:"#"},brackets:[["{","}"],["[","]"],["(",")"]],autoClosingPairs:[{open:"{",close:"}"},{open:"[",close:"]"},{open:"(",close:")"},{open:'"',close:'"'},{open:"'",close:"'"}],surroundingPairs:[{open:"{",close:"}"},{open:"[",close:"]"},{open:"(",close:")"},{open:'"',close:'"'},{open:"'",close:"'"}],folding:{markers:{start:new RegExp("^\\s*#region\\b"),end:new RegExp("^\\s*#endregion\\b")}}},smt={defaultToken:"",ignoreCase:!0,tokenPostfix:".coffee",brackets:[{open:"{",close:"}",token:"delimiter.curly"},{open:"[",close:"]",token:"delimiter.square"},{open:"(",close:")",token:"delimiter.parenthesis"}],regEx:/\/(?!\/\/)(?:[^\/\\]|\\.)*\/[igm]*/,keywords:["and","or","is","isnt","not","on","yes","@","no","off","true","false","null","this","new","delete","typeof","in","instanceof","return","throw","break","continue","debugger","if","else","switch","for","while","do","try","catch","finally","class","extends","super","undefined","then","unless","until","loop","of","by","when"],symbols:/[=>amt,language:()=>lmt});var amt,lmt,Spe=k(()=>{amt={comments:{lineComment:"//",blockComment:["/*","*/"]},brackets:[["{","}"],["[","]"],["(",")"]],autoClosingPairs:[{open:"[",close:"]"},{open:"{",close:"}"},{open:"(",close:")"},{open:"'",close:"'",notIn:["string","comment"]},{open:'"',close:'"',notIn:["string"]}],surroundingPairs:[{open:"{",close:"}"},{open:"[",close:"]"},{open:"(",close:")"},{open:'"',close:'"'},{open:"'",close:"'"}],folding:{markers:{start:new RegExp("^\\s*#pragma\\s+region\\b"),end:new RegExp("^\\s*#pragma\\s+endregion\\b")}}},lmt={defaultToken:"",tokenPostfix:".cpp",brackets:[{token:"delimiter.curly",open:"{",close:"}"},{token:"delimiter.parenthesis",open:"(",close:")"},{token:"delimiter.square",open:"[",close:"]"},{token:"delimiter.angle",open:"<",close:">"}],keywords:["abstract","amp","array","auto","bool","break","case","catch","char","class","const","constexpr","const_cast","continue","cpu","decltype","default","delegate","delete","do","double","dynamic_cast","each","else","enum","event","explicit","export","extern","false","final","finally","float","for","friend","gcnew","generic","goto","if","in","initonly","inline","int","interface","interior_ptr","internal","literal","long","mutable","namespace","new","noexcept","nullptr","__nullptr","operator","override","partial","pascal","pin_ptr","private","property","protected","public","ref","register","reinterpret_cast","restrict","return","safe_cast","sealed","short","signed","sizeof","static","static_assert","static_cast","struct","switch","template","this","thread_local","throw","tile_static","true","try","typedef","typeid","typename","union","unsigned","using","virtual","void","volatile","wchar_t","where","while","_asm","_based","_cdecl","_declspec","_fastcall","_if_exists","_if_not_exists","_inline","_multiple_inheritance","_pascal","_single_inheritance","_stdcall","_virtual_inheritance","_w64","__abstract","__alignof","__asm","__assume","__based","__box","__builtin_alignof","__cdecl","__clrcall","__declspec","__delegate","__event","__except","__fastcall","__finally","__forceinline","__gc","__hook","__identifier","__if_exists","__if_not_exists","__inline","__int128","__int16","__int32","__int64","__int8","__interface","__leave","__m128","__m128d","__m128i","__m256","__m256d","__m256i","__m512","__m512d","__m512i","__m64","__multiple_inheritance","__newslot","__nogc","__noop","__nounwind","__novtordisp","__pascal","__pin","__pragma","__property","__ptr32","__ptr64","__raise","__restrict","__resume","__sealed","__single_inheritance","__stdcall","__super","__thiscall","__try","__try_cast","__typeof","__unaligned","__unhook","__uuidof","__value","__virtual_inheritance","__w64","__wchar_t"],operators:["=",">","<","!","~","?",":","==","<=",">=","!=","&&","||","++","--","+","-","*","/","&","|","^","%","<<",">>","+=","-=","*=","/=","&=","|=","^=","%=","<<=",">>="],symbols:/[=>\[\]]/,"@brackets"],[/@symbols/,{cases:{"@operators":"delimiter","@default":""}}],[/\d*\d+[eE]([\-+]?\d+)?(@floatsuffix)/,"number.float"],[/\d*\.\d+([eE][\-+]?\d+)?(@floatsuffix)/,"number.float"],[/0[xX][0-9a-fA-F']*[0-9a-fA-F](@integersuffix)/,"number.hex"],[/0[0-7']*[0-7](@integersuffix)/,"number.octal"],[/0[bB][0-1']*[0-1](@integersuffix)/,"number.binary"],[/\d[\d']*\d(@integersuffix)/,"number"],[/\d(@integersuffix)/,"number"],[/[;,.]/,"delimiter"],[/"([^"\\]|\\.)*$/,"string.invalid"],[/"/,"string","@string"],[/'[^\\']'/,"string"],[/(')(@escapes)(')/,["string","string.escape","string"]],[/'/,"string.invalid"]],whitespace:[[/[ \t\r\n]+/,""],[/\/\*\*(?!\/)/,"comment.doc","@doccomment"],[/\/\*/,"comment","@comment"],[/\/\/.*\\$/,"comment","@linecomment"],[/\/\/.*$/,"comment"]],comment:[[/[^\/*]+/,"comment"],[/\*\//,"comment","@pop"],[/[\/*]/,"comment"]],linecomment:[[/.*[^\\]$/,"comment","@pop"],[/[^]+/,"comment"]],doccomment:[[/[^\/*]+/,"comment.doc"],[/\*\//,"comment.doc","@pop"],[/[\/*]/,"comment.doc"]],string:[[/[^\\"]+/,"string"],[/@escapes/,"string.escape"],[/\\./,"string.escape.invalid"],[/"/,"string","@pop"]],raw:[[/[^)]+/,"string.raw"],[/\)$S2\"/,{token:"string.raw.end",next:"@pop"}],[/\)/,"string.raw"]],annotation:[{include:"@whitespace"},[/using|alignas/,"keyword"],[/[a-zA-Z0-9_]+/,"annotation"],[/[,:]/,"delimiter"],[/[()]/,"@brackets"],[/\]\s*\]/,{token:"annotation",next:"@pop"}]],include:[[/(\s*)(<)([^<>]*)(>)/,["","keyword.directive.include.begin","string.include.identifier",{token:"keyword.directive.include.end",next:"@pop"}]],[/(\s*)(")([^"]*)(")/,["","keyword.directive.include.begin","string.include.identifier",{token:"keyword.directive.include.end",next:"@pop"}]]]}}});var u6e={};st(u6e,{conf:()=>cmt,language:()=>dmt});var cmt,dmt,h6e=k(()=>{cmt={wordPattern:/(-?\d*\.\d\w*)|([^\`\~\!\#\$\%\^\&\*\(\)\-\=\+\[\{\]\}\\\|\;\:\'\"\,\.\<\>\/\?\s]+)/g,comments:{lineComment:"//",blockComment:["/*","*/"]},brackets:[["{","}"],["[","]"],["(",")"]],autoClosingPairs:[{open:"{",close:"}"},{open:"[",close:"]"},{open:"(",close:")"},{open:"'",close:"'",notIn:["string","comment"]},{open:'"',close:'"',notIn:["string","comment"]}],surroundingPairs:[{open:"{",close:"}"},{open:"[",close:"]"},{open:"(",close:")"},{open:"<",close:">"},{open:"'",close:"'"},{open:'"',close:'"'}],folding:{markers:{start:new RegExp("^\\s*#region\\b"),end:new RegExp("^\\s*#endregion\\b")}}},dmt={defaultToken:"",tokenPostfix:".cs",brackets:[{open:"{",close:"}",token:"delimiter.curly"},{open:"[",close:"]",token:"delimiter.square"},{open:"(",close:")",token:"delimiter.parenthesis"},{open:"<",close:">",token:"delimiter.angle"}],keywords:["extern","alias","using","bool","decimal","sbyte","byte","short","ushort","int","uint","long","ulong","char","float","double","object","dynamic","string","assembly","is","as","ref","out","this","base","new","typeof","void","checked","unchecked","default","delegate","var","const","if","else","switch","case","while","do","for","foreach","in","break","continue","goto","return","throw","try","catch","finally","lock","yield","from","let","where","join","on","equals","into","orderby","ascending","descending","select","group","by","namespace","partial","class","field","event","method","param","public","protected","internal","private","abstract","sealed","static","struct","readonly","volatile","virtual","override","params","get","set","add","remove","operator","true","false","implicit","explicit","interface","enum","null","async","await","fixed","sizeof","stackalloc","unsafe","nameof","when"],namespaceFollows:["namespace","using"],parenFollows:["if","for","while","switch","foreach","using","catch","when"],operators:["=","??","||","&&","|","^","&","==","!=","<=",">=","<<","+","-","*","/","%","!","~","++","--","+=","-=","*=","/=","%=","&=","|=","^=","<<=",">>=",">>","=>"],symbols:/[=>](?!@symbols)/,"@brackets"],[/@symbols/,{cases:{"@operators":"delimiter","@default":""}}],[/[0-9_]*\.[0-9_]+([eE][\-+]?\d+)?[fFdD]?/,"number.float"],[/0[xX][0-9a-fA-F_]+/,"number.hex"],[/0[bB][01_]+/,"number.hex"],[/[0-9_]+/,"number"],[/[;,.]/,"delimiter"],[/"([^"\\]|\\.)*$/,"string.invalid"],[/"/,{token:"string.quote",next:"@string"}],[/\$\@"/,{token:"string.quote",next:"@litinterpstring"}],[/\@"/,{token:"string.quote",next:"@litstring"}],[/\$"/,{token:"string.quote",next:"@interpolatedstring"}],[/'[^\\']'/,"string"],[/(')(@escapes)(')/,["string","string.escape","string"]],[/'/,"string.invalid"]],qualified:[[/[a-zA-Z_][\w]*/,{cases:{"@keywords":{token:"keyword.$0"},"@default":"identifier"}}],[/\./,"delimiter"],["","","@pop"]],namespace:[{include:"@whitespace"},[/[A-Z]\w*/,"namespace"],[/[\.=]/,"delimiter"],["","","@pop"]],comment:[[/[^\/*]+/,"comment"],["\\*/","comment","@pop"],[/[\/*]/,"comment"]],string:[[/[^\\"]+/,"string"],[/@escapes/,"string.escape"],[/\\./,"string.escape.invalid"],[/"/,{token:"string.quote",next:"@pop"}]],litstring:[[/[^"]+/,"string"],[/""/,"string.escape"],[/"/,{token:"string.quote",next:"@pop"}]],litinterpstring:[[/[^"{]+/,"string"],[/""/,"string.escape"],[/{{/,"string.escape"],[/}}/,"string.escape"],[/{/,{token:"string.quote",next:"root.litinterpstring"}],[/"/,{token:"string.quote",next:"@pop"}]],interpolatedstring:[[/[^\\"{]+/,"string"],[/@escapes/,"string.escape"],[/\\./,"string.escape.invalid"],[/{{/,"string.escape"],[/}}/,"string.escape"],[/{/,{token:"string.quote",next:"root.interpolatedstring"}],[/"/,{token:"string.quote",next:"@pop"}]],whitespace:[[/^[ \t\v\f]*#((r)|(load))(?=\s)/,"directive.csx"],[/^[ \t\v\f]*#\w.*$/,"namespace.cpp"],[/[ \t\v\f\r\n]+/,""],[/\/\*/,"comment","@comment"],[/\/\/.*$/,"comment"]]}}});var f6e={};st(f6e,{conf:()=>umt,language:()=>hmt});var umt,hmt,p6e=k(()=>{umt={brackets:[],autoClosingPairs:[],surroundingPairs:[]},hmt={keywords:[],typeKeywords:[],tokenPostfix:".csp",operators:[],symbols:/[=>fmt,language:()=>pmt});var fmt,pmt,g6e=k(()=>{fmt={wordPattern:/(#?-?\d*\.\d\w*%?)|((::|[@#.!:])?[\w-?]+%?)|::|[@#.!:]/g,comments:{blockComment:["/*","*/"]},brackets:[["{","}"],["[","]"],["(",")"]],autoClosingPairs:[{open:"{",close:"}",notIn:["string","comment"]},{open:"[",close:"]",notIn:["string","comment"]},{open:"(",close:")",notIn:["string","comment"]},{open:'"',close:'"',notIn:["string","comment"]},{open:"'",close:"'",notIn:["string","comment"]}],surroundingPairs:[{open:"{",close:"}"},{open:"[",close:"]"},{open:"(",close:")"},{open:'"',close:'"'},{open:"'",close:"'"}],folding:{markers:{start:new RegExp("^\\s*\\/\\*\\s*#region\\b\\s*(.*?)\\s*\\*\\/"),end:new RegExp("^\\s*\\/\\*\\s*#endregion\\b.*\\*\\/")}}},pmt={defaultToken:"",tokenPostfix:".css",ws:`[ \r\f]*`,identifier:"-?-?([a-zA-Z]|(\\\\(([0-9a-fA-F]{1,6}\\s?)|[^[0-9a-fA-F])))([\\w\\-]|(\\\\(([0-9a-fA-F]{1,6}\\s?)|[^[0-9a-fA-F])))*",brackets:[{open:"{",close:"}",token:"delimiter.bracket"},{open:"[",close:"]",token:"delimiter.bracket"},{open:"(",close:")",token:"delimiter.parenthesis"},{open:"<",close:">",token:"delimiter.angle"}],tokenizer:{root:[{include:"@selector"}],selector:[{include:"@comments"},{include:"@import"},{include:"@strings"},["[@](keyframes|-webkit-keyframes|-moz-keyframes|-o-keyframes)",{token:"keyword",next:"@keyframedeclaration"}],["[@](page|content|font-face|-moz-document)",{token:"keyword"}],["[@](charset|namespace)",{token:"keyword",next:"@declarationbody"}],["(url-prefix)(\\()",["attribute.value",{token:"delimiter.parenthesis",next:"@urldeclaration"}]],["(url)(\\()",["attribute.value",{token:"delimiter.parenthesis",next:"@urldeclaration"}]],{include:"@selectorname"},["[\\*]","tag"],["[>\\+,]","delimiter"],["\\[",{token:"delimiter.bracket",next:"@selectorattribute"}],["{",{token:"delimiter.bracket",next:"@selectorbody"}]],selectorbody:[{include:"@comments"},["[*_]?@identifier@ws:(?=(\\s|\\d|[^{;}]*[;}]))","attribute.name","@rulevalue"],["}",{token:"delimiter.bracket",next:"@pop"}]],selectorname:[["(\\.|#(?=[^{])|%|(@identifier)|:)+","tag"]],selectorattribute:[{include:"@term"},["]",{token:"delimiter.bracket",next:"@pop"}]],term:[{include:"@comments"},["(url-prefix)(\\()",["attribute.value",{token:"delimiter.parenthesis",next:"@urldeclaration"}]],["(url)(\\()",["attribute.value",{token:"delimiter.parenthesis",next:"@urldeclaration"}]],{include:"@functioninvocation"},{include:"@numbers"},{include:"@name"},{include:"@strings"},["([<>=\\+\\-\\*\\/\\^\\|\\~,])","delimiter"],[",","delimiter"]],rulevalue:[{include:"@comments"},{include:"@strings"},{include:"@term"},["!important","keyword"],[";","delimiter","@pop"],["(?=})",{token:"",next:"@pop"}]],warndebug:[["[@](warn|debug)",{token:"keyword",next:"@declarationbody"}]],import:[["[@](import)",{token:"keyword",next:"@declarationbody"}]],urldeclaration:[{include:"@strings"},[`[^)\r ]+`,"string"],["\\)",{token:"delimiter.parenthesis",next:"@pop"}]],parenthizedterm:[{include:"@term"},["\\)",{token:"delimiter.parenthesis",next:"@pop"}]],declarationbody:[{include:"@term"},[";","delimiter","@pop"],["(?=})",{token:"",next:"@pop"}]],comments:[["\\/\\*","comment","@comment"],["\\/\\/+.*","comment"]],comment:[["\\*\\/","comment","@pop"],[/[^*/]+/,"comment"],[/./,"comment"]],name:[["@identifier","attribute.value"]],numbers:[["-?(\\d*\\.)?\\d+([eE][\\-+]?\\d+)?",{token:"attribute.value.number",next:"@units"}],["#[0-9a-fA-F_]+(?!\\w)","attribute.value.hex"]],units:[["(em|ex|ch|rem|fr|vmin|vmax|vw|vh|vm|cm|mm|in|px|pt|pc|deg|grad|rad|turn|s|ms|Hz|kHz|%)?","attribute.value.unit","@pop"]],keyframedeclaration:[["@identifier","attribute.value"],["{",{token:"delimiter.bracket",switchTo:"@keyframebody"}]],keyframebody:[{include:"@term"},["{",{token:"delimiter.bracket",next:"@selectorbody"}],["}",{token:"delimiter.bracket",next:"@pop"}]],functioninvocation:[["@identifier\\(",{token:"attribute.value",next:"@functionarguments"}]],functionarguments:[["\\$@identifier@ws:","attribute.name"],["[,]","delimiter"],{include:"@term"},["\\)",{token:"attribute.value",next:"@pop"}]],strings:[['~?"',{token:"string",next:"@stringenddoublequote"}],["~?'",{token:"string",next:"@stringendquote"}]],stringenddoublequote:[["\\\\.","string"],['"',{token:"string",next:"@pop"}],[/[^\\"]+/,"string"],[".","string"]],stringendquote:[["\\\\.","string"],["'",{token:"string",next:"@pop"}],[/[^\\']+/,"string"],[".","string"]]}}});var _6e={};st(_6e,{conf:()=>mmt,language:()=>gmt});var mmt,gmt,b6e=k(()=>{mmt={comments:{lineComment:"//",blockComment:["/*","*/"]},brackets:[["{","}"],["[","]"],["(",")"]],autoClosingPairs:[{open:"{",close:"}"},{open:"[",close:"]"},{open:"(",close:")"},{open:'"',close:'"'},{open:"'",close:"'"},{open:"`",close:"`"}],surroundingPairs:[{open:"{",close:"}"},{open:"[",close:"]"},{open:"(",close:")"},{open:'"',close:'"'},{open:"'",close:"'"},{open:"`",close:"`"}]},gmt={defaultToken:"",tokenPostfix:".cypher",ignoreCase:!0,brackets:[{open:"{",close:"}",token:"delimiter.curly"},{open:"[",close:"]",token:"delimiter.bracket"},{open:"(",close:")",token:"delimiter.parenthesis"}],keywords:["ALL","AND","AS","ASC","ASCENDING","BY","CALL","CASE","CONTAINS","CREATE","DELETE","DESC","DESCENDING","DETACH","DISTINCT","ELSE","END","ENDS","EXISTS","IN","IS","LIMIT","MANDATORY","MATCH","MERGE","NOT","ON","ON","OPTIONAL","OR","ORDER","REMOVE","RETURN","SET","SKIP","STARTS","THEN","UNION","UNWIND","WHEN","WHERE","WITH","XOR","YIELD"],builtinLiterals:["true","TRUE","false","FALSE","null","NULL"],builtinFunctions:["abs","acos","asin","atan","atan2","avg","ceil","coalesce","collect","cos","cot","count","degrees","e","endNode","exists","exp","floor","head","id","keys","labels","last","left","length","log","log10","lTrim","max","min","nodes","percentileCont","percentileDisc","pi","properties","radians","rand","range","relationships","replace","reverse","right","round","rTrim","sign","sin","size","split","sqrt","startNode","stDev","stDevP","substring","sum","tail","tan","timestamp","toBoolean","toFloat","toInteger","toLower","toString","toUpper","trim","type"],operators:["+","-","*","/","%","^","=","<>","<",">","<=",">=","->","<-","-->","<--"],escapes:/\\(?:[tbnrf\\"'`]|u[0-9A-Fa-f]{4}|U[0-9A-Fa-f]{8})/,digits:/\d+/,octaldigits:/[0-7]+/,hexdigits:/[0-9a-fA-F]+/,tokenizer:{root:[[/[{}[\]()]/,"@brackets"],{include:"common"}],common:[{include:"@whitespace"},{include:"@numbers"},{include:"@strings"},[/:[a-zA-Z_][\w]*/,"type.identifier"],[/[a-zA-Z_][\w]*(?=\()/,{cases:{"@builtinFunctions":"predefined.function"}}],[/[a-zA-Z_$][\w$]*/,{cases:{"@keywords":"keyword","@builtinLiterals":"predefined.literal","@default":"identifier"}}],[/`/,"identifier.escape","@identifierBacktick"],[/[;,.:|]/,"delimiter"],[/[<>=%+\-*/^]+/,{cases:{"@operators":"delimiter","@default":""}}]],numbers:[[/-?(@digits)[eE](-?(@digits))?/,"number.float"],[/-?(@digits)?\.(@digits)([eE]-?(@digits))?/,"number.float"],[/-?0x(@hexdigits)/,"number.hex"],[/-?0(@octaldigits)/,"number.octal"],[/-?(@digits)/,"number"]],strings:[[/"([^"\\]|\\.)*$/,"string.invalid"],[/'([^'\\]|\\.)*$/,"string.invalid"],[/"/,"string","@stringDouble"],[/'/,"string","@stringSingle"]],whitespace:[[/[ \t\r\n]+/,"white"],[/\/\*/,"comment","@comment"],[/\/\/.*$/,"comment"]],comment:[[/\/\/.*/,"comment"],[/[^/*]+/,"comment"],[/\*\//,"comment","@pop"],[/[/*]/,"comment"]],stringDouble:[[/[^\\"]+/,"string"],[/@escapes/,"string"],[/\\./,"string.invalid"],[/"/,"string","@pop"]],stringSingle:[[/[^\\']+/,"string"],[/@escapes/,"string"],[/\\./,"string.invalid"],[/'/,"string","@pop"]],identifierBacktick:[[/[^\\`]+/,"identifier.escape"],[/@escapes/,"identifier.escape"],[/\\./,"identifier.escape.invalid"],[/`/,"identifier.escape","@pop"]]}}});var v6e={};st(v6e,{conf:()=>_mt,language:()=>bmt});var _mt,bmt,x6e=k(()=>{_mt={comments:{lineComment:"//",blockComment:["/*","*/"]},brackets:[["{","}"],["[","]"],["(",")"]],autoClosingPairs:[{open:"{",close:"}"},{open:"[",close:"]"},{open:"(",close:")"},{open:"'",close:"'",notIn:["string","comment"]},{open:'"',close:'"',notIn:["string"]},{open:"`",close:"`",notIn:["string","comment"]},{open:"/**",close:" */",notIn:["string"]}],surroundingPairs:[{open:"{",close:"}"},{open:"[",close:"]"},{open:"(",close:")"},{open:"<",close:">"},{open:"'",close:"'"},{open:"(",close:")"},{open:'"',close:'"'},{open:"`",close:"`"}],folding:{markers:{start:/^\s*\s*#?region\b/,end:/^\s*\s*#?endregion\b/}}},bmt={defaultToken:"invalid",tokenPostfix:".dart",keywords:["abstract","dynamic","implements","show","as","else","import","static","assert","enum","in","super","async","export","interface","switch","await","extends","is","sync","break","external","library","this","case","factory","mixin","throw","catch","false","new","true","class","final","null","try","const","finally","on","typedef","continue","for","operator","var","covariant","Function","part","void","default","get","rethrow","while","deferred","hide","return","with","do","if","set","yield"],typeKeywords:["int","double","String","bool"],operators:["+","-","*","/","~/","%","++","--","==","!=",">","<",">=","<=","=","-=","/=","%=",">>=","^=","+=","*=","~/=","<<=","&=","!=","||","&&","&","|","^","~","<<",">>","!",">>>","??","?",":","|="],symbols:/[=>](?!@symbols)/,"@brackets"],[/!(?=([^=]|$))/,"delimiter"],[/@symbols/,{cases:{"@operators":"delimiter","@default":""}}],[/(@digits)[eE]([\-+]?(@digits))?/,"number.float"],[/(@digits)\.(@digits)([eE][\-+]?(@digits))?/,"number.float"],[/0[xX](@hexdigits)n?/,"number.hex"],[/0[oO]?(@octaldigits)n?/,"number.octal"],[/0[bB](@binarydigits)n?/,"number.binary"],[/(@digits)n?/,"number"],[/[;,.]/,"delimiter"],[/"([^"\\]|\\.)*$/,"string.invalid"],[/'([^'\\]|\\.)*$/,"string.invalid"],[/"/,"string","@string_double"],[/'/,"string","@string_single"]],whitespace:[[/[ \t\r\n]+/,""],[/\/\*\*(?!\/)/,"comment.doc","@jsdoc"],[/\/\*/,"comment","@comment"],[/\/\/\/.*$/,"comment.doc"],[/\/\/.*$/,"comment"]],comment:[[/[^\/*]+/,"comment"],[/\*\//,"comment","@pop"],[/[\/*]/,"comment"]],jsdoc:[[/[^\/*]+/,"comment.doc"],[/\*\//,"comment.doc","@pop"],[/[\/*]/,"comment.doc"]],regexp:[[/(\{)(\d+(?:,\d*)?)(\})/,["regexp.escape.control","regexp.escape.control","regexp.escape.control"]],[/(\[)(\^?)(?=(?:[^\]\\\/]|\\.)+)/,["regexp.escape.control",{token:"regexp.escape.control",next:"@regexrange"}]],[/(\()(\?:|\?=|\?!)/,["regexp.escape.control","regexp.escape.control"]],[/[()]/,"regexp.escape.control"],[/@regexpctl/,"regexp.escape.control"],[/[^\\\/]/,"regexp"],[/@regexpesc/,"regexp.escape"],[/\\\./,"regexp.invalid"],[/(\/)([gimsuy]*)/,[{token:"regexp",bracket:"@close",next:"@pop"},"keyword.other"]]],regexrange:[[/-/,"regexp.escape.control"],[/\^/,"regexp.invalid"],[/@regexpesc/,"regexp.escape"],[/[^\]]/,"regexp"],[/\]/,{token:"regexp.escape.control",next:"@pop",bracket:"@close"}]],string_double:[[/[^\\"\$]+/,"string"],[/[^\\"]+/,"string"],[/@escapes/,"string.escape"],[/\\./,"string.escape.invalid"],[/"/,"string","@pop"],[/\$\w+/,"identifier"]],string_single:[[/[^\\'\$]+/,"string"],[/@escapes/,"string.escape"],[/\\./,"string.escape.invalid"],[/'/,"string","@pop"],[/\$\w+/,"identifier"]]}}});var w6e={};st(w6e,{conf:()=>vmt,language:()=>xmt});var vmt,xmt,y6e=k(()=>{vmt={brackets:[["{","}"],["[","]"],["(",")"]],autoClosingPairs:[{open:"{",close:"}"},{open:"[",close:"]"},{open:"(",close:")"},{open:'"',close:'"'},{open:"'",close:"'"}],surroundingPairs:[{open:"{",close:"}"},{open:"[",close:"]"},{open:"(",close:")"},{open:'"',close:'"'},{open:"'",close:"'"}]},xmt={defaultToken:"",tokenPostfix:".dockerfile",variable:/\${?[\w]+}?/,tokenizer:{root:[{include:"@whitespace"},{include:"@comment"},[/(ONBUILD)(\s+)/,["keyword",""]],[/(ENV)(\s+)([\w]+)/,["keyword","",{token:"variable",next:"@arguments"}]],[/(FROM|MAINTAINER|RUN|EXPOSE|ENV|ADD|ARG|VOLUME|LABEL|USER|WORKDIR|COPY|CMD|STOPSIGNAL|SHELL|HEALTHCHECK|ENTRYPOINT)/,{token:"keyword",next:"@arguments"}]],arguments:[{include:"@whitespace"},{include:"@strings"},[/(@variable)/,{cases:{"@eos":{token:"variable",next:"@popall"},"@default":"variable"}}],[/\\/,{cases:{"@eos":"","@default":""}}],[/./,{cases:{"@eos":{token:"",next:"@popall"},"@default":""}}]],whitespace:[[/\s+/,{cases:{"@eos":{token:"",next:"@popall"},"@default":""}}]],comment:[[/(^#.*$)/,"comment","@popall"]],strings:[[/\\'$/,"","@popall"],[/\\'/,""],[/'$/,"string","@popall"],[/'/,"string","@stringBody"],[/"$/,"string","@popall"],[/"/,"string","@dblStringBody"]],stringBody:[[/[^\\\$']/,{cases:{"@eos":{token:"string",next:"@popall"},"@default":"string"}}],[/\\./,"string.escape"],[/'$/,"string","@popall"],[/'/,"string","@pop"],[/(@variable)/,"variable"],[/\\$/,"string"],[/$/,"string","@popall"]],dblStringBody:[[/[^\\\$"]/,{cases:{"@eos":{token:"string",next:"@popall"},"@default":"string"}}],[/\\./,"string.escape"],[/"$/,"string","@popall"],[/"/,"string","@pop"],[/(@variable)/,"variable"],[/\\$/,"string"],[/$/,"string","@popall"]]}}});var C6e={};st(C6e,{conf:()=>wmt,language:()=>ymt});var wmt,ymt,S6e=k(()=>{wmt={comments:{lineComment:"//",blockComment:["/*","*/"]},brackets:[["{","}"],["[","]"],["(",")"]],autoClosingPairs:[{open:"{",close:"}"},{open:"[",close:"]"},{open:"(",close:")"},{open:"'",close:"'",notIn:["string","comment"]},{open:'"',close:'"',notIn:["string","comment"]}],surroundingPairs:[{open:"{",close:"}"},{open:"[",close:"]"},{open:"(",close:")"},{open:"<",close:">"},{open:"'",close:"'"},{open:'"',close:'"'}]},ymt={defaultToken:"",tokenPostfix:".ecl",ignoreCase:!0,brackets:[{open:"{",close:"}",token:"delimiter.curly"},{open:"[",close:"]",token:"delimiter.square"},{open:"(",close:")",token:"delimiter.parenthesis"},{open:"<",close:">",token:"delimiter.angle"}],pounds:["append","break","declare","demangle","end","for","getdatatype","if","inmodule","loop","mangle","onwarning","option","set","stored","uniquename"].join("|"),keywords:["__compressed__","after","all","and","any","as","atmost","before","beginc","best","between","case","cluster","compressed","compression","const","counter","csv","default","descend","embed","encoding","encrypt","end","endc","endembed","endmacro","enum","escape","except","exclusive","expire","export","extend","fail","few","fileposition","first","flat","forward","from","full","function","functionmacro","group","grouped","heading","hole","ifblock","import","in","inner","interface","internal","joined","keep","keyed","last","left","limit","linkcounted","literal","little_endian","load","local","locale","lookup","lzw","macro","many","maxcount","maxlength","min skew","module","mofn","multiple","named","namespace","nocase","noroot","noscan","nosort","not","noxpath","of","onfail","only","opt","or","outer","overwrite","packed","partition","penalty","physicallength","pipe","prefetch","quote","record","repeat","retry","return","right","right1","right2","rows","rowset","scan","scope","self","separator","service","shared","skew","skip","smart","soapaction","sql","stable","store","terminator","thor","threshold","timelimit","timeout","token","transform","trim","type","unicodeorder","unordered","unsorted","unstable","update","use","validate","virtual","whole","width","wild","within","wnotrim","xml","xpath"],functions:["abs","acos","aggregate","allnodes","apply","ascii","asin","assert","asstring","atan","atan2","ave","build","buildindex","case","catch","choose","choosen","choosesets","clustersize","combine","correlation","cos","cosh","count","covariance","cron","dataset","dedup","define","denormalize","dictionary","distribute","distributed","distribution","ebcdic","enth","error","evaluate","event","eventextra","eventname","exists","exp","fail","failcode","failmessage","fetch","fromunicode","fromxml","getenv","getisvalid","global","graph","group","hash","hash32","hash64","hashcrc","hashmd5","having","httpcall","httpheader","if","iff","index","intformat","isvalid","iterate","join","keydiff","keypatch","keyunicode","length","library","limit","ln","loadxml","local","log","loop","map","matched","matchlength","matchposition","matchtext","matchunicode","max","merge","mergejoin","min","nofold","nolocal","nonempty","normalize","nothor","notify","output","parallel","parse","pipe","power","preload","process","project","pull","random","range","rank","ranked","realformat","recordof","regexfind","regexreplace","regroup","rejected","rollup","round","roundup","row","rowdiff","sample","sequential","set","sin","sinh","sizeof","soapcall","sort","sorted","sqrt","stepped","stored","sum","table","tan","tanh","thisnode","topn","tounicode","toxml","transfer","transform","trim","truncate","typeof","ungroup","unicodeorder","variance","wait","which","workunit","xmldecode","xmlencode","xmltext","xmlunicode"],typesint:["integer","unsigned"].join("|"),typesnum:["data","qstring","string","unicode","utf8","varstring","varunicode"],typesone:["ascii","big_endian","boolean","data","decimal","ebcdic","grouped","integer","linkcounted","pattern","qstring","real","record","rule","set of","streamed","string","token","udecimal","unicode","unsigned","utf8","varstring","varunicode"].join("|"),operators:["+","-","/",":=","<","<>","=",">","\\","and","in","not","or"],symbols:/[=>](?!@symbols)/,"@brackets"],[/@symbols/,{cases:{"@operators":"delimiter","@default":""}}],[/[0-9_]*\.[0-9_]+([eE][\-+]?\d+)?/,"number.float"],[/0[xX][0-9a-fA-F_]+/,"number.hex"],[/0[bB][01]+/,"number.hex"],[/[0-9_]+/,"number"],[/[;,.]/,"delimiter"],[/"([^"\\]|\\.)*$/,"string.invalid"],[/"/,"string","@string"],[/'[^\\']'/,"string"],[/(')(@escapes)(')/,["string","string.escape","string"]],[/'/,"string.invalid"]],whitespace:[[/[ \t\v\f\r\n]+/,""],[/\/\*/,"comment","@comment"],[/\/\/.*$/,"comment"]],comment:[[/[^\/*]+/,"comment"],[/\*\//,"comment","@pop"],[/[\/*]/,"comment"]],string:[[/[^\\']+/,"string"],[/@escapes/,"string.escape"],[/\\./,"string.escape.invalid"],[/'/,"string","@pop"]]}}});var k6e={};st(k6e,{conf:()=>Cmt,language:()=>Smt});var Cmt,Smt,L6e=k(()=>{Cmt={comments:{lineComment:"#"},brackets:[["{","}"],["[","]"],["(",")"]],surroundingPairs:[{open:"{",close:"}"},{open:"[",close:"]"},{open:"(",close:")"},{open:"'",close:"'"},{open:'"',close:'"'}],autoClosingPairs:[{open:"'",close:"'",notIn:["string","comment"]},{open:'"',close:'"',notIn:["comment"]},{open:'"""',close:'"""'},{open:"`",close:"`",notIn:["string","comment"]},{open:"(",close:")"},{open:"{",close:"}"},{open:"[",close:"]"},{open:"<<",close:">>"}],indentationRules:{increaseIndentPattern:/^\s*(after|else|catch|rescue|fn|[^#]*(do|<\-|\->|\{|\[|\=))\s*$/,decreaseIndentPattern:/^\s*((\}|\])\s*$|(after|else|catch|rescue|end)\b)/}},Smt={defaultToken:"source",tokenPostfix:".elixir",brackets:[{open:"[",close:"]",token:"delimiter.square"},{open:"(",close:")",token:"delimiter.parenthesis"},{open:"{",close:"}",token:"delimiter.curly"},{open:"<<",close:">>",token:"delimiter.angle.special"}],declarationKeywords:["def","defp","defn","defnp","defguard","defguardp","defmacro","defmacrop","defdelegate","defcallback","defmacrocallback","defmodule","defprotocol","defexception","defimpl","defstruct"],operatorKeywords:["and","in","not","or","when"],namespaceKeywords:["alias","import","require","use"],otherKeywords:["after","case","catch","cond","do","else","end","fn","for","if","quote","raise","receive","rescue","super","throw","try","unless","unquote_splicing","unquote","with"],constants:["true","false","nil"],nameBuiltin:["__MODULE__","__DIR__","__ENV__","__CALLER__","__STACKTRACE__"],operator:/-[->]?|!={0,2}|\*{1,2}|\/|\\\\|&{1,3}|\.\.?|\^(?:\^\^)?|\+\+?|<(?:-|<<|=|>|\|>|~>?)?|=~|={1,3}|>(?:=|>>)?|\|~>|\|>|\|{1,3}|~>>?|~~~|::/,variableName:/[a-z_][a-zA-Z0-9_]*[?!]?/,atomName:/[a-zA-Z_][a-zA-Z0-9_@]*[?!]?|@specialAtomName|@operator/,specialAtomName:/\.\.\.|<<>>|%\{\}|%|\{\}/,aliasPart:/[A-Z][a-zA-Z0-9_]*/,moduleName:/@aliasPart(?:\.@aliasPart)*/,sigilSymmetricDelimiter:/"""|'''|"|'|\/|\|/,sigilStartDelimiter:/@sigilSymmetricDelimiter|<|\{|\[|\(/,sigilEndDelimiter:/@sigilSymmetricDelimiter|>|\}|\]|\)/,sigilModifiers:/[a-zA-Z0-9]*/,decimal:/\d(?:_?\d)*/,hex:/[0-9a-fA-F](_?[0-9a-fA-F])*/,octal:/[0-7](_?[0-7])*/,binary:/[01](_?[01])*/,escape:/\\u[0-9a-fA-F]{4}|\\x[0-9a-fA-F]{2}|\\./,tokenizer:{root:[{include:"@whitespace"},{include:"@comments"},{include:"@keywordsShorthand"},{include:"@numbers"},{include:"@identifiers"},{include:"@strings"},{include:"@atoms"},{include:"@sigils"},{include:"@attributes"},{include:"@symbols"}],whitespace:[[/\s+/,"white"]],comments:[[/(#)(.*)/,["comment.punctuation","comment"]]],keywordsShorthand:[[/(@atomName)(:)(\s+)/,["constant","constant.punctuation","white"]],[/"(?=([^"]|#\{.*?\}|\\")*":)/,{token:"constant.delimiter",next:"@doubleQuotedStringKeyword"}],[/'(?=([^']|#\{.*?\}|\\')*':)/,{token:"constant.delimiter",next:"@singleQuotedStringKeyword"}]],doubleQuotedStringKeyword:[[/":/,{token:"constant.delimiter",next:"@pop"}],{include:"@stringConstantContentInterpol"}],singleQuotedStringKeyword:[[/':/,{token:"constant.delimiter",next:"@pop"}],{include:"@stringConstantContentInterpol"}],numbers:[[/0b@binary/,"number.binary"],[/0o@octal/,"number.octal"],[/0x@hex/,"number.hex"],[/@decimal\.@decimal([eE]-?@decimal)?/,"number.float"],[/@decimal/,"number"]],identifiers:[[/\b(defp?|defnp?|defmacrop?|defguardp?|defdelegate)(\s+)(@variableName)(?!\s+@operator)/,["keyword.declaration","white",{cases:{unquote:"keyword","@default":"function"}}]],[/(@variableName)(?=\s*\.?\s*\()/,{cases:{"@declarationKeywords":"keyword.declaration","@namespaceKeywords":"keyword","@otherKeywords":"keyword","@default":"function.call"}}],[/(@moduleName)(\s*)(\.)(\s*)(@variableName)/,["type.identifier","white","operator","white","function.call"]],[/(:)(@atomName)(\s*)(\.)(\s*)(@variableName)/,["constant.punctuation","constant","white","operator","white","function.call"]],[/(\|>)(\s*)(@variableName)/,["operator","white",{cases:{"@otherKeywords":"keyword","@default":"function.call"}}]],[/(&)(\s*)(@variableName)/,["operator","white","function.call"]],[/@variableName/,{cases:{"@declarationKeywords":"keyword.declaration","@operatorKeywords":"keyword.operator","@namespaceKeywords":"keyword","@otherKeywords":"keyword","@constants":"constant.language","@nameBuiltin":"variable.language","_.*":"comment.unused","@default":"identifier"}}],[/@moduleName/,"type.identifier"]],strings:[[/"""/,{token:"string.delimiter",next:"@doubleQuotedHeredoc"}],[/'''/,{token:"string.delimiter",next:"@singleQuotedHeredoc"}],[/"/,{token:"string.delimiter",next:"@doubleQuotedString"}],[/'/,{token:"string.delimiter",next:"@singleQuotedString"}]],doubleQuotedHeredoc:[[/"""/,{token:"string.delimiter",next:"@pop"}],{include:"@stringContentInterpol"}],singleQuotedHeredoc:[[/'''/,{token:"string.delimiter",next:"@pop"}],{include:"@stringContentInterpol"}],doubleQuotedString:[[/"/,{token:"string.delimiter",next:"@pop"}],{include:"@stringContentInterpol"}],singleQuotedString:[[/'/,{token:"string.delimiter",next:"@pop"}],{include:"@stringContentInterpol"}],atoms:[[/(:)(@atomName)/,["constant.punctuation","constant"]],[/:"/,{token:"constant.delimiter",next:"@doubleQuotedStringAtom"}],[/:'/,{token:"constant.delimiter",next:"@singleQuotedStringAtom"}]],doubleQuotedStringAtom:[[/"/,{token:"constant.delimiter",next:"@pop"}],{include:"@stringConstantContentInterpol"}],singleQuotedStringAtom:[[/'/,{token:"constant.delimiter",next:"@pop"}],{include:"@stringConstantContentInterpol"}],sigils:[[/~[a-z]@sigilStartDelimiter/,{token:"@rematch",next:"@sigil.interpol"}],[/~([A-Z]+)@sigilStartDelimiter/,{token:"@rematch",next:"@sigil.noInterpol"}]],sigil:[[/~([a-z]|[A-Z]+)\{/,{token:"@rematch",switchTo:"@sigilStart.$S2.$1.{.}"}],[/~([a-z]|[A-Z]+)\[/,{token:"@rematch",switchTo:"@sigilStart.$S2.$1.[.]"}],[/~([a-z]|[A-Z]+)\(/,{token:"@rematch",switchTo:"@sigilStart.$S2.$1.(.)"}],[/~([a-z]|[A-Z]+)\"}],[/~([a-z]|[A-Z]+)(@sigilSymmetricDelimiter)/,{token:"@rematch",switchTo:"@sigilStart.$S2.$1.$2.$2"}]],"sigilStart.interpol.s":[[/~s@sigilStartDelimiter/,{token:"string.delimiter",switchTo:"@sigilContinue.$S2.$S3.$S4.$S5"}]],"sigilContinue.interpol.s":[[/(@sigilEndDelimiter)@sigilModifiers/,{cases:{"$1==$S5":{token:"string.delimiter",next:"@pop"},"@default":"string"}}],{include:"@stringContentInterpol"}],"sigilStart.noInterpol.S":[[/~S@sigilStartDelimiter/,{token:"string.delimiter",switchTo:"@sigilContinue.$S2.$S3.$S4.$S5"}]],"sigilContinue.noInterpol.S":[[/(^|[^\\])\\@sigilEndDelimiter/,"string"],[/(@sigilEndDelimiter)@sigilModifiers/,{cases:{"$1==$S5":{token:"string.delimiter",next:"@pop"},"@default":"string"}}],{include:"@stringContent"}],"sigilStart.interpol.r":[[/~r@sigilStartDelimiter/,{token:"regexp.delimiter",switchTo:"@sigilContinue.$S2.$S3.$S4.$S5"}]],"sigilContinue.interpol.r":[[/(@sigilEndDelimiter)@sigilModifiers/,{cases:{"$1==$S5":{token:"regexp.delimiter",next:"@pop"},"@default":"regexp"}}],{include:"@regexpContentInterpol"}],"sigilStart.noInterpol.R":[[/~R@sigilStartDelimiter/,{token:"regexp.delimiter",switchTo:"@sigilContinue.$S2.$S3.$S4.$S5"}]],"sigilContinue.noInterpol.R":[[/(^|[^\\])\\@sigilEndDelimiter/,"regexp"],[/(@sigilEndDelimiter)@sigilModifiers/,{cases:{"$1==$S5":{token:"regexp.delimiter",next:"@pop"},"@default":"regexp"}}],{include:"@regexpContent"}],"sigilStart.interpol":[[/~([a-z]|[A-Z]+)@sigilStartDelimiter/,{token:"sigil.delimiter",switchTo:"@sigilContinue.$S2.$S3.$S4.$S5"}]],"sigilContinue.interpol":[[/(@sigilEndDelimiter)@sigilModifiers/,{cases:{"$1==$S5":{token:"sigil.delimiter",next:"@pop"},"@default":"sigil"}}],{include:"@sigilContentInterpol"}],"sigilStart.noInterpol":[[/~([a-z]|[A-Z]+)@sigilStartDelimiter/,{token:"sigil.delimiter",switchTo:"@sigilContinue.$S2.$S3.$S4.$S5"}]],"sigilContinue.noInterpol":[[/(^|[^\\])\\@sigilEndDelimiter/,"sigil"],[/(@sigilEndDelimiter)@sigilModifiers/,{cases:{"$1==$S5":{token:"sigil.delimiter",next:"@pop"},"@default":"sigil"}}],{include:"@sigilContent"}],attributes:[[/\@(module|type)?doc (~[sS])?"""/,{token:"comment.block.documentation",next:"@doubleQuotedHeredocDocstring"}],[/\@(module|type)?doc (~[sS])?'''/,{token:"comment.block.documentation",next:"@singleQuotedHeredocDocstring"}],[/\@(module|type)?doc (~[sS])?"/,{token:"comment.block.documentation",next:"@doubleQuotedStringDocstring"}],[/\@(module|type)?doc (~[sS])?'/,{token:"comment.block.documentation",next:"@singleQuotedStringDocstring"}],[/\@(module|type)?doc false/,"comment.block.documentation"],[/\@(@variableName)/,"variable"]],doubleQuotedHeredocDocstring:[[/"""/,{token:"comment.block.documentation",next:"@pop"}],{include:"@docstringContent"}],singleQuotedHeredocDocstring:[[/'''/,{token:"comment.block.documentation",next:"@pop"}],{include:"@docstringContent"}],doubleQuotedStringDocstring:[[/"/,{token:"comment.block.documentation",next:"@pop"}],{include:"@docstringContent"}],singleQuotedStringDocstring:[[/'/,{token:"comment.block.documentation",next:"@pop"}],{include:"@docstringContent"}],symbols:[[/\?(\\.|[^\\\s])/,"number.constant"],[/&\d+/,"operator"],[/<<<|>>>/,"operator"],[/[()\[\]\{\}]|<<|>>/,"@brackets"],[/\.\.\./,"identifier"],[/=>/,"punctuation"],[/@operator/,"operator"],[/[:;,.%]/,"punctuation"]],stringContentInterpol:[{include:"@interpolation"},{include:"@escapeChar"},{include:"@stringContent"}],stringContent:[[/./,"string"]],stringConstantContentInterpol:[{include:"@interpolation"},{include:"@escapeChar"},{include:"@stringConstantContent"}],stringConstantContent:[[/./,"constant"]],regexpContentInterpol:[{include:"@interpolation"},{include:"@escapeChar"},{include:"@regexpContent"}],regexpContent:[[/(\s)(#)(\s.*)$/,["white","comment.punctuation","comment"]],[/./,"regexp"]],sigilContentInterpol:[{include:"@interpolation"},{include:"@escapeChar"},{include:"@sigilContent"}],sigilContent:[[/./,"sigil"]],docstringContent:[[/./,"comment.block.documentation"]],escapeChar:[[/@escape/,"constant.character.escape"]],interpolation:[[/#{/,{token:"delimiter.bracket.embed",next:"@interpolationContinue"}]],interpolationContinue:[[/}/,{token:"delimiter.bracket.embed",next:"@pop"}],{include:"@root"}]}}});var I6e={};st(I6e,{conf:()=>kmt,language:()=>Lmt});var kmt,Lmt,E6e=k(()=>{kmt={comments:{blockComment:["/*","*/"],lineComment:"//"},brackets:[["{","}"],["[","]"],["(",")"]],autoClosingPairs:[{open:"{",close:"}",notIn:["string"]},{open:"[",close:"]",notIn:["string"]},{open:"(",close:")",notIn:["string"]},{open:'"',close:'"',notIn:["string"]},{open:"'",close:"'",notIn:["string"]}],surroundingPairs:[{open:"{",close:"}"},{open:"[",close:"]"},{open:"(",close:")"},{open:'"',close:'"'},{open:"'",close:"'"},{open:"<",close:">"}]},Lmt={defaultToken:"",tokenPostfix:".flow",keywords:["import","require","export","forbid","native","if","else","cast","unsafe","switch","default"],types:["io","mutable","bool","int","double","string","flow","void","ref","true","false","with"],operators:["=",">","<","<=",">=","==","!","!=",":=","::=","&&","||","+","-","*","/","@","&","%",":","->","\\","$","??","^"],symbols:/[@$=>](?!@symbols)/,"delimiter"],[/@symbols/,{cases:{"@operators":"delimiter","@default":""}}],[/((0(x|X)[0-9a-fA-F]*)|(([0-9]+\.?[0-9]*)|(\.[0-9]+))((e|E)(\+|-)?[0-9]+)?)/,"number"],[/[;,.]/,"delimiter"],[/"([^"\\]|\\.)*$/,"string.invalid"],[/"/,"string","@string"]],whitespace:[[/[ \t\r\n]+/,""],[/\/\*/,"comment","@comment"],[/\/\/.*$/,"comment"]],comment:[[/[^\/*]+/,"comment"],[/\*\//,"comment","@pop"],[/[\/*]/,"comment"]],string:[[/[^\\"]+/,"string"],[/@escapes/,"string.escape"],[/\\./,"string.escape.invalid"],[/"/,"string","@pop"]]}}});var T6e={};st(T6e,{conf:()=>Imt,language:()=>Emt});var Imt,Emt,D6e=k(()=>{Imt={comments:{lineComment:"//",blockComment:["(*","*)"]},brackets:[["{","}"],["[","]"],["(",")"]],autoClosingPairs:[{open:"{",close:"}"},{open:"[",close:"]"},{open:"(",close:")"},{open:'"',close:'"'}],surroundingPairs:[{open:"{",close:"}"},{open:"[",close:"]"},{open:"(",close:")"},{open:'"',close:'"'},{open:"'",close:"'"}],folding:{markers:{start:new RegExp("^\\s*//\\s*#region\\b|^\\s*\\(\\*\\s*#region(.*)\\*\\)"),end:new RegExp("^\\s*//\\s*#endregion\\b|^\\s*\\(\\*\\s*#endregion\\s*\\*\\)")}}},Emt={defaultToken:"",tokenPostfix:".fs",keywords:["abstract","and","atomic","as","assert","asr","base","begin","break","checked","component","const","constraint","constructor","continue","class","default","delegate","do","done","downcast","downto","elif","else","end","exception","eager","event","external","extern","false","finally","for","fun","function","fixed","functor","global","if","in","include","inherit","inline","interface","internal","land","lor","lsl","lsr","lxor","lazy","let","match","member","mod","module","mutable","namespace","method","mixin","new","not","null","of","open","or","object","override","private","parallel","process","protected","pure","public","rec","return","static","sealed","struct","sig","then","to","true","tailcall","trait","try","type","upcast","use","val","void","virtual","volatile","when","while","with","yield"],symbols:/[=>\]/,"annotation"],[/^#(if|else|endif)/,"keyword"],[/[{}()\[\]]/,"@brackets"],[/[<>](?!@symbols)/,"@brackets"],[/@symbols/,"delimiter"],[/\d*\d+[eE]([\-+]?\d+)?(@floatsuffix)/,"number.float"],[/\d*\.\d+([eE][\-+]?\d+)?(@floatsuffix)/,"number.float"],[/0x[0-9a-fA-F]+LF/,"number.float"],[/0x[0-9a-fA-F]+(@integersuffix)/,"number.hex"],[/0b[0-1]+(@integersuffix)/,"number.bin"],[/\d+(@integersuffix)/,"number"],[/[;,.]/,"delimiter"],[/"([^"\\]|\\.)*$/,"string.invalid"],[/"""/,"string",'@string."""'],[/"/,"string",'@string."'],[/\@"/,{token:"string.quote",next:"@litstring"}],[/'[^\\']'B?/,"string"],[/(')(@escapes)(')/,["string","string.escape","string"]],[/'/,"string.invalid"]],whitespace:[[/[ \t\r\n]+/,""],[/\(\*(?!\))/,"comment","@comment"],[/\/\/.*$/,"comment"]],comment:[[/[^*(]+/,"comment"],[/\*\)/,"comment","@pop"],[/\*/,"comment"],[/\(\*\)/,"comment"],[/\(/,"comment"]],string:[[/[^\\"]+/,"string"],[/@escapes/,"string.escape"],[/\\./,"string.escape.invalid"],[/("""|"B?)/,{cases:{"$#==$S2":{token:"string",next:"@pop"},"@default":"string"}}]],litstring:[[/[^"]+/,"string"],[/""/,"string.escape"],[/"/,{token:"string.quote",next:"@pop"}]]}}});var Vw={};st(Vw,{TagAngleInterpolationBracket:()=>Fmt,TagAngleInterpolationDollar:()=>Pmt,TagAutoInterpolationBracket:()=>Hmt,TagAutoInterpolationDollar:()=>Wmt,TagBracketInterpolationBracket:()=>Bmt,TagBracketInterpolationDollar:()=>Omt});function zj(n){return{brackets:[["<",">"],["[","]"],["(",")"],["{","}"]],comments:{blockComment:[`${n.open}--`,`--${n.close}`]},autoCloseBefore:` \r }]),.:;=`,autoClosingPairs:[{open:"{",close:"}"},{open:"[",close:"]"},{open:"(",close:")"},{open:'"',close:'"',notIn:["string"]},{open:"'",close:"'",notIn:["string"]}],surroundingPairs:[{open:'"',close:'"'},{open:"'",close:"'"},{open:"{",close:"}"},{open:"[",close:"]"},{open:"(",close:")"},{open:"<",close:">"}],folding:{markers:{start:new RegExp(`${n.open}#(?:${Hj.join("|")})([^/${n.close}]*(?!/)${n.close})[^${n.open}]*$`),end:new RegExp(`${n.open}/#(?:${Hj.join("|")})[\\r\\n\\t ]*>`)}},onEnterRules:[{beforeText:new RegExp(`${n.open}#(?!(?:${Wj.join("|")}))([a-zA-Z_]+)([^/${n.close}]*(?!/)${n.close})[^${n.open}]*$`),afterText:new RegExp(`^${n.open}/#([a-zA-Z_]+)[\\r\\n\\t ]*${n.close}$`),action:{indentAction:PP.languages.IndentAction.IndentOutdent}},{beforeText:new RegExp(`${n.open}#(?!(?:${Wj.join("|")}))([a-zA-Z_]+)([^/${n.close}]*(?!/)${n.close})[^${n.open}]*$`),action:{indentAction:PP.languages.IndentAction.Indent}}]}}function R6e(){return{brackets:[["<",">"],["[","]"],["(",")"],["{","}"]],autoCloseBefore:` \r }]),.:;=`,autoClosingPairs:[{open:"{",close:"}"},{open:"[",close:"]"},{open:"(",close:")"},{open:'"',close:'"',notIn:["string"]},{open:"'",close:"'",notIn:["string"]}],surroundingPairs:[{open:'"',close:'"'},{open:"'",close:"'"},{open:"{",close:"}"},{open:"[",close:"]"},{open:"(",close:")"},{open:"<",close:">"}],folding:{markers:{start:new RegExp(`[<\\[]#(?:${Hj.join("|")})([^/>\\]]*(?!/)[>\\]])[^<\\[]*$`),end:new RegExp(`[<\\[]/#(?:${Hj.join("|")})[\\r\\n\\t ]*>`)}},onEnterRules:[{beforeText:new RegExp(`[<\\[]#(?!(?:${Wj.join("|")}))([a-zA-Z_]+)([^/>\\]]*(?!/)[>\\]])[^[<\\[]]*$`),afterText:new RegExp("^[<\\[]/#([a-zA-Z_]+)[\\r\\n\\t ]*[>\\]]$"),action:{indentAction:PP.languages.IndentAction.IndentOutdent}},{beforeText:new RegExp(`[<\\[]#(?!(?:${Wj.join("|")}))([a-zA-Z_]+)([^/>\\]]*(?!/)[>\\]])[^[<\\[]]*$`),action:{indentAction:PP.languages.IndentAction.Indent}}]}}function O0(n,e){let t=`_${n.id}_${e.id}`,i=r=>r.replace(/__id__/g,t),o=r=>{let s=r.source.replace(/__id__/g,t);return new RegExp(s,r.flags)};return{unicode:!0,includeLF:!1,start:i("default__id__"),ignoreCase:!1,defaultToken:"invalid",tokenPostfix:".freemarker2",brackets:[{open:"{",close:"}",token:"delimiter.curly"},{open:"[",close:"]",token:"delimiter.square"},{open:"(",close:")",token:"delimiter.parenthesis"},{open:"<",close:">",token:"delimiter.angle"}],[i("open__id__")]:new RegExp(n.open),[i("close__id__")]:new RegExp(n.close),[i("iOpen1__id__")]:new RegExp(e.open1),[i("iOpen2__id__")]:new RegExp(e.open2),[i("iClose__id__")]:new RegExp(e.close),[i("startTag__id__")]:o(/(@open__id__)(#)/),[i("endTag__id__")]:o(/(@open__id__)(\/#)/),[i("startOrEndTag__id__")]:o(/(@open__id__)(\/?#)/),[i("closeTag1__id__")]:o(/((?:@blank)*)(@close__id__)/),[i("closeTag2__id__")]:o(/((?:@blank)*\/?)(@close__id__)/),blank:/[ \t\n\r]/,keywords:["false","true","in","as","using"],directiveStartCloseTag1:/attempt|recover|sep|auto[eE]sc|no(?:autoe|AutoE)sc|compress|default|no[eE]scape|comment|no[pP]arse/,directiveStartCloseTag2:/else|break|continue|return|stop|flush|t|lt|rt|nt|nested|recurse|fallback|ftl/,directiveStartBlank:/if|else[iI]f|list|for[eE]ach|switch|case|assign|global|local|include|import|function|macro|transform|visit|stop|return|call|setting|output[fF]ormat|nested|recurse|escape|ftl|items/,directiveEndCloseTag1:/if|list|items|sep|recover|attempt|for[eE]ach|local|global|assign|function|macro|output[fF]ormat|auto[eE]sc|no(?:autoe|AutoE)sc|compress|transform|switch|escape|no[eE]scape/,escapedChar:/\\(?:[ntrfbgla\\'"\{=]|(?:x[0-9A-Fa-f]{1,4}))/,asciiDigit:/[0-9]/,integer:/[0-9]+/,nonEscapedIdStartChar:/[\$@-Z_a-z\u00AA\u00B5\u00BA\u00C0-\u00D6\u00D8-\u00F6\u00F8-\u1FFF\u2071\u207F\u2090-\u209C\u2102\u2107\u210A-\u2113\u2115\u2119-\u211D\u2124\u2126\u2128\u212A-\u212D\u212F-\u2139\u213C-\u213F\u2145-\u2149\u214E\u2183-\u2184\u2C00-\u2C2E\u2C30-\u2C5E\u2C60-\u2CE4\u2CEB-\u2CEE\u2CF2-\u2CF3\u2D00-\u2D25\u2D27\u2D2D\u2D30-\u2D67\u2D6F\u2D80-\u2D96\u2DA0-\u2DA6\u2DA8-\u2DAE\u2DB0-\u2DB6\u2DB8-\u2DBE\u2DC0-\u2DC6\u2DC8-\u2DCE\u2DD0-\u2DD6\u2DD8-\u2DDE\u2E2F\u3005-\u3006\u3031-\u3035\u303B-\u303C\u3040-\u318F\u31A0-\u31BA\u31F0-\u31FF\u3300-\u337F\u3400-\u4DB5\u4E00-\uA48C\uA4D0-\uA4FD\uA500-\uA60C\uA610-\uA62B\uA640-\uA66E\uA67F-\uA697\uA6A0-\uA6E5\uA717-\uA71F\uA722-\uA788\uA78B-\uA78E\uA790-\uA793\uA7A0-\uA7AA\uA7F8-\uA801\uA803-\uA805\uA807-\uA80A\uA80C-\uA822\uA840-\uA873\uA882-\uA8B3\uA8D0-\uA8D9\uA8F2-\uA8F7\uA8FB\uA900-\uA925\uA930-\uA946\uA960-\uA97C\uA984-\uA9B2\uA9CF-\uA9D9\uAA00-\uAA28\uAA40-\uAA42\uAA44-\uAA4B\uAA50-\uAA59\uAA60-\uAA76\uAA7A\uAA80-\uAAAF\uAAB1\uAAB5-\uAAB6\uAAB9-\uAABD\uAAC0\uAAC2\uAADB-\uAADD\uAAE0-\uAAEA\uAAF2-\uAAF4\uAB01-\uAB06\uAB09-\uAB0E\uAB11-\uAB16\uAB20-\uAB26\uAB28-\uAB2E\uABC0-\uABE2\uABF0-\uABF9\uAC00-\uD7A3\uD7B0-\uD7C6\uD7CB-\uD7FB\uF900-\uFB06\uFB13-\uFB17\uFB1D\uFB1F-\uFB28\uFB2A-\uFB36\uFB38-\uFB3C\uFB3E\uFB40-\uFB41\uFB43-\uFB44\uFB46-\uFBB1\uFBD3-\uFD3D\uFD50-\uFD8F\uFD92-\uFDC7\uFDF0-\uFDFB\uFE70-\uFE74\uFE76-\uFEFC\uFF10-\uFF19\uFF21-\uFF3A\uFF41-\uFF5A\uFF66-\uFFBE\uFFC2-\uFFC7\uFFCA-\uFFCF\uFFD2-\uFFD7\uFFDA-\uFFDC]/,escapedIdChar:/\\[\-\.:#]/,idStartChar:/(?:@nonEscapedIdStartChar)|(?:@escapedIdChar)/,id:/(?:@idStartChar)(?:(?:@idStartChar)|(?:@asciiDigit))*/,specialHashKeys:/\*\*|\*|false|true|in|as|using/,namedSymbols:/<=|>=|\\lte|\\lt|<|\\gte|\\gt|>|&&|\\and|->|->|==|!=|\+=|-=|\*=|\/=|%=|\+\+|--|<=|&&|\|\||:|\.\.\.|\.\.\*|\.\.<|\.\.!|\?\?|=|<|\+|-|\*|\/|%|\||\.\.|\?|!|&|\.|,|;/,arrows:["->","->"],delimiters:[";",":",",","."],stringOperators:["lte","lt","gte","gt"],noParseTags:["noparse","noParse","comment"],tokenizer:{[i("default__id__")]:[{include:i("@directive_token__id__")},{include:i("@interpolation_and_text_token__id__")}],[i("fmExpression__id__.directive")]:[{include:i("@blank_and_expression_comment_token__id__")},{include:i("@directive_end_token__id__")},{include:i("@expression_token__id__")}],[i("fmExpression__id__.interpolation")]:[{include:i("@blank_and_expression_comment_token__id__")},{include:i("@expression_token__id__")},{include:i("@greater_operators_token__id__")}],[i("inParen__id__.plain")]:[{include:i("@blank_and_expression_comment_token__id__")},{include:i("@directive_end_token__id__")},{include:i("@expression_token__id__")}],[i("inParen__id__.gt")]:[{include:i("@blank_and_expression_comment_token__id__")},{include:i("@expression_token__id__")},{include:i("@greater_operators_token__id__")}],[i("noSpaceExpression__id__")]:[{include:i("@no_space_expression_end_token__id__")},{include:i("@directive_end_token__id__")},{include:i("@expression_token__id__")}],[i("unifiedCall__id__")]:[{include:i("@unified_call_token__id__")}],[i("singleString__id__")]:[{include:i("@string_single_token__id__")}],[i("doubleString__id__")]:[{include:i("@string_double_token__id__")}],[i("rawSingleString__id__")]:[{include:i("@string_single_raw_token__id__")}],[i("rawDoubleString__id__")]:[{include:i("@string_double_raw_token__id__")}],[i("expressionComment__id__")]:[{include:i("@expression_comment_token__id__")}],[i("noParse__id__")]:[{include:i("@no_parse_token__id__")}],[i("terseComment__id__")]:[{include:i("@terse_comment_token__id__")}],[i("directive_token__id__")]:[[o(/(?:@startTag__id__)(@directiveStartCloseTag1)(?:@closeTag1__id__)/),n.id==="auto"?{cases:{"$1==<":{token:"@rematch",switchTo:`@default_angle_${e.id}`},"$1==[":{token:"@rematch",switchTo:`@default_bracket_${e.id}`}}}:[{token:"@brackets.directive"},{token:"delimiter.directive"},{cases:{"@noParseTags":{token:"tag",next:i("@noParse__id__.$3")},"@default":{token:"tag"}}},{token:"delimiter.directive"},{token:"@brackets.directive"}]],[o(/(?:@startTag__id__)(@directiveStartCloseTag2)(?:@closeTag2__id__)/),n.id==="auto"?{cases:{"$1==<":{token:"@rematch",switchTo:`@default_angle_${e.id}`},"$1==[":{token:"@rematch",switchTo:`@default_bracket_${e.id}`}}}:[{token:"@brackets.directive"},{token:"delimiter.directive"},{token:"tag"},{token:"delimiter.directive"},{token:"@brackets.directive"}]],[o(/(?:@startTag__id__)(@directiveStartBlank)(@blank)/),n.id==="auto"?{cases:{"$1==<":{token:"@rematch",switchTo:`@default_angle_${e.id}`},"$1==[":{token:"@rematch",switchTo:`@default_bracket_${e.id}`}}}:[{token:"@brackets.directive"},{token:"delimiter.directive"},{token:"tag"},{token:"",next:i("@fmExpression__id__.directive")}]],[o(/(?:@endTag__id__)(@directiveEndCloseTag1)(?:@closeTag1__id__)/),n.id==="auto"?{cases:{"$1==<":{token:"@rematch",switchTo:`@default_angle_${e.id}`},"$1==[":{token:"@rematch",switchTo:`@default_bracket_${e.id}`}}}:[{token:"@brackets.directive"},{token:"delimiter.directive"},{token:"tag"},{token:"delimiter.directive"},{token:"@brackets.directive"}]],[o(/(@open__id__)(@)/),n.id==="auto"?{cases:{"$1==<":{token:"@rematch",switchTo:`@default_angle_${e.id}`},"$1==[":{token:"@rematch",switchTo:`@default_bracket_${e.id}`}}}:[{token:"@brackets.directive"},{token:"delimiter.directive",next:i("@unifiedCall__id__")}]],[o(/(@open__id__)(\/@)((?:(?:@id)(?:\.(?:@id))*)?)(?:@closeTag1__id__)/),[{token:"@brackets.directive"},{token:"delimiter.directive"},{token:"tag"},{token:"delimiter.directive"},{token:"@brackets.directive"}]],[o(/(@open__id__)#--/),n.id==="auto"?{cases:{"$1==<":{token:"@rematch",switchTo:`@default_angle_${e.id}`},"$1==[":{token:"@rematch",switchTo:`@default_bracket_${e.id}`}}}:{token:"comment",next:i("@terseComment__id__")}],[o(/(?:@startOrEndTag__id__)([a-zA-Z_]+)/),n.id==="auto"?{cases:{"$1==<":{token:"@rematch",switchTo:`@default_angle_${e.id}`},"$1==[":{token:"@rematch",switchTo:`@default_bracket_${e.id}`}}}:[{token:"@brackets.directive"},{token:"delimiter.directive"},{token:"tag.invalid",next:i("@fmExpression__id__.directive")}]]],[i("interpolation_and_text_token__id__")]:[[o(/(@iOpen1__id__)(@iOpen2__id__)/),[{token:e.id==="bracket"?"@brackets.interpolation":"delimiter.interpolation"},{token:e.id==="bracket"?"delimiter.interpolation":"@brackets.interpolation",next:i("@fmExpression__id__.interpolation")}]],[/[\$#<\[\{]|(?:@blank)+|[^\$<#\[\{\n\r\t ]+/,{token:"source"}]],[i("string_single_token__id__")]:[[/[^'\\]/,{token:"string"}],[/@escapedChar/,{token:"string.escape"}],[/'/,{token:"string",next:"@pop"}]],[i("string_double_token__id__")]:[[/[^"\\]/,{token:"string"}],[/@escapedChar/,{token:"string.escape"}],[/"/,{token:"string",next:"@pop"}]],[i("string_single_raw_token__id__")]:[[/[^']+/,{token:"string.raw"}],[/'/,{token:"string.raw",next:"@pop"}]],[i("string_double_raw_token__id__")]:[[/[^"]+/,{token:"string.raw"}],[/"/,{token:"string.raw",next:"@pop"}]],[i("expression_token__id__")]:[[/(r?)(['"])/,{cases:{"r'":[{token:"keyword"},{token:"string.raw",next:i("@rawSingleString__id__")}],'r"':[{token:"keyword"},{token:"string.raw",next:i("@rawDoubleString__id__")}],"'":[{token:"source"},{token:"string",next:i("@singleString__id__")}],'"':[{token:"source"},{token:"string",next:i("@doubleString__id__")}]}}],[/(?:@integer)(?:\.(?:@integer))?/,{cases:{"(?:@integer)":{token:"number"},"@default":{token:"number.float"}}}],[/(\.)(@blank*)(@specialHashKeys)/,[{token:"delimiter"},{token:""},{token:"identifier"}]],[/(?:@namedSymbols)/,{cases:{"@arrows":{token:"meta.arrow"},"@delimiters":{token:"delimiter"},"@default":{token:"operators"}}}],[/@id/,{cases:{"@keywords":{token:"keyword.$0"},"@stringOperators":{token:"operators"},"@default":{token:"identifier"}}}],[/[\[\]\(\)\{\}]/,{cases:{"\\[":{cases:{"$S2==gt":{token:"@brackets",next:i("@inParen__id__.gt")},"@default":{token:"@brackets",next:i("@inParen__id__.plain")}}},"\\]":{cases:{...e.id==="bracket"?{"$S2==interpolation":{token:"@brackets.interpolation",next:"@popall"}}:{},...n.id==="bracket"?{"$S2==directive":{token:"@brackets.directive",next:"@popall"}}:{},[i("$S1==inParen__id__")]:{token:"@brackets",next:"@pop"},"@default":{token:"@brackets"}}},"\\(":{token:"@brackets",next:i("@inParen__id__.gt")},"\\)":{cases:{[i("$S1==inParen__id__")]:{token:"@brackets",next:"@pop"},"@default":{token:"@brackets"}}},"\\{":{cases:{"$S2==gt":{token:"@brackets",next:i("@inParen__id__.gt")},"@default":{token:"@brackets",next:i("@inParen__id__.plain")}}},"\\}":{cases:{...e.id==="bracket"?{}:{"$S2==interpolation":{token:"@brackets.interpolation",next:"@popall"}},[i("$S1==inParen__id__")]:{token:"@brackets",next:"@pop"},"@default":{token:"@brackets"}}}}}],[/\$\{/,{token:"delimiter.invalid"}]],[i("blank_and_expression_comment_token__id__")]:[[/(?:@blank)+/,{token:""}],[/[<\[][#!]--/,{token:"comment",next:i("@expressionComment__id__")}]],[i("directive_end_token__id__")]:[[/>/,n.id==="bracket"?{token:"operators"}:{token:"@brackets.directive",next:"@popall"}],[o(/(\/)(@close__id__)/),[{token:"delimiter.directive"},{token:"@brackets.directive",next:"@popall"}]]],[i("greater_operators_token__id__")]:[[/>/,{token:"operators"}],[/>=/,{token:"operators"}]],[i("no_space_expression_end_token__id__")]:[[/(?:@blank)+/,{token:"",switchTo:i("@fmExpression__id__.directive")}]],[i("unified_call_token__id__")]:[[/(@id)((?:@blank)+)/,[{token:"tag"},{token:"",next:i("@fmExpression__id__.directive")}]],[o(/(@id)(\/?)(@close__id__)/),[{token:"tag"},{token:"delimiter.directive"},{token:"@brackets.directive",next:"@popall"}]],[/./,{token:"@rematch",next:i("@noSpaceExpression__id__")}]],[i("no_parse_token__id__")]:[[o(/(@open__id__)(\/#?)([a-zA-Z]+)((?:@blank)*)(@close__id__)/),{cases:{"$S2==$3":[{token:"@brackets.directive"},{token:"delimiter.directive"},{token:"tag"},{token:""},{token:"@brackets.directive",next:"@popall"}],"$S2==comment":[{token:"comment"},{token:"comment"},{token:"comment"},{token:"comment"},{token:"comment"}],"@default":[{token:"source"},{token:"source"},{token:"source"},{token:"source"},{token:"source"}]}}],[/[^<\[\-]+|[<\[\-]/,{cases:{"$S2==comment":{token:"comment"},"@default":{token:"source"}}}]],[i("expression_comment_token__id__")]:[[/--[>\]]/,{token:"comment",next:"@pop"}],[/[^\->\]]+|[>\]\-]/,{token:"comment"}]],[i("terse_comment_token__id__")]:[[o(/--(?:@close__id__)/),{token:"comment",next:"@popall"}],[/[^<\[\-]+|[<\[\-]/,{token:"comment"}]]}}}function A6e(n){let e=O0(OP,n),t=O0(FP,n),i=O0(Mmt,n);return{...e,...t,...i,unicode:!0,includeLF:!1,start:`default_auto_${n.id}`,ignoreCase:!1,defaultToken:"invalid",tokenPostfix:".freemarker2",brackets:[{open:"{",close:"}",token:"delimiter.curly"},{open:"[",close:"]",token:"delimiter.square"},{open:"(",close:")",token:"delimiter.parenthesis"},{open:"<",close:">",token:"delimiter.angle"}],tokenizer:{...e.tokenizer,...t.tokenizer,...i.tokenizer}}}var Tmt,Dmt,Nmt,Rmt,N6e,Amt,PP,Wj,Hj,OP,FP,Mmt,kpe,Lpe,Pmt,Omt,Fmt,Bmt,Wmt,Hmt,Uw=k(()=>{Ir();Tmt=Object.defineProperty,Dmt=Object.getOwnPropertyDescriptor,Nmt=Object.getOwnPropertyNames,Rmt=Object.prototype.hasOwnProperty,N6e=(n,e,t,i)=>{if(e&&typeof e=="object"||typeof e=="function")for(let o of Nmt(e))!Rmt.call(n,o)&&o!==t&&Tmt(n,o,{get:()=>e[o],enumerable:!(i=Dmt(e,o))||i.enumerable});return n},Amt=(n,e,t)=>(N6e(n,e,"default"),t&&N6e(t,e,"default")),PP={};Amt(PP,fn);Wj=["assign","flush","ftl","return","global","import","include","break","continue","local","nested","nt","setting","stop","t","lt","rt","fallback"],Hj=["attempt","autoesc","autoEsc","compress","comment","escape","noescape","function","if","list","items","sep","macro","noparse","noParse","noautoesc","noAutoEsc","outputformat","switch","visit","recurse"],OP={close:">",id:"angle",open:"<"},FP={close:"\\]",id:"bracket",open:"\\["},Mmt={close:"[>\\]]",id:"auto",open:"[<\\[]"},kpe={close:"\\}",id:"dollar",open1:"\\$",open2:"\\{"},Lpe={close:"\\]",id:"bracket",open1:"\\[",open2:"="};Pmt={conf:zj(OP),language:O0(OP,kpe)},Omt={conf:zj(FP),language:O0(FP,kpe)},Fmt={conf:zj(OP),language:O0(OP,Lpe)},Bmt={conf:zj(FP),language:O0(FP,Lpe)},Wmt={conf:R6e(),language:A6e(kpe)},Hmt={conf:R6e(),language:A6e(Lpe)}});var M6e={};st(M6e,{conf:()=>zmt,language:()=>Vmt});var zmt,Vmt,P6e=k(()=>{zmt={comments:{lineComment:"//",blockComment:["/*","*/"]},brackets:[["{","}"],["[","]"],["(",")"]],autoClosingPairs:[{open:"{",close:"}"},{open:"[",close:"]"},{open:"(",close:")"},{open:"`",close:"`",notIn:["string"]},{open:'"',close:'"',notIn:["string"]},{open:"'",close:"'",notIn:["string","comment"]}],surroundingPairs:[{open:"{",close:"}"},{open:"[",close:"]"},{open:"(",close:")"},{open:"`",close:"`"},{open:'"',close:'"'},{open:"'",close:"'"}]},Vmt={defaultToken:"",tokenPostfix:".go",keywords:["break","case","chan","const","continue","default","defer","else","fallthrough","for","func","go","goto","if","import","interface","map","package","range","return","select","struct","switch","type","var","bool","true","false","uint8","uint16","uint32","uint64","int8","int16","int32","int64","float32","float64","complex64","complex128","byte","rune","uint","int","uintptr","string","nil"],operators:["+","-","*","/","%","&","|","^","<<",">>","&^","+=","-=","*=","/=","%=","&=","|=","^=","<<=",">>=","&^=","&&","||","<-","++","--","==","<",">","=","!","!=","<=",">=",":=","...","(",")","","]","{","}",",",";",".",":"],symbols:/[=>](?!@symbols)/,"@brackets"],[/@symbols/,{cases:{"@operators":"delimiter","@default":""}}],[/\d*\d+[eE]([\-+]?\d+)?/,"number.float"],[/\d*\.\d+([eE][\-+]?\d+)?/,"number.float"],[/0[xX][0-9a-fA-F']*[0-9a-fA-F]/,"number.hex"],[/0[0-7']*[0-7]/,"number.octal"],[/0[bB][0-1']*[0-1]/,"number.binary"],[/\d[\d']*/,"number"],[/\d/,"number"],[/[;,.]/,"delimiter"],[/"([^"\\]|\\.)*$/,"string.invalid"],[/"/,"string","@string"],[/`/,"string","@rawstring"],[/'[^\\']'/,"string"],[/(')(@escapes)(')/,["string","string.escape","string"]],[/'/,"string.invalid"]],whitespace:[[/[ \t\r\n]+/,""],[/\/\*\*(?!\/)/,"comment.doc","@doccomment"],[/\/\*/,"comment","@comment"],[/\/\/.*$/,"comment"]],comment:[[/[^\/*]+/,"comment"],[/\*\//,"comment","@pop"],[/[\/*]/,"comment"]],doccomment:[[/[^\/*]+/,"comment.doc"],[/\/\*/,"comment.doc.invalid"],[/\*\//,"comment.doc","@pop"],[/[\/*]/,"comment.doc"]],string:[[/[^\\"]+/,"string"],[/@escapes/,"string.escape"],[/\\./,"string.escape.invalid"],[/"/,"string","@pop"]],rawstring:[[/[^\`]/,"string"],[/`/,"string","@pop"]]}}});var O6e={};st(O6e,{conf:()=>Umt,language:()=>$mt});var Umt,$mt,F6e=k(()=>{Umt={comments:{lineComment:"#"},brackets:[["{","}"],["[","]"],["(",")"]],autoClosingPairs:[{open:"{",close:"}"},{open:"[",close:"]"},{open:"(",close:")"},{open:'"""',close:'"""',notIn:["string","comment"]},{open:'"',close:'"',notIn:["string","comment"]}],surroundingPairs:[{open:"{",close:"}"},{open:"[",close:"]"},{open:"(",close:")"},{open:'"""',close:'"""'},{open:'"',close:'"'}],folding:{offSide:!0}},$mt={defaultToken:"invalid",tokenPostfix:".gql",keywords:["null","true","false","query","mutation","subscription","extend","schema","directive","scalar","type","interface","union","enum","input","implements","fragment","on"],typeKeywords:["Int","Float","String","Boolean","ID"],directiveLocations:["SCHEMA","SCALAR","OBJECT","FIELD_DEFINITION","ARGUMENT_DEFINITION","INTERFACE","UNION","ENUM","ENUM_VALUE","INPUT_OBJECT","INPUT_FIELD_DEFINITION","QUERY","MUTATION","SUBSCRIPTION","FIELD","FRAGMENT_DEFINITION","FRAGMENT_SPREAD","INLINE_FRAGMENT","VARIABLE_DEFINITION"],operators:["=","!","?",":","&","|"],symbols:/[=!?:&|]+/,escapes:/\\(?:["\\\/bfnrt]|u[0-9A-Fa-f]{4})/,tokenizer:{root:[[/[a-z_][\w$]*/,{cases:{"@keywords":"keyword","@default":"key.identifier"}}],[/[$][\w$]*/,{cases:{"@keywords":"keyword","@default":"argument.identifier"}}],[/[A-Z][\w\$]*/,{cases:{"@typeKeywords":"keyword","@default":"type.identifier"}}],{include:"@whitespace"},[/[{}()\[\]]/,"@brackets"],[/@symbols/,{cases:{"@operators":"operator","@default":""}}],[/@\s*[a-zA-Z_\$][\w\$]*/,{token:"annotation",log:"annotation token: $0"}],[/\d*\.\d+([eE][\-+]?\d+)?/,"number.float"],[/0[xX][0-9a-fA-F]+/,"number.hex"],[/\d+/,"number"],[/[;,.]/,"delimiter"],[/"""/,{token:"string",next:"@mlstring",nextEmbedded:"markdown"}],[/"([^"\\]|\\.)*$/,"string.invalid"],[/"/,{token:"string.quote",bracket:"@open",next:"@string"}]],mlstring:[[/[^"]+/,"string"],['"""',{token:"string",next:"@pop",nextEmbedded:"@pop"}]],string:[[/[^\\"]+/,"string"],[/@escapes/,"string.escape"],[/\\./,"string.escape.invalid"],[/"/,{token:"string.quote",bracket:"@close",next:"@pop"}]],whitespace:[[/[ \t\r\n]+/,""],[/#.*$/,"comment"]]}}});var H6e={};st(H6e,{conf:()=>Zmt,language:()=>Xmt});var jmt,qmt,Kmt,Gmt,B6e,Ymt,Ipe,W6e,Zmt,Xmt,z6e=k(()=>{Ir();jmt=Object.defineProperty,qmt=Object.getOwnPropertyDescriptor,Kmt=Object.getOwnPropertyNames,Gmt=Object.prototype.hasOwnProperty,B6e=(n,e,t,i)=>{if(e&&typeof e=="object"||typeof e=="function")for(let o of Kmt(e))!Gmt.call(n,o)&&o!==t&&jmt(n,o,{get:()=>e[o],enumerable:!(i=qmt(e,o))||i.enumerable});return n},Ymt=(n,e,t)=>(B6e(n,e,"default"),t&&B6e(t,e,"default")),Ipe={};Ymt(Ipe,fn);W6e=["area","base","br","col","embed","hr","img","input","keygen","link","menuitem","meta","param","source","track","wbr"],Zmt={wordPattern:/(-?\d*\.\d\w*)|([^\`\~\!\@\$\^\&\*\(\)\=\+\[\{\]\}\\\|\;\:\'\"\,\.\<\>\/\s]+)/g,comments:{blockComment:["{{!--","--}}"]},brackets:[[""],["<",">"],["{{","}}"],["{","}"],["(",")"]],autoClosingPairs:[{open:"{",close:"}"},{open:"[",close:"]"},{open:"(",close:")"},{open:'"',close:'"'},{open:"'",close:"'"}],surroundingPairs:[{open:"<",close:">"},{open:'"',close:'"'},{open:"'",close:"'"}],onEnterRules:[{beforeText:new RegExp(`<(?!(?:${W6e.join("|")}))(\\w[\\w\\d]*)([^/>]*(?!/)>)[^<]*$`,"i"),afterText:/^<\/(\w[\w\d]*)\s*>$/i,action:{indentAction:Ipe.languages.IndentAction.IndentOutdent}},{beforeText:new RegExp(`<(?!(?:${W6e.join("|")}))(\\w[\\w\\d]*)([^/>]*(?!/)>)[^<]*$`,"i"),action:{indentAction:Ipe.languages.IndentAction.Indent}}]},Xmt={defaultToken:"",tokenPostfix:"",tokenizer:{root:[[/\{\{!--/,"comment.block.start.handlebars","@commentBlock"],[/\{\{!/,"comment.start.handlebars","@comment"],[/\{\{/,{token:"@rematch",switchTo:"@handlebarsInSimpleState.root"}],[/)/,["delimiter.html","tag.html","delimiter.html"]],[/(<)(script)/,["delimiter.html",{token:"tag.html",next:"@script"}]],[/(<)(style)/,["delimiter.html",{token:"tag.html",next:"@style"}]],[/(<)([:\w]+)/,["delimiter.html",{token:"tag.html",next:"@otherTag"}]],[/(<\/)(\w+)/,["delimiter.html",{token:"tag.html",next:"@otherTag"}]],[/]+/,"metatag.content.html"],[/>/,"metatag.html","@pop"]],comment:[[/\}\}/,"comment.end.handlebars","@pop"],[/./,"comment.content.handlebars"]],commentBlock:[[/--\}\}/,"comment.block.end.handlebars","@pop"],[/./,"comment.content.handlebars"]],commentHtml:[[/\{\{/,{token:"@rematch",switchTo:"@handlebarsInSimpleState.comment"}],[/-->/,"comment.html","@pop"],[/[^-]+/,"comment.content.html"],[/./,"comment.content.html"]],otherTag:[[/\{\{/,{token:"@rematch",switchTo:"@handlebarsInSimpleState.otherTag"}],[/\/?>/,"delimiter.html","@pop"],[/"([^"]*)"/,"attribute.value"],[/'([^']*)'/,"attribute.value"],[/[\w\-]+/,"attribute.name"],[/=/,"delimiter"],[/[ \t\r\n]+/]],script:[[/\{\{/,{token:"@rematch",switchTo:"@handlebarsInSimpleState.script"}],[/type/,"attribute.name","@scriptAfterType"],[/"([^"]*)"/,"attribute.value"],[/'([^']*)'/,"attribute.value"],[/[\w\-]+/,"attribute.name"],[/=/,"delimiter"],[/>/,{token:"delimiter.html",next:"@scriptEmbedded.text/javascript",nextEmbedded:"text/javascript"}],[/[ \t\r\n]+/],[/(<\/)(script\s*)(>)/,["delimiter.html","tag.html",{token:"delimiter.html",next:"@pop"}]]],scriptAfterType:[[/\{\{/,{token:"@rematch",switchTo:"@handlebarsInSimpleState.scriptAfterType"}],[/=/,"delimiter","@scriptAfterTypeEquals"],[/>/,{token:"delimiter.html",next:"@scriptEmbedded.text/javascript",nextEmbedded:"text/javascript"}],[/[ \t\r\n]+/],[/<\/script\s*>/,{token:"@rematch",next:"@pop"}]],scriptAfterTypeEquals:[[/\{\{/,{token:"@rematch",switchTo:"@handlebarsInSimpleState.scriptAfterTypeEquals"}],[/"([^"]*)"/,{token:"attribute.value",switchTo:"@scriptWithCustomType.$1"}],[/'([^']*)'/,{token:"attribute.value",switchTo:"@scriptWithCustomType.$1"}],[/>/,{token:"delimiter.html",next:"@scriptEmbedded.text/javascript",nextEmbedded:"text/javascript"}],[/[ \t\r\n]+/],[/<\/script\s*>/,{token:"@rematch",next:"@pop"}]],scriptWithCustomType:[[/\{\{/,{token:"@rematch",switchTo:"@handlebarsInSimpleState.scriptWithCustomType.$S2"}],[/>/,{token:"delimiter.html",next:"@scriptEmbedded.$S2",nextEmbedded:"$S2"}],[/"([^"]*)"/,"attribute.value"],[/'([^']*)'/,"attribute.value"],[/[\w\-]+/,"attribute.name"],[/=/,"delimiter"],[/[ \t\r\n]+/],[/<\/script\s*>/,{token:"@rematch",next:"@pop"}]],scriptEmbedded:[[/\{\{/,{token:"@rematch",switchTo:"@handlebarsInEmbeddedState.scriptEmbedded.$S2",nextEmbedded:"@pop"}],[/<\/script/,{token:"@rematch",next:"@pop",nextEmbedded:"@pop"}]],style:[[/\{\{/,{token:"@rematch",switchTo:"@handlebarsInSimpleState.style"}],[/type/,"attribute.name","@styleAfterType"],[/"([^"]*)"/,"attribute.value"],[/'([^']*)'/,"attribute.value"],[/[\w\-]+/,"attribute.name"],[/=/,"delimiter"],[/>/,{token:"delimiter.html",next:"@styleEmbedded.text/css",nextEmbedded:"text/css"}],[/[ \t\r\n]+/],[/(<\/)(style\s*)(>)/,["delimiter.html","tag.html",{token:"delimiter.html",next:"@pop"}]]],styleAfterType:[[/\{\{/,{token:"@rematch",switchTo:"@handlebarsInSimpleState.styleAfterType"}],[/=/,"delimiter","@styleAfterTypeEquals"],[/>/,{token:"delimiter.html",next:"@styleEmbedded.text/css",nextEmbedded:"text/css"}],[/[ \t\r\n]+/],[/<\/style\s*>/,{token:"@rematch",next:"@pop"}]],styleAfterTypeEquals:[[/\{\{/,{token:"@rematch",switchTo:"@handlebarsInSimpleState.styleAfterTypeEquals"}],[/"([^"]*)"/,{token:"attribute.value",switchTo:"@styleWithCustomType.$1"}],[/'([^']*)'/,{token:"attribute.value",switchTo:"@styleWithCustomType.$1"}],[/>/,{token:"delimiter.html",next:"@styleEmbedded.text/css",nextEmbedded:"text/css"}],[/[ \t\r\n]+/],[/<\/style\s*>/,{token:"@rematch",next:"@pop"}]],styleWithCustomType:[[/\{\{/,{token:"@rematch",switchTo:"@handlebarsInSimpleState.styleWithCustomType.$S2"}],[/>/,{token:"delimiter.html",next:"@styleEmbedded.$S2",nextEmbedded:"$S2"}],[/"([^"]*)"/,"attribute.value"],[/'([^']*)'/,"attribute.value"],[/[\w\-]+/,"attribute.name"],[/=/,"delimiter"],[/[ \t\r\n]+/],[/<\/style\s*>/,{token:"@rematch",next:"@pop"}]],styleEmbedded:[[/\{\{/,{token:"@rematch",switchTo:"@handlebarsInEmbeddedState.styleEmbedded.$S2",nextEmbedded:"@pop"}],[/<\/style/,{token:"@rematch",next:"@pop",nextEmbedded:"@pop"}]],handlebarsInSimpleState:[[/\{\{\{?/,"delimiter.handlebars"],[/\}\}\}?/,{token:"delimiter.handlebars",switchTo:"@$S2.$S3"}],{include:"handlebarsRoot"}],handlebarsInEmbeddedState:[[/\{\{\{?/,"delimiter.handlebars"],[/\}\}\}?/,{token:"delimiter.handlebars",switchTo:"@$S2.$S3",nextEmbedded:"$S3"}],{include:"handlebarsRoot"}],handlebarsRoot:[[/"[^"]*"/,"string.handlebars"],[/[#/][^\s}]+/,"keyword.helper.handlebars"],[/else\b/,"keyword.helper.handlebars"],[/[\s]+/],[/[^}]/,"variable.parameter.handlebars"]]}}});var V6e={};st(V6e,{conf:()=>Qmt,language:()=>Jmt});var Qmt,Jmt,U6e=k(()=>{Qmt={comments:{lineComment:"#",blockComment:["/*","*/"]},brackets:[["{","}"],["[","]"],["(",")"]],autoClosingPairs:[{open:"{",close:"}"},{open:"[",close:"]"},{open:"(",close:")"},{open:'"',close:'"',notIn:["string"]}],surroundingPairs:[{open:"{",close:"}"},{open:"[",close:"]"},{open:"(",close:")"},{open:'"',close:'"'}]},Jmt={defaultToken:"",tokenPostfix:".hcl",keywords:["var","local","path","for_each","any","string","number","bool","true","false","null","if ","else ","endif ","for ","in","endfor"],operators:["=",">=","<=","==","!=","+","-","*","/","%","&&","||","!","<",">","?","...",":"],symbols:/[=>](?!@symbols)/,"@brackets"],[/@symbols/,{cases:{"@operators":"operator","@default":""}}],[/\d*\d+[eE]([\-+]?\d+)?/,"number.float"],[/\d*\.\d+([eE][\-+]?\d+)?/,"number.float"],[/\d[\d']*/,"number"],[/\d/,"number"],[/[;,.]/,"delimiter"],[/"/,"string","@string"],[/'/,"invalid"]],heredoc:[[/<<[-]*\s*["]?([\w\-]+)["]?/,{token:"string.heredoc.delimiter",next:"@heredocBody.$1"}]],heredocBody:[[/([\w\-]+)$/,{cases:{"$1==$S2":[{token:"string.heredoc.delimiter",next:"@popall"}],"@default":"string.heredoc"}}],[/./,"string.heredoc"]],whitespace:[[/[ \t\r\n]+/,""],[/\/\*/,"comment","@comment"],[/\/\/.*$/,"comment"],[/#.*$/,"comment"]],comment:[[/[^\/*]+/,"comment"],[/\*\//,"comment","@pop"],[/[\/*]/,"comment"]],string:[[/\$\{/,{token:"delimiter",next:"@stringExpression"}],[/[^\\"\$]+/,"string"],[/@escapes/,"string.escape"],[/\\./,"string.escape.invalid"],[/"/,"string","@popall"]],stringInsideExpression:[[/[^\\"]+/,"string"],[/@escapes/,"string.escape"],[/\\./,"string.escape.invalid"],[/"/,"string","@pop"]],stringExpression:[[/\}/,{token:"delimiter",next:"@pop"}],[/"/,"string","@stringInsideExpression"],{include:"@terraform"}]}}});var q6e={};st(q6e,{conf:()=>rgt,language:()=>sgt});var egt,tgt,igt,ngt,$6e,ogt,Epe,j6e,rgt,sgt,K6e=k(()=>{Ir();egt=Object.defineProperty,tgt=Object.getOwnPropertyDescriptor,igt=Object.getOwnPropertyNames,ngt=Object.prototype.hasOwnProperty,$6e=(n,e,t,i)=>{if(e&&typeof e=="object"||typeof e=="function")for(let o of igt(e))!ngt.call(n,o)&&o!==t&&egt(n,o,{get:()=>e[o],enumerable:!(i=tgt(e,o))||i.enumerable});return n},ogt=(n,e,t)=>($6e(n,e,"default"),t&&$6e(t,e,"default")),Epe={};ogt(Epe,fn);j6e=["area","base","br","col","embed","hr","img","input","keygen","link","menuitem","meta","param","source","track","wbr"],rgt={wordPattern:/(-?\d*\.\d\w*)|([^\`\~\!\@\$\^\&\*\(\)\=\+\[\{\]\}\\\|\;\:\'\"\,\.\<\>\/\s]+)/g,comments:{blockComment:[""]},brackets:[[""],["<",">"],["{","}"],["(",")"]],autoClosingPairs:[{open:"{",close:"}"},{open:"[",close:"]"},{open:"(",close:")"},{open:'"',close:'"'},{open:"'",close:"'"}],surroundingPairs:[{open:'"',close:'"'},{open:"'",close:"'"},{open:"{",close:"}"},{open:"[",close:"]"},{open:"(",close:")"},{open:"<",close:">"}],onEnterRules:[{beforeText:new RegExp(`<(?!(?:${j6e.join("|")}))([_:\\w][_:\\w-.\\d]*)([^/>]*(?!/)>)[^<]*$`,"i"),afterText:/^<\/([_:\w][_:\w-.\d]*)\s*>$/i,action:{indentAction:Epe.languages.IndentAction.IndentOutdent}},{beforeText:new RegExp(`<(?!(?:${j6e.join("|")}))(\\w[\\w\\d]*)([^/>]*(?!/)>)[^<]*$`,"i"),action:{indentAction:Epe.languages.IndentAction.Indent}}],folding:{markers:{start:new RegExp("^\\s*"),end:new RegExp("^\\s*")}}},sgt={defaultToken:"",tokenPostfix:".html",ignoreCase:!0,tokenizer:{root:[[/)/,["delimiter","tag","","delimiter"]],[/(<)(script)/,["delimiter",{token:"tag",next:"@script"}]],[/(<)(style)/,["delimiter",{token:"tag",next:"@style"}]],[/(<)((?:[\w\-]+:)?[\w\-]+)/,["delimiter",{token:"tag",next:"@otherTag"}]],[/(<\/)((?:[\w\-]+:)?[\w\-]+)/,["delimiter",{token:"tag",next:"@otherTag"}]],[/]+/,"metatag.content"],[/>/,"metatag","@pop"]],comment:[[/-->/,"comment","@pop"],[/[^-]+/,"comment.content"],[/./,"comment.content"]],otherTag:[[/\/?>/,"delimiter","@pop"],[/"([^"]*)"/,"attribute.value"],[/'([^']*)'/,"attribute.value"],[/[\w\-]+/,"attribute.name"],[/=/,"delimiter"],[/[ \t\r\n]+/]],script:[[/type/,"attribute.name","@scriptAfterType"],[/"([^"]*)"/,"attribute.value"],[/'([^']*)'/,"attribute.value"],[/[\w\-]+/,"attribute.name"],[/=/,"delimiter"],[/>/,{token:"delimiter",next:"@scriptEmbedded",nextEmbedded:"text/javascript"}],[/[ \t\r\n]+/],[/(<\/)(script\s*)(>)/,["delimiter","tag",{token:"delimiter",next:"@pop"}]]],scriptAfterType:[[/=/,"delimiter","@scriptAfterTypeEquals"],[/>/,{token:"delimiter",next:"@scriptEmbedded",nextEmbedded:"text/javascript"}],[/[ \t\r\n]+/],[/<\/script\s*>/,{token:"@rematch",next:"@pop"}]],scriptAfterTypeEquals:[[/"module"/,{token:"attribute.value",switchTo:"@scriptWithCustomType.text/javascript"}],[/'module'/,{token:"attribute.value",switchTo:"@scriptWithCustomType.text/javascript"}],[/"([^"]*)"/,{token:"attribute.value",switchTo:"@scriptWithCustomType.$1"}],[/'([^']*)'/,{token:"attribute.value",switchTo:"@scriptWithCustomType.$1"}],[/>/,{token:"delimiter",next:"@scriptEmbedded",nextEmbedded:"text/javascript"}],[/[ \t\r\n]+/],[/<\/script\s*>/,{token:"@rematch",next:"@pop"}]],scriptWithCustomType:[[/>/,{token:"delimiter",next:"@scriptEmbedded.$S2",nextEmbedded:"$S2"}],[/"([^"]*)"/,"attribute.value"],[/'([^']*)'/,"attribute.value"],[/[\w\-]+/,"attribute.name"],[/=/,"delimiter"],[/[ \t\r\n]+/],[/<\/script\s*>/,{token:"@rematch",next:"@pop"}]],scriptEmbedded:[[/<\/script/,{token:"@rematch",next:"@pop",nextEmbedded:"@pop"}],[/[^<]+/,""]],style:[[/type/,"attribute.name","@styleAfterType"],[/"([^"]*)"/,"attribute.value"],[/'([^']*)'/,"attribute.value"],[/[\w\-]+/,"attribute.name"],[/=/,"delimiter"],[/>/,{token:"delimiter",next:"@styleEmbedded",nextEmbedded:"text/css"}],[/[ \t\r\n]+/],[/(<\/)(style\s*)(>)/,["delimiter","tag",{token:"delimiter",next:"@pop"}]]],styleAfterType:[[/=/,"delimiter","@styleAfterTypeEquals"],[/>/,{token:"delimiter",next:"@styleEmbedded",nextEmbedded:"text/css"}],[/[ \t\r\n]+/],[/<\/style\s*>/,{token:"@rematch",next:"@pop"}]],styleAfterTypeEquals:[[/"([^"]*)"/,{token:"attribute.value",switchTo:"@styleWithCustomType.$1"}],[/'([^']*)'/,{token:"attribute.value",switchTo:"@styleWithCustomType.$1"}],[/>/,{token:"delimiter",next:"@styleEmbedded",nextEmbedded:"text/css"}],[/[ \t\r\n]+/],[/<\/style\s*>/,{token:"@rematch",next:"@pop"}]],styleWithCustomType:[[/>/,{token:"delimiter",next:"@styleEmbedded.$S2",nextEmbedded:"$S2"}],[/"([^"]*)"/,"attribute.value"],[/'([^']*)'/,"attribute.value"],[/[\w\-]+/,"attribute.name"],[/=/,"delimiter"],[/[ \t\r\n]+/],[/<\/style\s*>/,{token:"@rematch",next:"@pop"}]],styleEmbedded:[[/<\/style/,{token:"@rematch",next:"@pop",nextEmbedded:"@pop"}],[/[^<]+/,""]]}}});var G6e={};st(G6e,{conf:()=>agt,language:()=>lgt});var agt,lgt,Y6e=k(()=>{agt={comments:{lineComment:"#"},brackets:[["{","}"],["[","]"],["(",")"]],autoClosingPairs:[{open:"{",close:"}"},{open:"[",close:"]"},{open:"(",close:")"},{open:'"',close:'"'},{open:"'",close:"'"}],surroundingPairs:[{open:"{",close:"}"},{open:"[",close:"]"},{open:"(",close:")"},{open:'"',close:'"'},{open:"'",close:"'"}]},lgt={defaultToken:"",tokenPostfix:".ini",escapes:/\\(?:[abfnrtv\\"']|x[0-9A-Fa-f]{1,4}|u[0-9A-Fa-f]{4}|U[0-9A-Fa-f]{8})/,tokenizer:{root:[[/^\[[^\]]*\]/,"metatag"],[/(^\w+)(\s*)(\=)/,["key","","delimiter"]],{include:"@whitespace"},[/\d+/,"number"],[/"([^"\\]|\\.)*$/,"string.invalid"],[/'([^'\\]|\\.)*$/,"string.invalid"],[/"/,"string",'@string."'],[/'/,"string","@string.'"]],whitespace:[[/[ \t\r\n]+/,""],[/^\s*[#;].*$/,"comment"]],string:[[/[^\\"']+/,"string"],[/@escapes/,"string.escape"],[/\\./,"string.escape.invalid"],[/["']/,{cases:{"$#==$S2":{token:"string",next:"@pop"},"@default":"string"}}]]}}});var Z6e={};st(Z6e,{conf:()=>cgt,language:()=>dgt});var cgt,dgt,X6e=k(()=>{cgt={wordPattern:/(-?\d*\.\d\w*)|([^\`\~\!\#\%\^\&\*\(\)\-\=\+\[\{\]\}\\\|\;\:\'\"\,\.\<\>\/\?\s]+)/g,comments:{lineComment:"//",blockComment:["/*","*/"]},brackets:[["{","}"],["[","]"],["(",")"]],autoClosingPairs:[{open:"{",close:"}"},{open:"[",close:"]"},{open:"(",close:")"},{open:'"',close:'"'},{open:"'",close:"'"}],surroundingPairs:[{open:"{",close:"}"},{open:"[",close:"]"},{open:"(",close:")"},{open:'"',close:'"'},{open:"'",close:"'"},{open:"<",close:">"}],folding:{markers:{start:new RegExp("^\\s*//\\s*(?:(?:#?region\\b)|(?:))")}}},dgt={defaultToken:"",tokenPostfix:".java",keywords:["abstract","continue","for","new","switch","assert","default","goto","package","synchronized","boolean","do","if","private","this","break","double","implements","protected","throw","byte","else","import","public","throws","case","enum","instanceof","return","transient","catch","extends","int","short","try","char","final","interface","static","void","class","finally","long","strictfp","volatile","const","float","native","super","while","true","false","yield","record","sealed","non-sealed","permits"],operators:["=",">","<","!","~","?",":","==","<=",">=","!=","&&","||","++","--","+","-","*","/","&","|","^","%","<<",">>",">>>","+=","-=","*=","/=","&=","|=","^=","%=","<<=",">>=",">>>="],symbols:/[=>](?!@symbols)/,"@brackets"],[/@symbols/,{cases:{"@operators":"delimiter","@default":""}}],[/@\s*[a-zA-Z_\$][\w\$]*/,"annotation"],[/(@digits)[eE]([\-+]?(@digits))?[fFdD]?/,"number.float"],[/(@digits)\.(@digits)([eE][\-+]?(@digits))?[fFdD]?/,"number.float"],[/0[xX](@hexdigits)[Ll]?/,"number.hex"],[/0(@octaldigits)[Ll]?/,"number.octal"],[/0[bB](@binarydigits)[Ll]?/,"number.binary"],[/(@digits)[fFdD]/,"number.float"],[/(@digits)[lL]?/,"number"],[/[;,.]/,"delimiter"],[/"([^"\\]|\\.)*$/,"string.invalid"],[/"""/,"string","@multistring"],[/"/,"string","@string"],[/'[^\\']'/,"string"],[/(')(@escapes)(')/,["string","string.escape","string"]],[/'/,"string.invalid"]],whitespace:[[/[ \t\r\n]+/,""],[/\/\*\*(?!\/)/,"comment.doc","@javadoc"],[/\/\*/,"comment","@comment"],[/\/\/.*$/,"comment"]],comment:[[/[^\/*]+/,"comment"],[/\*\//,"comment","@pop"],[/[\/*]/,"comment"]],javadoc:[[/[^\/*]+/,"comment.doc"],[/\/\*/,"comment.doc.invalid"],[/\*\//,"comment.doc","@pop"],[/[\/*]/,"comment.doc"]],string:[[/[^\\"]+/,"string"],[/@escapes/,"string.escape"],[/\\./,"string.escape.invalid"],[/"/,"string","@pop"]],multistring:[[/[^\\"]+/,"string"],[/@escapes/,"string.escape"],[/\\./,"string.escape.invalid"],[/"""/,"string","@pop"],[/./,"string"]]}}});var J6e={};st(J6e,{conf:()=>Tpe,language:()=>Wf});var ugt,hgt,fgt,pgt,Q6e,mgt,BP,Tpe,Wf,Dpe=k(()=>{Ir();ugt=Object.defineProperty,hgt=Object.getOwnPropertyDescriptor,fgt=Object.getOwnPropertyNames,pgt=Object.prototype.hasOwnProperty,Q6e=(n,e,t,i)=>{if(e&&typeof e=="object"||typeof e=="function")for(let o of fgt(e))!pgt.call(n,o)&&o!==t&&ugt(n,o,{get:()=>e[o],enumerable:!(i=hgt(e,o))||i.enumerable});return n},mgt=(n,e,t)=>(Q6e(n,e,"default"),t&&Q6e(t,e,"default")),BP={};mgt(BP,fn);Tpe={wordPattern:/(-?\d*\.\d\w*)|([^\`\~\!\@\#\%\^\&\*\(\)\-\=\+\[\{\]\}\\\|\;\:\'\"\,\.\<\>\/\?\s]+)/g,comments:{lineComment:"//",blockComment:["/*","*/"]},brackets:[["{","}"],["[","]"],["(",")"]],onEnterRules:[{beforeText:/^\s*\/\*\*(?!\/)([^\*]|\*(?!\/))*$/,afterText:/^\s*\*\/$/,action:{indentAction:BP.languages.IndentAction.IndentOutdent,appendText:" * "}},{beforeText:/^\s*\/\*\*(?!\/)([^\*]|\*(?!\/))*$/,action:{indentAction:BP.languages.IndentAction.None,appendText:" * "}},{beforeText:/^(\t|(\ \ ))*\ \*(\ ([^\*]|\*(?!\/))*)?$/,action:{indentAction:BP.languages.IndentAction.None,appendText:"* "}},{beforeText:/^(\t|(\ \ ))*\ \*\/\s*$/,action:{indentAction:BP.languages.IndentAction.None,removeText:1}}],autoClosingPairs:[{open:"{",close:"}"},{open:"[",close:"]"},{open:"(",close:")"},{open:'"',close:'"',notIn:["string"]},{open:"'",close:"'",notIn:["string","comment"]},{open:"`",close:"`",notIn:["string","comment"]},{open:"/**",close:" */",notIn:["string"]}],folding:{markers:{start:new RegExp("^\\s*//\\s*#?region\\b"),end:new RegExp("^\\s*//\\s*#?endregion\\b")}}},Wf={defaultToken:"invalid",tokenPostfix:".ts",keywords:["abstract","any","as","asserts","bigint","boolean","break","case","catch","class","continue","const","constructor","debugger","declare","default","delete","do","else","enum","export","extends","false","finally","for","from","function","get","if","implements","import","in","infer","instanceof","interface","is","keyof","let","module","namespace","never","new","null","number","object","out","package","private","protected","public","override","readonly","require","global","return","satisfies","set","static","string","super","switch","symbol","this","throw","true","try","type","typeof","undefined","unique","unknown","var","void","while","with","yield","async","await","of"],operators:["<=",">=","==","!=","===","!==","=>","+","-","**","*","/","%","++","--","<<",">",">>>","&","|","^","!","~","&&","||","??","?",":","=","+=","-=","*=","**=","/=","%=","<<=",">>=",">>>=","&=","|=","^=","@"],symbols:/[=>](?!@symbols)/,"@brackets"],[/!(?=([^=]|$))/,"delimiter"],[/@symbols/,{cases:{"@operators":"delimiter","@default":""}}],[/(@digits)[eE]([\-+]?(@digits))?/,"number.float"],[/(@digits)\.(@digits)([eE][\-+]?(@digits))?/,"number.float"],[/0[xX](@hexdigits)n?/,"number.hex"],[/0[oO]?(@octaldigits)n?/,"number.octal"],[/0[bB](@binarydigits)n?/,"number.binary"],[/(@digits)n?/,"number"],[/[;,.]/,"delimiter"],[/"([^"\\]|\\.)*$/,"string.invalid"],[/'([^'\\]|\\.)*$/,"string.invalid"],[/"/,"string","@string_double"],[/'/,"string","@string_single"],[/`/,"string","@string_backtick"]],whitespace:[[/[ \t\r\n]+/,""],[/\/\*\*(?!\/)/,"comment.doc","@jsdoc"],[/\/\*/,"comment","@comment"],[/\/\/.*$/,"comment"]],comment:[[/[^\/*]+/,"comment"],[/\*\//,"comment","@pop"],[/[\/*]/,"comment"]],jsdoc:[[/[^\/*]+/,"comment.doc"],[/\*\//,"comment.doc","@pop"],[/[\/*]/,"comment.doc"]],regexp:[[/(\{)(\d+(?:,\d*)?)(\})/,["regexp.escape.control","regexp.escape.control","regexp.escape.control"]],[/(\[)(\^?)(?=(?:[^\]\\\/]|\\.)+)/,["regexp.escape.control",{token:"regexp.escape.control",next:"@regexrange"}]],[/(\()(\?:|\?=|\?!)/,["regexp.escape.control","regexp.escape.control"]],[/[()]/,"regexp.escape.control"],[/@regexpctl/,"regexp.escape.control"],[/[^\\\/]/,"regexp"],[/@regexpesc/,"regexp.escape"],[/\\\./,"regexp.invalid"],[/(\/)([dgimsuy]*)/,[{token:"regexp",bracket:"@close",next:"@pop"},"keyword.other"]]],regexrange:[[/-/,"regexp.escape.control"],[/\^/,"regexp.invalid"],[/@regexpesc/,"regexp.escape"],[/[^\]]/,"regexp"],[/\]/,{token:"regexp.escape.control",next:"@pop",bracket:"@close"}]],string_double:[[/[^\\"]+/,"string"],[/@escapes/,"string.escape"],[/\\./,"string.escape.invalid"],[/"/,"string","@pop"]],string_single:[[/[^\\']+/,"string"],[/@escapes/,"string.escape"],[/\\./,"string.escape.invalid"],[/'/,"string","@pop"]],string_backtick:[[/\$\{/,{token:"delimiter.bracket",next:"@bracketCounting"}],[/[^\\`$]+/,"string"],[/@escapes/,"string.escape"],[/\\./,"string.escape.invalid"],[/`/,"string","@pop"]],bracketCounting:[[/\{/,"delimiter.bracket","@bracketCounting"],[/\}/,"delimiter.bracket","@pop"],{include:"common"}]}}});var e9e={};st(e9e,{conf:()=>ggt,language:()=>_gt});var ggt,_gt,t9e=k(()=>{Dpe();ggt=Tpe,_gt={defaultToken:"invalid",tokenPostfix:".js",keywords:["break","case","catch","class","continue","const","constructor","debugger","default","delete","do","else","export","extends","false","finally","for","from","function","get","if","import","in","instanceof","let","new","null","return","set","static","super","switch","symbol","this","throw","true","try","typeof","undefined","var","void","while","with","yield","async","await","of"],typeKeywords:[],operators:Wf.operators,symbols:Wf.symbols,escapes:Wf.escapes,digits:Wf.digits,octaldigits:Wf.octaldigits,binarydigits:Wf.binarydigits,hexdigits:Wf.hexdigits,regexpctl:Wf.regexpctl,regexpesc:Wf.regexpesc,tokenizer:Wf.tokenizer}});var i9e={};st(i9e,{conf:()=>bgt,language:()=>vgt});var bgt,vgt,n9e=k(()=>{bgt={brackets:[["{","}"],["[","]"],["(",")"]],autoClosingPairs:[{open:"{",close:"}"},{open:"[",close:"]"},{open:"(",close:")"},{open:'"',close:'"'},{open:"'",close:"'"}],surroundingPairs:[{open:"{",close:"}"},{open:"[",close:"]"},{open:"(",close:")"},{open:'"',close:'"'},{open:"'",close:"'"}]},vgt={tokenPostfix:".julia",keywords:["begin","while","if","for","try","return","break","continue","function","macro","quote","let","local","global","const","do","struct","module","baremodule","using","import","export","end","else","elseif","catch","finally","mutable","primitive","abstract","type","in","isa","where","new"],types:["LinRange","LineNumberNode","LinearIndices","LoadError","MIME","Matrix","Method","MethodError","Missing","MissingException","Module","NTuple","NamedTuple","Nothing","Number","OrdinalRange","OutOfMemoryError","OverflowError","Pair","PartialQuickSort","PermutedDimsArray","Pipe","Ptr","QuoteNode","Rational","RawFD","ReadOnlyMemoryError","Real","ReentrantLock","Ref","Regex","RegexMatch","RoundingMode","SegmentationFault","Set","Signed","Some","StackOverflowError","StepRange","StepRangeLen","StridedArray","StridedMatrix","StridedVecOrMat","StridedVector","String","StringIndexError","SubArray","SubString","SubstitutionString","Symbol","SystemError","Task","Text","TextDisplay","Timer","Tuple","Type","TypeError","TypeVar","UInt","UInt128","UInt16","UInt32","UInt64","UInt8","UndefInitializer","AbstractArray","UndefKeywordError","AbstractChannel","UndefRefError","AbstractChar","UndefVarError","AbstractDict","Union","AbstractDisplay","UnionAll","AbstractFloat","UnitRange","AbstractIrrational","Unsigned","AbstractMatrix","AbstractRange","Val","AbstractSet","Vararg","AbstractString","VecElement","AbstractUnitRange","VecOrMat","AbstractVecOrMat","Vector","AbstractVector","VersionNumber","Any","WeakKeyDict","ArgumentError","WeakRef","Array","AssertionError","BigFloat","BigInt","BitArray","BitMatrix","BitSet","BitVector","Bool","BoundsError","CapturedException","CartesianIndex","CartesianIndices","Cchar","Cdouble","Cfloat","Channel","Char","Cint","Cintmax_t","Clong","Clonglong","Cmd","Colon","Complex","ComplexF16","ComplexF32","ComplexF64","CompositeException","Condition","Cptrdiff_t","Cshort","Csize_t","Cssize_t","Cstring","Cuchar","Cuint","Cuintmax_t","Culong","Culonglong","Cushort","Cvoid","Cwchar_t","Cwstring","DataType","DenseArray","DenseMatrix","DenseVecOrMat","DenseVector","Dict","DimensionMismatch","Dims","DivideError","DomainError","EOFError","Enum","ErrorException","Exception","ExponentialBackOff","Expr","Float16","Float32","Float64","Function","GlobalRef","HTML","IO","IOBuffer","IOContext","IOStream","IdDict","IndexCartesian","IndexLinear","IndexStyle","InexactError","InitError","Int","Int128","Int16","Int32","Int64","Int8","Integer","InterruptException","InvalidStateException","Irrational","KeyError"],keywordops:["<:",">:",":","=>","...",".","->","?"],allops:/[^\w\d\s()\[\]{}"'#]+/,constants:["true","false","nothing","missing","undef","Inf","pi","NaN","\u03C0","\u212F","ans","PROGRAM_FILE","ARGS","C_NULL","VERSION","DEPOT_PATH","LOAD_PATH"],operators:["!","!=","!==","%","&","*","+","-","/","//","<","<<","<=","==","===","=>",">",">=",">>",">>>","\\","^","|","|>","~","\xF7","\u2208","\u2209","\u220B","\u220C","\u2218","\u221A","\u221B","\u2229","\u222A","\u2248","\u2249","\u2260","\u2261","\u2262","\u2264","\u2265","\u2286","\u2287","\u2288","\u2289","\u228A","\u228B","\u22BB"],brackets:[{open:"(",close:")",token:"delimiter.parenthesis"},{open:"{",close:"}",token:"delimiter.curly"},{open:"[",close:"]",token:"delimiter.square"}],ident:/π|ℯ|\b(?!\d)\w+\b/,escape:/(?:[abefnrstv\\"'\n\r]|[0-7]{1,3}|x[0-9A-Fa-f]{1,2}|u[0-9A-Fa-f]{4})/,escapes:/\\(?:C\-(@escape|.)|c(@escape|.)|@escape)/,tokenizer:{root:[[/(::)\s*|\b(isa)\s+/,"keyword","@typeanno"],[/\b(isa)(\s*\(@ident\s*,\s*)/,["keyword",{token:"",next:"@typeanno"}]],[/\b(type|struct)[ \t]+/,"keyword","@typeanno"],[/^\s*:@ident[!?]?/,"metatag"],[/(return)(\s*:@ident[!?]?)/,["keyword","metatag"]],[/(\(|\[|\{|@allops)(\s*:@ident[!?]?)/,["","metatag"]],[/:\(/,"metatag","@quote"],[/r"""/,"regexp.delim","@tregexp"],[/r"/,"regexp.delim","@sregexp"],[/raw"""/,"string.delim","@rtstring"],[/[bv]?"""/,"string.delim","@dtstring"],[/raw"/,"string.delim","@rsstring"],[/[bv]?"/,"string.delim","@dsstring"],[/(@ident)\{/,{cases:{"$1@types":{token:"type",next:"@gen"},"@default":{token:"type",next:"@gen"}}}],[/@ident[!?'']?(?=\.?\()/,{cases:{"@types":"type","@keywords":"keyword","@constants":"variable","@default":"keyword.flow"}}],[/@ident[!?']?/,{cases:{"@types":"type","@keywords":"keyword","@constants":"variable","@default":"identifier"}}],[/\$\w+/,"key"],[/\$\(/,"key","@paste"],[/@@@ident/,"annotation"],{include:"@whitespace"},[/'(?:@escapes|.)'/,"string.character"],[/[()\[\]{}]/,"@brackets"],[/@allops/,{cases:{"@keywordops":"keyword","@operators":"operator"}}],[/[;,]/,"delimiter"],[/0[xX][0-9a-fA-F](_?[0-9a-fA-F])*/,"number.hex"],[/0[_oO][0-7](_?[0-7])*/,"number.octal"],[/0[bB][01](_?[01])*/,"number.binary"],[/[+\-]?\d+(\.\d+)?(im?|[eE][+\-]?\d+(\.\d+)?)?/,"number"]],typeanno:[[/[a-zA-Z_]\w*(?:\.[a-zA-Z_]\w*)*\{/,"type","@gen"],[/([a-zA-Z_]\w*(?:\.[a-zA-Z_]\w*)*)(\s*<:\s*)/,["type","keyword"]],[/[a-zA-Z_]\w*(?:\.[a-zA-Z_]\w*)*/,"type","@pop"],["","","@pop"]],gen:[[/[a-zA-Z_]\w*(?:\.[a-zA-Z_]\w*)*\{/,"type","@push"],[/[a-zA-Z_]\w*(?:\.[a-zA-Z_]\w*)*/,"type"],[/<:/,"keyword"],[/(\})(\s*<:\s*)/,["type",{token:"keyword",next:"@pop"}]],[/\}/,"type","@pop"],{include:"@root"}],quote:[[/\$\(/,"key","@paste"],[/\(/,"@brackets","@paren"],[/\)/,"metatag","@pop"],{include:"@root"}],paste:[[/:\(/,"metatag","@quote"],[/\(/,"@brackets","@paren"],[/\)/,"key","@pop"],{include:"@root"}],paren:[[/\$\(/,"key","@paste"],[/:\(/,"metatag","@quote"],[/\(/,"@brackets","@push"],[/\)/,"@brackets","@pop"],{include:"@root"}],sregexp:[[/^.*/,"invalid"],[/[^\\"()\[\]{}]/,"regexp"],[/[()\[\]{}]/,"@brackets"],[/\\./,"operator.scss"],[/"[imsx]*/,"regexp.delim","@pop"]],tregexp:[[/[^\\"()\[\]{}]/,"regexp"],[/[()\[\]{}]/,"@brackets"],[/\\./,"operator.scss"],[/"(?!"")/,"string"],[/"""[imsx]*/,"regexp.delim","@pop"]],rsstring:[[/^.*/,"invalid"],[/[^\\"]/,"string"],[/\\./,"string.escape"],[/"/,"string.delim","@pop"]],rtstring:[[/[^\\"]/,"string"],[/\\./,"string.escape"],[/"(?!"")/,"string"],[/"""/,"string.delim","@pop"]],dsstring:[[/^.*/,"invalid"],[/[^\\"\$]/,"string"],[/\$/,"","@interpolated"],[/@escapes/,"string.escape"],[/\\./,"string.escape.invalid"],[/"/,"string.delim","@pop"]],dtstring:[[/[^\\"\$]/,"string"],[/\$/,"","@interpolated"],[/@escapes/,"string.escape"],[/\\./,"string.escape.invalid"],[/"(?!"")/,"string"],[/"""/,"string.delim","@pop"]],interpolated:[[/\(/,{token:"",switchTo:"@interpolated_compound"}],[/[a-zA-Z_]\w*/,"identifier"],["","","@pop"]],interpolated_compound:[[/\)/,"","@pop"],{include:"@root"}],whitespace:[[/[ \t\r\n]+/,""],[/#=/,"comment","@multi_comment"],[/#.*$/,"comment"]],multi_comment:[[/#=/,"comment","@push"],[/=#/,"comment","@pop"],[/=(?!#)|#(?!=)/,"comment"],[/[^#=]+/,"comment"]]}}});var o9e={};st(o9e,{conf:()=>xgt,language:()=>wgt});var xgt,wgt,r9e=k(()=>{xgt={wordPattern:/(-?\d*\.\d\w*)|([^\`\~\!\#\%\^\&\*\(\)\-\=\+\[\{\]\}\\\|\;\:\'\"\,\.\<\>\/\?\s]+)/g,comments:{lineComment:"//",blockComment:["/*","*/"]},brackets:[["{","}"],["[","]"],["(",")"]],autoClosingPairs:[{open:"{",close:"}"},{open:"[",close:"]"},{open:"(",close:")"},{open:'"',close:'"'},{open:"'",close:"'"}],surroundingPairs:[{open:"{",close:"}"},{open:"[",close:"]"},{open:"(",close:")"},{open:'"',close:'"'},{open:"'",close:"'"},{open:"<",close:">"}],folding:{markers:{start:new RegExp("^\\s*//\\s*(?:(?:#?region\\b)|(?:))")}}},wgt={defaultToken:"",tokenPostfix:".kt",keywords:["as","as?","break","class","continue","do","else","false","for","fun","if","in","!in","interface","is","!is","null","object","package","return","super","this","throw","true","try","typealias","val","var","when","while","by","catch","constructor","delegate","dynamic","field","file","finally","get","import","init","param","property","receiver","set","setparam","where","actual","abstract","annotation","companion","const","crossinline","data","enum","expect","external","final","infix","inline","inner","internal","lateinit","noinline","open","operator","out","override","private","protected","public","reified","sealed","suspend","tailrec","vararg","field","it"],operators:["+","-","*","/","%","=","+=","-=","*=","/=","%=","++","--","&&","||","!","==","!=","===","!==",">","<","<=",">=","[","]","!!","?.","?:","::","..",":","?","->","@",";","$","_"],symbols:/[=>](?!@symbols)/,"@brackets"],[/@symbols/,{cases:{"@operators":"delimiter","@default":""}}],[/@\s*[a-zA-Z_\$][\w\$]*/,"annotation"],[/(@digits)[eE]([\-+]?(@digits))?[fFdD]?/,"number.float"],[/(@digits)\.(@digits)([eE][\-+]?(@digits))?[fFdD]?/,"number.float"],[/0[xX](@hexdigits)[Ll]?/,"number.hex"],[/0(@octaldigits)[Ll]?/,"number.octal"],[/0[bB](@binarydigits)[Ll]?/,"number.binary"],[/(@digits)[fFdD]/,"number.float"],[/(@digits)[lL]?/,"number"],[/[;,.]/,"delimiter"],[/"([^"\\]|\\.)*$/,"string.invalid"],[/"""/,"string","@multistring"],[/"/,"string","@string"],[/'[^\\']'/,"string"],[/(')(@escapes)(')/,["string","string.escape","string"]],[/'/,"string.invalid"]],whitespace:[[/[ \t\r\n]+/,""],[/\/\*\*(?!\/)/,"comment.doc","@javadoc"],[/\/\*/,"comment","@comment"],[/\/\/.*$/,"comment"]],comment:[[/[^\/*]+/,"comment"],[/\/\*/,"comment","@comment"],[/\*\//,"comment","@pop"],[/[\/*]/,"comment"]],javadoc:[[/[^\/*]+/,"comment.doc"],[/\/\*/,"comment.doc","@push"],[/\/\*/,"comment.doc.invalid"],[/\*\//,"comment.doc","@pop"],[/[\/*]/,"comment.doc"]],string:[[/[^\\"]+/,"string"],[/@escapes/,"string.escape"],[/\\./,"string.escape.invalid"],[/"/,"string","@pop"]],multistring:[[/[^\\"]+/,"string"],[/@escapes/,"string.escape"],[/\\./,"string.escape.invalid"],[/"""/,"string","@pop"],[/./,"string"]]}}});var s9e={};st(s9e,{conf:()=>ygt,language:()=>Cgt});var ygt,Cgt,a9e=k(()=>{ygt={wordPattern:/(#?-?\d*\.\d\w*%?)|([@#!.:]?[\w-?]+%?)|[@#!.]/g,comments:{blockComment:["/*","*/"],lineComment:"//"},brackets:[["{","}"],["[","]"],["(",")"]],autoClosingPairs:[{open:"{",close:"}",notIn:["string","comment"]},{open:"[",close:"]",notIn:["string","comment"]},{open:"(",close:")",notIn:["string","comment"]},{open:'"',close:'"',notIn:["string","comment"]},{open:"'",close:"'",notIn:["string","comment"]}],surroundingPairs:[{open:"{",close:"}"},{open:"[",close:"]"},{open:"(",close:")"},{open:'"',close:'"'},{open:"'",close:"'"}],folding:{markers:{start:new RegExp("^\\s*\\/\\*\\s*#region\\b\\s*(.*?)\\s*\\*\\/"),end:new RegExp("^\\s*\\/\\*\\s*#endregion\\b.*\\*\\/")}}},Cgt={defaultToken:"",tokenPostfix:".less",identifier:"-?-?([a-zA-Z]|(\\\\(([0-9a-fA-F]{1,6}\\s?)|[^[0-9a-fA-F])))([\\w\\-]|(\\\\(([0-9a-fA-F]{1,6}\\s?)|[^[0-9a-fA-F])))*",identifierPlus:"-?-?([a-zA-Z:.]|(\\\\(([0-9a-fA-F]{1,6}\\s?)|[^[0-9a-fA-F])))([\\w\\-:.]|(\\\\(([0-9a-fA-F]{1,6}\\s?)|[^[0-9a-fA-F])))*",brackets:[{open:"{",close:"}",token:"delimiter.curly"},{open:"[",close:"]",token:"delimiter.bracket"},{open:"(",close:")",token:"delimiter.parenthesis"},{open:"<",close:">",token:"delimiter.angle"}],tokenizer:{root:[{include:"@nestedJSBegin"},["[ \\t\\r\\n]+",""],{include:"@comments"},{include:"@keyword"},{include:"@strings"},{include:"@numbers"},["[*_]?[a-zA-Z\\-\\s]+(?=:.*(;|(\\\\$)))","attribute.name","@attribute"],["url(\\-prefix)?\\(",{token:"tag",next:"@urldeclaration"}],["[{}()\\[\\]]","@brackets"],["[,:;]","delimiter"],["#@identifierPlus","tag.id"],["&","tag"],["\\.@identifierPlus(?=\\()","tag.class","@attribute"],["\\.@identifierPlus","tag.class"],["@identifierPlus","tag"],{include:"@operators"},["@(@identifier(?=[:,\\)]))","variable","@attribute"],["@(@identifier)","variable"],["@","key","@atRules"]],nestedJSBegin:[["``","delimiter.backtick"],["`",{token:"delimiter.backtick",next:"@nestedJSEnd",nextEmbedded:"text/javascript"}]],nestedJSEnd:[["`",{token:"delimiter.backtick",next:"@pop",nextEmbedded:"@pop"}]],operators:[["[<>=\\+\\-\\*\\/\\^\\|\\~]","operator"]],keyword:[["(@[\\s]*import|![\\s]*important|true|false|when|iscolor|isnumber|isstring|iskeyword|isurl|ispixel|ispercentage|isem|hue|saturation|lightness|alpha|lighten|darken|saturate|desaturate|fadein|fadeout|fade|spin|mix|round|ceil|floor|percentage)\\b","keyword"]],urldeclaration:[{include:"@strings"},[`[^)\r ]+`,"string"],["\\)",{token:"tag",next:"@pop"}]],attribute:[{include:"@nestedJSBegin"},{include:"@comments"},{include:"@strings"},{include:"@numbers"},{include:"@keyword"},["[a-zA-Z\\-]+(?=\\()","attribute.value","@attribute"],[">","operator","@pop"],["@identifier","attribute.value"],{include:"@operators"},["@(@identifier)","variable"],["[)\\}]","@brackets","@pop"],["[{}()\\[\\]>]","@brackets"],["[;]","delimiter","@pop"],["[,=:]","delimiter"],["\\s",""],[".","attribute.value"]],comments:[["\\/\\*","comment","@comment"],["\\/\\/+.*","comment"]],comment:[["\\*\\/","comment","@pop"],[".","comment"]],numbers:[["(\\d*\\.)?\\d+([eE][\\-+]?\\d+)?",{token:"attribute.value.number",next:"@units"}],["#[0-9a-fA-F_]+(?!\\w)","attribute.value.hex"]],units:[["(em|ex|ch|rem|fr|vmin|vmax|vw|vh|vm|cm|mm|in|px|pt|pc|deg|grad|rad|turn|s|ms|Hz|kHz|%)?","attribute.value.unit","@pop"]],strings:[['~?"',{token:"string.delimiter",next:"@stringsEndDoubleQuote"}],["~?'",{token:"string.delimiter",next:"@stringsEndQuote"}]],stringsEndDoubleQuote:[['\\\\"',"string"],['"',{token:"string.delimiter",next:"@popall"}],[".","string"]],stringsEndQuote:[["\\\\'","string"],["'",{token:"string.delimiter",next:"@popall"}],[".","string"]],atRules:[{include:"@comments"},{include:"@strings"},["[()]","delimiter"],["[\\{;]","delimiter","@pop"],[".","key"]]}}});var l9e={};st(l9e,{conf:()=>Sgt,language:()=>kgt});var Sgt,kgt,c9e=k(()=>{Sgt={comments:{lineComment:"COMMENT"},brackets:[["(",")"]],autoClosingPairs:[{open:"{",close:"}"},{open:"[",close:"]"},{open:"(",close:")"},{open:'"',close:'"'},{open:":",close:"."}],surroundingPairs:[{open:"{",close:"}"},{open:"[",close:"]"},{open:"(",close:")"},{open:"`",close:"`"},{open:'"',close:'"'},{open:"'",close:"'"},{open:":",close:"."}],folding:{markers:{start:new RegExp("^\\s*(::\\s*|COMMENT\\s+)#region"),end:new RegExp("^\\s*(::\\s*|COMMENT\\s+)#endregion")}}},kgt={tokenPostfix:".lexon",ignoreCase:!0,keywords:["lexon","lex","clause","terms","contracts","may","pay","pays","appoints","into","to"],typeKeywords:["amount","person","key","time","date","asset","text"],operators:["less","greater","equal","le","gt","or","and","add","added","subtract","subtracted","multiply","multiplied","times","divide","divided","is","be","certified"],symbols:/[=>](?!@symbols)/,"@brackets"],[/@symbols/,"delimiter"],[/\d*\.\d*\.\d*/,"number.semver"],[/\d*\.\d+([eE][\-+]?\d+)?/,"number.float"],[/0[xX][0-9a-fA-F]+/,"number.hex"],[/\d+/,"number"],[/[;,.]/,"delimiter"]],quoted_identifier:[[/[^\\"]+/,"identifier"],[/"/,{token:"identifier.quote",bracket:"@close",next:"@pop"}]],space_identifier_until_period:[[":","delimiter"],[" ",{token:"white",next:"@identifier_rest"}]],identifier_until_period:[{include:"@whitespace"},[":",{token:"delimiter",next:"@identifier_rest"}],[/[^\\.]+/,"identifier"],[/\./,{token:"delimiter",bracket:"@close",next:"@pop"}]],identifier_rest:[[/[^\\.]+/,"identifier"],[/\./,{token:"delimiter",bracket:"@close",next:"@pop"}]],semver:[{include:"@whitespace"},[":","delimiter"],[/\d*\.\d*\.\d*/,{token:"number.semver",bracket:"@close",next:"@pop"}]],whitespace:[[/[ \t\r\n]+/,"white"]]}}});var d9e={};st(d9e,{conf:()=>Lgt,language:()=>Igt});var Lgt,Igt,u9e=k(()=>{Lgt={comments:{lineComment:"--",blockComment:["--[[","]]"]},brackets:[["{","}"],["[","]"],["(",")"]],autoClosingPairs:[{open:"{",close:"}"},{open:"[",close:"]"},{open:"(",close:")"},{open:'"',close:'"'},{open:"'",close:"'"}],surroundingPairs:[{open:"{",close:"}"},{open:"[",close:"]"},{open:"(",close:")"},{open:'"',close:'"'},{open:"'",close:"'"}]},Igt={defaultToken:"",tokenPostfix:".lua",keywords:["and","break","do","else","elseif","end","false","for","function","goto","if","in","local","nil","not","or","repeat","return","then","true","until","while"],brackets:[{token:"delimiter.bracket",open:"{",close:"}"},{token:"delimiter.array",open:"[",close:"]"},{token:"delimiter.parenthesis",open:"(",close:")"}],operators:["+","-","*","/","%","^","#","==","~=","<=",">=","<",">","=",";",":",",",".","..","..."],symbols:/[=>Agt,language:()=>Mgt});var Egt,Tgt,Dgt,Ngt,h9e,Rgt,Npe,f9e,Agt,Mgt,m9e=k(()=>{Ir();Egt=Object.defineProperty,Tgt=Object.getOwnPropertyDescriptor,Dgt=Object.getOwnPropertyNames,Ngt=Object.prototype.hasOwnProperty,h9e=(n,e,t,i)=>{if(e&&typeof e=="object"||typeof e=="function")for(let o of Dgt(e))!Ngt.call(n,o)&&o!==t&&Egt(n,o,{get:()=>e[o],enumerable:!(i=Tgt(e,o))||i.enumerable});return n},Rgt=(n,e,t)=>(h9e(n,e,"default"),t&&h9e(t,e,"default")),Npe={};Rgt(Npe,fn);f9e=["area","base","br","col","embed","hr","img","input","keygen","link","menuitem","meta","param","source","track","wbr"],Agt={wordPattern:/(-?\d*\.\d\w*)|([^\`\~\!\@\$\^\&\*\(\)\=\+\[\{\]\}\\\|\;\:\'\"\,\.\<\>\/\s]+)/g,brackets:[[""],["<",">"],["{{","}}"],["{%","%}"],["{","}"],["(",")"]],autoClosingPairs:[{open:"{",close:"}"},{open:"%",close:"%"},{open:"[",close:"]"},{open:"(",close:")"},{open:'"',close:'"'},{open:"'",close:"'"}],surroundingPairs:[{open:"<",close:">"},{open:'"',close:'"'},{open:"'",close:"'"}],onEnterRules:[{beforeText:new RegExp(`<(?!(?:${f9e.join("|")}))(\\w[\\w\\d]*)([^/>]*(?!/)>)[^<]*$`,"i"),afterText:/^<\/(\w[\w\d]*)\s*>$/i,action:{indentAction:Npe.languages.IndentAction.IndentOutdent}},{beforeText:new RegExp(`<(?!(?:${f9e.join("|")}))(\\w[\\w\\d]*)([^/>]*(?!/)>)[^<]*$`,"i"),action:{indentAction:Npe.languages.IndentAction.Indent}}]},Mgt={defaultToken:"",tokenPostfix:"",builtinTags:["if","else","elseif","endif","render","assign","capture","endcapture","case","endcase","comment","endcomment","cycle","decrement","for","endfor","include","increment","layout","raw","endraw","render","tablerow","endtablerow","unless","endunless"],builtinFilters:["abs","append","at_least","at_most","capitalize","ceil","compact","date","default","divided_by","downcase","escape","escape_once","first","floor","join","json","last","lstrip","map","minus","modulo","newline_to_br","plus","prepend","remove","remove_first","replace","replace_first","reverse","round","rstrip","size","slice","sort","sort_natural","split","strip","strip_html","strip_newlines","times","truncate","truncatewords","uniq","upcase","url_decode","url_encode","where"],constants:["true","false"],operators:["==","!=",">","<",">=","<="],symbol:/[=>)/,["delimiter.html","tag.html","delimiter.html"]],[/(<)([:\w]+)/,["delimiter.html",{token:"tag.html",next:"@otherTag"}]],[/(<\/)([\w\-]+)/,["delimiter.html",{token:"tag.html",next:"@otherTag"}]],[//,"delimiter.html","@pop"],[/"([^"]*)"/,"attribute.value"],[/'([^']*)'/,"attribute.value"],[/[\w\-]+/,"attribute.name"],[/=/,"delimiter"],[/[ \t\r\n]+/]],liquidState:[[/\{\{/,"delimiter.output.liquid"],[/\}\}/,{token:"delimiter.output.liquid",switchTo:"@$S2.$S3"}],[/\{\%/,"delimiter.tag.liquid"],[/raw\s*\%\}/,"delimiter.tag.liquid","@liquidRaw"],[/\%\}/,{token:"delimiter.tag.liquid",switchTo:"@$S2.$S3"}],{include:"liquidRoot"}],liquidRaw:[[/^(?!\{\%\s*endraw\s*\%\}).+/],[/\{\%/,"delimiter.tag.liquid"],[/@identifier/],[/\%\}/,{token:"delimiter.tag.liquid",next:"@root"}]],liquidRoot:[[/\d+(\.\d+)?/,"number.liquid"],[/"[^"]*"/,"string.liquid"],[/'[^']*'/,"string.liquid"],[/\s+/],[/@symbol/,{cases:{"@operators":"operator.liquid","@default":""}}],[/\./],[/@identifier/,{cases:{"@constants":"keyword.liquid","@builtinFilters":"predefined.liquid","@builtinTags":"predefined.liquid","@default":"variable.liquid"}}],[/[^}|%]/,"variable.liquid"]]}}});var g9e={};st(g9e,{conf:()=>Pgt,language:()=>Ogt});var Pgt,Ogt,_9e=k(()=>{Pgt={comments:{blockComment:["(*","*)"]},brackets:[["{","}"],["[","]"],["(",")"]],autoClosingPairs:[{open:"[",close:"]"},{open:"{",close:"}"},{open:"(",close:")"},{open:"(*",close:"*)"},{open:"<*",close:"*>"},{open:"'",close:"'",notIn:["string","comment"]},{open:'"',close:'"',notIn:["string","comment"]}]},Ogt={defaultToken:"",tokenPostfix:".m3",brackets:[{token:"delimiter.curly",open:"{",close:"}"},{token:"delimiter.parenthesis",open:"(",close:")"},{token:"delimiter.square",open:"[",close:"]"}],keywords:["AND","ANY","ARRAY","AS","BEGIN","BITS","BRANDED","BY","CASE","CONST","DIV","DO","ELSE","ELSIF","END","EVAL","EXCEPT","EXCEPTION","EXIT","EXPORTS","FINALLY","FOR","FROM","GENERIC","IF","IMPORT","IN","INTERFACE","LOCK","LOOP","METHODS","MOD","MODULE","NOT","OBJECT","OF","OR","OVERRIDES","PROCEDURE","RAISE","RAISES","READONLY","RECORD","REF","REPEAT","RETURN","REVEAL","SET","THEN","TO","TRY","TYPE","TYPECASE","UNSAFE","UNTIL","UNTRACED","VALUE","VAR","WHILE","WITH"],reservedConstNames:["ABS","ADR","ADRSIZE","BITSIZE","BYTESIZE","CEILING","DEC","DISPOSE","FALSE","FIRST","FLOAT","FLOOR","INC","ISTYPE","LAST","LOOPHOLE","MAX","MIN","NARROW","NEW","NIL","NUMBER","ORD","ROUND","SUBARRAY","TRUE","TRUNC","TYPECODE","VAL"],reservedTypeNames:["ADDRESS","ANY","BOOLEAN","CARDINAL","CHAR","EXTENDED","INTEGER","LONGCARD","LONGINT","LONGREAL","MUTEX","NULL","REAL","REFANY","ROOT","TEXT"],operators:["+","-","*","/","&","^","."],relations:["=","#","<","<=",">",">=","<:",":"],delimiters:["|","..","=>",",",";",":="],symbols:/[>=<#.,:;+\-*/&^]+/,escapes:/\\(?:[\\fnrt"']|[0-7]{3})/,tokenizer:{root:[[/_\w*/,"invalid"],[/[a-zA-Z][a-zA-Z0-9_]*/,{cases:{"@keywords":{token:"keyword.$0"},"@reservedConstNames":{token:"constant.reserved.$0"},"@reservedTypeNames":{token:"type.reserved.$0"},"@default":"identifier"}}],{include:"@whitespace"},[/[{}()\[\]]/,"@brackets"],[/[0-9]+\.[0-9]+(?:[DdEeXx][\+\-]?[0-9]+)?/,"number.float"],[/[0-9]+(?:\_[0-9a-fA-F]+)?L?/,"number"],[/@symbols/,{cases:{"@operators":"operators","@relations":"operators","@delimiters":"delimiter","@default":"invalid"}}],[/'[^\\']'/,"string.char"],[/(')(@escapes)(')/,["string.char","string.escape","string.char"]],[/'/,"invalid"],[/"([^"\\]|\\.)*$/,"invalid"],[/"/,"string.text","@text"]],text:[[/[^\\"]+/,"string.text"],[/@escapes/,"string.escape"],[/\\./,"invalid"],[/"/,"string.text","@pop"]],comment:[[/\(\*/,"comment","@push"],[/\*\)/,"comment","@pop"],[/./,"comment"]],pragma:[[/<\*/,"keyword.pragma","@push"],[/\*>/,"keyword.pragma","@pop"],[/./,"keyword.pragma"]],whitespace:[[/[ \t\r\n]+/,"white"],[/\(\*/,"comment","@comment"],[/<\*/,"keyword.pragma","@pragma"]]}}});var b9e={};st(b9e,{conf:()=>Fgt,language:()=>Bgt});var Fgt,Bgt,v9e=k(()=>{Fgt={comments:{blockComment:[""]},brackets:[["{","}"],["[","]"],["(",")"]],autoClosingPairs:[{open:"{",close:"}"},{open:"[",close:"]"},{open:"(",close:")"},{open:"<",close:">",notIn:["string"]}],surroundingPairs:[{open:"(",close:")"},{open:"[",close:"]"},{open:"`",close:"`"}],folding:{markers:{start:new RegExp("^\\s*"),end:new RegExp("^\\s*")}}},Bgt={defaultToken:"",tokenPostfix:".md",control:/[\\`*_\[\]{}()#+\-\.!]/,noncontrol:/[^\\`*_\[\]{}()#+\-\.!]/,escapes:/\\(?:@control)/,jsescapes:/\\(?:[btnfr\\"']|[0-7][0-7]?|[0-3][0-7]{2})/,empty:["area","base","basefont","br","col","frame","hr","img","input","isindex","link","meta","param"],tokenizer:{root:[[/^\s*\|/,"@rematch","@table_header"],[/^(\s{0,3})(#+)((?:[^\\#]|@escapes)+)((?:#+)?)/,["white","keyword","keyword","keyword"]],[/^\s*(=+|\-+)\s*$/,"keyword"],[/^\s*((\*[ ]?)+)\s*$/,"meta.separator"],[/^\s*>+/,"comment"],[/^\s*([\*\-+:]|\d+\.)\s/,"keyword"],[/^(\t|[ ]{4})[^ ].*$/,"string"],[/^\s*~~~\s*((?:\w|[\/\-#])+)?\s*$/,{token:"string",next:"@codeblock"}],[/^\s*```\s*((?:\w|[\/\-#])+).*$/,{token:"string",next:"@codeblockgh",nextEmbedded:"$1"}],[/^\s*```\s*$/,{token:"string",next:"@codeblock"}],{include:"@linecontent"}],table_header:[{include:"@table_common"},[/[^\|]+/,"keyword.table.header"]],table_body:[{include:"@table_common"},{include:"@linecontent"}],table_common:[[/\s*[\-:]+\s*/,{token:"keyword",switchTo:"table_body"}],[/^\s*\|/,"keyword.table.left"],[/^\s*[^\|]/,"@rematch","@pop"],[/^\s*$/,"@rematch","@pop"],[/\|/,{cases:{"@eos":"keyword.table.right","@default":"keyword.table.middle"}}]],codeblock:[[/^\s*~~~\s*$/,{token:"string",next:"@pop"}],[/^\s*```\s*$/,{token:"string",next:"@pop"}],[/.*$/,"variable.source"]],codeblockgh:[[/```\s*$/,{token:"string",next:"@pop",nextEmbedded:"@pop"}],[/[^`]+/,"variable.source"]],linecontent:[[/&\w+;/,"string.escape"],[/@escapes/,"escape"],[/\b__([^\\_]|@escapes|_(?!_))+__\b/,"strong"],[/\*\*([^\\*]|@escapes|\*(?!\*))+\*\*/,"strong"],[/\b_[^_]+_\b/,"emphasis"],[/\*([^\\*]|@escapes)+\*/,"emphasis"],[/`([^\\`]|@escapes)+`/,"variable"],[/\{+[^}]+\}+/,"string.target"],[/(!?\[)((?:[^\]\\]|@escapes)*)(\]\([^\)]+\))/,["string.link","","string.link"]],[/(!?\[)((?:[^\]\\]|@escapes)*)(\])/,"string.link"],{include:"html"}],html:[[/<(\w+)\/>/,"tag"],[/<(\w+)(\-|\w)*/,{cases:{"@empty":{token:"tag",next:"@tag.$1"},"@default":{token:"tag",next:"@tag.$1"}}}],[/<\/(\w+)(\-|\w)*\s*>/,{token:"tag"}],[//,"comment","@pop"],[//,"comment.html","@pop"],[/[^-]+/,"comment.content.html"],[/./,"comment.content.html"]],otherTag:[[/<\?((php)|=)?/,{token:"@rematch",switchTo:"@phpInSimpleState.otherTag"}],[/\/?>/,"delimiter.html","@pop"],[/"([^"]*)"/,"attribute.value"],[/'([^']*)'/,"attribute.value"],[/[\w\-]+/,"attribute.name"],[/=/,"delimiter"],[/[ \t\r\n]+/]],script:[[/<\?((php)|=)?/,{token:"@rematch",switchTo:"@phpInSimpleState.script"}],[/type/,"attribute.name","@scriptAfterType"],[/"([^"]*)"/,"attribute.value"],[/'([^']*)'/,"attribute.value"],[/[\w\-]+/,"attribute.name"],[/=/,"delimiter"],[/>/,{token:"delimiter.html",next:"@scriptEmbedded.text/javascript",nextEmbedded:"text/javascript"}],[/[ \t\r\n]+/],[/(<\/)(script\s*)(>)/,["delimiter.html","tag.html",{token:"delimiter.html",next:"@pop"}]]],scriptAfterType:[[/<\?((php)|=)?/,{token:"@rematch",switchTo:"@phpInSimpleState.scriptAfterType"}],[/=/,"delimiter","@scriptAfterTypeEquals"],[/>/,{token:"delimiter.html",next:"@scriptEmbedded.text/javascript",nextEmbedded:"text/javascript"}],[/[ \t\r\n]+/],[/<\/script\s*>/,{token:"@rematch",next:"@pop"}]],scriptAfterTypeEquals:[[/<\?((php)|=)?/,{token:"@rematch",switchTo:"@phpInSimpleState.scriptAfterTypeEquals"}],[/"([^"]*)"/,{token:"attribute.value",switchTo:"@scriptWithCustomType.$1"}],[/'([^']*)'/,{token:"attribute.value",switchTo:"@scriptWithCustomType.$1"}],[/>/,{token:"delimiter.html",next:"@scriptEmbedded.text/javascript",nextEmbedded:"text/javascript"}],[/[ \t\r\n]+/],[/<\/script\s*>/,{token:"@rematch",next:"@pop"}]],scriptWithCustomType:[[/<\?((php)|=)?/,{token:"@rematch",switchTo:"@phpInSimpleState.scriptWithCustomType.$S2"}],[/>/,{token:"delimiter.html",next:"@scriptEmbedded.$S2",nextEmbedded:"$S2"}],[/"([^"]*)"/,"attribute.value"],[/'([^']*)'/,"attribute.value"],[/[\w\-]+/,"attribute.name"],[/=/,"delimiter"],[/[ \t\r\n]+/],[/<\/script\s*>/,{token:"@rematch",next:"@pop"}]],scriptEmbedded:[[/<\?((php)|=)?/,{token:"@rematch",switchTo:"@phpInEmbeddedState.scriptEmbedded.$S2",nextEmbedded:"@pop"}],[/<\/script/,{token:"@rematch",next:"@pop",nextEmbedded:"@pop"}]],style:[[/<\?((php)|=)?/,{token:"@rematch",switchTo:"@phpInSimpleState.style"}],[/type/,"attribute.name","@styleAfterType"],[/"([^"]*)"/,"attribute.value"],[/'([^']*)'/,"attribute.value"],[/[\w\-]+/,"attribute.name"],[/=/,"delimiter"],[/>/,{token:"delimiter.html",next:"@styleEmbedded.text/css",nextEmbedded:"text/css"}],[/[ \t\r\n]+/],[/(<\/)(style\s*)(>)/,["delimiter.html","tag.html",{token:"delimiter.html",next:"@pop"}]]],styleAfterType:[[/<\?((php)|=)?/,{token:"@rematch",switchTo:"@phpInSimpleState.styleAfterType"}],[/=/,"delimiter","@styleAfterTypeEquals"],[/>/,{token:"delimiter.html",next:"@styleEmbedded.text/css",nextEmbedded:"text/css"}],[/[ \t\r\n]+/],[/<\/style\s*>/,{token:"@rematch",next:"@pop"}]],styleAfterTypeEquals:[[/<\?((php)|=)?/,{token:"@rematch",switchTo:"@phpInSimpleState.styleAfterTypeEquals"}],[/"([^"]*)"/,{token:"attribute.value",switchTo:"@styleWithCustomType.$1"}],[/'([^']*)'/,{token:"attribute.value",switchTo:"@styleWithCustomType.$1"}],[/>/,{token:"delimiter.html",next:"@styleEmbedded.text/css",nextEmbedded:"text/css"}],[/[ \t\r\n]+/],[/<\/style\s*>/,{token:"@rematch",next:"@pop"}]],styleWithCustomType:[[/<\?((php)|=)?/,{token:"@rematch",switchTo:"@phpInSimpleState.styleWithCustomType.$S2"}],[/>/,{token:"delimiter.html",next:"@styleEmbedded.$S2",nextEmbedded:"$S2"}],[/"([^"]*)"/,"attribute.value"],[/'([^']*)'/,"attribute.value"],[/[\w\-]+/,"attribute.name"],[/=/,"delimiter"],[/[ \t\r\n]+/],[/<\/style\s*>/,{token:"@rematch",next:"@pop"}]],styleEmbedded:[[/<\?((php)|=)?/,{token:"@rematch",switchTo:"@phpInEmbeddedState.styleEmbedded.$S2",nextEmbedded:"@pop"}],[/<\/style/,{token:"@rematch",next:"@pop",nextEmbedded:"@pop"}]],phpInSimpleState:[[/<\?((php)|=)?/,"metatag.php"],[/\?>/,{token:"metatag.php",switchTo:"@$S2.$S3"}],{include:"phpRoot"}],phpInEmbeddedState:[[/<\?((php)|=)?/,"metatag.php"],[/\?>/,{token:"metatag.php",switchTo:"@$S2.$S3",nextEmbedded:"$S3"}],{include:"phpRoot"}],phpRoot:[[/[a-zA-Z_]\w*/,{cases:{"@phpKeywords":{token:"keyword.php"},"@phpCompileTimeConstants":{token:"constant.php"},"@default":"identifier.php"}}],[/[$a-zA-Z_]\w*/,{cases:{"@phpPreDefinedVariables":{token:"variable.predefined.php"},"@default":"variable.php"}}],[/[{}]/,"delimiter.bracket.php"],[/[\[\]]/,"delimiter.array.php"],[/[()]/,"delimiter.parenthesis.php"],[/[ \t\r\n]+/],[/(#|\/\/)$/,"comment.php"],[/(#|\/\/)/,"comment.php","@phpLineComment"],[/\/\*/,"comment.php","@phpComment"],[/"/,"string.php","@phpDoubleQuoteString"],[/'/,"string.php","@phpSingleQuoteString"],[/[\+\-\*\%\&\|\^\~\!\=\<\>\/\?\;\:\.\,\@]/,"delimiter.php"],[/\d*\d+[eE]([\-+]?\d+)?/,"number.float.php"],[/\d*\.\d+([eE][\-+]?\d+)?/,"number.float.php"],[/0[xX][0-9a-fA-F']*[0-9a-fA-F]/,"number.hex.php"],[/0[0-7']*[0-7]/,"number.octal.php"],[/0[bB][0-1']*[0-1]/,"number.binary.php"],[/\d[\d']*/,"number.php"],[/\d/,"number.php"]],phpComment:[[/\*\//,"comment.php","@pop"],[/[^*]+/,"comment.php"],[/./,"comment.php"]],phpLineComment:[[/\?>/,{token:"@rematch",next:"@pop"}],[/.$/,"comment.php","@pop"],[/[^?]+$/,"comment.php","@pop"],[/[^?]+/,"comment.php"],[/./,"comment.php"]],phpDoubleQuoteString:[[/[^\\"]+/,"string.php"],[/@escapes/,"string.escape.php"],[/\\./,"string.escape.invalid.php"],[/"/,"string.php","@pop"]],phpSingleQuoteString:[[/[^\\']+/,"string.php"],[/@escapes/,"string.escape.php"],[/\\./,"string.escape.invalid.php"],[/'/,"string.php","@pop"]]},phpKeywords:["abstract","and","array","as","break","callable","case","catch","cfunction","class","clone","const","continue","declare","default","do","else","elseif","enddeclare","endfor","endforeach","endif","endswitch","endwhile","extends","false","final","for","foreach","function","global","goto","if","implements","interface","instanceof","insteadof","namespace","new","null","object","old_function","or","private","protected","public","resource","static","switch","throw","trait","try","true","use","var","while","xor","die","echo","empty","exit","eval","include","include_once","isset","list","require","require_once","return","print","unset","yield","__construct"],phpCompileTimeConstants:["__CLASS__","__DIR__","__FILE__","__LINE__","__NAMESPACE__","__METHOD__","__FUNCTION__","__TRAIT__"],phpPreDefinedVariables:["$GLOBALS","$_SERVER","$_GET","$_POST","$_FILES","$_REQUEST","$_SESSION","$_ENV","$_COOKIE","$php_errormsg","$HTTP_RAW_POST_DATA","$http_response_header","$argc","$argv"],escapes:/\\(?:[abfnrtv\\"']|x[0-9A-Fa-f]{1,4}|u[0-9A-Fa-f]{4}|U[0-9A-Fa-f]{8})/}});var z9e={};st(z9e,{conf:()=>d_t,language:()=>u_t});var d_t,u_t,V9e=k(()=>{d_t={comments:{lineComment:"#"},brackets:[["[","]"],["<",">"],["(",")"]],autoClosingPairs:[{open:"[",close:"]"},{open:"<",close:">"},{open:"(",close:")"}],surroundingPairs:[{open:"[",close:"]"},{open:"<",close:">"},{open:"(",close:")"}]},u_t={defaultToken:"",tokenPostfix:".pla",brackets:[{open:"[",close:"]",token:"delimiter.square"},{open:"<",close:">",token:"delimiter.angle"},{open:"(",close:")",token:"delimiter.parenthesis"}],keywords:[".i",".o",".mv",".ilb",".ob",".label",".type",".phase",".pair",".symbolic",".symbolic-output",".kiss",".p",".e",".end"],comment:/#.*$/,identifier:/[a-zA-Z]+[a-zA-Z0-9_\-]*/,plaContent:/[01\-~\|]+/,tokenizer:{root:[{include:"@whitespace"},[/@comment/,"comment"],[/\.([a-zA-Z_\-]+)/,{cases:{"@eos":{token:"keyword.$1"},"@keywords":{cases:{".type":{token:"keyword.$1",next:"@type"},"@default":{token:"keyword.$1",next:"@keywordArg"}}},"@default":{token:"keyword.$1"}}}],[/@identifier/,"identifier"],[/@plaContent/,"string"]],whitespace:[[/[ \t\r\n]+/,""]],type:[{include:"@whitespace"},[/\w+/,{token:"type",next:"@pop"}]],keywordArg:[[/[ \t\r\n]+/,{cases:{"@eos":{token:"",next:"@pop"},"@default":""}}],[/@comment/,"comment","@pop"],[/[<>()\[\]]/,{cases:{"@eos":{token:"@brackets",next:"@pop"},"@default":"@brackets"}}],[/\-?\d+/,{cases:{"@eos":{token:"number",next:"@pop"},"@default":"number"}}],[/@identifier/,{cases:{"@eos":{token:"identifier",next:"@pop"},"@default":"identifier"}}],[/[;=]/,{cases:{"@eos":{token:"delimiter",next:"@pop"},"@default":"delimiter"}}]]}}});var U9e={};st(U9e,{conf:()=>h_t,language:()=>f_t});var h_t,f_t,$9e=k(()=>{h_t={comments:{lineComment:"//",blockComment:["(*","*)"]},brackets:[["{","}"],["[","]"],["(",")"],["<",">"]],autoClosingPairs:[{open:'"',close:'"',notIn:["string","comment"]},{open:"{",close:"}",notIn:["string","comment"]},{open:"[",close:"]",notIn:["string","comment"]},{open:"(",close:")",notIn:["string","comment"]}]},f_t={tokenPostfix:".pats",defaultToken:"invalid",keywords:["abstype","abst0ype","absprop","absview","absvtype","absviewtype","absvt0ype","absviewt0ype","as","and","assume","begin","classdec","datasort","datatype","dataprop","dataview","datavtype","dataviewtype","do","end","extern","extype","extvar","exception","fn","fnx","fun","prfn","prfun","praxi","castfn","if","then","else","ifcase","in","infix","infixl","infixr","prefix","postfix","implmnt","implement","primplmnt","primplement","import","let","local","macdef","macrodef","nonfix","symelim","symintr","overload","of","op","rec","sif","scase","sortdef","sta","stacst","stadef","static","staload","dynload","try","tkindef","typedef","propdef","viewdef","vtypedef","viewtypedef","prval","var","prvar","when","where","with","withtype","withprop","withview","withvtype","withviewtype"],keywords_dlr:["$delay","$ldelay","$arrpsz","$arrptrsize","$d2ctype","$effmask","$effmask_ntm","$effmask_exn","$effmask_ref","$effmask_wrt","$effmask_all","$extern","$extkind","$extype","$extype_struct","$extval","$extfcall","$extmcall","$literal","$myfilename","$mylocation","$myfunction","$lst","$lst_t","$lst_vt","$list","$list_t","$list_vt","$rec","$rec_t","$rec_vt","$record","$record_t","$record_vt","$tup","$tup_t","$tup_vt","$tuple","$tuple_t","$tuple_vt","$break","$continue","$raise","$showtype","$vcopyenv_v","$vcopyenv_vt","$tempenver","$solver_assert","$solver_verify"],keywords_srp:["#if","#ifdef","#ifndef","#then","#elif","#elifdef","#elifndef","#else","#endif","#error","#prerr","#print","#assert","#undef","#define","#include","#require","#pragma","#codegen2","#codegen3"],irregular_keyword_list:["val+","val-","val","case+","case-","case","addr@","addr","fold@","free@","fix@","fix","lam@","lam","llam@","llam","viewt@ype+","viewt@ype-","viewt@ype","viewtype+","viewtype-","viewtype","view+","view-","view@","view","type+","type-","type","vtype+","vtype-","vtype","vt@ype+","vt@ype-","vt@ype","viewt@ype+","viewt@ype-","viewt@ype","viewtype+","viewtype-","viewtype","prop+","prop-","prop","type+","type-","type","t@ype","t@ype+","t@ype-","abst@ype","abstype","absviewt@ype","absvt@ype","for*","for","while*","while"],keywords_types:["bool","double","byte","int","short","char","void","unit","long","float","string","strptr"],keywords_effects:["0","fun","clo","prf","funclo","cloptr","cloref","ref","ntm","1"],operators:["@","!","|","`",":","$",".","=","#","~","..","...","=>","=<>","=/=>","=>>","=/=>>","<",">","><",".<",">.",".<>.","->","-<>"],brackets:[{open:",(",close:")",token:"delimiter.parenthesis"},{open:"`(",close:")",token:"delimiter.parenthesis"},{open:"%(",close:")",token:"delimiter.parenthesis"},{open:"'(",close:")",token:"delimiter.parenthesis"},{open:"'{",close:"}",token:"delimiter.parenthesis"},{open:"@(",close:")",token:"delimiter.parenthesis"},{open:"@{",close:"}",token:"delimiter.brace"},{open:"@[",close:"]",token:"delimiter.square"},{open:"#[",close:"]",token:"delimiter.square"},{open:"{",close:"}",token:"delimiter.curly"},{open:"[",close:"]",token:"delimiter.square"},{open:"(",close:")",token:"delimiter.parenthesis"},{open:"<",close:">",token:"delimiter.angle"}],symbols:/[=>]/,digit:/[0-9]/,digitseq0:/@digit*/,xdigit:/[0-9A-Za-z]/,xdigitseq0:/@xdigit*/,INTSP:/[lLuU]/,FLOATSP:/[fFlL]/,fexponent:/[eE][+-]?[0-9]+/,fexponent_bin:/[pP][+-]?[0-9]+/,deciexp:/\.[0-9]*@fexponent?/,hexiexp:/\.[0-9a-zA-Z]*@fexponent_bin?/,irregular_keywords:/val[+-]?|case[+-]?|addr\@?|fold\@|free\@|fix\@?|lam\@?|llam\@?|prop[+-]?|type[+-]?|view[+-@]?|viewt@?ype[+-]?|t@?ype[+-]?|v(iew)?t@?ype[+-]?|abst@?ype|absv(iew)?t@?ype|for\*?|while\*?/,ESCHAR:/[ntvbrfa\\\?'"\(\[\{]/,start:"root",tokenizer:{root:[{regex:/[ \t\r\n]+/,action:{token:""}},{regex:/\(\*\)/,action:{token:"invalid"}},{regex:/\(\*/,action:{token:"comment",next:"lexing_COMMENT_block_ml"}},{regex:/\(/,action:"@brackets"},{regex:/\)/,action:"@brackets"},{regex:/\[/,action:"@brackets"},{regex:/\]/,action:"@brackets"},{regex:/\{/,action:"@brackets"},{regex:/\}/,action:"@brackets"},{regex:/,\(/,action:"@brackets"},{regex:/,/,action:{token:"delimiter.comma"}},{regex:/;/,action:{token:"delimiter.semicolon"}},{regex:/@\(/,action:"@brackets"},{regex:/@\[/,action:"@brackets"},{regex:/@\{/,action:"@brackets"},{regex:/:/,action:{token:"@rematch",next:"@pop"}}],lexing_EXTCODE:[{regex:/^%}/,action:{token:"@rematch",next:"@pop",nextEmbedded:"@pop"}},{regex:/[^%]+/,action:""}],lexing_DQUOTE:[{regex:/"/,action:{token:"string.quote",next:"@pop"}},{regex:/(\{\$)(@IDENTFST@IDENTRST*)(\})/,action:[{token:"string.escape"},{token:"identifier"},{token:"string.escape"}]},{regex:/\\$/,action:{token:"string.escape"}},{regex:/\\(@ESCHAR|[xX]@xdigit+|@digit+)/,action:{token:"string.escape"}},{regex:/[^\\"]+/,action:{token:"string"}}]}}});var j9e={};st(j9e,{conf:()=>p_t,language:()=>m_t});var p_t,m_t,q9e=k(()=>{p_t={comments:{lineComment:"//",blockComment:["/*","*/"]},brackets:[["[","]"],["(",")"],["{","}"]],autoClosingPairs:[{open:'"',close:'"',notIn:["string","comment","identifier"]},{open:"[",close:"]",notIn:["string","comment","identifier"]},{open:"(",close:")",notIn:["string","comment","identifier"]},{open:"{",close:"}",notIn:["string","comment","identifier"]}]},m_t={defaultToken:"",tokenPostfix:".pq",ignoreCase:!1,brackets:[{open:"[",close:"]",token:"delimiter.square"},{open:"{",close:"}",token:"delimiter.brackets"},{open:"(",close:")",token:"delimiter.parenthesis"}],operatorKeywords:["and","not","or"],keywords:["as","each","else","error","false","if","in","is","let","meta","otherwise","section","shared","then","true","try","type"],constructors:["#binary","#date","#datetime","#datetimezone","#duration","#table","#time"],constants:["#infinity","#nan","#sections","#shared"],typeKeywords:["action","any","anynonnull","none","null","logical","number","time","date","datetime","datetimezone","duration","text","binary","list","record","table","function"],builtinFunctions:["Access.Database","Action.Return","Action.Sequence","Action.Try","ActiveDirectory.Domains","AdoDotNet.DataSource","AdoDotNet.Query","AdobeAnalytics.Cubes","AnalysisServices.Database","AnalysisServices.Databases","AzureStorage.BlobContents","AzureStorage.Blobs","AzureStorage.Tables","Binary.Buffer","Binary.Combine","Binary.Compress","Binary.Decompress","Binary.End","Binary.From","Binary.FromList","Binary.FromText","Binary.InferContentType","Binary.Length","Binary.ToList","Binary.ToText","BinaryFormat.7BitEncodedSignedInteger","BinaryFormat.7BitEncodedUnsignedInteger","BinaryFormat.Binary","BinaryFormat.Byte","BinaryFormat.ByteOrder","BinaryFormat.Choice","BinaryFormat.Decimal","BinaryFormat.Double","BinaryFormat.Group","BinaryFormat.Length","BinaryFormat.List","BinaryFormat.Null","BinaryFormat.Record","BinaryFormat.SignedInteger16","BinaryFormat.SignedInteger32","BinaryFormat.SignedInteger64","BinaryFormat.Single","BinaryFormat.Text","BinaryFormat.Transform","BinaryFormat.UnsignedInteger16","BinaryFormat.UnsignedInteger32","BinaryFormat.UnsignedInteger64","Byte.From","Character.FromNumber","Character.ToNumber","Combiner.CombineTextByDelimiter","Combiner.CombineTextByEachDelimiter","Combiner.CombineTextByLengths","Combiner.CombineTextByPositions","Combiner.CombineTextByRanges","Comparer.Equals","Comparer.FromCulture","Comparer.Ordinal","Comparer.OrdinalIgnoreCase","Csv.Document","Cube.AddAndExpandDimensionColumn","Cube.AddMeasureColumn","Cube.ApplyParameter","Cube.AttributeMemberId","Cube.AttributeMemberProperty","Cube.CollapseAndRemoveColumns","Cube.Dimensions","Cube.DisplayFolders","Cube.Measures","Cube.Parameters","Cube.Properties","Cube.PropertyKey","Cube.ReplaceDimensions","Cube.Transform","Currency.From","DB2.Database","Date.AddDays","Date.AddMonths","Date.AddQuarters","Date.AddWeeks","Date.AddYears","Date.Day","Date.DayOfWeek","Date.DayOfWeekName","Date.DayOfYear","Date.DaysInMonth","Date.EndOfDay","Date.EndOfMonth","Date.EndOfQuarter","Date.EndOfWeek","Date.EndOfYear","Date.From","Date.FromText","Date.IsInCurrentDay","Date.IsInCurrentMonth","Date.IsInCurrentQuarter","Date.IsInCurrentWeek","Date.IsInCurrentYear","Date.IsInNextDay","Date.IsInNextMonth","Date.IsInNextNDays","Date.IsInNextNMonths","Date.IsInNextNQuarters","Date.IsInNextNWeeks","Date.IsInNextNYears","Date.IsInNextQuarter","Date.IsInNextWeek","Date.IsInNextYear","Date.IsInPreviousDay","Date.IsInPreviousMonth","Date.IsInPreviousNDays","Date.IsInPreviousNMonths","Date.IsInPreviousNQuarters","Date.IsInPreviousNWeeks","Date.IsInPreviousNYears","Date.IsInPreviousQuarter","Date.IsInPreviousWeek","Date.IsInPreviousYear","Date.IsInYearToDate","Date.IsLeapYear","Date.Month","Date.MonthName","Date.QuarterOfYear","Date.StartOfDay","Date.StartOfMonth","Date.StartOfQuarter","Date.StartOfWeek","Date.StartOfYear","Date.ToRecord","Date.ToText","Date.WeekOfMonth","Date.WeekOfYear","Date.Year","DateTime.AddZone","DateTime.Date","DateTime.FixedLocalNow","DateTime.From","DateTime.FromFileTime","DateTime.FromText","DateTime.IsInCurrentHour","DateTime.IsInCurrentMinute","DateTime.IsInCurrentSecond","DateTime.IsInNextHour","DateTime.IsInNextMinute","DateTime.IsInNextNHours","DateTime.IsInNextNMinutes","DateTime.IsInNextNSeconds","DateTime.IsInNextSecond","DateTime.IsInPreviousHour","DateTime.IsInPreviousMinute","DateTime.IsInPreviousNHours","DateTime.IsInPreviousNMinutes","DateTime.IsInPreviousNSeconds","DateTime.IsInPreviousSecond","DateTime.LocalNow","DateTime.Time","DateTime.ToRecord","DateTime.ToText","DateTimeZone.FixedLocalNow","DateTimeZone.FixedUtcNow","DateTimeZone.From","DateTimeZone.FromFileTime","DateTimeZone.FromText","DateTimeZone.LocalNow","DateTimeZone.RemoveZone","DateTimeZone.SwitchZone","DateTimeZone.ToLocal","DateTimeZone.ToRecord","DateTimeZone.ToText","DateTimeZone.ToUtc","DateTimeZone.UtcNow","DateTimeZone.ZoneHours","DateTimeZone.ZoneMinutes","Decimal.From","Diagnostics.ActivityId","Diagnostics.Trace","DirectQueryCapabilities.From","Double.From","Duration.Days","Duration.From","Duration.FromText","Duration.Hours","Duration.Minutes","Duration.Seconds","Duration.ToRecord","Duration.ToText","Duration.TotalDays","Duration.TotalHours","Duration.TotalMinutes","Duration.TotalSeconds","Embedded.Value","Error.Record","Excel.CurrentWorkbook","Excel.Workbook","Exchange.Contents","Expression.Constant","Expression.Evaluate","Expression.Identifier","Facebook.Graph","File.Contents","Folder.Contents","Folder.Files","Function.From","Function.Invoke","Function.InvokeAfter","Function.IsDataSource","GoogleAnalytics.Accounts","Guid.From","HdInsight.Containers","HdInsight.Contents","HdInsight.Files","Hdfs.Contents","Hdfs.Files","Informix.Database","Int16.From","Int32.From","Int64.From","Int8.From","ItemExpression.From","Json.Document","Json.FromValue","Lines.FromBinary","Lines.FromText","Lines.ToBinary","Lines.ToText","List.Accumulate","List.AllTrue","List.Alternate","List.AnyTrue","List.Average","List.Buffer","List.Combine","List.Contains","List.ContainsAll","List.ContainsAny","List.Count","List.Covariance","List.DateTimeZones","List.DateTimes","List.Dates","List.Difference","List.Distinct","List.Durations","List.FindText","List.First","List.FirstN","List.Generate","List.InsertRange","List.Intersect","List.IsDistinct","List.IsEmpty","List.Last","List.LastN","List.MatchesAll","List.MatchesAny","List.Max","List.MaxN","List.Median","List.Min","List.MinN","List.Mode","List.Modes","List.NonNullCount","List.Numbers","List.PositionOf","List.PositionOfAny","List.Positions","List.Product","List.Random","List.Range","List.RemoveFirstN","List.RemoveItems","List.RemoveLastN","List.RemoveMatchingItems","List.RemoveNulls","List.RemoveRange","List.Repeat","List.ReplaceMatchingItems","List.ReplaceRange","List.ReplaceValue","List.Reverse","List.Select","List.Single","List.SingleOrDefault","List.Skip","List.Sort","List.StandardDeviation","List.Sum","List.Times","List.Transform","List.TransformMany","List.Union","List.Zip","Logical.From","Logical.FromText","Logical.ToText","MQ.Queue","MySQL.Database","Number.Abs","Number.Acos","Number.Asin","Number.Atan","Number.Atan2","Number.BitwiseAnd","Number.BitwiseNot","Number.BitwiseOr","Number.BitwiseShiftLeft","Number.BitwiseShiftRight","Number.BitwiseXor","Number.Combinations","Number.Cos","Number.Cosh","Number.Exp","Number.Factorial","Number.From","Number.FromText","Number.IntegerDivide","Number.IsEven","Number.IsNaN","Number.IsOdd","Number.Ln","Number.Log","Number.Log10","Number.Mod","Number.Permutations","Number.Power","Number.Random","Number.RandomBetween","Number.Round","Number.RoundAwayFromZero","Number.RoundDown","Number.RoundTowardZero","Number.RoundUp","Number.Sign","Number.Sin","Number.Sinh","Number.Sqrt","Number.Tan","Number.Tanh","Number.ToText","OData.Feed","Odbc.DataSource","Odbc.Query","OleDb.DataSource","OleDb.Query","Oracle.Database","Percentage.From","PostgreSQL.Database","RData.FromBinary","Record.AddField","Record.Combine","Record.Field","Record.FieldCount","Record.FieldNames","Record.FieldOrDefault","Record.FieldValues","Record.FromList","Record.FromTable","Record.HasFields","Record.RemoveFields","Record.RenameFields","Record.ReorderFields","Record.SelectFields","Record.ToList","Record.ToTable","Record.TransformFields","Replacer.ReplaceText","Replacer.ReplaceValue","RowExpression.Column","RowExpression.From","Salesforce.Data","Salesforce.Reports","SapBusinessWarehouse.Cubes","SapHana.Database","SharePoint.Contents","SharePoint.Files","SharePoint.Tables","Single.From","Soda.Feed","Splitter.SplitByNothing","Splitter.SplitTextByAnyDelimiter","Splitter.SplitTextByDelimiter","Splitter.SplitTextByEachDelimiter","Splitter.SplitTextByLengths","Splitter.SplitTextByPositions","Splitter.SplitTextByRanges","Splitter.SplitTextByRepeatedLengths","Splitter.SplitTextByWhitespace","Sql.Database","Sql.Databases","SqlExpression.SchemaFrom","SqlExpression.ToExpression","Sybase.Database","Table.AddColumn","Table.AddIndexColumn","Table.AddJoinColumn","Table.AddKey","Table.AggregateTableColumn","Table.AlternateRows","Table.Buffer","Table.Column","Table.ColumnCount","Table.ColumnNames","Table.ColumnsOfType","Table.Combine","Table.CombineColumns","Table.Contains","Table.ContainsAll","Table.ContainsAny","Table.DemoteHeaders","Table.Distinct","Table.DuplicateColumn","Table.ExpandListColumn","Table.ExpandRecordColumn","Table.ExpandTableColumn","Table.FillDown","Table.FillUp","Table.FilterWithDataTable","Table.FindText","Table.First","Table.FirstN","Table.FirstValue","Table.FromColumns","Table.FromList","Table.FromPartitions","Table.FromRecords","Table.FromRows","Table.FromValue","Table.Group","Table.HasColumns","Table.InsertRows","Table.IsDistinct","Table.IsEmpty","Table.Join","Table.Keys","Table.Last","Table.LastN","Table.MatchesAllRows","Table.MatchesAnyRows","Table.Max","Table.MaxN","Table.Min","Table.MinN","Table.NestedJoin","Table.Partition","Table.PartitionValues","Table.Pivot","Table.PositionOf","Table.PositionOfAny","Table.PrefixColumns","Table.Profile","Table.PromoteHeaders","Table.Range","Table.RemoveColumns","Table.RemoveFirstN","Table.RemoveLastN","Table.RemoveMatchingRows","Table.RemoveRows","Table.RemoveRowsWithErrors","Table.RenameColumns","Table.ReorderColumns","Table.Repeat","Table.ReplaceErrorValues","Table.ReplaceKeys","Table.ReplaceMatchingRows","Table.ReplaceRelationshipIdentity","Table.ReplaceRows","Table.ReplaceValue","Table.ReverseRows","Table.RowCount","Table.Schema","Table.SelectColumns","Table.SelectRows","Table.SelectRowsWithErrors","Table.SingleRow","Table.Skip","Table.Sort","Table.SplitColumn","Table.ToColumns","Table.ToList","Table.ToRecords","Table.ToRows","Table.TransformColumnNames","Table.TransformColumnTypes","Table.TransformColumns","Table.TransformRows","Table.Transpose","Table.Unpivot","Table.UnpivotOtherColumns","Table.View","Table.ViewFunction","TableAction.DeleteRows","TableAction.InsertRows","TableAction.UpdateRows","Tables.GetRelationships","Teradata.Database","Text.AfterDelimiter","Text.At","Text.BeforeDelimiter","Text.BetweenDelimiters","Text.Clean","Text.Combine","Text.Contains","Text.End","Text.EndsWith","Text.Format","Text.From","Text.FromBinary","Text.Insert","Text.Length","Text.Lower","Text.Middle","Text.NewGuid","Text.PadEnd","Text.PadStart","Text.PositionOf","Text.PositionOfAny","Text.Proper","Text.Range","Text.Remove","Text.RemoveRange","Text.Repeat","Text.Replace","Text.ReplaceRange","Text.Select","Text.Split","Text.SplitAny","Text.Start","Text.StartsWith","Text.ToBinary","Text.ToList","Text.Trim","Text.TrimEnd","Text.TrimStart","Text.Upper","Time.EndOfHour","Time.From","Time.FromText","Time.Hour","Time.Minute","Time.Second","Time.StartOfHour","Time.ToRecord","Time.ToText","Type.AddTableKey","Type.ClosedRecord","Type.Facets","Type.ForFunction","Type.ForRecord","Type.FunctionParameters","Type.FunctionRequiredParameters","Type.FunctionReturn","Type.Is","Type.IsNullable","Type.IsOpenRecord","Type.ListItem","Type.NonNullable","Type.OpenRecord","Type.RecordFields","Type.ReplaceFacets","Type.ReplaceTableKeys","Type.TableColumn","Type.TableKeys","Type.TableRow","Type.TableSchema","Type.Union","Uri.BuildQueryString","Uri.Combine","Uri.EscapeDataString","Uri.Parts","Value.Add","Value.As","Value.Compare","Value.Divide","Value.Equals","Value.Firewall","Value.FromText","Value.Is","Value.Metadata","Value.Multiply","Value.NativeQuery","Value.NullableEquals","Value.RemoveMetadata","Value.ReplaceMetadata","Value.ReplaceType","Value.Subtract","Value.Type","ValueAction.NativeStatement","ValueAction.Replace","Variable.Value","Web.Contents","Web.Page","WebAction.Request","Xml.Document","Xml.Tables"],builtinConstants:["BinaryEncoding.Base64","BinaryEncoding.Hex","BinaryOccurrence.Optional","BinaryOccurrence.Repeating","BinaryOccurrence.Required","ByteOrder.BigEndian","ByteOrder.LittleEndian","Compression.Deflate","Compression.GZip","CsvStyle.QuoteAfterDelimiter","CsvStyle.QuoteAlways","Culture.Current","Day.Friday","Day.Monday","Day.Saturday","Day.Sunday","Day.Thursday","Day.Tuesday","Day.Wednesday","ExtraValues.Error","ExtraValues.Ignore","ExtraValues.List","GroupKind.Global","GroupKind.Local","JoinAlgorithm.Dynamic","JoinAlgorithm.LeftHash","JoinAlgorithm.LeftIndex","JoinAlgorithm.PairwiseHash","JoinAlgorithm.RightHash","JoinAlgorithm.RightIndex","JoinAlgorithm.SortMerge","JoinKind.FullOuter","JoinKind.Inner","JoinKind.LeftAnti","JoinKind.LeftOuter","JoinKind.RightAnti","JoinKind.RightOuter","JoinSide.Left","JoinSide.Right","MissingField.Error","MissingField.Ignore","MissingField.UseNull","Number.E","Number.Epsilon","Number.NaN","Number.NegativeInfinity","Number.PI","Number.PositiveInfinity","Occurrence.All","Occurrence.First","Occurrence.Last","Occurrence.Optional","Occurrence.Repeating","Occurrence.Required","Order.Ascending","Order.Descending","Precision.Decimal","Precision.Double","QuoteStyle.Csv","QuoteStyle.None","RelativePosition.FromEnd","RelativePosition.FromStart","RoundingMode.AwayFromZero","RoundingMode.Down","RoundingMode.ToEven","RoundingMode.TowardZero","RoundingMode.Up","SapHanaDistribution.All","SapHanaDistribution.Connection","SapHanaDistribution.Off","SapHanaDistribution.Statement","SapHanaRangeOperator.Equals","SapHanaRangeOperator.GreaterThan","SapHanaRangeOperator.GreaterThanOrEquals","SapHanaRangeOperator.LessThan","SapHanaRangeOperator.LessThanOrEquals","SapHanaRangeOperator.NotEquals","TextEncoding.Ascii","TextEncoding.BigEndianUnicode","TextEncoding.Unicode","TextEncoding.Utf16","TextEncoding.Utf8","TextEncoding.Windows","TraceLevel.Critical","TraceLevel.Error","TraceLevel.Information","TraceLevel.Verbose","TraceLevel.Warning","WebMethod.Delete","WebMethod.Get","WebMethod.Head","WebMethod.Patch","WebMethod.Post","WebMethod.Put"],builtinTypes:["Action.Type","Any.Type","Binary.Type","BinaryEncoding.Type","BinaryOccurrence.Type","Byte.Type","ByteOrder.Type","Character.Type","Compression.Type","CsvStyle.Type","Currency.Type","Date.Type","DateTime.Type","DateTimeZone.Type","Day.Type","Decimal.Type","Double.Type","Duration.Type","ExtraValues.Type","Function.Type","GroupKind.Type","Guid.Type","Int16.Type","Int32.Type","Int64.Type","Int8.Type","JoinAlgorithm.Type","JoinKind.Type","JoinSide.Type","List.Type","Logical.Type","MissingField.Type","None.Type","Null.Type","Number.Type","Occurrence.Type","Order.Type","Password.Type","Percentage.Type","Precision.Type","QuoteStyle.Type","Record.Type","RelativePosition.Type","RoundingMode.Type","SapHanaDistribution.Type","SapHanaRangeOperator.Type","Single.Type","Table.Type","Text.Type","TextEncoding.Type","Time.Type","TraceLevel.Type","Type.Type","Uri.Type","WebMethod.Type"],tokenizer:{root:[[/#"[\w \.]+"/,"identifier.quote"],[/\d*\.\d+([eE][\-+]?\d+)?/,"number.float"],[/0[xX][0-9a-fA-F]+/,"number.hex"],[/\d+([eE][\-+]?\d+)?/,"number"],[/(#?[a-z]+)\b/,{cases:{"@typeKeywords":"type","@keywords":"keyword","@constants":"constant","@constructors":"constructor","@operatorKeywords":"operators","@default":"identifier"}}],[/\b([A-Z][a-zA-Z0-9]+\.Type)\b/,{cases:{"@builtinTypes":"type","@default":"identifier"}}],[/\b([A-Z][a-zA-Z0-9]+\.[A-Z][a-zA-Z0-9]+)\b/,{cases:{"@builtinFunctions":"keyword.function","@builtinConstants":"constant","@default":"identifier"}}],[/\b([a-zA-Z_][\w\.]*)\b/,"identifier"],{include:"@whitespace"},{include:"@comments"},{include:"@strings"},[/[{}()\[\]]/,"@brackets"],[/([=\+<>\-\*&@\?\/!])|([<>]=)|(<>)|(=>)|(\.\.\.)|(\.\.)/,"operators"],[/[,;]/,"delimiter"]],whitespace:[[/\s+/,"white"]],comments:[["\\/\\*","comment","@comment"],["\\/\\/+.*","comment"]],comment:[["\\*\\/","comment","@pop"],[".","comment"]],strings:[['"',"string","@string"]],string:[['""',"string.escape"],['"',"string","@pop"],[".","string"]]}}});var K9e={};st(K9e,{conf:()=>g_t,language:()=>__t});var g_t,__t,G9e=k(()=>{g_t={wordPattern:/(-?\d*\.\d\w*)|([^\`\~\!\@\#%\^\&\*\(\)\=\+\[\{\]\}\\\|\;\:\'\"\,\.\<\>\/\?\s]+)/g,comments:{lineComment:"#",blockComment:["<#","#>"]},brackets:[["{","}"],["[","]"],["(",")"]],autoClosingPairs:[{open:"{",close:"}"},{open:"[",close:"]"},{open:"(",close:")"},{open:'"',close:'"',notIn:["string"]},{open:"'",close:"'",notIn:["string","comment"]}],surroundingPairs:[{open:"{",close:"}"},{open:"[",close:"]"},{open:"(",close:")"},{open:'"',close:'"'},{open:"'",close:"'"}],folding:{markers:{start:new RegExp("^\\s*#region\\b"),end:new RegExp("^\\s*#endregion\\b")}}},__t={defaultToken:"",ignoreCase:!0,tokenPostfix:".ps1",brackets:[{token:"delimiter.curly",open:"{",close:"}"},{token:"delimiter.square",open:"[",close:"]"},{token:"delimiter.parenthesis",open:"(",close:")"}],keywords:["begin","break","catch","class","continue","data","define","do","dynamicparam","else","elseif","end","exit","filter","finally","for","foreach","from","function","if","in","param","process","return","switch","throw","trap","try","until","using","var","while","workflow","parallel","sequence","inlinescript","configuration"],helpKeywords:/SYNOPSIS|DESCRIPTION|PARAMETER|EXAMPLE|INPUTS|OUTPUTS|NOTES|LINK|COMPONENT|ROLE|FUNCTIONALITY|FORWARDHELPTARGETNAME|FORWARDHELPCATEGORY|REMOTEHELPRUNSPACE|EXTERNALHELP/,symbols:/[=>/,"comment","@pop"],[/(\.)(@helpKeywords)(?!\w)/,{token:"comment.keyword.$2"}],[/[\.#]/,"comment"]]}}});var Y9e={};st(Y9e,{conf:()=>v_t,language:()=>x_t});var b_t,v_t,x_t,Z9e=k(()=>{b_t=["true","false"],v_t={comments:{lineComment:"//",blockComment:["/*","*/"]},brackets:[["{","}"],["[","]"],["(",")"],["<",">"]],surroundingPairs:[{open:"{",close:"}"},{open:"[",close:"]"},{open:"(",close:")"},{open:"<",close:">"},{open:'"',close:'"'},{open:"'",close:"'"}],autoClosingPairs:[{open:"{",close:"}"},{open:"[",close:"]"},{open:"(",close:")"},{open:"<",close:">"},{open:'"',close:'"',notIn:["string"]},{open:"'",close:"'",notIn:["string"]}],autoCloseBefore:`.,=}])>' `,indentationRules:{increaseIndentPattern:new RegExp("^((?!\\/\\/).)*(\\{[^}\"'`]*|\\([^)\"'`]*|\\[[^\\]\"'`]*)$"),decreaseIndentPattern:new RegExp("^((?!.*?\\/\\*).*\\*/)?\\s*[\\}\\]].*$")}},x_t={defaultToken:"",tokenPostfix:".proto",brackets:[{open:"{",close:"}",token:"delimiter.curly"},{open:"[",close:"]",token:"delimiter.square"},{open:"(",close:")",token:"delimiter.parenthesis"},{open:"<",close:">",token:"delimiter.angle"}],symbols:/[=>/,{token:"@brackets",bracket:"@close",switchTo:"identifier"}]],field:[{include:"@whitespace"},["group",{cases:{"$S2==proto2":{token:"keyword",switchTo:"@groupDecl.$S2"}}}],[/(@identifier)(\s*)(=)/,["identifier","white",{token:"delimiter",next:"@pop"}]],[/@fullIdentifier|\./,{cases:{"@builtinTypes":"keyword","@default":"type.identifier"}}]],groupDecl:[{include:"@whitespace"},[/@identifier/,"identifier"],["=","operator"],[/{/,{token:"@brackets",bracket:"@open",switchTo:"@messageBody.$S2"}],{include:"@constant"}],type:[{include:"@whitespace"},[/@identifier/,"type.identifier","@pop"],[/./,"delimiter"]],identifier:[{include:"@whitespace"},[/@identifier/,"identifier","@pop"]],serviceDecl:[{include:"@whitespace"},[/@identifier/,"identifier"],[/{/,{token:"@brackets",bracket:"@open",switchTo:"@serviceBody.$S2"}]],serviceBody:[{include:"@whitespace"},{include:"@constant"},[/;/,"delimiter"],[/option\b/,"keyword","@option.$S2"],[/rpc\b/,"keyword","@rpc.$S2"],[/\[/,{token:"@brackets",bracket:"@open",next:"@options.$S2"}],[/}/,{token:"@brackets",bracket:"@close",next:"@pop"}]],rpc:[{include:"@whitespace"},[/@identifier/,"identifier"],[/\(/,{token:"@brackets",bracket:"@open",switchTo:"@request.$S2"}],[/{/,{token:"@brackets",bracket:"@open",next:"@methodOptions.$S2"}],[/;/,"delimiter","@pop"]],request:[{include:"@whitespace"},[/@messageType/,{cases:{stream:{token:"keyword",next:"@type.$S2"},"@default":"type.identifier"}}],[/\)/,{token:"@brackets",bracket:"@close",switchTo:"@returns.$S2"}]],returns:[{include:"@whitespace"},[/returns\b/,"keyword"],[/\(/,{token:"@brackets",bracket:"@open",switchTo:"@response.$S2"}]],response:[{include:"@whitespace"},[/@messageType/,{cases:{stream:{token:"keyword",next:"@type.$S2"},"@default":"type.identifier"}}],[/\)/,{token:"@brackets",bracket:"@close",switchTo:"@rpc.$S2"}]],methodOptions:[{include:"@whitespace"},{include:"@constant"},[/;/,"delimiter"],["option","keyword"],[/@optionName/,"annotation"],[/[()]/,"annotation.brackets"],[/=/,"operator"],[/}/,{token:"@brackets",bracket:"@close",next:"@pop"}]],comment:[[/[^\/*]+/,"comment"],[/\/\*/,"comment","@push"],["\\*/","comment","@pop"],[/[\/*]/,"comment"]],string:[[/[^\\"]+/,"string"],[/@escapes/,"string.escape"],[/\\./,"string.escape.invalid"],[/"/,{token:"string.quote",bracket:"@close",next:"@pop"}]],stringSingle:[[/[^\\']+/,"string"],[/@escapes/,"string.escape"],[/\\./,"string.escape.invalid"],[/'/,{token:"string.quote",bracket:"@close",next:"@pop"}]],constant:[["@boolLit","keyword.constant"],["@hexLit","number.hex"],["@octalLit","number.octal"],["@decimalLit","number"],["@floatLit","number.float"],[/("([^"\\]|\\.)*|'([^'\\]|\\.)*)$/,"string.invalid"],[/"/,{token:"string.quote",bracket:"@open",next:"@string"}],[/'/,{token:"string.quote",bracket:"@open",next:"@stringSingle"}],[/{/,{token:"@brackets",bracket:"@open",next:"@prototext"}],[/identifier/,"identifier"]],whitespace:[[/[ \t\r\n]+/,"white"],[/\/\*/,"comment","@comment"],[/\/\/.*$/,"comment"]],prototext:[{include:"@whitespace"},{include:"@constant"},[/@identifier/,"identifier"],[/[:;]/,"delimiter"],[/}/,{token:"@brackets",bracket:"@close",next:"@pop"}]]}}});var X9e={};st(X9e,{conf:()=>w_t,language:()=>y_t});var w_t,y_t,Q9e=k(()=>{w_t={comments:{lineComment:"//"},brackets:[["{","}"],["[","]"],["(",")"]],autoClosingPairs:[{open:'"',close:'"',notIn:["string","comment"]},{open:"'",close:"'",notIn:["string","comment"]},{open:"{",close:"}",notIn:["string","comment"]},{open:"[",close:"]",notIn:["string","comment"]},{open:"(",close:")",notIn:["string","comment"]}],folding:{offSide:!0}},y_t={defaultToken:"",tokenPostfix:".pug",ignoreCase:!0,brackets:[{token:"delimiter.curly",open:"{",close:"}"},{token:"delimiter.array",open:"[",close:"]"},{token:"delimiter.parenthesis",open:"(",close:")"}],keywords:["append","block","case","default","doctype","each","else","extends","for","if","in","include","mixin","typeof","unless","var","when"],tags:["a","abbr","acronym","address","area","article","aside","audio","b","base","basefont","bdi","bdo","blockquote","body","br","button","canvas","caption","center","cite","code","col","colgroup","command","datalist","dd","del","details","dfn","div","dl","dt","em","embed","fieldset","figcaption","figure","font","footer","form","frame","frameset","h1","h2","h3","h4","h5","h6","head","header","hgroup","hr","html","i","iframe","img","input","ins","keygen","kbd","label","li","link","map","mark","menu","meta","meter","nav","noframes","noscript","object","ol","optgroup","option","output","p","param","pre","progress","q","rp","rt","ruby","s","samp","script","section","select","small","source","span","strike","strong","style","sub","summary","sup","table","tbody","td","textarea","tfoot","th","thead","time","title","tr","tracks","tt","u","ul","video","wbr"],symbols:/[\+\-\*\%\&\|\!\=\/\.\,\:]+/,escapes:/\\(?:[abfnrtv\\"']|x[0-9A-Fa-f]{1,4}|u[0-9A-Fa-f]{4}|U[0-9A-Fa-f]{8})/,tokenizer:{root:[[/^(\s*)([a-zA-Z_-][\w-]*)/,{cases:{"$2@tags":{cases:{"@eos":["","tag"],"@default":["",{token:"tag",next:"@tag.$1"}]}},"$2@keywords":["",{token:"keyword.$2"}],"@default":["",""]}}],[/^(\s*)(#[a-zA-Z_-][\w-]*)/,{cases:{"@eos":["","tag.id"],"@default":["",{token:"tag.id",next:"@tag.$1"}]}}],[/^(\s*)(\.[a-zA-Z_-][\w-]*)/,{cases:{"@eos":["","tag.class"],"@default":["",{token:"tag.class",next:"@tag.$1"}]}}],[/^(\s*)(\|.*)$/,""],{include:"@whitespace"},[/[a-zA-Z_$][\w$]*/,{cases:{"@keywords":{token:"keyword.$0"},"@default":""}}],[/[{}()\[\]]/,"@brackets"],[/@symbols/,"delimiter"],[/\d+\.\d+([eE][\-+]?\d+)?/,"number.float"],[/\d+/,"number"],[/"/,"string",'@string."'],[/'/,"string","@string.'"]],tag:[[/(\.)(\s*$)/,[{token:"delimiter",next:"@blockText.$S2."},""]],[/\s+/,{token:"",next:"@simpleText"}],[/#[a-zA-Z_-][\w-]*/,{cases:{"@eos":{token:"tag.id",next:"@pop"},"@default":"tag.id"}}],[/\.[a-zA-Z_-][\w-]*/,{cases:{"@eos":{token:"tag.class",next:"@pop"},"@default":"tag.class"}}],[/\(/,{token:"delimiter.parenthesis",next:"@attributeList"}]],simpleText:[[/[^#]+$/,{token:"",next:"@popall"}],[/[^#]+/,{token:""}],[/(#{)([^}]*)(})/,{cases:{"@eos":["interpolation.delimiter","interpolation",{token:"interpolation.delimiter",next:"@popall"}],"@default":["interpolation.delimiter","interpolation","interpolation.delimiter"]}}],[/#$/,{token:"",next:"@popall"}],[/#/,""]],attributeList:[[/\s+/,""],[/(\w+)(\s*=\s*)("|')/,["attribute.name","delimiter",{token:"attribute.value",next:"@value.$3"}]],[/\w+/,"attribute.name"],[/,/,{cases:{"@eos":{token:"attribute.delimiter",next:"@popall"},"@default":"attribute.delimiter"}}],[/\)$/,{token:"delimiter.parenthesis",next:"@popall"}],[/\)/,{token:"delimiter.parenthesis",next:"@pop"}]],whitespace:[[/^(\s*)(\/\/.*)$/,{token:"comment",next:"@blockText.$1.comment"}],[/[ \t\r\n]+/,""],[//,{token:"comment",next:"@pop"}],[/"]},brackets:[[""],["<",">"],["{","}"],["(",")"]],autoClosingPairs:[{open:"{",close:"}"},{open:"[",close:"]"},{open:"(",close:")"},{open:'"',close:'"'},{open:"'",close:"'"}],surroundingPairs:[{open:'"',close:'"'},{open:"'",close:"'"},{open:"<",close:">"}],onEnterRules:[{beforeText:new RegExp(`<(?!(?:${l7e.join("|")}))(\\w[\\w\\d]*)([^/>]*(?!/)>)[^<]*$`,"i"),afterText:/^<\/(\w[\w\d]*)\s*>$/i,action:{indentAction:Rpe.languages.IndentAction.IndentOutdent}},{beforeText:new RegExp(`<(?!(?:${l7e.join("|")}))(\\w[\\w\\d]*)([^/>]*(?!/)>)[^<]*$`,"i"),action:{indentAction:Rpe.languages.IndentAction.Indent}}]},H_t={defaultToken:"",tokenPostfix:"",tokenizer:{root:[[/@@@@/],[/@[^@]/,{token:"@rematch",switchTo:"@razorInSimpleState.root"}],[/)/,["delimiter.html","tag.html","delimiter.html"]],[/(<)(script)/,["delimiter.html",{token:"tag.html",next:"@script"}]],[/(<)(style)/,["delimiter.html",{token:"tag.html",next:"@style"}]],[/(<)([:\w\-]+)/,["delimiter.html",{token:"tag.html",next:"@otherTag"}]],[/(<\/)([\w\-]+)/,["delimiter.html",{token:"tag.html",next:"@otherTag"}]],[/]+/,"metatag.content.html"],[/>/,"metatag.html","@pop"]],comment:[[/@[^@]/,{token:"@rematch",switchTo:"@razorInSimpleState.comment"}],[/-->/,"comment.html","@pop"],[/[^-]+/,"comment.content.html"],[/./,"comment.content.html"]],otherTag:[[/@[^@]/,{token:"@rematch",switchTo:"@razorInSimpleState.otherTag"}],[/\/?>/,"delimiter.html","@pop"],[/"([^"]*)"/,"attribute.value"],[/'([^']*)'/,"attribute.value"],[/[\w\-]+/,"attribute.name"],[/=/,"delimiter"],[/[ \t\r\n]+/]],script:[[/@[^@]/,{token:"@rematch",switchTo:"@razorInSimpleState.script"}],[/type/,"attribute.name","@scriptAfterType"],[/"([^"]*)"/,"attribute.value"],[/'([^']*)'/,"attribute.value"],[/[\w\-]+/,"attribute.name"],[/=/,"delimiter"],[/>/,{token:"delimiter.html",next:"@scriptEmbedded.text/javascript",nextEmbedded:"text/javascript"}],[/[ \t\r\n]+/],[/(<\/)(script\s*)(>)/,["delimiter.html","tag.html",{token:"delimiter.html",next:"@pop"}]]],scriptAfterType:[[/@[^@]/,{token:"@rematch",switchTo:"@razorInSimpleState.scriptAfterType"}],[/=/,"delimiter","@scriptAfterTypeEquals"],[/>/,{token:"delimiter.html",next:"@scriptEmbedded.text/javascript",nextEmbedded:"text/javascript"}],[/[ \t\r\n]+/],[/<\/script\s*>/,{token:"@rematch",next:"@pop"}]],scriptAfterTypeEquals:[[/@[^@]/,{token:"@rematch",switchTo:"@razorInSimpleState.scriptAfterTypeEquals"}],[/"([^"]*)"/,{token:"attribute.value",switchTo:"@scriptWithCustomType.$1"}],[/'([^']*)'/,{token:"attribute.value",switchTo:"@scriptWithCustomType.$1"}],[/>/,{token:"delimiter.html",next:"@scriptEmbedded.text/javascript",nextEmbedded:"text/javascript"}],[/[ \t\r\n]+/],[/<\/script\s*>/,{token:"@rematch",next:"@pop"}]],scriptWithCustomType:[[/@[^@]/,{token:"@rematch",switchTo:"@razorInSimpleState.scriptWithCustomType.$S2"}],[/>/,{token:"delimiter.html",next:"@scriptEmbedded.$S2",nextEmbedded:"$S2"}],[/"([^"]*)"/,"attribute.value"],[/'([^']*)'/,"attribute.value"],[/[\w\-]+/,"attribute.name"],[/=/,"delimiter"],[/[ \t\r\n]+/],[/<\/script\s*>/,{token:"@rematch",next:"@pop"}]],scriptEmbedded:[[/@[^@]/,{token:"@rematch",switchTo:"@razorInEmbeddedState.scriptEmbedded.$S2",nextEmbedded:"@pop"}],[/<\/script/,{token:"@rematch",next:"@pop",nextEmbedded:"@pop"}]],style:[[/@[^@]/,{token:"@rematch",switchTo:"@razorInSimpleState.style"}],[/type/,"attribute.name","@styleAfterType"],[/"([^"]*)"/,"attribute.value"],[/'([^']*)'/,"attribute.value"],[/[\w\-]+/,"attribute.name"],[/=/,"delimiter"],[/>/,{token:"delimiter.html",next:"@styleEmbedded.text/css",nextEmbedded:"text/css"}],[/[ \t\r\n]+/],[/(<\/)(style\s*)(>)/,["delimiter.html","tag.html",{token:"delimiter.html",next:"@pop"}]]],styleAfterType:[[/@[^@]/,{token:"@rematch",switchTo:"@razorInSimpleState.styleAfterType"}],[/=/,"delimiter","@styleAfterTypeEquals"],[/>/,{token:"delimiter.html",next:"@styleEmbedded.text/css",nextEmbedded:"text/css"}],[/[ \t\r\n]+/],[/<\/style\s*>/,{token:"@rematch",next:"@pop"}]],styleAfterTypeEquals:[[/@[^@]/,{token:"@rematch",switchTo:"@razorInSimpleState.styleAfterTypeEquals"}],[/"([^"]*)"/,{token:"attribute.value",switchTo:"@styleWithCustomType.$1"}],[/'([^']*)'/,{token:"attribute.value",switchTo:"@styleWithCustomType.$1"}],[/>/,{token:"delimiter.html",next:"@styleEmbedded.text/css",nextEmbedded:"text/css"}],[/[ \t\r\n]+/],[/<\/style\s*>/,{token:"@rematch",next:"@pop"}]],styleWithCustomType:[[/@[^@]/,{token:"@rematch",switchTo:"@razorInSimpleState.styleWithCustomType.$S2"}],[/>/,{token:"delimiter.html",next:"@styleEmbedded.$S2",nextEmbedded:"$S2"}],[/"([^"]*)"/,"attribute.value"],[/'([^']*)'/,"attribute.value"],[/[\w\-]+/,"attribute.name"],[/=/,"delimiter"],[/[ \t\r\n]+/],[/<\/style\s*>/,{token:"@rematch",next:"@pop"}]],styleEmbedded:[[/@[^@]/,{token:"@rematch",switchTo:"@razorInEmbeddedState.styleEmbedded.$S2",nextEmbedded:"@pop"}],[/<\/style/,{token:"@rematch",next:"@pop",nextEmbedded:"@pop"}]],razorInSimpleState:[[/@\*/,"comment.cs","@razorBlockCommentTopLevel"],[/@[{(]/,"metatag.cs","@razorRootTopLevel"],[/(@)(\s*[\w]+)/,["metatag.cs",{token:"identifier.cs",switchTo:"@$S2.$S3"}]],[/[})]/,{token:"metatag.cs",switchTo:"@$S2.$S3"}],[/\*@/,{token:"comment.cs",switchTo:"@$S2.$S3"}]],razorInEmbeddedState:[[/@\*/,"comment.cs","@razorBlockCommentTopLevel"],[/@[{(]/,"metatag.cs","@razorRootTopLevel"],[/(@)(\s*[\w]+)/,["metatag.cs",{token:"identifier.cs",switchTo:"@$S2.$S3",nextEmbedded:"$S3"}]],[/[})]/,{token:"metatag.cs",switchTo:"@$S2.$S3",nextEmbedded:"$S3"}],[/\*@/,{token:"comment.cs",switchTo:"@$S2.$S3",nextEmbedded:"$S3"}]],razorBlockCommentTopLevel:[[/\*@/,"@rematch","@pop"],[/[^*]+/,"comment.cs"],[/./,"comment.cs"]],razorBlockComment:[[/\*@/,"comment.cs","@pop"],[/[^*]+/,"comment.cs"],[/./,"comment.cs"]],razorRootTopLevel:[[/\{/,"delimiter.bracket.cs","@razorRoot"],[/\(/,"delimiter.parenthesis.cs","@razorRoot"],[/[})]/,"@rematch","@pop"],{include:"razorCommon"}],razorRoot:[[/\{/,"delimiter.bracket.cs","@razorRoot"],[/\(/,"delimiter.parenthesis.cs","@razorRoot"],[/\}/,"delimiter.bracket.cs","@pop"],[/\)/,"delimiter.parenthesis.cs","@pop"],{include:"razorCommon"}],razorCommon:[[/[a-zA-Z_]\w*/,{cases:{"@razorKeywords":{token:"keyword.cs"},"@default":"identifier.cs"}}],[/[\[\]]/,"delimiter.array.cs"],[/[ \t\r\n]+/],[/\/\/.*$/,"comment.cs"],[/@\*/,"comment.cs","@razorBlockComment"],[/"([^"]*)"/,"string.cs"],[/'([^']*)'/,"string.cs"],[/(<)([\w\-]+)(\/>)/,["delimiter.html","tag.html","delimiter.html"]],[/(<)([\w\-]+)(>)/,["delimiter.html","tag.html","delimiter.html"]],[/(<\/)([\w\-]+)(>)/,["delimiter.html","tag.html","delimiter.html"]],[/[\+\-\*\%\&\|\^\~\!\=\<\>\/\?\;\:\.\,]/,"delimiter.cs"],[/\d*\d+[eE]([\-+]?\d+)?/,"number.float.cs"],[/\d*\.\d+([eE][\-+]?\d+)?/,"number.float.cs"],[/0[xX][0-9a-fA-F']*[0-9a-fA-F]/,"number.hex.cs"],[/0[0-7']*[0-7]/,"number.octal.cs"],[/0[bB][0-1']*[0-1]/,"number.binary.cs"],[/\d[\d']*/,"number.cs"],[/\d/,"number.cs"]]},razorKeywords:["abstract","as","async","await","base","bool","break","by","byte","case","catch","char","checked","class","const","continue","decimal","default","delegate","do","double","descending","explicit","event","extern","else","enum","false","finally","fixed","float","for","foreach","from","goto","group","if","implicit","in","int","interface","internal","into","is","lock","long","nameof","new","null","namespace","object","operator","out","override","orderby","params","private","protected","public","readonly","ref","return","switch","struct","sbyte","sealed","short","sizeof","stackalloc","static","string","select","this","throw","true","try","typeof","uint","ulong","unchecked","unsafe","ushort","using","var","virtual","volatile","void","when","while","where","yield","model","inject"],escapes:/\\(?:[abfnrtv\\"']|x[0-9A-Fa-f]{1,4}|u[0-9A-Fa-f]{4}|U[0-9A-Fa-f]{8})/}});var u7e={};st(u7e,{conf:()=>z_t,language:()=>V_t});var z_t,V_t,h7e=k(()=>{z_t={brackets:[["{","}"],["[","]"],["(",")"]],autoClosingPairs:[{open:"{",close:"}"},{open:"[",close:"]"},{open:"(",close:")"},{open:'"',close:'"'},{open:"'",close:"'"}],surroundingPairs:[{open:"{",close:"}"},{open:"[",close:"]"},{open:"(",close:")"},{open:'"',close:'"'},{open:"'",close:"'"}]},V_t={defaultToken:"",tokenPostfix:".redis",ignoreCase:!0,brackets:[{open:"[",close:"]",token:"delimiter.square"},{open:"(",close:")",token:"delimiter.parenthesis"}],keywords:["APPEND","AUTH","BGREWRITEAOF","BGSAVE","BITCOUNT","BITFIELD","BITOP","BITPOS","BLPOP","BRPOP","BRPOPLPUSH","CLIENT","KILL","LIST","GETNAME","PAUSE","REPLY","SETNAME","CLUSTER","ADDSLOTS","COUNT-FAILURE-REPORTS","COUNTKEYSINSLOT","DELSLOTS","FAILOVER","FORGET","GETKEYSINSLOT","INFO","KEYSLOT","MEET","NODES","REPLICATE","RESET","SAVECONFIG","SET-CONFIG-EPOCH","SETSLOT","SLAVES","SLOTS","COMMAND","COUNT","GETKEYS","CONFIG","GET","REWRITE","SET","RESETSTAT","DBSIZE","DEBUG","OBJECT","SEGFAULT","DECR","DECRBY","DEL","DISCARD","DUMP","ECHO","EVAL","EVALSHA","EXEC","EXISTS","EXPIRE","EXPIREAT","FLUSHALL","FLUSHDB","GEOADD","GEOHASH","GEOPOS","GEODIST","GEORADIUS","GEORADIUSBYMEMBER","GETBIT","GETRANGE","GETSET","HDEL","HEXISTS","HGET","HGETALL","HINCRBY","HINCRBYFLOAT","HKEYS","HLEN","HMGET","HMSET","HSET","HSETNX","HSTRLEN","HVALS","INCR","INCRBY","INCRBYFLOAT","KEYS","LASTSAVE","LINDEX","LINSERT","LLEN","LPOP","LPUSH","LPUSHX","LRANGE","LREM","LSET","LTRIM","MGET","MIGRATE","MONITOR","MOVE","MSET","MSETNX","MULTI","PERSIST","PEXPIRE","PEXPIREAT","PFADD","PFCOUNT","PFMERGE","PING","PSETEX","PSUBSCRIBE","PUBSUB","PTTL","PUBLISH","PUNSUBSCRIBE","QUIT","RANDOMKEY","READONLY","READWRITE","RENAME","RENAMENX","RESTORE","ROLE","RPOP","RPOPLPUSH","RPUSH","RPUSHX","SADD","SAVE","SCARD","SCRIPT","FLUSH","LOAD","SDIFF","SDIFFSTORE","SELECT","SETBIT","SETEX","SETNX","SETRANGE","SHUTDOWN","SINTER","SINTERSTORE","SISMEMBER","SLAVEOF","SLOWLOG","SMEMBERS","SMOVE","SORT","SPOP","SRANDMEMBER","SREM","STRLEN","SUBSCRIBE","SUNION","SUNIONSTORE","SWAPDB","SYNC","TIME","TOUCH","TTL","TYPE","UNSUBSCRIBE","UNLINK","UNWATCH","WAIT","WATCH","ZADD","ZCARD","ZCOUNT","ZINCRBY","ZINTERSTORE","ZLEXCOUNT","ZRANGE","ZRANGEBYLEX","ZREVRANGEBYLEX","ZRANGEBYSCORE","ZRANK","ZREM","ZREMRANGEBYLEX","ZREMRANGEBYRANK","ZREMRANGEBYSCORE","ZREVRANGE","ZREVRANGEBYSCORE","ZREVRANK","ZSCORE","ZUNIONSTORE","SCAN","SSCAN","HSCAN","ZSCAN"],operators:[],builtinFunctions:[],builtinVariables:[],pseudoColumns:[],tokenizer:{root:[{include:"@whitespace"},{include:"@pseudoColumns"},{include:"@numbers"},{include:"@strings"},{include:"@scopes"},[/[;,.]/,"delimiter"],[/[()]/,"@brackets"],[/[\w@#$]+/,{cases:{"@keywords":"keyword","@operators":"operator","@builtinVariables":"predefined","@builtinFunctions":"predefined","@default":"identifier"}}],[/[<>=!%&+\-*/|~^]/,"operator"]],whitespace:[[/\s+/,"white"]],pseudoColumns:[[/[$][A-Za-z_][\w@#$]*/,{cases:{"@pseudoColumns":"predefined","@default":"identifier"}}]],numbers:[[/0[xX][0-9a-fA-F]*/,"number"],[/[$][+-]*\d*(\.\d*)?/,"number"],[/((\d+(\.\d*)?)|(\.\d+))([eE][\-+]?\d+)?/,"number"]],strings:[[/'/,{token:"string",next:"@string"}],[/"/,{token:"string.double",next:"@stringDouble"}]],string:[[/[^']+/,"string"],[/''/,"string"],[/'/,{token:"string",next:"@pop"}]],stringDouble:[[/[^"]+/,"string.double"],[/""/,"string.double"],[/"/,{token:"string.double",next:"@pop"}]],scopes:[]}}});var f7e={};st(f7e,{conf:()=>U_t,language:()=>$_t});var U_t,$_t,p7e=k(()=>{U_t={comments:{lineComment:"--",blockComment:["/*","*/"]},brackets:[["{","}"],["[","]"],["(",")"]],autoClosingPairs:[{open:"{",close:"}"},{open:"[",close:"]"},{open:"(",close:")"},{open:'"',close:'"'},{open:"'",close:"'"}],surroundingPairs:[{open:"{",close:"}"},{open:"[",close:"]"},{open:"(",close:")"},{open:'"',close:'"'},{open:"'",close:"'"}]},$_t={defaultToken:"",tokenPostfix:".sql",ignoreCase:!0,brackets:[{open:"[",close:"]",token:"delimiter.square"},{open:"(",close:")",token:"delimiter.parenthesis"}],keywords:["AES128","AES256","ALL","ALLOWOVERWRITE","ANALYSE","ANALYZE","AND","ANY","ARRAY","AS","ASC","AUTHORIZATION","AZ64","BACKUP","BETWEEN","BINARY","BLANKSASNULL","BOTH","BYTEDICT","BZIP2","CASE","CAST","CHECK","COLLATE","COLUMN","CONSTRAINT","CREATE","CREDENTIALS","CROSS","CURRENT_DATE","CURRENT_TIME","CURRENT_TIMESTAMP","CURRENT_USER","CURRENT_USER_ID","DEFAULT","DEFERRABLE","DEFLATE","DEFRAG","DELTA","DELTA32K","DESC","DISABLE","DISTINCT","DO","ELSE","EMPTYASNULL","ENABLE","ENCODE","ENCRYPT","ENCRYPTION","END","EXCEPT","EXPLICIT","FALSE","FOR","FOREIGN","FREEZE","FROM","FULL","GLOBALDICT256","GLOBALDICT64K","GRANT","GROUP","GZIP","HAVING","IDENTITY","IGNORE","ILIKE","IN","INITIALLY","INNER","INTERSECT","INTO","IS","ISNULL","JOIN","LANGUAGE","LEADING","LEFT","LIKE","LIMIT","LOCALTIME","LOCALTIMESTAMP","LUN","LUNS","LZO","LZOP","MINUS","MOSTLY16","MOSTLY32","MOSTLY8","NATURAL","NEW","NOT","NOTNULL","NULL","NULLS","OFF","OFFLINE","OFFSET","OID","OLD","ON","ONLY","OPEN","OR","ORDER","OUTER","OVERLAPS","PARALLEL","PARTITION","PERCENT","PERMISSIONS","PLACING","PRIMARY","RAW","READRATIO","RECOVER","REFERENCES","RESPECT","REJECTLOG","RESORT","RESTORE","RIGHT","SELECT","SESSION_USER","SIMILAR","SNAPSHOT","SOME","SYSDATE","SYSTEM","TABLE","TAG","TDES","TEXT255","TEXT32K","THEN","TIMESTAMP","TO","TOP","TRAILING","TRUE","TRUNCATECOLUMNS","UNION","UNIQUE","USER","USING","VERBOSE","WALLET","WHEN","WHERE","WITH","WITHOUT"],operators:["AND","BETWEEN","IN","LIKE","NOT","OR","IS","NULL","INTERSECT","UNION","INNER","JOIN","LEFT","OUTER","RIGHT"],builtinFunctions:["current_schema","current_schemas","has_database_privilege","has_schema_privilege","has_table_privilege","age","current_time","current_timestamp","localtime","isfinite","now","ascii","get_bit","get_byte","set_bit","set_byte","to_ascii","approximate percentile_disc","avg","count","listagg","max","median","min","percentile_cont","stddev_samp","stddev_pop","sum","var_samp","var_pop","bit_and","bit_or","bool_and","bool_or","cume_dist","first_value","lag","last_value","lead","nth_value","ratio_to_report","dense_rank","ntile","percent_rank","rank","row_number","case","coalesce","decode","greatest","least","nvl","nvl2","nullif","add_months","at time zone","convert_timezone","current_date","date_cmp","date_cmp_timestamp","date_cmp_timestamptz","date_part_year","dateadd","datediff","date_part","date_trunc","extract","getdate","interval_cmp","last_day","months_between","next_day","sysdate","timeofday","timestamp_cmp","timestamp_cmp_date","timestamp_cmp_timestamptz","timestamptz_cmp","timestamptz_cmp_date","timestamptz_cmp_timestamp","timezone","to_timestamp","trunc","abs","acos","asin","atan","atan2","cbrt","ceil","ceiling","checksum","cos","cot","degrees","dexp","dlog1","dlog10","exp","floor","ln","log","mod","pi","power","radians","random","round","sin","sign","sqrt","tan","to_hex","bpcharcmp","btrim","bttext_pattern_cmp","char_length","character_length","charindex","chr","concat","crc32","func_sha1","initcap","left and rights","len","length","lower","lpad and rpads","ltrim","md5","octet_length","position","quote_ident","quote_literal","regexp_count","regexp_instr","regexp_replace","regexp_substr","repeat","replace","replicate","reverse","rtrim","split_part","strpos","strtol","substring","textlen","translate","trim","upper","cast","convert","to_char","to_date","to_number","json_array_length","json_extract_array_element_text","json_extract_path_text","current_setting","pg_cancel_backend","pg_terminate_backend","set_config","current_database","current_user","current_user_id","pg_backend_pid","pg_last_copy_count","pg_last_copy_id","pg_last_query_id","pg_last_unload_count","session_user","slice_num","user","version","abbrev","acosd","any","area","array_agg","array_append","array_cat","array_dims","array_fill","array_length","array_lower","array_ndims","array_position","array_positions","array_prepend","array_remove","array_replace","array_to_json","array_to_string","array_to_tsvector","array_upper","asind","atan2d","atand","bit","bit_length","bound_box","box","brin_summarize_new_values","broadcast","cardinality","center","circle","clock_timestamp","col_description","concat_ws","convert_from","convert_to","corr","cosd","cotd","covar_pop","covar_samp","current_catalog","current_query","current_role","currval","cursor_to_xml","diameter","div","encode","enum_first","enum_last","enum_range","every","family","format","format_type","generate_series","generate_subscripts","get_current_ts_config","gin_clean_pending_list","grouping","has_any_column_privilege","has_column_privilege","has_foreign_data_wrapper_privilege","has_function_privilege","has_language_privilege","has_sequence_privilege","has_server_privilege","has_tablespace_privilege","has_type_privilege","height","host","hostmask","inet_client_addr","inet_client_port","inet_merge","inet_same_family","inet_server_addr","inet_server_port","isclosed","isempty","isopen","json_agg","json_object","json_object_agg","json_populate_record","json_populate_recordset","json_to_record","json_to_recordset","jsonb_agg","jsonb_object_agg","justify_days","justify_hours","justify_interval","lastval","left","line","localtimestamp","lower_inc","lower_inf","lpad","lseg","make_date","make_interval","make_time","make_timestamp","make_timestamptz","masklen","mode","netmask","network","nextval","npoints","num_nonnulls","num_nulls","numnode","obj_description","overlay","parse_ident","path","pclose","percentile_disc","pg_advisory_lock","pg_advisory_lock_shared","pg_advisory_unlock","pg_advisory_unlock_all","pg_advisory_unlock_shared","pg_advisory_xact_lock","pg_advisory_xact_lock_shared","pg_backup_start_time","pg_blocking_pids","pg_client_encoding","pg_collation_is_visible","pg_column_size","pg_conf_load_time","pg_control_checkpoint","pg_control_init","pg_control_recovery","pg_control_system","pg_conversion_is_visible","pg_create_logical_replication_slot","pg_create_physical_replication_slot","pg_create_restore_point","pg_current_xlog_flush_location","pg_current_xlog_insert_location","pg_current_xlog_location","pg_database_size","pg_describe_object","pg_drop_replication_slot","pg_export_snapshot","pg_filenode_relation","pg_function_is_visible","pg_get_constraintdef","pg_get_expr","pg_get_function_arguments","pg_get_function_identity_arguments","pg_get_function_result","pg_get_functiondef","pg_get_indexdef","pg_get_keywords","pg_get_object_address","pg_get_owned_sequence","pg_get_ruledef","pg_get_serial_sequence","pg_get_triggerdef","pg_get_userbyid","pg_get_viewdef","pg_has_role","pg_identify_object","pg_identify_object_as_address","pg_index_column_has_property","pg_index_has_property","pg_indexam_has_property","pg_indexes_size","pg_is_in_backup","pg_is_in_recovery","pg_is_other_temp_schema","pg_is_xlog_replay_paused","pg_last_committed_xact","pg_last_xact_replay_timestamp","pg_last_xlog_receive_location","pg_last_xlog_replay_location","pg_listening_channels","pg_logical_emit_message","pg_logical_slot_get_binary_changes","pg_logical_slot_get_changes","pg_logical_slot_peek_binary_changes","pg_logical_slot_peek_changes","pg_ls_dir","pg_my_temp_schema","pg_notification_queue_usage","pg_opclass_is_visible","pg_operator_is_visible","pg_opfamily_is_visible","pg_options_to_table","pg_postmaster_start_time","pg_read_binary_file","pg_read_file","pg_relation_filenode","pg_relation_filepath","pg_relation_size","pg_reload_conf","pg_replication_origin_create","pg_replication_origin_drop","pg_replication_origin_oid","pg_replication_origin_progress","pg_replication_origin_session_is_setup","pg_replication_origin_session_progress","pg_replication_origin_session_reset","pg_replication_origin_session_setup","pg_replication_origin_xact_reset","pg_replication_origin_xact_setup","pg_rotate_logfile","pg_size_bytes","pg_size_pretty","pg_sleep","pg_sleep_for","pg_sleep_until","pg_start_backup","pg_stat_file","pg_stop_backup","pg_switch_xlog","pg_table_is_visible","pg_table_size","pg_tablespace_databases","pg_tablespace_location","pg_tablespace_size","pg_total_relation_size","pg_trigger_depth","pg_try_advisory_lock","pg_try_advisory_lock_shared","pg_try_advisory_xact_lock","pg_try_advisory_xact_lock_shared","pg_ts_config_is_visible","pg_ts_dict_is_visible","pg_ts_parser_is_visible","pg_ts_template_is_visible","pg_type_is_visible","pg_typeof","pg_xact_commit_timestamp","pg_xlog_location_diff","pg_xlog_replay_pause","pg_xlog_replay_resume","pg_xlogfile_name","pg_xlogfile_name_offset","phraseto_tsquery","plainto_tsquery","point","polygon","popen","pqserverversion","query_to_xml","querytree","quote_nullable","radius","range_merge","regexp_matches","regexp_split_to_array","regexp_split_to_table","regr_avgx","regr_avgy","regr_count","regr_intercept","regr_r2","regr_slope","regr_sxx","regr_sxy","regr_syy","right","row_security_active","row_to_json","rpad","scale","set_masklen","setseed","setval","setweight","shobj_description","sind","sprintf","statement_timestamp","stddev","string_agg","string_to_array","strip","substr","table_to_xml","table_to_xml_and_xmlschema","tand","text","to_json","to_regclass","to_regnamespace","to_regoper","to_regoperator","to_regproc","to_regprocedure","to_regrole","to_regtype","to_tsquery","to_tsvector","transaction_timestamp","ts_debug","ts_delete","ts_filter","ts_headline","ts_lexize","ts_parse","ts_rank","ts_rank_cd","ts_rewrite","ts_stat","ts_token_type","tsquery_phrase","tsvector_to_array","tsvector_update_trigger","tsvector_update_trigger_column","txid_current","txid_current_snapshot","txid_snapshot_xip","txid_snapshot_xmax","txid_snapshot_xmin","txid_visible_in_snapshot","unnest","upper_inc","upper_inf","variance","width","width_bucket","xml_is_well_formed","xml_is_well_formed_content","xml_is_well_formed_document","xmlagg","xmlcomment","xmlconcat","xmlelement","xmlexists","xmlforest","xmlparse","xmlpi","xmlroot","xmlserialize","xpath","xpath_exists"],builtinVariables:[],pseudoColumns:[],tokenizer:{root:[{include:"@comments"},{include:"@whitespace"},{include:"@pseudoColumns"},{include:"@numbers"},{include:"@strings"},{include:"@complexIdentifiers"},{include:"@scopes"},[/[;,.]/,"delimiter"],[/[()]/,"@brackets"],[/[\w@#$]+/,{cases:{"@keywords":"keyword","@operators":"operator","@builtinVariables":"predefined","@builtinFunctions":"predefined","@default":"identifier"}}],[/[<>=!%&+\-*/|~^]/,"operator"]],whitespace:[[/\s+/,"white"]],comments:[[/--+.*/,"comment"],[/\/\*/,{token:"comment.quote",next:"@comment"}]],comment:[[/[^*/]+/,"comment"],[/\*\//,{token:"comment.quote",next:"@pop"}],[/./,"comment"]],pseudoColumns:[[/[$][A-Za-z_][\w@#$]*/,{cases:{"@pseudoColumns":"predefined","@default":"identifier"}}]],numbers:[[/0[xX][0-9a-fA-F]*/,"number"],[/[$][+-]*\d*(\.\d*)?/,"number"],[/((\d+(\.\d*)?)|(\.\d+))([eE][\-+]?\d+)?/,"number"]],strings:[[/'/,{token:"string",next:"@string"}]],string:[[/[^']+/,"string"],[/''/,"string"],[/'/,{token:"string",next:"@pop"}]],complexIdentifiers:[[/"/,{token:"identifier.quote",next:"@quotedIdentifier"}]],quotedIdentifier:[[/[^"]+/,"identifier"],[/""/,"identifier"],[/"/,{token:"identifier.quote",next:"@pop"}]],scopes:[]}}});var m7e={};st(m7e,{conf:()=>j_t,language:()=>q_t});var j_t,q_t,g7e=k(()=>{j_t={brackets:[["{","}"],["[","]"],["(",")"]],autoClosingPairs:[{open:"{",close:"}"},{open:"[",close:"]"},{open:"(",close:")"},{open:"<",close:">",notIn:["string"]}],surroundingPairs:[{open:"(",close:")"},{open:"[",close:"]"},{open:"`",close:"`"}],folding:{markers:{start:new RegExp("^\\s*"),end:new RegExp("^\\s*")}}},q_t={defaultToken:"",tokenPostfix:".rst",control:/[\\`*_\[\]{}()#+\-\.!]/,escapes:/\\(?:@control)/,empty:["area","base","basefont","br","col","frame","hr","img","input","isindex","link","meta","param"],alphanumerics:/[A-Za-z0-9]/,simpleRefNameWithoutBq:/(?:@alphanumerics[-_+:.]*@alphanumerics)+|(?:@alphanumerics+)/,simpleRefName:/(?:`@phrase`|@simpleRefNameWithoutBq)/,phrase:/@simpleRefNameWithoutBq(?:\s@simpleRefNameWithoutBq)*/,citationName:/[A-Za-z][A-Za-z0-9-_.]*/,blockLiteralStart:/(?:[!"#$%&'()*+,-./:;<=>?@\[\]^_`{|}~]|[\s])/,precedingChars:/(?:[ -:/'"<([{])/,followingChars:/(?:[ -.,:;!?/'")\]}>]|$)/,punctuation:/(=|-|~|`|#|"|\^|\+|\*|:|\.|'|_|\+)/,tokenizer:{root:[[/^(@punctuation{3,}$){1,1}?/,"keyword"],[/^\s*([\*\-+‣•]|[a-zA-Z0-9]+\.|\([a-zA-Z0-9]+\)|[a-zA-Z0-9]+\))\s/,"keyword"],[/([ ]::)\s*$/,"keyword","@blankLineOfLiteralBlocks"],[/(::)\s*$/,"keyword","@blankLineOfLiteralBlocks"],{include:"@tables"},{include:"@explicitMarkupBlocks"},{include:"@inlineMarkup"}],explicitMarkupBlocks:[{include:"@citations"},{include:"@footnotes"},[/^(\.\.\s)(@simpleRefName)(::\s)(.*)$/,[{token:"",next:"subsequentLines"},"keyword","",""]],[/^(\.\.)(\s+)(_)(@simpleRefName)(:)(\s+)(.*)/,[{token:"",next:"hyperlinks"},"","","string.link","","","string.link"]],[/^((?:(?:\.\.)(?:\s+))?)(__)(:)(\s+)(.*)/,[{token:"",next:"subsequentLines"},"","","","string.link"]],[/^(__\s+)(.+)/,["","string.link"]],[/^(\.\.)( \|)([^| ]+[^|]*[^| ]*)(\| )(@simpleRefName)(:: .*)/,[{token:"",next:"subsequentLines"},"","string.link","","keyword",""],"@rawBlocks"],[/(\|)([^| ]+[^|]*[^| ]*)(\|_{0,2})/,["","string.link",""]],[/^(\.\.)([ ].*)$/,[{token:"",next:"@comments"},"comment"]]],inlineMarkup:[{include:"@citationsReference"},{include:"@footnotesReference"},[/(@simpleRefName)(_{1,2})/,["string.link",""]],[/(`)([^<`]+\s+)(<)(.*)(>)(`)(_)/,["","string.link","","string.link","","",""]],[/\*\*([^\\*]|\*(?!\*))+\*\*/,"strong"],[/\*[^*]+\*/,"emphasis"],[/(``)((?:[^`]|\`(?!`))+)(``)/,["","keyword",""]],[/(__\s+)(.+)/,["","keyword"]],[/(:)((?:@simpleRefNameWithoutBq)?)(:`)([^`]+)(`)/,["","keyword","","",""]],[/(`)([^`]+)(`:)((?:@simpleRefNameWithoutBq)?)(:)/,["","","","keyword",""]],[/(`)([^`]+)(`)/,""],[/(_`)(@phrase)(`)/,["","string.link",""]]],citations:[[/^(\.\.\s+\[)((?:@citationName))(\]\s+)(.*)/,[{token:"",next:"@subsequentLines"},"string.link","",""]]],citationsReference:[[/(\[)(@citationName)(\]_)/,["","string.link",""]]],footnotes:[[/^(\.\.\s+\[)((?:[0-9]+))(\]\s+.*)/,[{token:"",next:"@subsequentLines"},"string.link",""]],[/^(\.\.\s+\[)((?:#@simpleRefName?))(\]\s+)(.*)/,[{token:"",next:"@subsequentLines"},"string.link","",""]],[/^(\.\.\s+\[)((?:\*))(\]\s+)(.*)/,[{token:"",next:"@subsequentLines"},"string.link","",""]]],footnotesReference:[[/(\[)([0-9]+)(\])(_)/,["","string.link","",""]],[/(\[)(#@simpleRefName?)(\])(_)/,["","string.link","",""]],[/(\[)(\*)(\])(_)/,["","string.link","",""]]],blankLineOfLiteralBlocks:[[/^$/,"","@subsequentLinesOfLiteralBlocks"],[/^.*$/,"","@pop"]],subsequentLinesOfLiteralBlocks:[[/(@blockLiteralStart+)(.*)/,["keyword",""]],[/^(?!blockLiteralStart)/,"","@popall"]],subsequentLines:[[/^[\s]+.*/,""],[/^(?!\s)/,"","@pop"]],hyperlinks:[[/^[\s]+.*/,"string.link"],[/^(?!\s)/,"","@pop"]],comments:[[/^[\s]+.*/,"comment"],[/^(?!\s)/,"","@pop"]],tables:[[/\+-[+-]+/,"keyword"],[/\+=[+=]+/,"keyword"]]}}});var _7e={};st(_7e,{conf:()=>K_t,language:()=>G_t});var K_t,G_t,b7e=k(()=>{K_t={comments:{lineComment:"#",blockComment:["=begin","=end"]},brackets:[["(",")"],["{","}"],["[","]"]],autoClosingPairs:[{open:"{",close:"}"},{open:"[",close:"]"},{open:"(",close:")"},{open:'"',close:'"'},{open:"'",close:"'"}],surroundingPairs:[{open:"{",close:"}"},{open:"[",close:"]"},{open:"(",close:")"},{open:'"',close:'"'},{open:"'",close:"'"}],indentationRules:{increaseIndentPattern:new RegExp(`^\\s*((begin|class|(private|protected)\\s+def|def|else|elsif|ensure|for|if|module|rescue|unless|until|when|while|case)|([^#]*\\sdo\\b)|([^#]*=\\s*(case|if|unless)))\\b([^#\\{;]|("|'|/).*\\4)*(#.*)?$`),decreaseIndentPattern:new RegExp("^\\s*([}\\]]([,)]?\\s*(#|$)|\\.[a-zA-Z_]\\w*\\b)|(end|rescue|ensure|else|elsif|when)\\b)")}},G_t={tokenPostfix:".ruby",keywords:["__LINE__","__ENCODING__","__FILE__","BEGIN","END","alias","and","begin","break","case","class","def","defined?","do","else","elsif","end","ensure","for","false","if","in","module","next","nil","not","or","redo","rescue","retry","return","self","super","then","true","undef","unless","until","when","while","yield"],keywordops:["::","..","...","?",":","=>"],builtins:["require","public","private","include","extend","attr_reader","protected","private_class_method","protected_class_method","new"],declarations:["module","class","def","case","do","begin","for","if","while","until","unless"],linedecls:["def","case","do","begin","for","if","while","until","unless"],operators:["^","&","|","<=>","==","===","!~","=~",">",">=","<","<=","<<",">>","+","-","*","/","%","**","~","+@","-@","[]","[]=","`","+=","-=","*=","**=","/=","^=","%=","<<=",">>=","&=","&&=","||=","|="],brackets:[{open:"(",close:")",token:"delimiter.parenthesis"},{open:"{",close:"}",token:"delimiter.curly"},{open:"[",close:"]",token:"delimiter.square"}],symbols:/[=>"}],[/%([qws])(@delim)/,{token:"string.$1.delim",switchTo:"@qstring.$1.$2.$2"}],[/%r\(/,{token:"regexp.delim",switchTo:"@pregexp.(.)"}],[/%r\[/,{token:"regexp.delim",switchTo:"@pregexp.[.]"}],[/%r\{/,{token:"regexp.delim",switchTo:"@pregexp.{.}"}],[/%r"}],[/%r(@delim)/,{token:"regexp.delim",switchTo:"@pregexp.$1.$1"}],[/%(x|W|Q?)\(/,{token:"string.$1.delim",switchTo:"@qqstring.$1.(.)"}],[/%(x|W|Q?)\[/,{token:"string.$1.delim",switchTo:"@qqstring.$1.[.]"}],[/%(x|W|Q?)\{/,{token:"string.$1.delim",switchTo:"@qqstring.$1.{.}"}],[/%(x|W|Q?)"}],[/%(x|W|Q?)(@delim)/,{token:"string.$1.delim",switchTo:"@qqstring.$1.$2.$2"}],[/%([rqwsxW]|Q?)./,{token:"invalid",next:"@pop"}],[/./,{token:"invalid",next:"@pop"}]],qstring:[[/\\$/,"string.$S2.escape"],[/\\./,"string.$S2.escape"],[/./,{cases:{"$#==$S4":{token:"string.$S2.delim",next:"@pop"},"$#==$S3":{token:"string.$S2.delim",next:"@push"},"@default":"string.$S2"}}]],qqstring:[[/#/,"string.$S2.escape","@interpolated"],{include:"@qstring"}],whitespace:[[/[ \t\r\n]+/,""],[/^\s*=begin\b/,"comment","@comment"],[/#.*$/,"comment"]],comment:[[/[^=]+/,"comment"],[/^\s*=begin\b/,"comment.invalid"],[/^\s*=end\b.*/,"comment","@pop"],[/[=]/,"comment"]]}}});var v7e={};st(v7e,{conf:()=>Y_t,language:()=>Z_t});var Y_t,Z_t,x7e=k(()=>{Y_t={comments:{lineComment:"//",blockComment:["/*","*/"]},brackets:[["{","}"],["[","]"],["(",")"]],autoClosingPairs:[{open:"[",close:"]"},{open:"{",close:"}"},{open:"(",close:")"},{open:'"',close:'"',notIn:["string"]}],surroundingPairs:[{open:"{",close:"}"},{open:"[",close:"]"},{open:"(",close:")"},{open:'"',close:'"'},{open:"'",close:"'"}],folding:{markers:{start:new RegExp("^\\s*#pragma\\s+region\\b"),end:new RegExp("^\\s*#pragma\\s+endregion\\b")}}},Z_t={tokenPostfix:".rust",defaultToken:"invalid",keywords:["as","async","await","box","break","const","continue","crate","dyn","else","enum","extern","false","fn","for","if","impl","in","let","loop","match","mod","move","mut","pub","ref","return","self","static","struct","super","trait","true","try","type","unsafe","use","where","while","catch","default","union","static","abstract","alignof","become","do","final","macro","offsetof","override","priv","proc","pure","sizeof","typeof","unsized","virtual","yield"],typeKeywords:["Self","m32","m64","m128","f80","f16","f128","int","uint","float","char","bool","u8","u16","u32","u64","f32","f64","i8","i16","i32","i64","str","Option","Either","c_float","c_double","c_void","FILE","fpos_t","DIR","dirent","c_char","c_schar","c_uchar","c_short","c_ushort","c_int","c_uint","c_long","c_ulong","size_t","ptrdiff_t","clock_t","time_t","c_longlong","c_ulonglong","intptr_t","uintptr_t","off_t","dev_t","ino_t","pid_t","mode_t","ssize_t"],constants:["true","false","Some","None","Left","Right","Ok","Err"],supportConstants:["EXIT_FAILURE","EXIT_SUCCESS","RAND_MAX","EOF","SEEK_SET","SEEK_CUR","SEEK_END","_IOFBF","_IONBF","_IOLBF","BUFSIZ","FOPEN_MAX","FILENAME_MAX","L_tmpnam","TMP_MAX","O_RDONLY","O_WRONLY","O_RDWR","O_APPEND","O_CREAT","O_EXCL","O_TRUNC","S_IFIFO","S_IFCHR","S_IFBLK","S_IFDIR","S_IFREG","S_IFMT","S_IEXEC","S_IWRITE","S_IREAD","S_IRWXU","S_IXUSR","S_IWUSR","S_IRUSR","F_OK","R_OK","W_OK","X_OK","STDIN_FILENO","STDOUT_FILENO","STDERR_FILENO"],supportMacros:["format!","print!","println!","panic!","format_args!","unreachable!","write!","writeln!"],operators:["!","!=","%","%=","&","&=","&&","*","*=","+","+=","-","-=","->",".","..","...","/","/=",":",";","<<","<<=","<","<=","=","==","=>",">",">=",">>",">>=","@","^","^=","|","|=","||","_","?","#"],escapes:/\\([nrt0\"''\\]|x\h{2}|u\{\h{1,6}\})/,delimiters:/[,]/,symbols:/[\#\!\%\&\*\+\-\.\/\:\;\<\=\>\@\^\|_\?]+/,intSuffixes:/[iu](8|16|32|64|128|size)/,floatSuffixes:/f(32|64)/,tokenizer:{root:[[/r(#*)"/,{token:"string.quote",bracket:"@open",next:"@stringraw.$1"}],[/[a-zA-Z][a-zA-Z0-9_]*!?|_[a-zA-Z0-9_]+/,{cases:{"@typeKeywords":"keyword.type","@keywords":"keyword","@supportConstants":"keyword","@supportMacros":"keyword","@constants":"keyword","@default":"identifier"}}],[/\$/,"identifier"],[/'[a-zA-Z_][a-zA-Z0-9_]*(?=[^\'])/,"identifier"],[/'(\S|@escapes)'/,"string.byteliteral"],[/"/,{token:"string.quote",bracket:"@open",next:"@string"}],{include:"@numbers"},{include:"@whitespace"},[/@delimiters/,{cases:{"@keywords":"keyword","@default":"delimiter"}}],[/[{}()\[\]<>]/,"@brackets"],[/@symbols/,{cases:{"@operators":"operator","@default":""}}]],whitespace:[[/[ \t\r\n]+/,"white"],[/\/\*/,"comment","@comment"],[/\/\/.*$/,"comment"]],comment:[[/[^\/*]+/,"comment"],[/\/\*/,"comment","@push"],["\\*/","comment","@pop"],[/[\/*]/,"comment"]],string:[[/[^\\"]+/,"string"],[/@escapes/,"string.escape"],[/\\./,"string.escape.invalid"],[/"/,{token:"string.quote",bracket:"@close",next:"@pop"}]],stringraw:[[/[^"#]+/,{token:"string"}],[/"(#*)/,{cases:{"$1==$S2":{token:"string.quote",bracket:"@close",next:"@pop"},"@default":{token:"string"}}}],[/["#]/,{token:"string"}]],numbers:[[/(0o[0-7_]+)(@intSuffixes)?/,{token:"number"}],[/(0b[0-1_]+)(@intSuffixes)?/,{token:"number"}],[/[\d][\d_]*(\.[\d][\d_]*)?[eE][+-][\d_]+(@floatSuffixes)?/,{token:"number"}],[/\b(\d\.?[\d_]*)(@floatSuffixes)?\b/,{token:"number"}],[/(0x[\da-fA-F]+)_?(@intSuffixes)?/,{token:"number"}],[/[\d][\d_]*(@intSuffixes?)?/,{token:"number"}]]}}});var w7e={};st(w7e,{conf:()=>X_t,language:()=>Q_t});var X_t,Q_t,y7e=k(()=>{X_t={comments:{lineComment:"'"},brackets:[["(",")"],["[","]"],["If","EndIf"],["While","EndWhile"],["For","EndFor"],["Sub","EndSub"]],autoClosingPairs:[{open:'"',close:'"',notIn:["string","comment"]},{open:"(",close:")",notIn:["string","comment"]},{open:"[",close:"]",notIn:["string","comment"]}]},Q_t={defaultToken:"",tokenPostfix:".sb",ignoreCase:!0,brackets:[{token:"delimiter.array",open:"[",close:"]"},{token:"delimiter.parenthesis",open:"(",close:")"},{token:"keyword.tag-if",open:"If",close:"EndIf"},{token:"keyword.tag-while",open:"While",close:"EndWhile"},{token:"keyword.tag-for",open:"For",close:"EndFor"},{token:"keyword.tag-sub",open:"Sub",close:"EndSub"}],keywords:["Else","ElseIf","EndFor","EndIf","EndSub","EndWhile","For","Goto","If","Step","Sub","Then","To","While"],tagwords:["If","Sub","While","For"],operators:[">","<","<>","<=",">=","And","Or","+","-","*","/","="],identifier:/[a-zA-Z_][\w]*/,symbols:/[=><:+\-*\/%\.,]+/,escapes:/\\(?:[abfnrtv\\"']|x[0-9A-Fa-f]{1,4}|u[0-9A-Fa-f]{4}|U[0-9A-Fa-f]{8})/,tokenizer:{root:[{include:"@whitespace"},[/(@identifier)(?=[.])/,"type"],[/@identifier/,{cases:{"@keywords":{token:"keyword.$0"},"@operators":"operator","@default":"variable.name"}}],[/([.])(@identifier)/,{cases:{$2:["delimiter","type.member"],"@default":""}}],[/\d*\.\d+/,"number.float"],[/\d+/,"number"],[/[()\[\]]/,"@brackets"],[/@symbols/,{cases:{"@operators":"operator","@default":"delimiter"}}],[/"([^"\\]|\\.)*$/,"string.invalid"],[/"/,"string","@string"]],whitespace:[[/[ \t\r\n]+/,""],[/(\').*$/,"comment"]],string:[[/[^\\"]+/,"string"],[/@escapes/,"string.escape"],[/\\./,"string.escape.invalid"],[/"C?/,"string","@pop"]]}}});var C7e={};st(C7e,{conf:()=>J_t,language:()=>ebt});var J_t,ebt,S7e=k(()=>{J_t={wordPattern:/(unary_[@~!#%^&*()\-=+\\|:<>\/?]+)|([a-zA-Z_$][\w$]*?_=)|(`[^`]+`)|([a-zA-Z_$][\w$]*)/g,comments:{lineComment:"//",blockComment:["/*","*/"]},brackets:[["{","}"],["[","]"],["(",")"]],autoClosingPairs:[{open:"{",close:"}"},{open:"[",close:"]"},{open:"(",close:")"},{open:'"',close:'"'},{open:"'",close:"'"}],surroundingPairs:[{open:"{",close:"}"},{open:"[",close:"]"},{open:"(",close:")"},{open:'"',close:'"'},{open:"'",close:"'"}],folding:{markers:{start:new RegExp("^\\s*//\\s*(?:(?:#?region\\b)|(?:))")}}},ebt={tokenPostfix:".scala",keywords:["asInstanceOf","catch","class","classOf","def","do","else","extends","finally","for","foreach","forSome","if","import","isInstanceOf","macro","match","new","object","package","return","throw","trait","try","type","until","val","var","while","with","yield","given","enum","then"],softKeywords:["as","export","extension","end","derives","on"],constants:["true","false","null","this","super"],modifiers:["abstract","final","implicit","lazy","override","private","protected","sealed"],softModifiers:["inline","opaque","open","transparent","using"],name:/(?:[a-z_$][\w$]*|`[^`]+`)/,type:/(?:[A-Z][\w$]*)/,symbols:/[=>))/,["@brackets","white","variable"]],[/@name/,{cases:{"@keywords":"keyword","@softKeywords":"keyword","@modifiers":"keyword.modifier","@softModifiers":"keyword.modifier","@constants":{token:"constant",next:"@allowMethod"},"@default":{token:"identifier",next:"@allowMethod"}}}],[/@type/,"type","@allowMethod"],{include:"@whitespace"},[/@[a-zA-Z_$][\w$]*(?:\.[a-zA-Z_$][\w$]*)*/,"annotation"],[/[{(]/,"@brackets"],[/[})]/,"@brackets","@allowMethod"],[/\[/,"operator.square"],[/](?!\s*(?:va[rl]|def|type)\b)/,"operator.square","@allowMethod"],[/]/,"operator.square"],[/([=-]>|<-|>:|<:|:>|<%)(?=[\s\w()[\]{},\."'`])/,"keyword"],[/@symbols/,"operator"],[/[;,\.]/,"delimiter"],[/'[a-zA-Z$][\w$]*(?!')/,"attribute.name"],[/'[^\\']'/,"string","@allowMethod"],[/(')(@escapes)(')/,["string","string.escape",{token:"string",next:"@allowMethod"}]],[/'/,"string.invalid"]],import:[[/;/,"delimiter","@pop"],[/^|$/,"","@pop"],[/[ \t]+/,"white"],[/[\n\r]+/,"white","@pop"],[/\/\*/,"comment","@comment"],[/@name|@type/,"type"],[/[(){}]/,"@brackets"],[/[[\]]/,"operator.square"],[/[\.,]/,"delimiter"]],allowMethod:[[/^|$/,"","@pop"],[/[ \t]+/,"white"],[/[\n\r]+/,"white","@pop"],[/\/\*/,"comment","@comment"],[/(?==>[\s\w([{])/,"keyword","@pop"],[/(@name|@symbols)(?=[ \t]*[[({"'`]|[ \t]+(?:[+-]?\.?\d|\w))/,{cases:{"@keywords":{token:"keyword",next:"@pop"},"->|<-|>:|<:|<%":{token:"keyword",next:"@pop"},"@default":{token:"@rematch",next:"@pop"}}}],["","","@pop"]],comment:[[/[^\/*]+/,"comment"],[/\/\*/,"comment","@push"],[/\*\//,"comment","@pop"],[/[\/*]/,"comment"]],case:[[/\b_\*/,"key"],[/\b(_|true|false|null|this|super)\b/,"keyword","@allowMethod"],[/\bif\b|=>/,"keyword","@pop"],[/`[^`]+`/,"identifier","@allowMethod"],[/@name/,"variable","@allowMethod"],[/:::?|\||@(?![a-z_$])/,"keyword"],{include:"@root"}],vardef:[[/\b_\*/,"key"],[/\b(_|true|false|null|this|super)\b/,"keyword"],[/@name/,"variable"],[/:::?|\||@(?![a-z_$])/,"keyword"],[/=|:(?!:)/,"operator","@pop"],[/$/,"white","@pop"],{include:"@root"}],string:[[/[^\\"\n\r]+/,"string"],[/@escapes/,"string.escape"],[/\\./,"string.escape.invalid"],[/"/,{token:"string.quote",bracket:"@close",switchTo:"@allowMethod"}]],stringt:[[/[^\\"\n\r]+/,"string"],[/@escapes/,"string.escape"],[/\\./,"string.escape.invalid"],[/"(?=""")/,"string"],[/"""/,{token:"string.quote",bracket:"@close",switchTo:"@allowMethod"}],[/"/,"string"]],fstring:[[/@escapes/,"string.escape"],[/"/,{token:"string.quote",bracket:"@close",switchTo:"@allowMethod"}],[/\$\$/,"string"],[/(\$)([a-z_]\w*)/,["operator","identifier"]],[/\$\{/,"operator","@interp"],[/%%/,"string"],[/(%)([\-#+ 0,(])(\d+|\.\d+|\d+\.\d+)(@fstring_conv)/,["metatag","keyword.modifier","number","metatag"]],[/(%)(\d+|\.\d+|\d+\.\d+)(@fstring_conv)/,["metatag","number","metatag"]],[/(%)([\-#+ 0,(])(@fstring_conv)/,["metatag","keyword.modifier","metatag"]],[/(%)(@fstring_conv)/,["metatag","metatag"]],[/./,"string"]],fstringt:[[/@escapes/,"string.escape"],[/"(?=""")/,"string"],[/"""/,{token:"string.quote",bracket:"@close",switchTo:"@allowMethod"}],[/\$\$/,"string"],[/(\$)([a-z_]\w*)/,["operator","identifier"]],[/\$\{/,"operator","@interp"],[/%%/,"string"],[/(%)([\-#+ 0,(])(\d+|\.\d+|\d+\.\d+)(@fstring_conv)/,["metatag","keyword.modifier","number","metatag"]],[/(%)(\d+|\.\d+|\d+\.\d+)(@fstring_conv)/,["metatag","number","metatag"]],[/(%)([\-#+ 0,(])(@fstring_conv)/,["metatag","keyword.modifier","metatag"]],[/(%)(@fstring_conv)/,["metatag","metatag"]],[/./,"string"]],sstring:[[/@escapes/,"string.escape"],[/"/,{token:"string.quote",bracket:"@close",switchTo:"@allowMethod"}],[/\$\$/,"string"],[/(\$)([a-z_]\w*)/,["operator","identifier"]],[/\$\{/,"operator","@interp"],[/./,"string"]],sstringt:[[/@escapes/,"string.escape"],[/"(?=""")/,"string"],[/"""/,{token:"string.quote",bracket:"@close",switchTo:"@allowMethod"}],[/\$\$/,"string"],[/(\$)([a-z_]\w*)/,["operator","identifier"]],[/\$\{/,"operator","@interp"],[/./,"string"]],interp:[[/{/,"operator","@push"],[/}/,"operator","@pop"],{include:"@root"}],rawstring:[[/[^"]/,"string"],[/"/,{token:"string.quote",bracket:"@close",switchTo:"@allowMethod"}]],rawstringt:[[/[^"]/,"string"],[/"(?=""")/,"string"],[/"""/,{token:"string.quote",bracket:"@close",switchTo:"@allowMethod"}],[/"/,"string"]],whitespace:[[/[ \t\r\n]+/,"white"],[/\/\*/,"comment","@comment"],[/\/\/.*$/,"comment"]]}}});var k7e={};st(k7e,{conf:()=>tbt,language:()=>ibt});var tbt,ibt,L7e=k(()=>{tbt={comments:{lineComment:";",blockComment:["#|","|#"]},brackets:[["(",")"],["{","}"],["[","]"]],autoClosingPairs:[{open:"{",close:"}"},{open:"[",close:"]"},{open:"(",close:")"},{open:'"',close:'"'}],surroundingPairs:[{open:"{",close:"}"},{open:"[",close:"]"},{open:"(",close:")"},{open:'"',close:'"'}]},ibt={defaultToken:"",ignoreCase:!0,tokenPostfix:".scheme",brackets:[{open:"(",close:")",token:"delimiter.parenthesis"},{open:"{",close:"}",token:"delimiter.curly"},{open:"[",close:"]",token:"delimiter.square"}],keywords:["case","do","let","loop","if","else","when","cons","car","cdr","cond","lambda","lambda*","syntax-rules","format","set!","quote","eval","append","list","list?","member?","load"],constants:["#t","#f"],operators:["eq?","eqv?","equal?","and","or","not","null?"],tokenizer:{root:[[/#[xXoObB][0-9a-fA-F]+/,"number.hex"],[/[+-]?\d+(?:(?:\.\d*)?(?:[eE][+-]?\d+)?)?/,"number.float"],[/(?:\b(?:(define|define-syntax|define-macro))\b)(\s+)((?:\w|\-|\!|\?)*)/,["keyword","white","variable"]],{include:"@whitespace"},{include:"@strings"},[/[a-zA-Z_#][a-zA-Z0-9_\-\?\!\*]*/,{cases:{"@keywords":"keyword","@constants":"constant","@operators":"operators","@default":"identifier"}}]],comment:[[/[^\|#]+/,"comment"],[/#\|/,"comment","@push"],[/\|#/,"comment","@pop"],[/[\|#]/,"comment"]],whitespace:[[/[ \t\r\n]+/,"white"],[/#\|/,"comment","@comment"],[/;.*$/,"comment"]],strings:[[/"$/,"string","@popall"],[/"(?=.)/,"string","@multiLineString"]],multiLineString:[[/[^\\"]+$/,"string","@popall"],[/[^\\"]+/,"string"],[/\\./,"string.escape"],[/"/,"string","@popall"],[/\\$/,"string"]]}}});var I7e={};st(I7e,{conf:()=>nbt,language:()=>obt});var nbt,obt,E7e=k(()=>{nbt={wordPattern:/(#?-?\d*\.\d\w*%?)|([@$#!.:]?[\w-?]+%?)|[@#!.]/g,comments:{blockComment:["/*","*/"],lineComment:"//"},brackets:[["{","}"],["[","]"],["(",")"]],autoClosingPairs:[{open:"{",close:"}",notIn:["string","comment"]},{open:"[",close:"]",notIn:["string","comment"]},{open:"(",close:")",notIn:["string","comment"]},{open:'"',close:'"',notIn:["string","comment"]},{open:"'",close:"'",notIn:["string","comment"]}],surroundingPairs:[{open:"{",close:"}"},{open:"[",close:"]"},{open:"(",close:")"},{open:'"',close:'"'},{open:"'",close:"'"}],folding:{markers:{start:new RegExp("^\\s*\\/\\*\\s*#region\\b\\s*(.*?)\\s*\\*\\/"),end:new RegExp("^\\s*\\/\\*\\s*#endregion\\b.*\\*\\/")}}},obt={defaultToken:"",tokenPostfix:".scss",ws:`[ \r\f]*`,identifier:"-?-?([a-zA-Z]|(\\\\(([0-9a-fA-F]{1,6}\\s?)|[^[0-9a-fA-F])))([\\w\\-]|(\\\\(([0-9a-fA-F]{1,6}\\s?)|[^[0-9a-fA-F])))*",brackets:[{open:"{",close:"}",token:"delimiter.curly"},{open:"[",close:"]",token:"delimiter.bracket"},{open:"(",close:")",token:"delimiter.parenthesis"},{open:"<",close:">",token:"delimiter.angle"}],tokenizer:{root:[{include:"@selector"}],selector:[{include:"@comments"},{include:"@import"},{include:"@variabledeclaration"},{include:"@warndebug"},["[@](include)",{token:"keyword",next:"@includedeclaration"}],["[@](keyframes|-webkit-keyframes|-moz-keyframes|-o-keyframes)",{token:"keyword",next:"@keyframedeclaration"}],["[@](page|content|font-face|-moz-document)",{token:"keyword"}],["[@](charset|namespace)",{token:"keyword",next:"@declarationbody"}],["[@](function)",{token:"keyword",next:"@functiondeclaration"}],["[@](mixin)",{token:"keyword",next:"@mixindeclaration"}],["url(\\-prefix)?\\(",{token:"meta",next:"@urldeclaration"}],{include:"@controlstatement"},{include:"@selectorname"},["[&\\*]","tag"],["[>\\+,]","delimiter"],["\\[",{token:"delimiter.bracket",next:"@selectorattribute"}],["{",{token:"delimiter.curly",next:"@selectorbody"}]],selectorbody:[["[*_]?@identifier@ws:(?=(\\s|\\d|[^{;}]*[;}]))","attribute.name","@rulevalue"],{include:"@selector"},["[@](extend)",{token:"keyword",next:"@extendbody"}],["[@](return)",{token:"keyword",next:"@declarationbody"}],["}",{token:"delimiter.curly",next:"@pop"}]],selectorname:[["#{",{token:"meta",next:"@variableinterpolation"}],["(\\.|#(?=[^{])|%|(@identifier)|:)+","tag"]],selectorattribute:[{include:"@term"},["]",{token:"delimiter.bracket",next:"@pop"}]],term:[{include:"@comments"},["url(\\-prefix)?\\(",{token:"meta",next:"@urldeclaration"}],{include:"@functioninvocation"},{include:"@numbers"},{include:"@strings"},{include:"@variablereference"},["(and\\b|or\\b|not\\b)","operator"],{include:"@name"},["([<>=\\+\\-\\*\\/\\^\\|\\~,])","operator"],[",","delimiter"],["!default","literal"],["\\(",{token:"delimiter.parenthesis",next:"@parenthizedterm"}]],rulevalue:[{include:"@term"},["!important","literal"],[";","delimiter","@pop"],["{",{token:"delimiter.curly",switchTo:"@nestedproperty"}],["(?=})",{token:"",next:"@pop"}]],nestedproperty:[["[*_]?@identifier@ws:","attribute.name","@rulevalue"],{include:"@comments"},["}",{token:"delimiter.curly",next:"@pop"}]],warndebug:[["[@](warn|debug)",{token:"keyword",next:"@declarationbody"}]],import:[["[@](import)",{token:"keyword",next:"@declarationbody"}]],variabledeclaration:[["\\$@identifier@ws:","variable.decl","@declarationbody"]],urldeclaration:[{include:"@strings"},[`[^)\r ]+`,"string"],["\\)",{token:"meta",next:"@pop"}]],parenthizedterm:[{include:"@term"},["\\)",{token:"delimiter.parenthesis",next:"@pop"}]],declarationbody:[{include:"@term"},[";","delimiter","@pop"],["(?=})",{token:"",next:"@pop"}]],extendbody:[{include:"@selectorname"},["!optional","literal"],[";","delimiter","@pop"],["(?=})",{token:"",next:"@pop"}]],variablereference:[["\\$@identifier","variable.ref"],["\\.\\.\\.","operator"],["#{",{token:"meta",next:"@variableinterpolation"}]],variableinterpolation:[{include:"@variablereference"},["}",{token:"meta",next:"@pop"}]],comments:[["\\/\\*","comment","@comment"],["\\/\\/+.*","comment"]],comment:[["\\*\\/","comment","@pop"],[".","comment"]],name:[["@identifier","attribute.value"]],numbers:[["(\\d*\\.)?\\d+([eE][\\-+]?\\d+)?",{token:"number",next:"@units"}],["#[0-9a-fA-F_]+(?!\\w)","number.hex"]],units:[["(em|ex|ch|rem|fr|vmin|vmax|vw|vh|vm|cm|mm|in|px|pt|pc|deg|grad|rad|turn|s|ms|Hz|kHz|%)?","number","@pop"]],functiondeclaration:[["@identifier@ws\\(",{token:"meta",next:"@parameterdeclaration"}],["{",{token:"delimiter.curly",switchTo:"@functionbody"}]],mixindeclaration:[["@identifier@ws\\(",{token:"meta",next:"@parameterdeclaration"}],["@identifier","meta"],["{",{token:"delimiter.curly",switchTo:"@selectorbody"}]],parameterdeclaration:[["\\$@identifier@ws:","variable.decl"],["\\.\\.\\.","operator"],[",","delimiter"],{include:"@term"},["\\)",{token:"meta",next:"@pop"}]],includedeclaration:[{include:"@functioninvocation"},["@identifier","meta"],[";","delimiter","@pop"],["(?=})",{token:"",next:"@pop"}],["{",{token:"delimiter.curly",switchTo:"@selectorbody"}]],keyframedeclaration:[["@identifier","meta"],["{",{token:"delimiter.curly",switchTo:"@keyframebody"}]],keyframebody:[{include:"@term"},["{",{token:"delimiter.curly",next:"@selectorbody"}],["}",{token:"delimiter.curly",next:"@pop"}]],controlstatement:[["[@](if|else|for|while|each|media)",{token:"keyword.flow",next:"@controlstatementdeclaration"}]],controlstatementdeclaration:[["(in|from|through|if|to)\\b",{token:"keyword.flow"}],{include:"@term"},["{",{token:"delimiter.curly",switchTo:"@selectorbody"}]],functionbody:[["[@](return)",{token:"keyword"}],{include:"@variabledeclaration"},{include:"@term"},{include:"@controlstatement"},[";","delimiter"],["}",{token:"delimiter.curly",next:"@pop"}]],functioninvocation:[["@identifier\\(",{token:"meta",next:"@functionarguments"}]],functionarguments:[["\\$@identifier@ws:","attribute.name"],["[,]","delimiter"],{include:"@term"},["\\)",{token:"meta",next:"@pop"}]],strings:[['~?"',{token:"string.delimiter",next:"@stringenddoublequote"}],["~?'",{token:"string.delimiter",next:"@stringendquote"}]],stringenddoublequote:[["\\\\.","string"],['"',{token:"string.delimiter",next:"@pop"}],[".","string"]],stringendquote:[["\\\\.","string"],["'",{token:"string.delimiter",next:"@pop"}],[".","string"]]}}});var T7e={};st(T7e,{conf:()=>rbt,language:()=>sbt});var rbt,sbt,D7e=k(()=>{rbt={comments:{lineComment:"#"},brackets:[["{","}"],["[","]"],["(",")"]],autoClosingPairs:[{open:"{",close:"}"},{open:"[",close:"]"},{open:"(",close:")"},{open:'"',close:'"'},{open:"'",close:"'"},{open:"`",close:"`"}],surroundingPairs:[{open:"{",close:"}"},{open:"[",close:"]"},{open:"(",close:")"},{open:'"',close:'"'},{open:"'",close:"'"},{open:"`",close:"`"}]},sbt={defaultToken:"",ignoreCase:!0,tokenPostfix:".shell",brackets:[{token:"delimiter.bracket",open:"{",close:"}"},{token:"delimiter.parenthesis",open:"(",close:")"},{token:"delimiter.square",open:"[",close:"]"}],keywords:["if","then","do","else","elif","while","until","for","in","esac","fi","fin","fil","done","exit","set","unset","export","function"],builtins:["ab","awk","bash","beep","cat","cc","cd","chown","chmod","chroot","clear","cp","curl","cut","diff","echo","find","gawk","gcc","get","git","grep","hg","kill","killall","ln","ls","make","mkdir","openssl","mv","nc","node","npm","ping","ps","restart","rm","rmdir","sed","service","sh","shopt","shred","source","sort","sleep","ssh","start","stop","su","sudo","svn","tee","telnet","top","touch","vi","vim","wall","wc","wget","who","write","yes","zsh"],startingWithDash:/\-+\w+/,identifiersWithDashes:/[a-zA-Z]\w+(?:@startingWithDash)+/,symbols:/[=>abt,language:()=>lbt});var abt,lbt,R7e=k(()=>{abt={comments:{lineComment:"//",blockComment:["/*","*/"]},brackets:[["{","}"],["[","]"],["(",")"],["<",">"]],autoClosingPairs:[{open:'"',close:'"',notIn:["string","comment"]},{open:"{",close:"}",notIn:["string","comment"]},{open:"[",close:"]",notIn:["string","comment"]},{open:"(",close:")",notIn:["string","comment"]}]},lbt={defaultToken:"",tokenPostfix:".sol",brackets:[{token:"delimiter.curly",open:"{",close:"}"},{token:"delimiter.parenthesis",open:"(",close:")"},{token:"delimiter.square",open:"[",close:"]"},{token:"delimiter.angle",open:"<",close:">"}],keywords:["pragma","solidity","contract","library","using","struct","function","modifier","constructor","address","string","bool","Int","Uint","Byte","Fixed","Ufixed","int","int8","int16","int24","int32","int40","int48","int56","int64","int72","int80","int88","int96","int104","int112","int120","int128","int136","int144","int152","int160","int168","int176","int184","int192","int200","int208","int216","int224","int232","int240","int248","int256","uint","uint8","uint16","uint24","uint32","uint40","uint48","uint56","uint64","uint72","uint80","uint88","uint96","uint104","uint112","uint120","uint128","uint136","uint144","uint152","uint160","uint168","uint176","uint184","uint192","uint200","uint208","uint216","uint224","uint232","uint240","uint248","uint256","byte","bytes","bytes1","bytes2","bytes3","bytes4","bytes5","bytes6","bytes7","bytes8","bytes9","bytes10","bytes11","bytes12","bytes13","bytes14","bytes15","bytes16","bytes17","bytes18","bytes19","bytes20","bytes21","bytes22","bytes23","bytes24","bytes25","bytes26","bytes27","bytes28","bytes29","bytes30","bytes31","bytes32","fixed","fixed0x8","fixed0x16","fixed0x24","fixed0x32","fixed0x40","fixed0x48","fixed0x56","fixed0x64","fixed0x72","fixed0x80","fixed0x88","fixed0x96","fixed0x104","fixed0x112","fixed0x120","fixed0x128","fixed0x136","fixed0x144","fixed0x152","fixed0x160","fixed0x168","fixed0x176","fixed0x184","fixed0x192","fixed0x200","fixed0x208","fixed0x216","fixed0x224","fixed0x232","fixed0x240","fixed0x248","fixed0x256","fixed8x8","fixed8x16","fixed8x24","fixed8x32","fixed8x40","fixed8x48","fixed8x56","fixed8x64","fixed8x72","fixed8x80","fixed8x88","fixed8x96","fixed8x104","fixed8x112","fixed8x120","fixed8x128","fixed8x136","fixed8x144","fixed8x152","fixed8x160","fixed8x168","fixed8x176","fixed8x184","fixed8x192","fixed8x200","fixed8x208","fixed8x216","fixed8x224","fixed8x232","fixed8x240","fixed8x248","fixed16x8","fixed16x16","fixed16x24","fixed16x32","fixed16x40","fixed16x48","fixed16x56","fixed16x64","fixed16x72","fixed16x80","fixed16x88","fixed16x96","fixed16x104","fixed16x112","fixed16x120","fixed16x128","fixed16x136","fixed16x144","fixed16x152","fixed16x160","fixed16x168","fixed16x176","fixed16x184","fixed16x192","fixed16x200","fixed16x208","fixed16x216","fixed16x224","fixed16x232","fixed16x240","fixed24x8","fixed24x16","fixed24x24","fixed24x32","fixed24x40","fixed24x48","fixed24x56","fixed24x64","fixed24x72","fixed24x80","fixed24x88","fixed24x96","fixed24x104","fixed24x112","fixed24x120","fixed24x128","fixed24x136","fixed24x144","fixed24x152","fixed24x160","fixed24x168","fixed24x176","fixed24x184","fixed24x192","fixed24x200","fixed24x208","fixed24x216","fixed24x224","fixed24x232","fixed32x8","fixed32x16","fixed32x24","fixed32x32","fixed32x40","fixed32x48","fixed32x56","fixed32x64","fixed32x72","fixed32x80","fixed32x88","fixed32x96","fixed32x104","fixed32x112","fixed32x120","fixed32x128","fixed32x136","fixed32x144","fixed32x152","fixed32x160","fixed32x168","fixed32x176","fixed32x184","fixed32x192","fixed32x200","fixed32x208","fixed32x216","fixed32x224","fixed40x8","fixed40x16","fixed40x24","fixed40x32","fixed40x40","fixed40x48","fixed40x56","fixed40x64","fixed40x72","fixed40x80","fixed40x88","fixed40x96","fixed40x104","fixed40x112","fixed40x120","fixed40x128","fixed40x136","fixed40x144","fixed40x152","fixed40x160","fixed40x168","fixed40x176","fixed40x184","fixed40x192","fixed40x200","fixed40x208","fixed40x216","fixed48x8","fixed48x16","fixed48x24","fixed48x32","fixed48x40","fixed48x48","fixed48x56","fixed48x64","fixed48x72","fixed48x80","fixed48x88","fixed48x96","fixed48x104","fixed48x112","fixed48x120","fixed48x128","fixed48x136","fixed48x144","fixed48x152","fixed48x160","fixed48x168","fixed48x176","fixed48x184","fixed48x192","fixed48x200","fixed48x208","fixed56x8","fixed56x16","fixed56x24","fixed56x32","fixed56x40","fixed56x48","fixed56x56","fixed56x64","fixed56x72","fixed56x80","fixed56x88","fixed56x96","fixed56x104","fixed56x112","fixed56x120","fixed56x128","fixed56x136","fixed56x144","fixed56x152","fixed56x160","fixed56x168","fixed56x176","fixed56x184","fixed56x192","fixed56x200","fixed64x8","fixed64x16","fixed64x24","fixed64x32","fixed64x40","fixed64x48","fixed64x56","fixed64x64","fixed64x72","fixed64x80","fixed64x88","fixed64x96","fixed64x104","fixed64x112","fixed64x120","fixed64x128","fixed64x136","fixed64x144","fixed64x152","fixed64x160","fixed64x168","fixed64x176","fixed64x184","fixed64x192","fixed72x8","fixed72x16","fixed72x24","fixed72x32","fixed72x40","fixed72x48","fixed72x56","fixed72x64","fixed72x72","fixed72x80","fixed72x88","fixed72x96","fixed72x104","fixed72x112","fixed72x120","fixed72x128","fixed72x136","fixed72x144","fixed72x152","fixed72x160","fixed72x168","fixed72x176","fixed72x184","fixed80x8","fixed80x16","fixed80x24","fixed80x32","fixed80x40","fixed80x48","fixed80x56","fixed80x64","fixed80x72","fixed80x80","fixed80x88","fixed80x96","fixed80x104","fixed80x112","fixed80x120","fixed80x128","fixed80x136","fixed80x144","fixed80x152","fixed80x160","fixed80x168","fixed80x176","fixed88x8","fixed88x16","fixed88x24","fixed88x32","fixed88x40","fixed88x48","fixed88x56","fixed88x64","fixed88x72","fixed88x80","fixed88x88","fixed88x96","fixed88x104","fixed88x112","fixed88x120","fixed88x128","fixed88x136","fixed88x144","fixed88x152","fixed88x160","fixed88x168","fixed96x8","fixed96x16","fixed96x24","fixed96x32","fixed96x40","fixed96x48","fixed96x56","fixed96x64","fixed96x72","fixed96x80","fixed96x88","fixed96x96","fixed96x104","fixed96x112","fixed96x120","fixed96x128","fixed96x136","fixed96x144","fixed96x152","fixed96x160","fixed104x8","fixed104x16","fixed104x24","fixed104x32","fixed104x40","fixed104x48","fixed104x56","fixed104x64","fixed104x72","fixed104x80","fixed104x88","fixed104x96","fixed104x104","fixed104x112","fixed104x120","fixed104x128","fixed104x136","fixed104x144","fixed104x152","fixed112x8","fixed112x16","fixed112x24","fixed112x32","fixed112x40","fixed112x48","fixed112x56","fixed112x64","fixed112x72","fixed112x80","fixed112x88","fixed112x96","fixed112x104","fixed112x112","fixed112x120","fixed112x128","fixed112x136","fixed112x144","fixed120x8","fixed120x16","fixed120x24","fixed120x32","fixed120x40","fixed120x48","fixed120x56","fixed120x64","fixed120x72","fixed120x80","fixed120x88","fixed120x96","fixed120x104","fixed120x112","fixed120x120","fixed120x128","fixed120x136","fixed128x8","fixed128x16","fixed128x24","fixed128x32","fixed128x40","fixed128x48","fixed128x56","fixed128x64","fixed128x72","fixed128x80","fixed128x88","fixed128x96","fixed128x104","fixed128x112","fixed128x120","fixed128x128","fixed136x8","fixed136x16","fixed136x24","fixed136x32","fixed136x40","fixed136x48","fixed136x56","fixed136x64","fixed136x72","fixed136x80","fixed136x88","fixed136x96","fixed136x104","fixed136x112","fixed136x120","fixed144x8","fixed144x16","fixed144x24","fixed144x32","fixed144x40","fixed144x48","fixed144x56","fixed144x64","fixed144x72","fixed144x80","fixed144x88","fixed144x96","fixed144x104","fixed144x112","fixed152x8","fixed152x16","fixed152x24","fixed152x32","fixed152x40","fixed152x48","fixed152x56","fixed152x64","fixed152x72","fixed152x80","fixed152x88","fixed152x96","fixed152x104","fixed160x8","fixed160x16","fixed160x24","fixed160x32","fixed160x40","fixed160x48","fixed160x56","fixed160x64","fixed160x72","fixed160x80","fixed160x88","fixed160x96","fixed168x8","fixed168x16","fixed168x24","fixed168x32","fixed168x40","fixed168x48","fixed168x56","fixed168x64","fixed168x72","fixed168x80","fixed168x88","fixed176x8","fixed176x16","fixed176x24","fixed176x32","fixed176x40","fixed176x48","fixed176x56","fixed176x64","fixed176x72","fixed176x80","fixed184x8","fixed184x16","fixed184x24","fixed184x32","fixed184x40","fixed184x48","fixed184x56","fixed184x64","fixed184x72","fixed192x8","fixed192x16","fixed192x24","fixed192x32","fixed192x40","fixed192x48","fixed192x56","fixed192x64","fixed200x8","fixed200x16","fixed200x24","fixed200x32","fixed200x40","fixed200x48","fixed200x56","fixed208x8","fixed208x16","fixed208x24","fixed208x32","fixed208x40","fixed208x48","fixed216x8","fixed216x16","fixed216x24","fixed216x32","fixed216x40","fixed224x8","fixed224x16","fixed224x24","fixed224x32","fixed232x8","fixed232x16","fixed232x24","fixed240x8","fixed240x16","fixed248x8","ufixed","ufixed0x8","ufixed0x16","ufixed0x24","ufixed0x32","ufixed0x40","ufixed0x48","ufixed0x56","ufixed0x64","ufixed0x72","ufixed0x80","ufixed0x88","ufixed0x96","ufixed0x104","ufixed0x112","ufixed0x120","ufixed0x128","ufixed0x136","ufixed0x144","ufixed0x152","ufixed0x160","ufixed0x168","ufixed0x176","ufixed0x184","ufixed0x192","ufixed0x200","ufixed0x208","ufixed0x216","ufixed0x224","ufixed0x232","ufixed0x240","ufixed0x248","ufixed0x256","ufixed8x8","ufixed8x16","ufixed8x24","ufixed8x32","ufixed8x40","ufixed8x48","ufixed8x56","ufixed8x64","ufixed8x72","ufixed8x80","ufixed8x88","ufixed8x96","ufixed8x104","ufixed8x112","ufixed8x120","ufixed8x128","ufixed8x136","ufixed8x144","ufixed8x152","ufixed8x160","ufixed8x168","ufixed8x176","ufixed8x184","ufixed8x192","ufixed8x200","ufixed8x208","ufixed8x216","ufixed8x224","ufixed8x232","ufixed8x240","ufixed8x248","ufixed16x8","ufixed16x16","ufixed16x24","ufixed16x32","ufixed16x40","ufixed16x48","ufixed16x56","ufixed16x64","ufixed16x72","ufixed16x80","ufixed16x88","ufixed16x96","ufixed16x104","ufixed16x112","ufixed16x120","ufixed16x128","ufixed16x136","ufixed16x144","ufixed16x152","ufixed16x160","ufixed16x168","ufixed16x176","ufixed16x184","ufixed16x192","ufixed16x200","ufixed16x208","ufixed16x216","ufixed16x224","ufixed16x232","ufixed16x240","ufixed24x8","ufixed24x16","ufixed24x24","ufixed24x32","ufixed24x40","ufixed24x48","ufixed24x56","ufixed24x64","ufixed24x72","ufixed24x80","ufixed24x88","ufixed24x96","ufixed24x104","ufixed24x112","ufixed24x120","ufixed24x128","ufixed24x136","ufixed24x144","ufixed24x152","ufixed24x160","ufixed24x168","ufixed24x176","ufixed24x184","ufixed24x192","ufixed24x200","ufixed24x208","ufixed24x216","ufixed24x224","ufixed24x232","ufixed32x8","ufixed32x16","ufixed32x24","ufixed32x32","ufixed32x40","ufixed32x48","ufixed32x56","ufixed32x64","ufixed32x72","ufixed32x80","ufixed32x88","ufixed32x96","ufixed32x104","ufixed32x112","ufixed32x120","ufixed32x128","ufixed32x136","ufixed32x144","ufixed32x152","ufixed32x160","ufixed32x168","ufixed32x176","ufixed32x184","ufixed32x192","ufixed32x200","ufixed32x208","ufixed32x216","ufixed32x224","ufixed40x8","ufixed40x16","ufixed40x24","ufixed40x32","ufixed40x40","ufixed40x48","ufixed40x56","ufixed40x64","ufixed40x72","ufixed40x80","ufixed40x88","ufixed40x96","ufixed40x104","ufixed40x112","ufixed40x120","ufixed40x128","ufixed40x136","ufixed40x144","ufixed40x152","ufixed40x160","ufixed40x168","ufixed40x176","ufixed40x184","ufixed40x192","ufixed40x200","ufixed40x208","ufixed40x216","ufixed48x8","ufixed48x16","ufixed48x24","ufixed48x32","ufixed48x40","ufixed48x48","ufixed48x56","ufixed48x64","ufixed48x72","ufixed48x80","ufixed48x88","ufixed48x96","ufixed48x104","ufixed48x112","ufixed48x120","ufixed48x128","ufixed48x136","ufixed48x144","ufixed48x152","ufixed48x160","ufixed48x168","ufixed48x176","ufixed48x184","ufixed48x192","ufixed48x200","ufixed48x208","ufixed56x8","ufixed56x16","ufixed56x24","ufixed56x32","ufixed56x40","ufixed56x48","ufixed56x56","ufixed56x64","ufixed56x72","ufixed56x80","ufixed56x88","ufixed56x96","ufixed56x104","ufixed56x112","ufixed56x120","ufixed56x128","ufixed56x136","ufixed56x144","ufixed56x152","ufixed56x160","ufixed56x168","ufixed56x176","ufixed56x184","ufixed56x192","ufixed56x200","ufixed64x8","ufixed64x16","ufixed64x24","ufixed64x32","ufixed64x40","ufixed64x48","ufixed64x56","ufixed64x64","ufixed64x72","ufixed64x80","ufixed64x88","ufixed64x96","ufixed64x104","ufixed64x112","ufixed64x120","ufixed64x128","ufixed64x136","ufixed64x144","ufixed64x152","ufixed64x160","ufixed64x168","ufixed64x176","ufixed64x184","ufixed64x192","ufixed72x8","ufixed72x16","ufixed72x24","ufixed72x32","ufixed72x40","ufixed72x48","ufixed72x56","ufixed72x64","ufixed72x72","ufixed72x80","ufixed72x88","ufixed72x96","ufixed72x104","ufixed72x112","ufixed72x120","ufixed72x128","ufixed72x136","ufixed72x144","ufixed72x152","ufixed72x160","ufixed72x168","ufixed72x176","ufixed72x184","ufixed80x8","ufixed80x16","ufixed80x24","ufixed80x32","ufixed80x40","ufixed80x48","ufixed80x56","ufixed80x64","ufixed80x72","ufixed80x80","ufixed80x88","ufixed80x96","ufixed80x104","ufixed80x112","ufixed80x120","ufixed80x128","ufixed80x136","ufixed80x144","ufixed80x152","ufixed80x160","ufixed80x168","ufixed80x176","ufixed88x8","ufixed88x16","ufixed88x24","ufixed88x32","ufixed88x40","ufixed88x48","ufixed88x56","ufixed88x64","ufixed88x72","ufixed88x80","ufixed88x88","ufixed88x96","ufixed88x104","ufixed88x112","ufixed88x120","ufixed88x128","ufixed88x136","ufixed88x144","ufixed88x152","ufixed88x160","ufixed88x168","ufixed96x8","ufixed96x16","ufixed96x24","ufixed96x32","ufixed96x40","ufixed96x48","ufixed96x56","ufixed96x64","ufixed96x72","ufixed96x80","ufixed96x88","ufixed96x96","ufixed96x104","ufixed96x112","ufixed96x120","ufixed96x128","ufixed96x136","ufixed96x144","ufixed96x152","ufixed96x160","ufixed104x8","ufixed104x16","ufixed104x24","ufixed104x32","ufixed104x40","ufixed104x48","ufixed104x56","ufixed104x64","ufixed104x72","ufixed104x80","ufixed104x88","ufixed104x96","ufixed104x104","ufixed104x112","ufixed104x120","ufixed104x128","ufixed104x136","ufixed104x144","ufixed104x152","ufixed112x8","ufixed112x16","ufixed112x24","ufixed112x32","ufixed112x40","ufixed112x48","ufixed112x56","ufixed112x64","ufixed112x72","ufixed112x80","ufixed112x88","ufixed112x96","ufixed112x104","ufixed112x112","ufixed112x120","ufixed112x128","ufixed112x136","ufixed112x144","ufixed120x8","ufixed120x16","ufixed120x24","ufixed120x32","ufixed120x40","ufixed120x48","ufixed120x56","ufixed120x64","ufixed120x72","ufixed120x80","ufixed120x88","ufixed120x96","ufixed120x104","ufixed120x112","ufixed120x120","ufixed120x128","ufixed120x136","ufixed128x8","ufixed128x16","ufixed128x24","ufixed128x32","ufixed128x40","ufixed128x48","ufixed128x56","ufixed128x64","ufixed128x72","ufixed128x80","ufixed128x88","ufixed128x96","ufixed128x104","ufixed128x112","ufixed128x120","ufixed128x128","ufixed136x8","ufixed136x16","ufixed136x24","ufixed136x32","ufixed136x40","ufixed136x48","ufixed136x56","ufixed136x64","ufixed136x72","ufixed136x80","ufixed136x88","ufixed136x96","ufixed136x104","ufixed136x112","ufixed136x120","ufixed144x8","ufixed144x16","ufixed144x24","ufixed144x32","ufixed144x40","ufixed144x48","ufixed144x56","ufixed144x64","ufixed144x72","ufixed144x80","ufixed144x88","ufixed144x96","ufixed144x104","ufixed144x112","ufixed152x8","ufixed152x16","ufixed152x24","ufixed152x32","ufixed152x40","ufixed152x48","ufixed152x56","ufixed152x64","ufixed152x72","ufixed152x80","ufixed152x88","ufixed152x96","ufixed152x104","ufixed160x8","ufixed160x16","ufixed160x24","ufixed160x32","ufixed160x40","ufixed160x48","ufixed160x56","ufixed160x64","ufixed160x72","ufixed160x80","ufixed160x88","ufixed160x96","ufixed168x8","ufixed168x16","ufixed168x24","ufixed168x32","ufixed168x40","ufixed168x48","ufixed168x56","ufixed168x64","ufixed168x72","ufixed168x80","ufixed168x88","ufixed176x8","ufixed176x16","ufixed176x24","ufixed176x32","ufixed176x40","ufixed176x48","ufixed176x56","ufixed176x64","ufixed176x72","ufixed176x80","ufixed184x8","ufixed184x16","ufixed184x24","ufixed184x32","ufixed184x40","ufixed184x48","ufixed184x56","ufixed184x64","ufixed184x72","ufixed192x8","ufixed192x16","ufixed192x24","ufixed192x32","ufixed192x40","ufixed192x48","ufixed192x56","ufixed192x64","ufixed200x8","ufixed200x16","ufixed200x24","ufixed200x32","ufixed200x40","ufixed200x48","ufixed200x56","ufixed208x8","ufixed208x16","ufixed208x24","ufixed208x32","ufixed208x40","ufixed208x48","ufixed216x8","ufixed216x16","ufixed216x24","ufixed216x32","ufixed216x40","ufixed224x8","ufixed224x16","ufixed224x24","ufixed224x32","ufixed232x8","ufixed232x16","ufixed232x24","ufixed240x8","ufixed240x16","ufixed248x8","event","enum","let","mapping","private","public","external","inherited","payable","true","false","var","import","constant","if","else","for","else","for","while","do","break","continue","throw","returns","return","suicide","new","is","this","super"],operators:["=",">","<","!","~","?",":","==","<=",">=","!=","&&","||","++","--","+","-","*","/","&","|","^","%","<<",">>",">>>","+=","-=","*=","/=","&=","|=","^=","%=","<<=",">>=",">>>="],symbols:/[=>](?!@symbols)/,"@brackets"],[/@symbols/,{cases:{"@operators":"delimiter","@default":""}}],[/\d*\d+[eE]([\-+]?\d+)?(@floatsuffix)/,"number.float"],[/\d*\.\d+([eE][\-+]?\d+)?(@floatsuffix)/,"number.float"],[/0[xX][0-9a-fA-F']*[0-9a-fA-F](@integersuffix)/,"number.hex"],[/0[0-7']*[0-7](@integersuffix)/,"number.octal"],[/0[bB][0-1']*[0-1](@integersuffix)/,"number.binary"],[/\d[\d']*\d(@integersuffix)/,"number"],[/\d(@integersuffix)/,"number"],[/[;,.]/,"delimiter"],[/"([^"\\]|\\.)*$/,"string.invalid"],[/"/,"string","@string"],[/'[^\\']'/,"string"],[/(')(@escapes)(')/,["string","string.escape","string"]],[/'/,"string.invalid"]],whitespace:[[/[ \t\r\n]+/,""],[/\/\*\*(?!\/)/,"comment.doc","@doccomment"],[/\/\*/,"comment","@comment"],[/\/\/.*$/,"comment"]],comment:[[/[^\/*]+/,"comment"],[/\*\//,"comment","@pop"],[/[\/*]/,"comment"]],doccomment:[[/[^\/*]+/,"comment.doc"],[/\*\//,"comment.doc","@pop"],[/[\/*]/,"comment.doc"]],string:[[/[^\\"]+/,"string"],[/@escapes/,"string.escape"],[/\\./,"string.escape.invalid"],[/"/,"string","@pop"]]}}});var A7e={};st(A7e,{conf:()=>cbt,language:()=>dbt});var cbt,dbt,M7e=k(()=>{cbt={comments:{lineComment:"//",blockComment:["/*","*/"]},brackets:[["{","}"],["[","]"],["(",")"],["<",">"]],autoClosingPairs:[{open:'"',close:'"',notIn:["string","comment"]},{open:"{",close:"}",notIn:["string","comment"]},{open:"[",close:"]",notIn:["string","comment"]},{open:"(",close:")",notIn:["string","comment"]}]},dbt={defaultToken:"",tokenPostfix:".aes",brackets:[{token:"delimiter.curly",open:"{",close:"}"},{token:"delimiter.parenthesis",open:"(",close:")"},{token:"delimiter.square",open:"[",close:"]"},{token:"delimiter.angle",open:"<",close:">"}],keywords:["contract","library","entrypoint","function","stateful","state","hash","signature","tuple","list","address","string","bool","int","record","datatype","type","option","oracle","oracle_query","Call","Bits","Bytes","Oracle","String","Crypto","Address","Auth","Chain","None","Some","bits","bytes","event","let","map","private","public","true","false","var","if","else","throw"],operators:["=",">","<","!","~","?","::",":","==","<=",">=","!=","&&","||","++","--","+","-","*","/","&","|","^","%","<<",">>",">>>","+=","-=","*=","/=","&=","|=","^=","%=","<<=",">>=",">>>="],symbols:/[=>](?!@symbols)/,"@brackets"],[/@symbols/,{cases:{"@operators":"delimiter","@default":""}}],[/\d*\d+[eE]([\-+]?\d+)?(@floatsuffix)/,"number.float"],[/\d*\.\d+([eE][\-+]?\d+)?(@floatsuffix)/,"number.float"],[/0[xX][0-9a-fA-F']*[0-9a-fA-F](@integersuffix)/,"number.hex"],[/0[0-7']*[0-7](@integersuffix)/,"number.octal"],[/0[bB][0-1']*[0-1](@integersuffix)/,"number.binary"],[/\d[\d']*\d(@integersuffix)/,"number"],[/\d(@integersuffix)/,"number"],[/[;,.]/,"delimiter"],[/"([^"\\]|\\.)*$/,"string.invalid"],[/"/,"string","@string"],[/'[^\\']'/,"string"],[/(')(@escapes)(')/,["string","string.escape","string"]],[/'/,"string.invalid"]],whitespace:[[/[ \t\r\n]+/,""],[/\/\*\*(?!\/)/,"comment.doc","@doccomment"],[/\/\*/,"comment","@comment"],[/\/\/.*$/,"comment"]],comment:[[/[^\/*]+/,"comment"],[/\*\//,"comment","@pop"],[/[\/*]/,"comment"]],doccomment:[[/[^\/*]+/,"comment.doc"],[/\*\//,"comment.doc","@pop"],[/[\/*]/,"comment.doc"]],string:[[/[^\\"]+/,"string"],[/@escapes/,"string.escape"],[/\\./,"string.escape.invalid"],[/"/,"string","@pop"]]}}});var P7e={};st(P7e,{conf:()=>ubt,language:()=>hbt});var ubt,hbt,O7e=k(()=>{ubt={comments:{lineComment:"#"},brackets:[["{","}"],["[","]"],["(",")"]],autoClosingPairs:[{open:"'",close:"'",notIn:["string"]},{open:'"',close:'"',notIn:["string"]},{open:"{",close:"}"},{open:"[",close:"]"},{open:"(",close:")"}]},hbt={defaultToken:"",tokenPostfix:".rq",brackets:[{token:"delimiter.curly",open:"{",close:"}"},{token:"delimiter.parenthesis",open:"(",close:")"},{token:"delimiter.square",open:"[",close:"]"},{token:"delimiter.angle",open:"<",close:">"}],keywords:["add","as","asc","ask","base","by","clear","construct","copy","create","data","delete","desc","describe","distinct","drop","false","filter","from","graph","group","having","in","insert","limit","load","minus","move","named","not","offset","optional","order","prefix","reduced","select","service","silent","to","true","undef","union","using","values","where","with"],builtinFunctions:["a","abs","avg","bind","bnode","bound","ceil","coalesce","concat","contains","count","datatype","day","encode_for_uri","exists","floor","group_concat","hours","if","iri","isblank","isiri","isliteral","isnumeric","isuri","lang","langmatches","lcase","max","md5","min","minutes","month","now","rand","regex","replace","round","sameterm","sample","seconds","sha1","sha256","sha384","sha512","str","strafter","strbefore","strdt","strends","strlang","strlen","strstarts","struuid","substr","sum","timezone","tz","ucase","uri","uuid","year"],ignoreCase:!0,tokenizer:{root:[[/<[^\s\u00a0>]*>?/,"tag"],{include:"@strings"},[/#.*/,"comment"],[/[{}()\[\]]/,"@brackets"],[/[;,.]/,"delimiter"],[/[_\w\d]+:(\.(?=[\w_\-\\%])|[:\w_-]|\\[-\\_~.!$&'()*+,;=/?#@%]|%[a-f\d][a-f\d])*/,"tag"],[/:(\.(?=[\w_\-\\%])|[:\w_-]|\\[-\\_~.!$&'()*+,;=/?#@%]|%[a-f\d][a-f\d])+/,"tag"],[/[$?]?[_\w\d]+/,{cases:{"@keywords":{token:"keyword"},"@builtinFunctions":{token:"predefined.sql"},"@default":"identifier"}}],[/\^\^/,"operator.sql"],[/\^[*+\-<>=&|^\/!?]*/,"operator.sql"],[/[*+\-<>=&|\/!?]/,"operator.sql"],[/@[a-z\d\-]*/,"metatag.html"],[/\s+/,"white"]],strings:[[/'([^'\\]|\\.)*$/,"string.invalid"],[/'$/,"string.sql","@pop"],[/'/,"string.sql","@stringBody"],[/"([^"\\]|\\.)*$/,"string.invalid"],[/"$/,"string.sql","@pop"],[/"/,"string.sql","@dblStringBody"]],stringBody:[[/[^\\']+/,"string.sql"],[/\\./,"string.escape"],[/'/,"string.sql","@pop"]],dblStringBody:[[/[^\\"]+/,"string.sql"],[/\\./,"string.escape"],[/"/,"string.sql","@pop"]]}}});var F7e={};st(F7e,{conf:()=>fbt,language:()=>pbt});var fbt,pbt,B7e=k(()=>{fbt={comments:{lineComment:"--",blockComment:["/*","*/"]},brackets:[["{","}"],["[","]"],["(",")"]],autoClosingPairs:[{open:"{",close:"}"},{open:"[",close:"]"},{open:"(",close:")"},{open:'"',close:'"'},{open:"'",close:"'"}],surroundingPairs:[{open:"{",close:"}"},{open:"[",close:"]"},{open:"(",close:")"},{open:'"',close:'"'},{open:"'",close:"'"}]},pbt={defaultToken:"",tokenPostfix:".sql",ignoreCase:!0,brackets:[{open:"[",close:"]",token:"delimiter.square"},{open:"(",close:")",token:"delimiter.parenthesis"}],keywords:["ABORT","ABSOLUTE","ACTION","ADA","ADD","AFTER","ALL","ALLOCATE","ALTER","ALWAYS","ANALYZE","AND","ANY","ARE","AS","ASC","ASSERTION","AT","ATTACH","AUTHORIZATION","AUTOINCREMENT","AVG","BACKUP","BEFORE","BEGIN","BETWEEN","BIT","BIT_LENGTH","BOTH","BREAK","BROWSE","BULK","BY","CASCADE","CASCADED","CASE","CAST","CATALOG","CHAR","CHARACTER","CHARACTER_LENGTH","CHAR_LENGTH","CHECK","CHECKPOINT","CLOSE","CLUSTERED","COALESCE","COLLATE","COLLATION","COLUMN","COMMIT","COMPUTE","CONFLICT","CONNECT","CONNECTION","CONSTRAINT","CONSTRAINTS","CONTAINS","CONTAINSTABLE","CONTINUE","CONVERT","CORRESPONDING","COUNT","CREATE","CROSS","CURRENT","CURRENT_DATE","CURRENT_TIME","CURRENT_TIMESTAMP","CURRENT_USER","CURSOR","DATABASE","DATE","DAY","DBCC","DEALLOCATE","DEC","DECIMAL","DECLARE","DEFAULT","DEFERRABLE","DEFERRED","DELETE","DENY","DESC","DESCRIBE","DESCRIPTOR","DETACH","DIAGNOSTICS","DISCONNECT","DISK","DISTINCT","DISTRIBUTED","DO","DOMAIN","DOUBLE","DROP","DUMP","EACH","ELSE","END","END-EXEC","ERRLVL","ESCAPE","EXCEPT","EXCEPTION","EXCLUDE","EXCLUSIVE","EXEC","EXECUTE","EXISTS","EXIT","EXPLAIN","EXTERNAL","EXTRACT","FAIL","FALSE","FETCH","FILE","FILLFACTOR","FILTER","FIRST","FLOAT","FOLLOWING","FOR","FOREIGN","FORTRAN","FOUND","FREETEXT","FREETEXTTABLE","FROM","FULL","FUNCTION","GENERATED","GET","GLOB","GLOBAL","GO","GOTO","GRANT","GROUP","GROUPS","HAVING","HOLDLOCK","HOUR","IDENTITY","IDENTITYCOL","IDENTITY_INSERT","IF","IGNORE","IMMEDIATE","IN","INCLUDE","INDEX","INDEXED","INDICATOR","INITIALLY","INNER","INPUT","INSENSITIVE","INSERT","INSTEAD","INT","INTEGER","INTERSECT","INTERVAL","INTO","IS","ISNULL","ISOLATION","JOIN","KEY","KILL","LANGUAGE","LAST","LEADING","LEFT","LEVEL","LIKE","LIMIT","LINENO","LOAD","LOCAL","LOWER","MATCH","MATERIALIZED","MAX","MERGE","MIN","MINUTE","MODULE","MONTH","NAMES","NATIONAL","NATURAL","NCHAR","NEXT","NO","NOCHECK","NONCLUSTERED","NONE","NOT","NOTHING","NOTNULL","NULL","NULLIF","NULLS","NUMERIC","OCTET_LENGTH","OF","OFF","OFFSET","OFFSETS","ON","ONLY","OPEN","OPENDATASOURCE","OPENQUERY","OPENROWSET","OPENXML","OPTION","OR","ORDER","OTHERS","OUTER","OUTPUT","OVER","OVERLAPS","PAD","PARTIAL","PARTITION","PASCAL","PERCENT","PIVOT","PLAN","POSITION","PRAGMA","PRECEDING","PRECISION","PREPARE","PRESERVE","PRIMARY","PRINT","PRIOR","PRIVILEGES","PROC","PROCEDURE","PUBLIC","QUERY","RAISE","RAISERROR","RANGE","READ","READTEXT","REAL","RECONFIGURE","RECURSIVE","REFERENCES","REGEXP","REINDEX","RELATIVE","RELEASE","RENAME","REPLACE","REPLICATION","RESTORE","RESTRICT","RETURN","RETURNING","REVERT","REVOKE","RIGHT","ROLLBACK","ROW","ROWCOUNT","ROWGUIDCOL","ROWS","RULE","SAVE","SAVEPOINT","SCHEMA","SCROLL","SECOND","SECTION","SECURITYAUDIT","SELECT","SEMANTICKEYPHRASETABLE","SEMANTICSIMILARITYDETAILSTABLE","SEMANTICSIMILARITYTABLE","SESSION","SESSION_USER","SET","SETUSER","SHUTDOWN","SIZE","SMALLINT","SOME","SPACE","SQL","SQLCA","SQLCODE","SQLERROR","SQLSTATE","SQLWARNING","STATISTICS","SUBSTRING","SUM","SYSTEM_USER","TABLE","TABLESAMPLE","TEMP","TEMPORARY","TEXTSIZE","THEN","TIES","TIME","TIMESTAMP","TIMEZONE_HOUR","TIMEZONE_MINUTE","TO","TOP","TRAILING","TRAN","TRANSACTION","TRANSLATE","TRANSLATION","TRIGGER","TRIM","TRUE","TRUNCATE","TRY_CONVERT","TSEQUAL","UNBOUNDED","UNION","UNIQUE","UNKNOWN","UNPIVOT","UPDATE","UPDATETEXT","UPPER","USAGE","USE","USER","USING","VACUUM","VALUE","VALUES","VARCHAR","VARYING","VIEW","VIRTUAL","WAITFOR","WHEN","WHENEVER","WHERE","WHILE","WINDOW","WITH","WITHIN GROUP","WITHOUT","WORK","WRITE","WRITETEXT","YEAR","ZONE"],operators:["ALL","AND","ANY","BETWEEN","EXISTS","IN","LIKE","NOT","OR","SOME","EXCEPT","INTERSECT","UNION","APPLY","CROSS","FULL","INNER","JOIN","LEFT","OUTER","RIGHT","CONTAINS","FREETEXT","IS","NULL","PIVOT","UNPIVOT","MATCHED"],builtinFunctions:["AVG","CHECKSUM_AGG","COUNT","COUNT_BIG","GROUPING","GROUPING_ID","MAX","MIN","SUM","STDEV","STDEVP","VAR","VARP","CUME_DIST","FIRST_VALUE","LAG","LAST_VALUE","LEAD","PERCENTILE_CONT","PERCENTILE_DISC","PERCENT_RANK","COLLATE","COLLATIONPROPERTY","TERTIARY_WEIGHTS","FEDERATION_FILTERING_VALUE","CAST","CONVERT","PARSE","TRY_CAST","TRY_CONVERT","TRY_PARSE","ASYMKEY_ID","ASYMKEYPROPERTY","CERTPROPERTY","CERT_ID","CRYPT_GEN_RANDOM","DECRYPTBYASYMKEY","DECRYPTBYCERT","DECRYPTBYKEY","DECRYPTBYKEYAUTOASYMKEY","DECRYPTBYKEYAUTOCERT","DECRYPTBYPASSPHRASE","ENCRYPTBYASYMKEY","ENCRYPTBYCERT","ENCRYPTBYKEY","ENCRYPTBYPASSPHRASE","HASHBYTES","IS_OBJECTSIGNED","KEY_GUID","KEY_ID","KEY_NAME","SIGNBYASYMKEY","SIGNBYCERT","SYMKEYPROPERTY","VERIFYSIGNEDBYCERT","VERIFYSIGNEDBYASYMKEY","CURSOR_STATUS","DATALENGTH","IDENT_CURRENT","IDENT_INCR","IDENT_SEED","IDENTITY","SQL_VARIANT_PROPERTY","CURRENT_TIMESTAMP","DATEADD","DATEDIFF","DATEFROMPARTS","DATENAME","DATEPART","DATETIME2FROMPARTS","DATETIMEFROMPARTS","DATETIMEOFFSETFROMPARTS","DAY","EOMONTH","GETDATE","GETUTCDATE","ISDATE","MONTH","SMALLDATETIMEFROMPARTS","SWITCHOFFSET","SYSDATETIME","SYSDATETIMEOFFSET","SYSUTCDATETIME","TIMEFROMPARTS","TODATETIMEOFFSET","YEAR","CHOOSE","COALESCE","IIF","NULLIF","ABS","ACOS","ASIN","ATAN","ATN2","CEILING","COS","COT","DEGREES","EXP","FLOOR","LOG","LOG10","PI","POWER","RADIANS","RAND","ROUND","SIGN","SIN","SQRT","SQUARE","TAN","APP_NAME","APPLOCK_MODE","APPLOCK_TEST","ASSEMBLYPROPERTY","COL_LENGTH","COL_NAME","COLUMNPROPERTY","DATABASE_PRINCIPAL_ID","DATABASEPROPERTYEX","DB_ID","DB_NAME","FILE_ID","FILE_IDEX","FILE_NAME","FILEGROUP_ID","FILEGROUP_NAME","FILEGROUPPROPERTY","FILEPROPERTY","FULLTEXTCATALOGPROPERTY","FULLTEXTSERVICEPROPERTY","INDEX_COL","INDEXKEY_PROPERTY","INDEXPROPERTY","OBJECT_DEFINITION","OBJECT_ID","OBJECT_NAME","OBJECT_SCHEMA_NAME","OBJECTPROPERTY","OBJECTPROPERTYEX","ORIGINAL_DB_NAME","PARSENAME","SCHEMA_ID","SCHEMA_NAME","SCOPE_IDENTITY","SERVERPROPERTY","STATS_DATE","TYPE_ID","TYPE_NAME","TYPEPROPERTY","DENSE_RANK","NTILE","RANK","ROW_NUMBER","PUBLISHINGSERVERNAME","OPENDATASOURCE","OPENQUERY","OPENROWSET","OPENXML","CERTENCODED","CERTPRIVATEKEY","CURRENT_USER","HAS_DBACCESS","HAS_PERMS_BY_NAME","IS_MEMBER","IS_ROLEMEMBER","IS_SRVROLEMEMBER","LOGINPROPERTY","ORIGINAL_LOGIN","PERMISSIONS","PWDENCRYPT","PWDCOMPARE","SESSION_USER","SESSIONPROPERTY","SUSER_ID","SUSER_NAME","SUSER_SID","SUSER_SNAME","SYSTEM_USER","USER","USER_ID","USER_NAME","ASCII","CHAR","CHARINDEX","CONCAT","DIFFERENCE","FORMAT","LEFT","LEN","LOWER","LTRIM","NCHAR","PATINDEX","QUOTENAME","REPLACE","REPLICATE","REVERSE","RIGHT","RTRIM","SOUNDEX","SPACE","STR","STUFF","SUBSTRING","UNICODE","UPPER","BINARY_CHECKSUM","CHECKSUM","CONNECTIONPROPERTY","CONTEXT_INFO","CURRENT_REQUEST_ID","ERROR_LINE","ERROR_NUMBER","ERROR_MESSAGE","ERROR_PROCEDURE","ERROR_SEVERITY","ERROR_STATE","FORMATMESSAGE","GETANSINULL","GET_FILESTREAM_TRANSACTION_CONTEXT","HOST_ID","HOST_NAME","ISNULL","ISNUMERIC","MIN_ACTIVE_ROWVERSION","NEWID","NEWSEQUENTIALID","ROWCOUNT_BIG","XACT_STATE","TEXTPTR","TEXTVALID","COLUMNS_UPDATED","EVENTDATA","TRIGGER_NESTLEVEL","UPDATE","CHANGETABLE","CHANGE_TRACKING_CONTEXT","CHANGE_TRACKING_CURRENT_VERSION","CHANGE_TRACKING_IS_COLUMN_IN_MASK","CHANGE_TRACKING_MIN_VALID_VERSION","CONTAINSTABLE","FREETEXTTABLE","SEMANTICKEYPHRASETABLE","SEMANTICSIMILARITYDETAILSTABLE","SEMANTICSIMILARITYTABLE","FILETABLEROOTPATH","GETFILENAMESPACEPATH","GETPATHLOCATOR","PATHNAME","GET_TRANSMISSION_STATUS"],builtinVariables:["@@DATEFIRST","@@DBTS","@@LANGID","@@LANGUAGE","@@LOCK_TIMEOUT","@@MAX_CONNECTIONS","@@MAX_PRECISION","@@NESTLEVEL","@@OPTIONS","@@REMSERVER","@@SERVERNAME","@@SERVICENAME","@@SPID","@@TEXTSIZE","@@VERSION","@@CURSOR_ROWS","@@FETCH_STATUS","@@DATEFIRST","@@PROCID","@@ERROR","@@IDENTITY","@@ROWCOUNT","@@TRANCOUNT","@@CONNECTIONS","@@CPU_BUSY","@@IDLE","@@IO_BUSY","@@PACKET_ERRORS","@@PACK_RECEIVED","@@PACK_SENT","@@TIMETICKS","@@TOTAL_ERRORS","@@TOTAL_READ","@@TOTAL_WRITE"],pseudoColumns:["$ACTION","$IDENTITY","$ROWGUID","$PARTITION"],tokenizer:{root:[{include:"@comments"},{include:"@whitespace"},{include:"@pseudoColumns"},{include:"@numbers"},{include:"@strings"},{include:"@complexIdentifiers"},{include:"@scopes"},[/[;,.]/,"delimiter"],[/[()]/,"@brackets"],[/[\w@#$]+/,{cases:{"@operators":"operator","@builtinVariables":"predefined","@builtinFunctions":"predefined","@keywords":"keyword","@default":"identifier"}}],[/[<>=!%&+\-*/|~^]/,"operator"]],whitespace:[[/\s+/,"white"]],comments:[[/--+.*/,"comment"],[/\/\*/,{token:"comment.quote",next:"@comment"}]],comment:[[/[^*/]+/,"comment"],[/\*\//,{token:"comment.quote",next:"@pop"}],[/./,"comment"]],pseudoColumns:[[/[$][A-Za-z_][\w@#$]*/,{cases:{"@pseudoColumns":"predefined","@default":"identifier"}}]],numbers:[[/0[xX][0-9a-fA-F]*/,"number"],[/[$][+-]*\d*(\.\d*)?/,"number"],[/((\d+(\.\d*)?)|(\.\d+))([eE][\-+]?\d+)?/,"number"]],strings:[[/N'/,{token:"string",next:"@string"}],[/'/,{token:"string",next:"@string"}]],string:[[/[^']+/,"string"],[/''/,"string"],[/'/,{token:"string",next:"@pop"}]],complexIdentifiers:[[/\[/,{token:"identifier.quote",next:"@bracketedIdentifier"}],[/"/,{token:"identifier.quote",next:"@quotedIdentifier"}]],bracketedIdentifier:[[/[^\]]+/,"identifier"],[/]]/,"identifier"],[/]/,{token:"identifier.quote",next:"@pop"}]],quotedIdentifier:[[/[^"]+/,"identifier"],[/""/,"identifier"],[/"/,{token:"identifier.quote",next:"@pop"}]],scopes:[[/BEGIN\s+(DISTRIBUTED\s+)?TRAN(SACTION)?\b/i,"keyword"],[/BEGIN\s+TRY\b/i,{token:"keyword.try"}],[/END\s+TRY\b/i,{token:"keyword.try"}],[/BEGIN\s+CATCH\b/i,{token:"keyword.catch"}],[/END\s+CATCH\b/i,{token:"keyword.catch"}],[/(BEGIN|CASE)\b/i,{token:"keyword.block"}],[/END\b/i,{token:"keyword.block"}],[/WHEN\b/i,{token:"keyword.choice"}],[/THEN\b/i,{token:"keyword.choice"}]]}}});var W7e={};st(W7e,{conf:()=>mbt,language:()=>gbt});var mbt,gbt,H7e=k(()=>{mbt={comments:{lineComment:"//",blockComment:["(*","*)"]},brackets:[["{","}"],["[","]"],["(",")"],["var","end_var"],["var_input","end_var"],["var_output","end_var"],["var_in_out","end_var"],["var_temp","end_var"],["var_global","end_var"],["var_access","end_var"],["var_external","end_var"],["type","end_type"],["struct","end_struct"],["program","end_program"],["function","end_function"],["function_block","end_function_block"],["action","end_action"],["step","end_step"],["initial_step","end_step"],["transaction","end_transaction"],["configuration","end_configuration"],["tcp","end_tcp"],["recource","end_recource"],["channel","end_channel"],["library","end_library"],["folder","end_folder"],["binaries","end_binaries"],["includes","end_includes"],["sources","end_sources"]],autoClosingPairs:[{open:"[",close:"]"},{open:"{",close:"}"},{open:"(",close:")"},{open:"/*",close:"*/"},{open:"'",close:"'",notIn:["string_sq"]},{open:'"',close:'"',notIn:["string_dq"]},{open:"var_input",close:"end_var"},{open:"var_output",close:"end_var"},{open:"var_in_out",close:"end_var"},{open:"var_temp",close:"end_var"},{open:"var_global",close:"end_var"},{open:"var_access",close:"end_var"},{open:"var_external",close:"end_var"},{open:"type",close:"end_type"},{open:"struct",close:"end_struct"},{open:"program",close:"end_program"},{open:"function",close:"end_function"},{open:"function_block",close:"end_function_block"},{open:"action",close:"end_action"},{open:"step",close:"end_step"},{open:"initial_step",close:"end_step"},{open:"transaction",close:"end_transaction"},{open:"configuration",close:"end_configuration"},{open:"tcp",close:"end_tcp"},{open:"recource",close:"end_recource"},{open:"channel",close:"end_channel"},{open:"library",close:"end_library"},{open:"folder",close:"end_folder"},{open:"binaries",close:"end_binaries"},{open:"includes",close:"end_includes"},{open:"sources",close:"end_sources"}],surroundingPairs:[{open:"{",close:"}"},{open:"[",close:"]"},{open:"(",close:")"},{open:'"',close:'"'},{open:"'",close:"'"},{open:"var",close:"end_var"},{open:"var_input",close:"end_var"},{open:"var_output",close:"end_var"},{open:"var_in_out",close:"end_var"},{open:"var_temp",close:"end_var"},{open:"var_global",close:"end_var"},{open:"var_access",close:"end_var"},{open:"var_external",close:"end_var"},{open:"type",close:"end_type"},{open:"struct",close:"end_struct"},{open:"program",close:"end_program"},{open:"function",close:"end_function"},{open:"function_block",close:"end_function_block"},{open:"action",close:"end_action"},{open:"step",close:"end_step"},{open:"initial_step",close:"end_step"},{open:"transaction",close:"end_transaction"},{open:"configuration",close:"end_configuration"},{open:"tcp",close:"end_tcp"},{open:"recource",close:"end_recource"},{open:"channel",close:"end_channel"},{open:"library",close:"end_library"},{open:"folder",close:"end_folder"},{open:"binaries",close:"end_binaries"},{open:"includes",close:"end_includes"},{open:"sources",close:"end_sources"}],folding:{markers:{start:new RegExp("^\\s*#pragma\\s+region\\b"),end:new RegExp("^\\s*#pragma\\s+endregion\\b")}}},gbt={defaultToken:"",tokenPostfix:".st",ignoreCase:!0,brackets:[{token:"delimiter.curly",open:"{",close:"}"},{token:"delimiter.parenthesis",open:"(",close:")"},{token:"delimiter.square",open:"[",close:"]"}],keywords:["if","end_if","elsif","else","case","of","to","__try","__catch","__finally","do","with","by","while","repeat","end_while","end_repeat","end_case","for","end_for","task","retain","non_retain","constant","with","at","exit","return","interval","priority","address","port","on_channel","then","iec","file","uses","version","packagetype","displayname","copyright","summary","vendor","common_source","from","extends","implements"],constant:["false","true","null"],defineKeywords:["var","var_input","var_output","var_in_out","var_temp","var_global","var_access","var_external","end_var","type","end_type","struct","end_struct","program","end_program","function","end_function","function_block","end_function_block","interface","end_interface","method","end_method","property","end_property","namespace","end_namespace","configuration","end_configuration","tcp","end_tcp","resource","end_resource","channel","end_channel","library","end_library","folder","end_folder","binaries","end_binaries","includes","end_includes","sources","end_sources","action","end_action","step","initial_step","end_step","transaction","end_transaction"],typeKeywords:["int","sint","dint","lint","usint","uint","udint","ulint","real","lreal","time","date","time_of_day","date_and_time","string","bool","byte","word","dword","array","pointer","lword"],operators:["=",">","<",":",":=","<=",">=","<>","&","+","-","*","**","MOD","^","or","and","not","xor","abs","acos","asin","atan","cos","exp","expt","ln","log","sin","sqrt","tan","sel","max","min","limit","mux","shl","shr","rol","ror","indexof","sizeof","adr","adrinst","bitadr","is_valid","ref","ref_to"],builtinVariables:[],builtinFunctions:["sr","rs","tp","ton","tof","eq","ge","le","lt","ne","round","trunc","ctd","\u0441tu","ctud","r_trig","f_trig","move","concat","delete","find","insert","left","len","replace","right","rtc"],symbols:/[=>_bt,language:()=>bbt});var _bt,bbt,V7e=k(()=>{_bt={comments:{lineComment:"//",blockComment:["/*","*/"]},brackets:[["{","}"],["[","]"],["(",")"]],autoClosingPairs:[{open:"{",close:"}"},{open:"[",close:"]"},{open:"(",close:")"},{open:'"',close:'"'},{open:"'",close:"'"},{open:"`",close:"`"}],surroundingPairs:[{open:"{",close:"}"},{open:"[",close:"]"},{open:"(",close:")"},{open:'"',close:'"'},{open:"'",close:"'"},{open:"`",close:"`"}]},bbt={defaultToken:"",tokenPostfix:".swift",identifier:/[a-zA-Z_][\w$]*/,attributes:["@GKInspectable","@IBAction","@IBDesignable","@IBInspectable","@IBOutlet","@IBSegueAction","@NSApplicationMain","@NSCopying","@NSManaged","@Sendable","@UIApplicationMain","@autoclosure","@actorIndependent","@asyncHandler","@available","@convention","@derivative","@differentiable","@discardableResult","@dynamicCallable","@dynamicMemberLookup","@escaping","@frozen","@globalActor","@inlinable","@inline","@main","@noDerivative","@nonobjc","@noreturn","@objc","@objcMembers","@preconcurrency","@propertyWrapper","@requires_stored_property_inits","@resultBuilder","@testable","@unchecked","@unknown","@usableFromInline","@warn_unqualified_access"],accessmodifiers:["open","public","internal","fileprivate","private"],keywords:["#available","#colorLiteral","#column","#dsohandle","#else","#elseif","#endif","#error","#file","#fileID","#fileLiteral","#filePath","#function","#if","#imageLiteral","#keyPath","#line","#selector","#sourceLocation","#warning","Any","Protocol","Self","Type","actor","as","assignment","associatedtype","associativity","async","await","break","case","catch","class","continue","convenience","default","defer","deinit","didSet","do","dynamic","dynamicType","else","enum","extension","fallthrough","false","fileprivate","final","for","func","get","guard","higherThan","if","import","in","indirect","infix","init","inout","internal","is","isolated","lazy","left","let","lowerThan","mutating","nil","none","nonisolated","nonmutating","open","operator","optional","override","postfix","precedence","precedencegroup","prefix","private","protocol","public","repeat","required","rethrows","return","right","safe","self","set","some","static","struct","subscript","super","switch","throw","throws","true","try","typealias","unowned","unsafe","var","weak","where","while","willSet","__consuming","__owned"],symbols:/[=(){}\[\].,:;@#\_&\-<>`?!+*\\\/]/,operatorstart:/[\/=\-+!*%<>&|^~?\u00A1-\u00A7\u00A9\u00AB\u00AC\u00AE\u00B0-\u00B1\u00B6\u00BB\u00BF\u00D7\u00F7\u2016-\u2017\u2020-\u2027\u2030-\u203E\u2041-\u2053\u2055-\u205E\u2190-\u23FF\u2500-\u2775\u2794-\u2BFF\u2E00-\u2E7F\u3001-\u3003\u3008-\u3030]/,operatorend:/[\u0300-\u036F\u1DC0-\u1DFF\u20D0-\u20FF\uFE00-\uFE0F\uFE20-\uFE2F\uE0100-\uE01EF]/,operators:/(@operatorstart)((@operatorstart)|(@operatorend))*/,escapes:/\\(?:[abfnrtv\\"']|x[0-9A-Fa-f]{1,4}|u[0-9A-Fa-f]{4}|U[0-9A-Fa-f]{8})/,tokenizer:{root:[{include:"@whitespace"},{include:"@comment"},{include:"@attribute"},{include:"@literal"},{include:"@keyword"},{include:"@invokedmethod"},{include:"@symbol"}],whitespace:[[/\s+/,"white"],[/"""/,"string.quote","@endDblDocString"]],endDblDocString:[[/[^"]+/,"string"],[/\\"/,"string"],[/"""/,"string.quote","@popall"],[/"/,"string"]],symbol:[[/[{}()\[\]]/,"@brackets"],[/[<>](?!@symbols)/,"@brackets"],[/[.]/,"delimiter"],[/@operators/,"operator"],[/@symbols/,"operator"]],comment:[[/\/\/\/.*$/,"comment.doc"],[/\/\*\*/,"comment.doc","@commentdocbody"],[/\/\/.*$/,"comment"],[/\/\*/,"comment","@commentbody"]],commentdocbody:[[/\/\*/,"comment","@commentbody"],[/\*\//,"comment.doc","@pop"],[/\:[a-zA-Z]+\:/,"comment.doc.param"],[/./,"comment.doc"]],commentbody:[[/\/\*/,"comment","@commentbody"],[/\*\//,"comment","@pop"],[/./,"comment"]],attribute:[[/@@@identifier/,{cases:{"@attributes":"keyword.control","@default":""}}]],literal:[[/"/,{token:"string.quote",next:"@stringlit"}],[/0[b]([01]_?)+/,"number.binary"],[/0[o]([0-7]_?)+/,"number.octal"],[/0[x]([0-9a-fA-F]_?)+([pP][\-+](\d_?)+)?/,"number.hex"],[/(\d_?)*\.(\d_?)+([eE][\-+]?(\d_?)+)?/,"number.float"],[/(\d_?)+/,"number"]],stringlit:[[/\\\(/,{token:"operator",next:"@interpolatedexpression"}],[/@escapes/,"string"],[/\\./,"string.escape.invalid"],[/"/,{token:"string.quote",next:"@pop"}],[/./,"string"]],interpolatedexpression:[[/\(/,{token:"operator",next:"@interpolatedexpression"}],[/\)/,{token:"operator",next:"@pop"}],{include:"@literal"},{include:"@keyword"},{include:"@symbol"}],keyword:[[/`/,{token:"operator",next:"@escapedkeyword"}],[/@identifier/,{cases:{"@keywords":"keyword","[A-Z][a-zA-Z0-9$]*":"type.identifier","@default":"identifier"}}]],escapedkeyword:[[/`/,{token:"operator",next:"@pop"}],[/./,"identifier"]],invokedmethod:[[/([.])(@identifier)/,{cases:{$2:["delimeter","type.identifier"],"@default":""}}]]}};});var Ape={};st(Ape,{conf:()=>vbt,language:()=>xbt});var vbt,xbt,Mpe=k(()=>{vbt={comments:{lineComment:"//",blockComment:["/*","*/"]},brackets:[["{","}"],["[","]"],["(",")"],["begin","end"],["case","endcase"],["casex","endcase"],["casez","endcase"],["checker","endchecker"],["class","endclass"],["clocking","endclocking"],["config","endconfig"],["function","endfunction"],["generate","endgenerate"],["group","endgroup"],["interface","endinterface"],["module","endmodule"],["package","endpackage"],["primitive","endprimitive"],["program","endprogram"],["property","endproperty"],["specify","endspecify"],["sequence","endsequence"],["table","endtable"],["task","endtask"]],autoClosingPairs:[{open:"[",close:"]"},{open:"{",close:"}"},{open:"(",close:")"},{open:"'",close:"'",notIn:["string","comment"]},{open:'"',close:'"',notIn:["string"]}],surroundingPairs:[{open:"{",close:"}"},{open:"[",close:"]"},{open:"(",close:")"},{open:'"',close:'"'},{open:"'",close:"'"}],folding:{offSide:!1,markers:{start:new RegExp("^(?:\\s*|.*(?!\\/[\\/\\*])[^\\w])(?:begin|case(x|z)?|class|clocking|config|covergroup|function|generate|interface|module|package|primitive|property|program|sequence|specify|table|task)\\b"),end:new RegExp("^(?:\\s*|.*(?!\\/[\\/\\*])[^\\w])(?:end|endcase|endclass|endclocking|endconfig|endgroup|endfunction|endgenerate|endinterface|endmodule|endpackage|endprimitive|endproperty|endprogram|endsequence|endspecify|endtable|endtask)\\b")}}},xbt={defaultToken:"",tokenPostfix:".sv",brackets:[{token:"delimiter.curly",open:"{",close:"}"},{token:"delimiter.parenthesis",open:"(",close:")"},{token:"delimiter.square",open:"[",close:"]"},{token:"delimiter.angle",open:"<",close:">"}],keywords:["accept_on","alias","always","always_comb","always_ff","always_latch","and","assert","assign","assume","automatic","before","begin","bind","bins","binsof","bit","break","buf","bufif0","bufif1","byte","case","casex","casez","cell","chandle","checker","class","clocking","cmos","config","const","constraint","context","continue","cover","covergroup","coverpoint","cross","deassign","default","defparam","design","disable","dist","do","edge","else","end","endcase","endchecker","endclass","endclocking","endconfig","endfunction","endgenerate","endgroup","endinterface","endmodule","endpackage","endprimitive","endprogram","endproperty","endspecify","endsequence","endtable","endtask","enum","event","eventually","expect","export","extends","extern","final","first_match","for","force","foreach","forever","fork","forkjoin","function","generate","genvar","global","highz0","highz1","if","iff","ifnone","ignore_bins","illegal_bins","implements","implies","import","incdir","include","initial","inout","input","inside","instance","int","integer","interconnect","interface","intersect","join","join_any","join_none","large","let","liblist","library","local","localparam","logic","longint","macromodule","matches","medium","modport","module","nand","negedge","nettype","new","nexttime","nmos","nor","noshowcancelled","not","notif0","notif1","null","or","output","package","packed","parameter","pmos","posedge","primitive","priority","program","property","protected","pull0","pull1","pulldown","pullup","pulsestyle_ondetect","pulsestyle_onevent","pure","rand","randc","randcase","randsequence","rcmos","real","realtime","ref","reg","reject_on","release","repeat","restrict","return","rnmos","rpmos","rtran","rtranif0","rtranif1","s_always","s_eventually","s_nexttime","s_until","s_until_with","scalared","sequence","shortint","shortreal","showcancelled","signed","small","soft","solve","specify","specparam","static","string","strong","strong0","strong1","struct","super","supply0","supply1","sync_accept_on","sync_reject_on","table","tagged","task","this","throughout","time","timeprecision","timeunit","tran","tranif0","tranif1","tri","tri0","tri1","triand","trior","trireg","type","typedef","union","unique","unique0","unsigned","until","until_with","untyped","use","uwire","var","vectored","virtual","void","wait","wait_order","wand","weak","weak0","weak1","while","wildcard","wire","with","within","wor","xnor","xor"],builtin_gates:["and","nand","nor","or","xor","xnor","buf","not","bufif0","bufif1","notif1","notif0","cmos","nmos","pmos","rcmos","rnmos","rpmos","tran","tranif1","tranif0","rtran","rtranif1","rtranif0"],operators:["=","+=","-=","*=","/=","%=","&=","|=","^=","<<=",">>+","<<<=",">>>=","?",":","+","-","!","~","&","~&","|","~|","^","~^","^~","+","-","*","/","%","==","!=","===","!==","==?","!=?","&&","||","**","<","<=",">",">=","&","|","^",">>","<<",">>>","<<<","++","--","->","<->","inside","dist","::","+:","-:","*>","&&&","|->","|=>","#=#"],symbols:/[=>](?!@symbols)/,"@brackets"],[/@symbols/,{cases:{"@operators":"delimiter","@default":""}}],{include:"@numbers"},[/[;,.]/,"delimiter"],{include:"@strings"}],identifier_or_keyword:[[/@identifier/,{cases:{"@keywords":{token:"keyword.$0"},"@default":"identifier"}}]],numbers:[[/\d+?[\d_]*(?:\.[\d_]+)?[eE][\-+]?\d+/,"number.float"],[/\d+?[\d_]*\.[\d_]+(?:\s*@timeunits)?/,"number.float"],[/(?:\d+?[\d_]*\s*)?'[sS]?[dD]\s*[0-9xXzZ?]+?[0-9xXzZ?_]*/,"number"],[/(?:\d+?[\d_]*\s*)?'[sS]?[bB]\s*[0-1xXzZ?]+?[0-1xXzZ?_]*/,"number.binary"],[/(?:\d+?[\d_]*\s*)?'[sS]?[oO]\s*[0-7xXzZ?]+?[0-7xXzZ?_]*/,"number.octal"],[/(?:\d+?[\d_]*\s*)?'[sS]?[hH]\s*[0-9a-fA-FxXzZ?]+?[0-9a-fA-FxXzZ?_]*/,"number.hex"],[/1step/,"number"],[/[\dxXzZ]+?[\dxXzZ_]*(?:\s*@timeunits)?/,"number"],[/'[01xXzZ]+/,"number"]],module_instance:[{include:"@whitespace"},[/(#?)(\()/,["",{token:"@brackets",next:"@port_connection"}]],[/@identifier\s*[;={}\[\],]/,{token:"@rematch",next:"@pop"}],[/@symbols|[;={}\[\],]/,{token:"@rematch",next:"@pop"}],[/@identifier/,"type"],[/;/,"delimiter","@pop"]],port_connection:[{include:"@identifier_or_keyword"},{include:"@whitespace"},[/@systemcall/,"variable.predefined"],{include:"@numbers"},{include:"@strings"},[/[,]/,"delimiter"],[/\(/,"@brackets","@port_connection"],[/\)/,"@brackets","@pop"]],whitespace:[[/[ \t\r\n]+/,""],[/\/\*/,"comment","@comment"],[/\/\/.*$/,"comment"]],comment:[[/[^\/*]+/,"comment"],[/\*\//,"comment","@pop"],[/[\/*]/,"comment"]],strings:[[/"([^"\\]|\\.)*$/,"string.invalid"],[/"/,"string","@string"]],string:[[/[^\\"]+/,"string"],[/@escapes/,"string.escape"],[/\\./,"string.escape.invalid"],[/"/,"string","@pop"]],include:[[/(\s*)(")([\w*\/*]*)(.\w*)(")/,["","string.include.identifier","string.include.identifier","string.include.identifier",{token:"string.include.identifier",next:"@pop"}]],[/(\s*)(<)([\w*\/*]*)(.\w*)(>)/,["","string.include.identifier","string.include.identifier","string.include.identifier",{token:"string.include.identifier",next:"@pop"}]]],table:[{include:"@whitespace"},[/[()]/,"@brackets"],[/[:;]/,"delimiter"],[/[01\-*?xXbBrRfFpPnN]/,"variable.predefined"],["endtable","keyword.endtable","@pop"]]}}});var U7e={};st(U7e,{conf:()=>wbt,language:()=>ybt});var wbt,ybt,$7e=k(()=>{wbt={brackets:[["{","}"],["[","]"],["(",")"]],autoClosingPairs:[{open:"{",close:"}"},{open:"[",close:"]"},{open:"(",close:")"},{open:'"',close:'"'},{open:"'",close:"'"}],surroundingPairs:[{open:"{",close:"}"},{open:"[",close:"]"},{open:"(",close:")"},{open:'"',close:'"'},{open:"'",close:"'"}]},ybt={tokenPostfix:".tcl",specialFunctions:["set","unset","rename","variable","proc","coroutine","foreach","incr","append","lappend","linsert","lreplace"],mainFunctions:["if","then","elseif","else","case","switch","while","for","break","continue","return","package","namespace","catch","exit","eval","expr","uplevel","upvar"],builtinFunctions:["file","info","concat","join","lindex","list","llength","lrange","lsearch","lsort","split","array","parray","binary","format","regexp","regsub","scan","string","subst","dict","cd","clock","exec","glob","pid","pwd","close","eof","fblocked","fconfigure","fcopy","fileevent","flush","gets","open","puts","read","seek","socket","tell","interp","after","auto_execok","auto_load","auto_mkindex","auto_reset","bgerror","error","global","history","load","source","time","trace","unknown","unset","update","vwait","winfo","wm","bind","event","pack","place","grid","font","bell","clipboard","destroy","focus","grab","lower","option","raise","selection","send","tk","tkwait","tk_bisque","tk_focusNext","tk_focusPrev","tk_focusFollowsMouse","tk_popup","tk_setPalette"],symbols:/[=>Cbt,language:()=>Sbt});var Cbt,Sbt,q7e=k(()=>{Cbt={wordPattern:/(-?\d*\.\d\w*)|([^\`\~\!\@\$\^\&\*\(\)\=\+\[\{\]\}\\\|\;\:\'\"\,\.\<\>\/\s]+)/g,comments:{blockComment:["{#","#}"]},brackets:[["{#","#}"],["{%","%}"],["{{","}}"],["(",")"],["[","]"],[""],["<",">"]],autoClosingPairs:[{open:"{# ",close:" #}"},{open:"{% ",close:" %}"},{open:"{{ ",close:" }}"},{open:"[",close:"]"},{open:"(",close:")"},{open:'"',close:'"'},{open:"'",close:"'"}],surroundingPairs:[{open:'"',close:'"'},{open:"'",close:"'"},{open:"<",close:">"}]},Sbt={defaultToken:"",tokenPostfix:"",ignoreCase:!0,keywords:["apply","autoescape","block","deprecated","do","embed","extends","flush","for","from","if","import","include","macro","sandbox","set","use","verbatim","with","endapply","endautoescape","endblock","endembed","endfor","endif","endmacro","endsandbox","endset","endwith","true","false"],tokenizer:{root:[[/\s+/],[/{#/,"comment.twig","@commentState"],[/{%[-~]?/,"delimiter.twig","@blockState"],[/{{[-~]?/,"delimiter.twig","@variableState"],[/)/,["delimiter.html","tag.html","","delimiter.html"]],[/(<)(script)/,["delimiter.html",{token:"tag.html",next:"@script"}]],[/(<)(style)/,["delimiter.html",{token:"tag.html",next:"@style"}]],[/(<)((?:[\w\-]+:)?[\w\-]+)/,["delimiter.html",{token:"tag.html",next:"@otherTag"}]],[/(<\/)((?:[\w\-]+:)?[\w\-]+)/,["delimiter.html",{token:"tag.html",next:"@otherTag"}]],[/|>=|<=/,"operators.twig"],[/(starts with|ends with|matches)(\s+)/,["operators.twig",""]],[/(in)(\s+)/,["operators.twig",""]],[/(is)(\s+)/,["operators.twig",""]],[/\||~|:|\.{1,2}|\?{1,2}/,"operators.twig"],[/[^\W\d][\w]*/,{cases:{"@keywords":"keyword.twig","@default":"variable.twig"}}],[/\d+(\.\d+)?/,"number.twig"],[/\(|\)|\[|\]|{|}|,/,"delimiter.twig"],[/"([^#"\\]*(?:\\.[^#"\\]*)*)"|\'([^\'\\]*(?:\\.[^\'\\]*)*)\'/,"string.twig"],[/"/,"string.twig","@stringState"],[/=>/,"operators.twig"],[/=/,"operators.twig"]],doctype:[[/[^>]+/,"metatag.content.html"],[/>/,"metatag.html","@pop"]],comment:[[/-->/,"comment.html","@pop"],[/[^-]+/,"comment.content.html"],[/./,"comment.content.html"]],otherTag:[[/\/?>/,"delimiter.html","@pop"],[/"([^"]*)"/,"attribute.value.html"],[/'([^']*)'/,"attribute.value.html"],[/[\w\-]+/,"attribute.name.html"],[/=/,"delimiter.html"],[/[ \t\r\n]+/]],script:[[/type/,"attribute.name.html","@scriptAfterType"],[/"([^"]*)"/,"attribute.value.html"],[/'([^']*)'/,"attribute.value.html"],[/[\w\-]+/,"attribute.name.html"],[/=/,"delimiter.html"],[/>/,{token:"delimiter.html",next:"@scriptEmbedded",nextEmbedded:"text/javascript"}],[/[ \t\r\n]+/],[/(<\/)(script\s*)(>)/,["delimiter.html","tag.html",{token:"delimiter.html",next:"@pop"}]]],scriptAfterType:[[/=/,"delimiter.html","@scriptAfterTypeEquals"],[/>/,{token:"delimiter.html",next:"@scriptEmbedded",nextEmbedded:"text/javascript"}],[/[ \t\r\n]+/],[/<\/script\s*>/,{token:"@rematch",next:"@pop"}]],scriptAfterTypeEquals:[[/"([^"]*)"/,{token:"attribute.value.html",switchTo:"@scriptWithCustomType.$1"}],[/'([^']*)'/,{token:"attribute.value.html",switchTo:"@scriptWithCustomType.$1"}],[/>/,{token:"delimiter.html",next:"@scriptEmbedded",nextEmbedded:"text/javascript"}],[/[ \t\r\n]+/],[/<\/script\s*>/,{token:"@rematch",next:"@pop"}]],scriptWithCustomType:[[/>/,{token:"delimiter.html",next:"@scriptEmbedded.$S2",nextEmbedded:"$S2"}],[/"([^"]*)"/,"attribute.value.html"],[/'([^']*)'/,"attribute.value.html"],[/[\w\-]+/,"attribute.name.html"],[/=/,"delimiter.html"],[/[ \t\r\n]+/],[/<\/script\s*>/,{token:"@rematch",next:"@pop"}]],scriptEmbedded:[[/<\/script/,{token:"@rematch",next:"@pop",nextEmbedded:"@pop"}],[/[^<]+/,""]],style:[[/type/,"attribute.name.html","@styleAfterType"],[/"([^"]*)"/,"attribute.value.html"],[/'([^']*)'/,"attribute.value.html"],[/[\w\-]+/,"attribute.name.html"],[/=/,"delimiter.html"],[/>/,{token:"delimiter.html",next:"@styleEmbedded",nextEmbedded:"text/css"}],[/[ \t\r\n]+/],[/(<\/)(style\s*)(>)/,["delimiter.html","tag.html",{token:"delimiter.html",next:"@pop"}]]],styleAfterType:[[/=/,"delimiter.html","@styleAfterTypeEquals"],[/>/,{token:"delimiter.html",next:"@styleEmbedded",nextEmbedded:"text/css"}],[/[ \t\r\n]+/],[/<\/style\s*>/,{token:"@rematch",next:"@pop"}]],styleAfterTypeEquals:[[/"([^"]*)"/,{token:"attribute.value.html",switchTo:"@styleWithCustomType.$1"}],[/'([^']*)'/,{token:"attribute.value.html",switchTo:"@styleWithCustomType.$1"}],[/>/,{token:"delimiter.html",next:"@styleEmbedded",nextEmbedded:"text/css"}],[/[ \t\r\n]+/],[/<\/style\s*>/,{token:"@rematch",next:"@pop"}]],styleWithCustomType:[[/>/,{token:"delimiter.html",next:"@styleEmbedded.$S2",nextEmbedded:"$S2"}],[/"([^"]*)"/,"attribute.value.html"],[/'([^']*)'/,"attribute.value.html"],[/[\w\-]+/,"attribute.name.html"],[/=/,"delimiter.html"],[/[ \t\r\n]+/],[/<\/style\s*>/,{token:"@rematch",next:"@pop"}]],styleEmbedded:[[/<\/style/,{token:"@rematch",next:"@pop",nextEmbedded:"@pop"}],[/[^<]+/,""]]}}});var Z7e={};st(Z7e,{conf:()=>Rbt,language:()=>Abt});var Y7e,K7e,kbt,Lbt,G7e,Ibt,Ebt,Tbt,Dbt,Nbt,Rbt,Abt,X7e=k(()=>{Y7e=n=>`\\b${n}\\b`,K7e=n=>`(?!${n})`,kbt="[_a-zA-Z]",Lbt="[_a-zA-Z0-9]",G7e=Y7e(`${kbt}${Lbt}*`),Ibt=Y7e("[_a-zA-Z-0-9]+"),Ebt=["import","model","scalar","namespace","op","interface","union","using","is","extends","enum","alias","return","void","if","else","projection","dec","extern","fn"],Tbt=["true","false","null","unknown","never"],Dbt="[ \\t\\r\\n]",Nbt="[0-9]+",Rbt={comments:{lineComment:"//",blockComment:["/*","*/"]},brackets:[["{","}"],["[","]"],["(",")"]],autoClosingPairs:[{open:"{",close:"}"},{open:"[",close:"]"},{open:"(",close:")"},{open:'"',close:'"'},{open:"/**",close:" */",notIn:["string"]}],surroundingPairs:[{open:"{",close:"}"},{open:"[",close:"]"},{open:"(",close:")"},{open:'"',close:'"'}],indentationRules:{decreaseIndentPattern:new RegExp("^((?!.*?/\\*).*\\*/)?\\s*[\\}\\]].*$"),increaseIndentPattern:new RegExp("^((?!//).)*(\\{([^}\"'`/]*|(\\t|[ ])*//.*)|\\([^)\"'`/]*|\\[[^\\]\"'`/]*)$"),unIndentedLinePattern:new RegExp("^(\\t|[ ])*[ ]\\*[^/]*\\*/\\s*$|^(\\t|[ ])*[ ]\\*/\\s*$|^(\\t|[ ])*[ ]\\*([ ]([^\\*]|\\*(?!/))*)?$")}},Abt={defaultToken:"",tokenPostfix:".tsp",brackets:[{open:"{",close:"}",token:"delimiter.curly"},{open:"[",close:"]",token:"delimiter.square"},{open:"(",close:")",token:"delimiter.parenthesis"}],symbols:/[=:;<>]+/,keywords:Ebt,namedLiterals:Tbt,escapes:'\\\\(u{[0-9A-Fa-f]+}|n|r|t|\\\\|"|\\${)',tokenizer:{root:[{include:"@expression"},{include:"@whitespace"}],stringVerbatim:[{regex:'(|"|"")[^"]',action:{token:"string"}},{regex:`"""${K7e('"')}`,action:{token:"string",next:"@pop"}}],stringLiteral:[{regex:"\\${",action:{token:"delimiter.bracket",next:"@bracketCounting"}},{regex:'[^\\\\"$]+',action:{token:"string"}},{regex:"@escapes",action:{token:"string.escape"}},{regex:"\\\\.",action:{token:"string.escape.invalid"}},{regex:'"',action:{token:"string",next:"@pop"}}],bracketCounting:[{regex:"{",action:{token:"delimiter.bracket",next:"@bracketCounting"}},{regex:"}",action:{token:"delimiter.bracket",next:"@pop"}},{include:"@expression"}],comment:[{regex:"[^\\*]+",action:{token:"comment"}},{regex:"\\*\\/",action:{token:"comment",next:"@pop"}},{regex:"[\\/*]",action:{token:"comment"}}],whitespace:[{regex:Dbt},{regex:"\\/\\*",action:{token:"comment",next:"@comment"}},{regex:"\\/\\/.*$",action:{token:"comment"}}],expression:[{regex:'"""',action:{token:"string",next:"@stringVerbatim"}},{regex:`"${K7e('""')}`,action:{token:"string",next:"@stringLiteral"}},{regex:Nbt,action:{token:"number"}},{regex:G7e,action:{cases:{"@keywords":{token:"keyword"},"@namedLiterals":{token:"keyword"},"@default":{token:"identifier"}}}},{regex:`@${G7e}`,action:{token:"tag"}},{regex:`#${Ibt}`,action:{token:"directive"}}]}}});var Q7e={};st(Q7e,{conf:()=>Mbt,language:()=>Pbt});var Mbt,Pbt,J7e=k(()=>{Mbt={comments:{lineComment:"'",blockComment:["/*","*/"]},brackets:[["{","}"],["[","]"],["(",")"],["<",">"],["addhandler","end addhandler"],["class","end class"],["enum","end enum"],["event","end event"],["function","end function"],["get","end get"],["if","end if"],["interface","end interface"],["module","end module"],["namespace","end namespace"],["operator","end operator"],["property","end property"],["raiseevent","end raiseevent"],["removehandler","end removehandler"],["select","end select"],["set","end set"],["structure","end structure"],["sub","end sub"],["synclock","end synclock"],["try","end try"],["while","end while"],["with","end with"],["using","end using"],["do","loop"],["for","next"]],autoClosingPairs:[{open:"{",close:"}",notIn:["string","comment"]},{open:"[",close:"]",notIn:["string","comment"]},{open:"(",close:")",notIn:["string","comment"]},{open:'"',close:'"',notIn:["string","comment"]},{open:"<",close:">",notIn:["string","comment"]}],folding:{markers:{start:new RegExp("^\\s*#Region\\b"),end:new RegExp("^\\s*#End Region\\b")}}},Pbt={defaultToken:"",tokenPostfix:".vb",ignoreCase:!0,brackets:[{token:"delimiter.bracket",open:"{",close:"}"},{token:"delimiter.array",open:"[",close:"]"},{token:"delimiter.parenthesis",open:"(",close:")"},{token:"delimiter.angle",open:"<",close:">"},{token:"keyword.tag-addhandler",open:"addhandler",close:"end addhandler"},{token:"keyword.tag-class",open:"class",close:"end class"},{token:"keyword.tag-enum",open:"enum",close:"end enum"},{token:"keyword.tag-event",open:"event",close:"end event"},{token:"keyword.tag-function",open:"function",close:"end function"},{token:"keyword.tag-get",open:"get",close:"end get"},{token:"keyword.tag-if",open:"if",close:"end if"},{token:"keyword.tag-interface",open:"interface",close:"end interface"},{token:"keyword.tag-module",open:"module",close:"end module"},{token:"keyword.tag-namespace",open:"namespace",close:"end namespace"},{token:"keyword.tag-operator",open:"operator",close:"end operator"},{token:"keyword.tag-property",open:"property",close:"end property"},{token:"keyword.tag-raiseevent",open:"raiseevent",close:"end raiseevent"},{token:"keyword.tag-removehandler",open:"removehandler",close:"end removehandler"},{token:"keyword.tag-select",open:"select",close:"end select"},{token:"keyword.tag-set",open:"set",close:"end set"},{token:"keyword.tag-structure",open:"structure",close:"end structure"},{token:"keyword.tag-sub",open:"sub",close:"end sub"},{token:"keyword.tag-synclock",open:"synclock",close:"end synclock"},{token:"keyword.tag-try",open:"try",close:"end try"},{token:"keyword.tag-while",open:"while",close:"end while"},{token:"keyword.tag-with",open:"with",close:"end with"},{token:"keyword.tag-using",open:"using",close:"end using"},{token:"keyword.tag-do",open:"do",close:"loop"},{token:"keyword.tag-for",open:"for",close:"next"}],keywords:["AddHandler","AddressOf","Alias","And","AndAlso","As","Async","Boolean","ByRef","Byte","ByVal","Call","Case","Catch","CBool","CByte","CChar","CDate","CDbl","CDec","Char","CInt","Class","CLng","CObj","Const","Continue","CSByte","CShort","CSng","CStr","CType","CUInt","CULng","CUShort","Date","Decimal","Declare","Default","Delegate","Dim","DirectCast","Do","Double","Each","Else","ElseIf","End","EndIf","Enum","Erase","Error","Event","Exit","False","Finally","For","Friend","Function","Get","GetType","GetXMLNamespace","Global","GoSub","GoTo","Handles","If","Implements","Imports","In","Inherits","Integer","Interface","Is","IsNot","Let","Lib","Like","Long","Loop","Me","Mod","Module","MustInherit","MustOverride","MyBase","MyClass","NameOf","Namespace","Narrowing","New","Next","Not","Nothing","NotInheritable","NotOverridable","Object","Of","On","Operator","Option","Optional","Or","OrElse","Out","Overloads","Overridable","Overrides","ParamArray","Partial","Private","Property","Protected","Public","RaiseEvent","ReadOnly","ReDim","RemoveHandler","Resume","Return","SByte","Select","Set","Shadows","Shared","Short","Single","Static","Step","Stop","String","Structure","Sub","SyncLock","Then","Throw","To","True","Try","TryCast","TypeOf","UInteger","ULong","UShort","Using","Variant","Wend","When","While","Widening","With","WithEvents","WriteOnly","Xor"],tagwords:["If","Sub","Select","Try","Class","Enum","Function","Get","Interface","Module","Namespace","Operator","Set","Structure","Using","While","With","Do","Loop","For","Next","Property","Continue","AddHandler","RemoveHandler","Event","RaiseEvent","SyncLock"],symbols:/[=>Obt,language:()=>Kbt});function Jb(n){let e=[],t=n.split(/\t+|\r+|\n+| +/);for(let i=0;i0&&e.push(t[i]);return e}var Obt,Fbt,Bbt,Wbt,Hbt,zbt,Vbt,Ubt,$bt,jbt,qbt,eWe,fT,Kbt,iWe=k(()=>{Obt={comments:{lineComment:"//",blockComment:["/*","*/"]},brackets:[["{","}"],["[","]"],["(",")"]],autoClosingPairs:[{open:"[",close:"]"},{open:"{",close:"}"},{open:"(",close:")"}],surroundingPairs:[{open:"{",close:"}"},{open:"[",close:"]"},{open:"(",close:")"}]};Fbt=Jb("true false"),Bbt=Jb(` alias break case const const_assert continue continuing default diagnostic discard else enable fn for if let loop override requires return struct switch var while `),Wbt=Jb(` NULL Self abstract active alignas alignof as asm asm_fragment async attribute auto await become binding_array cast catch class co_await co_return co_yield coherent column_major common compile compile_fragment concept const_cast consteval constexpr constinit crate debugger decltype delete demote demote_to_helper do dynamic_cast enum explicit export extends extern external fallthrough filter final finally friend from fxgroup get goto groupshared highp impl implements import inline instanceof interface layout lowp macro macro_rules match mediump meta mod module move mut mutable namespace new nil noexcept noinline nointerpolation noperspective null nullptr of operator package packoffset partition pass patch pixelfragment precise precision premerge priv protected pub public readonly ref regardless register reinterpret_cast require resource restrict self set shared sizeof smooth snorm static static_assert static_cast std subroutine super target template this thread_local throw trait try type typedef typeid typename typeof union unless unorm unsafe unsized use using varying virtual volatile wgsl where with writeonly yield `),Hbt=Jb(` read write read_write function private workgroup uniform storage perspective linear flat center centroid sample vertex_index instance_index position front_facing frag_depth local_invocation_id local_invocation_index global_invocation_id workgroup_id num_workgroups sample_index sample_mask rgba8unorm rgba8snorm rgba8uint rgba8sint rgba16uint rgba16sint rgba16float r32uint r32sint r32float rg32uint rg32sint rg32float rgba32uint rgba32sint rgba32float bgra8unorm `),zbt=Jb(` bool f16 f32 i32 sampler sampler_comparison texture_depth_2d texture_depth_2d_array texture_depth_cube texture_depth_cube_array texture_depth_multisampled_2d texture_external texture_external u32 `),Vbt=Jb(` array atomic mat2x2 mat2x3 mat2x4 mat3x2 mat3x3 mat3x4 mat4x2 mat4x3 mat4x4 ptr texture_1d texture_2d texture_2d_array texture_3d texture_cube texture_cube_array texture_multisampled_2d texture_storage_1d texture_storage_2d texture_storage_2d_array texture_storage_3d vec2 vec3 vec4 `),Ubt=Jb(` vec2i vec3i vec4i vec2u vec3u vec4u vec2f vec3f vec4f vec2h vec3h vec4h mat2x2f mat2x3f mat2x4f mat3x2f mat3x3f mat3x4f mat4x2f mat4x3f mat4x4f mat2x2h mat2x3h mat2x4h mat3x2h mat3x3h mat3x4h mat4x2h mat4x3h mat4x4h `),$bt=Jb(` bitcast all any select arrayLength abs acos acosh asin asinh atan atanh atan2 ceil clamp cos cosh countLeadingZeros countOneBits countTrailingZeros cross degrees determinant distance dot exp exp2 extractBits faceForward firstLeadingBit firstTrailingBit floor fma fract frexp inverseBits inverseSqrt ldexp length log log2 max min mix modf normalize pow quantizeToF16 radians reflect refract reverseBits round saturate sign sin sinh smoothstep sqrt step tan tanh transpose trunc dpdx dpdxCoarse dpdxFine dpdy dpdyCoarse dpdyFine fwidth fwidthCoarse fwidthFine textureDimensions textureGather textureGatherCompare textureLoad textureNumLayers textureNumLevels textureNumSamples textureSample textureSampleBias textureSampleCompare textureSampleCompareLevel textureSampleGrad textureSampleLevel textureSampleBaseClampToEdge textureStore atomicLoad atomicStore atomicAdd atomicSub atomicMax atomicMin atomicAnd atomicOr atomicXor atomicExchange atomicCompareExchangeWeak pack4x8snorm pack4x8unorm pack2x16snorm pack2x16unorm pack2x16float unpack4x8snorm unpack4x8unorm unpack2x16snorm unpack2x16unorm unpack2x16float storageBarrier workgroupBarrier workgroupUniformLoad `),jbt=Jb(` & && -> / = == != > >= < <= % - -- + ++ | || * << >> += -= *= /= %= &= |= ^= >>= <<= `),qbt=/enable|requires|diagnostic/,eWe=/[_\p{XID_Start}]\p{XID_Continue}*/u,fT="variable.predefined",Kbt={tokenPostfix:".wgsl",defaultToken:"invalid",unicode:!0,atoms:Fbt,keywords:Bbt,reserved:Wbt,predeclared_enums:Hbt,predeclared_types:zbt,predeclared_type_generators:Vbt,predeclared_type_aliases:Ubt,predeclared_intrinsics:$bt,operators:jbt,symbols:/[!%&*+\-\.\/:;<=>^|_~,]+/,tokenizer:{root:[[qbt,"keyword","@directive"],[eWe,{cases:{"@atoms":fT,"@keywords":"keyword","@reserved":"invalid","@predeclared_enums":fT,"@predeclared_types":fT,"@predeclared_type_generators":fT,"@predeclared_type_aliases":fT,"@predeclared_intrinsics":fT,"@default":"identifier"}}],{include:"@commentOrSpace"},{include:"@numbers"},[/[{}()\[\]]/,"@brackets"],["@","annotation","@attribute"],[/@symbols/,{cases:{"@operators":"operator","@default":"delimiter"}}],[/./,"invalid"]],commentOrSpace:[[/\s+/,"white"],[/\/\*/,"comment","@blockComment"],[/\/\/.*$/,"comment"]],blockComment:[[/[^\/*]+/,"comment"],[/\/\*/,"comment","@push"],[/\*\//,"comment","@pop"],[/[\/*]/,"comment"]],attribute:[{include:"@commentOrSpace"},[/\w+/,"annotation","@pop"]],directive:[{include:"@commentOrSpace"},[/[()]/,"@brackets"],[/,/,"delimiter"],[eWe,"meta.content"],[/;/,"delimiter","@pop"]],numbers:[[/0[fh]/,"number.float"],[/[1-9][0-9]*[fh]/,"number.float"],[/[0-9]*\.[0-9]+([eE][+-]?[0-9]+)?[fh]?/,"number.float"],[/[0-9]+\.[0-9]*([eE][+-]?[0-9]+)?[fh]?/,"number.float"],[/[0-9]+[eE][+-]?[0-9]+[fh]?/,"number.float"],[/0[xX][0-9a-fA-F]*\.[0-9a-fA-F]+(?:[pP][+-]?[0-9]+[fh]?)?/,"number.hex"],[/0[xX][0-9a-fA-F]+\.[0-9a-fA-F]*(?:[pP][+-]?[0-9]+[fh]?)?/,"number.hex"],[/0[xX][0-9a-fA-F]+[pP][+-]?[0-9]+[fh]?/,"number.hex"],[/0[xX][0-9a-fA-F]+[iu]?/,"number.hex"],[/[1-9][0-9]*[iu]?/,"number"],[/0[iu]?/,"number"]]}}});var oWe={};st(oWe,{conf:()=>Jbt,language:()=>evt});var Gbt,Ybt,Zbt,Xbt,nWe,Qbt,Ppe,Jbt,evt,rWe=k(()=>{Ir();Gbt=Object.defineProperty,Ybt=Object.getOwnPropertyDescriptor,Zbt=Object.getOwnPropertyNames,Xbt=Object.prototype.hasOwnProperty,nWe=(n,e,t,i)=>{if(e&&typeof e=="object"||typeof e=="function")for(let o of Zbt(e))!Xbt.call(n,o)&&o!==t&&Gbt(n,o,{get:()=>e[o],enumerable:!(i=Ybt(e,o))||i.enumerable});return n},Qbt=(n,e,t)=>(nWe(n,e,"default"),t&&nWe(t,e,"default")),Ppe={};Qbt(Ppe,fn);Jbt={comments:{blockComment:[""]},brackets:[["<",">"]],autoClosingPairs:[{open:"<",close:">"},{open:"'",close:"'"},{open:'"',close:'"'}],surroundingPairs:[{open:"<",close:">"},{open:"'",close:"'"},{open:'"',close:'"'}],onEnterRules:[{beforeText:new RegExp("<([_:\\w][_:\\w-.\\d]*)([^/>]*(?!/)>)[^<]*$","i"),afterText:/^<\/([_:\w][_:\w-.\d]*)\s*>$/i,action:{indentAction:Ppe.languages.IndentAction.IndentOutdent}},{beforeText:new RegExp("<(\\w[\\w\\d]*)([^/>]*(?!/)>)[^<]*$","i"),action:{indentAction:Ppe.languages.IndentAction.Indent}}]},evt={defaultToken:"",tokenPostfix:".xml",ignoreCase:!0,qualifiedName:/(?:[\w\.\-]+:)?[\w\.\-]+/,tokenizer:{root:[[/[^<&]+/,""],{include:"@whitespace"},[/(<)(@qualifiedName)/,[{token:"delimiter"},{token:"tag",next:"@tag"}]],[/(<\/)(@qualifiedName)(\s*)(>)/,[{token:"delimiter"},{token:"tag"},"",{token:"delimiter"}]],[/(<\?)(@qualifiedName)/,[{token:"delimiter"},{token:"metatag",next:"@tag"}]],[/(<\!)(@qualifiedName)/,[{token:"delimiter"},{token:"metatag",next:"@tag"}]],[/<\!\[CDATA\[/,{token:"delimiter.cdata",next:"@cdata"}],[/&\w+;/,"string.escape"]],cdata:[[/[^\]]+/,""],[/\]\]>/,{token:"delimiter.cdata",next:"@pop"}],[/\]/,""]],tag:[[/[ \t\r\n]+/,""],[/(@qualifiedName)(\s*=\s*)("[^"]*"|'[^']*')/,["attribute.name","","attribute.value"]],[/(@qualifiedName)(\s*=\s*)("[^">?\/]*|'[^'>?\/]*)(?=[\?\/]\>)/,["attribute.name","","attribute.value"]],[/(@qualifiedName)(\s*=\s*)("[^">]*|'[^'>]*)/,["attribute.name","","attribute.value"]],[/@qualifiedName/,"attribute.name"],[/\?>/,{token:"delimiter",next:"@pop"}],[/(\/)(>)/,[{token:"tag"},{token:"delimiter",next:"@pop"}]],[/>/,{token:"delimiter",next:"@pop"}]],whitespace:[[/[ \t\r\n]+/,""],[//,{token:"comment",next:"@pop"}],[/=0&&a.resolve(Ze.None)}return e}};Wwe=Yqe([M4(5,CD)],Wwe);var Hwe=class extends D{constructor(e,t,i,o){super(),this._languageFeatureService=e,this._clipboardService=t,this._suggestMemoryService=i,this._editorService=o,this._store.add(e.inlineCompletionsProvider.register("*",this))}async provideInlineCompletions(e,t,i,o){if(i.selectedSuggestionInfo)return;let r;for(let f of this._editorService.listCodeEditors())if(f.getModel()===e){r=f;break}if(!r)return;let s=r.getOption(90);if(t_.isAllOff(s))return;e.tokenization.tokenizeIfCheap(t.lineNumber);let a=e.tokenization.getLineTokens(t.lineNumber),l=a.getStandardTokenType(a.findTokenIndexAtOffset(Math.max(t.column-1-1,0)));if(t_.valueFor(s,l)!=="inline")return;let c=e.getWordAtPosition(t),d;if(c?.word||(d=this._getTriggerCharacterInfo(e,t)),!c?.word&&!d||(c||(c=e.getWordUntilPosition(t)),c.endColumn!==t.column))return;let u,h=e.getValueInRange(new S(t.lineNumber,1,t.lineNumber,t.column));if(!d&&this._lastResult?.canBeReused(e,t.lineNumber,c)){let f=new r4(h,t.column-this._lastResult.word.endColumn);this._lastResult.completionModel.lineContext=f,this._lastResult.acquire(),u=this._lastResult}else{let f=await qO(this._languageFeatureService.completionProvider,e,t,new dS(void 0,ID.createSuggestFilter(r).itemKind,d?.providers),d&&{triggerKind:1,triggerCharacter:d.ch},o),p;f.needsClipboard&&(p=await this._clipboardService.readText());let g=new LD(f.items,t.column,new r4(h,0),kD.None,r.getOption(119),r.getOption(113),{boostFullMatch:!1,firstMatchCanBeWeak:!1},p);u=new Wwe(e,t.lineNumber,c,g,f,this._suggestMemoryService)}return this._lastResult=u,u}handleItemDidShow(e,t){t.completion.resolve(Ze.None)}freeInlineCompletions(e){e.release()}_getTriggerCharacterInfo(e,t){let i=e.getValueInRange(S.fromPositions({lineNumber:t.lineNumber,column:t.column-1},t)),o=new Set;for(let r of this._languageFeatureService.completionProvider.all(e))r.triggerCharacters?.includes(i)&&o.add(r);if(o.size!==0)return{providers:o,ch:i}}};Hwe=Yqe([M4(0,le),M4(1,gc),M4(2,CD),M4(3,xt)],Hwe);Rf(Hwe);kl();mt();pe();var zwe=class extends fe{constructor(){super({id:"editor.action.forceRetokenize",label:m("forceRetokenize","Developer: Force Retokenize"),alias:"Developer: Force Retokenize",precondition:void 0})}run(e,t){if(!t.hasModel())return;let i=t.getModel();i.tokenization.resetTokenization();let o=new cn;i.tokenization.forceTokenization(i.getLineCount()),o.stop(),console.log(`tokenization took ${o.elapsed()}`)}};ee(zwe);Ns();fV();pe();an();var Vwe=class n extends vr{static{this.ID="editor.action.toggleTabFocusMode"}constructor(){super({id:n.ID,title:et({key:"toggle.tabMovesFocus",comment:["Turn on/off use of tab key for moving focus around VS Code"]},"Toggle Tab Key Moves Focus"),precondition:void 0,keybinding:{primary:2091,mac:{primary:1323},weight:100},metadata:{description:et("tabMovesFocusDescriptions","Determines whether the tab key moves focus around the workbench or inserts the tab character in the current editor. This is also called tab trapping, tab navigation, or tab focus mode.")},f1:!0})}run(){let t=!Bb.getTabFocusMode();Bb.setTabFocusMode(t),t?Bo(m("toggle.tabMovesFocus.on","Pressing Tab will now move focus to the next focusable element")):Bo(m("toggle.tabMovesFocus.off","Pressing Tab will now insert the tab character"))}};zi(Vwe);ft();Qi();Pl();j();Bt();Qe();mt();ir();Ho();gre();Ip();fs();ffe();ke();Oh();Gr();j();pb();Fe();ke();Sf();Ks();Pd();Ie();j();Ml();Ps();db();var H0t=function(n,e,t,i){var o=arguments.length,r=o<3?e:i===null?i=Object.getOwnPropertyDescriptor(e,t):i,s;if(typeof Reflect=="object"&&typeof Reflect.decorate=="function")r=Reflect.decorate(n,e,t,i);else for(var a=n.length-1;a>=0;a--)(s=n[a])&&(r=(o<3?s(r):o>3?s(e,t,r):s(e,t))||r);return o>3&&r&&Object.defineProperty(e,t,r),r},Zqe=function(n,e){return function(t,i){e(t,i,n)}},IZ=class extends D{get enabled(){return this._enabled}set enabled(e){e?(this.el.setAttribute("aria-disabled","false"),this.el.tabIndex=0,this.el.style.pointerEvents="auto",this.el.style.opacity="1",this.el.style.cursor="pointer",this._enabled=!1):(this.el.setAttribute("aria-disabled","true"),this.el.tabIndex=-1,this.el.style.pointerEvents="none",this.el.style.opacity="0.4",this.el.style.cursor="default",this._enabled=!0),this._enabled=e}constructor(e,t,i={},o,r){super(),this._link=t,this._hoverService=o,this._enabled=!0,this.el=Q(e,J("a.monaco-link",{tabIndex:t.tabIndex??0,href:t.href},t.label)),this.hoverDelegate=i.hoverDelegate??lo("mouse"),this.setTooltip(t.title),this.el.setAttribute("role","button");let s=this._register(new Mt(this.el,"click")),a=this._register(new Mt(this.el,"keypress")),l=ne.chain(a.event,u=>u.map(h=>new Xt(h)).filter(h=>h.keyCode===3)),c=this._register(new Mt(this.el,Mi.Tap)).event;this._register(so.addTarget(this.el));let d=ne.any(s.event,l,c);this._register(d(u=>{this.enabled&&(Rt.stop(u,!0),i?.opener?i.opener(this._link.href):r.open(this._link.href,{allowCommands:!0}))})),this.enabled=!0}setTooltip(e){this.hoverDelegate.showNativeHover?this.el.title=e??"":!this.hover&&e?this.hover=this._register(this._hoverService.setupManagedHover(this.hoverDelegate,this.el,e)):this.hover&&this.hover.update(e)}};IZ=H0t([Zqe(3,cc),Zqe(4,xo)],IZ);$d();bn();var Xqe=function(n,e,t,i){var o=arguments.length,r=o<3?e:i===null?i=Object.getOwnPropertyDescriptor(e,t):i,s;if(typeof Reflect=="object"&&typeof Reflect.decorate=="function")r=Reflect.decorate(n,e,t,i);else for(var a=n.length-1;a>=0;a--)(s=n[a])&&(r=(o<3?s(r):o>3?s(e,t,r):s(e,t))||r);return o>3&&r&&Object.defineProperty(e,t,r),r},Qqe=function(n,e){return function(t,i){e(t,i,n)}},z0t=26,EZ=class extends D{constructor(e,t){super(),this._editor=e,this.instantiationService=t,this.banner=this._register(this.instantiationService.createInstance(Uwe))}hide(){this._editor.setBanner(null,0),this.banner.clear()}show(e){this.banner.show({...e,onClose:()=>{this.hide(),e.onClose?.()}}),this._editor.setBanner(this.banner.element,z0t)}};EZ=Xqe([Qqe(1,he)],EZ);var Uwe=class extends D{constructor(e){super(),this.instantiationService=e,this.markdownRenderer=this.instantiationService.createInstance(Gc,{}),this.element=J("div.editor-banner"),this.element.tabIndex=0}getAriaLabel(e){if(e.ariaLabel)return e.ariaLabel;if(typeof e.message=="string")return e.message}getBannerMessage(e){if(typeof e=="string"){let t=J("span");return t.innerText=e,t}return this.markdownRenderer.render(e).element}clear(){no(this.element)}show(e){no(this.element);let t=this.getAriaLabel(e);t&&this.element.setAttribute("aria-label",t);let i=Q(this.element,J("div.icon-container"));i.setAttribute("aria-hidden","true"),e.icon&&i.appendChild(J(`div${Oe.asCSSSelector(e.icon)}`));let o=Q(this.element,J("div.message-container"));if(o.setAttribute("aria-hidden","true"),o.appendChild(this.getBannerMessage(e.message)),this.messageActionsContainer=Q(this.element,J("div.message-actions-container")),e.actions)for(let s of e.actions)this._register(this.instantiationService.createInstance(IZ,this.messageActionsContainer,{...s,tabIndex:-1},{}));let r=Q(this.element,J("div.action-container"));this.actionBar=this._register(new Zo(r)),this.actionBar.push(this._register(new rr("banner.close","Close Banner",Oe.asClassName(Hz),!0,()=>{typeof e.onClose=="function"&&e.onClose()})),{icon:!0,label:!1}),this.actionBar.setFocusable(!1)}};Uwe=Xqe([Qqe(0,he)],Uwe);pe();en();Fe();Ml();Jc();$d();Eae();var Xwe=function(n,e,t,i){var o=arguments.length,r=o<3?e:i===null?i=Object.getOwnPropertyDescriptor(e,t):i,s;if(typeof Reflect=="object"&&typeof Reflect.decorate=="function")r=Reflect.decorate(n,e,t,i);else for(var a=n.length-1;a>=0;a--)(s=n[a])&&(r=(o<3?s(r):o>3?s(e,t,r):s(e,t))||r);return o>3&&r&&Object.defineProperty(e,t,r),r},jD=function(n,e){return function(t,i){e(t,i,n)}},V0t=Fi("extensions-warning-message",oe.warning,m("warningIcon","Icon shown with a warning message in the extensions editor.")),P4=class extends D{static{this.ID="editor.contrib.unicodeHighlighter"}constructor(e,t,i,o){super(),this._editor=e,this._editorWorkerService=t,this._workspaceTrustService=i,this._highlighter=null,this._bannerClosed=!1,this._updateState=r=>{if(r&&r.hasMore){if(this._bannerClosed)return;let s=Math.max(r.ambiguousCharacterCount,r.nonBasicAsciiCharacterCount,r.invisibleCharacterCount),a;if(r.nonBasicAsciiCharacterCount>=s)a={message:m("unicodeHighlighting.thisDocumentHasManyNonBasicAsciiUnicodeCharacters","This document contains many non-basic ASCII unicode characters"),command:new F4};else if(r.ambiguousCharacterCount>=s)a={message:m("unicodeHighlighting.thisDocumentHasManyAmbiguousUnicodeCharacters","This document contains many ambiguous unicode characters"),command:new _S};else if(r.invisibleCharacterCount>=s)a={message:m("unicodeHighlighting.thisDocumentHasManyInvisibleUnicodeCharacters","This document contains many invisible unicode characters"),command:new O4};else throw new Error("Unreachable");this._bannerController.show({id:"unicodeHighlightBanner",message:a.message,icon:V0t,actions:[{label:a.command.shortLabel,href:`command:${a.command.id}`}],onClose:()=>{this._bannerClosed=!0}})}else this._bannerController.hide()},this._bannerController=this._register(o.createInstance(EZ,e)),this._register(this._editor.onDidChangeModel(()=>{this._bannerClosed=!1,this._updateHighlighter()})),this._options=e.getOption(126),this._register(i.onDidChangeTrust(r=>{this._updateHighlighter()})),this._register(e.onDidChangeConfiguration(r=>{r.hasChanged(126)&&(this._options=e.getOption(126),this._updateHighlighter())})),this._updateHighlighter()}dispose(){this._highlighter&&(this._highlighter.dispose(),this._highlighter=null),super.dispose()}_updateHighlighter(){if(this._updateState(null),this._highlighter&&(this._highlighter.dispose(),this._highlighter=null),!this._editor.hasModel())return;let e=U0t(this._workspaceTrustService.isWorkspaceTrusted(),this._options);if([e.nonBasicASCII,e.ambiguousCharacters,e.invisibleCharacters].every(i=>i===!1))return;let t={nonBasicASCII:e.nonBasicASCII,ambiguousCharacters:e.ambiguousCharacters,invisibleCharacters:e.invisibleCharacters,includeComments:e.includeComments,includeStrings:e.includeStrings,allowedCodePoints:Object.keys(e.allowedCharacters).map(i=>i.codePointAt(0)),allowedLocales:Object.keys(e.allowedLocales).map(i=>i==="_os"?new Intl.NumberFormat().resolvedOptions().locale:i==="_vscode"?eTe:i)};this._editorWorkerService.canComputeUnicodeHighlights(this._editor.getModel().uri)?this._highlighter=new jwe(this._editor,t,this._updateState,this._editorWorkerService):this._highlighter=new qwe(this._editor,t,this._updateState)}getDecorationInfo(e){return this._highlighter?this._highlighter.getDecorationInfo(e):null}};P4=Xwe([jD(1,kr),jD(2,V7),jD(3,he)],P4);function U0t(n,e){return{nonBasicASCII:e.nonBasicASCII===wd?!n:e.nonBasicASCII,ambiguousCharacters:e.ambiguousCharacters,invisibleCharacters:e.invisibleCharacters,includeComments:e.includeComments===wd?!n:e.includeComments,includeStrings:e.includeStrings===wd?!n:e.includeStrings,allowedCharacters:e.allowedCharacters,allowedLocales:e.allowedLocales}}var jwe=class extends D{constructor(e,t,i,o){super(),this._editor=e,this._options=t,this._updateState=i,this._editorWorkerService=o,this._model=this._editor.getModel(),this._decorations=this._editor.createDecorationsCollection(),this._updateSoon=this._register(new Lt(()=>this._update(),250)),this._register(this._editor.onDidChangeModelContent(()=>{this._updateSoon.schedule()})),this._updateSoon.schedule()}dispose(){this._decorations.clear(),super.dispose()}_update(){if(this._model.isDisposed())return;if(!this._model.mightContainNonBasicASCII()){this._decorations.clear();return}let e=this._model.getVersionId();this._editorWorkerService.computedUnicodeHighlights(this._model.uri,this._options).then(t=>{if(this._model.isDisposed()||this._model.getVersionId()!==e)return;this._updateState(t);let i=[];if(!t.hasMore)for(let o of t.ranges)i.push({range:o,options:TZ.instance.getDecorationFromOptions(this._options)});this._decorations.set(i)})}getDecorationInfo(e){if(!this._decorations.has(e))return null;let t=this._editor.getModel();if(!O$(t,e))return null;let i=t.getValueInRange(e.range);return{reason:eKe(i,this._options),inComment:F$(t,e),inString:B$(t,e)}}};jwe=Xwe([jD(3,kr)],jwe);var qwe=class extends D{constructor(e,t,i){super(),this._editor=e,this._options=t,this._updateState=i,this._model=this._editor.getModel(),this._decorations=this._editor.createDecorationsCollection(),this._updateSoon=this._register(new Lt(()=>this._update(),250)),this._register(this._editor.onDidLayoutChange(()=>{this._updateSoon.schedule()})),this._register(this._editor.onDidScrollChange(()=>{this._updateSoon.schedule()})),this._register(this._editor.onDidChangeHiddenAreas(()=>{this._updateSoon.schedule()})),this._register(this._editor.onDidChangeModelContent(()=>{this._updateSoon.schedule()})),this._updateSoon.schedule()}dispose(){this._decorations.clear(),super.dispose()}_update(){if(this._model.isDisposed())return;if(!this._model.mightContainNonBasicASCII()){this._decorations.clear();return}let e=this._editor.getVisibleRanges(),t=[],i={ranges:[],ambiguousCharacterCount:0,invisibleCharacterCount:0,nonBasicAsciiCharacterCount:0,hasMore:!1};for(let o of e){let r=G1.computeUnicodeHighlights(this._model,this._options,o);for(let s of r.ranges)i.ranges.push(s);i.ambiguousCharacterCount+=i.ambiguousCharacterCount,i.invisibleCharacterCount+=i.invisibleCharacterCount,i.nonBasicAsciiCharacterCount+=i.nonBasicAsciiCharacterCount,i.hasMore=i.hasMore||r.hasMore}if(!i.hasMore)for(let o of i.ranges)t.push({range:o,options:TZ.instance.getDecorationFromOptions(this._options)});this._updateState(i),this._decorations.set(t)}getDecorationInfo(e){if(!this._decorations.has(e))return null;let t=this._editor.getModel(),i=t.getValueInRange(e.range);return O$(t,e)?{reason:eKe(i,this._options),inComment:F$(t,e),inString:B$(t,e)}:null}},Jqe=m("unicodeHighlight.configureUnicodeHighlightOptions","Configure Unicode Highlight Options"),Kwe=class{constructor(e,t,i){this._editor=e,this._languageService=t,this._openerService=i,this.hoverOrdinal=5}computeSync(e,t){if(!this._editor.hasModel()||e.type!==1)return[];let i=this._editor.getModel(),o=this._editor.getContribution(P4.ID);if(!o)return[];let r=[],s=new Set,a=300;for(let l of t){let c=o.getDecorationInfo(l);if(!c)continue;let u=i.getValueInRange(l.range).codePointAt(0),h=$we(u),f;switch(c.reason.kind){case 0:{Im(c.reason.confusableWith)?f=m("unicodeHighlight.characterIsAmbiguousASCII","The character {0} could be confused with the ASCII character {1}, which is more common in source code.",h,$we(c.reason.confusableWith.codePointAt(0))):f=m("unicodeHighlight.characterIsAmbiguous","The character {0} could be confused with the character {1}, which is more common in source code.",h,$we(c.reason.confusableWith.codePointAt(0)));break}case 1:f=m("unicodeHighlight.characterIsInvisible","The character {0} is invisible.",h);break;case 2:f=m("unicodeHighlight.characterIsNonBasicAscii","The character {0} is not a basic ASCII character.",h);break}if(s.has(f))continue;s.add(f);let p={codePoint:u,reason:c.reason,inComment:c.inComment,inString:c.inString},g=m("unicodeHighlight.adjustSettings","Adjust settings"),_=`command:${DZ.ID}?${encodeURIComponent(JSON.stringify(p))}`,b=new Eo("",!0).appendMarkdown(f).appendText(" ").appendLink(_,g,Jqe);r.push(new cd(this,l.range,[b],!1,a++))}return r}renderHoverParts(e,t){return q$e(e,t,this._editor,this._languageService,this._openerService)}};Kwe=Xwe([jD(1,ai),jD(2,xo)],Kwe);function Gwe(n){return`U+${n.toString(16).padStart(4,"0")}`}function $we(n){let e=`\`${Gwe(n)}\``;return W_.isInvisibleCharacter(n)||(e+=` "${`${$0t(n)}`}"`),e}function $0t(n){return n===96?"`` ` ``":"`"+String.fromCodePoint(n)+"`"}function eKe(n,e){return G1.computeUnicodeHighlightReason(n,e)}var TZ=class n{constructor(){this.map=new Map}static{this.instance=new n}getDecorationFromOptions(e){return this.getDecoration(!e.includeComments,!e.includeStrings)}getDecoration(e,t){let i=`${e}${t}`,o=this.map.get(i);return o||(o=tt.createDynamic({description:"unicode-highlight",stickiness:1,className:"unicode-highlight",showIfCollapsed:!0,overviewRuler:null,minimap:null,hideInCommentTokens:e,hideInStringTokens:t}),this.map.set(i,o)),o}},Ywe=class extends fe{constructor(){super({id:_S.ID,label:m("action.unicodeHighlight.disableHighlightingInComments","Disable highlighting of characters in comments"),alias:"Disable highlighting of characters in comments",precondition:void 0}),this.shortLabel=m("unicodeHighlight.disableHighlightingInComments.shortLabel","Disable Highlight In Comments")}async run(e,t,i){let o=e?.get(Ve);o&&this.runAction(o)}async runAction(e){await e.updateValue(tc.includeComments,!1,2)}},Zwe=class extends fe{constructor(){super({id:_S.ID,label:m("action.unicodeHighlight.disableHighlightingInStrings","Disable highlighting of characters in strings"),alias:"Disable highlighting of characters in strings",precondition:void 0}),this.shortLabel=m("unicodeHighlight.disableHighlightingInStrings.shortLabel","Disable Highlight In Strings")}async run(e,t,i){let o=e?.get(Ve);o&&this.runAction(o)}async runAction(e){await e.updateValue(tc.includeStrings,!1,2)}},_S=class n extends fe{static{this.ID="editor.action.unicodeHighlight.disableHighlightingOfAmbiguousCharacters"}constructor(){super({id:n.ID,label:m("action.unicodeHighlight.disableHighlightingOfAmbiguousCharacters","Disable highlighting of ambiguous characters"),alias:"Disable highlighting of ambiguous characters",precondition:void 0}),this.shortLabel=m("unicodeHighlight.disableHighlightingOfAmbiguousCharacters.shortLabel","Disable Ambiguous Highlight")}async run(e,t,i){let o=e?.get(Ve);o&&this.runAction(o)}async runAction(e){await e.updateValue(tc.ambiguousCharacters,!1,2)}},O4=class n extends fe{static{this.ID="editor.action.unicodeHighlight.disableHighlightingOfInvisibleCharacters"}constructor(){super({id:n.ID,label:m("action.unicodeHighlight.disableHighlightingOfInvisibleCharacters","Disable highlighting of invisible characters"),alias:"Disable highlighting of invisible characters",precondition:void 0}),this.shortLabel=m("unicodeHighlight.disableHighlightingOfInvisibleCharacters.shortLabel","Disable Invisible Highlight")}async run(e,t,i){let o=e?.get(Ve);o&&this.runAction(o)}async runAction(e){await e.updateValue(tc.invisibleCharacters,!1,2)}},F4=class n extends fe{static{this.ID="editor.action.unicodeHighlight.disableHighlightingOfNonBasicAsciiCharacters"}constructor(){super({id:n.ID,label:m("action.unicodeHighlight.disableHighlightingOfNonBasicAsciiCharacters","Disable highlighting of non basic ASCII characters"),alias:"Disable highlighting of non basic ASCII characters",precondition:void 0}),this.shortLabel=m("unicodeHighlight.disableHighlightingOfNonBasicAsciiCharacters.shortLabel","Disable Non ASCII Highlight")}async run(e,t,i){let o=e?.get(Ve);o&&this.runAction(o)}async runAction(e){await e.updateValue(tc.nonBasicASCII,!1,2)}},DZ=class n extends fe{static{this.ID="editor.action.unicodeHighlight.showExcludeOptions"}constructor(){super({id:n.ID,label:m("action.unicodeHighlight.showExcludeOptions","Show Exclude Options"),alias:"Show Exclude Options",precondition:void 0})}async run(e,t,i){let{codePoint:o,reason:r,inString:s,inComment:a}=i,l=String.fromCodePoint(o),c=e.get(Pr),d=e.get(Ve);function u(p){return W_.isInvisibleCharacter(p)?m("unicodeHighlight.excludeInvisibleCharFromBeingHighlighted","Exclude {0} (invisible character) from being highlighted",Gwe(p)):m("unicodeHighlight.excludeCharFromBeingHighlighted","Exclude {0} from being highlighted",`${Gwe(p)} "${l}"`)}let h=[];if(r.kind===0)for(let p of r.notAmbiguousInLocales)h.push({label:m("unicodeHighlight.allowCommonCharactersInLanguage",'Allow unicode characters that are more common in the language "{0}".',p),run:async()=>{q0t(d,[p])}});if(h.push({label:u(o),run:()=>j0t(d,[o])}),a){let p=new Ywe;h.push({label:p.label,run:async()=>p.runAction(d)})}else if(s){let p=new Zwe;h.push({label:p.label,run:async()=>p.runAction(d)})}if(r.kind===0){let p=new _S;h.push({label:p.label,run:async()=>p.runAction(d)})}else if(r.kind===1){let p=new O4;h.push({label:p.label,run:async()=>p.runAction(d)})}else if(r.kind===2){let p=new F4;h.push({label:p.label,run:async()=>p.runAction(d)})}else K0t(r);let f=await c.pick(h,{title:Jqe});f&&await f.run()}};async function j0t(n,e){let t=n.getValue(tc.allowedCharacters),i;typeof t=="object"&&t?i=t:i={};for(let o of e)i[String.fromCodePoint(o)]=!0;await n.updateValue(tc.allowedCharacters,i,2)}async function q0t(n,e){let t=n.inspect(tc.allowedLocales).user?.value,i;typeof t=="object"&&t?i=Object.assign({},t):i={};for(let o of e)i[o]=!0;await n.updateValue(tc.allowedLocales,i,2)}function K0t(n){throw new Error(`Unexpected value: ${n}`)}ee(_S);ee(O4);ee(F4);ee(DZ);ze(P4.ID,P4,1);Uh.register(Kwe);j();ia();mt();Po();pe();AL();var G0t=function(n,e,t,i){var o=arguments.length,r=o<3?e:i===null?i=Object.getOwnPropertyDescriptor(e,t):i,s;if(typeof Reflect=="object"&&typeof Reflect.decorate=="function")r=Reflect.decorate(n,e,t,i);else for(var a=n.length-1;a>=0;a--)(s=n[a])&&(r=(o<3?s(r):o>3?s(e,t,r):s(e,t))||r);return o>3&&r&&Object.defineProperty(e,t,r),r},tKe=function(n,e){return function(t,i){e(t,i,n)}},iKe="ignoreUnusualLineTerminators";function Y0t(n,e,t){n.setModelProperty(e.uri,iKe,t)}function Z0t(n,e){return n.getModelProperty(e.uri,iKe)}var NZ=class extends D{static{this.ID="editor.contrib.unusualLineTerminatorsDetector"}constructor(e,t,i){super(),this._editor=e,this._dialogService=t,this._codeEditorService=i,this._isPresentingDialog=!1,this._config=this._editor.getOption(127),this._register(this._editor.onDidChangeConfiguration(o=>{o.hasChanged(127)&&(this._config=this._editor.getOption(127),this._checkForUnusualLineTerminators())})),this._register(this._editor.onDidChangeModel(()=>{this._checkForUnusualLineTerminators()})),this._register(this._editor.onDidChangeModelContent(o=>{o.isUndoing||this._checkForUnusualLineTerminators()})),this._checkForUnusualLineTerminators()}async _checkForUnusualLineTerminators(){if(this._config==="off"||!this._editor.hasModel())return;let e=this._editor.getModel();if(!e.mightContainUnusualLineTerminators()||Z0t(this._codeEditorService,e)===!0||this._editor.getOption(92))return;if(this._config==="auto"){e.removeUnusualLineTerminators(this._editor.getSelections());return}if(this._isPresentingDialog)return;let i;try{this._isPresentingDialog=!0,i=await this._dialogService.confirm({title:m("unusualLineTerminators.title","Unusual Line Terminators"),message:m("unusualLineTerminators.message","Detected unusual line terminators"),detail:m("unusualLineTerminators.detail","The file '{0}' contains one or more unusual line terminator characters, like Line Separator (LS) or Paragraph Separator (PS).\n\nIt is recommended to remove them from the file. This can be configured via `editor.unusualLineTerminators`.",ta(e.uri)),primaryButton:m({key:"unusualLineTerminators.fix",comment:["&& denotes a mnemonic"]},"&&Remove Unusual Line Terminators"),cancelButton:m("unusualLineTerminators.ignore","Ignore")})}finally{this._isPresentingDialog=!1}if(!i.confirmed){Y0t(this._codeEditorService,e,!0);return}e.removeUnusualLineTerminators(this._editor.getSelections())}};NZ=G0t([tKe(1,Um),tKe(2,xt)],NZ);ze(NZ.ID,NZ,1);pe();Ns();ft();ci();je();j();uT();mt();Po();we();Si();Zr();Qt();it();ds();Ds();ase();ia();h1();Qt();Ji();j();Ds();var X0t=function(n,e,t,i){var o=arguments.length,r=o<3?e:i===null?i=Object.getOwnPropertyDescriptor(e,t):i,s;if(typeof Reflect=="object"&&typeof Reflect.decorate=="function")r=Reflect.decorate(n,e,t,i);else for(var a=n.length-1;a>=0;a--)(s=n[a])&&(r=(o<3?s(r):o>3?s(e,t,r):s(e,t))||r);return o>3&&r&&Object.defineProperty(e,t,r),r},Q0t=function(n,e){return function(t,i){e(t,i,n)}},RZ=class{constructor(){this.selector={language:"*"}}provideDocumentHighlights(e,t,i){let o=[],r=e.getWordAtPosition({lineNumber:t.lineNumber,column:t.column});return r?e.isDisposed()?void 0:e.findMatches(r.word,!0,!1,!0,Vk,!1).map(a=>({range:a.range,kind:mx.Text})):Promise.resolve(o)}provideMultiDocumentHighlights(e,t,i,o){let r=new Fo,s=e.getWordAtPosition({lineNumber:t.lineNumber,column:t.column});if(!s)return Promise.resolve(r);for(let a of[e,...i]){if(a.isDisposed())continue;let c=a.findMatches(s.word,!0,!1,!0,Vk,!1).map(d=>({range:d.range,kind:mx.Text}));c&&r.set(a.uri,c)}return r}},AZ=class extends D{constructor(e){super(),this._register(e.documentHighlightProvider.register("*",new RZ)),this._register(e.multiDocumentHighlightProvider.register("*",new RZ))}};AZ=X0t([Q0t(0,le)],AZ);Iw();var nKe=function(n,e,t,i){var o=arguments.length,r=o<3?e:i===null?i=Object.getOwnPropertyDescriptor(e,t):i,s;if(typeof Reflect=="object"&&typeof Reflect.decorate=="function")r=Reflect.decorate(n,e,t,i);else for(var a=n.length-1;a>=0;a--)(s=n[a])&&(r=(o<3?s(r):o>3?s(e,t,r):s(e,t))||r);return o>3&&r&&Object.defineProperty(e,t,r),r},MZ=function(n,e){return function(t,i){e(t,i,n)}},Qo,Qwe,rye=new me("hasWordHighlights",!1);function oKe(n,e,t,i){let o=n.ordered(e);return tA(o.map(r=>()=>Promise.resolve(r.provideDocumentHighlights(e,t,i)).then(void 0,mi)),r=>r!=null).then(r=>{if(r){let s=new Fo;return s.set(e.uri,r),s}return new Fo})}function J0t(n,e,t,i,o,r){let s=n.ordered(e);return tA(s.map(a=>()=>{let l=r.filter(c=>P6(c)).filter(c=>ZA(a.selector,c.uri,c.getLanguageId(),!0,void 0,void 0)>0);return Promise.resolve(a.provideMultiDocumentHighlights(e,t,l,o)).then(void 0,mi)}),a=>a!=null)}var PZ=class{constructor(e,t,i){this._model=e,this._selection=t,this._wordSeparators=i,this._wordRange=this._getCurrentWordRange(e,t),this._result=null}get result(){return this._result||(this._result=sn(e=>this._compute(this._model,this._selection,this._wordSeparators,e))),this._result}_getCurrentWordRange(e,t){let i=e.getWordAtPosition(t.getPosition());return i?new S(t.startLineNumber,i.startColumn,t.startLineNumber,i.endColumn):null}isValid(e,t,i){let o=t.startLineNumber,r=t.startColumn,s=t.endColumn,a=this._getCurrentWordRange(e,t),l=!!(this._wordRange&&this._wordRange.equalsRange(a));for(let c=0,d=i.length;!l&&c=s&&(l=!0)}return l}cancel(){this.result.cancel()}},Jwe=class extends PZ{constructor(e,t,i,o){super(e,t,i),this._providers=o}_compute(e,t,i,o){return oKe(this._providers,e,t.getPosition(),o).then(r=>r||new Fo)}},eye=class extends PZ{constructor(e,t,i,o,r){super(e,t,i),this._providers=o,this._otherModels=r}_compute(e,t,i,o){return J0t(this._providers,e,t.getPosition(),i,o,this._otherModels).then(r=>r||new Fo)}};function eSt(n,e,t,i,o){return new Jwe(e,t,o,n)}function tSt(n,e,t,i,o,r){return new eye(e,t,o,n,r)}Zs("_executeDocumentHighlights",async(n,e,t)=>{let i=n.get(le);return(await oKe(i.documentHighlightProvider,e,t,Ze.None))?.get(e.uri)});var tye=class{static{Qo=this}static{this.storedDecorationIDs=new Fo}static{this.query=null}constructor(e,t,i,o,r){this.toUnhook=new H,this.workerRequestTokenId=0,this.workerRequestCompleted=!1,this.workerRequestValue=new Fo,this.lastCursorPositionChangeTime=0,this.renderDecorationsTimer=-1,this.runDelayer=this.toUnhook.add(new gr(50)),this.editor=e,this.providers=t,this.multiDocumentProviders=i,this.codeEditorService=r,this._hasWordHighlights=rye.bindTo(o),this._ignorePositionChangeEvent=!1,this.occurrencesHighlight=this.editor.getOption(81),this.model=this.editor.getModel(),this.toUnhook.add(e.onDidChangeCursorPosition(s=>{this._ignorePositionChangeEvent||this.occurrencesHighlight!=="off"&&this.runDelayer.trigger(()=>{this._onPositionChanged(s)})})),this.toUnhook.add(e.onDidFocusEditorText(s=>{this.occurrencesHighlight!=="off"&&(this.workerRequest||this.runDelayer.trigger(()=>{this._run()}))})),this.toUnhook.add(e.onDidChangeModelContent(s=>{L1(this.model.uri,"output")||this._stopAll()})),this.toUnhook.add(e.onDidChangeModel(s=>{!s.newModelUrl&&s.oldModelUrl?this._stopSingular():Qo.query&&this._run()})),this.toUnhook.add(e.onDidChangeConfiguration(s=>{let a=this.editor.getOption(81);if(this.occurrencesHighlight!==a)switch(this.occurrencesHighlight=a,a){case"off":this._stopAll();break;case"singleFile":this._stopAll(Qo.query?.modelInfo?.model);break;case"multiFile":Qo.query&&this._run(!0);break;default:console.warn("Unknown occurrencesHighlight setting value:",a);break}})),this.decorations=this.editor.createDecorationsCollection(),this.workerRequestTokenId=0,this.workerRequest=null,this.workerRequestCompleted=!1,this.lastCursorPositionChangeTime=0,this.renderDecorationsTimer=-1,Qo.query&&this._run()}hasDecorations(){return this.decorations.length>0}restore(){this.occurrencesHighlight!=="off"&&(this.runDelayer.cancel(),this._run())}_getSortedHighlights(){return this.decorations.getRanges().sort(S.compareRangesUsingStarts)}moveNext(){let e=this._getSortedHighlights(),i=(e.findIndex(r=>r.containsPosition(this.editor.getPosition()))+1)%e.length,o=e[i];try{this._ignorePositionChangeEvent=!0,this.editor.setPosition(o.getStartPosition()),this.editor.revealRangeInCenterIfOutsideViewport(o);let r=this._getWord();if(r){let s=this.editor.getModel().getLineContent(o.startLineNumber);Bo(`${s}, ${i+1} of ${e.length} for '${r.word}'`)}}finally{this._ignorePositionChangeEvent=!1}}moveBack(){let e=this._getSortedHighlights(),i=(e.findIndex(r=>r.containsPosition(this.editor.getPosition()))-1+e.length)%e.length,o=e[i];try{this._ignorePositionChangeEvent=!0,this.editor.setPosition(o.getStartPosition()),this.editor.revealRangeInCenterIfOutsideViewport(o);let r=this._getWord();if(r){let s=this.editor.getModel().getLineContent(o.startLineNumber);Bo(`${s}, ${i+1} of ${e.length} for '${r.word}'`)}}finally{this._ignorePositionChangeEvent=!1}}_removeSingleDecorations(){if(!this.editor.hasModel())return;let e=Qo.storedDecorationIDs.get(this.editor.getModel().uri);e&&(this.editor.removeDecorations(e),Qo.storedDecorationIDs.delete(this.editor.getModel().uri),this.decorations.length>0&&(this.decorations.clear(),this._hasWordHighlights.set(!1)))}_removeAllDecorations(e){let t=this.codeEditorService.listCodeEditors(),i=[];for(let o of t){if(!o.hasModel()||hb(o.getModel().uri,e?.uri))continue;let r=Qo.storedDecorationIDs.get(o.getModel().uri);if(!r)continue;o.removeDecorations(r),i.push(o.getModel().uri);let s=xy.get(o);s?.wordHighlighter&&s.wordHighlighter.decorations.length>0&&(s.wordHighlighter.decorations.clear(),s.wordHighlighter.workerRequest=null,s.wordHighlighter._hasWordHighlights.set(!1))}for(let o of i)Qo.storedDecorationIDs.delete(o)}_stopSingular(){this._removeSingleDecorations(),this.editor.hasTextFocus()&&(this.editor.getModel()?.uri.scheme!==rt.vscodeNotebookCell&&Qo.query?.modelInfo?.model.uri.scheme!==rt.vscodeNotebookCell?(Qo.query=null,this._run()):Qo.query?.modelInfo&&(Qo.query.modelInfo=null)),this.renderDecorationsTimer!==-1&&(clearTimeout(this.renderDecorationsTimer),this.renderDecorationsTimer=-1),this.workerRequest!==null&&(this.workerRequest.cancel(),this.workerRequest=null),this.workerRequestCompleted||(this.workerRequestTokenId++,this.workerRequestCompleted=!0)}_stopAll(e){this._removeAllDecorations(e),this.renderDecorationsTimer!==-1&&(clearTimeout(this.renderDecorationsTimer),this.renderDecorationsTimer=-1),this.workerRequest!==null&&(this.workerRequest.cancel(),this.workerRequest=null),this.workerRequestCompleted||(this.workerRequestTokenId++,this.workerRequestCompleted=!0)}_onPositionChanged(e){if(this.occurrencesHighlight==="off"){this._stopAll();return}if(e.reason!==3&&this.editor.getModel()?.uri.scheme!==rt.vscodeNotebookCell){this._stopAll();return}this._run()}_getWord(){let e=this.editor.getSelection(),t=e.startLineNumber,i=e.startColumn;return this.model.isDisposed()?null:this.model.getWordAtPosition({lineNumber:t,column:i})}getOtherModelsToHighlight(e){if(!e)return[];if(e.uri.scheme===rt.vscodeNotebookCell){let r=[],s=this.codeEditorService.listCodeEditors();for(let a of s){let l=a.getModel();l&&l!==e&&l.uri.scheme===rt.vscodeNotebookCell&&r.push(l)}return r}let i=[],o=this.codeEditorService.listCodeEditors();for(let r of o){if(!RP(r))continue;let s=r.getModel();s&&e===s.modified&&i.push(s.modified)}if(i.length)return i;if(this.occurrencesHighlight==="singleFile")return[];for(let r of o){let s=r.getModel();s&&s!==e&&i.push(s)}return i}_run(e){let t;if(this.editor.hasTextFocus()){let o=this.editor.getSelection();if(!o||o.startLineNumber!==o.endLineNumber){Qo.query=null,this._stopAll();return}let r=o.startColumn,s=o.endColumn,a=this._getWord();if(!a||a.startColumn>r||a.endColumn{o===this.workerRequestTokenId&&(this.workerRequestCompleted=!0,this.workerRequestValue=s||[],this._beginRenderDecorations())},Be)}}computeWithModel(e,t,i,o){return o.length?tSt(this.multiDocumentProviders,e,t,i,this.editor.getOption(132),o):eSt(this.providers,e,t,i,this.editor.getOption(132))}_beginRenderDecorations(){let e=new Date().getTime(),t=this.lastCursorPositionChangeTime+250;e>=t?(this.renderDecorationsTimer=-1,this.renderDecorations()):this.renderDecorationsTimer=setTimeout(()=>{this.renderDecorations()},t-e)}renderDecorations(){this.renderDecorationsTimer=-1;let e=this.codeEditorService.listCodeEditors();for(let t of e){let i=xy.get(t);if(!i)continue;let o=[],r=t.getModel()?.uri;if(r&&this.workerRequestValue.has(r)){let s=Qo.storedDecorationIDs.get(r),a=this.workerRequestValue.get(r);if(a)for(let c of a)c.range&&o.push({range:c.range,options:Sqe(c.kind)});let l=[];t.changeDecorations(c=>{l=c.deltaDecorations(s??[],o)}),Qo.storedDecorationIDs=Qo.storedDecorationIDs.set(r,l),o.length>0&&(i.wordHighlighter?.decorations.set(o),i.wordHighlighter?._hasWordHighlights.set(!0))}}}dispose(){this._stopSingular(),this.toUnhook.dispose()}};tye=Qo=nKe([MZ(4,xt)],tye);var xy=class extends D{static{Qwe=this}static{this.ID="editor.contrib.wordHighlighter"}static get(e){return e.getContribution(Qwe.ID)}constructor(e,t,i,o){super(),this._wordHighlighter=null;let r=()=>{e.hasModel()&&!e.getModel().isTooLargeForTokenization()&&(this._wordHighlighter=new tye(e,i.documentHighlightProvider,i.multiDocumentHighlightProvider,t,o))};this._register(e.onDidChangeModel(s=>{this._wordHighlighter&&(this._wordHighlighter.dispose(),this._wordHighlighter=null),r()})),r()}get wordHighlighter(){return this._wordHighlighter}saveViewState(){return!!(this._wordHighlighter&&this._wordHighlighter.hasDecorations())}moveNext(){this._wordHighlighter?.moveNext()}moveBack(){this._wordHighlighter?.moveBack()}restoreViewState(e){this._wordHighlighter&&e&&this._wordHighlighter.restore()}dispose(){this._wordHighlighter&&(this._wordHighlighter.dispose(),this._wordHighlighter=null),super.dispose()}};xy=Qwe=nKe([MZ(1,Le),MZ(2,le),MZ(3,xt)],xy);var OZ=class extends fe{constructor(e,t){super(t),this._isNext=e}run(e,t){let i=xy.get(t);i&&(this._isNext?i.moveNext():i.moveBack())}},iye=class extends OZ{constructor(){super(!0,{id:"editor.action.wordHighlight.next",label:m("wordHighlight.next.label","Go to Next Symbol Highlight"),alias:"Go to Next Symbol Highlight",precondition:rye,kbOpts:{kbExpr:T.editorTextFocus,primary:65,weight:100}})}},nye=class extends OZ{constructor(){super(!1,{id:"editor.action.wordHighlight.prev",label:m("wordHighlight.previous.label","Go to Previous Symbol Highlight"),alias:"Go to Previous Symbol Highlight",precondition:rye,kbOpts:{kbExpr:T.editorTextFocus,primary:1089,weight:100}})}},oye=class extends fe{constructor(){super({id:"editor.action.wordHighlight.trigger",label:m("wordHighlight.trigger.label","Trigger Symbol Highlight"),alias:"Trigger Symbol Highlight",precondition:void 0,kbOpts:{kbExpr:T.editorTextFocus,primary:0,weight:100}})}run(e,t,i){let o=xy.get(t);o&&o.restoreViewState(!0)}};ze(xy.ID,xy,0);ee(iye);ee(nye);ee(oye);Rf(AZ);mt();d0();ir();Bu();lP();SL();qe();we();Ui();Si();Ko();pe();uc();it();lE();var bS=class extends hn{constructor(e){super(e),this._inSelectionMode=e.inSelectionMode,this._wordNavigationType=e.wordNavigationType}runEditorCommand(e,t,i){if(!t.hasModel())return;let o=Dl(t.getOption(132),t.getOption(131)),r=t.getModel(),s=t.getSelections(),a=s.length>1,l=s.map(c=>{let d=new P(c.positionLineNumber,c.positionColumn),u=this._move(o,r,d,this._wordNavigationType,a);return this._moveTo(c,u,this._inSelectionMode)});if(r.pushStackElement(),t._getViewModel().setCursorStates("moveWordCommand",3,l.map(c=>Jt.fromModelSelection(c))),l.length===1){let c=new P(l[0].positionLineNumber,l[0].positionColumn);t.revealPosition(c,0)}}_moveTo(e,t,i){return i?new Se(e.selectionStartLineNumber,e.selectionStartColumn,t.lineNumber,t.column):new Se(t.lineNumber,t.column,t.lineNumber,t.column)}},r_=class extends bS{_move(e,t,i,o,r){return Fr.moveWordLeft(e,t,i,o,r)}},s_=class extends bS{_move(e,t,i,o,r){return Fr.moveWordRight(e,t,i,o)}},sye=class extends r_{constructor(){super({inSelectionMode:!1,wordNavigationType:0,id:"cursorWordStartLeft",precondition:void 0})}},aye=class extends r_{constructor(){super({inSelectionMode:!1,wordNavigationType:2,id:"cursorWordEndLeft",precondition:void 0})}},lye=class extends r_{constructor(){super({inSelectionMode:!1,wordNavigationType:1,id:"cursorWordLeft",precondition:void 0,kbOpts:{kbExpr:Y.and(T.textInputFocus,Y.and(mC,E2)?.negate()),primary:2063,mac:{primary:527},weight:100}})}},cye=class extends r_{constructor(){super({inSelectionMode:!0,wordNavigationType:0,id:"cursorWordStartLeftSelect",precondition:void 0})}},dye=class extends r_{constructor(){super({inSelectionMode:!0,wordNavigationType:2,id:"cursorWordEndLeftSelect",precondition:void 0})}},uye=class extends r_{constructor(){super({inSelectionMode:!0,wordNavigationType:1,id:"cursorWordLeftSelect",precondition:void 0,kbOpts:{kbExpr:Y.and(T.textInputFocus,Y.and(mC,E2)?.negate()),primary:3087,mac:{primary:1551},weight:100}})}},hye=class extends r_{constructor(){super({inSelectionMode:!1,wordNavigationType:3,id:"cursorWordAccessibilityLeft",precondition:void 0})}_move(e,t,i,o,r){return super._move(Dl(Oc.wordSeparators.defaultValue,e.intlSegmenterLocales),t,i,o,r)}},fye=class extends r_{constructor(){super({inSelectionMode:!0,wordNavigationType:3,id:"cursorWordAccessibilityLeftSelect",precondition:void 0})}_move(e,t,i,o,r){return super._move(Dl(Oc.wordSeparators.defaultValue,e.intlSegmenterLocales),t,i,o,r)}},pye=class extends s_{constructor(){super({inSelectionMode:!1,wordNavigationType:0,id:"cursorWordStartRight",precondition:void 0})}},mye=class extends s_{constructor(){super({inSelectionMode:!1,wordNavigationType:2,id:"cursorWordEndRight",precondition:void 0,kbOpts:{kbExpr:Y.and(T.textInputFocus,Y.and(mC,E2)?.negate()),primary:2065,mac:{primary:529},weight:100}})}},gye=class extends s_{constructor(){super({inSelectionMode:!1,wordNavigationType:2,id:"cursorWordRight",precondition:void 0})}},_ye=class extends s_{constructor(){super({inSelectionMode:!0,wordNavigationType:0,id:"cursorWordStartRightSelect",precondition:void 0})}},bye=class extends s_{constructor(){super({inSelectionMode:!0,wordNavigationType:2,id:"cursorWordEndRightSelect",precondition:void 0,kbOpts:{kbExpr:Y.and(T.textInputFocus,Y.and(mC,E2)?.negate()),primary:3089,mac:{primary:1553},weight:100}})}},vye=class extends s_{constructor(){super({inSelectionMode:!0,wordNavigationType:2,id:"cursorWordRightSelect",precondition:void 0})}},xye=class extends s_{constructor(){super({inSelectionMode:!1,wordNavigationType:3,id:"cursorWordAccessibilityRight",precondition:void 0})}_move(e,t,i,o,r){return super._move(Dl(Oc.wordSeparators.defaultValue,e.intlSegmenterLocales),t,i,o,r)}},wye=class extends s_{constructor(){super({inSelectionMode:!0,wordNavigationType:3,id:"cursorWordAccessibilityRightSelect",precondition:void 0})}_move(e,t,i,o,r){return super._move(Dl(Oc.wordSeparators.defaultValue,e.intlSegmenterLocales),t,i,o,r)}},vS=class extends hn{constructor(e){super(e),this._whitespaceHeuristics=e.whitespaceHeuristics,this._wordNavigationType=e.wordNavigationType}runEditorCommand(e,t,i){let o=e.get(ti);if(!t.hasModel())return;let r=Dl(t.getOption(132),t.getOption(131)),s=t.getModel(),a=t.getSelections(),l=t.getOption(6),c=t.getOption(11),d=o.getLanguageConfiguration(s.getLanguageId()).getAutoClosingPairs(),u=t._getViewModel(),h=a.map(f=>{let p=this._delete({wordSeparators:r,model:s,selection:f,whitespaceHeuristics:this._whitespaceHeuristics,autoClosingDelete:t.getOption(9),autoClosingBrackets:l,autoClosingQuotes:c,autoClosingPairs:d,autoClosedCharacters:u.getCursorAutoClosedCharacters()},this._wordNavigationType);return new Xo(p,"")});t.pushUndoStop(),t.executeCommands(this.id,h),t.pushUndoStop()}},B4=class extends vS{_delete(e,t){let i=Fr.deleteWordLeft(e,t);return i||new S(1,1,1,1)}},W4=class extends vS{_delete(e,t){let i=Fr.deleteWordRight(e,t);if(i)return i;let o=e.model.getLineCount(),r=e.model.getLineMaxColumn(o);return new S(o,r,o,r)}},yye=class extends B4{constructor(){super({whitespaceHeuristics:!1,wordNavigationType:0,id:"deleteWordStartLeft",precondition:T.writable})}},Cye=class extends B4{constructor(){super({whitespaceHeuristics:!1,wordNavigationType:2,id:"deleteWordEndLeft",precondition:T.writable})}},Sye=class extends B4{constructor(){super({whitespaceHeuristics:!0,wordNavigationType:0,id:"deleteWordLeft",precondition:T.writable,kbOpts:{kbExpr:T.textInputFocus,primary:2049,mac:{primary:513},weight:100}})}},kye=class extends W4{constructor(){super({whitespaceHeuristics:!1,wordNavigationType:0,id:"deleteWordStartRight",precondition:T.writable})}},Lye=class extends W4{constructor(){super({whitespaceHeuristics:!1,wordNavigationType:2,id:"deleteWordEndRight",precondition:T.writable})}},Iye=class extends W4{constructor(){super({whitespaceHeuristics:!0,wordNavigationType:2,id:"deleteWordRight",precondition:T.writable,kbOpts:{kbExpr:T.textInputFocus,primary:2068,mac:{primary:532},weight:100}})}},Eye=class extends fe{constructor(){super({id:"deleteInsideWord",precondition:T.writable,label:m("deleteInsideWord","Delete Word"),alias:"Delete Word"})}run(e,t,i){if(!t.hasModel())return;let o=Dl(t.getOption(132),t.getOption(131)),r=t.getModel(),a=t.getSelections().map(l=>{let c=Fr.deleteInsideWord(o,r,l);return new Xo(c,"")});t.pushUndoStop(),t.executeCommands(this.id,a),t.pushUndoStop()}};ye(new sye);ye(new aye);ye(new lye);ye(new cye);ye(new dye);ye(new uye);ye(new pye);ye(new mye);ye(new gye);ye(new _ye);ye(new bye);ye(new vye);ye(new hye);ye(new fye);ye(new xye);ye(new wye);ye(new yye);ye(new Cye);ye(new Sye);ye(new kye);ye(new Lye);ye(new Iye);ee(Eye);mt();lP();we();Si();Gi();var Tye=class extends vS{constructor(){super({whitespaceHeuristics:!0,wordNavigationType:0,id:"deleteWordPartLeft",precondition:T.writable,kbOpts:{kbExpr:T.textInputFocus,primary:0,mac:{primary:769},weight:100}})}_delete(e,t){let i=u0.deleteWordPartLeft(e);return i||new S(1,1,1,1)}},Dye=class extends vS{constructor(){super({whitespaceHeuristics:!0,wordNavigationType:2,id:"deleteWordPartRight",precondition:T.writable,kbOpts:{kbExpr:T.textInputFocus,primary:0,mac:{primary:788},weight:100}})}_delete(e,t){let i=u0.deleteWordPartRight(e);if(i)return i;let o=e.model.getLineCount(),r=e.model.getLineMaxColumn(o);return new S(o,r,o,r)}},FZ=class extends bS{_move(e,t,i,o,r){return u0.moveWordPartLeft(e,t,i,r)}},Nye=class extends FZ{constructor(){super({inSelectionMode:!1,wordNavigationType:0,id:"cursorWordPartLeft",precondition:void 0,kbOpts:{kbExpr:T.textInputFocus,primary:0,mac:{primary:783},weight:100}})}};wt.registerCommandAlias("cursorWordPartStartLeft","cursorWordPartLeft");var Rye=class extends FZ{constructor(){super({inSelectionMode:!0,wordNavigationType:0,id:"cursorWordPartLeftSelect",precondition:void 0,kbOpts:{kbExpr:T.textInputFocus,primary:0,mac:{primary:1807},weight:100}})}};wt.registerCommandAlias("cursorWordPartStartLeftSelect","cursorWordPartLeftSelect");var BZ=class extends bS{_move(e,t,i,o,r){return u0.moveWordPartRight(e,t,i)}},Aye=class extends BZ{constructor(){super({inSelectionMode:!1,wordNavigationType:2,id:"cursorWordPartRight",precondition:void 0,kbOpts:{kbExpr:T.textInputFocus,primary:0,mac:{primary:785},weight:100}})}},Mye=class extends BZ{constructor(){super({inSelectionMode:!0,wordNavigationType:2,id:"cursorWordPartRightSelect",precondition:void 0,kbOpts:{kbExpr:T.textInputFocus,primary:0,mac:{primary:1809},weight:100}})}};ye(new Tye);ye(new Dye);ye(new Nye);ye(new Rye);ye(new Aye);ye(new Mye);Pl();j();mt();pe();var WZ=class extends D{static{this.ID="editor.contrib.readOnlyMessageController"}constructor(e){super(),this.editor=e,this._register(this.editor.onDidAttemptReadOnlyEdit(()=>this._onDidAttemptReadOnlyEdit()))}_onDidAttemptReadOnlyEdit(){let e=Wa.get(this.editor);if(e&&this.editor.hasModel()){let t=this.editor.getOptions().get(93);t||(this.editor.isSimpleWidget?t=new Eo(m("editor.simple.readonly","Cannot edit in read-only input")):t=new Eo(m("editor.readonly","Cannot edit in read-only editor"))),e.showMessage(t,this.editor.getPosition())}}};ze(WZ.ID,WZ,2);var aIn=Ue(sKe());og();ke();j();mt();Bt();var HZ=class extends D{static{this.ID="editor.contrib.iPadShowKeyboard"}constructor(e){super(),this.editor=e,this.widget=null,Xa&&(this._register(e.onDidChangeConfiguration(()=>this.update())),this.update())}update(){let e=!this.editor.getOption(92);!this.widget&&e?this.widget=new Oye(this.editor):this.widget&&!e&&(this.widget.dispose(),this.widget=null)}dispose(){super.dispose(),this.widget&&(this.widget.dispose(),this.widget=null)}},Oye=class n extends D{static{this.ID="editor.contrib.ShowKeyboardWidget"}constructor(e){super(),this.editor=e,this._domNode=document.createElement("textarea"),this._domNode.className="iPadShowKeyboard",this._register(U(this._domNode,"touchstart",t=>{this.editor.focus()})),this._register(U(this._domNode,"focus",t=>{this.editor.focus()})),this.editor.addOverlayWidget(this)}dispose(){this.editor.removeOverlayWidget(this),super.dispose()}getId(){return n.ID}getDomNode(){return this._domNode}getPosition(){return{preference:1}}};ze(HZ.ID,HZ,3);var rDn=Ue(cKe());br();BC();og();pe();br();j();Pn();BC();Jc();var sSt=function(n,e,t,i){var o=arguments.length,r=o<3?e:i===null?i=Object.getOwnPropertyDescriptor(e,t):i,s;if(typeof Reflect=="object"&&typeof Reflect.decorate=="function")r=Reflect.decorate(n,e,t,i);else for(var a=n.length-1;a>=0;a--)(s=n[a])&&(r=(o<3?s(r):o>3?s(e,t,r):s(e,t))||r);return o>3&&r&&Object.defineProperty(e,t,r),r},dKe=function(n,e){return function(t,i){e(t,i,n)}},U4,zZ=class{static{U4=this}static{this.PREFIX="?"}constructor(e,t){this.quickInputService=e,this.keybindingService=t,this.registry=ei.as(Fh.Quickaccess)}provide(e){let t=new H;return t.add(e.onDidAccept(()=>{let[i]=e.selectedItems;i&&this.quickInputService.quickAccess.show(i.prefix,{preserveValue:!0})})),t.add(e.onDidChangeValue(i=>{let o=this.registry.getQuickAccessProvider(i.substr(U4.PREFIX.length));o&&o.prefix&&o.prefix!==U4.PREFIX&&this.quickInputService.quickAccess.show(o.prefix,{preserveValue:!0})})),e.items=this.getQuickAccessProviders().filter(i=>i.prefix!==U4.PREFIX),t}getQuickAccessProviders(){return this.registry.getQuickAccessProviders().sort((t,i)=>t.prefix.localeCompare(i.prefix)).flatMap(t=>this.createPicks(t))}createPicks(e){return e.helpEntries.map(t=>{let i=t.prefix||e.prefix,o=i||"\u2026";return{prefix:i,label:o,keybinding:t.commandId?this.keybindingService.lookupKeybinding(t.commandId):void 0,ariaLabel:m("helpPickAriaLabel","{0}, {1}",o,t.description),description:t.description}})}};zZ=U4=sSt([dKe(0,Pr),dKe(1,_t)],zZ);ei.as(Fh.Quickaccess).registerQuickAccessProvider({ctor:zZ,prefix:"",helpEntries:[{description:B7.helpQuickAccessActionLabel}]});j();uT();sx();j();uT();Zr();Nu();Yi();Ns();var qD=class{constructor(e){this.options=e,this.rangeHighlightDecorationId=void 0}provide(e,t,i){let o=new H;e.canAcceptInBackground=!!this.options?.canAcceptInBackground,e.matchOnLabel=e.matchOnDescription=e.matchOnDetail=e.sortByLabel=!1;let r=o.add(new Hi);return r.value=this.doProvide(e,t,i),o.add(this.onDidActiveTextEditorControlChange(()=>{r.value=void 0,r.value=this.doProvide(e,t)})),o}doProvide(e,t,i){let o=new H,r=this.activeTextEditorControl;if(r&&this.canProvideWithTextEditor(r)){let s={editor:r},a=Pj(r);if(a){let l=r.saveViewState()??void 0;o.add(a.onDidChangeCursorPosition(()=>{l=r.saveViewState()??void 0})),s.restoreViewState=()=>{l&&r===this.activeTextEditorControl&&r.restoreViewState(l)},o.add(yd(t.onCancellationRequested)(()=>s.restoreViewState?.()))}o.add(ge(()=>this.clearDecorations(r))),o.add(this.provideWithTextEditor(s,e,t,i))}else o.add(this.provideWithoutTextEditor(e,t));return o}canProvideWithTextEditor(e){return!0}gotoLocation({editor:e},t){e.setSelection(t.range,"code.jump"),e.revealRangeInCenter(t.range,0),t.preserveFocus||e.focus();let i=e.getModel();i&&"getLineContent"in i&&Ol(`${i.getLineContent(t.range.startLineNumber)}`)}getModel(e){return RP(e)?e.getModel()?.modified:e.getModel()}addDecorations(e,t){e.changeDecorations(i=>{let o=[];this.rangeHighlightDecorationId&&(o.push(this.rangeHighlightDecorationId.overviewRulerDecorationId),o.push(this.rangeHighlightDecorationId.rangeHighlightId),this.rangeHighlightDecorationId=void 0);let r=[{range:t,options:{description:"quick-access-range-highlight",className:"rangeHighlight",isWholeLine:!0}},{range:t,options:{description:"quick-access-range-highlight-overview",overviewRuler:{color:vn(RW),position:Js.Full}}}],[s,a]=i.deltaDecorations(o,r);this.rangeHighlightDecorationId={rangeHighlightId:s,overviewRulerDecorationId:a}})}clearDecorations(e){let t=this.rangeHighlightDecorationId;t&&(e.changeDecorations(i=>{i.deltaDecorations([t.overviewRulerDecorationId,t.rangeHighlightId],[])}),this.rangeHighlightDecorationId=void 0)}};pe();var VZ=class n extends qD{static{this.PREFIX=":"}constructor(){super({canAcceptInBackground:!0})}provideWithoutTextEditor(e){let t=m("cannotRunGotoLine","Open a text editor first to go to a line.");return e.items=[{label:t}],e.ariaLabel=t,D.None}provideWithTextEditor(e,t,i){let o=e.editor,r=new H;r.add(t.onDidAccept(l=>{let[c]=t.selectedItems;if(c){if(!this.isValidLineNumber(o,c.lineNumber))return;this.gotoLocation(e,{range:this.toRange(c.lineNumber,c.column),keyMods:t.keyMods,preserveFocus:l.inBackground}),l.inBackground||t.hide()}}));let s=()=>{let l=this.parsePosition(o,t.value.trim().substr(n.PREFIX.length)),c=this.getPickLabel(o,l.lineNumber,l.column);if(t.items=[{lineNumber:l.lineNumber,column:l.column,label:c}],t.ariaLabel=c,!this.isValidLineNumber(o,l.lineNumber)){this.clearDecorations(o);return}let d=this.toRange(l.lineNumber,l.column);o.revealRangeInCenter(d,0),this.addDecorations(o,d)};s(),r.add(t.onDidChangeValue(()=>s()));let a=Pj(o);return a&&a.getOptions().get(68).renderType===2&&(a.updateOptions({lineNumbers:"on"}),r.add(ge(()=>a.updateOptions({lineNumbers:"relative"})))),r}toRange(e=1,t=1){return{startLineNumber:e,startColumn:t,endLineNumber:e,endColumn:t}}parsePosition(e,t){let i=t.split(/,|:|#/).map(r=>parseInt(r,10)).filter(r=>!isNaN(r)),o=this.lineCount(e)+1;return{lineNumber:i[0]>0?i[0]:o+i[0],column:i[1]}}getPickLabel(e,t,i){if(this.isValidLineNumber(e,t))return this.isValidColumn(e,t,i)?m("gotoLineColumnLabel","Go to line {0} and character {1}.",t,i):m("gotoLineLabel","Go to line {0}.",t);let o=e.getPosition()||{lineNumber:1,column:1},r=this.lineCount(e);return r>1?m("gotoLineLabelEmptyWithLimit","Current Line: {0}, Character: {1}. Type a line number between 1 and {2} to navigate to.",o.lineNumber,o.column,r):m("gotoLineLabelEmpty","Current Line: {0}, Character: {1}. Type a line number to navigate to.",o.lineNumber,o.column)}isValidLineNumber(e,t){return!t||typeof t!="number"?!1:t>0&&t<=this.lineCount(e)}isValidColumn(e,t,i){if(!i||typeof i!="number")return!1;let o=this.getModel(e);if(!o)return!1;let r={lineNumber:t,column:i};return o.validatePosition(r).equals(r)}lineCount(e){return this.getModel(e)?.getLineCount()??0}};br();BC();Po();og();Ie();mt();Si();Jc();var aSt=function(n,e,t,i){var o=arguments.length,r=o<3?e:i===null?i=Object.getOwnPropertyDescriptor(e,t):i,s;if(typeof Reflect=="object"&&typeof Reflect.decorate=="function")r=Reflect.decorate(n,e,t,i);else for(var a=n.length-1;a>=0;a--)(s=n[a])&&(r=(o<3?s(r):o>3?s(e,t,r):s(e,t))||r);return o>3&&r&&Object.defineProperty(e,t,r),r},lSt=function(n,e){return function(t,i){e(t,i,n)}},$4=class extends VZ{constructor(e){super(),this.editorService=e,this.onDidActiveTextEditorControlChange=ne.None}get activeTextEditorControl(){return this.editorService.getFocusedCodeEditor()??void 0}};$4=aSt([lSt(0,xt)],$4);var UZ=class n extends fe{static{this.ID="editor.action.gotoLine"}constructor(){super({id:n.ID,label:TM.gotoLineActionLabel,alias:"Go to Line/Column...",precondition:void 0,kbOpts:{kbExpr:T.focus,primary:2085,mac:{primary:293},weight:100}})}run(e){e.get(Pr).quickAccess.show($4.PREFIX)}};ee(UZ);ei.as(Fh.Quickaccess).registerQuickAccessProvider({ctor:$4,prefix:$4.PREFIX,helpEntries:[{description:TM.gotoLineActionLabel,commandId:UZ.ID}]});ft();ci();Qi();bn();Th();sp();Bt();Qe();var fKe=[void 0,[]];function jZ(n,e,t=0,i=0){let o=e;return o.values&&o.values.length>1?cSt(n,o.values,t,i):pKe(n,e,t,i)}function cSt(n,e,t,i){let o=0,r=[];for(let s of e){let[a,l]=pKe(n,s,t,i);if(typeof a!="number")return fKe;o+=a,r.push(...l)}return[o,dSt(r)]}function pKe(n,e,t,i){let o=Jm(e.original,e.originalLowercase,t,n,n.toLowerCase(),i,{firstMatchCanBeWeak:!0,boostFullMatch:!0});return o?[o[0],iw(o)]:fKe}var bEn=Object.freeze({score:0});function dSt(n){let e=n.sort((o,r)=>o.start-r.start),t=[],i;for(let o of e)!i||!uSt(i,o)?(i=o,t.push(o)):(i.start=Math.min(i.start,o.start),i.end=Math.max(i.end,o.end));return t}function uSt(n,e){return!(n.end=0,s=uKe(n),a,l=n.split(mKe);if(l.length>1)for(let c of l){let d=uKe(c),{pathNormalized:u,normalized:h,normalizedLowercase:f}=hKe(c);h&&(a||(a=[]),a.push({original:c,originalLowercase:c.toLowerCase(),pathNormalized:u,normalized:h,normalizedLowercase:f,expectContiguousMatch:d}))}return{original:n,originalLowercase:e,pathNormalized:t,normalized:i,normalizedLowercase:o,values:a,containsPathSeparator:r,expectContiguousMatch:s}}function hKe(n){let e;kn?e=n.replace(/\//g,Cd):e=n.replace(/\\/g,Cd);let t=FTe(e).replace(/\s|"/g,"");return{pathNormalized:e,normalized:t,normalizedLowercase:t.toLowerCase()}}function Hye(n){return Array.isArray(n)?$Z(n.map(e=>e.original).join(mKe)):$Z(n.original)}j();Qe();we();Ji();_D();pe();Qt();Ad();var hSt=function(n,e,t,i){var o=arguments.length,r=o<3?e:i===null?i=Object.getOwnPropertyDescriptor(e,t):i,s;if(typeof Reflect=="object"&&typeof Reflect.decorate=="function")r=Reflect.decorate(n,e,t,i);else for(var a=n.length-1;a>=0;a--)(s=n[a])&&(r=(o<3?s(r):o>3?s(e,t,r):s(e,t))||r);return o>3&&r&&Object.defineProperty(e,t,r),r},gKe=function(n,e){return function(t,i){e(t,i,n)}},qZ,wy=class extends qD{static{qZ=this}static{this.PREFIX="@"}static{this.SCOPE_PREFIX=":"}static{this.PREFIX_BY_CATEGORY=`${this.PREFIX}${this.SCOPE_PREFIX}`}constructor(e,t,i=Object.create(null)){super(i),this._languageFeaturesService=e,this._outlineModelService=t,this.options=i,this.options.canAcceptInBackground=!0}provideWithoutTextEditor(e){return this.provideLabelPick(e,m("cannotRunGotoSymbolWithoutEditor","To go to a symbol, first open a text editor with symbol information.")),D.None}provideWithTextEditor(e,t,i,o){let r=e.editor,s=this.getModel(r);return s?this._languageFeaturesService.documentSymbolProvider.has(s)?this.doProvideWithEditorSymbols(e,s,t,i,o):this.doProvideWithoutEditorSymbols(e,s,t,i):D.None}doProvideWithoutEditorSymbols(e,t,i,o){let r=new H;return this.provideLabelPick(i,m("cannotRunGotoSymbolWithoutSymbolProvider","The active text editor does not provide symbol information.")),(async()=>!await this.waitForLanguageSymbolRegistry(t,r)||o.isCancellationRequested||r.add(this.doProvideWithEditorSymbols(e,t,i,o)))(),r}provideLabelPick(e,t){e.items=[{label:t,index:0,kind:14}],e.ariaLabel=t}async waitForLanguageSymbolRegistry(e,t){if(this._languageFeaturesService.documentSymbolProvider.has(e))return!0;let i=new mu,o=t.add(this._languageFeaturesService.documentSymbolProvider.onDidChange(()=>{this._languageFeaturesService.documentSymbolProvider.has(e)&&(o.dispose(),i.complete(!0))}));return t.add(ge(()=>i.complete(!1))),i.p}doProvideWithEditorSymbols(e,t,i,o,r){let s=e.editor,a=new H;a.add(i.onDidAccept(u=>{let[h]=i.selectedItems;h&&h.range&&(this.gotoLocation(e,{range:h.range.selection,keyMods:i.keyMods,preserveFocus:u.inBackground}),r?.handleAccept?.(h),u.inBackground||i.hide())})),a.add(i.onDidTriggerItemButton(({item:u})=>{u&&u.range&&(this.gotoLocation(e,{range:u.range.selection,keyMods:i.keyMods,forceSideBySide:!0}),i.hide())}));let l=this.getDocumentSymbols(t,o),c,d=async u=>{c?.dispose(!0),i.busy=!1,c=new qt(o),i.busy=!0;try{let h=$Z(i.value.substr(qZ.PREFIX.length).trim()),f=await this.doGetSymbolPicks(l,h,void 0,c.token,t);if(o.isCancellationRequested)return;if(f.length>0){if(i.items=f,u&&h.original.length===0){let p=eb(f,g=>!!(g.type!=="separator"&&g.range&&S.containsPosition(g.range.decoration,u)));p&&(i.activeItems=[p])}}else h.original.length>0?this.provideLabelPick(i,m("noMatchingSymbolResults","No matching editor symbols")):this.provideLabelPick(i,m("noSymbolResults","No editor symbols"))}finally{o.isCancellationRequested||(i.busy=!1)}};return a.add(i.onDidChangeValue(()=>d(void 0))),d(s.getSelection()?.getPosition()),a.add(i.onDidChangeActive(()=>{let[u]=i.activeItems;u&&u.range&&(s.revealRangeInCenter(u.range.selection,0),this.addDecorations(s,u.range.decoration))})),a}async doGetSymbolPicks(e,t,i,o,r){let s=await e;if(o.isCancellationRequested)return[];let a=t.original.indexOf(qZ.SCOPE_PREFIX)===0,l=a?1:0,c,d;t.values&&t.values.length>1?(c=Hye(t.values[0]),d=Hye(t.values.slice(1))):c=t;let u,h=this.options?.openSideBySideDirection?.();h&&(u=[{iconClass:h==="right"?Oe.asClassName(oe.splitHorizontal):Oe.asClassName(oe.splitVertical),tooltip:h==="right"?m("openToSide","Open to the Side"):m("openToBottom","Open to the Bottom")}]);let f=[];for(let _=0;_l){let F=!1;if(c!==t&&([C,L]=jZ(x,{...t,values:void 0},l,w),typeof C=="number"&&(F=!0)),typeof C!="number"&&([C,L]=jZ(x,c,l,w),typeof C!="number"))continue;if(!F&&d){if(y&&d.original.length>0&&([E,N]=jZ(y,d)),typeof E!="number")continue;typeof C=="number"&&(C+=E)}}let M=b.tags&&b.tags.indexOf(1)>=0;f.push({index:_,kind:b.kind,score:C,label:x,ariaLabel:DTe(b.name,b.kind),description:y,highlights:M?void 0:{label:L,description:N},range:{selection:S.collapseToStart(b.selectionRange),decoration:b.range},uri:r.uri,symbolName:v,strikethrough:M,buttons:u})}let p=f.sort((_,b)=>a?this.compareByKindAndScore(_,b):this.compareByScore(_,b)),g=[];if(a){let x=function(){b&&typeof _=="number"&&v>0&&(b.label=dh(Vye[_]||zye,v))},_,b,v=0;for(let w of p)_!==w.kind?(x(),_=w.kind,v=1,b={type:"separator"},g.push(b)):v++,g.push(w);x()}else p.length>0&&(g=[{label:m("symbols","symbols ({0})",f.length),type:"separator"},...p]);return g}compareByScore(e,t){if(typeof e.score!="number"&&typeof t.score=="number")return 1;if(typeof e.score=="number"&&typeof t.score!="number")return-1;if(typeof e.score=="number"&&typeof t.score=="number"){if(e.score>t.score)return-1;if(e.scoret.index?1:0}compareByKindAndScore(e,t){let i=Vye[e.kind]||zye,o=Vye[t.kind]||zye,r=i.localeCompare(o);return r===0?this.compareByScore(e,t):r}async getDocumentSymbols(e,t){let i=await this._outlineModelService.getOrCreate(e,t);return t.isCancellationRequested?[]:i.asListOfDocumentSymbols()}};wy=qZ=hSt([gKe(0,le),gKe(1,lv)],wy);var zye=m("property","properties ({0})"),Vye={5:m("method","methods ({0})"),11:m("function","functions ({0})"),8:m("_constructor","constructors ({0})"),12:m("variable","variables ({0})"),4:m("class","classes ({0})"),22:m("struct","structs ({0})"),23:m("event","events ({0})"),24:m("operator","operators ({0})"),10:m("interface","interfaces ({0})"),2:m("namespace","namespaces ({0})"),3:m("package","packages ({0})"),25:m("typeParameter","type parameters ({0})"),1:m("modules","modules ({0})"),6:m("property","properties ({0})"),9:m("enum","enumerations ({0})"),21:m("enumMember","enumeration members ({0})"),14:m("string","strings ({0})"),0:m("file","files ({0})"),17:m("array","arrays ({0})"),15:m("number","numbers ({0})"),16:m("boolean","booleans ({0})"),18:m("object","objects ({0})"),19:m("key","keys ({0})"),7:m("field","fields ({0})"),13:m("constant","constants ({0})")};br();BC();Po();og();Ie();mt();Si();Jc();_D();Qt();var fSt=function(n,e,t,i){var o=arguments.length,r=o<3?e:i===null?i=Object.getOwnPropertyDescriptor(e,t):i,s;if(typeof Reflect=="object"&&typeof Reflect.decorate=="function")r=Reflect.decorate(n,e,t,i);else for(var a=n.length-1;a>=0;a--)(s=n[a])&&(r=(o<3?s(r):o>3?s(e,t,r):s(e,t))||r);return o>3&&r&&Object.defineProperty(e,t,r),r},Uye=function(n,e){return function(t,i){e(t,i,n)}},$ye=class extends wy{constructor(e,t,i){super(t,i),this.editorService=e,this.onDidActiveTextEditorControlChange=ne.None}get activeTextEditorControl(){return this.editorService.getFocusedCodeEditor()??void 0}};$ye=fSt([Uye(0,xt),Uye(1,le),Uye(2,lv)],$ye);var KZ=class n extends fe{static{this.ID="editor.action.quickOutline"}constructor(){super({id:n.ID,label:cI.quickOutlineActionLabel,alias:"Go to Symbol...",precondition:T.hasDocumentSymbolProvider,kbOpts:{kbExpr:T.focus,primary:3117,weight:100},contextMenuOpts:{group:"navigation",order:3}})}run(e){e.get(Pr).quickAccess.show(wy.PREFIX,{itemActivation:Pu.NONE})}};ee(KZ);ei.as(Fh.Quickaccess).registerQuickAccessProvider({ctor:$ye,prefix:wy.PREFIX,helpEntries:[{description:cI.quickOutlineActionLabel,prefix:wy.PREFIX,commandId:KZ.ID},{description:cI.quickOutlineByCategoryActionLabel,prefix:wy.PREFIX_BY_CATEGORY}]});br();BC();og();Po();fC();rle();je();Th();sx();j();Ds();function pSt(n){let e=new Map;for(let t of n)e.set(t,(e.get(t)??0)+1);return e}var GZ=class n{constructor(){this.chunkCount=0,this.chunkOccurrences=new Map,this.documents=new Map}calculateScores(e,t){let i=this.computeEmbedding(e),o=new Map,r=[];for(let[s,a]of this.documents){if(t.isCancellationRequested)return[];for(let l of a.chunks){let c=this.computeSimilarityScore(l,i,o);c>0&&r.push({key:s,score:c})}}return r}static termFrequencies(e){return pSt(n.splitTerms(e))}static*splitTerms(e){let t=i=>i.toLowerCase();for(let[i]of e.matchAll(/\b\p{Letter}[\p{Letter}\d]{2,}\b/gu)){yield t(i);let o=i.replace(/([a-z])([A-Z])/g,"$1 $2").split(/\s+/g);if(o.length>1)for(let r of o)r.length>2&&/\p{Letter}{3,}/gu.test(r)&&(yield t(r))}}updateDocuments(e){for(let{key:t}of e)this.deleteDocument(t);for(let t of e){let i=[];for(let o of t.textChunks){let r=n.termFrequencies(o);for(let s of r.keys())this.chunkOccurrences.set(s,(this.chunkOccurrences.get(s)??0)+1);i.push({text:o,tf:r})}this.chunkCount+=i.length,this.documents.set(t.key,{chunks:i})}return this}deleteDocument(e){let t=this.documents.get(e);if(t){this.documents.delete(e),this.chunkCount-=t.chunks.length;for(let i of t.chunks)for(let o of i.tf.keys()){let r=this.chunkOccurrences.get(o);if(typeof r=="number"){let s=r-1;s<=0?this.chunkOccurrences.delete(o):this.chunkOccurrences.set(o,s)}}}}computeSimilarityScore(e,t,i){let o=0;for(let[r,s]of Object.entries(t)){let a=e.tf.get(r);if(!a)continue;let l=i.get(r);typeof l!="number"&&(l=this.computeIdf(r),i.set(r,l));let c=a*l;o+=c*s}return o}computeEmbedding(e){let t=n.termFrequencies(e);return this.computeTfidf(t)}computeIdf(e){let t=this.chunkOccurrences.get(e)??0;return t>0?Math.log((this.chunkCount+1)/t):0}computeTfidf(e){let t=Object.create(null);for(let[i,o]of e){let r=this.computeIdf(i);r>0&&(t[i]=o*r)}return t}};function _Ke(n){let e=n.slice(0);e.sort((i,o)=>o.score-i.score);let t=e[0]?.score??0;if(t>0)for(let i of e)i.score/=t;return e}pe();Gi();en();AL();Fe();Pn();ac();ft();ci();j();yi();var KD;(function(n){n[n.NO_ACTION=0]="NO_ACTION",n[n.CLOSE_PICKER=1]="CLOSE_PICKER",n[n.REFRESH_PICKER=2]="REFRESH_PICKER",n[n.REMOVE_ITEM=3]="REMOVE_ITEM"})(KD||(KD={}));function jye(n){let e=n;return Array.isArray(e.items)}function bKe(n){let e=n;return!!e.picks&&e.additionalPicks instanceof Promise}var YZ=class extends D{constructor(e,t){super(),this.prefix=e,this.options=t}provide(e,t,i){let o=new H;e.canAcceptInBackground=!!this.options?.canAcceptInBackground,e.matchOnLabel=e.matchOnDescription=e.matchOnDetail=e.sortByLabel=!1;let r,s=o.add(new Hi),a=async()=>{let c=s.value=new H;r?.dispose(!0),e.busy=!1,r=new qt(t);let d=r.token,u=e.value.substring(this.prefix.length);this.options?.shouldSkipTrimPickFilter||(u=u.trim());let h=this._getPicks(u,c,d,i),f=(g,_)=>{let b,v;if(jye(g)?(b=g.items,v=g.active):b=g,b.length===0){if(_)return!1;(u.length>0||e.hideInput)&&this.options?.noResultsPick&&(ex(this.options.noResultsPick)?b=[this.options.noResultsPick(u)]:b=[this.options.noResultsPick])}return e.items=b,v&&(e.activeItems=[v]),!0},p=async g=>{let _=!1,b=!1;await Promise.all([(async()=>{typeof g.mergeDelay=="number"&&(await oc(g.mergeDelay),d.isCancellationRequested)||b||(_=f(g.picks,!0))})(),(async()=>{e.busy=!0;try{let v=await g.additionalPicks;if(d.isCancellationRequested)return;let x,w;jye(g.picks)?(x=g.picks.items,w=g.picks.active):x=g.picks;let y,C;if(jye(v)?(y=v.items,C=v.active):y=v,y.length>0||!_){let L;if(!w&&!C){let E=e.activeItems[0];E&&x.indexOf(E)!==-1&&(L=E)}f({items:[...x,...y],active:w||C||L})}}finally{d.isCancellationRequested||(e.busy=!1),b=!0}})()])};if(h!==null)if(bKe(h))await p(h);else if(!(h instanceof Promise))f(h);else{e.busy=!0;try{let g=await h;if(d.isCancellationRequested)return;bKe(g)?await p(g):f(g)}finally{d.isCancellationRequested||(e.busy=!1)}}};o.add(e.onDidChangeValue(()=>a())),a(),o.add(e.onDidAccept(c=>{if(i?.handleAccept){c.inBackground||e.hide(),i.handleAccept?.(e.activeItems[0]);return}let[d]=e.selectedItems;typeof d?.accept=="function"&&(c.inBackground||e.hide(),d.accept(e.keyMods,c))}));let l=async(c,d)=>{if(typeof d.trigger!="function")return;let u=d.buttons?.indexOf(c)??-1;if(u>=0){let h=d.trigger(u,e.keyMods),f=typeof h=="number"?h:await h;if(t.isCancellationRequested)return;switch(f){case KD.NO_ACTION:break;case KD.CLOSE_PICKER:e.hide();break;case KD.REFRESH_PICKER:a();break;case KD.REMOVE_ITEM:{let p=e.items.indexOf(d);if(p!==-1){let g=e.items.slice(),_=g.splice(p,1),b=e.activeItems.filter(x=>x!==_[0]),v=e.keepScrollPosition;e.keepScrollPosition=!0,e.items=g,b&&(e.activeItems=b),e.keepScrollPosition=v}break}}}};return o.add(e.onDidTriggerItemButton(({button:c,item:d})=>l(c,d))),o.add(e.onDidTriggerSeparatorButton(({button:c,separator:d})=>l(c,d))),o}};kp();sc();var vKe=function(n,e,t,i){var o=arguments.length,r=o<3?e:i===null?i=Object.getOwnPropertyDescriptor(e,t):i,s;if(typeof Reflect=="object"&&typeof Reflect.decorate=="function")r=Reflect.decorate(n,e,t,i);else for(var a=n.length-1;a>=0;a--)(s=n[a])&&(r=(o<3?s(r):o>3?s(e,t,r):s(e,t))||r);return o>3&&r&&Object.defineProperty(e,t,r),r},yy=function(n,e){return function(t,i){e(t,i,n)}},xS,Br,ZZ=class extends YZ{static{xS=this}static{this.PREFIX=">"}static{this.TFIDF_THRESHOLD=.5}static{this.TFIDF_MAX_RESULTS=5}static{this.WORD_FILTER=a7(hC,d2e,Use)}constructor(e,t,i,o,r,s){super(xS.PREFIX,e),this.instantiationService=t,this.keybindingService=i,this.commandService=o,this.telemetryService=r,this.dialogService=s,this.commandsHistory=this._register(this.instantiationService.createInstance(qye)),this.options=e}async _getPicks(e,t,i,o){let r=await this.getCommandPicks(i);if(i.isCancellationRequested)return[];let s=yd(()=>{let f=new GZ;f.updateDocuments(r.map(g=>({key:g.commandId,textChunks:[this.getTfIdfChunk(g)]})));let p=f.calculateScores(e,i);return _Ke(p).filter(g=>g.score>xS.TFIDF_THRESHOLD).slice(0,xS.TFIDF_MAX_RESULTS)}),a=[];for(let f of r){let p=xS.WORD_FILTER(e,f.label)??void 0,g=f.commandAlias?xS.WORD_FILTER(e,f.commandAlias)??void 0:void 0;if(p||g)f.highlights={label:p,detail:this.options.showAlias?g:void 0},a.push(f);else if(e===f.commandId)a.push(f);else if(e.length>=3){let _=s();if(i.isCancellationRequested)return[];let b=_.find(v=>v.key===f.commandId);b&&(f.tfIdfScore=b.score,a.push(f))}}let l=new Map;for(let f of a){let p=l.get(f.label);p?(f.description=f.commandId,p.description=p.commandId):l.set(f.label,f)}a.sort((f,p)=>{if(f.tfIdfScore&&p.tfIdfScore)return f.tfIdfScore===p.tfIdfScore?f.label.localeCompare(p.label):p.tfIdfScore-f.tfIdfScore;if(f.tfIdfScore)return 1;if(p.tfIdfScore)return-1;let g=this.commandsHistory.peek(f.commandId),_=this.commandsHistory.peek(p.commandId);if(g&&_)return g>_?-1:1;if(g)return-1;if(_)return 1;if(this.options.suggestedCommandIds){let b=this.options.suggestedCommandIds.has(f.commandId),v=this.options.suggestedCommandIds.has(p.commandId);if(b&&v)return 0;if(b)return-1;if(v)return 1}return f.label.localeCompare(p.label)});let c=[],d=!1,u=!0,h=!!this.options.suggestedCommandIds;for(let f=0;f{let f=await this.getAdditionalCommandPicks(r,a,e,i);if(i.isCancellationRequested)return[];let p=f.map(g=>this.toCommandPick(g,o));return u&&p[0]?.type!=="separator"&&p.unshift({type:"separator",label:m("suggested","similar commands")}),p})()}:c}toCommandPick(e,t){if(e.type==="separator")return e;let i=this.keybindingService.lookupKeybinding(e.commandId),o=i?m("commandPickAriaLabelWithKeybinding","{0}, {1}",e.label,i.getAriaLabel()):e.label;return{...e,ariaLabel:o,detail:this.options.showAlias&&e.commandAlias!==e.label?e.commandAlias:void 0,keybinding:i,accept:async()=>{this.commandsHistory.push(e.commandId),this.telemetryService.publicLog2("workbenchActionExecuted",{id:e.commandId,from:t?.from??"quick open"});try{e.args?.length?await this.commandService.executeCommand(e.commandId,...e.args):await this.commandService.executeCommand(e.commandId)}catch(r){$r(r)||this.dialogService.error(m("canNotRun","Command '{0}' resulted in an error",e.label),WT(r))}}}}getTfIdfChunk({label:e,commandAlias:t,commandDescription:i}){let o=e;return t&&t!==e&&(o+=` - ${t}`),i&&i.value!==e&&(o+=` - ${i.value===i.original?i.value:`${i.value} (${i.original})`}`),o}};ZZ=xS=vKe([yy(1,he),yy(2,_t),yy(3,$t),yy(4,Fn),yy(5,Um)],ZZ);var qye=class extends D{static{Br=this}static{this.DEFAULT_COMMANDS_HISTORY_LENGTH=50}static{this.PREF_KEY_CACHE="commandPalette.mru.cache"}static{this.PREF_KEY_COUNTER="commandPalette.mru.counter"}static{this.counter=1}static{this.hasChanges=!1}constructor(e,t,i){super(),this.storageService=e,this.configurationService=t,this.logService=i,this.configuredCommandsHistoryLength=0,this.updateConfiguration(),this.load(),this.registerListeners()}registerListeners(){this._register(this.configurationService.onDidChangeConfiguration(e=>this.updateConfiguration(e))),this._register(this.storageService.onWillSaveState(e=>{e.reason===hw.SHUTDOWN&&this.saveState()}))}updateConfiguration(e){e&&!e.affectsConfiguration("workbench.commandPalette.history")||(this.configuredCommandsHistoryLength=Br.getConfiguredCommandHistoryLength(this.configurationService),Br.cache&&Br.cache.limit!==this.configuredCommandsHistoryLength&&(Br.cache.limit=this.configuredCommandsHistoryLength,Br.hasChanges=!0))}load(){let e=this.storageService.get(Br.PREF_KEY_CACHE,0),t;if(e)try{t=JSON.parse(e)}catch(o){this.logService.error(`[CommandsHistory] invalid data: ${o}`)}let i=Br.cache=new Ts(this.configuredCommandsHistoryLength,1);if(t){let o;t.usesLRU?o=t.entries:o=t.entries.sort((r,s)=>r.value-s.value),o.forEach(r=>i.set(r.key,r.value))}Br.counter=this.storageService.getNumber(Br.PREF_KEY_COUNTER,0,Br.counter)}push(e){Br.cache&&(Br.cache.set(e,Br.counter++),Br.hasChanges=!0)}peek(e){return Br.cache?.peek(e)}saveState(){if(!Br.cache||!Br.hasChanges)return;let e={usesLRU:!0,entries:[]};Br.cache.forEach((t,i)=>e.entries.push({key:i,value:t})),this.storageService.store(Br.PREF_KEY_CACHE,JSON.stringify(e),0,0),this.storageService.store(Br.PREF_KEY_COUNTER,Br.counter,0,0),Br.hasChanges=!1}static getConfiguredCommandHistoryLength(e){let i=e.getValue().workbench?.commandPalette?.history;return typeof i=="number"?i:Br.DEFAULT_COMMANDS_HISTORY_LENGTH}};qye=Br=vKe([yy(0,Fs),yy(1,Ve),yy(2,Bn)],qye);var XZ=class extends ZZ{constructor(e,t,i,o,r,s){super(e,t,i,o,r,s)}getCodeEditorCommandPicks(){let e=this.activeTextEditorControl;if(!e)return[];let t=[];for(let i of e.getSupportedActions()){let o;i.metadata?.description&&(aOe(i.metadata.description)?o=i.metadata.description:o={original:i.metadata.description,value:i.metadata.description}),t.push({commandId:i.id,commandAlias:i.alias,commandDescription:o,label:QL(i.label)||i.id})}return t}};Fe();Pn();Gi();sc();AL();mt();Si();Jc();var mSt=function(n,e,t,i){var o=arguments.length,r=o<3?e:i===null?i=Object.getOwnPropertyDescriptor(e,t):i,s;if(typeof Reflect=="object"&&typeof Reflect.decorate=="function")r=Reflect.decorate(n,e,t,i);else for(var a=n.length-1;a>=0;a--)(s=n[a])&&(r=(o<3?s(r):o>3?s(e,t,r):s(e,t))||r);return o>3&&r&&Object.defineProperty(e,t,r),r},GD=function(n,e){return function(t,i){e(t,i,n)}},j4=class extends XZ{get activeTextEditorControl(){return this.codeEditorService.getFocusedCodeEditor()??void 0}constructor(e,t,i,o,r,s){super({showAlias:!1},e,i,o,r,s),this.codeEditorService=t}async getCommandPicks(){return this.getCodeEditorCommandPicks()}hasAdditionalCommandPicks(){return!1}async getAdditionalCommandPicks(){return[]}};j4=mSt([GD(0,he),GD(1,xt),GD(2,_t),GD(3,$t),GD(4,Fn),GD(5,Um)],j4);var QZ=class n extends fe{static{this.ID="editor.action.quickCommand"}constructor(){super({id:n.ID,label:DM.quickCommandActionLabel,alias:"Command Palette",precondition:void 0,kbOpts:{kbExpr:T.focus,primary:59,weight:100},contextMenuOpts:{group:"z_commands",order:1}})}run(e){e.get(Pr).quickAccess.show(j4.PREFIX)}};ee(QZ);ei.as(Fh.Quickaccess).registerQuickAccessProvider({ctor:j4,prefix:j4.PREFIX,helpEntries:[{description:DM.quickCommandHelp,commandId:QZ.ID}]});mt();Po();en();it();Fe();ea();kp();var gSt=function(n,e,t,i){var o=arguments.length,r=o<3?e:i===null?i=Object.getOwnPropertyDescriptor(e,t):i,s;if(typeof Reflect=="object"&&typeof Reflect.decorate=="function")r=Reflect.decorate(n,e,t,i);else for(var a=n.length-1;a>=0;a--)(s=n[a])&&(r=(o<3?s(r):o>3?s(e,t,r):s(e,t))||r);return o>3&&r&&Object.defineProperty(e,t,r),r},YD=function(n,e){return function(t,i){e(t,i,n)}},Kye=class extends rv{constructor(e,t,i,o,r,s,a){super(!0,e,t,i,o,r,s,a)}};Kye=gSt([YD(1,Le),YD(2,xt),YD(3,Di),YD(4,he),YD(5,Fs),YD(6,Ve)],Kye);ze(rv.ID,Kye,4);mt();QC();og();wf();qde();var Gye=class extends fe{constructor(){super({id:"editor.action.toggleHighContrast",label:H7.toggleHighContrast,alias:"Toggle High Contrast Theme",precondition:void 0}),this._originalThemeName=null}run(e,t){let i=e.get(La),o=i.getColorTheme();nl(o.type)?(i.setTheme(this._originalThemeName||(Vm(o.type)?XC:Mg)),this._originalThemeName=null):(i.setTheme(Vm(o.type)?Sw:kw),this._originalThemeName=o.themeName)}};ee(Gye);Ir();var ZD={diffEditorWrapper:"yr",diffEditorContainer:"z",truncationGradient:"zr",clickOverlay:"bo",expandButton:"uo"};var Jp=Ue(Xe(),1),wKe=(0,Jp.createContext)(void 0);function yKe({children:n}){let[e,t]=(0,Jp.useState)({isOpen:!1,original:"",modified:""}),i=(0,Jp.useCallback)(r=>{t({isOpen:!0,...r})},[]),o=(0,Jp.useCallback)(()=>{t(r=>({...r,isOpen:!1}))},[]);return Jp.default.createElement(wKe.Provider,{value:{modalState:e,openModal:i,closeModal:o}},n)}function JZ(){let n=(0,Jp.useContext)(wKe);if(n===void 0)throw new Error("useModalDiff must be used within a ModalDiffProvider");return n}function CKe({original:n,modified:e,language:t="plaintext",filePath:i}){let o=(0,Ul.useRef)(null),r=(0,Ul.useRef)(null),s=(0,Ul.useRef)({original:null,modified:null}),[a,l]=(0,Ul.useState)(!1),[c,d]=(0,Ul.useState)(!1),[u,h]=(0,Ul.useState)(!1),{openModal:f}=JZ(),p=()=>{let _=n.split(` `).length,b=e.split(` `).length,v=a?_+b:Math.max(_,b),x=19,w=a?60:20,y=0,C=200,L=v*x+w,E=L>C;return d(E),Math.min(C,Math.max(y,L))};(0,Ul.useEffect)(()=>{if(!o.current)return;let _=rd.createDiffEditor(o.current,{readOnly:!0,renderSideBySide:!0,renderOverviewRuler:!1,scrollBeyondLastLine:!1,minimap:{enabled:!1},automaticLayout:!0,theme:"vs-dark",fontSize:12,lineNumbers:"off",lightbulb:{enabled:rd.ShowLightbulbIconMode.Off},wordWrap:"on",wrappingIndent:"same",scrollbar:{vertical:"hidden",horizontal:"hidden",verticalScrollbarSize:0,handleMouseWheel:!1}});r.current=_;let b=new ResizeObserver(v=>{for(let x of v){let y=x.contentRect.width>700;l(!y),_.updateOptions({renderSideBySide:y})}});return b.observe(o.current),()=>{b.disconnect(),_.dispose(),s.current.original&&s.current.original.dispose(),s.current.modified&&s.current.modified.dispose(),s.current={original:null,modified:null}}},[]),(0,Ul.useEffect)(()=>{if(o.current){let _=p();o.current.style.height=`${_}px`}},[n,e,a]),(0,Ul.useEffect)(()=>{if(!r.current)return;let _=t;if(i&&t==="plaintext"){let b=rd.createModel("",void 0,AP.file(i));_=b.getLanguageId(),b.dispose()}s.current.original?(s.current.original.setValue(n),rd.setModelLanguage(s.current.original,_)):s.current.original=rd.createModel(n,_),s.current.modified?(s.current.modified.setValue(e),rd.setModelLanguage(s.current.modified,_)):s.current.modified=rd.createModel(e,_),r.current.setModel({original:s.current.original,modified:s.current.modified})},[n,e,t,i]);let g=()=>{f({original:n,modified:e,language:t,filePath:i})};return Ul.default.createElement("div",{className:ZD.diffEditorWrapper,onMouseEnter:()=>h(!0),onMouseLeave:()=>h(!1)},Ul.default.createElement("div",{ref:o,className:ZD.diffEditorContainer}),c&&Ul.default.createElement("div",{className:ZD.truncationGradient}),Ul.default.createElement("div",{className:ZD.clickOverlay,onClick:g},u&&Ul.default.createElement("div",{className:ZD.expandButton},"Click to expand")))}var SKe={toolBodyWrapper:"ho"};var Cy=class n extends Qv{static toolName="Edit";name=n.toolName;body(e,t,i){let r=i&&i.is_error?"Edit failed":vSt(t.old_string||"",t.new_string||""),s=q4(i);return ju.default.createElement(ju.default.Fragment,null,ju.default.createElement($s,null,r),s&&ju.default.createElement($s,null,s),ju.default.createElement("div",{className:`${ht.toolBody} ${SKe.toolBodyWrapper}`},ju.default.createElement(CKe,{original:t.old_string||"",modified:t.new_string||"",filePath:t.file_path||""})))}permissionRequest(e,t){let i=t.file_path.split("/").pop();return ju.default.createElement(ju.default.Fragment,null,ju.default.createElement("div",{className:bi.permissionRequestHeader},"Make this edit to"," ",ju.default.createElement("span",{className:bi.permissionPath},i),"?"))}};function vSt(n,e){let t=n.split(` `).length,i=e.split(` `).length,o=Math.max(0,i-t),r=Math.max(0,t-i);return o>0&&r>0?`Added ${o} line${o!==1?"s":""}, removed ${r} line${r!==1?"s":""}`:o>0?`Added ${o} line${o!==1?"s":""}`:r>0?`Removed ${r} line${r!==1?"s":""}`:"Modified"}function q4(n){if(!n||!n.is_error||typeof n.content!="string")return;let e=n.content;if(e.includes("")||e===Yye||!e.startsWith(eX))return;let t=e.replace(eX,"");return ju.default.createElement(ju.default.Fragment,null,ju.default.createElement("b",null,"Reason: ")," ",t)}var tX=class extends Dn{name="Bash";header(e){return cl.default.createElement("div",null,cl.default.createElement("span",{className:ht.toolNameText},"Bash"))}body(e,t,i){let o=this.toolDescription(t),r=q4(i),s=this.renderInput(e,t),a=r?void 0:this.renderOutput(e,i);return cl.default.createElement(cl.default.Fragment,null,o&&cl.default.createElement($s,null,o),r&&cl.default.createElement($s,null,r),cl.default.createElement("div",{className:ht.toolBody},cl.default.createElement("div",{className:ht.toolBodyGrid},s,a)))}renderInput(e,t){let i=()=>{e.fileOpener.openContent(t.command||"","command",!1)};return cl.default.createElement("div",{className:ht.toolBodyRow},cl.default.createElement("div",{className:ht.toolBodyRowLabel},"IN"),cl.default.createElement("div",{className:ht.toolBodyRowContent,onClick:i,style:{cursor:"pointer"}},cl.default.createElement("pre",null,t.command)))}toolDescription(e){return e.description}permissionRequest(e,t,i){return xSt(t,i)}};function xSt(n,e){let t=cl.default.useRef(null),i=()=>{if(t.current){let o=t.current.textContent||"";e({...n,command:o})}};return cl.default.createElement(cl.default.Fragment,null,cl.default.createElement("div",{className:bi.permissionRequestHeader},"Allow this bash command?"),cl.default.createElement("div",{className:`${bi.permissionRequestInput} ${MEe.bashCommand}`,contentEditable:!0,onInput:i,spellCheck:!1,ref:t},n.command),n.description&&cl.default.createElement("div",{className:bi.permissionRequestDescription},n.description))}var iX=Ue(Xe(),1);var nX=class extends Dn{name="BashOutput";header(e,t){return iX.default.createElement("div",null,iX.default.createElement("span",{className:ht.toolNameText},this.name)," ",t.filter&&iX.default.createElement("span",{className:ht.toolNameTextSecondary},'filter: "',t.filter,'"'))}renderInput(){return null}};var Sy=Ue(Xe(),1);var oX=class extends Dn{name="Task";header(e,t){return Sy.default.createElement("div",null,Sy.default.createElement("span",{className:ht.toolNameText},"Task:"),Sy.default.createElement("span",{className:ht.toolNameTextSecondary},t.description))}renderInput(e,t){if(!t.prompt)return null;let i=()=>{e.fileOpener.openContent(t.prompt,`${this.name} tool input`,!1)};return Sy.default.createElement("div",{className:ht.toolBodyRow},Sy.default.createElement("div",{className:ht.toolBodyRowLabel},"IN"),Sy.default.createElement("div",{className:ht.toolBodyRowContent,onClick:i,style:{cursor:"pointer"}},Sy.default.createElement("pre",null,t.prompt)))}renderOutput(){return null}};var sX=Ue(Xe(),1);var em=Ue(Xe(),1);var wS={todoListContainer:"Br",todoList:"qr",todoItem:"Fr",completed:"xo",content:"fo",checkbox:"B"};function ySt({status:n}){let e=(0,em.useRef)(null);return(0,em.useEffect)(()=>{e.current&&(n==="completed"?(e.current.checked=!0,e.current.indeterminate=!1):n==="in_progress"?(e.current.checked=!1,e.current.indeterminate=!0):(e.current.checked=!1,e.current.indeterminate=!1))},[n]),em.default.createElement("input",{ref:e,type:"checkbox",className:wS.checkbox,disabled:!0})}function rX({todos:n}){return nf(),!n||n.length===0?null:em.default.createElement("div",{className:wS.todoListContainer},em.default.createElement("ul",{className:wS.todoList},n.map((e,t)=>em.default.createElement("li",{key:t,className:`${wS.todoItem} ${e.status==="completed"?wS.completed:""}`},em.default.createElement(ySt,{status:e.status}),em.default.createElement("div",{className:wS.content},e.content)))))}var aX=class extends Dn{name="TodoRead";header(e,t){return sX.default.createElement("div",null,sX.default.createElement("span",{className:ht.toolNameText},"Read Todos"))}body(e,t,i){if(i&&i.type==="tool_result"&&typeof i.content=="string")try{let o=JSON.parse(i.content);if(o.todos&&Array.isArray(o.todos))return sX.default.createElement(rX,{todos:o.todos})}catch{}return super.body(e,t,i)}};var lX=Ue(Xe(),1);var cX=class extends Dn{name="TodoWrite";header(e){return lX.default.createElement("div",null,lX.default.createElement("span",{className:ht.toolNameText},"Update Todos"))}body(e,t,i){return t&&t.todos&&Array.isArray(t.todos)?lX.default.createElement(rX,{todos:t.todos}):super.body(e,t,i)}};var qu=Ue(Xe(),1);var dX=class extends Qv{name="Read";header(e,t){let i=t.file_path?.split("/").pop();if(i){let o=s=>{s.stopPropagation(),s.preventDefault();let a=t.offset?t.offset+1:1;this.opener.open(t.file_path,{startLine:a})},r="";return t.offset!==void 0&&t.limit!==void 0?r=` (lines ${t.offset+1}-${t.offset+t.limit})`:t.offset!==void 0&&t.limit===void 0&&(r=` (from line ${t.offset+1})`),qu.default.createElement(qu.default.Fragment,null,qu.default.createElement("span",{className:ht.toolNameText},"Read "),qu.default.createElement("span",{className:ht.toolNameTextSecondary},qu.default.createElement("a",{href:"#",onClick:o},i)),r&&qu.default.createElement("span",null,r))}return qu.default.createElement(qu.default.Fragment,null,qu.default.createElement("span",{className:ht.toolNameText},"Read"))}body(e,t,i){return null}permissionRequest(e,t){let i=(t.file_path||"").split("/").pop();return qu.default.createElement(qu.default.Fragment,null,qu.default.createElement("div",{className:bi.permissionRequestHeader},"Allow reading from"," ",qu.default.createElement("span",{className:bi.permissionPath},i),"?"))}};var jf=Ue(Xe(),1);var kKe={toolBodyWrapper:"vo"};var ky=class n extends Qv{static toolName="Write";name=n.toolName;body(e,t,i){let o=i&&i.is_error,r=typeof t.content=="string"?t.content:JSON.stringify(t.content,null,2),s=q4(i);return jf.default.createElement(jf.default.Fragment,null,jf.default.createElement($s,null,SSt(t,o)),s&&jf.default.createElement($s,null,s),jf.default.createElement("div",{className:`${ht.toolBody} ${kKe.toolBodyWrapper}`},jf.default.createElement("div",{className:ht.toolBodyRowContent},jf.default.createElement("pre",null,r))))}permissionRequest(e,t){let i=(t.file_path||"").split("/").pop();return jf.default.createElement(jf.default.Fragment,null,jf.default.createElement("div",{className:bi.permissionRequestHeader},"Allow write to"," ",jf.default.createElement("span",{className:bi.permissionPath},i),"?"))}};function SSt(n,e){if(e)return"Write failed";if(typeof n.content!="string")return"Write succeeded";let t=n.content.split(` `).length;return`${t} line${t!==1?"s":""}`}var tm=Ue(Xe(),1);var uX=class extends Dn{name="Glob";header(e,t){return tm.default.createElement("div",null,tm.default.createElement("span",{className:ht.toolNameText},"Glob"),tm.default.createElement("span",{className:ht.toolNameTextSecondary},'pattern: "',t.pattern,'"'))}permissionRequest(e,t){return tm.default.createElement(tm.default.Fragment,null,tm.default.createElement("div",{className:bi.permissionRequestHeader},t.path?tm.default.createElement(tm.default.Fragment,null,"Allow glob search in"," ",tm.default.createElement("span",{className:bi.permissionPath},t.path),"?"):"Allow this glob command"))}body(e,t,i){if(!i)return null;let o=this.toOutputContent(i),r=o?.trim(),a=(r&&r!=="No files found"?r.split(` `).filter(c=>c.length>0):[]).length;return tm.default.createElement($s,{onClick:o?()=>{e.fileOpener.openContent(o,"Glob output",!1)}:void 0},a===0?"No files found":a===1?"Found 1 file":`Found ${a} files`)}};var im=Ue(Xe(),1);var hX=class extends Dn{name="Grep";header(e,t){let i=[];return t.path&&i.push(`in ${t.path}`),t.glob&&i.push(`glob: ${t.glob}`),t.type&&i.push(`type: ${t.type}`),im.default.createElement("div",null,im.default.createElement("span",{className:ht.toolNameText},"Grep")," ",im.default.createElement("span",{className:ht.toolNameTextSecondary},'"',t.pattern,'"',i.length>0&&` (${i.join(", ")})`))}permissionRequest(e,t){return im.default.createElement(im.default.Fragment,null,im.default.createElement("div",{className:bi.permissionRequestHeader},t.path?im.default.createElement(im.default.Fragment,null,"Allow grep in"," ",im.default.createElement("span",{className:bi.permissionPath},t.path),"?"):"Allow this grep command"))}body(e,t,i){if(!i)return null;let o=this.toOutputContent(i),s=(o?o.trim().split(` `).filter(l=>l.length>0):[]).length;return im.default.createElement($s,{onClick:o?()=>{e.fileOpener.openContent(o,"Grep output",!1)}:void 0},s===0?"No matches found":s===1?"1 line of output":`${s} lines of output`)}};var a_=Ue(Xe(),1);var fX=class extends Dn{name="Search";header(e,t){return a_.default.createElement("div",null,a_.default.createElement("span",{className:ht.toolNameText},"Search")," ",a_.default.createElement("span",{className:ht.toolNameTextSecondary},'pattern: "',t.pattern,'"'))}permissionRequest(e,t){return a_.default.createElement(a_.default.Fragment,null,a_.default.createElement("div",{className:bi.permissionRequestHeader},t.path?a_.default.createElement(a_.default.Fragment,null,"Allow searching in"," ",a_.default.createElement("span",{className:bi.permissionPath},t.path),"?"):"Allow this search"))}};var pX=class extends Dn{name;constructor(e){super(),this.name=e}};var qf=Ue(Xe(),1);var mX=class extends Dn{name="WebFetch";header(e,t){return qf.default.createElement("div",null,qf.default.createElement("span",{className:ht.toolNameText},"Web Fetch"),qf.default.createElement("span",{className:ht.toolNameTextSecondary},t.url))}body(e,t,i){if(i&&typeof i.content=="string")try{if(i.is_error){let o=i.content||"Unknown error",r=i.content?()=>{e.fileOpener.openContent(o,"Fetch output",!1)}:void 0;return qf.default.createElement("div",{className:ht.toolBody},qf.default.createElement("div",{className:ht.toolBodyPlainText,onClick:r,style:r?{cursor:"pointer"}:void 0},i.content))}else return qf.default.createElement("div",{className:ht.toolBody},qf.default.createElement("div",{className:ht.toolBodyPlainText},"Fetched from ",t.url))}catch{}return super.body(e,t,i)}permissionRequest(e,t){return qf.default.createElement(qf.default.Fragment,null,qf.default.createElement("div",{className:bi.permissionRequestHeader},"Allow fetching this url?"),qf.default.createElement("div",{className:bi.permissionRequestInput},t.url))}};var l_=Ue(Xe(),1);var gX=class extends Dn{constructor(t){super();this.opener=t}name="ReadCoalesced";header(t,i){return l_.default.createElement(l_.default.Fragment,null,l_.default.createElement("span",{className:ht.toolNameText},"Read "),(i.fileReads||[]).map((o,r)=>{let s=c=>{c.stopPropagation(),c.preventDefault();let d=o.offset?o.offset+1:1;this.opener.open(o.file_path,{startLine:d})},a="";o.offset!==void 0&&o.limit!==void 0?a=` (lines ${o.offset+1}-${o.offset+o.limit})`:o.offset!==void 0&&o.limit===void 0&&(a=` (from line ${o.offset+1})`);let l=o.file_path.split("/").pop()||o.file_path;return l_.default.createElement(l_.default.Fragment,{key:r},r>0&&l_.default.createElement("span",null,", "),l_.default.createElement("span",{className:ht.toolNameTextSecondary},l_.default.createElement("a",{href:"#",onClick:s},l)),a&&l_.default.createElement("span",null," ",a))}))}body(t,i,o){return null}};var nm=Ue(Xe(),1);var Ly=class n extends Dn{static toolName="ExitPlanMode";name=n.toolName;header(e,t){let i=t?.plan?"Claude\u2019s Plan":"Plan Mode";return nm.default.createElement("span",{className:ht.toolNameText},i)}body(e,t,i){let o=i&&!i.is_error,r=i?o?"User approved the plan":"Stayed in plan mode":void 0;return nm.default.createElement(nm.default.Fragment,null,nm.default.createElement("div",null,nm.default.createElement(xm,{content:t.plan||"",context:e})),r&&nm.default.createElement($s,{hideBracket:!0},r))}permissionRequest(e,t){return nm.default.createElement(nm.default.Fragment,null,nm.default.createElement("div",{className:bi.permissionRequestHeader},"Accept this plan?"),nm.default.createElement("div",{className:bi.permissionRequestDescription},"Review the plan above and decide whether to proceed"))}};var hd=Ue(Xe(),1);var _X=class n extends Dn{constructor(t){super();this.opener=t}static toolName="NotebookEdit";name=n.toolName;header(t,i){let o=i.notebook_path?.split("/").pop();if(o){let r=s=>{s.stopPropagation(),s.preventDefault(),this.opener.open(i.notebook_path)};return hd.default.createElement(hd.default.Fragment,null,hd.default.createElement("span",{className:ht.toolNameText},"Edit Notebook Cell "),hd.default.createElement("span",{className:ht.toolNameTextSecondary},hd.default.createElement("a",{href:"#",onClick:r},o,i.cell_id&&hd.default.createElement("span",null,":"+i.cell_id))))}return hd.default.createElement(hd.default.Fragment,null,hd.default.createElement("span",{className:ht.toolNameText},"Edit Notebook Cell"))}body(t,i,o){let r=o?o.is_error?"Failed":"Success":"Pending",s=i?.new_source??"[No content]";return hd.default.createElement(hd.default.Fragment,null,hd.default.createElement($s,null,r),hd.default.createElement("div",{className:`${ht.toolBody}`},hd.default.createElement("div",{className:`${ht.toolBodyRowContent} ${ht.toolBodyRowContent_disableClipping}`},hd.default.createElement("pre",null,s))))}};var mv=Ue(Xe(),1);var bX=class extends Dn{name="SlashCommand";header(e,t){let i=t.command?.split(" ")[0]||"";return mv.default.createElement(mv.default.Fragment,null,mv.default.createElement("span",{className:ht.toolNameText},i),mv.default.createElement("span",{className:ht.toolNameTextSecondary}," slash command"))}body(e,t,i){return null}permissionRequest(e,t,i){let o=(t.command||"").split(" ")[0]||"";return mv.default.createElement(mv.default.Fragment,null,mv.default.createElement("div",{className:bi.permissionRequestHeader},"Let Claude run the"," ",mv.default.createElement("span",{className:bi.permissionPath},o)," slash command?"))}};var _i=Ue(Xe(),1);var pn={questionsSummary:"Hr",questionItem:"Wr",questionText:"Ir",answerText:"Sr",navigationBar:"Lr",navTab:"wo",navTabAnswered:"jr",navTabActive:"Er",navTabLabel:"Mr",questionsContainer:"Tr",questionBlock:"Cr",questionHeader:"Ar",questionTextLarge:"Rr",optionsContainer:"Vr",selectionConfirm:"ko",option:"O",optionConfirming:"Dr",optionCheckbox:"Gr",checkbox:"Or",checkboxChecked:"Pr",radio:"Xr",radioChecked:"Yr",radioDot:"Ur",optionContent:"Nr",optionLabel:"Kr",optionDescription:"Jr",otherInput:"P"};var Zye="AskUserQuestion",vX=class extends Dn{name=Zye;header(e){return _i.default.createElement("div",null,_i.default.createElement("span",{className:ht.toolNameText},"Ask Question"))}body(e,t,i){let o=this.renderInput(e,t),r=this.renderOutput(e,i);return _i.default.createElement("div",{className:ht.toolBody},_i.default.createElement("div",{className:ht.toolBodyGrid},o,r))}renderInput(e,t){return t.questions?_i.default.createElement("div",{className:ht.toolBodyRow},_i.default.createElement("div",{className:ht.toolBodyRowLabel},"IN"),_i.default.createElement("div",{className:ht.toolBodyRowContent},_i.default.createElement("div",{className:pn.questionsSummary},t.questions.map((i,o)=>_i.default.createElement("div",{key:o,className:pn.questionItem},_i.default.createElement("div",{className:pn.questionText},i.question),t.answers&&t.answers[i.question]&&_i.default.createElement("div",{className:pn.answerText},"\u2192 ",t.answers[i.question])))))):null}permissionRequest(e,t,i){return LSt(t,i)}};function LSt(n,e){let[t,i]=_i.default.useState(0),[o,r]=_i.default.useState(()=>{let x={};if(n.answers&&n.questions)for(let w of n.questions){let y=n.answers[w.question];y?x[w.question]=new Set(y.split(", ")):x[w.question]=new Set}else if(n.questions)for(let w of n.questions)x[w.question]=new Set;return x}),[s,a]=_i.default.useState({}),l=_i.default.useRef({}),[c,d]=_i.default.useState(!1),[u,h]=_i.default.useState(null),f=_i.default.useRef(null);_i.default.useEffect(()=>{let x=f.current;if(!x)return;x.querySelector('[role="radio"], [role="checkbox"]')?.focus()},[t]);let p=x=>{if(!c&&n.questions){if(x.key==="ArrowLeft"&&t>0)i(w=>w-1),x.stopPropagation();else if(x.key==="ArrowRight"&&tw+1),x.stopPropagation();else if(x.key==="ArrowUp"||x.key==="ArrowDown"){let w=f.current;if(!w)return;let y=Array.from(w.querySelectorAll('[role="radio"], [role="checkbox"]'));if(y.length===0)return;let C=y.findIndex(E=>E===document.activeElement),L;x.key==="ArrowUp"?L=C<=0?y.length-1:C-1:L=C>=y.length-1?0:C+1,y[L]?.focus(),x.preventDefault(),x.stopPropagation()}}};_i.default.useEffect(()=>{if(!n.questions)return;let x={};for(let w of n.questions){let y=o[w.question];if(y&&y.size>0){let C=Array.from(y);if(C.includes("Other")&&s[w.question]){let L=s[w.question],E=C.filter(N=>N!=="Other");E.push(L),x[w.question]=E.join(", ")}else x[w.question]=C.join(", ")}}e({questions:n.questions,answers:x})},[o,s,n.questions,e]);let g=(x,w)=>{let y=n.questions?.find(C=>C.question===x);y&&r(C=>{let L={...C},E=new Set(C[x]||[]);return y.multiSelect?E.has(w)?E.delete(w):(E.add(w),w==="Other"&&setTimeout(()=>{l.current[x]?.focus()},0)):(E.clear(),E.add(w),w==="Other"?setTimeout(()=>{l.current[x]?.focus()},0):(h(w),setTimeout(()=>{h(null),n.questions&&tN+1)},300))),L[x]=E,L})},_=(x,w)=>{a(y=>({...y,[x]:w}))};if(!n.questions)return _i.default.createElement("div",{className:bi.permissionRequestHeader},"No questions provided");let b=n.questions[t];if(!b)return null;let v=x=>o[b.question]?.has(x)||!1;return _i.default.createElement("div",{onKeyDown:p},_i.default.createElement("div",{className:bi.permissionRequestHeader},"Answer Claude's questions:"),_i.default.createElement("div",{className:pn.navigationBar},n.questions.map((x,w)=>{let y=w===t,C=(o[x.question]?.size??0)>0;return _i.default.createElement("button",{key:w,className:`${pn.navTab} ${y?pn.navTabActive:""} ${C?pn.navTabAnswered:""}`,onClick:()=>i(w)},_i.default.createElement("span",{className:pn.navTabLabel},x.header))})),_i.default.createElement("div",{className:pn.questionsContainer},_i.default.createElement("div",{key:t,className:pn.questionBlock},_i.default.createElement("div",{className:pn.questionHeader},_i.default.createElement("span",{className:pn.questionTextLarge},b.question)),_i.default.createElement("div",{className:pn.optionsContainer,ref:f},b.options.map((x,w)=>_i.default.createElement("div",{key:w,className:`${pn.option} ${v(x.label)?pn.optionSelected:""} ${u===x.label?pn.optionConfirming:""}`,tabIndex:0,role:b.multiSelect?"checkbox":"radio","aria-checked":v(x.label),onClick:()=>g(b.question,x.label),onKeyDown:y=>{(y.key==="Enter"||y.key===" ")&&(y.preventDefault(),g(b.question,x.label))}},_i.default.createElement("div",{className:pn.optionCheckbox},b.multiSelect?_i.default.createElement("div",{className:`${pn.checkbox} ${v(x.label)?pn.checkboxChecked:""}`},v(x.label)&&_i.default.createElement("svg",{width:"12",height:"12",viewBox:"0 0 12 12",fill:"none"},_i.default.createElement("path",{d:"M2 6L5 9L10 3",stroke:"currentColor",strokeWidth:"2",strokeLinecap:"round",strokeLinejoin:"round"}))):_i.default.createElement("div",{className:`${pn.radio} ${v(x.label)?pn.radioChecked:""}`},v(x.label)&&_i.default.createElement("div",{className:pn.radioDot}))),_i.default.createElement("div",{className:pn.optionContent},_i.default.createElement("div",{className:pn.optionLabel},x.label),x.description&&_i.default.createElement("div",{className:pn.optionDescription},x.description)))),_i.default.createElement("div",{className:`${pn.option} ${v("Other")?pn.optionSelected:""} ${u==="Other"?pn.optionConfirming:""}`,tabIndex:0,role:b.multiSelect?"checkbox":"radio","aria-checked":v("Other"),onClick:()=>g(b.question,"Other"),onKeyDown:x=>{(x.key==="Enter"||x.key===" ")&&(x.preventDefault(),g(b.question,"Other"))}},_i.default.createElement("div",{className:pn.optionCheckbox},b.multiSelect?_i.default.createElement("div",{className:`${pn.checkbox} ${v("Other")?pn.checkboxChecked:""}`},v("Other")&&_i.default.createElement("svg",{width:"12",height:"12",viewBox:"0 0 12 12",fill:"none"},_i.default.createElement("path",{d:"M2 6L5 9L10 3",stroke:"currentColor",strokeWidth:"2",strokeLinecap:"round",strokeLinejoin:"round"}))):_i.default.createElement("div",{className:`${pn.radio} ${v("Other")?pn.radioChecked:""}`},v("Other")&&_i.default.createElement("div",{className:pn.radioDot}))),_i.default.createElement("div",{className:pn.optionContent},_i.default.createElement("div",{className:pn.optionLabel},"Other"),v("Other")&&_i.default.createElement("input",{ref:x=>{l.current[b.question]=x},type:"text",className:pn.otherInput,placeholder:"Type your answer...",value:s[b.question]||"",onChange:x=>_(b.question,x.target.value),onFocus:()=>d(!0),onBlur:()=>d(!1),onClick:x=>x.stopPropagation()})))))))}function gR(n,e){let i=[new S3,new tX,new nX,new oX,new aX,new cX,new dX(e.fileOpener),new ky(e.fileOpener),new Cy(e.fileOpener),new uX,new hX,new fX,new mX,new Ly,new gX(e.fileOpener),new _X(e.fileOpener),new bX,new vX].find(o=>o.name===n);return i||new pX(n)}var c_=Ue(Xe(),1);var xX={wrapper:"Qr",placeholder:"Zr",input:"_r"};var Xye=c_.default.forwardRef(({value:n,onChange:e,onKeyDown:t,placeholder:i,className:o,autoFocus:r},s)=>{let a=(0,c_.useRef)(null),l=s||a;(0,c_.useEffect)(()=>{l.current&&(l.current.textContent||"")!==n&&(l.current.textContent=n)},[n,l]),(0,c_.useEffect)(()=>{r&&l.current&&l.current.focus()},[r,l]);let c=()=>{if(l.current){let u=l.current.textContent||"";e(u)}},d=!n;return c_.default.createElement("div",{className:`${xX.wrapper} ${o||""}`},d&&c_.default.createElement("div",{className:xX.placeholder},i),c_.default.createElement("div",{ref:l,className:xX.input,contentEditable:"plaintext-only",onInput:c,onKeyDown:t,spellCheck:!1,suppressContentEditableWarning:!0}))});Xye.displayName="ContentEditableInput";var Yye="The user doesn't want to proceed with this tool use. The tool use was rejected (eg. if it was a file edit, the new_string was NOT written to the file). STOP what you are doing and wait for the user to tell you how to proceed.",ESt="User chose to stay in plan mode and continue planning",eX="The user doesn't want to proceed with this tool use. The tool use was rejected (eg. if it was a file edit, the new_string was NOT written to the file). The user provided the following reason for the rejection: ";function IKe({request:n,context:e,onPermissionModeChange:t}){let[i,o]=yn.default.useState(null),[r,s]=yn.default.useState(""),[a,l]=yn.default.useState(!0),[c,d]=yn.default.useState(0),u=yn.default.useRef(null),h=yn.default.useRef(null),f=yn.default.useRef(null),p=yn.default.useRef(null),g=yn.default.useRef(null),_=yn.default.useRef(null),b=n.toolName===Ly.toolName,v=b||n.suggestions&&n.suggestions.length>0,x=n.toolName===Zye,w=yn.default.useMemo(()=>{if(!x)return!0;let z=i||n.inputs;return!z?.questions||!z?.answers?!1:z.questions.every(ae=>{let X=z.answers?.[ae.question];return X&&X.trim().length})},[n.toolName,n.inputs,i]),y=async()=>{b&&await t("acceptEdits",!0),n.accept(i||n.inputs)},C=async()=>{let z=b?[{type:"setMode",mode:"default",destination:"session"}]:n.suggestions,ae=z.find(X=>X.type==="setMode"&&X.destination==="session");ae&&ae.type==="setMode"&&await t(ae.mode,!1),n.accept(i||n.inputs,z)},L=()=>{let z=r.trim(),ae=z?`${eX} ${z}`:b?ESt:Yye;n.reject(ae,!z)},E=(0,yn.useMemo)(()=>{let z=[u];return v&&z.push(h),z.push(f,p),z},[v]),N=z=>{let ae=document.activeElement,X=E.findIndex(B=>B.current===ae),ue=X===-1?0:(X+z+E.length)%E.length,ce=E[ue].current;ce&&(d(ue),e.safeFocus(ce))},M=async z=>{if(g.current?.contains(z.target)&&!x)return;let ae=document.activeElement===p.current,X=[y];v&&X.push(C),X.push(L),X.push(()=>{p.current&&(d(E.length-1),e.safeFocus(p.current))});let ue={};for(let[ce,B]of X.entries())ue[(ce+1).toString()]=B;if(!ae&&!a&&ue[z.key]){if(z.key==="1"&&!w){z.preventDefault();return}z.preventDefault(),ue[z.key]()}else if(z.key==="Escape"&&!a&&!z.metaKey&&!z.ctrlKey)z.preventDefault(),L();else if(z.key==="ArrowDown"){if(ae&&r.includes(` `))return;z.preventDefault(),N(1)}else if(z.key==="ArrowUp"){if(ae&&r.includes(` `))return;z.preventDefault(),N(-1)}},F=async z=>{if(z.key==="Enter"&&!z.shiftKey){if(z.nativeEvent.isComposing)return;z.preventDefault(),L()}else z.key==="Escape"&&!z.metaKey&&!z.ctrlKey&&(z.preventDefault(),L())};yn.default.useEffect(()=>{let z=setTimeout(async()=>{(0,LKe.flushSync)(()=>{l(!1)});let ae=n.toolName===Cy.toolName||n.toolName===ky.toolName;u.current&&document.hasFocus()?(d(0),e.safeFocus(u.current)):_.current&&ae&&e.safeFocus(_.current)},800);return()=>clearTimeout(z)},[n.toolName,e]);let q=z=>{if(z.target===z.currentTarget&&E[c].current){z.currentTarget.blur();let ae=E[c].current;ae&&e.safeFocus(ae)}};yn.default.useEffect(()=>{let z=()=>{let X=document.activeElement,ue=E.findIndex(ce=>ce.current===X);ue!==-1&&d(ue)},ae=_.current;if(ae)return ae.addEventListener("focusin",z),()=>ae.removeEventListener("focusin",z)},[E]);let te="Yes";b?te="Yes, and auto-accept":x&&(te="Submit answers");let $="No";return b?$="No, keep planning":x&&($="Cancel"),yn.default.createElement("div",{ref:_,className:bi.permissionRequestContainer,tabIndex:0,onKeyDown:M,onFocus:q,"data-focused-index":c},yn.default.createElement("div",{className:bi.permissionRequestContainerBackground}),yn.default.createElement("div",{className:bi.permissionRequestContent,ref:g},TSt(e,n,o)),yn.default.createElement("div",{className:bi.buttonContainer},yn.default.createElement("button",{ref:u,className:`${bi.button} ${bi.primary}`,onClick:y,disabled:a||!w},yn.default.createElement("span",{className:bi.shortcutNum},"1")," ",te),v&&yn.default.createElement("button",{ref:h,className:`${bi.button}`,onClick:C,disabled:a},yn.default.createElement("span",{className:bi.shortcutNum},"2")," ",b?"Yes, and manually approve edits":"Yes, and don't ask again"),yn.default.createElement("button",{ref:f,className:`${bi.button}`,onClick:L,disabled:a},yn.default.createElement("span",{className:bi.shortcutNum},v?"3":"2")," ",$),yn.default.createElement(Xye,{ref:p,className:bi.rejectMessageInput,placeholder:"Tell Claude what to do instead",value:r,onChange:s,onKeyDown:F})))}function TSt(n,e,t){let o=gR(e.toolName,n).permissionRequest(n,e.inputs,t);return o||yn.default.createElement(yn.default.Fragment,null,yn.default.createElement("div",{className:bi.permissionRequestHeader},"Do you want to proceed with ",yn.default.createElement("strong",null,e.toolName),"?"),yn.default.createElement("div",{className:bi.permissionRequestDescription},Object.keys(e.inputs).length>0&&yn.default.createElement("details",null,yn.default.createElement("summary",null,yn.default.createElement("span",null,"Details"),yn.default.createElement("svg",{className:bi.chevron,width:"12",height:"12",viewBox:"0 0 12 12",fill:"none",xmlns:"http://www.w3.org/2000/svg"},yn.default.createElement("path",{d:"M3 4.5L6 7.5L9 4.5",stroke:"currentColor",strokeWidth:"1.5",strokeLinecap:"round",strokeLinejoin:"round"}))),yn.default.createElement("pre",{className:bi.inputJson},JSON.stringify(e.inputs,null,2)))))}var d_=Ue(Xe(),1);var yS={container:"oi",header:"ei",title:"ri",spinner:"ii",spin:"yo",output:"q",error:"ni"};function EKe({output:n,error:e}){let t=n.join(` `);return d_.default.createElement("div",{className:yS.container},d_.default.createElement("div",{className:yS.header},d_.default.createElement("div",{className:yS.spinner}),d_.default.createElement("div",{className:yS.title},"Authenticating...")),n.length>0&&d_.default.createElement("div",{className:yS.output},d_.default.createElement(xm,{content:t})),e&&d_.default.createElement("div",{className:yS.error},e,d_.default.createElement("br",null),d_.default.createElement(N_,null)))}var on=Ue(Xe(),1);var u_={inputContainer:"u",inputContainerBackground:"ti",messageInputContainer:"zo",selectionLabel:"Bo",hidesWhenNarrow:"ai",messageInput:"d",micButton:"F",recording:"qo",pulse:"Fo",micIcon:"di",micButtonWrapper:"ci",audioPopup:"X",fadeIn:"Ho",audioWaveform:"li",scrim:"si",attachedFilesContainer:"Wo"};var lr=Ue(Xe(),1);var om={menuPopup:"pi",fadeIn:"Io",filterInput:"h",commandList:"gi",sectionDivider:"mi",sectionHeader:"bi",commandItem:"ui",commandContent:"hi",commandLabel:"So",activeCommandItem:"Lo",chevronIcon:"xi",emptyState:"fi"};var TKe=({isOpen:n,onClose:e,onCommandSelect:t,commandRegistry:i,filterText:o,suppressFilter:r=!1})=>{let[s,a]=(0,lr.useState)(""),[l,c]=(0,lr.useState)(null),d=(0,lr.useRef)(null),u=(0,lr.useRef)(null),h=(0,lr.useRef)(null),f=r?o||"":s||"",p=i.getCommandsBySection(),g=Object.entries(p).reduce((x,[w,y])=>{let C=y.filter(L=>L.label.toLowerCase().includes(f.toLowerCase()));return C.length>0&&(x[w]=C),x},{}),_=Object.values(g).flat();(0,lr.useEffect)(()=>{n&&(!r&&d.current&&d.current.focus(),c(null),o===void 0&&a(""))},[n,r,o]),(0,lr.useEffect)(()=>{f&&(_.length>0?l&&_.some(w=>w.id===l)||c(_[0].id):c(null))},[_,l,f]),(0,lr.useEffect)(()=>{f===""&&c(null)},[f]);let b=(0,lr.useCallback)(x=>{if(x.key==="Escape"){x.preventDefault(),e();return}if(x.key==="ArrowDown"&&_.length>0){x.preventDefault();let w=_.findIndex(C=>C.id===l),y=w<_.length-1?w+1:0;c(_[y]?.id||null);return}if(x.key==="ArrowUp"&&_.length>0){x.preventDefault();let w=_.findIndex(C=>C.id===l),y=w>0?w-1:_.length-1;c(_[y]?.id||null);return}if((x.key==="Tab"||x.key==="Enter")&&!x.shiftKey){if("isComposing"in x&&x.isComposing)return;if(x.preventDefault(),l){let w=_.find(y=>y.id===l);if(w){a("");let y=x.key==="Tab";t(w,y)}}return}},[l,_,e,t]);(0,lr.useEffect)(()=>{h.current&&h.current.scrollIntoView({behavior:"instant",block:"nearest"})},[l]);function v(x){["Escape","ArrowDown","ArrowUp","Enter","Tab"].includes(x.key)&&b(x)}return(0,lr.useEffect)(()=>{if(n&&r)return document.addEventListener("keydown",b),()=>{document.removeEventListener("keydown",b)}},[n,r,b]),n?lr.default.createElement("div",{ref:u,className:om.menuPopup},!r&&lr.default.createElement("input",{ref:d,type:"text",value:f,onChange:x=>a(x.target.value),onKeyDown:v,placeholder:"Filter actions...",className:om.filterInput}),r&&lr.default.createElement("div",{style:{height:4}}),lr.default.createElement("div",{className:om.commandList},Object.keys(g).length===0?lr.default.createElement("div",{className:om.emptyState},"No matching commands"):Object.entries(g).map(([x,w],y)=>lr.default.createElement("div",{key:x},y>0&&lr.default.createElement("div",{className:om.sectionDivider}),lr.default.createElement("div",{className:om.sectionHeader},x),w.map(C=>lr.default.createElement("div",{key:C.id,ref:C.id===l?h:null,className:`${om.commandItem} ${C.id===l?om.activeCommandItem:""}`,onMouseEnter:()=>c(C.id),onClick:()=>{a(""),t(C,!1)},title:C.description},lr.default.createElement("div",{className:om.commandContent},lr.default.createElement("span",{className:om.commandLabel},C.label),C.trailingComponent))))))):null};var uo=Ue(Xe(),1);var Ku={menuPopup:"vi",fadeIn:"wi",loading:"ki",fileList:"yi",emptyState:"zi",fileItem:"Bi",activeFileItem:"qi",fileIcon:"jo",fileContent:"Fi",fileName:"Hi",fileDirectory:"Wi",fileDirectoryDirectionReset:"Ii",directoryPath:"Si",directoryPathDirectionReset:"Li"};var DKe=({searchQuery:n,onClose:e,onFileSelect:t,onListFiles:i})=>{let[o,r]=(0,uo.useState)([]),[s,a]=(0,uo.useState)(0),l=(0,uo.useRef)(null),c=(0,uo.useRef)(null);(0,uo.useEffect)(()=>{let u=setTimeout(()=>{i(n).then(h=>{r(h),a(0)}).catch(h=>{})},200);return()=>clearTimeout(u)},[i,n]);let d=(0,uo.useCallback)(u=>{switch(u.key){case"ArrowDown":o.length>1&&(u.preventDefault(),a(h=>h1&&(u.preventDefault(),a(h=>h>0?h-1:o.length-1));break;case"Tab":case"Enter":u.shiftKey||(u.preventDefault(),o[s]&&t(o[s],u.key==="Tab"));break;case"Escape":u.preventDefault(),e();break}},[o,s,t,e]);return(0,uo.useEffect)(()=>{c.current&&c.current.scrollIntoView({behavior:"instant",block:"nearest"})},[s]),(0,uo.useEffect)(()=>(document.addEventListener("keydown",d),()=>document.removeEventListener("keydown",d)),[d]),uo.default.createElement("div",{ref:l,className:Ku.menuPopup},uo.default.createElement("div",{className:Ku.fileList},o.length===0?uo.default.createElement("div",{className:Ku.emptyState},"No files found"):o.map((u,h)=>uo.default.createElement("div",{key:u.path,ref:h===s?c:null,className:`${Ku.fileItem} ${h===s?Ku.activeFileItem:""}`,onMouseEnter:()=>a(h),onClick:()=>t(u,!1)},uo.default.createElement("div",{className:Ku.fileContent},u.type==="file"?uo.default.createElement(uo.default.Fragment,null,uo.default.createElement("div",{className:Ku.fileIcon},uo.default.createElement("svg",{width:"20",height:"20",viewBox:"0 0 20 20",xmlns:"http://www.w3.org/2000/svg"},uo.default.createElement("path",{d:"M11.5859 2C11.9837 2.00004 12.3652 2.15818 12.6465 2.43945L15.5605 5.35352C15.8418 5.63478 16 6.01629 16 6.41406V16.5C16 17.3284 15.3284 18 14.5 18H5.5C4.72334 18 4.08461 17.4097 4.00781 16.6533L4 16.5V3.5C4 2.67157 4.67157 2 5.5 2H11.5859ZM5.5 3C5.22386 3 5 3.22386 5 3.5V16.5C5 16.7761 5.22386 17 5.5 17H14.5C14.7761 17 15 16.7761 15 16.5V7H12.5C11.6716 7 11 6.32843 11 5.5V3H5.5ZM12.54 13.3037C12.6486 13.05 12.9425 12.9317 13.1963 13.04C13.45 13.1486 13.5683 13.4425 13.46 13.6963C13.1651 14.3853 12.589 15 11.7998 15C11.3132 14.9999 10.908 14.7663 10.5996 14.4258C10.2913 14.7661 9.88667 14.9999 9.40039 15C8.91365 15 8.50769 14.7665 8.19922 14.4258C7.89083 14.7661 7.48636 15 7 15C6.72386 15 6.5 14.7761 6.5 14.5C6.5 14.2239 6.72386 14 7 14C7.21245 14 7.51918 13.8199 7.74023 13.3037L7.77441 13.2373C7.86451 13.0913 8.02513 13 8.2002 13C8.40022 13.0001 8.58145 13.1198 8.66016 13.3037C8.88121 13.8198 9.18796 14 9.40039 14C9.61284 13.9998 9.9197 13.8197 10.1406 13.3037L10.1748 13.2373C10.2649 13.0915 10.4248 13.0001 10.5996 13C10.7997 13 10.9808 13.1198 11.0596 13.3037C11.2806 13.8198 11.5874 13.9999 11.7998 14C12.0122 14 12.319 13.8198 12.54 13.3037ZM12.54 9.30371C12.6486 9.05001 12.9425 8.93174 13.1963 9.04004C13.45 9.14863 13.5683 9.44253 13.46 9.69629C13.1651 10.3853 12.589 11 11.7998 11C11.3132 10.9999 10.908 10.7663 10.5996 10.4258C10.2913 10.7661 9.88667 10.9999 9.40039 11C8.91365 11 8.50769 10.7665 8.19922 10.4258C7.89083 10.7661 7.48636 11 7 11C6.72386 11 6.5 10.7761 6.5 10.5C6.5 10.2239 6.72386 10 7 10C7.21245 10 7.51918 9.8199 7.74023 9.30371L7.77441 9.2373C7.86451 9.09126 8.02513 9 8.2002 9C8.40022 9.00008 8.58145 9.11981 8.66016 9.30371C8.88121 9.8198 9.18796 10 9.40039 10C9.61284 9.99978 9.9197 9.81969 10.1406 9.30371L10.1748 9.2373C10.2649 9.09147 10.4248 9.00014 10.5996 9C10.7997 9 10.9808 9.11975 11.0596 9.30371C11.2806 9.8198 11.5874 9.99989 11.7998 10C12.0122 10 12.319 9.81985 12.54 9.30371ZM12 5.5C12 5.77614 12.2239 6 12.5 6H14.793L12 3.20703V5.5Z"}))),uo.default.createElement("div",{className:Ku.fileName},u.name),u.path.length>u.name.length&&uo.default.createElement("div",{className:Ku.fileDirectory},uo.default.createElement("span",{className:Ku.fileDirectoryDirectionReset},u.path.substring(0,u.path.length-u.name.length)))):uo.default.createElement(uo.default.Fragment,null,uo.default.createElement("div",{className:Ku.fileIcon},uo.default.createElement("svg",{width:"20",height:"20",viewBox:"0 0 20 20",xmlns:"http://www.w3.org/2000/svg"},uo.default.createElement("path",{d:"M16.5 3C17.3284 3 18 3.67157 18 4.5V15.5C18 16.3284 17.3284 17 16.5 17H3.5C2.67157 17 2 16.3284 2 15.5V6.5C2 5.67157 2.67157 5 3.5 5H10.793L12.3535 3.43945L12.4639 3.33984C12.7307 3.12123 13.0661 3.00003 13.4141 3H16.5ZM13.4141 4C13.3146 4.00003 13.2182 4.02961 13.1367 4.08398L13.0605 4.14648L11.3535 5.85352C11.2597 5.94728 11.1326 6 11 6H3.5C3.22386 6 3 6.22386 3 6.5V15.5C3 15.7761 3.22386 16 3.5 16H16.5C16.7761 16 17 15.7761 17 15.5V4.5C17 4.22386 16.7761 4 16.5 4H13.4141Z"}))),uo.default.createElement("div",{className:Ku.directoryPath},uo.default.createElement("span",{className:Ku.directoryPathDirectionReset},u.path))))))))};var ho=Ue(Xe(),1);var $l={inputFooter:"ji",spacer:"Ei",footerButton:"l",footerButtonDisabled:"Mi",footerButtonInactive:"Eo",sendButton:"r",menuButton:"H",menuButtonInactivated:"Ti",menuButtonActivated:"W",menuButtonOff:"Ci",sendIcon:"I",stopIcon:"S",menuIcon:"Ai",hidesWhenNarrow:"Ri"};var XD=Ue(Xe(),1);function PSt({title:n,titleId:e,...t},i){return XD.createElement("svg",Object.assign({xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 16 16",fill:"currentColor","aria-hidden":"true","data-slot":"icon",ref:i,"aria-labelledby":e},t),n?XD.createElement("title",{id:e},n):null,XD.createElement("path",{fillRule:"evenodd",d:"M12.78 7.595a.75.75 0 0 1 0 1.06l-3.25 3.25a.75.75 0 0 1-1.06-1.06l2.72-2.72-2.72-2.72a.75.75 0 0 1 1.06-1.06l3.25 3.25Zm-8.25-3.25 3.25 3.25a.75.75 0 0 1 0 1.06l-3.25 3.25a.75.75 0 0 1-1.06-1.06l2.72-2.72-2.72-2.72a.75.75 0 0 1 1.06-1.06Z",clipRule:"evenodd"}))}var OSt=XD.forwardRef(PSt),Qye=OSt;var QD=Ue(Xe(),1);function FSt({title:n,titleId:e,...t},i){return QD.createElement("svg",Object.assign({xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 16 16",fill:"currentColor","aria-hidden":"true","data-slot":"icon",ref:i,"aria-labelledby":e},t),n?QD.createElement("title",{id:e},n):null,QD.createElement("path",{d:"M2.53 3.956A1 1 0 0 0 1 4.804v6.392a1 1 0 0 0 1.53.848l5.113-3.196c.16-.1.279-.233.357-.383v2.73a1 1 0 0 0 1.53.849l5.113-3.196a1 1 0 0 0 0-1.696L9.53 3.956A1 1 0 0 0 8 4.804v2.731a.992.992 0 0 0-.357-.383L2.53 3.956Z"}))}var BSt=QD.forwardRef(FSt),Jye=BSt;var JD=Ue(Xe(),1);function WSt({title:n,titleId:e,...t},i){return JD.createElement("svg",Object.assign({xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 16 16",fill:"currentColor","aria-hidden":"true","data-slot":"icon",ref:i,"aria-labelledby":e},t),n?JD.createElement("title",{id:e},n):null,JD.createElement("path",{d:"M4.5 2a.5.5 0 0 0-.5.5v11a.5.5 0 0 0 .5.5h1a.5.5 0 0 0 .5-.5v-11a.5.5 0 0 0-.5-.5h-1ZM10.5 2a.5.5 0 0 0-.5.5v11a.5.5 0 0 0 .5.5h1a.5.5 0 0 0 .5-.5v-11a.5.5 0 0 0-.5-.5h-1Z"}))}var HSt=JD.forwardRef(WSt),e1e=HSt;var eN=Ue(Xe(),1);function zSt({title:n,titleId:e,...t},i){return eN.createElement("svg",Object.assign({xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 16 16",fill:"currentColor","aria-hidden":"true","data-slot":"icon",ref:i,"aria-labelledby":e},t),n?eN.createElement("title",{id:e},n):null,eN.createElement("path",{fillRule:"evenodd",d:"M11.013 2.513a1.75 1.75 0 0 1 2.475 2.474L6.226 12.25a2.751 2.751 0 0 1-.892.596l-2.047.848a.75.75 0 0 1-.98-.98l.848-2.047a2.75 2.75 0 0 1 .596-.892l7.262-7.261Z",clipRule:"evenodd"}))}var VSt=eN.forwardRef(zSt),t1e=VSt;var Cc=Ue(Xe(),1);var gv={usageContainer:"Vi",usage:"Mo",pie:"Di",value:"Gi",popup:"Oi",popupContent:"Pi",remainingText:"Xi",compactHint:"Yi"};function NKe({usedTokens:n,contextWindow:e,onCompact:t}){let[i,o]=(0,Cc.useState)(!1),r=(0,Cc.useRef)(null);(0,Cc.useEffect)(()=>{if(i&&r.current){let b=r.current,v=b.getBoundingClientRect();v.left<0?(b.style.left="0",b.style.right="auto"):v.right>window.innerWidth&&(b.style.left="auto",b.style.right="0")}},[i]);let s=e>0?Math.min(n/e*100,100):0,a=100-s,l=12,c=l/2,d=l/2,u=s/100*360,h=(u-90)*(Math.PI/180),f=c+d*Math.cos(h),p=c+d*Math.sin(h),g=u>180?1:0,_=a===0?"":`M ${c} ${c} L ${c} 0 A ${d} ${d} 0 ${g} 1 ${f} ${p} Z`;return e===0||a>=50?null:Cc.default.createElement("div",{className:gv.usageContainer},Cc.default.createElement("button",{type:"button",className:gv.usage,onClick:t,onMouseEnter:()=>o(!0),onMouseLeave:()=>o(!1)},Cc.default.createElement("svg",{width:l,height:l,viewBox:`0 0 ${l} ${l}`,className:gv.pie},Cc.default.createElement("circle",{cx:c,cy:c,r:d,fill:"var(--app-secondary-foreground)",opacity:"0.2"}),a>0&&Cc.default.createElement("path",{d:_,fill:"var(--app-secondary-foreground)"})),Cc.default.createElement("span",{className:gv.value},Math.round(a),"%")),i&&Cc.default.createElement("div",{className:gv.popup,ref:r},Cc.default.createElement("div",{className:gv.popupContent},Cc.default.createElement("div",{className:gv.remainingText},Math.round(a),"% of context remaining until auto-compact."),Cc.default.createElement("div",{className:gv.compactHint},"Click to compact now."))))}function RKe({session:n,mode:e,onCycleMode:t,currentSelection:i,canSendMessage:o,toggleCommandMenu:r,includeSelection:s,onToggleIncludeSelection:a,onCompact:l,onAttachFile:c}){nf();let d=null;n.busy.value&&!o?d=ho.default.createElement(fie,{className:$l.stopIcon}):d=ho.default.createElement(oie,{className:$l.sendIcon});let u=n.thinkingLevel.value!=="off",h=()=>{n.setThinkingLevel(n.thinkingLevel.value==="off"?"default_on":"off")};return ho.default.createElement("div",{className:$l.inputFooter},ho.default.createElement(jSt,{mode:e,onTap:t}),i&&ho.default.createElement(qSt,{includeSelection:s??!1,currentSelection:i,onToggle:a??(()=>{})}),ho.default.createElement(NKe,{usedTokens:n.usageData.value.totalTokens,contextWindow:n.usageData.value.contextWindow,onCompact:l}),ho.default.createElement("div",{className:$l.spacer}),ho.default.createElement(KSt,{thinkingOn:u,toggleThinking:h}),ho.default.createElement("button",{type:"button",className:$l.menuButton,title:"Show command menu (/)",onClick:r},ho.default.createElement(hie,{className:$l.menuIcon})),ho.default.createElement("button",{type:"submit",disabled:!n.busy.value&&!o,className:$l.sendButton,"data-permission-mode":e,onClick:f=>{n.busy.value&&!o&&(f.preventDefault(),n.interrupt())}},d))}function $St(n){if(n.selectedText){let e=n.endLine-n.startLine+1;return`${e} ${e===1?"line":"lines"} selected`}else{let e=n.filePath.split(/[/\\]/);return e[e.length-1]}}function jSt({mode:n,onTap:e}){switch(n){case"acceptEdits":return ho.default.createElement("button",{type:"button",className:$l.footerButton,onClick:e,title:"Claude will edit your selected text or the whole file. Click, or press Shift+Tab, to switch modes."},ho.default.createElement(Jye,null),ho.default.createElement("span",null,"Edit automatically"));case"plan":return ho.default.createElement("button",{type:"button",className:$l.footerButton,onClick:e,title:"Claude will explore the code and present a plan before editing. Click, or press Shift+Tab, to switch modes."},ho.default.createElement(e1e,null),ho.default.createElement("span",null,"Plan mode"));case"bypassPermissions":return ho.default.createElement("button",{type:"button",className:$l.footerButton,onClick:e,title:"Claude Code will not ask for your approval before running potentially dangerous commands."},ho.default.createElement(Qye,null),ho.default.createElement("span",null,"Bypass permissions"));case"default":default:return ho.default.createElement("button",{type:"button",className:$l.footerButton,onClick:e,title:"Claude will ask before each edit. Click, or press Shift+Tab, to switch modes."},ho.default.createElement(t1e,null),ho.default.createElement("span",null,"Ask before edits"))}}function qSt({includeSelection:n,currentSelection:e,onToggle:t}){let i=$St(e);return n?ho.default.createElement("button",{type:"button",className:$l.footerButton,onClick:t,title:`Showing Claude your current file selection (${i})`},ho.default.createElement(aie,null),ho.default.createElement("span",null,i)):ho.default.createElement("button",{type:"button",className:`${$l.footerButton} ${$l.footerButtonInactive}`,onClick:t,title:`Not showing Claude your current file selection (${i}). Click to attach.`},ho.default.createElement(lie,null),ho.default.createElement("span",null,i))}function KSt({thinkingOn:n,toggleThinking:e}){return ho.default.createElement("button",{type:"button",className:`${$l.menuButton} ${n?$l.menuButtonActivated:$l.menuButtonInactivated}`,title:n?"Thinking on":"Thinking off",onClick:e},ho.default.createElement("svg",{width:"16",height:"16",viewBox:"0 0 16 16",fill:"none",xmlns:"http://www.w3.org/2000/svg"},ho.default.createElement("path",{d:"M8.00293 1.11523L8.35059 1.12402H8.35352C11.9915 1.30834 14.8848 4.31624 14.8848 8C14.8848 11.8025 11.8025 14.8848 8 14.8848C4.19752 14.8848 1.11523 11.8025 1.11523 8C1.11523 7.67691 1.37711 7.41504 1.7002 7.41504C2.02319 7.41514 2.28516 7.67698 2.28516 8C2.28516 11.1563 4.84369 13.7148 8 13.7148C11.1563 13.7148 13.7148 11.1563 13.7148 8C13.7148 4.94263 11.3141 2.4464 8.29492 2.29297V2.29199L7.99609 2.28516H7.9873V2.28418L7.89648 2.27539L7.88281 2.27441V2.27344C7.61596 2.21897 7.41513 1.98293 7.41504 1.7002C7.41504 1.37711 7.67691 1.11523 8 1.11523H8.00293ZM8 3.81543C8.32309 3.81543 8.58496 4.0773 8.58496 4.40039V7.6377L10.9619 8.82715C11.2505 8.97169 11.3678 9.32256 11.2236 9.61133C11.0972 9.86425 10.8117 9.98544 10.5488 9.91504L10.5352 9.91211V9.91016L10.4502 9.87891L10.4385 9.87402V9.87305L7.73828 8.52344C7.54007 8.42433 7.41504 8.22155 7.41504 8V4.40039C7.41504 4.0773 7.67691 3.81543 8 3.81543ZM2.44336 5.12695C2.77573 5.19517 3.02597 5.48929 3.02637 5.8418C3.02637 6.19456 2.7761 6.49022 2.44336 6.55859L2.2959 6.57324C1.89241 6.57324 1.56543 6.24529 1.56543 5.8418C1.56588 5.43853 1.89284 5.1123 2.2959 5.1123L2.44336 5.12695ZM3.46094 2.72949C3.86418 2.72984 4.19017 3.05712 4.19043 3.45996V3.46094C4.19009 3.86393 3.86392 4.19008 3.46094 4.19043H3.45996C3.05712 4.19017 2.72983 3.86419 2.72949 3.46094V3.45996C2.72976 3.05686 3.05686 2.72976 3.45996 2.72949H3.46094ZM5.98926 1.58008C6.32235 1.64818 6.57324 1.94276 6.57324 2.2959L6.55859 2.44336C6.49022 2.7761 6.19456 3.02637 5.8418 3.02637C5.43884 3.02591 5.11251 2.69895 5.1123 2.2959L5.12695 2.14844C5.19504 1.81591 5.48906 1.56583 5.8418 1.56543L5.98926 1.58008Z",strokeWidth:"0.27",style:{stroke:"var(--app-secondary-foreground)",fill:"var(--app-secondary-foreground)"}})))}var Gt=Ue(Xe(),1);var dn={banner:"To",fadeIn:"Co",bannerVertical:"Ui",content:"Ao",text:"Ni",link:"Ro",actions:"Ki",stars:"Ji",starButton:"Qi",star:"Zi",closeButton:"Vo",feedbackButton:"Y",textButton:"Do",heartIcon:"_i",wiggle:"Go",transitionOverlay:"on"};var i1e=Ue(Xe(),1),CS=({width:n=47,height:e=38})=>i1e.default.createElement("svg",{width:n,height:e,viewBox:"0 0 47 38",fill:"none",xmlns:"http://www.w3.org/2000/svg"},i1e.default.createElement("path",{d:"M5.08191 10.0769V0.938461H9.37422V10.0769H5.08191ZM9.23305 10.0769V0.938461H13.5254V10.0769H9.23305ZM13.3842 10.0769V0.938461H17.6765V10.0769H13.3842ZM17.5353 10.0769V0.938461H21.8276V10.0769H17.5353ZM21.6865 10.0769V0.938461H25.9788V10.0769H21.6865ZM25.8376 10.0769V0.938461H30.1299V10.0769H25.8376ZM29.9888 10.0769V0.938461H34.2811V10.0769H29.9888ZM34.1399 10.0769V0.938461H38.4322V10.0769H34.1399ZM38.291 10.0769V0.938461H42.5834V10.0769H38.291ZM0.930769 19.0769V9.93846H5.22308V19.0769H0.930769ZM5.08191 19.0769V9.93846H9.37422V19.0769H5.08191ZM9.23305 19.0769V14.5077H13.5254V19.0769H9.23305ZM13.3842 19.0769V9.93846H17.6765V19.0769H13.3842ZM17.5353 19.0769V9.93846H21.8276V19.0769H17.5353ZM21.6865 19.0769V9.93846H25.9788V19.0769H21.6865ZM25.8376 19.0769V9.93846H30.1299V19.0769H25.8376ZM29.9888 19.0769V9.93846H34.2811V19.0769H29.9888ZM34.1399 19.0769V14.5077H38.4322V19.0769H34.1399ZM38.291 19.0769V9.93846H42.5834V19.0769H38.291ZM42.4422 19.0769V9.93846H46.7345V19.0769H42.4422ZM5.08191 28.0769V18.9385H9.37422V28.0769H5.08191ZM9.23305 28.0769V18.9385H13.5254V28.0769H9.23305ZM13.3842 28.0769V18.9385H17.6765V28.0769H13.3842ZM17.5353 28.0769V18.9385H21.8276V28.0769H17.5353ZM21.6865 28.0769V18.9385H25.9788V28.0769H21.6865ZM25.8376 28.0769V18.9385H30.1299V28.0769H25.8376ZM29.9888 28.0769V18.9385H34.2811V28.0769H29.9888ZM34.1399 28.0769V18.9385H38.4322V28.0769H34.1399ZM38.291 28.0769V18.9385H42.5834V28.0769H38.291ZM5.08191 37.0769V27.9385H9.37422V37.0769H5.08191ZM13.3842 37.0769V27.9385H17.6765V37.0769H13.3842ZM29.9888 37.0769V27.9385H34.2811V37.0769H29.9888ZM38.291 37.0769V27.9385H42.5834V37.0769H38.291Z",fill:"#D97757"}));var tN=Ue(Xe(),1),AKe=({width:n=32,height:e=26})=>tN.default.createElement("svg",{width:n,height:e,viewBox:"0 0 32 26",fill:"none",xmlns:"http://www.w3.org/2000/svg"},tN.default.createElement("path",{d:"M3.88775 7.44482V1.0876246H6.77738V7.44482H3.88775ZM6.7755 7.44482V1.0876246H9.66513V7.44482H6.7755ZM9.66325 7.44482V1.0876246H12.5529V7.44482H9.66325ZM12.551 7.44482V1.0876246H15.4406V7.44482H12.551ZM15.4388 7.44482V1.0876246H18.3284V7.44482H15.4388ZM18.3265 7.44482V1.0876246H21.2161V7.44482H18.3265ZM21.2143 7.44482V1.0876246H24.1039V7.44482H21.2143ZM24.102 7.44482V1.0876246H26.9916V7.44482H24.102ZM26.9898 7.44482V1.0876246H29.8794V7.44482H26.9898ZM1 13.4448V7.08762H3.88963V13.4448H1ZM3.88775 13.4448V7.08762H6.77738V13.4448H3.88775ZM6.7755 13.4448V10.26622H9.66513V13.4448H6.7755ZM9.66325 13.4448V7.08762H12.5529V13.4448H9.66325ZM12.551 13.4448V7.08762H15.4406V13.4448H12.551ZM15.4388 13.4448V7.08762H18.3284V13.4448H15.4388ZM18.3265 13.4448V7.08762H21.2161V13.4448H18.3265ZM21.2143 13.4448V7.08762H24.1039V13.4448H21.2143ZM24.102 13.4448V10.26622H26.9916V13.4448H24.102ZM26.9898 13.4448V7.08762H29.8794V13.4448H26.9898ZM29.8775 13.4448V7.08762H32.7671V13.4448H29.8775ZM3.88775 19.4448V13.0876H6.77738V19.4448H3.88775ZM6.7755 19.4448V13.0876H9.66513V19.4448H6.7755ZM9.66325 19.4448V13.0876H12.5529V19.4448H9.66325ZM12.551 19.4448V13.0876H15.4406V19.4448H12.551ZM15.4388 19.4448V13.0876H18.3284V19.4448H15.4388ZM18.3265 19.4448V13.0876H21.2161V19.4448H18.3265ZM21.2143 19.4448V13.0876H24.1039V19.4448H21.2143ZM24.102 19.4448V13.0876H26.9916V19.4448H24.102ZM26.9898 19.4448V13.0876H29.8794V19.4448H26.9898ZM3.88775 25.4448V19.0876H6.77738V25.4448H3.88775ZM9.66325 25.4448V19.0876H12.5529V25.4448H9.66325ZM21.2143 25.4448V19.0876H24.1039V25.4448H21.2143ZM26.9898 25.4448V19.0876H29.8794V25.4448H26.9898Z",fill:"#D97757"}),tN.default.createElement("rect",{x:"6",y:"7",width:"22",height:"5",fill:"#D97757"}),tN.default.createElement("rect",{x:"24",y:"10",width:"3",height:"2",fill:"#1F1F1F"}),tN.default.createElement("rect",{x:"7",y:"10",width:"3",height:"2",fill:"#1F1F1F"}));var YSt={totalSessions:0,recentSessions:0,editsAccepted:0,editsAutoAccepted:0,editsDeclined:0};function MKe(){return YSt}function PKe({context:n,session:e,otherPopupsVisible:t}){let[i,o]=(0,Gt.useState)("rating"),[r,s]=(0,Gt.useState)(null),[a,l]=(0,Gt.useState)(null),[c,d]=(0,Gt.useState)(!1),[u,h]=(0,Gt.useState)(null),f=(0,Gt.useRef)("rating"),p=(0,Gt.useRef)(!1);(0,Gt.useEffect)(()=>{if(!t&&!p.current){p.current=!0;let y=MKe();e.logEvent("review_upsell_shown",{totalSessions:y.totalSessions,recentSessions:y.recentSessions})}},[t,e]),(0,Gt.useEffect)(()=>{if(f.current!==i){d(!0);let y=setTimeout(()=>{d(!1)},500);return f.current=i,()=>clearTimeout(y)}},[i]);function g(y){l(y),e.logEvent("review_upsell_stars_selected",{stars:y}),o(y===5?"ask":"feedback")}function _(){o("review")}function b(){e.logEvent("review_upsell_favor_no",{}),n.dismissReviewUpsellBanner({stars:a||void 0,lastModified:Date.now(),step:"favor-no"})}function v(){let y=e.sessionId.value||"",L=`https://anthropic.qualtrics.com/jfe/form/SV_0ettWPbtcijGS2y?rating=${a||0}&session=${y}`;e.logEvent("review_upsell_give_feedback",{stars:a||void 0}),n.openURL(L),o("thanks"),h("feedback-given")}function x(){let y;switch(n.marketplaceType){case"openvsx":y="https://open-vsx.org/extension/Anthropic/claude-code/reviews";break;case"vscode":y="https://marketplace.visualstudio.com/items?itemName=anthropic.claude-code&ssr=false#review-details";break}e.logEvent("review_upsell_write_review",{stars:a||void 0,marketplace:n.marketplaceType}),n.openURL(y),o("thanks"),h("review-written")}function w(){let y="x-dismissed";u?y=u:i==="review"?y="review-close":i==="feedback"?y="feedback-closed":i==="thanks"&&(y="thanks-closed"),e.logEvent("review_upsell_dismissed",{stars:a||void 0,step:y}),n.dismissReviewUpsellBanner({stars:a||void 0,lastModified:Date.now(),step:y})}if(!t)return i==="rating"?Gt.default.createElement("div",{key:"rating",className:dn.banner},c&&Gt.default.createElement("div",{className:dn.transitionOverlay}),Gt.default.createElement(XSt,{onClick:w}),Gt.default.createElement("div",{className:dn.content},Gt.default.createElement(CS,{width:32,height:26}),Gt.default.createElement("span",{className:dn.text},"Rate Claude Code",n.marketplaceType==="vscode"?" for VS Code":" extension")),Gt.default.createElement("div",{className:dn.stars},[1,2,3,4,5].map(y=>Gt.default.createElement(ZSt,{key:y,rating:y,onClick:()=>g(y),onMouseEnter:()=>s(y),onMouseLeave:()=>s(null),isHovered:r!==null&&y<=r})))):i==="ask"?Gt.default.createElement("div",{key:"ask",className:dn.banner},c&&Gt.default.createElement("div",{className:dn.transitionOverlay}),Gt.default.createElement("div",{className:dn.content},Gt.default.createElement(CS,{width:32,height:26}),Gt.default.createElement("span",{className:dn.text},"Can I ask for a favor?")),Gt.default.createElement("div",{className:dn.actions},Gt.default.createElement("button",{className:dn.textButton,onClick:b},"What? No!"),Gt.default.createElement("button",{className:dn.feedbackButton,onClick:_},"Sure!"))):i==="review"?Gt.default.createElement("div",{key:"review",className:`${dn.banner} ${dn.bannerVertical}`},c&&Gt.default.createElement("div",{className:dn.transitionOverlay}),Gt.default.createElement("div",{className:dn.content},Gt.default.createElement(CS,{width:32,height:26}),Gt.default.createElement("span",{className:dn.text},"If I've been helpful to you, I'd love a review on the"," ",n.marketplaceType==="openvsx"?"OpenVSX":"VS Code"," ","marketplace!")),Gt.default.createElement("div",{className:dn.actions},Gt.default.createElement("button",{className:dn.feedbackButton,onClick:x},Gt.default.createElement(w3,{width:16,height:16}),"Write review"),Gt.default.createElement("button",{className:dn.textButton,onClick:w},"Close"))):i==="feedback"?Gt.default.createElement("div",{key:"feedback",className:`${dn.banner} ${dn.bannerVertical}`},c&&Gt.default.createElement("div",{className:dn.transitionOverlay}),Gt.default.createElement("div",{className:dn.content},Gt.default.createElement(AKe,{width:32,height:26}),Gt.default.createElement("span",{className:dn.text},"How can I do better? We would love to hear your feedback!")),Gt.default.createElement("div",{className:dn.actions},Gt.default.createElement("button",{className:dn.feedbackButton,onClick:v},Gt.default.createElement(w3,{width:16,height:16}),"Give feedback"),Gt.default.createElement("button",{className:dn.textButton,onClick:w},"Close"))):Gt.default.createElement("div",{key:"thankyou",className:dn.banner},c&&Gt.default.createElement("div",{className:dn.transitionOverlay}),Gt.default.createElement("div",{className:dn.content},Gt.default.createElement(CS,{width:32,height:26}),Gt.default.createElement(tie,{width:20,height:20,className:dn.heartIcon}),Gt.default.createElement("span",{className:dn.text},"Thank you very much for the feedback!")),Gt.default.createElement("div",{className:dn.actions},Gt.default.createElement("button",{className:dn.textButton,onClick:w},"Close")))}function ZSt({rating:n,onClick:e,onMouseEnter:t,onMouseLeave:i,isHovered:o}){return Gt.default.createElement("button",{className:dn.starButton,onClick:e,onMouseEnter:t,onMouseLeave:i,"aria-label":`Rate ${n} stars`},Gt.default.createElement("svg",{className:o?dn.starHovered:dn.star,width:"16",height:"16",viewBox:"0 0 20 20",fill:"none",xmlns:"http://www.w3.org/2000/svg"},Gt.default.createElement("path",{d:"M10 1L12.9389 6.90983L19.5106 7.90983L14.7553 12.5902L15.8779 19.0902L10 16L4.12215 19.0902L5.24472 12.5902L0.489435 7.90983L7.06107 6.90983L10 1Z",fill:o?"currentColor":"none",stroke:"currentColor",strokeWidth:"1.5",strokeLinejoin:"round"})))}function XSt({onClick:n}){return Gt.default.createElement("button",{className:dn.closeButton,onClick:n,"aria-label":"Close banner"},Gt.default.createElement("svg",{width:"8",height:"8",viewBox:"0 0 14 14",fill:"none",xmlns:"http://www.w3.org/2000/svg"},Gt.default.createElement("path",{d:"M1 1L13 13M1 13L13 1",stroke:"currentColor",strokeWidth:"1.5",strokeLinecap:"round"})))}var SS=Ue(Xe(),1);function FKe(n,e){let[,t]=(0,SS.useState)(0),[i,o]=(0,SS.useState)(!1);return(0,SS.useEffect)(()=>{if(!e)return;let r=()=>{t(a=>a+1)},s=a=>{a.key==="Escape"&&o(!0)};return document.addEventListener("selectionchange",r),e.addEventListener("keydown",s),()=>{document.removeEventListener("selectionchange",r),e.removeEventListener("keydown",s)}},[e]),(0,SS.useMemo)(()=>{let r=QSt(window.getSelection(),e),s=OKe(n,r,/(?:^|\s)@[^\s]*/gm,"@"),a=OKe(n,r,/(?:^|\s)\/[^\s/]*/gm,"/");return i&&!s&&!a&&o(!1),i?{atMention:void 0,slashCommand:void 0}:{atMention:s,slashCommand:a}},[n,e,i])}function n1e(n,e,t,i=!1){let o=n.substring(0,e.start),r=n.substring(e.end),s=i?n[e.start]:"",a=r.startsWith(" ")?"":" ";return o+s+t+a+r}function BKe(n,e){let t=n.substring(0,e.start),i=n.substring(e.end);return t+i}function QSt(n,e){if(!n||n.rangeCount===0||!e)return;let t=n.getRangeAt(0),i=document.createRange();return i.setStart(e,0),i.setEnd(t.startContainer,t.startOffset),i.toString().length}function OKe(n,e,t,i){if(e===void 0)return;let o=Array.from(n.matchAll(t));for(let r of o){let s=r.index;if(s===void 0)continue;let a=n.indexOf(i,s),l=s+r[0].length;if(e>=a&&e<=l)return{query:n.substring(a+1,l),start:a,end:l}}}var h_=Ue(Xe(),1);var WKe={"[Request interrupted by user]":"Interrupted","[Request interrupted by user for tool use]":"Tool interrupted"};function wX(n){if(n.type!=="text")return null;let e=n.text;if(WKe[e])return{type:"interrupt",message:e,friendlyMessage:WKe[e]};if(e.includes("")){let o=JSt(e);if(o)return{type:"ideSelection",selection:o,originalText:e}}if(e.includes("")){let o=ekt(e);if(o)return{type:"ideOpenedFile",file:o,originalText:e}}if(e.includes("")||e.includes("")){let{result:o,isError:r}=ikt(e);if(o)return{type:"slashCommandResult",result:o,isError:r}}if(e.includes("")){let o=nkt(e);if(o.length>0)return{type:"ideDiagnostics",diagnostics:o,originalText:e}}let t=tkt(e)||e,i=t.startsWith("/");return{type:"text",text:t,isSlashCommand:i}}function JSt(n){let e=n.match(/from ([^:]+):/);if(!e)return null;let t=e[1],i=t.split("/").pop()||t,o=i,r,s,a=n.match(/lines (\d+) to (\d+)/);return a&&(r=parseInt(a[1],10),s=parseInt(a[2],10),o=`${i}#${r}-${s}`),{filePath:t,startLine:r,endLine:s,label:o}}function ekt(n){let e=n.match(/(?:opened the file|opened file) (.+?) in (?:the )?(?:IDE|editor)/);if(!e)return null;let t=e[1],i=t.split("/").pop()||t;return{filePath:t,label:i}}function tkt(n){let e=n.match(/([\s\S]*?)<\/command-name>/),t=n.match(/([\s\S]*?)<\/command-args>/);if(!e)return null;let i=e[1].trim(),o=t?t[1].trim():"";return`${i} ${o}`.trim()}function ikt(n){let e=n.match(/([\s\S]*?)<\/local-command-stderr>/);if(e)return{result:e[1].trim()||"",isError:!0};let t=n.match(/([\s\S]*?)<\/local-command-stdout>/);return t?{result:t[1].trim()||"",isError:!1}:{result:null,isError:!1}}function nkt(n){let e=n.match(/([\s\S]*?)<\/post-tool-use-hook>/);if(!e)return[];let i=e[1].match(/([\s\S]*?)<\/ide_diagnostics>/);if(!i)return[];try{let o=JSON.parse(i[1]);if(Array.isArray(o))return o.map(r=>({filePath:r.filePath||"",line:r.line||0,column:r.column||0,message:r.message||"",code:r.code||"",severity:r.severity||""}))}catch{return[]}return[]}function okt(n){let e=document.createRange(),t=window.getSelection();n.firstChild?e.setStart(n.firstChild,0):e.selectNodeContents(n),e.collapse(!0),t?.removeAllRanges(),t?.addRange(e)}function rkt(n){let e=document.createRange(),t=window.getSelection(),i=n.firstChild||n,o=n.textContent||"";i&&o.length>0?(e.setStart(i,o.length),e.setEnd(i,o.length)):(e.selectNodeContents(n),e.collapse(!1)),t?.removeAllRanges(),t?.addRange(e)}function HKe({messages:n,currentInput:e,onInputChange:t,editableRef:i}){let[o,r]=(0,h_.useState)(-1),s=(0,h_.useRef)(""),a=(0,h_.useCallback)(()=>{let d=[];return n.filter(u=>u.type==="user").forEach(u=>{let h=[];u.content.forEach(p=>{let g=wX(p.content);g&&g.type==="text"&&h.push(g.text)});let f=h.join("").trim();f.length>0&&d.push(f)}),d.reverse()},[n]);(0,h_.useEffect)(()=>{e===""&&(r(-1),s.current="")},[e]);let l=(0,h_.useCallback)(d=>{if(!i.current)return!1;let u=window.getSelection();if(!u||u.rangeCount===0)return!1;let h=u.getRangeAt(0),f=i.current.textContent||"",p=d===-1?h.startOffset:h.endOffset;if(d===-1&&(p!==0||h.startContainer!==(i.current.firstChild||i.current))||d===1&&!(h.endContainer===(i.current.firstChild||i.current)&&p===f.length))return!1;let g=a();if(g.length===0)return!1;let _;if(d===-1)if(o===-1)s.current=e,_=0;else if(o0?_=o-1:_=-1}r(_);let b=_===-1?s.current:g[_];return t(b),i.current&&(i.current.textContent=b,setTimeout(()=>{i.current&&(d===-1&&_!==-1?okt(i.current):rkt(i.current))},0)),!0},[e,a,o,t,i]),c=(0,h_.useCallback)(()=>{r(-1),s.current=""},[]);return{cycleMessage:l,resetHistory:c}}var cr=Ue(Xe(),1);var Kf={menuPopup:"en",fadeIn:"Oo",modelList:"rn",sectionHeader:"in",checkIcon:"Po",modelItem:"nn",modelContent:"tn",modelLabel:"Xo",modelDescription:"an",activeModelItem:"Yo",emptyState:"dn"};function zKe({isOpen:n,onClose:e,availableModels:t,currentModel:i,onModelSelected:o}){let[r,s]=(0,cr.useState)(null),a=(0,cr.useRef)(null),l=(0,cr.useRef)(null);(0,cr.useEffect)(()=>{if(!n)return;let d=t?.find(u=>u.value===i);s(d?.value||null)},[n,t,i]);let c=(0,cr.useCallback)(d=>{if(!(!n||t===void 0)){if(d.key==="Escape"){d.preventDefault(),e();return}if(d.key==="ArrowDown"&&t.length>0){d.preventDefault();let u=t.findIndex(f=>f.value===r),h=u0){d.preventDefault();let u=t.findIndex(f=>f.value===r),h=u>0?u-1:t.length-1;s(t[h]?.value||null);return}if(d.key==="Enter"&&!d.shiftKey){d.preventDefault();let u=t.find(h=>h.value===r);u&&(o(u),e());return}}},[n,r,t,e,o]);return(0,cr.useEffect)(()=>{if(!n){document.removeEventListener("keydown",c);return}return document.addEventListener("keydown",c),()=>{document.removeEventListener("keydown",c)}},[n,c]),(0,cr.useEffect)(()=>{l.current&&l.current.scrollIntoView({behavior:"instant",block:"nearest"})},[r]),n?cr.default.createElement(cr.default.Fragment,null,cr.default.createElement("div",{ref:a,className:Kf.menuPopup},cr.default.createElement("div",{className:Kf.modelList},t===void 0&&cr.default.createElement("div",{className:Kf.emptyState},"Loading models\u2026"),t!==void 0&&t?.length===0&&cr.default.createElement("div",{className:Kf.emptyState},"No models available"),t!==void 0&&t?.length>0&&cr.default.createElement(cr.default.Fragment,null,cr.default.createElement("div",{className:Kf.sectionHeader},"Select a model"),t.map(d=>cr.default.createElement("div",{key:d.value,ref:d.value===r?l:null,className:`${Kf.modelItem} ${d.value===r?Kf.activeModelItem:""}`,onMouseEnter:()=>s(d.value),onClick:()=>{o(d),e()}},cr.default.createElement("div",{className:Kf.modelContent},cr.default.createElement("span",{className:Kf.modelLabel},d.displayName),d.description&&cr.default.createElement("span",{className:Kf.modelDescription},d.description)),cr.default.createElement("div",{className:Kf.checkIcon},i===d.value&&cr.default.createElement(Jte,null)))))))):null}var Wr=Ue(Xe(),1);var Gf={dialogContainer:"x",dialogContent:"cn",dialogHeader:"Uo",dialogDescription:"No",buttonContainer:"U",button:"f",shortcutNum:"ln"};var K4=Ue(Xe(),1);var VKe={icon:"sn"};function kS({size:n=16}){return K4.default.createElement("svg",{className:VKe.icon,width:n,height:n,viewBox:"0 0 20 20",xmlns:"http://www.w3.org/2000/svg"},K4.default.createElement("path",{d:"M5.14648 7.14648C5.34175 6.95122 5.65825 6.95122 5.85352 7.14648L8.35352 9.64648C8.44728 9.74025 8.5 9.86739 8.5 10C8.5 10.0994 8.47037 10.1958 8.41602 10.2773L8.35352 10.3535L5.85352 12.8535C5.65825 13.0488 5.34175 13.0488 5.14648 12.8535C4.95122 12.6583 4.95122 12.3417 5.14648 12.1465L7.29297 10L5.14648 7.85352C4.95122 7.65825 4.95122 7.34175 5.14648 7.14648Z"}),K4.default.createElement("path",{d:"M14.5 12C14.7761 12 15 12.2239 15 12.5C15 12.7761 14.7761 13 14.5 13H9.5C9.22386 13 9 12.7761 9 12.5C9 12.2239 9.22386 12 9.5 12H14.5Z"}),K4.default.createElement("path",{fillRule:"evenodd",clipRule:"evenodd",d:"M16.5 4C17.3284 4 18 4.67157 18 5.5V14.5C18 15.3284 17.3284 16 16.5 16H3.5C2.67157 16 2 15.3284 2 14.5V5.5C2 4.67157 2.67157 4 3.5 4H16.5ZM3.5 5C3.22386 5 3 5.22386 3 5.5V14.5C3 14.7761 3.22386 15 3.5 15H16.5C16.7761 15 17 14.7761 17 14.5V5.5C17 5.22386 16.7761 5 16.5 5H3.5Z"}))}var UKe={agents:{label:"Configure agents",dialogTitle:"Continue in Terminal to configure agents?",dialogDescription:"Once agents are configured in Terminal, you can reload this extension and ask Claude to use them here."},plugins:{label:"Manage plugins",dialogTitle:"Continue in Terminal to manage plugins?",dialogDescription:"After installing plugins, reload this extension to use them here."},hooks:{label:"Configure hooks",dialogTitle:"Continue in Terminal to configure hooks?",dialogDescription:"Once hooks are configured in this repository, they\u2019ll be active in your IDE, too."},mcp:{label:"Manage MCPs",dialogTitle:"Continue in Terminal to manage MCPs?",dialogDescription:"Once configured, MCPs will be reflected in your IDE, too."},memory:{label:"Edit memory",dialogTitle:"Continue in Terminal to edit memory?",dialogDescription:"Once configured, memories will be picked up by Claude Code here in your IDE."},"output-style":{label:"Change output styles",dialogTitle:"Continue in Terminal to change output style?",dialogDescription:"After changing your output style in Terminal and reloading this extension, you\u2019ll be able to use it here."},permissions:{label:"Manage permissions",dialogTitle:"Continue in Terminal to manage permissions?",dialogDescription:"Permission settings are shared between Terminal and this IDE."}};function $Ke(n,e){for(let[t,i]of Object.entries(UKe))n.commandRegistry.registerAction({id:`terminal-kickback-${t}`,label:i.label,description:i.dialogDescription,trailingComponent:Wr.default.createElement(kS,{size:24})},"Settings",()=>{e(t)})}function jKe({command:n,context:e,onRestartClaude:t,onClose:i}){let[o,r]=(0,Wr.useState)("kickback"),[s,a]=(0,Wr.useState)(0),l=(0,Wr.useRef)(null),c=(0,Wr.useRef)(null),d=(0,Wr.useRef)(null),u=async()=>{if(o==="kickback"){if(!n)return;r("refresh"),e.openClaudeInTerminal(`/${n}`,[],"window")}else await t(),i()},h=(0,Wr.useMemo)(()=>[l,c],[]),f=y=>{let C=document.activeElement,L=h.findIndex(M=>M.current===C),E=L===-1?0:(L+y+h.length)%h.length,N=h[E].current;N&&(a(E),e.safeFocus(N))},p=async y=>{let C=[u,i],L={};for(let[E,N]of C.entries())L[(E+1).toString()]=N;L[y.key]?(y.preventDefault(),L[y.key]()):y.key==="Escape"?(y.preventDefault(),i()):y.key==="ArrowDown"?(y.preventDefault(),f(1)):y.key==="ArrowUp"&&(y.preventDefault(),f(-1))};(0,Wr.useEffect)(()=>{let y=()=>{let L=document.activeElement,E=h.findIndex(N=>N.current===L);E!==-1&&a(E)},C=d.current;if(C)return C.addEventListener("focusin",y),()=>C.removeEventListener("focusin",y)},[h]);let g=y=>{if(y.target===y.currentTarget&&h[s].current){y.currentTarget.blur();let C=h[s].current;C&&e.safeFocus(C)}};(0,Wr.useEffect)(()=>{d.current&&e.safeFocus(d.current),l.current&&(a(0),e.safeFocus(l.current))},[e,o]);let _=UKe[n],b=o==="kickback"?_?_.dialogTitle:`Continue in Terminal to configure ${n}?`:"Terminal opened",v=o==="kickback"?_?.dialogDescription:"After making changes, exit Claude in Terminal, and reload the IDE extension to use them here.",x=o==="kickback"?"Continue in Terminal":"Refresh and continue",w=o==="kickback"?"Never mind":"Continue without refreshing";return Wr.default.createElement("div",{ref:d,className:Gf.dialogContainer,tabIndex:0,onKeyDown:p,onFocus:g,"data-focused-index":s},Wr.default.createElement("div",{className:Gf.dialogContainerBackground}),Wr.default.createElement("div",{className:Gf.dialogContent},Wr.default.createElement("div",{className:Gf.dialogHeader},Wr.default.createElement(kS,{size:24}),b),Wr.default.createElement("div",{className:Gf.dialogDescription},v)),Wr.default.createElement("div",{className:Gf.buttonContainer},Wr.default.createElement("button",{ref:l,className:`${Gf.button} ${Gf.primary}`,onClick:u},Wr.default.createElement("span",{className:Gf.shortcutNum},"1")," ",x),Wr.default.createElement("button",{ref:c,className:`${Gf.button}`,onClick:i},Wr.default.createElement("span",{className:Gf.shortcutNum},"2")," ",w)))}var yX=Ue(Xe(),1),o1e="claude-vscode-first-run-bypassed";function CX(){let[n,e]=(0,yX.useState)(()=>typeof globalThis<"u"&&globalThis.localStorage?globalThis.localStorage.getItem(o1e)==="true":!1);return(0,yX.useEffect)(()=>{function t(i){i.key===o1e&&e(i.newValue==="true")}return window.addEventListener("storage",t),()=>{window.removeEventListener("storage",t)}},[]),n}function r1e(){typeof globalThis<"u"&&globalThis.localStorage&&globalThis.localStorage.setItem(o1e,"true")}var s1e=(0,on.forwardRef)(({session:n,onSubmit:e,context:t,onListFiles:i,attachedFiles:o,onRemoveFile:r,onAddFiles:s,includeSelection:a,onToggleIncludeSelection:l,onModelSelected:c},d)=>{nf();let[u,h]=(0,on.useState)(""),[f,p]=(0,on.useState)(!1),[g,_]=(0,on.useState)(!1),[b,v]=(0,on.useState)(!1),[x,w]=(0,on.useState)(!1),[y,C]=(0,on.useState)(void 0),[L,E]=(0,on.useState)(null),[N,M]=(0,on.useState)(!1),F=(0,on.useRef)(null),q=200,{atMention:te,slashCommand:$}=FKe(u,F.current),z=HKe({messages:n.messages.value,currentInput:u,onInputChange:h,editableRef:F});(0,on.useEffect)(()=>{t.commandRegistry.registerAction({id:"model",label:"Select model"},"Settings",()=>{w(!0)}),$Ke(t,C)},[t]);let ae=(0,on.useRef)(null),X=t.currentSelection.value?.startColumn!==void 0,ue=ckt(),ce=dkt()?"\u2318 Esc":"ctrl esc",B=CX(),Je=n.busy.value?"Queue another message\u2026":X&&!ue?`${ce} to attach selected text`:B?`${ce} to focus or unfocus Claude`:"Ask Claude to edit\u2026";(0,on.useEffect)(()=>{$&&!g?(_(!0),v(!0),w(!1),C(void 0)):!$&&b&&(_(!1),v(!1),w(!1),C(void 0))},[$,g,b]);let ni=gt=>{if(!F.current)return;F.current.focus();let Ii=window.getSelection();if(!Ii)return;let un=document.createRange();un.selectNodeContents(F.current),un.collapse(!1),Ii.removeAllRanges(),Ii.addRange(un);let Tr=(qKe(F.current,Ii)?"":" ")+gt;document.execCommand("insertText",!1,Tr),setTimeout(()=>{Ri()},100)},K=gt=>{if(!F.current)return;F.current.focus();let Ii=window.getSelection();if(!Ii||!Ii.rangeCount){ni(gt);return}let Ao=(qKe(F.current,Ii)?"":" ")+gt;document.execCommand("insertText",!1,Ao),setTimeout(()=>{Ri()},100)};(0,on.useImperativeHandle)(d,()=>({focus:()=>{F.current&&t.safeFocus(F.current)},insertAtMention:(gt,Ii)=>{if(F.current){let un=window.getSelection();if(un&&un.rangeCount>0&&KKe(F.current,un).trimEnd().endsWith(gt))return}Ii?ni(gt):K(gt+" ")},setInputText:gt=>{if(F.current){F.current.textContent=gt,h(gt);let Ii=document.createRange(),un=window.getSelection();Ii.selectNodeContents(F.current),Ii.collapse(!1),un?.removeAllRanges(),un?.addRange(Ii)}}}),[t]),(0,on.useEffect)(()=>{F.current&&u===""&&(F.current.textContent="")},[u]);async function Ni(gt){gt?.preventDefault();let Ii=F.current?.textContent?.trim()||"";if(!Ii)return;let un=5e4,Ao=Ii;Ii.length>un&&(Ao=Ii.slice(0,un)+` [Message truncated - exceeded 50,000 character limit]`),h(""),F.current&&(F.current.textContent=""),z.resetHistory(),e(Ao)}let ui=()=>{e("/compact")};function po(){let gt=n.config.value?.allowDangerouslySkipPermissions?["default","acceptEdits","plan","bypassPermissions"]:["default","acceptEdits","plan"],un=(gt.indexOf(n.permissionMode.value)+1)%gt.length,Ao=gt[un];n.setPermissionMode(Ao,!0)}function Jr(gt){if(gt.key==="Tab"&>.shiftKey){gt.preventDefault(),po();return}if(gt.key==="Escape"){(te||$||g||x||y)&&(gt.preventDefault(),_(!1),v(!1),w(!1),C(void 0));return}if(!(($&&g||x||y)&&(gt.key==="ArrowDown"||gt.key==="ArrowUp"||gt.key==="Enter"||gt.key==="Tab"))&&!te){if(gt.key==="ArrowUp"&&!g&&!te&&z.cycleMessage(-1)){gt.preventDefault();return}if(gt.key==="ArrowDown"&&!g&&!te&&z.cycleMessage(1)){gt.preventDefault();return}if(gt.key==="Enter"&&!gt.shiftKey){if(gt.nativeEvent.isComposing)return;let Ii=gt.metaKey||gt.ctrlKey;(t.useCtrlEnterToSend?Ii:!0)&&(gt.preventDefault(),f?(Kl(),F.current?.textContent?.trim()&&Ni()):Ni())}}}function Ri(){let gt=F.current?.textContent||"";h(gt)}function vs(gt){let Ii=gt.clipboardData?.items;if(!Ii)return;let un=!1,Ao=[];for(let Tr=0;Tr0){gt.preventDefault();let Tr=new DataTransfer;Ao.forEach(Hr=>Tr.items.add(Hr)),s(Tr.files)}}function da(){v(!1),_(!g),w(!1),C(void 0)}function Sc(){_(!1),v(!1),w(!1),C(void 0)}function ql(gt,Ii){if(F.current&&te){let un=!(Ii&>.type==="directory"),Ao=un?gt.path+" ":gt.path,Tr=n1e(u,te,Ao,!0);F.current.textContent=Tr,h(Tr);let Hr=F.current.firstChild||F.current;if(Hr){let Hs=document.createRange(),Gl=un?1:0,Re=te.start+1+gt.path.length+Gl;Hs.setStart(Hr,Math.min(Re,Tr.length)),Hs.collapse(!0);let nt=window.getSelection();nt?.removeAllRanges(),nt?.addRange(Hs)}t.safeFocus(F.current)}}function Yf(gt,Ii){if(_(!1),v(!1),w(!1),C(void 0),!F.current)return;t.safeFocus(F.current);let un=gt.label.startsWith("/");if(!$)t.commandRegistry.executeCommand(gt.id);else if(Ii&&un){let Ao=n1e(u,$,gt.label+" ",!1);F.current.textContent=Ao,h(Ao);let Tr=F.current.firstChild||F.current;if(Tr){let Hr=document.createRange(),Hs=$.start+gt.label.length+1;Hr.setStart(Tr,Math.min(Hs,Ao.length)),Hr.collapse(!0);let Gl=window.getSelection();Gl?.removeAllRanges(),Gl?.addRange(Hr)}}else{let Ao=BKe(u,$);F.current.textContent=Ao,h(Ao);let Tr=F.current.firstChild||F.current;if(Tr&&Ao.length>0){let Hr=document.createRange();Hr.setStart(Tr,$.start),Hr.collapse(!0);let Hs=window.getSelection();Hs?.removeAllRanges(),Hs?.addRange(Hr)}t.commandRegistry.executeCommand(gt.id)}}async function Kl(){f?(await n.stopSpeechToText(),p(!1)):(p(!0),F.current?.focus(),await n.startSpeechToText(gt=>{if(F.current){F.current.textContent=gt,h(gt);let Ii=document.createRange(),un=window.getSelection();Ii.selectNodeContents(F.current),Ii.collapse(!1),un?.removeAllRanges(),un?.addRange(Ii)}}))}let sm=()=>{E(Date.now())},am=()=>{if(L===null)return;let gt=Date.now()-L;E(null),(gt{L!==null&&N&&(Kl(),M(!1),E(null))};return(0,on.useEffect)(()=>{if(L!==null){let gt=setTimeout(()=>{f||(M(!0),Kl())},q);return()=>clearTimeout(gt)}},[L,f]),on.default.createElement(on.default.Fragment,null,(g||te||$||x)&&on.default.createElement("div",{className:u_.scrim,onClick:Sc}),on.default.createElement("form",{onSubmit:Ni,className:u_.inputContainer,"data-permission-mode":n.permissionMode.value},on.default.createElement("div",{className:u_.inputContainerBackground}),on.default.createElement(TKe,{isOpen:g,onClose:Sc,onCommandSelect:Yf,commandRegistry:t.commandRegistry,filterText:$?.query||"",suppressFilter:b}),x&&!g&&on.default.createElement(zKe,{isOpen:x,onClose:Sc,availableModels:n.claudeConfig.value?.models,currentModel:n.modelSelection.value||n.config.value?.modelSetting,onModelSelected:c}),i&&te!==void 0&&!x&&!g&&on.default.createElement(DKe,{searchQuery:te.query,onClose:()=>{},onFileSelect:ql,onListFiles:i}),y&&te===void 0&&!x&&!g&&on.default.createElement(jKe,{command:y,context:t,onRestartClaude:async()=>{await n.restartClaude()},onClose:()=>{C(void 0),F.current&&t.safeFocus(F.current)}}),t.showReviewUpsellBanner.value&&on.default.createElement(PKe,{context:t,session:n,otherPopupsVisible:!!y||te!==void 0||x||g}),on.default.createElement("div",{className:u_.messageInputContainer},on.default.createElement("div",{ref:F,contentEditable:"plaintext-only",onInput:Ri,onKeyDown:Jr,onPaste:vs,onClick:()=>{g&&_(!1)},className:u_.messageInput,role:"textbox","aria-label":"Message input","aria-multiline":"true","data-placeholder":Je}),t.speechToTextEnabled&&(u===""||f)&&on.default.createElement("div",{className:u_.micButtonWrapper},on.default.createElement("button",{ref:ae,type:"button",onMouseDown:sm,onMouseUp:am,onMouseLeave:Yu,className:`${u_.micButton} ${f?u_.recording:""}`,title:f?"Stop recording":"Click to toggle recording, hold to use push-to-talk"},on.default.createElement(die,null)))),o&&o.length>0&&on.default.createElement("div",{className:u_.attachedFilesContainer},o.map((gt,Ii)=>on.default.createElement(vR,{key:Ii,label:gt.file.name,type:gt.file.type?.startsWith("image/")?"image":"document",onRemove:()=>r(Ii)}))),on.default.createElement(RKe,{session:n,mode:n.permissionMode.value,onCycleMode:po,currentSelection:n.selection.value,canSendMessage:!!u.trim(),toggleCommandMenu:da,includeSelection:a,onToggleIncludeSelection:l,onCompact:ui,onAttachFile:()=>{let gt=document.createElement("input");gt.type="file",gt.multiple=!0,gt.onchange=()=>{gt.files&>.files.length>0&&s(gt.files)},gt.click()}})))});function KKe(n,e){let t=e.getRangeAt(0),i=t.cloneRange();return i.setStart(n,0),i.setEnd(t.startContainer,t.startOffset),i.toString()}function qKe(n,e){let t=KKe(n,e);return t.length===0||/\s$/.test(t)}function ckt(){let[n,e]=(0,on.useState)(document.hasFocus());return(0,on.useEffect)(()=>{function t(){e(!0)}function i(){e(!1)}return window.addEventListener("focus",t),window.addEventListener("blur",i),()=>{window.removeEventListener("focus",t),window.removeEventListener("blur",i)}},[]),n}s1e.displayName="PromptInput";function dkt(){if(typeof navigator>"u")return!1;let n=navigator.userAgent,e=navigator.platform;return!!(/iPad|iPhone|iPod/.test(n)||e==="MacIntel"||/Mac/.test(e)||/Macintosh|Mac OS X/.test(n))}var LS=Ue(Xe(),1);var Gu=Ue(Xe(),1),GKe=()=>Gu.default.createElement("div",null,Gu.default.createElement("svg",{width:"172",height:"24",viewBox:"0 0 172 24",fill:"none",xmlns:"http://www.w3.org/2000/svg"},Gu.default.createElement("path",{d:"M4.65938 16.2682L9.19744 13.7235L9.27224 13.5006L9.19744 13.3765H8.97303L8.21253 13.3302L5.61935 13.2608L3.37526 13.1683L1.1935 13.0526L0.644944 12.9369L0.133789 12.2545L0.183658 11.9191L0.644944 11.6067L1.30571 11.6646L2.76437 11.7687L4.95859 11.9191L6.54192 12.0116L8.89822 12.2545H9.27224L9.32211 12.1041L9.19744 12.0116L9.0977 11.9191L6.82867 10.3807L4.37263 8.7613L3.08851 7.82439L2.40282 7.35014L2.05374 6.9106L1.90413 5.93899L2.52749 5.24498L3.37526 5.30281L3.5872 5.36065L4.44744 6.01996L6.28011 7.44268L8.67381 9.20084L9.0229 9.49001L9.16346 9.39514L9.18497 9.32808L9.0229 9.06204L7.72631 6.71397L6.34245 4.31963L5.71909 3.32488L5.55702 2.73497C5.49423 2.48741 5.45728 2.2826 5.45728 2.02939L6.16791 1.05778L6.56686 0.930542L7.52683 1.05778L7.92578 1.40478L8.52421 2.76967L9.48418 4.90954L10.9802 7.82439L11.4166 8.6919L11.6535 9.49001L11.7407 9.73292H11.8903V9.59411L12.015 7.95162L12.2394 5.93899L12.4638 3.34801L12.5386 2.6193L12.9002 1.74022L13.6233 1.26598L14.1843 1.53202L14.6456 2.19133L14.5833 2.6193L14.309 4.4006L13.7729 7.18821L13.4238 9.06204H13.6233L13.8602 8.81913L14.8077 7.56991L16.391 5.58042L17.0892 4.79387L17.912 3.92636L18.4356 3.50995H19.433L20.1561 4.59723L19.832 5.71922L18.8096 7.01471L17.9619 8.11356L16.7463 9.74212L15.9921 11.0515L16.0597 11.1596L16.2414 11.1441L18.9842 10.5542L20.4678 10.2881L22.2381 9.98739L23.036 10.3575L23.1233 10.7392L22.8116 11.5142L20.9166 11.9769L18.6974 12.428L15.3928 13.2059L15.3562 13.2353L15.3994 13.2994L16.8897 13.4343L17.5255 13.469H19.0839L21.9888 13.6888L22.7493 14.1862L23.1981 14.7992L23.1233 15.2734L21.9514 15.8633L20.3805 15.4932L16.7027 14.6141L15.4435 14.3018H15.269V14.4059L16.3162 15.4354L18.2486 17.1704L20.6548 19.4144L20.7795 19.9696L20.4678 20.4091L20.1436 20.3629L18.0242 18.7666L17.2014 18.0495L15.3562 16.488H15.2316V16.6499L15.6554 17.2745L17.912 20.6636L18.0242 21.7046L17.8621 22.04L17.2762 22.2482L16.6403 22.1326L15.3064 20.2703L13.9474 18.1883L12.8503 16.3145L12.7178 16.3981L12.0649 23.3702L11.7657 23.7288L11.0675 23.9948L10.4816 23.5553L10.1699 22.8382L10.4816 21.4154L10.8556 19.5647L11.1548 18.0958L11.4291 16.2682L11.5966 15.6577L11.5818 15.6168L11.4479 15.6393L10.0701 17.529L7.97565 20.3629L6.31752 22.1326L5.91857 22.2945L5.23287 21.9359L5.29521 21.2998L5.68169 20.733L7.97565 17.8181L9.35951 16.0021L10.2514 14.9597L10.2427 14.809L10.1935 14.8048L4.09836 18.7782L3.01371 18.917L2.53996 18.4775L2.60229 17.7603L2.8267 17.529L4.65938 16.2682Z",fill:"var(--app-claude-clay-button-orange)"}),Gu.default.createElement("path",{d:"M49.7578 4.98526V19.3633C49.7578 20.3095 50.2424 20.5172 51.5118 20.6788V21.6943H45.2343V20.6788C46.5037 20.5172 46.9883 20.3095 46.9883 19.3633V5.46991L45.3497 4.70831V4.10827L49.0423 3.00049H49.8732L49.7578 4.98526Z",fill:"var(--app-primary-foreground)"}),Gu.default.createElement("path",{d:"M37.1106 20.4018C38.1953 20.4018 39.0954 20.2403 39.8108 19.9172C41.2648 19.271 42.1418 18.0478 42.8803 16.0169H44.1035L43.5958 20.4711C41.6341 21.3942 39.4185 21.925 36.626 21.925C34.6643 21.925 32.9565 21.5327 31.5256 20.7249C28.6638 19.1325 27.1406 16.2708 27.1406 13.0397C27.1406 11.1242 27.5791 9.43945 28.433 7.98549C30.1409 5.07757 33.2103 3.46206 36.8106 3.46206C39.3723 3.46206 41.4725 4.01595 43.1573 5.10065L43.3188 9.13943H42.1187C41.1263 6.20843 39.3954 4.98526 36.5798 4.98526C32.4026 4.98526 30.5101 7.91626 30.5101 12.1397C30.5101 13.6398 30.7409 15.0014 31.2256 16.2477C32.1718 18.7633 34.1796 20.4018 37.1106 20.4018Z",fill:"var(--app-primary-foreground)"}),Gu.default.createElement("path",{fillRule:"evenodd",clipRule:"evenodd",d:"M64.0435 20.1018C63.3742 20.1018 63.0511 19.571 63.0511 18.5325V13.709C63.0511 10.4088 61.2971 9.13943 58.1354 9.13943C55.3428 9.13943 53.3119 10.2934 53.3119 12.2089C53.3119 12.7859 53.5196 13.2244 53.935 13.5244L56.0583 13.2474C55.966 12.6012 55.9198 12.2089 55.9198 12.0473C55.9198 10.9626 56.4968 10.4088 57.6738 10.4088C59.4047 10.4088 60.2817 11.6319 60.2817 13.5936V14.2398L55.8967 15.5553C54.4428 15.9477 53.6119 16.2938 53.058 17.1016C52.7811 17.517 52.6426 18.0709 52.6426 18.7402C52.6426 20.6096 53.935 21.925 56.1275 21.925C57.7199 21.925 59.1277 21.2096 60.3509 19.848C60.7894 21.2096 61.4587 21.925 62.6588 21.925C63.6281 21.925 64.5051 21.5327 65.2898 20.7711L65.059 19.9634C64.7128 20.0557 64.3897 20.1018 64.0435 20.1018ZM60.2817 18.8325C59.1508 19.6864 58.4815 20.0557 57.443 20.0557C56.2429 20.0557 55.5044 19.3633 55.5044 18.1401C55.5044 17.3093 55.8967 16.8246 56.7276 16.5477L60.2817 15.4168V18.8325Z",fill:"var(--app-primary-foreground)"}),Gu.default.createElement("path",{fillRule:"evenodd",clipRule:"evenodd",d:"M101.823 19.5018C103.6 19.5018 105.285 18.4863 106.139 16.9631L106.924 17.1708C106.578 19.8941 104.108 21.925 101.085 21.925C97.5307 21.925 95.0844 19.3171 95.0844 15.5553C95.0844 11.7935 97.7384 9.13943 101.293 9.13943C103.947 9.13943 105.816 10.7319 106.416 13.5013L97.7043 16.1738C98.237 18.2417 99.7149 19.5018 101.823 19.5018ZM103.393 13.1551C103.07 11.6089 102.123 10.7319 100.808 10.7319C98.8462 10.7319 97.4846 12.2089 97.4846 14.3321C97.4846 14.5555 97.4938 14.7725 97.5104 14.9848L103.393 13.1551Z",fill:"var(--app-primary-foreground)"}),Gu.default.createElement("path",{fillRule:"evenodd",clipRule:"evenodd",d:"M92.5688 18.9248V4.98526L92.6842 3.00049H91.8534L88.1608 4.10827V4.70831L89.7994 5.46991V10.0395C88.9916 9.43945 87.93 9.13943 86.6607 9.13943C82.9911 9.13943 80.1294 11.932 80.1294 16.1092C80.1294 19.5479 82.1834 21.925 85.576 21.925C87.3299 21.925 88.8531 21.0711 89.7994 19.7556L89.684 21.925H90.1686L94.4151 21.1173V20.0787L93.8151 20.0326C92.8227 19.9403 92.5688 19.7326 92.5688 18.9248ZM89.7994 18.6709C89.0608 19.4325 87.9761 19.8941 86.753 19.8941C84.2374 19.8941 82.9681 17.9093 82.9681 15.2553C82.9681 12.2781 84.422 10.5242 86.7299 10.5242C88.4839 10.5242 89.7994 11.5396 89.7994 13.409V18.6709Z",fill:"var(--app-primary-foreground)"}),Gu.default.createElement("path",{d:"M77.6138 11.5165V18.9248C77.6138 19.7326 77.8677 19.9403 78.8601 20.0326L79.4601 20.0787V21.1173L75.2136 21.925H74.729L74.8444 19.6633C73.7597 20.9788 72.3057 21.925 70.5286 21.925C68.1977 21.925 66.7437 20.7019 66.7437 18.1171V12.0243C66.7437 11.2627 66.4206 10.9626 65.3359 10.8011L64.9205 10.7319V9.7164L68.9362 9.13943H69.6286L69.5132 11.5165V17.7247C69.5132 19.271 70.3209 19.9403 71.6364 19.9403C72.8134 19.9403 73.8058 19.4325 74.8444 18.6248V12.0243C74.8444 11.2627 74.5213 10.9626 73.4366 10.8011L73.0442 10.7319V9.7164L77.0599 9.13943H77.7292L77.6138 11.5165Z",fill:"var(--app-primary-foreground)"}),Gu.default.createElement("path",{d:"M155.362 21.8081H154.868L154.986 19.6521C154.5 20.3096 153.881 20.8371 153.129 21.2347C152.392 21.617 151.577 21.8081 150.684 21.8081C149.524 21.8081 148.529 21.5635 147.698 21.0742C146.868 20.5696 146.233 19.8815 145.794 19.0099C145.355 18.123 145.136 17.1291 145.136 16.0281C145.136 14.652 145.434 13.4363 146.029 12.3812C146.625 11.3262 147.432 10.5157 148.45 9.94998C149.469 9.38422 150.582 9.10134 151.789 9.10134C153.089 9.10134 154.155 9.39951 154.986 9.99586V5.45444L153.317 4.69754V4.10119L157.078 3.00024H157.924L157.807 4.97278V18.8264C157.807 19.2239 157.893 19.4992 158.065 19.6521C158.238 19.7897 158.575 19.8815 159.076 19.9273L159.688 19.9732V21.0053L155.362 21.8081ZM151.859 10.4775C150.684 10.4775 149.751 10.8904 149.062 11.7161C148.372 12.5418 148.027 13.6963 148.027 15.1795C148.027 16.4945 148.349 17.5955 148.991 18.4823C149.634 19.3539 150.598 19.7897 151.883 19.7897C152.51 19.7897 153.089 19.6827 153.622 19.4686C154.155 19.2545 154.61 18.9564 154.986 18.5741V13.3446C154.986 12.4118 154.688 11.7008 154.092 11.2115C153.497 10.7222 152.753 10.4775 151.859 10.4775Z",fill:"var(--app-primary-foreground)"}),Gu.default.createElement("path",{d:"M137.019 21.808C135.765 21.808 134.66 21.548 133.704 21.0281C132.748 20.493 132.004 19.7666 131.471 18.8492C130.938 17.9164 130.672 16.8614 130.672 15.684C130.672 14.3689 130.977 13.2145 131.589 12.2205C132.2 11.2266 133.023 10.4621 134.057 9.92691C135.091 9.37643 136.236 9.1012 137.489 9.1012C138.743 9.1012 139.848 9.36879 140.804 9.90397C141.776 10.4239 142.528 11.1502 143.061 12.0829C143.594 13.0157 143.86 14.0631 143.86 15.2252C143.86 16.5402 143.555 17.6947 142.943 18.6886C142.332 19.6825 141.501 20.4547 140.451 21.0052C139.417 21.5404 138.273 21.808 137.019 21.808ZM137.677 20.34C138.727 20.34 139.519 19.9501 140.052 19.1703C140.585 18.3904 140.851 17.343 140.851 16.028C140.851 14.4377 140.491 13.1304 139.77 12.1059C139.064 11.0814 138.085 10.5691 136.831 10.5691C135.781 10.5691 134.99 10.959 134.457 11.7389C133.924 12.5187 133.657 13.5662 133.657 14.8812C133.657 16.4714 134.01 17.7788 134.715 18.8033C135.436 19.8278 136.424 20.34 137.677 20.34Z",fill:"var(--app-primary-foreground)"}),Gu.default.createElement("path",{d:"M122.007 20.2943C123.104 20.2943 124.021 20.1338 124.758 19.8127C125.494 19.4915 126.106 19.0175 126.591 18.3906C127.077 17.7637 127.508 16.9456 127.884 15.9364H129.13L128.613 20.3631C127.61 20.8219 126.529 21.1812 125.369 21.4411C124.225 21.6858 122.94 21.8081 121.514 21.8081C119.508 21.8081 117.776 21.4106 116.318 20.6154C114.861 19.8203 113.748 18.7499 112.98 17.4043C112.228 16.0587 111.852 14.5832 111.852 12.9776C111.852 11.0815 112.283 9.41481 113.145 7.97746C114.022 6.52482 115.205 5.40858 116.694 4.62874C118.199 3.8489 119.868 3.45898 121.702 3.45898C124.303 3.45898 126.458 4.00181 128.166 5.08747L128.308 9.03254H127.085C126.584 7.59519 125.878 6.56305 124.969 5.93612C124.06 5.2939 122.893 4.97279 121.467 4.97279C119.335 4.97279 117.768 5.63794 116.765 6.96826C115.777 8.28328 115.284 9.98822 115.284 12.0831C115.284 13.5663 115.527 14.9348 116.013 16.1887C116.498 17.4273 117.243 18.4212 118.246 19.1704C119.265 19.9197 120.518 20.2943 122.007 20.2943Z",fill:"var(--app-primary-foreground)"}),Gu.default.createElement("path",{fillRule:"evenodd",clipRule:"evenodd",d:"M166.93 19.5172C168.696 19.5172 170.371 18.508 171.219 16.9941L171.999 17.2006C171.655 19.9071 169.201 21.9256 166.196 21.9256C162.664 21.9256 160.232 19.3337 160.232 15.595C160.232 11.8563 162.87 9.21851 166.402 9.21851C169.04 9.21851 170.898 10.8012 171.494 13.5536L162.836 16.2097C163.366 18.2649 164.834 19.5172 166.93 19.5172ZM168.49 13.2095C168.169 11.6728 167.228 10.8012 165.921 10.8012C163.971 10.8012 162.618 12.2691 162.618 14.3793C162.618 14.6014 162.627 14.817 162.644 15.028L168.49 13.2095Z",fill:"var(--app-primary-foreground)"})));var jo=Ue(Xe(),1);var Kh={container:"pn",messageContainer:"Ko",message:"Jo",keyboardShortcut:"gn",key:"Qo"};var YKe={text:"What to do first? Ask about this codebase or we can start writing code."};function ZKe({context:n}){let e=(0,jo.useMemo)(()=>[{text:"// TODO: Everything. Let\u2019s start."},{text:jo.default.createElement(jo.default.Fragment,null,"Ready to code?",jo.default.createElement("br",null),"Let's write something worth deploying.")},{text:"Type /model to pick the right tool for the job."},{text:"Make a CLAUDE.md file for instructions Claude will read every single time."},{text:"Tired of repeating yourself? Tell Claude to remember what you\u2019ve told it using CLAUDE.md."},{text:jo.default.createElement(jo.default.Fragment,null,"Press"," ",jo.default.createElement("div",{className:Kh.keyboardShortcut},jo.default.createElement("span",{className:Kh.key},"Shift"),jo.default.createElement("span",{className:Kh.key},"Tab"))," ","to automatically approve code edits")},{text:jo.default.createElement(jo.default.Fragment,null,"Highlight any text and press"," ",jo.default.createElement("div",{className:Kh.keyboardShortcut},jo.default.createElement("span",{className:Kh.key},n.platform==="windows"?"Alt":"Option"),jo.default.createElement("span",{className:Kh.key},"K"))," ","to chat about it")},{text:"Use Claude Code in the terminal to configure MCP servers. They\u2019ll work here, too!"},{text:jo.default.createElement(jo.default.Fragment,null,"Use planning mode to talk through big changes before a commit. Press"," ",jo.default.createElement("div",{className:Kh.keyboardShortcut},jo.default.createElement("span",{className:Kh.key},"Shift"),jo.default.createElement("span",{className:Kh.key},"Tab"))," ","to cycle between modes.")},{text:"Type /model to pick the right tool for the job."},{text:"It's a beautiful day to use the computer, don't you think?"},{text:"You\u2019ve come to the absolutely right place!"}],[n.platform]),[t,i]=(0,jo.useState)(YKe),o=CX();return(0,jo.useEffect)(()=>{if(o){let r=Math.floor(Math.random()*e.length);i(e[r])}else i(YKe)},[e,o]),jo.default.createElement("div",{className:Kh.container},jo.default.createElement(CS,{width:46,height:45}),jo.default.createElement("div",{className:Kh.messageContainer},jo.default.createElement("div",{className:Kh.message},t.text)))}var _v=Ue(Xe(),1);var G4={banner:"mn",content:"bn",icon:"un",link:"Zo",closeButton:"_o"};function XKe({context:n}){return _v.default.createElement("div",{className:G4.banner},_v.default.createElement("div",{className:G4.content},_v.default.createElement(kS,null),_v.default.createElement("label",null,"Prefer the Terminal experience?"," ",_v.default.createElement("a",{href:"#",onClick:e=>{e.preventDefault(),n.showClaudeTerminalSetting()},className:G4.link},"Switch back in Settings."))),_v.default.createElement("button",{className:G4.closeButton,onClick:()=>{n.dismissTerminalBanner()},"aria-label":"Close banner"},_v.default.createElement("svg",{width:"10",height:"10",viewBox:"0 0 14 14",fill:"none",xmlns:"http://www.w3.org/2000/svg"},_v.default.createElement("path",{d:"M1 1L13 13M1 13L13 1",stroke:"currentColor",strokeWidth:"1.5",strokeLinecap:"round"}))))}var SX={container:"hn",topCenter:"oe",terminalBannerContainer:"xn"};function QKe({context:n}){return LS.default.createElement("div",{className:SX.container},LS.default.createElement("div",{className:SX.topCenter},LS.default.createElement(GKe,null)),LS.default.createElement(ZKe,{context:n}),n.showTerminalBanner.value&&LS.default.createElement("div",{className:SX.terminalBannerContainer},LS.default.createElement(XKe,{context:n})))}var LX=Ue(Xe(),1);var kX={selectionAttachment:"fn",icon:"vn",attachmentInfo:"wn",attachmentText:"kn"};function a1e({label:n,filePath:e,startLine:t,endLine:i,onClick:o}){let r=()=>{o(e,{startLine:t,endLine:i})};return LX.default.createElement("div",{className:kX.selectionAttachment,onClick:r,role:"button",tabIndex:0,onKeyDown:s=>{(s.key==="Enter"||s.key===" ")&&(s.preventDefault(),r())}},LX.default.createElement("div",{className:kX.attachmentInfo},LX.default.createElement("div",{className:kX.attachmentText,title:n},n)))}var Jo=Ue(Xe(),1);var dl={overlay:"yn",dialog:"ee",header:"zn",title:"Bn",closeButton:"re",description:"qn",loadingText:"Fn",codeBlock:"Hn",buttonContainer:"ie",button:"c",rejectMessageInput:"Wn",primary:"In",serverStatus:"Sn",serverList:"Ln",serverItem:"jn",serverName:"En",serverStatusBadge:"v",connected:"Mn",failed:"Tn","needs-auth":"Cn",pending:"An"};function JKe({isOpen:n,context:e,onLoadMcpServers:t,onClose:i,_onConfirm:o}){let[r,s]=(0,Jo.useState)([]),[a,l]=(0,Jo.useState)(!0),c=(0,Jo.useRef)(null);if((0,Jo.useEffect)(()=>{n&&(t().then(h=>{s(h),l(!1)}).catch(()=>{l(!1)}),c.current&&e.safeFocus?.(c.current))},[n,t,e]),!n)return null;let d=h=>{h.key==="Escape"&&(h.preventDefault(),i())},u=h=>{h.preventDefault(),e.openURL("https://docs.claude.com/en/docs/claude-code/mcp")};return Jo.default.createElement("div",{className:dl.overlay,onClick:i},Jo.default.createElement("div",{className:dl.dialog,onClick:h=>h.stopPropagation(),ref:c,onKeyDown:d,tabIndex:-1},Jo.default.createElement("div",{className:dl.header},Jo.default.createElement("h3",{className:dl.title},"Manage MCP Servers"),Jo.default.createElement("button",{className:dl.closeButton,onClick:i,"aria-label":"Close dialog"},Jo.default.createElement(nie,null))),Jo.default.createElement("div",{className:dl.content},a&&Jo.default.createElement("div",{className:dl.serverStatus},Jo.default.createElement("div",{className:dl.loadingText},"Loading MCP servers\u2026")),!a&&r.length===0&&Jo.default.createElement("div",{className:dl.serverStatus},Jo.default.createElement("span",{className:dl.serverName},"No running MCP servers.")),!a&&r.length>0&&Jo.default.createElement("div",{className:dl.serverStatus},Jo.default.createElement("ul",{className:dl.serverList},r.map(h=>Jo.default.createElement("li",{key:h.name,className:dl.serverItem},Jo.default.createElement("span",{className:dl.serverName},h.name),Jo.default.createElement("span",{className:`${dl.serverStatusBadge} ${dl[h.status]}`},h.status))))),Jo.default.createElement("div",{className:dl.description},"You can use the ",Jo.default.createElement("code",null,"claude mcp add")," command-line tool to configure system-wide or private servers.",Jo.default.createElement("br",null),Jo.default.createElement("a",{href:"https://docs.claude.com/en/docs/claude-code/mcp",className:dl.link,onClick:u},"Learn more")))))}var Er=Ue(Xe(),1);var Gh={container:"ne",actionButton:"i",subtleVisible:"Rn",visible:"Vn",popup:"Dn",popupHeader:"Gn",popupOption:"w",optionText:"On"};function eGe({context:n,session:e,message:t,containerRef:i,promptText:o}){let[r,s]=(0,Er.useState)(!1),[a,l]=(0,Er.useState)(!1),[c,d]=(0,Er.useState)(0),[u,h]=(0,Er.useState)(!1),f=(0,Er.useRef)(null),p=(0,Er.useRef)(null);if((0,Er.useEffect)(()=>{let y=i?.current;if(!y)return;let C=()=>l(!0),L=()=>l(!1);return y.addEventListener("mouseenter",C),y.addEventListener("mouseleave",L),()=>{y.removeEventListener("mouseenter",C),y.removeEventListener("mouseleave",L)}},[i]),(0,Er.useEffect)(()=>{function y(C){p.current&&!p.current.contains(C.target)&&f.current&&!f.current.contains(C.target)&&s(!1)}if(r)return document.addEventListener("mousedown",y),()=>{document.removeEventListener("mousedown",y)}},[r]),(0,Er.useEffect)(()=>{if(r&&p.current){let C=p.current.getBoundingClientRect();C.left<0?d(-C.left+8):d(0),h(!0)}else r||(d(0),h(!1))},[r]),window.CLAUDE_FORK_SESSIONS!==!0)return null;let g=e.sessionId.value;if(!g)return null;let _=e.messages.value,b;for(let y=_.indexOf(t)-1;y>=0;y--){let C=_[y];if(C?.uuid&&(C.type==="assistant"||C.type==="user")){b=C.uuid;break}}if(!b)return null;function v(){s(!1),b&&e.rewindCode(t.uuid)}function x(){s(!1),g&&n.forkConversation(g,o,b)}async function w(){s(!1),!(!g||!b)&&(await e.rewindCode(t.uuid),await n.forkConversation(g,o,b))}return Er.default.createElement("div",{className:`${Gh.container} ${a?Gh.messageHovered:""}`},Er.default.createElement("button",{ref:f,className:`${Gh.actionButton} ${r?Gh.visible:""} ${a?Gh.subtleVisible:""}`,onClick:()=>s(!r),title:"Message actions","aria-expanded":r},Er.default.createElement("svg",{style:{transform:"scale(0.9)"},xmlns:"http://www.w3.org/2000/svg",fill:"none",viewBox:"0 0 24 24",strokeWidth:"3",stroke:"currentColor"},Er.default.createElement("path",{strokeLinecap:"round",strokeLinejoin:"round",d:"M9 15 3 9m0 0 6-6M3 9h12a6 6 0 0 1 0 12h-3"}))),r&&Er.default.createElement("div",{ref:p,className:Gh.popup,style:{transform:c!==0?`translateX(${c}px)`:"none",visibility:u?"visible":"hidden"}},Er.default.createElement("button",{className:Gh.popupOption,onClick:x},Er.default.createElement("span",{className:Gh.optionText},"Fork conversation from here")),window.ENABLE_FILE_CHECKPOINTING&&Er.default.createElement(Er.default.Fragment,null,Er.default.createElement("button",{className:Gh.popupOption,onClick:v},Er.default.createElement("span",{className:Gh.optionText},"Rewind code to here")),Er.default.createElement("button",{className:Gh.popupOption,onClick:()=>void w()},Er.default.createElement("span",{className:Gh.optionText},"Fork conversation and rewind code")))))}var iN=Ue(Xe(),1);var Y4={diagnosticContainer:"Pn",diagnosticTitle:"Xn",diagnosticSubtitle:"Yn"};function tGe({diagnostics:n,context:e}){function t(){let i=bkt(n);e.fileOpener.openContent(i,"Diagnostics: VSCode Problems",!1)}return iN.default.createElement("div",{className:Y4.diagnosticContainer},iN.default.createElement("div",{className:Y4.diagnosticHeader},iN.default.createElement("span",{className:Y4.diagnosticTitle},"Diagnostics"),iN.default.createElement("span",{className:Y4.diagnosticSubtitle},"VSCode Problems")),iN.default.createElement($s,{onClick:t},"Found ",n.length," new problem",n.length!==1?"s":""))}function bkt(n){let e=new Map;for(let i of n){let o=e.get(i.filePath)||[];o.push(i),e.set(i.filePath,o)}let t=[];for(let[i,o]of e.entries()){t.push(`${i}:`);for(let r of o){let s=vkt[r.severity.toLowerCase()]||"\u2022",a=r.code?` [${r.code}]`:"";t.push(` ${s} [Line ${r.line}:${r.column}] ${r.message}${a} (${r.severity})`)}t.push("")}return t.join(` `)}var vkt={error:"\u2716",warning:"\u26A0",info:"\u2139",hint:"\u2022"};var ja=Ue(Xe(),1);var f_={expandableContainer:"Un",content:"te",collapsed:"Nn",truncationGradient:"Kn",expandButton:"ae",buttonContainer:"de",collapseButton:"ce"};function iGe({content:n,context:e,maxHeight:t=250}){let i=(0,ja.useRef)(null),[o,r]=(0,ja.useState)(!1),[s,a]=(0,ja.useState)(!1),[l,c]=(0,ja.useState)(!1);(0,ja.useEffect)(()=>{if(i.current){let u=i.current.scrollHeight;r(u>t)}},[t,n]);let d=()=>{a(!s)};return ja.default.createElement("div",{className:f_.expandableContainer},ja.default.createElement("div",{className:f_.contentWrapper,onMouseEnter:()=>c(!0),onMouseLeave:()=>c(!1)},ja.default.createElement("div",{ref:i,className:`${f_.content} ${!s&&o?f_.collapsed:""}`,style:!s&&o?{maxHeight:`${t}px`}:void 0},ja.default.createElement(Xv,{content:n,context:e,plainText:!0}),!s&&o&&ja.default.createElement("div",{className:f_.truncationGradient})),!s&&o&&ja.default.createElement(ja.default.Fragment,null,ja.default.createElement("div",{className:f_.buttonContainer,onClick:d},l&&ja.default.createElement("button",{className:f_.expandButton,"aria-label":"Show more"},"Show more")))),s&&o&&ja.default.createElement("div",{className:f_.buttonContainer},ja.default.createElement("button",{className:f_.collapseButton,onClick:d,"aria-label":"Show less"},"Show less")))}function oGe({session:n,context:e}){nf();let t=(0,yt.useRef)(null),i=(0,yt.useRef)(null),o=(0,yt.useRef)(null),r=(0,yt.useRef)(null),s=(0,yt.useRef)(null),[a,l]=(0,yt.useState)(0),c=(0,yt.useRef)(0),[d,u]=(0,yt.useState)([]),h=(0,yt.useRef)(null),f=(0,yt.useRef)(!0),[p,g]=(0,yt.useState)(!0),[_,b]=(0,yt.useState)(!1),[v,x]=(0,yt.useState)(!1);function w(X){X.ctrlKey&&X.key==="o"&&(X.preventDefault(),x(ue=>!ue))}(0,yt.useEffect)(()=>{e.commandRegistry.registerAction({id:"mention-file",label:"Mention a file"},"Manage Context",()=>{r.current?.focus(),r.current?.insertAtMention("@",!0)}),e.commandRegistry.registerAction({id:"attach-file",label:"Attach file"},"Manage Context",()=>{h.current?.click()}),e.commandRegistry.registerAction({id:"mcp-config",label:"MCP Status"},"Settings",async()=>{b(!0)}),e.commandRegistry.registerAction({id:"slash-command-config",label:"General Config",description:"Open Claude Code Extension configuration"},"Settings",()=>{e.openConfig()}),e.commandRegistry.registerAction({id:"slash-command-help",label:"Help",description:"Open help documentation"},"Misc",()=>{e.openHelp()}),e.commandRegistry.registerAction({id:"slash-command-terminal",label:"Open Claude in Terminal",description:"Open a new Claude instance in the Terminal",trailingComponent:yt.default.createElement(kS,{size:24})},"Misc",()=>{e.openClaudeInTerminal(void 0,void 0,"bottom")})},[e,n]),(0,yt.useEffect)(()=>{let X=e.atMentionEvents.add(ue=>{if(n.permissionRequests.value.length>0){let ce=s.current?.querySelector('[tabindex="0"]');ce&&e.safeFocus(ce)}else r.current?.focus(),ue&&r.current?.insertAtMention(ue,!1)});return()=>{X()}},[e,n.permissionRequests.value.length]),(0,yt.useEffect)(()=>{e.currentSelection!==void 0&&n.selection.value===void 0&&(n.selection.value=e.currentSelection.value)},[e.currentSelection,n]);let y=i.current;if(y){let{scrollTop:X,scrollHeight:ue,clientHeight:ce}=y,B=ue-X-ce;f.current=B<50}(0,yt.useLayoutEffect)(()=>{if(!t.current||!i.current)return;if(n.permissionRequests.value.length>0){t.current.scrollIntoView({behavior:"smooth"});return}let X=n.messages.value.length,ue=c.current===0&&X>0;if(c.current=X,ue){t.current.scrollIntoView({behavior:"smooth"}),f.current=!0;return}f.current&&t.current.scrollIntoView()},[n.messages.value,n.permissionRequests.value,v]),(0,yt.useEffect)(()=>{n.permissionRequests.value.length===0&&setTimeout(()=>{r.current?.focus()},100)},[n.permissionRequests.value.length]),(0,yt.useEffect)(()=>{r.current?.focus()},[n.sessionId.value]);let C=n.initialPrompt.value;(0,yt.useEffect)(()=>{C&&(r.current?.setInputText(C),n.initialPrompt.value=void 0)},[n,C]),(0,yt.useEffect)(()=>{c.current=n.messages.value.length},[n.messages.value.length]);function L(X){X.preventDefault(),X.stopPropagation()}async function E(X){if(X.preventDefault(),X.stopPropagation(),n.isLoading.value||!e.isAuthenticated||n.permissionRequests.value.length>0||_)return;let ue=X.dataTransfer?.files;if(ue&&ue.length>0){let B=await I5(ue);u(Je=>[...Je,...B])}let ce=X.dataTransfer?.items;ce&&(await Lkt(ce,n.cwd.value,B=>{r.current?.insertAtMention(`@${B}`,!1)}),r.current?.focus())}(0,yt.useEffect)(()=>{if(!o.current)return;let X=new ResizeObserver(ue=>{for(let ce of ue)l(ce.contentRect.height)});return X.observe(o.current),()=>{X.disconnect()}},[]);let N=(0,yt.useCallback)(async X=>{try{r1e();let ue=X.trim().startsWith("/");await n.send(X,d,p&&!ue),u([]),t.current?.scrollIntoView({behavior:"smooth"})}catch{}},[n,d,p]);ou(()=>{n.claudeConfig.value?.slashCommands?.forEach(X=>{e.commandRegistry.registerAction({id:`slash-command-${X.name}`,label:`/${X.name}`,description:X.description},"Slash Commands",()=>{let ue=`/${X.name}`;N(ue)})})});async function M(X){let ue=X.target.files;if(!ue)return;let ce=await I5(ue);u(B=>[...B,...ce]),X.target.value=""}let F=n.busy.value&&!n.permissionRequests.value.length,q=yt.default.createElement("div",{className:Xn.spinnerRow},yt.default.createElement("div",{className:Xn.spinner},F&&yt.default.createElement(gke,{permissionMode:n.permissionMode.value,status:n.status.value}))),te=n.messages.value.length>0,$=wkt(n.messages.value,n.permissionRequests.value),z=n.error.value,ae=null;return e.isAuthenticated.value&&(ae=yt.default.createElement("div",{className:Xn.promptInputContainer,style:{display:n.permissionRequests.value.length>0?"none":"block"}},yt.default.createElement(s1e,{session:n,ref:r,onSubmit:N,onListFiles:X=>new Promise((ue,ce)=>{n.listFiles(X).then(B=>{ue(B?B.files:[])}).catch(()=>ce())}),context:e,attachedFiles:d,onRemoveFile:X=>{u(ue=>ue.filter((ce,B)=>B!==X))},onAddFiles:async X=>{let ue=await I5(X);u(ce=>[...ce,...ue])},includeSelection:p,onToggleIncludeSelection:()=>g(X=>!X),onModelSelected:async X=>await n.setModel(X)}),yt.default.createElement("input",{ref:h,type:"file",accept:"*/*",multiple:!0,style:{display:"none"},onChange:M}))),yt.default.createElement("div",{className:Xn.chatContainer,onDragOver:L,onDrop:E,onKeyDown:w},z&&yt.default.createElement("div",{className:Xn.errorBanner},yt.default.createElement("div",{className:Xn.errorMessage},z,yt.default.createElement("br",null),yt.default.createElement(N_,null)),yt.default.createElement("button",{className:Xn.errorDismiss,onClick:()=>{n.error.value=void 0},"aria-label":"Dismiss error"},"\xD7")),n.isLoading.value&&yt.default.createElement("div",{className:Xn.loadingState},"Loading..."),!n.isLoading.value&&!te&&yt.default.createElement("div",{className:Xn.emptyState},yt.default.createElement(QKe,{context:e})),te&&yt.default.createElement("div",{ref:i,className:`${Xn.messagesContainer} ${n.permissionRequests.value.length>0?Xn.dimmed:""}`},n.messages.value.map((X,ue)=>kkt(n,X,ue,e,$===ue,v,x)),q,yt.default.createElement("div",{ref:t,style:{height:`${a}px`,minHeight:`${a}px`}})),yt.default.createElement("div",{className:Xn.messageGradient}),yt.default.createElement("div",{ref:o,className:Xn.inputContainer},n.awsAuthInProgress.value&&yt.default.createElement("div",{className:Xn.authStatusContainer},yt.default.createElement(EKe,{output:n.awsAuthInProgress.value.output,error:n.awsAuthInProgress.value.error})),n.permissionRequests.value.length>0&&yt.default.createElement("div",{ref:s,className:Xn.permissionsContainer},yt.default.createElement(IKe,{key:0,request:n.permissionRequests.value[0],context:e,onPermissionModeChange:async(X,ue)=>{await n.setPermissionMode(X,ue)}})),ae),_&&yt.default.createElement(JKe,{isOpen:_,onLoadMcpServers:async()=>(await n.getMcpServers()).mcpServers,onClose:()=>b(!1),_onConfirm:()=>{b(!1),n.restartClaude()},context:e}))}function wkt(n,e){if(e.length===0)return;let t=e[0].toolName;for(let i=n.length-1;i>=0;i--){let o=n[i];if(o.type==="assistant"){for(let r of o.content)if(r.content.type==="tool_use"&&r.content.name===t&&!r.toolResult.value)return i}}}function ykt(n,e){if(n.type==="assistant"){for(let t of n.content)if(t.content.type==="tool_use"){let i=t.toolResult.value;return i?i.is_error?"failure":"success":e?"progress":"failure"}}return null}function Ckt({message:n,index:e,context:t,isHighlighted:i=!1,areThinkingBlocksExpanded:o,setAreThinkingBlocksExpanded:r,isBusy:s}){let a=yt.default.useRef(null),l=ykt(n,s),c=l==="success"?Xn.dotSuccess:l==="failure"?Xn.dotFailure:l==="progress"?Xn.dotProgress:"";return yt.default.createElement("div",{key:e,ref:a,className:`${Xn.message} ${Xn.timelineMessage} ${c} ${i?Xn.highlightedMessage:""}`},n.content.map(d=>yt.default.createElement(Xv,{key:d.key,content:d,context:t,areThinkingBlocksExpanded:o,setAreThinkingBlocksExpanded:r})))}function Skt({session:n,message:e,index:t,context:i,isHighlighted:o=!1,areThinkingBlocksExpanded:r,setAreThinkingBlocksExpanded:s}){let a=yt.default.useRef(null),l=e.content.toReversed().map(f=>wX(f.content)),c="";for(let f of l)f?.type==="text"&&(c+=f.text);let d=l.find(f=>f?.type==="ideDiagnostics"),u=d?Xn.timelineMessage:Xn.userMessageContainer,h=d?Xn.dotWarning:"";return yt.default.createElement("div",{key:t,className:`${Xn.message} ${u} ${h} ${o?Xn.highlightedMessage:""}`,ref:a},e.content.toReversed().map((f,p)=>{let g=l[p];if(f.content.type==="image"||f.content.type==="document")return yt.default.createElement("div",{key:p},yt.default.createElement(Xv,{content:f,context:i,areThinkingBlocksExpanded:r,setAreThinkingBlocksExpanded:s}));if(g)switch(g.type){case"toolUseHook":return null;case"interrupt":return yt.default.createElement("div",{className:Xn.interruptedMessage,key:p},g.friendlyMessage);case"ideSelection":return yt.default.createElement("div",{key:p},yt.default.createElement(a1e,{label:g.selection.label,filePath:g.selection.filePath,startLine:g.selection.startLine,endLine:g.selection.endLine,onClick:(_,b)=>i.fileOpener.open(_,b)}));case"ideOpenedFile":return yt.default.createElement("div",{key:p},yt.default.createElement(a1e,{label:g.file.label,filePath:g.file.filePath,onClick:(_,b)=>i.fileOpener.open(_,b)}));case"ideDiagnostics":return yt.default.createElement("div",{key:p},yt.default.createElement(tGe,{diagnostics:g.diagnostics,context:i}));case"slashCommandResult":return yt.default.createElement("div",{className:Xn.slashCommandResultMessage,key:p},yt.default.createElement(xm,{content:g.result,context:i}));case"text":if(g.isSlashCommand)return yt.default.createElement("div",{className:`${Xn.userMessage} ${Xn.slashCommandMessage}`,key:p},g.text);break}return yt.default.createElement("div",{className:Xn.userMessageContainer,key:p},yt.default.createElement(eGe,{session:n,message:e,context:i,containerRef:a,promptText:c}),yt.default.createElement("div",{className:Xn.userMessage},yt.default.createElement(iGe,{content:f,context:i})))}))}function kkt(n,e,t,i,o=!1,r,s){return e.isEmpty?null:e.type==="user"?e.parentToolUseId?null:yt.default.createElement(Skt,{session:n,message:e,index:t,context:i,isHighlighted:o,areThinkingBlocksExpanded:r,setAreThinkingBlocksExpanded:s}):e.type==="assistant"?yt.default.createElement(Ckt,{message:e,index:t,context:i,isHighlighted:o,areThinkingBlocksExpanded:r,setAreThinkingBlocksExpanded:s,isBusy:n.busy.value}):null}async function Lkt(n,e,t){let i=new Set;for(let o=0;o{try{let a=JSON.parse(s);if(!Array.isArray(a))return;for(let l of a)if(typeof l=="string"){let c=await nGe(l,e);c&&!i.has(c)&&(t(c),i.add(c))}}catch{}})}for(let o=0;o{try{let a=JSON.parse(s);if(!Array.isArray(a))return;for(let l of a){if(!l?.resource)continue;let c=l.resource.external||l.resource.fsPath;if(!c)continue;let d=await nGe(c,e);d&&!i.has(d)&&(t(d),i.add(d))}}catch{}})}}async function nGe(n,e){if(!n.trim())return null;let t=n.trim();return t.startsWith("file://")?(t=decodeURIComponent(t.substring(7)),e&&t.startsWith(e)&&(t=t.slice(e.length),t.startsWith("/")&&(t=t.slice(1))),t):null}var jl=Ue(Xe(),1);var rm={overlay:"Jn",dialog:"Qn",title:"Zn",content:"_n",label:"ot",input:"le",hint:"et",actions:"rt",cancelButton:"N",confirmButton:"L"};function rGe({isOpen:n,onClose:e,onConfirm:t}){let[i,o]=(0,jl.useState)(""),r=(0,jl.useRef)(null);if((0,jl.useEffect)(()=>{n&&(o(lee()),setTimeout(()=>{r.current?.focus(),r.current?.select()},0))},[n]),!n)return null;let s=l=>{l.preventDefault(),i.trim()&&t(i.trim())},a=l=>{l.key==="Escape"&&(l.preventDefault(),e())};return jl.default.createElement("div",{className:rm.overlay,onClick:e},jl.default.createElement("div",{className:rm.dialog,onClick:l=>l.stopPropagation(),onKeyDown:a},jl.default.createElement("h2",{className:rm.title},"Create Worktree Session"),jl.default.createElement("form",{onSubmit:s},jl.default.createElement("div",{className:rm.content},jl.default.createElement("label",{htmlFor:"worktree-name",className:rm.label},"Worktree Name"),jl.default.createElement("input",{ref:r,id:"worktree-name",type:"text",value:i,onChange:l=>o(l.target.value),className:rm.input,placeholder:"Enter worktree name",autoComplete:"off"}),jl.default.createElement("p",{className:rm.hint},"A new Git worktree will be created in a sibling directory")),jl.default.createElement("div",{className:rm.actions},jl.default.createElement("button",{type:"button",onClick:e,className:rm.cancelButton},"Cancel"),jl.default.createElement("button",{type:"submit",disabled:!i.trim(),className:rm.confirmButton},"Create")))))}var fo=Ue(Xe(),1);var ul={overlay:"it",dropdown:"nt",searchContainer:"tt",searchIcon:"at",searchInput:"K",clearButton:"se",content:"dt",nullState:"ct",nullStateText:"lt",emptyState:"st",sectionTitle:"pe",sessionsList:"pt",sessionItem:"s",focused:"gt",active:"J",checkIcon:"ge",sessionName:"me",highlight:"mt",sessionTime:"bt"};function aGe({isOpen:n,onClose:e,sessions:t,activeSession:i,onSessionClick:o,buttonRef:r}){nf();let[s,a]=(0,fo.useState)(0),[l,c]=(0,fo.useState)(""),d=(0,fo.useRef)(null),u=(0,fo.useRef)(new Map),h=(0,fo.useRef)(null),f=l?t.filter(y=>sGe(y).toLowerCase().includes(l.toLowerCase())):t,p=Dkt(f),g=[];if(p.forEach(y=>{g.push(...y.sessions)}),(0,fo.useEffect)(()=>{if(n){let y=g.findIndex(C=>C===i);a(y>=0?y:0),setTimeout(()=>{h.current?.focus(),u.current.get(y>=0?y:0)?.scrollIntoView({block:"nearest",behavior:"instant"})},0)}else u.current.clear(),c("")},[n,i]),(0,fo.useEffect)(()=>{u.current.get(s)?.scrollIntoView({block:"nearest",behavior:"instant"})},[s]),!n)return null;let _=y=>{o(y),e()},b=r.current?.getBoundingClientRect(),v=b?{top:`${b.bottom+4}px`,left:`${b.left}px`}:{};function x(y){if(n)switch(y.key){case"ArrowDown":y.preventDefault(),a(C=>Math.min(C+1,g.length-1));break;case"ArrowUp":y.preventDefault(),a(C=>Math.max(C-1,0));break;case"Enter":y.preventDefault(),g[s]&&_(g[s]);break;case"Escape":y.preventDefault(),l?c(""):e();break}}let w=0;return fo.default.createElement(fo.default.Fragment,null,fo.default.createElement("div",{className:ul.overlay,onClick:e}),fo.default.createElement("div",{ref:d,className:ul.dropdown,style:v,onKeyDown:x,tabIndex:-1},fo.default.createElement("div",{className:ul.searchContainer},fo.default.createElement(cie,{className:ul.searchIcon}),fo.default.createElement("input",{ref:h,type:"text",className:ul.searchInput,placeholder:"Search sessions\u2026",value:l,onChange:y=>c(y.target.value)}),l&&fo.default.createElement("button",{className:ul.clearButton,onClick:()=>c(""),"aria-label":"Clear search"},"\xD7")),fo.default.createElement("div",{className:ul.content},t.length===0?fo.default.createElement("div",{className:ul.nullState},fo.default.createElement("div",{className:ul.nullStateText},"No sessions yet")):p.length===0&&l?fo.default.createElement("div",{className:ul.emptyState},"No sessions found"):p.map(({label:y,sessions:C})=>fo.default.createElement(fo.default.Fragment,{key:y},fo.default.createElement("div",{className:ul.sectionTitle},y),fo.default.createElement("div",{className:ul.sessionsList},C.map((L,E)=>{let N=w++,M=N===s;return fo.default.createElement("button",{key:`${y}-${E}`,ref:F=>{F&&u.current.set(N,F)},className:`${ul.sessionItem} ${L===i?ul.active:""} ${M?ul.focused:""}`,onClick:()=>_(L),onMouseEnter:()=>a(N)},fo.default.createElement("span",{className:ul.sessionName},lGe(sGe(L),l)),fo.default.createElement("span",{className:ul.sessionTime},Tkt(L.lastModifiedTime.value)))})))))))}function sGe(n){return n.summary.value||"Untitled"}function lGe(n,e){if(!e)return n;let t=n.toLowerCase(),i=e.toLowerCase(),o=t.indexOf(i);if(o===-1)return n;let r=n.slice(0,o),s=n.slice(o,o+e.length),a=n.slice(o+e.length);return fo.default.createElement(fo.default.Fragment,null,r,fo.default.createElement("mark",{className:ul.highlight},s),lGe(a,e))}function Tkt(n){let t=Date.now()-n,i=Math.floor(t/1e3),o=Math.floor(i/60),r=Math.floor(o/60),s=Math.floor(r/24),a=Math.floor(s/30),l=Math.floor(s/365);return l>0?`${l}y`:a>0?`${a}mo`:s>0?`${s}d`:r>0?`${r}h`:o>0?`${o}m`:"now"}function Dkt(n){let e=Date.now(),t=24*60*60*1e3,i=7*t,o=30*t,r=[],s=[],a=[],l=[],c=[],d=new Date;d.setHours(0,0,0,0);let u=d.getTime(),h=u-t;n.forEach(p=>{let g=p.lastModifiedTime.value,_=e-g;g>=u?r.push(p):g>=h?s.push(p):_<=i?a.push(p):_<=o?l.push(p):c.push(p)});let f=[];return r.length>0&&f.push({label:"Today",sessions:r}),s.length>0&&f.push({label:"Yesterday",sessions:s}),a.length>0&&f.push({label:"Past week",sessions:a}),l.length>0&&f.push({label:"Past month",sessions:l}),c.length>0&&f.push({label:"Older",sessions:c}),f}var hl=Ue(Xe(),1),cGe=Ue(x5(),1);var Iy={modalBackdrop:"ut",modalContent:"ht",modalHeader:"xt",modalTitle:"ft",closeButton:"be",closeIcon:"vt",diffEditorContainer:"wt"};function dGe(){let{modalState:n,closeModal:e}=JZ(),t=(0,hl.useRef)(null),i=(0,hl.useRef)(null),o=(0,hl.useRef)({original:null,modified:null}),r=(0,hl.useCallback)(a=>{a.key==="Escape"&&(e(),a.preventDefault())},[e]),s=(0,hl.useCallback)(a=>{a.target===a.currentTarget&&e()},[e]);return(0,hl.useEffect)(()=>(n.isOpen&&(document.addEventListener("keydown",r,!0),document.body.style.overflow="hidden"),()=>{document.removeEventListener("keydown",r,!0),document.body.style.overflow=""}),[n.isOpen,r]),(0,hl.useEffect)(()=>{if(!t.current||!n.isOpen)return;let a=rd.createDiffEditor(t.current,{readOnly:!0,renderSideBySide:!0,renderOverviewRuler:!0,scrollBeyondLastLine:!1,minimap:{enabled:!1},automaticLayout:!0,theme:"vs-dark",fontSize:12,lineNumbers:"off",wordWrap:"on",wrappingIndent:"same",scrollbar:{vertical:"auto",horizontal:"auto"}});return i.current=a,()=>{a.dispose(),o.current.original&&o.current.original.dispose(),o.current.modified&&o.current.modified.dispose(),o.current={original:null,modified:null}}},[n.isOpen]),(0,hl.useEffect)(()=>{if(!i.current||!n.isOpen)return;let a=n.language||"plaintext";if(n.filePath&&(!n.language||n.language==="plaintext")){let l=rd.createModel("",void 0,AP.file(n.filePath));a=l.getLanguageId(),l.dispose()}o.current.original?(o.current.original.setValue(n.original),rd.setModelLanguage(o.current.original,a)):o.current.original=rd.createModel(n.original,a),o.current.modified?(o.current.modified.setValue(n.modified),rd.setModelLanguage(o.current.modified,a)):o.current.modified=rd.createModel(n.modified,a),i.current.setModel({original:o.current.original,modified:o.current.modified})},[n]),n.isOpen?cGe.default.createPortal(hl.default.createElement("div",{className:Iy.modalBackdrop,onClick:s},hl.default.createElement("div",{className:Iy.modalContent},hl.default.createElement("div",{className:Iy.modalHeader},hl.default.createElement("div",{className:Iy.modalTitle},n.filePath?`${n.filePath}`:"Diff View"),hl.default.createElement("button",{className:Iy.closeButton,onClick:e,"aria-label":"Close"},hl.default.createElement(bR,{className:Iy.closeIcon}))),hl.default.createElement("div",{ref:t,className:Iy.diffEditorContainer}))),document.body):null}var Li=Ue(Xe(),1);var Ro={container:"kt",baseState:"yt",authUrlState:"ue",signInSection:"zt",methodSelection:"Bt",fullWidthButton:"k",primary:"qt",noteBeneathButton:"Ft",error:"he",asciiArtContainer:"xe",externalLinkIcon:"fe",signingInState:"Ht",authUrlContainer:"Wt",authUrlInput:"It",copyButton:"Q",copyIcon:"St",codeInput:"Z",terminalNote:"ve",terminalLink:"_"};var IX=Ue(Xe(),1);function l1e(){let[n,e]=(0,IX.useState)(!0);return(0,IX.useEffect)(()=>{let t=()=>{let o=document.body.classList.contains("vscode-light");e(!o)};t();let i=new MutationObserver(t);return i.observe(document.body,{attributes:!0,attributeFilter:["class"]}),()=>i.disconnect()},[]),n}function uGe({context:n}){let[e,t]=(0,Li.useState)(!1),[i,o]=(0,Li.useState)(null),[r,s]=(0,Li.useState)(null),[a,l]=(0,Li.useState)(""),c=n.authStatus.value;async function d(f){t(!0),s(null);try{await n.login(f,p=>{s(p)})}catch(p){o(p instanceof Error?p.message:"Login failed")}finally{t(!1),s(null)}}function u(){t(!1),s(null),o(null),l("")}async function h(){if(!a.trim()){o("Please enter the OAuth code");return}try{await n.submitOAuthCode(a.trim()),l(""),s(null),t(!1)}catch(f){o(f instanceof Error?f.message:"Failed to submit OAuth code")}}return c?Li.default.createElement("div",{className:Ro.container},"Signed in"):e&&r?Li.default.createElement("div",{className:Ro.container},Li.default.createElement(Mkt,{authUrl:r,oauthCode:a,setOauthCode:l,handleSubmitOAuthCode:h,handleCancelLogin:u})):e?Li.default.createElement("div",{className:Ro.container},Li.default.createElement(Akt,{isSigningIn:!0,back:u})):Li.default.createElement("div",{className:Ro.container},Li.default.createElement(Pkt,{error:i,isLoggingIn:e,handleLogin:d,context:n}))}function Akt({isSigningIn:n,back:e}){return n?Li.default.createElement("div",{className:Ro.signingInState},Li.default.createElement("p",null,"Signing in\u2026"),Li.default.createElement("button",{className:Ro.fullWidthButton,onClick:e},"Back")):null}function Mkt({authUrl:n,oauthCode:e,setOauthCode:t,handleSubmitOAuthCode:i,handleCancelLogin:o}){return Li.default.createElement("div",{className:Ro.authUrlState},Li.default.createElement("h3",null,"Continue in browser"),Li.default.createElement("p",null,"If the browser didn't open, visit this URL:"),Li.default.createElement("div",{className:Ro.authUrlContainer},Li.default.createElement("input",{type:"text",readOnly:!0,value:n,className:Ro.authUrlInput,onClick:r=>r.currentTarget.select()}),Li.default.createElement("button",{className:Ro.copyButton,onClick:()=>{navigator.clipboard.writeText(n)},title:"Copy to clipboard"},Li.default.createElement(sie,{className:Ro.copyIcon}))),Li.default.createElement("p",null,"Or, paste your authorization code manually:"),Li.default.createElement("form",{className:Ro.codeInputContainer,onSubmit:i},Li.default.createElement("input",{type:"text",value:e,onChange:r=>t(r.target.value),placeholder:"012345",className:Ro.codeInput}),Li.default.createElement("input",{type:"submit",className:`${Ro.fullWidthButton} ${Ro.primary}`,onClick:()=>void i(),disabled:!e.trim(),value:"Continue"})),Li.default.createElement("button",{className:Ro.fullWidthButton,onClick:o},"Back"))}function Pkt({error:n,isLoggingIn:e,handleLogin:t,context:i}){let o=l1e(),r=i.assetUris.value?.["welcome-art"]?.[o?"dark":"light"]??"";return Li.default.createElement("div",{className:Ro.baseState},Li.default.createElement("div",{className:Ro.asciiArtContainer},Li.default.createElement("img",{alt:"Welcome to Claude Code",src:r})),Li.default.createElement("p",null,"Claude Code can be used with your Claude subscription or billed based on API usage through your Console account."),Li.default.createElement("p",null,"How do you want to log in?"),n&&Li.default.createElement("div",{className:Ro.error},n,Li.default.createElement("br",null),Li.default.createElement(N_,null)),Li.default.createElement("div",{className:Ro.methodSelection},Li.default.createElement("button",{className:`${Ro.fullWidthButton} ${Ro.primary}`,onClick:()=>t("claudeai"),disabled:e,title:"Use your Claude Pro, Team, or Enterprise subscription"},"Claude.ai Subscription"),Li.default.createElement("p",{className:Ro.noteBeneathButton},"Use your Claude Pro, Team, or Enterprise subscription"),Li.default.createElement("button",{className:`${Ro.fullWidthButton}`,onClick:()=>t("console"),disabled:e},"Anthropic Console"),Li.default.createElement("p",{className:Ro.noteBeneathButton},"Pay for API usage through your Console account"),Li.default.createElement("button",{className:`${Ro.fullWidthButton}`,onClick:()=>i.openURL("https://docs.claude.com/en/docs/claude-code/vs-code#using-third-party-providers"),disabled:e},"Bedrock, Foundry, or Vertex",Li.default.createElement(Okt,null)),Li.default.createElement("p",{className:Ro.noteBeneathButton},"Instructions on how to use API keys or third-party providers.")),Li.default.createElement("div",{className:Ro.terminalNote},Li.default.createElement("p",null,"Prefer the terminal experience?"," ",Li.default.createElement("a",{href:"#",onClick:s=>{s.preventDefault(),i.openClaudeInTerminal()},className:Ro.terminalLink},"Run ",Li.default.createElement("code",null,"claude")," in terminal"))))}var Okt=()=>Li.default.createElement("svg",{className:Ro.externalLinkIcon,width:"24",height:"24",viewBox:"0 0 24 24",fill:"none",xmlns:"http://www.w3.org/2000/svg"},Li.default.createElement("path",{d:"M10 6H6C4.89543 6 4 6.89543 4 8V18C4 19.1046 4.89543 20 6 20H16C17.1046 20 18 19.1046 18 18V14M14 4H20M20 4V10M20 4L10 14",strokeWidth:"2",strokeLinecap:"round",strokeLinejoin:"round"}));function hGe({sessions:n,context:e}){nf();let t=(0,dr.useRef)(null),[i,o]=(0,dr.useState)(!1),[r,s]=(0,dr.useState)(!1);return(0,dr.useEffect)(()=>{e.commandRegistry.registerAction({id:"new-conversation",label:"New conversation"},"Conversations",()=>{e.startNewConversationTab()||n.createSession()}),e.commandRegistry.registerAction({id:"resume-conversation",label:"Resume conversation"},"Conversations",()=>{o(!0)}),e.commandRegistry.registerAction({id:"clear-conversation",label:"Clear conversation"},"Conversations",()=>{n.createSession()}),e.commandRegistry.registerAction({id:"login",label:"Login"},"Settings",()=>{e.showLogin()}),window.IS_ANT&&e.commandRegistry.registerAction({id:"issue",label:"Submit model issue"},"Misc",()=>{let a=n.activeSession.value?.sessionId.value,l=[];a&&l.push("--resume",a),e.openClaudeInTerminal("/issue",l)})},[n,e]),e.isAuthenticated.value?dr.default.createElement(yKe,null,dr.default.createElement("div",{className:ru.root},dr.default.createElement("div",{className:ru.header},dr.default.createElement("button",{ref:t,className:ru.sessionsButton,onClick:()=>o(!i),title:"Past conversations"},dr.default.createElement("span",{className:ru.sessionsButtonContent},dr.default.createElement("span",{className:ru.sessionsButtonText},n.activeSession.value?.summary.value||"Past Conversations"),dr.default.createElement(_R,{className:ru.headerButtonIcon}))),dr.default.createElement("div",{className:ru.headerSpacer}),dr.default.createElement("button",{onClick:()=>{e.startNewConversationTab()||n.createSession()},title:"New Session",className:ru.headerButton},dr.default.createElement(uie,{className:ru.headerButtonIcon}))),dr.default.createElement("div",{className:ru.body},dr.default.createElement("div",{className:ru.content},n.activeSession.value&&dr.default.createElement("div",{className:ru.sessionBody},dr.default.createElement(oGe,{session:n.activeSession.value,context:e}))))),dr.default.createElement(aGe,{isOpen:i,onClose:()=>o(!1),sessions:n.sessionsByLastModified.value,activeSession:n.activeSession.value||null,onSessionClick:a=>{n.activeSession.value=a},buttonRef:t}),dr.default.createElement(rGe,{isOpen:r,onClose:()=>s(!1),onConfirm:async a=>{s(!1),await n.createSession({useWorktree:!0,worktreeName:a})}}),dr.default.createElement(dGe,null)):dr.default.createElement("div",{className:ru.root},dr.default.createElement(uGe,{context:e}))}var EX=class extends S5{constructor(t,i,o){super(i,o);this.api=t;this.state.value="connected",window.addEventListener("message",r=>{r.data.type==="from-extension"&&this.fromHost.enqueue(r.data.message)}),this.opened=this.requestInit()}opened;closed=new Promise(()=>{});send(t){this.api.postMessage(t)}close(){}};async function fGe({permissionRequest:n,session:e}){if(e.showNotification(`Claude is requesting permission to use ${n.toolName}`,"info",["View"],!0),n.toolName===Cy.toolName){let t=new AbortController;n.onResolved(()=>{t.abort()});let i=n.inputs,o=await e.openDiff(i.file_path,i.file_path,[{oldString:i.old_string,newString:i.new_string,replaceAll:!!i.replace_all}],!1,t.signal);o?n.accept({file_path:i.file_path,old_string:o[0].oldString,new_string:o[0].newString,replace_all:o[0].replaceAll}):n.reject("User cancelled the edit",!0)}else if(n.toolName===ky.toolName){let t=new AbortController;n.onResolved(()=>{t.abort()});let i=n.inputs,o=await e.openDiff(i.file_path,i.file_path,[{oldString:"",newString:i.content,replaceAll:!0}],!1,t.signal);o?n.accept({file_path:i.file_path,content:o[0].newString}):n.reject("User cancelled the write",!0)}else n.toolName,Ly.toolName}var TX=class{constructor(e){this.api=e}update(e){let i={...this.api.getState()||{},...e};this.api.setState(i)}get value(){return this.api.getState()||{}}};var Fkt=["Conversations","Manage Context","Settings","Slash Commands","Misc"],DX=class{sections=new Map;commandActions=new Map;constructor(){}registerAction(e,t,i){this.sections.has(t)||this.sections.set(t,[]);let o=this.sections.get(t),r=o.findIndex(s=>s.id===e.id);r!==-1?o[r]=e:o.push(e),t==="Slash Commands"&&o.sort((s,a)=>s.label.localeCompare(a.label)),t==="Settings"&&o.sort((s,a)=>{let l=s.id.includes("terminal-kickback-"),c=a.id.includes("terminal-kickback-");return l&&!c?1:!l&&c?-1:s.label.localeCompare(a.label)}),this.commandActions.set(e.id,i)}executeCommand(e){let t=this.commandActions.get(e);t&&t()}getCommandsBySection(){let e={};for(let t of Fkt)this.sections.has(t)&&(e[t]=this.sections.get(t));return e}};var NX=class{constructor(e,t,i){this.comms=e;this.atMentionEvents=t;this.viewSession=i}supportsSpeechRecognition=!1;currentSelection=Wi(void 0);get speechToTextEnabled(){return this.comms.connection.value?.config.value?.speechToTextEnabled??!1}get useCtrlEnterToSend(){return this.comms.connection.value?.config.value?.useCtrlEnterToSend??!1}authStatus=pa(()=>this.comms.connection.value?.authStatus.value);showTerminalBanner=Wi(!1);dismissedReviewUpsellBanner=Wi(!1);showReviewUpsellBanner=pa(()=>this.dismissedReviewUpsellBanner.value?!1:this.comms.connection.value?.config.value?.showReviewUpsellBanner??!1);forceLogin=Wi(!1);isAuthenticated=pa(()=>{if(this.forceLogin.value)return!1;if(this.authStatus.value!==null)return!0;let t=this.comms.connection.value;if(t){let i=t.claudeConfig.value;if(i)return!!(i.accountInfo.tokenSource&&i.accountInfo.tokenSource!=="none"||i.accountInfo.subscriptionType)}return!1});commandRegistry=new DX;fileOpener={open:(e,t)=>{let i=this.comms.connection.value;i&&i.openFile(e,t)},openContent:(e,t,i)=>{let o=this.comms.connection.value;return o?o.openContent(e,t,i):Promise.resolve(void 0)}};startNewConversationTab(e,t){let i=this.comms.connection.value;return i&&i.config.value?.openNewInTab?(i.startNewConversationTab(e,t),!0):!1}async forkConversation(e,t,i){let o=this.comms.connection.value;if(o){let r=o.config.value?.openNewInTab,s=await o.forkConversation(e,i);r?this.startNewConversationTab(t,s):this.viewSession(s,t)}return""}assetUris=Wi(void 0);renameTab=e=>{let t=this.comms.connection.value;return t&&t.config.value?.openNewInTab?(t.renameTab(e),!0):!1};openURL=e=>{let t=this.comms.connection.value;t&&t.openURL(e)};get platform(){return this.comms.connection.value?.config.value?.platform??"macos"}get marketplaceType(){return this.comms.connection.value?.config.value?.marketplaceType??"vscode"}async login(e,t){await(await this.comms.get()).login(e,t),this.forceLogin.value=!1}async showLogin(){let e=await this.comms.get();e.authStatus.value=null,this.forceLogin.value=!0}async submitOAuthCode(e){await(await this.comms.get()).submitOAuthCode(e)}openClaudeInTerminal(e,t,i){let o=this.comms.connection.value;o&&o.openClaudeInTerminal(e,t,i)}showClaudeTerminalSetting(){let e=this.comms.connection.value;e&&e.showClaudeTerminalSetting()}dismissTerminalBanner(){this.showTerminalBanner.value=!1;let e=this.comms.connection.value;e&&e.dismissTerminalBanner()}dismissReviewUpsellBanner(e){this.dismissedReviewUpsellBanner.value=!0;let t=this.comms.connection.value;t&&t.dismissReviewUpsellBanner(e)}safeFocus(e){this.comms.connection.value?.isVisible.value&&e.focus()}openConfig(e){let t=this.comms.connection.value;t&&t.openConfig(e)}openHelp(){let e=this.comms.connection.value;e&&e.openHelp()}};function Bkt(){let n=acquireVsCodeApi(),e=new TX(n),t=new nh,i=new nh,o=new EX(n,t,i),r=new C5(()=>o),s,a=new NX(r,t,async(u,h)=>{await s.activateSessionFromServer(u,h)});s=new T5(r,a);let l;e.value.sessionID&&(e.value.sessionUpdatedAt===void 0||Date.now()-e.value.sessionUpdatedAt<6e5)&&(l=e.value.sessionID),s.listSessions().then(()=>{let u=window.initialConfiguration;if(u?.initialSession)s.activateSessionFromServer(u.initialSession,u.initialPrompt);else if(l){let h=s.sessions.value.find(f=>f.sessionId.value===l);h?s.activeSession.value=h:s.createSession({isExplicit:!1})}else u?.initialPrompt&&s.createSession({isExplicit:!1}).then(h=>{h&&u.initialPrompt&&(h.initialPrompt.value=u.initialPrompt)})}),ou(()=>{let u=o.config.value?.openNewInTab,h=s.activeSession.value;if(!h){e.update({sessionID:void 0,sessionUpdatedAt:void 0});return}let f=h?.sessionId.value;e.update({sessionID:f,sessionUpdatedAt:u?void 0:Date.now()})});let c=window.initialConfiguration;!l&&!c?.initialSession&&!c?.initialPrompt&&s.createSession({isExplicit:!1}),s.onPermissionRequested(fGe),i.add(u=>{a.currentSelection.value=u}),o.opened.then(()=>{o.getCurrentSelection().then(u=>{a.currentSelection.value=u.selection,i.emit(u.selection)}).catch(u=>{console.warn("Failed to get initial selection:",u)}),o.getAssetUris().then(u=>{a.assetUris.value=u.assetUris}),a.showTerminalBanner.value=o.config.value?.showTerminalBanner||!1});let d=()=>{setTimeout(()=>{(!document.activeElement||document.activeElement===document.body)&&t.emit("")},0)};window.addEventListener("focus",d),document.body.addEventListener("keydown",u=>{let h=s.activeSession.value;if(!h||u.defaultPrevented)return;let f=document.querySelector('.PermissionRequest_permissionRequestContainer[tabindex="0"]');u.key==="Escape"&&!f&&!u.altKey&&!u.ctrlKey&&!u.metaKey&&!u.shiftKey&&(h.interrupt(),d())}),(0,pGe.createRoot)(document.querySelector("#root")).render(Z4.default.createElement(Z4.StrictMode,null,Z4.default.createElement(hGe,{sessions:s,context:a})))}Bkt(); /*! Bundled license information: react/cjs/react.production.min.js: (** * @license React * react.production.min.js * * Copyright (c) Facebook, Inc. and its affiliates. * * This source code is licensed under the MIT license found in the * LICENSE file in the root directory of this source tree. *) scheduler/cjs/scheduler.production.min.js: (** * @license React * scheduler.production.min.js * * Copyright (c) Facebook, Inc. and its affiliates. * * This source code is licensed under the MIT license found in the * LICENSE file in the root directory of this source tree. *) react-dom/cjs/react-dom.production.min.js: (** * @license React * react-dom.production.min.js * * Copyright (c) Facebook, Inc. and its affiliates. * * This source code is licensed under the MIT license found in the * LICENSE file in the root directory of this source tree. *) use-sync-external-store/cjs/use-sync-external-store-shim.production.js: (** * @license React * use-sync-external-store-shim.production.js * * Copyright (c) Meta Platforms, Inc. and affiliates. * * This source code is licensed under the MIT license found in the * LICENSE file in the root directory of this source tree. *) ieee754/index.js: (*! ieee754. BSD-3-Clause License. Feross Aboukhadijeh *) buffer/index.js: (*! * The buffer module from node.js, for the browser. * * @author Feross Aboukhadijeh * @license MIT *) react/cjs/react-jsx-runtime.production.min.js: (** * @license React * react-jsx-runtime.production.min.js * * Copyright (c) Facebook, Inc. and its affiliates. * * This source code is licensed under the MIT license found in the * LICENSE file in the root directory of this source tree. *) monaco-editor/esm/vs/base/browser/dompurify/dompurify.js: (*! @license DOMPurify 3.1.7 | (c) Cure53 and other contributors | Released under the Apache license 2.0 and Mozilla Public License 2.0 | github.com/cure53/DOMPurify/blob/3.1.7/LICENSE *) monaco-editor/esm/vs/basic-languages/abap/abap.js: monaco-editor/esm/vs/basic-languages/apex/apex.js: monaco-editor/esm/vs/basic-languages/azcli/azcli.js: monaco-editor/esm/vs/basic-languages/bat/bat.js: monaco-editor/esm/vs/basic-languages/bicep/bicep.js: monaco-editor/esm/vs/basic-languages/cameligo/cameligo.js: monaco-editor/esm/vs/basic-languages/clojure/clojure.js: monaco-editor/esm/vs/basic-languages/coffee/coffee.js: monaco-editor/esm/vs/basic-languages/cpp/cpp.js: monaco-editor/esm/vs/basic-languages/csharp/csharp.js: monaco-editor/esm/vs/basic-languages/csp/csp.js: monaco-editor/esm/vs/basic-languages/css/css.js: monaco-editor/esm/vs/basic-languages/cypher/cypher.js: monaco-editor/esm/vs/basic-languages/dart/dart.js: monaco-editor/esm/vs/basic-languages/dockerfile/dockerfile.js: monaco-editor/esm/vs/basic-languages/ecl/ecl.js: monaco-editor/esm/vs/basic-languages/elixir/elixir.js: monaco-editor/esm/vs/basic-languages/flow9/flow9.js: monaco-editor/esm/vs/basic-languages/fsharp/fsharp.js: monaco-editor/esm/vs/basic-languages/freemarker2/freemarker2.js: monaco-editor/esm/vs/basic-languages/go/go.js: monaco-editor/esm/vs/basic-languages/graphql/graphql.js: monaco-editor/esm/vs/basic-languages/handlebars/handlebars.js: monaco-editor/esm/vs/basic-languages/hcl/hcl.js: monaco-editor/esm/vs/basic-languages/html/html.js: monaco-editor/esm/vs/basic-languages/ini/ini.js: monaco-editor/esm/vs/basic-languages/java/java.js: monaco-editor/esm/vs/basic-languages/typescript/typescript.js: monaco-editor/esm/vs/basic-languages/javascript/javascript.js: monaco-editor/esm/vs/basic-languages/julia/julia.js: monaco-editor/esm/vs/basic-languages/kotlin/kotlin.js: monaco-editor/esm/vs/basic-languages/less/less.js: monaco-editor/esm/vs/basic-languages/lexon/lexon.js: monaco-editor/esm/vs/basic-languages/lua/lua.js: monaco-editor/esm/vs/basic-languages/liquid/liquid.js: monaco-editor/esm/vs/basic-languages/m3/m3.js: monaco-editor/esm/vs/basic-languages/markdown/markdown.js: monaco-editor/esm/vs/basic-languages/mdx/mdx.js: monaco-editor/esm/vs/basic-languages/mips/mips.js: monaco-editor/esm/vs/basic-languages/msdax/msdax.js: monaco-editor/esm/vs/basic-languages/mysql/mysql.js: monaco-editor/esm/vs/basic-languages/objective-c/objective-c.js: monaco-editor/esm/vs/basic-languages/pascal/pascal.js: monaco-editor/esm/vs/basic-languages/pascaligo/pascaligo.js: monaco-editor/esm/vs/basic-languages/perl/perl.js: monaco-editor/esm/vs/basic-languages/pgsql/pgsql.js: monaco-editor/esm/vs/basic-languages/php/php.js: monaco-editor/esm/vs/basic-languages/pla/pla.js: monaco-editor/esm/vs/basic-languages/postiats/postiats.js: monaco-editor/esm/vs/basic-languages/powerquery/powerquery.js: monaco-editor/esm/vs/basic-languages/powershell/powershell.js: monaco-editor/esm/vs/basic-languages/protobuf/protobuf.js: monaco-editor/esm/vs/basic-languages/pug/pug.js: monaco-editor/esm/vs/basic-languages/python/python.js: monaco-editor/esm/vs/basic-languages/qsharp/qsharp.js: monaco-editor/esm/vs/basic-languages/r/r.js: monaco-editor/esm/vs/basic-languages/razor/razor.js: monaco-editor/esm/vs/basic-languages/redis/redis.js: monaco-editor/esm/vs/basic-languages/redshift/redshift.js: monaco-editor/esm/vs/basic-languages/restructuredtext/restructuredtext.js: monaco-editor/esm/vs/basic-languages/ruby/ruby.js: monaco-editor/esm/vs/basic-languages/rust/rust.js: monaco-editor/esm/vs/basic-languages/sb/sb.js: monaco-editor/esm/vs/basic-languages/scala/scala.js: monaco-editor/esm/vs/basic-languages/scheme/scheme.js: monaco-editor/esm/vs/basic-languages/scss/scss.js: monaco-editor/esm/vs/basic-languages/shell/shell.js: monaco-editor/esm/vs/basic-languages/solidity/solidity.js: monaco-editor/esm/vs/basic-languages/sophia/sophia.js: monaco-editor/esm/vs/basic-languages/sparql/sparql.js: monaco-editor/esm/vs/basic-languages/sql/sql.js: monaco-editor/esm/vs/basic-languages/st/st.js: monaco-editor/esm/vs/basic-languages/systemverilog/systemverilog.js: monaco-editor/esm/vs/basic-languages/tcl/tcl.js: monaco-editor/esm/vs/basic-languages/twig/twig.js: monaco-editor/esm/vs/basic-languages/typespec/typespec.js: monaco-editor/esm/vs/basic-languages/vb/vb.js: monaco-editor/esm/vs/basic-languages/wgsl/wgsl.js: monaco-editor/esm/vs/basic-languages/xml/xml.js: monaco-editor/esm/vs/basic-languages/yaml/yaml.js: monaco-editor/esm/vs/language/css/cssMode.js: monaco-editor/esm/vs/language/html/htmlMode.js: monaco-editor/esm/vs/language/json/jsonMode.js: monaco-editor/esm/vs/language/typescript/tsMode.js: monaco-editor/esm/vs/language/typescript/monaco.contribution.js: monaco-editor/esm/vs/basic-languages/_.contribution.js: monaco-editor/esm/vs/basic-languages/abap/abap.contribution.js: monaco-editor/esm/vs/basic-languages/apex/apex.contribution.js: monaco-editor/esm/vs/basic-languages/azcli/azcli.contribution.js: monaco-editor/esm/vs/basic-languages/bat/bat.contribution.js: monaco-editor/esm/vs/basic-languages/bicep/bicep.contribution.js: monaco-editor/esm/vs/basic-languages/cameligo/cameligo.contribution.js: monaco-editor/esm/vs/basic-languages/clojure/clojure.contribution.js: monaco-editor/esm/vs/basic-languages/coffee/coffee.contribution.js: monaco-editor/esm/vs/basic-languages/cpp/cpp.contribution.js: monaco-editor/esm/vs/basic-languages/csharp/csharp.contribution.js: monaco-editor/esm/vs/basic-languages/csp/csp.contribution.js: monaco-editor/esm/vs/basic-languages/css/css.contribution.js: monaco-editor/esm/vs/basic-languages/cypher/cypher.contribution.js: monaco-editor/esm/vs/basic-languages/dart/dart.contribution.js: monaco-editor/esm/vs/basic-languages/dockerfile/dockerfile.contribution.js: monaco-editor/esm/vs/basic-languages/ecl/ecl.contribution.js: monaco-editor/esm/vs/basic-languages/elixir/elixir.contribution.js: monaco-editor/esm/vs/basic-languages/flow9/flow9.contribution.js: monaco-editor/esm/vs/basic-languages/fsharp/fsharp.contribution.js: monaco-editor/esm/vs/basic-languages/freemarker2/freemarker2.contribution.js: monaco-editor/esm/vs/basic-languages/go/go.contribution.js: monaco-editor/esm/vs/basic-languages/graphql/graphql.contribution.js: monaco-editor/esm/vs/basic-languages/handlebars/handlebars.contribution.js: monaco-editor/esm/vs/basic-languages/hcl/hcl.contribution.js: monaco-editor/esm/vs/basic-languages/html/html.contribution.js: monaco-editor/esm/vs/basic-languages/ini/ini.contribution.js: monaco-editor/esm/vs/basic-languages/java/java.contribution.js: monaco-editor/esm/vs/basic-languages/javascript/javascript.contribution.js: monaco-editor/esm/vs/basic-languages/julia/julia.contribution.js: monaco-editor/esm/vs/basic-languages/kotlin/kotlin.contribution.js: monaco-editor/esm/vs/basic-languages/less/less.contribution.js: monaco-editor/esm/vs/basic-languages/lexon/lexon.contribution.js: monaco-editor/esm/vs/basic-languages/lua/lua.contribution.js: monaco-editor/esm/vs/basic-languages/liquid/liquid.contribution.js: monaco-editor/esm/vs/basic-languages/m3/m3.contribution.js: monaco-editor/esm/vs/basic-languages/markdown/markdown.contribution.js: monaco-editor/esm/vs/basic-languages/mdx/mdx.contribution.js: monaco-editor/esm/vs/basic-languages/mips/mips.contribution.js: monaco-editor/esm/vs/basic-languages/msdax/msdax.contribution.js: monaco-editor/esm/vs/basic-languages/mysql/mysql.contribution.js: monaco-editor/esm/vs/basic-languages/objective-c/objective-c.contribution.js: monaco-editor/esm/vs/basic-languages/pascal/pascal.contribution.js: monaco-editor/esm/vs/basic-languages/pascaligo/pascaligo.contribution.js: monaco-editor/esm/vs/basic-languages/perl/perl.contribution.js: monaco-editor/esm/vs/basic-languages/pgsql/pgsql.contribution.js: monaco-editor/esm/vs/basic-languages/php/php.contribution.js: monaco-editor/esm/vs/basic-languages/pla/pla.contribution.js: monaco-editor/esm/vs/basic-languages/postiats/postiats.contribution.js: monaco-editor/esm/vs/basic-languages/powerquery/powerquery.contribution.js: monaco-editor/esm/vs/basic-languages/powershell/powershell.contribution.js: monaco-editor/esm/vs/basic-languages/protobuf/protobuf.contribution.js: monaco-editor/esm/vs/basic-languages/pug/pug.contribution.js: monaco-editor/esm/vs/basic-languages/python/python.contribution.js: monaco-editor/esm/vs/basic-languages/qsharp/qsharp.contribution.js: monaco-editor/esm/vs/basic-languages/r/r.contribution.js: monaco-editor/esm/vs/basic-languages/razor/razor.contribution.js: monaco-editor/esm/vs/basic-languages/redis/redis.contribution.js: monaco-editor/esm/vs/basic-languages/redshift/redshift.contribution.js: monaco-editor/esm/vs/basic-languages/restructuredtext/restructuredtext.contribution.js: monaco-editor/esm/vs/basic-languages/ruby/ruby.contribution.js: monaco-editor/esm/vs/basic-languages/rust/rust.contribution.js: monaco-editor/esm/vs/basic-languages/sb/sb.contribution.js: monaco-editor/esm/vs/basic-languages/scala/scala.contribution.js: monaco-editor/esm/vs/basic-languages/scheme/scheme.contribution.js: monaco-editor/esm/vs/basic-languages/scss/scss.contribution.js: monaco-editor/esm/vs/basic-languages/shell/shell.contribution.js: monaco-editor/esm/vs/basic-languages/solidity/solidity.contribution.js: monaco-editor/esm/vs/basic-languages/sophia/sophia.contribution.js: monaco-editor/esm/vs/basic-languages/sparql/sparql.contribution.js: monaco-editor/esm/vs/basic-languages/sql/sql.contribution.js: monaco-editor/esm/vs/basic-languages/st/st.contribution.js: monaco-editor/esm/vs/basic-languages/swift/swift.contribution.js: monaco-editor/esm/vs/basic-languages/systemverilog/systemverilog.contribution.js: monaco-editor/esm/vs/basic-languages/tcl/tcl.contribution.js: monaco-editor/esm/vs/basic-languages/twig/twig.contribution.js: monaco-editor/esm/vs/basic-languages/typescript/typescript.contribution.js: monaco-editor/esm/vs/basic-languages/typespec/typespec.contribution.js: monaco-editor/esm/vs/basic-languages/vb/vb.contribution.js: monaco-editor/esm/vs/basic-languages/wgsl/wgsl.contribution.js: monaco-editor/esm/vs/basic-languages/xml/xml.contribution.js: monaco-editor/esm/vs/basic-languages/yaml/yaml.contribution.js: monaco-editor/esm/vs/basic-languages/monaco.contribution.js: monaco-editor/esm/vs/language/css/monaco.contribution.js: monaco-editor/esm/vs/language/html/monaco.contribution.js: monaco-editor/esm/vs/language/json/monaco.contribution.js: (*!----------------------------------------------------------------------------- * Copyright (c) Microsoft Corporation. All rights reserved. * Version: 0.52.2(404545bded1df6ffa41ea0af4e8ddb219018c6c1) * Released under the MIT license * https://github.com/microsoft/monaco-editor/blob/main/LICENSE.txt *-----------------------------------------------------------------------------*) monaco-editor/esm/vs/basic-languages/swift/swift.js: (*!----------------------------------------------------------------------------- * Copyright (c) Microsoft Corporation. All rights reserved. * Version: 0.52.2(404545bded1df6ffa41ea0af4e8ddb219018c6c1) * Released under the MIT license * https://github.com/microsoft/monaco-editor/blob/main/LICENSE.txt *-----------------------------------------------------------------------------*) (*!--------------------------------------------------------------------------------------------- * Copyright (C) David Owens II, owensd.io. All rights reserved. *--------------------------------------------------------------------------------------------*) */