diff --git "a/code-server/extensions/ms-python.python-2023.16.0-universal/dist/extension.browser.js" "b/code-server/extensions/ms-python.python-2023.16.0-universal/dist/extension.browser.js" new file mode 100644--- /dev/null +++ "b/code-server/extensions/ms-python.python-2023.16.0-universal/dist/extension.browser.js" @@ -0,0 +1,3 @@ +/*! For license information please see extension.browser.js.LICENSE.txt */ +(()=>{var e={7164:(e,t,n)=>{"use strict";n.r(t),n.d(t,{AppInsightsCore:()=>z,BaseCore:()=>B,BaseTelemetryPlugin:()=>k.i,CoreUtils:()=>K.Tr,DiagnosticLogger:()=>m.AQ,ESPromise:()=>J,ESPromiseScheduler:()=>ne,EventHelper:()=>se.zB,EventLatency:()=>l,EventPersistence:()=>f,EventPropertyType:()=>d,EventsDiscardedReason:()=>oe.h,FullVersionString:()=>K.vs,InternalAppInsightsCore:()=>U,InternalBaseCore:()=>L,LoggingSeverity:()=>a,MinChannelPriorty:()=>re,NotificationManager:()=>j,PerfEvent:()=>v.zn,PerfManager:()=>v.Jk,ProcessTelemetryContext:()=>b.Vi,TraceLevel:()=>p,Undefined:()=>ue.jA,Utils:()=>K.cQ,ValueKind:()=>u,ValueSanitizer:()=>ie,Version:()=>K.Gf,_ExtendedInternalMessageId:()=>g,_InternalLogMessage:()=>m.lQ,_InternalMessageId:()=>c,__getRegisteredEvents:()=>ae.um,_logInternalMessage:()=>m.L4,_throwInternal:()=>m.kP,_warnToConsole:()=>m.jV,addEventHandler:()=>ae.Ib,addEventListeners:()=>ae.yw,addPageHideEventListener:()=>ae.TJ,addPageShowEventListener:()=>ae.nD,addPageUnloadEventListener:()=>ae.c9,areCookiesSupported:()=>w.p7,arrForEach:()=>s.tO,arrIndexOf:()=>s.UA,arrMap:()=>s.Mr,arrReduce:()=>s.Xz,attachEvent:()=>ae.pZ,cookieAvailable:()=>w.p7,createCookieMgr:()=>w.Nz,createEnumStyle:()=>o.By,createGuid:()=>K.cm,createProcessTelemetryContext:()=>b.CD,createTraceParent:()=>le.SU,createUniqueNamespace:()=>E.J,createUnloadHandlerContainer:()=>N.Y,dateNow:()=>s.m6,deleteCookie:()=>K.kT,detachEvent:()=>ae.pD,disableCookies:()=>K.oF,disallowsSameSiteNone:()=>w.UY,doPerf:()=>v.Lm,dumpObj:()=>y.eU,eventOff:()=>ae.QY,eventOn:()=>ae.XO,extend:()=>K.l7,findW3cTraceParent:()=>le.lq,formatTraceParent:()=>le.aR,generateW3CId:()=>se.DO,getCommonSchemaMetaData:()=>K.Vv,getConsole:()=>y.dr,getCookie:()=>K.ej,getCookieValue:()=>K.Do,getCrypto:()=>y.MX,getDocument:()=>y.Me,getExceptionName:()=>s.jj,getFieldValueType:()=>K.Sy,getGlobal:()=>C.Rd,getGlobalInst:()=>y.a8,getHistory:()=>y.s1,getIEVersion:()=>y.sA,getISOString:()=>s.Y6,getJSON:()=>y.xA,getLocation:()=>y.k$,getMsCrypto:()=>y.gz,getNavigator:()=>y.jW,getPerformance:()=>y.r,getSetValue:()=>s.qK,getTenantId:()=>K.jM,getTime:()=>K.hK,getWindow:()=>y.Jj,hasDocument:()=>y.Nv,hasHistory:()=>y.fE,hasJSON:()=>y.nS,hasNavigator:()=>y.d6,hasOwnProperty:()=>s.nr,hasWindow:()=>y.Ym,isArray:()=>s.kJ,isArrayValid:()=>K.JT,isBeaconsSupported:()=>y.MF,isBoolean:()=>s.jn,isChromium:()=>K.mJ,isDate:()=>s.J_,isDocumentObjectAvailable:()=>K.x9,isError:()=>s.VZ,isFetchSupported:()=>y.JO,isFunction:()=>s.mf,isIE:()=>y.w1,isLatency:()=>K.r7,isNotTruthy:()=>s.F,isNullOrUndefined:()=>s.le,isNumber:()=>s.hj,isObject:()=>s.Kn,isReactNative:()=>y.b$,isSampledFlag:()=>le.Pn,isString:()=>s.HD,isTruthy:()=>s.fQ,isTypeof:()=>s.Ym,isUint8ArrayAvailable:()=>K.IZ,isUndefined:()=>s.o8,isValidSpanId:()=>le.Lc,isValidTraceId:()=>le.jN,isValidTraceParent:()=>le.J6,isValueAssigned:()=>K.Sn,isValueKind:()=>K.oS,isWindowObjectAvailable:()=>K.dH,isXhrSupported:()=>y.Z3,mergeEvtNamespace:()=>ae.jU,newGuid:()=>se.GW,newId:()=>ce.pZ,normalizeJsName:()=>s.Gf,objCreate:()=>C.pu,objDefineAccessors:()=>s.l_,objForEachKey:()=>s.rW,objFreeze:()=>s.FL,objKeys:()=>s.FY,objSeal:()=>s.Xi,openXhr:()=>K.ot,optimizeObject:()=>s.Ax,parseTraceParent:()=>le.j_,perfNow:()=>se.Jj,proxyAssign:()=>s.cf,proxyFunctionAs:()=>s.Oi,proxyFunctions:()=>s.Vb,random32:()=>ce._l,randomValue:()=>ce.az,removeEventHandler:()=>ae.C1,removeEventListeners:()=>ae.nJ,removePageHideEventListener:()=>ae.C9,removePageShowEventListener:()=>ae.Yl,removePageUnloadEventListener:()=>ae.JA,safeGetCookieMgr:()=>w.JP,safeGetLogger:()=>m.vH,sanitizeProperty:()=>K.yj,setCookie:()=>K.d8,setEnableEnvMocks:()=>y.dI,setProcessTelemetryTimings:()=>K.if,setValue:()=>s.sO,strContains:()=>s._Q,strEndsWith:()=>s.Id,strFunction:()=>ue.cb,strObject:()=>ue.fK,strPrototype:()=>ue.hB,strStartsWith:()=>s.xe,strTrim:()=>s.nd,strUndefined:()=>ue.jA,throwError:()=>s._y,toISOString:()=>s.Y6,useXDomainRequest:()=>y.cp});var i,r=n(7421),o=n(951),s=n(4869),a=(0,o.By)({CRITICAL:1,WARNING:2}),c=(0,o.By)(((i={}).BrowserDoesNotSupportLocalStorage=0,i.BrowserCannotReadLocalStorage=1,i.BrowserCannotReadSessionStorage=2,i.BrowserCannotWriteLocalStorage=3,i.BrowserCannotWriteSessionStorage=4,i.BrowserFailedRemovalFromLocalStorage=5,i.BrowserFailedRemovalFromSessionStorage=6,i.CannotSendEmptyTelemetry=7,i.ClientPerformanceMathError=8,i.ErrorParsingAISessionCookie=9,i.ErrorPVCalc=10,i.ExceptionWhileLoggingError=11,i.FailedAddingTelemetryToBuffer=12,i.FailedMonitorAjaxAbort=13,i.FailedMonitorAjaxDur=14,i.FailedMonitorAjaxOpen=15,i.FailedMonitorAjaxRSC=16,i.FailedMonitorAjaxSend=17,i.FailedMonitorAjaxGetCorrelationHeader=18,i.FailedToAddHandlerForOnBeforeUnload=19,i.FailedToSendQueuedTelemetry=20,i.FailedToReportDataLoss=21,i.FlushFailed=22,i.MessageLimitPerPVExceeded=23,i.MissingRequiredFieldSpecification=24,i.NavigationTimingNotSupported=25,i.OnError=26,i.SessionRenewalDateIsZero=27,i.SenderNotInitialized=28,i.StartTrackEventFailed=29,i.StopTrackEventFailed=30,i.StartTrackFailed=31,i.StopTrackFailed=32,i.TelemetrySampledAndNotSent=33,i.TrackEventFailed=34,i.TrackExceptionFailed=35,i.TrackMetricFailed=36,i.TrackPVFailed=37,i.TrackPVFailedCalc=38,i.TrackTraceFailed=39,i.TransmissionFailed=40,i.FailedToSetStorageBuffer=41,i.FailedToRestoreStorageBuffer=42,i.InvalidBackendResponse=43,i.FailedToFixDepricatedValues=44,i.InvalidDurationValue=45,i.TelemetryEnvelopeInvalid=46,i.CreateEnvelopeError=47,i.CannotSerializeObject=48,i.CannotSerializeObjectNonSerializable=49,i.CircularReferenceDetected=50,i.ClearAuthContextFailed=51,i.ExceptionTruncated=52,i.IllegalCharsInName=53,i.ItemNotInArray=54,i.MaxAjaxPerPVExceeded=55,i.MessageTruncated=56,i.NameTooLong=57,i.SampleRateOutOfRange=58,i.SetAuthContextFailed=59,i.SetAuthContextFailedAccountName=60,i.StringValueTooLong=61,i.StartCalledMoreThanOnce=62,i.StopCalledWithoutStart=63,i.TelemetryInitializerFailed=64,i.TrackArgumentsNotSpecified=65,i.UrlTooLong=66,i.SessionStorageBufferFull=67,i.CannotAccessCookie=68,i.IdTooLong=69,i.InvalidEvent=70,i.FailedMonitorAjaxSetRequestHeader=71,i.SendBrowserInfoOnUserInit=72,i.PluginException=73,i.NotificationException=74,i.SnippetScriptLoadFailure=99,i.InvalidInstrumentationKey=100,i.CannotParseAiBlobValue=101,i.InvalidContentBlob=102,i.TrackPageActionEventFailed=103,i.FailedAddingCustomDefinedRequestContext=104,i.InMemoryStorageBufferFull=105,i.InstrumentationKeyDeprecation=106,i)),u=(0,o.By)({NotSet:0,Pii_DistinguishedName:1,Pii_GenericData:2,Pii_IPV4Address:3,Pii_IPv6Address:4,Pii_MailSubject:5,Pii_PhoneNumber:6,Pii_QueryString:7,Pii_SipAddress:8,Pii_SmtpAddress:9,Pii_Identity:10,Pii_Uri:11,Pii_Fqdn:12,Pii_IPV4AddressLegacy:13,CustomerContent_GenericContent:32}),l=(0,o.By)({Normal:1,CostDeferred:2,RealTime:3,Immediate:4}),d=(0,o.By)({Unspecified:0,String:1,Int32:2,UInt32:3,Int64:4,UInt64:5,Double:6,Bool:7,Guid:8,DateTime:9}),f=(0,o.By)({Normal:1,Critical:2}),p=(0,o.By)({NONE:0,ERROR:1,WARNING:2,INFORMATION:3}),g=(0,s.FL)((0,r.uc)((0,r.uc)({},c),(0,o.By)({AuthHandShakeError:501,AuthRedirectFail:502,BrowserCannotReadLocalStorage:503,BrowserCannotWriteLocalStorage:504,BrowserDoesNotSupportLocalStorage:505,CannotParseBiBlobValue:506,CannotParseDataAttribute:507,CVPluginNotAvailable:508,DroppedEvent:509,ErrorParsingAISessionCookie:510,ErrorProvidedChannels:511,FailedToGetCookies:512,FailedToInitializeCorrelationVector:513,FailedToInitializeSDK:514,InvalidContentBlob:515,InvalidCorrelationValue:516,SessionRenewalDateIsZero:517,SendPostOnCompleteFailure:518,PostResponseHandler:519,SDKNotInitialized:520}))),h=n(9141),m=n(9339),v=n(1782),y=n(9251),S=n(8145),C=n(175),T=n(6335),b=n(1030),_=n(9031),R=500;function D(e,t,n){t&&(0,s.kJ)(t)&&t[S.R5]>0&&(t=t.sort((function(e,t){return e[T.yi]-t[T.yi]})),(0,s.tO)(t,(function(e){e[T.yi]R&&r[S.MW](e)})),D(i,r,n)}return i}(g,r,e)),p){var o=(0,s.UA)(r,p);-1!==o&&r[S.cb](o,1),-1!==(o=(0,s.UA)(f,p))&&f[S.cb](o,1),p._setQueue(y)}else p=function(e,t){function n(){return(0,b.CD)(null,t[S.TC],t,null)}function i(e,t,n,i){var r=e?e[S.R5]+1:1;function o(){0==--r&&(i&&i(),i=null)}r>0&&(0,s.tO)(e,(function(e){if(e&&e.queue[S.R5]>0){var i=e.chain,s=t[S.zV](i);s[S.Fc](o),n(s)}else r--})),o()}var r=!1,o={identifier:"ChannelControllerPlugin",priority:R,initialize:function(t,n,i,o){r=!0,(0,s.tO)(e,(function(e){e&&e.queue[S.R5]>0&&(0,_.bP)((0,b.CD)(e.chain,t,n),i)}))},isInitialized:function(){return r},processTelemetry:function(t,r){i(e,r||n(),(function(e){e[S.uL](t)}),(function(){r[S.uL](t)}))},update:function(t,n){var r=n||{reason:0};return i(e,t,(function(e){e[S.uL](r)}),(function(){t[S.uL](r)})),!0},pause:function(){i(e,n(),(function(e){e.iterate((function(e){e.pause&&e.pause()}))}),null)},resume:function(){i(e,n(),(function(e){e.iterate((function(e){e.resume&&e.resume()}))}),null)},teardown:function(t,n){var o=n||{reason:0,isAsync:!1};return i(e,t,(function(e){e[S.uL](o)}),(function(){t[S.uL](o),r=!1})),!0},getChannel:function(t){var n=null;return e&&e[S.R5]>0&&(0,s.tO)(e,(function(e){if(e&&e.queue[S.R5]>0&&((0,s.tO)(e.queue,(function(e){if(e[S.pZ]===t)return n=e,-1})),n))return-1})),n},flush:function(t,r,o,s){var a=1,c=!1,u=null;function l(){a--,c&&0===a&&(u&&(clearTimeout(u),u=null),r&&r(c),r=null)}return s=s||5e3,i(e,n(),(function(e){e.iterate((function(e){if(e[S.kL]){a++;var n=!1;e[S.kL](t,(function(){n=!0,l()}),o)||n||(t&&null==u?u=setTimeout((function(){u=null,l()}),s):l())}}))}),(function(){c=!0,l()})),!0},_setQueue:function(t){e=t}};return o}(y,e);r[S.MW](p),f[S.MW](p),e[S.iC]=(0,_.AA)(r),p[S.VL](t,e,r),(0,_.bP)(z(),r),e[S.iC]=(0,s.FL)((0,_.AA)(f||[])).slice(),n&&function(t){var n=(0,b.xy)($(),e);e._updateHook&&!0===e._updateHook(n,t)||n[S.uL](t)}(n)}function B(t){var n,i=null,r=null;return(0,s.tO)(e[S.iC],(function(e){if(e[S.pZ]===t&&e!==p&&e!==L)return r=e,-1})),!r&&p&&(r=p.getChannel(t)),r&&((n={plugin:r})[S.$h]=function(e){(0,_.OY)(r)[T.mE]=!e},n.isEnabled=function(){var e=(0,_.OY)(r);return!e[S.fi]&&!e[T.mE]},n.remove=function(e,t){var n;void 0===e&&(e=!0);var i=[r],o=((n={reason:1})[S.d]=e,n);G(i,o,(function(e){e&&V({reason:32,removed:i}),t&&t(e)}))},i=n),i}function $(){if(!l){var n=(f||[]).slice();-1===(0,s.UA)(n,L)&&n[S.MW](L),l=(0,b.jV)((0,_.AA)(n),t,e)}return l}function G(n,i,r){if(n&&n[S.R5]>0){var o=(0,b.jV)(n,t,e),a=(0,b.Bt)(o,e);a[S.Fc]((function(){var e=!1,t=[];(0,s.tO)(d,(function(i,r){M(i,n)?e=!0:t[S.MW](i)})),d=t;var i=[];g&&((0,s.tO)(g,(function(t,r){var o=[];(0,s.tO)(t,(function(t){M(t,n)?e=!0:o[S.MW](t)})),i[S.MW](o)})),g=i),r&&r(e)})),a[S.uL](i)}else r(!1)}function J(){var n=e[S.eZ]?e[S.eZ].queue:[];n&&((0,s.tO)(n,(function(n){var i,r=((i={})[S.I]=q||"InternalMessageId: "+n[S.Gc],i.iKey=(0,s.v4)(t[S.p$]),i.time=(0,s.Y6)(new Date),i.baseType=m.lQ.dataType,i.baseData={message:n[S.gU]},i);e.track(r)})),n[S.R5]=0)}function Y(e,t,n,i){return p?p[S.kL](e,t,n||6,i):(t&&t(!1),!0)}function Z(t){var n=e[S.eZ];n?(0,m.kP)(n,2,73,t):(0,s._y)(t)}h(),e[S.yl]=function(){return n},e[S.VL]=function(i,a,u,l){var f,p;k&&(0,s._y)(I),e[S.yl]()&&(0,s._y)("Core should not be initialized more than once"),t=i||{},e[S.TC]=t,(0,s.le)(i[S.p$])&&(0,s._y)("Please provide instrumentation key"),o=l,e._notificationManager=l,!0===(p=(0,s.v4)(t.disableDbgExt))&&H&&(o[S.n7](H),H=null),o&&!H&&!0!==p&&(H=(0,P.p)(t),o[S.g](H)),!(f=(0,s.v4)(t.enablePerfMgr))&&c&&(c=null),f&&(0,s.qK)(t,T.DN,F),(0,s.qK)(t,T.Zh,{}).NotificationManager=o,u&&(e[S.eZ]=u);var h=(0,s.qK)(t,T.js,[]);(d=[])[S.MW].apply(d,(0,r.$h)((0,r.$h)([],a,!1),h,!1)),g=(0,s.qK)(t,T.Z,[]),V(null),y&&0!==y[S.R5]||(0,s._y)("No "+T.Z+" available"),n=!0,e.releaseQueue()},e.getTransmissionControls=function(){var e=[];return y&&(0,s.tO)(y,(function(t){e[S.MW](t.queue)})),(0,s.FL)(e)},e.track=function(n){n.iKey=n.iKey||t[S.p$],n[S.Z_]=n[S.Z_]||(0,s.Y6)(new Date),n.ver=n.ver||"4.0",!k&&e[S.yl]()?z()[S.uL](n):i[S.MW](n)},e[S.SD]=z,e[S.tb]=function(){return o||(o=function(){var e;return(0,C.pu)(((e={})[S.g]=function(e){},e[S.n7]=function(e){},e[T.uC]=function(e){},e[T.$F]=function(e,t){},e[T.f_]=function(e,t){},e))}(),e._notificationManager=o),o},e[S.g]=function(e){o&&o[S.g](e)},e[S.n7]=function(e){o&&o[S.n7](e)},e.getCookieMgr=function(){return u||(u=(0,w.Nz)(t,e[S.eZ])),u},e.setCookieMgr=function(e){u=e},e[T.kl]=function(){if(!a&&!c&&(0,s.v4)(t.enablePerfMgr)){var n=(0,s.v4)(t[T.DN]);(0,s.mf)(n)&&(c=n(e,e[S.tb]()))}return a||c||(0,v.j5)()},e.setPerfMgr=function(e){a=e},e.eventCnt=function(){return i[S.R5]},e.releaseQueue=function(){if(n&&i[S.R5]>0){var e=i;i=[],(0,s.tO)(e,(function(e){z()[S.uL](e)}))}},e.pollInternalLogs=function(e){q=e||null;var n=(0,s.v4)(t.diagnosticLogInterval);return n&&n>0||(n=1e4),W&&clearInterval(W),W=setInterval((function(){J()}),n)},e[S.LS]=function(){W&&(clearInterval(W),W=0,J())},(0,s.Vb)(e,(function(){return L}),["addTelemetryInitializer"]),e.unload=function(t,i,r){var o;void 0===t&&(t=!0),n||(0,s._y)("SDK is not initialized"),k&&(0,s._y)(I);var a=((o={reason:50})[S.d]=t,o.flushComplete=!1,o),c=(0,b.Bt)($(),e);function u(t){a.flushComplete=t,k=!0,U.run(c,a),e[S.LS](),c[S.uL](a)}c[S.Fc]((function(){h(),i&&i(a)}),e),Y(t,u,6,r)||u(!1)},e[S.TO]=B,e.addPlugin=function(e,t,n,i){if(!e)return i&&i(!1),void Z(O);var r=B(e[S.pZ]);if(r&&!t)return i&&i(!1),void Z("Plugin ["+e[S.pZ]+"] is already loaded!");var o={reason:16};function s(t){d[S.MW](e),o.added=[e],V(o),i&&i(!0)}if(r){var a=[r.plugin];G(a,{reason:2,isAsync:!!n},(function(e){e?(o.removed=a,o.reason|=32,s()):i&&i(!1)}))}else s()},e.evtNamespace=function(){return j},e[S.kL]=Y,e.getTraceCtx=function(e){return K||(K=(0,_.Yn)()),K},e.setTraceCtx=function(e){K=e||null},(0,s.Oi)(e,"addUnloadCb",(function(){return U}),"add")}))}return e.__ieDyn=1,e}();function q(e,t,n,i){(0,s.tO)(e,(function(e){if(e&&e[t])if(n)setTimeout((function(){return i(e)}),0);else try{i(e)}catch(e){}}))}var j=function(){function e(t){this.listeners=[];var n=!!(t||{}).perfEvtsSendAll;(0,h.Z)(e,this,(function(e){e[S.g]=function(t){e.listeners[S.MW](t)},e[S.n7]=function(t){for(var n=(0,s.UA)(e[S.dE],t);n>-1;)e.listeners[S.cb](n,1),n=(0,s.UA)(e[S.dE],t)},e[T.uC]=function(t){q(e[S.dE],T.uC,!0,(function(e){e[T.uC](t)}))},e[T.$F]=function(t,n){q(e[S.dE],T.$F,!0,(function(e){e[T.$F](t,n)}))},e[T.f_]=function(t,n){q(e[S.dE],T.f_,n,(function(e){e[T.f_](t,n)}))},e[T.C$]=function(t){t&&(!n&&t[S.PL]()||q(e[S.dE],T.C$,!1,(function(e){t[S.d]?setTimeout((function(){return e[T.C$](t)}),0):e[T.C$](t)})))}}))}return e.__ieDyn=1,e}(),U=function(e){function t(){var n=e.call(this)||this;return(0,h.Z)(t,n,(function(e,t){function n(t){var n=e[S.tb]();n&&n[T.$F]([t],2)}e[S.VL]=function(e,n,i,r){t[S.VL](e,n,i||new m.AQ(e),r||new j(e))},e.track=function(i){(0,v.Lm)(e[T.kl](),(function(){return"AppInsightsCore:track"}),(function(){null===i&&(n(i),(0,s._y)("Invalid telemetry item")),function(e){(0,s.le)(e[S.I])&&(n(e),(0,s._y)("telemetry name required"))}(i),t.track(i)}),(function(){return{item:i}}),!i.sync)}})),n}return(0,r.ne)(t,e),t.__ieDyn=1,t}(L),H=n(1539),K=n(5705),W=function(e){function t(){var n=e.call(this)||this;return n.pluginVersionStringArr=[],(0,h.Z)(t,n,(function(e,t){e.logger&&e.logger.queue||(e.logger=new m.AQ({loggingLevelConsole:1})),e.initialize=function(n,i,r,o){(0,v.Lm)(e,(function(){return"AppInsightsCore.initialize"}),(function(){var a=e.pluginVersionStringArr;if(n){n.endpointUrl||(n.endpointUrl=H.YT);var c=n.propertyStorageOverride;!c||c.getProperty&&c.setProperty||(0,s._y)("Invalid property storage override passed."),n.channels&&(0,s.tO)(n.channels,(function(e){e&&(0,s.tO)(e,(function(e){if(e.identifier&&e.version){var t=e.identifier+"="+e.version;a.push(t)}}))}))}e.getWParam=function(){return"undefined"!=typeof document||n.enableWParam?0:-1},i&&(0,s.tO)(i,(function(e){if(e&&e.identifier&&e.version){var t=e.identifier+"="+e.version;a.push(t)}})),e.pluginVersionString=a.join(";"),e.pluginVersionStringArr=a;try{t.initialize(n,i,r,o),e.pollInternalLogs("InternalLog")}catch(t){var u=e.logger,l=(0,y.eU)(t);-1!==l.indexOf("channels")&&(l+="\n - Channels must be provided through config.channels only!"),(0,m.kP)(u,1,514,"SDK Initialization Failed - no telemetry will be sent: "+l)}}),(function(){return{config:n,extensions:i,logger:r,notificationManager:o}}))},e.track=function(n){(0,v.Lm)(e,(function(){return"AppInsightsCore.track"}),(function(){var i=n;if(i){i.timings=i.timings||{},i.timings.trackStart=(0,K.hK)(),(0,K.r7)(i.latency)||(i.latency=1);var r=i.ext=i.ext||{};r.sdk=r.sdk||{},r.sdk.ver=K.vs;var o=i.baseData=i.baseData||{};o[H.o6]=o[H.o6]||{};var s=o[H.o6];s[H.p8]=s[H.p8]||e.pluginVersionString||H.qS}t.track(i)}),(function(){return{item:n}}),!n.sync)}})),n}return(0,r.ne)(t,e),t.__ieDyn=1,t}(U);const z=W;var V=function(e){function t(){var n=e.call(this)||this;return(0,h.Z)(t,n,(function(e,t){e.initialize=function(n,i,r,o){n&&!n.endpointUrl&&(n.endpointUrl=H.YT),e.getWParam=function(){return K.x9||n.enableWParam?0:-1};try{t.initialize(n,i,r,o)}catch(t){(0,m.kP)(e.logger,1,514,"Initialization Failed: "+(0,y.eU)(t)+"\n - Note: Channels must be provided through config.channels only")}},e.track=function(e){var n=e;if(n){var i=n.ext=n.ext||{};i.sdk=i.sdk||{},i.sdk.ver=K.vs}t.track(n)}})),n}return(0,r.ne)(t,e),t.__ieDyn=1,t}(L);const B=V;var $=s.mf;function G(e,t,n){return function(i){e[t]=i,n()}}const J=function(){function e(t){var n=0,i=null,r=[];function o(){if(r.length>0){var e=r.slice();r=[],setTimeout((function(){for(var t=0,n=e.length;t")+"."+Z;function o(e){var t=(0,C.Rd)();t&&t.QUnit&&Y&&Y.log("ESPromiseScheduler["+r+"] "+e)}function s(e){(0,m.jV)(n,"ESPromiseScheduler["+r+"] "+e)}Z++,(0,h.Z)(e,this,(function(e){var t=null,n=0;function a(e,t){for(var n=0;n0){for(var c=0;c{"use strict";n.d(t,{YT:()=>r,o6:()=>s,p8:()=>o,qS:()=>i});var i="",r="https://browser.events.data.microsoft.com/OneCollector/1.0/",o="version",s="properties"},5705:(e,t,n)=>{"use strict";n.d(t,{Do:()=>x,Gf:()=>p,IZ:()=>b,JT:()=>F,Sn:()=>C,Sy:()=>L,Tr:()=>j,Vv:()=>D,cQ:()=>q,cm:()=>N,d8:()=>E,dH:()=>S,ej:()=>k,hK:()=>I,if:()=>M,jM:()=>T,kT:()=>P,l7:()=>O,mJ:()=>U,oF:()=>w,oS:()=>A,ot:()=>H,r7:()=>_,vs:()=>g,x9:()=>y,yj:()=>R});var i,r=n(9251),o=n(4869),s=n(8140),a=n(8956),c=n(1550),u=n(7954),l=n(9406),d=n(175),f=n(1539),p="3.2.9",g="1DS-Web-JS-"+p,h="withCredentials",m=((i={})[0]=0,i[2]=6,i[1]=1,i[3]=7,i[4098]=6,i[4097]=1,i[4099]=7,i),v=null,y=Boolean((0,r.Me)()),S=Boolean((0,r.Jj)());function C(e){return!(e===f.qS||(0,o.le)(e))}function T(e){if(e){var t=e.indexOf("-");if(t>-1)return e.substring(0,t)}return f.qS}function b(){return null===v&&(v=!(0,o.o8)(Uint8Array)&&!function(){var e=(0,r.jW)();if(!(0,o.o8)(e)&&e.userAgent){var t=e.userAgent.toLowerCase();if((t.indexOf("safari")>=0||t.indexOf("firefox")>=0)&&t.indexOf("chrome")<0)return!0}return!1}()&&!(0,r.b$)()),v}function _(e){return!!(e&&(0,o.hj)(e)&&e>=1&&e<=4)}function R(e,t,n){if(!t&&!C(t)||"string"!=typeof e)return null;var i=typeof t;if("string"===i||"number"===i||"boolean"===i||(0,o.kJ)(t))t={value:t};else if("object"!==i||c.CY.call(t,"value")){if((0,o.le)(t.value)||t.value===f.qS||!(0,o.HD)(t.value)&&!(0,o.hj)(t.value)&&!(0,o.jn)(t.value)&&!(0,o.kJ)(t.value))return null}else t={value:n?JSON.stringify(t):t};if((0,o.kJ)(t.value)&&!F(t.value))return null;if(!(0,o.le)(t.kind)){if((0,o.kJ)(t.value)||!A(t.kind))return null;t.value=t.value.toString()}return t}function D(e,t,n){var i=-1;if(!(0,o.o8)(e))if(t>0&&(32===t?i=8192:t<=13&&(i=t<<5)),function(e){return e>=0&&e<=9}(n))-1===i&&(i=0),i|=n;else{var r=m[L(e)]||-1;-1!==i&&-1!==r?i|=r:6===r&&(i=r)}return i}function w(){(0,s.JP)(null).setEnabled(!1)}function E(e,t,n){(0,s.p7)(null)&&(0,s.JP)(null).set(e,t,86400*n,null,"/")}function P(e){(0,s.p7)(null)&&(0,s.JP)(null).del(e)}function k(e){return(0,s.p7)(null)?x((0,s.JP)(null),e):f.qS}function x(e,t,n){var i;return void 0===n&&(n=!0),e&&(i=e.get(t),n&&i&&decodeURIComponent&&(i=decodeURIComponent(i))),i||f.qS}function N(e){void 0===e&&(e="D");var t=(0,a.GW)();return"B"===e?t="{"+t+"}":"P"===e?t="("+t+")":"N"===e&&(t=t.replace(/-/g,f.qS)),t}function O(e,t,n,i,r){var s={},a=!1,u=0,l=arguments.length,d=Object[c.hB],f=arguments;for("[object Boolean]"===d.toString.call(f[0])&&(a=f[0],u++);u0&&e<=13||32===e}function F(e){return e.length>0}function M(e,t){var n=e;n.timings=n.timings||{},n.timings.processTelemetryStart=n.timings.processTelemetryStart||{},n.timings.processTelemetryStart[t]=I()}function L(e){var t=0;if(null!=e){var n=typeof e;"string"===n?t=1:"number"===n?t=2:"boolean"===n?t=3:n===c.fK&&(t=4,(0,o.kJ)(e)?(t=4096,e.length>0&&(t|=L(e[0]))):c.CY.call(e,"value")&&(t=8192|L(e.value)))}return t}var q={Version:p,FullVersionString:g,strUndefined:c.jA,strObject:c.fK,Undefined:c.jA,arrForEach:o.tO,arrIndexOf:o.UA,arrMap:o.Mr,arrReduce:o.Xz,objKeys:o.FY,toISOString:o.Y6,isReactNative:r.b$,isString:o.HD,isNumber:o.hj,isBoolean:o.jn,isFunction:o.mf,isArray:o.kJ,isObject:o.Kn,strTrim:o.nd,isDocumentObjectAvailable:y,isWindowObjectAvailable:S,isValueAssigned:C,getTenantId:T,isBeaconsSupported:r.MF,isUint8ArrayAvailable:b,isLatency:_,sanitizeProperty:R,getISOString:o.Y6,useXDomainRequest:r.cp,getCommonSchemaMetaData:D,cookieAvailable:s.p7,disallowsSameSiteNone:s.UY,setCookie:E,deleteCookie:P,getCookie:k,createGuid:N,extend:O,getTime:I,isValueKind:A,isArrayValid:F,objDefineAccessors:o.l_,addPageUnloadEventListener:u.c9,setProcessTelemetryTimings:M,addEventHandler:u.Ib,getFieldValueType:L,strEndsWith:o.Id,objForEachKey:o.rW},j={_canUseCookies:void 0,isTypeof:o.Ym,isUndefined:o.o8,isNullOrUndefined:o.le,hasOwnProperty:o.nr,isFunction:o.mf,isObject:o.Kn,isDate:o.J_,isArray:o.kJ,isError:o.VZ,isString:o.HD,isNumber:o.hj,isBoolean:o.jn,toISOString:o.Y6,arrForEach:o.tO,arrIndexOf:o.UA,arrMap:o.Mr,arrReduce:o.Xz,strTrim:o.nd,objCreate:d.pu,objKeys:o.FY,objDefineAccessors:o.l_,addEventHandler:u.Ib,dateNow:o.m6,isIE:r.w1,disableCookies:w,newGuid:a.GW,perfNow:a.Jj,newId:l.pZ,randomValue:l.az,random32:l._l,mwcRandomSeed:l.CN,mwcRandom32:l.F6,generateW3CId:a.DO};function U(){return!!(0,r.a8)("chrome")}function H(e,t,n,i,r,o){function s(e,t,n){try{e[t]=n}catch(e){}}void 0===i&&(i=!1),void 0===r&&(r=!1);var a=new XMLHttpRequest;return i&&s(a,"Microsoft_ApplicationInsights_BypassAjaxInstrumentation",i),n&&s(a,h,n),a.open(e,t,!r),n&&s(a,h,n),!r&&o&&s(a,"timeout",o),a}},1488:(e,t,n)=>{"use strict";n.r(t),n.d(t,{BE_PROFILE:()=>m,NRT_PROFILE:()=>h,PostChannel:()=>ie,RT_PROFILE:()=>g});var i=n(7421),r=n(9141),o=n(1782),s=n(7954),a=n(7624),c=n(5705),u=n(4869),l=n(9251),d=n(8452),f=n(9339),p=n(7951),g="REAL_TIME",h="NEAR_REAL_TIME",m="BEST_EFFORT",v="",y="POST",S="drop",C="requeue",T="application/x-json-stream",b="content-type",_="client-version",R="client-id",D="time-delta-to-apply-millis",w="upload-time",E="apikey",P="AuthMsaDeviceTicket",k="AuthXToken";function x(e){var t=(e.ext||{}).intweb;return t&&(0,c.Sn)(t.msfpc)?t.msfpc:null}function N(e){for(var t=null,n=0;null===t&&n(0,u.m6)()||(delete n[i],!1)}}))}return e.__ieDyn=1,e}();var F=n(1550);function M(e){var t,n=Math.floor(1200*Math.random())+2400;return t=Math.pow(2,e)*n,Math.min(t,6e5)}var L,q=2e6,j=Math.min(q,65e3),U=/\./,H=function(){function e(t,n,i,s){var a="baseData",l=!!s,d=n,f={};(0,r.Z)(e,this,(function(e){function n(e,t,r,o,s,a,p){(0,u.rW)(e,(function(e,g){var h=null;if(g||(0,c.Sn)(g)){var m=r,v=e,y=s,S=t;if(l&&!o&&U.test(e)){var C=e.split("."),T=C.length;if(T>1){y&&(y=y.slice());for(var b=0;b=7&&(n=(0,u.xe)(e,"ext.metadata")||(0,u.xe)(e,"ext.web")),f[e]=n),n}(m);if(h=!R&&d&&d.handleField(m,v)?d.value(m,v,g,i):(0,c.yj)(v,g,i)){var D=h.value;if(S[v]=D,a&&a(y,v,h),p&&"object"==typeof D&&!(0,u.kJ)(D)){var w=y;w&&(w=w.slice()).push(v),n(g,D,m+"."+v,o,w,a,p)}}}}))}e.createPayload=function(e,t,n,i,r,o){return{apiKeys:[],payloadBlob:v,overflow:null,sizeExceed:[],failedEvts:[],batches:[],numEvents:0,retryCnt:e,isTeardown:t,isSync:n,isBeacon:i,sendType:o,sendReason:r}},e.appendPayload=function(n,i,r){var s=n&&i&&!n.overflow;return s&&(0,o.Lm)(t,(function(){return"Serializer:appendPayload"}),(function(){for(var t=i.events(),o=n.payloadBlob,s=n.numEvents,a=!1,c=[],l=[],d=n.isBeacon,f=d?65e3:3984588,p=d?j:q,g=0,h=0;g=r){n.overflow=i.split(g);break}var v=e.getEventBlob(m);if(v&&v.length<=p){var y=v.length;if(o.length+y>f){n.overflow=i.split(g);break}o&&(o+="\n"),o+=v,++h>20&&(o.substr(0,1),h=0),a=!0,s++}else v?c.push(m):l.push(m),t.splice(g,1),g--}g++}if(c&&c.length>0&&n.sizeExceed.push(O.create(i.iKey(),c)),l&&l.length>0&&n.failedEvts.push(O.create(i.iKey(),l)),a){n.batches.push(i),n.payloadBlob=o,n.numEvents=s;var S=i.iKey();-1===(0,u.UA)(n.apiKeys,S)&&n.apiKeys.push(S)}}),(function(){return{payload:n,theBatch:{iKey:i.iKey(),evts:i.events()},max:r}})),s},e.getEventBlob=function(e){try{return(0,o.Lm)(t,(function(){return"Serializer.getEventBlob"}),(function(){var t={};t.name=e.name,t.time=e.time,t.ver=e.ver,t.iKey="o:"+(0,c.jM)(e.iKey);var i={},r=e.ext;r&&(t.ext=i,(0,u.rW)(r,(function(e,t){n(t,i[e]={},"ext."+e,!0,null,null,!0)})));var o=t.data={};o.baseType=e.baseType;var s=o.baseData={};return n(e.baseData,s,a,!1,[a],(function(e,t,n){K(i,e,t,n)}),!0),n(e.data,o,"data",!1,[],(function(e,t,n){K(i,e,t,n)}),!0),JSON.stringify(t)}),(function(){return{item:e}}))}catch(e){return null}}}))}return e.__ieDyn=1,e}();function K(e,t,n,i){if(i&&e){var r=(0,c.Vv)(i.value,i.kind,i.propertyType);if(r>-1){var o=e.metadata;o||(o=e.metadata={f:{}});var s=o.f;if(s||(s=o.f={}),t)for(var a=0;a0)for(var r=t.toLowerCase(),o=0;o0&&(i&&V[t]?(e.hdrs[V[t]]=n,e.useHdrs=!0):e.url+="&"+t+"="+n)}function Z(e,t){return t&&((0,u.hj)(t)?e=[t].concat(e):(0,u.kJ)(t)&&(e=t.concat(e))),e}$(P,P,!1),$(_,_),$(R,"Client-Id"),$(E,E),$(D,D),$(w,w),$(k,k);var X=function(){function e(t,n,i,s,a){this._responseHandlers=[];var d,p,g,h,m,C,P,k,x,N,O="?cors=true&"+b.toLowerCase()+"="+T,L=new A,q=!1,j=new I,U=!1,K=0,V=!0,$=[],X={},Q=[],ee=null,te=!1,ne=!1,ie=!1;(0,r.Z)(e,this,(function(e){var r=!0;function I(e,t){for(var n=0,i=null,r=0;null==i&&r0&&(l.headers=e.headers),fetch(o,l).then((function(e){var n={},i=v,r=e.headers;r&&r.forEach((function(e,t){n[t]=e})),e.body&&e.text().then((function(e){i=e})),c||(c=!0,se(t,e.status,n,i),ye(i))})).catch((function(e){c||(c=!0,se(t,0,{}))})),s&&!c&&(c=!0,se(t,200,{})),!c&&e.timeout>0&&a.set((function(){c||(c=!0,se(t,500,{}))}),e.timeout)}function oe(e,t,n){var i=e.urlString;function o(e,t,n){if(!e[n]&&t&&t.getResponseHeader){var i=t.getResponseHeader(n);i&&(e[n]=(0,u.nd)(i))}return e}function s(e,n){se(t,e.status,function(e){var t={};return e.getAllResponseHeaders?t=function(e){var t={};if((0,u.HD)(e)){var n=(0,u.nd)(e).split(/[\r\n]+/);(0,u.tO)(n,(function(e){if(e){var n=e.indexOf(": ");if(-1!==n){var i=(0,u.nd)(e.substring(0,n)).toLowerCase(),r=(0,u.nd)(e.substring(n+1));t[i]=r}else t[(0,u.nd)(e)]=1}}))}return t}(e.getAllResponseHeaders()):(t=o(t,e,"time-delta-millis"),t=o(t,e,"kill-duration"),t=o(t,e,"kill-duration-seconds")),t}(e),n)}n&&e.disableXhrSync&&(n=!1);var a=(0,c.ot)(y,i,r,!0,n,e.timeout);(0,u.rW)(e.headers,(function(e,t){a.setRequestHeader(e,t)})),a.onload=function(){var e=G(a);s(a,e),ye(e)},a.onerror=function(){s(a)},a.ontimeout=function(){s(a)},a.send(e.data)}function se(e,t,n,i){try{e(t,n,i)}catch(e){(0,f.kP)(p,2,518,(0,l.eU)(e))}}function ae(e,t,n){var i=200,r=e._thePayload,o=e.urlString+(N?W:v);try{var s=(0,l.jW)();if(!s.sendBeacon(o,e.data))if(r){var a=[];(0,u.tO)(r.batches,(function(e){if(a&&e&&e.count()>0){for(var t=e.events(),n=0;n0&&!q&&g[t]&&ee&&(i=0!==t||le()&&(n>0||j.allowRequestSending())),i}function pe(e){var t={};return e&&(0,u.tO)(e,(function(e,n){t[n]={iKey:e.iKey(),evts:e.events()}})),t}function ge(e,n,i,r,s){if(e&&0!==e.length)if(q)Se(e,1,r);else{r=ue(r);try{var a=e,u=0!==r;(0,o.Lm)(h,(function(){return"HttpManager:_sendBatches"}),(function(o){o&&(e=e.slice(0));for(var a=[],l=null,d=(0,c.hK)(),f=g[r]||(u?g[1]:g[0]),p=f&&f._transport,h=x&&(ne||ce(r)||3===p||f._isSync&&2===p);fe(e,r,n);){var m=e.shift();m&&m.count()>0&&(L.isTenantKilled(m.iKey())?a.push(m):(l=l||ee.createPayload(n,i,u,h,s,r),ee.appendPayload(l,m,t)?null!==l.overflow&&(e=[l.overflow].concat(e),l.overflow=null,me(l,d,(0,c.hK)(),s),d=(0,c.hK)(),l=null):(me(l,d,(0,c.hK)(),s),d=(0,c.hK)(),e=[m].concat(e),l=null)))}l&&me(l,d,(0,c.hK)(),s),e.length>0&&(Q=e.concat(Q)),Se(a,8004,r)}),(function(){return{batches:pe(a),retryCount:n,isTeardown:i,isSynchronous:u,sendReason:s,useSendBeacon:ce(r),sendType:r}}),!u)}catch(e){(0,f.kP)(p,2,48,"Unexpected Exception sending batch: "+(0,l.eU)(e))}}}function he(e,t,n){e[t]=e[t]||{},e[t][d.identifier]=n}function me(t,n,r,s){if(t&&t.payloadBlob&&t.payloadBlob.length>0){var a=!!e.sendHook,m=g[t.sendType];!ce(t.sendType)&&t.isBeacon&&2===t.sendReason&&(m=g[2]||g[3]||m);var y=ie;(t.isBeacon||3===m._transport)&&(y=!1);var S=function(e,t){var n={url:O,hdrs:{},useHdrs:!1};t?(n.hdrs=(0,c.l7)(n.hdrs,X),n.useHdrs=(0,u.FY)(n.hdrs).length>0):(0,u.rW)(X,(function(e,t){B[e]?Y(n,B[e],t,!1):(n.hdrs[e]=t,n.useHdrs=!0)})),Y(n,R,"NO_AUTH",t),Y(n,_,c.vs,t);var i=v;(0,u.tO)(e.apiKeys,(function(e){i.length>0&&(i+=","),i+=e})),Y(n,E,i,t),Y(n,w,(0,u.m6)().toString(),t);var r=function(e){for(var t=0;t=0&&(n.url+="&w="+o)}for(var s=0;s<$.length;s++)n.url+="&"+$[s].name+"="+$[s].value;return n}(t,y);y=y||S.useHdrs;var x=(0,c.hK)();(0,o.Lm)(h,(function(){return"HttpManager:_doPayloadSend"}),(function(){for(var g=0;g0?R.sendAttempt++:R.sendAttempt=1}Se(t.batches,1e3+(s||0),t.sendType,!0);var w={data:t.payloadBlob,urlString:S.url,headers:S.hdrs,_thePayload:t,_sendReason:s,timeout:C,disableXhrSync:P,disableFetchKeepAlive:k};y&&(J(w.headers,"cache-control")||(w.headers["cache-control"]="no-cache, no-store"),J(w.headers,b)||(w.headers["content-type"]=T));var E=null;m&&(E=function(n){j.firstRequestSent();var r=function(n,r){!function(t,n,r,o){var s,a=9e3,l=null,f=!1,p=!1;try{var g=!0;if(typeof t!==F.jA){if(n){j.setClockSkew(n["time-delta-millis"]);var h=n["kill-duration"]||n["kill-duration-seconds"];(0,u.tO)(L.setKillSwitchTenants(n["kill-tokens"],h),(function(e){(0,u.tO)(r.batches,(function(t){if(t.iKey()===e){l=l||[];var n=t.split(0);r.numEvents-=n.count(),l.push(n)}}))}))}if(200==t||204==t)return void(a=200);((s=t)>=300&&s<500&&408!=s&&429!=s||501==s||505==s||r.numEvents<=0)&&(g=!1),a=9e3+t%1e3}if(g){a=100;var m=r.retryCnt;0===r.sendType&&(m0&&function(e,t){te&&(0,u.tO)(e,(function(e){he(e.timings=e.timings||{},"sendEventCompleted",t)}))}(e.events(),t)}))}}(t.batches)),Se(t.batches,n,t.sendType,!0)}finally{0===t.sendType&&(K--,5!==i&&e.sendQueuedRequests(t.sendType,i))}}(r,a,o,p)),Se(l,8004,r.sendType)}}(n,r,t,s)},o=t.isTeardown||t.isSync;try{m.sendPOST(n,r,o),e.sendListener&&e.sendListener(w,n,o,t.isBeacon)}catch(e){(0,f.jV)(p,"Unexpected exception sending payload. Ex:"+(0,l.eU)(e)),se(r,0,{})}}),(0,o.Lm)(h,(function(){return"HttpManager:_doPayloadSend.sender"}),(function(){if(E)if(0===t.sendType&&K++,a&&!t.isBeacon&&3!==m._transport){var n={data:w.data,urlString:w.urlString,headers:(0,c.l7)({},w.headers),timeout:w.timeout,disableXhrSync:w.disableXhrSync,disableFetchKeepAlive:w.disableFetchKeepAlive},i=!1;(0,o.Lm)(h,(function(){return"HttpManager:_doPayloadSend.sendHook"}),(function(){try{e.sendHook(n,(function(e){i=!0,V||e._thePayload||(e._thePayload=e._thePayload||w._thePayload,e._sendReason=e._sendReason||w._sendReason),E(e)}),t.isSync||t.isTeardown)}catch(e){i||E(w)}}))}else E(w)}))}),(function(){return{thePayload:t,serializationStart:n,serializationCompleted:r,sendReason:s}}),t.isSync)}t.sizeExceed&&t.sizeExceed.length>0&&Se(t.sizeExceed,8003,t.sendType),t.failedEvts&&t.failedEvts.length>0&&Se(t.failedEvts,8002,t.sendType)}function ve(e,t,n){t?e():a.set(e,n)}function ye(t){var n=e._responseHandlers;try{for(var i=0;i0&&s){var r=s[(u=t,l=z[u],(0,c.Sn)(l)||(l="oth",u>=9e3&&u<=9999?l="rspFail":u>=8e3&&u<=8999?l=S:u>=1e3&&u<=1999&&(l="send")),l)];if(r){var a=0!==n;(0,o.Lm)(h,(function(){return"HttpManager:_sendBatchesNotification"}),(function(){ve((function(){try{r.call(s,e,t,a,n)}catch(e){(0,f.kP)(p,1,74,"send request notification failed: "+e)}}),i||a,0)}),(function(){return{batches:pe(e),reason:t,isSync:a,sendSync:i,sendType:n}}),!a)}}var u,l}e.initialize=function(e,t,n,i,o){var s;o||(o={}),O=e+O,ie=!!(0,u.o8)(o.avoidOptions)||!o.avoidOptions,h=t,m=t.getCookieMgr(),te=!h.config.disableEventTimings;var a=!!h.config.enableCompoundKey;p=(d=n).diagLog();var c=o.valueSanitizer,v=o.stringifyObjects;(0,u.o8)(o.enableCompoundKey)||(a=!!o.enableCompoundKey),C=o.xhrTimeout,P=!!o.disableXhrSync,k=!!o.disableFetchKeepAlive,N=!1!==o.addNoResponse,U=!(0,l.b$)(),ee=new H(h,c,v,a),(0,u.le)(o.useSendBeacon)||(U=!!o.useSendBeacon);var y=i,S=o.alwaysUseXhrOverride?i:null,T=o.alwaysUseXhrOverride?i:null,b=[3,2];if(!i){V=!1;var _=(0,l.k$)();_&&_.protocol&&"file:"===_.protocol.toLowerCase()&&(r=!1);var R=[];(0,l.b$)()?(R=[2,1],b=[2,1,3]):R=[1,2,3],(i=I(R=Z(R,o.transports),!1))||(0,f.jV)(p,"No available transport to send events"),y=I(R,!0)}S||(S=I(b=Z(b,o.unloadTransports),!0)),x=!V&&(U&&(0,l.MF)()||!k&&(0,l.JO)(!0)),(s={})[0]=i,s[1]=y||I([1,2,3],!0),s[2]=S||y||I([1],!0),s[3]=T||I([2,3],!0)||y||I([1],!0),g=s},e._getDbgPlgTargets=function(){return[g[0],L,ee,g]},e.addQueryStringParameter=function(e,t){for(var n=0;n<$.length;n++)if($[n].name===e)return void($[n].value=t);$.push({name:e,value:t})},e.addHeader=function(e,t){X[e]=t},e.canSendRequest=function(){return le()&&j.allowRequestSending()},e.sendQueuedRequests=function(e,t){(0,u.o8)(e)&&(e=0),ne&&(e=ue(e),t=2),fe(Q,e,0)&&ge(de(),0,!1,e,t||0)},e.isCompletelyIdle=function(){return!q&&0===K&&0===Q.length},e.setUnloading=function(e){ne=e},e.addBatch=function(e){if(e&&e.count()>0){if(L.isTenantKilled(e.iKey()))return!1;Q.push(e)}return!0},e.teardown=function(){Q.length>0&&ge(de(),0,!0,2,2)},e.pause=function(){q=!0},e.resume=function(){q=!1,e.sendQueuedRequests(0,4)},e.sendSynchronousBatch=function(e,t,n){e&&e.count()>0&&((0,u.le)(t)&&(t=1),ne&&(t=ue(t),n=2),ge([e],0,!1,t,n||0))}}))}return e.__ieDyn=1,e}();function Q(e,t){for(var n=[],i=2;i0){var o=r.split(0,i),s=o.count();if(s>0)return 4===n?E-=s:x-=s,ge(ne,[o],d.h.QueueFull),!0}n++}return se(),!1}(e.iKey,e.latency,s,a)&&(o=!oe(e,t))}o&&pe(ne,[e],d.h.QueueFull)}function $(e,t,n){var i=ae(e,t,n);return v.sendQueuedRequests(t,n),i}function G(){return x>0}function J(){if(H>=0&&ae(H,0,C)&&v.sendQueuedRequests(0,C),E>0&&!L&&!w){var e=I[A][2];e>=0&&(L=Z((function(){L=null,$(4,0,1),J()}),e))}var t=I[A][1];!F&&!D&&t>=0&&!w&&(G()?F=Z((function(){F=null,$(0===j?3:1,0,1),j++,j%=2,J()}),t):j=0)}function Y(){n=null,_=!1,R=[],D=null,w=!1,E=0,k=500,x=0,N=1e4,I={},A=g,F=null,L=null,q=0,j=0,p=null,U={},y=void 0,S=0,H=-1,C=null,K=!0,W=!1,z=6,V=2,T=null,b=te(),v=new X(500,2,1,{requeue:de,send:he,sent:me,drop:ve,rspFail:ye,oth:Se},b),le(),U[4]={batches:[],iKeyMap:{}},U[3]={batches:[],iKeyMap:{}},U[2]={batches:[],iKeyMap:{}},U[1]={batches:[],iKeyMap:{}},Ce()}function Z(e,t){0===t&&q&&(t=1);var n=1e3;return q&&(n=M(q-1)),b.set(e,t*n)}function Q(){return null!==F&&(b.clear(F),F=null,j=0,!0)}function ee(e,t){Q(),D&&(b.clear(D),D=null),w||$(1,e,t)}function ie(e,t,n){var i=U[t];i||(i=U[t=1]);var r=i.iKeyMap[e];return!r&&n&&(r=O.create(e),i.batches.push(r),i.iKeyMap[e]=r),r}function re(t,n){v.canSendRequest()&&!q&&(y>0&&x>y&&(n=!0),n&&null==D&&e.flush(t,null,20))}function oe(e,t){K&&(e=(0,u.Ax)(e));var n=e.latency,i=ie(e.iKey,n,!0);return!!i.addEvent(e)&&(4!==n?(x++,t&&0===e.sendAttempt&&re(!e.sync,S>0&&i.count()>=S)):E++,!0)}function se(){for(var e=0,t=0,n=function(n){var i=U[n];i&&i.batches&&(0,u.tO)(i.batches,(function(i){4===n?e+=i.count():t+=i.count()}))},i=1;i<=4;i++)n(i);x=t,E=e}function ae(t,n,i){var r=!1,s=0===n;return!s||v.canSendRequest()?(0,o.Lm)(e.core,(function(){return"PostChannel._queueBatches"}),(function(){for(var e=[],n=4;n>=t;){var i=U[n];i&&i.batches&&i.batches.length>0&&((0,u.tO)(i.batches,(function(t){v.addBatch(t)?r=r||t&&t.count()>0:e=e.concat(t.events()),4===n?E-=t.count():x-=t.count()})),i.batches=[],i.iKeyMap={}),n--}e.length>0&&pe(ne,e,d.h.KillSwitch),r&&H>=t&&(H=-1,C=0)}),(function(){return{latency:t,sendType:n,sendReason:i}}),!s):(H=H>=0?Math.min(H,t):t,C=Math.max(C,i)),r}function ce(e,t){$(1,0,t),se(),ue((function(){e&&e(),R.length>0?D=Z((function(){D=null,ce(R.shift(),t)}),0):(D=null,J())}))}function ue(e){v.isCompletelyIdle()?e():D=Z((function(){D=null,ue(e)}),.25)}function le(){(I={})[g]=[2,1,0],I[h]=[6,3,0],I[m]=[18,9,0]}function de(t,n){var i=[],r=z;W&&(r=V),(0,u.tO)(t,(function(t){t&&t.count()>0&&(0,u.tO)(t.events(),(function(t){t&&(t.sync&&(t.latency=4,t.sync=!1),t.sendAttempt0&&pe(ne,i,d.h.NonRetryableStatus),W&&ee(2,2)}function fe(t,n){var i=e._notificationManager||{},r=i[t];if(r)try{r.apply(i,n)}catch(n){(0,f.kP)(e.diagLog(),1,74,t+" notification failed: "+n)}}function pe(e,t){for(var n=[],i=2;i0&&fe(e,[t].concat(n))}function ge(e,t){for(var n=[],i=2;i0&&(0,u.tO)(t,(function(t){t&&t.count()>0&&fe(e,[t.events()].concat(n))}))}function he(e,t,n){e&&e.length>0&&fe("eventsSendRequest",[t>=1e3&&t<=1999?t-1e3:0,!0!==n])}function me(e,t){ge("eventsSent",e,t),J()}function ve(e,t){ge(ne,e,t>=8e3&&t<=8999?t-8e3:d.h.Unknown)}function ye(e){ge(ne,e,d.h.NonRetryableStatus),J()}function Se(e,t){ge(ne,e,d.h.Unknown),J()}function Ce(){S=n&&n.disableAutoBatchFlushLimit?0:Math.max(1500,N/6)}Y(),e._getDbgPlgTargets=function(){return[v]},e.initialize=function(l,d,f){(0,o.Lm)(d,(function(){return"PostChannel:initialize"}),(function(){var o=d;t.initialize(l,d,f);try{d.addUnloadCb,T=(0,s.jU)((0,a.J)(e.identifier),d.evtNamespace&&d.evtNamespace());var g=e._getTelCtx();l.extensionConfig[e.identifier]=l.extensionConfig[e.identifier]||{},n=g.getExtCfg(e.identifier),b=te(n.setTimeoutOverride,n.clearTimeoutOverride),K=!n.disableOptimizeObj&&(0,c.mJ)(),function(e){var t=e.getWParam;e.getWParam=function(){var e=0;return n.ignoreMc1Ms0CookieProcessing&&(e|=2),e|t()}}(o),n.eventsLimitInMem>0&&(N=n.eventsLimitInMem),n.immediateEventLimit>0&&(k=n.immediateEventLimit),n.autoFlushEventsLimit>0&&(y=n.autoFlushEventsLimit),(0,u.hj)(n.maxEventRetryAttempts)&&(z=n.maxEventRetryAttempts),(0,u.hj)(n.maxUnloadEventRetryAttempts)&&(V=n.maxUnloadEventRetryAttempts),Ce(),n.httpXHROverride&&n.httpXHROverride.sendPOST&&(p=n.httpXHROverride),(0,c.Sn)(l.anonCookieName)&&v.addQueryStringParameter("anoncknm",l.anonCookieName),v.sendHook=n.payloadPreprocessor,v.sendListener=n.payloadListener;var h=n.overrideEndpointUrl?n.overrideEndpointUrl:l.endpointUrl;e._notificationManager=d.getNotifyMgr(),v.initialize(h,e.core,e,p,n);var m=l.disablePageUnloadEvents||[];(0,s.c9)(i,m,T),(0,s.TJ)(i,m,T),(0,s.nD)(r,l.disablePageShowEvents,T)}catch(t){throw e.setInitialized(!1),t}}),(function(){return{coreConfig:l,core:d,extensions:f}}))},e.processTelemetry=function(t,i){(0,c.if)(t,e.identifier);var r=(i=e._getTelCtx(i)).getExtCfg(e.identifier),o=!!n.disableTelemetry;r&&(o=o||!!r.disableTelemetry);var s=t;o||_||(n.overrideInstrumentationKey&&(s.iKey=n.overrideInstrumentationKey),r&&r.overrideInstrumentationKey&&(s.iKey=r.overrideInstrumentationKey),B(s,!0),W?ee(2,2):J()),e.processNext(s,i)},e._doTeardown=function(e,t){ee(2,2),_=!0,v.teardown(),(0,s.JA)(null,T),(0,s.C9)(null,T),(0,s.Yl)(null,T),Y()},e.setEventQueueLimits=function(e,t){N=e>0?e:1e4,y=t>0?t:0,Ce();var n=x>e;if(!n&&S>0)for(var i=1;!n&&i<=3;i++){var r=U[i];r&&r.batches&&(0,u.tO)(r.batches,(function(e){e&&e.count()>=S&&(n=!0)}))}re(!0,n)},e.pause=function(){Q(),w=!0,v.pause()},e.resume=function(){w=!1,v.resume(),J()},e.addResponseHandler=function(e){v._responseHandlers.push(e)},e._loadTransmitProfiles=function(e){Q(),le(),A=g,J(),(0,u.rW)(e,(function(e,t){var n=t.length;if(n>=2){var i=n>2?t[2]:0;if(t.splice(0,n-2),t[1]<0&&(t[0]=-1),t[1]>0&&t[0]>0){var r=t[0]/t[1];t[0]=Math.ceil(r)*t[1]}i>=0&&t[1]>=0&&i>t[1]&&(i=t[1]),t.push(i),I[e]=t}}))},e.flush=function(e,t,n){if(void 0===e&&(e=!0),!w)if(n=n||1,e)null==D?(Q(),ae(1,0,n),D=Z((function(){D=null,ce(t,n)}),0)):R.push(t);else{var i=Q();$(1,1,n),null!=t&&t(),i&&J()}},e.setMsaAuthTicket=function(e){v.addHeader(P,e)},e.hasEvents=G,e._setTransmitProfile=function(e){A!==e&&void 0!==I[e]&&(Q(),A=e,J())},e._backOffTransmission=function(){q<4&&(q++,Q(),J())},e._clearBackOff=function(){q&&(q=0,Q(),J())},(0,u.l_)(e,"_setTimeoutOverride",(function(){return b.set}),(function(e){b=te(e,b.clear)})),(0,u.l_)(e,"_clearTimeoutOverride",(function(){return b.clear}),(function(e){b=te(b.set,e)}))})),i}return(0,i.ne)(t,e),t.__ieDyn=1,t}(p.i)},951:(e,t,n)=>{"use strict";n.d(t,{By:()=>r});var i=n(4869);function r(e){var t={};return(0,i.rW)(e,(function(e,n){t[e]=n,t[n]=e})),(0,i._A)(t)}},8452:(e,t,n)=>{"use strict";n.d(t,{h:()=>i});var i=(0,n(951).By)({Unknown:0,NonRetryableStatus:1,InvalidEvent:2,SizeLimitExceeded:3,KillSwitch:4,QueueFull:5})},7951:(e,t,n)=>{"use strict";n.d(t,{i:()=>u});var i=n(9141),r=n(8145),o=n(4869),s=n(6335),a=n(1030),c=n(8593),u=function(){function e(){var t,n,u,l,d,f=this;function p(e){void 0===e&&(e=null);var t=e;if(!t){var i=n||(0,a.CD)(null,{},f[s.oV]);t=u&&u.getPlugin?i[r.zV](null,u.getPlugin):i[r.zV](null,u)}return t}function g(e,t,i){e&&(0,o.sO)(e,s.Zh,[],null,o.le),!i&&t&&(i=t[r.SD]()[r.W2]());var c=u;u&&u.getPlugin&&(c=u.getPlugin()),f[s.oV]=t,n=(0,a.CD)(i,e,t,c)}function h(){t=!1,f[s.oV]=null,n=null,u=null,d=[],l=(0,c.Y)()}h(),(0,i.Z)(e,f,(function(e){e[r.VL]=function(e,n,i,r){g(e,n,r),t=!0},e[r.fi]=function(t,n){var i,c=e[s.oV];if(c&&(!t||c===t[s.oV]())){var f,p=!1,g=t||(0,a.Bt)(null,c,u&&u.getPlugin?u.getPlugin():u),m=n||((i={reason:0})[r.d]=!1,i);return e[r.F3]&&!0===e[r.F3](g,m,v)?f=!0:v(),f}function v(){if(!p){p=!0,l.run(g,n);var e=d;d=[],(0,o.tO)(e,(function(e){e.rm()})),!0===f&&g[r.uL](m),h()}}},e[r.Tu]=function(t,n){var i=e[s.oV];if(i&&(!t||i===t[s.oV]())){var o,c=!1,l=t||(0,a.xy)(null,i,u&&u.getPlugin?u.getPlugin():u),d=n||{reason:0};return e._doUpdate&&!0===e._doUpdate(l,d,f)?o=!0:f(),o}function f(){c||(c=!0,g(l.getCfg(),l.core(),l[r.W2]()))}},e._addHook=function(e){e&&((0,o.kJ)(e)?d=d.concat(e):d[r.MW](e))},(0,o.Oi)(e,"_addUnloadCb",(function(){return l}),"add")})),f[r.mc]=function(e){return p(e)[r.mc]()},f[r.yl]=function(){return t},f.setInitialized=function(e){t=e},f[r.Jd]=function(e){u=e},f[r.uL]=function(e,t){t?t[r.uL](e):u&&(0,o.mf)(u[s.hL])&&u[s.hL](e,null)},f._getTelCtx=p}return e.__ieDyn=1,e}()},8140:(e,t,n)=>{"use strict";n.d(t,{JP:()=>S,Nz:()=>C,UY:()=>E,kj:()=>m,p7:()=>T});var i=n(8145),r=n(9339),o=n(9251),s=n(4869),a=n(6335),c="toGMTString",u="toUTCString",l=null,d=null,f=null,p=(0,o.Me)(),g={},h={};function m(e,t){var n=C._ckMgr||h._ckMgr;return n||(n=C._ckMgr=C(e,t),h._ckMgr=n),n}function v(e){return!e||e.isEnabled()}function y(e,t){return!!(t&&e&&(0,s.kJ)(e.ignoreCookies))&&-1!==e.ignoreCookies[i.ou](t)}function S(e,t){var n;if(e)n=e.getCookieMgr();else if(t){var r=t[i.Lk];n=r._ckMgr?r._ckMgr:C(t)}return n||(n=m(t,(e||{})[i.eZ])),n}function C(e,t){var n,r=function(e){var t=e[i.Lk]=e[i.Lk]||{};if((0,s.sO)(t,"domain",e.cookieDomain,s.BX,s.le),(0,s.sO)(t,"path",e.cookiePath||"/",null,s.le),(0,s.le)(t.enabled)){var n=void 0;(0,s.o8)(e.isCookieUseDisabled)||(n=!e.isCookieUseDisabled),(0,s.o8)(e.disableCookiesUsage)||(n=!e.disableCookiesUsage),t.enabled=n}return t}(e||h),l=r.path||"/",f=r.domain,p=!1!==r.enabled,g=((n={isEnabled:function(){var e=p&&T(t),n=h._ckMgr;return e&&n&&g!==n&&(e=v(n)),e}})[i.$h]=function(e){p=!1!==e},n.set=function(e,t,n,p,h){var m=!1;if(v(g)&&!function(e,t){return!!(t&&e&&(0,s.kJ)(e.blockedCookies)&&-1!==e.blockedCookies[i.ou](t))||y(e,t)}(r,e)){var S={},C=(0,s.nd)(t||a.qS),T=C[i.ou](";");if(-1!==T&&(C=(0,s.nd)(t[i.zc](0,T)),S=b(t[i.zc](T+1))),(0,s.sO)(S,"domain",p||f,s.fQ,s.o8),!(0,s.le)(n)){var D=(0,o.w1)();if((0,s.o8)(S.expires)){var P=(0,s.m6)()+1e3*n;if(P>0){var k=new Date;k.setTime(P),(0,s.sO)(S,"expires",_(k,D?c:u)||_(k,D?c:u)||a.qS,s.fQ)}}D||(0,s.sO)(S,"max-age",a.qS+n,null,s.o8)}var x=(0,o.k$)();x&&"https:"===x.protocol&&((0,s.sO)(S,"secure",null,null,s.o8),null===d&&(d=!E(((0,o.jW)()||{})[i.qV])),d&&(0,s.sO)(S,"SameSite","None",null,s.o8)),(0,s.sO)(S,"path",h||l,null,s.o8),(r.setCookie||w)(e,R(C,S)),m=!0}return m},n.get=function(e){var t=a.qS;return v(g)&&!y(r,e)&&(t=(r.getCookie||D)(e)),t},n.del=function(e,t){var n=!1;return v(g)&&(n=g.purge(e,t)),n},n.purge=function(e,n){var i,s=!1;if(T(t)){var c=((i={}).path=n||"/",i.expires="Thu, 01 Jan 1970 00:00:01 GMT",i);(0,o.w1)()||(c["max-age"]="0"),(r.delCookie||w)(e,R(a.qS,c)),s=!0}return s},n);return g._ckMgr=g,g}function T(e){if(null===l){l=!1;try{l=void 0!==(p||{}).cookie}catch(t){(0,r.kP)(e,2,68,"Cannot access document.cookie - "+(0,s.jj)(t),{exception:(0,o.eU)(t)})}}return l}function b(e){var t={};if(e&&e[i.R5]){var n=(0,s.nd)(e)[i.w6](";");(0,s.tO)(n,(function(e){if(e=(0,s.nd)(e||a.qS)){var n=e[i.ou]("=");-1===n?t[e]=null:t[(0,s.nd)(e[i.zc](0,n))]=(0,s.nd)(e[i.zc](n+1))}}))}return t}function _(e,t){return(0,s.mf)(e[t])?e[t]():null}function R(e,t){var n=e||a.qS;return(0,s.rW)(t,(function(e,t){n+="; "+e+((0,s.le)(t)?a.qS:"="+t)})),n}function D(e){var t=a.qS;if(p){var n=p.cookie||a.qS;f!==n&&(g=b(n),f=n),t=(0,s.nd)(g[e]||a.qS)}return t}function w(e,t){p&&(p.cookie=e+"="+t)}function E(e){return!(!(0,s.HD)(e)||!(0,s._Q)(e,"CPU iPhone OS 12")&&!(0,s._Q)(e,"iPad; CPU OS 12")&&!((0,s._Q)(e,"Macintosh; Intel Mac OS X 10_14")&&(0,s._Q)(e,"Version/")&&(0,s._Q)(e,"Safari"))&&(!(0,s._Q)(e,"Macintosh; Intel Mac OS X 10_14")||!(0,s.Id)(e,"AppleWebKit/605.1.15 (KHTML, like Gecko)"))&&!(0,s._Q)(e,"Chrome/5")&&!(0,s._Q)(e,"Chrome/6")&&(!(0,s._Q)(e,"UnrealEngine")||(0,s._Q)(e,"Chrome"))&&!(0,s._Q)(e,"UCBrowser/12")&&!(0,s._Q)(e,"UCBrowser/11"))}},8956:(e,t,n)=>{"use strict";n.d(t,{DO:()=>h,GW:()=>p,Jj:()=>g,zB:()=>v});var i,r=n(175),o=n(8145),s=n(8140),a=n(9251),c=n(7954),u=n(4869),l=n(6335),d=n(9406),f=null;function p(){var e=h();return e[o.zc](0,8)+"-"+e[o.zc](8,12)+"-"+e[o.zc](12,16)+"-"+e[o.zc](16,20)+"-"+e[o.zc](20)}function g(){var e=(0,a.r)();return e&&e.now?e.now():(0,u.m6)()}function h(){for(var e,t=["0","1","2","3","4","5","6","7","8","9","a","b","c","d","e","f"],n=l.qS,i=0;i<4;i++)n+=t[15&(e=(0,d._l)())]+t[e>>4&15]+t[e>>8&15]+t[e>>12&15]+t[e>>16&15]+t[e>>20&15]+t[e>>24&15]+t[e>>28&15];var r=t[8+(3&(0,d._l)())|0];return n[o.Jn](0,8)+n[o.Jn](9,4)+"4"+n[o.Jn](13,3)+r+n[o.Jn](16,3)+n[o.Jn](19,12)}var m={_canUseCookies:void 0,isTypeof:u.Ym,isUndefined:u.o8,isNullOrUndefined:u.le,hasOwnProperty:u.nr,isFunction:u.mf,isObject:u.Kn,isDate:u.J_,isArray:u.kJ,isError:u.VZ,isString:u.HD,isNumber:u.hj,isBoolean:u.jn,toISOString:u.Y6,arrForEach:u.tO,arrIndexOf:u.UA,arrMap:u.Mr,arrReduce:u.Xz,strTrim:u.nd,objCreate:r.pu,objKeys:u.FY,objDefineAccessors:u.l_,addEventHandler:c.Ib,dateNow:u.m6,isIE:a.w1,disableCookies:function(){var e,t,n,r;(n=(0,s.kj)(e,t),r=m._canUseCookies,null===f&&(f=[],i=r,(0,u.l_)(m,"_canUseCookies",(function(){return i}),(function(e){i=e,(0,u.tO)(f,(function(t){t[o.$h](e)}))}))),-1===(0,u.UA)(f,n)&&f[o.MW](n),(0,u.jn)(r)&&n[o.$h](r),(0,u.jn)(i)&&n[o.$h](i),n)[o.$h](!1)},newGuid:p,perfNow:g,newId:d.pZ,randomValue:d.az,random32:d._l,mwcRandomSeed:d.CN,mwcRandom32:d.F6,generateW3CId:h},v={Attach:c.pZ,AttachEvent:c.pZ,Detach:c.pD,DetachEvent:c.pD}},7624:(e,t,n)=>{"use strict";n.d(t,{J:()=>f,K:()=>p});var i=n(1550),r=n(8145),o=n(4869),s=n(6335),a=n(9406),c=i.RJ,u="."+(0,a.pZ)(6),l=0;function d(e){return 1===e[r.xv]||9===e[r.xv]||!+e[r.xv]}function f(e,t){return void 0===t&&(t=!1),(0,o.Gf)(e+l+++(t?".2.8.10":s.qS)+u)}function p(e){var t={id:f("_aiData-"+(e||s.qS)+".2.8.10"),accept:function(e){return d(e)},get:function(e,n,i,r){var s=e[t.id];return s?s[(0,o.Gf)(n)]:(r&&((s=function(e,t){var n=t[e.id];if(!n){n={};try{d(t)&&(function(e,t,n){if(c)try{return c(e,t,{value:n,enumerable:!1,configurable:!0}),!0}catch(e){}return!1}(t,e.id,n)||(t[e.id]=n))}catch(e){}}return n}(t,e))[(0,o.Gf)(n)]=i),i)},kill:function(e,t){if(e&&e[t])try{delete e[t]}catch(e){}}};return t}},8341:(e,t,n)=>{"use strict";n.d(t,{j:()=>u,p:()=>l});var i,r=n(8145),o=n(9251),s=["eventsSent","eventsDiscarded","eventsSendRequest","perfEvent"],a=null;function c(e,t){return function(){var n=arguments,i=u(t);if(i){var o=i.listener;o&&o[e]&&o[e][r.ZV](o,n)}}}function u(e){var t,n=a;return n||!0===e.disableDbgExt||(n=a||((t=(0,o.a8)("Microsoft"))&&(a=t.ApplicationInsights),a)),n?n.ChromeDbgExt:null}function l(e){if(!i){i={};for(var t=0;t{"use strict";n.d(t,{AQ:()=>p,L4:()=>v,jV:()=>m,kP:()=>h,lQ:()=>d,vH:()=>f});var i=n(9141),r=n(8145),o=n(8341),s=n(9251),a=n(4869),c=n(6335);function u(e){return e?'"'+e[r.i7](/\"/g,c.qS)+'"':c.qS}function l(e,t){var n=(0,s.dr)();if(n){var i="log";n[e]&&(i=e),(0,a.mf)(n[i])&&n[i](t)}}var d=function(){function e(e,t,n,i){void 0===n&&(n=!1);var o=this;o[r.Gc]=e,o[r.gU]=(n?"AI: ":"AI (Internal): ")+e;var a=c.qS;(0,s.nS)()&&(a=(0,s.xA)().stringify(i));var l=(t?" message:"+u(t):c.qS)+(i?" props:"+u(a):c.qS);o[r.gU]+=l}return e.dataType="MessageData",e}();function f(e,t){return(e||{})[r.eZ]||new p(t)}var p=function(){function e(t){this.identifier="DiagnosticLogger",this.queue=[];var n,u,f,p,g=0,h={};(0,i.Z)(e,this,(function(e){function i(t,n){if(!(g>=f)){var i=!0,o="AITR_"+n[r.Gc];if(h[o]?i=!1:h[o]=!0,i&&(t<=u&&(e.queue[r.MW](n),g++,m(1===t?"error":"warn",n)),g===f)){var s="Internal events throttle limit per PageView reached for this app.",a=new d(23,s,!1);e.queue[r.MW](a),1===t?e[c.ys](s):e[c.cL](s)}}}function m(e,n){var i=(0,o.j)(t||{});i&&i[r.mc]&&i[r.mc](e,n)}!function(e){n=(0,a.v4)(e.loggingLevelConsole,0),u=(0,a.v4)(e.loggingLevelTelemetry,1),f=(0,a.v4)(e.maxMessageLimit,25),p=(0,a.v4)(e[r.Fr],!1)}(t||{}),e.consoleLoggingLevel=function(){return n},e.telemetryLoggingLevel=function(){return u},e.maxInternalMessageLimit=function(){return f},e[r.Fr]=function(){return p},e.throwInternal=function(t,o,u,l,f){void 0===f&&(f=!1);var g=new d(o,u,f,l);if(p)throw(0,s.eU)(g);var v=1===t?c.ys:c.cL;if((0,a.o8)(g[r.gU]))m("throw"+(1===t?"Critical":"Warning"),g);else{if(f){var y=+g[r.Gc];!h[y]&&n>=t&&(e[v](g[r.gU]),h[y]=!0)}else n>=t&&e[v](g[r.gU]);i(t,g)}},e[c.cL]=function(e){l("warn",e),m("warning",e)},e[c.ys]=function(e){l("error",e),m("error",e)},e.resetInternalMessageCount=function(){g=0,h={}},e[r.jk]=i}))}return e.__ieDyn=1,e}();function g(e){return e||new p}function h(e,t,n,i,r,o){void 0===o&&(o=!1),g(e).throwInternal(t,n,i,r,o)}function m(e,t){g(e)[c.cL](t)}function v(e,t,n){g(e)[r.jk](t,n)}},9251:(e,t,n)=>{"use strict";n.d(t,{JO:()=>K,Jj:()=>_,MF:()=>H,MX:()=>F,Me:()=>D,Nv:()=>R,Ym:()=>b,Z3:()=>z,a8:()=>T,b$:()=>L,cp:()=>W,d6:()=>w,dI:()=>C,dr:()=>N,eU:()=>U,ed:()=>B,fE:()=>P,gz:()=>M,jW:()=>E,k$:()=>x,nS:()=>I,pI:()=>$,r:()=>O,s1:()=>k,sA:()=>j,w1:()=>q,xA:()=>A});var i=n(1550),r=n(175),o=n(8145),s=n(4869),a=n(6335),c=n(5108),u="window",l="JSON",d="msie",f="trident/",p="XMLHttpRequest",g=null,h=null,m=!1,v=null,y=null;function S(e,t){var n=!1;if(e){try{if(!(n=t in e)){var r=e[i.hB];r&&(n=t in r)}}catch(e){}if(!n)try{var o=new e;n=!(0,s.o8)(o[t])}catch(e){}}return n}function C(e){m=e}function T(e){var t=(0,r.Rd)();return t&&t[e]?t[e]:e===u&&b()?window:null}function b(){return Boolean(typeof window===i.fK&&window)}function _(){return b()?window:T(u)}function R(){return Boolean(typeof document===i.fK&&document)}function D(){return R()?document:T("document")}function w(){return Boolean(typeof navigator===i.fK&&navigator)}function E(){return w()?navigator:T("navigator")}function P(){return Boolean(typeof history===i.fK&&history)}function k(){return P()?history:T("history")}function x(e){if(e&&m){var t=T("__mockLocation");if(t)return t}return typeof location===i.fK&&location?location:T("location")}function N(){return typeof c!==i.jA?c:T("console")}function O(){return T("performance")}function I(){return Boolean(typeof JSON===i.fK&&JSON||null!==T(l))}function A(){return I()?JSON||T(l):null}function F(){return T("crypto")}function M(){return T("msCrypto")}function L(){var e=E();return!(!e||!e.product)&&"ReactNative"===e.product}function q(){var e=E();if(e&&(e[o.qV]!==h||null===g)){var t=((h=e[o.qV])||a.qS)[o.T1]();g=(0,s._Q)(t,d)||(0,s._Q)(t,f)}return g}function j(e){if(void 0===e&&(e=null),!e){var t=E()||{};e=t?(t[o.qV]||a.qS)[o.T1]():a.qS}var n=(e||a.qS)[o.T1]();if((0,s._Q)(n,d)){var i=D()||{};return Math.max(parseInt(n[o.w6](d)[1]),i.documentMode||0)}if((0,s._Q)(n,f)){var r=parseInt(n[o.w6](f)[1]);if(r)return r+4}return null}function U(e){var t=Object[i.hB].toString[o._S](e),n=a.qS;return"[object Error]"===t?n="{ stack: '"+e.stack+"', message: '"+e.message+"', name: '"+e[o.I]+"'":I()&&(n=A().stringify(e)),t+n}function H(){return null===y&&(y=w()&&Boolean(E().sendBeacon)),y}function K(e){var t=!1;try{t=!!T("fetch");var n=T("Request");t&&e&&n&&(t=S(n,"keepalive"))}catch(e){}return t}function W(){return null===v&&(v=typeof XDomainRequest!==i.jA)&&z()&&(v=v&&!S(T(p),"withCredentials")),v}function z(){var e=!1;try{e=!!T(p)}catch(e){}return e}function V(e,t){if(e)for(var n=0;n0?i[0]:{}).serverTiming,e).description}return t}},7954:(e,t,n)=>{"use strict";n.d(t,{C1:()=>I,C9:()=>U,Ib:()=>O,JA:()=>q,QY:()=>k,TJ:()=>j,XO:()=>P,Yl:()=>K,c9:()=>L,jU:()=>E,nD:()=>H,nJ:()=>M,pD:()=>N,pZ:()=>x,um:()=>_,yw:()=>F});var i=n(8145),r=n(7624),o=n(9251),s=n(4869),a=n(6335),c="events",u="visibilitychange",l="pagehide",d="pageshow",f="unload",p="beforeunload",g=(0,r.J)("aiEvtPageHide"),h=(0,r.J)("aiEvtPageShow"),m=/\.[\.]+/g,v=/[\.]+$/,y=1,S=(0,r.K)("events"),C=/^([^.]*)(?:\.(.+)|)/;function T(e){return e&&e[i.i7]?e[i.i7](/^[\s\.]+|(?=[\s\.])[\.\s]+$/g,a.qS):e}function b(e,t){var n;if(t){var r=a.qS;(0,s.kJ)(t)?(r=a.qS,(0,s.tO)(t,(function(e){(e=T(e))&&("."!==e[0]&&(e="."+e),r+=e)}))):r=T(t),r&&("."!==r[0]&&(r="."+r),e=(e||a.qS)+r)}var o=C.exec(e||a.qS)||[];return(n={})[i.P6]=o[1],n.ns=(o[2]||a.qS).replace(m,".").replace(v,a.qS)[i.w6](".").sort().join("."),n}function _(e,t,n){var r=[],o=S.get(e,c,{},!1),u=b(t,n);return(0,s.rW)(o,(function(e,t){(0,s.tO)(t,(function(e){var t;u[i.P6]&&u[i.P6]!==e.evtName[i.P6]||u.ns&&u.ns!=u.ns||r[i.MW](((t={})[i.I]=e.evtName[i.P6]+(e.evtName.ns?"."+e.evtName.ns:a.qS),t.handler=e[i.Kn],t))}))})),r}function R(e,t,n){void 0===n&&(n=!0);var i=S.get(e,c,{},n),r=i[t];return r||(r=i[t]=[]),r}function D(e,t,n,r){e&&t&&t[i.P6]&&(e.removeEventListener?e.removeEventListener(t[i.P6],n,r):e.detachEvent&&e.detachEvent("on"+t[i.P6],n))}function w(e,t,n,r){for(var o=t[i.R5];o--;){var s=t[o];s&&(n.ns&&n.ns!==s.evtName.ns||r&&!r(s)||(D(e,s.evtName,s[i.Kn],s.capture),t[i.cb](o,1)))}}function E(e,t){return t?b("xx",(0,s.kJ)(t)?[e].concat(t):[e,t]).ns[i.w6]("."):e}function P(e,t,n,r,o){var s;void 0===o&&(o=!1);var a=!1;if(e)try{var c=b(t,r);if(a=function(e,t,n,r){var o=!1;return e&&t&&t[i.P6]&&n&&(e.addEventListener?(e.addEventListener(t[i.P6],n,r),o=!0):e.attachEvent&&(e.attachEvent("on"+t[i.P6],n),o=!0)),o}(e,c,n,o),a&&S.accept(e)){var u=((s={guid:y++,evtName:c})[i.Kn]=n,s.capture=o,s);R(e,c.type)[i.MW](u)}}catch(e){}return a}function k(e,t,n,r,o){if(void 0===o&&(o=!1),e)try{var a=b(t,r),u=!1;!function(e,t,n){if(t[i.P6])w(e,R(e,t[i.P6]),t,n);else{var r=S.get(e,c,{});(0,s.rW)(r,(function(i,r){w(e,r,t,n)})),0===(0,s.FY)(r)[i.R5]&&S.kill(e,c)}}(e,a,(function(e){return!((!a.ns||n)&&e[i.Kn]!==n||(u=!0,0))})),u||D(e,a,n,o)}catch(e){}}function x(e,t,n,i){return void 0===i&&(i=!1),P(e,t,n,null,i)}function N(e,t,n,i){void 0===i&&(i=!1),k(e,t,n,null,i)}function O(e,t,n){var i=!1,r=(0,o.Jj)();r&&(i=P(r,e,t,n),i=P(r.body,e,t,n)||i);var s=(0,o.Me)();return s&&(i=P(s,e,t,n)||i),i}function I(e,t,n){var i=(0,o.Jj)();i&&(k(i,e,t,n),k(i.body,e,t,n));var r=(0,o.Me)();r&&k(r,e,t,n)}function A(e,t,n,r){var o=!1;return t&&e&&e[i.R5]>0&&(0,s.tO)(e,(function(e){e&&(n&&-1!==(0,s.UA)(n,e)||(o=O(e,t,r)||o))})),o}function F(e,t,n,r){var o=!1;return t&&e&&(0,s.kJ)(e)&&!(o=A(e,t,n,r))&&n&&n[i.R5]>0&&(o=A(e,t,null,r)),o}function M(e,t,n){e&&(0,s.kJ)(e)&&(0,s.tO)(e,(function(e){e&&I(e,t,n)}))}function L(e,t,n){return F([p,f,l],e,t,n)}function q(e,t){M([p,f,l],e,t)}function j(e,t,n){var i=E(g,n),r=A([l],e,t,i);return t&&-1!==(0,s.UA)(t,u)||(r=A([u],(function(t){var n=(0,o.Me)();e&&n&&"hidden"===n.visibilityState&&e(t)}),t,i)||r),!r&&t&&(r=j(e,null,n)),r}function U(e,t){var n=E(g,t);M([l],e,n),M([u],null,n)}function H(e,t,n){var i=E(h,n),r=A([d],e,t,i);return!(r=A([u],(function(t){var n=(0,o.Me)();e&&n&&"visible"===n.visibilityState&&e(t)}),t,i)||r)&&t&&(r=H(e,null,n)),r}function K(e,t){var n=E(h,t);M([d],e,n),M([u],null,n)}},4869:(e,t,n)=>{"use strict";n.d(t,{Ax:()=>he,BX:()=>E,F:()=>ce,FL:()=>te,FY:()=>Z,Gf:()=>N,HD:()=>j,Id:()=>I,J_:()=>M,Kn:()=>k,Mr:()=>B,Oi:()=>pe,UA:()=>V,VZ:()=>q,Vb:()=>ge,Xi:()=>ne,Xz:()=>$,Y6:()=>W,Ym:()=>R,_A:()=>ee,_Q:()=>F,_y:()=>le,cf:()=>fe,fQ:()=>ue,hj:()=>U,jj:()=>re,jn:()=>H,kJ:()=>L,l_:()=>X,le:()=>w,m6:()=>ie,mf:()=>x,mm:()=>me,nd:()=>G,nr:()=>P,o8:()=>D,qK:()=>se,rW:()=>O,sO:()=>oe,tO:()=>z,v4:()=>ae,xe:()=>A});var i=n(1550),r=n(175),o=n(8145),s=n(6335),a=i.RJ,c=i.Pw.freeze,u=i.Pw.seal,l=i.Pw.keys,d=String[i.hB],f=d.trim,p=d.endsWith,g=d.startsWith,h=Date[i.hB].toISOString,m=Array.isArray,v=i.V4.toString,y=i.CY.toString,S=y[o._S](i.Pw),C=/-([a-z])/g,T=/([^\w\d_$])/g,b=/^(\d+[\w\d_$])/,_=Object.getPrototypeOf;function R(e,t){return typeof e===t}function D(e){return void 0===e||typeof e===i.jA}function w(e){return null===e||D(e)}function E(e){return!w(e)}function P(e,t){return!(!e||!i.CY[o._S](e,t))}function k(e){return!(!e||typeof e!==i.fK)}function x(e){return!(!e||typeof e!==i.cb)}function N(e){var t=e;return t&&j(t)&&(t=(t=(t=t[o.i7](C,(function(e,t){return t.toUpperCase()})))[o.i7](T,"_"))[o.i7](b,(function(e,t){return"_"+t}))),t}function O(e,t){if(e)for(var n in e)i.CY[o._S](e,n)&&t[o._S](e,n,e[n])}function I(e,t){var n=!1;return e&&t&&!(n=e===t)&&(n=p?e.endsWith(t):function(e,t){var n=!1,i=t?t[o.R5]:0,r=e?e[o.R5]:0;if(i&&r&&r>=i&&!(n=e===t)){for(var s=r-1,a=i-1;a>=0;a--){if(e[s]!=t[a])return!1;s--}n=!0}return n}(e,t)),n}function A(e,t){var n=!1;return e&&t&&!(n=e===t)&&(n=g?e.startsWith(t):function(e,t){var n=!1,i=t?t[o.R5]:0;if(e&&i&&e[o.R5]>=i&&!(n=e===t)){for(var r=0;r=0?r:i-Math.abs(r),0);s=3)i=arguments[2];else{for(;s0&&H(u)&&(d=u,u=c[f]||{},f++),k(u)||(u={});f{"use strict";n.d(t,{$F:()=>p,C$:()=>h,DN:()=>s,Z:()=>r,Zh:()=>c,cL:()=>v,f_:()=>g,hL:()=>l,js:()=>u,kl:()=>y,mE:()=>a,oV:()=>o,qS:()=>i,uC:()=>f,yi:()=>d,ys:()=>m});var i="",r="channels",o="core",s="createPerfMgr",a="disabled",c="extensionConfig",u="extensions",l="processTelemetry",d="priority",f="eventsSent",p="eventsDiscarded",g="eventsSendRequest",h="perfEvent",m="errorToConsole",v="warnToConsole",y="getPerfMgr"},1782:(e,t,n)=>{"use strict";n.d(t,{Jk:()=>c,Lm:()=>l,j5:()=>d,zn:()=>a});var i=n(9141),r=n(8145),o=n(4869),s=n(6335),a=function(){function e(t,n,i){var s,a=this,c=!1;a.start=(0,o.m6)(),a[r.I]=t,a[r.d]=i,a[r.PL]=function(){return!1},(0,o.mf)(n)&&(c=(0,o.l_)(a,"payload",(function(){return!s&&(0,o.mf)(n)&&(s=n(),n=null),s}))),a[r.T]=function(t){return t?t===e.ParentContextKey||t===e.ChildrenContextKey?a[t]:(a.ctx||{})[t]:null},a[r.wu]=function(t,n){t&&(t===e.ParentContextKey?(a[t]||(a[r.PL]=function(){return!0}),a[t]=n):t===e.ChildrenContextKey?a[t]=n:(a.ctx=a.ctx||{})[t]=n)},a[r.Km]=function(){var t=0,i=a[r.T](e.ChildrenContextKey);if((0,o.kJ)(i))for(var s=0;s{"use strict";n.d(t,{Bt:()=>p,CD:()=>f,Vi:()=>m,jV:()=>h,xy:()=>g});var i=n(8145),r=n(9339),o=n(9251),s=n(4869),a=n(6335),c=n(1782),u=n(9031),l=0;function d(e,t,n,c){var u=null,l=[];null!==c&&(u=c?function(e,t,n){for(;e;){if(e[i.TO]()===n)return e;e=e[i.W2]()}return h([n],t[i.TC]||{},t)}(e,n,c):e);var d={_next:function(){var e=u;if(u=e?e[i.W2]():null,!e){var t=l;t&&t[i.R5]>0&&((0,s.tO)(t,(function(e){try{e.func[i._S](e.self,e.args)}catch(e){(0,r.kP)(n[i.eZ],2,73,"Unexpected Exception during onComplete - "+(0,o.eU)(e))}})),l=[])}return e},ctx:{core:function(){return n},diagLog:function(){return(0,r.vH)(n,t)},getCfg:function(){return t},getExtCfg:f,getConfig:function(e,n,i){void 0===i&&(i=!1);var r,o=f(e,null);return o&&!(0,s.le)(o[n])?r=o[n]:t&&!(0,s.le)(t[n])&&(r=t[n]),(0,s.le)(r)?i:r},hasNext:function(){return!!u},getNext:function(){return u},setNext:function(e){u=e},iterate:function(e){for(var t;t=d._next();){var n=t[i.TO]();n&&e(n)}},onComplete:function(e,t){for(var n=[],r=2;r0){var m=null;(0,s.tO)(e,(function(e){if(g||d!==e||(g=!0),g&&e&&(0,s.mf)(e[a.hL])){var h=function(e,t,n){var d,p=null,g=(0,s.mf)(e[a.hL]),h=(0,s.mf)(e[i.Jd]),m={getPlugin:function(){return e},getNext:function(){return p},processTelemetry:function(r,o){v(o=o||function(){var i;return e&&(0,s.mf)(e._getTelCtx)&&(i=e._getTelCtx()),i||(i=f(m,t,n)),i}(),(function(t){if(!e||!g)return!1;var n=(0,u.OY)(e);return!n[i.fi]&&!n[a.mE]&&(h&&e[i.Jd](p),e[a.hL](r,t),!0)}),"processTelemetry",(function(){return{item:r}}),!r.sync)||o[i.uL](r)},unload:function(t,n){v(t,(function(){var r=!1;if(e){var o=(0,u.OY)(e),s=e[a.oV]||o[a.oV];!e||s&&s!==t.core()||o[i.fi]||(o[a.oV]=null,o[i.fi]=!0,o[i.yl]=!1,e[i.fi]&&!0===e[i.fi](t,n)&&(r=!0))}return r}),"unload",(function(){}),n[i.d])||t[i.uL](n)},update:function(t,n){v(t,(function(){var r=!1;if(e){var o=(0,u.OY)(e),s=e[a.oV]||o[a.oV];!e||s&&s!==t.core()||o[i.fi]||e[i.Tu]&&!0===e[i.Tu](t,n)&&(r=!0)}return r}),"update",(function(){}),!1)||t[i.uL](n)},_id:d=e?e[i.pZ]+"-"+e[a.yi]+"-"+l++:"Unknown-0-"+l++,_setNext:function(e){p=e}};function v(t,n,s,u,l){var f=!1,g=e?e[i.pZ]:"TelemetryPluginChain",h=t._hasRun;return h||(h=t._hasRun={}),t.setNext(p),e&&(0,c.Lm)(t[a.oV](),(function(){return g+":"+s}),(function(){h[d]=!0;try{var e=p?p._id:a.qS;e&&(h[e]=!1),f=n(t)}catch(e){var c=!p||h[p._id];c&&(f=!0),p&&c||(0,r.kP)(t[i.mc](),1,73,"Plugin ["+g+"] failed during "+s+" - "+(0,o.eU)(e)+", run flags: "+(0,o.eU)(h))}}),u,l),f}return(0,s.FL)(m)}(e,t,n);p||(p=h),m&&m._setNext(h),m=h}}))}return d&&!p?h([d],t,n):p}var m=function(e,t,n,i){var r=f(e,t,n,i);(0,s.Vb)(this,r,(0,s.FY)(r))}},9406:(e,t,n)=>{"use strict";n.d(t,{CN:()=>m,F6:()=>v,_l:()=>h,az:()=>g,pZ:()=>y});var i=n(8145),r=n(9251),o=n(4869),s=n(6335),a=4294967296,c=4294967295,u=!1,l=123456789,d=987654321;function f(e){e<0&&(e>>>=0),l=123456789+e&c,d=987654321-e&c,u=!0}function p(){try{var e=2147483647&(0,o.m6)();f((Math.random()*a^e)+e)}catch(e){}}function g(e){return e>0?Math.floor(h()/c*(e+1))>>>0:0}function h(e){var t=0,n=(0,r.MX)()||(0,r.gz)();return n&&n.getRandomValues&&(t=n.getRandomValues(new Uint32Array(1))[0]&c),0===t&&(0,r.w1)()&&(u||p(),t=v()&c),0===t&&(t=Math.floor(a*Math.random()|0)),e||(t>>>=0),t}function m(e){e?f(e):p()}function v(e){var t=((d=36969*(65535&d)+(d>>16)&c)<<16)+(65535&(l=18e3*(65535&l)+(l>>16)&c))>>>0&c|0;return e||(t>>>=0),t}function y(e){void 0===e&&(e=22);for(var t=h()>>>0,n=0,r=s.qS;r[i.R5]>>=6,5===n&&(t=(h()<<2&4294967295|3&t)>>>0,n=0);return r}},9031:(e,t,n)=>{"use strict";n.d(t,{AA:()=>d,OY:()=>u,Yn:()=>f,bP:()=>l});var i=n(8145),r=n(7624),o=n(4869),s=n(6335),a=n(6207),c=(0,r.K)("plugin");function u(e){return c.get(e,"state",{},!0)}function l(e,t){for(var n,r=[],a=null,c=e[i.W2]();c;){var l=c[i.TO]();l&&(a&&(0,o.mf)(a[i.Jd])&&(0,o.mf)(l[s.hL])&&a[i.Jd](l),((0,o.mf)(l[i.yl])?l[i.yl]():(n=u(l))[i.yl])||r[i.MW](l),a=l,c=c[i.W2]())}(0,o.tO)(r,(function(r){var o=e[s.oV]();r[i.VL](e.getCfg(),o,t,e[i.W2]()),n=u(r),r[s.oV]||n[s.oV]||(n[s.oV]=o),n[i.yl]=!0,delete n[i.fi]}))}function d(e){return e.sort((function(e,t){var n=0;if(t){var i=(0,o.mf)(t[s.hL]);(0,o.mf)(e[s.hL])?n=i?e[s.yi]-t[s.yi]:1:i&&(n=-1)}else n=e?1:-1;return n}))}function f(e){var t={};return{getName:function(){return t[i.I]},setName:function(n){e&&e.setName(n),t[i.I]=n},getTraceId:function(){return t[i.nY]},setTraceId:function(n){e&&e.setTraceId(n),(0,a.jN)(n)&&(t[i.nY]=n)},getSpanId:function(){return t[i._d]},setSpanId:function(n){e&&e.setSpanId(n),(0,a.Lc)(n)&&(t[i._d]=n)},getTraceFlags:function(){return t[i.T0]},setTraceFlags:function(n){e&&e.setTraceFlags(n),t[i.T0]=n}}}},8593:(e,t,n)=>{"use strict";n.d(t,{Y:()=>a});var i=n(8145),r=n(9339),o=n(9251),s=n(4869);function a(){var e=[];return{add:function(t){t&&e[i.MW](t)},run:function(t,n){(0,s.tO)(e,(function(e){try{e(t,n)}catch(e){(0,r.kP)(t[i.mc](),2,73,"Unexpected error calling unload handler - "+(0,o.eU)(e))}})),e=[]}}}},6207:(e,t,n)=>{"use strict";n.d(t,{J6:()=>S,Lc:()=>y,Pn:()=>C,SU:()=>h,aR:()=>T,jN:()=>v,j_:()=>m,lq:()=>b});var i=n(8145),r=n(8956),o=n(9251),s=n(4869),a=/^([\da-f]{2})-([\da-f]{32})-([\da-f]{16})-([\da-f]{2})(-[^\s]*)?$/,c="00",u="ff",l="00000000000000000000000000000000",d="0000000000000000";function f(e,t,n){return!(!e||e[i.R5]!==t||e===n||!e.match(/^[\da-f]*$/))}function p(e,t,n){return f(e,t)?e:n}function g(e){(isNaN(e)||e<0||e>255)&&(e=1);for(var t=e.toString(16);t[i.R5]<2;)t="0"+t;return t}function h(e,t,n,o){var s;return(s={})[i.PA]=f(o,2,u)?o:c,s[i.nY]=v(e)?e:(0,r.DO)(),s.spanId=y(t)?t:(0,r.DO)()[i.Jn](0,16),s.traceFlags=n>=0&&n<=255?n:1,s}function m(e){var t;if(!e)return null;if((0,s.kJ)(e)&&(e=e[0]||""),!e||!(0,s.HD)(e)||e[i.R5]>8192)return null;var n=a.exec((0,s.nd)(e));return n&&n[1]!==u&&n[2]!==l&&n[3]!==d?((t={})[i.PA]=n[1],t[i.nY]=n[2],t[i._d]=n[3],t[i.T0]=parseInt(n[4],16),t):null}function v(e){return f(e,32,l)}function y(e){return f(e,16,d)}function S(e){return!!(e&&f(e[i.PA],2,u)&&f(e[i.nY],32,l)&&f(e[i._d],16,d)&&f(g(e[i.T0]),2))}function C(e){return!!S(e)&&1==(1&e[i.T0])}function T(e){if(e){var t=g(e[i.T0]);f(t,2)||(t="01");var n=e[i.PA]||c;return"00"!==n&&"ff"!==n&&(n=c),"".concat(n,"-").concat(p(e.traceId,32,l),"-").concat(p(e.spanId,16,d),"-").concat(t)}return""}function b(){var e="traceparent",t=m((0,o.ed)(e));return t||(t=m((0,o.pI)(e))),t}},8145:(e,t,n)=>{"use strict";n.d(t,{$h:()=>j,F3:()=>P,Fc:()=>S,Fr:()=>z,Gc:()=>D,I:()=>r,Jd:()=>O,Jn:()=>U,Km:()=>ee,Kn:()=>J,LS:()=>y,Lk:()=>A,MW:()=>a,P6:()=>G,PA:()=>re,PL:()=>Z,R5:()=>f,SD:()=>h,T:()=>X,T0:()=>ie,T1:()=>B,TC:()=>u,TO:()=>C,Tu:()=>k,VL:()=>i,W2:()=>x,ZV:()=>K,Z_:()=>p,_S:()=>$,_d:()=>ne,cb:()=>_,d:()=>E,dE:()=>Y,eZ:()=>d,fi:()=>R,g:()=>m,gU:()=>w,i7:()=>W,iC:()=>b,jk:()=>V,kL:()=>T,mc:()=>N,n7:()=>v,nY:()=>te,ou:()=>F,p$:()=>l,pZ:()=>s,qV:()=>L,tb:()=>o,uL:()=>g,w6:()=>q,wu:()=>Q,xv:()=>H,yl:()=>c,zV:()=>I,zc:()=>M});var i="initialize",r="name",o="getNotifyMgr",s="identifier",a="push",c="isInitialized",u="config",l="instrumentationKey",d="logger",f="length",p="time",g="processNext",h="getProcessTelContext",m="addNotificationListener",v="removeNotificationListener",y="stopPollingInternalLogs",S="onComplete",C="getPlugin",T="flush",b="_extensions",_="splice",R="teardown",D="messageId",w="message",E="isAsync",P="_doTeardown",k="update",x="getNext",N="diagLog",O="setNextPlugin",I="createNew",A="cookieCfg",F="indexOf",M="substring",L="userAgent",q="split",j="setEnabled",U="substr",H="nodeType",K="apply",W="replace",z="enableDebugExceptions",V="logInternalMessage",B="toLowerCase",$="call",G="type",J="handler",Y="listeners",Z="isChildEvt",X="getCtx",Q="setCtx",ee="complete",te="traceId",ne="spanId",ie="traceFlags",re="version"},1550:(e,t,n)=>{"use strict";n.d(t,{CY:()=>p,Pw:()=>c,RJ:()=>f,V4:()=>u,bO:()=>a,cb:()=>i,fK:()=>r,hB:()=>s,jA:()=>o,rl:()=>l,yu:()=>d});var i="function",r="object",o="undefined",s="prototype",a="hasOwnProperty",c=Object,u=c[s],l=c.assign,d=c.create,f=c.defineProperty,p=u[a]},175:(e,t,n)=>{"use strict";n.d(t,{Rd:()=>o,ZU:()=>s,pu:()=>a});var i=n(1550),r=null;function o(e){void 0===e&&(e=!0);var t=!1===e?null:r;return t||(typeof globalThis!==i.jA&&(t=globalThis),t||typeof self===i.jA||(t=self),t||typeof window===i.jA||(t=window),t||typeof n.g===i.jA||(t=n.g),r=t),t}function s(e){throw new TypeError(e)}function a(e){var t=i.yu;if(t)return t(e);if(null==e)return{};var n=typeof e;function r(){}return n!==i.fK&&n!==i.cb&&s("Object prototype may only be an Object:"+e),r[i.hB]=e,new r}},7421:(e,t,n)=>{"use strict";n.d(t,{$h:()=>c,ne:()=>a,uc:()=>o});var i=n(1550),r=n(175),o=(((0,r.Rd)()||{}).Symbol,((0,r.Rd)()||{}).Reflect,i.rl||function(e){for(var t,n=1,r=arguments.length;n{"use strict";n.r(t),n.d(t,{AppInsightsCore:()=>ua,ApplicationInsights:()=>Da,CoreUtils:()=>Ta,Sender:()=>Mr,SeverityLevel:()=>Ra,_InternalMessageId:()=>_a,arrForEach:()=>ho,isNullOrUndefined:()=>to,proxyFunctions:()=>xo,throwError:()=>Po});var i=n(9141),r=n(7421),o="Microsoft_ApplicationInsights_BypassAjaxInstrumentation",s="http.method",a="https://dc.services.visualstudio.com",c="/v2/track",u="not_specified",l=n(1550),d=n(175),f="",p=l.RJ,g=l.Pw.freeze,h=(l.Pw.seal,l.Pw.keys),m=String[l.hB],v=m.trim,y=m.endsWith,S=(m.startsWith,Date[l.hB].toISOString),C=Array.isArray,T=l.V4.toString,b=(l.CY.toString.call(l.Pw),/-([a-z])/g),_=/([^\w\d_$])/g,R=/^(\d+[\w\d_$])/;function D(e){return void 0===e||typeof e===l.jA}function w(e){return null===e||D(e)}function E(e){return!w(e)}function P(e){return!(!e||typeof e!==l.fK)}function k(e){return!(!e||typeof e!==l.cb)}function x(e){var t=e;return t&&F(t)&&(t=(t=(t=t.replace(b,(function(e,t){return t.toUpperCase()}))).replace(_,"_")).replace(R,(function(e,t){return"_"+t}))),t}function N(e,t){if(e)for(var n in e)l.CY.call(e,n)&&t.call(e,n,e[n])}function O(e,t){return!(!e||!t)&&-1!==e.indexOf(t)}Object.getPrototypeOf;var I=C||function(e){return!(!e||"[object Array]"!==T.call(e))};function A(e){return!(!e||"[object Error]"!==T.call(e))}function F(e){return"string"==typeof e}function M(e){return"boolean"==typeof e}function L(e){if(e)return S?e.toISOString():function(e){if(e&&e.getUTCFullYear){var t=function(e){var t=String(e);return 1===t.length&&(t="0"+t),t};return e.getUTCFullYear()+"-"+t(e.getUTCMonth()+1)+"-"+t(e.getUTCDate())+"T"+t(e.getUTCHours())+":"+t(e.getUTCMinutes())+":"+t(e.getUTCSeconds())+"."+String((e.getUTCMilliseconds()/1e3).toFixed(3)).slice(2,5)+"Z"}}(e)}function q(e,t,n){var i=e.length;try{for(var r=0;r=0?r:i-Math.abs(r),0);o=3)i=arguments[2];else{for(;o=o)){var i=!0,s="AITR_"+n.messageId;if(c[s]?i=!1:c[s]=!0,i&&(t<=r&&(e.queue.push(n),a++,u(1===t?"error":"warn",n)),a===o)){var l="Internal events throttle limit per PageView reached for this app.",d=new ve(23,l,!1);e.queue.push(d),1===t?e.errorToConsole(l):e.warnToConsole(l)}}}function u(e,n){var i=function(e){var t,n=pe;return n||!0===e.disableDbgExt||(n=pe||((t=oe("Microsoft"))&&(pe=t.ApplicationInsights),pe)),n?n.ChromeDbgExt:null}(t||{});i&&i.diagLog&&i.diagLog(e,n)}!function(e){n=X(e.loggingLevelConsole,0),r=X(e.loggingLevelTelemetry,1),o=X(e.maxMessageLimit,25),s=X(e.enableDebugExceptions,!1)}(t||{}),e.consoleLoggingLevel=function(){return n},e.telemetryLoggingLevel=function(){return r},e.maxInternalMessageLimit=function(){return o},e.enableDebugExceptions=function(){return s},e.throwInternal=function(t,r,o,a,l){void 0===l&&(l=!1);var d=new ve(r,o,l,a);if(s)throw fe(d);var f=1===t?"errorToConsole":"warnToConsole";if(D(d.message))u("throw"+(1===t?"Critical":"Warning"),d);else{if(l){var p=+d.messageId;!c[p]&&n>=t&&(e[f](d.message),c[p]=!0)}else n>=t&&e[f](d.message);i(t,d)}},e.warnToConsole=function(e){he("warn",e),u("warning",e)},e.errorToConsole=function(e){he("error",e),u("error",e)},e.resetInternalMessageCount=function(){a=0,c={}},e.logInternalMessage=i}))}return e.__ieDyn=1,e}();function Se(e,t,n,i,r,o){void 0===o&&(o=!1),function(e){return e||new ye}(e).throwInternal(t,n,i,r,o)}function Ce(e,t,n){var i=t.length,r=Te(e,t);if(r.length!==i){for(var o=0,s=r;void 0!==n[s];)o++,s=r.substring(0,147)+xe(o);r=s}return r}function Te(e,t){var n;return t&&(t=K(t.toString())).length>150&&(n=t.substring(0,150),Se(e,2,57,"name is too long. It has been truncated to 150 characters.",{name:t},!0)),n||t}function be(e,t,n){var i;return void 0===n&&(n=1024),t&&(n=n||1024,(t=K(t)).toString().length>n&&(i=t.toString().substring(0,n),Se(e,2,61,"string value is too long. It has been truncated to "+n+" characters.",{value:t},!0))),i||t}function _e(e,t){return ke(e,t,2048,66)}function Re(e,t){var n;return t&&t.length>32768&&(n=t.substring(0,32768),Se(e,2,56,"message is too long, it has been truncated to 32768 characters.",{message:t},!0)),n||t}function De(e,t){var n;if(t){var i=""+t;i.length>32768&&(n=i.substring(0,32768),Se(e,2,52,"exception is too long, it has been truncated to 32768 characters.",{exception:t},!0))}return n||t}function we(e,t){if(t){var n={};N(t,(function(t,i){if(P(i)&&ue())try{i=le().stringify(i)}catch(t){Se(e,2,49,"custom property is not valid",{exception:t},!0)}i=be(e,i,8192),t=Ce(e,t,n),n[t]=i})),t=n}return t}function Ee(e,t){if(t){var n={};N(t,(function(t,i){t=Ce(e,t,n),n[t]=i})),t=n}return t}function Pe(e,t){return t?ke(e,t,128,69).toString():t}function ke(e,t,n,i){var r;return t&&(t=K(t)).length>n&&(r=t.substring(0,n),Se(e,2,i,"input is too long, it has been truncated to "+n+" characters.",{data:t},!0)),r||t}function xe(e){var t="00"+e;return t.substr(t.length-3)}(me={MAX_NAME_LENGTH:150,MAX_ID_LENGTH:128,MAX_PROPERTY_LENGTH:8192,MAX_STRING_LENGTH:1024,MAX_URL_LENGTH:2048,MAX_MESSAGE_LENGTH:32768,MAX_EXCEPTION_LENGTH:32768}).sanitizeKeyAndAddUniqueness=Ce,me.sanitizeKey=Te,me.sanitizeString=be,me.sanitizeUrl=_e,me.sanitizeMessage=Re,me.sanitizeException=De,me.sanitizeProperties=we,me.sanitizeMeasurements=Ee,me.sanitizeId=Pe,me.sanitizeInput=ke,me.padNumber=xe,me.trim=K;var Ne=function(){function e(e,t,n,i){this.aiDataContract={ver:1,name:1,properties:0,measurements:0};var r=this;r.ver=2,r.name=be(e,t)||u,r.properties=we(e,n),r.measurements=Ee(e,i)}return e.envelopeType="Microsoft.ApplicationInsights.{0}.Event",e.dataType="EventData",e}(),Oe=function(){function e(e,t,n,i,r){this.aiDataContract={ver:1,message:1,severityLevel:0,properties:0};var o=this;o.ver=2,t=t||u,o.message=Re(e,t),o.properties=we(e,i),o.measurements=Ee(e,r),n&&(o.severityLevel=n)}return e.envelopeType="Microsoft.ApplicationInsights.{0}.Message",e.dataType="MessageData",e}();function Ie(e){(isNaN(e)||e<0)&&(e=0);var t=""+(e=Math.round(e))%1e3,n=""+Math.floor(e/1e3)%60,i=""+Math.floor(e/6e4)%60,r=""+Math.floor(e/36e5)%24,o=Math.floor(e/864e5);return t=1===t.length?"00"+t:2===t.length?"0"+t:t,n=n.length<2?"0"+n:n,i=i.length<2?"0"+i:i,(o>0?o+".":"")+(r=r.length<2?"0"+r:r)+":"+i+":"+n+"."+t}var Ae=function(){function e(e,t,n,i,r,o,s){this.aiDataContract={ver:1,name:0,url:0,duration:0,properties:0,measurements:0,id:0};var a=this;a.ver=2,a.id=Pe(e,s),a.url=_e(e,n),a.name=be(e,t)||u,isNaN(i)||(a.duration=Ie(i)),a.properties=we(e,r),a.measurements=Ee(e,o)}return e.envelopeType="Microsoft.ApplicationInsights.{0}.Pageview",e.dataType="PageviewData",e}(),Fe=function(){function e(e,t,n,i,r,o,s){this.aiDataContract={ver:1,name:0,url:0,duration:0,perfTotal:0,networkConnect:0,sentRequest:0,receivedResponse:0,domProcessing:0,properties:0,measurements:0};var a=this;a.ver=2,a.url=_e(e,n),a.name=be(e,t)||u,a.properties=we(e,r),a.measurements=Ee(e,o),s&&(a.domProcessing=s.domProcessing,a.duration=s.duration,a.networkConnect=s.networkConnect,a.perfTotal=s.perfTotal,a.receivedResponse=s.receivedResponse,a.sentRequest=s.sentRequest)}return e.envelopeType="Microsoft.ApplicationInsights.{0}.PageviewPerformance",e.dataType="PageviewPerformanceData",e}();function Me(e,t){var n=e;return n&&!F(n)&&(JSON&&JSON.stringify?(n=JSON.stringify(e),!t||n&&"{}"!==n||(n=k(e.toString)?e.toString():""+e)):n=e+" - (Missing JSON.stringify)"),n||""}function Le(e,t){var n=e;return e&&(n&&!F(n)&&(n=e.message||e.description||n),n&&!F(n)&&(n=Me(n,!0)),e.filename&&(n=n+" @"+(e.filename||"")+":"+(e.lineno||"?")+":"+(e.colno||"?"))),t&&"String"!==t&&"Object"!==t&&"Error"!==t&&-1===(n||"").indexOf(t)&&(n=t+": "+n),n||""}function qe(e){return e&&e.src&&F(e.src)&&e.obj&&I(e.obj)}function je(e){var t=e||"";F(t)||(t=F(t.stack)?t.stack:""+t);var n=t.split("\n");return{src:t,obj:n}}function Ue(e){var t=null;if(e)try{if(e.stack)t=je(e.stack);else if(e.error&&e.error.stack)t=je(e.error.stack);else if(e.exception&&e.exception.stack)t=je(e.exception.stack);else if(qe(e))t=e;else if(qe(e.stackDetails))t=e.stackDetails;else if(window&&window.opera&&e.message)t=function(e){for(var t=[],n=e.split("\n"),i=0;i1?n[1]:""}catch(e){}return t}function Ke(e){if(e)try{if(!F(e)){var t=He(e),n=Me(e,!1);return n&&"{}"!==n||(e.error&&(t=He(e=e.error)),n=Me(e,!0)),0!==n.indexOf(t)&&"String"!==t?t+":"+n:n}}catch(e){}return""+(e||"")}var We=function(){function e(e,t,n,i,r,o){this.aiDataContract={ver:1,exceptions:1,severityLevel:0,properties:0,measurements:0};var s=this;s.ver=2,function(e){try{if(P(e))return"ver"in e&&"exceptions"in e&&"properties"in e}catch(e){}return!1}(t)?(s.exceptions=t.exceptions||[],s.properties=t.properties,s.measurements=t.measurements,t.severityLevel&&(s.severityLevel=t.severityLevel),t.id&&(s.id=t.id),t.problemGroup&&(s.problemGroup=t.problemGroup),w(t.isManual)||(s.isManual=t.isManual)):(n||(n={}),s.exceptions=[new ze(e,t,n)],s.properties=we(e,n),s.measurements=Ee(e,i),r&&(s.severityLevel=r),o&&(s.id=o))}return e.CreateAutoException=function(e,t,n,i,r,o,s,a){var c,u=He(r||o||e);return(c={}).message=Le(e,u),c.url=t,c.lineNumber=n,c.columnNumber=i,c.error=Ke(r||o||e),c.evt=Ke(o||e),c.typeName=u,c.stackDetails=Ue(s||r||o),c.errorSrc=a,c},e.CreateFromInterface=function(t,n,i,o){var s=n.exceptions&&U(n.exceptions,(function(e){return ze.CreateFromInterface(t,e)}));return new e(t,(0,r.uc)((0,r.uc)({},n),{exceptions:s}),i,o)},e.prototype.toInterface=function(){var e,t=this,n=t.exceptions,i=t.properties,r=t.measurements,o=t.severityLevel,s=t.problemGroup,a=t.id,c=t.isManual,u=n instanceof Array&&U(n,(function(e){return e.toInterface()}))||void 0;return(e={ver:"4.0"}).exceptions=u,e.severityLevel=o,e.properties=i,e.measurements=r,e.problemGroup=s,e.id=a,e.isManual=c,e},e.CreateSimpleException=function(e,t,n,i,r,o){var s;return{exceptions:[(s={},s.hasFullStack=!0,s.message=e,s.stack=r,s.typeName=t,s)]}},e.envelopeType="Microsoft.ApplicationInsights.{0}.Exception",e.dataType="ExceptionData",e.formatError=Ke,e}(),ze=function(){function e(e,t,n){this.aiDataContract={id:0,outerId:0,typeName:1,message:1,hasFullStack:0,stack:0,parsedStack:2};var i=this;if(function(e){try{if(P(e))return"hasFullStack"in e&&"typeName"in e}catch(e){}return!1}(t))i.typeName=t.typeName,i.message=t.message,i.stack=t.stack,i.parsedStack=t.parsedStack||[],i.hasFullStack=t.hasFullStack;else{var r=t,o=r&&r.evt;A(r)||(r=r.error||o||r),i.typeName=be(e,He(r))||u,i.message=Re(e,Le(t||r,i.typeName))||u;var s=t.stackDetails||Ue(t);i.parsedStack=function(e){var t,n=e.obj;if(n&&n.length>0){t=[];var i=0,r=0;if(q(n,(function(e){var n=e.toString();if(Ve.regex.test(n)){var o=new Ve(n,i++);r+=o.sizeInBytes,t.push(o)}})),r>32768)for(var o=0,s=t.length-1,a=0,c=o,u=s;o32768){var l=u-c+1;t.splice(c,l);break}c=o,u=s,o++,s--}}return t}(s),I(i.parsedStack)&&U(i.parsedStack,(function(t){return t.assembly=be(e,t.assembly)})),i.stack=De(e,function(e){var t="";return e&&(e.obj?q(e.obj,(function(e){t+=e+"\n"})):t=e.src||""),t}(s)),i.hasFullStack=I(i.parsedStack)&&i.parsedStack.length>0,n&&(n.typeName=n.typeName||i.typeName)}}return e.prototype.toInterface=function(){var e,t=this,n=t.parsedStack instanceof Array&&U(t.parsedStack,(function(e){return e.toInterface()}));return(e={id:t.id,outerId:t.outerId,typeName:t.typeName,message:t.message,hasFullStack:t.hasFullStack,stack:t.stack}).parsedStack=n||void 0,e},e.CreateFromInterface=function(t,n){var i=n.parsedStack instanceof Array&&U(n.parsedStack,(function(e){return Ve.CreateFromInterface(e)}))||n.parsedStack;return new e(t,(0,r.uc)((0,r.uc)({},n),{parsedStack:i}))},e}(),Ve=function(){function e(t,n){this.aiDataContract={level:1,method:1,assembly:0,fileName:0,line:0};var i=this;if(i.sizeInBytes=0,"string"==typeof t){var r=t;i.level=n,i.method="",i.assembly=K(r),i.fileName="",i.line=0;var o=r.match(e.regex);o&&o.length>=5&&(i.method=K(o[2])||i.method,i.fileName=K(o[4]),i.line=parseInt(o[5])||0)}else i.level=t.level,i.method=t.method,i.assembly=t.assembly,i.fileName=t.fileName,i.line=t.line,i.sizeInBytes=0;i.sizeInBytes+=i.method.length,i.sizeInBytes+=i.fileName.length,i.sizeInBytes+=i.assembly.length,i.sizeInBytes+=e.baseSize,i.sizeInBytes+=i.level.toString().length,i.sizeInBytes+=i.line.toString().length}return e.CreateFromInterface=function(t){return new e(t,null)},e.prototype.toInterface=function(){var e=this;return{level:e.level,method:e.method,assembly:e.assembly,fileName:e.fileName,line:e.line}},e.regex=/^([\s]+at)?[\s]{0,50}([^\@\()]+?)[\s]{0,50}(\@|\()([^\(\n]+):([0-9]+):([0-9]+)(\)?)$/,e.baseSize=58,e}(),Be=function(){this.aiDataContract={name:1,kind:0,value:1,count:0,min:0,max:0,stdDev:0},this.kind=0},$e=function(){function e(e,t,n,i,r,o,s,a,c){this.aiDataContract={ver:1,metrics:1,properties:0};var l=this;l.ver=2;var d=new Be;d.count=i>0?i:void 0,d.max=isNaN(o)||null===o?void 0:o,d.min=isNaN(r)||null===r?void 0:r,d.name=be(e,t)||u,d.value=n,d.stdDev=isNaN(s)||null===s?void 0:s,l.metrics=[d],l.properties=we(e,a),l.measurements=Ee(e,c)}return e.envelopeType="Microsoft.ApplicationInsights.{0}.Metric",e.dataType="MetricData",e}(),Ge="toGMTString",Je="toUTCString",Ye=null,Ze=null,Xe=null,Qe=ae(),et={},tt={};function nt(e){return!e||e.isEnabled()}function it(e,t){return!!(t&&e&&I(e.ignoreCookies))&&-1!==e.ignoreCookies.indexOf(t)}function rt(e,t){var n,i=function(e){var t=e.cookieCfg=e.cookieCfg||{};if(Z(t,"domain",e.cookieDomain,E,w),Z(t,"path",e.cookiePath||"/",null,w),w(t.enabled)){var n=void 0;D(e.isCookieUseDisabled)||(n=!e.isCookieUseDisabled),D(e.disableCookiesUsage)||(n=!e.disableCookiesUsage),t.enabled=n}return t}(e||tt),r=i.path||"/",o=i.domain,s=!1!==i.enabled,a=((n={isEnabled:function(){var e=s&&ot(t),n=tt._ckMgr;return e&&n&&a!==n&&(e=nt(n)),e}}).setEnabled=function(e){s=!1!==e},n.set=function(e,t,n,s,c){var u,d=!1;if(nt(a)&&!function(e,t){return!!(t&&e&&I(e.blockedCookies)&&-1!==e.blockedCookies.indexOf(t))||it(e,t)}(i,e)){var p={},g=K(t||f),h=g.indexOf(";");if(-1!==h&&(g=K(t.substring(0,h)),p=st(t.substring(h+1))),Z(p,"domain",s||o,Q,D),!w(n)){var m=de();if(D(p.expires)){var v=J()+1e3*n;if(v>0){var S=new Date;S.setTime(v),Z(p,"expires",at(S,m?Ge:Je)||at(S,m?Ge:Je)||f,Q)}}m||Z(p,"max-age",f+n,null,D)}var C=typeof location===l.fK&&location?location:oe("location");C&&"https:"===C.protocol&&(Z(p,"secure",null,null,D),null===Ze&&(u=(ce()||{}).userAgent,Ze=!(F(u)&&(O(u,"CPU iPhone OS 12")||O(u,"iPad; CPU OS 12")||O(u,"Macintosh; Intel Mac OS X 10_14")&&O(u,"Version/")&&O(u,"Safari")||O(u,"Macintosh; Intel Mac OS X 10_14")&&function(e,t){var n=!1;return e&&t&&!(n=e===t)&&(n=y?e.endsWith(t):function(e,t){var n=!1,i=t?t.length:0,r=e?e.length:0;if(i&&r&&r>=i&&!(n=e===t)){for(var o=r-1,s=i-1;s>=0;s--){if(e[o]!=t[s])return!1;o--}n=!0}return n}(e,t)),n}(u,"AppleWebKit/605.1.15 (KHTML, like Gecko)")||O(u,"Chrome/5")||O(u,"Chrome/6")||O(u,"UnrealEngine")&&!O(u,"Chrome")||O(u,"UCBrowser/12")||O(u,"UCBrowser/11")))),Ze&&Z(p,"SameSite","None",null,D)),Z(p,"path",c||r,null,D),(i.setCookie||lt)(e,ct(g,p)),d=!0}return d},n.get=function(e){var t=f;return nt(a)&&!it(i,e)&&(t=(i.getCookie||ut)(e)),t},n.del=function(e,t){var n=!1;return nt(a)&&(n=a.purge(e,t)),n},n.purge=function(e,n){var r,o=!1;if(ot(t)){var s=((r={}).path=n||"/",r.expires="Thu, 01 Jan 1970 00:00:01 GMT",r);de()||(s["max-age"]="0"),(i.delCookie||lt)(e,ct(f,s)),o=!0}return o},n);return a._ckMgr=a,a}function ot(e){if(null===Ye){Ye=!1;try{Ye=void 0!==(Qe||{}).cookie}catch(t){Se(e,2,68,"Cannot access document.cookie - "+Y(t),{exception:fe(t)})}}return Ye}function st(e){var t={};return e&&e.length&&q(K(e).split(";"),(function(e){if(e=K(e||f)){var n=e.indexOf("=");-1===n?t[e]=null:t[K(e.substring(0,n))]=K(e.substring(n+1))}})),t}function at(e,t){return k(e[t])?e[t]():null}function ct(e,t){var n=e||f;return N(t,(function(e,t){n+="; "+e+(w(t)?f:"="+t)})),n}function ut(e){var t=f;if(Qe){var n=Qe.cookie||f;Xe!==n&&(et=st(n),Xe=n),t=K(et[e]||f)}return t}function lt(e,t){Qe&&(Qe.cookie=e+"="+t)}var dt=4294967296,ft=4294967295,pt=!1,gt=123456789,ht=987654321;function mt(e){e<0&&(e>>>=0),gt=123456789+e&ft,ht=987654321-e&ft,pt=!0}function vt(){try{var e=2147483647&J();mt((Math.random()*dt^e)+e)}catch(e){}}function yt(e){var t=0,n=oe("crypto")||oe("msCrypto");return n&&n.getRandomValues&&(t=n.getRandomValues(new Uint32Array(1))[0]&ft),0===t&&de()&&(pt||vt(),t=St()&ft),0===t&&(t=Math.floor(dt*Math.random()|0)),e||(t>>>=0),t}function St(e){var t=((ht=36969*(65535&ht)+(ht>>16)&ft)<<16)+(65535&(gt=18e3*(65535>)+(gt>>16)&ft))>>>0&ft|0;return e||(t>>>=0),t}function Ct(e){void 0===e&&(e=22);for(var t=yt()>>>0,n=0,i=f;i.length>>=6,5===n&&(t=(yt()<<2&4294967295|3&t)>>>0,n=0);return i}var Tt=l.RJ,bt="."+Ct(6),_t=0;function Rt(e){return 1===e.nodeType||9===e.nodeType||!+e.nodeType}function Dt(e,t){return void 0===t&&(t=!1),x(e+_t+++(t?".2.8.11":f)+bt)}var wt,Et=(Dt("aiEvtPageHide"),Dt("aiEvtPageShow"),/\.[\.]+/g),Pt=/[\.]+$/,kt=1,xt=wt={id:Dt("_aiData-events.2.8.11"),accept:function(e){return Rt(e)},get:function(e,t,n,i){var r=e[wt.id];return r?r[x(t)]:(i&&((r=function(e,t){var n=t[e.id];if(!n){n={};try{Rt(t)&&(function(e,t,n){if(Tt)try{return Tt(e,t,{value:n,enumerable:!1,configurable:!0}),!0}catch(e){}return!1}(t,e.id,n)||(t[e.id]=n))}catch(e){}}return n}(wt,e))[x(t)]=n),n)},kill:function(e,t){if(e&&e[t])try{delete e[t]}catch(e){}}},Nt=/^([^.]*)(?:\.(.+)|)/;function Ot(e){return e&&e.replace?e.replace(/^[\s\.]+|(?=[\s\.])[\.\s]+$/g,f):e}function It(e,t,n,i,r){var o;void 0===r&&(r=!1);var s=!1;if(e)try{var a=function(e,t){var n;if(t){var i=f;I(t)?(i=f,q(t,(function(e){(e=Ot(e))&&("."!==e[0]&&(e="."+e),i+=e)}))):i=Ot(t),i&&("."!==i[0]&&(i="."+i),e=(e||f)+i)}var r=Nt.exec(e||f)||[];return(n={}).type=r[1],n.ns=(r[2]||f).replace(Et,".").replace(Pt,f).split(".").sort().join("."),n}(t,i);if(s=function(e,t,n,i){var r=!1;return e&&t&&t.type&&n&&(e.addEventListener?(e.addEventListener(t.type,n,i),r=!0):e.attachEvent&&(e.attachEvent("on"+t.type,n),r=!0)),r}(e,a,n,r),s&&xt.accept(e)){var c=((o={guid:kt++,evtName:a}).handler=n,o.capture=r,o);(function(e,t,n){void 0===n&&(n=!0);var i=xt.get(e,"events",{},n),r=i[t];return r||(r=i[t]=[]),r})(e,a.type).push(c)}}catch(e){}return s}var At,Ft=null;function Mt(){for(var e,t=["0","1","2","3","4","5","6","7","8","9","a","b","c","d","e","f"],n=f,i=0;i<4;i++)n+=t[15&(e=yt())]+t[e>>4&15]+t[e>>8&15]+t[e>>12&15]+t[e>>16&15]+t[e>>20&15]+t[e>>24&15]+t[e>>28&15];var r=t[8+(3&yt())|0];return n.substr(0,8)+n.substr(9,4)+"4"+n.substr(13,3)+r+n.substr(16,3)+n.substr(19,12)}var Lt={_canUseCookies:void 0,isTypeof:function(e,t){return typeof e===t},isUndefined:D,isNullOrUndefined:w,hasOwnProperty:function(e,t){return!(!e||!l.CY.call(e,t))},isFunction:k,isObject:P,isDate:function(e){return!(!e||"[object Date]"!==T.call(e))},isArray:I,isError:A,isString:F,isNumber:function(e){return"number"==typeof e},isBoolean:M,toISOString:L,arrForEach:q,arrIndexOf:j,arrMap:U,arrReduce:H,strTrim:K,objCreate:d.pu,objKeys:V,objDefineAccessors:B,addEventHandler:function(e,t,n){var i=!1,r=se()?window:oe(te);r&&(i=It(r,e,t,n),i=It(r.body,e,t,n)||i);var o=ae();return o&&(i=It(o,e,t,n)||i),i},dateNow:J,isIE:de,disableCookies:function(){(n=function(e,t){var n=rt._ckMgr||tt._ckMgr;return n||(n=rt._ckMgr=rt(e,t),tt._ckMgr=n),n}(e,t),i=Lt._canUseCookies,null===Ft&&(Ft=[],At=i,B(Lt,"_canUseCookies",(function(){return At}),(function(e){At=e,q(Ft,(function(t){t.setEnabled(e)}))}))),-1===j(Ft,n)&&Ft.push(n),M(i)&&n.setEnabled(i),M(At)&&n.setEnabled(At),n).setEnabled(!1);var e,t,n,i},newGuid:function(){var e=Mt();return e.substring(0,8)+"-"+e.substring(8,12)+"-"+e.substring(12,16)+"-"+e.substring(16,20)+"-"+e.substring(20)},perfNow:function(){var e=oe("performance");return e&&e.now?e.now():J()},newId:Ct,randomValue:function(e){return e>0?Math.floor(yt()/ft*(e+1))>>>0:0},random32:yt,mwcRandomSeed:function(e){e?mt(e):vt()},mwcRandom32:St,generateW3CId:Mt};function qt(e){var t={};return N(e,(function(e,n){t[e]=n,t[n]=e})),$(t)}var jt,Ut=(jt={},N({requestContextHeader:[0,"Request-Context"],requestContextTargetKey:[1,"appId"],requestContextAppIdFormat:[2,"appId=cid-v1:"],requestIdHeader:[3,"Request-Id"],traceParentHeader:[4,"traceparent"],traceStateHeader:[5,"tracestate"],sdkContextHeader:[6,"Sdk-Context"],sdkContextHeaderAppIdRequest:[7,"appId"],requestContextHeaderLowerCase:[8,"request-context"]},(function(e,t){jt[e]=t[1],jt[t[0]]=t[1]})),$(jt)),Ht=qt({LocalStorage:0,SessionStorage:1}),Kt=void qt({AI:0,AI_AND_W3C:1,W3C:2});function Wt(e){try{if(w((0,d.Rd)()))return null;var t=(new Date).toString(),n=oe(e===Ht.LocalStorage?"localStorage":"sessionStorage");n.setItem(t,t);var i=n.getItem(t)!==t;if(n.removeItem(t),!i)return n}catch(e){}return null}function zt(){return Vt()?Wt(Ht.SessionStorage):null}function Vt(e){return(e||void 0===Kt)&&(Kt=!!Wt(Ht.SessionStorage)),Kt}function Bt(e,t,n){var i=zt();if(null!==i)try{return i.setItem(t,n),!0}catch(t){Kt=!1,Se(e,2,4,"Browser failed write to session storage. "+Y(t),{exception:fe(t)})}return!1}var $t=ae()||{},Gt=0,Jt=[null,null,null,null,null];function Yt(e,t){var n=function(e,t){var n=null;if(e){var i=e.match(/(\w{1,150}):\/\/([^\/:]{1,256})(:\d{1,20})?/i);if(null!=i&&i.length>2&&F(i[2])&&i[2].length>0&&(n=i[2]||"",t&&i.length>2)){var r=(i[1]||"").toLowerCase(),o=i[3]||"";("http"===r&&":80"===o||"https"===r&&":443"===o)&&(o=""),n+=o}}return n}(e,t)||"";if(n){var i=n.match(/(www\d{0,5}\.)?([^\/:]{1,256})(:\d{1,20})?/i);if(null!=i&&i.length>3&&F(i[2])&&i[2].length>0)return i[2]+(i[3]||"")}return n}var Zt=[a+c,"https://breeze.aimon.applicationinsights.io/v2/track","https://dc-int.services.visualstudio.com/v2/track"];function Xt(e){return-1!==j(Zt,e.toLowerCase())}var Qt=function(){function e(e,t,n,i,r,o,s,a,c,u,l,d){void 0===c&&(c="Ajax"),this.aiDataContract={id:1,ver:1,name:0,resultCode:0,duration:0,success:0,data:0,target:0,type:0,properties:0,measurements:0,kind:0,value:0,count:0,min:0,max:0,stdDev:0,dependencyKind:0,dependencySource:0,commandName:0,dependencyTypeName:0};var f=this;f.ver=2,f.id=t,f.duration=Ie(r),f.success=o,f.resultCode=s+"",f.type=be(e,c);var p=function(e,t,n,i){var r,o,s,a,c,u=i,l=i;if(t&&t.length>0){var d=(o=t,c=(a=Jt)[s=Gt],$t.createElement?a[s]||(c=a[s]=$t.createElement("a")):c={host:Yt(o,!0)},c.href=o,++s>=a.length&&(s=0),Gt=s,c);if(r=d.host,!u)if(null!=d.pathname){var f=0===d.pathname.length?"/":d.pathname;"/"!==f.charAt(0)&&(f="/"+f),l=d.pathname,u=be(e,n?n+" "+f:f)}else u=be(e,t)}else r=i,u=i;return{target:r,name:u,data:l}}(e,n,a,i);f.data=_e(e,i)||p.data,f.target=be(e,p.target),u&&(f.target="".concat(f.target," | ").concat(u)),f.name=be(e,p.name),f.properties=we(e,l),f.measurements=Ee(e,d)}return e.envelopeType="Microsoft.ApplicationInsights.{0}.RemoteDependency",e.dataType="RemoteDependencyData",e}(),en="",tn=l.RJ,nn=l.Pw.freeze,rn=(l.Pw.seal,l.Pw.keys),on=String[l.hB],sn=(on.trim,on.endsWith,on.startsWith,Date[l.hB].toISOString),an=Array.isArray,cn=l.V4.toString,un=l.CY.toString,ln=un.call(l.Pw),dn=/-([a-z])/g,fn=/([^\w\d_$])/g,pn=/^(\d+[\w\d_$])/,gn=Object.getPrototypeOf;function hn(e){return void 0===e||typeof e===l.jA}function mn(e){return null===e||hn(e)}function vn(e){return!(!e||typeof e!==l.fK)}function yn(e){return!(!e||typeof e!==l.cb)}function Sn(e){var t=e;return t&&_n(t)&&(t=(t=(t=t.replace(dn,(function(e,t){return t.toUpperCase()}))).replace(fn,"_")).replace(pn,(function(e,t){return"_"+t}))),t}function Cn(e,t){if(e)for(var n in e)l.CY.call(e,n)&&t.call(e,n,e[n])}function Tn(e,t){return!(!e||!t)&&-1!==e.indexOf(t)}var bn=an||function(e){return!(!e||"[object Array]"!==cn.call(e))};function _n(e){return"string"==typeof e}function Rn(e){return"boolean"==typeof e}function Dn(e){var t=!1;if(e&&"object"==typeof e){var n=gn?gn(e):function(e){if(e){if(gn)return gn(e);var t=e.__proto__||e[l.hB]||e.constructor;if(t)return t}return null}(e);n?(n.constructor&&l.CY.call(n,"constructor")&&(n=n.constructor),t=typeof n===l.cb&&un.call(n)===ln):t=!0}return t}function wn(e,t,n){var i=e.length;try{for(var r=0;r0&&Rn(a)&&(u=a,a=s[d]||{},d++),vn(a)||(a={});d=o)){var i=!0,s="AITR_"+n.messageId;if(c[s]?i=!1:c[s]=!0,i&&(t<=r&&(e.queue.push(n),a++,u(1===t?"error":"warn",n)),a===o)){var l="Internal events throttle limit per PageView reached for this app.",d=new fi(23,l,!1);e.queue.push(d),1===t?e.errorToConsole(l):e.warnToConsole(l)}}}function u(e,n){var i=function(e){var t,n=ui;return n||!0===e.disableDbgExt||(n=ui||((t=Yn("Microsoft"))&&(ui=t.ApplicationInsights),ui)),n?n.ChromeDbgExt:null}(t||{});i&&i.diagLog&&i.diagLog(e,n)}!function(e){n=An(e.loggingLevelConsole,0),r=An(e.loggingLevelTelemetry,1),o=An(e.maxMessageLimit,25),s=An(e.enableDebugExceptions,!1)}(t||{}),e.consoleLoggingLevel=function(){return n},e.telemetryLoggingLevel=function(){return r},e.maxInternalMessageLimit=function(){return o},e.enableDebugExceptions=function(){return s},e.throwInternal=function(t,r,o,a,l){void 0===l&&(l=!1);var d=new fi(r,o,l,a);if(s)throw ri(d);var f=1===t?"errorToConsole":"warnToConsole";if(hn(d.message))u("throw"+(1===t?"Critical":"Warning"),d);else{if(l){var p=+d.messageId;!c[p]&&n>=t&&(e[f](d.message),c[p]=!0)}else n>=t&&e[f](d.message);i(t,d)}},e.warnToConsole=function(e){di("warn",e),u("warning",e)},e.errorToConsole=function(e){di("error",e),u("error",e)},e.resetInternalMessageCount=function(){a=0,c={}},e.logInternalMessage=i}))}return e.__ieDyn=1,e}();function hi(e){return e||new gi}function mi(e,t,n,i,r,o){void 0===o&&(o=!1),hi(e).throwInternal(t,n,i,r,o)}function vi(e,t){hi(e).warnToConsole(t)}var yi=4294967296,Si=4294967295,Ci=!1,Ti=123456789,bi=987654321;function _i(){try{var e=2147483647&Nn();(t=(Math.random()*yi^e)+e)<0&&(t>>>=0),Ti=123456789+t&Si,bi=987654321-t&Si,Ci=!0}catch(e){}var t}function Ri(e){var t=0,n=Yn("crypto")||Yn("msCrypto");return n&&n.getRandomValues&&(t=n.getRandomValues(new Uint32Array(1))[0]&Si),0===t&&function(){var e=ti();if(e&&(e.userAgent!==Bn||null===Vn)){var t=((Bn=e.userAgent)||en).toLowerCase();Vn=Tn(t,Kn)||Tn(t,Wn)}return Vn}()&&(Ci||_i(),t=function(e){var t=((bi=36969*(65535&bi)+(bi>>16)&Si)<<16)+(65535&(Ti=18e3*(65535&Ti)+(Ti>>16)&Si))>>>0&Si|0;return t>>>=0}()&Si),0===t&&(t=Math.floor(yi*Math.random()|0)),e||(t>>>=0),t}var Di=l.RJ,wi="."+function(e){void 0===e&&(e=22);for(var t=Ri()>>>0,n=0,i=en;i.length>>=6,5===n&&(t=(Ri()<<2&4294967295|3&t)>>>0,n=0);return i}(6),Ei=0;function Pi(e){return 1===e.nodeType||9===e.nodeType||!+e.nodeType}function ki(e,t){return void 0===t&&(t=!1),Sn(e+Ei+++(t?".2.8.11":en)+wi)}function xi(e){var t={id:ki("_aiData-"+(e||en)+".2.8.11"),accept:function(e){return Pi(e)},get:function(e,n,i,r){var o=e[t.id];return o?o[Sn(n)]:(r&&((o=function(e,t){var n=t[e.id];if(!n){n={};try{Pi(t)&&(function(e,t,n){if(Di)try{return Di(e,t,{value:n,enumerable:!1,configurable:!0}),!0}catch(e){}return!1}(t,e.id,n)||(t[e.id]=n))}catch(e){}}return n}(t,e))[Sn(n)]=i),i)},kill:function(e,t){if(e&&e[t])try{delete e[t]}catch(e){}}};return t}var Ni="events",Oi=(ki("aiEvtPageHide"),ki("aiEvtPageShow"),/\.[\.]+/g),Ii=/[\.]+$/,Ai=1,Fi=xi("events"),Mi=/^([^.]*)(?:\.(.+)|)/;function Li(e){return e&&e.replace?e.replace(/^[\s\.]+|(?=[\s\.])[\.\s]+$/g,en):e}function qi(e,t){var n;if(t){var i=en;bn(t)?(i=en,wn(t,(function(e){(e=Li(e))&&("."!==e[0]&&(e="."+e),i+=e)}))):i=Li(t),i&&("."!==i[0]&&(i="."+i),e=(e||en)+i)}var r=Mi.exec(e||en)||[];return(n={}).type=r[1],n.ns=(r[2]||en).replace(Oi,".").replace(Ii,en).split(".").sort().join("."),n}function ji(e,t,n){void 0===n&&(n=!0);var i=Fi.get(e,Ni,{},n),r=i[t];return r||(r=i[t]=[]),r}function Ui(e,t,n,i){e&&t&&t.type&&(e.removeEventListener?e.removeEventListener(t.type,n,i):e.detachEvent&&e.detachEvent("on"+t.type,n))}function Hi(e,t,n,i){for(var r=t.length;r--;){var o=t[r];o&&(n.ns&&n.ns!==o.evtName.ns||i&&!i(o)||(Ui(e,o.evtName,o.handler,o.capture),t.splice(r,1)))}}function Ki(e,t){return t?qi("xx",bn(t)?[e].concat(t):[e,t]).ns.split("."):e}function Wi(e,t,n,i,r){var o;void 0===r&&(r=!1);var s=!1;if(e)try{var a=qi(t,i);if(s=function(e,t,n,i){var r=!1;return e&&t&&t.type&&n&&(e.addEventListener?(e.addEventListener(t.type,n,i),r=!0):e.attachEvent&&(e.attachEvent("on"+t.type,n),r=!0)),r}(e,a,n,r),s&&Fi.accept(e)){var c=((o={guid:Ai++,evtName:a}).handler=n,o.capture=r,o);ji(e,a.type).push(c)}}catch(e){}return s}var zi=function(){function e(t,n,i){var r,o=this,s=!1;o.start=Nn(),o.name=t,o.isAsync=i,o.isChildEvt=function(){return!1},yn(n)&&(s=function(e,t,n,i){if(tn)try{var r={enumerable:!0,configurable:!0};return n&&(r.get=n),i&&(r.set=i),tn(e,t,r),!0}catch(e){}return!1}(o,"payload",(function(){return!r&&yn(n)&&(r=n(),n=null),r}))),o.getCtx=function(t){return t?t===e.ParentContextKey||t===e.ChildrenContextKey?o[t]:(o.ctx||{})[t]:null},o.setCtx=function(t,n){t&&(t===e.ParentContextKey?(o[t]||(o.isChildEvt=function(){return!0}),o[t]=n):t===e.ChildrenContextKey?o[t]=n:(o.ctx=o.ctx||{})[t]=n)},o.complete=function(){var t=0,i=o.getCtx(e.ChildrenContextKey);if(bn(i))for(var r=0;r0&&(wn(t,(function(e){try{e.func.call(e.self,e.args)}catch(e){mi(n.logger,2,73,"Unexpected Exception during onComplete - "+ri(e))}})),o=[])}return e},ctx:{core:function(){return n},diagLog:function(){return pi(n,t)},getCfg:function(){return t},getExtCfg:a,getConfig:function(e,n,i){void 0===i&&(i=!1);var r,o=a(e,null);return o&&!mn(o[n])?r=o[n]:t&&!mn(t[n])&&(r=t[n]),mn(r)?i:r},hasNext:function(){return!!r},getNext:function(){return r},setNext:function(e){r=e},iterate:function(e){for(var t;t=s._next();){var n=t.getPlugin();n&&e(n)}},onComplete:function(e,t){for(var n=[],i=2;i0){var s=null;wn(e,(function(e){if(o||i!==e||(o=!0),o&&e&&yn(e.processTelemetry)){var a=function(e,t,n){var i,r=null,o=yn(e.processTelemetry),s=yn(e.setNextPlugin),a={getPlugin:function(){return e},getNext:function(){return r},processTelemetry:function(i,u){c(u=u||function(){var i;return e&&yn(e._getTelCtx)&&(i=e._getTelCtx()),i||(i=Yi(a,t,n)),i}(),(function(t){if(!e||!o)return!1;var n=$i(e);return!n.teardown&&!n.disabled&&(s&&e.setNextPlugin(r),e.processTelemetry(i,t),!0)}),"processTelemetry",(function(){return{item:i}}),!i.sync)||u.processNext(i)},unload:function(t,n){c(t,(function(){var i=!1;if(e){var r=$i(e),o=e.core||r.core;!e||o&&o!==t.core()||r.teardown||(r.core=null,r.teardown=!0,r.isInitialized=!1,e.teardown&&!0===e.teardown(t,n)&&(i=!0))}return i}),"unload",(function(){}),n.isAsync)||t.processNext(n)},update:function(t,n){c(t,(function(){var i=!1;if(e){var r=$i(e),o=e.core||r.core;!e||o&&o!==t.core()||r.teardown||e.update&&!0===e.update(t,n)&&(i=!0)}return i}),"update",(function(){}),!1)||t.processNext(n)},_id:i=e?e.identifier+"-"+e.priority+"-"+Gi++:"Unknown-0-"+Gi++,_setNext:function(e){r=e}};function c(t,n,o,s,a){var c=!1,u=e?e.identifier:"TelemetryPluginChain",l=t._hasRun;return l||(l=t._hasRun={}),t.setNext(r),e&&function(e,t,n,i,r){if(e){var s=e;if(s.getPerfMgr&&(s=s.getPerfMgr()),s){var a=void 0,c=s.getCtx(Vi);try{if(a=s.create(u+":"+o,i,r)){if(c&&a.setCtx&&(a.setCtx(zi.ParentContextKey,c),c.getCtx&&c.setCtx)){var l=c.getCtx(zi.ChildrenContextKey);l||(l=[],c.setCtx(zi.ChildrenContextKey,l)),l.push(a)}return s.setCtx(Vi,a),n()}}catch(e){a&&a.setCtx&&a.setCtx("exception",e)}finally{a&&s.fire(a),s.setCtx(Vi,c)}}}n()}(t.core(),0,(function(){l[i]=!0;try{var e=r?r._id:en;e&&(l[e]=!1),c=n(t)}catch(e){var s=!r||l[r._id];s&&(c=!0),r&&s||mi(t.diagLog(),1,73,"Plugin ["+u+"] failed during "+o+" - "+ri(e)+", run flags: "+ri(l))}}),s,a),c}return xn(a)}(e,t,n);r||(r=a),s&&s._setNext(a),s=a}}))}return i&&!r?Qi([i],t,n):r}var er=function(){function e(){var t,n,r,o,s,a=this;function c(e){void 0===e&&(e=null);var t=e;if(!t){var i=n||Yi(null,{},a.core);t=r&&r.getPlugin?i.createNew(null,r.getPlugin):i.createNew(null,r)}return t}function u(e,t,i){e&&In(e,"extensionConfig",[],null,mn),!i&&t&&(i=t.getProcessTelContext().getNext());var o=r;r&&r.getPlugin&&(o=r.getPlugin()),a.core=t,n=Yi(i,e,t,o)}function l(){var e;t=!1,a.core=null,n=null,r=null,s=[],e=[],o={add:function(t){t&&e.push(t)},run:function(t,n){wn(e,(function(e){try{e(t,n)}catch(e){mi(t.diagLog(),2,73,"Unexpected error calling unload handler - "+ri(e))}})),e=[]}}}l(),(0,i.Z)(e,a,(function(e){e.initialize=function(e,n,i,r){u(e,n,r),t=!0},e.teardown=function(t,n){var i,a=e.core;if(a&&(!t||a===t.core())){var c,u=!1,d=t||Zi(null,a,r&&r.getPlugin?r.getPlugin():r),f=n||((i={reason:0}).isAsync=!1,i);return e._doTeardown&&!0===e._doTeardown(d,f,p)?c=!0:p(),c}function p(){if(!u){u=!0,o.run(d,n);var e=s;s=[],wn(e,(function(e){e.rm()})),!0===c&&d.processNext(f),l()}}},e.update=function(t,n){var i=e.core;if(i&&(!t||i===t.core())){var o,s=!1,a=t||Xi(null,i,r&&r.getPlugin?r.getPlugin():r),c=n||{reason:0};return e._doUpdate&&!0===e._doUpdate(a,c,l)?o=!0:l(),o}function l(){s||(s=!0,u(a.getCfg(),a.core(),a.getNext()))}},e._addHook=function(e){e&&(bn(e)?s=s.concat(e):s.push(e))},Mn(e,"_addUnloadCb",(function(){return o}),"add")})),a.diagLog=function(e){return c(e).diagLog()},a.isInitialized=function(){return t},a.setInitialized=function(e){t=e},a.setNextPlugin=function(e){r=e},a.processNext=function(e,t){t?t.processNext(e):r&&yn(r.processTelemetry)&&r.processTelemetry(e,null)},a._getTelCtx=c}return e.__ieDyn=1,e}();function tr(e){var t="ai."+e+".";return function(e){return t+e}}var nr,ir=tr("application"),rr=tr("device"),or=tr("location"),sr=tr("operation"),ar=tr("session"),cr=tr("user"),ur=tr("cloud"),lr=tr("internal"),dr=function(e){function t(){return e.call(this)||this}return(0,r.ne)(t,e),t}((nr={applicationVersion:ir("ver"),applicationBuild:ir("build"),applicationTypeId:ir("typeId"),applicationId:ir("applicationId"),applicationLayer:ir("layer"),deviceId:rr("id"),deviceIp:rr("ip"),deviceLanguage:rr("language"),deviceLocale:rr("locale"),deviceModel:rr("model"),deviceFriendlyName:rr("friendlyName"),deviceNetwork:rr("network"),deviceNetworkName:rr("networkName"),deviceOEMName:rr("oemName"),deviceOS:rr("os"),deviceOSVersion:rr("osVersion"),deviceRoleInstance:rr("roleInstance"),deviceRoleName:rr("roleName"),deviceScreenResolution:rr("screenResolution"),deviceType:rr("type"),deviceMachineName:rr("machineName"),deviceVMName:rr("vmName"),deviceBrowser:rr("browser"),deviceBrowserVersion:rr("browserVersion"),locationIp:or("ip"),locationCountry:or("country"),locationProvince:or("province"),locationCity:or("city"),operationId:sr("id"),operationName:sr("name"),operationParentId:sr("parentId"),operationRootId:sr("rootId"),operationSyntheticSource:sr("syntheticSource"),operationCorrelationVector:sr("correlationVector"),sessionId:ar("id"),sessionIsFirst:ar("isFirst"),sessionIsNew:ar("isNew"),userAccountAcquisitionDate:cr("accountAcquisitionDate"),userAccountId:cr("accountId"),userAgent:cr("userAgent"),userId:cr("id"),userStoreRegion:cr("storeRegion"),userAuthUserId:cr("authUserId"),userAnonymousUserAcquisitionDate:cr("anonUserAcquisitionDate"),userAuthenticatedUserAcquisitionDate:cr("authUserAcquisitionDate"),cloudName:ur("name"),cloudRole:ur("role"),cloudRoleVer:ur("roleVer"),cloudRoleInstance:ur("roleInstance"),cloudEnvironment:ur("environment"),cloudLocation:ur("location"),cloudDeploymentUnit:ur("deploymentUnit"),internalNodeName:lr("nodeName"),internalSdkVersion:lr("sdkVersion"),internalAgentVersion:lr("agentVersion"),internalSnippet:lr("snippet"),internalSdkSrc:lr("sdkSrc")},function(){var e=this;nr&&N(nr,(function(t,n){e[t]=n}))})),fr=new dr,pr=function(e,t,n){var i=this,r=this;r.ver=1,r.sampleRate=100,r.tags={},r.name=be(e,n)||u,r.data=t,r.time=L(new Date),r.aiDataContract={time:1,iKey:1,name:1,sampleRate:function(){return 100===i.sampleRate?4:1},tags:1,data:1}},gr=function(e,t){this.aiDataContract={baseType:1,baseData:1},this.baseType=e,this.baseData=t},hr="disableInstrumentationKeyValidation",mr="true";function vr(e,t,n){return In(e,t,n,Fn)}function yr(e,t,n){mn(e)||Cn(e,(function(e,i){!function(e){return"number"==typeof e}(i)?_n(i)?t[e]=i:ni()&&(t[e]=ii().stringify(i)):n[e]=i}))}function Sr(e,t){mn(e)||Cn(e,(function(n,i){e[n]=i||t}))}function Cr(e,t,n,i){var o=new pr(e,i,t);vr(o,"sampleRate",n.sampleRate),(n.baseData||{}).startTime&&(o.time=function(e){if(e)return sn?e.toISOString():function(e){if(e&&e.getUTCFullYear){var t=function(e){var t=String(e);return 1===t.length&&(t="0"+t),t};return e.getUTCFullYear()+"-"+t(e.getUTCMonth()+1)+"-"+t(e.getUTCDate())+"T"+t(e.getUTCHours())+":"+t(e.getUTCMinutes())+":"+t(e.getUTCSeconds())+"."+String((e.getUTCMilliseconds()/1e3).toFixed(3)).slice(2,5)+"Z"}}(e)}(n.baseData.startTime)),o.iKey=n.iKey;var s=n.iKey.replace(/-/g,"");return o.name=o.name.replace("{0}",s),function(e,t,n){var i=n.tags=n.tags||{},o=t.ext=t.ext||{},s=t.tags=t.tags||[],a=o.user;a&&(vr(i,fr.userAuthUserId,a.authId),vr(i,fr.userId,a.id||a.localId));var c=o.app;c&&vr(i,fr.sessionId,c.sesId);var u=o.device;u&&(vr(i,fr.deviceId,u.id||u.localId),vr(i,fr.deviceType,u.deviceClass),vr(i,fr.deviceIp,u.ip),vr(i,fr.deviceModel,u.model),vr(i,fr.deviceType,u.deviceType));var l=t.ext.web;if(l){vr(i,fr.deviceLanguage,l.browserLang),vr(i,fr.deviceBrowserVersion,l.browserVer),vr(i,fr.deviceBrowser,l.browser);var d=n.data=n.data||{},f=d.baseData=d.baseData||{},p=f.properties=f.properties||{};vr(p,"domain",l.domain),vr(p,"isManual",l.isManual?mr:null),vr(p,"screenRes",l.screenRes),vr(p,"userConsent",l.userConsent?mr:null)}var g=o.os;g&&vr(i,fr.deviceOS,g.name);var h=o.trace;h&&(vr(i,fr.operationParentId,h.parentID),vr(i,fr.operationName,be(e,h.name)),vr(i,fr.operationId,h.traceID));for(var m={},v=s.length-1;v>=0;v--)Cn(s[v],(function(e,t){m[e]=t})),s.splice(v,1);Cn(s,(function(e,t){m[e]=t}));var y=(0,r.uc)((0,r.uc)({},i),m);y[fr.internalSdkVersion]||(y[fr.internalSdkVersion]="javascript:".concat(br.Version)),n.tags=Ln(y)}(e,n,o),n.tags=n.tags||[],Ln(o)}function Tr(e,t){mn(t.baseData)&&mi(e,1,46,"telemetryItem.baseData cannot be null.")}var br={Version:"2.8.11"};function _r(e,t,n){Tr(e,t);var i={},r={};t.baseType!==Ne.dataType&&(i.baseTypeSource=t.baseType),t.baseType===Ne.dataType?(i=t.baseData.properties||{},r=t.baseData.measurements||{}):t.baseData&&yr(t.baseData,i,r),yr(t.data,i,r),mn(n)||Sr(i,n);var o=t.baseData.name,s=new Ne(e,o,i,r),a=new gr(Ne.dataType,s);return Cr(e,Ne.envelopeType,t,a)}function Rr(e,t){!function(e,t,n,i,r){if(void 0===r&&(r=!1),e)try{var o=qi(t,i),s=!1;!function(e,t,n){if(t.type)Hi(e,ji(e,t.type),t,n);else{var i=Fi.get(e,Ni,{});Cn(i,(function(i,r){Hi(e,r,t,n)})),0===kn(i).length&&Fi.kill(e,Ni)}}(e,o,(function(e){return!((!o.ns||n)&&e.handler!==n||(s=!0,0))})),s||Ui(e,o,n,r)}catch(e){}}(e,null,null,t)}var Dr,wr=function(){function e(t,n){var r=[],o=!1;this._get=function(){return r},this._set=function(e){return r=e},(0,i.Z)(e,this,(function(e){e.enqueue=function(i){e.count()>=n.eventsLimitInMem()?o||(mi(t,2,105,"Maximum in-memory buffer size reached: "+e.count(),!0),o=!0):r.push(i)},e.count=function(){return r.length},e.size=function(){for(var e=r.length,t=0;t0?n.emitLineDelimitedJson()?e.join("\n"):"["+e.join(",")+"]":null}}))}return e.__ieDyn=1,e}(),Er=function(e){function t(n,r){var o=e.call(this,n,r)||this;return(0,i.Z)(t,o,(function(e,t){e.markAsSent=function(e){t.clear()},e.clearSent=function(e){}})),o}return(0,r.ne)(t,e),t.__ieDyn=1,t}(wr),Pr=function(e){function t(n,r){var o=e.call(this,n,r)||this,s=!1;return(0,i.Z)(t,o,(function(e,i){var o=l(t.BUFFER_KEY),a=l(t.SENT_BUFFER_KEY),c=e._set(o.concat(a));function u(e,t){var n=[];return wn(t,(function(t){yn(t)||-1!==function(e,t,n){if(e){if(e.indexOf)return e.indexOf(t,n);var i=e.length;try{for(var r=Math.max(0,0);rt.MAX_BUFFER_SIZE&&(c.length=t.MAX_BUFFER_SIZE),d(t.SENT_BUFFER_KEY,[]),d(t.BUFFER_KEY,c),e.enqueue=function(r){e.count()>=t.MAX_BUFFER_SIZE?s||(mi(n,2,67,"Maximum buffer size reached: "+e.count(),!0),s=!0):(i.enqueue(r),d(t.BUFFER_KEY,e._get()))},e.clear=function(){i.clear(),d(t.BUFFER_KEY,e._get()),d(t.SENT_BUFFER_KEY,[]),s=!1},e.markAsSent=function(i){d(t.BUFFER_KEY,e._set(u(i,e._get())));var r=l(t.SENT_BUFFER_KEY);r instanceof Array&&i instanceof Array&&((r=r.concat(i)).length>t.MAX_BUFFER_SIZE&&(mi(n,1,67,"Sent buffer reached its maximum size: "+r.length,!0),r.length=t.MAX_BUFFER_SIZE),d(t.SENT_BUFFER_KEY,r))},e.clearSent=function(e){var n=l(t.SENT_BUFFER_KEY);n=u(e,n),d(t.SENT_BUFFER_KEY,n)}})),o}return(0,r.ne)(t,e),t.BUFFER_KEY="AI_buffer",t.SENT_BUFFER_KEY="AI_sentBuffer",t.MAX_BUFFER_SIZE=2e3,t}(wr),kr=function(){function e(t){(0,i.Z)(e,this,(function(e){function n(e,o){var s={};if(!e)return mi(t,1,48,"cannot serialize object because it is null or undefined",{name:o},!0),s;if(e.__aiCircularRefCheck)return mi(t,2,50,"Circular reference detected while serializing object",{name:o},!0),s;if(!e.aiDataContract){if("measurements"===o)s=r(e,"number",o);else if("properties"===o)s=r(e,"string",o);else if("tags"===o)s=r(e,"string",o);else if(bn(e))s=i(e,o);else{mi(t,2,49,"Attempting to serialize an object which does not implement ISerializable",{name:o},!0);try{ii().stringify(e),s=e}catch(e){mi(t,1,48,e&&yn(e.toString)?e.toString():"Error serializing object",null,!0)}}return s}return e.__aiCircularRefCheck=!0,Cn(e.aiDataContract,(function(r,a){var c=yn(a)?1&a():1&a,u=yn(a)?4&a():4&a,l=2&a,d=void 0!==e[r],f=vn(e[r])&&null!==e[r];if(!c||d||l){if(!u){var p;void 0!==(p=f?l?i(e[r],r):n(e[r],r):e[r])&&(s[r]=p)}}else mi(t,1,24,"Missing required field specification. The field is required but not present on source",{field:r,name:o})})),delete e.__aiCircularRefCheck,s}function i(e,i){var r;if(e)if(bn(e)){r=[];for(var o=0;o100||e<0)&&(n.throwInternal(2,58,"Sampling rate is out of range (0..100). Sampling will be disabled, you may be sending too much data which may affect your AI service level.",{samplingRate:e},!0),e=100),this.sampleRate=e,this.samplingScoreGenerator=new Nr}return e.prototype.isSampledIn=function(e){var t=this.sampleRate;return null==t||t>=100||e.baseType===$e.dataType||this.samplingScoreGenerator.getSamplingScore(e)=300)&&0!==t){if((301===t||307===t||308===t)&&!y(r))return void e._onError(i,s);!e._senderConfig.isRetryDisabled()&&x(t)?(E(i),mi(e.diagLog(),2,40,". Response code "+t+". Will retry to send "+i.length+" items.")):e._onError(i,s)}else g&&!g.isOnline()?e._senderConfig.isRetryDisabled()||(E(i,10),mi(e.diagLog(),2,40,". Offline - Response Code: ".concat(t,". Offline status: ").concat(!g.isOnline(),". Will retry to send ").concat(i.length," items."))):(y(r),206===t?(c||(c=w(a)),c&&!e._senderConfig.isRetryDisabled()?e._onPartialSuccess(i,c):e._onError(i,s)):(n=0,e._onSuccess(i,o)))}function y(t){return!(u>=10||mn(t)||""===t||t===e._senderConfig.endpointUrl()||(e._senderConfig.endpointUrl=function(){return t},++u,0))}function S(e,t){p?p(e,!1):T(e)}function C(t){var n=ti(),i=e._buffer,r=e._senderConfig.endpointUrl(),o=e._buffer.batchPayloads(t),s=new Blob([o],{type:"text/plain;charset=UTF-8"}),a=n.sendBeacon(r,s);return a&&(i.markAsSent(t),e._onSuccess(t,t.length)),a}function T(t,n){if(bn(t)&&t.length>0&&!C(t)){for(var i=[],r=0;r0&&(f&&f(i,!0),mi(e.diagLog(),2,40,". Failed to send telemetry with Beacon API, retried with normal sender."))}}function b(t,n){var i=new XMLHttpRequest,r=e._senderConfig.endpointUrl();try{i[o]=!0}catch(e){}i.open("POST",r,n),i.setRequestHeader("Content-type","application/json"),Xt(r)&&i.setRequestHeader(Ut[6],Ut[7]),wn(kn(l),(function(e){i.setRequestHeader(e,l[e])})),i.onreadystatechange=function(){return e._xhrReadyStateChange(i,t,t.length)},i.onerror=function(n){return e._onError(t,N(i),n)};var s=e._buffer.batchPayloads(t);i.send(s),e._buffer.markAsSent(t)}function _(t,n){if(bn(t)){for(var i=t.length,r=0;r=n.itemsAccepted&&n.itemsReceived-n.itemsAccepted===n.errors.length)return n}}catch(n){mi(e.diagLog(),1,43,"Cannot parse the response. "+On(n),{response:t})}return null}function E(t,i){if(void 0===i&&(i=1),t&&0!==t.length){var o=e._buffer;o.clearSent(t),n++;for(var s=0,a=t;se._senderConfig.maxBatchSizeInBytes()&&e.triggerSend(!0,null,10),P())},e.flush=function(t,n,i){if(void 0===t&&(t=!0),!s){k();try{e.triggerSend(t,null,i||1)}catch(t){mi(e.diagLog(),1,22,"flush failed, telemetry will not be collected: "+On(t),{exception:ri(t)})}}},e.onunloadFlush=function(){if(!s)if(!1!==e._senderConfig.onunloadDisableBeacon()&&!1!==e._senderConfig.isBeaconApiDisabled()||!oi())e.flush();else try{e.triggerSend(!0,S,2)}catch(t){mi(e.diagLog(),1,20,"failed to flush with beacon sender on page unload, telemetry will not be collected: "+On(t),{exception:ri(t)})}},e.addHeader=function(e,t){l[e]=t},e.initialize=function(t,o,s,a){e.isInitialized()&&mi(e.diagLog(),1,28,"Sender is already initialized"),i.initialize(t,o,s,a);var l=e._getTelCtx(),m=e.identifier;c=new kr(o.logger),n=0,r=null,e._sender=null,u=0;var v=e.diagLog();h=Ki(ki("Sender"),o.evtNamespace&&o.evtNamespace()),g=function(e){var t=Qn(),n=ti(),i=!1,r=!0,o=Ki(ki("OfflineListener"),e);try{if(a(Xn())&&(i=!0),t){var s=t.body||t;s.ononline&&a(s)&&(i=!0)}i&&n&&!mn(n.onLine)&&(r=n.onLine)}catch(e){i=!1}function a(e){var t=!1;return e&&(t=Wi(e,"online",c,o))&&Wi(e,"offline",u,o),t}function c(){r=!0}function u(){r=!1}return{isOnline:function(){var e=!0;return i?e=r:n&&!mn(n.onLine)&&(e=n.onLine),e},isListening:function(){return i},unload:function(){var e=Xn();if(e&&i){if(Rr(e,o),t){var n=t.body||t;hn(n.ononline)||Rr(n,o)}i=!1}}}}(h),Cn(Ar(),(function(t,n){e._senderConfig[t]=function(){var e=l.getConfig(m,t,n());return e||"endpointUrl"!==t||(e=n()),e}})),e._buffer=e._senderConfig.enableSessionStorageBuffer()&&Vt()?new Pr(v,e._senderConfig):new Er(v,e._senderConfig),e._sample=new Or(e._senderConfig.samplingPercentage(),v),function(e){return!(mn(e[hr])||!e[hr])||new RegExp("^[0-9a-f]{8}-[0-9a-f]{4}-[0-9a-f]{4}-[0-9a-f]{4}-[0-9a-f]{12}$").test(e.instrumentationKey)}(t)||mi(v,1,100,"Invalid Instrumentation key "+t.instrumentationKey),!Xt(e._senderConfig.endpointUrl())&&e._senderConfig.customHeaders()&&e._senderConfig.customHeaders().length>0&&wn(e._senderConfig.customHeaders(),(function(e){d.addHeader(e.header,e.value)}));var y=e._senderConfig,S=null;!y.disableXhr()&&ai()?S=O:!y.disableXhr()&&ci()&&(S=b),!S&&si()&&(S=R),f=S||b,!y.isBeaconApiDisabled()&&oi()&&(S=T),e._sender=S||b,p=!y.onunloadDisableFetch()&&si(!0)?_:oi()?T:!y.disableXhr()&&ai()?O:!y.disableXhr()&&ci()?b:f},e.processTelemetry=function(n,i){var r,o=(i=e._getTelCtx(i)).diagLog();try{if(e._senderConfig.disableTelemetry())return;if(!n)return void mi(o,1,7,"Cannot send empty telemetry");if(n.baseData&&!n.baseType)return void mi(o,1,70,"Cannot send telemetry without baseData and baseType");if(n.baseType||(n.baseType="EventData"),!e._sender)return void mi(o,1,28,"Sender was not initialized");if(r=n,!e._sample.isSampledIn(r))return void mi(o,2,33,"Telemetry item was sampled out and not sent",{SampleRate:e._sample.sampleRate});n.sampleRate=e._sample.sampleRate;var s=e._senderConfig.convertUndefined()||void 0,a=n.iKey||e._senderConfig.instrumentationKey(),u=t.constructEnvelope(n,a,o,s);if(!u)return void mi(o,1,47,"Unable to create an AppInsights envelope");var l=!1;if(n.tags&&n.tags.ProcessLegacy&&(wn(n.tags.ProcessLegacy,(function(e){try{e&&!1===e(u)&&(l=!0,vi(o,"Telemetry processor check returns false"))}catch(e){mi(o,1,64,"One of telemetry initializers failed, telemetry item will not be sent: "+On(e),{exception:ri(e)},!0)}})),delete n.tags.ProcessLegacy),l)return;var d=c.serialize(u),f=e._buffer;f.size()+d.length>e._senderConfig.maxBatchSizeInBytes()&&e.triggerSend(!0,null,10),f.enqueue(d),P()}catch(e){mi(o,2,12,"Failed adding telemetry to the sender's buffer, some telemetry will be lost: "+On(e),{exception:ri(e)})}e.processNext(n,i)},e._xhrReadyStateChange=function(e,t,n){4===e.readyState&&v(e.status,t,e.responseURL,n,N(e),Ir(e)||e.response)},e.triggerSend=function(t,n,i){if(void 0===t&&(t=!0),!s)try{var r=e._buffer;if(e._senderConfig.disableTelemetry())r.clear();else{if(r.count()>0){var o=r.getItems();!function(t,n){var i,r=(i="getNotifyMgr",e.core[i]?e.core[i]():e.core._notificationManager);if(r&&r.eventsSendRequest)try{r.eventsSendRequest(t,n)}catch(t){mi(e.diagLog(),1,74,"send request notification failed: "+On(t),{exception:ri(t)})}}(i||0,t),n?n.call(d,o,t):e._sender(o,t)}new Date}k()}catch(t){var a=function(e){if(void 0===e&&(e=null),!e){var t=ti()||{};e=t?(t.userAgent||en).toLowerCase():en}var n=(e||en).toLowerCase();if(Tn(n,Kn)){var i=Qn()||{};return Math.max(parseInt(n.split(Kn)[1]),i.documentMode||0)}if(Tn(n,Wn)){var r=parseInt(n.split(Wn)[1]);if(r)return r+4}return null}();(!a||a>9)&&mi(e.diagLog(),1,40,"Telemetry transmission failed, some telemetry will be lost: "+On(t),{exception:ri(t)})}},e._doTeardown=function(t,n){e.onunloadFlush(),g.unload(),A()},e._onError=function(t,n,i){mi(e.diagLog(),2,26,"Failed to send telemetry.",{message:n}),e._buffer.clearSent(t)},e._onPartialSuccess=function(t,n){for(var i=[],r=[],o=0,s=n.errors.reverse();o0&&e._onSuccess(t,n.itemsAccepted),i.length>0&&e._onError(i,N(null,["partial success",n.itemsAccepted,"of",n.itemsReceived].join(" "))),r.length>0&&(E(r),mi(e.diagLog(),2,40,"Partial success. Delivered: "+t.length+", Failed: "+i.length+". Will retry to send "+r.length+" our of "+n.itemsReceived+" items"))},e._onSuccess=function(t,n){e._buffer.clearSent(t)},e._xdrOnLoad=function(t,i){var r=Ir(t);if(!t||r+""!="200"&&""!==r){var o=w(r);o&&o.itemsReceived&&o.itemsReceived>o.itemsAccepted&&!e._senderConfig.isRetryDisabled()?e._onPartialSuccess(i,o):e._onError(i,I(t))}else n=0,e._onSuccess(i,0)}})),d}return(0,r.ne)(t,e),t.constructEnvelope=function(e,t,n,i){var o;return o=t===e.iKey||mn(t)?e:(0,r.uc)((0,r.uc)({},e),{iKey:t}),(Fr[o.baseType]||_r)(n,o,i)},t}(er);var Lr="",qr="extensionConfig",jr=l.RJ,Ur=l.Pw.freeze,Hr=(l.Pw.seal,l.Pw.keys),Kr=String[l.hB],Wr=Kr.trim,zr=Kr.endsWith,Vr=(Kr.startsWith,Date[l.hB].toISOString),Br=Array.isArray,$r=l.V4.toString,Gr=l.CY.toString,Jr=Gr.call(l.Pw),Yr=/-([a-z])/g,Zr=/([^\w\d_$])/g,Xr=/^(\d+[\w\d_$])/,Qr=Object.getPrototypeOf;function eo(e){return void 0===e||typeof e===l.jA}function to(e){return null===e||eo(e)}function no(e){return!to(e)}function io(e){return!(!e||typeof e!==l.fK)}function ro(e){return!(!e||typeof e!==l.cb)}function oo(e){var t=e;return t&&lo(t)&&(t=(t=(t=t.replace(Yr,(function(e,t){return t.toUpperCase()}))).replace(Zr,"_")).replace(Xr,(function(e,t){return"_"+t}))),t}function so(e,t){if(e)for(var n in e)l.CY.call(e,n)&&t.call(e,n,e[n])}function ao(e,t){return!(!e||!t)&&-1!==e.indexOf(t)}var co=Br||function(e){return!(!e||"[object Array]"!==$r.call(e))};function uo(e){return!(!e||"[object Error]"!==$r.call(e))}function lo(e){return"string"==typeof e}function fo(e){return"boolean"==typeof e}function po(e){var t=!1;if(e&&"object"==typeof e){var n=Qr?Qr(e):function(e){if(e){if(Qr)return Qr(e);var t=e.__proto__||e[l.hB]||e.constructor;if(t)return t}return null}(e);n?(n.constructor&&l.CY.call(n,"constructor")&&(n=n.constructor),t=typeof n===l.cb&&Gr.call(n)===Jr):t=!0}return t}function go(e){if(e)return Vr?e.toISOString():function(e){if(e&&e.getUTCFullYear){var t=function(e){var t=String(e);return 1===t.length&&(t="0"+t),t};return e.getUTCFullYear()+"-"+t(e.getUTCMonth()+1)+"-"+t(e.getUTCDate())+"T"+t(e.getUTCHours())+":"+t(e.getUTCMinutes())+":"+t(e.getUTCSeconds())+"."+String((e.getUTCMilliseconds()/1e3).toFixed(3)).slice(2,5)+"Z"}}(e)}function ho(e,t,n){var i=e.length;try{for(var r=0;r=0?r:i-Math.abs(r),0);o0&&fo(a)&&(u=a,a=s[d]||{},d++),io(a)||(a={});d=o)){var i=!0,s="AITR_"+n.messageId;if(c[s]?i=!1:c[s]=!0,i&&(t<=r&&(e.queue.push(n),a++,u(1===t?"error":"warn",n)),a===o)){var l="Internal events throttle limit per PageView reached for this app.",d=new Xo(23,l,!1);e.queue.push(d),1===t?e.errorToConsole(l):e.warnToConsole(l)}}}function u(e,n){var i=Jo(t||{});i&&i.diagLog&&i.diagLog(e,n)}!function(e){n=wo(e.loggingLevelConsole,0),r=wo(e.loggingLevelTelemetry,1),o=wo(e.maxMessageLimit,25),s=wo(e.enableDebugExceptions,!1)}(t||{}),e.consoleLoggingLevel=function(){return n},e.telemetryLoggingLevel=function(){return r},e.maxInternalMessageLimit=function(){return o},e.enableDebugExceptions=function(){return s},e.throwInternal=function(t,r,o,a,l){void 0===l&&(l=!1);var d=new Xo(r,o,l,a);if(s)throw zo(d);var f=1===t?"errorToConsole":"warnToConsole";if(eo(d.message))u("throw"+(1===t?"Critical":"Warning"),d);else{if(l){var p=+d.messageId;!c[p]&&n>=t&&(e[f](d.message),c[p]=!0)}else n>=t&&e[f](d.message);i(t,d)}},e.warnToConsole=function(e){Zo("warn",e),u("warning",e)},e.errorToConsole=function(e){Zo("error",e),u("error",e)},e.resetInternalMessageCount=function(){a=0,c={}},e.logInternalMessage=i}))}return e.__ieDyn=1,e}();function es(e){return e||new Qo}function ts(e,t,n,i,r,o){void 0===o&&(o=!1),es(e).throwInternal(t,n,i,r,o)}var ns=function(){function e(t,n,i){var r,o=this,s=!1;o.start=bo(),o.name=t,o.isAsync=i,o.isChildEvt=function(){return!1},ro(n)&&(s=Co(o,"payload",(function(){return!r&&ro(n)&&(r=n(),n=null),r}))),o.getCtx=function(t){return t?t===e.ParentContextKey||t===e.ChildrenContextKey?o[t]:(o.ctx||{})[t]:null},o.setCtx=function(t,n){t&&(t===e.ParentContextKey?(o[t]||(o.isChildEvt=function(){return!0}),o[t]=n):t===e.ChildrenContextKey?o[t]=n:(o.ctx=o.ctx||{})[t]=n)},o.complete=function(){var t=0,i=o.getCtx(e.ChildrenContextKey);if(co(i))for(var r=0;r>>=0),us=123456789+e&as,ls=987654321-e&as,cs=!0}function fs(){try{var e=2147483647&bo();ds((Math.random()*ss^e)+e)}catch(e){}}function ps(e){var t=0,n=Lo("crypto")||Lo("msCrypto");return n&&n.getRandomValues&&(t=n.getRandomValues(new Uint32Array(1))[0]&as),0===t&&Wo()&&(cs||fs(),t=gs()&as),0===t&&(t=Math.floor(ss*Math.random()|0)),e||(t>>>=0),t}function gs(e){var t=((ls=36969*(65535&ls)+(ls>>16)&as)<<16)+(65535&(us=18e3*(65535&us)+(us>>16)&as))>>>0&as|0;return e||(t>>>=0),t}function hs(e){void 0===e&&(e=22);for(var t=ps()>>>0,n=0,i=Lr;i.length>>=6,5===n&&(t=(ps()<<2&4294967295|3&t)>>>0,n=0);return i}var ms=l.RJ,vs="."+hs(6),ys=0;function Ss(e){return 1===e.nodeType||9===e.nodeType||!+e.nodeType}function Cs(e,t){return void 0===t&&(t=!1),oo(e+ys+++(t?".2.8.11":Lr)+vs)}function Ts(e){var t={id:Cs("_aiData-"+(e||Lr)+".2.8.11"),accept:function(e){return Ss(e)},get:function(e,n,i,r){var o=e[t.id];return o?o[oo(n)]:(r&&((o=function(e,t){var n=t[e.id];if(!n){n={};try{Ss(t)&&(function(e,t,n){if(ms)try{return ms(e,t,{value:n,enumerable:!1,configurable:!0}),!0}catch(e){}return!1}(t,e.id,n)||(t[e.id]=n))}catch(e){}}return n}(t,e))[oo(n)]=i),i)},kill:function(e,t){if(e&&e[t])try{delete e[t]}catch(e){}}};return t}function bs(e,t,n){return!(!e||e.length!==t||e===n||!e.match(/^[\da-f]*$/))}var _s=Ts("plugin");function Rs(e){return _s.get(e,"state",{},!0)}function Ds(e,t){for(var n,i=[],r=null,o=e.getNext();o;){var s=o.getPlugin();s&&(r&&ro(r.setNextPlugin)&&ro(s.processTelemetry)&&r.setNextPlugin(s),(ro(s.isInitialized)?s.isInitialized():(n=Rs(s)).isInitialized)||i.push(s),r=s,o=o.getNext())}ho(i,(function(i){var r=e.core();i.initialize(e.getCfg(),r,t,e.getNext()),n=Rs(i),i.core||n.core||(n.core=r),n.isInitialized=!0,delete n.teardown}))}function ws(e){return e.sort((function(e,t){var n=0;if(t){var i=ro(t.processTelemetry);ro(e.processTelemetry)?n=i?e.priority-t.priority:1:i&&(n=-1)}else n=e?1:-1;return n}))}var Es=0;function Ps(e,t,n,i){var r=null,o=[];null!==i&&(r=i?function(e,t,n){for(;e;){if(e.getPlugin()===n)return e;e=e.getNext()}return Os([n],t.config||{},t)}(e,n,i):e);var s={_next:function(){var e=r;if(r=e?e.getNext():null,!e){var t=o;t&&t.length>0&&(ho(t,(function(e){try{e.func.call(e.self,e.args)}catch(e){ts(n.logger,2,73,"Unexpected Exception during onComplete - "+zo(e))}})),o=[])}return e},ctx:{core:function(){return n},diagLog:function(){return function(e,t){return(e||{}).logger||new Qo(t)}(n,t)},getCfg:function(){return t},getExtCfg:a,getConfig:function(e,n,i){void 0===i&&(i=!1);var r,o=a(e,null);return o&&!to(o[n])?r=o[n]:t&&!to(t[n])&&(r=t[n]),to(r)?i:r},hasNext:function(){return!!r},getNext:function(){return r},setNext:function(e){r=e},iterate:function(e){for(var t;t=s._next();){var n=t.getPlugin();n&&e(n)}},onComplete:function(e,t){for(var n=[],i=2;i0){var s=null;ho(e,(function(e){if(o||i!==e||(o=!0),o&&e&&ro(e.processTelemetry)){var a=function(e,t,n){var i,r=null,o=ro(e.processTelemetry),s=ro(e.setNextPlugin),a={getPlugin:function(){return e},getNext:function(){return r},processTelemetry:function(i,u){c(u=u||function(){var i;return e&&ro(e._getTelCtx)&&(i=e._getTelCtx()),i||(i=ks(a,t,n)),i}(),(function(t){if(!e||!o)return!1;var n=Rs(e);return!n.teardown&&!n.disabled&&(s&&e.setNextPlugin(r),e.processTelemetry(i,t),!0)}),"processTelemetry",(function(){return{item:i}}),!i.sync)||u.processNext(i)},unload:function(t,n){c(t,(function(){var i=!1;if(e){var r=Rs(e),o=e.core||r.core;!e||o&&o!==t.core()||r.teardown||(r.core=null,r.teardown=!0,r.isInitialized=!1,e.teardown&&!0===e.teardown(t,n)&&(i=!0))}return i}),"unload",(function(){}),n.isAsync)||t.processNext(n)},update:function(t,n){c(t,(function(){var i=!1;if(e){var r=Rs(e),o=e.core||r.core;!e||o&&o!==t.core()||r.teardown||e.update&&!0===e.update(t,n)&&(i=!0)}return i}),"update",(function(){}),!1)||t.processNext(n)},_id:i=e?e.identifier+"-"+e.priority+"-"+Es++:"Unknown-0-"+Es++,_setNext:function(e){r=e}};function c(t,n,o,s,a){var c=!1,u=e?e.identifier:"TelemetryPluginChain",l=t._hasRun;return l||(l=t._hasRun={}),t.setNext(r),e&&os(t.core(),(function(){return u+":"+o}),(function(){l[i]=!0;try{var e=r?r._id:Lr;e&&(l[e]=!1),c=n(t)}catch(e){var s=!r||l[r._id];s&&(c=!0),r&&s||ts(t.diagLog(),1,73,"Plugin ["+u+"] failed during "+o+" - "+zo(e)+", run flags: "+zo(l))}}),s,a),c}return To(a)}(e,t,n);r||(r=a),s&&s._setNext(a),s=a}}))}return i&&!r?Os([i],t,n):r}var Is=500;function As(e,t,n){t&&co(t)&&t.length>0&&(ho(t=t.sort((function(e,t){return e.priority-t.priority})),(function(e){e.priority0){var v=new Date;v.setTime(m),Ro(f,"expires",Gs(v,h?Fs:Ms)||Gs(v,h?Fs:Ms)||Lr,Eo)}}h||Ro(f,"max-age",Lr+n,null,eo)}var y=typeof location===l.fK&&location?location:Lo("location");y&&"https:"===y.protocol&&(Ro(f,"secure",null,null,eo),null===qs&&(u=(Uo()||{}).userAgent,qs=!(lo(u)&&(ao(u,"CPU iPhone OS 12")||ao(u,"iPad; CPU OS 12")||ao(u,"Macintosh; Intel Mac OS X 10_14")&&ao(u,"Version/")&&ao(u,"Safari")||ao(u,"Macintosh; Intel Mac OS X 10_14")&&function(e,t){var n=!1;return e&&t&&!(n=e===t)&&(n=zr?e.endsWith(t):function(e,t){var n=!1,i=t?t.length:0,r=e?e.length:0;if(i&&r&&r>=i&&!(n=e===t)){for(var o=r-1,s=i-1;s>=0;s--){if(e[o]!=t[s])return!1;o--}n=!0}return n}(e,t)),n}(u,"AppleWebKit/605.1.15 (KHTML, like Gecko)")||ao(u,"Chrome/5")||ao(u,"Chrome/6")||ao(u,"UnrealEngine")&&!ao(u,"Chrome")||ao(u,"UCBrowser/12")||ao(u,"UCBrowser/11")))),qs&&Ro(f,"SameSite","None",null,eo)),Ro(f,"path",c||r,null,eo),(i.setCookie||Zs)(e,Js(p,f)),d=!0}return d},n.get=function(e){var t=Lr;return Ws(a)&&!zs(i,e)&&(t=(i.getCookie||Ys)(e)),t},n.del=function(e,t){var n=!1;return Ws(a)&&(n=a.purge(e,t)),n},n.purge=function(e,n){var r,o=!1;if(Bs(t)){var s=((r={}).path=n||"/",r.expires="Thu, 01 Jan 1970 00:00:01 GMT",r);Wo()||(s["max-age"]="0"),(i.delCookie||Zs)(e,Js(Lr,s)),o=!0}return o},n);return a._ckMgr=a,a}function Bs(e){if(null===Ls){Ls=!1;try{Ls=void 0!==(Us||{}).cookie}catch(t){ts(e,2,68,"Cannot access document.cookie - "+_o(t),{exception:zo(t)})}}return Ls}function $s(e){var t={};return e&&e.length&&ho(vo(e).split(";"),(function(e){if(e=vo(e||Lr)){var n=e.indexOf("=");-1===n?t[e]=null:t[vo(e.substring(0,n))]=vo(e.substring(n+1))}})),t}function Gs(e,t){return ro(e[t])?e[t]():null}function Js(e,t){var n=e||Lr;return so(t,(function(e,t){n+="; "+e+(to(t)?Lr:"="+t)})),n}function Ys(e){var t=Lr;if(Us){var n=Us.cookie||Lr;js!==n&&(Hs=$s(n),js=n),t=vo(Hs[e]||Lr)}return t}function Zs(e,t){Us&&(Us.cookie=e+"="+t)}function Xs(){var e=[];return{add:function(t){t&&e.push(t)},run:function(t,n){ho(e,(function(e){try{e(t,n)}catch(e){ts(t.diagLog(),2,73,"Unexpected error calling unload handler - "+zo(e))}})),e=[]}}}var Qs=function(){function e(){var t,n,r,o,s,a=this;function c(e){void 0===e&&(e=null);var t=e;if(!t){var i=n||ks(null,{},a.core);t=r&&r.getPlugin?i.createNew(null,r.getPlugin):i.createNew(null,r)}return t}function u(e,t,i){e&&Ro(e,qr,[],null,to),!i&&t&&(i=t.getProcessTelContext().getNext());var o=r;r&&r.getPlugin&&(o=r.getPlugin()),a.core=t,n=ks(i,e,t,o)}function l(){t=!1,a.core=null,n=null,r=null,s=[],o=Xs()}l(),(0,i.Z)(e,a,(function(e){e.initialize=function(e,n,i,r){u(e,n,r),t=!0},e.teardown=function(t,n){var i,a=e.core;if(a&&(!t||a===t.core())){var c,u=!1,d=t||xs(null,a,r&&r.getPlugin?r.getPlugin():r),f=n||((i={reason:0}).isAsync=!1,i);return e._doTeardown&&!0===e._doTeardown(d,f,p)?c=!0:p(),c}function p(){if(!u){u=!0,o.run(d,n);var e=s;s=[],ho(e,(function(e){e.rm()})),!0===c&&d.processNext(f),l()}}},e.update=function(t,n){var i=e.core;if(i&&(!t||i===t.core())){var o,s=!1,a=t||Ns(null,i,r&&r.getPlugin?r.getPlugin():r),c=n||{reason:0};return e._doUpdate&&!0===e._doUpdate(a,c,l)?o=!0:l(),o}function l(){s||(s=!0,u(a.getCfg(),a.core(),a.getNext()))}},e._addHook=function(e){e&&(co(e)?s=s.concat(e):s.push(e))},ko(e,"_addUnloadCb",(function(){return o}),"add")})),a.diagLog=function(e){return c(e).diagLog()},a.isInitialized=function(){return t},a.setInitialized=function(e){t=e},a.setNextPlugin=function(e){r=e},a.processNext=function(e,t){t?t.processNext(e):r&&ro(r.processTelemetry)&&r.processTelemetry(e,null)},a._getTelCtx=c}return e.__ieDyn=1,e}(),ea=function(e){function t(){var n,r,o=e.call(this)||this;function s(){n=0,r=[]}return o.identifier="TelemetryInitializerPlugin",o.priority=199,s(),(0,i.Z)(t,o,(function(e,t){e.addTelemetryInitializer=function(e){var t={id:n++,fn:e};return r.push(t),{remove:function(){ho(r,(function(e,n){if(e.id===t.id)return r.splice(n,1),-1}))}}},e.processTelemetry=function(t,n){for(var i=!1,o=r.length,s=0;sIs&&r.push(e)})),As(i,r,n)}return i}(h,r,e)),g){var o=mo(r,g);-1!==o&&r.splice(o,1),-1!==(o=mo(p,g))&&p.splice(o,1),g._setQueue(m)}else g=function(e,t){function n(){return ks(null,t.config,t,null)}function i(e,t,n,i){var r=e?e.length+1:1;function o(){0==--r&&(i&&i(),i=null)}r>0&&ho(e,(function(e){if(e&&e.queue.length>0){var i=e.chain,s=t.createNew(i);s.onComplete(o),n(s)}else r--})),o()}var r=!1,o={identifier:"ChannelControllerPlugin",priority:Is,initialize:function(t,n,i,o){r=!0,ho(e,(function(e){e&&e.queue.length>0&&Ds(ks(e.chain,t,n),i)}))},isInitialized:function(){return r},processTelemetry:function(t,r){i(e,r||n(),(function(e){e.processNext(t)}),(function(){r.processNext(t)}))},update:function(t,n){var r=n||{reason:0};return i(e,t,(function(e){e.processNext(r)}),(function(){t.processNext(r)})),!0},pause:function(){i(e,n(),(function(e){e.iterate((function(e){e.pause&&e.pause()}))}),null)},resume:function(){i(e,n(),(function(e){e.iterate((function(e){e.resume&&e.resume()}))}),null)},teardown:function(t,n){var o=n||{reason:0,isAsync:!1};return i(e,t,(function(e){e.processNext(o)}),(function(){t.processNext(o),r=!1})),!0},getChannel:function(t){var n=null;return e&&e.length>0&&ho(e,(function(e){if(e&&e.queue.length>0&&(ho(e.queue,(function(e){if(e.identifier===t)return n=e,-1})),n))return-1})),n},flush:function(t,r,o,s){var a=1,c=!1,u=null;function l(){a--,c&&0===a&&(u&&(clearTimeout(u),u=null),r&&r(c),r=null)}return s=s||5e3,i(e,n(),(function(e){e.iterate((function(e){if(e.flush){a++;var n=!1;e.flush(t,(function(){n=!0,l()}),o)||n||(t&&null==u?u=setTimeout((function(){u=null,l()}),s):l())}}))}),(function(){c=!0,l()})),!0},_setQueue:function(t){e=t}};return o}(m,e);r.push(g),p.push(g),e._extensions=ws(r),g.initialize(t,e,r),Ds(D(),r),e._extensions=To(ws(p||[])).slice(),n&&function(t){var n=Ns(P(),e);e._updateHook&&!0===e._updateHook(n,t)||n.processNext(t)}(n)}function E(t){var n,i=null,r=null;return ho(e._extensions,(function(e){if(e.identifier===t&&e!==g&&e!==y)return r=e,-1})),!r&&g&&(r=g.getChannel(t)),r&&((n={plugin:r}).setEnabled=function(e){Rs(r).disabled=!e},n.isEnabled=function(){var e=Rs(r);return!e.teardown&&!e.disabled},n.remove=function(e,t){var n;void 0===e&&(e=!0);var i=[r],o=((n={reason:1}).isAsync=e,n);k(i,o,(function(e){e&&w({reason:32,removed:i}),t&&t(e)}))},i=n),i}function P(){if(!l){var n=(p||[]).slice();-1===mo(n,y)&&n.push(y),l=Os(ws(n),t,e)}return l}function k(n,i,r){if(n&&n.length>0){var o=xs(Os(n,t,e),e);o.onComplete((function(){var e=!1,t=[];ho(f,(function(i,r){oa(i,n)?e=!0:t.push(i)})),f=t;var i=[];h&&(ho(h,(function(t,r){var o=[];ho(t,(function(t){oa(t,n)?e=!0:o.push(t)})),i.push(o)})),h=i),r&&r(e)})),o.processNext(i)}else r(!1)}function x(){var n=e.logger?e.logger.queue:[];n&&(ho(n,(function(n){var i,r=((i={}).name=S||"InternalMessageId: "+n.messageId,i.iKey=wo(t.instrumentationKey),i.time=go(new Date),i.baseType=Xo.dataType,i.baseData={message:n.message},i);e.track(r)})),n.length=0)}function N(e,t,n,i){return g?g.flush(e,t,n||6,i):(t&&t(!1),!0)}function O(t){var n=e.logger;n?ts(n,2,73,t):Po(t)}i(),e.isInitialized=function(){return n},e.initialize=function(i,o,a,u){var l,d;v&&Po(na),e.isInitialized()&&Po("Core should not be initialized more than once"),t=i||{},e.config=t,to(i.instrumentationKey)&&Po("Please provide instrumentation key"),s=u,e._notificationManager=u,!0===(d=wo(t.disableDbgExt))&&b&&(s.removeNotificationListener(b),b=null),s&&!b&&!0!==d&&(b=function(e){if(!Vo){Vo={};for(var t=0;t0){var e=o;o=[],ho(e,(function(e){D().processNext(e)}))}},e.pollInternalLogs=function(e){S=e||null;var n=wo(t.diagnosticLogInterval);return n&&n>0||(n=1e4),R&&clearInterval(R),R=setInterval((function(){x()}),n)},e.stopPollingInternalLogs=function(){R&&(clearInterval(R),R=0,x())},xo(e,(function(){return y}),["addTelemetryInitializer"]),e.unload=function(t,r,o){var s;void 0===t&&(t=!0),n||Po("SDK is not initialized"),v&&Po(na);var a=((s={reason:50}).isAsync=t,s.flushComplete=!1,s),c=xs(P(),e);function u(t){a.flushComplete=t,v=!0,T.run(c,a),e.stopPollingInternalLogs(),c.processNext(a)}c.onComplete((function(){i(),r&&r(a)}),e),N(t,u,6,o)||u(!1)},e.getPlugin=E,e.addPlugin=function(e,t,n,i){if(!e)return i&&i(!1),void O(ta);var r=E(e.identifier);if(r&&!t)return i&&i(!1),void O("Plugin ["+e.identifier+"] is already loaded!");var o={reason:16};function s(t){f.push(e),o.added=[e],w(o),i&&i(!0)}if(r){var a=[r.plugin];k(a,{reason:2,isAsync:!!n},(function(e){e?(o.removed=a,o.reason|=32,s()):i&&i(!1)}))}else s()},e.evtNamespace=function(){return C},e.flush=N,e.getTraceCtx=function(e){var t;return _||(t={},_={getName:function(){return t.name},setName:function(e){t.name=e},getTraceId:function(){return t.traceId},setTraceId:function(e){bs(e,32,"00000000000000000000000000000000")&&(t.traceId=e)},getSpanId:function(){return t.spanId},setSpanId:function(e){bs(e,16,"0000000000000000")&&(t.spanId=e)},getTraceFlags:function(){return t.traceFlags},setTraceFlags:function(e){t.traceFlags=e}}),_},e.setTraceCtx=function(e){_=e||null},ko(e,"addUnloadCb",(function(){return T}),"add")}))}return e.__ieDyn=1,e}();function aa(e,t,n,i){ho(e,(function(e){if(e&&e[t])if(n)setTimeout((function(){return i(e)}),0);else try{i(e)}catch(e){}}))}var ca=function(){function e(t){this.listeners=[];var n=!!(t||{}).perfEvtsSendAll;(0,i.Z)(e,this,(function(e){e.addNotificationListener=function(t){e.listeners.push(t)},e.removeNotificationListener=function(t){for(var n=mo(e.listeners,t);n>-1;)e.listeners.splice(n,1),n=mo(e.listeners,t)},e.eventsSent=function(t){aa(e.listeners,"eventsSent",!0,(function(e){e.eventsSent(t)}))},e.eventsDiscarded=function(t,n){aa(e.listeners,"eventsDiscarded",!0,(function(e){e.eventsDiscarded(t,n)}))},e.eventsSendRequest=function(t,n){aa(e.listeners,"eventsSendRequest",n,(function(e){e.eventsSendRequest(t,n)}))},e.perfEvent=function(t){t&&(!n&&t.isChildEvt()||aa(e.listeners,"perfEvent",!1,(function(e){t.isAsync?setTimeout((function(){return e.perfEvent(t)}),0):e.perfEvent(t)})))}}))}return e.__ieDyn=1,e}(),ua=function(e){function t(){var n=e.call(this)||this;return(0,i.Z)(t,n,(function(e,t){function n(t){var n=e.getNotifyMgr();n&&n.eventsDiscarded([t],2)}e.initialize=function(e,n,i,r){t.initialize(e,n,i||new Qo(e),r||new ca(e))},e.track=function(i){os(e.getPerfMgr(),(function(){return"AppInsightsCore:track"}),(function(){null===i&&(n(i),Po("Invalid telemetry item")),function(e){to(e.name)&&(n(e),Po("telemetry name required"))}(i),t.track(i)}),(function(){return{item:i}}),!i.sync)}})),n}return(0,r.ne)(t,e),t.__ieDyn=1,t}(sa),la=(Cs("aiEvtPageHide"),Cs("aiEvtPageShow"),/\.[\.]+/g),da=/[\.]+$/,fa=1,pa=Ts("events"),ga=/^([^.]*)(?:\.(.+)|)/;function ha(e){return e&&e.replace?e.replace(/^[\s\.]+|(?=[\s\.])[\.\s]+$/g,Lr):e}function ma(e,t,n,i,r){var o;void 0===r&&(r=!1);var s=!1;if(e)try{var a=function(e,t){var n;if(t){var i=Lr;co(t)?(i=Lr,ho(t,(function(e){(e=ha(e))&&("."!==e[0]&&(e="."+e),i+=e)}))):i=ha(t),i&&("."!==i[0]&&(i="."+i),e=(e||Lr)+i)}var r=ga.exec(e||Lr)||[];return(n={}).type=r[1],n.ns=(r[2]||Lr).replace(la,".").replace(da,Lr).split(".").sort().join("."),n}(t,i);if(s=function(e,t,n,i){var r=!1;return e&&t&&t.type&&n&&(e.addEventListener?(e.addEventListener(t.type,n,i),r=!0):e.attachEvent&&(e.attachEvent("on"+t.type,n),r=!0)),r}(e,a,n,r),s&&pa.accept(e)){var c=((o={guid:fa++,evtName:a}).handler=n,o.capture=r,o);(function(e,t,n){void 0===n&&(n=!0);var i=pa.get(e,"events",{},n),r=i[t];return r||(r=i[t]=[]),r})(e,a.type).push(c)}}catch(e){}return s}var va,ya=null;function Sa(){for(var e,t=["0","1","2","3","4","5","6","7","8","9","a","b","c","d","e","f"],n=Lr,i=0;i<4;i++)n+=t[15&(e=ps())]+t[e>>4&15]+t[e>>8&15]+t[e>>12&15]+t[e>>16&15]+t[e>>20&15]+t[e>>24&15]+t[e>>28&15];var r=t[8+(3&ps())|0];return n.substr(0,8)+n.substr(9,4)+"4"+n.substr(13,3)+r+n.substr(16,3)+n.substr(19,12)}var Ca,Ta={_canUseCookies:void 0,isTypeof:function(e,t){return typeof e===t},isUndefined:eo,isNullOrUndefined:to,hasOwnProperty:function(e,t){return!(!e||!l.CY.call(e,t))},isFunction:ro,isObject:io,isDate:function(e){return!(!e||"[object Date]"!==$r.call(e))},isArray:co,isError:uo,isString:lo,isNumber:function(e){return"number"==typeof e},isBoolean:fo,toISOString:go,arrForEach:ho,arrIndexOf:mo,arrMap:function(e,t,n){var i;if(e){if(e.map)return e.map(t,n);var r=e.length,o=n||e;i=new Array(r);try{for(var s=0;s=3)i=arguments[2];else{for(;o0?Math.floor(ps()/as*(e+1))>>>0:0},random32:ps,mwcRandomSeed:function(e){e?ds(e):fs()},mwcRandom32:gs,generateW3CId:Sa};function ba(e){var t,n={};return so(e,(function(e,t){n[e]=t,n[t]=e})),t=n,Ur&&so(t,(function(e,t){(co(t)||io(t))&&Ur(t)})),To(t)}ba({CRITICAL:1,WARNING:2});var _a=ba(((Ca={}).BrowserDoesNotSupportLocalStorage=0,Ca.BrowserCannotReadLocalStorage=1,Ca.BrowserCannotReadSessionStorage=2,Ca.BrowserCannotWriteLocalStorage=3,Ca.BrowserCannotWriteSessionStorage=4,Ca.BrowserFailedRemovalFromLocalStorage=5,Ca.BrowserFailedRemovalFromSessionStorage=6,Ca.CannotSendEmptyTelemetry=7,Ca.ClientPerformanceMathError=8,Ca.ErrorParsingAISessionCookie=9,Ca.ErrorPVCalc=10,Ca.ExceptionWhileLoggingError=11,Ca.FailedAddingTelemetryToBuffer=12,Ca.FailedMonitorAjaxAbort=13,Ca.FailedMonitorAjaxDur=14,Ca.FailedMonitorAjaxOpen=15,Ca.FailedMonitorAjaxRSC=16,Ca.FailedMonitorAjaxSend=17,Ca.FailedMonitorAjaxGetCorrelationHeader=18,Ca.FailedToAddHandlerForOnBeforeUnload=19,Ca.FailedToSendQueuedTelemetry=20,Ca.FailedToReportDataLoss=21,Ca.FlushFailed=22,Ca.MessageLimitPerPVExceeded=23,Ca.MissingRequiredFieldSpecification=24,Ca.NavigationTimingNotSupported=25,Ca.OnError=26,Ca.SessionRenewalDateIsZero=27,Ca.SenderNotInitialized=28,Ca.StartTrackEventFailed=29,Ca.StopTrackEventFailed=30,Ca.StartTrackFailed=31,Ca.StopTrackFailed=32,Ca.TelemetrySampledAndNotSent=33,Ca.TrackEventFailed=34,Ca.TrackExceptionFailed=35,Ca.TrackMetricFailed=36,Ca.TrackPVFailed=37,Ca.TrackPVFailedCalc=38,Ca.TrackTraceFailed=39,Ca.TransmissionFailed=40,Ca.FailedToSetStorageBuffer=41,Ca.FailedToRestoreStorageBuffer=42,Ca.InvalidBackendResponse=43,Ca.FailedToFixDepricatedValues=44,Ca.InvalidDurationValue=45,Ca.TelemetryEnvelopeInvalid=46,Ca.CreateEnvelopeError=47,Ca.CannotSerializeObject=48,Ca.CannotSerializeObjectNonSerializable=49,Ca.CircularReferenceDetected=50,Ca.ClearAuthContextFailed=51,Ca.ExceptionTruncated=52,Ca.IllegalCharsInName=53,Ca.ItemNotInArray=54,Ca.MaxAjaxPerPVExceeded=55,Ca.MessageTruncated=56,Ca.NameTooLong=57,Ca.SampleRateOutOfRange=58,Ca.SetAuthContextFailed=59,Ca.SetAuthContextFailedAccountName=60,Ca.StringValueTooLong=61,Ca.StartCalledMoreThanOnce=62,Ca.StopCalledWithoutStart=63,Ca.TelemetryInitializerFailed=64,Ca.TrackArgumentsNotSpecified=65,Ca.UrlTooLong=66,Ca.SessionStorageBufferFull=67,Ca.CannotAccessCookie=68,Ca.IdTooLong=69,Ca.InvalidEvent=70,Ca.FailedMonitorAjaxSetRequestHeader=71,Ca.SendBrowserInfoOnUserInit=72,Ca.PluginException=73,Ca.NotificationException=74,Ca.SnippetScriptLoadFailure=99,Ca.InvalidInstrumentationKey=100,Ca.CannotParseAiBlobValue=101,Ca.InvalidContentBlob=102,Ca.TrackPageActionEventFailed=103,Ca.FailedAddingCustomDefinedRequestContext=104,Ca.InMemoryStorageBufferFull=105,Ca.InstrumentationKeyDeprecation=106,Ca)),Ra=qt({Verbose:0,Information:1,Warning:2,Error:3,Critical:4}),Da=function(){function e(t){var n=new ua;(to(t)||to(t.instrumentationKey)&&to(t.connectionString))&&Po("Invalid input configuration"),(0,i.Z)(e,this,(function(e){if(t.connectionString){var i=function(e){if(!e)return{};var t=H(e.split(";"),(function(e,t){var n=t.split("=");if(2===n.length){var i=n[0].toLowerCase(),r=n[1];e[i]=r}return e}),{});if(V(t).length>0){if(t.endpointsuffix){var n=t.location?t.location+".":"";t.ingestionendpoint=t.ingestionendpoint||"https://"+n+"dc."+t.endpointsuffix}t.ingestionendpoint=t.ingestionendpoint||a}return t}(t.connectionString),r=i.ingestionendpoint;t.endpointUrl=r?r+c:t.endpointUrl,t.instrumentationKey=i.instrumentationkey||t.instrumentationKey}function o(){n.initialize(e.config,[new Mr]),n.pollInternalLogs()}e.config=t,o(),e.initialize=o,e.getSKUDefaults=function(){e.config.diagnosticLogInterval=e.config.diagnosticLogInterval&&e.config.diagnosticLogInterval>0?e.config.diagnosticLogInterval:1e4},e.getSKUDefaults(),xo(e,n,["track","flush","pollInternalLogs","stopPollingInternalLogs","unload","getPlugin","addPlugin","evtNamespace","addUnloadCb"])}))}return e.__ieDyn=1,e}()},9141:(e,t,n)=>{"use strict";var i;n.d(t,{Z:()=>w});var r,o="undefined",s="prototype",a="function",c="_dynClass",u="_unknown_",l=Object,d=l.getPrototypeOf,f=l.getOwnPropertyNames,p=(typeof globalThis!==o&&(r=globalThis),r||typeof self===o||(r=self),r||typeof window===o||(r=window),r||typeof n.g===o||(r=n.g),r||{}),g=p.__dynProto$Gbl||(p.__dynProto$Gbl={o:(i={},i.setInstFuncs=!0,i.useBaseInst=!0,i),n:1e3});function h(e,t){return e&&l.prototype.hasOwnProperty.call(e,t)}function m(e){return e&&(e===l.prototype||e===Array.prototype)}function v(e){return m(e)||e===Function.prototype}function y(e){var t;if(e){if(d)return d(e);var n=e.__proto__||e.prototype||(e.constructor?e.constructor.prototype:null);t=e._dyn__proto__||n,h(e,"_dyn__proto__")||(delete e._dynInstProto,t=e._dyn__proto__=e._dynInstProto||e._dyn__proto__,e._dynInstProto=n)}return t}function S(e,t){var n=[];if(f)n=f(e);else for(var i in e)"string"==typeof i&&h(e,i)&&n.push(i);if(n&&n.length>0)for(var r=0;r=0;n--)if(e[n]===t)return!0;return!1}function _(e,t,n,i){var r=null;if(e&&h(n,c)){var o=e._dynInstFuncs||{};if((r=(o[n._dynClass]||{})[t])||T("Missing ["+t+"] "+a),!r._dynInstChk&&!1!==o._dynInstChk){for(var s=!h(e,t),u=y(e),l=[];s&&u&&!v(u)&&!b(l,u);){var d=u[t];if(d){s=d===i;break}l.push(u),u=y(u)}try{s&&(e[t]=r),r._dynInstChk=1}catch(e){o._dynInstChk=!1}}}return r}function R(e,t,n){var i=t[e];return i===n&&(i=y(t)[e]),typeof i!==a&&T("["+e+"] is not a "+a),i}function D(e,t){return h(e,s)?e.name||t||u:((e||{}).constructor||{}).name||t||u}function w(e,t,n,i){h(e,s)||T("theClass is an invalid class definition.");var r=e.prototype;(function(e,t){if(d){for(var n=[],i=y(t);i&&!v(i)&&!b(n,i);){if(i===e)return!0;n.push(i),i=y(i)}return!1}return!0})(r,t)||T("["+D(e)+"] not in hierarchy of ["+D(t)+"]");var o=null;h(r,c)?o=r._dynClass:(o="_dynCls$"+D(e,"_")+"$"+g.n,g.n++,r._dynClass=o);var a=w._dfOpts,u=!!a.useBaseInst;u&&i&&void 0!==i.useBaseInst&&(u=!!i.useBaseInst);var l=function(e){var t={};return S(e,(function(n){!t[n]&&C(e,n,!1)&&(t[n]=e[n])})),t}(t),f=function(e,t,n,i){function r(e,t,n){var r=t[n];if(r._isDynProxy&&i){var o=e._dynInstFuncs||{};!1!==o._dynInstChk&&(r=(o[t._dynClass]||{})[n]||r)}return function(){return r.apply(e,arguments)}}var o={};S(n,(function(e){o[e]=r(t,n,e)}));for(var s=y(e),a=[];s&&!v(s)&&!b(a,s);)S(s,(function(e){!o[e]&&C(s,e,!d)&&(o[e]=r(t,s,e))})),a.push(s),s=y(s);return o}(r,t,l,u);n(t,f);var p=!!d&&!!a.setInstFuncs;p&&i&&(p=!!i.setInstFuncs),function(e,t,n,i,r){if(!m(e)){var o=n._dynInstFuncs=n._dynInstFuncs||{},s=o[t]=o[t]||{};!1!==o._dynInstChk&&(o._dynInstChk=!!r),S(n,(function(t){C(n,t,!1)&&n[t]!==i[t]&&(s[t]=n[t],delete n[t],(!h(e,t)||e[t]&&!e[t]._isDynProxy)&&(e[t]=function(e,t){var n=function(){return(_(this,t,e,n)||R(t,e,n)).apply(this,arguments)};return n._isDynProxy=1,n}(e,t)))}))}}(r,o,t,l,!1!==p)}w._dfOpts=g.o},217:(e,t,n)=>{"use strict";n.d(t,{Z:()=>u});var i=n(9496);var r,o=n(5108);!function(e){e[e.NOT_INSTANTIATED=0]="NOT_INSTANTIATED",e[e.INSTANTIATING=1]="INSTANTIATING",e[e.INSTANTIATED=2]="INSTANTIATED"}(r||(r={}));class s{constructor(e,t){this._instantiationStatus=r.NOT_INSTANTIATED,this._eventQueue=[],this._exceptionQueue=[],this._clientFactory=t,this._key=e}sendEventData(e,t){this._telemetryClient?this._telemetryClient.logEvent(e,t):this._instantiationStatus!==r.INSTANTIATED&&this._eventQueue.push({eventName:e,data:t})}sendErrorData(e,t){this._telemetryClient||this._instantiationStatus!==r.INSTANTIATED&&this._exceptionQueue.push({exception:e,data:t})}async flush(){this._telemetryClient&&(await this._telemetryClient.flush(),this._telemetryClient=void 0)}_flushQueues(){this._eventQueue.forEach((({eventName:e,data:t})=>this.sendEventData(e,t))),this._eventQueue=[],this._exceptionQueue.forEach((({exception:e,data:t})=>this.sendErrorData(e,t))),this._exceptionQueue=[]}instantiateSender(){this._instantiationStatus===r.NOT_INSTANTIATED&&(this._instantiationStatus=r.INSTANTIATING,this._clientFactory(this._key).then((e=>{this._telemetryClient=e,this._instantiationStatus=r.INSTANTIATED,this._flushQueues()})).catch((e=>{o.error(e),this._instantiationStatus=r.INSTANTIATED})))}}class a{static applyReplacements(e,t){for(const n of Object.keys(e))for(const i of t)i.lookup.test(n)&&(void 0!==i.replacementString?e[n]=i.replacementString:delete e[n])}static shouldUseOneDataSystemSDK(e){return 74===e.length&&"-"===e[32]&&"-"===e[41]&&"-"===e[46]&&"-"===e[51]&&"-"===e[56]&&"-"===e[69]}static getAdditionalCommonProperties(e){return{"common.os":e.platform,"common.nodeArch":e.architecture,"common.platformversion":(e.release||"").replace(/^(\d+)(\.\d+)?(\.\d+)?(.*)/,"$1$2$3"),"common.telemetryclientversion":"0.7.7"}}static getInstance(){return a._instance||(a._instance=new a),a._instance}}function c(e){if(e.userAgentData){const t=e.userAgentData.brands[e.userAgentData.brands.length-1];return`${e.userAgentData.platform} - ${t?.brand} v${t?.version}}`}return e.appVersion}class u extends class{constructor(e,t,n){this.telemetrySender=e,this.vscodeAPI=t,this.userOptIn=!1,this.errorOptIn=!1,this.disposables=[],this._onDidChangeTelemetryLevel=new this.vscodeAPI.EventEmitter,this.onDidChangeTelemetryLevel=this._onDidChangeTelemetryLevel.event,this.telemetryLogger=this.vscodeAPI.env.createTelemetryLogger(this.telemetrySender,n),this.updateUserOptIn(),this.telemetryLogger.onDidChangeEnableStates((()=>{this.updateUserOptIn()}))}updateUserOptIn(){this.errorOptIn=this.telemetryLogger.isErrorsEnabled,this.userOptIn=this.telemetryLogger.isUsageEnabled,(this.telemetryLogger.isErrorsEnabled||this.telemetryLogger.isUsageEnabled)&&this.telemetrySender.instantiateSender(),this._onDidChangeTelemetryLevel.fire(this.telemetryLevel)}get telemetryLevel(){return this.errorOptIn&&this.userOptIn?"all":this.errorOptIn?"error":"off"}internalSendTelemetryEvent(e,t,n,i){i?this.telemetrySender.sendEventData(e,{properties:t,measurements:n}):this.telemetryLogger.logUsage(e,{properties:t,measurements:n})}sendTelemetryEvent(e,t,n){this.internalSendTelemetryEvent(e,t,n,!1)}sendDangerousTelemetryEvent(e,t,n){this.telemetrySender.instantiateSender(),this.internalSendTelemetryEvent(e,t,n,!0)}internalSendTelemetryErrorEvent(e,t,n,i){i?this.telemetrySender.sendEventData(e,{properties:t,measurements:n}):this.telemetryLogger.logError(e,{properties:t,measurements:n})}sendTelemetryErrorEvent(e,t,n){this.internalSendTelemetryErrorEvent(e,t,n,!1)}sendDangerousTelemetryErrorEvent(e,t,n){this.telemetrySender.instantiateSender(),this.internalSendTelemetryErrorEvent(e,t,n,!0)}internalSendTelemetryException(e,t,n,i){i?this.telemetrySender.sendErrorData(e,{properties:t,measurements:n}):this.telemetryLogger.logError(e,{properties:t,measurements:n})}sendTelemetryException(e,t,n){this.internalSendTelemetryException(e,t,n,!1)}sendDangerousTelemetryException(e,t,n){this.telemetrySender.instantiateSender(),this.internalSendTelemetryException(e,t,n,!0)}dispose(){return this.telemetryLogger.dispose(),Promise.all(this.disposables.map((e=>e.dispose())))}}{constructor(e,t){let r=e=>(async(e,t)=>{let i;try{const t=await Promise.resolve().then(n.bind(n,1626));i=new t.ApplicationInsights({instrumentationKey:e,disableAjaxTracking:!0,disableExceptionTracking:!0,disableFetchTracking:!0,disableCorrelationHeaders:!0,disableCookiesUsage:!0,autoTrackPageVisitTime:!1,emitLineDelimitedJson:!1,disableInstrumentationKeyValidation:!0})}catch(e){return Promise.reject(e)}return{logEvent:(e,n)=>{const r={...n?.properties,...n?.measurements};t?.length&&a.applyReplacements(r,t),i?.track({name:e,data:r})},flush:async()=>{i?.flush()}}})(e,t);a.shouldUseOneDataSystemSDK(e)&&(r=e=>(async(e,t,i)=>{const r=await(async(e,t,i)=>{const r=await Promise.resolve().then(n.bind(n,7164)),o=await Promise.resolve().then(n.bind(n,1488)),s=new r.AppInsightsCore,a=new o.PostChannel,c={instrumentationKey:e,endpointUrl:"https://mobile.events.data.microsoft.com/OneCollector/1.0",loggingLevelTelemetry:0,loggingLevelConsole:0,disableCookiesUsage:!0,disableDbgExt:!0,disableInstrumentationKeyValidation:!0,channels:[[a]]};if(i){c.extensionConfig={};const e={alwaysUseXhrOverride:!0,httpXHROverride:i};c.extensionConfig[a.identifier]=e}const u=t.workspace.getConfiguration("telemetry").get("internalTesting");return s.initialize(c,[]),s.addTelemetryInitializer((e=>{u&&(e.ext=e.ext??{},e.ext.utc=e.ext.utc??{},e.ext.utc.flags=8462029)})),s})(e,t,i);return{logEvent:(e,t)=>{try{r?.track({name:e,baseData:{name:e,properties:t?.properties,measurements:t?.measurements}})}catch(e){throw new Error("Failed to log event to app insights!\n"+e.message)}},flush:async()=>{try{r?.unload()}catch(e){throw new Error("Failed to flush app insights!\n"+e.message)}}}})(e,i));const o={release:c(navigator),platform:"web",architecture:"web"},u=new s(e,r);if(e&&0===e.indexOf("AIF"))throw new Error("AIF keys are no longer supported. Please switch to 1DS keys for 1st party extensions");super(u,i,{additionalCommonProperties:a.getAdditionalCommonProperties(o)})}}},8583:(e,t,n)=>{"use strict";var i=n(7418);function r(e,t){if(e===t)return 0;for(var n=e.length,i=t.length,r=0,o=Math.min(n,i);r=0;u--)if(l[u]!==d[u])return!1;for(u=l.length-1;u>=0;u--)if(!S(e[a=l[u]],t[a],n,i))return!1;return!0}(e,t,n,i))}return n?e===t:e==t}function C(e){return"[object Arguments]"==Object.prototype.toString.call(e)}function T(e,t){if(!e||!t)return!1;if("[object RegExp]"==Object.prototype.toString.call(t))return t.test(e);try{if(e instanceof t)return!0}catch(e){}return!Error.isPrototypeOf(t)&&!0===t.call({},e)}function b(e,t,n,i){var r;if("function"!=typeof t)throw new TypeError('"block" argument must be a function');"string"==typeof n&&(i=n,n=null),r=function(e){var t;try{e()}catch(e){t=e}return t}(t),i=(n&&n.name?" ("+n.name+").":".")+(i?" "+i:"."),e&&!r&&v(r,n,"Missing expected exception"+i);var o="string"==typeof i,a=!e&&r&&!n;if((!e&&s.isError(r)&&o&&T(r,n)||a)&&v(r,n,"Got unwanted exception"+i),e&&r&&n&&!T(r,n)||!e&&r)throw r}f.AssertionError=function(e){this.name="AssertionError",this.actual=e.actual,this.expected=e.expected,this.operator=e.operator,e.message?(this.message=e.message,this.generatedMessage=!1):(this.message=function(e){return h(m(e.actual),128)+" "+e.operator+" "+h(m(e.expected),128)}(this),this.generatedMessage=!0);var t=e.stackStartFunction||v;if(Error.captureStackTrace)Error.captureStackTrace(this,t);else{var n=new Error;if(n.stack){var i=n.stack,r=g(t),o=i.indexOf("\n"+r);if(o>=0){var s=i.indexOf("\n",o+1);i=i.substring(s+1)}this.stack=i}}},s.inherits(f.AssertionError,Error),f.fail=v,f.ok=y,f.equal=function(e,t,n){e!=t&&v(e,t,n,"==",f.equal)},f.notEqual=function(e,t,n){e==t&&v(e,t,n,"!=",f.notEqual)},f.deepEqual=function(e,t,n){S(e,t,!1)||v(e,t,n,"deepEqual",f.deepEqual)},f.deepStrictEqual=function(e,t,n){S(e,t,!0)||v(e,t,n,"deepStrictEqual",f.deepStrictEqual)},f.notDeepEqual=function(e,t,n){S(e,t,!1)&&v(e,t,n,"notDeepEqual",f.notDeepEqual)},f.notDeepStrictEqual=function e(t,n,i){S(t,n,!0)&&v(t,n,i,"notDeepStrictEqual",e)},f.strictEqual=function(e,t,n){e!==t&&v(e,t,n,"===",f.strictEqual)},f.notStrictEqual=function(e,t,n){e===t&&v(e,t,n,"!==",f.notStrictEqual)},f.throws=function(e,t,n){b(!0,e,t,n)},f.doesNotThrow=function(e,t,n){b(!1,e,t,n)},f.ifError=function(e){if(e)throw e},f.strict=i((function e(t,n){t||v(t,!0,n,"==",e)}),f,{equal:f.strictEqual,deepEqual:f.deepStrictEqual,notEqual:f.notStrictEqual,notDeepEqual:f.notDeepStrictEqual}),f.strict.strict=f.strict;var _=Object.keys||function(e){var t=[];for(var n in e)a.call(e,n)&&t.push(n);return t}},6076:e=>{"function"==typeof Object.create?e.exports=function(e,t){e.super_=t,e.prototype=Object.create(t.prototype,{constructor:{value:e,enumerable:!1,writable:!0,configurable:!0}})}:e.exports=function(e,t){e.super_=t;var n=function(){};n.prototype=t.prototype,e.prototype=new n,e.prototype.constructor=e}},2014:e=>{e.exports=function(e){return e&&"object"==typeof e&&"function"==typeof e.copy&&"function"==typeof e.fill&&"function"==typeof e.readUInt8}},69:(e,t,n)=>{var i=n(4155),r=n(5108),o=/%[sdj%]/g;t.format=function(e){if(!y(e)){for(var t=[],n=0;n=r)return e;switch(e){case"%s":return String(i[n++]);case"%d":return Number(i[n++]);case"%j":try{return JSON.stringify(i[n++])}catch(e){return"[Circular]"}default:return e}})),a=i[n];n=3&&(i.depth=arguments[2]),arguments.length>=4&&(i.colors=arguments[3]),h(n)?i.showHidden=n:n&&t._extend(i,n),S(i.showHidden)&&(i.showHidden=!1),S(i.depth)&&(i.depth=2),S(i.colors)&&(i.colors=!1),S(i.customInspect)&&(i.customInspect=!0),i.colors&&(i.stylize=u),d(i,e,i.depth)}function u(e,t){var n=c.styles[t];return n?"["+c.colors[n][0]+"m"+e+"["+c.colors[n][1]+"m":e}function l(e,t){return e}function d(e,n,i){if(e.customInspect&&n&&R(n.inspect)&&n.inspect!==t.inspect&&(!n.constructor||n.constructor.prototype!==n)){var r=n.inspect(i,e);return y(r)||(r=d(e,r,i)),r}var o=function(e,t){if(S(t))return e.stylize("undefined","undefined");if(y(t)){var n="'"+JSON.stringify(t).replace(/^"|"$/g,"").replace(/'/g,"\\'").replace(/\\"/g,'"')+"'";return e.stylize(n,"string")}return v(t)?e.stylize(""+t,"number"):h(t)?e.stylize(""+t,"boolean"):m(t)?e.stylize("null","null"):void 0}(e,n);if(o)return o;var s=Object.keys(n),a=function(e){var t={};return e.forEach((function(e,n){t[e]=!0})),t}(s);if(e.showHidden&&(s=Object.getOwnPropertyNames(n)),_(n)&&(s.indexOf("message")>=0||s.indexOf("description")>=0))return f(n);if(0===s.length){if(R(n)){var c=n.name?": "+n.name:"";return e.stylize("[Function"+c+"]","special")}if(C(n))return e.stylize(RegExp.prototype.toString.call(n),"regexp");if(b(n))return e.stylize(Date.prototype.toString.call(n),"date");if(_(n))return f(n)}var u,l="",T=!1,D=["{","}"];return g(n)&&(T=!0,D=["[","]"]),R(n)&&(l=" [Function"+(n.name?": "+n.name:"")+"]"),C(n)&&(l=" "+RegExp.prototype.toString.call(n)),b(n)&&(l=" "+Date.prototype.toUTCString.call(n)),_(n)&&(l=" "+f(n)),0!==s.length||T&&0!=n.length?i<0?C(n)?e.stylize(RegExp.prototype.toString.call(n),"regexp"):e.stylize("[Object]","special"):(e.seen.push(n),u=T?function(e,t,n,i,r){for(var o=[],s=0,a=t.length;s60?n[0]+(""===t?"":t+"\n ")+" "+e.join(",\n ")+" "+n[1]:n[0]+t+" "+e.join(", ")+" "+n[1]}(u,l,D)):D[0]+l+D[1]}function f(e){return"["+Error.prototype.toString.call(e)+"]"}function p(e,t,n,i,r,o){var s,a,c;if((c=Object.getOwnPropertyDescriptor(t,r)||{value:t[r]}).get?a=c.set?e.stylize("[Getter/Setter]","special"):e.stylize("[Getter]","special"):c.set&&(a=e.stylize("[Setter]","special")),k(i,r)||(s="["+r+"]"),a||(e.seen.indexOf(c.value)<0?(a=m(n)?d(e,c.value,null):d(e,c.value,n-1)).indexOf("\n")>-1&&(a=o?a.split("\n").map((function(e){return" "+e})).join("\n").substr(2):"\n"+a.split("\n").map((function(e){return" "+e})).join("\n")):a=e.stylize("[Circular]","special")),S(s)){if(o&&r.match(/^\d+$/))return a;(s=JSON.stringify(""+r)).match(/^"([a-zA-Z_][a-zA-Z_0-9]*)"$/)?(s=s.substr(1,s.length-2),s=e.stylize(s,"name")):(s=s.replace(/'/g,"\\'").replace(/\\"/g,'"').replace(/(^"|"$)/g,"'"),s=e.stylize(s,"string"))}return s+": "+a}function g(e){return Array.isArray(e)}function h(e){return"boolean"==typeof e}function m(e){return null===e}function v(e){return"number"==typeof e}function y(e){return"string"==typeof e}function S(e){return void 0===e}function C(e){return T(e)&&"[object RegExp]"===D(e)}function T(e){return"object"==typeof e&&null!==e}function b(e){return T(e)&&"[object Date]"===D(e)}function _(e){return T(e)&&("[object Error]"===D(e)||e instanceof Error)}function R(e){return"function"==typeof e}function D(e){return Object.prototype.toString.call(e)}function w(e){return e<10?"0"+e.toString(10):e.toString(10)}t.debuglog=function(e){if(S(s)&&(s=i.env.NODE_DEBUG||""),e=e.toUpperCase(),!a[e])if(new RegExp("\\b"+e+"\\b","i").test(s)){var n=i.pid;a[e]=function(){var i=t.format.apply(t,arguments);r.error("%s %d: %s",e,n,i)}}else a[e]=function(){};return a[e]},t.inspect=c,c.colors={bold:[1,22],italic:[3,23],underline:[4,24],inverse:[7,27],white:[37,39],grey:[90,39],black:[30,39],blue:[34,39],cyan:[36,39],green:[32,39],magenta:[35,39],red:[31,39],yellow:[33,39]},c.styles={special:"cyan",number:"yellow",boolean:"yellow",undefined:"grey",null:"bold",string:"green",date:"magenta",regexp:"red"},t.isArray=g,t.isBoolean=h,t.isNull=m,t.isNullOrUndefined=function(e){return null==e},t.isNumber=v,t.isString=y,t.isSymbol=function(e){return"symbol"==typeof e},t.isUndefined=S,t.isRegExp=C,t.isObject=T,t.isDate=b,t.isError=_,t.isFunction=R,t.isPrimitive=function(e){return null===e||"boolean"==typeof e||"number"==typeof e||"string"==typeof e||"symbol"==typeof e||void 0===e},t.isBuffer=n(2014);var E=["Jan","Feb","Mar","Apr","May","Jun","Jul","Aug","Sep","Oct","Nov","Dec"];function P(){var e=new Date,t=[w(e.getHours()),w(e.getMinutes()),w(e.getSeconds())].join(":");return[e.getDate(),E[e.getMonth()],t].join(" ")}function k(e,t){return Object.prototype.hasOwnProperty.call(e,t)}t.log=function(){r.log("%s - %s",P(),t.format.apply(t,arguments))},t.inherits=n(6076),t._extend=function(e,t){if(!t||!T(t))return e;for(var n=Object.keys(t),i=n.length;i--;)e[n[i]]=t[n[i]];return e}},5623:e=>{"use strict";function t(e,t,r){e instanceof RegExp&&(e=n(e,r)),t instanceof RegExp&&(t=n(t,r));var o=i(e,t,r);return o&&{start:o[0],end:o[1],pre:r.slice(0,o[0]),body:r.slice(o[0]+e.length,o[1]),post:r.slice(o[1]+t.length)}}function n(e,t){var n=t.match(e);return n?n[0]:null}function i(e,t,n){var i,r,o,s,a,c=n.indexOf(e),u=n.indexOf(t,c+1),l=c;if(c>=0&&u>0){for(i=[],o=n.length;l>=0&&!a;)l==c?(i.push(l),c=n.indexOf(e,l+1)):1==i.length?a=[i.pop(),u]:((r=i.pop())=0?c:u;i.length&&(a=[o,s])}return a}e.exports=t,t.range=i},5108:(e,t,n)=>{var i=n(9539),r=n(8583);function o(){return(new Date).getTime()}var s,a=Array.prototype.slice,c={};s=void 0!==n.g&&n.g.console?n.g.console:"undefined"!=typeof window&&window.console?window.console:{};for(var u=[[function(){},"log"],[function(){s.log.apply(s,arguments)},"info"],[function(){s.log.apply(s,arguments)},"warn"],[function(){s.warn.apply(s,arguments)},"error"],[function(e){c[e]=o()},"time"],[function(e){var t=c[e];if(!t)throw new Error("No such label: "+e);delete c[e];var n=o()-t;s.log(e+": "+n+"ms")},"timeEnd"],[function(){var e=new Error;e.name="Trace",e.message=i.format.apply(null,arguments),s.error(e.stack)},"trace"],[function(e){s.log(i.inspect(e)+"\n")},"dir"],[function(e){if(!e){var t=a.call(arguments,1);r.ok(!1,i.format.apply(null,t))}},"assert"]],l=0;l{var i=n(4155);const r="object"==typeof i&&i&&"win32"===i.platform;e.exports=r?{sep:"\\"}:{sep:"/"}},1171:(e,t,n)=>{var i=n(5108);const r=e.exports=(e,t,n={})=>(v(t),!(!n.nocomment&&"#"===t.charAt(0))&&new S(t,n).match(e));e.exports=r;const o=n(8696);r.sep=o.sep;const s=Symbol("globstar **");r.GLOBSTAR=s;const a=n(5282),c={"!":{open:"(?:(?!(?:",close:"))[^/]*?)"},"?":{open:"(?:",close:")?"},"+":{open:"(?:",close:")+"},"*":{open:"(?:",close:")*"},"@":{open:"(?:",close:")"}},u="[^/]",l="[^/]*?",d=e=>e.split("").reduce(((e,t)=>(e[t]=!0,e)),{}),f=d("().*{}+?[]^$\\!"),p=d("[.("),g=/\/+/;r.filter=(e,t={})=>(n,i,o)=>r(n,e,t);const h=(e,t={})=>{const n={};return Object.keys(e).forEach((t=>n[t]=e[t])),Object.keys(t).forEach((e=>n[e]=t[e])),n};r.defaults=e=>{if(!e||"object"!=typeof e||!Object.keys(e).length)return r;const t=r,n=(n,i,r)=>t(n,i,h(e,r));return(n.Minimatch=class extends t.Minimatch{constructor(t,n){super(t,h(e,n))}}).defaults=n=>t.defaults(h(e,n)).Minimatch,n.filter=(n,i)=>t.filter(n,h(e,i)),n.defaults=n=>t.defaults(h(e,n)),n.makeRe=(n,i)=>t.makeRe(n,h(e,i)),n.braceExpand=(n,i)=>t.braceExpand(n,h(e,i)),n.match=(n,i,r)=>t.match(n,i,h(e,r)),n},r.braceExpand=(e,t)=>m(e,t);const m=(e,t={})=>(v(e),t.nobrace||!/\{(?:(?!\{).)*\}/.test(e)?[e]:a(e)),v=e=>{if("string"!=typeof e)throw new TypeError("invalid pattern");if(e.length>65536)throw new TypeError("pattern is too long")},y=Symbol("subparse");r.makeRe=(e,t)=>new S(e,t||{}).makeRe(),r.match=(e,t,n={})=>{const i=new S(t,n);return e=e.filter((e=>i.match(e))),i.options.nonull&&!e.length&&e.push(t),e};class S{constructor(e,t){v(e),t||(t={}),this.options=t,this.set=[],this.pattern=e,this.windowsPathsNoEscape=!!t.windowsPathsNoEscape||!1===t.allowWindowsEscape,this.windowsPathsNoEscape&&(this.pattern=this.pattern.replace(/\\/g,"/")),this.regexp=null,this.negate=!1,this.comment=!1,this.empty=!1,this.partial=!!t.partial,this.make()}debug(){}make(){const e=this.pattern,t=this.options;if(!t.nocomment&&"#"===e.charAt(0))return void(this.comment=!0);if(!e)return void(this.empty=!0);this.parseNegate();let n=this.globSet=this.braceExpand();t.debug&&(this.debug=(...e)=>i.error(...e)),this.debug(this.pattern,n),n=this.globParts=n.map((e=>e.split(g))),this.debug(this.pattern,n),n=n.map(((e,t,n)=>e.map(this.parse,this))),this.debug(this.pattern,n),n=n.filter((e=>-1===e.indexOf(!1))),this.debug(this.pattern,n),this.set=n}parseNegate(){if(this.options.nonegate)return;const e=this.pattern;let t=!1,n=0;for(let i=0;i>> no match, partial?",e,f,t,p),f!==a))}if("string"==typeof l?(u=d===l,this.debug("string match",l,d,u)):(u=d.match(l),this.debug("pattern match",l,d,u)),!u)return!1}if(r===a&&o===c)return!0;if(r===a)return n;if(o===c)return r===a-1&&""===e[r];throw new Error("wtf?")}braceExpand(){return m(this.pattern,this.options)}parse(e,t){v(e);const n=this.options;if("**"===e){if(!n.noglobstar)return s;e="*"}if(""===e)return"";let i="",r=!!n.nocase,o=!1;const a=[],d=[];let g,h,m,S,C=!1,T=-1,b=-1;const _="."===e.charAt(0)?"":n.dot?"(?!(?:^|\\/)\\.{1,2}(?:$|\\/))":"(?!\\.)",R=()=>{if(g){switch(g){case"*":i+=l,r=!0;break;case"?":i+=u,r=!0;break;default:i+="\\"+g}this.debug("clearStateChar %j %j",g,i),g=!1}};for(let t,s=0;s(n||(n="\\"),t+t+n+"|"))),this.debug("tail=%j\n %s",e,e,m,i);const t="*"===m.type?l:"?"===m.type?u:"\\"+m.type;r=!0,i=i.slice(0,m.reStart)+t+"\\("+e}R(),o&&(i+="\\\\");const D=p[i.charAt(0)];for(let e=d.length-1;e>-1;e--){const n=d[e],r=i.slice(0,n.reStart),o=i.slice(n.reStart,n.reEnd-8);let s=i.slice(n.reEnd);const a=i.slice(n.reEnd-8,n.reEnd)+s,c=r.split("(").length-1;let u=s;for(let e=0;e(e=e.map((e=>"string"==typeof e?e.replace(/[-[\]{}()*+?.,\\^$|#\s]/g,"\\$&"):e===s?s:e._src)).reduce(((e,t)=>(e[e.length-1]===s&&t===s||e.push(t),e)),[]),e.forEach(((t,i)=>{t===s&&e[i-1]!==s&&(0===i?e.length>1?e[i+1]="(?:\\/|"+n+"\\/)?"+e[i+1]:e[i]=n:i===e.length-1?e[i-1]+="(?:\\/|"+n+")?":(e[i-1]+="(?:\\/|\\/"+n+"\\/)"+e[i+1],e[i+1]=s))})),e.filter((e=>e!==s)).join("/")))).join("|");r="^(?:"+r+")$",this.negate&&(r="^(?!"+r+").*$");try{this.regexp=new RegExp(r,i)}catch(e){this.regexp=!1}return this.regexp}match(e,t=this.partial){if(this.debug("match",e,this.pattern),this.comment)return!1;if(this.empty)return""===e;if("/"===e&&t)return!0;const n=this.options;"/"!==o.sep&&(e=e.split(o.sep).join("/")),e=e.split(g),this.debug(this.pattern,"split",e);const i=this.set;let r;this.debug(this.pattern,"set",i);for(let t=e.length-1;t>=0&&(r=e[t],!r);t--);for(let o=0;o{var i=n(5623);e.exports=function(e){return e?("{}"===e.substr(0,2)&&(e="\\{\\}"+e.substr(2)),m(function(e){return e.split("\\\\").join(r).split("\\{").join(o).split("\\}").join(s).split("\\,").join(a).split("\\.").join(c)}(e),!0).map(l)):[]};var r="\0SLASH"+Math.random()+"\0",o="\0OPEN"+Math.random()+"\0",s="\0CLOSE"+Math.random()+"\0",a="\0COMMA"+Math.random()+"\0",c="\0PERIOD"+Math.random()+"\0";function u(e){return parseInt(e,10)==e?parseInt(e,10):e.charCodeAt(0)}function l(e){return e.split(r).join("\\").split(o).join("{").split(s).join("}").split(a).join(",").split(c).join(".")}function d(e){if(!e)return[""];var t=[],n=i("{","}",e);if(!n)return e.split(",");var r=n.pre,o=n.body,s=n.post,a=r.split(",");a[a.length-1]+="{"+o+"}";var c=d(s);return s.length&&(a[a.length-1]+=c.shift(),a.push.apply(a,c)),t.push.apply(t,a),t}function f(e){return"{"+e+"}"}function p(e){return/^-?0\d/.test(e)}function g(e,t){return e<=t}function h(e,t){return e>=t}function m(e,t){var n=[],r=i("{","}",e);if(!r)return[e];var o=r.pre,a=r.post.length?m(r.post,!1):[""];if(/\$$/.test(r.pre))for(var c=0;c=0;if(!T&&!b)return r.post.match(/,.*\}/)?m(e=r.pre+"{"+r.body+s+r.post):[e];if(T)v=r.body.split(/\.\./);else if(1===(v=d(r.body)).length&&1===(v=m(v[0],!1).map(f)).length)return a.map((function(e){return r.pre+v[0]+e}));if(T){var _=u(v[0]),R=u(v[1]),D=Math.max(v[0].length,v[1].length),w=3==v.length?Math.abs(u(v[2])):1,E=g;R<_&&(w*=-1,E=h);var P=v.some(p);y=[];for(var k=_;E(k,R);k+=w){var x;if(C)"\\"===(x=String.fromCharCode(k))&&(x="");else if(x=String(k),P){var N=D-x.length;if(N>0){var O=new Array(N+1).join("0");x=k<0?"-"+O+x.slice(1):O+x}}y.push(x)}}else{y=[];for(var I=0;I{"use strict";var t=Object.getOwnPropertySymbols,n=Object.prototype.hasOwnProperty,i=Object.prototype.propertyIsEnumerable;function r(e){if(null==e)throw new TypeError("Object.assign cannot be called with null or undefined");return Object(e)}e.exports=function(){try{if(!Object.assign)return!1;var e=new String("abc");if(e[5]="de","5"===Object.getOwnPropertyNames(e)[0])return!1;for(var t={},n=0;n<10;n++)t["_"+String.fromCharCode(n)]=n;if("0123456789"!==Object.getOwnPropertyNames(t).map((function(e){return t[e]})).join(""))return!1;var i={};return"abcdefghijklmnopqrst".split("").forEach((function(e){i[e]=e})),"abcdefghijklmnopqrst"===Object.keys(Object.assign({},i)).join("")}catch(e){return!1}}()?Object.assign:function(e,o){for(var s,a,c=r(e),u=1;u{var i=n(4155);function r(e,t){for(var n=0,i=e.length-1;i>=0;i--){var r=e[i];"."===r?e.splice(i,1):".."===r?(e.splice(i,1),n++):n&&(e.splice(i,1),n--)}if(t)for(;n--;n)e.unshift("..");return e}function o(e,t){if(e.filter)return e.filter(t);for(var n=[],i=0;i=-1&&!t;n--){var s=n>=0?arguments[n]:i.cwd();if("string"!=typeof s)throw new TypeError("Arguments to path.resolve must be strings");s&&(e=s+"/"+e,t="/"===s.charAt(0))}return(t?"/":"")+(e=r(o(e.split("/"),(function(e){return!!e})),!t).join("/"))||"."},t.normalize=function(e){var n=t.isAbsolute(e),i="/"===s(e,-1);return(e=r(o(e.split("/"),(function(e){return!!e})),!n).join("/"))||n||(e="."),e&&i&&(e+="/"),(n?"/":"")+e},t.isAbsolute=function(e){return"/"===e.charAt(0)},t.join=function(){var e=Array.prototype.slice.call(arguments,0);return t.normalize(o(e,(function(e,t){if("string"!=typeof e)throw new TypeError("Arguments to path.join must be strings");return e})).join("/"))},t.relative=function(e,n){function i(e){for(var t=0;t=0&&""===e[n];n--);return t>n?[]:e.slice(t,n-t+1)}e=t.resolve(e).substr(1),n=t.resolve(n).substr(1);for(var r=i(e.split("/")),o=i(n.split("/")),s=Math.min(r.length,o.length),a=s,c=0;c=1;--o)if(47===(t=e.charCodeAt(o))){if(!r){i=o;break}}else r=!1;return-1===i?n?"/":".":n&&1===i?"/":e.slice(0,i)},t.basename=function(e,t){var n=function(e){"string"!=typeof e&&(e+="");var t,n=0,i=-1,r=!0;for(t=e.length-1;t>=0;--t)if(47===e.charCodeAt(t)){if(!r){n=t+1;break}}else-1===i&&(r=!1,i=t+1);return-1===i?"":e.slice(n,i)}(e);return t&&n.substr(-1*t.length)===t&&(n=n.substr(0,n.length-t.length)),n},t.extname=function(e){"string"!=typeof e&&(e+="");for(var t=-1,n=0,i=-1,r=!0,o=0,s=e.length-1;s>=0;--s){var a=e.charCodeAt(s);if(47!==a)-1===i&&(r=!1,i=s+1),46===a?-1===t?t=s:1!==o&&(o=1):-1!==t&&(o=-1);else if(!r){n=s+1;break}}return-1===t||-1===i||0===o||1===o&&t===i-1&&t===n+1?"":e.slice(t,i)};var s=function(e,t,n){return e.substr(t,n)}},4155:e=>{var t,n,i=e.exports={};function r(){throw new Error("setTimeout has not been defined")}function o(){throw new Error("clearTimeout has not been defined")}function s(e){if(t===setTimeout)return setTimeout(e,0);if((t===r||!t)&&setTimeout)return t=setTimeout,setTimeout(e,0);try{return t(e,0)}catch(n){try{return t.call(null,e,0)}catch(n){return t.call(this,e,0)}}}!function(){try{t="function"==typeof setTimeout?setTimeout:r}catch(e){t=r}try{n="function"==typeof clearTimeout?clearTimeout:o}catch(e){n=o}}();var a,c=[],u=!1,l=-1;function d(){u&&a&&(u=!1,a.length?c=a.concat(c):l=-1,c.length&&f())}function f(){if(!u){var e=s(d);u=!0;for(var t=c.length;t;){for(a=c,c=[];++l1)for(var n=1;n{"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.LanguageClientMiddlewareBase=void 0;const i=n(6470),r=n(9496),o=n(5770),s=n(6298),a=n(6255),c=n(9467),u=n(5175),l=n(7962),d=n(24),f=n(3699),p=3e5,g=6e4;t.LanguageClientMiddlewareBase=class{constructor(e,t,n,i){this.serviceContainer=e,this.sendTelemetryEventFunc=n,this.serverVersion=i,this.lastCaptured=new Map,this.nextWindow=0,this.eventCount=0,this.workspace={configuration:async(e,t,n)=>{var i,s,c;if(!this.serviceContainer)return n(e,t);const d=this.serviceContainer.get(l.IInterpreterService),f=this.serviceContainer.get(u.IEnvironmentVariablesProvider);let p=n(e,t);if((0,a.isThenable)(p)&&(p=await p),p instanceof o.ResponseError)return p;for(const[t,n]of e.items.entries()){if("python"===n.section){const e=n.scopeUri?r.Uri.parse(n.scopeUri):void 0,o=p[t];o.pythonPath=null!==(c=null!==(i=await this.getPythonPathOverride(e))&&void 0!==i?i:null===(s=await d.getActiveInterpreter(e))||void 0===s?void 0:s.path)&&void 0!==c?c:"python";const a=(await f.getEnvironmentVariables(e)).PYTHONPATH;a&&(o._envPYTHONPATH=a)}this.configurationHook(n,p[t])}return p}},this.connectedPromise=(0,a.createDeferred)(),this.notebooks={didOpen:this.didOpenNotebook.bind(this),didSave:this.didSaveNotebook.bind(this),didChange:this.didChangeNotebook.bind(this),didClose:this.didCloseNotebook.bind(this)},this.handleDiagnostics=this.handleDiagnostics.bind(this),this.didOpen=this.didOpen.bind(this),this.didSave=this.didSave.bind(this),this.didChange=this.didChange.bind(this),this.didClose=this.didClose.bind(this),this.willSave=this.willSave.bind(this),this.willSaveWaitUntil=this.willSaveWaitUntil.bind(this),t===f.LanguageServerType.Node?this.eventName=d.EventName.LANGUAGE_SERVER_REQUEST:t===f.LanguageServerType.Jedi&&(this.eventName=d.EventName.JEDI_LANGUAGE_SERVER_REQUEST)}async getPythonPathOverride(e){}configurationHook(e,t){}get connected(){return this.connectedPromise.promise}connect(){this.connectedPromise.resolve(!0)}disconnect(){this.connectedPromise=(0,a.createDeferred)(),this.connectedPromise.resolve(!1)}didChange(){return this.callNext("didChange",arguments)}didOpen(){return this.callNext("didOpen",arguments)}didClose(){return this.callNext("didClose",arguments)}didSave(){return this.callNext("didSave",arguments)}willSave(){return this.callNext("willSave",arguments)}willSaveWaitUntil(){return this.callNext("willSaveWaitUntil",arguments)}async didOpenNotebook(){return this.callNotebooksNext("didOpen",arguments)}async didSaveNotebook(){return this.callNotebooksNext("didSave",arguments)}async didChangeNotebook(){return this.callNotebooksNext("didChange",arguments)}async didCloseNotebook(){return this.callNotebooksNext("didClose",arguments)}async provideCompletionItem(){if(await this.connected)return this.callNextAndSendTelemetry("textDocument/completion",p,"provideCompletionItem",arguments,((e,t)=>t?{resultLength:Array.isArray(t)?t.length:t.items.length}:{resultLength:0}))}async provideHover(){if(await this.connected)return this.callNextAndSendTelemetry("textDocument/hover",p,"provideHover",arguments)}async handleDiagnostics(e,t,n){if(await this.connected){const t=e.fsPath,n=t?i.basename(t):void 0;if(!n||!n.startsWith(s.HiddenFilePrefix))return this.callNext("handleDiagnostics",arguments)}}async resolveCompletionItem(){if(await this.connected)return this.callNextAndSendTelemetry("completionItem/resolve",p,"resolveCompletionItem",arguments)}async provideSignatureHelp(){if(await this.connected)return this.callNextAndSendTelemetry("textDocument/signatureHelp",p,"provideSignatureHelp",arguments)}async provideDefinition(){if(await this.connected)return this.callNextAndSendTelemetry("textDocument/definition",g,"provideDefinition",arguments)}async provideReferences(){if(await this.connected)return this.callNextAndSendTelemetry("textDocument/references",g,"provideReferences",arguments)}async provideDocumentHighlights(){if(await this.connected)return this.callNext("provideDocumentHighlights",arguments)}async provideDocumentSymbols(){if(await this.connected)return this.callNextAndSendTelemetry("textDocument/documentSymbol",p,"provideDocumentSymbols",arguments)}async provideWorkspaceSymbols(){if(await this.connected)return this.callNextAndSendTelemetry("workspace/symbol",g,"provideWorkspaceSymbols",arguments)}async provideCodeActions(){if(await this.connected)return this.callNextAndSendTelemetry("textDocument/codeAction",p,"provideCodeActions",arguments)}async provideCodeLenses(){if(await this.connected)return this.callNextAndSendTelemetry("textDocument/codeLens",p,"provideCodeLenses",arguments)}async resolveCodeLens(){if(await this.connected)return this.callNextAndSendTelemetry("codeLens/resolve",p,"resolveCodeLens",arguments)}async provideDocumentFormattingEdits(){if(await this.connected)return this.callNext("provideDocumentFormattingEdits",arguments)}async provideDocumentRangeFormattingEdits(){if(await this.connected)return this.callNext("provideDocumentRangeFormattingEdits",arguments)}async provideOnTypeFormattingEdits(){if(await this.connected)return this.callNextAndSendTelemetry("textDocument/onTypeFormatting",p,"provideOnTypeFormattingEdits",arguments)}async provideRenameEdits(){if(await this.connected)return this.callNextAndSendTelemetry("textDocument/rename",g,"provideRenameEdits",arguments)}async prepareRename(){if(await this.connected)return this.callNextAndSendTelemetry("textDocument/prepareRename",g,"prepareRename",arguments)}async provideDocumentLinks(){if(await this.connected)return this.callNext("provideDocumentLinks",arguments)}async resolveDocumentLink(){if(await this.connected)return this.callNext("resolveDocumentLink",arguments)}async provideDeclaration(){if(await this.connected)return this.callNextAndSendTelemetry("textDocument/declaration",g,"provideDeclaration",arguments)}async provideTypeDefinition(){if(await this.connected)return this.callNextAndSendTelemetry("textDocument/typeDefinition",g,"provideTypeDefinition",arguments)}async provideImplementation(){if(await this.connected)return this.callNext("provideImplementation",arguments)}async provideDocumentColors(){if(await this.connected)return this.callNext("provideDocumentColors",arguments)}async provideColorPresentations(){if(await this.connected)return this.callNext("provideColorPresentations",arguments)}async provideFoldingRanges(){if(await this.connected)return this.callNextAndSendTelemetry("textDocument/foldingRange",p,"provideFoldingRanges",arguments)}async provideSelectionRanges(){if(await this.connected)return this.callNextAndSendTelemetry("textDocument/selectionRange",g,"provideSelectionRanges",arguments)}async prepareCallHierarchy(){if(await this.connected)return this.callNext("prepareCallHierarchy",arguments)}async provideCallHierarchyIncomingCalls(){if(await this.connected)return this.callNext("provideCallHierarchyIncomingCalls",arguments)}async provideCallHierarchyOutgoingCalls(){if(await this.connected)return this.callNext("provideCallHierarchyOutgoingCalls",arguments)}async provideDocumentSemanticTokens(){if(await this.connected)return this.callNext("provideDocumentSemanticTokens",arguments)}async provideDocumentSemanticTokensEdits(){if(await this.connected)return this.callNext("provideDocumentSemanticTokensEdits",arguments)}async provideDocumentRangeSemanticTokens(){if(await this.connected)return this.callNext("provideDocumentRangeSemanticTokens",arguments)}async provideLinkedEditingRange(){if(await this.connected)return this.callNext("provideLinkedEditingRange",arguments)}callNext(e,t){return this.notebookAddon&&this.notebookAddon[e]?this.notebookAddon[e](...t):t[t.length-1](...t)}callNotebooksNext(e,t){var n;return(null===(n=this.notebookAddon)||void 0===n?void 0:n.notebooks)&&this.notebookAddon.notebooks[e]?this.notebookAddon.notebooks[e](...t):t[t.length-1](...t)}callNextAndSendTelemetry(e,t,n,i,r){const o=Date.now(),s=new c.StopWatch;let u=!1;const l=[...i];l[l.length-1]=(...e)=>(u=!0,i[i.length-1](...e)),o>this.nextWindow&&(this.nextWindow=o+36e5,this.eventCount=0);const d=this.lastCaptured.get(e),f=n=>{if(this.eventName&&u&&this.eventCount<100&&(!d||o-d>t)){this.lastCaptured.set(e,o),this.eventCount+=1;const t=e.replace(/\//g,"."),i={lsVersion:this.serverVersion||"unknown",method:t};let a=s.elapsedTime;r&&(a={duration:a,...r(this,n)}),this.sendTelemetryEventFunc(this.eventName,a,i)}return n},p=this.callNext(n,l);return(0,a.isThenable)(p)?p.then(f):f(p)}}},3699:(e,t)=>{"use strict";var n;Object.defineProperty(t,"__esModule",{value:!0}),t.IExtensionSingleActivationService=t.ILanguageServerOutputChannel=t.ILanguageServerProxy=t.ILanguageServerManager=t.ILanguageServerAnalysisOptions=t.ILanguageClientFactory=t.ILanguageServerActivator=t.LanguageServerType=t.IExtensionActivationService=t.IExtensionActivationManager=void 0,t.IExtensionActivationManager=Symbol("IExtensionActivationManager"),t.IExtensionActivationService=Symbol("IExtensionActivationService"),(n=t.LanguageServerType||(t.LanguageServerType={})).Jedi="Jedi",n.JediLSP="JediLSP",n.Microsoft="Microsoft",n.Node="Pylance",n.None="None",t.ILanguageServerActivator=Symbol("ILanguageServerActivator"),t.ILanguageClientFactory=Symbol("ILanguageClientFactory"),t.ILanguageServerAnalysisOptions=Symbol("ILanguageServerAnalysisOptions"),t.ILanguageServerManager=Symbol("ILanguageServerManager"),t.ILanguageServerProxy=Symbol("ILanguageServerProxy"),t.ILanguageServerOutputChannel=Symbol("ILanguageServerOutputChannel"),t.IExtensionSingleActivationService=Symbol("IExtensionSingleActivationService")},9497:(e,t,n)=>{"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.buildApi=void 0;const i=n(8595),r=n(6298);t.buildApi=function(e){return{pylance:{createClient:(...e)=>new i.LanguageClient(r.PYTHON_LANGUAGE,"Python Language Server",e[0],e[1]),start:e=>e.start(),stop:e=>e.stop(),getTelemetryReporter:()=>e}}}},774:(e,t,n)=>{"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.createStatusItem=void 0;const i=n(9496),r=n(8654);t.createStatusItem=function(){if("createLanguageStatusItem"in i.languages){const e=i.languages.createLanguageStatusItem("python.projectStatus",{language:"python"});return e.name=r.LanguageService.statusItem.name,e.severity=i.LanguageStatusSeverity.Warning,e.text=r.LanguageService.statusItem.text,e.detail=r.LanguageService.statusItem.detail,e.command={title:r.Common.learnMore,command:"vscode.open",arguments:[i.Uri.parse("https://aka.ms/AAdzyh4")]},e}return{dispose:()=>{}}}},8654:(e,t,n)=>{"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.Common=t.LanguageService=void 0;const i=n(9496);(t.LanguageService||(t.LanguageService={})).statusItem={name:i.l10n.t("Python IntelliSense Status"),text:i.l10n.t("Partial Mode"),detail:i.l10n.t("Limited IntelliSense provided by Pylance")},(t.Common||(t.Common={})).learnMore=i.l10n.t("Learn more")},6298:function(e,t,n){"use strict";var i,r,o,s,a=n(4155),c=this&&this.__createBinding||(Object.create?function(e,t,n,i){void 0===i&&(i=n),Object.defineProperty(e,i,{enumerable:!0,get:function(){return t[n]}})}:function(e,t,n,i){void 0===i&&(i=n),e[i]=t[n]}),u=this&&this.__exportStar||function(e,t){for(var n in e)"default"===n||Object.prototype.hasOwnProperty.call(t,n)||c(t,e,n)};function l(){return"1"===a.env.VSC_PYTHON_UNIT_TEST}Object.defineProperty(t,"__esModule",{value:!0}),t.UseProposedApi=t.isUnitTestExecution=t.isTestExecution=t.isCI=t.DEFAULT_INTERPRETER_SETTING=t.ThemeIcons=t.Octicons=t.Commands=t.CommandSource=t.AppinsightsKey=t.JUPYTER_EXTENSION_ID=t.PYLANCE_EXTENSION_ID=t.PVSC_EXTENSION_ID=t.PYTHON_NOTEBOOKS=t.PYTHON=t.InteractiveScheme=t.InteractiveInputScheme=t.NotebookCellScheme=t.PYTHON_WARNINGS=t.PYTHON_LANGUAGE=void 0,t.PYTHON_LANGUAGE="python",t.PYTHON_WARNINGS="PYTHONWARNINGS",t.NotebookCellScheme="vscode-notebook-cell",t.InteractiveInputScheme="vscode-interactive-input",t.InteractiveScheme="vscode-interactive",t.PYTHON=[{scheme:"file",language:t.PYTHON_LANGUAGE},{scheme:"untitled",language:t.PYTHON_LANGUAGE},{scheme:"vscode-notebook",language:t.PYTHON_LANGUAGE},{scheme:t.NotebookCellScheme,language:t.PYTHON_LANGUAGE},{scheme:t.InteractiveInputScheme,language:t.PYTHON_LANGUAGE}],t.PYTHON_NOTEBOOKS=[{scheme:"vscode-notebook",language:t.PYTHON_LANGUAGE},{scheme:t.NotebookCellScheme,language:t.PYTHON_LANGUAGE},{scheme:t.InteractiveInputScheme,language:t.PYTHON_LANGUAGE}],t.PVSC_EXTENSION_ID="ms-python.python",t.PYLANCE_EXTENSION_ID="ms-python.vscode-pylance",t.JUPYTER_EXTENSION_ID="ms-toolsai.jupyter",t.AppinsightsKey="0c6ae279ed8443289764825290e4f9e2-1a736e7c-1324-4338-be46-fc2a58ae4d14-7255",(s=t.CommandSource||(t.CommandSource={})).ui="ui",s.commandPalette="commandpalette",(o=t.Commands||(t.Commands={})).ClearStorage="python.clearCacheAndReload",o.CreateNewFile="python.createNewFile",o.ClearWorkspaceInterpreter="python.clearWorkspaceInterpreter",o.Create_Environment="python.createEnvironment",o.Create_Environment_Button="python.createEnvironment-button",o.Create_Terminal="python.createTerminal",o.Debug_In_Terminal="python.debugInTerminal",o.Enable_Linter="python.enableLinting",o.Enable_SourceMap_Support="python.enableSourceMapSupport",o.Exec_In_Terminal="python.execInTerminal",o.Exec_In_Terminal_Icon="python.execInTerminal-icon",o.Exec_In_Separate_Terminal="python.execInDedicatedTerminal",o.Exec_Selection_In_Django_Shell="python.execSelectionInDjangoShell",o.Exec_Selection_In_Terminal="python.execSelectionInTerminal",o.GetSelectedInterpreterPath="python.interpreterPath",o.InstallJupyter="python.installJupyter",o.InstallPython="python.installPython",o.InstallPythonOnLinux="python.installPythonOnLinux",o.InstallPythonOnMac="python.installPythonOnMac",o.LaunchTensorBoard="python.launchTensorBoard",o.PickLocalProcess="python.pickLocalProcess",o.RefreshTensorBoard="python.refreshTensorBoard",o.ReportIssue="python.reportIssue",o.Run_Linter="python.runLinting",o.Set_Interpreter="python.setInterpreter",o.Set_Linter="python.setLinter",o.Set_ShebangInterpreter="python.setShebangInterpreter",o.Sort_Imports="python.sortImports",o.Start_REPL="python.startREPL",o.Tests_Configure="python.configureTests",o.TriggerEnvironmentSelection="python.triggerEnvSelection",o.ViewOutput="python.viewOutput",(r=t.Octicons||(t.Octicons={})).Add="$(add)",r.Test_Pass="$(check)",r.Test_Fail="$(alert)",r.Test_Error="$(x)",r.Test_Skip="$(circle-slash)",r.Downloading="$(cloud-download)",r.Installing="$(desktop-download)",r.Search_Stop="$(search-stop)",r.Star="$(star-full)",r.Gear="$(gear)",r.Warning="$(warning)",r.Error="$(error)",r.Lightbulb="$(lightbulb)",(i=t.ThemeIcons||(t.ThemeIcons={})).Refresh="refresh",i.SpinningLoader="loading~spin",t.DEFAULT_INTERPRETER_SETTING="python",t.isCI="true"===a.env.TRAVIS||void 0!==a.env.TF_BUILD,t.isTestExecution=function(){return"1"===a.env.VSC_PYTHON_CI_TEST||l()},t.isUnitTestExecution=l,t.UseProposedApi=Symbol("USE_VSC_PROPOSED_API"),u(n(9732),t)},6255:(e,t)=>{"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.flattenIterator=t.iterable=t.mapToIterator=t.chain=t.iterEmpty=t.createDeferredFromPromise=t.createDeferredFrom=t.createDeferred=t.isPromise=t.isThenable=t.sleep=void 0,t.sleep=async function(e){return new Promise((t=>{setTimeout((()=>t(e)),e)}))},t.isThenable=function(e){return"function"==typeof(null==e?void 0:e.then)},t.isPromise=function(e){return"function"==typeof(null==e?void 0:e.then)&&"function"==typeof(null==e?void 0:e.catch)};class n{constructor(e=null){this.scope=e,this._resolved=!1,this._rejected=!1,this._promise=new Promise(((e,t)=>{this._resolve=e,this._reject=t}))}resolve(e){this.completed||(this._resolve.apply(this.scope?this.scope:this,[e]),this._resolved=!0)}reject(e){this.completed||(this._reject.apply(this.scope?this.scope:this,[e]),this._rejected=!0)}get promise(){return this._promise}get resolved(){return this._resolved}get rejected(){return this._rejected}get completed(){return this._rejected||this._resolved}}function i(e=null){return new n(e)}async function r(e,t){const n=void 0===t?-1:t;try{return{index:n,result:await e.next(),err:null}}catch(e){return{index:n,err:e,result:null}}}t.createDeferred=i,t.createDeferredFrom=function(...e){const t=i();return Promise.all(e).then(t.resolve.bind(t)).catch(t.reject.bind(t)),t},t.createDeferredFromPromise=function(e){const t=i();return e.then(t.resolve.bind(t)).catch(t.reject.bind(t)),t},t.iterEmpty=function(){return async function*(){}()};const o=new Promise((()=>{}));async function*s(e,t){const n=e.map(r);let i=e.length;for(;i>0;){const{index:s,result:a,err:c}=await Promise.race(n);null!==c?(n[s]=o,i-=1,void 0!==t&&await t(c,s)):a.done?(n[s]=o,i-=1,void 0!==a.value&&(yield a.value)):(n[s]=r(e[s],s),yield a.value)}}function a(e){const t=e;return void 0===t[Symbol.asyncIterator]&&(t[Symbol.asyncIterator]=()=>t),t}t.chain=s,t.mapToIterator=async function*(e,t,n=!0){if(n){const n=e.map((e=>async function*(){yield t(e)}()));yield*a(s(n))}else yield*e.map(t)},t.iterable=a,t.flattenIterator=async function(e){const t=[];for await(const n of a(e))t.push(n);return t}},9467:(e,t)=>{"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.StopWatch=void 0,t.StopWatch=class{constructor(){this.started=(new Date).getTime()}get elapsedTime(){return(new Date).getTime()-this.started}reset(){this.started=(new Date).getTime()}}},5175:(e,t)=>{"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.IEnvironmentVariablesProvider=t.IEnvironmentVariablesService=void 0,t.IEnvironmentVariablesService=Symbol("IEnvironmentVariablesService"),t.IEnvironmentVariablesProvider=Symbol("IEnvironmentVariablesProvider")},9732:(e,t,n)=>{"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.HiddenFilePrefix=t.EXTENSION_ROOT_DIR=void 0;const i=n(6470),r=i.basename("/");t.EXTENSION_ROOT_DIR="client"===r?i.join("/","..",".."):i.join("/","..","..","..",".."),t.HiddenFilePrefix="_HiddenFile_"},7962:(e,t)=>{"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.IActivatedEnvironmentLaunch=t.IInterpreterStatusbarVisibilityFilter=t.IInterpreterHelper=t.IInterpreterDisplay=t.IInterpreterService=t.ICondaService=t.IComponentAdapter=void 0,t.IComponentAdapter=Symbol("IComponentAdapter"),t.ICondaService=Symbol("ICondaService"),t.IInterpreterService=Symbol("IInterpreterService"),t.IInterpreterDisplay=Symbol("IInterpreterDisplay"),t.IInterpreterHelper=Symbol("IInterpreterHelper"),t.IInterpreterStatusbarVisibilityFilter=Symbol("IInterpreterStatusbarVisibilityFilter"),t.IActivatedEnvironmentLaunch=Symbol("IActivatedEnvironmentLaunch")},24:(e,t)=>{"use strict";var n,i;Object.defineProperty(t,"__esModule",{value:!0}),t.PlatformErrors=t.EventName=void 0,(i=t.EventName||(t.EventName={})).FORMAT_SORT_IMPORTS="FORMAT.SORT_IMPORTS",i.FORMAT="FORMAT.FORMAT",i.FORMAT_ON_TYPE="FORMAT.FORMAT_ON_TYPE",i.EDITOR_LOAD="EDITOR.LOAD",i.LINTING="LINTING",i.REPL="REPL",i.CREATE_NEW_FILE_COMMAND="CREATE_NEW_FILE_COMMAND",i.SELECT_INTERPRETER="SELECT_INTERPRETER",i.SELECT_INTERPRETER_ENTER_BUTTON="SELECT_INTERPRETER_ENTER_BUTTON",i.SELECT_INTERPRETER_ENTER_CHOICE="SELECT_INTERPRETER_ENTER_CHOICE",i.SELECT_INTERPRETER_SELECTED="SELECT_INTERPRETER_SELECTED",i.SELECT_INTERPRETER_ENTER_OR_FIND="SELECT_INTERPRETER_ENTER_OR_FIND",i.SELECT_INTERPRETER_ENTERED_EXISTS="SELECT_INTERPRETER_ENTERED_EXISTS",i.PYTHON_INTERPRETER="PYTHON_INTERPRETER",i.PYTHON_INSTALL_PACKAGE="PYTHON_INSTALL_PACKAGE",i.ENVIRONMENT_WITHOUT_PYTHON_SELECTED="ENVIRONMENT_WITHOUT_PYTHON_SELECTED",i.PYTHON_ENVIRONMENTS_API="PYTHON_ENVIRONMENTS_API",i.PYTHON_INTERPRETER_DISCOVERY="PYTHON_INTERPRETER_DISCOVERY",i.PYTHON_INTERPRETER_AUTO_SELECTION="PYTHON_INTERPRETER_AUTO_SELECTION",i.PYTHON_INTERPRETER_ACTIVATION_ENVIRONMENT_VARIABLES="PYTHON_INTERPRETER.ACTIVATION_ENVIRONMENT_VARIABLES",i.PYTHON_INTERPRETER_ACTIVATION_FOR_RUNNING_CODE="PYTHON_INTERPRETER_ACTIVATION_FOR_RUNNING_CODE",i.PYTHON_INTERPRETER_ACTIVATION_FOR_TERMINAL="PYTHON_INTERPRETER_ACTIVATION_FOR_TERMINAL",i.TERMINAL_SHELL_IDENTIFICATION="TERMINAL_SHELL_IDENTIFICATION",i.PYTHON_INTERPRETER_ACTIVATE_ENVIRONMENT_PROMPT="PYTHON_INTERPRETER_ACTIVATE_ENVIRONMENT_PROMPT",i.PYTHON_NOT_INSTALLED_PROMPT="PYTHON_NOT_INSTALLED_PROMPT",i.CONDA_INHERIT_ENV_PROMPT="CONDA_INHERIT_ENV_PROMPT",i.REQUIRE_JUPYTER_PROMPT="REQUIRE_JUPYTER_PROMPT",i.ACTIVATED_CONDA_ENV_LAUNCH="ACTIVATED_CONDA_ENV_LAUNCH",i.ENVFILE_VARIABLE_SUBSTITUTION="ENVFILE_VARIABLE_SUBSTITUTION",i.ENVFILE_WORKSPACE="ENVFILE_WORKSPACE",i.EXECUTION_CODE="EXECUTION_CODE",i.EXECUTION_DJANGO="EXECUTION_DJANGO",i.DEBUG_IN_TERMINAL_BUTTON="DEBUG.IN_TERMINAL",i.DEBUG_ADAPTER_USING_WHEELS_PATH="DEBUG_ADAPTER.USING_WHEELS_PATH",i.DEBUG_SESSION_ERROR="DEBUG_SESSION.ERROR",i.DEBUG_SESSION_START="DEBUG_SESSION.START",i.DEBUG_SESSION_STOP="DEBUG_SESSION.STOP",i.DEBUG_SESSION_USER_CODE_RUNNING="DEBUG_SESSION.USER_CODE_RUNNING",i.DEBUGGER="DEBUGGER",i.DEBUGGER_ATTACH_TO_CHILD_PROCESS="DEBUGGER.ATTACH_TO_CHILD_PROCESS",i.DEBUGGER_ATTACH_TO_LOCAL_PROCESS="DEBUGGER.ATTACH_TO_LOCAL_PROCESS",i.DEBUGGER_CONFIGURATION_PROMPTS="DEBUGGER.CONFIGURATION.PROMPTS",i.DEBUGGER_CONFIGURATION_PROMPTS_IN_LAUNCH_JSON="DEBUGGER.CONFIGURATION.PROMPTS.IN.LAUNCH.JSON",i.UNITTEST_CONFIGURING="UNITTEST.CONFIGURING",i.UNITTEST_CONFIGURE="UNITTEST.CONFIGURE",i.UNITTEST_DISCOVERY_TRIGGER="UNITTEST.DISCOVERY.TRIGGER",i.UNITTEST_DISCOVERING="UNITTEST.DISCOVERING",i.UNITTEST_DISCOVERING_STOP="UNITTEST.DISCOVERY.STOP",i.UNITTEST_DISCOVERY_DONE="UNITTEST.DISCOVERY.DONE",i.UNITTEST_RUN_STOP="UNITTEST.RUN.STOP",i.UNITTEST_RUN="UNITTEST.RUN",i.UNITTEST_RUN_ALL_FAILED="UNITTEST.RUN_ALL_FAILED",i.UNITTEST_DISABLED="UNITTEST.DISABLED",i.PYTHON_EXPERIMENTS_INIT_PERFORMANCE="PYTHON_EXPERIMENTS_INIT_PERFORMANCE",i.PYTHON_EXPERIMENTS_LSP_NOTEBOOKS="PYTHON_EXPERIMENTS_LSP_NOTEBOOKS",i.PYTHON_EXPERIMENTS_OPT_IN_OPT_OUT_SETTINGS="PYTHON_EXPERIMENTS_OPT_IN_OPT_OUT_SETTINGS",i.EXTENSION_SURVEY_PROMPT="EXTENSION_SURVEY_PROMPT",i.LANGUAGE_SERVER_ENABLED="LANGUAGE_SERVER.ENABLED",i.LANGUAGE_SERVER_STARTUP="LANGUAGE_SERVER.STARTUP",i.LANGUAGE_SERVER_READY="LANGUAGE_SERVER.READY",i.LANGUAGE_SERVER_TELEMETRY="LANGUAGE_SERVER.EVENT",i.LANGUAGE_SERVER_REQUEST="LANGUAGE_SERVER.REQUEST",i.LANGUAGE_SERVER_RESTART="LANGUAGE_SERVER.RESTART",i.TERMINAL_CREATE="TERMINAL.CREATE",i.ACTIVATE_ENV_IN_CURRENT_TERMINAL="ACTIVATE_ENV_IN_CURRENT_TERMINAL",i.ACTIVATE_ENV_TO_GET_ENV_VARS_FAILED="ACTIVATE_ENV_TO_GET_ENV_VARS_FAILED",i.DIAGNOSTICS_ACTION="DIAGNOSTICS.ACTION",i.DIAGNOSTICS_MESSAGE="DIAGNOSTICS.MESSAGE",i.SELECT_LINTER="LINTING.SELECT",i.USE_REPORT_ISSUE_COMMAND="USE_REPORT_ISSUE_COMMAND",i.LINTER_NOT_INSTALLED_PROMPT="LINTER_NOT_INSTALLED_PROMPT",i.HASHED_PACKAGE_NAME="HASHED_PACKAGE_NAME",i.JEDI_LANGUAGE_SERVER_ENABLED="JEDI_LANGUAGE_SERVER.ENABLED",i.JEDI_LANGUAGE_SERVER_STARTUP="JEDI_LANGUAGE_SERVER.STARTUP",i.JEDI_LANGUAGE_SERVER_READY="JEDI_LANGUAGE_SERVER.READY",i.JEDI_LANGUAGE_SERVER_REQUEST="JEDI_LANGUAGE_SERVER.REQUEST",i.TENSORBOARD_SESSION_LAUNCH="TENSORBOARD.SESSION_LAUNCH",i.TENSORBOARD_SESSION_DURATION="TENSORBOARD.SESSION_DURATION",i.TENSORBOARD_SESSION_DAEMON_STARTUP_DURATION="TENSORBOARD.SESSION_DAEMON_STARTUP_DURATION",i.TENSORBOARD_LAUNCH_PROMPT_SELECTION="TENSORBOARD.LAUNCH_PROMPT_SELECTION",i.TENSORBOARD_SESSION_E2E_STARTUP_DURATION="TENSORBOARD.SESSION_E2E_STARTUP_DURATION",i.TENSORBOARD_ENTRYPOINT_SHOWN="TENSORBOARD.ENTRYPOINT_SHOWN",i.TENSORBOARD_INSTALL_PROMPT_SHOWN="TENSORBOARD.INSTALL_PROMPT_SHOWN",i.TENSORBOARD_INSTALL_PROMPT_SELECTION="TENSORBOARD.INSTALL_PROMPT_SELECTION",i.TENSORBOARD_DETECTED_IN_INTEGRATED_TERMINAL="TENSORBOARD_DETECTED_IN_INTEGRATED_TERMINAL",i.TENSORBOARD_PACKAGE_INSTALL_RESULT="TENSORBOARD.PACKAGE_INSTALL_RESULT",i.TENSORBOARD_TORCH_PROFILER_IMPORT="TENSORBOARD.TORCH_PROFILER_IMPORT",i.TENSORBOARD_JUMP_TO_SOURCE_REQUEST="TENSORBOARD_JUMP_TO_SOURCE_REQUEST",i.TENSORBOARD_JUMP_TO_SOURCE_FILE_NOT_FOUND="TENSORBOARD_JUMP_TO_SOURCE_FILE_NOT_FOUND",i.ENVIRONMENT_CREATING="ENVIRONMENT.CREATING",i.ENVIRONMENT_CREATED="ENVIRONMENT.CREATED",i.ENVIRONMENT_FAILED="ENVIRONMENT.FAILED",i.ENVIRONMENT_INSTALLING_PACKAGES="ENVIRONMENT.INSTALLING_PACKAGES",i.ENVIRONMENT_INSTALLED_PACKAGES="ENVIRONMENT.INSTALLED_PACKAGES",i.ENVIRONMENT_INSTALLING_PACKAGES_FAILED="ENVIRONMENT.INSTALLING_PACKAGES_FAILED",i.ENVIRONMENT_BUTTON="ENVIRONMENT.BUTTON",i.ENVIRONMENT_DELETE="ENVIRONMENT.DELETE",i.ENVIRONMENT_REUSE="ENVIRONMENT.REUSE",i.TOOLS_EXTENSIONS_ALREADY_INSTALLED="TOOLS_EXTENSIONS.ALREADY_INSTALLED",i.TOOLS_EXTENSIONS_PROMPT_SHOWN="TOOLS_EXTENSIONS.PROMPT_SHOWN",i.TOOLS_EXTENSIONS_INSTALL_SELECTED="TOOLS_EXTENSIONS.INSTALL_SELECTED",i.TOOLS_EXTENSIONS_PROMPT_DISMISSED="TOOLS_EXTENSIONS.PROMPT_DISMISSED",(n=t.PlatformErrors||(t.PlatformErrors={})).FailedToParseVersion="FailedToParseVersion",n.FailedToDetermineOS="FailedToDetermineOS"},1496:e=>{"function"==typeof Object.create?e.exports=function(e,t){e.super_=t,e.prototype=Object.create(t.prototype,{constructor:{value:e,enumerable:!1,writable:!0,configurable:!0}})}:e.exports=function(e,t){e.super_=t;var n=function(){};n.prototype=t.prototype,e.prototype=new n,e.prototype.constructor=e}},384:e=>{e.exports=function(e){return e&&"object"==typeof e&&"function"==typeof e.copy&&"function"==typeof e.fill&&"function"==typeof e.readUInt8}},9539:(e,t,n)=>{var i=n(4155),r=n(5108),o=Object.getOwnPropertyDescriptors||function(e){for(var t=Object.keys(e),n={},i=0;i=r)return e;switch(e){case"%s":return String(i[n++]);case"%d":return Number(i[n++]);case"%j":try{return JSON.stringify(i[n++])}catch(e){return"[Circular]"}default:return e}})),a=i[n];n=3&&(i.depth=arguments[2]),arguments.length>=4&&(i.colors=arguments[3]),m(n)?i.showHidden=n:n&&t._extend(i,n),C(i.showHidden)&&(i.showHidden=!1),C(i.depth)&&(i.depth=2),C(i.colors)&&(i.colors=!1),C(i.customInspect)&&(i.customInspect=!0),i.colors&&(i.stylize=l),f(i,e,i.depth)}function l(e,t){var n=u.styles[t];return n?"["+u.colors[n][0]+"m"+e+"["+u.colors[n][1]+"m":e}function d(e,t){return e}function f(e,n,i){if(e.customInspect&&n&&D(n.inspect)&&n.inspect!==t.inspect&&(!n.constructor||n.constructor.prototype!==n)){var r=n.inspect(i,e);return S(r)||(r=f(e,r,i)),r}var o=function(e,t){if(C(t))return e.stylize("undefined","undefined");if(S(t)){var n="'"+JSON.stringify(t).replace(/^"|"$/g,"").replace(/'/g,"\\'").replace(/\\"/g,'"')+"'";return e.stylize(n,"string")}return y(t)?e.stylize(""+t,"number"):m(t)?e.stylize(""+t,"boolean"):v(t)?e.stylize("null","null"):void 0}(e,n);if(o)return o;var s=Object.keys(n),a=function(e){var t={};return e.forEach((function(e,n){t[e]=!0})),t}(s);if(e.showHidden&&(s=Object.getOwnPropertyNames(n)),R(n)&&(s.indexOf("message")>=0||s.indexOf("description")>=0))return p(n);if(0===s.length){if(D(n)){var c=n.name?": "+n.name:"";return e.stylize("[Function"+c+"]","special")}if(T(n))return e.stylize(RegExp.prototype.toString.call(n),"regexp");if(_(n))return e.stylize(Date.prototype.toString.call(n),"date");if(R(n))return p(n)}var u,l="",d=!1,b=["{","}"];return h(n)&&(d=!0,b=["[","]"]),D(n)&&(l=" [Function"+(n.name?": "+n.name:"")+"]"),T(n)&&(l=" "+RegExp.prototype.toString.call(n)),_(n)&&(l=" "+Date.prototype.toUTCString.call(n)),R(n)&&(l=" "+p(n)),0!==s.length||d&&0!=n.length?i<0?T(n)?e.stylize(RegExp.prototype.toString.call(n),"regexp"):e.stylize("[Object]","special"):(e.seen.push(n),u=d?function(e,t,n,i,r){for(var o=[],s=0,a=t.length;s60?n[0]+(""===t?"":t+"\n ")+" "+e.join(",\n ")+" "+n[1]:n[0]+t+" "+e.join(", ")+" "+n[1]}(u,l,b)):b[0]+l+b[1]}function p(e){return"["+Error.prototype.toString.call(e)+"]"}function g(e,t,n,i,r,o){var s,a,c;if((c=Object.getOwnPropertyDescriptor(t,r)||{value:t[r]}).get?a=c.set?e.stylize("[Getter/Setter]","special"):e.stylize("[Getter]","special"):c.set&&(a=e.stylize("[Setter]","special")),x(i,r)||(s="["+r+"]"),a||(e.seen.indexOf(c.value)<0?(a=v(n)?f(e,c.value,null):f(e,c.value,n-1)).indexOf("\n")>-1&&(a=o?a.split("\n").map((function(e){return" "+e})).join("\n").substr(2):"\n"+a.split("\n").map((function(e){return" "+e})).join("\n")):a=e.stylize("[Circular]","special")),C(s)){if(o&&r.match(/^\d+$/))return a;(s=JSON.stringify(""+r)).match(/^"([a-zA-Z_][a-zA-Z_0-9]*)"$/)?(s=s.substr(1,s.length-2),s=e.stylize(s,"name")):(s=s.replace(/'/g,"\\'").replace(/\\"/g,'"').replace(/(^"|"$)/g,"'"),s=e.stylize(s,"string"))}return s+": "+a}function h(e){return Array.isArray(e)}function m(e){return"boolean"==typeof e}function v(e){return null===e}function y(e){return"number"==typeof e}function S(e){return"string"==typeof e}function C(e){return void 0===e}function T(e){return b(e)&&"[object RegExp]"===w(e)}function b(e){return"object"==typeof e&&null!==e}function _(e){return b(e)&&"[object Date]"===w(e)}function R(e){return b(e)&&("[object Error]"===w(e)||e instanceof Error)}function D(e){return"function"==typeof e}function w(e){return Object.prototype.toString.call(e)}function E(e){return e<10?"0"+e.toString(10):e.toString(10)}t.debuglog=function(e){if(C(a)&&(a=i.env.NODE_DEBUG||""),e=e.toUpperCase(),!c[e])if(new RegExp("\\b"+e+"\\b","i").test(a)){var n=i.pid;c[e]=function(){var i=t.format.apply(t,arguments);r.error("%s %d: %s",e,n,i)}}else c[e]=function(){};return c[e]},t.inspect=u,u.colors={bold:[1,22],italic:[3,23],underline:[4,24],inverse:[7,27],white:[37,39],grey:[90,39],black:[30,39],blue:[34,39],cyan:[36,39],green:[32,39],magenta:[35,39],red:[31,39],yellow:[33,39]},u.styles={special:"cyan",number:"yellow",boolean:"yellow",undefined:"grey",null:"bold",string:"green",date:"magenta",regexp:"red"},t.isArray=h,t.isBoolean=m,t.isNull=v,t.isNullOrUndefined=function(e){return null==e},t.isNumber=y,t.isString=S,t.isSymbol=function(e){return"symbol"==typeof e},t.isUndefined=C,t.isRegExp=T,t.isObject=b,t.isDate=_,t.isError=R,t.isFunction=D,t.isPrimitive=function(e){return null===e||"boolean"==typeof e||"number"==typeof e||"string"==typeof e||"symbol"==typeof e||void 0===e},t.isBuffer=n(384);var P=["Jan","Feb","Mar","Apr","May","Jun","Jul","Aug","Sep","Oct","Nov","Dec"];function k(){var e=new Date,t=[E(e.getHours()),E(e.getMinutes()),E(e.getSeconds())].join(":");return[e.getDate(),P[e.getMonth()],t].join(" ")}function x(e,t){return Object.prototype.hasOwnProperty.call(e,t)}t.log=function(){r.log("%s - %s",k(),t.format.apply(t,arguments))},t.inherits=n(1496),t._extend=function(e,t){if(!t||!b(t))return e;for(var n=Object.keys(t),i=n.length;i--;)e[n[i]]=t[n[i]];return e};var N="undefined"!=typeof Symbol?Symbol("util.promisify.custom"):void 0;function O(e,t){if(!e){var n=new Error("Promise was rejected with a falsy value");n.reason=e,e=n}return t(e)}t.promisify=function(e){if("function"!=typeof e)throw new TypeError('The "original" argument must be of type Function');if(N&&e[N]){var t;if("function"!=typeof(t=e[N]))throw new TypeError('The "util.promisify.custom" argument must be of type Function');return Object.defineProperty(t,N,{value:t,enumerable:!1,writable:!1,configurable:!0}),t}function t(){for(var t,n,i=new Promise((function(e,i){t=e,n=i})),r=[],o=0;o{"use strict";e.exports=n(5770)},5770:function(e,t,n){"use strict";var i=this&&this.__createBinding||(Object.create?function(e,t,n,i){void 0===i&&(i=n);var r=Object.getOwnPropertyDescriptor(t,n);r&&!("get"in r?!t.__esModule:r.writable||r.configurable)||(r={enumerable:!0,get:function(){return t[n]}}),Object.defineProperty(e,i,r)}:function(e,t,n,i){void 0===i&&(i=n),e[i]=t[n]}),r=this&&this.__exportStar||function(e,t){for(var n in e)"default"===n||Object.prototype.hasOwnProperty.call(t,n)||i(t,e,n)};Object.defineProperty(t,"__esModule",{value:!0}),t.LanguageClient=void 0;const o=n(5734),s=n(5224);r(n(5224),t),r(n(5734),t);class a extends o.BaseLanguageClient{constructor(e,t,n,i){super(e,t,n),this.worker=i}createMessageTransports(e){const t=new s.BrowserMessageReader(this.worker),n=new s.BrowserMessageWriter(this.worker);return Promise.resolve({reader:t,writer:n})}}t.LanguageClient=a},5734:function(e,t,n){"use strict";var i=this&&this.__createBinding||(Object.create?function(e,t,n,i){void 0===i&&(i=n);var r=Object.getOwnPropertyDescriptor(t,n);r&&!("get"in r?!t.__esModule:r.writable||r.configurable)||(r={enumerable:!0,get:function(){return t[n]}}),Object.defineProperty(e,i,r)}:function(e,t,n,i){void 0===i&&(i=n),e[i]=t[n]}),r=this&&this.__exportStar||function(e,t){for(var n in e)"default"===n||Object.prototype.hasOwnProperty.call(t,n)||i(t,e,n)};Object.defineProperty(t,"__esModule",{value:!0}),t.DiagnosticPullMode=t.vsdiag=void 0,r(n(152),t),r(n(8909),t);var o=n(2570);Object.defineProperty(t,"vsdiag",{enumerable:!0,get:function(){return o.vsdiag}}),Object.defineProperty(t,"DiagnosticPullMode",{enumerable:!0,get:function(){return o.DiagnosticPullMode}}),r(n(4384),t)},5578:(e,t,n)=>{"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.CallHierarchyFeature=void 0;const i=n(9496),r=n(152),o=n(8909);class s{constructor(e){this.client=e,this.middleware=e.middleware}prepareCallHierarchy(e,t,n){const i=this.client,o=this.middleware,s=(e,t,n)=>{const o=i.code2ProtocolConverter.asTextDocumentPositionParams(e,t);return i.sendRequest(r.CallHierarchyPrepareRequest.type,o,n).then((e=>n.isCancellationRequested?null:i.protocol2CodeConverter.asCallHierarchyItems(e,n)),(e=>i.handleFailedRequest(r.CallHierarchyPrepareRequest.type,n,e,null)))};return o.prepareCallHierarchy?o.prepareCallHierarchy(e,t,n,s):s(e,t,n)}provideCallHierarchyIncomingCalls(e,t){const n=this.client,i=this.middleware,o=(e,t)=>{const i={item:n.code2ProtocolConverter.asCallHierarchyItem(e)};return n.sendRequest(r.CallHierarchyIncomingCallsRequest.type,i,t).then((e=>t.isCancellationRequested?null:n.protocol2CodeConverter.asCallHierarchyIncomingCalls(e,t)),(e=>n.handleFailedRequest(r.CallHierarchyIncomingCallsRequest.type,t,e,null)))};return i.provideCallHierarchyIncomingCalls?i.provideCallHierarchyIncomingCalls(e,t,o):o(e,t)}provideCallHierarchyOutgoingCalls(e,t){const n=this.client,i=this.middleware,o=(e,t)=>{const i={item:n.code2ProtocolConverter.asCallHierarchyItem(e)};return n.sendRequest(r.CallHierarchyOutgoingCallsRequest.type,i,t).then((e=>t.isCancellationRequested?null:n.protocol2CodeConverter.asCallHierarchyOutgoingCalls(e,t)),(e=>n.handleFailedRequest(r.CallHierarchyOutgoingCallsRequest.type,t,e,null)))};return i.provideCallHierarchyOutgoingCalls?i.provideCallHierarchyOutgoingCalls(e,t,o):o(e,t)}}class a extends o.TextDocumentLanguageFeature{constructor(e){super(e,r.CallHierarchyPrepareRequest.type)}fillClientCapabilities(e){const t=e;(0,o.ensure)((0,o.ensure)(t,"textDocument"),"callHierarchy").dynamicRegistration=!0}initialize(e,t){const[n,i]=this.getRegistration(t,e.callHierarchyProvider);n&&i&&this.register({id:n,registerOptions:i})}registerLanguageProvider(e){const t=this._client,n=new s(t);return[i.languages.registerCallHierarchyProvider(this._client.protocol2CodeConverter.asDocumentSelector(e.documentSelector),n),n]}}t.CallHierarchyFeature=a},4384:(e,t,n)=>{"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.ProposedFeatures=t.BaseLanguageClient=t.MessageTransports=t.SuspendMode=t.State=t.CloseAction=t.ErrorAction=t.RevealOutputChannelOn=void 0;const i=n(9496),r=n(152),o=n(71),s=n(8785),a=n(9763),c=n(4904),u=n(1980),l=n(8071),d=n(8909),f=n(2570),p=n(203),g=n(6495),h=n(743),m=n(1435),v=n(6782),y=n(122),S=n(2908),C=n(9959),T=n(2483),b=n(3051),_=n(8480),R=n(9474),D=n(7711),w=n(6426),E=n(6458),P=n(3471),k=n(4849),x=n(5338),N=n(8880),O=n(9889),I=n(328),A=n(5941),F=n(6454),M=n(707),L=n(750),q=n(3603),j=n(5578),U=n(9957),H=n(7606),K=n(3483),W=n(4175),z=n(5098),V=n(6190);var B,$,G,J,Y,Z,X;!function(e){e[e.Info=1]="Info",e[e.Warn=2]="Warn",e[e.Error=3]="Error",e[e.Never=4]="Never"}(B=t.RevealOutputChannelOn||(t.RevealOutputChannelOn={})),function(e){e[e.Continue=1]="Continue",e[e.Shutdown=2]="Shutdown"}($=t.ErrorAction||(t.ErrorAction={})),function(e){e[e.DoNotRestart=1]="DoNotRestart",e[e.Restart=2]="Restart"}(G=t.CloseAction||(t.CloseAction={})),function(e){e[e.Stopped=1]="Stopped",e[e.Starting=3]="Starting",e[e.Running=2]="Running"}(J=t.State||(t.State={})),(X=t.SuspendMode||(t.SuspendMode={})).off="off",X.on="on";class Q{constructor(e,t){this.client=e,this.maxRestartCount=t,this.restarts=[]}error(e,t,n){return n&&n<=3?{action:$.Continue}:{action:$.Shutdown}}closed(){return this.restarts.push(Date.now()),this.restarts.length<=this.maxRestartCount?{action:G.Restart}:this.restarts[this.restarts.length-1]-this.restarts[0]<=18e4?{action:G.DoNotRestart,message:`The ${this.client.name} server crashed ${this.maxRestartCount+1} times in the last 3 minutes. The server will not be restarted. See the output for more information.`}:(this.restarts.shift(),{action:G.Restart})}}!function(e){e.Initial="initial",e.Starting="starting",e.StartFailed="startFailed",e.Running="running",e.Stopping="stopping",e.Stopped="stopped"}(Y||(Y={})),(t.MessageTransports||(t.MessageTransports={})).is=function(e){return e&&r.MessageReader.is(e.reader)&&r.MessageWriter.is(e.writer)};class ee{constructor(e,t,n){this._traceFormat=r.TraceFormat.Text,this._diagnosticQueue=new Map,this._diagnosticQueueState={state:"idle"},this._features=[],this._dynamicFeatures=new Map,this.workspaceEditLock=new c.Semaphore(1),this._id=e,this._name=t;const i={isTrusted:!1,supportHtml:!1};void 0!==(n=n||{}).markdown&&(i.isTrusted=!0===n.markdown.isTrusted,i.supportHtml=!0===n.markdown.supportHtml),this._clientOptions={documentSelector:n.documentSelector??[],synchronize:n.synchronize??{},diagnosticCollectionName:n.diagnosticCollectionName,outputChannelName:n.outputChannelName??this._name,revealOutputChannelOn:n.revealOutputChannelOn??B.Error,stdioEncoding:n.stdioEncoding??"utf8",initializationOptions:n.initializationOptions,initializationFailedHandler:n.initializationFailedHandler,progressOnInitialization:!!n.progressOnInitialization,errorHandler:n.errorHandler??this.createDefaultErrorHandler(n.connectionOptions?.maxRestartCount),middleware:n.middleware??{},uriConverters:n.uriConverters,workspaceFolder:n.workspaceFolder,connectionOptions:n.connectionOptions,markdown:i,diagnosticPullOptions:n.diagnosticPullOptions??{onChange:!0,onSave:!1},notebookDocumentOptions:n.notebookDocumentOptions??{}},this._clientOptions.synchronize=this._clientOptions.synchronize||{},this._state=Y.Initial,this._ignoredRegistrations=new Set,this._listeners=[],this._notificationHandlers=new Map,this._pendingNotificationHandlers=new Map,this._notificationDisposables=new Map,this._requestHandlers=new Map,this._pendingRequestHandlers=new Map,this._requestDisposables=new Map,this._progressHandlers=new Map,this._pendingProgressHandlers=new Map,this._progressDisposables=new Map,this._connection=void 0,this._initializeResult=void 0,n.outputChannel?(this._outputChannel=n.outputChannel,this._disposeOutputChannel=!1):(this._outputChannel=void 0,this._disposeOutputChannel=!0),this._traceOutputChannel=n.traceOutputChannel,this._diagnostics=void 0,this._pendingOpenNotifications=new Set,this._pendingChangeSemaphore=new c.Semaphore(1),this._pendingChangeDelayer=new c.Delayer(250),this._fileEvents=[],this._fileEventDelayer=new c.Delayer(250),this._onStop=void 0,this._telemetryEmitter=new r.Emitter,this._stateChangeEmitter=new r.Emitter,this._trace=r.Trace.Off,this._tracer={log:(e,t)=>{a.string(e)?this.logTrace(e,t):this.logObjectTrace(e)}},this._c2p=o.createConverter(n.uriConverters?n.uriConverters.code2Protocol:void 0),this._p2c=s.createConverter(n.uriConverters?n.uriConverters.protocol2Code:void 0,this._clientOptions.markdown.isTrusted,this._clientOptions.markdown.supportHtml),this._syncedDocuments=new Map,this.registerBuiltinFeatures()}get name(){return this._name}get middleware(){return this._clientOptions.middleware??Object.create(null)}get clientOptions(){return this._clientOptions}get protocol2CodeConverter(){return this._p2c}get code2ProtocolConverter(){return this._c2p}get onTelemetry(){return this._telemetryEmitter.event}get onDidChangeState(){return this._stateChangeEmitter.event}get outputChannel(){return this._outputChannel||(this._outputChannel=i.window.createOutputChannel(this._clientOptions.outputChannelName?this._clientOptions.outputChannelName:this._name)),this._outputChannel}get traceOutputChannel(){return this._traceOutputChannel?this._traceOutputChannel:this.outputChannel}get diagnostics(){return this._diagnostics}get state(){return this.getPublicState()}get $state(){return this._state}set $state(e){let t=this.getPublicState();this._state=e;let n=this.getPublicState();n!==t&&this._stateChangeEmitter.fire({oldState:t,newState:n})}getPublicState(){switch(this.$state){case Y.Starting:return J.Starting;case Y.Running:return J.Running;default:return J.Stopped}}get initializeResult(){return this._initializeResult}async sendRequest(e,...t){if(this.$state===Y.StartFailed||this.$state===Y.Stopping||this.$state===Y.Stopped)return Promise.reject(new r.ResponseError(r.ErrorCodes.ConnectionInactive,"Client is not running"));const n=await this.$start();return this._didChangeTextDocumentFeature.syncKind===r.TextDocumentSyncKind.Full&&await this.sendPendingFullTextDocumentChanges(n),n.sendRequest(e,...t)}onRequest(e,t){const n="string"==typeof e?e:e.method;this._requestHandlers.set(n,t);const i=this.activeConnection();let r;return void 0!==i?(this._requestDisposables.set(n,i.onRequest(e,t)),r={dispose:()=>{const e=this._requestDisposables.get(n);void 0!==e&&(e.dispose(),this._requestDisposables.delete(n))}}):(this._pendingRequestHandlers.set(n,t),r={dispose:()=>{this._pendingRequestHandlers.delete(n);const e=this._requestDisposables.get(n);void 0!==e&&(e.dispose(),this._requestDisposables.delete(n))}}),{dispose:()=>{this._requestHandlers.delete(n),r.dispose()}}}async sendNotification(e,t){if(this.$state===Y.StartFailed||this.$state===Y.Stopping||this.$state===Y.Stopped)return Promise.reject(new r.ResponseError(r.ErrorCodes.ConnectionInactive,"Client is not running"));const n=this._didChangeTextDocumentFeature.syncKind===r.TextDocumentSyncKind.Full;let i;n&&"string"!=typeof e&&e.method===r.DidOpenTextDocumentNotification.method&&(i=t?.textDocument.uri,this._pendingOpenNotifications.add(i));const o=await this.$start();return n&&await this.sendPendingFullTextDocumentChanges(o),void 0!==i&&this._pendingOpenNotifications.delete(i),o.sendNotification(e,t)}onNotification(e,t){const n="string"==typeof e?e:e.method;this._notificationHandlers.set(n,t);const i=this.activeConnection();let r;return void 0!==i?(this._notificationDisposables.set(n,i.onNotification(e,t)),r={dispose:()=>{const e=this._notificationDisposables.get(n);void 0!==e&&(e.dispose(),this._notificationDisposables.delete(n))}}):(this._pendingNotificationHandlers.set(n,t),r={dispose:()=>{this._pendingNotificationHandlers.delete(n);const e=this._notificationDisposables.get(n);void 0!==e&&(e.dispose(),this._notificationDisposables.delete(n))}}),{dispose:()=>{this._notificationHandlers.delete(n),r.dispose()}}}async sendProgress(e,t,n){if(this.$state===Y.StartFailed||this.$state===Y.Stopping||this.$state===Y.Stopped)return Promise.reject(new r.ResponseError(r.ErrorCodes.ConnectionInactive,"Client is not running"));try{return(await this.$start()).sendProgress(e,t,n)}catch(e){throw this.error(`Sending progress for token ${t} failed.`,e),e}}onProgress(e,t,n){this._progressHandlers.set(t,{type:e,handler:n});const i=this.activeConnection();let o;const s=this._clientOptions.middleware?.handleWorkDoneProgress,a=r.WorkDoneProgress.is(e)&&void 0!==s?e=>{s(t,e,(()=>n(e)))}:n;return void 0!==i?(this._progressDisposables.set(t,i.onProgress(e,t,a)),o={dispose:()=>{const e=this._progressDisposables.get(t);void 0!==e&&(e.dispose(),this._progressDisposables.delete(t))}}):(this._pendingProgressHandlers.set(t,{type:e,handler:n}),o={dispose:()=>{this._pendingProgressHandlers.delete(t);const e=this._progressDisposables.get(t);void 0!==e&&(e.dispose(),this._progressDisposables.delete(t))}}),{dispose:()=>{this._progressHandlers.delete(t),o.dispose()}}}createDefaultErrorHandler(e){if(void 0!==e&&e<0)throw new Error(`Invalid maxRestartCount: ${e}`);return new Q(this,e??4)}async setTrace(e){this._trace=e;const t=this.activeConnection();void 0!==t&&await t.trace(this._trace,this._tracer,{sendNotification:!1,traceFormat:this._traceFormat})}data2String(e){if(e instanceof r.ResponseError){const t=e;return` Message: ${t.message}\n Code: ${t.code} ${t.data?"\n"+t.data.toString():""}`}return e instanceof Error?a.string(e.stack)?e.stack:e.message:a.string(e)?e:e.toString()}info(e,t,n=!0){this.outputChannel.appendLine(`[Info - ${(new Date).toLocaleTimeString()}] ${e}`),null!=t&&this.outputChannel.appendLine(this.data2String(t)),n&&this._clientOptions.revealOutputChannelOn<=B.Info&&this.showNotificationMessage(r.MessageType.Info,e)}warn(e,t,n=!0){this.outputChannel.appendLine(`[Warn - ${(new Date).toLocaleTimeString()}] ${e}`),null!=t&&this.outputChannel.appendLine(this.data2String(t)),n&&this._clientOptions.revealOutputChannelOn<=B.Warn&&this.showNotificationMessage(r.MessageType.Warning,e)}error(e,t,n=!0){this.outputChannel.appendLine(`[Error - ${(new Date).toLocaleTimeString()}] ${e}`),null!=t&&this.outputChannel.appendLine(this.data2String(t)),("force"===n||n&&this._clientOptions.revealOutputChannelOn<=B.Error)&&this.showNotificationMessage(r.MessageType.Error,e)}showNotificationMessage(e,t){t=t??"A request has failed. See the output for more information.",(e===r.MessageType.Error?i.window.showErrorMessage:e===r.MessageType.Warning?i.window.showWarningMessage:i.window.showInformationMessage)(t,"Go to output").then((e=>{void 0!==e&&this.outputChannel.show(!0)}))}logTrace(e,t){this.traceOutputChannel.appendLine(`[Trace - ${(new Date).toLocaleTimeString()}] ${e}`),t&&this.traceOutputChannel.appendLine(this.data2String(t))}logObjectTrace(e){e.isLSPMessage&&e.type?this.traceOutputChannel.append(`[LSP - ${(new Date).toLocaleTimeString()}] `):this.traceOutputChannel.append(`[Trace - ${(new Date).toLocaleTimeString()}] `),e&&this.traceOutputChannel.appendLine(`${JSON.stringify(e)}`)}needsStart(){return this.$state===Y.Initial||this.$state===Y.Stopping||this.$state===Y.Stopped}needsStop(){return this.$state===Y.Starting||this.$state===Y.Running}activeConnection(){return this.$state===Y.Running&&void 0!==this._connection?this._connection:void 0}isRunning(){return this.$state===Y.Running}async start(){if("disposing"===this._disposed||"disposed"===this._disposed)throw new Error("Client got disposed and can't be restarted.");if(this.$state===Y.Stopping)throw new Error("Client is currently stopping. Can only restart a full stopped client");if(void 0!==this._onStart)return this._onStart;const[e,t,n]=this.createOnStartPromise();this._onStart=e,void 0===this._diagnostics&&(this._diagnostics=this._clientOptions.diagnosticCollectionName?i.languages.createDiagnosticCollection(this._clientOptions.diagnosticCollectionName):i.languages.createDiagnosticCollection());for(const[e,t]of this._notificationHandlers)this._pendingNotificationHandlers.has(e)||this._pendingNotificationHandlers.set(e,t);for(const[e,t]of this._requestHandlers)this._pendingRequestHandlers.has(e)||this._pendingRequestHandlers.set(e,t);for(const[e,t]of this._progressHandlers)this._pendingProgressHandlers.has(e)||this._pendingProgressHandlers.set(e,t);this.$state=Y.Starting;try{const e=await this.createConnection();e.onNotification(r.LogMessageNotification.type,(e=>{switch(e.type){case r.MessageType.Error:this.error(e.message,void 0,!1);break;case r.MessageType.Warning:this.warn(e.message,void 0,!1);break;case r.MessageType.Info:this.info(e.message,void 0,!1);break;default:this.outputChannel.appendLine(e.message)}})),e.onNotification(r.ShowMessageNotification.type,(e=>{switch(e.type){case r.MessageType.Error:i.window.showErrorMessage(e.message);break;case r.MessageType.Warning:i.window.showWarningMessage(e.message);break;case r.MessageType.Info:default:i.window.showInformationMessage(e.message)}})),e.onRequest(r.ShowMessageRequest.type,(e=>{let t;switch(e.type){case r.MessageType.Error:t=i.window.showErrorMessage;break;case r.MessageType.Warning:t=i.window.showWarningMessage;break;case r.MessageType.Info:default:t=i.window.showInformationMessage}let n=e.actions||[];return t(e.message,...n)})),e.onNotification(r.TelemetryEventNotification.type,(e=>{this._telemetryEmitter.fire(e)})),e.onRequest(r.ShowDocumentRequest.type,(async e=>{const t=async e=>{const t=this.protocol2CodeConverter.asUri(e.uri);try{if(!0===e.external)return{success:await i.env.openExternal(t)};{const n={};return void 0!==e.selection&&(n.selection=this.protocol2CodeConverter.asRange(e.selection)),void 0===e.takeFocus||!1===e.takeFocus?n.preserveFocus=!0:!0===e.takeFocus&&(n.preserveFocus=!1),await i.window.showTextDocument(t,n),{success:!0}}}catch(e){return{success:!1}}},n=this._clientOptions.middleware.window?.showDocument;return void 0!==n?n(e,t):t(e)})),e.listen(),await this.initialize(e),t()}catch(e){this.$state=Y.StartFailed,this.error(`${this._name} client: couldn't create connection to server.`,e,"force"),n(e)}return this._onStart}createOnStartPromise(){let e,t;return[new Promise(((n,i)=>{e=n,t=i})),e,t]}async initialize(e){this.refreshTrace(e,!1);const t=this._clientOptions.initializationOptions,[n,o]=void 0!==this._clientOptions.workspaceFolder?[this._clientOptions.workspaceFolder.uri.fsPath,[{uri:this._c2p.asUri(this._clientOptions.workspaceFolder.uri),name:this._clientOptions.workspaceFolder.name}]]:[this._clientGetRootPath(),null],s={processId:null,clientInfo:{name:i.env.appName,version:i.version},locale:this.getLocale(),rootPath:n||null,rootUri:n?this._c2p.asUri(i.Uri.file(n)):null,capabilities:this.computeClientCapabilities(),initializationOptions:a.func(t)?t():t,trace:r.Trace.toString(this._trace),workspaceFolders:o};if(this.fillInitializeParams(s),!this._clientOptions.progressOnInitialization)return this.doInitialize(e,s);{const t=u.generateUuid(),n=new l.ProgressPart(e,t);s.workDoneToken=t;try{const t=await this.doInitialize(e,s);return n.done(),t}catch(e){throw n.cancel(),e}}}async doInitialize(e,t){try{const n=await e.initialize(t);if(void 0!==n.capabilities.positionEncoding&&n.capabilities.positionEncoding!==r.PositionEncodingKind.UTF16)throw new Error(`Unsupported position encoding (${n.capabilities.positionEncoding}) received from server ${this.name}`);let i;this._initializeResult=n,this.$state=Y.Running,a.number(n.capabilities.textDocumentSync)?i=n.capabilities.textDocumentSync===r.TextDocumentSyncKind.None?{openClose:!1,change:r.TextDocumentSyncKind.None,save:void 0}:{openClose:!0,change:n.capabilities.textDocumentSync,save:{includeText:!1}}:void 0!==n.capabilities.textDocumentSync&&null!==n.capabilities.textDocumentSync&&(i=n.capabilities.textDocumentSync),this._capabilities=Object.assign({},n.capabilities,{resolvedTextDocumentSync:i}),e.onNotification(r.PublishDiagnosticsNotification.type,(e=>this.handleDiagnostics(e))),e.onRequest(r.RegistrationRequest.type,(e=>this.handleRegistrationRequest(e))),e.onRequest("client/registerFeature",(e=>this.handleRegistrationRequest(e))),e.onRequest(r.UnregistrationRequest.type,(e=>this.handleUnregistrationRequest(e))),e.onRequest("client/unregisterFeature",(e=>this.handleUnregistrationRequest(e))),e.onRequest(r.ApplyWorkspaceEditRequest.type,(e=>this.handleApplyWorkspaceEdit(e)));for(const[t,n]of this._pendingNotificationHandlers)this._notificationDisposables.set(t,e.onNotification(t,n));this._pendingNotificationHandlers.clear();for(const[t,n]of this._pendingRequestHandlers)this._requestDisposables.set(t,e.onRequest(t,n));this._pendingRequestHandlers.clear();for(const[t,n]of this._pendingProgressHandlers)this._progressDisposables.set(t,e.onProgress(n.type,t,n.handler));return this._pendingProgressHandlers.clear(),await e.sendNotification(r.InitializedNotification.type,{}),this.hookFileEvents(e),this.hookConfigurationChanged(e),this.initializeFeatures(e),n}catch(t){throw this._clientOptions.initializationFailedHandler?this._clientOptions.initializationFailedHandler(t)?this.initialize(e):this.stop():t instanceof r.ResponseError&&t.data&&t.data.retry?i.window.showErrorMessage(t.message,{title:"Retry",id:"retry"}).then((t=>{t&&"retry"===t.id?this.initialize(e):this.stop()})):(t&&t.message&&i.window.showErrorMessage(t.message),this.error("Server initialization failed.",t),this.stop()),t}}_clientGetRootPath(){let e=i.workspace.workspaceFolders;if(!e||0===e.length)return;let t=e[0];return"file"===t.uri.scheme?t.uri.fsPath:void 0}stop(e=2e3){return this.shutdown("stop",e)}dispose(e=2e3){try{return this._disposed="disposing",this.stop(e)}finally{this._disposed="disposed"}}async shutdown(e,t){if(this.$state===Y.Stopped||this.$state===Y.Initial)return;if(this.$state===Y.Stopping){if(void 0!==this._onStop)return this._onStop;throw new Error("Client is stopping but no stop promise available.")}const n=this.activeConnection();if(void 0===n||this.$state!==Y.Running)throw new Error(`Client is not running and can't be stopped. It's current state is: ${this.$state}`);this._initializeResult=void 0,this.$state=Y.Stopping,this.cleanUp(e);const i=new Promise((e=>{(0,r.RAL)().timer.setTimeout(e,t)})),o=(async e=>(await e.shutdown(),await e.exit(),e))(n);return this._onStop=Promise.race([i,o]).then((e=>{if(void 0===e)throw this.error("Stopping server timed out",void 0,!1),new Error("Stopping the server timed out");e.end(),e.dispose()}),(e=>{throw this.error("Stopping server failed",e,!1),e})).finally((()=>{this.$state=Y.Stopped,"stop"===e&&this.cleanUpChannel(),this._onStart=void 0,this._onStop=void 0,this._connection=void 0,this._ignoredRegistrations.clear()}))}cleanUp(e){this._fileEvents=[],this._fileEventDelayer.cancel();const t=this._listeners.splice(0,this._listeners.length);for(const e of t)e.dispose();this._syncedDocuments&&this._syncedDocuments.clear();for(const e of Array.from(this._features.entries()).map((e=>e[1])).reverse())e.dispose();"stop"===e&&void 0!==this._diagnostics&&(this._diagnostics.dispose(),this._diagnostics=void 0),void 0!==this._idleInterval&&(this._idleInterval.dispose(),this._idleInterval=void 0)}cleanUpChannel(){void 0!==this._outputChannel&&this._disposeOutputChannel&&(this._outputChannel.dispose(),this._outputChannel=void 0)}notifyFileEvent(e){const t=this;async function n(e){return t._fileEvents.push(e),t._fileEventDelayer.trigger((async()=>{await t.sendNotification(r.DidChangeWatchedFilesNotification.type,{changes:t._fileEvents}),t._fileEvents=[]}))}const i=this.clientOptions.middleware?.workspace;(i?.didChangeWatchedFile?i.didChangeWatchedFile(e,n):n(e)).catch((e=>{t.error("Notify file events failed.",e)}))}async sendPendingFullTextDocumentChanges(e){return this._pendingChangeSemaphore.lock((async()=>{try{const t=this._didChangeTextDocumentFeature.getPendingDocumentChanges(this._pendingOpenNotifications);if(0===t.length)return;for(const n of t){const t=this.code2ProtocolConverter.asChangeTextDocumentParams(n);await e.sendNotification(r.DidChangeTextDocumentNotification.type,t),this._didChangeTextDocumentFeature.notificationSent(n,r.DidChangeTextDocumentNotification.type,t)}}catch(e){throw this.error("Sending pending changes failed",e,!1),e}}))}triggerPendingChangeDelivery(){this._pendingChangeDelayer.trigger((async()=>{const e=this.activeConnection();void 0!==e?await this.sendPendingFullTextDocumentChanges(e):this.triggerPendingChangeDelivery()})).catch((e=>this.error("Delivering pending changes failed",e,!1)))}handleDiagnostics(e){if(!this._diagnostics)return;const t=e.uri;"busy"===this._diagnosticQueueState.state&&this._diagnosticQueueState.document===t&&this._diagnosticQueueState.tokenSource.cancel(),this._diagnosticQueue.set(e.uri,e.diagnostics),this.triggerDiagnosticQueue()}triggerDiagnosticQueue(){(0,r.RAL)().timer.setImmediate((()=>{this.workDiagnosticQueue()}))}workDiagnosticQueue(){if("busy"===this._diagnosticQueueState.state)return;const e=this._diagnosticQueue.entries().next();if(!0===e.done)return;const[t,n]=e.value;this._diagnosticQueue.delete(t);const r=new i.CancellationTokenSource;this._diagnosticQueueState={state:"busy",document:t,tokenSource:r},this._p2c.asDiagnostics(n,r.token).then((e=>{if(!r.token.isCancellationRequested){const n=this._p2c.asUri(t),i=this.clientOptions.middleware;i.handleDiagnostics?i.handleDiagnostics(n,e,((e,t)=>this.setDiagnostics(e,t))):this.setDiagnostics(n,e)}})).finally((()=>{this._diagnosticQueueState={state:"idle"},this.triggerDiagnosticQueue()}))}setDiagnostics(e,t){this._diagnostics&&this._diagnostics.set(e,t)}getLocale(){return i.env.language}async $start(){if(this.$state===Y.StartFailed)throw new Error("Previous start failed. Can't restart server.");await this.start();const e=this.activeConnection();if(void 0===e)throw new Error("Starting server failed");return e}async createConnection(){const e=await this.createMessageTransports(this._clientOptions.stdioEncoding||"utf8");return this._connection=function(e,t,n,i,o){const s=new te,c=(0,r.createProtocolConnection)(e,t,s,o);return c.onError((e=>{n(e[0],e[1],e[2])})),c.onClose(i),{listen:()=>c.listen(),sendRequest:c.sendRequest,onRequest:c.onRequest,hasPendingResponse:c.hasPendingResponse,sendNotification:c.sendNotification,onNotification:c.onNotification,onProgress:c.onProgress,sendProgress:c.sendProgress,trace:(e,t,n)=>{const i={sendNotification:!1,traceFormat:r.TraceFormat.Text};return void 0===n?c.trace(e,t,i):(a.boolean(n),c.trace(e,t,n))},initialize:e=>c.sendRequest(r.InitializeRequest.type,e),shutdown:()=>c.sendRequest(r.ShutdownRequest.type,void 0),exit:()=>c.sendNotification(r.ExitNotification.type),end:()=>c.end(),dispose:()=>c.dispose()}}(e.reader,e.writer,((e,t,n)=>{this.handleConnectionError(e,t,n).catch((e=>this.error("Handling connection error failed",e)))}),(()=>{this.handleConnectionClosed().catch((e=>this.error("Handling connection close failed",e)))}),this._clientOptions.connectionOptions),this._connection}async handleConnectionClosed(){if(this.$state===Y.Stopped)return;try{void 0!==this._connection&&this._connection.dispose()}catch(e){}let e={action:G.DoNotRestart};if(this.$state!==Y.Stopping)try{e=await this._clientOptions.errorHandler.closed()}catch(e){}this._connection=void 0,e.action===G.DoNotRestart?(this.error(e.message??"Connection to server got closed. Server will not be restarted.",void 0,!0!==e.handled&&"force"),this.cleanUp("stop"),this.$state===Y.Starting?this.$state=Y.StartFailed:this.$state=Y.Stopped,this._onStop=Promise.resolve(),this._onStart=void 0):e.action===G.Restart&&(this.info(e.message??"Connection to server got closed. Server will restart.",!e.handled),this.cleanUp("restart"),this.$state=Y.Initial,this._onStop=Promise.resolve(),this._onStart=void 0,this.start().catch((e=>this.error("Restarting server failed",e,"force"))))}async handleConnectionError(e,t,n){const i=await this._clientOptions.errorHandler.error(e,t,n);i.action===$.Shutdown&&(this.error(i.message??`Client ${this._name}: connection to server is erroring. Shutting down server.`,void 0,!0!==i.handled&&"force"),this.stop().catch((e=>{this.error("Stopping server failed",e,!1)})))}hookConfigurationChanged(e){this._listeners.push(i.workspace.onDidChangeConfiguration((()=>{this.refreshTrace(e,!0)})))}refreshTrace(e,t=!1){const n=i.workspace.getConfiguration(this._id);let o=r.Trace.Off,s=r.TraceFormat.Text;if(n){const e=n.get("trace.server","off");"string"==typeof e?o=r.Trace.fromString(e):(o=r.Trace.fromString(n.get("trace.server.verbosity","off")),s=r.TraceFormat.fromString(n.get("trace.server.format","text")))}this._trace=o,this._traceFormat=s,e.trace(this._trace,this._tracer,{sendNotification:t,traceFormat:this._traceFormat}).catch((e=>{this.error("Updating trace failed with error",e,!1)}))}hookFileEvents(e){let t,n=this._clientOptions.synchronize.fileEvents;n&&(t=a.array(n)?n:[n],t&&this._dynamicFeatures.get(r.DidChangeWatchedFilesNotification.type.method).registerRaw(u.generateUuid(),t))}registerFeatures(e){for(let t of e)this.registerFeature(t)}registerFeature(e){if(this._features.push(e),d.DynamicFeature.is(e)){const t=e.registrationType;this._dynamicFeatures.set(t.method,e)}}getFeature(e){return this._dynamicFeatures.get(e)}hasDedicatedTextSynchronizationFeature(e){const t=this.getFeature(r.NotebookDocumentSyncRegistrationType.method);return void 0!==t&&t instanceof p.NotebookDocumentSyncFeature&&t.handles(e)}registerBuiltinFeatures(){const e=new Map;this.registerFeature(new g.ConfigurationFeature(this)),this.registerFeature(new h.DidOpenTextDocumentFeature(this,this._syncedDocuments)),this._didChangeTextDocumentFeature=new h.DidChangeTextDocumentFeature(this,e),this._didChangeTextDocumentFeature.onPendingChangeAdded((()=>{this.triggerPendingChangeDelivery()})),this.registerFeature(this._didChangeTextDocumentFeature),this.registerFeature(new h.WillSaveFeature(this)),this.registerFeature(new h.WillSaveWaitUntilFeature(this)),this.registerFeature(new h.DidSaveTextDocumentFeature(this)),this.registerFeature(new h.DidCloseTextDocumentFeature(this,this._syncedDocuments,e)),this.registerFeature(new x.FileSystemWatcherFeature(this,(e=>this.notifyFileEvent(e)))),this.registerFeature(new m.CompletionItemFeature(this)),this.registerFeature(new v.HoverFeature(this)),this.registerFeature(new S.SignatureHelpFeature(this)),this.registerFeature(new y.DefinitionFeature(this)),this.registerFeature(new _.ReferencesFeature(this)),this.registerFeature(new C.DocumentHighlightFeature(this)),this.registerFeature(new T.DocumentSymbolFeature(this)),this.registerFeature(new b.WorkspaceSymbolFeature(this)),this.registerFeature(new R.CodeActionFeature(this)),this.registerFeature(new D.CodeLensFeature(this)),this.registerFeature(new w.DocumentFormattingFeature(this)),this.registerFeature(new w.DocumentRangeFormattingFeature(this)),this.registerFeature(new w.DocumentOnTypeFormattingFeature(this)),this.registerFeature(new E.RenameFeature(this)),this.registerFeature(new P.DocumentLinkFeature(this)),this.registerFeature(new k.ExecuteCommandFeature(this)),this.registerFeature(new g.SyncConfigurationFeature(this)),this.registerFeature(new I.TypeDefinitionFeature(this)),this.registerFeature(new O.ImplementationFeature(this)),this.registerFeature(new N.ColorProviderFeature(this)),void 0===this.clientOptions.workspaceFolder&&this.registerFeature(new A.WorkspaceFoldersFeature(this)),this.registerFeature(new F.FoldingRangeFeature(this)),this.registerFeature(new M.DeclarationFeature(this)),this.registerFeature(new L.SelectionRangeFeature(this)),this.registerFeature(new q.ProgressFeature(this)),this.registerFeature(new j.CallHierarchyFeature(this)),this.registerFeature(new U.SemanticTokensFeature(this)),this.registerFeature(new K.LinkedEditingFeature(this)),this.registerFeature(new H.DidCreateFilesFeature(this)),this.registerFeature(new H.DidRenameFilesFeature(this)),this.registerFeature(new H.DidDeleteFilesFeature(this)),this.registerFeature(new H.WillCreateFilesFeature(this)),this.registerFeature(new H.WillRenameFilesFeature(this)),this.registerFeature(new H.WillDeleteFilesFeature(this)),this.registerFeature(new W.TypeHierarchyFeature(this)),this.registerFeature(new z.InlineValueFeature(this)),this.registerFeature(new V.InlayHintsFeature(this)),this.registerFeature(new f.DiagnosticFeature(this)),this.registerFeature(new p.NotebookDocumentSyncFeature(this))}registerProposedFeatures(){this.registerFeatures(Z.createAll(this))}fillInitializeParams(e){for(let t of this._features)a.func(t.fillInitializeParams)&&t.fillInitializeParams(e)}computeClientCapabilities(){const e={};(0,d.ensure)(e,"workspace").applyEdit=!0;const t=(0,d.ensure)((0,d.ensure)(e,"workspace"),"workspaceEdit");t.documentChanges=!0,t.resourceOperations=[r.ResourceOperationKind.Create,r.ResourceOperationKind.Rename,r.ResourceOperationKind.Delete],t.failureHandling=r.FailureHandlingKind.TextOnlyTransactional,t.normalizesLineEndings=!0,t.changeAnnotationSupport={groupsOnLabel:!0};const n=(0,d.ensure)((0,d.ensure)(e,"textDocument"),"publishDiagnostics");n.relatedInformation=!0,n.versionSupport=!1,n.tagSupport={valueSet:[r.DiagnosticTag.Unnecessary,r.DiagnosticTag.Deprecated]},n.codeDescriptionSupport=!0,n.dataSupport=!0;const i=(0,d.ensure)(e,"window");(0,d.ensure)(i,"showMessage").messageActionItem={additionalPropertiesSupport:!0},(0,d.ensure)(i,"showDocument").support=!0;const o=(0,d.ensure)(e,"general");o.staleRequestSupport={cancel:!0,retryOnContentModified:Array.from(ee.RequestsToCancelOnContentModified)},o.regularExpressions={engine:"ECMAScript",version:"ES2020"},o.markdown={parser:"marked",version:"1.1.0"},o.positionEncodings=["utf-16"],this._clientOptions.markdown.supportHtml&&(o.markdown.allowedTags=["ul","li","p","code","blockquote","ol","h1","h2","h3","h4","h5","h6","hr","em","pre","table","thead","tbody","tr","th","td","div","del","a","strong","br","img","span"]);for(let t of this._features)t.fillClientCapabilities(e);return e}initializeFeatures(e){const t=this._clientOptions.documentSelector;for(const e of this._features)a.func(e.preInitialize)&&e.preInitialize(this._capabilities,t);for(const e of this._features)e.initialize(this._capabilities,t)}async handleRegistrationRequest(e){if(this.isRunning())for(const t of e.registrations){const e=this._dynamicFeatures.get(t.method);if(void 0===e)return Promise.reject(new Error(`No feature implementation for ${t.method} found. Registration failed.`));const n=t.registerOptions??{};n.documentSelector=n.documentSelector??this._clientOptions.documentSelector;const i={id:t.id,registerOptions:n};try{e.register(i)}catch(e){return Promise.reject(e)}}else for(const t of e.registrations)this._ignoredRegistrations.add(t.id)}async handleUnregistrationRequest(e){for(let t of e.unregisterations){if(this._ignoredRegistrations.has(t.id))continue;const e=this._dynamicFeatures.get(t.method);if(!e)return Promise.reject(new Error(`No feature implementation for ${t.method} found. Unregistration failed.`));e.unregister(t.id)}}async handleApplyWorkspaceEdit(e){const t=e.edit,n=await this.workspaceEditLock.lock((()=>this._p2c.asWorkspaceEdit(t))),o=new Map;i.workspace.textDocuments.forEach((e=>o.set(e.uri.toString(),e)));let s=!1;if(t.documentChanges)for(const e of t.documentChanges)if(r.TextDocumentEdit.is(e)&&e.textDocument.version&&e.textDocument.version>=0){const t=this._p2c.asUri(e.textDocument.uri).toString(),n=o.get(t);if(n&&n.version!==e.textDocument.version){s=!0;break}}return s?Promise.resolve({applied:!1}):a.asPromise(i.workspace.applyEdit(n).then((e=>({applied:e}))))}handleFailedRequest(e,t,n,o,s=!0){if(n instanceof r.ResponseError){if(n.code===r.ErrorCodes.PendingResponseRejected||n.code===r.ErrorCodes.ConnectionInactive)return o;if(n.code===r.LSPErrorCodes.RequestCancelled||n.code===r.LSPErrorCodes.ServerCancelled){if(void 0!==t&&t.isCancellationRequested)return o;throw void 0!==n.data?new d.LSPCancellationError(n.data):new i.CancellationError}if(n.code===r.LSPErrorCodes.ContentModified){if(ee.RequestsToCancelOnContentModified.has(e.method)||ee.CancellableResolveCalls.has(e.method))throw new i.CancellationError;return o}}throw this.error(`Request ${e.method} failed.`,n,s),n}}t.BaseLanguageClient=ee,ee.RequestsToCancelOnContentModified=new Set([r.SemanticTokensRequest.method,r.SemanticTokensRangeRequest.method,r.SemanticTokensDeltaRequest.method]),ee.CancellableResolveCalls=new Set([r.CompletionResolveRequest.method,r.CodeLensResolveRequest.method,r.CodeActionResolveRequest.method,r.InlayHintResolveRequest.method,r.DocumentLinkResolveRequest.method,r.WorkspaceSymbolResolveRequest.method]);class te{error(e){(0,r.RAL)().console.error(e)}warn(e){(0,r.RAL)().console.warn(e)}info(e){(0,r.RAL)().console.info(e)}log(e){(0,r.RAL)().console.log(e)}}!function(e){e.createAll=function(e){return[]}}(Z=t.ProposedFeatures||(t.ProposedFeatures={}))},9474:(e,t,n)=>{"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.CodeActionFeature=void 0;const i=n(9496),r=n(152),o=n(1980),s=n(8909);class a extends s.TextDocumentLanguageFeature{constructor(e){super(e,r.CodeActionRequest.type)}fillClientCapabilities(e){const t=(0,s.ensure)((0,s.ensure)(e,"textDocument"),"codeAction");t.dynamicRegistration=!0,t.isPreferredSupport=!0,t.disabledSupport=!0,t.dataSupport=!0,t.resolveSupport={properties:["edit"]},t.codeActionLiteralSupport={codeActionKind:{valueSet:[r.CodeActionKind.Empty,r.CodeActionKind.QuickFix,r.CodeActionKind.Refactor,r.CodeActionKind.RefactorExtract,r.CodeActionKind.RefactorInline,r.CodeActionKind.RefactorRewrite,r.CodeActionKind.Source,r.CodeActionKind.SourceOrganizeImports]}},t.honorsChangeAnnotations=!1}initialize(e,t){const n=this.getRegistrationOptions(t,e.codeActionProvider);n&&this.register({id:o.generateUuid(),registerOptions:n})}registerLanguageProvider(e){const t=e.documentSelector,n={provideCodeActions:(e,t,n,i)=>{const o=this._client,s=async(e,t,n,i)=>{const s={textDocument:o.code2ProtocolConverter.asTextDocumentIdentifier(e),range:o.code2ProtocolConverter.asRange(t),context:await o.code2ProtocolConverter.asCodeActionContext(n,i)};return o.sendRequest(r.CodeActionRequest.type,s,i).then((e=>i.isCancellationRequested||null==e?null:o.protocol2CodeConverter.asCodeActionResult(e,i)),(e=>o.handleFailedRequest(r.CodeActionRequest.type,i,e,null)))},a=o.middleware;return a.provideCodeActions?a.provideCodeActions(e,t,n,i,s):s(e,t,n,i)},resolveCodeAction:e.resolveProvider?(e,t)=>{const n=this._client,i=this._client.middleware,o=async(e,t)=>n.sendRequest(r.CodeActionResolveRequest.type,await n.code2ProtocolConverter.asCodeAction(e,t),t).then((i=>t.isCancellationRequested?e:n.protocol2CodeConverter.asCodeAction(i,t)),(i=>n.handleFailedRequest(r.CodeActionResolveRequest.type,t,i,e)));return i.resolveCodeAction?i.resolveCodeAction(e,t,o):o(e,t)}:void 0};return[i.languages.registerCodeActionsProvider(this._client.protocol2CodeConverter.asDocumentSelector(t),n,e.codeActionKinds?{providedCodeActionKinds:this._client.protocol2CodeConverter.asCodeActionKinds(e.codeActionKinds)}:void 0),n]}}t.CodeActionFeature=a},71:(e,t,n)=>{"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.createConverter=void 0;const i=n(9496),r=n(152),o=n(9763),s=n(4904),a=n(1807),c=n(583),u=n(8705),l=n(6434),d=n(5316),f=n(8714),p=n(1365),g=n(3912),h=n(1065);var m;!function(e){e.is=function(e){const t=e;return t&&!!t.inserting&&!!t.replacing}}(m||(m={})),t.createConverter=function(e){const t=e||(e=>e.toString());function n(e){return t(e)}function v(e){return{uri:t(e.uri)}}function y(e){return{uri:t(e.uri),languageId:e.languageId,version:e.version,text:e.getText()}}function S(e){switch(e){case i.TextDocumentSaveReason.Manual:return r.TextDocumentSaveReason.Manual;case i.TextDocumentSaveReason.AfterDelay:return r.TextDocumentSaveReason.AfterDelay;case i.TextDocumentSaveReason.FocusOut:return r.TextDocumentSaveReason.FocusOut}return r.TextDocumentSaveReason.Manual}function C(e){switch(e){case i.CompletionTriggerKind.TriggerCharacter:return r.CompletionTriggerKind.TriggerCharacter;case i.CompletionTriggerKind.TriggerForIncompleteCompletions:return r.CompletionTriggerKind.TriggerForIncompleteCompletions;default:return r.CompletionTriggerKind.Invoked}}function T(e){switch(e){case i.SignatureHelpTriggerKind.Invoke:return r.SignatureHelpTriggerKind.Invoked;case i.SignatureHelpTriggerKind.TriggerCharacter:return r.SignatureHelpTriggerKind.TriggerCharacter;case i.SignatureHelpTriggerKind.ContentChange:return r.SignatureHelpTriggerKind.ContentChange}}function b(e){return{label:e.label}}function _(e){return{label:e.label,parameters:(t=e.parameters,t.map(b))};var t}function R(e){return{line:e.line,character:e.character}}function D(e){return null==e?e:{line:e.line>r.uinteger.MAX_VALUE?r.uinteger.MAX_VALUE:e.line,character:e.character>r.uinteger.MAX_VALUE?r.uinteger.MAX_VALUE:e.character}}function w(e){return null==e?e:{start:D(e.start),end:D(e.end)}}function E(e){return null==e?e:r.Location.create(n(e.uri),w(e.range))}function P(e){switch(e){case i.DiagnosticSeverity.Error:return r.DiagnosticSeverity.Error;case i.DiagnosticSeverity.Warning:return r.DiagnosticSeverity.Warning;case i.DiagnosticSeverity.Information:return r.DiagnosticSeverity.Information;case i.DiagnosticSeverity.Hint:return r.DiagnosticSeverity.Hint}}function k(e){switch(e){case i.DiagnosticTag.Unnecessary:return r.DiagnosticTag.Unnecessary;case i.DiagnosticTag.Deprecated:return r.DiagnosticTag.Deprecated;default:return}}function x(e){return{message:e.message,location:E(e.location)}}function N(e){const t=r.Diagnostic.create(w(e.range),e.message),i=e instanceof d.ProtocolDiagnostic?e:void 0;void 0!==i&&void 0!==i.data&&(t.data=i.data);const s=function(e){if(null!=e)return o.number(e)||o.string(e)?e:{value:e.value,target:n(e.target)}}(e.code);return d.DiagnosticCode.is(s)?void 0!==i&&i.hasDiagnosticCode?t.code=s:(t.code=s.value,t.codeDescription={href:s.target}):t.code=s,o.number(e.severity)&&(t.severity=P(e.severity)),Array.isArray(e.tags)&&(t.tags=function(e){if(!e)return;let t=[];for(let n of e){let e=k(n);void 0!==e&&t.push(e)}return t.length>0?t:void 0}(e.tags)),e.relatedInformation&&(t.relatedInformation=e.relatedInformation.map(x)),e.source&&(t.source=e.source),t}function O(e,t){return null==e?e:s.map(e,N,t)}function I(e){if(e===i.CompletionItemTag.Deprecated)return r.CompletionItemTag.Deprecated}function A(e){return{range:w(e.range),newText:e.newText}}function F(e){return null==e?e:e.map(A)}function M(e){return e<=i.SymbolKind.TypeParameter?e+1:r.SymbolKind.Property}function L(e){return e}function q(e){return e.map(L)}function j(e){let t=r.Command.create(e.title,e.command);return e.arguments&&(t.arguments=e.arguments),t}function U(e){const t=r.InlayHintLabelPart.create(e.value);return void 0!==e.location&&(t.location=E(e.location)),void 0!==e.command&&(t.command=j(e.command)),void 0!==e.tooltip&&(t.tooltip=H(e.tooltip)),t}function H(e){return"string"==typeof e?e:{kind:r.MarkupKind.Markdown,value:e.value}}return{asUri:n,asTextDocumentIdentifier:v,asTextDocumentItem:y,asVersionedTextDocumentIdentifier:function(e){return{uri:t(e.uri),version:e.version}},asOpenTextDocumentParams:function(e){return{textDocument:y(e)}},asChangeTextDocumentParams:function(e,n,i){if(function(e){const t=e;return!!t.uri&&!!t.version}(e))return{textDocument:{uri:t(e.uri),version:e.version},contentChanges:[{text:e.getText()}]};if(function(e){const t=e;return!!t.document&&!!t.contentChanges}(e)){const r=i;return{textDocument:{uri:t(n),version:r},contentChanges:e.contentChanges.map((e=>{const t=e.range;return{range:{start:{line:t.start.line,character:t.start.character},end:{line:t.end.line,character:t.end.character}},rangeLength:e.rangeLength,text:e.text}}))}}throw Error("Unsupported text document change parameter")},asCloseTextDocumentParams:function(e){return{textDocument:v(e)}},asSaveTextDocumentParams:function(e,t=!1){let n={textDocument:v(e)};return t&&(n.text=e.getText()),n},asWillSaveTextDocumentParams:function(e){return{textDocument:v(e.document),reason:S(e.reason)}},asDidCreateFilesParams:function(e){return{files:e.files.map((e=>({uri:t(e)})))}},asDidRenameFilesParams:function(e){return{files:e.files.map((e=>({oldUri:t(e.oldUri),newUri:t(e.newUri)})))}},asDidDeleteFilesParams:function(e){return{files:e.files.map((e=>({uri:t(e)})))}},asWillCreateFilesParams:function(e){return{files:e.files.map((e=>({uri:t(e)})))}},asWillRenameFilesParams:function(e){return{files:e.files.map((e=>({oldUri:t(e.oldUri),newUri:t(e.newUri)})))}},asWillDeleteFilesParams:function(e){return{files:e.files.map((e=>({uri:t(e)})))}},asTextDocumentPositionParams:function(e,t){return{textDocument:v(e),position:R(t)}},asCompletionParams:function(e,t,n){return{textDocument:v(e),position:R(t),context:{triggerKind:C(n.triggerKind),triggerCharacter:n.triggerCharacter}}},asSignatureHelpParams:function(e,t,n){return{textDocument:v(e),position:R(t),context:{isRetrigger:n.isRetrigger,triggerCharacter:n.triggerCharacter,triggerKind:T(n.triggerKind),activeSignatureHelp:(i=n.activeSignatureHelp,void 0===i?i:{signatures:(r=i.signatures,r.map(_)),activeSignature:i.activeSignature,activeParameter:i.activeParameter})}};var i,r},asWorkerPosition:R,asRange:w,asPosition:D,asPositions:function(e,t){return s.map(e,D,t)},asLocation:E,asDiagnosticSeverity:P,asDiagnosticTag:k,asDiagnostic:N,asDiagnostics:O,asCompletionItem:function(e,t=!1){let n,s;o.string(e.label)?n=e.label:(n=e.label.label,!t||void 0===e.label.detail&&void 0===e.label.description||(s={detail:e.label.detail,description:e.label.description}));let c={label:n};void 0!==s&&(c.labelDetails=s);let u=e instanceof a.default?e:void 0;var l,d;e.detail&&(c.detail=e.detail),e.documentation&&(u&&"$string"!==u.documentationFormat?c.documentation=function(e,t){switch(e){case"$string":return t;case r.MarkupKind.PlainText:return{kind:e,value:t};case r.MarkupKind.Markdown:return{kind:e,value:t.value};default:return`Unsupported Markup content received. Kind is: ${e}`}}(u.documentationFormat,e.documentation):c.documentation=e.documentation),e.filterText&&(c.filterText=e.filterText),function(e,t){let n,o,s=r.InsertTextFormat.PlainText;t.textEdit?(n=t.textEdit.newText,o=t.textEdit.range):t.insertText instanceof i.SnippetString?(s=r.InsertTextFormat.Snippet,n=t.insertText.value):n=t.insertText,t.range&&(o=t.range),e.insertTextFormat=s,t.fromEdit&&void 0!==n&&void 0!==o?e.textEdit=function(e,t){return m.is(t)?r.InsertReplaceEdit.create(e,w(t.inserting),w(t.replacing)):{newText:e,range:w(t)}}(n,o):e.insertText=n}(c,e),o.number(e.kind)&&(c.kind=(l=e.kind,void 0!==(d=u&&u.originalItemKind)?d:l+1)),e.sortText&&(c.sortText=e.sortText),e.additionalTextEdits&&(c.additionalTextEdits=F(e.additionalTextEdits)),e.commitCharacters&&(c.commitCharacters=e.commitCharacters.slice()),e.command&&(c.command=j(e.command)),!0!==e.preselect&&!1!==e.preselect||(c.preselect=e.preselect);const f=function(e){if(void 0===e)return e;const t=[];for(let n of e){const e=I(n);void 0!==e&&t.push(e)}return t}(e.tags);if(u){if(void 0!==u.data&&(c.data=u.data),!0===u.deprecated||!1===u.deprecated){if(!0===u.deprecated&&void 0!==f&&f.length>0){const e=f.indexOf(i.CompletionItemTag.Deprecated);-1!==e&&f.splice(e,1)}c.deprecated=u.deprecated}void 0!==u.insertTextMode&&(c.insertTextMode=u.insertTextMode)}return void 0!==f&&f.length>0&&(c.tags=f),void 0===c.insertTextMode&&!0===e.keepWhitespace&&(c.insertTextMode=r.InsertTextMode.adjustIndentation),c},asTextEdit:A,asSymbolKind:M,asSymbolTag:L,asSymbolTags:q,asReferenceParams:function(e,t,n){return{textDocument:v(e),position:R(t),context:{includeDeclaration:n.includeDeclaration}}},asCodeAction:async function(e,t){let n=r.CodeAction.create(e.title);if(e instanceof l.default&&void 0!==e.data&&(n.data=e.data),void 0!==e.kind&&(n.kind=function(e){if(null!=e)return e.value}(e.kind)),void 0!==e.diagnostics&&(n.diagnostics=await O(e.diagnostics,t)),void 0!==e.edit)throw new Error("VS Code code actions can only be converted to a protocol code action without an edit.");return void 0!==e.command&&(n.command=j(e.command)),void 0!==e.isPreferred&&(n.isPreferred=e.isPreferred),void 0!==e.disabled&&(n.disabled={reason:e.disabled.reason}),n},asCodeActionContext:async function(e,t){if(null==e)return e;let n;return e.only&&o.string(e.only.value)&&(n=[e.only.value]),r.CodeActionContext.create(await O(e.diagnostics,t),n,function(e){switch(e){case i.CodeActionTriggerKind.Invoke:return r.CodeActionTriggerKind.Invoked;case i.CodeActionTriggerKind.Automatic:return r.CodeActionTriggerKind.Automatic;default:return}}(e.triggerKind))},asInlineValueContext:function(e){return null==e?e:r.InlineValueContext.create(e.frameId,w(e.stoppedLocation))},asCommand:j,asCodeLens:function(e){let t=r.CodeLens.create(w(e.range));return e.command&&(t.command=j(e.command)),e instanceof c.default&&e.data&&(t.data=e.data),t},asFormattingOptions:function(e,t){const n={tabSize:e.tabSize,insertSpaces:e.insertSpaces};return t.trimTrailingWhitespace&&(n.trimTrailingWhitespace=!0),t.trimFinalNewlines&&(n.trimFinalNewlines=!0),t.insertFinalNewline&&(n.insertFinalNewline=!0),n},asDocumentSymbolParams:function(e){return{textDocument:v(e)}},asCodeLensParams:function(e){return{textDocument:v(e)}},asDocumentLink:function(e){let t=r.DocumentLink.create(w(e.range));e.target&&(t.target=n(e.target)),void 0!==e.tooltip&&(t.tooltip=e.tooltip);let i=e instanceof u.default?e:void 0;return i&&i.data&&(t.data=i.data),t},asDocumentLinkParams:function(e){return{textDocument:v(e)}},asCallHierarchyItem:function(e){const t={name:e.name,kind:M(e.kind),uri:n(e.uri),range:w(e.range),selectionRange:w(e.selectionRange)};return void 0!==e.detail&&e.detail.length>0&&(t.detail=e.detail),void 0!==e.tags&&(t.tags=q(e.tags)),e instanceof f.default&&void 0!==e.data&&(t.data=e.data),t},asTypeHierarchyItem:function(e){const t={name:e.name,kind:M(e.kind),uri:n(e.uri),range:w(e.range),selectionRange:w(e.selectionRange)};return void 0!==e.detail&&e.detail.length>0&&(t.detail=e.detail),void 0!==e.tags&&(t.tags=q(e.tags)),e instanceof p.default&&void 0!==e.data&&(t.data=e.data),t},asInlayHint:function(e){const t="string"==typeof e.label?e.label:e.label.map(U),n=r.InlayHint.create(D(e.position),t);return void 0!==e.kind&&(n.kind=e.kind),void 0!==e.textEdits&&(n.textEdits=F(e.textEdits)),void 0!==e.tooltip&&(n.tooltip=H(e.tooltip)),void 0!==e.paddingLeft&&(n.paddingLeft=e.paddingLeft),void 0!==e.paddingRight&&(n.paddingRight=e.paddingRight),e instanceof h.default&&void 0!==e.data&&(n.data=e.data),n},asWorkspaceSymbol:function(e){const n=e instanceof g.default?{name:e.name,kind:M(e.kind),location:e.hasRange?E(e.location):{uri:t(e.location.uri)},data:e.data}:{name:e.name,kind:M(e.kind),location:E(e.location)};return void 0!==e.tags&&(n.tags=q(e.tags)),""!==e.containerName&&(n.containerName=e.containerName),n}}}},7711:(e,t,n)=>{"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.CodeLensFeature=void 0;const i=n(9496),r=n(152),o=n(1980),s=n(8909);class a extends s.TextDocumentLanguageFeature{constructor(e){super(e,r.CodeLensRequest.type)}fillClientCapabilities(e){(0,s.ensure)((0,s.ensure)(e,"textDocument"),"codeLens").dynamicRegistration=!0,(0,s.ensure)((0,s.ensure)(e,"workspace"),"codeLens").refreshSupport=!0}initialize(e,t){this._client.onRequest(r.CodeLensRefreshRequest.type,(async()=>{for(const e of this.getAllProviders())e.onDidChangeCodeLensEmitter.fire()}));const n=this.getRegistrationOptions(t,e.codeLensProvider);n&&this.register({id:o.generateUuid(),registerOptions:n})}registerLanguageProvider(e){const t=e.documentSelector,n=new i.EventEmitter,o={onDidChangeCodeLenses:n.event,provideCodeLenses:(e,t)=>{const n=this._client,i=(e,t)=>n.sendRequest(r.CodeLensRequest.type,n.code2ProtocolConverter.asCodeLensParams(e),t).then((e=>t.isCancellationRequested?null:n.protocol2CodeConverter.asCodeLenses(e,t)),(e=>n.handleFailedRequest(r.CodeLensRequest.type,t,e,null))),o=n.middleware;return o.provideCodeLenses?o.provideCodeLenses(e,t,i):i(e,t)},resolveCodeLens:e.resolveProvider?(e,t)=>{const n=this._client,i=(e,t)=>n.sendRequest(r.CodeLensResolveRequest.type,n.code2ProtocolConverter.asCodeLens(e),t).then((i=>t.isCancellationRequested?e:n.protocol2CodeConverter.asCodeLens(i)),(i=>n.handleFailedRequest(r.CodeLensResolveRequest.type,t,i,e))),o=n.middleware;return o.resolveCodeLens?o.resolveCodeLens(e,t,i):i(e,t)}:void 0};return[i.languages.registerCodeLensProvider(this._client.protocol2CodeConverter.asDocumentSelector(t),o),{provider:o,onDidChangeCodeLensEmitter:n}]}}t.CodeLensFeature=a},8880:(e,t,n)=>{"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.ColorProviderFeature=void 0;const i=n(9496),r=n(152),o=n(8909);class s extends o.TextDocumentLanguageFeature{constructor(e){super(e,r.DocumentColorRequest.type)}fillClientCapabilities(e){(0,o.ensure)((0,o.ensure)(e,"textDocument"),"colorProvider").dynamicRegistration=!0}initialize(e,t){let[n,i]=this.getRegistration(t,e.colorProvider);n&&i&&this.register({id:n,registerOptions:i})}registerLanguageProvider(e){const t=e.documentSelector,n={provideColorPresentations:(e,t,n)=>{const i=this._client,o=(e,t,n)=>{const o={color:e,textDocument:i.code2ProtocolConverter.asTextDocumentIdentifier(t.document),range:i.code2ProtocolConverter.asRange(t.range)};return i.sendRequest(r.ColorPresentationRequest.type,o,n).then((e=>n.isCancellationRequested?null:this._client.protocol2CodeConverter.asColorPresentations(e,n)),(e=>i.handleFailedRequest(r.ColorPresentationRequest.type,n,e,null)))},s=i.middleware;return s.provideColorPresentations?s.provideColorPresentations(e,t,n,o):o(e,t,n)},provideDocumentColors:(e,t)=>{const n=this._client,i=(e,t)=>{const i={textDocument:n.code2ProtocolConverter.asTextDocumentIdentifier(e)};return n.sendRequest(r.DocumentColorRequest.type,i,t).then((e=>t.isCancellationRequested?null:this._client.protocol2CodeConverter.asColorInformations(e,t)),(e=>n.handleFailedRequest(r.DocumentColorRequest.type,t,e,null)))},o=n.middleware;return o.provideDocumentColors?o.provideDocumentColors(e,t,i):i(e,t)}};return[i.languages.registerColorProvider(this._client.protocol2CodeConverter.asDocumentSelector(t),n),n]}}t.ColorProviderFeature=s},1435:(e,t,n)=>{"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.CompletionItemFeature=void 0;const i=n(9496),r=n(152),o=n(8909),s=n(1980),a=[r.CompletionItemKind.Text,r.CompletionItemKind.Method,r.CompletionItemKind.Function,r.CompletionItemKind.Constructor,r.CompletionItemKind.Field,r.CompletionItemKind.Variable,r.CompletionItemKind.Class,r.CompletionItemKind.Interface,r.CompletionItemKind.Module,r.CompletionItemKind.Property,r.CompletionItemKind.Unit,r.CompletionItemKind.Value,r.CompletionItemKind.Enum,r.CompletionItemKind.Keyword,r.CompletionItemKind.Snippet,r.CompletionItemKind.Color,r.CompletionItemKind.File,r.CompletionItemKind.Reference,r.CompletionItemKind.Folder,r.CompletionItemKind.EnumMember,r.CompletionItemKind.Constant,r.CompletionItemKind.Struct,r.CompletionItemKind.Event,r.CompletionItemKind.Operator,r.CompletionItemKind.TypeParameter];class c extends o.TextDocumentLanguageFeature{constructor(e){super(e,r.CompletionRequest.type),this.labelDetailsSupport=new Map}fillClientCapabilities(e){let t=(0,o.ensure)((0,o.ensure)(e,"textDocument"),"completion");t.dynamicRegistration=!0,t.contextSupport=!0,t.completionItem={snippetSupport:!0,commitCharactersSupport:!0,documentationFormat:[r.MarkupKind.Markdown,r.MarkupKind.PlainText],deprecatedSupport:!0,preselectSupport:!0,tagSupport:{valueSet:[r.CompletionItemTag.Deprecated]},insertReplaceSupport:!0,resolveSupport:{properties:["documentation","detail","additionalTextEdits"]},insertTextModeSupport:{valueSet:[r.InsertTextMode.asIs,r.InsertTextMode.adjustIndentation]},labelDetailsSupport:!0},t.insertTextMode=r.InsertTextMode.adjustIndentation,t.completionItemKind={valueSet:a},t.completionList={itemDefaults:["commitCharacters","editRange","insertTextFormat","insertTextMode"]}}initialize(e,t){const n=this.getRegistrationOptions(t,e.completionProvider);n&&this.register({id:s.generateUuid(),registerOptions:n})}registerLanguageProvider(e,t){this.labelDetailsSupport.set(t,!!e.completionItem?.labelDetailsSupport);const n=e.triggerCharacters??[],o=e.allCommitCharacters,s=e.documentSelector,a={provideCompletionItems:(e,t,n,i)=>{const s=this._client,a=this._client.middleware,c=(e,t,n,i)=>s.sendRequest(r.CompletionRequest.type,s.code2ProtocolConverter.asCompletionParams(e,t,n),i).then((e=>i.isCancellationRequested?null:s.protocol2CodeConverter.asCompletionResult(e,o,i)),(e=>s.handleFailedRequest(r.CompletionRequest.type,i,e,null)));return a.provideCompletionItem?a.provideCompletionItem(e,t,i,n,c):c(e,t,i,n)},resolveCompletionItem:e.resolveProvider?(e,n)=>{const i=this._client,o=this._client.middleware,s=(e,n)=>i.sendRequest(r.CompletionResolveRequest.type,i.code2ProtocolConverter.asCompletionItem(e,!!this.labelDetailsSupport.get(t)),n).then((e=>n.isCancellationRequested?null:i.protocol2CodeConverter.asCompletionItem(e)),(t=>i.handleFailedRequest(r.CompletionResolveRequest.type,n,t,e)));return o.resolveCompletionItem?o.resolveCompletionItem(e,n,s):s(e,n)}:void 0};return[i.languages.registerCompletionItemProvider(this._client.protocol2CodeConverter.asDocumentSelector(s),a,...n),a]}}t.CompletionItemFeature=c},6495:(e,t,n)=>{"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.SyncConfigurationFeature=t.toJSONObject=t.ConfigurationFeature=void 0;const i=n(9496),r=n(152),o=n(9763),s=n(1980),a=n(8909);function c(e){if(e){if(Array.isArray(e))return e.map(c);if("object"==typeof e){const t=Object.create(null);for(const n in e)Object.prototype.hasOwnProperty.call(e,n)&&(t[n]=c(e[n]));return t}}return e}t.ConfigurationFeature=class{constructor(e){this._client=e}getState(){return{kind:"static"}}fillClientCapabilities(e){e.workspace=e.workspace||{},e.workspace.configuration=!0}initialize(){let e=this._client;e.onRequest(r.ConfigurationRequest.type,((t,n)=>{let i=e=>{let t=[];for(let n of e.items){let e=void 0!==n.scopeUri&&null!==n.scopeUri?this._client.protocol2CodeConverter.asUri(n.scopeUri):void 0;t.push(this.getConfiguration(e,null!==n.section?n.section:void 0))}return t},r=e.middleware.workspace;return r&&r.configuration?r.configuration(t,n,i):i(t)}))}getConfiguration(e,t){let n=null;if(t){let r=t.lastIndexOf(".");if(-1===r)n=c(i.workspace.getConfiguration(void 0,e).get(t));else{let o=i.workspace.getConfiguration(t.substr(0,r),e);o&&(n=c(o.get(t.substr(r+1))))}}else{let t=i.workspace.getConfiguration(void 0,e);n={};for(let e of Object.keys(t))t.has(e)&&(n[e]=c(t.get(e)))}return void 0===n&&(n=null),n}dispose(){}},t.toJSONObject=c,t.SyncConfigurationFeature=class{constructor(e){this._client=e,this.isDisposed=!1,this._listeners=new Map}getState(){return{kind:"workspace",id:this.registrationType.method,registrations:this._listeners.size>0}}get registrationType(){return r.DidChangeConfigurationNotification.type}fillClientCapabilities(e){(0,a.ensure)((0,a.ensure)(e,"workspace"),"didChangeConfiguration").dynamicRegistration=!0}initialize(){let e=this._client.clientOptions.synchronize?.configurationSection;void 0!==e&&this.register({id:s.generateUuid(),registerOptions:{section:e}})}register(e){let t=i.workspace.onDidChangeConfiguration((t=>{this.onDidChangeConfiguration(e.registerOptions.section,t)}));this._listeners.set(e.id,t),void 0!==e.registerOptions.section&&this.onDidChangeConfiguration(e.registerOptions.section,void 0)}unregister(e){let t=this._listeners.get(e);t&&(this._listeners.delete(e),t.dispose())}dispose(){for(const e of this._listeners.values())e.dispose();this._listeners.clear(),this.isDisposed=!0}onDidChangeConfiguration(e,t){if(this.isDisposed)return;let n;if(n=o.string(e)?[e]:e,void 0!==n&&void 0!==t&&!n.some((e=>t.affectsConfiguration(e))))return;const i=async e=>void 0===e?this._client.sendNotification(r.DidChangeConfigurationNotification.type,{settings:null}):this._client.sendNotification(r.DidChangeConfigurationNotification.type,{settings:this.extractSettingsInformation(e)});let s=this._client.middleware.workspace?.didChangeConfiguration;(s?s(n,i):i(n)).catch((e=>{this._client.error(`Sending notification ${r.DidChangeConfigurationNotification.type.method} failed`,e)}))}extractSettingsInformation(e){function t(e,t){let n=e;for(let e=0;e=0?i.workspace.getConfiguration(s.substr(0,a),n).get(s.substr(a+1)):i.workspace.getConfiguration(void 0,n).get(s),u){let n=e[o].split(".");t(r,n)[n[n.length-1]]=c(u)}}return r}}},707:(e,t,n)=>{"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.DeclarationFeature=void 0;const i=n(9496),r=n(152),o=n(8909);class s extends o.TextDocumentLanguageFeature{constructor(e){super(e,r.DeclarationRequest.type)}fillClientCapabilities(e){const t=(0,o.ensure)((0,o.ensure)(e,"textDocument"),"declaration");t.dynamicRegistration=!0,t.linkSupport=!0}initialize(e,t){const[n,i]=this.getRegistration(t,e.declarationProvider);n&&i&&this.register({id:n,registerOptions:i})}registerLanguageProvider(e){const t=e.documentSelector,n={provideDeclaration:(e,t,n)=>{const i=this._client,o=(e,t,n)=>i.sendRequest(r.DeclarationRequest.type,i.code2ProtocolConverter.asTextDocumentPositionParams(e,t),n).then((e=>n.isCancellationRequested?null:i.protocol2CodeConverter.asDeclarationResult(e,n)),(e=>i.handleFailedRequest(r.DeclarationRequest.type,n,e,null))),s=i.middleware;return s.provideDeclaration?s.provideDeclaration(e,t,n,o):o(e,t,n)}};return[this.registerProvider(t,n),n]}registerProvider(e,t){return i.languages.registerDeclarationProvider(this._client.protocol2CodeConverter.asDocumentSelector(e),t)}}t.DeclarationFeature=s},122:(e,t,n)=>{"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.DefinitionFeature=void 0;const i=n(9496),r=n(152),o=n(8909),s=n(1980);class a extends o.TextDocumentLanguageFeature{constructor(e){super(e,r.DefinitionRequest.type)}fillClientCapabilities(e){let t=(0,o.ensure)((0,o.ensure)(e,"textDocument"),"definition");t.dynamicRegistration=!0,t.linkSupport=!0}initialize(e,t){const n=this.getRegistrationOptions(t,e.definitionProvider);n&&this.register({id:s.generateUuid(),registerOptions:n})}registerLanguageProvider(e){const t=e.documentSelector,n={provideDefinition:(e,t,n)=>{const i=this._client,o=(e,t,n)=>i.sendRequest(r.DefinitionRequest.type,i.code2ProtocolConverter.asTextDocumentPositionParams(e,t),n).then((e=>n.isCancellationRequested?null:i.protocol2CodeConverter.asDefinitionResult(e,n)),(e=>i.handleFailedRequest(r.DefinitionRequest.type,n,e,null))),s=i.middleware;return s.provideDefinition?s.provideDefinition(e,t,n,o):o(e,t,n)}};return[this.registerProvider(t,n),n]}registerProvider(e,t){return i.languages.registerDefinitionProvider(this._client.protocol2CodeConverter.asDocumentSelector(e),t)}}t.DefinitionFeature=a},2570:(e,t,n)=>{"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.DiagnosticFeature=t.DiagnosticPullMode=t.vsdiag=void 0;const i=n(1171),r=n(9496),o=n(152),s=n(1980),a=n(8909);function c(e,t){return void 0===e[t]&&(e[t]={}),e[t]}var u,l,d,f,p;!function(e){let t;!function(e){e.full="full",e.unChanged="unChanged"}(t=e.DocumentDiagnosticReportKind||(e.DocumentDiagnosticReportKind={}))}(u=t.vsdiag||(t.vsdiag={})),function(e){e.onType="onType",e.onSave="onSave"}(l=t.DiagnosticPullMode||(t.DiagnosticPullMode={})),function(e){e.active="open",e.reschedule="reschedule",e.outDated="drop"}(d||(d={}));class g{constructor(){this.open=new Set,this._onOpen=new r.EventEmitter,this._onClose=new r.EventEmitter,g.fillTabResources(this.open);void 0!==r.window.tabGroups.onDidChangeTabs?this.disposable=r.window.tabGroups.onDidChangeTabs((e=>{if(0===e.closed.length&&0===e.opened.length)return;const t=this.open,n=new Set;g.fillTabResources(n);const i=new Set,o=new Set(n);for(const e of t.values())n.has(e)?o.delete(e):i.add(e);if(this.open=n,i.size>0){const e=new Set;for(const t of i)e.add(r.Uri.parse(t));this._onClose.fire(e)}if(o.size>0){const e=new Set;for(const t of o)e.add(r.Uri.parse(t));this._onOpen.fire(e)}})):this.disposable={dispose:()=>{}}}get onClose(){return this._onClose.event}get onOpen(){return this._onOpen.event}dispose(){this.disposable.dispose()}isActive(e){return e instanceof r.Uri?r.window.activeTextEditor?.document.uri===e:r.window.activeTextEditor?.document===e}isVisible(e){const t=e instanceof r.Uri?e:e.uri;return this.open.has(t.toString())}getTabResources(){const e=new Set;return g.fillTabResources(new Set,e),e}static fillTabResources(e,t){const n=e??new Set;for(const e of r.window.tabGroups.all)for(const i of e.tabs){const e=i.input;let o;e instanceof r.TabInputText?o=e.uri:e instanceof r.TabInputTextDiff&&(o=e.modified),void 0===o||n.has(o.toString())||(n.add(o.toString()),void 0!==t&&t.add(o))}}}!function(e){e[e.document=1]="document",e[e.workspace=2]="workspace"}(f||(f={})),function(e){e.asKey=function(e){return e instanceof r.Uri?e.toString():e.uri.toString()}}(p||(p={}));class h{constructor(){this.documentPullStates=new Map,this.workspacePullStates=new Map}track(e,t,n){const i=e===f.document?this.documentPullStates:this.workspacePullStates,[o,s,a]=t instanceof r.Uri?[t.toString(),t,n]:[t.uri.toString(),t.uri,t.version];let c=i.get(o);return void 0===c&&(c={document:s,pulledVersion:a,resultId:void 0},i.set(o,c)),c}update(e,t,n,i){const o=e===f.document?this.documentPullStates:this.workspacePullStates,[s,a,c,u]=t instanceof r.Uri?[t.toString(),t,n,i]:[t.uri.toString(),t.uri,t.version,n];let l=o.get(s);void 0===l?(l={document:a,pulledVersion:c,resultId:u},o.set(s,l)):(l.pulledVersion=c,l.resultId=u)}unTrack(e,t){const n=p.asKey(t);(e===f.document?this.documentPullStates:this.workspacePullStates).delete(n)}tracks(e,t){const n=p.asKey(t);return(e===f.document?this.documentPullStates:this.workspacePullStates).has(n)}getResultId(e,t){const n=p.asKey(t);return(e===f.document?this.documentPullStates:this.workspacePullStates).get(n)?.resultId}getAllResultIds(){const e=[];for(let[t,n]of this.workspacePullStates)this.documentPullStates.has(t)&&(n=this.documentPullStates.get(t)),void 0!==n.resultId&&e.push({uri:t,value:n.resultId});return e}}class m{constructor(e,t,n){this.client=e,this.tabs=t,this.options=n,this.isDisposed=!1,this.onDidChangeDiagnosticsEmitter=new r.EventEmitter,this.provider=this.createProvider(),this.diagnostics=r.languages.createDiagnosticCollection(n.identifier),this.openRequests=new Map,this.documentStates=new h,this.workspaceErrorCounter=0}knows(e,t){const n=t instanceof r.Uri?t:t.uri;return this.documentStates.tracks(e,t)||this.openRequests.has(n.toString())}forget(e,t){this.documentStates.unTrack(e,t)}pull(e,t){if(this.isDisposed)return;const n=e instanceof r.Uri?e:e.uri;this.pullAsync(e).then((()=>{t&&t()}),(e=>{this.client.error(`Document pull failed for text document ${n.toString()}`,e,!1)}))}async pullAsync(e,t){if(this.isDisposed)return;const n=e instanceof r.Uri,i=n?e:e.uri,s=i.toString();t=n?t:e.version;const c=this.openRequests.get(s),l=n?this.documentStates.track(f.document,e,t):this.documentStates.track(f.document,e);if(void 0===c){const n=new r.CancellationTokenSource;let c,p;this.openRequests.set(s,{state:d.active,document:e,version:t,tokenSource:n});try{c=await this.provider.provideDiagnostics(e,l.resultId,n.token)??{kind:u.DocumentDiagnosticReportKind.full,items:[]}}catch(t){if(t instanceof a.LSPCancellationError&&o.DiagnosticServerCancellationData.is(t.data)&&!1===t.data.retriggerRequest&&(p={state:d.outDated,document:e}),!(void 0===p&&t instanceof r.CancellationError))throw t;p={state:d.reschedule,document:e}}if(p=p??this.openRequests.get(s),void 0===p)return this.client.error(`Lost request state in diagnostic pull model. Clearing diagnostics for ${s}`),void this.diagnostics.delete(i);if(this.openRequests.delete(s),!this.tabs.isVisible(e))return void this.documentStates.unTrack(f.document,e);if(p.state===d.outDated)return;void 0!==c&&(c.kind===u.DocumentDiagnosticReportKind.full&&this.diagnostics.set(i,c.items),l.pulledVersion=t,l.resultId=c.resultId),p.state===d.reschedule&&this.pull(e)}else c.state===d.active?(c.tokenSource.cancel(),this.openRequests.set(s,{state:d.reschedule,document:c.document})):c.state===d.outDated&&this.openRequests.set(s,{state:d.reschedule,document:c.document})}forgetDocument(e){const t=e instanceof r.Uri?e:e.uri,n=t.toString(),i=this.openRequests.get(n);this.options.workspaceDiagnostics?void 0!==i?this.openRequests.set(n,{state:d.reschedule,document:e}):this.pull(e,(()=>{this.forget(f.document,e)})):(void 0!==i&&(i.state===d.active&&i.tokenSource.cancel(),this.openRequests.set(n,{state:d.outDated,document:e})),this.diagnostics.delete(t),this.forget(f.document,e))}pullWorkspace(){this.isDisposed||this.pullWorkspaceAsync().then((()=>{this.workspaceTimeout=(0,o.RAL)().timer.setTimeout((()=>{this.pullWorkspace()}),2e3)}),(e=>{e instanceof a.LSPCancellationError||o.DiagnosticServerCancellationData.is(e.data)||(this.client.error("Workspace diagnostic pull failed.",e,!1),this.workspaceErrorCounter++),this.workspaceErrorCounter<=5&&(this.workspaceTimeout=(0,o.RAL)().timer.setTimeout((()=>{this.pullWorkspace()}),2e3))}))}async pullWorkspaceAsync(){if(!this.provider.provideWorkspaceDiagnostics||this.isDisposed)return;void 0!==this.workspaceCancellation&&(this.workspaceCancellation.cancel(),this.workspaceCancellation=void 0),this.workspaceCancellation=new r.CancellationTokenSource;const e=this.documentStates.getAllResultIds().map((e=>({uri:this.client.protocol2CodeConverter.asUri(e.uri),value:e.value})));await this.provider.provideWorkspaceDiagnostics(e,this.workspaceCancellation.token,(e=>{if(e&&!this.isDisposed)for(const t of e.items)t.kind===u.DocumentDiagnosticReportKind.full&&(this.documentStates.tracks(f.document,t.uri)||this.diagnostics.set(t.uri,t.items)),this.documentStates.update(f.workspace,t.uri,t.version??void 0,t.resultId)}))}createProvider(){const e={onDidChangeDiagnostics:this.onDidChangeDiagnosticsEmitter.event,provideDiagnostics:(e,t,n)=>{const i=(e,t,n)=>{const i={identifier:this.options.identifier,textDocument:{uri:this.client.code2ProtocolConverter.asUri(e instanceof r.Uri?e:e.uri)},previousResultId:t};return!0!==this.isDisposed&&this.client.isRunning()?this.client.sendRequest(o.DocumentDiagnosticRequest.type,i,n).then((async e=>null==e||this.isDisposed||n.isCancellationRequested?{kind:u.DocumentDiagnosticReportKind.full,items:[]}:e.kind===o.DocumentDiagnosticReportKind.Full?{kind:u.DocumentDiagnosticReportKind.full,resultId:e.resultId,items:await this.client.protocol2CodeConverter.asDiagnostics(e.items,n)}:{kind:u.DocumentDiagnosticReportKind.unChanged,resultId:e.resultId}),(e=>this.client.handleFailedRequest(o.DocumentDiagnosticRequest.type,n,e,{kind:u.DocumentDiagnosticReportKind.full,items:[]}))):{kind:u.DocumentDiagnosticReportKind.full,items:[]}},s=this.client.middleware;return s.provideDiagnostics?s.provideDiagnostics(e,t,n,i):i(e,t,n)}};return this.options.workspaceDiagnostics&&(e.provideWorkspaceDiagnostics=(e,t,n)=>{const i=async e=>e.kind===o.DocumentDiagnosticReportKind.Full?{kind:u.DocumentDiagnosticReportKind.full,uri:this.client.protocol2CodeConverter.asUri(e.uri),resultId:e.resultId,version:e.version,items:await this.client.protocol2CodeConverter.asDiagnostics(e.items,t)}:{kind:u.DocumentDiagnosticReportKind.unChanged,uri:this.client.protocol2CodeConverter.asUri(e.uri),resultId:e.resultId,version:e.version},r=e=>{const t=[];for(const n of e)t.push({uri:this.client.code2ProtocolConverter.asUri(n.uri),value:n.value});return t},a=(e,t)=>{const a=(0,s.generateUuid)(),c=this.client.onProgress(o.WorkspaceDiagnosticRequest.partialResult,a,(async e=>{if(null==e)return void n(null);const t={items:[]};for(const n of e.items)try{t.items.push(await i(n))}catch(e){this.client.error("Converting workspace diagnostics failed.",e)}n(t)})),u={identifier:this.options.identifier,previousResultIds:r(e),partialResultToken:a};return!0!==this.isDisposed&&this.client.isRunning()?this.client.sendRequest(o.WorkspaceDiagnosticRequest.type,u,t).then((async e=>{if(t.isCancellationRequested)return{items:[]};const r={items:[]};for(const t of e.items)r.items.push(await i(t));return c.dispose(),n(r),{items:[]}}),(e=>(c.dispose(),this.client.handleFailedRequest(o.DocumentDiagnosticRequest.type,t,e,{items:[]})))):{items:[]}},c=this.client.middleware;return c.provideWorkspaceDiagnostics?c.provideWorkspaceDiagnostics(e,t,n,a):a(e,t)}),e}dispose(){this.isDisposed=!0,this.workspaceCancellation?.cancel(),this.workspaceTimeout?.dispose();for(const[e,t]of this.openRequests)t.state===d.active&&t.tokenSource.cancel(),this.openRequests.set(e,{state:d.outDated,document:t.document});this.diagnostics.dispose()}}class v{constructor(e){this.diagnosticRequestor=e,this.documents=new o.LinkedMap,this.isDisposed=!1}add(e){if(!0===this.isDisposed)return;const t=p.asKey(e);this.documents.has(t)||(this.documents.set(t,e,o.Touch.Last),this.trigger())}remove(e){const t=p.asKey(e);this.documents.delete(t),0===this.documents.size?this.stop():t===this.endDocumentKey()&&(this.endDocument=this.documents.last)}trigger(){!0!==this.isDisposed&&(void 0===this.intervalHandle?(this.endDocument=this.documents.last,this.intervalHandle=(0,o.RAL)().timer.setInterval((()=>{const e=this.documents.first;if(void 0!==e){const t=p.asKey(e);this.diagnosticRequestor.pull(e),this.documents.set(t,e,o.Touch.Last),t===this.endDocumentKey()&&this.stop()}}),200)):this.endDocument=this.documents.last)}dispose(){this.isDisposed=!0,this.stop(),this.documents.clear()}stop(){this.intervalHandle?.dispose(),this.intervalHandle=void 0,this.endDocument=void 0}endDocumentKey(){return void 0!==this.endDocument?p.asKey(this.endDocument):void 0}}class y{constructor(e,t,n){const s=e.clientOptions.diagnosticPullOptions??{onChange:!0,onSave:!1},a=e.protocol2CodeConverter.asDocumentSelector(n.documentSelector),c=[],u=e=>e instanceof r.Uri?(e=>{const t=n.documentSelector;if(void 0!==s.match)return s.match(t,e);for(const n of t)if(o.TextDocumentFilter.is(n)){if("string"==typeof n)return!1;if(void 0!==n.language&&"*"!==n.language)return!1;if(void 0!==n.scheme&&"*"!==n.scheme&&n.scheme!==e.scheme)return!1;if(void 0!==n.pattern){const t=new i.Minimatch(n.pattern,{noext:!0});if(!t.makeRe())return!1;if(!t.match(e.fsPath))return!1}}return!0})(e):r.languages.match(a,e)>0&&t.isVisible(e),d=e=>e instanceof r.Uri?this.activeTextDocument?.uri.toString()===e.toString():this.activeTextDocument===e;this.diagnosticRequestor=new m(e,t,n),this.backgroundScheduler=new v(this.diagnosticRequestor);const p=e=>{u(e)&&n.interFileDependencies&&!d(e)&&this.backgroundScheduler.add(e)};this.activeTextDocument=r.window.activeTextEditor?.document,r.window.onDidChangeActiveTextEditor((e=>{const t=this.activeTextDocument;this.activeTextDocument=e?.document,void 0!==t&&p(t),void 0!==this.activeTextDocument&&this.backgroundScheduler.remove(this.activeTextDocument)}));const g=e.getFeature(o.DidOpenTextDocumentNotification.method);c.push(g.onNotificationSent((e=>{const t=e.textDocument;this.diagnosticRequestor.knows(f.document,t)||u(t)&&this.diagnosticRequestor.pull(t,(()=>{p(t)}))}))),t.onOpen((e=>{for(const t of e){if(this.diagnosticRequestor.knows(f.document,t))continue;const e=t.toString();let n;for(const t of r.workspace.textDocuments)if(e===t.uri.toString()){n=t;break}void 0!==n&&u(n)?this.diagnosticRequestor.pull(n,(()=>{p(n)})):u(t)&&this.diagnosticRequestor.pull(t,(()=>{p(t)}))}}));const h=new Set;for(const e of r.workspace.textDocuments)u(e)&&(this.diagnosticRequestor.pull(e,(()=>{p(e)})),h.add(e.uri.toString()));if(!0===s.onTabs)for(const e of t.getTabResources())!h.has(e.toString())&&u(e)&&this.diagnosticRequestor.pull(e,(()=>{p(e)}));if(!0===s.onChange){const t=e.getFeature(o.DidChangeTextDocumentNotification.method);c.push(t.onNotificationSent((async e=>{const t=e.textDocument;void 0!==s.filter&&s.filter(t,l.onType)||!this.diagnosticRequestor.knows(f.document,t)||this.diagnosticRequestor.pull(t,(()=>{this.backgroundScheduler.trigger()}))})))}if(!0===s.onSave){const t=e.getFeature(o.DidSaveTextDocumentNotification.method);c.push(t.onNotificationSent((e=>{const t=e.textDocument;void 0!==s.filter&&s.filter(t,l.onSave)||!this.diagnosticRequestor.knows(f.document,t)||this.diagnosticRequestor.pull(e.textDocument,(()=>{this.backgroundScheduler.trigger()}))})))}const y=e.getFeature(o.DidCloseTextDocumentNotification.method);c.push(y.onNotificationSent((e=>{this.cleanUpDocument(e.textDocument)}))),t.onClose((e=>{for(const t of e)this.cleanUpDocument(t)})),this.diagnosticRequestor.onDidChangeDiagnosticsEmitter.event((()=>{for(const e of r.workspace.textDocuments)u(e)&&this.diagnosticRequestor.pull(e)})),!0===n.workspaceDiagnostics&&"da348dc5-c30a-4515-9d98-31ff3be38d14"!==n.identifier&&this.diagnosticRequestor.pullWorkspace(),this.disposable=r.Disposable.from(...c,this.backgroundScheduler,this.diagnosticRequestor)}get onDidChangeDiagnosticsEmitter(){return this.diagnosticRequestor.onDidChangeDiagnosticsEmitter}get diagnostics(){return this.diagnosticRequestor.provider}cleanUpDocument(e){this.diagnosticRequestor.knows(f.document,e)&&(this.diagnosticRequestor.forgetDocument(e),this.backgroundScheduler.remove(e))}}class S extends a.TextDocumentLanguageFeature{constructor(e){super(e,o.DocumentDiagnosticRequest.type)}fillClientCapabilities(e){let t=c(c(e,"textDocument"),"diagnostic");t.dynamicRegistration=!0,t.relatedDocumentSupport=!1,c(c(e,"workspace"),"diagnostics").refreshSupport=!0}initialize(e,t){this._client.onRequest(o.DiagnosticRefreshRequest.type,(async()=>{for(const e of this.getAllProviders())e.onDidChangeDiagnosticsEmitter.fire()}));let[n,i]=this.getRegistration(t,e.diagnosticProvider);n&&i&&this.register({id:n,registerOptions:i})}dispose(){void 0!==this.tabs&&(this.tabs.dispose(),this.tabs=void 0),super.dispose()}registerLanguageProvider(e){void 0===this.tabs&&(this.tabs=new g);const t=new y(this._client,this.tabs,e);return[t.disposable,t]}}t.DiagnosticFeature=S},9959:(e,t,n)=>{"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.DocumentHighlightFeature=void 0;const i=n(9496),r=n(152),o=n(8909),s=n(1980);class a extends o.TextDocumentLanguageFeature{constructor(e){super(e,r.DocumentHighlightRequest.type)}fillClientCapabilities(e){(0,o.ensure)((0,o.ensure)(e,"textDocument"),"documentHighlight").dynamicRegistration=!0}initialize(e,t){const n=this.getRegistrationOptions(t,e.documentHighlightProvider);n&&this.register({id:s.generateUuid(),registerOptions:n})}registerLanguageProvider(e){const t=e.documentSelector,n={provideDocumentHighlights:(e,t,n)=>{const i=this._client,o=(e,t,n)=>i.sendRequest(r.DocumentHighlightRequest.type,i.code2ProtocolConverter.asTextDocumentPositionParams(e,t),n).then((e=>n.isCancellationRequested?null:i.protocol2CodeConverter.asDocumentHighlights(e,n)),(e=>i.handleFailedRequest(r.DocumentHighlightRequest.type,n,e,null))),s=i.middleware;return s.provideDocumentHighlights?s.provideDocumentHighlights(e,t,n,o):o(e,t,n)}};return[i.languages.registerDocumentHighlightProvider(this._client.protocol2CodeConverter.asDocumentSelector(t),n),n]}}t.DocumentHighlightFeature=a},3471:(e,t,n)=>{"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.DocumentLinkFeature=void 0;const i=n(9496),r=n(152),o=n(8909),s=n(1980);class a extends o.TextDocumentLanguageFeature{constructor(e){super(e,r.DocumentLinkRequest.type)}fillClientCapabilities(e){const t=(0,o.ensure)((0,o.ensure)(e,"textDocument"),"documentLink");t.dynamicRegistration=!0,t.tooltipSupport=!0}initialize(e,t){const n=this.getRegistrationOptions(t,e.documentLinkProvider);n&&this.register({id:s.generateUuid(),registerOptions:n})}registerLanguageProvider(e){const t=e.documentSelector,n={provideDocumentLinks:(e,t)=>{const n=this._client,i=(e,t)=>n.sendRequest(r.DocumentLinkRequest.type,n.code2ProtocolConverter.asDocumentLinkParams(e),t).then((e=>t.isCancellationRequested?null:n.protocol2CodeConverter.asDocumentLinks(e,t)),(e=>n.handleFailedRequest(r.DocumentLinkRequest.type,t,e,null))),o=n.middleware;return o.provideDocumentLinks?o.provideDocumentLinks(e,t,i):i(e,t)},resolveDocumentLink:e.resolveProvider?(e,t)=>{const n=this._client;let i=(e,t)=>n.sendRequest(r.DocumentLinkResolveRequest.type,n.code2ProtocolConverter.asDocumentLink(e),t).then((i=>t.isCancellationRequested?e:n.protocol2CodeConverter.asDocumentLink(i)),(i=>n.handleFailedRequest(r.DocumentLinkResolveRequest.type,t,i,e)));const o=n.middleware;return o.resolveDocumentLink?o.resolveDocumentLink(e,t,i):i(e,t)}:void 0};return[i.languages.registerDocumentLinkProvider(this._client.protocol2CodeConverter.asDocumentSelector(t),n),n]}}t.DocumentLinkFeature=a},2483:(e,t,n)=>{"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.DocumentSymbolFeature=t.SupportedSymbolTags=t.SupportedSymbolKinds=void 0;const i=n(9496),r=n(152),o=n(8909),s=n(1980);t.SupportedSymbolKinds=[r.SymbolKind.File,r.SymbolKind.Module,r.SymbolKind.Namespace,r.SymbolKind.Package,r.SymbolKind.Class,r.SymbolKind.Method,r.SymbolKind.Property,r.SymbolKind.Field,r.SymbolKind.Constructor,r.SymbolKind.Enum,r.SymbolKind.Interface,r.SymbolKind.Function,r.SymbolKind.Variable,r.SymbolKind.Constant,r.SymbolKind.String,r.SymbolKind.Number,r.SymbolKind.Boolean,r.SymbolKind.Array,r.SymbolKind.Object,r.SymbolKind.Key,r.SymbolKind.Null,r.SymbolKind.EnumMember,r.SymbolKind.Struct,r.SymbolKind.Event,r.SymbolKind.Operator,r.SymbolKind.TypeParameter],t.SupportedSymbolTags=[r.SymbolTag.Deprecated];class a extends o.TextDocumentLanguageFeature{constructor(e){super(e,r.DocumentSymbolRequest.type)}fillClientCapabilities(e){let n=(0,o.ensure)((0,o.ensure)(e,"textDocument"),"documentSymbol");n.dynamicRegistration=!0,n.symbolKind={valueSet:t.SupportedSymbolKinds},n.hierarchicalDocumentSymbolSupport=!0,n.tagSupport={valueSet:t.SupportedSymbolTags},n.labelSupport=!0}initialize(e,t){const n=this.getRegistrationOptions(t,e.documentSymbolProvider);n&&this.register({id:s.generateUuid(),registerOptions:n})}registerLanguageProvider(e){const t=e.documentSelector,n={provideDocumentSymbols:(e,t)=>{const n=this._client,i=async(e,t)=>{try{const i=await n.sendRequest(r.DocumentSymbolRequest.type,n.code2ProtocolConverter.asDocumentSymbolParams(e),t);if(t.isCancellationRequested||null==i)return null;if(0===i.length)return[];{const e=i[0];return r.DocumentSymbol.is(e)?await n.protocol2CodeConverter.asDocumentSymbols(i,t):await n.protocol2CodeConverter.asSymbolInformations(i,t)}}catch(e){return n.handleFailedRequest(r.DocumentSymbolRequest.type,t,e,null)}},o=n.middleware;return o.provideDocumentSymbols?o.provideDocumentSymbols(e,t,i):i(e,t)}},o=void 0!==e.label?{label:e.label}:void 0;return[i.languages.registerDocumentSymbolProvider(this._client.protocol2CodeConverter.asDocumentSelector(t),n,o),n]}}t.DocumentSymbolFeature=a},4849:(e,t,n)=>{"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.ExecuteCommandFeature=void 0;const i=n(9496),r=n(152),o=n(1980),s=n(8909);t.ExecuteCommandFeature=class{constructor(e){this._client=e,this._commands=new Map}getState(){return{kind:"workspace",id:this.registrationType.method,registrations:this._commands.size>0}}get registrationType(){return r.ExecuteCommandRequest.type}fillClientCapabilities(e){(0,s.ensure)((0,s.ensure)(e,"workspace"),"executeCommand").dynamicRegistration=!0}initialize(e){e.executeCommandProvider&&this.register({id:o.generateUuid(),registerOptions:Object.assign({},e.executeCommandProvider)})}register(e){const t=this._client,n=t.middleware,o=(e,n)=>{let i={command:e,arguments:n};return t.sendRequest(r.ExecuteCommandRequest.type,i).then(void 0,(e=>t.handleFailedRequest(r.ExecuteCommandRequest.type,void 0,e,void 0)))};if(e.registerOptions.commands){const t=[];for(const r of e.registerOptions.commands)t.push(i.commands.registerCommand(r,((...e)=>n.executeCommand?n.executeCommand(r,e,o):o(r,e))));this._commands.set(e.id,t)}}unregister(e){let t=this._commands.get(e);t&&t.forEach((e=>e.dispose()))}dispose(){this._commands.forEach((e=>{e.forEach((e=>e.dispose()))})),this._commands.clear()}}},8909:(e,t,n)=>{"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.WorkspaceFeature=t.TextDocumentLanguageFeature=t.TextDocumentEventFeature=t.DynamicDocumentFeature=t.DynamicFeature=t.StaticFeature=t.ensure=t.LSPCancellationError=void 0;const i=n(9496),r=n(152),o=n(9763),s=n(1980);class a extends i.CancellationError{constructor(e){super(),this.data=e}}t.LSPCancellationError=a,t.ensure=function(e,t){return void 0===e[t]&&(e[t]={}),e[t]},(t.StaticFeature||(t.StaticFeature={})).is=function(e){const t=e;return null!=t&&o.func(t.fillClientCapabilities)&&o.func(t.initialize)&&o.func(t.getState)&&o.func(t.dispose)&&(void 0===t.fillInitializeParams||o.func(t.fillInitializeParams))},(t.DynamicFeature||(t.DynamicFeature={})).is=function(e){const t=e;return null!=t&&o.func(t.fillClientCapabilities)&&o.func(t.initialize)&&o.func(t.getState)&&o.func(t.dispose)&&(void 0===t.fillInitializeParams||o.func(t.fillInitializeParams))&&o.func(t.register)&&o.func(t.unregister)&&void 0!==t.registrationType};class c{constructor(e){this._client=e}getState(){const e=this.getDocumentSelectors();let t=0;for(const n of e){t++;for(const e of i.workspace.textDocuments)if(i.languages.match(n,e)>0)return{kind:"document",id:this.registrationType.method,registrations:!0,matches:!0}}const n=t>0;return{kind:"document",id:this.registrationType.method,registrations:n,matches:!1}}}t.DynamicDocumentFeature=c,t.TextDocumentEventFeature=class extends c{constructor(e,t,n,r,o,s,a){super(e),this._event=t,this._type=n,this._middleware=r,this._createParams=o,this._textDocument=s,this._selectorFilter=a,this._selectors=new Map,this._onNotificationSent=new i.EventEmitter}static textDocumentFilter(e,t){for(const n of e)if(i.languages.match(n,t)>0)return!0;return!1}getStateInfo(){return[this._selectors.values(),!1]}getDocumentSelectors(){return this._selectors.values()}register(e){e.registerOptions.documentSelector&&(this._listener||(this._listener=this._event((e=>{this.callback(e).catch((e=>{this._client.error(`Sending document notification ${this._type.method} failed.`,e)}))}))),this._selectors.set(e.id,this._client.protocol2CodeConverter.asDocumentSelector(e.registerOptions.documentSelector)))}async callback(e){const t=async e=>{const t=this._createParams(e);await this._client.sendNotification(this._type,t),this.notificationSent(this.getTextDocument(e),this._type,t)};if(this.matches(e)){const n=this._middleware();return n?n(e,(e=>t(e))):t(e)}}matches(e){return!this._client.hasDedicatedTextSynchronizationFeature(this._textDocument(e))&&(!this._selectorFilter||this._selectorFilter(this._selectors.values(),e))}get onNotificationSent(){return this._onNotificationSent.event}notificationSent(e,t,n){this._onNotificationSent.fire({textDocument:e,type:t,params:n})}unregister(e){this._selectors.delete(e),0===this._selectors.size&&this._listener&&(this._listener.dispose(),this._listener=void 0)}dispose(){this._selectors.clear(),this._onNotificationSent.dispose(),this._listener&&(this._listener.dispose(),this._listener=void 0)}getProvider(e){for(const t of this._selectors.values())if(i.languages.match(t,e)>0)return{send:e=>this.callback(e)}}},t.TextDocumentLanguageFeature=class extends c{constructor(e,t){super(e),this._registrationType=t,this._registrations=new Map}*getDocumentSelectors(){for(const e of this._registrations.values()){const t=e.data.registerOptions.documentSelector;null!==t&&(yield this._client.protocol2CodeConverter.asDocumentSelector(t))}}get registrationType(){return this._registrationType}register(e){if(!e.registerOptions.documentSelector)return;let t=this.registerLanguageProvider(e.registerOptions,e.id);this._registrations.set(e.id,{disposable:t[0],data:e,provider:t[1]})}unregister(e){let t=this._registrations.get(e);void 0!==t&&t.disposable.dispose()}dispose(){this._registrations.forEach((e=>{e.disposable.dispose()})),this._registrations.clear()}getRegistration(e,t){if(!t)return[void 0,void 0];if(r.TextDocumentRegistrationOptions.is(t)){const n=r.StaticRegistrationOptions.hasId(t)?t.id:s.generateUuid(),i=t.documentSelector??e;if(i)return[n,Object.assign({},t,{documentSelector:i})]}else if(o.boolean(t)&&!0===t||r.WorkDoneProgressOptions.is(t)){if(!e)return[void 0,void 0];const n=o.boolean(t)&&!0===t?{documentSelector:e}:Object.assign({},t,{documentSelector:e});return[s.generateUuid(),n]}return[void 0,void 0]}getRegistrationOptions(e,t){if(e&&t)return o.boolean(t)&&!0===t?{documentSelector:e}:Object.assign({},t,{documentSelector:e})}getProvider(e){for(const t of this._registrations.values()){let n=t.data.registerOptions.documentSelector;if(null!==n&&i.languages.match(this._client.protocol2CodeConverter.asDocumentSelector(n),e)>0)return t.provider}}getAllProviders(){const e=[];for(const t of this._registrations.values())e.push(t.provider);return e}},t.WorkspaceFeature=class{constructor(e,t){this._client=e,this._registrationType=t,this._registrations=new Map}getState(){const e=this._registrations.size>0;return{kind:"workspace",id:this._registrationType.method,registrations:e}}get registrationType(){return this._registrationType}register(e){const t=this.registerLanguageProvider(e.registerOptions);this._registrations.set(e.id,{disposable:t[0],provider:t[1]})}unregister(e){let t=this._registrations.get(e);void 0!==t&&t.disposable.dispose()}dispose(){this._registrations.forEach((e=>{e.disposable.dispose()})),this._registrations.clear()}getProviders(){const e=[];for(const t of this._registrations.values())e.push(t.provider);return e}}},7606:(e,t,n)=>{"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.WillDeleteFilesFeature=t.WillRenameFilesFeature=t.WillCreateFilesFeature=t.DidDeleteFilesFeature=t.DidRenameFilesFeature=t.DidCreateFilesFeature=void 0;const i=n(9496),r=n(1171),o=n(152),s=n(1980);function a(e,t){return void 0===e[t]&&(e[t]={}),e[t]}function c(e,t,n){e[t]=n}class u{constructor(e,t,n,i,r){this._client=e,this._event=t,this._registrationType=n,this._clientCapability=i,this._serverCapability=r,this._filters=new Map}getState(){return{kind:"workspace",id:this._registrationType.method,registrations:this._filters.size>0}}filterSize(){return this._filters.size}get registrationType(){return this._registrationType}fillClientCapabilities(e){const t=a(a(e,"workspace"),"fileOperations");c(t,"dynamicRegistration",!0),c(t,this._clientCapability,!0)}initialize(e){const t=e.workspace?.fileOperations,n=void 0!==t?t[this._serverCapability]:void 0;if(void 0!==n?.filters)try{this.register({id:s.generateUuid(),registerOptions:{filters:n.filters}})}catch(e){this._client.warn(`Ignoring invalid glob pattern for ${this._serverCapability} registration: ${e}`)}}register(e){this._listener||(this._listener=this._event(this.send,this));const t=e.registerOptions.filters.map((e=>{const t=new r.Minimatch(e.pattern.glob,u.asMinimatchOptions(e.pattern.options));if(!t.makeRe())throw new Error(`Invalid pattern ${e.pattern.glob}!`);return{scheme:e.scheme,matcher:t,kind:e.pattern.matches}}));this._filters.set(e.id,t)}unregister(e){this._filters.delete(e),0===this._filters.size&&this._listener&&(this._listener.dispose(),this._listener=void 0)}dispose(){this._filters.clear(),this._listener&&(this._listener.dispose(),this._listener=void 0)}getFileType(e){return u.getFileType(e)}async filter(e,t){const n=await Promise.all(e.files.map((async e=>{const n=t(e),r=n.fsPath.replace(/\\/g,"/");for(const e of this._filters.values())for(const t of e)if(void 0===t.scheme||t.scheme===n.scheme)if(t.matcher.match(r)){if(void 0===t.kind)return!0;const e=await this.getFileType(n);if(void 0===e)return this._client.error(`Failed to determine file type for ${n.toString()}.`),!0;if(e===i.FileType.File&&t.kind===o.FileOperationPatternKind.file||e===i.FileType.Directory&&t.kind===o.FileOperationPatternKind.folder)return!0}else if(t.kind===o.FileOperationPatternKind.folder&&await u.getFileType(n)===i.FileType.Directory&&t.matcher.match(`${r}/`))return!0;return!1}))),r=e.files.filter(((e,t)=>n[t]));return{...e,files:r}}static async getFileType(e){try{return(await i.workspace.fs.stat(e)).type}catch(e){return}}static asMinimatchOptions(e){if(void 0!==e)return!0===e.ignoreCase?{nocase:!0}:void 0}}class l extends u{constructor(e,t,n,i,r,o,s){super(e,t,n,i,r),this._notificationType=n,this._accessUri=o,this._createParams=s}async send(e){const t=await this.filter(e,this._accessUri);if(t.files.length){const e=async e=>this._client.sendNotification(this._notificationType,this._createParams(e));return this.doSend(t,e)}}}class d extends l{constructor(){super(...arguments),this._fsPathFileTypes=new Map}async getFileType(e){const t=e.fsPath;if(this._fsPathFileTypes.has(t))return this._fsPathFileTypes.get(t);const n=await u.getFileType(e);return n&&this._fsPathFileTypes.set(t,n),n}async cacheFileTypes(e,t){await this.filter(e,t)}clearFileTypeCache(){this._fsPathFileTypes.clear()}unregister(e){super.unregister(e),0===this.filterSize()&&this._willListener&&(this._willListener.dispose(),this._willListener=void 0)}dispose(){super.dispose(),this._willListener&&(this._willListener.dispose(),this._willListener=void 0)}}t.DidCreateFilesFeature=class extends l{constructor(e){super(e,i.workspace.onDidCreateFiles,o.DidCreateFilesNotification.type,"didCreate","didCreate",(e=>e),e.code2ProtocolConverter.asDidCreateFilesParams)}doSend(e,t){const n=this._client.middleware.workspace;return n?.didCreateFiles?n.didCreateFiles(e,t):t(e)}},t.DidRenameFilesFeature=class extends d{constructor(e){super(e,i.workspace.onDidRenameFiles,o.DidRenameFilesNotification.type,"didRename","didRename",(e=>e.oldUri),e.code2ProtocolConverter.asDidRenameFilesParams)}register(e){this._willListener||(this._willListener=i.workspace.onWillRenameFiles(this.willRename,this)),super.register(e)}willRename(e){e.waitUntil(this.cacheFileTypes(e,(e=>e.oldUri)))}doSend(e,t){this.clearFileTypeCache();const n=this._client.middleware.workspace;return n?.didRenameFiles?n.didRenameFiles(e,t):t(e)}},t.DidDeleteFilesFeature=class extends d{constructor(e){super(e,i.workspace.onDidDeleteFiles,o.DidDeleteFilesNotification.type,"didDelete","didDelete",(e=>e),e.code2ProtocolConverter.asDidDeleteFilesParams)}register(e){this._willListener||(this._willListener=i.workspace.onWillDeleteFiles(this.willDelete,this)),super.register(e)}willDelete(e){e.waitUntil(this.cacheFileTypes(e,(e=>e)))}doSend(e,t){this.clearFileTypeCache();const n=this._client.middleware.workspace;return n?.didDeleteFiles?n.didDeleteFiles(e,t):t(e)}};class f extends u{constructor(e,t,n,i,r,o,s){super(e,t,n,i,r),this._requestType=n,this._accessUri=o,this._createParams=s}async send(e){const t=this.waitUntil(e);e.waitUntil(t)}async waitUntil(e){const t=await this.filter(e,this._accessUri);if(t.files.length){const e=e=>this._client.sendRequest(this._requestType,this._createParams(e),e.token).then(this._client.protocol2CodeConverter.asWorkspaceEdit);return this.doSend(t,e)}}}t.WillCreateFilesFeature=class extends f{constructor(e){super(e,i.workspace.onWillCreateFiles,o.WillCreateFilesRequest.type,"willCreate","willCreate",(e=>e),e.code2ProtocolConverter.asWillCreateFilesParams)}doSend(e,t){const n=this._client.middleware.workspace;return n?.willCreateFiles?n.willCreateFiles(e,t):t(e)}},t.WillRenameFilesFeature=class extends f{constructor(e){super(e,i.workspace.onWillRenameFiles,o.WillRenameFilesRequest.type,"willRename","willRename",(e=>e.oldUri),e.code2ProtocolConverter.asWillRenameFilesParams)}doSend(e,t){const n=this._client.middleware.workspace;return n?.willRenameFiles?n.willRenameFiles(e,t):t(e)}},t.WillDeleteFilesFeature=class extends f{constructor(e){super(e,i.workspace.onWillDeleteFiles,o.WillDeleteFilesRequest.type,"willDelete","willDelete",(e=>e),e.code2ProtocolConverter.asWillDeleteFilesParams)}doSend(e,t){const n=this._client.middleware.workspace;return n?.willDeleteFiles?n.willDeleteFiles(e,t):t(e)}}},5338:(e,t,n)=>{"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.FileSystemWatcherFeature=void 0;const i=n(9496),r=n(152),o=n(8909);t.FileSystemWatcherFeature=class{constructor(e,t){this._client=e,this._notifyFileEvent=t,this._watchers=new Map}getState(){return{kind:"workspace",id:this.registrationType.method,registrations:this._watchers.size>0}}get registrationType(){return r.DidChangeWatchedFilesNotification.type}fillClientCapabilities(e){(0,o.ensure)((0,o.ensure)(e,"workspace"),"didChangeWatchedFiles").dynamicRegistration=!0,(0,o.ensure)((0,o.ensure)(e,"workspace"),"didChangeWatchedFiles").relativePatternSupport=!0}initialize(e,t){}register(e){if(!Array.isArray(e.registerOptions.watchers))return;const t=[];for(const n of e.registerOptions.watchers){const e=this._client.protocol2CodeConverter.asGlobPattern(n.globPattern);if(void 0===e)continue;let o=!0,s=!0,a=!0;void 0!==n.kind&&null!==n.kind&&(o=0!=(n.kind&r.WatchKind.Create),s=0!=(n.kind&r.WatchKind.Change),a=0!=(n.kind&r.WatchKind.Delete));const c=i.workspace.createFileSystemWatcher(e,!o,!s,!a);this.hookListeners(c,o,s,a,t),t.push(c)}this._watchers.set(e.id,t)}registerRaw(e,t){let n=[];for(let e of t)this.hookListeners(e,!0,!0,!0,n);this._watchers.set(e,n)}hookListeners(e,t,n,i,o){t&&e.onDidCreate((e=>this._notifyFileEvent({uri:this._client.code2ProtocolConverter.asUri(e),type:r.FileChangeType.Created})),null,o),n&&e.onDidChange((e=>this._notifyFileEvent({uri:this._client.code2ProtocolConverter.asUri(e),type:r.FileChangeType.Changed})),null,o),i&&e.onDidDelete((e=>this._notifyFileEvent({uri:this._client.code2ProtocolConverter.asUri(e),type:r.FileChangeType.Deleted})),null,o)}unregister(e){let t=this._watchers.get(e);if(t)for(let e of t)e.dispose()}dispose(){this._watchers.forEach((e=>{for(let t of e)t.dispose()})),this._watchers.clear()}}},6454:(e,t,n)=>{"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.FoldingRangeFeature=void 0;const i=n(9496),r=n(152),o=n(8909);class s extends o.TextDocumentLanguageFeature{constructor(e){super(e,r.FoldingRangeRequest.type)}fillClientCapabilities(e){let t=(0,o.ensure)((0,o.ensure)(e,"textDocument"),"foldingRange");t.dynamicRegistration=!0,t.rangeLimit=5e3,t.lineFoldingOnly=!0,t.foldingRangeKind={valueSet:[r.FoldingRangeKind.Comment,r.FoldingRangeKind.Imports,r.FoldingRangeKind.Region]},t.foldingRange={collapsedText:!1}}initialize(e,t){let[n,i]=this.getRegistration(t,e.foldingRangeProvider);n&&i&&this.register({id:n,registerOptions:i})}registerLanguageProvider(e){const t=e.documentSelector,n={provideFoldingRanges:(e,t,n)=>{const i=this._client,o=(e,t,n)=>{const o={textDocument:i.code2ProtocolConverter.asTextDocumentIdentifier(e)};return i.sendRequest(r.FoldingRangeRequest.type,o,n).then((e=>n.isCancellationRequested?null:i.protocol2CodeConverter.asFoldingRanges(e,n)),(e=>i.handleFailedRequest(r.FoldingRangeRequest.type,n,e,null)))},s=i.middleware;return s.provideFoldingRanges?s.provideFoldingRanges(e,t,n,o):o(e,0,n)}};return[i.languages.registerFoldingRangeProvider(this._client.protocol2CodeConverter.asDocumentSelector(t),n),n]}}t.FoldingRangeFeature=s},6426:(e,t,n)=>{"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.DocumentOnTypeFormattingFeature=t.DocumentRangeFormattingFeature=t.DocumentFormattingFeature=void 0;const i=n(9496),r=n(152),o=n(1980),s=n(8909);var a;!function(e){e.fromConfiguration=function(e){const t=i.workspace.getConfiguration("files",e);return{trimTrailingWhitespace:t.get("trimTrailingWhitespace"),trimFinalNewlines:t.get("trimFinalNewlines"),insertFinalNewline:t.get("insertFinalNewline")}}}(a||(a={}));class c extends s.TextDocumentLanguageFeature{constructor(e){super(e,r.DocumentFormattingRequest.type)}fillClientCapabilities(e){(0,s.ensure)((0,s.ensure)(e,"textDocument"),"formatting").dynamicRegistration=!0}initialize(e,t){const n=this.getRegistrationOptions(t,e.documentFormattingProvider);n&&this.register({id:o.generateUuid(),registerOptions:n})}registerLanguageProvider(e){const t=e.documentSelector,n={provideDocumentFormattingEdits:(e,t,n)=>{const i=this._client,o=(e,t,n)=>{const o={textDocument:i.code2ProtocolConverter.asTextDocumentIdentifier(e),options:i.code2ProtocolConverter.asFormattingOptions(t,a.fromConfiguration(e))};return i.sendRequest(r.DocumentFormattingRequest.type,o,n).then((e=>n.isCancellationRequested?null:i.protocol2CodeConverter.asTextEdits(e,n)),(e=>i.handleFailedRequest(r.DocumentFormattingRequest.type,n,e,null)))},s=i.middleware;return s.provideDocumentFormattingEdits?s.provideDocumentFormattingEdits(e,t,n,o):o(e,t,n)}};return[i.languages.registerDocumentFormattingEditProvider(this._client.protocol2CodeConverter.asDocumentSelector(t),n),n]}}t.DocumentFormattingFeature=c;class u extends s.TextDocumentLanguageFeature{constructor(e){super(e,r.DocumentRangeFormattingRequest.type)}fillClientCapabilities(e){(0,s.ensure)((0,s.ensure)(e,"textDocument"),"rangeFormatting").dynamicRegistration=!0}initialize(e,t){const n=this.getRegistrationOptions(t,e.documentRangeFormattingProvider);n&&this.register({id:o.generateUuid(),registerOptions:n})}registerLanguageProvider(e){const t=e.documentSelector,n={provideDocumentRangeFormattingEdits:(e,t,n,i)=>{const o=this._client,s=(e,t,n,i)=>{const s={textDocument:o.code2ProtocolConverter.asTextDocumentIdentifier(e),range:o.code2ProtocolConverter.asRange(t),options:o.code2ProtocolConverter.asFormattingOptions(n,a.fromConfiguration(e))};return o.sendRequest(r.DocumentRangeFormattingRequest.type,s,i).then((e=>i.isCancellationRequested?null:o.protocol2CodeConverter.asTextEdits(e,i)),(e=>o.handleFailedRequest(r.DocumentRangeFormattingRequest.type,i,e,null)))},c=o.middleware;return c.provideDocumentRangeFormattingEdits?c.provideDocumentRangeFormattingEdits(e,t,n,i,s):s(e,t,n,i)}};return[i.languages.registerDocumentRangeFormattingEditProvider(this._client.protocol2CodeConverter.asDocumentSelector(t),n),n]}}t.DocumentRangeFormattingFeature=u;class l extends s.TextDocumentLanguageFeature{constructor(e){super(e,r.DocumentOnTypeFormattingRequest.type)}fillClientCapabilities(e){(0,s.ensure)((0,s.ensure)(e,"textDocument"),"onTypeFormatting").dynamicRegistration=!0}initialize(e,t){const n=this.getRegistrationOptions(t,e.documentOnTypeFormattingProvider);n&&this.register({id:o.generateUuid(),registerOptions:n})}registerLanguageProvider(e){const t=e.documentSelector,n={provideOnTypeFormattingEdits:(e,t,n,i,o)=>{const s=this._client,c=(e,t,n,i,o)=>{let c={textDocument:s.code2ProtocolConverter.asTextDocumentIdentifier(e),position:s.code2ProtocolConverter.asPosition(t),ch:n,options:s.code2ProtocolConverter.asFormattingOptions(i,a.fromConfiguration(e))};return s.sendRequest(r.DocumentOnTypeFormattingRequest.type,c,o).then((e=>o.isCancellationRequested?null:s.protocol2CodeConverter.asTextEdits(e,o)),(e=>s.handleFailedRequest(r.DocumentOnTypeFormattingRequest.type,o,e,null)))},u=s.middleware;return u.provideOnTypeFormattingEdits?u.provideOnTypeFormattingEdits(e,t,n,i,o,c):c(e,t,n,i,o)}},o=e.moreTriggerCharacter||[];return[i.languages.registerOnTypeFormattingEditProvider(this._client.protocol2CodeConverter.asDocumentSelector(t),n,e.firstTriggerCharacter,...o),n]}}t.DocumentOnTypeFormattingFeature=l},6782:(e,t,n)=>{"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.HoverFeature=void 0;const i=n(9496),r=n(152),o=n(8909),s=n(1980);class a extends o.TextDocumentLanguageFeature{constructor(e){super(e,r.HoverRequest.type)}fillClientCapabilities(e){const t=(0,o.ensure)((0,o.ensure)(e,"textDocument"),"hover");t.dynamicRegistration=!0,t.contentFormat=[r.MarkupKind.Markdown,r.MarkupKind.PlainText]}initialize(e,t){const n=this.getRegistrationOptions(t,e.hoverProvider);n&&this.register({id:s.generateUuid(),registerOptions:n})}registerLanguageProvider(e){const t=e.documentSelector,n={provideHover:(e,t,n)=>{const i=this._client,o=(e,t,n)=>i.sendRequest(r.HoverRequest.type,i.code2ProtocolConverter.asTextDocumentPositionParams(e,t),n).then((e=>n.isCancellationRequested?null:i.protocol2CodeConverter.asHover(e)),(e=>i.handleFailedRequest(r.HoverRequest.type,n,e,null))),s=i.middleware;return s.provideHover?s.provideHover(e,t,n,o):o(e,t,n)}};return[this.registerProvider(t,n),n]}registerProvider(e,t){return i.languages.registerHoverProvider(this._client.protocol2CodeConverter.asDocumentSelector(e),t)}}t.HoverFeature=a},9889:(e,t,n)=>{"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.ImplementationFeature=void 0;const i=n(9496),r=n(152),o=n(8909);class s extends o.TextDocumentLanguageFeature{constructor(e){super(e,r.ImplementationRequest.type)}fillClientCapabilities(e){let t=(0,o.ensure)((0,o.ensure)(e,"textDocument"),"implementation");t.dynamicRegistration=!0,t.linkSupport=!0}initialize(e,t){let[n,i]=this.getRegistration(t,e.implementationProvider);n&&i&&this.register({id:n,registerOptions:i})}registerLanguageProvider(e){const t=e.documentSelector,n={provideImplementation:(e,t,n)=>{const i=this._client,o=(e,t,n)=>i.sendRequest(r.ImplementationRequest.type,i.code2ProtocolConverter.asTextDocumentPositionParams(e,t),n).then((e=>n.isCancellationRequested?null:i.protocol2CodeConverter.asDefinitionResult(e,n)),(e=>i.handleFailedRequest(r.ImplementationRequest.type,n,e,null))),s=i.middleware;return s.provideImplementation?s.provideImplementation(e,t,n,o):o(e,t,n)}};return[this.registerProvider(t,n),n]}registerProvider(e,t){return i.languages.registerImplementationProvider(this._client.protocol2CodeConverter.asDocumentSelector(e),t)}}t.ImplementationFeature=s},6190:(e,t,n)=>{"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.InlayHintsFeature=void 0;const i=n(9496),r=n(152),o=n(8909);class s extends o.TextDocumentLanguageFeature{constructor(e){super(e,r.InlayHintRequest.type)}fillClientCapabilities(e){const t=(0,o.ensure)((0,o.ensure)(e,"textDocument"),"inlayHint");t.dynamicRegistration=!0,t.resolveSupport={properties:["tooltip","textEdits","label.tooltip","label.location","label.command"]},(0,o.ensure)((0,o.ensure)(e,"workspace"),"inlayHint").refreshSupport=!0}initialize(e,t){this._client.onRequest(r.InlayHintRefreshRequest.type,(async()=>{for(const e of this.getAllProviders())e.onDidChangeInlayHints.fire()}));const[n,i]=this.getRegistration(t,e.inlayHintProvider);n&&i&&this.register({id:n,registerOptions:i})}registerLanguageProvider(e){const t=e.documentSelector,n=new i.EventEmitter,o={onDidChangeInlayHints:n.event,provideInlayHints:(e,t,n)=>{const i=this._client,o=async(e,t,n)=>{const o={textDocument:i.code2ProtocolConverter.asTextDocumentIdentifier(e),range:i.code2ProtocolConverter.asRange(t)};try{const e=await i.sendRequest(r.InlayHintRequest.type,o,n);return n.isCancellationRequested?null:i.protocol2CodeConverter.asInlayHints(e,n)}catch(e){return i.handleFailedRequest(r.InlayHintRequest.type,n,e,null)}},s=i.middleware;return s.provideInlayHints?s.provideInlayHints(e,t,n,o):o(e,t,n)}};return o.resolveInlayHint=!0===e.resolveProvider?(e,t)=>{const n=this._client,i=async(e,t)=>{try{const i=await n.sendRequest(r.InlayHintResolveRequest.type,n.code2ProtocolConverter.asInlayHint(e),t);if(t.isCancellationRequested)return null;const o=n.protocol2CodeConverter.asInlayHint(i,t);return t.isCancellationRequested?null:o}catch(e){return n.handleFailedRequest(r.InlayHintResolveRequest.type,t,e,null)}},o=n.middleware;return o.resolveInlayHint?o.resolveInlayHint(e,t,i):i(e,t)}:void 0,[this.registerProvider(t,o),{provider:o,onDidChangeInlayHints:n}]}registerProvider(e,t){return i.languages.registerInlayHintsProvider(this._client.protocol2CodeConverter.asDocumentSelector(e),t)}}t.InlayHintsFeature=s},5098:(e,t,n)=>{"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.InlineValueFeature=void 0;const i=n(9496),r=n(152),o=n(8909);class s extends o.TextDocumentLanguageFeature{constructor(e){super(e,r.InlineValueRequest.type)}fillClientCapabilities(e){(0,o.ensure)((0,o.ensure)(e,"textDocument"),"inlineValue").dynamicRegistration=!0,(0,o.ensure)((0,o.ensure)(e,"workspace"),"inlineValue").refreshSupport=!0}initialize(e,t){this._client.onRequest(r.InlineValueRefreshRequest.type,(async()=>{for(const e of this.getAllProviders())e.onDidChangeInlineValues.fire()}));const[n,i]=this.getRegistration(t,e.inlineValueProvider);n&&i&&this.register({id:n,registerOptions:i})}registerLanguageProvider(e){const t=e.documentSelector,n=new i.EventEmitter,o={onDidChangeInlineValues:n.event,provideInlineValues:(e,t,n,i)=>{const o=this._client,s=(e,t,n,i)=>{const s={textDocument:o.code2ProtocolConverter.asTextDocumentIdentifier(e),range:o.code2ProtocolConverter.asRange(t),context:o.code2ProtocolConverter.asInlineValueContext(n)};return o.sendRequest(r.InlineValueRequest.type,s,i).then((e=>i.isCancellationRequested?null:o.protocol2CodeConverter.asInlineValues(e,i)),(e=>o.handleFailedRequest(r.InlineValueRequest.type,i,e,null)))},a=o.middleware;return a.provideInlineValues?a.provideInlineValues(e,t,n,i,s):s(e,t,n,i)}};return[this.registerProvider(t,o),{provider:o,onDidChangeInlineValues:n}]}registerProvider(e,t){return i.languages.registerInlineValuesProvider(this._client.protocol2CodeConverter.asDocumentSelector(e),t)}}t.InlineValueFeature=s},3483:(e,t,n)=>{"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.LinkedEditingFeature=void 0;const i=n(9496),r=n(152),o=n(8909);class s extends o.TextDocumentLanguageFeature{constructor(e){super(e,r.LinkedEditingRangeRequest.type)}fillClientCapabilities(e){(0,o.ensure)((0,o.ensure)(e,"textDocument"),"linkedEditingRange").dynamicRegistration=!0}initialize(e,t){let[n,i]=this.getRegistration(t,e.linkedEditingRangeProvider);n&&i&&this.register({id:n,registerOptions:i})}registerLanguageProvider(e){const t=e.documentSelector,n={provideLinkedEditingRanges:(e,t,n)=>{const i=this._client,o=(e,t,n)=>i.sendRequest(r.LinkedEditingRangeRequest.type,i.code2ProtocolConverter.asTextDocumentPositionParams(e,t),n).then((e=>n.isCancellationRequested?null:i.protocol2CodeConverter.asLinkedEditingRanges(e,n)),(e=>i.handleFailedRequest(r.LinkedEditingRangeRequest.type,n,e,null))),s=i.middleware;return s.provideLinkedEditingRange?s.provideLinkedEditingRange(e,t,n,o):o(e,t,n)}};return[this.registerProvider(t,n),n]}registerProvider(e,t){return i.languages.registerLinkedEditingRangeProvider(this._client.protocol2CodeConverter.asDocumentSelector(e),t)}}t.LinkedEditingFeature=s},203:(e,t,n)=>{"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.NotebookDocumentSyncFeature=void 0;const i=n(9496),r=n(1171),o=n(152),s=n(1980),a=n(9763);function c(e,t){return void 0===e[t]&&(e[t]={}),e[t]}var u,l,d,f,p;!function(e){let t;!function(t){function n(e,t){return e.map((e=>s(e,t)))}function r(e){return c(new Set,e)}function s(e,t){const n=o.NotebookCell.create(function(e){switch(e){case i.NotebookCellKind.Markup:return o.NotebookCellKind.Markup;case i.NotebookCellKind.Code:return o.NotebookCellKind.Code}}(e.kind),t.asUri(e.document.uri));return Object.keys(e.metadata).length>0&&(n.metadata=r(e.metadata)),void 0!==e.executionSummary&&a.number(e.executionSummary.executionOrder)&&a.boolean(e.executionSummary.success)&&(n.executionSummary={executionOrder:e.executionSummary.executionOrder,success:e.executionSummary.success}),n}function c(e,t){if(e.has(t))throw new Error("Can't deep copy cyclic structures.");if(Array.isArray(t)){const n=[];for(const i of t)if(null!==i&&"object"==typeof i||Array.isArray(i))n.push(c(e,i));else{if(i instanceof RegExp)throw new Error("Can't transfer regular expressions to the server");n.push(i)}return n}{const n=Object.keys(t),i=Object.create(null);for(const r of n){const n=t[r];if(null!==n&&"object"==typeof n||Array.isArray(n))i[r]=c(e,n);else{if(n instanceof RegExp)throw new Error("Can't transfer regular expressions to the server");i[r]=n}}return i}}t.asVersionedNotebookDocumentIdentifier=function(e,t){return{version:e.version,uri:t.asUri(e.uri)}},t.asNotebookDocument=function(e,t,i){const s=o.NotebookDocument.create(i.asUri(e.uri),e.notebookType,e.version,n(t,i));return Object.keys(e.metadata).length>0&&(s.metadata=r(e.metadata)),s},t.asNotebookCells=n,t.asMetadata=r,t.asNotebookCell=s,t.asTextContentChange=function(e,t){const n=t.asChangeTextDocumentParams(e,e.document.uri,e.document.version);return{document:n.textDocument,changes:n.contentChanges}},t.asNotebookDocumentChangeEvent=function(t,n){const i=Object.create(null);if(t.metadata&&(i.metadata=e.c2p.asMetadata(t.metadata)),void 0!==t.cells){const r=Object.create(null),o=t.cells;o.structure&&(r.structure={array:{start:o.structure.array.start,deleteCount:o.structure.array.deleteCount,cells:void 0!==o.structure.array.cells?o.structure.array.cells.map((t=>e.c2p.asNotebookCell(t,n))):void 0},didOpen:void 0!==o.structure.didOpen?o.structure.didOpen.map((e=>n.asOpenTextDocumentParams(e.document).textDocument)):void 0,didClose:void 0!==o.structure.didClose?o.structure.didClose.map((e=>n.asCloseTextDocumentParams(e.document).textDocument)):void 0}),void 0!==o.data&&(r.data=o.data.map((t=>e.c2p.asNotebookCell(t,n)))),void 0!==o.textContent&&(r.textContent=o.textContent.map((t=>e.c2p.asTextContentChange(t,n)))),Object.keys(r).length>0&&(i.cells=r)}return i}}(t=e.c2p||(e.c2p={}))}(u||(u={})),function(e){function t(e,t,i=!0){return!(e.kind!==t.kind||e.document.uri.toString()!==t.document.uri.toString()||e.document.languageId!==t.document.languageId||!function(e,t){return e===t||void 0!==e&&void 0!==t&&(e.executionOrder===t.executionOrder&&e.success===t.success&&function(e,t){return e===t||void 0!==e&&void 0!==t&&(e.startTime===t.startTime&&e.endTime===t.endTime)}(e.timing,t.timing))}(e.executionSummary,t.executionSummary))&&(!i||i&&n(e.metadata,t.metadata))}function n(e,t){if(e===t)return!0;if(null==e||null==t)return!1;if(typeof e!=typeof t)return!1;if("object"!=typeof e)return!1;const r=Array.isArray(e),o=Array.isArray(t);if(r!==o)return!1;if(r&&o){if(e.length!==t.length)return!1;for(let i=0;i=0&&c>=0&&t(e[a],n[c],i);)a--,c--;const u=a+1-s,l=s===c+1?void 0:n.slice(s,c+1);return void 0!==l?{start:s,deleteCount:u,cells:l}:{start:s,deleteCount:u}}return se.document.uri.toString())))}}}(p||(p={}));class g{constructor(e,t){this.client=e,this.options=t,this.notebookSyncInfo=new Map,this.notebookDidOpen=new Set,this.disposables=[],this.selector=e.protocol2CodeConverter.asDocumentSelector(f.asDocumentSelector(t)),i.workspace.onDidOpenNotebookDocument((e=>{this.notebookDidOpen.add(e.uri.toString()),this.didOpen(e)}),void 0,this.disposables);for(const e of i.workspace.notebookDocuments)this.notebookDidOpen.add(e.uri.toString()),this.didOpen(e);i.workspace.onDidChangeNotebookDocument((e=>this.didChangeNotebookDocument(e)),void 0,this.disposables),!0===this.options.save&&i.workspace.onDidSaveNotebookDocument((e=>this.didSave(e)),void 0,this.disposables),i.workspace.onDidCloseNotebookDocument((e=>{this.didClose(e),this.notebookDidOpen.delete(e.uri.toString())}),void 0,this.disposables)}getState(){for(const e of i.workspace.notebookDocuments)if(void 0!==this.getMatchingCells(e))return{kind:"document",id:"$internal",registrations:!0,matches:!0};return{kind:"document",id:"$internal",registrations:!0,matches:!1}}get mode(){return"notebook"}handles(e){return i.languages.match(this.selector,e)>0}didOpenNotebookCellTextDocument(e,t){if(0===i.languages.match(this.selector,t.document))return;if(!this.notebookDidOpen.has(e.uri.toString()))return;const n=this.notebookSyncInfo.get(e.uri.toString()),r=this.cellMatches(e,t);if(void 0!==n){const i=n.uris.has(t.document.uri.toString());if(r&&i||!r&&!i)return;if(r){const t=this.getMatchingCells(e);if(void 0!==t){const i=this.asNotebookDocumentChangeEvent(e,void 0,n,t);void 0!==i&&this.doSendChange(i,t).catch((()=>{}))}}}else r&&this.doSendOpen(e,[t]).catch((()=>{}))}didChangeNotebookCellTextDocument(e,t){0!==i.languages.match(this.selector,t.document)&&this.doSendChange({notebook:e,cells:{textContent:[t]}},void 0).catch((()=>{}))}didCloseNotebookCellTextDocument(e,t){const n=this.notebookSyncInfo.get(e.uri.toString());if(void 0===n)return;const i=t.document.uri,r=n.cells.findIndex((e=>e.document.uri.toString()===i.toString()));if(-1!==r)if(0===r&&1===n.cells.length)this.doSendClose(e,n.cells).catch((()=>{}));else{const t=n.cells.slice(),i=t.splice(r,1);this.doSendChange({notebook:e,cells:{structure:{array:{start:r,deleteCount:1},didClose:i}}},t).catch((()=>{}))}}dispose(){for(const e of this.disposables)e.dispose()}didOpen(e,t=this.getMatchingCells(e),n=this.notebookSyncInfo.get(e.uri.toString())){if(void 0!==n)if(void 0!==t){const i=this.asNotebookDocumentChangeEvent(e,void 0,n,t);void 0!==i&&this.doSendChange(i,t).catch((()=>{}))}else this.doSendClose(e,[]).catch((()=>{}));else{if(void 0===t)return;this.doSendOpen(e,t).catch((()=>{}))}}didChangeNotebookDocument(e){const t=e.notebook,n=this.notebookSyncInfo.get(t.uri.toString());if(void 0===n){if(0===e.contentChanges.length)return;const i=this.getMatchingCells(t);if(void 0===i)return;this.didOpen(t,i,n)}else{const i=this.getMatchingCells(t);if(void 0===i)return void this.didClose(t,n);const r=this.asNotebookDocumentChangeEvent(e.notebook,e,n,i);void 0!==r&&this.doSendChange(r,i).catch((()=>{}))}}didSave(e){void 0!==this.notebookSyncInfo.get(e.uri.toString())&&this.doSendSave(e).catch((()=>{}))}didClose(e,t=this.notebookSyncInfo.get(e.uri.toString())){if(void 0===t)return;const n=e.getCells().filter((e=>t.uris.has(e.document.uri.toString())));this.doSendClose(e,n).catch((()=>{}))}async sendDidOpenNotebookDocument(e){const t=this.getMatchingCells(e);if(void 0!==t)return this.doSendOpen(e,t)}async doSendOpen(e,t){const n=async(e,t)=>{const n=u.c2p.asNotebookDocument(e,t,this.client.code2ProtocolConverter),i=t.map((e=>this.client.code2ProtocolConverter.asTextDocumentItem(e.document)));try{await this.client.sendNotification(o.DidOpenNotebookDocumentNotification.type,{notebookDocument:n,cellTextDocuments:i})}catch(e){throw this.client.error("Sending DidOpenNotebookDocumentNotification failed",e),e}},i=this.client.middleware?.notebooks;return this.notebookSyncInfo.set(e.uri.toString(),p.create(t)),void 0!==i?.didOpen?i.didOpen(e,t,n):n(e,t)}async sendDidChangeNotebookDocument(e){return this.doSendChange(e,void 0)}async doSendChange(e,t=this.getMatchingCells(e.notebook)){const n=async e=>{try{await this.client.sendNotification(o.DidChangeNotebookDocumentNotification.type,{notebookDocument:u.c2p.asVersionedNotebookDocumentIdentifier(e.notebook,this.client.code2ProtocolConverter),change:u.c2p.asNotebookDocumentChangeEvent(e,this.client.code2ProtocolConverter)})}catch(e){throw this.client.error("Sending DidChangeNotebookDocumentNotification failed",e),e}},i=this.client.middleware?.notebooks;return void 0!==e.cells?.structure&&this.notebookSyncInfo.set(e.notebook.uri.toString(),p.create(t??[])),void 0!==i?.didChange?i?.didChange(e,n):n(e)}async sendDidSaveNotebookDocument(e){return this.doSendSave(e)}async doSendSave(e){const t=async e=>{try{await this.client.sendNotification(o.DidSaveNotebookDocumentNotification.type,{notebookDocument:{uri:this.client.code2ProtocolConverter.asUri(e.uri)}})}catch(e){throw this.client.error("Sending DidSaveNotebookDocumentNotification failed",e),e}},n=this.client.middleware?.notebooks;return void 0!==n?.didSave?n.didSave(e,t):t(e)}async sendDidCloseNotebookDocument(e){return this.doSendClose(e,this.getMatchingCells(e)??[])}async doSendClose(e,t){const n=async(e,t)=>{try{await this.client.sendNotification(o.DidCloseNotebookDocumentNotification.type,{notebookDocument:{uri:this.client.code2ProtocolConverter.asUri(e.uri)},cellTextDocuments:t.map((e=>this.client.code2ProtocolConverter.asTextDocumentIdentifier(e.document)))})}catch(e){throw this.client.error("Sending DidCloseNotebookDocumentNotification failed",e),e}},i=this.client.middleware?.notebooks;return this.notebookSyncInfo.delete(e.uri.toString()),void 0!==i?.didClose?i.didClose(e,t,n):n(e,t)}asNotebookDocumentChangeEvent(e,t,n,i){if(void 0!==t&&t.notebook!==e)throw new Error("Notebook must be identical");const r={notebook:e};let o;if(void 0!==t?.metadata&&(r.metadata=u.c2p.asMetadata(t.metadata)),void 0!==t?.cellChanges&&t.cellChanges.length>0){const e=[];o=new Set(i.map((e=>e.document.uri.toString())));for(const n of t.cellChanges)!o.has(n.cell.document.uri.toString())||void 0===n.executionSummary&&void 0===n.metadata||e.push(n.cell);e.length>0&&(r.cells=r.cells??{},r.cells.data=e)}if((void 0!==t?.contentChanges&&t.contentChanges.length>0||void 0===t)&&void 0!==n&&void 0!==i){const e=n.cells,t=i,o=l.computeDiff(e,t,!1);let s,a;if(void 0!==o){s=void 0===o.cells?new Map:new Map(o.cells.map((e=>[e.document.uri.toString(),e]))),a=0===o.deleteCount?new Map:new Map(e.slice(o.start,o.start+o.deleteCount).map((e=>[e.document.uri.toString(),e])));for(const e of Array.from(a.keys()))s.has(e)&&(a.delete(e),s.delete(e));r.cells=r.cells??{};const t=[],n=[];if(s.size>0||a.size>0){for(const e of s.values())t.push(e);for(const e of a.values())n.push(e)}r.cells.structure={array:o,didOpen:t,didClose:n}}}return Object.keys(r).length>1?r:void 0}getMatchingCells(e,t=e.getCells()){if(void 0!==this.options.notebookSelector)for(const n of this.options.notebookSelector)if(void 0===n.notebook||d.matchNotebook(n.notebook,e)){const i=this.filterCells(e,t,n.cells);return 0===i.length?void 0:i}}cellMatches(e,t){const n=this.getMatchingCells(e,[t]);return void 0!==n&&n[0]===t}filterCells(e,t,n){const i=void 0!==n?t.filter((e=>{const t=e.document.languageId;return n.some((e=>"*"===e.language||t===e.language))})):t;return"function"==typeof this.client.clientOptions.notebookDocumentOptions?.filterCells?this.client.clientOptions.notebookDocumentOptions.filterCells(e,i):i}}class h{constructor(e){this.client=e,this.registrations=new Map,this.registrationType=o.NotebookDocumentSyncRegistrationType.type,i.workspace.onDidOpenTextDocument((e=>{if(e.uri.scheme!==h.CellScheme)return;const[t,n]=this.findNotebookDocumentAndCell(e);if(void 0!==t&&void 0!==n)for(const e of this.registrations.values())e instanceof g&&e.didOpenNotebookCellTextDocument(t,n)})),i.workspace.onDidChangeTextDocument((e=>{if(0===e.contentChanges.length)return;const t=e.document;if(t.uri.scheme!==h.CellScheme)return;const[n]=this.findNotebookDocumentAndCell(t);if(void 0!==n)for(const t of this.registrations.values())t instanceof g&&t.didChangeNotebookCellTextDocument(n,e)})),i.workspace.onDidCloseTextDocument((e=>{if(e.uri.scheme!==h.CellScheme)return;const[t,n]=this.findNotebookDocumentAndCell(e);if(void 0!==t&&void 0!==n)for(const e of this.registrations.values())e instanceof g&&e.didCloseNotebookCellTextDocument(t,n)}))}getState(){if(0===this.registrations.size)return{kind:"document",id:this.registrationType.method,registrations:!1,matches:!1};for(const e of this.registrations.values()){const t=e.getState();if("document"===t.kind&&!0===t.registrations&&!0===t.matches)return{kind:"document",id:this.registrationType.method,registrations:!0,matches:!0}}return{kind:"document",id:this.registrationType.method,registrations:!0,matches:!1}}fillClientCapabilities(e){const t=c(c(e,"notebookDocument"),"synchronization");t.dynamicRegistration=!0,t.executionSummarySupport=!0}preInitialize(e){const t=e.notebookDocumentSync;void 0!==t&&(this.dedicatedChannel=this.client.protocol2CodeConverter.asDocumentSelector(f.asDocumentSelector(t)))}initialize(e){const t=e.notebookDocumentSync;if(void 0===t)return;const n=t.id??s.generateUuid();this.register({id:n,registerOptions:t})}register(e){const t=new g(this.client,e.registerOptions);this.registrations.set(e.id,t)}unregister(e){const t=this.registrations.get(e);t&&t.dispose()}dispose(){for(const e of this.registrations.values())e.dispose();this.registrations.clear()}handles(e){if(e.uri.scheme!==h.CellScheme)return!1;if(void 0!==this.dedicatedChannel&&i.languages.match(this.dedicatedChannel,e)>0)return!0;for(const t of this.registrations.values())if(t.handles(e))return!0;return!1}getProvider(e){for(const t of this.registrations.values())if(t.handles(e.document))return t}findNotebookDocumentAndCell(e){const t=e.uri.toString();for(const e of i.workspace.notebookDocuments)for(const n of e.getCells())if(n.document.uri.toString()===t)return[e,n];return[void 0,void 0]}}t.NotebookDocumentSyncFeature=h,h.CellScheme="vscode-notebook-cell"},3603:(e,t,n)=>{"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.ProgressFeature=void 0;const i=n(152),r=n(8071);t.ProgressFeature=class{constructor(e){this._client=e,this.activeParts=new Set}getState(){return{kind:"window",id:i.WorkDoneProgressCreateRequest.method,registrations:this.activeParts.size>0}}fillClientCapabilities(e){var t,n;(t=e,n="window",void 0===t[n]&&(t[n]=Object.create(null)),t[n]).workDoneProgress=!0}initialize(){const e=this._client,t=e=>{this.activeParts.delete(e)};e.onRequest(i.WorkDoneProgressCreateRequest.type,(e=>{this.activeParts.add(new r.ProgressPart(this._client,e.token,t))}))}dispose(){for(const e of this.activeParts)e.done();this.activeParts.clear()}}},8071:(e,t,n)=>{"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.ProgressPart=void 0;const i=n(9496),r=n(152),o=n(9763);t.ProgressPart=class{constructor(e,t,n){this._client=e,this._token=t,this._reported=0,this._infinite=!1,this._lspProgressDisposable=this._client.onProgress(r.WorkDoneProgress.type,this._token,(e=>{switch(e.kind){case"begin":this.begin(e);break;case"report":this.report(e);break;case"end":this.done(),n&&n(this)}}))}begin(e){this._infinite=void 0===e.percentage,void 0!==this._lspProgressDisposable&&i.window.withProgress({location:i.ProgressLocation.Window,cancellable:e.cancellable,title:e.title},(async(t,n)=>{if(void 0!==this._lspProgressDisposable)return this._progress=t,this._cancellationToken=n,this._tokenDisposable=this._cancellationToken.onCancellationRequested((()=>{this._client.sendNotification(r.WorkDoneProgressCancelNotification.type,{token:this._token})})),this.report(e),new Promise(((e,t)=>{this._resolve=e,this._reject=t}))}))}report(e){if(this._infinite&&o.string(e.message))void 0!==this._progress&&this._progress.report({message:e.message});else if(o.number(e.percentage)){const t=Math.max(0,Math.min(e.percentage,100)),n=Math.max(0,t-this._reported);this._reported+=n,void 0!==this._progress&&this._progress.report({message:e.message,increment:n})}}cancel(){this.cleanup(),void 0!==this._reject&&(this._reject(),this._resolve=void 0,this._reject=void 0)}done(){this.cleanup(),void 0!==this._resolve&&(this._resolve(),this._resolve=void 0,this._reject=void 0)}cleanup(){void 0!==this._lspProgressDisposable&&(this._lspProgressDisposable.dispose(),this._lspProgressDisposable=void 0),void 0!==this._tokenDisposable&&(this._tokenDisposable.dispose(),this._tokenDisposable=void 0),this._progress=void 0,this._cancellationToken=void 0}}},8714:(e,t,n)=>{"use strict";Object.defineProperty(t,"__esModule",{value:!0});const i=n(9496);class r extends i.CallHierarchyItem{constructor(e,t,n,i,r,o,s){super(e,t,n,i,r,o),void 0!==s&&(this.data=s)}}t.default=r},6434:(e,t,n)=>{"use strict";Object.defineProperty(t,"__esModule",{value:!0});const i=n(9496);class r extends i.CodeAction{constructor(e,t){super(e),this.data=t}}t.default=r},583:(e,t,n)=>{"use strict";Object.defineProperty(t,"__esModule",{value:!0});const i=n(9496);class r extends i.CodeLens{constructor(e){super(e)}}t.default=r},1807:(e,t,n)=>{"use strict";Object.defineProperty(t,"__esModule",{value:!0});const i=n(9496);class r extends i.CompletionItem{constructor(e){super(e)}}t.default=r},8785:(e,t,n)=>{"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.createConverter=void 0;const i=n(9496),r=n(152),o=n(9763),s=n(4904),a=n(1807),c=n(583),u=n(8705),l=n(6434),d=n(5316),f=n(8714),p=n(1365),g=n(3912),h=n(1065),m=n(152);var v;!function(e){e.is=function(e){let t=e;return t&&o.string(t.language)&&o.string(t.value)}}(v||(v={})),t.createConverter=function(e,t,n){const y=e||(e=>i.Uri.parse(e));function S(e){return y(e)}function C(e){let t=new d.ProtocolDiagnostic(_(e.range),e.message,D(e.severity),e.data);if(void 0!==e.code)if("string"==typeof e.code||"number"==typeof e.code)r.CodeDescription.is(e.codeDescription)?t.code={value:e.code,target:S(e.codeDescription.href)}:t.code=e.code;else if(d.DiagnosticCode.is(e.code)){t.hasDiagnosticCode=!0;const n=e.code;t.code={value:n.value,target:S(n.target)}}return e.source&&(t.source=e.source),e.relatedInformation&&(t.relatedInformation=function(e){const t=new Array(e.length);for(let n=0;n0?t:void 0}(e.tags)),t}function T(e){switch(e){case r.DiagnosticTag.Unnecessary:return i.DiagnosticTag.Unnecessary;case r.DiagnosticTag.Deprecated:return i.DiagnosticTag.Deprecated;default:return}}function b(e){return e?new i.Position(e.line,e.character):void 0}function _(e){return e?new i.Range(e.start.line,e.start.character,e.end.line,e.end.character):void 0}async function R(e,t){return s.map(e,(e=>new i.Range(e.start.line,e.start.character,e.end.line,e.end.character)),t)}function D(e){if(null==e)return i.DiagnosticSeverity.Error;switch(e){case r.DiagnosticSeverity.Error:return i.DiagnosticSeverity.Error;case r.DiagnosticSeverity.Warning:return i.DiagnosticSeverity.Warning;case r.DiagnosticSeverity.Information:return i.DiagnosticSeverity.Information;case r.DiagnosticSeverity.Hint:return i.DiagnosticSeverity.Hint}return i.DiagnosticSeverity.Error}function w(e){if(o.string(e))return e;switch(e.kind){case r.MarkupKind.Markdown:return E(e.value);case r.MarkupKind.PlainText:return e.value;default:return`Unsupported Markup content received. Kind is: ${e.kind}`}}function E(e){let o;if(void 0===e||"string"==typeof e)o=new i.MarkdownString(e);else switch(e.kind){case r.MarkupKind.Markdown:o=new i.MarkdownString(e.value);break;case r.MarkupKind.PlainText:o=new i.MarkdownString,o.appendText(e.value);break;default:o=new i.MarkdownString,o.appendText(`Unsupported Markup content received. Kind is: ${e.kind}`)}return o.isTrusted=t,o.supportHtml=n,o}function P(e){if(e===r.CompletionItemTag.Deprecated)return i.CompletionItemTag.Deprecated}function k(e,t,n,s,c,u){const l=function(e){if(null==e)return[];const t=[];for(const n of e){const e=P(n);void 0!==e&&t.push(e)}return t}(e.tags),d=function(e){return r.CompletionItemLabelDetails.is(e.labelDetails)?{label:e.label,detail:e.labelDetails.detail,description:e.labelDetails.description}:e.label}(e),f=new a.default(d);e.detail&&(f.detail=e.detail),e.documentation&&(f.documentation=w(e.documentation),f.documentationFormat=o.string(e.documentation)?"$string":e.documentation.kind),e.filterText&&(f.filterText=e.filterText);const p=function(e,t,n){const o=e.insertTextFormat??n;if(void 0!==e.textEdit||void 0!==t){const[n,a]=void 0!==e.textEdit?(s=e.textEdit,r.InsertReplaceEdit.is(s)?[{inserting:_(s.insert),replacing:_(s.replace)},s.newText]:[_(s.range),s.newText]):[t,e.textEditText??e.label];return o===r.InsertTextFormat.Snippet?{text:new i.SnippetString(a),range:n,fromEdit:!0}:{text:a,range:n,fromEdit:!0}}return e.insertText?o===r.InsertTextFormat.Snippet?{text:new i.SnippetString(e.insertText),fromEdit:!1}:{text:e.insertText,fromEdit:!1}:void 0;var s}(e,n,c);if(p&&(f.insertText=p.text,f.range=p.range,f.fromEdit=p.fromEdit),o.number(e.kind)){let[t,n]=(g=e.kind,r.CompletionItemKind.Text<=g&&g<=r.CompletionItemKind.TypeParameter?[g-1,void 0]:[i.CompletionItemKind.Text,g]);f.kind=t,n&&(f.originalItemKind=n)}var g;e.sortText&&(f.sortText=e.sortText),e.additionalTextEdits&&(f.additionalTextEdits=O(e.additionalTextEdits));const h=void 0!==e.commitCharacters?o.stringArray(e.commitCharacters)?e.commitCharacters:void 0:t;h&&(f.commitCharacters=h.slice()),e.command&&(f.command=G(e.command)),!0!==e.deprecated&&!1!==e.deprecated||(f.deprecated=e.deprecated,!0===e.deprecated&&l.push(i.CompletionItemTag.Deprecated)),!0!==e.preselect&&!1!==e.preselect||(f.preselect=e.preselect);const m=e.data??u;void 0!==m&&(f.data=m),l.length>0&&(f.tags=l);const v=e.insertTextMode??s;return void 0!==v&&(f.insertTextMode=v,v===r.InsertTextMode.asIs&&(f.keepWhitespace=!0)),f}function x(e){if(e)return new i.TextEdit(_(e.range),e.newText)}async function N(e,t){if(e)return s.map(e,x,t)}function O(e){if(!e)return;const t=new Array(e.length);for(let n=0;n0){let n=[];for(let t of e.children)n.push(B(t));t.children=n}return t}function $(e,t){e.tags=z(t.tags),t.deprecated&&(e.tags?e.tags.includes(i.SymbolTag.Deprecated)||(e.tags=e.tags.concat(i.SymbolTag.Deprecated)):e.tags=[i.SymbolTag.Deprecated])}function G(e){let t={title:e.title,command:e.command};return e.arguments&&(t.arguments=e.arguments),t}const J=new Map;function Y(e){if(null==e)return;let t=J.get(e);if(t)return t;let n=e.split(".");t=i.CodeActionKind.Empty;for(let e of n)t=t.append(e);return t}async function Z(e,t){if(null==e)return;let n=new l.default(e.title,e.data);return void 0!==e.kind&&(n.kind=Y(e.kind)),void 0!==e.diagnostics&&(n.diagnostics=function(e){const t=new Array(e.length);for(let n=0;n{const t=function(e){if(void 0!==e)return{label:e.label,needsConfirmation:!!e.needsConfirmation,description:e.description}}(i[e]);n.set(e,t)}),t)}const o=e=>void 0===e?void 0:n.get(e),a=new i.WorkspaceEdit;if(e.documentChanges){const n=e.documentChanges;await s.forEach(n,(e=>{if(r.CreateFile.is(e))a.createFile(y(e.uri),e.options,o(e.annotationId));else if(r.RenameFile.is(e))a.renameFile(y(e.oldUri),y(e.newUri),e.options,o(e.annotationId));else if(r.DeleteFile.is(e))a.deleteFile(y(e.uri),e.options,o(e.annotationId));else{if(!r.TextDocumentEdit.is(e))throw new Error(`Unknown workspace edit change received:\n${JSON.stringify(e,void 0,4)}`);{const t=y(e.textDocument.uri);for(const n of e.edits)r.AnnotatedTextEdit.is(n)?a.replace(t,_(n.range),n.newText,o(n.annotationId)):a.replace(t,_(n.range),n.newText)}}}),t)}else if(e.changes){const n=e.changes;await s.forEach(Object.keys(n),(e=>{a.set(y(e),O(n[e]))}),t)}return a}function ee(e){let t=_(e.range),n=e.target?S(e.target):void 0,i=new u.default(t,n);return void 0!==e.tooltip&&(i.tooltip=e.tooltip),void 0!==e.data&&null!==e.data&&(i.data=e.data),i}function te(e){return new i.Color(e.red,e.green,e.blue,e.alpha)}function ne(e){return new i.ColorInformation(_(e.range),te(e.color))}function ie(e){let t=new i.ColorPresentation(e.label);return t.additionalTextEdits=O(e.additionalTextEdits),e.textEdit&&(t.textEdit=x(e.textEdit)),t}function re(e){if(e)switch(e){case r.FoldingRangeKind.Comment:return i.FoldingRangeKind.Comment;case r.FoldingRangeKind.Imports:return i.FoldingRangeKind.Imports;case r.FoldingRangeKind.Region:return i.FoldingRangeKind.Region}}function oe(e){return new i.FoldingRange(e.startLine,e.endLine,re(e.kind))}function se(e){return new i.SelectionRange(_(e.range),e.parent?se(e.parent):void 0)}function ae(e){return r.InlineValueText.is(e)?new i.InlineValueText(_(e.range),e.text):r.InlineValueVariableLookup.is(e)?new i.InlineValueVariableLookup(_(e.range),e.variableName,e.caseSensitiveLookup):new i.InlineValueEvaluatableExpression(_(e.range),e.expression)}async function ce(e,t){const n="string"==typeof e.label?e.label:await s.map(e.label,ue,t),i=new h.default(b(e.position),n);return void 0!==e.kind&&(i.kind=e.kind),void 0!==e.textEdits&&(i.textEdits=await N(e.textEdits,t)),void 0!==e.tooltip&&(i.tooltip=le(e.tooltip)),void 0!==e.paddingLeft&&(i.paddingLeft=e.paddingLeft),void 0!==e.paddingRight&&(i.paddingRight=e.paddingRight),void 0!==e.data&&(i.data=e.data),i}function ue(e){const t=new i.InlayHintLabelPart(e.value);return void 0!==e.location&&(t.location=L(e.location)),void 0!==e.tooltip&&(t.tooltip=le(e.tooltip)),void 0!==e.command&&(t.command=G(e.command)),t}function le(e){return"string"==typeof e?e:E(e)}function de(e){if(null===e)return;const t=new f.default(K(e.kind),e.name,e.detail||"",S(e.uri),_(e.range),_(e.selectionRange),e.data);return void 0!==e.tags&&(t.tags=z(e.tags)),t}async function fe(e,t){return new i.CallHierarchyIncomingCall(de(e.from),await R(e.fromRanges,t))}async function pe(e,t){return new i.CallHierarchyOutgoingCall(de(e.to),await R(e.fromRanges,t))}function ge(e){return new i.SemanticTokensEdit(e.start,e.deleteCount,void 0!==e.data?new Uint32Array(e.data):void 0)}function he(e){if(null===e)return;let t=new p.default(K(e.kind),e.name,e.detail||"",S(e.uri),_(e.range),_(e.selectionRange),e.data);return void 0!==e.tags&&(t.tags=z(e.tags)),t}return J.set(r.CodeActionKind.Empty,i.CodeActionKind.Empty),J.set(r.CodeActionKind.QuickFix,i.CodeActionKind.QuickFix),J.set(r.CodeActionKind.Refactor,i.CodeActionKind.Refactor),J.set(r.CodeActionKind.RefactorExtract,i.CodeActionKind.RefactorExtract),J.set(r.CodeActionKind.RefactorInline,i.CodeActionKind.RefactorInline),J.set(r.CodeActionKind.RefactorRewrite,i.CodeActionKind.RefactorRewrite),J.set(r.CodeActionKind.Source,i.CodeActionKind.Source),J.set(r.CodeActionKind.SourceOrganizeImports,i.CodeActionKind.SourceOrganizeImports),{asUri:S,asDocumentSelector:function(e){const t=[];for(const n of e)if("string"==typeof n)t.push(n);else if(m.NotebookCellTextDocumentFilter.is(n))if("string"==typeof n.notebook)t.push({notebookType:n.notebook,language:n.language});else{const e=n.notebook.notebookType??"*";t.push({notebookType:e,scheme:n.notebook.scheme,pattern:n.notebook.pattern,language:n.language})}else m.TextDocumentFilter.is(n)&&t.push({language:n.language,scheme:n.scheme,pattern:n.pattern});return t},asDiagnostics:async function(e,t){return s.map(e,C,t)},asDiagnostic:C,asRange:_,asRanges:R,asPosition:b,asDiagnosticSeverity:D,asDiagnosticTag:T,asHover:function(e){if(e)return new i.Hover(function(e){if(o.string(e))return E(e);if(v.is(e))return E().appendCodeblock(e.value,e.language);if(Array.isArray(e)){let t=[];for(let n of e){let e=E();v.is(n)?e.appendCodeblock(n.value,n.language):e.appendMarkdown(n),t.push(e)}return t}return E(e)}(e.contents),_(e.range))},asCompletionResult:async function(e,t,n){if(!e)return;if(Array.isArray(e))return s.map(e,(e=>k(e,t)),n);const o=e,{defaultRange:a,commitCharacters:c}=function(e,t){const n=e.itemDefaults?.editRange,i=e.itemDefaults?.commitCharacters??t;return r.Range.is(n)?{defaultRange:_(n),commitCharacters:i}:void 0!==n?{defaultRange:{inserting:_(n.insert),replacing:_(n.replace)},commitCharacters:i}:{defaultRange:void 0,commitCharacters:i}}(o,t),u=await s.map(o.items,(e=>k(e,c,a,o.itemDefaults?.insertTextMode,o.itemDefaults?.insertTextFormat,o.itemDefaults?.data)),n);return new i.CompletionList(u,o.isIncomplete)},asCompletionItem:k,asTextEdit:x,asTextEdits:N,asSignatureHelp:async function(e,t){if(!e)return;let n=new i.SignatureHelp;return o.number(e.activeSignature)?n.activeSignature=e.activeSignature:n.activeSignature=0,o.number(e.activeParameter)?n.activeParameter=e.activeParameter:n.activeParameter=0,e.signatures&&(n.signatures=await I(e.signatures,t)),n},asSignatureInformations:I,asSignatureInformation:A,asParameterInformations:F,asParameterInformation:M,asDeclarationResult:async function(e,t){if(e)return j(e,t)},asDefinitionResult:async function(e,t){if(e)return j(e,t)},asLocation:L,asReferences:async function(e,t){if(e)return s.map(e,L,t)},asDocumentHighlights:async function(e,t){if(e)return s.map(e,U,t)},asDocumentHighlight:U,asDocumentHighlightKind:H,asSymbolKind:K,asSymbolTag:W,asSymbolTags:z,asSymbolInformations:async function(e,t){if(e)return s.map(e,V,t)},asSymbolInformation:V,asDocumentSymbols:async function(e,t){if(null!=e)return s.map(e,B,t)},asDocumentSymbol:B,asCommand:G,asCommands:async function(e,t){if(e)return s.map(e,G,t)},asCodeAction:Z,asCodeActionKind:Y,asCodeActionKinds:function(e){if(null!=e)return e.map((e=>Y(e)))},asCodeActionResult:function(e,t){return s.mapAsync(e,(async e=>r.Command.is(e)?G(e):Z(e,t)),t)},asCodeLens:X,asCodeLenses:async function(e,t){if(e)return s.map(e,X,t)},asWorkspaceEdit:Q,asDocumentLink:ee,asDocumentLinks:async function(e,t){if(e)return s.map(e,ee,t)},asFoldingRangeKind:re,asFoldingRange:oe,asFoldingRanges:async function(e,t){if(e)return s.map(e,oe,t)},asColor:te,asColorInformation:ne,asColorInformations:async function(e,t){if(e)return s.map(e,ne,t)},asColorPresentation:ie,asColorPresentations:async function(e,t){if(e)return s.map(e,ie,t)},asSelectionRange:se,asSelectionRanges:async function(e,t){return Array.isArray(e)?s.map(e,se,t):[]},asInlineValue:ae,asInlineValues:async function(e,t){return Array.isArray(e)?s.map(e,ae,t):[]},asInlayHint:ce,asInlayHints:async function(e,t){if(Array.isArray(e))return s.mapAsync(e,ce,t)},asSemanticTokensLegend:function(e){return e},asSemanticTokens:async function(e,t){if(null!=e)return new i.SemanticTokens(new Uint32Array(e.data),e.resultId)},asSemanticTokensEdit:ge,asSemanticTokensEdits:async function(e,t){if(null!=e)return new i.SemanticTokensEdits(e.edits.map(ge),e.resultId)},asCallHierarchyItem:de,asCallHierarchyItems:async function(e,t){if(null!==e)return s.map(e,de,t)},asCallHierarchyIncomingCall:fe,asCallHierarchyIncomingCalls:async function(e,t){if(null!==e)return s.mapAsync(e,fe,t)},asCallHierarchyOutgoingCall:pe,asCallHierarchyOutgoingCalls:async function(e,t){if(null!==e)return s.mapAsync(e,pe,t)},asLinkedEditingRanges:async function(e,t){if(null!=e)return new i.LinkedEditingRanges(await R(e.ranges,t),function(e){if(null!=e)return new RegExp(e)}(e.wordPattern))},asTypeHierarchyItem:he,asTypeHierarchyItems:async function(e,t){if(null!==e)return s.map(e,he,t)},asGlobPattern:function(e){if(o.string(e))return e;if(r.RelativePattern.is(e)){if(r.URI.is(e.baseUri))return new i.RelativePattern(S(e.baseUri),e.pattern);if(r.WorkspaceFolder.is(e.baseUri)){const t=i.workspace.getWorkspaceFolder(S(e.baseUri.uri));return void 0!==t?new i.RelativePattern(t,e.pattern):void 0}}}}}},5316:(e,t,n)=>{"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.ProtocolDiagnostic=t.DiagnosticCode=void 0;const i=n(9496),r=n(9763);(t.DiagnosticCode||(t.DiagnosticCode={})).is=function(e){const t=e;return null!=t&&(r.number(t.value)||r.string(t.value))&&r.string(t.target)};class o extends i.Diagnostic{constructor(e,t,n,i){super(e,t,n),this.data=i,this.hasDiagnosticCode=!1}}t.ProtocolDiagnostic=o},8705:(e,t,n)=>{"use strict";Object.defineProperty(t,"__esModule",{value:!0});const i=n(9496);class r extends i.DocumentLink{constructor(e,t){super(e,t)}}t.default=r},1065:(e,t,n)=>{"use strict";Object.defineProperty(t,"__esModule",{value:!0});const i=n(9496);class r extends i.InlayHint{constructor(e,t,n){super(e,t,n)}}t.default=r},1365:(e,t,n)=>{"use strict";Object.defineProperty(t,"__esModule",{value:!0});const i=n(9496);class r extends i.TypeHierarchyItem{constructor(e,t,n,i,r,o,s){super(e,t,n,i,r,o),void 0!==s&&(this.data=s)}}t.default=r},3912:(e,t,n)=>{"use strict";Object.defineProperty(t,"__esModule",{value:!0});const i=n(9496);class r extends i.SymbolInformation{constructor(e,t,n,r,o){const s=!(r instanceof i.Uri);super(e,t,n,s?r:new i.Location(r,new i.Range(0,0,0,0))),this.hasRange=s,void 0!==o&&(this.data=o)}}t.default=r},8480:(e,t,n)=>{"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.ReferencesFeature=void 0;const i=n(9496),r=n(152),o=n(8909),s=n(1980);class a extends o.TextDocumentLanguageFeature{constructor(e){super(e,r.ReferencesRequest.type)}fillClientCapabilities(e){(0,o.ensure)((0,o.ensure)(e,"textDocument"),"references").dynamicRegistration=!0}initialize(e,t){const n=this.getRegistrationOptions(t,e.referencesProvider);n&&this.register({id:s.generateUuid(),registerOptions:n})}registerLanguageProvider(e){const t=e.documentSelector,n={provideReferences:(e,t,n,i)=>{const o=this._client,s=(e,t,n,i)=>o.sendRequest(r.ReferencesRequest.type,o.code2ProtocolConverter.asReferenceParams(e,t,n),i).then((e=>i.isCancellationRequested?null:o.protocol2CodeConverter.asReferences(e,i)),(e=>o.handleFailedRequest(r.ReferencesRequest.type,i,e,null))),a=o.middleware;return a.provideReferences?a.provideReferences(e,t,n,i,s):s(e,t,n,i)}};return[this.registerProvider(t,n),n]}registerProvider(e,t){return i.languages.registerReferenceProvider(this._client.protocol2CodeConverter.asDocumentSelector(e),t)}}t.ReferencesFeature=a},6458:(e,t,n)=>{"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.RenameFeature=void 0;const i=n(9496),r=n(152),o=n(1980),s=n(9763),a=n(8909);class c extends a.TextDocumentLanguageFeature{constructor(e){super(e,r.RenameRequest.type)}fillClientCapabilities(e){let t=(0,a.ensure)((0,a.ensure)(e,"textDocument"),"rename");t.dynamicRegistration=!0,t.prepareSupport=!0,t.prepareSupportDefaultBehavior=r.PrepareSupportDefaultBehavior.Identifier,t.honorsChangeAnnotations=!0}initialize(e,t){const n=this.getRegistrationOptions(t,e.renameProvider);n&&(s.boolean(e.renameProvider)&&(n.prepareProvider=!1),this.register({id:o.generateUuid(),registerOptions:n}))}registerLanguageProvider(e){const t=e.documentSelector,n={provideRenameEdits:(e,t,n,i)=>{const o=this._client,s=(e,t,n,i)=>{let s={textDocument:o.code2ProtocolConverter.asTextDocumentIdentifier(e),position:o.code2ProtocolConverter.asPosition(t),newName:n};return o.sendRequest(r.RenameRequest.type,s,i).then((e=>i.isCancellationRequested?null:o.protocol2CodeConverter.asWorkspaceEdit(e,i)),(e=>o.handleFailedRequest(r.RenameRequest.type,i,e,null,!1)))},a=o.middleware;return a.provideRenameEdits?a.provideRenameEdits(e,t,n,i,s):s(e,t,n,i)},prepareRename:e.prepareProvider?(e,t,n)=>{const i=this._client,o=(e,t,n)=>{let o={textDocument:i.code2ProtocolConverter.asTextDocumentIdentifier(e),position:i.code2ProtocolConverter.asPosition(t)};return i.sendRequest(r.PrepareRenameRequest.type,o,n).then((e=>n.isCancellationRequested?null:r.Range.is(e)?i.protocol2CodeConverter.asRange(e):this.isDefaultBehavior(e)?!0===e.defaultBehavior?null:Promise.reject(new Error("The element can't be renamed.")):e&&r.Range.is(e.range)?{range:i.protocol2CodeConverter.asRange(e.range),placeholder:e.placeholder}:Promise.reject(new Error("The element can't be renamed."))),(e=>{throw"string"==typeof e.message?new Error(e.message):new Error("The element can't be renamed.")}))},s=i.middleware;return s.prepareRename?s.prepareRename(e,t,n,o):o(e,t,n)}:void 0};return[this.registerProvider(t,n),n]}registerProvider(e,t){return i.languages.registerRenameProvider(this._client.protocol2CodeConverter.asDocumentSelector(e),t)}isDefaultBehavior(e){const t=e;return t&&s.boolean(t.defaultBehavior)}}t.RenameFeature=c},750:(e,t,n)=>{"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.SelectionRangeFeature=void 0;const i=n(9496),r=n(152),o=n(8909);class s extends o.TextDocumentLanguageFeature{constructor(e){super(e,r.SelectionRangeRequest.type)}fillClientCapabilities(e){(0,o.ensure)((0,o.ensure)(e,"textDocument"),"selectionRange").dynamicRegistration=!0}initialize(e,t){const[n,i]=this.getRegistration(t,e.selectionRangeProvider);n&&i&&this.register({id:n,registerOptions:i})}registerLanguageProvider(e){const t=e.documentSelector,n={provideSelectionRanges:(e,t,n)=>{const i=this._client,o=async(e,t,n)=>{const o={textDocument:i.code2ProtocolConverter.asTextDocumentIdentifier(e),positions:await i.code2ProtocolConverter.asPositions(t,n)};return i.sendRequest(r.SelectionRangeRequest.type,o,n).then((e=>n.isCancellationRequested?null:i.protocol2CodeConverter.asSelectionRanges(e,n)),(e=>i.handleFailedRequest(r.SelectionRangeRequest.type,n,e,null)))},s=i.middleware;return s.provideSelectionRanges?s.provideSelectionRanges(e,t,n,o):o(e,t,n)}};return[this.registerProvider(t,n),n]}registerProvider(e,t){return i.languages.registerSelectionRangeProvider(this._client.protocol2CodeConverter.asDocumentSelector(e),t)}}t.SelectionRangeFeature=s},9957:(e,t,n)=>{"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.SemanticTokensFeature=void 0;const i=n(9496),r=n(152),o=n(8909),s=n(9763);class a extends o.TextDocumentLanguageFeature{constructor(e){super(e,r.SemanticTokensRegistrationType.type)}fillClientCapabilities(e){const t=(0,o.ensure)((0,o.ensure)(e,"textDocument"),"semanticTokens");t.dynamicRegistration=!0,t.tokenTypes=[r.SemanticTokenTypes.namespace,r.SemanticTokenTypes.type,r.SemanticTokenTypes.class,r.SemanticTokenTypes.enum,r.SemanticTokenTypes.interface,r.SemanticTokenTypes.struct,r.SemanticTokenTypes.typeParameter,r.SemanticTokenTypes.parameter,r.SemanticTokenTypes.variable,r.SemanticTokenTypes.property,r.SemanticTokenTypes.enumMember,r.SemanticTokenTypes.event,r.SemanticTokenTypes.function,r.SemanticTokenTypes.method,r.SemanticTokenTypes.macro,r.SemanticTokenTypes.keyword,r.SemanticTokenTypes.modifier,r.SemanticTokenTypes.comment,r.SemanticTokenTypes.string,r.SemanticTokenTypes.number,r.SemanticTokenTypes.regexp,r.SemanticTokenTypes.operator,r.SemanticTokenTypes.decorator],t.tokenModifiers=[r.SemanticTokenModifiers.declaration,r.SemanticTokenModifiers.definition,r.SemanticTokenModifiers.readonly,r.SemanticTokenModifiers.static,r.SemanticTokenModifiers.deprecated,r.SemanticTokenModifiers.abstract,r.SemanticTokenModifiers.async,r.SemanticTokenModifiers.modification,r.SemanticTokenModifiers.documentation,r.SemanticTokenModifiers.defaultLibrary],t.formats=[r.TokenFormat.Relative],t.requests={range:!0,full:{delta:!0}},t.multilineTokenSupport=!1,t.overlappingTokenSupport=!1,t.serverCancelSupport=!0,t.augmentsSyntaxTokens=!0,(0,o.ensure)((0,o.ensure)(e,"workspace"),"semanticTokens").refreshSupport=!0}initialize(e,t){this._client.onRequest(r.SemanticTokensRefreshRequest.type,(async()=>{for(const e of this.getAllProviders())e.onDidChangeSemanticTokensEmitter.fire()}));const[n,i]=this.getRegistration(t,e.semanticTokensProvider);n&&i&&this.register({id:n,registerOptions:i})}registerLanguageProvider(e){const t=e.documentSelector,n=s.boolean(e.full)?e.full:void 0!==e.full,o=void 0!==e.full&&"boolean"!=typeof e.full&&!0===e.full.delta,a=new i.EventEmitter,c=n?{onDidChangeSemanticTokens:a.event,provideDocumentSemanticTokens:(e,t)=>{const n=this._client,i=n.middleware,o=(e,t)=>{const i={textDocument:n.code2ProtocolConverter.asTextDocumentIdentifier(e)};return n.sendRequest(r.SemanticTokensRequest.type,i,t).then((e=>t.isCancellationRequested?null:n.protocol2CodeConverter.asSemanticTokens(e,t)),(e=>n.handleFailedRequest(r.SemanticTokensRequest.type,t,e,null)))};return i.provideDocumentSemanticTokens?i.provideDocumentSemanticTokens(e,t,o):o(e,t)},provideDocumentSemanticTokensEdits:o?(e,t,n)=>{const i=this._client,o=i.middleware,s=(e,t,n)=>{const o={textDocument:i.code2ProtocolConverter.asTextDocumentIdentifier(e),previousResultId:t};return i.sendRequest(r.SemanticTokensDeltaRequest.type,o,n).then((async e=>n.isCancellationRequested?null:r.SemanticTokens.is(e)?await i.protocol2CodeConverter.asSemanticTokens(e,n):await i.protocol2CodeConverter.asSemanticTokensEdits(e,n)),(e=>i.handleFailedRequest(r.SemanticTokensDeltaRequest.type,n,e,null)))};return o.provideDocumentSemanticTokensEdits?o.provideDocumentSemanticTokensEdits(e,t,n,s):s(e,t,n)}:void 0}:void 0,u=!0===e.range?{provideDocumentRangeSemanticTokens:(e,t,n)=>{const i=this._client,o=i.middleware,s=(e,t,n)=>{const o={textDocument:i.code2ProtocolConverter.asTextDocumentIdentifier(e),range:i.code2ProtocolConverter.asRange(t)};return i.sendRequest(r.SemanticTokensRangeRequest.type,o,n).then((e=>n.isCancellationRequested?null:i.protocol2CodeConverter.asSemanticTokens(e,n)),(e=>i.handleFailedRequest(r.SemanticTokensRangeRequest.type,n,e,null)))};return o.provideDocumentRangeSemanticTokens?o.provideDocumentRangeSemanticTokens(e,t,n,s):s(e,t,n)}}:void 0,l=[],d=this._client,f=d.protocol2CodeConverter.asSemanticTokensLegend(e.legend),p=d.protocol2CodeConverter.asDocumentSelector(t);return void 0!==c&&l.push(i.languages.registerDocumentSemanticTokensProvider(p,c,f)),void 0!==u&&l.push(i.languages.registerDocumentRangeSemanticTokensProvider(p,u,f)),[new i.Disposable((()=>l.forEach((e=>e.dispose())))),{range:u,full:c,onDidChangeSemanticTokensEmitter:a}]}}t.SemanticTokensFeature=a},2908:(e,t,n)=>{"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.SignatureHelpFeature=void 0;const i=n(9496),r=n(152),o=n(8909),s=n(1980);class a extends o.TextDocumentLanguageFeature{constructor(e){super(e,r.SignatureHelpRequest.type)}fillClientCapabilities(e){let t=(0,o.ensure)((0,o.ensure)(e,"textDocument"),"signatureHelp");t.dynamicRegistration=!0,t.signatureInformation={documentationFormat:[r.MarkupKind.Markdown,r.MarkupKind.PlainText]},t.signatureInformation.parameterInformation={labelOffsetSupport:!0},t.signatureInformation.activeParameterSupport=!0,t.contextSupport=!0}initialize(e,t){const n=this.getRegistrationOptions(t,e.signatureHelpProvider);n&&this.register({id:s.generateUuid(),registerOptions:n})}registerLanguageProvider(e){const t={provideSignatureHelp:(e,t,n,i)=>{const o=this._client,s=(e,t,n,i)=>o.sendRequest(r.SignatureHelpRequest.type,o.code2ProtocolConverter.asSignatureHelpParams(e,t,n),i).then((e=>i.isCancellationRequested?null:o.protocol2CodeConverter.asSignatureHelp(e,i)),(e=>o.handleFailedRequest(r.SignatureHelpRequest.type,i,e,null))),a=o.middleware;return a.provideSignatureHelp?a.provideSignatureHelp(e,t,i,n,s):s(e,t,i,n)}};return[this.registerProvider(e,t),t]}registerProvider(e,t){const n=this._client.protocol2CodeConverter.asDocumentSelector(e.documentSelector);if(void 0===e.retriggerCharacters){const r=e.triggerCharacters||[];return i.languages.registerSignatureHelpProvider(n,t,...r)}{const r={triggerCharacters:e.triggerCharacters||[],retriggerCharacters:e.retriggerCharacters||[]};return i.languages.registerSignatureHelpProvider(n,t,r)}}}t.SignatureHelpFeature=a},743:(e,t,n)=>{"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.DidSaveTextDocumentFeature=t.WillSaveWaitUntilFeature=t.WillSaveFeature=t.DidChangeTextDocumentFeature=t.DidCloseTextDocumentFeature=t.DidOpenTextDocumentFeature=void 0;const i=n(9496),r=n(152),o=n(8909),s=n(1980);class a extends o.TextDocumentEventFeature{constructor(e,t){super(e,i.workspace.onDidOpenTextDocument,r.DidOpenTextDocumentNotification.type,(()=>e.middleware.didOpen),(t=>e.code2ProtocolConverter.asOpenTextDocumentParams(t)),(e=>e),o.TextDocumentEventFeature.textDocumentFilter),this._syncedDocuments=t}get openDocuments(){return this._syncedDocuments.values()}fillClientCapabilities(e){(0,o.ensure)((0,o.ensure)(e,"textDocument"),"synchronization").dynamicRegistration=!0}initialize(e,t){const n=e.resolvedTextDocumentSync;t&&n&&n.openClose&&this.register({id:s.generateUuid(),registerOptions:{documentSelector:t}})}get registrationType(){return r.DidOpenTextDocumentNotification.type}register(e){if(super.register(e),!e.registerOptions.documentSelector)return;const t=this._client.protocol2CodeConverter.asDocumentSelector(e.registerOptions.documentSelector);i.workspace.textDocuments.forEach((e=>{const n=e.uri.toString();if(!this._syncedDocuments.has(n)&&i.languages.match(t,e)>0&&!this._client.hasDedicatedTextSynchronizationFeature(e)){const t=this._client.middleware,i=e=>this._client.sendNotification(this._type,this._createParams(e));(t.didOpen?t.didOpen(e,i):i(e)).catch((e=>{this._client.error(`Sending document notification ${this._type.method} failed`,e)})),this._syncedDocuments.set(n,e)}}))}getTextDocument(e){return e}notificationSent(e,t,n){this._syncedDocuments.set(e.uri.toString(),e),super.notificationSent(e,t,n)}}t.DidOpenTextDocumentFeature=a;class c extends o.TextDocumentEventFeature{constructor(e,t,n){super(e,i.workspace.onDidCloseTextDocument,r.DidCloseTextDocumentNotification.type,(()=>e.middleware.didClose),(t=>e.code2ProtocolConverter.asCloseTextDocumentParams(t)),(e=>e),o.TextDocumentEventFeature.textDocumentFilter),this._syncedDocuments=t,this._pendingTextDocumentChanges=n}get registrationType(){return r.DidCloseTextDocumentNotification.type}fillClientCapabilities(e){(0,o.ensure)((0,o.ensure)(e,"textDocument"),"synchronization").dynamicRegistration=!0}initialize(e,t){let n=e.resolvedTextDocumentSync;t&&n&&n.openClose&&this.register({id:s.generateUuid(),registerOptions:{documentSelector:t}})}async callback(e){await super.callback(e),this._pendingTextDocumentChanges.delete(e.uri.toString())}getTextDocument(e){return e}notificationSent(e,t,n){this._syncedDocuments.delete(e.uri.toString()),super.notificationSent(e,t,n)}unregister(e){const t=this._selectors.get(e);super.unregister(e);const n=this._selectors.values();this._syncedDocuments.forEach((e=>{if(i.languages.match(t,e)>0&&!this._selectorFilter(n,e)&&!this._client.hasDedicatedTextSynchronizationFeature(e)){let t=this._client.middleware,n=e=>this._client.sendNotification(this._type,this._createParams(e));this._syncedDocuments.delete(e.uri.toString()),(t.didClose?t.didClose(e,n):n(e)).catch((e=>{this._client.error(`Sending document notification ${this._type.method} failed`,e)}))}}))}}t.DidCloseTextDocumentFeature=c;class u extends o.DynamicDocumentFeature{constructor(e,t){super(e),this._changeData=new Map,this._onNotificationSent=new i.EventEmitter,this._onPendingChangeAdded=new i.EventEmitter,this._pendingTextDocumentChanges=t,this._syncKind=r.TextDocumentSyncKind.None}get onNotificationSent(){return this._onNotificationSent.event}get onPendingChangeAdded(){return this._onPendingChangeAdded.event}get syncKind(){return this._syncKind}get registrationType(){return r.DidChangeTextDocumentNotification.type}fillClientCapabilities(e){(0,o.ensure)((0,o.ensure)(e,"textDocument"),"synchronization").dynamicRegistration=!0}initialize(e,t){let n=e.resolvedTextDocumentSync;t&&n&&void 0!==n.change&&n.change!==r.TextDocumentSyncKind.None&&this.register({id:s.generateUuid(),registerOptions:Object.assign({},{documentSelector:t},{syncKind:n.change})})}register(e){e.registerOptions.documentSelector&&(this._listener||(this._listener=i.workspace.onDidChangeTextDocument(this.callback,this)),this._changeData.set(e.id,{syncKind:e.registerOptions.syncKind,documentSelector:this._client.protocol2CodeConverter.asDocumentSelector(e.registerOptions.documentSelector)}),this.updateSyncKind(e.registerOptions.syncKind))}*getDocumentSelectors(){for(const e of this._changeData.values())yield e.documentSelector}async callback(e){if(0===e.contentChanges.length)return;const t=e.document.uri,n=e.document.version,o=[];for(const s of this._changeData.values())if(i.languages.match(s.documentSelector,e.document)>0&&!this._client.hasDedicatedTextSynchronizationFeature(e.document)){const i=this._client.middleware;if(s.syncKind===r.TextDocumentSyncKind.Incremental){const s=async e=>{const i=this._client.code2ProtocolConverter.asChangeTextDocumentParams(e,t,n);await this._client.sendNotification(r.DidChangeTextDocumentNotification.type,i),this.notificationSent(e.document,r.DidChangeTextDocumentNotification.type,i)};o.push(i.didChange?i.didChange(e,(e=>s(e))):s(e))}else if(s.syncKind===r.TextDocumentSyncKind.Full){const t=async e=>{const t=e.document.uri.toString();this._pendingTextDocumentChanges.set(t,e.document),this._onPendingChangeAdded.fire()};o.push(i.didChange?i.didChange(e,(e=>t(e))):t(e))}}return Promise.all(o).then(void 0,(e=>{throw this._client.error(`Sending document notification ${r.DidChangeTextDocumentNotification.type.method} failed`,e),e}))}notificationSent(e,t,n){this._onNotificationSent.fire({textDocument:e,type:t,params:n})}unregister(e){if(this._changeData.delete(e),0===this._changeData.size)this._listener&&(this._listener.dispose(),this._listener=void 0),this._syncKind=r.TextDocumentSyncKind.None;else{this._syncKind=r.TextDocumentSyncKind.None;for(const e of this._changeData.values())if(this.updateSyncKind(e.syncKind),this._syncKind===r.TextDocumentSyncKind.Full)break}}dispose(){this._pendingTextDocumentChanges.clear(),this._changeData.clear(),this._syncKind=r.TextDocumentSyncKind.None,this._listener&&(this._listener.dispose(),this._listener=void 0)}getPendingDocumentChanges(e){if(0===this._pendingTextDocumentChanges.size)return[];let t;if(0===e.size)t=Array.from(this._pendingTextDocumentChanges.values()),this._pendingTextDocumentChanges.clear();else{t=[];for(const n of this._pendingTextDocumentChanges)e.has(n[0])||(t.push(n[1]),this._pendingTextDocumentChanges.delete(n[0]))}return t}getProvider(e){for(const t of this._changeData.values())if(i.languages.match(t.documentSelector,e)>0)return{send:e=>this.callback(e)}}updateSyncKind(e){if(this._syncKind!==r.TextDocumentSyncKind.Full)switch(e){case r.TextDocumentSyncKind.Full:this._syncKind=e;break;case r.TextDocumentSyncKind.Incremental:this._syncKind===r.TextDocumentSyncKind.None&&(this._syncKind=r.TextDocumentSyncKind.Incremental)}}}t.DidChangeTextDocumentFeature=u;class l extends o.TextDocumentEventFeature{constructor(e){super(e,i.workspace.onWillSaveTextDocument,r.WillSaveTextDocumentNotification.type,(()=>e.middleware.willSave),(t=>e.code2ProtocolConverter.asWillSaveTextDocumentParams(t)),(e=>e.document),((e,t)=>o.TextDocumentEventFeature.textDocumentFilter(e,t.document)))}get registrationType(){return r.WillSaveTextDocumentNotification.type}fillClientCapabilities(e){(0,o.ensure)((0,o.ensure)(e,"textDocument"),"synchronization").willSave=!0}initialize(e,t){let n=e.resolvedTextDocumentSync;t&&n&&n.willSave&&this.register({id:s.generateUuid(),registerOptions:{documentSelector:t}})}getTextDocument(e){return e.document}}t.WillSaveFeature=l;class d extends o.DynamicDocumentFeature{constructor(e){super(e),this._selectors=new Map}getDocumentSelectors(){return this._selectors.values()}get registrationType(){return r.WillSaveTextDocumentWaitUntilRequest.type}fillClientCapabilities(e){(0,o.ensure)((0,o.ensure)(e,"textDocument"),"synchronization").willSaveWaitUntil=!0}initialize(e,t){let n=e.resolvedTextDocumentSync;t&&n&&n.willSaveWaitUntil&&this.register({id:s.generateUuid(),registerOptions:{documentSelector:t}})}register(e){e.registerOptions.documentSelector&&(this._listener||(this._listener=i.workspace.onWillSaveTextDocument(this.callback,this)),this._selectors.set(e.id,this._client.protocol2CodeConverter.asDocumentSelector(e.registerOptions.documentSelector)))}callback(e){if(o.TextDocumentEventFeature.textDocumentFilter(this._selectors.values(),e.document)&&!this._client.hasDedicatedTextSynchronizationFeature(e.document)){let t=this._client.middleware,n=e=>this._client.sendRequest(r.WillSaveTextDocumentWaitUntilRequest.type,this._client.code2ProtocolConverter.asWillSaveTextDocumentParams(e)).then((async e=>{let t=await this._client.protocol2CodeConverter.asTextEdits(e);return void 0===t?[]:t}));e.waitUntil(t.willSaveWaitUntil?t.willSaveWaitUntil(e,n):n(e))}}unregister(e){this._selectors.delete(e),0===this._selectors.size&&this._listener&&(this._listener.dispose(),this._listener=void 0)}dispose(){this._selectors.clear(),this._listener&&(this._listener.dispose(),this._listener=void 0)}}t.WillSaveWaitUntilFeature=d;class f extends o.TextDocumentEventFeature{constructor(e){super(e,i.workspace.onDidSaveTextDocument,r.DidSaveTextDocumentNotification.type,(()=>e.middleware.didSave),(t=>e.code2ProtocolConverter.asSaveTextDocumentParams(t,this._includeText)),(e=>e),o.TextDocumentEventFeature.textDocumentFilter),this._includeText=!1}get registrationType(){return r.DidSaveTextDocumentNotification.type}fillClientCapabilities(e){(0,o.ensure)((0,o.ensure)(e,"textDocument"),"synchronization").didSave=!0}initialize(e,t){const n=e.resolvedTextDocumentSync;if(t&&n&&n.save){const e="boolean"==typeof n.save?{includeText:!1}:{includeText:!!n.save.includeText};this.register({id:s.generateUuid(),registerOptions:Object.assign({},{documentSelector:t},e)})}}register(e){this._includeText=!!e.registerOptions.includeText,super.register(e)}getTextDocument(e){return e}}t.DidSaveTextDocumentFeature=f},328:(e,t,n)=>{"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.TypeDefinitionFeature=void 0;const i=n(9496),r=n(152),o=n(8909);class s extends o.TextDocumentLanguageFeature{constructor(e){super(e,r.TypeDefinitionRequest.type)}fillClientCapabilities(e){(0,o.ensure)((0,o.ensure)(e,"textDocument"),"typeDefinition").dynamicRegistration=!0;let t=(0,o.ensure)((0,o.ensure)(e,"textDocument"),"typeDefinition");t.dynamicRegistration=!0,t.linkSupport=!0}initialize(e,t){let[n,i]=this.getRegistration(t,e.typeDefinitionProvider);n&&i&&this.register({id:n,registerOptions:i})}registerLanguageProvider(e){const t=e.documentSelector,n={provideTypeDefinition:(e,t,n)=>{const i=this._client,o=(e,t,n)=>i.sendRequest(r.TypeDefinitionRequest.type,i.code2ProtocolConverter.asTextDocumentPositionParams(e,t),n).then((e=>n.isCancellationRequested?null:i.protocol2CodeConverter.asDefinitionResult(e,n)),(e=>i.handleFailedRequest(r.TypeDefinitionRequest.type,n,e,null))),s=i.middleware;return s.provideTypeDefinition?s.provideTypeDefinition(e,t,n,o):o(e,t,n)}};return[this.registerProvider(t,n),n]}registerProvider(e,t){return i.languages.registerTypeDefinitionProvider(this._client.protocol2CodeConverter.asDocumentSelector(e),t)}}t.TypeDefinitionFeature=s},4175:(e,t,n)=>{"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.TypeHierarchyFeature=void 0;const i=n(9496),r=n(152),o=n(8909);class s{constructor(e){this.client=e,this.middleware=e.middleware}prepareTypeHierarchy(e,t,n){const i=this.client,o=this.middleware,s=(e,t,n)=>{const o=i.code2ProtocolConverter.asTextDocumentPositionParams(e,t);return i.sendRequest(r.TypeHierarchyPrepareRequest.type,o,n).then((e=>n.isCancellationRequested?null:i.protocol2CodeConverter.asTypeHierarchyItems(e,n)),(e=>i.handleFailedRequest(r.TypeHierarchyPrepareRequest.type,n,e,null)))};return o.prepareTypeHierarchy?o.prepareTypeHierarchy(e,t,n,s):s(e,t,n)}provideTypeHierarchySupertypes(e,t){const n=this.client,i=this.middleware,o=(e,t)=>{const i={item:n.code2ProtocolConverter.asTypeHierarchyItem(e)};return n.sendRequest(r.TypeHierarchySupertypesRequest.type,i,t).then((e=>t.isCancellationRequested?null:n.protocol2CodeConverter.asTypeHierarchyItems(e,t)),(e=>n.handleFailedRequest(r.TypeHierarchySupertypesRequest.type,t,e,null)))};return i.provideTypeHierarchySupertypes?i.provideTypeHierarchySupertypes(e,t,o):o(e,t)}provideTypeHierarchySubtypes(e,t){const n=this.client,i=this.middleware,o=(e,t)=>{const i={item:n.code2ProtocolConverter.asTypeHierarchyItem(e)};return n.sendRequest(r.TypeHierarchySubtypesRequest.type,i,t).then((e=>t.isCancellationRequested?null:n.protocol2CodeConverter.asTypeHierarchyItems(e,t)),(e=>n.handleFailedRequest(r.TypeHierarchySubtypesRequest.type,t,e,null)))};return i.provideTypeHierarchySubtypes?i.provideTypeHierarchySubtypes(e,t,o):o(e,t)}}class a extends o.TextDocumentLanguageFeature{constructor(e){super(e,r.TypeHierarchyPrepareRequest.type)}fillClientCapabilities(e){(0,o.ensure)((0,o.ensure)(e,"textDocument"),"typeHierarchy").dynamicRegistration=!0}initialize(e,t){const[n,i]=this.getRegistration(t,e.typeHierarchyProvider);n&&i&&this.register({id:n,registerOptions:i})}registerLanguageProvider(e){const t=this._client,n=new s(t);return[i.languages.registerTypeHierarchyProvider(t.protocol2CodeConverter.asDocumentSelector(e.documentSelector),n),n]}}t.TypeHierarchyFeature=a},4904:(e,t,n)=>{"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.forEach=t.mapAsync=t.map=t.clearTestMode=t.setTestMode=t.Semaphore=t.Delayer=void 0;const i=n(152);t.Delayer=class{constructor(e){this.defaultDelay=e,this.timeout=void 0,this.completionPromise=void 0,this.onSuccess=void 0,this.task=void 0}trigger(e,t=this.defaultDelay){return this.task=e,t>=0&&this.cancelTimeout(),this.completionPromise||(this.completionPromise=new Promise((e=>{this.onSuccess=e})).then((()=>{this.completionPromise=void 0,this.onSuccess=void 0;var e=this.task();return this.task=void 0,e}))),(t>=0||void 0===this.timeout)&&(this.timeout=(0,i.RAL)().timer.setTimeout((()=>{this.timeout=void 0,this.onSuccess(void 0)}),t>=0?t:this.defaultDelay)),this.completionPromise}forceDelivery(){if(!this.completionPromise)return;this.cancelTimeout();let e=this.task();return this.completionPromise=void 0,this.onSuccess=void 0,this.task=void 0,e}isTriggered(){return void 0!==this.timeout}cancel(){this.cancelTimeout(),this.completionPromise=void 0}cancelTimeout(){void 0!==this.timeout&&(this.timeout.dispose(),this.timeout=void 0)}},t.Semaphore=class{constructor(e=1){if(e<=0)throw new Error("Capacity must be greater than 0");this._capacity=e,this._active=0,this._waiting=[]}lock(e){return new Promise(((t,n)=>{this._waiting.push({thunk:e,resolve:t,reject:n}),this.runNext()}))}get active(){return this._active}runNext(){0!==this._waiting.length&&this._active!==this._capacity&&(0,i.RAL)().timer.setImmediate((()=>this.doRunNext()))}doRunNext(){if(0===this._waiting.length||this._active===this._capacity)return;const e=this._waiting.shift();if(this._active++,this._active>this._capacity)throw new Error("To many thunks active");try{const t=e.thunk();t instanceof Promise?t.then((t=>{this._active--,e.resolve(t),this.runNext()}),(t=>{this._active--,e.reject(t),this.runNext()})):(this._active--,e.resolve(t),this.runNext())}catch(t){this._active--,e.reject(t),this.runNext()}}};let r=!1;t.setTestMode=function(){r=!0},t.clearTestMode=function(){r=!1};class o{constructor(e=15){this.yieldAfter=!0===r?Math.max(e,2):Math.max(e,15),this.startTime=Date.now(),this.counter=0,this.total=0,this.counterInterval=1}start(){this.counter=0,this.total=0,this.counterInterval=1,this.startTime=Date.now()}shouldYield(){if(++this.counter>=this.counterInterval){const e=Date.now()-this.startTime,t=Math.max(0,this.yieldAfter-e);if(this.total+=this.counter,this.counter=0,e>=this.yieldAfter||t<=1)return this.counterInterval=1,this.total=0,!0;switch(e){case 0:case 1:this.counterInterval=2*this.total}}return!1}}t.map=async function(e,t,n,r){if(0===e.length)return[];const s=new Array(e.length),a=new o(r?.yieldAfter);function c(n){a.start();for(let i=n;i{(0,i.RAL)().timer.setImmediate((()=>{e(c(u))}))}));return s},t.mapAsync=async function(e,t,n,r){if(0===e.length)return[];const s=new Array(e.length),a=new o(r?.yieldAfter);async function c(i){a.start();for(let o=i;o{(0,i.RAL)().timer.setImmediate((()=>{e(c(u))}))}));return s},t.forEach=async function(e,t,n,r){if(0===e.length)return;const s=new o(r?.yieldAfter);function a(n){s.start();for(let i=n;i{(0,i.RAL)().timer.setImmediate((()=>{e(a(c))}))}))}},9763:(e,t)=>{"use strict";function n(e){return"string"==typeof e||e instanceof String}function i(e){return"function"==typeof e}function r(e){return Array.isArray(e)}function o(e){return e&&i(e.then)}Object.defineProperty(t,"__esModule",{value:!0}),t.asPromise=t.thenable=t.typedArray=t.stringArray=t.array=t.func=t.error=t.number=t.string=t.boolean=void 0,t.boolean=function(e){return!0===e||!1===e},t.string=n,t.number=function(e){return"number"==typeof e||e instanceof Number},t.error=function(e){return e instanceof Error},t.func=i,t.array=r,t.stringArray=function(e){return r(e)&&e.every((e=>n(e)))},t.typedArray=function(e,t){return Array.isArray(e)&&e.every(t)},t.thenable=o,t.asPromise=function(e){return e instanceof Promise?e:o(e)?new Promise(((t,n)=>{e.then((e=>t(e)),(e=>n(e)))})):Promise.resolve(e)}},1980:(e,t)=>{"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.generateUuid=t.parse=t.isUUID=t.v4=t.empty=void 0;class n{constructor(e){this._value=e}asHex(){return this._value}equals(e){return this.asHex()===e.asHex()}}class i extends n{constructor(){super([i._randomHex(),i._randomHex(),i._randomHex(),i._randomHex(),i._randomHex(),i._randomHex(),i._randomHex(),i._randomHex(),"-",i._randomHex(),i._randomHex(),i._randomHex(),i._randomHex(),"-","4",i._randomHex(),i._randomHex(),i._randomHex(),"-",i._oneOf(i._timeHighBits),i._randomHex(),i._randomHex(),i._randomHex(),"-",i._randomHex(),i._randomHex(),i._randomHex(),i._randomHex(),i._randomHex(),i._randomHex(),i._randomHex(),i._randomHex(),i._randomHex(),i._randomHex(),i._randomHex(),i._randomHex()].join(""))}static _oneOf(e){return e[Math.floor(e.length*Math.random())]}static _randomHex(){return i._oneOf(i._chars)}}function r(){return new i}i._chars=["0","1","2","3","4","5","6","6","7","8","9","a","b","c","d","e","f"],i._timeHighBits=["8","9","a","b"],t.empty=new n("00000000-0000-0000-0000-000000000000"),t.v4=r;const o=/^[0-9a-f]{8}-[0-9a-f]{4}-[0-9a-f]{4}-[0-9a-f]{4}-[0-9a-f]{12}$/i;function s(e){return o.test(e)}t.isUUID=s,t.parse=function(e){if(!s(e))throw new Error("invalid uuid");return new n(e)},t.generateUuid=function(){return r().asHex()}},5941:(e,t,n)=>{"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.WorkspaceFoldersFeature=t.arrayDiff=void 0;const i=n(1980),r=n(9496),o=n(152);function s(e,t){if(null!=e)return e[t]}function a(e,t){return e.filter((e=>t.indexOf(e)<0))}t.arrayDiff=a,t.WorkspaceFoldersFeature=class{constructor(e){this._client=e,this._listeners=new Map}getState(){return{kind:"workspace",id:this.registrationType.method,registrations:this._listeners.size>0}}get registrationType(){return o.DidChangeWorkspaceFoldersNotification.type}fillInitializeParams(e){const t=r.workspace.workspaceFolders;this.initializeWithFolders(t),e.workspaceFolders=void 0===t?null:t.map((e=>this.asProtocol(e)))}initializeWithFolders(e){this._initialFolders=e}fillClientCapabilities(e){e.workspace=e.workspace||{},e.workspace.workspaceFolders=!0}initialize(e){const t=this._client;t.onRequest(o.WorkspaceFoldersRequest.type,(e=>{const n=()=>{const e=r.workspace.workspaceFolders;return void 0===e?null:e.map((e=>this.asProtocol(e)))},i=t.middleware.workspace;return i&&i.workspaceFolders?i.workspaceFolders(e,n):n()}));const n=s(s(s(e,"workspace"),"workspaceFolders"),"changeNotifications");let a;"string"==typeof n?a=n:!0===n&&(a=i.generateUuid()),a&&this.register({id:a,registerOptions:void 0})}sendInitialEvent(e){let t;if(this._initialFolders&&e){const n=a(this._initialFolders,e),i=a(e,this._initialFolders);(i.length>0||n.length>0)&&(t=this.doSendEvent(i,n))}else this._initialFolders?t=this.doSendEvent([],this._initialFolders):e&&(t=this.doSendEvent(e,[]));void 0!==t&&t.catch((e=>{this._client.error(`Sending notification ${o.DidChangeWorkspaceFoldersNotification.type.method} failed`,e)}))}doSendEvent(e,t){let n={event:{added:e.map((e=>this.asProtocol(e))),removed:t.map((e=>this.asProtocol(e)))}};return this._client.sendNotification(o.DidChangeWorkspaceFoldersNotification.type,n)}register(e){let t=e.id,n=this._client,i=r.workspace.onDidChangeWorkspaceFolders((e=>{let t=e=>this.doSendEvent(e.added,e.removed),i=n.middleware.workspace;(i&&i.didChangeWorkspaceFolders?i.didChangeWorkspaceFolders(e,t):t(e)).catch((e=>{this._client.error(`Sending notification ${o.DidChangeWorkspaceFoldersNotification.type.method} failed`,e)}))}));this._listeners.set(t,i),this.sendInitialEvent(r.workspace.workspaceFolders)}unregister(e){let t=this._listeners.get(e);void 0!==t&&(this._listeners.delete(e),t.dispose())}dispose(){for(let e of this._listeners.values())e.dispose();this._listeners.clear()}asProtocol(e){return void 0===e?null:{uri:this._client.code2ProtocolConverter.asUri(e.uri),name:e.name}}}},3051:(e,t,n)=>{"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.WorkspaceSymbolFeature=void 0;const i=n(9496),r=n(152),o=n(8909),s=n(2483),a=n(1980);class c extends o.WorkspaceFeature{constructor(e){super(e,r.WorkspaceSymbolRequest.type)}fillClientCapabilities(e){let t=(0,o.ensure)((0,o.ensure)(e,"workspace"),"symbol");t.dynamicRegistration=!0,t.symbolKind={valueSet:s.SupportedSymbolKinds},t.tagSupport={valueSet:s.SupportedSymbolTags},t.resolveSupport={properties:["location.range"]}}initialize(e){e.workspaceSymbolProvider&&this.register({id:a.generateUuid(),registerOptions:!0===e.workspaceSymbolProvider?{workDoneProgress:!1}:e.workspaceSymbolProvider})}registerLanguageProvider(e){const t={provideWorkspaceSymbols:(e,t)=>{const n=this._client,i=(e,t)=>n.sendRequest(r.WorkspaceSymbolRequest.type,{query:e},t).then((e=>t.isCancellationRequested?null:n.protocol2CodeConverter.asSymbolInformations(e,t)),(e=>n.handleFailedRequest(r.WorkspaceSymbolRequest.type,t,e,null))),o=n.middleware;return o.provideWorkspaceSymbols?o.provideWorkspaceSymbols(e,t,i):i(e,t)},resolveWorkspaceSymbol:!0===e.resolveProvider?(e,t)=>{const n=this._client,i=(e,t)=>n.sendRequest(r.WorkspaceSymbolResolveRequest.type,n.code2ProtocolConverter.asWorkspaceSymbol(e),t).then((e=>t.isCancellationRequested?null:n.protocol2CodeConverter.asSymbolInformation(e)),(e=>n.handleFailedRequest(r.WorkspaceSymbolResolveRequest.type,t,e,null))),o=n.middleware;return o.resolveWorkspaceSymbol?o.resolveWorkspaceSymbol(e,t,i):i(e,t)}:void 0};return[i.languages.registerWorkspaceSymbolProvider(t),t]}}t.WorkspaceSymbolFeature=c},5224:(e,t,n)=>{"use strict";e.exports=n(152)},152:function(e,t,n){"use strict";var i=this&&this.__createBinding||(Object.create?function(e,t,n,i){void 0===i&&(i=n);var r=Object.getOwnPropertyDescriptor(t,n);r&&!("get"in r?!t.__esModule:r.writable||r.configurable)||(r={enumerable:!0,get:function(){return t[n]}}),Object.defineProperty(e,i,r)}:function(e,t,n,i){void 0===i&&(i=n),e[i]=t[n]}),r=this&&this.__exportStar||function(e,t){for(var n in e)"default"===n||Object.prototype.hasOwnProperty.call(t,n)||i(t,e,n)};Object.defineProperty(t,"__esModule",{value:!0}),t.createProtocolConnection=void 0;const o=n(380);r(n(380),t),r(n(1661),t),t.createProtocolConnection=function(e,t,n,i){return(0,o.createMessageConnection)(e,t,n,i)}},1661:function(e,t,n){"use strict";var i=this&&this.__createBinding||(Object.create?function(e,t,n,i){void 0===i&&(i=n);var r=Object.getOwnPropertyDescriptor(t,n);r&&!("get"in r?!t.__esModule:r.writable||r.configurable)||(r={enumerable:!0,get:function(){return t[n]}}),Object.defineProperty(e,i,r)}:function(e,t,n,i){void 0===i&&(i=n),e[i]=t[n]}),r=this&&this.__exportStar||function(e,t){for(var n in e)"default"===n||Object.prototype.hasOwnProperty.call(t,n)||i(t,e,n)};Object.defineProperty(t,"__esModule",{value:!0}),t.LSPErrorCodes=t.createProtocolConnection=void 0,r(n(8337),t),r(n(1674),t),r(n(6140),t),r(n(542),t);var o,s=n(3767);Object.defineProperty(t,"createProtocolConnection",{enumerable:!0,get:function(){return s.createProtocolConnection}}),(o=t.LSPErrorCodes||(t.LSPErrorCodes={})).lspReservedErrorRangeStart=-32899,o.RequestFailed=-32803,o.ServerCancelled=-32802,o.ContentModified=-32801,o.RequestCancelled=-32800,o.lspReservedErrorRangeEnd=-32800},3767:(e,t,n)=>{"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.createProtocolConnection=void 0;const i=n(8337);t.createProtocolConnection=function(e,t,n,r){return i.ConnectionStrategy.is(r)&&(r={connectionStrategy:r}),(0,i.createMessageConnection)(e,t,n,r)}},6140:(e,t,n)=>{"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.ProtocolNotificationType=t.ProtocolNotificationType0=t.ProtocolRequestType=t.ProtocolRequestType0=t.RegistrationType=t.MessageDirection=void 0;const i=n(8337);var r;(r=t.MessageDirection||(t.MessageDirection={})).clientToServer="clientToServer",r.serverToClient="serverToClient",r.both="both",t.RegistrationType=class{constructor(e){this.method=e}};class o extends i.RequestType0{constructor(e){super(e)}}t.ProtocolRequestType0=o;class s extends i.RequestType{constructor(e){super(e,i.ParameterStructures.byName)}}t.ProtocolRequestType=s;class a extends i.NotificationType0{constructor(e){super(e)}}t.ProtocolNotificationType0=a;class c extends i.NotificationType{constructor(e){super(e,i.ParameterStructures.byName)}}t.ProtocolNotificationType=c},2918:(e,t,n)=>{"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.CallHierarchyOutgoingCallsRequest=t.CallHierarchyIncomingCallsRequest=t.CallHierarchyPrepareRequest=void 0;const i=n(6140);var r,o,s;(s=t.CallHierarchyPrepareRequest||(t.CallHierarchyPrepareRequest={})).method="textDocument/prepareCallHierarchy",s.messageDirection=i.MessageDirection.clientToServer,s.type=new i.ProtocolRequestType(s.method),(o=t.CallHierarchyIncomingCallsRequest||(t.CallHierarchyIncomingCallsRequest={})).method="callHierarchy/incomingCalls",o.messageDirection=i.MessageDirection.clientToServer,o.type=new i.ProtocolRequestType(o.method),(r=t.CallHierarchyOutgoingCallsRequest||(t.CallHierarchyOutgoingCallsRequest={})).method="callHierarchy/outgoingCalls",r.messageDirection=i.MessageDirection.clientToServer,r.type=new i.ProtocolRequestType(r.method)},9891:(e,t,n)=>{"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.ColorPresentationRequest=t.DocumentColorRequest=void 0;const i=n(6140);var r,o;(o=t.DocumentColorRequest||(t.DocumentColorRequest={})).method="textDocument/documentColor",o.messageDirection=i.MessageDirection.clientToServer,o.type=new i.ProtocolRequestType(o.method),(r=t.ColorPresentationRequest||(t.ColorPresentationRequest={})).method="textDocument/colorPresentation",r.messageDirection=i.MessageDirection.clientToServer,r.type=new i.ProtocolRequestType(r.method)},5934:(e,t,n)=>{"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.ConfigurationRequest=void 0;const i=n(6140);var r;(r=t.ConfigurationRequest||(t.ConfigurationRequest={})).method="workspace/configuration",r.messageDirection=i.MessageDirection.serverToClient,r.type=new i.ProtocolRequestType(r.method)},764:(e,t,n)=>{"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.DeclarationRequest=void 0;const i=n(6140);var r;(r=t.DeclarationRequest||(t.DeclarationRequest={})).method="textDocument/declaration",r.messageDirection=i.MessageDirection.clientToServer,r.type=new i.ProtocolRequestType(r.method)},9824:(e,t,n)=>{"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.DiagnosticRefreshRequest=t.WorkspaceDiagnosticRequest=t.DocumentDiagnosticRequest=t.DocumentDiagnosticReportKind=t.DiagnosticServerCancellationData=void 0;const i=n(8337),r=n(9533),o=n(6140);var s,a,c,u;(t.DiagnosticServerCancellationData||(t.DiagnosticServerCancellationData={})).is=function(e){const t=e;return t&&r.boolean(t.retriggerRequest)},(u=t.DocumentDiagnosticReportKind||(t.DocumentDiagnosticReportKind={})).Full="full",u.Unchanged="unchanged",(c=t.DocumentDiagnosticRequest||(t.DocumentDiagnosticRequest={})).method="textDocument/diagnostic",c.messageDirection=o.MessageDirection.clientToServer,c.type=new o.ProtocolRequestType(c.method),c.partialResult=new i.ProgressType,(a=t.WorkspaceDiagnosticRequest||(t.WorkspaceDiagnosticRequest={})).method="workspace/diagnostic",a.messageDirection=o.MessageDirection.clientToServer,a.type=new o.ProtocolRequestType(a.method),a.partialResult=new i.ProgressType,(s=t.DiagnosticRefreshRequest||(t.DiagnosticRefreshRequest={})).method="workspace/diagnostic/refresh",s.messageDirection=o.MessageDirection.serverToClient,s.type=new o.ProtocolRequestType0(s.method)},7846:(e,t,n)=>{"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.WillDeleteFilesRequest=t.DidDeleteFilesNotification=t.DidRenameFilesNotification=t.WillRenameFilesRequest=t.DidCreateFilesNotification=t.WillCreateFilesRequest=t.FileOperationPatternKind=void 0;const i=n(6140);var r,o,s,a,c,u,l;(l=t.FileOperationPatternKind||(t.FileOperationPatternKind={})).file="file",l.folder="folder",(u=t.WillCreateFilesRequest||(t.WillCreateFilesRequest={})).method="workspace/willCreateFiles",u.messageDirection=i.MessageDirection.clientToServer,u.type=new i.ProtocolRequestType(u.method),(c=t.DidCreateFilesNotification||(t.DidCreateFilesNotification={})).method="workspace/didCreateFiles",c.messageDirection=i.MessageDirection.clientToServer,c.type=new i.ProtocolNotificationType(c.method),(a=t.WillRenameFilesRequest||(t.WillRenameFilesRequest={})).method="workspace/willRenameFiles",a.messageDirection=i.MessageDirection.clientToServer,a.type=new i.ProtocolRequestType(a.method),(s=t.DidRenameFilesNotification||(t.DidRenameFilesNotification={})).method="workspace/didRenameFiles",s.messageDirection=i.MessageDirection.clientToServer,s.type=new i.ProtocolNotificationType(s.method),(o=t.DidDeleteFilesNotification||(t.DidDeleteFilesNotification={})).method="workspace/didDeleteFiles",o.messageDirection=i.MessageDirection.clientToServer,o.type=new i.ProtocolNotificationType(o.method),(r=t.WillDeleteFilesRequest||(t.WillDeleteFilesRequest={})).method="workspace/willDeleteFiles",r.messageDirection=i.MessageDirection.clientToServer,r.type=new i.ProtocolRequestType(r.method)},3394:(e,t,n)=>{"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.FoldingRangeRequest=void 0;const i=n(6140);var r;(r=t.FoldingRangeRequest||(t.FoldingRangeRequest={})).method="textDocument/foldingRange",r.messageDirection=i.MessageDirection.clientToServer,r.type=new i.ProtocolRequestType(r.method)},2122:(e,t,n)=>{"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.ImplementationRequest=void 0;const i=n(6140);var r;(r=t.ImplementationRequest||(t.ImplementationRequest={})).method="textDocument/implementation",r.messageDirection=i.MessageDirection.clientToServer,r.type=new i.ProtocolRequestType(r.method)},9999:(e,t,n)=>{"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.InlayHintRefreshRequest=t.InlayHintResolveRequest=t.InlayHintRequest=void 0;const i=n(6140);var r,o,s;(s=t.InlayHintRequest||(t.InlayHintRequest={})).method="textDocument/inlayHint",s.messageDirection=i.MessageDirection.clientToServer,s.type=new i.ProtocolRequestType(s.method),(o=t.InlayHintResolveRequest||(t.InlayHintResolveRequest={})).method="inlayHint/resolve",o.messageDirection=i.MessageDirection.clientToServer,o.type=new i.ProtocolRequestType(o.method),(r=t.InlayHintRefreshRequest||(t.InlayHintRefreshRequest={})).method="workspace/inlayHint/refresh",r.messageDirection=i.MessageDirection.serverToClient,r.type=new i.ProtocolRequestType0(r.method)},5246:(e,t,n)=>{"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.InlineValueRefreshRequest=t.InlineValueRequest=void 0;const i=n(6140);var r,o;(o=t.InlineValueRequest||(t.InlineValueRequest={})).method="textDocument/inlineValue",o.messageDirection=i.MessageDirection.clientToServer,o.type=new i.ProtocolRequestType(o.method),(r=t.InlineValueRefreshRequest||(t.InlineValueRefreshRequest={})).method="workspace/inlineValue/refresh",r.messageDirection=i.MessageDirection.serverToClient,r.type=new i.ProtocolRequestType0(r.method)},542:(e,t,n)=>{"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.WorkspaceSymbolRequest=t.CodeActionResolveRequest=t.CodeActionRequest=t.DocumentSymbolRequest=t.DocumentHighlightRequest=t.ReferencesRequest=t.DefinitionRequest=t.SignatureHelpRequest=t.SignatureHelpTriggerKind=t.HoverRequest=t.CompletionResolveRequest=t.CompletionRequest=t.CompletionTriggerKind=t.PublishDiagnosticsNotification=t.WatchKind=t.RelativePattern=t.FileChangeType=t.DidChangeWatchedFilesNotification=t.WillSaveTextDocumentWaitUntilRequest=t.WillSaveTextDocumentNotification=t.TextDocumentSaveReason=t.DidSaveTextDocumentNotification=t.DidCloseTextDocumentNotification=t.DidChangeTextDocumentNotification=t.TextDocumentContentChangeEvent=t.DidOpenTextDocumentNotification=t.TextDocumentSyncKind=t.TelemetryEventNotification=t.LogMessageNotification=t.ShowMessageRequest=t.ShowMessageNotification=t.MessageType=t.DidChangeConfigurationNotification=t.ExitNotification=t.ShutdownRequest=t.InitializedNotification=t.InitializeErrorCodes=t.InitializeRequest=t.WorkDoneProgressOptions=t.TextDocumentRegistrationOptions=t.StaticRegistrationOptions=t.PositionEncodingKind=t.FailureHandlingKind=t.ResourceOperationKind=t.UnregistrationRequest=t.RegistrationRequest=t.DocumentSelector=t.NotebookCellTextDocumentFilter=t.NotebookDocumentFilter=t.TextDocumentFilter=void 0,t.TypeHierarchySubtypesRequest=t.TypeHierarchyPrepareRequest=t.MonikerRequest=t.MonikerKind=t.UniquenessLevel=t.WillDeleteFilesRequest=t.DidDeleteFilesNotification=t.WillRenameFilesRequest=t.DidRenameFilesNotification=t.WillCreateFilesRequest=t.DidCreateFilesNotification=t.FileOperationPatternKind=t.LinkedEditingRangeRequest=t.ShowDocumentRequest=t.SemanticTokensRegistrationType=t.SemanticTokensRefreshRequest=t.SemanticTokensRangeRequest=t.SemanticTokensDeltaRequest=t.SemanticTokensRequest=t.TokenFormat=t.CallHierarchyPrepareRequest=t.CallHierarchyOutgoingCallsRequest=t.CallHierarchyIncomingCallsRequest=t.WorkDoneProgressCancelNotification=t.WorkDoneProgressCreateRequest=t.WorkDoneProgress=t.SelectionRangeRequest=t.DeclarationRequest=t.FoldingRangeRequest=t.ColorPresentationRequest=t.DocumentColorRequest=t.ConfigurationRequest=t.DidChangeWorkspaceFoldersNotification=t.WorkspaceFoldersRequest=t.TypeDefinitionRequest=t.ImplementationRequest=t.ApplyWorkspaceEditRequest=t.ExecuteCommandRequest=t.PrepareRenameRequest=t.RenameRequest=t.PrepareSupportDefaultBehavior=t.DocumentOnTypeFormattingRequest=t.DocumentRangeFormattingRequest=t.DocumentFormattingRequest=t.DocumentLinkResolveRequest=t.DocumentLinkRequest=t.CodeLensRefreshRequest=t.CodeLensResolveRequest=t.CodeLensRequest=t.WorkspaceSymbolResolveRequest=void 0,t.DidCloseNotebookDocumentNotification=t.DidSaveNotebookDocumentNotification=t.DidChangeNotebookDocumentNotification=t.NotebookCellArrayChange=t.DidOpenNotebookDocumentNotification=t.NotebookDocumentSyncRegistrationType=t.NotebookDocument=t.NotebookCell=t.ExecutionSummary=t.NotebookCellKind=t.DiagnosticRefreshRequest=t.WorkspaceDiagnosticRequest=t.DocumentDiagnosticRequest=t.DocumentDiagnosticReportKind=t.DiagnosticServerCancellationData=t.InlayHintRefreshRequest=t.InlayHintResolveRequest=t.InlayHintRequest=t.InlineValueRefreshRequest=t.InlineValueRequest=t.TypeHierarchySupertypesRequest=void 0;const i=n(6140),r=n(1674),o=n(9533),s=n(2122);Object.defineProperty(t,"ImplementationRequest",{enumerable:!0,get:function(){return s.ImplementationRequest}});const a=n(1589);Object.defineProperty(t,"TypeDefinitionRequest",{enumerable:!0,get:function(){return a.TypeDefinitionRequest}});const c=n(8744);Object.defineProperty(t,"WorkspaceFoldersRequest",{enumerable:!0,get:function(){return c.WorkspaceFoldersRequest}}),Object.defineProperty(t,"DidChangeWorkspaceFoldersNotification",{enumerable:!0,get:function(){return c.DidChangeWorkspaceFoldersNotification}});const u=n(5934);Object.defineProperty(t,"ConfigurationRequest",{enumerable:!0,get:function(){return u.ConfigurationRequest}});const l=n(9891);Object.defineProperty(t,"DocumentColorRequest",{enumerable:!0,get:function(){return l.DocumentColorRequest}}),Object.defineProperty(t,"ColorPresentationRequest",{enumerable:!0,get:function(){return l.ColorPresentationRequest}});const d=n(3394);Object.defineProperty(t,"FoldingRangeRequest",{enumerable:!0,get:function(){return d.FoldingRangeRequest}});const f=n(764);Object.defineProperty(t,"DeclarationRequest",{enumerable:!0,get:function(){return f.DeclarationRequest}});const p=n(5206);Object.defineProperty(t,"SelectionRangeRequest",{enumerable:!0,get:function(){return p.SelectionRangeRequest}});const g=n(1862);Object.defineProperty(t,"WorkDoneProgress",{enumerable:!0,get:function(){return g.WorkDoneProgress}}),Object.defineProperty(t,"WorkDoneProgressCreateRequest",{enumerable:!0,get:function(){return g.WorkDoneProgressCreateRequest}}),Object.defineProperty(t,"WorkDoneProgressCancelNotification",{enumerable:!0,get:function(){return g.WorkDoneProgressCancelNotification}});const h=n(2918);Object.defineProperty(t,"CallHierarchyIncomingCallsRequest",{enumerable:!0,get:function(){return h.CallHierarchyIncomingCallsRequest}}),Object.defineProperty(t,"CallHierarchyOutgoingCallsRequest",{enumerable:!0,get:function(){return h.CallHierarchyOutgoingCallsRequest}}),Object.defineProperty(t,"CallHierarchyPrepareRequest",{enumerable:!0,get:function(){return h.CallHierarchyPrepareRequest}});const m=n(9434);Object.defineProperty(t,"TokenFormat",{enumerable:!0,get:function(){return m.TokenFormat}}),Object.defineProperty(t,"SemanticTokensRequest",{enumerable:!0,get:function(){return m.SemanticTokensRequest}}),Object.defineProperty(t,"SemanticTokensDeltaRequest",{enumerable:!0,get:function(){return m.SemanticTokensDeltaRequest}}),Object.defineProperty(t,"SemanticTokensRangeRequest",{enumerable:!0,get:function(){return m.SemanticTokensRangeRequest}}),Object.defineProperty(t,"SemanticTokensRefreshRequest",{enumerable:!0,get:function(){return m.SemanticTokensRefreshRequest}}),Object.defineProperty(t,"SemanticTokensRegistrationType",{enumerable:!0,get:function(){return m.SemanticTokensRegistrationType}});const v=n(5726);Object.defineProperty(t,"ShowDocumentRequest",{enumerable:!0,get:function(){return v.ShowDocumentRequest}});const y=n(6305);Object.defineProperty(t,"LinkedEditingRangeRequest",{enumerable:!0,get:function(){return y.LinkedEditingRangeRequest}});const S=n(7846);Object.defineProperty(t,"FileOperationPatternKind",{enumerable:!0,get:function(){return S.FileOperationPatternKind}}),Object.defineProperty(t,"DidCreateFilesNotification",{enumerable:!0,get:function(){return S.DidCreateFilesNotification}}),Object.defineProperty(t,"WillCreateFilesRequest",{enumerable:!0,get:function(){return S.WillCreateFilesRequest}}),Object.defineProperty(t,"DidRenameFilesNotification",{enumerable:!0,get:function(){return S.DidRenameFilesNotification}}),Object.defineProperty(t,"WillRenameFilesRequest",{enumerable:!0,get:function(){return S.WillRenameFilesRequest}}),Object.defineProperty(t,"DidDeleteFilesNotification",{enumerable:!0,get:function(){return S.DidDeleteFilesNotification}}),Object.defineProperty(t,"WillDeleteFilesRequest",{enumerable:!0,get:function(){return S.WillDeleteFilesRequest}});const C=n(3443);Object.defineProperty(t,"UniquenessLevel",{enumerable:!0,get:function(){return C.UniquenessLevel}}),Object.defineProperty(t,"MonikerKind",{enumerable:!0,get:function(){return C.MonikerKind}}),Object.defineProperty(t,"MonikerRequest",{enumerable:!0,get:function(){return C.MonikerRequest}});const T=n(3693);Object.defineProperty(t,"TypeHierarchyPrepareRequest",{enumerable:!0,get:function(){return T.TypeHierarchyPrepareRequest}}),Object.defineProperty(t,"TypeHierarchySubtypesRequest",{enumerable:!0,get:function(){return T.TypeHierarchySubtypesRequest}}),Object.defineProperty(t,"TypeHierarchySupertypesRequest",{enumerable:!0,get:function(){return T.TypeHierarchySupertypesRequest}});const b=n(5246);Object.defineProperty(t,"InlineValueRequest",{enumerable:!0,get:function(){return b.InlineValueRequest}}),Object.defineProperty(t,"InlineValueRefreshRequest",{enumerable:!0,get:function(){return b.InlineValueRefreshRequest}});const _=n(9999);Object.defineProperty(t,"InlayHintRequest",{enumerable:!0,get:function(){return _.InlayHintRequest}}),Object.defineProperty(t,"InlayHintResolveRequest",{enumerable:!0,get:function(){return _.InlayHintResolveRequest}}),Object.defineProperty(t,"InlayHintRefreshRequest",{enumerable:!0,get:function(){return _.InlayHintRefreshRequest}});const R=n(9824);Object.defineProperty(t,"DiagnosticServerCancellationData",{enumerable:!0,get:function(){return R.DiagnosticServerCancellationData}}),Object.defineProperty(t,"DocumentDiagnosticReportKind",{enumerable:!0,get:function(){return R.DocumentDiagnosticReportKind}}),Object.defineProperty(t,"DocumentDiagnosticRequest",{enumerable:!0,get:function(){return R.DocumentDiagnosticRequest}}),Object.defineProperty(t,"WorkspaceDiagnosticRequest",{enumerable:!0,get:function(){return R.WorkspaceDiagnosticRequest}}),Object.defineProperty(t,"DiagnosticRefreshRequest",{enumerable:!0,get:function(){return R.DiagnosticRefreshRequest}});const D=n(7169);var w,E,P,k,x,N,O,I,A,F,M,L,q,j,U,H,K,W,z,V,B,$,G,J,Y,Z,X,Q,ee,te,ne,ie,re,oe,se,ae,ce,ue,le,de,fe,pe,ge,he,me,ve,ye,Se,Ce,Te,be,_e,Re,De,we,Ee,Pe,ke,xe;Object.defineProperty(t,"NotebookCellKind",{enumerable:!0,get:function(){return D.NotebookCellKind}}),Object.defineProperty(t,"ExecutionSummary",{enumerable:!0,get:function(){return D.ExecutionSummary}}),Object.defineProperty(t,"NotebookCell",{enumerable:!0,get:function(){return D.NotebookCell}}),Object.defineProperty(t,"NotebookDocument",{enumerable:!0,get:function(){return D.NotebookDocument}}),Object.defineProperty(t,"NotebookDocumentSyncRegistrationType",{enumerable:!0,get:function(){return D.NotebookDocumentSyncRegistrationType}}),Object.defineProperty(t,"DidOpenNotebookDocumentNotification",{enumerable:!0,get:function(){return D.DidOpenNotebookDocumentNotification}}),Object.defineProperty(t,"NotebookCellArrayChange",{enumerable:!0,get:function(){return D.NotebookCellArrayChange}}),Object.defineProperty(t,"DidChangeNotebookDocumentNotification",{enumerable:!0,get:function(){return D.DidChangeNotebookDocumentNotification}}),Object.defineProperty(t,"DidSaveNotebookDocumentNotification",{enumerable:!0,get:function(){return D.DidSaveNotebookDocumentNotification}}),Object.defineProperty(t,"DidCloseNotebookDocumentNotification",{enumerable:!0,get:function(){return D.DidCloseNotebookDocumentNotification}}),function(e){e.is=function(e){const t=e;return o.string(t.language)||o.string(t.scheme)||o.string(t.pattern)}}(w=t.TextDocumentFilter||(t.TextDocumentFilter={})),function(e){e.is=function(e){const t=e;return o.objectLiteral(t)&&(o.string(t.notebookType)||o.string(t.scheme)||o.string(t.pattern))}}(E=t.NotebookDocumentFilter||(t.NotebookDocumentFilter={})),function(e){e.is=function(e){const t=e;return o.objectLiteral(t)&&(o.string(t.notebook)||E.is(t.notebook))&&(void 0===t.language||o.string(t.language))}}(P=t.NotebookCellTextDocumentFilter||(t.NotebookCellTextDocumentFilter={})),function(e){e.is=function(e){if(!Array.isArray(e))return!1;for(let t of e)if(!o.string(t)&&!w.is(t)&&!P.is(t))return!1;return!0}}(k=t.DocumentSelector||(t.DocumentSelector={})),(xe=t.RegistrationRequest||(t.RegistrationRequest={})).method="client/registerCapability",xe.messageDirection=i.MessageDirection.serverToClient,xe.type=new i.ProtocolRequestType(xe.method),(ke=t.UnregistrationRequest||(t.UnregistrationRequest={})).method="client/unregisterCapability",ke.messageDirection=i.MessageDirection.serverToClient,ke.type=new i.ProtocolRequestType(ke.method),(Pe=t.ResourceOperationKind||(t.ResourceOperationKind={})).Create="create",Pe.Rename="rename",Pe.Delete="delete",(Ee=t.FailureHandlingKind||(t.FailureHandlingKind={})).Abort="abort",Ee.Transactional="transactional",Ee.TextOnlyTransactional="textOnlyTransactional",Ee.Undo="undo",(we=t.PositionEncodingKind||(t.PositionEncodingKind={})).UTF8="utf-8",we.UTF16="utf-16",we.UTF32="utf-32",(t.StaticRegistrationOptions||(t.StaticRegistrationOptions={})).hasId=function(e){const t=e;return t&&o.string(t.id)&&t.id.length>0},(t.TextDocumentRegistrationOptions||(t.TextDocumentRegistrationOptions={})).is=function(e){const t=e;return t&&(null===t.documentSelector||k.is(t.documentSelector))},(De=t.WorkDoneProgressOptions||(t.WorkDoneProgressOptions={})).is=function(e){const t=e;return o.objectLiteral(t)&&(void 0===t.workDoneProgress||o.boolean(t.workDoneProgress))},De.hasWorkDoneProgress=function(e){const t=e;return t&&o.boolean(t.workDoneProgress)},(Re=t.InitializeRequest||(t.InitializeRequest={})).method="initialize",Re.messageDirection=i.MessageDirection.clientToServer,Re.type=new i.ProtocolRequestType(Re.method),(t.InitializeErrorCodes||(t.InitializeErrorCodes={})).unknownProtocolVersion=1,(_e=t.InitializedNotification||(t.InitializedNotification={})).method="initialized",_e.messageDirection=i.MessageDirection.clientToServer,_e.type=new i.ProtocolNotificationType(_e.method),(be=t.ShutdownRequest||(t.ShutdownRequest={})).method="shutdown",be.messageDirection=i.MessageDirection.clientToServer,be.type=new i.ProtocolRequestType0(be.method),(Te=t.ExitNotification||(t.ExitNotification={})).method="exit",Te.messageDirection=i.MessageDirection.clientToServer,Te.type=new i.ProtocolNotificationType0(Te.method),(Ce=t.DidChangeConfigurationNotification||(t.DidChangeConfigurationNotification={})).method="workspace/didChangeConfiguration",Ce.messageDirection=i.MessageDirection.clientToServer,Ce.type=new i.ProtocolNotificationType(Ce.method),(Se=t.MessageType||(t.MessageType={})).Error=1,Se.Warning=2,Se.Info=3,Se.Log=4,(ye=t.ShowMessageNotification||(t.ShowMessageNotification={})).method="window/showMessage",ye.messageDirection=i.MessageDirection.serverToClient,ye.type=new i.ProtocolNotificationType(ye.method),(ve=t.ShowMessageRequest||(t.ShowMessageRequest={})).method="window/showMessageRequest",ve.messageDirection=i.MessageDirection.serverToClient,ve.type=new i.ProtocolRequestType(ve.method),(me=t.LogMessageNotification||(t.LogMessageNotification={})).method="window/logMessage",me.messageDirection=i.MessageDirection.serverToClient,me.type=new i.ProtocolNotificationType(me.method),(he=t.TelemetryEventNotification||(t.TelemetryEventNotification={})).method="telemetry/event",he.messageDirection=i.MessageDirection.serverToClient,he.type=new i.ProtocolNotificationType(he.method),(ge=t.TextDocumentSyncKind||(t.TextDocumentSyncKind={})).None=0,ge.Full=1,ge.Incremental=2,(pe=t.DidOpenTextDocumentNotification||(t.DidOpenTextDocumentNotification={})).method="textDocument/didOpen",pe.messageDirection=i.MessageDirection.clientToServer,pe.type=new i.ProtocolNotificationType(pe.method),(fe=t.TextDocumentContentChangeEvent||(t.TextDocumentContentChangeEvent={})).isIncremental=function(e){let t=e;return null!=t&&"string"==typeof t.text&&void 0!==t.range&&(void 0===t.rangeLength||"number"==typeof t.rangeLength)},fe.isFull=function(e){let t=e;return null!=t&&"string"==typeof t.text&&void 0===t.range&&void 0===t.rangeLength},(de=t.DidChangeTextDocumentNotification||(t.DidChangeTextDocumentNotification={})).method="textDocument/didChange",de.messageDirection=i.MessageDirection.clientToServer,de.type=new i.ProtocolNotificationType(de.method),(le=t.DidCloseTextDocumentNotification||(t.DidCloseTextDocumentNotification={})).method="textDocument/didClose",le.messageDirection=i.MessageDirection.clientToServer,le.type=new i.ProtocolNotificationType(le.method),(ue=t.DidSaveTextDocumentNotification||(t.DidSaveTextDocumentNotification={})).method="textDocument/didSave",ue.messageDirection=i.MessageDirection.clientToServer,ue.type=new i.ProtocolNotificationType(ue.method),(ce=t.TextDocumentSaveReason||(t.TextDocumentSaveReason={})).Manual=1,ce.AfterDelay=2,ce.FocusOut=3,(ae=t.WillSaveTextDocumentNotification||(t.WillSaveTextDocumentNotification={})).method="textDocument/willSave",ae.messageDirection=i.MessageDirection.clientToServer,ae.type=new i.ProtocolNotificationType(ae.method),(se=t.WillSaveTextDocumentWaitUntilRequest||(t.WillSaveTextDocumentWaitUntilRequest={})).method="textDocument/willSaveWaitUntil",se.messageDirection=i.MessageDirection.clientToServer,se.type=new i.ProtocolRequestType(se.method),(oe=t.DidChangeWatchedFilesNotification||(t.DidChangeWatchedFilesNotification={})).method="workspace/didChangeWatchedFiles",oe.messageDirection=i.MessageDirection.clientToServer,oe.type=new i.ProtocolNotificationType(oe.method),(re=t.FileChangeType||(t.FileChangeType={})).Created=1,re.Changed=2,re.Deleted=3,(t.RelativePattern||(t.RelativePattern={})).is=function(e){const t=e;return o.objectLiteral(t)&&(r.URI.is(t.baseUri)||r.WorkspaceFolder.is(t.baseUri))&&o.string(t.pattern)},(ie=t.WatchKind||(t.WatchKind={})).Create=1,ie.Change=2,ie.Delete=4,(ne=t.PublishDiagnosticsNotification||(t.PublishDiagnosticsNotification={})).method="textDocument/publishDiagnostics",ne.messageDirection=i.MessageDirection.serverToClient,ne.type=new i.ProtocolNotificationType(ne.method),(te=t.CompletionTriggerKind||(t.CompletionTriggerKind={})).Invoked=1,te.TriggerCharacter=2,te.TriggerForIncompleteCompletions=3,(ee=t.CompletionRequest||(t.CompletionRequest={})).method="textDocument/completion",ee.messageDirection=i.MessageDirection.clientToServer,ee.type=new i.ProtocolRequestType(ee.method),(Q=t.CompletionResolveRequest||(t.CompletionResolveRequest={})).method="completionItem/resolve",Q.messageDirection=i.MessageDirection.clientToServer,Q.type=new i.ProtocolRequestType(Q.method),(X=t.HoverRequest||(t.HoverRequest={})).method="textDocument/hover",X.messageDirection=i.MessageDirection.clientToServer,X.type=new i.ProtocolRequestType(X.method),(Z=t.SignatureHelpTriggerKind||(t.SignatureHelpTriggerKind={})).Invoked=1,Z.TriggerCharacter=2,Z.ContentChange=3,(Y=t.SignatureHelpRequest||(t.SignatureHelpRequest={})).method="textDocument/signatureHelp",Y.messageDirection=i.MessageDirection.clientToServer,Y.type=new i.ProtocolRequestType(Y.method),(J=t.DefinitionRequest||(t.DefinitionRequest={})).method="textDocument/definition",J.messageDirection=i.MessageDirection.clientToServer,J.type=new i.ProtocolRequestType(J.method),(G=t.ReferencesRequest||(t.ReferencesRequest={})).method="textDocument/references",G.messageDirection=i.MessageDirection.clientToServer,G.type=new i.ProtocolRequestType(G.method),($=t.DocumentHighlightRequest||(t.DocumentHighlightRequest={})).method="textDocument/documentHighlight",$.messageDirection=i.MessageDirection.clientToServer,$.type=new i.ProtocolRequestType($.method),(B=t.DocumentSymbolRequest||(t.DocumentSymbolRequest={})).method="textDocument/documentSymbol",B.messageDirection=i.MessageDirection.clientToServer,B.type=new i.ProtocolRequestType(B.method),(V=t.CodeActionRequest||(t.CodeActionRequest={})).method="textDocument/codeAction",V.messageDirection=i.MessageDirection.clientToServer,V.type=new i.ProtocolRequestType(V.method),(z=t.CodeActionResolveRequest||(t.CodeActionResolveRequest={})).method="codeAction/resolve",z.messageDirection=i.MessageDirection.clientToServer,z.type=new i.ProtocolRequestType(z.method),(W=t.WorkspaceSymbolRequest||(t.WorkspaceSymbolRequest={})).method="workspace/symbol",W.messageDirection=i.MessageDirection.clientToServer,W.type=new i.ProtocolRequestType(W.method),(K=t.WorkspaceSymbolResolveRequest||(t.WorkspaceSymbolResolveRequest={})).method="workspaceSymbol/resolve",K.messageDirection=i.MessageDirection.clientToServer,K.type=new i.ProtocolRequestType(K.method),(H=t.CodeLensRequest||(t.CodeLensRequest={})).method="textDocument/codeLens",H.messageDirection=i.MessageDirection.clientToServer,H.type=new i.ProtocolRequestType(H.method),(U=t.CodeLensResolveRequest||(t.CodeLensResolveRequest={})).method="codeLens/resolve",U.messageDirection=i.MessageDirection.clientToServer,U.type=new i.ProtocolRequestType(U.method),(j=t.CodeLensRefreshRequest||(t.CodeLensRefreshRequest={})).method="workspace/codeLens/refresh",j.messageDirection=i.MessageDirection.serverToClient,j.type=new i.ProtocolRequestType0(j.method),(q=t.DocumentLinkRequest||(t.DocumentLinkRequest={})).method="textDocument/documentLink",q.messageDirection=i.MessageDirection.clientToServer,q.type=new i.ProtocolRequestType(q.method),(L=t.DocumentLinkResolveRequest||(t.DocumentLinkResolveRequest={})).method="documentLink/resolve",L.messageDirection=i.MessageDirection.clientToServer,L.type=new i.ProtocolRequestType(L.method),(M=t.DocumentFormattingRequest||(t.DocumentFormattingRequest={})).method="textDocument/formatting",M.messageDirection=i.MessageDirection.clientToServer,M.type=new i.ProtocolRequestType(M.method),(F=t.DocumentRangeFormattingRequest||(t.DocumentRangeFormattingRequest={})).method="textDocument/rangeFormatting",F.messageDirection=i.MessageDirection.clientToServer,F.type=new i.ProtocolRequestType(F.method),(A=t.DocumentOnTypeFormattingRequest||(t.DocumentOnTypeFormattingRequest={})).method="textDocument/onTypeFormatting",A.messageDirection=i.MessageDirection.clientToServer,A.type=new i.ProtocolRequestType(A.method),(t.PrepareSupportDefaultBehavior||(t.PrepareSupportDefaultBehavior={})).Identifier=1,(I=t.RenameRequest||(t.RenameRequest={})).method="textDocument/rename",I.messageDirection=i.MessageDirection.clientToServer,I.type=new i.ProtocolRequestType(I.method),(O=t.PrepareRenameRequest||(t.PrepareRenameRequest={})).method="textDocument/prepareRename",O.messageDirection=i.MessageDirection.clientToServer,O.type=new i.ProtocolRequestType(O.method),(N=t.ExecuteCommandRequest||(t.ExecuteCommandRequest={})).method="workspace/executeCommand",N.messageDirection=i.MessageDirection.clientToServer,N.type=new i.ProtocolRequestType(N.method),(x=t.ApplyWorkspaceEditRequest||(t.ApplyWorkspaceEditRequest={})).method="workspace/applyEdit",x.messageDirection=i.MessageDirection.serverToClient,x.type=new i.ProtocolRequestType("workspace/applyEdit")},6305:(e,t,n)=>{"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.LinkedEditingRangeRequest=void 0;const i=n(6140);var r;(r=t.LinkedEditingRangeRequest||(t.LinkedEditingRangeRequest={})).method="textDocument/linkedEditingRange",r.messageDirection=i.MessageDirection.clientToServer,r.type=new i.ProtocolRequestType(r.method)},3443:(e,t,n)=>{"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.MonikerRequest=t.MonikerKind=t.UniquenessLevel=void 0;const i=n(6140);var r,o,s;(s=t.UniquenessLevel||(t.UniquenessLevel={})).document="document",s.project="project",s.group="group",s.scheme="scheme",s.global="global",(o=t.MonikerKind||(t.MonikerKind={})).$import="import",o.$export="export",o.local="local",(r=t.MonikerRequest||(t.MonikerRequest={})).method="textDocument/moniker",r.messageDirection=i.MessageDirection.clientToServer,r.type=new i.ProtocolRequestType(r.method)},7169:(e,t,n)=>{"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.DidCloseNotebookDocumentNotification=t.DidSaveNotebookDocumentNotification=t.DidChangeNotebookDocumentNotification=t.NotebookCellArrayChange=t.DidOpenNotebookDocumentNotification=t.NotebookDocumentSyncRegistrationType=t.NotebookDocument=t.NotebookCell=t.ExecutionSummary=t.NotebookCellKind=void 0;const i=n(1674),r=n(9533),o=n(6140);var s,a,c,u,l,d,f,p,g,h;!function(e){e.Markup=1,e.Code=2,e.is=function(e){return 1===e||2===e}}(s=t.NotebookCellKind||(t.NotebookCellKind={})),function(e){e.create=function(e,t){const n={executionOrder:e};return!0!==t&&!1!==t||(n.success=t),n},e.is=function(e){const t=e;return r.objectLiteral(t)&&i.uinteger.is(t.executionOrder)&&(void 0===t.success||r.boolean(t.success))},e.equals=function(e,t){return e===t||null!=e&&null!=t&&e.executionOrder===t.executionOrder&&e.success===t.success}}(a=t.ExecutionSummary||(t.ExecutionSummary={})),function(e){function t(e,n){if(e===n)return!0;if(null==e||null==n)return!1;if(typeof e!=typeof n)return!1;if("object"!=typeof e)return!1;const i=Array.isArray(e),o=Array.isArray(n);if(i!==o)return!1;if(i&&o){if(e.length!==n.length)return!1;for(let i=0;i{"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.WorkDoneProgressCancelNotification=t.WorkDoneProgressCreateRequest=t.WorkDoneProgress=void 0;const i=n(8337),r=n(6140);var o,s,a;(a=t.WorkDoneProgress||(t.WorkDoneProgress={})).type=new i.ProgressType,a.is=function(e){return e===a.type},(s=t.WorkDoneProgressCreateRequest||(t.WorkDoneProgressCreateRequest={})).method="window/workDoneProgress/create",s.messageDirection=r.MessageDirection.serverToClient,s.type=new r.ProtocolRequestType(s.method),(o=t.WorkDoneProgressCancelNotification||(t.WorkDoneProgressCancelNotification={})).method="window/workDoneProgress/cancel",o.messageDirection=r.MessageDirection.clientToServer,o.type=new r.ProtocolNotificationType(o.method)},5206:(e,t,n)=>{"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.SelectionRangeRequest=void 0;const i=n(6140);var r;(r=t.SelectionRangeRequest||(t.SelectionRangeRequest={})).method="textDocument/selectionRange",r.messageDirection=i.MessageDirection.clientToServer,r.type=new i.ProtocolRequestType(r.method)},9434:(e,t,n)=>{"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.SemanticTokensRefreshRequest=t.SemanticTokensRangeRequest=t.SemanticTokensDeltaRequest=t.SemanticTokensRequest=t.SemanticTokensRegistrationType=t.TokenFormat=void 0;const i=n(6140);var r,o,s,a,c;(t.TokenFormat||(t.TokenFormat={})).Relative="relative",function(e){e.method="textDocument/semanticTokens",e.type=new i.RegistrationType(e.method)}(r=t.SemanticTokensRegistrationType||(t.SemanticTokensRegistrationType={})),(c=t.SemanticTokensRequest||(t.SemanticTokensRequest={})).method="textDocument/semanticTokens/full",c.messageDirection=i.MessageDirection.clientToServer,c.type=new i.ProtocolRequestType(c.method),c.registrationMethod=r.method,(a=t.SemanticTokensDeltaRequest||(t.SemanticTokensDeltaRequest={})).method="textDocument/semanticTokens/full/delta",a.messageDirection=i.MessageDirection.clientToServer,a.type=new i.ProtocolRequestType(a.method),a.registrationMethod=r.method,(s=t.SemanticTokensRangeRequest||(t.SemanticTokensRangeRequest={})).method="textDocument/semanticTokens/range",s.messageDirection=i.MessageDirection.clientToServer,s.type=new i.ProtocolRequestType(s.method),s.registrationMethod=r.method,(o=t.SemanticTokensRefreshRequest||(t.SemanticTokensRefreshRequest={})).method="workspace/semanticTokens/refresh",o.messageDirection=i.MessageDirection.serverToClient,o.type=new i.ProtocolRequestType0(o.method)},5726:(e,t,n)=>{"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.ShowDocumentRequest=void 0;const i=n(6140);var r;(r=t.ShowDocumentRequest||(t.ShowDocumentRequest={})).method="window/showDocument",r.messageDirection=i.MessageDirection.serverToClient,r.type=new i.ProtocolRequestType(r.method)},1589:(e,t,n)=>{"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.TypeDefinitionRequest=void 0;const i=n(6140);var r;(r=t.TypeDefinitionRequest||(t.TypeDefinitionRequest={})).method="textDocument/typeDefinition",r.messageDirection=i.MessageDirection.clientToServer,r.type=new i.ProtocolRequestType(r.method)},3693:(e,t,n)=>{"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.TypeHierarchySubtypesRequest=t.TypeHierarchySupertypesRequest=t.TypeHierarchyPrepareRequest=void 0;const i=n(6140);var r,o,s;(s=t.TypeHierarchyPrepareRequest||(t.TypeHierarchyPrepareRequest={})).method="textDocument/prepareTypeHierarchy",s.messageDirection=i.MessageDirection.clientToServer,s.type=new i.ProtocolRequestType(s.method),(o=t.TypeHierarchySupertypesRequest||(t.TypeHierarchySupertypesRequest={})).method="typeHierarchy/supertypes",o.messageDirection=i.MessageDirection.clientToServer,o.type=new i.ProtocolRequestType(o.method),(r=t.TypeHierarchySubtypesRequest||(t.TypeHierarchySubtypesRequest={})).method="typeHierarchy/subtypes",r.messageDirection=i.MessageDirection.clientToServer,r.type=new i.ProtocolRequestType(r.method)},8744:(e,t,n)=>{"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.DidChangeWorkspaceFoldersNotification=t.WorkspaceFoldersRequest=void 0;const i=n(6140);var r,o;(o=t.WorkspaceFoldersRequest||(t.WorkspaceFoldersRequest={})).method="workspace/workspaceFolders",o.messageDirection=i.MessageDirection.serverToClient,o.type=new i.ProtocolRequestType0(o.method),(r=t.DidChangeWorkspaceFoldersNotification||(t.DidChangeWorkspaceFoldersNotification={})).method="workspace/didChangeWorkspaceFolders",r.messageDirection=i.MessageDirection.clientToServer,r.type=new i.ProtocolNotificationType(r.method)},9533:(e,t)=>{"use strict";function n(e){return"string"==typeof e||e instanceof String}function i(e){return Array.isArray(e)}Object.defineProperty(t,"__esModule",{value:!0}),t.objectLiteral=t.typedArray=t.stringArray=t.array=t.func=t.error=t.number=t.string=t.boolean=void 0,t.boolean=function(e){return!0===e||!1===e},t.string=n,t.number=function(e){return"number"==typeof e||e instanceof Number},t.error=function(e){return e instanceof Error},t.func=function(e){return"function"==typeof e},t.array=i,t.stringArray=function(e){return i(e)&&e.every((e=>n(e)))},t.typedArray=function(e,t){return Array.isArray(e)&&e.every(t)},t.objectLiteral=function(e){return null!==e&&"object"==typeof e}},380:(e,t,n)=>{"use strict";e.exports=n(8337)},8337:function(e,t,n){"use strict";var i=this&&this.__createBinding||(Object.create?function(e,t,n,i){void 0===i&&(i=n);var r=Object.getOwnPropertyDescriptor(t,n);r&&!("get"in r?!t.__esModule:r.writable||r.configurable)||(r={enumerable:!0,get:function(){return t[n]}}),Object.defineProperty(e,i,r)}:function(e,t,n,i){void 0===i&&(i=n),e[i]=t[n]}),r=this&&this.__exportStar||function(e,t){for(var n in e)"default"===n||Object.prototype.hasOwnProperty.call(t,n)||i(t,e,n)};Object.defineProperty(t,"__esModule",{value:!0}),t.createMessageConnection=t.BrowserMessageWriter=t.BrowserMessageReader=void 0,n(1106).default.install();const o=n(5575);r(n(5575),t);class s extends o.AbstractMessageReader{constructor(e){super(),this._onData=new o.Emitter,this._messageListener=e=>{this._onData.fire(e.data)},e.addEventListener("error",(e=>this.fireError(e))),e.onmessage=this._messageListener}listen(e){return this._onData.event(e)}}t.BrowserMessageReader=s;class a extends o.AbstractMessageWriter{constructor(e){super(),this.port=e,this.errorCount=0,e.addEventListener("error",(e=>this.fireError(e)))}write(e){try{return this.port.postMessage(e),Promise.resolve()}catch(t){return this.handleError(t,e),Promise.reject(t)}}handleError(e,t){this.errorCount++,this.fireError(e,t,this.errorCount)}end(){}}t.BrowserMessageWriter=a,t.createMessageConnection=function(e,t,n,i){return void 0===n&&(n=o.NullLogger),o.ConnectionStrategy.is(i)&&(i={connectionStrategy:i}),(0,o.createMessageConnection)(e,t,n,i)}},1106:(e,t,n)=>{"use strict";var i=n(5108);Object.defineProperty(t,"__esModule",{value:!0});const r=n(5575);class o extends r.AbstractMessageBuffer{constructor(e="utf-8"){super(e),this.asciiDecoder=new TextDecoder("ascii")}emptyBuffer(){return o.emptyBuffer}fromString(e,t){return(new TextEncoder).encode(e)}toString(e,t){return"ascii"===t?this.asciiDecoder.decode(e):new TextDecoder(t).decode(e)}asNative(e,t){return void 0===t?e:e.slice(0,t)}allocNative(e){return new Uint8Array(e)}}o.emptyBuffer=new Uint8Array(0);class s{constructor(e){this.socket=e,this._onData=new r.Emitter,this._messageListener=e=>{e.data.arrayBuffer().then((e=>{this._onData.fire(new Uint8Array(e))}),(()=>{(0,r.RAL)().console.error("Converting blob to array buffer failed.")}))},this.socket.addEventListener("message",this._messageListener)}onClose(e){return this.socket.addEventListener("close",e),r.Disposable.create((()=>this.socket.removeEventListener("close",e)))}onError(e){return this.socket.addEventListener("error",e),r.Disposable.create((()=>this.socket.removeEventListener("error",e)))}onEnd(e){return this.socket.addEventListener("end",e),r.Disposable.create((()=>this.socket.removeEventListener("end",e)))}onData(e){return this._onData.event(e)}}class a{constructor(e){this.socket=e}onClose(e){return this.socket.addEventListener("close",e),r.Disposable.create((()=>this.socket.removeEventListener("close",e)))}onError(e){return this.socket.addEventListener("error",e),r.Disposable.create((()=>this.socket.removeEventListener("error",e)))}onEnd(e){return this.socket.addEventListener("end",e),r.Disposable.create((()=>this.socket.removeEventListener("end",e)))}write(e,t){if("string"==typeof e){if(void 0!==t&&"utf-8"!==t)throw new Error(`In a Browser environments only utf-8 text encoding is supported. But got encoding: ${t}`);this.socket.send(e)}else this.socket.send(e);return Promise.resolve()}end(){this.socket.close()}}const c=new TextEncoder,u=Object.freeze({messageBuffer:Object.freeze({create:e=>new o(e)}),applicationJson:Object.freeze({encoder:Object.freeze({name:"application/json",encode:(e,t)=>{if("utf-8"!==t.charset)throw new Error(`In a Browser environments only utf-8 text encoding is supported. But got encoding: ${t.charset}`);return Promise.resolve(c.encode(JSON.stringify(e,void 0,0)))}}),decoder:Object.freeze({name:"application/json",decode:(e,t)=>{if(!(e instanceof Uint8Array))throw new Error("In a Browser environments only Uint8Arrays are supported.");return Promise.resolve(JSON.parse(new TextDecoder(t.charset).decode(e)))}})}),stream:Object.freeze({asReadableStream:e=>new s(e),asWritableStream:e=>new a(e)}),console:i,timer:Object.freeze({setTimeout(e,t,...n){const i=setTimeout(e,t,...n);return{dispose:()=>clearTimeout(i)}},setImmediate(e,...t){const n=setTimeout(e,0,...t);return{dispose:()=>clearTimeout(n)}},setInterval(e,t,...n){const i=setInterval(e,t,...n);return{dispose:()=>clearInterval(i)}}})});function l(){return u}!function(e){e.install=function(){r.RAL.install(u)}}(l||(l={})),t.default=l},5575:(e,t,n)=>{"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.ProgressType=t.ProgressToken=t.createMessageConnection=t.NullLogger=t.ConnectionOptions=t.ConnectionStrategy=t.AbstractMessageBuffer=t.WriteableStreamMessageWriter=t.AbstractMessageWriter=t.MessageWriter=t.ReadableStreamMessageReader=t.AbstractMessageReader=t.MessageReader=t.SharedArrayReceiverStrategy=t.SharedArraySenderStrategy=t.CancellationToken=t.CancellationTokenSource=t.Emitter=t.Event=t.Disposable=t.LRUCache=t.Touch=t.LinkedMap=t.ParameterStructures=t.NotificationType9=t.NotificationType8=t.NotificationType7=t.NotificationType6=t.NotificationType5=t.NotificationType4=t.NotificationType3=t.NotificationType2=t.NotificationType1=t.NotificationType0=t.NotificationType=t.ErrorCodes=t.ResponseError=t.RequestType9=t.RequestType8=t.RequestType7=t.RequestType6=t.RequestType5=t.RequestType4=t.RequestType3=t.RequestType2=t.RequestType1=t.RequestType0=t.RequestType=t.Message=t.RAL=void 0,t.MessageStrategy=t.CancellationStrategy=t.CancellationSenderStrategy=t.CancellationReceiverStrategy=t.ConnectionError=t.ConnectionErrors=t.LogTraceNotification=t.SetTraceNotification=t.TraceFormat=t.TraceValues=t.Trace=void 0;const i=n(1407);Object.defineProperty(t,"Message",{enumerable:!0,get:function(){return i.Message}}),Object.defineProperty(t,"RequestType",{enumerable:!0,get:function(){return i.RequestType}}),Object.defineProperty(t,"RequestType0",{enumerable:!0,get:function(){return i.RequestType0}}),Object.defineProperty(t,"RequestType1",{enumerable:!0,get:function(){return i.RequestType1}}),Object.defineProperty(t,"RequestType2",{enumerable:!0,get:function(){return i.RequestType2}}),Object.defineProperty(t,"RequestType3",{enumerable:!0,get:function(){return i.RequestType3}}),Object.defineProperty(t,"RequestType4",{enumerable:!0,get:function(){return i.RequestType4}}),Object.defineProperty(t,"RequestType5",{enumerable:!0,get:function(){return i.RequestType5}}),Object.defineProperty(t,"RequestType6",{enumerable:!0,get:function(){return i.RequestType6}}),Object.defineProperty(t,"RequestType7",{enumerable:!0,get:function(){return i.RequestType7}}),Object.defineProperty(t,"RequestType8",{enumerable:!0,get:function(){return i.RequestType8}}),Object.defineProperty(t,"RequestType9",{enumerable:!0,get:function(){return i.RequestType9}}),Object.defineProperty(t,"ResponseError",{enumerable:!0,get:function(){return i.ResponseError}}),Object.defineProperty(t,"ErrorCodes",{enumerable:!0,get:function(){return i.ErrorCodes}}),Object.defineProperty(t,"NotificationType",{enumerable:!0,get:function(){return i.NotificationType}}),Object.defineProperty(t,"NotificationType0",{enumerable:!0,get:function(){return i.NotificationType0}}),Object.defineProperty(t,"NotificationType1",{enumerable:!0,get:function(){return i.NotificationType1}}),Object.defineProperty(t,"NotificationType2",{enumerable:!0,get:function(){return i.NotificationType2}}),Object.defineProperty(t,"NotificationType3",{enumerable:!0,get:function(){return i.NotificationType3}}),Object.defineProperty(t,"NotificationType4",{enumerable:!0,get:function(){return i.NotificationType4}}),Object.defineProperty(t,"NotificationType5",{enumerable:!0,get:function(){return i.NotificationType5}}),Object.defineProperty(t,"NotificationType6",{enumerable:!0,get:function(){return i.NotificationType6}}),Object.defineProperty(t,"NotificationType7",{enumerable:!0,get:function(){return i.NotificationType7}}),Object.defineProperty(t,"NotificationType8",{enumerable:!0,get:function(){return i.NotificationType8}}),Object.defineProperty(t,"NotificationType9",{enumerable:!0,get:function(){return i.NotificationType9}}),Object.defineProperty(t,"ParameterStructures",{enumerable:!0,get:function(){return i.ParameterStructures}});const r=n(1546);Object.defineProperty(t,"LinkedMap",{enumerable:!0,get:function(){return r.LinkedMap}}),Object.defineProperty(t,"LRUCache",{enumerable:!0,get:function(){return r.LRUCache}}),Object.defineProperty(t,"Touch",{enumerable:!0,get:function(){return r.Touch}});const o=n(4687);Object.defineProperty(t,"Disposable",{enumerable:!0,get:function(){return o.Disposable}});const s=n(950);Object.defineProperty(t,"Event",{enumerable:!0,get:function(){return s.Event}}),Object.defineProperty(t,"Emitter",{enumerable:!0,get:function(){return s.Emitter}});const a=n(5951);Object.defineProperty(t,"CancellationTokenSource",{enumerable:!0,get:function(){return a.CancellationTokenSource}}),Object.defineProperty(t,"CancellationToken",{enumerable:!0,get:function(){return a.CancellationToken}});const c=n(4964);Object.defineProperty(t,"SharedArraySenderStrategy",{enumerable:!0,get:function(){return c.SharedArraySenderStrategy}}),Object.defineProperty(t,"SharedArrayReceiverStrategy",{enumerable:!0,get:function(){return c.SharedArrayReceiverStrategy}});const u=n(5483);Object.defineProperty(t,"MessageReader",{enumerable:!0,get:function(){return u.MessageReader}}),Object.defineProperty(t,"AbstractMessageReader",{enumerable:!0,get:function(){return u.AbstractMessageReader}}),Object.defineProperty(t,"ReadableStreamMessageReader",{enumerable:!0,get:function(){return u.ReadableStreamMessageReader}});const l=n(9719);Object.defineProperty(t,"MessageWriter",{enumerable:!0,get:function(){return l.MessageWriter}}),Object.defineProperty(t,"AbstractMessageWriter",{enumerable:!0,get:function(){return l.AbstractMessageWriter}}),Object.defineProperty(t,"WriteableStreamMessageWriter",{enumerable:!0,get:function(){return l.WriteableStreamMessageWriter}});const d=n(3039);Object.defineProperty(t,"AbstractMessageBuffer",{enumerable:!0,get:function(){return d.AbstractMessageBuffer}});const f=n(4784);Object.defineProperty(t,"ConnectionStrategy",{enumerable:!0,get:function(){return f.ConnectionStrategy}}),Object.defineProperty(t,"ConnectionOptions",{enumerable:!0,get:function(){return f.ConnectionOptions}}),Object.defineProperty(t,"NullLogger",{enumerable:!0,get:function(){return f.NullLogger}}),Object.defineProperty(t,"createMessageConnection",{enumerable:!0,get:function(){return f.createMessageConnection}}),Object.defineProperty(t,"ProgressToken",{enumerable:!0,get:function(){return f.ProgressToken}}),Object.defineProperty(t,"ProgressType",{enumerable:!0,get:function(){return f.ProgressType}}),Object.defineProperty(t,"Trace",{enumerable:!0,get:function(){return f.Trace}}),Object.defineProperty(t,"TraceValues",{enumerable:!0,get:function(){return f.TraceValues}}),Object.defineProperty(t,"TraceFormat",{enumerable:!0,get:function(){return f.TraceFormat}}),Object.defineProperty(t,"SetTraceNotification",{enumerable:!0,get:function(){return f.SetTraceNotification}}),Object.defineProperty(t,"LogTraceNotification",{enumerable:!0,get:function(){return f.LogTraceNotification}}),Object.defineProperty(t,"ConnectionErrors",{enumerable:!0,get:function(){return f.ConnectionErrors}}),Object.defineProperty(t,"ConnectionError",{enumerable:!0,get:function(){return f.ConnectionError}}),Object.defineProperty(t,"CancellationReceiverStrategy",{enumerable:!0,get:function(){return f.CancellationReceiverStrategy}}),Object.defineProperty(t,"CancellationSenderStrategy",{enumerable:!0,get:function(){return f.CancellationSenderStrategy}}),Object.defineProperty(t,"CancellationStrategy",{enumerable:!0,get:function(){return f.CancellationStrategy}}),Object.defineProperty(t,"MessageStrategy",{enumerable:!0,get:function(){return f.MessageStrategy}});const p=n(6022);t.RAL=p.default},5951:(e,t,n)=>{"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.CancellationTokenSource=t.CancellationToken=void 0;const i=n(6022),r=n(5198),o=n(950);var s;!function(e){e.None=Object.freeze({isCancellationRequested:!1,onCancellationRequested:o.Event.None}),e.Cancelled=Object.freeze({isCancellationRequested:!0,onCancellationRequested:o.Event.None}),e.is=function(t){const n=t;return n&&(n===e.None||n===e.Cancelled||r.boolean(n.isCancellationRequested)&&!!n.onCancellationRequested)}}(s=t.CancellationToken||(t.CancellationToken={}));const a=Object.freeze((function(e,t){const n=(0,i.default)().timer.setTimeout(e.bind(t),0);return{dispose(){n.dispose()}}}));class c{constructor(){this._isCancelled=!1}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?a:(this._emitter||(this._emitter=new o.Emitter),this._emitter.event)}dispose(){this._emitter&&(this._emitter.dispose(),this._emitter=void 0)}}t.CancellationTokenSource=class{get token(){return this._token||(this._token=new c),this._token}cancel(){this._token?this._token.cancel():this._token=s.Cancelled}dispose(){this._token?this._token instanceof c&&this._token.dispose():this._token=s.None}}},4784:(e,t,n)=>{"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.createMessageConnection=t.ConnectionOptions=t.MessageStrategy=t.CancellationStrategy=t.CancellationSenderStrategy=t.CancellationReceiverStrategy=t.RequestCancellationReceiverStrategy=t.IdCancellationReceiverStrategy=t.ConnectionStrategy=t.ConnectionError=t.ConnectionErrors=t.LogTraceNotification=t.SetTraceNotification=t.TraceFormat=t.TraceValues=t.Trace=t.NullLogger=t.ProgressType=t.ProgressToken=void 0;const i=n(6022),r=n(5198),o=n(1407),s=n(1546),a=n(950),c=n(5951);var u,l,d,f,p,g,h,m,v,y,S,C,T,b,_,R,D,w;!function(e){e.type=new o.NotificationType("$/cancelRequest")}(u||(u={})),function(e){e.is=function(e){return"string"==typeof e||"number"==typeof e}}(l=t.ProgressToken||(t.ProgressToken={})),function(e){e.type=new o.NotificationType("$/progress")}(d||(d={})),t.ProgressType=class{constructor(){}},function(e){e.is=function(e){return r.func(e)}}(f||(f={})),t.NullLogger=Object.freeze({error:()=>{},warn:()=>{},info:()=>{},log:()=>{}}),function(e){e[e.Off=0]="Off",e[e.Messages=1]="Messages",e[e.Compact=2]="Compact",e[e.Verbose=3]="Verbose"}(p=t.Trace||(t.Trace={})),(w=t.TraceValues||(t.TraceValues={})).Off="off",w.Messages="messages",w.Compact="compact",w.Verbose="verbose",function(e){e.fromString=function(t){if(!r.string(t))return e.Off;switch(t=t.toLowerCase()){case"off":default:return e.Off;case"messages":return e.Messages;case"compact":return e.Compact;case"verbose":return e.Verbose}},e.toString=function(t){switch(t){case e.Off:return"off";case e.Messages:return"messages";case e.Compact:return"compact";case e.Verbose:return"verbose";default:return"off"}}}(p=t.Trace||(t.Trace={})),function(e){e.Text="text",e.JSON="json"}(t.TraceFormat||(t.TraceFormat={})),function(e){e.fromString=function(t){return r.string(t)&&"json"===(t=t.toLowerCase())?e.JSON:e.Text}}(g=t.TraceFormat||(t.TraceFormat={})),function(e){e.type=new o.NotificationType("$/setTrace")}(h=t.SetTraceNotification||(t.SetTraceNotification={})),function(e){e.type=new o.NotificationType("$/logTrace")}(m=t.LogTraceNotification||(t.LogTraceNotification={})),function(e){e[e.Closed=1]="Closed",e[e.Disposed=2]="Disposed",e[e.AlreadyListening=3]="AlreadyListening"}(v=t.ConnectionErrors||(t.ConnectionErrors={}));class E extends Error{constructor(e,t){super(t),this.code=e,Object.setPrototypeOf(this,E.prototype)}}t.ConnectionError=E,function(e){e.is=function(e){const t=e;return t&&r.func(t.cancelUndispatched)}}(y=t.ConnectionStrategy||(t.ConnectionStrategy={})),function(e){e.is=function(e){const t=e;return t&&(void 0===t.kind||"id"===t.kind)&&r.func(t.createCancellationTokenSource)&&(void 0===t.dispose||r.func(t.dispose))}}(S=t.IdCancellationReceiverStrategy||(t.IdCancellationReceiverStrategy={})),function(e){e.is=function(e){const t=e;return t&&"request"===t.kind&&r.func(t.createCancellationTokenSource)&&(void 0===t.dispose||r.func(t.dispose))}}(C=t.RequestCancellationReceiverStrategy||(t.RequestCancellationReceiverStrategy={})),function(e){e.Message=Object.freeze({createCancellationTokenSource:e=>new c.CancellationTokenSource}),e.is=function(e){return S.is(e)||C.is(e)}}(T=t.CancellationReceiverStrategy||(t.CancellationReceiverStrategy={})),function(e){e.Message=Object.freeze({sendCancellation:(e,t)=>e.sendNotification(u.type,{id:t}),cleanup(e){}}),e.is=function(e){const t=e;return t&&r.func(t.sendCancellation)&&r.func(t.cleanup)}}(b=t.CancellationSenderStrategy||(t.CancellationSenderStrategy={})),function(e){e.Message=Object.freeze({receiver:T.Message,sender:b.Message}),e.is=function(e){const t=e;return t&&T.is(t.receiver)&&b.is(t.sender)}}(_=t.CancellationStrategy||(t.CancellationStrategy={})),function(e){e.is=function(e){const t=e;return t&&r.func(t.handleMessage)}}(R=t.MessageStrategy||(t.MessageStrategy={})),(t.ConnectionOptions||(t.ConnectionOptions={})).is=function(e){const t=e;return t&&(_.is(t.cancellationStrategy)||y.is(t.connectionStrategy)||R.is(t.messageStrategy))},function(e){e[e.New=1]="New",e[e.Listening=2]="Listening",e[e.Closed=3]="Closed",e[e.Disposed=4]="Disposed"}(D||(D={})),t.createMessageConnection=function(e,n,y,C){const T=void 0!==y?y:t.NullLogger;let b=0,w=0,P=0;const k="2.0";let x;const N=new Map;let O;const I=new Map,A=new Map;let F,M,L=new s.LinkedMap,q=new Map,j=new Set,U=new Map,H=p.Off,K=g.Text,W=D.New;const z=new a.Emitter,V=new a.Emitter,B=new a.Emitter,$=new a.Emitter,G=new a.Emitter,J=C&&C.cancellationStrategy?C.cancellationStrategy:_.Message;function Y(e){if(null===e)throw new Error("Can't send requests with id null since the response can't be correlated.");return"req-"+e.toString()}function Z(e){}function X(){return W===D.Listening}function Q(){return W===D.Closed}function ee(){return W===D.Disposed}function te(){W!==D.New&&W!==D.Listening||(W=D.Closed,V.fire(void 0))}function ne(){F||0===L.size||(F=(0,i.default)().timer.setImmediate((()=>{F=void 0,function(){if(0===L.size)return;const e=L.shift();try{const t=C?.messageStrategy;R.is(t)?t.handleMessage(e,ie):ie(e)}finally{ne()}}()})))}function ie(e){o.Message.isRequest(e)?function(e){if(ee())return;function t(t,i,r){const s={jsonrpc:k,id:e.id};t instanceof o.ResponseError?s.error=t.toJson():s.result=void 0===t?null:t,se(s,i,r),n.write(s).catch((()=>T.error("Sending response failed.")))}function i(t,i,r){const o={jsonrpc:k,id:e.id,error:t.toJson()};se(o,i,r),n.write(o).catch((()=>T.error("Sending response failed.")))}!function(e){if(H!==p.Off&&M)if(K===g.Text){let t;H!==p.Verbose&&H!==p.Compact||!e.params||(t=`Params: ${oe(e.params)}\n\n`),M.log(`Received request '${e.method} - (${e.id})'.`,t)}else ce("receive-request",e)}(e);const s=N.get(e.method);let a,c;s&&(a=s.type,c=s.handler);const u=Date.now();if(c||x){const s=e.id??String(Date.now()),l=S.is(J.receiver)?J.receiver.createCancellationTokenSource(s):J.receiver.createCancellationTokenSource(e);null!==e.id&&j.has(e.id)&&l.cancel(),null!==e.id&&U.set(s,l);try{let d;if(c)if(void 0===e.params){if(void 0!==a&&0!==a.numberOfParams)return void i(new o.ResponseError(o.ErrorCodes.InvalidParams,`Request ${e.method} defines ${a.numberOfParams} params but received none.`),e.method,u);d=c(l.token)}else if(Array.isArray(e.params)){if(void 0!==a&&a.parameterStructures===o.ParameterStructures.byName)return void i(new o.ResponseError(o.ErrorCodes.InvalidParams,`Request ${e.method} defines parameters by name but received parameters by position`),e.method,u);d=c(...e.params,l.token)}else{if(void 0!==a&&a.parameterStructures===o.ParameterStructures.byPosition)return void i(new o.ResponseError(o.ErrorCodes.InvalidParams,`Request ${e.method} defines parameters by position but received parameters by name`),e.method,u);d=c(e.params,l.token)}else x&&(d=x(e.method,e.params,l.token));const f=d;d?f.then?f.then((n=>{U.delete(s),t(n,e.method,u)}),(t=>{U.delete(s),t instanceof o.ResponseError?i(t,e.method,u):t&&r.string(t.message)?i(new o.ResponseError(o.ErrorCodes.InternalError,`Request ${e.method} failed with message: ${t.message}`),e.method,u):i(new o.ResponseError(o.ErrorCodes.InternalError,`Request ${e.method} failed unexpectedly without providing any details.`),e.method,u)})):(U.delete(s),t(d,e.method,u)):(U.delete(s),function(t,i,r){void 0===t&&(t=null);const o={jsonrpc:k,id:e.id,result:t};se(o,i,r),n.write(o).catch((()=>T.error("Sending response failed.")))}(d,e.method,u))}catch(n){U.delete(s),n instanceof o.ResponseError?t(n,e.method,u):n&&r.string(n.message)?i(new o.ResponseError(o.ErrorCodes.InternalError,`Request ${e.method} failed with message: ${n.message}`),e.method,u):i(new o.ResponseError(o.ErrorCodes.InternalError,`Request ${e.method} failed unexpectedly without providing any details.`),e.method,u)}}else i(new o.ResponseError(o.ErrorCodes.MethodNotFound,`Unhandled method ${e.method}`),e.method,u)}(e):o.Message.isNotification(e)?function(e){if(ee())return;let t,n;if(e.method===u.type.method){const t=e.params.id;return j.delete(t),void ae(e)}{const i=I.get(e.method);i&&(n=i.handler,t=i.type)}if(n||O)try{if(ae(e),n)if(void 0===e.params)void 0!==t&&0!==t.numberOfParams&&t.parameterStructures!==o.ParameterStructures.byName&&T.error(`Notification ${e.method} defines ${t.numberOfParams} params but received none.`),n();else if(Array.isArray(e.params)){const i=e.params;e.method===d.type.method&&2===i.length&&l.is(i[0])?n({token:i[0],value:i[1]}):(void 0!==t&&(t.parameterStructures===o.ParameterStructures.byName&&T.error(`Notification ${e.method} defines parameters by name but received parameters by position`),t.numberOfParams!==e.params.length&&T.error(`Notification ${e.method} defines ${t.numberOfParams} params but received ${i.length} arguments`)),n(...i))}else void 0!==t&&t.parameterStructures===o.ParameterStructures.byPosition&&T.error(`Notification ${e.method} defines parameters by position but received parameters by name`),n(e.params);else O&&O(e.method,e.params)}catch(t){t.message?T.error(`Notification handler '${e.method}' failed with message: ${t.message}`):T.error(`Notification handler '${e.method}' failed unexpectedly.`)}else B.fire(e)}(e):o.Message.isResponse(e)?function(e){if(!ee())if(null===e.id)e.error?T.error(`Received response message without id: Error is: \n${JSON.stringify(e.error,void 0,4)}`):T.error("Received response message without id. No further error information provided.");else{const t=e.id,n=q.get(t);if(function(e,t){if(H!==p.Off&&M)if(K===g.Text){let n;if(H!==p.Verbose&&H!==p.Compact||(e.error&&e.error.data?n=`Error data: ${oe(e.error.data)}\n\n`:e.result?n=`Result: ${oe(e.result)}\n\n`:void 0===e.error&&(n="No result returned.\n\n")),t){const i=e.error?` Request failed: ${e.error.message} (${e.error.code}).`:"";M.log(`Received response '${t.method} - (${e.id})' in ${Date.now()-t.timerStart}ms.${i}`,n)}else M.log(`Received response ${e.id} without active response promise.`,n)}else ce("receive-response",e)}(e,n),void 0!==n){q.delete(t);try{if(e.error){const t=e.error;n.reject(new o.ResponseError(t.code,t.message,t.data))}else{if(void 0===e.result)throw new Error("Should never happen.");n.resolve(e.result)}}catch(e){e.message?T.error(`Response handler '${n.method}' failed with message: ${e.message}`):T.error(`Response handler '${n.method}' failed unexpectedly.`)}}}}(e):function(e){if(!e)return void T.error("Received empty message.");T.error(`Received message which is neither a response nor a notification message:\n${JSON.stringify(e,null,4)}`);const t=e;if(r.string(t.id)||r.number(t.id)){const e=t.id,n=q.get(e);n&&n.reject(new Error("The received response has neither a result nor an error property."))}}(e)}e.onClose(te),e.onError((function(e){z.fire([e,void 0,void 0])})),n.onClose(te),n.onError((function(e){z.fire(e)}));const re=e=>{try{if(o.Message.isNotification(e)&&e.method===u.type.method){const t=e.params.id,i=Y(t),r=L.get(i);if(o.Message.isRequest(r)){const o=C?.connectionStrategy,s=o&&o.cancelUndispatched?o.cancelUndispatched(r,Z):void 0;if(s&&(void 0!==s.error||void 0!==s.result))return L.delete(i),U.delete(t),s.id=r.id,se(s,e.method,Date.now()),void n.write(s).catch((()=>T.error("Sending response for canceled message failed.")))}const s=U.get(t);if(void 0!==s)return s.cancel(),void ae(e);j.add(t)}!function(e,t){var n;o.Message.isRequest(t)?e.set(Y(t.id),t):o.Message.isResponse(t)?e.set(null===(n=t.id)?"res-unknown-"+(++P).toString():"res-"+n.toString(),t):e.set("not-"+(++w).toString(),t)}(L,e)}finally{ne()}};function oe(e){if(null!=e)switch(H){case p.Verbose:return JSON.stringify(e,null,4);case p.Compact:return JSON.stringify(e);default:return}}function se(e,t,n){if(H!==p.Off&&M)if(K===g.Text){let i;H!==p.Verbose&&H!==p.Compact||(e.error&&e.error.data?i=`Error data: ${oe(e.error.data)}\n\n`:e.result?i=`Result: ${oe(e.result)}\n\n`:void 0===e.error&&(i="No result returned.\n\n")),M.log(`Sending response '${t} - (${e.id})'. Processing request took ${Date.now()-n}ms`,i)}else ce("send-response",e)}function ae(e){if(H!==p.Off&&M&&e.method!==m.type.method)if(K===g.Text){let t;H!==p.Verbose&&H!==p.Compact||(t=e.params?`Params: ${oe(e.params)}\n\n`:"No parameters provided.\n\n"),M.log(`Received notification '${e.method}'.`,t)}else ce("receive-notification",e)}function ce(e,t){if(!M||H===p.Off)return;const n={isLSPMessage:!0,type:e,message:t,timestamp:Date.now()};M.log(n)}function ue(){if(Q())throw new E(v.Closed,"Connection is closed.");if(ee())throw new E(v.Disposed,"Connection is disposed.")}function le(e){return void 0===e?null:e}function de(e){return null===e?void 0:e}function fe(e){return null!=e&&!Array.isArray(e)&&"object"==typeof e}function pe(e,t){switch(e){case o.ParameterStructures.auto:return fe(t)?de(t):[le(t)];case o.ParameterStructures.byName:if(!fe(t))throw new Error("Received parameters by name but param is not an object literal.");return de(t);case o.ParameterStructures.byPosition:return[le(t)];default:throw new Error(`Unknown parameter structure ${e.toString()}`)}}function ge(e,t){let n;const i=e.numberOfParams;switch(i){case 0:n=void 0;break;case 1:n=pe(e.parameterStructures,t[0]);break;default:n=[];for(let e=0;e{let i,s;if(ue(),r.string(e)){i=e;const n=t[0];let r=0,a=o.ParameterStructures.auto;o.ParameterStructures.is(n)&&(r=1,a=n);let c=t.length;const u=c-r;switch(u){case 0:s=void 0;break;case 1:s=pe(a,t[r]);break;default:if(a===o.ParameterStructures.byName)throw new Error(`Received ${u} parameters for 'by Name' notification parameter structure.`);s=t.slice(r,c).map((e=>le(e)))}}else{const n=t;i=e.method,s=ge(e,n)}const a={jsonrpc:k,method:i,params:s};return function(e){if(H!==p.Off&&M)if(K===g.Text){let t;H!==p.Verbose&&H!==p.Compact||(t=e.params?`Params: ${oe(e.params)}\n\n`:"No parameters provided.\n\n"),M.log(`Sending notification '${e.method}'.`,t)}else ce("send-notification",e)}(a),n.write(a).catch((e=>{throw T.error("Sending notification failed."),e}))},onNotification:(e,t)=>{let n;return ue(),r.func(e)?O=e:t&&(r.string(e)?(n=e,I.set(e,{type:void 0,handler:t})):(n=e.method,I.set(e.method,{type:e,handler:t}))),{dispose:()=>{void 0!==n?I.delete(n):O=void 0}}},onProgress:(e,t,n)=>{if(A.has(t))throw new Error(`Progress handler for token ${t} already registered`);return A.set(t,n),{dispose:()=>{A.delete(t)}}},sendProgress:(e,t,n)=>he.sendNotification(d.type,{token:t,value:n}),onUnhandledProgress:$.event,sendRequest:(e,...t)=>{let i,s,a;if(ue(),function(){if(!X())throw new Error("Call listen() first.")}(),r.string(e)){i=e;const n=t[0],r=t[t.length-1];let u=0,l=o.ParameterStructures.auto;o.ParameterStructures.is(n)&&(u=1,l=n);let d=t.length;c.CancellationToken.is(r)&&(d-=1,a=r);const f=d-u;switch(f){case 0:s=void 0;break;case 1:s=pe(l,t[u]);break;default:if(l===o.ParameterStructures.byName)throw new Error(`Received ${f} parameters for 'by Name' request parameter structure.`);s=t.slice(u,d).map((e=>le(e)))}}else{const n=t;i=e.method,s=ge(e,n);const r=e.numberOfParams;a=c.CancellationToken.is(n[r])?n[r]:void 0}const u=b++;let l;a&&(l=a.onCancellationRequested((()=>{const e=J.sender.sendCancellation(he,u);return void 0===e?(T.log(`Received no promise from cancellation strategy when cancelling id ${u}`),Promise.resolve()):e.catch((()=>{T.log(`Sending cancellation messages for id ${u} failed`)}))})));const d={jsonrpc:k,id:u,method:i,params:s};return function(e){if(H!==p.Off&&M)if(K===g.Text){let t;H!==p.Verbose&&H!==p.Compact||!e.params||(t=`Params: ${oe(e.params)}\n\n`),M.log(`Sending request '${e.method} - (${e.id})'.`,t)}else ce("send-request",e)}(d),"function"==typeof J.sender.enableCancellation&&J.sender.enableCancellation(d),new Promise((async(e,t)=>{const r={method:i,timerStart:Date.now(),resolve:t=>{e(t),J.sender.cleanup(u),l?.dispose()},reject:e=>{t(e),J.sender.cleanup(u),l?.dispose()}};try{await n.write(d),q.set(u,r)}catch(e){throw T.error("Sending request failed."),r.reject(new o.ResponseError(o.ErrorCodes.MessageWriteError,e.message?e.message:"Unknown reason")),e}}))},onRequest:(e,t)=>{ue();let n=null;return f.is(e)?(n=void 0,x=e):r.string(e)?(n=null,void 0!==t&&(n=e,N.set(e,{handler:t,type:void 0}))):void 0!==t&&(n=e.method,N.set(e.method,{type:e,handler:t})),{dispose:()=>{null!==n&&(void 0!==n?N.delete(n):x=void 0)}}},hasPendingResponse:()=>q.size>0,trace:async(e,t,n)=>{let i=!1,o=g.Text;void 0!==n&&(r.boolean(n)?i=n:(i=n.sendNotification||!1,o=n.traceFormat||g.Text)),H=e,K=o,M=H===p.Off?void 0:t,!i||Q()||ee()||await he.sendNotification(h.type,{value:p.toString(e)})},onError:z.event,onClose:V.event,onUnhandledNotification:B.event,onDispose:G.event,end:()=>{n.end()},dispose:()=>{if(ee())return;W=D.Disposed,G.fire(void 0);const t=new o.ResponseError(o.ErrorCodes.PendingResponseRejected,"Pending response rejected since connection got disposed");for(const e of q.values())e.reject(t);q=new Map,U=new Map,j=new Set,L=new s.LinkedMap,r.func(n.dispose)&&n.dispose(),r.func(e.dispose)&&e.dispose()},listen:()=>{ue(),function(){if(X())throw new E(v.AlreadyListening,"Connection is already listening")}(),W=D.Listening,e.listen(re)},inspect:()=>{(0,i.default)().console.log("inspect")}};return he.onNotification(m.type,(e=>{if(H===p.Off||!M)return;const t=H===p.Verbose||H===p.Compact;M.log(e.message,t?e.verbose:void 0)})),he.onNotification(d.type,(e=>{const t=A.get(e.token);t?t(e.value):$.fire(e)})),he}},4687:(e,t)=>{"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.Disposable=void 0,(t.Disposable||(t.Disposable={})).create=function(e){return{dispose:e}}},950:(e,t,n)=>{"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.Emitter=t.Event=void 0;const i=n(6022);!function(e){const t={dispose(){}};e.None=function(){return t}}(t.Event||(t.Event={}));class r{add(e,t=null,n){this._callbacks||(this._callbacks=[],this._contexts=[]),this._callbacks.push(e),this._contexts.push(t),Array.isArray(n)&&n.push({dispose:()=>this.remove(e,t)})}remove(e,t=null){if(!this._callbacks)return;let n=!1;for(let i=0,r=this._callbacks.length;i{this._callbacks||(this._callbacks=new r),this._options&&this._options.onFirstListenerAdd&&this._callbacks.isEmpty()&&this._options.onFirstListenerAdd(this),this._callbacks.add(e,t);const i={dispose:()=>{this._callbacks&&(this._callbacks.remove(e,t),i.dispose=o._noop,this._options&&this._options.onLastListenerRemove&&this._callbacks.isEmpty()&&this._options.onLastListenerRemove(this))}};return Array.isArray(n)&&n.push(i),i}),this._event}fire(e){this._callbacks&&this._callbacks.invoke.call(this._callbacks,e)}dispose(){this._callbacks&&(this._callbacks.dispose(),this._callbacks=void 0)}}t.Emitter=o,o._noop=function(){}},5198:(e,t)=>{"use strict";function n(e){return"string"==typeof e||e instanceof String}function i(e){return Array.isArray(e)}Object.defineProperty(t,"__esModule",{value:!0}),t.stringArray=t.array=t.func=t.error=t.number=t.string=t.boolean=void 0,t.boolean=function(e){return!0===e||!1===e},t.string=n,t.number=function(e){return"number"==typeof e||e instanceof Number},t.error=function(e){return e instanceof Error},t.func=function(e){return"function"==typeof e},t.array=i,t.stringArray=function(e){return i(e)&&e.every((e=>n(e)))}},1546:(e,t)=>{"use strict";var n,i;Object.defineProperty(t,"__esModule",{value:!0}),t.LRUCache=t.LinkedMap=t.Touch=void 0,function(e){e.None=0,e.First=1,e.AsOld=e.First,e.Last=2,e.AsNew=e.Last}(i=t.Touch||(t.Touch={}));class r{constructor(){this[n]="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=i.None){const n=this._map.get(e);if(n)return t!==i.None&&this.touch(n,t),n.value}set(e,t,n=i.None){let r=this._map.get(e);if(r)r.value=t,n!==i.None&&this.touch(r,n);else{switch(r={key:e,value:t,next:void 0,previous:void 0},n){case i.None:this.addItemLast(r);break;case i.First:this.addItemFirst(r);break;case i.Last:default:this.addItemLast(r)}this._map.set(e,r),this._size++}return this}delete(e){return!!this.remove(e)}remove(e){const 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");const e=this._head;return this._map.delete(e.key),this.removeItem(e),this._size--,e.value}forEach(e,t){const n=this._state;let i=this._head;for(;i;){if(t?e.bind(t)(i.value,i.key,this):e(i.value,i.key,this),this._state!==n)throw new Error("LinkedMap got modified during iteration.");i=i.next}}keys(){const e=this._state;let t=this._head;const n={[Symbol.iterator]:()=>n,next:()=>{if(this._state!==e)throw new Error("LinkedMap got modified during iteration.");if(t){const e={value:t.key,done:!1};return t=t.next,e}return{value:void 0,done:!0}}};return n}values(){const e=this._state;let t=this._head;const n={[Symbol.iterator]:()=>n,next:()=>{if(this._state!==e)throw new Error("LinkedMap got modified during iteration.");if(t){const e={value:t.value,done:!1};return t=t.next,e}return{value:void 0,done:!0}}};return n}entries(){const e=this._state;let t=this._head;const n={[Symbol.iterator]:()=>n,next:()=>{if(this._state!==e)throw new Error("LinkedMap got modified during iteration.");if(t){const e={value:[t.key,t.value],done:!1};return t=t.next,e}return{value:void 0,done:!0}}};return n}[(n=Symbol.toStringTag,Symbol.iterator)](){return this.entries()}trimOld(e){if(e>=this.size)return;if(0===e)return void this.clear();let t=this._head,n=this.size;for(;t&&n>e;)this._map.delete(t.key),t=t.next,n--;this._head=t,this._size=n,t&&(t.previous=void 0),this._state++}addItemFirst(e){if(this._head||this._tail){if(!this._head)throw new Error("Invalid list");e.next=this._head,this._head.previous=e}else this._tail=e;this._head=e,this._state++}addItemLast(e){if(this._head||this._tail){if(!this._tail)throw new Error("Invalid list");e.previous=this._tail,this._tail.next=e}else this._head=e;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{const t=e.next,n=e.previous;if(!t||!n)throw new Error("Invalid list");t.previous=n,n.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===i.First||t===i.Last)if(t===i.First){if(e===this._head)return;const t=e.next,n=e.previous;e===this._tail?(n.next=void 0,this._tail=n):(t.previous=n,n.next=t),e.previous=void 0,e.next=this._head,this._head.previous=e,this._head=e,this._state++}else if(t===i.Last){if(e===this._tail)return;const t=e.next,n=e.previous;e===this._head?(t.previous=void 0,this._head=t):(t.previous=n,n.next=t),e.next=void 0,e.previous=this._tail,this._tail.next=e,this._tail=e,this._state++}}toJSON(){const e=[];return this.forEach(((t,n)=>{e.push([n,t])})),e}fromJSON(e){this.clear();for(const[t,n]of e)this.set(t,n)}}t.LinkedMap=r,t.LRUCache=class extends r{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 ratio(){return this._ratio}set ratio(e){this._ratio=Math.min(Math.max(0,e),1),this.checkTrim()}get(e,t=i.AsNew){return super.get(e,t)}peek(e){return super.get(e,i.None)}set(e,t){return super.set(e,t,i.Last),this.checkTrim(),this}checkTrim(){this.size>this._limit&&this.trimOld(Math.round(this._limit*this._ratio))}}},3039:(e,t)=>{"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.AbstractMessageBuffer=void 0,t.AbstractMessageBuffer=class{constructor(e="utf-8"){this._encoding=e,this._chunks=[],this._totalLength=0}get encoding(){return this._encoding}append(e){const t="string"==typeof e?this.fromString(e,this._encoding):e;this._chunks.push(t),this._totalLength+=t.byteLength}tryReadHeaders(e=!1){if(0===this._chunks.length)return;let t=0,n=0,i=0,r=0;e:for(;nthis._totalLength)throw new Error("Cannot read so many bytes!");if(this._chunks[0].byteLength===e){const t=this._chunks[0];return this._chunks.shift(),this._totalLength-=e,this.asNative(t)}if(this._chunks[0].byteLength>e){const t=this._chunks[0],n=this.asNative(t,e);return this._chunks[0]=t.slice(e),this._totalLength-=e,n}const t=this.allocNative(e);let n=0;for(;e>0;){const i=this._chunks[0];if(i.byteLength>e){const r=i.slice(0,e);t.set(r,n),n+=e,this._chunks[0]=i.slice(e),this._totalLength-=e,e-=e}else t.set(i,n),n+=i.byteLength,this._chunks.shift(),this._totalLength-=i.byteLength,e-=i.byteLength}return t}}},5483:(e,t,n)=>{"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.ReadableStreamMessageReader=t.AbstractMessageReader=t.MessageReader=void 0;const i=n(6022),r=n(5198),o=n(950),s=n(1858);var a;(t.MessageReader||(t.MessageReader={})).is=function(e){let t=e;return t&&r.func(t.listen)&&r.func(t.dispose)&&r.func(t.onError)&&r.func(t.onClose)&&r.func(t.onPartialMessage)};class c{constructor(){this.errorEmitter=new o.Emitter,this.closeEmitter=new o.Emitter,this.partialMessageEmitter=new o.Emitter}dispose(){this.errorEmitter.dispose(),this.closeEmitter.dispose()}get onError(){return this.errorEmitter.event}fireError(e){this.errorEmitter.fire(this.asError(e))}get onClose(){return this.closeEmitter.event}fireClose(){this.closeEmitter.fire(void 0)}get onPartialMessage(){return this.partialMessageEmitter.event}firePartialMessage(e){this.partialMessageEmitter.fire(e)}asError(e){return e instanceof Error?e:new Error(`Reader received error. Reason: ${r.string(e.message)?e.message:"unknown"}`)}}t.AbstractMessageReader=c,function(e){e.fromOptions=function(e){let t,n;const r=new Map;let o;const s=new Map;if(void 0===e||"string"==typeof e)t=e??"utf-8";else{if(t=e.charset??"utf-8",void 0!==e.contentDecoder&&(n=e.contentDecoder,r.set(n.name,n)),void 0!==e.contentDecoders)for(const t of e.contentDecoders)r.set(t.name,t);if(void 0!==e.contentTypeDecoder&&(o=e.contentTypeDecoder,s.set(o.name,o)),void 0!==e.contentTypeDecoders)for(const t of e.contentTypeDecoders)s.set(t.name,t)}return void 0===o&&(o=(0,i.default)().applicationJson.decoder,s.set(o.name,o)),{charset:t,contentDecoder:n,contentDecoders:r,contentTypeDecoder:o,contentTypeDecoders:s}}}(a||(a={})),t.ReadableStreamMessageReader=class extends c{constructor(e,t){super(),this.readable=e,this.options=a.fromOptions(t),this.buffer=(0,i.default)().messageBuffer.create(this.options.charset),this._partialMessageTimeout=1e4,this.nextMessageLength=-1,this.messageToken=0,this.readSemaphore=new s.Semaphore(1)}set partialMessageTimeout(e){this._partialMessageTimeout=e}get partialMessageTimeout(){return this._partialMessageTimeout}listen(e){this.nextMessageLength=-1,this.messageToken=0,this.partialMessageTimer=void 0,this.callback=e;const t=this.readable.onData((e=>{this.onData(e)}));return this.readable.onError((e=>this.fireError(e))),this.readable.onClose((()=>this.fireClose())),t}onData(e){for(this.buffer.append(e);;){if(-1===this.nextMessageLength){const e=this.buffer.tryReadHeaders(!0);if(!e)return;const t=e.get("content-length");if(!t)return void this.fireError(new Error("Header must provide a Content-Length property."));const n=parseInt(t);if(isNaN(n))return void this.fireError(new Error("Content-Length value must be a number."));this.nextMessageLength=n}const e=this.buffer.tryReadBody(this.nextMessageLength);if(void 0===e)return void this.setPartialMessageTimer();this.clearPartialMessageTimer(),this.nextMessageLength=-1,this.readSemaphore.lock((async()=>{const t=void 0!==this.options.contentDecoder?await this.options.contentDecoder.decode(e):e,n=await this.options.contentTypeDecoder.decode(t,this.options);this.callback(n)})).catch((e=>{this.fireError(e)}))}}clearPartialMessageTimer(){this.partialMessageTimer&&(this.partialMessageTimer.dispose(),this.partialMessageTimer=void 0)}setPartialMessageTimer(){this.clearPartialMessageTimer(),this._partialMessageTimeout<=0||(this.partialMessageTimer=(0,i.default)().timer.setTimeout(((e,t)=>{this.partialMessageTimer=void 0,e===this.messageToken&&(this.firePartialMessage({messageToken:e,waitingTime:t}),this.setPartialMessageTimer())}),this._partialMessageTimeout,this.messageToken,this._partialMessageTimeout))}}},9719:(e,t,n)=>{"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.WriteableStreamMessageWriter=t.AbstractMessageWriter=t.MessageWriter=void 0;const i=n(6022),r=n(5198),o=n(1858),s=n(950);var a;(t.MessageWriter||(t.MessageWriter={})).is=function(e){let t=e;return t&&r.func(t.dispose)&&r.func(t.onClose)&&r.func(t.onError)&&r.func(t.write)};class c{constructor(){this.errorEmitter=new s.Emitter,this.closeEmitter=new s.Emitter}dispose(){this.errorEmitter.dispose(),this.closeEmitter.dispose()}get onError(){return this.errorEmitter.event}fireError(e,t,n){this.errorEmitter.fire([this.asError(e),t,n])}get onClose(){return this.closeEmitter.event}fireClose(){this.closeEmitter.fire(void 0)}asError(e){return e instanceof Error?e:new Error(`Writer received error. Reason: ${r.string(e.message)?e.message:"unknown"}`)}}t.AbstractMessageWriter=c,function(e){e.fromOptions=function(e){return void 0===e||"string"==typeof e?{charset:e??"utf-8",contentTypeEncoder:(0,i.default)().applicationJson.encoder}:{charset:e.charset??"utf-8",contentEncoder:e.contentEncoder,contentTypeEncoder:e.contentTypeEncoder??(0,i.default)().applicationJson.encoder}}}(a||(a={})),t.WriteableStreamMessageWriter=class extends c{constructor(e,t){super(),this.writable=e,this.options=a.fromOptions(t),this.errorCount=0,this.writeSemaphore=new o.Semaphore(1),this.writable.onError((e=>this.fireError(e))),this.writable.onClose((()=>this.fireClose()))}async write(e){return this.writeSemaphore.lock((async()=>this.options.contentTypeEncoder.encode(e,this.options).then((e=>void 0!==this.options.contentEncoder?this.options.contentEncoder.encode(e):e)).then((t=>{const n=[];return n.push("Content-Length: ",t.byteLength.toString(),"\r\n"),n.push("\r\n"),this.doWrite(e,n,t)}),(e=>{throw this.fireError(e),e}))))}async doWrite(e,t,n){try{return await this.writable.write(t.join(""),"ascii"),this.writable.write(n)}catch(t){return this.handleError(t,e),Promise.reject(t)}}handleError(e,t){this.errorCount++,this.fireError(e,t,this.errorCount)}end(){this.writable.end()}}},1407:(e,t,n)=>{"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.Message=t.NotificationType9=t.NotificationType8=t.NotificationType7=t.NotificationType6=t.NotificationType5=t.NotificationType4=t.NotificationType3=t.NotificationType2=t.NotificationType1=t.NotificationType0=t.NotificationType=t.RequestType9=t.RequestType8=t.RequestType7=t.RequestType6=t.RequestType5=t.RequestType4=t.RequestType3=t.RequestType2=t.RequestType1=t.RequestType=t.RequestType0=t.AbstractMessageSignature=t.ParameterStructures=t.ResponseError=t.ErrorCodes=void 0;const i=n(5198);var r,o;!function(e){e.ParseError=-32700,e.InvalidRequest=-32600,e.MethodNotFound=-32601,e.InvalidParams=-32602,e.InternalError=-32603,e.jsonrpcReservedErrorRangeStart=-32099,e.serverErrorStart=-32099,e.MessageWriteError=-32099,e.MessageReadError=-32098,e.PendingResponseRejected=-32097,e.ConnectionInactive=-32096,e.ServerNotInitialized=-32002,e.UnknownErrorCode=-32001,e.jsonrpcReservedErrorRangeEnd=-32e3,e.serverErrorEnd=-32e3}(r=t.ErrorCodes||(t.ErrorCodes={}));class s extends Error{constructor(e,t,n){super(t),this.code=i.number(e)?e:r.UnknownErrorCode,this.data=n,Object.setPrototypeOf(this,s.prototype)}toJson(){const e={code:this.code,message:this.message};return void 0!==this.data&&(e.data=this.data),e}}t.ResponseError=s;class a{constructor(e){this.kind=e}static is(e){return e===a.auto||e===a.byName||e===a.byPosition}toString(){return this.kind}}t.ParameterStructures=a,a.auto=new a("auto"),a.byPosition=new a("byPosition"),a.byName=new a("byName");class c{constructor(e,t){this.method=e,this.numberOfParams=t}get parameterStructures(){return a.auto}}t.AbstractMessageSignature=c,t.RequestType0=class extends c{constructor(e){super(e,0)}},t.RequestType=class extends c{constructor(e,t=a.auto){super(e,1),this._parameterStructures=t}get parameterStructures(){return this._parameterStructures}},t.RequestType1=class extends c{constructor(e,t=a.auto){super(e,1),this._parameterStructures=t}get parameterStructures(){return this._parameterStructures}},t.RequestType2=class extends c{constructor(e){super(e,2)}},t.RequestType3=class extends c{constructor(e){super(e,3)}},t.RequestType4=class extends c{constructor(e){super(e,4)}},t.RequestType5=class extends c{constructor(e){super(e,5)}},t.RequestType6=class extends c{constructor(e){super(e,6)}},t.RequestType7=class extends c{constructor(e){super(e,7)}},t.RequestType8=class extends c{constructor(e){super(e,8)}},t.RequestType9=class extends c{constructor(e){super(e,9)}},t.NotificationType=class extends c{constructor(e,t=a.auto){super(e,1),this._parameterStructures=t}get parameterStructures(){return this._parameterStructures}},t.NotificationType0=class extends c{constructor(e){super(e,0)}},t.NotificationType1=class extends c{constructor(e,t=a.auto){super(e,1),this._parameterStructures=t}get parameterStructures(){return this._parameterStructures}},t.NotificationType2=class extends c{constructor(e){super(e,2)}},t.NotificationType3=class extends c{constructor(e){super(e,3)}},t.NotificationType4=class extends c{constructor(e){super(e,4)}},t.NotificationType5=class extends c{constructor(e){super(e,5)}},t.NotificationType6=class extends c{constructor(e){super(e,6)}},t.NotificationType7=class extends c{constructor(e){super(e,7)}},t.NotificationType8=class extends c{constructor(e){super(e,8)}},t.NotificationType9=class extends c{constructor(e){super(e,9)}},(o=t.Message||(t.Message={})).isRequest=function(e){const t=e;return t&&i.string(t.method)&&(i.string(t.id)||i.number(t.id))},o.isNotification=function(e){const t=e;return t&&i.string(t.method)&&void 0===e.id},o.isResponse=function(e){const t=e;return t&&(void 0!==t.result||!!t.error)&&(i.string(t.id)||i.number(t.id)||null===t.id)}},6022:(e,t)=>{"use strict";let n;function i(){if(void 0===n)throw new Error("No runtime abstraction layer installed");return n}Object.defineProperty(t,"__esModule",{value:!0}),function(e){e.install=function(e){if(void 0===e)throw new Error("No runtime abstraction layer provided");n=e}}(i||(i={})),t.default=i},1858:(e,t,n)=>{"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.Semaphore=void 0;const i=n(6022);t.Semaphore=class{constructor(e=1){if(e<=0)throw new Error("Capacity must be greater than 0");this._capacity=e,this._active=0,this._waiting=[]}lock(e){return new Promise(((t,n)=>{this._waiting.push({thunk:e,resolve:t,reject:n}),this.runNext()}))}get active(){return this._active}runNext(){0!==this._waiting.length&&this._active!==this._capacity&&(0,i.default)().timer.setImmediate((()=>this.doRunNext()))}doRunNext(){if(0===this._waiting.length||this._active===this._capacity)return;const e=this._waiting.shift();if(this._active++,this._active>this._capacity)throw new Error("To many thunks active");try{const t=e.thunk();t instanceof Promise?t.then((t=>{this._active--,e.resolve(t),this.runNext()}),(t=>{this._active--,e.reject(t),this.runNext()})):(this._active--,e.resolve(t),this.runNext())}catch(t){this._active--,e.reject(t),this.runNext()}}}},4964:(e,t,n)=>{"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.SharedArrayReceiverStrategy=t.SharedArraySenderStrategy=void 0;const i=n(5951);var r;!function(e){e.Continue=0,e.Cancelled=1}(r||(r={})),t.SharedArraySenderStrategy=class{constructor(){this.buffers=new Map}enableCancellation(e){if(null===e.id)return;const t=new SharedArrayBuffer(4);new Int32Array(t,0,1)[0]=r.Continue,this.buffers.set(e.id,t),e.$cancellationData=t}async sendCancellation(e,t){const n=this.buffers.get(t);if(void 0===n)return;const i=new Int32Array(n,0,1);Atomics.store(i,0,r.Cancelled)}cleanup(e){this.buffers.delete(e)}dispose(){this.buffers.clear()}};class o{constructor(e){this.data=new Int32Array(e,0,1)}get isCancellationRequested(){return Atomics.load(this.data,0)===r.Cancelled}get onCancellationRequested(){throw new Error("Cancellation over SharedArrayBuffer doesn't support cancellation events")}}class s{constructor(e){this.token=new o(e)}cancel(){}dispose(){}}t.SharedArrayReceiverStrategy=class{constructor(){this.kind="request"}createCancellationTokenSource(e){const t=e.$cancellationData;return void 0===t?new i.CancellationTokenSource:new s(t)}}},1674:(e,t,n)=>{"use strict";var i,r,o,s,a,c,u,l,d,f,p,g,h,m,v,y,S,C,T,b,_,R,D,w,E,P,k,x;n.r(t),n.d(t,{AnnotatedTextEdit:()=>D,ChangeAnnotation:()=>_,ChangeAnnotationIdentifier:()=>R,CodeAction:()=>oe,CodeActionContext:()=>re,CodeActionKind:()=>ne,CodeActionTriggerKind:()=>ie,CodeDescription:()=>S,CodeLens:()=>se,Color:()=>d,ColorInformation:()=>f,ColorPresentation:()=>p,Command:()=>T,CompletionItem:()=>W,CompletionItemKind:()=>L,CompletionItemLabelDetails:()=>K,CompletionItemTag:()=>j,CompletionList:()=>z,CreateFile:()=>E,DeleteFile:()=>k,Diagnostic:()=>C,DiagnosticRelatedInformation:()=>m,DiagnosticSeverity:()=>v,DiagnosticTag:()=>y,DocumentHighlight:()=>Y,DocumentHighlightKind:()=>J,DocumentLink:()=>ce,DocumentSymbol:()=>te,DocumentUri:()=>i,EOL:()=>De,FoldingRange:()=>h,FoldingRangeKind:()=>g,FormattingOptions:()=>ae,Hover:()=>B,InlayHint:()=>Se,InlayHintKind:()=>ve,InlayHintLabelPart:()=>ye,InlineValueContext:()=>me,InlineValueEvaluatableExpression:()=>he,InlineValueText:()=>pe,InlineValueVariableLookup:()=>ge,InsertReplaceEdit:()=>U,InsertTextFormat:()=>q,InsertTextMode:()=>H,Location:()=>u,LocationLink:()=>l,MarkedString:()=>V,MarkupContent:()=>M,MarkupKind:()=>F,OptionalVersionedTextDocumentIdentifier:()=>I,ParameterInformation:()=>$,Position:()=>a,Range:()=>c,RenameFile:()=>P,SelectionRange:()=>ue,SemanticTokenModifiers:()=>de,SemanticTokenTypes:()=>le,SemanticTokens:()=>fe,SignatureInformation:()=>G,SymbolInformation:()=>Q,SymbolKind:()=>Z,SymbolTag:()=>X,TextDocument:()=>Re,TextDocumentEdit:()=>w,TextDocumentIdentifier:()=>N,TextDocumentItem:()=>A,TextEdit:()=>b,URI:()=>r,VersionedTextDocumentIdentifier:()=>O,WorkspaceChange:()=>_e,WorkspaceEdit:()=>x,WorkspaceFolder:()=>Ce,WorkspaceSymbol:()=>ee,integer:()=>o,uinteger:()=>s}),function(e){e.is=function(e){return"string"==typeof e}}(i||(i={})),function(e){e.is=function(e){return"string"==typeof e}}(r||(r={})),function(e){e.MIN_VALUE=-2147483648,e.MAX_VALUE=2147483647,e.is=function(t){return"number"==typeof t&&e.MIN_VALUE<=t&&t<=e.MAX_VALUE}}(o||(o={})),function(e){e.MIN_VALUE=0,e.MAX_VALUE=2147483647,e.is=function(t){return"number"==typeof t&&e.MIN_VALUE<=t&&t<=e.MAX_VALUE}}(s||(s={})),function(e){e.create=function(e,t){return e===Number.MAX_VALUE&&(e=s.MAX_VALUE),t===Number.MAX_VALUE&&(t=s.MAX_VALUE),{line:e,character:t}},e.is=function(e){var t=e;return we.objectLiteral(t)&&we.uinteger(t.line)&&we.uinteger(t.character)}}(a||(a={})),function(e){e.create=function(e,t,n,i){if(we.uinteger(e)&&we.uinteger(t)&&we.uinteger(n)&&we.uinteger(i))return{start:a.create(e,t),end:a.create(n,i)};if(a.is(e)&&a.is(t))return{start:e,end:t};throw new Error("Range#create called with invalid arguments[".concat(e,", ").concat(t,", ").concat(n,", ").concat(i,"]"))},e.is=function(e){var t=e;return we.objectLiteral(t)&&a.is(t.start)&&a.is(t.end)}}(c||(c={})),function(e){e.create=function(e,t){return{uri:e,range:t}},e.is=function(e){var t=e;return we.objectLiteral(t)&&c.is(t.range)&&(we.string(t.uri)||we.undefined(t.uri))}}(u||(u={})),function(e){e.create=function(e,t,n,i){return{targetUri:e,targetRange:t,targetSelectionRange:n,originSelectionRange:i}},e.is=function(e){var t=e;return we.objectLiteral(t)&&c.is(t.targetRange)&&we.string(t.targetUri)&&c.is(t.targetSelectionRange)&&(c.is(t.originSelectionRange)||we.undefined(t.originSelectionRange))}}(l||(l={})),function(e){e.create=function(e,t,n,i){return{red:e,green:t,blue:n,alpha:i}},e.is=function(e){var t=e;return we.objectLiteral(t)&&we.numberRange(t.red,0,1)&&we.numberRange(t.green,0,1)&&we.numberRange(t.blue,0,1)&&we.numberRange(t.alpha,0,1)}}(d||(d={})),function(e){e.create=function(e,t){return{range:e,color:t}},e.is=function(e){var t=e;return we.objectLiteral(t)&&c.is(t.range)&&d.is(t.color)}}(f||(f={})),function(e){e.create=function(e,t,n){return{label:e,textEdit:t,additionalTextEdits:n}},e.is=function(e){var t=e;return we.objectLiteral(t)&&we.string(t.label)&&(we.undefined(t.textEdit)||b.is(t))&&(we.undefined(t.additionalTextEdits)||we.typedArray(t.additionalTextEdits,b.is))}}(p||(p={})),function(e){e.Comment="comment",e.Imports="imports",e.Region="region"}(g||(g={})),function(e){e.create=function(e,t,n,i,r,o){var s={startLine:e,endLine:t};return we.defined(n)&&(s.startCharacter=n),we.defined(i)&&(s.endCharacter=i),we.defined(r)&&(s.kind=r),we.defined(o)&&(s.collapsedText=o),s},e.is=function(e){var t=e;return we.objectLiteral(t)&&we.uinteger(t.startLine)&&we.uinteger(t.startLine)&&(we.undefined(t.startCharacter)||we.uinteger(t.startCharacter))&&(we.undefined(t.endCharacter)||we.uinteger(t.endCharacter))&&(we.undefined(t.kind)||we.string(t.kind))}}(h||(h={})),function(e){e.create=function(e,t){return{location:e,message:t}},e.is=function(e){var t=e;return we.defined(t)&&u.is(t.location)&&we.string(t.message)}}(m||(m={})),function(e){e.Error=1,e.Warning=2,e.Information=3,e.Hint=4}(v||(v={})),function(e){e.Unnecessary=1,e.Deprecated=2}(y||(y={})),function(e){e.is=function(e){var t=e;return we.objectLiteral(t)&&we.string(t.href)}}(S||(S={})),function(e){e.create=function(e,t,n,i,r,o){var s={range:e,message:t};return we.defined(n)&&(s.severity=n),we.defined(i)&&(s.code=i),we.defined(r)&&(s.source=r),we.defined(o)&&(s.relatedInformation=o),s},e.is=function(e){var t,n=e;return we.defined(n)&&c.is(n.range)&&we.string(n.message)&&(we.number(n.severity)||we.undefined(n.severity))&&(we.integer(n.code)||we.string(n.code)||we.undefined(n.code))&&(we.undefined(n.codeDescription)||we.string(null===(t=n.codeDescription)||void 0===t?void 0:t.href))&&(we.string(n.source)||we.undefined(n.source))&&(we.undefined(n.relatedInformation)||we.typedArray(n.relatedInformation,m.is))}}(C||(C={})),function(e){e.create=function(e,t){for(var n=[],i=2;i0&&(r.arguments=n),r},e.is=function(e){var t=e;return we.defined(t)&&we.string(t.title)&&we.string(t.command)}}(T||(T={})),function(e){e.replace=function(e,t){return{range:e,newText:t}},e.insert=function(e,t){return{range:{start:e,end:e},newText:t}},e.del=function(e){return{range:e,newText:""}},e.is=function(e){var t=e;return we.objectLiteral(t)&&we.string(t.newText)&&c.is(t.range)}}(b||(b={})),function(e){e.create=function(e,t,n){var i={label:e};return void 0!==t&&(i.needsConfirmation=t),void 0!==n&&(i.description=n),i},e.is=function(e){var t=e;return we.objectLiteral(t)&&we.string(t.label)&&(we.boolean(t.needsConfirmation)||void 0===t.needsConfirmation)&&(we.string(t.description)||void 0===t.description)}}(_||(_={})),function(e){e.is=function(e){var t=e;return we.string(t)}}(R||(R={})),function(e){e.replace=function(e,t,n){return{range:e,newText:t,annotationId:n}},e.insert=function(e,t,n){return{range:{start:e,end:e},newText:t,annotationId:n}},e.del=function(e,t){return{range:e,newText:"",annotationId:t}},e.is=function(e){var t=e;return b.is(t)&&(_.is(t.annotationId)||R.is(t.annotationId))}}(D||(D={})),function(e){e.create=function(e,t){return{textDocument:e,edits:t}},e.is=function(e){var t=e;return we.defined(t)&&I.is(t.textDocument)&&Array.isArray(t.edits)}}(w||(w={})),function(e){e.create=function(e,t,n){var i={kind:"create",uri:e};return void 0===t||void 0===t.overwrite&&void 0===t.ignoreIfExists||(i.options=t),void 0!==n&&(i.annotationId=n),i},e.is=function(e){var t=e;return t&&"create"===t.kind&&we.string(t.uri)&&(void 0===t.options||(void 0===t.options.overwrite||we.boolean(t.options.overwrite))&&(void 0===t.options.ignoreIfExists||we.boolean(t.options.ignoreIfExists)))&&(void 0===t.annotationId||R.is(t.annotationId))}}(E||(E={})),function(e){e.create=function(e,t,n,i){var r={kind:"rename",oldUri:e,newUri:t};return void 0===n||void 0===n.overwrite&&void 0===n.ignoreIfExists||(r.options=n),void 0!==i&&(r.annotationId=i),r},e.is=function(e){var t=e;return t&&"rename"===t.kind&&we.string(t.oldUri)&&we.string(t.newUri)&&(void 0===t.options||(void 0===t.options.overwrite||we.boolean(t.options.overwrite))&&(void 0===t.options.ignoreIfExists||we.boolean(t.options.ignoreIfExists)))&&(void 0===t.annotationId||R.is(t.annotationId))}}(P||(P={})),function(e){e.create=function(e,t,n){var i={kind:"delete",uri:e};return void 0===t||void 0===t.recursive&&void 0===t.ignoreIfNotExists||(i.options=t),void 0!==n&&(i.annotationId=n),i},e.is=function(e){var t=e;return t&&"delete"===t.kind&&we.string(t.uri)&&(void 0===t.options||(void 0===t.options.recursive||we.boolean(t.options.recursive))&&(void 0===t.options.ignoreIfNotExists||we.boolean(t.options.ignoreIfNotExists)))&&(void 0===t.annotationId||R.is(t.annotationId))}}(k||(k={})),function(e){e.is=function(e){var t=e;return t&&(void 0!==t.changes||void 0!==t.documentChanges)&&(void 0===t.documentChanges||t.documentChanges.every((function(e){return we.string(e.kind)?E.is(e)||P.is(e)||k.is(e):w.is(e)})))}}(x||(x={}));var N,O,I,A,F,M,L,q,j,U,H,K,W,z,V,B,$,G,J,Y,Z,X,Q,ee,te,ne,ie,re,oe,se,ae,ce,ue,le,de,fe,pe,ge,he,me,ve,ye,Se,Ce,Te=function(){function e(e,t){this.edits=e,this.changeAnnotations=t}return e.prototype.insert=function(e,t,n){var i,r;if(void 0===n?i=b.insert(e,t):R.is(n)?(r=n,i=D.insert(e,t,n)):(this.assertChangeAnnotations(this.changeAnnotations),r=this.changeAnnotations.manage(n),i=D.insert(e,t,r)),this.edits.push(i),void 0!==r)return r},e.prototype.replace=function(e,t,n){var i,r;if(void 0===n?i=b.replace(e,t):R.is(n)?(r=n,i=D.replace(e,t,n)):(this.assertChangeAnnotations(this.changeAnnotations),r=this.changeAnnotations.manage(n),i=D.replace(e,t,r)),this.edits.push(i),void 0!==r)return r},e.prototype.delete=function(e,t){var n,i;if(void 0===t?n=b.del(e):R.is(t)?(i=t,n=D.del(e,t)):(this.assertChangeAnnotations(this.changeAnnotations),i=this.changeAnnotations.manage(t),n=D.del(e,i)),this.edits.push(n),void 0!==i)return i},e.prototype.add=function(e){this.edits.push(e)},e.prototype.all=function(){return this.edits},e.prototype.clear=function(){this.edits.splice(0,this.edits.length)},e.prototype.assertChangeAnnotations=function(e){if(void 0===e)throw new Error("Text edit change is not configured to manage change annotations.")},e}(),be=function(){function e(e){this._annotations=void 0===e?Object.create(null):e,this._counter=0,this._size=0}return e.prototype.all=function(){return this._annotations},Object.defineProperty(e.prototype,"size",{get:function(){return this._size},enumerable:!1,configurable:!0}),e.prototype.manage=function(e,t){var n;if(R.is(e)?n=e:(n=this.nextId(),t=e),void 0!==this._annotations[n])throw new Error("Id ".concat(n," is already in use."));if(void 0===t)throw new Error("No annotation provided for id ".concat(n));return this._annotations[n]=t,this._size++,n},e.prototype.nextId=function(){return this._counter++,this._counter.toString()},e}(),_e=function(){function e(e){var t=this;this._textEditChanges=Object.create(null),void 0!==e?(this._workspaceEdit=e,e.documentChanges?(this._changeAnnotations=new be(e.changeAnnotations),e.changeAnnotations=this._changeAnnotations.all(),e.documentChanges.forEach((function(e){if(w.is(e)){var n=new Te(e.edits,t._changeAnnotations);t._textEditChanges[e.textDocument.uri]=n}}))):e.changes&&Object.keys(e.changes).forEach((function(n){var i=new Te(e.changes[n]);t._textEditChanges[n]=i}))):this._workspaceEdit={}}return Object.defineProperty(e.prototype,"edit",{get:function(){return this.initDocumentChanges(),void 0!==this._changeAnnotations&&(0===this._changeAnnotations.size?this._workspaceEdit.changeAnnotations=void 0:this._workspaceEdit.changeAnnotations=this._changeAnnotations.all()),this._workspaceEdit},enumerable:!1,configurable:!0}),e.prototype.getTextEditChange=function(e){if(I.is(e)){if(this.initDocumentChanges(),void 0===this._workspaceEdit.documentChanges)throw new Error("Workspace edit is not configured for document changes.");var t={uri:e.uri,version:e.version};if(!(i=this._textEditChanges[t.uri])){var n={textDocument:t,edits:r=[]};this._workspaceEdit.documentChanges.push(n),i=new Te(r,this._changeAnnotations),this._textEditChanges[t.uri]=i}return i}if(this.initChanges(),void 0===this._workspaceEdit.changes)throw new Error("Workspace edit is not configured for normal text edit changes.");var i;if(!(i=this._textEditChanges[e])){var r=[];this._workspaceEdit.changes[e]=r,i=new Te(r),this._textEditChanges[e]=i}return i},e.prototype.initDocumentChanges=function(){void 0===this._workspaceEdit.documentChanges&&void 0===this._workspaceEdit.changes&&(this._changeAnnotations=new be,this._workspaceEdit.documentChanges=[],this._workspaceEdit.changeAnnotations=this._changeAnnotations.all())},e.prototype.initChanges=function(){void 0===this._workspaceEdit.documentChanges&&void 0===this._workspaceEdit.changes&&(this._workspaceEdit.changes=Object.create(null))},e.prototype.createFile=function(e,t,n){if(this.initDocumentChanges(),void 0===this._workspaceEdit.documentChanges)throw new Error("Workspace edit is not configured for document changes.");var i,r,o;if(_.is(t)||R.is(t)?i=t:n=t,void 0===i?r=E.create(e,n):(o=R.is(i)?i:this._changeAnnotations.manage(i),r=E.create(e,n,o)),this._workspaceEdit.documentChanges.push(r),void 0!==o)return o},e.prototype.renameFile=function(e,t,n,i){if(this.initDocumentChanges(),void 0===this._workspaceEdit.documentChanges)throw new Error("Workspace edit is not configured for document changes.");var r,o,s;if(_.is(n)||R.is(n)?r=n:i=n,void 0===r?o=P.create(e,t,i):(s=R.is(r)?r:this._changeAnnotations.manage(r),o=P.create(e,t,i,s)),this._workspaceEdit.documentChanges.push(o),void 0!==s)return s},e.prototype.deleteFile=function(e,t,n){if(this.initDocumentChanges(),void 0===this._workspaceEdit.documentChanges)throw new Error("Workspace edit is not configured for document changes.");var i,r,o;if(_.is(t)||R.is(t)?i=t:n=t,void 0===i?r=k.create(e,n):(o=R.is(i)?i:this._changeAnnotations.manage(i),r=k.create(e,n,o)),this._workspaceEdit.documentChanges.push(r),void 0!==o)return o},e}();!function(e){e.create=function(e){return{uri:e}},e.is=function(e){var t=e;return we.defined(t)&&we.string(t.uri)}}(N||(N={})),function(e){e.create=function(e,t){return{uri:e,version:t}},e.is=function(e){var t=e;return we.defined(t)&&we.string(t.uri)&&we.integer(t.version)}}(O||(O={})),function(e){e.create=function(e,t){return{uri:e,version:t}},e.is=function(e){var t=e;return we.defined(t)&&we.string(t.uri)&&(null===t.version||we.integer(t.version))}}(I||(I={})),function(e){e.create=function(e,t,n,i){return{uri:e,languageId:t,version:n,text:i}},e.is=function(e){var t=e;return we.defined(t)&&we.string(t.uri)&&we.string(t.languageId)&&we.integer(t.version)&&we.string(t.text)}}(A||(A={})),function(e){e.PlainText="plaintext",e.Markdown="markdown",e.is=function(t){var n=t;return n===e.PlainText||n===e.Markdown}}(F||(F={})),function(e){e.is=function(e){var t=e;return we.objectLiteral(e)&&F.is(t.kind)&&we.string(t.value)}}(M||(M={})),function(e){e.Text=1,e.Method=2,e.Function=3,e.Constructor=4,e.Field=5,e.Variable=6,e.Class=7,e.Interface=8,e.Module=9,e.Property=10,e.Unit=11,e.Value=12,e.Enum=13,e.Keyword=14,e.Snippet=15,e.Color=16,e.File=17,e.Reference=18,e.Folder=19,e.EnumMember=20,e.Constant=21,e.Struct=22,e.Event=23,e.Operator=24,e.TypeParameter=25}(L||(L={})),function(e){e.PlainText=1,e.Snippet=2}(q||(q={})),function(e){e.Deprecated=1}(j||(j={})),function(e){e.create=function(e,t,n){return{newText:e,insert:t,replace:n}},e.is=function(e){var t=e;return t&&we.string(t.newText)&&c.is(t.insert)&&c.is(t.replace)}}(U||(U={})),function(e){e.asIs=1,e.adjustIndentation=2}(H||(H={})),function(e){e.is=function(e){var t=e;return t&&(we.string(t.detail)||void 0===t.detail)&&(we.string(t.description)||void 0===t.description)}}(K||(K={})),function(e){e.create=function(e){return{label:e}}}(W||(W={})),function(e){e.create=function(e,t){return{items:e||[],isIncomplete:!!t}}}(z||(z={})),function(e){e.fromPlainText=function(e){return e.replace(/[\\`*_{}[\]()#+\-.!]/g,"\\$&")},e.is=function(e){var t=e;return we.string(t)||we.objectLiteral(t)&&we.string(t.language)&&we.string(t.value)}}(V||(V={})),function(e){e.is=function(e){var t=e;return!!t&&we.objectLiteral(t)&&(M.is(t.contents)||V.is(t.contents)||we.typedArray(t.contents,V.is))&&(void 0===e.range||c.is(e.range))}}(B||(B={})),function(e){e.create=function(e,t){return t?{label:e,documentation:t}:{label:e}}}($||($={})),function(e){e.create=function(e,t){for(var n=[],i=2;i=0;s--){var a=r[s],c=e.offsetAt(a.range.start),u=e.offsetAt(a.range.end);if(!(u<=o))throw new Error("Overlapping edit");i=i.substring(0,c)+a.newText+i.substring(u,i.length),o=c}return i}}(Re||(Re={}));var we,Ee=function(){function e(e,t,n,i){this._uri=e,this._languageId=t,this._version=n,this._content=i,this._lineOffsets=void 0}return Object.defineProperty(e.prototype,"uri",{get:function(){return this._uri},enumerable:!1,configurable:!0}),Object.defineProperty(e.prototype,"languageId",{get:function(){return this._languageId},enumerable:!1,configurable:!0}),Object.defineProperty(e.prototype,"version",{get:function(){return this._version},enumerable:!1,configurable:!0}),e.prototype.getText=function(e){if(e){var t=this.offsetAt(e.start),n=this.offsetAt(e.end);return this._content.substring(t,n)}return this._content},e.prototype.update=function(e,t){this._content=e.text,this._version=t,this._lineOffsets=void 0},e.prototype.getLineOffsets=function(){if(void 0===this._lineOffsets){for(var e=[],t=this._content,n=!0,i=0;i0&&e.push(t.length),this._lineOffsets=e}return this._lineOffsets},e.prototype.positionAt=function(e){e=Math.max(Math.min(e,this._content.length),0);var t=this.getLineOffsets(),n=0,i=t.length;if(0===i)return a.create(0,e);for(;ne?i=r:n=r+1}var o=n-1;return a.create(o,e-t[o])},e.prototype.offsetAt=function(e){var t=this.getLineOffsets();if(e.line>=t.length)return this._content.length;if(e.line<0)return 0;var n=t[e.line],i=e.line+1{"use strict";e.exports=require("vscode")}},t={};function n(i){var r=t[i];if(void 0!==r)return r.exports;var o=t[i]={exports:{}};return e[i].call(o.exports,o,o.exports,n),o.exports}n.d=(e,t)=>{for(var i in t)n.o(t,i)&&!n.o(e,i)&&Object.defineProperty(e,i,{enumerable:!0,get:t[i]})},n.g=function(){if("object"==typeof globalThis)return globalThis;try{return this||new Function("return this")()}catch(e){if("object"==typeof window)return window}}(),n.o=(e,t)=>Object.prototype.hasOwnProperty.call(e,t),n.r=e=>{"undefined"!=typeof Symbol&&Symbol.toStringTag&&Object.defineProperty(e,Symbol.toStringTag,{value:"Module"}),Object.defineProperty(e,"__esModule",{value:!0})};var i={};(()=>{"use strict";var e=i,t=n(5108);Object.defineProperty(e,"__esModule",{value:!0}),e.deactivate=e.activate=void 0;const r=n(9496),o=n(8595),s=n(8460),a=n(3699),c=n(6298),u=n(24),l=n(774),d=n(9497);let f,p,g;async function h(e,n){e.subscriptions.push((0,l.createStatusItem)());const i=(n=await async function(e){return e.isActive||await e.activate(),e}(n)).exports;if(i.client&&i.client.isEnabled())return p=i,void await i.client.start();const{extensionUri:c,packageJSON:d}=n,g=r.Uri.joinPath(c,"dist");try{const t=new Worker(r.Uri.joinPath(g,"browser.server.bundle.js").toString()),n={distUrl:g.toString()};t.postMessage(n);const i=new s.LanguageClientMiddlewareBase(void 0,a.LanguageServerType.Node,v,d.version);i.connect();const c={documentSelector:[{language:"python"}],synchronize:{configurationSection:["python","jupyter.runStartupCommands"]},middleware:i},l=new o.LanguageClient("python","Python Language Server",c,t);f=l,e.subscriptions.push(r.commands.registerCommand("python.viewLanguageServerOutput",(()=>l.outputChannel.show()))),l.onTelemetry((e=>{var t;const n=e.EventName||u.EventName.LANGUAGE_SERVER_TELEMETRY,i={...e.Properties,method:null===(t=e.Properties.method)||void 0===t?void 0:t.replace(/\//g,".")};v(n,e.Measurements,i,e.Exception)})),await l.start()}catch(e){t.log(e)}}function m(){if(g)return g;const e=n(217).Z;return g=new e(c.AppinsightsKey,[{lookup:/(errorName|errorMessage|errorStack)/g}]),g}function v(e,n,i,r){var o;const s=m(),a="number"==typeof n?{duration:n}:n||void 0,c={},u=e;if(i){const n=i;Object.getOwnPropertyNames(n).forEach((i=>{if(void 0!==n[i]&&null!==n[i])try{switch(typeof n[i]){case"string":c[i]=n[i];break;case"object":c[i]="object";break;default:c[i]=n[i].toString()}}catch(n){t.error(`Failed to serialize ${i} for ${e}`,n)}}))}if(r){const e={errorName:r.name,errorStack:null!==(o=r.stack)&&void 0!==o?o:""};Object.assign(c,e),s.sendTelemetryErrorEvent(u,c,a)}else s.sendTelemetryEvent(u,c,a)}e.activate=function(e){const t=m(),n=Promise.resolve((0,d.buildApi)(t)),i=r.extensions.getExtension(c.PYLANCE_EXTENSION_ID);if(i)return n.then((()=>h(e,i))),n;const o=r.extensions.onDidChange((async()=>{const t=r.extensions.getExtension(c.PYLANCE_EXTENSION_ID);t&&(o.dispose(),await h(e,t))}));return n},e.deactivate=async function(){if(p){const e=p;p=void 0,await e.client.stop()}if(f){const e=f;f=void 0,await e.stop(),await e.dispose()}}})(),module.exports=i})(); +//# sourceMappingURL=extension.browser.js.map \ No newline at end of file