@microsoft/applicationinsights-web-basic 2.7.5-nightly.2203-02 → 2.7.5-nightly.2204-23

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
@@ -1,6 +1,6 @@
1
1
  /*!
2
- * Application Insights JavaScript Web SDK - Basic, 2.7.5-nightly.2203-02
2
+ * Application Insights JavaScript Web SDK - Basic, 2.7.5-nightly.2204-23
3
3
  * Copyright (c) Microsoft and contributors. All rights reserved.
4
4
  */
5
- var e=this,n=function(N){"use strict";var _="function",R="object",A="undefined",o="prototype",L="hasOwnProperty",t=Object,E=t[o],F=t.assign,q=t.create,e=t.defineProperty,V=E[L],W=null;function G(e){return void 0===e&&(e=!0),W&&e||(typeof globalThis!==A&&globalThis&&(W=globalThis),typeof self!==A&&self&&(W=self),typeof window!==A&&window&&(W=window),typeof global!==A&&global&&(W=global)),W}function H(e){throw new TypeError(e)}function X(e){if(q)return q(e);if(null==e)return{};var n=typeof e;function t(){}return n!==R&&n!==_&&H("Object prototype may only be an Object:"+e),t[o]=e,new t}(G()||{}).Symbol,(G()||{}).Reflect;var Y=F||function(e){for(var n,t=1,r=arguments.length;t<r;t++)for(var i in n=arguments[t])E[L].call(n,i)&&(e[i]=n[i]);return e},J=function(e,n){return(J=t.setPrototypeOf||{__proto__:[]}instanceof Array&&function(e,n){e.__proto__=n}||function(e,n){for(var t in n)n[L](t)&&(e[t]=n[t])})(e,n)};function n(e,n){function t(){this.constructor=e}typeof n!==_&&null!==n&&H("Class extends value "+n+" is not a constructor or null"),J(e,n),e[o]=null===n?X(n):(t[o]=n[o],new t)}function Z(e,n){for(var t=0,r=n.length,i=e.length;t<r;t++,i++)e[i]=n[t];return e}var Q="constructor",p="prototype",$="function",ee="_dynInstFuncs",ne="_isDynProxy",te="_dynClass",re="_dynInstChk",ie=re,oe="_dfOpts",ae="_unknown_",se="__proto__",ue="useBaseInst",le="setInstFuncs",ce=Object,fe=ce.getPrototypeOf,de=0;function ge(e,n){return e&&ce[p].hasOwnProperty.call(e,n)}function pe(e){return e&&(e===ce[p]||e===Array[p])}function he(e){return pe(e)||e===Function[p]}function me(e){if(e){if(fe)return fe(e);e=e[se]||e[p]||(e[Q]?e[Q][p]:null);if(e)return e}return null}function ve(e,n){var t=[],r=ce.getOwnPropertyNames;if(r)t=r(e);else for(var i in e)"string"==typeof i&&ge(e,i)&&t.push(i);if(t&&0<t.length)for(var o=0;o<t.length;o++)n(t[o])}function ye(e,n,t){return n!==Q&&typeof e[n]===$&&(t||ge(e,n))}function Ie(e){throw new TypeError("DynamicProto: "+e)}function Ce(e,n){for(var t=e.length-1;0<=t;t--)if(e[t]===n)return 1}function Se(e,n){return ge(e,p)?e.name||n||ae:((e||{})[Q]||{}).name||n||ae}function h(e,r,n,t){ge(e,p)||Ie("theClass is an invalid class definition.");var i,o,a,s,u,l,c=e[p],f=(function(e){if(fe)for(var n=[],t=me(r);t&&!he(t)&&!Ce(n,t);){if(t===e)return 1;n.push(t),t=me(t)}}(c)||Ie("["+Se(e)+"] is not in class hierarchy of ["+Se(r)+"]"),null),e=(ge(c,te)?f=c[te]:(f="_dynCls$"+Se(e,"_")+"$"+de,de++,c[te]=f),h[oe]),d=!!e[ue],g=(d&&t&&t[ue]!==undefined&&(d=!!t[ue]),o={},ve(i=r,function(e){!o[e]&&ye(i,e,!1)&&(o[e]=i[e])}),o),d=(n(r,function(e,n,t,o){function r(e,n,t){var r,i=n[t];return i[ne]&&o&&!1!==(r=e[ee]||{})[ie]&&(i=(r[n[te]]||{})[t]||i),function(){return i.apply(e,arguments)}}for(var i={},a=(ve(t,function(e){i[e]=r(n,t,e)}),me(e)),s=[];a&&!he(a)&&!Ce(s,a);)ve(a,function(e){!i[e]&&ye(a,e,!fe)&&(i[e]=r(n,a,e))}),s.push(a),a=me(a);return i}(c,r,g,d)),!!fe&&!!e[le]);a=c,n=f,s=r,u=g,e=!1!==(d=d&&t?!!t[le]:d),pe(a)||(c=s[ee]=s[ee]||{},l=c[n]=c[n]||{},!1!==c[ie]&&(c[ie]=!!e),ve(s,function(e){var t,r,i;ye(s,e,!1)&&s[e]!==u[e]&&(l[e]=s[e],delete s[e],ge(a,e)&&(!a[e]||a[e][ne])||(a[e]=(t=a,r=e,(i=function(){var e,n;return(function(e,n,t,r){var i=null;if(e&&ge(t,te)){var o=e[ee]||{};if((i=(o[t[te]]||{})[n])||Ie("Missing ["+n+"] "+$),!i[re]&&!1!==o[ie]){for(var a=!ge(e,n),s=me(e),u=[];a&&s&&!he(s)&&!Ce(u,s);){var l=s[n];if(l){a=l===r;break}u.push(s),s=me(s)}try{a&&(e[n]=i),i[re]=1}catch(c){o[ie]=!1}}}return i}(this,r,t,i)||(typeof(n=(n=t[e=r])===i?me(t)[e]:n)!==$&&Ie("["+e+"] is not a "+$),n)).apply(this,arguments)})[ne]=1,i)))}))}h[oe]={setInstFuncs:!0,useBaseInst:!0},(Re=M=M||{})[Re.CRITICAL=1]="CRITICAL",Re[Re.WARNING=2]="WARNING";var M,k={BrowserDoesNotSupportLocalStorage:0,BrowserCannotReadLocalStorage:1,BrowserCannotReadSessionStorage:2,BrowserCannotWriteLocalStorage:3,BrowserCannotWriteSessionStorage:4,BrowserFailedRemovalFromLocalStorage:5,BrowserFailedRemovalFromSessionStorage:6,CannotSendEmptyTelemetry:7,ClientPerformanceMathError:8,ErrorParsingAISessionCookie:9,ErrorPVCalc:10,ExceptionWhileLoggingError:11,FailedAddingTelemetryToBuffer:12,FailedMonitorAjaxAbort:13,FailedMonitorAjaxDur:14,FailedMonitorAjaxOpen:15,FailedMonitorAjaxRSC:16,FailedMonitorAjaxSend:17,FailedMonitorAjaxGetCorrelationHeader:18,FailedToAddHandlerForOnBeforeUnload:19,FailedToSendQueuedTelemetry:20,FailedToReportDataLoss:21,FlushFailed:22,MessageLimitPerPVExceeded:23,MissingRequiredFieldSpecification:24,NavigationTimingNotSupported:25,OnError:26,SessionRenewalDateIsZero:27,SenderNotInitialized:28,StartTrackEventFailed:29,StopTrackEventFailed:30,StartTrackFailed:31,StopTrackFailed:32,TelemetrySampledAndNotSent:33,TrackEventFailed:34,TrackExceptionFailed:35,TrackMetricFailed:36,TrackPVFailed:37,TrackPVFailedCalc:38,TrackTraceFailed:39,TransmissionFailed:40,FailedToSetStorageBuffer:41,FailedToRestoreStorageBuffer:42,InvalidBackendResponse:43,FailedToFixDepricatedValues:44,InvalidDurationValue:45,TelemetryEnvelopeInvalid:46,CreateEnvelopeError:47,CannotSerializeObject:48,CannotSerializeObjectNonSerializable:49,CircularReferenceDetected:50,ClearAuthContextFailed:51,ExceptionTruncated:52,IllegalCharsInName:53,ItemNotInArray:54,MaxAjaxPerPVExceeded:55,MessageTruncated:56,NameTooLong:57,SampleRateOutOfRange:58,SetAuthContextFailed:59,SetAuthContextFailedAccountName:60,StringValueTooLong:61,StartCalledMoreThanOnce:62,StopCalledWithoutStart:63,TelemetryInitializerFailed:64,TrackArgumentsNotSpecified:65,UrlTooLong:66,SessionStorageBufferFull:67,CannotAccessCookie:68,IdTooLong:69,InvalidEvent:70,FailedMonitorAjaxSetRequestHeader:71,SendBrowserInfoOnUserInit:72,PluginException:73,NotificationException:74,SnippetScriptLoadFailure:99,InvalidInstrumentationKey:100,CannotParseAiBlobValue:101,InvalidContentBlob:102,TrackPageActionEventFailed:103,FailedAddingCustomDefinedRequestContext:104,InMemoryStorageBufferFull:105},xe="attachEvent",Te="addEventListener",we="toISOString",be="endsWith",Ne="indexOf",_e="trim",Re="toString",Ae=e,Le=(t.freeze,t.seal,t.keys),e=String[o],Ee=e[_e],Fe=e[be],Me=(e.startsWith,Date[o][we]),e=Array.isArray,ke=E[Re];function g(e){return e===undefined||typeof e===A}function D(e){return null===e||g(e)}function De(e){return!D(e)}function Pe(e){return!(!e||typeof e!==R)}function d(e){return!(!e||typeof e!==_)}function Be(e,n,t,r){void 0===r&&(r=!1);var i=!1;if(!D(e))try{D(e[Te])?D(e[xe])||(e[xe]("on"+n,t),i=!0):(e[Te](n,t,r),i=!0)}catch(o){}return i}function P(e,n){if(e)for(var t in e)V.call(e,t)&&n.call(e,t,e[t])}function B(e,n){return!(!e||!n||!~e.indexOf(n))}V[Re].call(t);var U=e||function(e){return!(!e||"[object Array]"!==ke.call(e))};function Ue(e){return!(!e||"[object Error]"!==ke.call(e))}function m(e){return"string"==typeof e}function Oe(e){return"number"==typeof e}function ze(e){return"boolean"==typeof e}function je(e){if(e){if(Me)return e[we]();var n;return e&&e.getUTCFullYear?(n=function(e){e=""+e;return 1===e.length?"0"+e:e},e.getUTCFullYear()+"-"+n(1+e.getUTCMonth())+"-"+n(e.getUTCDate())+"T"+n(e.getUTCHours())+":"+n(e.getUTCMinutes())+":"+n(e.getUTCSeconds())+"."+(e.getUTCMilliseconds()/1e3).toFixed(3).slice(2,5)+"Z"):void 0}}function O(e,n,t){var r=e.length;try{for(var i=0;i<r&&!(i in e&&-1===n.call(t||e,e[i],i,e));i++);}catch(o){}}function Ke(e,n,t){if(e){if(e[Ne])return e[Ne](n,t);var r=e.length,t=t||0;try{for(var i=Math.max(0<=t?t:r-Math.abs(t),0);i<r;i++)if(i in e&&e[i]===n)return i}catch(o){}}return-1}function qe(e,n,t){if(e){if(e.map)return e.map(n,t);var r=e.length,i=t||e,o=Array(r);try{for(var a=0;a<r;a++)a in e&&(o[a]=n.call(i,e[a],e))}catch(s){}}return o}function v(e){return e&&(Ee&&e[_e]?e[_e]():e.replace?e.replace(/^\s+|\s+$/g,""):e)}var Ve=!{toString:null}.propertyIsEnumerable("toString"),We=["toString","toLocaleString","valueOf","hasOwnProperty","isPrototypeOf","propertyIsEnumerable","constructor"];function Ge(e){var n=typeof e;if(n===_||n===R&&null!==e||H("objKeys called on non-object"),!Ve&&Le)return Le(e);var t,r=[];for(t in e)e&&V.call(e,t)&&r.push(t);if(Ve)for(var i=We.length,o=0;o<i;o++)e&&V.call(e,We[o])&&r.push(We[o]);return r}function He(e,n,t,r){if(Ae)try{var i={enumerable:!0,configurable:!0};return t&&(i.get=t),r&&(i.set=r),Ae(e,n,i),!0}catch(o){}return!1}function Xe(){var e=Date;return e.now?e.now():(new e).getTime()}function z(e){return Ue(e)?e.name:""}function y(e,n,t,r,i){var o=t;!e||(o=e[n])===t||i&&!i(o)||r&&!r(t)||(e[n]=o=t)}function Ye(e){return!e}function Je(e){return!!e}function Ze(e){throw Error(e)}function Qe(e){return e&&F?t(F({},e)):e}var $e="window",en="navigator",nn="location",tn="console",rn="JSON",on="crypto",an="msCrypto",sn="msie",un="trident/",ln=null,cn=null,fn=null,dn=null;function gn(e,n){var t,r=!1;if(e){try{(r=n in e)||(t=e[o])&&(r=n in t)}catch(i){}if(!r)try{r=!g((new e)[n])}catch(i){}}return r}function I(e){var n=G();return n&&n[e]?n[e]:e===$e&&pn()?window:null}function pn(){return typeof window===R&&window}function hn(){return pn()?window:I($e)}function mn(){return typeof document===R&&document?document:I("document")}function vn(){return!(typeof navigator!==R||!navigator)}function yn(){return vn()?navigator:I(en)}function In(){return typeof JSON===R&&JSON||null!==I(rn)}function j(){return In()?JSON||I(rn):null}function Cn(){var e=yn();return!e||e.userAgent===cn&&null!==ln||(e=((cn=e.userAgent)||"").toLowerCase(),ln=B(e,sn)||B(e,un)),ln}function K(e){var n=Object[o].toString.call(e),t="";return"[object Error]"===n?t="{ stack: '"+e.stack+"', message: '"+e.message+"', name: '"+e.name+"'":In()&&(t=j().stringify(e)),n+t}function Sn(){return dn=null===dn?vn()&&!!yn().sendBeacon:dn}function xn(e){var n=!1;try{var n=!!I("fetch"),t=I("Request");n&&e&&t&&(n=gn(t,"keepalive"))}catch(r){}return n}function Tn(){return fn=null===fn&&(fn="undefined"!=typeof XDomainRequest)&&wn()?fn&&!gn(I("XMLHttpRequest"),"withCredentials"):fn}function wn(){var e=!1;try{e=!!I("XMLHttpRequest")}catch(n){}return e}var bn,Nn=["eventsSent","eventsDiscarded","eventsSendRequest","perfEvent"],_n=null;function Rn(e){var n=_n;return(n=n||!0===e.disableDbgExt?n:_n||(e=I("Microsoft"),_n=e?e.ApplicationInsights:_n))?n.ChromeDbgExt:null}function An(e){return e?'"'+e.replace(/\"/g,"")+'"':""}function Ln(e,n){var t,r=typeof console!==A?console:I(tn);r&&(t="log",d(r[t=r[e]?e:t])&&r[t](n))}Fn.dataType="MessageData";var En=Fn;function Fn(e,n,t,r){void 0===t&&(t=!1),this.messageId=e,this.message=(t?"AI: ":"AI (Internal): ")+e;t="",In()&&(t=j().stringify(r)),e=(n?" message:"+An(n):"")+(r?" props:"+An(t):"");this.message+=e}function Mn(e,n){return(e||{}).logger||new kn(n)}var kn=function Hi(r){this.identifier="DiagnosticLogger",this.queue=[];var i=0,s={};h(Hi,this,function(o){function e(e,n){e=r[e];return D(e)?n:e}function a(e,n){var t=Rn(r);t&&t.diagLog&&t.diagLog(e,n)}D(r)&&(r={}),o.consoleLoggingLevel=function(){return e("loggingLevelConsole",0)},o.telemetryLoggingLevel=function(){return e("loggingLevelTelemetry",1)},o.maxInternalMessageLimit=function(){return e("maxMessageLimit",25)},o.enableDebugExceptions=function(){return e("enableDebugExceptions",!1)},o.throwInternal=function(e,n,t,r,i){n=new En(n,t,i=void 0!==i&&i,r);if(o.enableDebugExceptions())throw n;t=e===M.CRITICAL?"errorToConsole":"warnToConsole";g(n.message)?a("throw"+(e===M.CRITICAL?"Critical":"Warning"),n):(r=o.consoleLoggingLevel(),i?(i=+n.messageId,!s[i]&&e<=r&&(o[t](n.message),s[i]=!0)):e<=r&&o[t](n.message),o.logInternalMessage(e,n))},o.warnToConsole=function(e){Ln("warn",e),a("warning",e)},o.errorToConsole=function(e){Ln("error",e),a("error",e)},o.resetInternalMessageCount=function(){i=0,s={}},o.logInternalMessage=function(e,n){var t,r;i>=o.maxInternalMessageLimit()||(r=!0,t="AITR_"+n.messageId,s[t]?r=!1:s[t]=!0,r&&(e<=o.telemetryLoggingLevel()&&(o.queue.push(n),i++,a(e===M.CRITICAL?"error":"warn",n)),i===o.maxInternalMessageLimit()&&(r=new En(k.MessageLimitPerPVExceeded,t="Internal events throttle limit per PageView reached for this app.",!1),o.queue.push(r),e===M.CRITICAL?o.errorToConsole(t):o.warnToConsole(t))))}})},Dn=(Pn.ParentContextKey="parent",Pn.ChildrenContextKey="childEvts",Pn);function Pn(e,i,n){var t,o=this,a=!1;o.start=Xe(),o.name=e,o.isAsync=n,o.isChildEvt=function(){return!1},d(i)&&(a=He(o,"payload",function(){return!t&&d(i)&&(t=i(),i=null),t})),o.getCtx=function(e){return e?(e===Pn.ParentContextKey||e===Pn.ChildrenContextKey?o:o.ctx||{})[e]:null},o.setCtx=function(e,n){e&&(e===Pn.ParentContextKey?(o[e]||(o.isChildEvt=function(){return!0}),o[e]=n):e===Pn.ChildrenContextKey?o[e]=n:(o.ctx=o.ctx||{})[e]=n)},o.complete=function(){var e=0,n=o.getCtx(Pn.ChildrenContextKey);if(U(n))for(var t=0;t<n.length;t++){var r=n[t];r&&(e+=r.time)}o.time=Xe()-o.start,o.exTime=o.time-e,o.complete=function(){},!a&&d(i)&&(o.payload=i())}}var Bn=function Xi(n){this.ctx={},h(Xi,this,function(t){t.create=function(e,n,t){return new Dn(e,n,t)},t.fire=function(e){e&&(e.complete(),n&&d(n.perfEvent)&&n.perfEvent(e))},t.setCtx=function(e,n){e&&((t.ctx=t.ctx||{})[e]=n)},t.getCtx=function(e){return(t.ctx||{})[e]}})},Un="CoreUtils.doPerf";function On(e,n,t,r,i){if(e)if(e=d(e.getPerfMgr)?e.getPerfMgr():e){var o,a=void 0,s=e.getCtx(Un);try{if(a=e.create(n(),r,i))return s&&a.setCtx&&(a.setCtx(Dn.ParentContextKey,s),s.getCtx&&s.setCtx&&((o=s.getCtx(Dn.ChildrenContextKey))||(o=[],s.setCtx(Dn.ChildrenContextKey,o)),o.push(a))),e.setCtx(Un,a),t(a)}catch(u){a&&a.setCtx&&a.setCtx("exception",u)}finally{a&&e.fire(a),e.setCtx(Un,s)}}t()}var zn=function(i,n){var o=this,a=null,s=d(i.processTelemetry),u=d(i.setNextPlugin);o._hasRun=!1,o.getPlugin=function(){return i},o.getNext=function(){return a},o.setNext=function(e){a=e},o.processTelemetry=function(t,r){r=r||n;var e=i?i.identifier:"TelemetryPluginChain";On(r?r.core():null,function(){return e+":processTelemetry"},function(){if(i&&s){o._hasRun=!0;try{r.setNext(a),u&&i.setNextPlugin(a),a&&(a._hasRun=!1),i.processTelemetry(t,r)}catch(n){var e=a&&a._hasRun;a&&e||r.diagLog().throwInternal(M.CRITICAL,k.PluginException,"Plugin ["+i.identifier+"] failed during processTelemetry - "+K(n)),a&&!e&&a.processTelemetry(t,r)}}else a&&(o._hasRun=!0,a.processTelemetry(t,r))},function(){return{item:t}},!t.sync)}};function jn(e,n){var t=[];if(e&&0<e.length)for(var r=null,i=0;i<e.length;i++){var o=e[i];o&&d(o.processTelemetry)&&(o=new zn(o,n),t.push(o),r&&r.setNext(o),r=o)}return 0<t.length?t[0]:null}var Kn=function Yi(e,i,t,n){var r,o,a,s,u=this,l=null;null!==n&&(e&&d(e.getPlugin)?l=function(e,n,t){var r=[],i=!t;if(e)for(;e;){var o=e.getPlugin();!i&&o!==t||(i=!0,r.push(o)),e=e.getNext()}return i||r.push(t),jn(r,n)}(e,u,n||e.getPlugin()):n?(r=u,a=e,s=!1,(o=n)&&e&&(a=[],O(e,function(e){!s&&e!==o||(s=!0,a.push(e))})),o&&!s&&(a=a||[]).push(o),l=jn(a,r)):g(n)&&(l=jn(e,u))),u.core=function(){return t},u.diagLog=function(){return Mn(t,i)},u.getCfg=function(){return i},u.getExtCfg=function(e,n){var t,r;return void 0===n&&(n={}),(t=i&&(r=i.extensionConfig)&&e?r[e]:t)||n},u.getConfig=function(e,n,t){void 0===t&&(t=!1);var r,e=u.getExtCfg(e,null);return e&&!D(e[n])?r=e[n]:i&&!D(i[n])&&(r=i[n]),D(r)?t:r},u.hasNext=function(){return null!=l},u.getNext=function(){return l},u.setNext=function(e){l=e},u.processNext=function(e){var n=l;n&&(l=n.getNext(),n.processTelemetry(e,u))},u.createNew=function(e,n){return new Yi((e=void 0===e?null:e)||l,i,t,n)}},qn="extensionConfig",Vn="getPlugin",Re=(Wn.prototype.initialize=function(e,n,t,r){this._baseTelInit(e,n,t,r)},Wn);function Wn(){var o=this,a=!1,s=null,u=null;o.core=null,o.diagLog=function(e){return o._getTelCtx(e).diagLog()},o.isInitialized=function(){return a},o.setInitialized=function(e){a=e},o.setNextPlugin=function(e){u=e},o.processNext=function(e,n){n?n.processNext(e):u&&d(u.processTelemetry)&&u.processTelemetry(e,null)},o._getTelCtx=function(e){var n,e=e=void 0===e?null:e;return e||(n=s||new Kn(null,{},o.core),e=u&&u[Vn]?n.createNew(null,u[Vn]):n.createNew(null,u)),e},o._baseTelInit=function(e,n,t,r){e&&y(e,qn,[],null,D),!r&&n&&(r=n.getProcessTelContext().getNext());var i=u;u&&u[Vn]&&(i=u[Vn]()),o.core=n,s=new Kn(r,e,n,i),a=!0}}var Gn="processTelemetry",Hn="priority",Xn="setNextPlugin",Yn="isInitialized";function Jn(n,t){for(var e=[],r=null,i=n.getNext();i;){var o=i.getPlugin();o&&(r&&d(r[Xn])&&d(o[Gn])&&r[Xn](o),d(o[Yn])&&o[Yn]()||e.push(o),r=o,i=i.getNext())}O(e,function(e){e.initialize(n.getCfg(),n.core(),t,n.getNext())})}function Zn(e){return e.sort(function(e,n){var t=0,r=d(n[Gn]);return d(e[Gn])?t=r?e[Hn]-n[Hn]:1:r&&(t=-1),t})}n(et,Qn=Re),et._staticInit=(He(e=et.prototype,"ChannelControls",e.getChannelControls),void He(e,"channelQueue",e.getChannelControls));var Qn,$n=et;function et(){var u,r=Qn.call(this)||this;function l(e){e&&0<e.length&&(O(e=e.sort(function(e,n){return e.priority-n.priority}),function(e){e.priority<500&&Ze("Channel has invalid priority"+e.identifier)}),u.push(e))}return r.identifier="ChannelControllerPlugin",r.priority=500,h(et,r,function(a,s){a.setNextPlugin=function(e){},a.processTelemetry=function(n,t){u&&O(u,function(e){0<e.length&&r._getTelCtx(t).createNew(e).processNext(n)})},a.getChannelControls=function(){return u},a.initialize=function(n,t,r){var e,i,o;a.isInitialized()||(s.initialize(n,t,r),e=(n||{}).channels,i=r,u=[],e&&O(e,l),i&&(o=[],O(i,function(e){500<e.priority&&o.push(e)}),l(o)),O(u,function(e){return Jn(new Kn(e,n,t),r)}))}}),r}var nt="toGMTString",tt="toUTCString",rt="cookie",it="expires",ot="enabled",at="isCookieUseDisabled",st="disableCookiesUsage",ut="_ckMgr",C="",lt=null,ct=null,ft=null,dt=mn(),gt={},pt={};function ht(e){return!e||e.isEnabled()}function mt(e,i){y(t=(e=e||pt).cookieCfg=e.cookieCfg||{},"domain",e.cookieDomain,De,D),y(t,"path",e.cookiePath||"/",null,D),D(t[ot])&&(n=void 0,g(e[at])||(n=!e[at]),g(e[st])||(n=!e[st]),t[ot]=n);var n,t,l=t,c=l.path||"/",f=l.domain,r=!1!==l[ot],d={isEnabled:function(){var e=r&&vt(i),n=pt[ut];return e&&n&&d!==n?ht(n):e},setEnabled:function(e){r=!1!==e},set:function(e,n,t,r,i){var o,a,s,u=!1;return ht(d)&&(o={},-1!=(s=(a=v(n||C)).indexOf(";"))&&(a=v(n.substring(0,s)),o=yt(n.substring(1+s))),y(o,"domain",r||f,Je,g),D(t)||(s=Cn(),g(o[it])&&0<(n=Xe()+1e3*t)&&((r=new Date).setTime(n),y(o,it,It(r,s?nt:tt)||It(r,s?nt:tt)||C,Je)),s||y(o,"max-age",C+t,null,g)),(n=typeof location===R&&location?location:I(nn))&&"https:"===n.protocol&&(y(o,"secure",null,null,g),(ct=null===ct?!(m(r=(yn()||{}).userAgent)&&(B(r,"CPU iPhone OS 12")||B(r,"iPad; CPU OS 12")||B(r,"Macintosh; Intel Mac OS X 10_14")&&B(r,"Version/")&&B(r,"Safari")||B(r,"Macintosh; Intel Mac OS X 10_14")&&function(e,n){var t=!1;if(!e||(t=e===n))return t;if(Fe)return e[be](n);var r=e,i=n,t=!1,e=r?r.length:0;if(e&&40<=e&&!(t=r===i)){for(var o=e-1,a=39;0<=a;a--){if(r[o]!=i[a])return;o--}t=!0}return t}(r,"AppleWebKit/605.1.15 (KHTML, like Gecko)")||B(r,"Chrome/5")||B(r,"Chrome/6")||B(r,"UnrealEngine")&&!B(r,"Chrome")||B(r,"UCBrowser/12")||B(r,"UCBrowser/11"))):ct)&&y(o,"SameSite","None",null,g)),y(o,"path",i||c,null,g),(l.setCookie||St)(e,Ct(a,o)),u=!0),u},get:function(e){var n=C;return ht(d)?(l.getCookie||function(e){var n,t=C;return dt&&(n=dt[rt]||C,ft!==n&&(gt=yt(n),ft=n),t=v(gt[e]||C)),t})(e):n},del:function(e,n){return!!ht(d)&&d.purge(e,n)},purge:function(e,n){var t,r=!1;return vt(i)&&((t={}).path=n||"/",t[it]="Thu, 01 Jan 1970 00:00:01 GMT",n=t,Cn()||(n["max-age"]="0"),(l.delCookie||St)(e,Ct(C,n)),r=!0),r}};return d[ut]=d}function vt(e){if(null===lt){lt=!1;try{lt=(dt||{})[rt]!==undefined}catch(n){e&&e.throwInternal(M.WARNING,k.CannotAccessCookie,"Cannot access document.cookie - "+z(n),{exception:K(n)})}}return lt}function yt(e){var t={};return e&&e.length&&O(v(e).split(";"),function(e){var n;(e=v(e||C))&&(-1==(n=e.indexOf("="))?t[e]=null:t[v(e.substring(0,n))]=v(e.substring(1+n)))}),t}function It(e,n){return d(e[n])?e[n]():null}function Ct(e,n){var t=e||C;return P(n,function(e,n){t+="; "+e+(D(n)?C:"="+n)}),t}function St(e,n){dt&&(dt[rt]=e+"="+n)}var xt="_notificationManager";function Tt(e,n){return new Bn(n)}var wt,bt=function Ji(e){this.listeners=[];var n=!!(e||{}).perfEvtsSendAll;h(Ji,this,function(i){i.addNotificationListener=function(e){i.listeners.push(e)},i.removeNotificationListener=function(e){for(var n=Ke(i.listeners,e);-1<n;)i.listeners.splice(n,1),n=Ke(i.listeners,e)},i.eventsSent=function(n){O(i.listeners,function(e){e&&e.eventsSent&&setTimeout(function(){return e.eventsSent(n)},0)})},i.eventsDiscarded=function(n,t){O(i.listeners,function(e){e&&e.eventsDiscarded&&setTimeout(function(){return e.eventsDiscarded(n,t)},0)})},i.eventsSendRequest=function(t,r){O(i.listeners,function(e){if(e&&e.eventsSendRequest)if(r)setTimeout(function(){return e.eventsSendRequest(t,r)},0);else try{e.eventsSendRequest(t,r)}catch(n){}})},i.perfEvent=function(t){!t||!n&&t.isChildEvt()||O(i.listeners,function(e){if(e&&e.perfEvent)if(t.isAsync)setTimeout(function(){return e.perfEvent(t)},0);else try{e.perfEvent(t)}catch(n){}})}})},Nt=(n(_t,wt=function Zi(){var n,l,c,t,r,f=!1;h(Zi,this,function(u){u._extensions=[],l=new $n,u.logger=new kn({loggingLevelConsole:M.CRITICAL}),n=[],u.isInitialized=function(){return f},u.initialize=function(e,n,r,t){u.isInitialized()&&Ze("Core should not be initialized more than once"),e&&!D(e.instrumentationKey)||Ze("Please provide instrumentation key"),c=t,u[xt]=t,u.config=e||{},t&&!0!==u.config.disableDbgExt&&t.addNotificationListener(function(e){if(!bn){bn={};for(var n=0;n<Nn.length;n++)bn[Nn[n]]=function(n,t){return function(){var e=Rn(t);e&&(e=e.listener)&&e[n]&&e[n].apply(e,arguments)}}(Nn[n],e)}return bn}(e)),u.config.enablePerfMgr&&y(u.config,"createPerfMgr",Tt),e.extensions=D(e.extensions)?[]:e.extensions,e?!(i=e[qn])&&D(i)&&(i=g(o)?{}:o,e[qn]=i):i=g(o)?{}:o,i.NotificationManager=t,r&&(u.logger=r);var i,o=[],a=(o.push.apply(o,Z(Z([],n),e.extensions)),o=Zn(o),[]),s={};O(o,function(e){(D(e)||D(e.initialize))&&Ze("Extensions must provide callback to initialize");var n=e.priority,t=e.identifier;e&&n&&(D(s[n])?s[n]=t:r.warnToConsole("Two extensions have same priority #"+n+" - "+s[n]+", "+t)),(!n||n<l.priority)&&a.push(e)}),o.push(l),a.push(l),o=Zn(o),u._extensions=o,Jn(new Kn([l],e,u),o),Jn(new Kn(a,e,u),o),u._extensions=a,0===u.getTransmissionControls().length&&Ze("No channels available"),f=!0,u.releaseQueue()},u.getTransmissionControls=function(){return l.getChannelControls()},u.track=function(e){y(e,"iKey",u.config.instrumentationKey,null,Ye),y(e,"time",je(new Date),null,Ye),y(e,"ver","4.0",null,D),u.isInitialized()?u.getProcessTelContext().processNext(e):n.push(e)},u.getProcessTelContext=function(){var e=u._extensions,n=e;return e&&0!==e.length||(n=[l]),new Kn(n,u.config,u)},u.getNotifyMgr=function(){return c||(c=X({addNotificationListener:function(e){},removeNotificationListener:function(e){},eventsSent:function(e){},eventsDiscarded:function(e,n){},eventsSendRequest:function(e,n){}}),u[xt]=c),c},u.getCookieMgr=function(){return r=r||mt(u.config,u.logger)},u.setCookieMgr=function(e){r=e},u.getPerfMgr=function(){return t||u.config&&u.config.enablePerfMgr&&d(u.config.createPerfMgr)&&(t=u.config.createPerfMgr(u,u.getNotifyMgr())),t||null},u.setPerfMgr=function(e){t=e},u.eventCnt=function(){return n.length},u.releaseQueue=function(){0<n.length&&(O(n,function(e){u.getProcessTelContext().processNext(e)}),n=[])}})}),_t);function _t(){var e=wt.call(this)||this,r=0;return h(_t,e,function(t,i){function n(e){var n=t.getNotifyMgr();n&&n.eventsDiscarded([e],2)}t.initialize=function(e,n,t,r){i.initialize(e,n,t||new kn(e),r||new bt(e))},t.track=function(e){On(t.getPerfMgr(),function(){return"AppInsightsCore:track"},function(){if(null===e&&(n(e),Ze("Invalid telemetry item")),D(e.name))throw n(e),Error("telemetry name required");i.track(e)},function(){return{item:e}},!e.sync)},t.addNotificationListener=function(e){var n=t.getNotifyMgr();n&&n.addNotificationListener(e)},t.removeNotificationListener=function(e){var n=t.getNotifyMgr();n&&n.removeNotificationListener(e)},t.pollInternalLogs=function(n){var e=t.config.diagnosticLogInterval;return e&&0<e||(e=1e4),r&&t.stopPollingInternalLogs(),r=setInterval(function(){var e=t.logger?t.logger.queue:[];O(e,function(e){e={name:n||"InternalMessageId: "+e.messageId,iKey:t.config.instrumentationKey,time:je(new Date),baseType:En.dataType,baseData:{message:e.message}};t.track(e)}),e.length=0},e)},t.stopPollingInternalLogs=function(){r&&(clearInterval(r),r=0)}}),e}var Rt=4294967296,At=4294967295,Lt=!1,Et=123456789,Ft=987654321;function Mt(e){e<0&&(e>>>=0),Et=123456789+e&At,Ft=987654321-e&At,Lt=!0}function kt(){try{var e=2147483647&Xe();Mt((Math.random()*Rt^e)+e)}catch(n){}}function Dt(e){return 0<e?Math.floor(Pt()/At*(e+1))>>>0:0}function Pt(e){var n=I(on)||I(an),n=n&&n.getRandomValues?n.getRandomValues(new Uint32Array(1))[0]&At:Cn()?(Lt||kt(),Bt()&At):Math.floor(Rt*Math.random()|0);return e||(n>>>=0),n}function Bt(e){var n=((Ft=36969*(65535&Ft)+(Ft>>16)&At)<<16)+(65535&(Et=18e3*(65535&Et)+(Et>>16)&At))>>>0&At|0;return e||(n>>>=0),n}var Ut,Ot=null,zt={_canUseCookies:undefined,isTypeof:function(e,n){return typeof e===n},isUndefined:g,isNullOrUndefined:D,hasOwnProperty:function(e,n){return!(!e||!V.call(e,n))},isFunction:d,isObject:Pe,isDate:function(e){return!(!e||"[object Date]"!==ke.call(e))},isArray:U,isError:Ue,isString:m,isNumber:Oe,isBoolean:ze,toISOString:je,arrForEach:O,arrIndexOf:Ke,arrMap:qe,arrReduce:function(e,n,t){var r;if(e){if(e.reduce)return e.reduce(n,t);var i=e.length,o=0;if(3<=arguments.length)r=t;else{for(;o<i&&!(o in e);)o++;r=e[o++]}for(;o<i;)o in e&&(r=n(r,e[o],o,e)),o++}return r},strTrim:v,objCreate:X,objKeys:Ge,objDefineAccessors:He,addEventHandler:function(e,n){var t=!1,r=hn(),r=(r&&(t=Be(r,e,n),t=Be(r.body,e,n)||t),mn());return r&&Be(r,e,n)||t},dateNow:Xe,isIE:Cn,disableCookies:function(){var e,n;(e=mt[ut]||pt[ut])||(e=mt[ut]=mt(void 0,void 0),pt[ut]=e),e=e,n=zt._canUseCookies,null===Ot&&(Ot=[],Ut=n,He(zt,"_canUseCookies",function(){return Ut},function(n){Ut=n,O(Ot,function(e){e.setEnabled(n)})})),-1===Ke(Ot,e)&&Ot.push(e),ze(n)&&e.setEnabled(n),ze(Ut)&&e.setEnabled(Ut),e.setEnabled(!1)},newGuid:function(){return"xxxxxxxx-xxxx-4xxx-yxxx-xxxxxxxxxxxx".replace(jt,function(e){var n=0|Dt(15);return("x"===e?n:3&n|8).toString(16)})},perfNow:function(){var e=I("performance");return e&&e.now?e.now():Xe()},newId:function(e){void 0===e&&(e=22);for(var n=Pt()>>>0,t=0,r="";r.length<e;)r+="ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789+/"[0|63&n]||"",n>>>=6,5==++t&&(n=(Pt()<<2&4294967295|3&n)>>>0,t=0);return r},randomValue:Dt,random32:Pt,mwcRandomSeed:function(e){e?Mt(e):kt()},mwcRandom32:Bt,generateW3CId:function(){for(var e,n=["0","1","2","3","4","5","6","7","8","9","a","b","c","d","e","f"],t="",r=0;r<4;r++)t+=n[15&(e=Pt())]+n[e>>4&15]+n[e>>8&15]+n[e>>12&15]+n[e>>16&15]+n[e>>20&15]+n[e>>24&15]+n[e>>28&15];var i=n[8+(3&Pt())|0];return t.substr(0,8)+t.substr(9,4)+"4"+t.substr(13,3)+i+t.substr(16,3)+t.substr(19,12)}},jt=/[xy]/g;function Kt(e,n,t){var r,i,o=n.length,a=(e=e,(n=n)&&150<(n=v(n.toString())).length&&(i=n.substring(0,150),e&&e.throwInternal(M.WARNING,k.NameTooLong,"name is too long. It has been truncated to 150 characters.",{name:n},!0)),i||n);if(a.length!==o){for(var s=0,u=a;t[u]!==undefined;)s++,u=a.substring(0,147)+(r=void 0,(r="00"+s).substr(r.length-3));a=u}return a}function S(e,n,t){var r;return void 0===t&&(t=1024),n&&(t=t||1024,(n=v(n)).toString().length>t&&(r=n.toString().substring(0,t),e&&e.throwInternal(M.WARNING,k.StringValueTooLong,"string value is too long. It has been truncated to "+t+" characters.",{value:n},!0))),r||n}function qt(e,n){return Ht(e,n,2048,k.UrlTooLong)}function Vt(e,n){var t;return n&&32768<n.length&&(t=n.substring(0,32768),e&&e.throwInternal(M.WARNING,k.MessageTruncated,"message is too long, it has been truncated to 32768 characters.",{message:n},!0)),t||n}function Wt(r,e){var i;return e&&(i={},P(e,function(e,n){if(Pe(n)&&In())try{n=j().stringify(n)}catch(t){r&&r.throwInternal(M.WARNING,k.CannotSerializeObjectNonSerializable,"custom property is not valid",{exception:t},!0)}n=S(r,n,8192),e=Kt(r,e,i),i[e]=n}),e=i),e}function Gt(t,e){var r;return e&&(r={},P(e,function(e,n){e=Kt(t,e,r),r[e]=n}),e=r),e}function Ht(e,n,t,r){var i;return n&&(n=v(n)).length>t&&(i=n.substring(0,t),e&&e.throwInternal(M.WARNING,r,"input is too long, it has been truncated to "+t+" characters.",{data:n},!0)),i||n}function Xt(e){var n=""+Math.floor((e=Math.round(e=isNaN(e)||e<0?0:e))/1e3)%60,t=""+Math.floor(e/6e4)%60,r=""+Math.floor(e/36e5)%24,i=Math.floor(e/864e5),e=1===(e=""+e%1e3).length?"00"+e:2===e.length?"0"+e:e,n=n.length<2?"0"+n:n,t=t.length<2?"0"+t:t;return(0<i?i+".":"")+(r=r.length<2?"0"+r:r)+":"+t+":"+n+"."+e}var Yt,Jt="Microsoft_ApplicationInsights_BypassAjaxInstrumentation",Zt="sampleRate",Qt="ProcessLegacy",$t="http.method",er="not_specified",nr=((e=Yt=Yt||{})[e.LocalStorage=0]="LocalStorage",e[e.SessionStorage=1]="SessionStorage",undefined);function tr(e){try{if(D(G()))return null;var n=new Date,t=I(e===Yt.LocalStorage?"localStorage":"sessionStorage"),r=(t.setItem(n.toString(),n.toString()),t.getItem(n.toString())!==n.toString());if(t.removeItem(n.toString()),!r)return t}catch(i){}return null}function rr(){return ir()?tr(Yt.SessionStorage):null}function ir(){return nr=nr===undefined?!!tr(Yt.SessionStorage):nr}function or(e,n){var t=rr();if(null!==t)try{return t.getItem(n)}catch(r){nr=!1,e.throwInternal(M.WARNING,k.BrowserCannotReadSessionStorage,"Browser failed read of session storage. "+z(r),{exception:K(r)})}return null}function ar(e,n,t){var r=rr();if(null!==r)try{r.setItem(n,t)}catch(i){nr=!1,e.throwInternal(M.WARNING,k.BrowserCannotWriteSessionStorage,"Browser failed write to session storage. "+z(i),{exception:K(i)})}}var sr=mn()||{},ur=0,lr=[null,null,null,null,null];var cr=["https://dc.services.visualstudio.com/v2/track","https://breeze.aimon.applicationinsights.io/v2/track","https://dc-int.services.visualstudio.com/v2/track"];function fr(e){return~cr.indexOf(e.toLowerCase())}n(gr,dr=function(){});var dr,e=gr;function gr(){return dr.call(this)||this}n(mr,pr=function(){this.ver=1,this.sampleRate=100,this.tags={}});var pr,hr=mr;function mr(e,n,t){var r=pr.call(this)||this;return r.name=S(e,t)||er,r.data=n,r.time=je(new Date),r.aiDataContract={time:1,iKey:1,name:1,sampleRate:function(){return 100===r.sampleRate?4:1},tags:1,data:1},r}var vr,r=function(){this.ver=2,this.properties={},this.measurements={}},yr=(n(Ir,vr=r),Ir.envelopeType="Microsoft.ApplicationInsights.{0}.Event",Ir.dataType="EventData",Ir);function Ir(e,n,t,r){var i=vr.call(this)||this;return i.aiDataContract={ver:1,name:1,properties:0,measurements:0},i.name=S(e,n)||er,i.properties=Wt(e,t),i.measurements=Gt(e,r),i}var Cr="error",u="stack",Sr="stackDetails",xr="errorSrc",Tr="message",wr="description";function br(e,n){var t=e;return t&&!m(t)&&(JSON&&JSON.stringify?(t=JSON.stringify(e),!n||t&&"{}"!==t||(t=d(e.toString)?e.toString():""+e)):t=e+" - (Missing JSON.stringify)"),t||""}function Nr(e,n){var t=e;return e&&((t=t&&!m(t)&&(e[Tr]||e[wr])||t)&&!m(t)&&(t=br(t,!0)),e.filename&&(t=t+" @"+(e.filename||"")+":"+(e.lineno||"?")+":"+(e.colno||"?"))),(n&&"String"!==n&&"Object"!==n&&"Error"!==n&&!~(t||"").indexOf(n)?n+": "+t:t)||""}function _r(e){return e&&e.src&&m(e.src)&&e.obj&&U(e.obj)}function Rr(e){var e=e||"",n=(e=m(e)?e:m(e[u])?e[u]:""+e).split("\n");return{src:e,obj:n}}function Ar(e){var n,t=null;if(e)try{e[u]?t=Rr(e[u]):e[Cr]&&e[Cr][u]?t=Rr(e[Cr][u]):e.exception&&e.exception[u]?t=Rr(e.exception[u]):_r(e)?t=e:_r(e[Sr])?t=e[Sr]:window&&window.opera&&e[Tr]?t=function(e){for(var n=[],t=e.split("\n"),r=0;r<t.length;r++){var i=t[r];t[r+1]&&(i+="@"+t[r+1],r++),n.push(i)}return{src:e,obj:n}}(e.message):m(e)?t=Rr(e):(n=e[Tr]||e[wr]||"",m(e[xr])&&(n&&(n+="\n"),n+=" from "+e[xr]),n&&(t=Rr(n)))}catch(r){t=Rr(r)}return t||{src:"",obj:null}}function Lr(e){var n="";if(e&&!(n=e.typeName||e.name||""))try{var t=/function (.{1,200})\(/.exec(e.constructor.toString()),n=t&&1<t.length?t[1]:""}catch(r){}return n}function Er(e){if(e)try{var n,t;if(!m(e))return n=Lr(e),(t=br(e,!1))&&"{}"!==t||(e[Cr]&&(n=Lr(e=e[Cr])),t=br(e,!0)),t.indexOf(n)&&"String"!==n?n+":"+t:t}catch(r){}return""+(e||"")}n(a,Fr=function(){this.ver=2,this.exceptions=[],this.properties={},this.measurements={}}),a.CreateAutoException=function(e,n,t,r,i,o,a,s){var u=Lr(i||o||e);return{message:Nr(e,u),url:n,lineNumber:t,columnNumber:r,error:Er(i||o||e),evt:Er(o||e),typeName:u,stackDetails:Ar(a||i||o),errorSrc:s}},a.CreateFromInterface=function(n,e,t,r){var i=e.exceptions&&qe(e.exceptions,function(e){return Dr.CreateFromInterface(n,e)});return new a(n,Y(Y({},e),{exceptions:i}),t,r)},a.prototype.toInterface=function(){var e=this,n=e.exceptions,t=e.properties,r=e.measurements,i=e.severityLevel,o=e.problemGroup,a=e.id,e=e.isManual;return{ver:"4.0",exceptions:n instanceof Array&&qe(n,function(e){return e.toInterface()})||undefined,severityLevel:i,properties:t,measurements:r,problemGroup:o,id:a,isManual:e}},a.CreateSimpleException=function(e,n,t,r,i,o){return{exceptions:[{hasFullStack:!0,message:e,stack:i,typeName:n}]}},a.envelopeType="Microsoft.ApplicationInsights.{0}.Exception",a.dataType="ExceptionData",a.formatError=Er;var Fr,Mr=a;function a(e,n,t,r,i,o){var a=Fr.call(this)||this;return a.aiDataContract={ver:1,exceptions:1,severityLevel:0,properties:0,measurements:0},function(e){try{if(Pe(e))return"ver"in e&&"exceptions"in e&&"properties"in e}catch(n){}}(n)?(a.exceptions=n.exceptions,a.properties=n.properties,a.measurements=n.measurements,n.severityLevel&&(a.severityLevel=n.severityLevel),n.id&&(a.id=n.id),n.problemGroup&&(a.problemGroup=n.problemGroup),a.ver=2,D(n.isManual)||(a.isManual=n.isManual)):(a.exceptions=[new Dr(e,n,t=t||{})],a.properties=Wt(e,t),a.measurements=Gt(e,r),i&&(a.severityLevel=i),o&&(a.id=o)),a}n(Pr,kr=function(){this.hasFullStack=!0,this.parsedStack=[]}),Pr.prototype.toInterface=function(){var e=this.parsedStack instanceof Array&&qe(this.parsedStack,function(e){return e.toInterface()});return{id:this.id,outerId:this.outerId,typeName:this.typeName,message:this.message,hasFullStack:this.hasFullStack,stack:this[u],parsedStack:e||undefined}},Pr.CreateFromInterface=function(e,n){var t=n.parsedStack instanceof Array&&qe(n.parsedStack,function(e){return Or.CreateFromInterface(e)})||n.parsedStack;return new Pr(e,Y(Y({},n),{parsedStack:t}))};var kr,Dr=Pr;function Pr(e,n,t){var l,r,i,o,a,s=kr.call(this)||this;return s.aiDataContract={id:0,outerId:0,typeName:1,message:1,hasFullStack:0,stack:0,parsedStack:2},function(e){try{if(Pe(e))return"hasFullStack"in e&&"typeName"in e}catch(n){}}(n)?(s.typeName=n.typeName,s.message=n.message,s[u]=n[u],s.parsedStack=n.parsedStack,s.hasFullStack=n.hasFullStack):(r=(o=n)&&o.evt,Ue(o)||(o=o[Cr]||r||o),s.typeName=S(e,Lr(o))||er,s.message=Vt(e,Nr(n||o,s.typeName))||er,l=n[Sr]||Ar(n),s.parsedStack=function(){var e=l.obj;if(e&&0<e.length){var n=[],t=0,r=0;if(O(e,function(e){var e=e.toString();Or.regex.test(e)&&(e=new Or(e,t++),r+=e.sizeInBytes,n.push(e))}),32768<r)for(var i=0,o=n.length-1,a=0,s=i,u=o;i<o;){if(32768<(a+=n[i].sizeInBytes+n[o].sizeInBytes)){n.splice(s,u-s+1);break}s=i,u=o,i++,o--}}return n}(),s[u]=(r=e,a="",(o=l)&&(o.obj?O(o.obj,function(e){a+=e+"\n"}):a=o.src||""),(n=a)&&32768<(e=""+n).length&&(i=e.substring(0,32768),r&&r.throwInternal(M.WARNING,k.ExceptionTruncated,"exception is too long, it has been truncated to 32768 characters.",{exception:n},!0)),i||n),s.hasFullStack=U(s.parsedStack)&&0<s.parsedStack.length,t&&(t.typeName=t.typeName||s.typeName)),s}n(i,Br=function(){}),i.CreateFromInterface=function(e){return new i(e,null)},i.prototype.toInterface=function(){return{level:this.level,method:this.method,assembly:this.assembly,fileName:this.fileName,line:this.line}},i.regex=/^([\s]+at)?[\s]{0,50}([^\@\()]+?)[\s]{0,50}(\@|\()([^\(\n]+):([0-9]+):([0-9]+)(\)?)$/,i.baseSize=58;var Br,Ur,Or=i;function i(e,n){var t,r=Br.call(this)||this;return r.sizeInBytes=0,r.aiDataContract={level:1,method:1,assembly:0,fileName:0,line:0},"string"==typeof e?(t=e,r.level=n,r.method="<no_method>",r.assembly=v(t),r.fileName="",r.line=0,(n=t.match(i.regex))&&5<=n.length&&(r.method=v(n[2])||r.method,r.fileName=v(n[4]),r.line=parseInt(n[5])||0)):(r.level=e.level,r.method=e.method,r.assembly=e.assembly,r.fileName=e.fileName,r.line=e.line,r.sizeInBytes=0),r.sizeInBytes+=r.method.length,r.sizeInBytes+=r.fileName.length,r.sizeInBytes+=r.assembly.length,r.sizeInBytes+=i.baseSize,r.sizeInBytes+=r.level.toString().length,r.sizeInBytes+=r.line.toString().length,r}Ur=0,n(Kr,zr=function(){this.kind=Ur});var zr,jr=Kr;function Kr(){var e=null!==zr&&zr.apply(this,arguments)||this;return e.aiDataContract={name:1,kind:0,value:1,count:0,min:0,max:0,stdDev:0},e}n(Wr,qr=function(){this.ver=2,this.metrics=[],this.properties={},this.measurements={}}),Wr.envelopeType="Microsoft.ApplicationInsights.{0}.Metric",Wr.dataType="MetricData";var qr,Vr=Wr;function Wr(e,n,t,r,i,o,a,s,u){var l=qr.call(this)||this,c=(l.aiDataContract={ver:1,metrics:1,properties:0},new jr);return c.count=0<r?r:undefined,c.max=isNaN(o)||null===o?undefined:o,c.min=isNaN(i)||null===i?undefined:i,c.name=S(e,n)||er,c.value=t,c.stdDev=isNaN(a)||null===a?undefined:a,l.metrics=[c],l.properties=Wt(e,s),l.measurements=Gt(e,u),l}n(Hr,Gr=r);var Gr,r=Hr;function Hr(){var e=Gr.call(this)||this;return e.ver=2,e.properties={},e.measurements={},e}n(Jr,Xr=r),Jr.envelopeType="Microsoft.ApplicationInsights.{0}.Pageview",Jr.dataType="PageviewData";var Xr,Yr=Jr;function Jr(e,n,t,r,i,o,a){var s=Xr.call(this)||this;return s.aiDataContract={ver:1,name:0,url:0,duration:0,properties:0,measurements:0,id:0},s.id=a&&Ht(e,a,128,k.IdTooLong).toString(),s.url=qt(e,t),s.name=S(e,n)||er,isNaN(r)||(s.duration=Xt(r)),s.properties=Wt(e,i),s.measurements=Gt(e,o),s}n($r,Zr=function(){this.ver=2,this.success=!0,this.properties={},this.measurements={}}),$r.envelopeType="Microsoft.ApplicationInsights.{0}.RemoteDependency",$r.dataType="RemoteDependencyData";var Zr,Qr=$r;function $r(e,n,t,r,i,o,a,s,u,l,c,f){void 0===u&&(u="Ajax");var d,g,p,h=Zr.call(this)||this,t=(h.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},h.id=n,h.duration=Xt(i),h.success=o,h.resultCode=a+"",h.type=S(e,u),n=e,i=s,u=a=o=r,a=(s=t)&&0<s.length?(d=s,p=(t=lr)[g=ur],sr.createElement?t[g]||(p=t[g]=sr.createElement("a")):p={host:function(){e=null,d&&null!=(t=d.match(/(\w*):\/\/(.[^/:]+)(\:[\d]+)?/i))&&2<t.length&&m(t[2])&&0<t[2].length&&(e=t[2]||"",2<t.length&&(n=(t[1]||"").toLowerCase(),t=t[3]||"",e+=t="http"==n&&":80"===t||"https"==n&&":443"===t?"":t));var e,n=e||"";if(n){var t=n.match(/(www[0-9]?\.)?(.[^/:]+)(\:[\d]+)?/i);if(null!=t&&3<t.length&&m(t[2])&&0<t[2].length)return t[2]+(t[3]||"")}return n}()},p.href=d,++g>=t.length&&(g=0),ur=g,g=(t=p).host,a||(null!=t.pathname?("/"!=((p=0===t.pathname.length?"/":t.pathname)[0]||"")&&(p="/"+p),u=t.pathname,S(n,i?i+" "+p:p)):S(n,s))):g=o,{target:g,name:a,data:u});return h.data=qt(e,r)||t.data,h.target=S(e,t.target),l&&(h.target="".concat(h.target," | ").concat(l)),h.name=S(e,t.name),h.properties=Wt(e,c),h.measurements=Gt(e,f),h}n(ri,ei=function(){this.ver=2,this.properties={},this.measurements={}}),ri.envelopeType="Microsoft.ApplicationInsights.{0}.Message",ri.dataType="MessageData";var ei,ni,ti=ri;function ri(e,n,t,r,i){var o=ei.call(this)||this;return o.aiDataContract={ver:1,message:1,severityLevel:0,properties:0},o.message=Vt(e,n=n||er),o.properties=Wt(e,r),o.measurements=Gt(e,i),t&&(o.severityLevel=t),o}function ii(){var e=ni.call(this)||this;return e.ver=2,e.properties={},e.measurements={},e}n(ii,ni=r),n(si,oi=ii),si.envelopeType="Microsoft.ApplicationInsights.{0}.PageviewPerformance",si.dataType="PageviewPerformanceData";var oi,ai=si;function si(e,n,t,r,i,o,a){var s=oi.call(this)||this;return s.aiDataContract={ver:1,name:0,url:0,duration:0,perfTotal:0,networkConnect:0,sentRequest:0,receivedResponse:0,domProcessing:0,properties:0,measurements:0},s.url=qt(e,t),s.name=S(e,n)||er,s.properties=Wt(e,i),s.measurements=Gt(e,o),a&&(s.domProcessing=a.domProcessing,s.duration=a.duration,s.networkConnect=a.networkConnect,s.perfTotal=a.perfTotal,s.receivedResponse=a.receivedResponse,s.sentRequest=a.sentRequest),s}n(ci,ui=e);var ui,li=ci;function ci(e,n){var t=ui.call(this)||this;return t.aiDataContract={baseType:1,baseData:1},t.baseType=e,t.baseData=n,t}function fi(e){var n="ai."+e+".";return function(e){return n+e}}N.SeverityLevel=void 0,(r=N.SeverityLevel||(N.SeverityLevel={}))[r.Verbose=0]="Verbose",r[r.Information=1]="Information",r[r.Warning=2]="Warning",r[r.Error=3]="Error",r[r.Critical=4]="Critical";var di,gi,e=fi("application"),r=fi("device"),pi=fi("location"),s=fi("operation"),hi=fi("session"),l=fi("user"),c=fi("cloud"),mi=fi("internal"),vi=(gi={applicationVersion:e("ver"),applicationBuild:e("build"),applicationTypeId:e("typeId"),applicationId:e("applicationId"),applicationLayer:e("layer"),deviceId:r("id"),deviceIp:r("ip"),deviceLanguage:r("language"),deviceLocale:r("locale"),deviceModel:r("model"),deviceFriendlyName:r("friendlyName"),deviceNetwork:r("network"),deviceNetworkName:r("networkName"),deviceOEMName:r("oemName"),deviceOS:r("os"),deviceOSVersion:r("osVersion"),deviceRoleInstance:r("roleInstance"),deviceRoleName:r("roleName"),deviceScreenResolution:r("screenResolution"),deviceType:r("type"),deviceMachineName:r("machineName"),deviceVMName:r("vmName"),deviceBrowser:r("browser"),deviceBrowserVersion:r("browserVersion"),locationIp:pi("ip"),locationCountry:pi("country"),locationProvince:pi("province"),locationCity:pi("city"),operationId:s("id"),operationName:s("name"),operationParentId:s("parentId"),operationRootId:s("rootId"),operationSyntheticSource:s("syntheticSource"),operationCorrelationVector:s("correlationVector"),sessionId:hi("id"),sessionIsFirst:hi("isFirst"),sessionIsNew:hi("isNew"),userAccountAcquisitionDate:l("accountAcquisitionDate"),userAccountId:l("accountId"),userAgent:l("userAgent"),userId:l("id"),userStoreRegion:l("storeRegion"),userAuthUserId:l("authUserId"),userAnonymousUserAcquisitionDate:l("anonUserAcquisitionDate"),userAuthenticatedUserAcquisitionDate:l("authUserAcquisitionDate"),cloudName:c("name"),cloudRole:c("role"),cloudRoleVer:c("roleVer"),cloudRoleInstance:c("roleInstance"),cloudEnvironment:c("environment"),cloudLocation:c("location"),cloudDeploymentUnit:c("deploymentUnit"),internalNodeName:mi("nodeName"),internalSdkVersion:mi("sdkVersion"),internalAgentVersion:mi("agentVersion"),internalSnippet:mi("snippet"),internalSdkSrc:mi("sdkSrc")},n(yi,di=function(){var t=this;P(gi,function(e,n){t[e]=n})}),yi);function yi(){return di.call(this)||this}var Ii,f=new vi,e=function Qi(t,r){var i=[],o=!1;this._get=function(){return i},this._set=function(e){return i=e},h(Qi,this,function(n){n.enqueue=function(e){n.count()>=r.eventsLimitInMem()?o||(t.throwInternal(M.WARNING,k.InMemoryStorageBufferFull,"Maximum in-memory buffer size reached: "+n.count(),!0),o=!0):i.push(e)},n.count=function(){return i.length},n.size=function(){for(var e=i.length,n=0;n<i.length;n++)e+=i[n].length;return r.emitLineDelimitedJson()||(e+=2),e},n.clear=function(){o=!(i=[])},n.getItems=function(){return i.slice(0)},n.batchPayloads=function(e){return e&&0<e.length?r.emitLineDelimitedJson()?e.join("\n"):"["+e.join(",")+"]":null}})},Ci=(n(Si,Ii=e),Si);function Si(e,n){e=Ii.call(this,e,n)||this;return h(Si,e,function(e,n){e.markAsSent=function(e){n.clear()},e.clearSent=function(e){}}),e}n(x,xi=e),x.BUFFER_KEY="AI_buffer",x.SENT_BUFFER_KEY="AI_sentBuffer",x.MAX_BUFFER_SIZE=2e3;var xi,Ti=x;function x(s,u){var e=xi.call(this,s,u)||this,l=!1;return h(x,e,function(t,n){var e=o(x.BUFFER_KEY),r=o(x.SENT_BUFFER_KEY),r=t._set(e.concat(r));function i(n,e){var t=[];return O(e,function(e){d(e)||-1!==Ke(n,e)||t.push(e)}),t}function o(e){try{var e=u.namePrefix&&u.namePrefix()?u.namePrefix()+"_"+e:e,n=or(s,e);if(n){var t=j().parse(n);if((t=m(t)?j().parse(t):t)&&U(t))return t}}catch(r){s.throwInternal(M.CRITICAL,k.FailedToRestoreStorageBuffer," storage key: "+e+", "+z(r),{exception:K(r)})}return[]}function a(e,n){try{var e=u.namePrefix&&u.namePrefix()?u.namePrefix()+"_"+e:e,t=JSON.stringify(n);ar(s,e,t)}catch(r){ar(s,e,JSON.stringify([])),s.throwInternal(M.WARNING,k.FailedToSetStorageBuffer," storage key: "+e+", "+z(r)+". Buffer cleared",{exception:K(r)})}}r.length>x.MAX_BUFFER_SIZE&&(r.length=x.MAX_BUFFER_SIZE),a(x.SENT_BUFFER_KEY,[]),a(x.BUFFER_KEY,r),t.enqueue=function(e){t.count()>=x.MAX_BUFFER_SIZE?l||(s.throwInternal(M.WARNING,k.SessionStorageBufferFull,"Maximum buffer size reached: "+t.count(),!0),l=!0):(n.enqueue(e),a(x.BUFFER_KEY,t._get()))},t.clear=function(){n.clear(),a(x.BUFFER_KEY,t._get()),a(x.SENT_BUFFER_KEY,[]),l=!1},t.markAsSent=function(e){a(x.BUFFER_KEY,t._set(i(e,t._get())));var n=o(x.SENT_BUFFER_KEY);n instanceof Array&&e instanceof Array&&((n=n.concat(e)).length>x.MAX_BUFFER_SIZE&&(s.throwInternal(M.CRITICAL,k.SessionStorageBufferFull,"Sent buffer reached its maximum size: "+n.length,!0),n.length=x.MAX_BUFFER_SIZE),a(x.SENT_BUFFER_KEY,n))},t.clearSent=function(e){e=i(e,o(x.SENT_BUFFER_KEY));a(x.SENT_BUFFER_KEY,e)}}),e}var wi="baseType",T="baseData",w="properties",bi="true";function b(e,n,t){y(e,n,t,Je)}function Ni(e,t,r){D(e)||P(e,function(e,n){Oe(n)?r[e]=n:m(n)?t[e]=n:In()&&(t[e]=j().stringify(n))})}function _i(t,r){D(t)||P(t,function(e,n){t[e]=n||r})}function Ri(e,n,t,r){for(var r=new hr(e,r,n),n=(b(r,"sampleRate",t[Zt]),(t[T]||{}).startTime&&(r.time=je(t[T].startTime)),r.iKey=t.iKey,t.iKey.replace(/-/g,"")),n=(r.name=r.name.replace("{0}",n),e),e=t,i=r,o=i.tags=i.tags||{},a=e.ext=e.ext||{},s=e.tags=e.tags||[],u=a.user,u=(u&&(b(o,f.userAuthUserId,u.authId),b(o,f.userId,u.id||u.localId)),a.app),u=(u&&b(o,f.sessionId,u.sesId),a.device),u=(u&&(b(o,f.deviceId,u.id||u.localId),b(o,f.deviceType,u.deviceClass),b(o,f.deviceIp,u.ip),b(o,f.deviceModel,u.model),b(o,f.deviceType,u.deviceType)),e.ext.web),e=(u&&(b(o,f.deviceLanguage,u.browserLang),b(o,f.deviceBrowserVersion,u.browserVer),b(o,f.deviceBrowser,u.browser),b(e=(e=(e=i.data=i.data||{})[T]=e[T]||{})[w]=e[w]||{},"domain",u.domain),b(e,"isManual",u.isManual?bi:null),b(e,"screenRes",u.screenRes),b(e,"userConsent",u.userConsent?bi:null)),a.os),u=(e&&b(o,f.deviceOS,e.name),a.trace),l=(u&&(b(o,f.operationParentId,u.parentID),b(o,f.operationName,S(n,u.name)),b(o,f.operationId,u.traceID)),{}),c=s.length-1;0<=c;c--)P(s[c],function(e,n){l[e]=n}),s.splice(c,1);P(s,function(e,n){l[e]=n});e=Y(Y({},o),l);return e[f.internalSdkVersion]||(e[f.internalSdkVersion]="javascript:".concat(Li.Version)),i.tags=Qe(e),t.tags=t.tags||[],Qe(r)}function Ai(e,n){D(n[T])&&e.throwInternal(M.CRITICAL,k.TelemetryEnvelopeInvalid,"telemetryItem.baseData cannot be null.")}var Li={Version:"2.7.5-nightly.2203-02"};function Ei(e,n,t){Ai(e,n);var r={},i={},t=(n[wi]!==yr.dataType&&(r.baseTypeSource=n[wi]),n[wi]===yr.dataType?(r=n[T][w]||{},i=n[T].measurements||{}):n[T]&&Ni(n[T],r,i),Ni(n.data,r,i),D(t)||_i(r,t),n[T].name),t=new yr(e,t,r,i),r=new li(yr.dataType,t);return Ri(e,yr.envelopeType,n,r)}var Fi=function $i(f){h($i,this,function(e){function l(a,s){var e="__aiCircularRefCheck",u={};if(!a)return f.throwInternal(M.CRITICAL,k.CannotSerializeObject,"cannot serialize object because it is null or undefined",{name:s},!0),u;if(a[e])return f.throwInternal(M.WARNING,k.CircularReferenceDetected,"Circular reference detected while serializing object",{name:s},!0),u;if(a.aiDataContract)return a[e]=!0,P(a.aiDataContract,function(e,n){var t=d(n)?1&n():1&n,r=d(n)?4&n():4&n,n=2&n,i=a[e]!==undefined,o=Pe(a[e])&&null!==a[e];!t||i||n?r||(t=o?(n?c:l)(a[e],e):a[e])!==undefined&&(u[e]=t):f.throwInternal(M.CRITICAL,k.MissingRequiredFieldSpecification,"Missing required field specification. The field is required but not present on source",{field:e,name:s})}),delete a[e],u;if("measurements"===s)u=t(a,"number",s);else if("properties"===s)u=t(a,"string",s);else if("tags"===s)u=t(a,"string",s);else if(U(a))u=c(a,s);else{f.throwInternal(M.WARNING,k.CannotSerializeObjectNonSerializable,"Attempting to serialize an object which does not implement ISerializable",{name:s},!0);try{j().stringify(a),u=a}catch(n){f.throwInternal(M.CRITICAL,k.CannotSerializeObject,n&&d(n.toString)?n.toString():"Error serializing object",null,!0)}}return u}function c(e,n){if(e)if(U(e))for(var t=[],r=0;r<e.length;r++){var i=l(e[r],n+"["+r+"]");t.push(i)}else f.throwInternal(M.CRITICAL,k.ItemNotInArray,"This field was specified as an array in the contract but the item is not an array.\r\n",{name:n},!0);return t}function t(e,t,r){var i;return e&&(i={},P(e,function(e,n){"string"===t?n===undefined?i[e]="undefined":null===n?i[e]="null":n.toString?i[e]=n.toString():i[e]="invalid field: toString() is not defined.":"number"===t?n===undefined?i[e]="undefined":i[e]=null===n?"null":isNaN(n=parseFloat(n))?"NaN":n:(i[e]="invalid field: "+r+" is of unknown type.",f.throwInternal(M.CRITICAL,i[e],null,!0))})),i}e.serialize=function(e){e=l(e,"root");try{return j().stringify(e)}catch(n){f.throwInternal(M.CRITICAL,k.CannotSerializeObject,n&&d(n.toString)?n.toString():"Error serializing object",null,!0)}}})};function Mi(){var a=hn(),s=mn(),u=!1,l=!0;h(Mi,this,function(e){try{var n,t;a&&Be(a,"online",r)&&(Be(a,"offline",i),u=!0),s&&!g((n=s.body||s).ononline)&&(n.ononline=r,n.onoffline=i,u=!0),u&&(t=yn())&&!D(t.onLine)&&(l=t.onLine)}catch(o){u=!1}function r(){l=!0}function i(){l=!1}e.isListening=u,e.isOnline=function(){var e=!0,n=yn();return u?e=l:n&&!D(n.onLine)&&(e=n.onLine),e},e.isOffline=function(){return!e.isOnline()}})}var ki=Mi.Offline=new Mi,Di=(Pi.prototype.getHashCodeScore=function(e){return this.getHashCode(e)/Pi.INT_MAX_VALUE*100},Pi.prototype.getHashCode=function(e){if(""===e)return 0;for(;e.length<8;)e=e.concat(e);for(var n=5381,t=0;t<e.length;++t)n=(n<<5)+n+e.charCodeAt(t),n&=n;return Math.abs(n)},Pi.INT_MAX_VALUE=2147483647,Pi);function Pi(){}var Bi=function(){var n=new Di,t=new vi;this.getSamplingScore=function(e){return e.tags&&e.tags[t.userId]?n.getHashCodeScore(e.tags[t.userId]):e.ext&&e.ext.user&&e.ext.user.id?n.getHashCodeScore(e.ext.user.id):e.tags&&e.tags[t.operationId]?n.getHashCodeScore(e.tags[t.operationId]):e.ext&&e.ext.telemetryTrace&&e.ext.telemetryTrace.traceID?n.getHashCodeScore(e.ext.telemetryTrace.traceID):100*Math.random()}},Ui=(Oi.prototype.isSampledIn=function(e){var n=this.sampleRate;return null===n||n===undefined||100<=n||e.baseType===Vr.dataType||this.samplingScoreGenerator.getSamplingScore(e)<n},Oi);function Oi(e,n){this.INT_MAX_VALUE=2147483647;n=n||Mn(null);(100<e||e<0)&&(n.throwInternal(M.WARNING,k.SampleRateOutOfRange,"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 Bi}function zi(e){try{return e.responseText}catch(n){}return null}function ji(){return{endpointUrl:function(){return"https://dc.services.visualstudio.com/v2/track"},emitLineDelimitedJson:function(){return!1},maxBatchInterval:function(){return 15e3},maxBatchSizeInBytes:function(){return 102400},disableTelemetry:function(){return!1},enableSessionStorageBuffer:function(){return!0},isRetryDisabled:function(){return!1},isBeaconApiDisabled:function(){return!0},disableXhr:function(){return!1},onunloadDisableFetch:function(){return!1},onunloadDisableBeacon:function(){return!1},instrumentationKey:function(){return undefined},namePrefix:function(){return undefined},samplingPercentage:function(){return 100},customHeaders:function(){return undefined},convertUndefined:function(){return undefined},eventsLimitInMem:function(){return 1e4}}}(r={})[yr.dataType]=Ei,r[ti.dataType]=function(e,n,t){Ai(e,n);var r=n[T].message,i=n[T].severityLevel,o=n[T][w]||{},a=n[T].measurements||{},t=(Ni(n.data,o,a),D(t)||_i(o,t),new ti(e,r,i,o,a)),r=new li(ti.dataType,t);return Ri(e,ti.envelopeType,n,r)},r[Yr.dataType]=function(e,n,t){Ai(e,n);var r,i="duration",o=n[T],i=(D(o)||D(o[w])||D(o[w][i])?D(n.data)||D(n.data[i])||(r=n.data[i],delete n.data[i]):(r=o[w][i],delete o[w][i]),n[T]),o=(((n.ext||{}).trace||{}).traceID&&(a=n.ext.trace.traceID),i.id||a),a=i.name,s=i.uri,u=i[w]||{},l=i.measurements||{},i=(D(i.refUri)||(u.refUri=i.refUri),D(i.pageType)||(u.pageType=i.pageType),D(i.isLoggedIn)||(u.isLoggedIn=i.isLoggedIn.toString()),D(i[w])||P(i[w],function(e,n){u[e]=n}),Ni(n.data,u,l),D(t)||_i(u,t),new Yr(e,a,s,r,u,l,o)),t=new li(Yr.dataType,i);return Ri(e,Yr.envelopeType,n,t)},r[ai.dataType]=function(e,n,t){Ai(e,n);var r=n[T],i=r.name,o=r.uri||r.url,a=r[w]||{},s=r.measurements||{},t=(Ni(n.data,a,s),D(t)||_i(a,t),new ai(e,i,o,undefined,a,s,r)),i=new li(ai.dataType,t);return Ri(e,ai.envelopeType,n,i)},r[Mr.dataType]=function(e,n,t){Ai(e,n);var r=n[T].measurements||{},i=n[T][w]||{},t=(Ni(n.data,i,r),D(t)||_i(i,t),n[T]),t=Mr.CreateFromInterface(e,t,i,r),i=new li(Mr.dataType,t);return Ri(e,Mr.envelopeType,n,i)},r[Vr.dataType]=function(e,n,t){Ai(e,n);var r=n[T],i=r[w]||{},o=r.measurements||{},t=(Ni(n.data,i,o),D(t)||_i(i,t),new Vr(e,r.name,r.average,r.sampleCount,r.min,r.max,r.stdDev,i,o)),r=new li(Vr.dataType,t);return Ri(e,Vr.envelopeType,n,r)},r[Qr.dataType]=function(e,n,t){Ai(e,n);var r=n[T].measurements||{},i=n[T][w]||{},t=(Ni(n.data,i,r),D(t)||_i(i,t),n[T]);if(D(t))return e.warnToConsole("Invalid input for dependency data"),null;var o=t[w]&&t[w][$t]?t[w][$t]:"GET",o=new Qr(e,t.id,t.target,t.name,t.duration,t.success,t.responseCode,o,t.type,t.correlationContext,i,r),t=new li(Qr.dataType,o);return Ri(e,Qr.envelopeType,n,t)};var Ki,qi=r,Vi=(n(Wi,Ki=Re),Wi.constructEnvelope=function(e,n,t,r){e=n===e.iKey||D(n)?e:Y(Y({},e),{iKey:n});return(qi[e.baseType]||Ei)(t,e,r)},Wi);function Wi(){var T,w,t,b,N,_,R,A=Ki.call(this)||this,L=(A.priority=1001,!(A.identifier="AppInsightsChannelPlugin")),E={},F=0;return A._senderConfig=ji(),h(Wi,A,function(l,a){function c(e,n,t,r,i,o){var a=null;l._appId||(a=p(o))&&a.appId&&(l._appId=a.appId),(e<200||300<=e)&&0!==e?(301!==e&&307!==e&&308!==e||s(t))&&!l._senderConfig.isRetryDisabled()&&y(e)?(h(n),l.diagLog().throwInternal(M.WARNING,k.TransmissionFailed,". Response code "+e+". Will retry to send "+n.length+" items.")):l._onError(n,i):ki.isOffline()?l._senderConfig.isRetryDisabled()||(h(n,10),l.diagLog().throwInternal(M.WARNING,k.TransmissionFailed,". Offline - Response Code: ".concat(e,". Offline status: ").concat(ki.isOffline(),". Will retry to send ").concat(n.length," items."))):(s(t),206===e?(a=a||p(o))&&!l._senderConfig.isRetryDisabled()?l._onPartialSuccess(n,a):l._onError(n,i):(T=0,l._onSuccess(n,r)))}function s(e){return!(10<=N)&&!D(e)&&""!==e&&e!==l._senderConfig.endpointUrl()&&(l._senderConfig.endpointUrl=function(){return e},++N,1)}function n(e,n){R?R(e,!1):u(e)}function o(e){var n=yn(),t=l._buffer,r=l._senderConfig.endpointUrl(),i=l._buffer.batchPayloads(e),i=new Blob([i],{type:"text/plain;charset=UTF-8"}),r=n.sendBeacon(r,i);return r&&(t.markAsSent(e),l._onSuccess(e,e.length)),r}function u(e,n){if(U(e)&&0<e.length&&!o(e)){for(var t=[],r=0;r<e.length;r++){var i=e[r];o([i])||t.push(i)}0<t.length&&(_(t,!0),l.diagLog().throwInternal(M.WARNING,k.TransmissionFailed,". Failed to send telemetry with Beacon API, retried with normal sender."))}}function f(n,e){var t=new XMLHttpRequest,r=l._senderConfig.endpointUrl();try{t[Jt]=!0}catch(i){}t.open("POST",r,e),t.setRequestHeader("Content-type","application/json"),fr(r)&&t.setRequestHeader("Sdk-Context","appId"),O(Ge(E),function(e){t.setRequestHeader(e,E[e])}),t.onreadystatechange=function(){return l._xhrReadyStateChange(t,n,n.length)},t.onerror=function(e){return l._onError(n,I(t),e)};e=l._buffer.batchPayloads(n);t.send(e),l._buffer.markAsSent(n)}function d(e,n){if(U(e)){for(var t=e.length,r=0;r<e.length;r++)t+=e[r].length;F+t<=65e3?i(e,!1):Sn()?u(e):(_&&_(e,!0),l.diagLog().throwInternal(M.WARNING,k.TransmissionFailed,". Failed to send telemetry with Beacon API, retried with xhrSender."))}}function g(e,n){i(e,!0)}function i(t,r){var e=l._senderConfig.endpointUrl(),n=l._buffer.batchPayloads(t),i=new Blob([n],{type:"application/json"}),o=new Headers,a=n.length,n=!1,s=!1,e=(fr(e)&&o.append("Sdk-Context","appId"),O(Ge(E),function(e){o.append(e,E[e])}),(i={method:"POST",headers:o,body:i})[Jt]=!0,r||(n=i.keepalive=!0,F+=a),new Request(e,i));try{e[Jt]=!0}catch(u){}l._buffer.markAsSent(t);try{fetch(e).then(function(n){r||(F-=a,a=0),s||(s=!0,n.ok?n.text().then(function(e){c(n.status,t,n.url,t.length,n.statusText,e)}):l._onError(t,n.statusText))})["catch"](function(e){r||(F-=a,a=0),s||(s=!0,l._onError(t,e.message))})}catch(u){s||l._onError(t,K(u))}n&&!s&&(s=!0,l._onSuccess(t,t.length))}function p(e){try{if(e&&""!==e){var n=j().parse(e);if(n&&n.itemsReceived&&n.itemsReceived>=n.itemsAccepted&&n.itemsReceived-n.itemsAccepted===n.errors.length)return n}}catch(t){l.diagLog().throwInternal(M.CRITICAL,k.InvalidBackendResponse,"Cannot parse the response. "+z(t),{response:e})}return null}function h(e,n){if(void 0===n&&(n=1),e&&0!==e.length){var t=l._buffer;t.clearSent(e),T++;for(var r=0,i=e;r<i.length;r++){var o=i[r];t.enqueue(o)}n=T<=1?10:(e=1+Math.floor((Math.pow(2,T)-1)/2*Math.random()*10),Math.max(Math.min(e*=n,3600),10)),e=Xe()+1e3*n;w=e,m()}}function m(){var e;t||L||(e=w?Math.max(0,w-Xe()):0,e=Math.max(l._senderConfig.maxBatchInterval(),e),t=setTimeout(function(){t=null,l.triggerSend(!0,null,1)},e))}function v(){clearTimeout(t),w=t=null}function y(e){return 408===e||429===e||500===e||503===e}function I(e,n){return e?"XMLHttpRequest,Status:"+e.status+",Response:"+zi(e)||e.response||"":n}function C(n,e){var t=l._buffer,r=hn(),i=new XDomainRequest,r=(i.onload=function(){return l._xdrOnLoad(i,n)},i.onerror=function(e){return l._onError(n,S(i),e)},r&&r.location&&r.location.protocol||"");if(l._senderConfig.endpointUrl().lastIndexOf(r,0))return l.diagLog().throwInternal(M.WARNING,k.TransmissionFailed,". Cannot send XDomain request. The endpoint URL protocol doesn't match the hosting page protocol."),void t.clear();r=l._senderConfig.endpointUrl().replace(/^(https?:)/,""),i.open("POST",r),r=t.batchPayloads(n);i.send(r),t.markAsSent(n)}function S(e,n){return e?"XDomainRequest,Response:"+zi(e)||"":n}function x(e,n){var t="getNotifyMgr",t=l.core[t]?l.core[t]():l.core._notificationManager;if(t&&t.eventsSendRequest)try{t.eventsSendRequest(e,n)}catch(r){l.diagLog().throwInternal(M.CRITICAL,k.NotificationException,"send request notification failed: "+z(r),{exception:K(r)})}}l.pause=function(){v(),L=!0},l.resume=function(){L&&(L=!1,w=null,l._buffer.size()>l._senderConfig.maxBatchSizeInBytes()&&l.triggerSend(!0,null,10),m())},l.flush=function(){if(!L){v();try{l.triggerSend(!0,null,1)}catch(e){l.diagLog().throwInternal(M.CRITICAL,k.FlushFailed,"flush failed, telemetry will not be collected: "+z(e),{exception:K(e)})}}},l.onunloadFlush=function(){if(!L)if(!1!==l._senderConfig.onunloadDisableBeacon()&&!1!==l._senderConfig.isBeaconApiDisabled()||!Sn())l.flush();else try{l.triggerSend(!0,n,2)}catch(e){l.diagLog().throwInternal(M.CRITICAL,k.FailedToSendQueuedTelemetry,"failed to flush with beacon sender on page unload, telemetry will not be collected: "+z(e),{exception:K(e)})}},l.teardown=function(){Ze("Method not implemented.")},l.addHeader=function(e,n){E[e]=n},l.initialize=function(e,n,t,r){a.initialize(e,n,t,r);var i=l._getTelCtx(),o=l.identifier,t=(b=new Fi(n.logger),w=null,T=0,l._sender=null,N=0,l.diagLog()),r=(P(ji(),function(e,n){l._senderConfig[e]=function(){return i.getConfig(o,e,n())}}),l._buffer=new(l._senderConfig.enableSessionStorageBuffer()&&ir()?Ti:Ci)(t,l._senderConfig),l._sample=new Ui(l._senderConfig.samplingPercentage(),t),!D(e.disableInstrumentationKeyValidation)&&e.disableInstrumentationKeyValidation||/^[0-9a-f]{8}-[0-9a-f]{4}-[0-9a-f]{4}-[0-9a-f]{4}-[0-9a-f]{12}$/.test(e.instrumentationKey)||t.throwInternal(M.CRITICAL,k.InvalidInstrumentationKey,"Invalid Instrumentation key "+e.instrumentationKey),!fr(l._senderConfig.endpointUrl())&&l._senderConfig.customHeaders()&&0<l._senderConfig.customHeaders().length&&O(l._senderConfig.customHeaders(),function(e){A.addHeader(e.header,e.value)}),l._senderConfig),n=null;!r.disableXhr()&&Tn()?n=C:!r.disableXhr()&&wn()&&(n=f),!n&&xn()&&(n=g),_=n||f,!r.isBeaconApiDisabled()&&Sn()&&(n=u),l._sender=n||f,R=!r.onunloadDisableFetch()&&xn(!0)?d:Sn()?u:!r.disableXhr()&&Tn()?C:!r.disableXhr()&&wn()?f:_},l.processTelemetry=function(e,t){t=l._getTelCtx(t);try{if(l._senderConfig.disableTelemetry())return;if(!e)return void t.diagLog().throwInternal(M.CRITICAL,k.CannotSendEmptyTelemetry,"Cannot send empty telemetry");if(e.baseData&&!e.baseType)return void t.diagLog().throwInternal(M.CRITICAL,k.InvalidEvent,"Cannot send telemetry without baseData and baseType");if(e.baseType||(e.baseType="EventData"),!l._sender)return void t.diagLog().throwInternal(M.CRITICAL,k.SenderNotInitialized,"Sender was not initialized");if(!l._sample.isSampledIn(e))return void t.diagLog().throwInternal(M.WARNING,k.TelemetrySampledAndNotSent,"Telemetry item was sampled out and not sent",{SampleRate:l._sample.sampleRate});e[Zt]=l._sample.sampleRate;var n=l._senderConfig.convertUndefined()||undefined,r=e.iKey||l._senderConfig.instrumentationKey(),i=Wi.constructEnvelope(e,r,t.diagLog(),n);if(!i)return void t.diagLog().throwInternal(M.CRITICAL,k.CreateEnvelopeError,"Unable to create an AppInsights envelope");var o=!1;if(e.tags&&e.tags[Qt]&&(O(e.tags[Qt],function(e){try{e&&!1===e(i)&&(o=!0,t.diagLog().warnToConsole("Telemetry processor check returns false"))}catch(n){t.diagLog().throwInternal(M.CRITICAL,k.TelemetryInitializerFailed,"One of telemetry initializers failed, telemetry item will not be sent: "+z(n),{exception:K(n)},!0)}}),delete e.tags[Qt]),o)return;var a=b.serialize(i),s=l._buffer;s.size()+a.length>l._senderConfig.maxBatchSizeInBytes()&&l.triggerSend(!0,null,10),s.enqueue(a),m()}catch(u){t.diagLog().throwInternal(M.WARNING,k.FailedAddingTelemetryToBuffer,"Failed adding telemetry to the sender's buffer, some telemetry will be lost: "+z(u),{exception:K(u)})}l.processNext(e,t)},l._xhrReadyStateChange=function(e,n,t){4===e.readyState&&c(e.status,n,e.responseURL,t,I(e),zi(e)||e.response)},l.triggerSend=function(e,n,t){if(void 0===e&&(e=!0),!L)try{var r,i=l._buffer;l._senderConfig.disableTelemetry()?i.clear():0<i.count()&&(r=i.getItems(),x(t||0,e),n?n.call(A,r,e):l._sender(r,e)),v()}catch(o){i=function(e){var n=((e=(e=void 0===e?null:e)?e:(n=yn()||{})?(n.userAgent||"").toLowerCase():"")||"").toLowerCase();if(B(n,sn))return e=mn()||{},Math.max(parseInt(n.split(sn)[1]),e.documentMode||0);if(B(n,un)){e=parseInt(n.split(un)[1]);if(e)return e+4}return null}();(!i||9<i)&&l.diagLog().throwInternal(M.CRITICAL,k.TransmissionFailed,"Telemetry transmission failed, some telemetry will be lost: "+z(o),{exception:K(o)})}},l._onError=function(e,n,t){l.diagLog().throwInternal(M.WARNING,k.OnError,"Failed to send telemetry.",{message:n}),l._buffer.clearSent(e)},l._onPartialSuccess=function(e,n){for(var t=[],r=[],i=0,o=n.errors.reverse();i<o.length;i++){var a=o[i],s=e.splice(a.index,1)[0];(y(a.statusCode)?r:t).push(s)}0<e.length&&l._onSuccess(e,n.itemsAccepted),0<t.length&&l._onError(t,I(null,["partial success",n.itemsAccepted,"of",n.itemsReceived].join(" "))),0<r.length&&(h(r),l.diagLog().throwInternal(M.WARNING,k.TransmissionFailed,"Partial success. Delivered: "+e.length+", Failed: "+t.length+". Will retry to send "+r.length+" our of "+n.itemsReceived+" items"))},l._onSuccess=function(e,n){l._buffer.clearSent(e)},l._xdrOnLoad=function(e,n){var t=zi(e);!e||t+""!="200"&&""!==t?(t=p(t))&&t.itemsReceived&&t.itemsReceived>t.itemsAccepted&&!l._senderConfig.isRetryDisabled()?l._onPartialSuccess(n,t):l._onError(n,S(e)):(T=0,l._onSuccess(n,0))}}),A}Gi.prototype.initialize=function(){this.core=new Nt;var e=[],n=new Vi;e.push(n),this.core.initialize(this.config,e),n.initialize(this.config,this.core,e),this.pollInternalLogs()},Gi.prototype.track=function(e){this.core.track(e)},Gi.prototype.flush=function(n){void 0===n&&(n=!0),O(this.core.getTransmissionControls(),function(e){O(e,function(e){n?e.flush():e.triggerSend(n,null,1)})})},Gi.prototype.pollInternalLogs=function(){this.core.pollInternalLogs()},Gi.prototype.stopPollingInternalLogs=function(){this.core.stopPollingInternalLogs()},Gi.prototype.getSKUDefaults=function(){this.config.diagnosticLogInterval=this.config.diagnosticLogInterval&&0<this.config.diagnosticLogInterval?this.config.diagnosticLogInterval:1e4};pi=Gi;function Gi(e){(D(e)||D(e.instrumentationKey))&&Ze("Invalid input configuration"),this.config=e,this.getSKUDefaults(),this.initialize()}N.AppInsightsCore=Nt,N.ApplicationInsights=pi,N.CoreUtils=zt,N.Sender=Vi;s=N,hi="__esModule",l={value:!0},c=Object.defineProperty;if(c)try{return void c(s,hi,l)}catch(eo){}typeof l.value!==undefined&&(s[hi]=l.value)};"object"==typeof exports&&"undefined"!=typeof module?n(exports):"function"==typeof define&&define.amd?define(["exports"],n):n(((e="undefined"!=typeof globalThis?globalThis:e||self).Microsoft=e.Microsoft||{},e.Microsoft.ApplicationInsights=e.Microsoft.ApplicationInsights||{}));
5
+ var e=this,n=function(N){"use strict";var _="function",R="object",A="undefined",o="prototype",L="hasOwnProperty",t=Object,E=t[o],F=t.assign,q=t.create,e=t.defineProperty,V=E[L],W=null;function G(e){return void 0===e&&(e=!0),W&&e||(typeof globalThis!==A&&globalThis&&(W=globalThis),typeof self!==A&&self&&(W=self),typeof window!==A&&window&&(W=window),typeof global!==A&&global&&(W=global)),W}function H(e){throw new TypeError(e)}function X(e){if(q)return q(e);if(null==e)return{};var n=typeof e;function t(){}return n!==R&&n!==_&&H("Object prototype may only be an Object:"+e),t[o]=e,new t}(G()||{}).Symbol,(G()||{}).Reflect;var Y=F||function(e){for(var n,t=1,r=arguments.length;t<r;t++)for(var i in n=arguments[t])E[L].call(n,i)&&(e[i]=n[i]);return e},J=function(e,n){return(J=t.setPrototypeOf||{__proto__:[]}instanceof Array&&function(e,n){e.__proto__=n}||function(e,n){for(var t in n)n[L](t)&&(e[t]=n[t])})(e,n)};function n(e,n){function t(){this.constructor=e}typeof n!==_&&null!==n&&H("Class extends value "+n+" is not a constructor or null"),J(e,n),e[o]=null===n?X(n):(t[o]=n[o],new t)}function Z(e,n){for(var t=0,r=n.length,i=e.length;t<r;t++,i++)e[i]=n[t];return e}var Q="constructor",p="prototype",$="function",ee="_dynInstFuncs",ne="_isDynProxy",te="_dynClass",re="_dynInstChk",ie=re,oe="_dfOpts",ae="_dynProto",se="_unknown_",ue="__proto__",le="useBaseInst",ce="setInstFuncs",fe=Object,de=fe.getPrototypeOf,ge=0;function pe(e,n){return e&&fe[p].hasOwnProperty.call(e,n)}function he(e){return e&&(e===fe[p]||e===Array[p])}function me(e){return he(e)||e===Function[p]}function ve(e){if(e){if(de)return de(e);var n=e[ae]||e[ue]||e[p]||(e[Q]?e[Q][p]:null);if(n)return e[ae]||(e[ae]=n),n}return null}function ye(e,n){var t=[],r=fe.getOwnPropertyNames;if(r)t=r(e);else for(var i in e)"string"==typeof i&&pe(e,i)&&t.push(i);if(t&&0<t.length)for(var o=0;o<t.length;o++)n(t[o])}function Ie(e,n,t){return n!==Q&&typeof e[n]===$&&(t||pe(e,n))}function Ce(e){throw new TypeError("DynamicProto: "+e)}function Se(e,n){for(var t=e.length-1;0<=t;t--)if(e[t]===n)return 1}function xe(e,n){return pe(e,p)?e.name||n||se:((e||{})[Q]||{}).name||n||se}function h(e,r,n,t){pe(e,p)||Ce("theClass is an invalid class definition.");var i,o,a,s,u,l,c=e[p],f=(function(e){if(!de)return 1;for(var n=[],t=ve(r);t&&!me(t)&&!Se(n,t);){if(t===e)return 1;n.push(t),t=ve(t)}}(c)||Ce("["+xe(e)+"] is not in class hierarchy of ["+xe(r)+"]"),null),e=(pe(c,te)?f=c[te]:(f="_dynCls$"+xe(e,"_")+"$"+ge,ge++,c[te]=f),h[oe]),d=!!e[le],g=(d&&t&&t[le]!==undefined&&(d=!!t[le]),o={},ye(i=r,function(e){!o[e]&&Ie(i,e,!1)&&(o[e]=i[e])}),o),d=(n(r,function(e,n,t,o){function r(e,n,t){var r,i=n[t];return i[ne]&&o&&!1!==(r=e[ee]||{})[ie]&&(i=(r[n[te]]||{})[t]||i),function(){return i.apply(e,arguments)}}for(var i={},a=(ye(t,function(e){i[e]=r(n,t,e)}),ve(e)),s=[];a&&!me(a)&&!Se(s,a);)ye(a,function(e){!i[e]&&Ie(a,e,!de)&&(i[e]=r(n,a,e))}),s.push(a),a=ve(a);return i}(c,r,g,d)),!!de&&!!e[ce]);a=c,n=f,s=r,u=g,e=!1!==(d=d&&t?!!t[ce]:d),he(a)||(c=s[ee]=s[ee]||{},l=c[n]=c[n]||{},!1!==c[ie]&&(c[ie]=!!e),ye(s,function(e){var t,r,i;Ie(s,e,!1)&&s[e]!==u[e]&&(l[e]=s[e],delete s[e],pe(a,e)&&(!a[e]||a[e][ne])||(a[e]=(t=a,r=e,(i=function(){var e,n;return(function(e,n,t,r){var i=null;if(e&&pe(t,te)){var o=e[ee]||{};if((i=(o[t[te]]||{})[n])||Ce("Missing ["+n+"] "+$),!i[re]&&!1!==o[ie]){for(var a=!pe(e,n),s=ve(e),u=[];a&&s&&!me(s)&&!Se(u,s);){var l=s[n];if(l){a=l===r;break}u.push(s),s=ve(s)}try{a&&(e[n]=i),i[re]=1}catch(c){o[ie]=!1}}}return i}(this,r,t,i)||(typeof(n=(n=t[e=r])===i?ve(t)[e]:n)!==$&&Ce("["+e+"] is not a "+$),n)).apply(this,arguments)})[ne]=1,i)))}))}h[oe]={setInstFuncs:!0,useBaseInst:!0},(Ae=M=M||{})[Ae.CRITICAL=1]="CRITICAL",Ae[Ae.WARNING=2]="WARNING";var M,k={BrowserDoesNotSupportLocalStorage:0,BrowserCannotReadLocalStorage:1,BrowserCannotReadSessionStorage:2,BrowserCannotWriteLocalStorage:3,BrowserCannotWriteSessionStorage:4,BrowserFailedRemovalFromLocalStorage:5,BrowserFailedRemovalFromSessionStorage:6,CannotSendEmptyTelemetry:7,ClientPerformanceMathError:8,ErrorParsingAISessionCookie:9,ErrorPVCalc:10,ExceptionWhileLoggingError:11,FailedAddingTelemetryToBuffer:12,FailedMonitorAjaxAbort:13,FailedMonitorAjaxDur:14,FailedMonitorAjaxOpen:15,FailedMonitorAjaxRSC:16,FailedMonitorAjaxSend:17,FailedMonitorAjaxGetCorrelationHeader:18,FailedToAddHandlerForOnBeforeUnload:19,FailedToSendQueuedTelemetry:20,FailedToReportDataLoss:21,FlushFailed:22,MessageLimitPerPVExceeded:23,MissingRequiredFieldSpecification:24,NavigationTimingNotSupported:25,OnError:26,SessionRenewalDateIsZero:27,SenderNotInitialized:28,StartTrackEventFailed:29,StopTrackEventFailed:30,StartTrackFailed:31,StopTrackFailed:32,TelemetrySampledAndNotSent:33,TrackEventFailed:34,TrackExceptionFailed:35,TrackMetricFailed:36,TrackPVFailed:37,TrackPVFailedCalc:38,TrackTraceFailed:39,TransmissionFailed:40,FailedToSetStorageBuffer:41,FailedToRestoreStorageBuffer:42,InvalidBackendResponse:43,FailedToFixDepricatedValues:44,InvalidDurationValue:45,TelemetryEnvelopeInvalid:46,CreateEnvelopeError:47,CannotSerializeObject:48,CannotSerializeObjectNonSerializable:49,CircularReferenceDetected:50,ClearAuthContextFailed:51,ExceptionTruncated:52,IllegalCharsInName:53,ItemNotInArray:54,MaxAjaxPerPVExceeded:55,MessageTruncated:56,NameTooLong:57,SampleRateOutOfRange:58,SetAuthContextFailed:59,SetAuthContextFailedAccountName:60,StringValueTooLong:61,StartCalledMoreThanOnce:62,StopCalledWithoutStart:63,TelemetryInitializerFailed:64,TrackArgumentsNotSpecified:65,UrlTooLong:66,SessionStorageBufferFull:67,CannotAccessCookie:68,IdTooLong:69,InvalidEvent:70,FailedMonitorAjaxSetRequestHeader:71,SendBrowserInfoOnUserInit:72,PluginException:73,NotificationException:74,SnippetScriptLoadFailure:99,InvalidInstrumentationKey:100,CannotParseAiBlobValue:101,InvalidContentBlob:102,TrackPageActionEventFailed:103,FailedAddingCustomDefinedRequestContext:104,InMemoryStorageBufferFull:105},Te="attachEvent",we="addEventListener",be="toISOString",Ne="endsWith",_e="indexOf",Re="trim",Ae="toString",Le=e,Ee=(t.freeze,t.seal,t.keys),e=String[o],Fe=e[Re],Me=e[Ne],ke=(e.startsWith,Date[o][be]),e=Array.isArray,De=E[Ae];function g(e){return e===undefined||typeof e===A}function D(e){return null===e||g(e)}function Pe(e){return!D(e)}function Be(e){return!(!e||typeof e!==R)}function d(e){return!(!e||typeof e!==_)}function Ue(e,n,t,r){void 0===r&&(r=!1);var i=!1;if(!D(e))try{D(e[we])?D(e[Te])||(e[Te]("on"+n,t),i=!0):(e[we](n,t,r),i=!0)}catch(o){}return i}function P(e,n){if(e)for(var t in e)V.call(e,t)&&n.call(e,t,e[t])}function B(e,n){return!(!e||!n||!~e.indexOf(n))}V[Ae].call(t);var U=e||function(e){return!(!e||"[object Array]"!==De.call(e))};function Oe(e){return!(!e||"[object Error]"!==De.call(e))}function m(e){return"string"==typeof e}function ze(e){return"number"==typeof e}function je(e){return"boolean"==typeof e}function Ke(e){if(e){if(ke)return e[be]();var n;return e&&e.getUTCFullYear?(n=function(e){e=""+e;return 1===e.length?"0"+e:e},e.getUTCFullYear()+"-"+n(1+e.getUTCMonth())+"-"+n(e.getUTCDate())+"T"+n(e.getUTCHours())+":"+n(e.getUTCMinutes())+":"+n(e.getUTCSeconds())+"."+(e.getUTCMilliseconds()/1e3).toFixed(3).slice(2,5)+"Z"):void 0}}function O(e,n,t){var r=e.length;try{for(var i=0;i<r&&!(i in e&&-1===n.call(t||e,e[i],i,e));i++);}catch(o){}}function qe(e,n,t){if(e){if(e[_e])return e[_e](n,t);var r=e.length,t=t||0;try{for(var i=Math.max(0<=t?t:r-Math.abs(t),0);i<r;i++)if(i in e&&e[i]===n)return i}catch(o){}}return-1}function Ve(e,n,t){if(e){if(e.map)return e.map(n,t);var r=e.length,i=t||e,o=Array(r);try{for(var a=0;a<r;a++)a in e&&(o[a]=n.call(i,e[a],e))}catch(s){}}return o}function v(e){return e&&(Fe&&e[Re]?e[Re]():e.replace?e.replace(/^\s+|\s+$/g,""):e)}var We=!{toString:null}.propertyIsEnumerable("toString"),Ge=["toString","toLocaleString","valueOf","hasOwnProperty","isPrototypeOf","propertyIsEnumerable","constructor"];function He(e){var n=typeof e;if(n===_||n===R&&null!==e||H("objKeys called on non-object"),!We&&Ee)return Ee(e);var t,r=[];for(t in e)e&&V.call(e,t)&&r.push(t);if(We)for(var i=Ge.length,o=0;o<i;o++)e&&V.call(e,Ge[o])&&r.push(Ge[o]);return r}function Xe(e,n,t,r){if(Le)try{var i={enumerable:!0,configurable:!0};return t&&(i.get=t),r&&(i.set=r),Le(e,n,i),!0}catch(o){}return!1}function Ye(){var e=Date;return e.now?e.now():(new e).getTime()}function z(e){return Oe(e)?e.name:""}function y(e,n,t,r,i){var o=t;!e||(o=e[n])===t||i&&!i(o)||r&&!r(t)||(e[n]=o=t)}function Je(e){return!e}function Ze(e){return!!e}function Qe(e){throw Error(e)}function $e(e){return e&&F?t(F({},e)):e}var en="window",nn="navigator",tn="location",rn="console",on="JSON",an="crypto",sn="msCrypto",un="msie",ln="trident/",cn=null,fn=null,dn=null,gn=null;function pn(e,n){var t,r=!1;if(e){try{(r=n in e)||(t=e[o])&&(r=n in t)}catch(i){}if(!r)try{r=!g((new e)[n])}catch(i){}}return r}function I(e){var n=G();return n&&n[e]?n[e]:e===en&&hn()?window:null}function hn(){return typeof window===R&&window}function mn(){return hn()?window:I(en)}function vn(){return typeof document===R&&document?document:I("document")}function yn(){return!(typeof navigator!==R||!navigator)}function In(){return yn()?navigator:I(nn)}function Cn(){return typeof JSON===R&&JSON||null!==I(on)}function j(){return Cn()?JSON||I(on):null}function Sn(){var e=In();return!e||e.userAgent===fn&&null!==cn||(e=((fn=e.userAgent)||"").toLowerCase(),cn=B(e,un)||B(e,ln)),cn}function K(e){var n=Object[o].toString.call(e),t="";return"[object Error]"===n?t="{ stack: '"+e.stack+"', message: '"+e.message+"', name: '"+e.name+"'":Cn()&&(t=j().stringify(e)),n+t}function xn(){return gn=null===gn?yn()&&!!In().sendBeacon:gn}function Tn(e){var n=!1;try{var n=!!I("fetch"),t=I("Request");n&&e&&t&&(n=pn(t,"keepalive"))}catch(r){}return n}function wn(){return dn=null===dn&&(dn="undefined"!=typeof XDomainRequest)&&bn()?dn&&!pn(I("XMLHttpRequest"),"withCredentials"):dn}function bn(){var e=!1;try{e=!!I("XMLHttpRequest")}catch(n){}return e}var Nn,_n=["eventsSent","eventsDiscarded","eventsSendRequest","perfEvent"],Rn=null;function An(e){var n=Rn;return(n=n||!0===e.disableDbgExt?n:Rn||(e=I("Microsoft"),Rn=e?e.ApplicationInsights:Rn))?n.ChromeDbgExt:null}function Ln(e){return e?'"'+e.replace(/\"/g,"")+'"':""}function En(e,n){var t,r=typeof console!==A?console:I(rn);r&&(t="log",d(r[t=r[e]?e:t])&&r[t](n))}Mn.dataType="MessageData";var Fn=Mn;function Mn(e,n,t,r){void 0===t&&(t=!1),this.messageId=e,this.message=(t?"AI: ":"AI (Internal): ")+e;t="",Cn()&&(t=j().stringify(r)),e=(n?" message:"+Ln(n):"")+(r?" props:"+Ln(t):"");this.message+=e}function kn(e,n){return(e||{}).logger||new Dn(n)}var Dn=function Xi(r){this.identifier="DiagnosticLogger",this.queue=[];var i=0,s={};h(Xi,this,function(o){function e(e,n){e=r[e];return D(e)?n:e}function a(e,n){var t=An(r);t&&t.diagLog&&t.diagLog(e,n)}D(r)&&(r={}),o.consoleLoggingLevel=function(){return e("loggingLevelConsole",0)},o.telemetryLoggingLevel=function(){return e("loggingLevelTelemetry",1)},o.maxInternalMessageLimit=function(){return e("maxMessageLimit",25)},o.enableDebugExceptions=function(){return e("enableDebugExceptions",!1)},o.throwInternal=function(e,n,t,r,i){n=new Fn(n,t,i=void 0!==i&&i,r);if(o.enableDebugExceptions())throw K(n);t=e===M.CRITICAL?"errorToConsole":"warnToConsole";g(n.message)?a("throw"+(e===M.CRITICAL?"Critical":"Warning"),n):(r=o.consoleLoggingLevel(),i?(i=+n.messageId,!s[i]&&e<=r&&(o[t](n.message),s[i]=!0)):e<=r&&o[t](n.message),o.logInternalMessage(e,n))},o.warnToConsole=function(e){En("warn",e),a("warning",e)},o.errorToConsole=function(e){En("error",e),a("error",e)},o.resetInternalMessageCount=function(){i=0,s={}},o.logInternalMessage=function(e,n){var t,r;i>=o.maxInternalMessageLimit()||(r=!0,t="AITR_"+n.messageId,s[t]?r=!1:s[t]=!0,r&&(e<=o.telemetryLoggingLevel()&&(o.queue.push(n),i++,a(e===M.CRITICAL?"error":"warn",n)),i===o.maxInternalMessageLimit()&&(r=new Fn(k.MessageLimitPerPVExceeded,t="Internal events throttle limit per PageView reached for this app.",!1),o.queue.push(r),e===M.CRITICAL?o.errorToConsole(t):o.warnToConsole(t))))}})},Pn=(Bn.ParentContextKey="parent",Bn.ChildrenContextKey="childEvts",Bn);function Bn(e,i,n){var t,o=this,a=!1;o.start=Ye(),o.name=e,o.isAsync=n,o.isChildEvt=function(){return!1},d(i)&&(a=Xe(o,"payload",function(){return!t&&d(i)&&(t=i(),i=null),t})),o.getCtx=function(e){return e?(e===Bn.ParentContextKey||e===Bn.ChildrenContextKey?o:o.ctx||{})[e]:null},o.setCtx=function(e,n){e&&(e===Bn.ParentContextKey?(o[e]||(o.isChildEvt=function(){return!0}),o[e]=n):e===Bn.ChildrenContextKey?o[e]=n:(o.ctx=o.ctx||{})[e]=n)},o.complete=function(){var e=0,n=o.getCtx(Bn.ChildrenContextKey);if(U(n))for(var t=0;t<n.length;t++){var r=n[t];r&&(e+=r.time)}o.time=Ye()-o.start,o.exTime=o.time-e,o.complete=function(){},!a&&d(i)&&(o.payload=i())}}var Un=function Yi(n){this.ctx={},h(Yi,this,function(t){t.create=function(e,n,t){return new Pn(e,n,t)},t.fire=function(e){e&&(e.complete(),n&&d(n.perfEvent)&&n.perfEvent(e))},t.setCtx=function(e,n){e&&((t.ctx=t.ctx||{})[e]=n)},t.getCtx=function(e){return(t.ctx||{})[e]}})},On="CoreUtils.doPerf";function zn(e,n,t,r,i){if(e)if(e=d(e.getPerfMgr)?e.getPerfMgr():e){var o,a=void 0,s=e.getCtx(On);try{if(a=e.create(n(),r,i))return s&&a.setCtx&&(a.setCtx(Pn.ParentContextKey,s),s.getCtx&&s.setCtx&&((o=s.getCtx(Pn.ChildrenContextKey))||(o=[],s.setCtx(Pn.ChildrenContextKey,o)),o.push(a))),e.setCtx(On,a),t(a)}catch(u){a&&a.setCtx&&a.setCtx("exception",u)}finally{a&&e.fire(a),e.setCtx(On,s)}}t()}var jn=function(i,n){var o=this,a=null,s=d(i.processTelemetry),u=d(i.setNextPlugin);o._hasRun=!1,o.getPlugin=function(){return i},o.getNext=function(){return a},o.setNext=function(e){a=e},o.processTelemetry=function(t,r){r=r||n;var e=i?i.identifier:"TelemetryPluginChain";zn(r?r.core():null,function(){return e+":processTelemetry"},function(){if(i&&s){o._hasRun=!0;try{r.setNext(a),u&&i.setNextPlugin(a),a&&(a._hasRun=!1),i.processTelemetry(t,r)}catch(n){var e=a&&a._hasRun;a&&e||r.diagLog().throwInternal(M.CRITICAL,k.PluginException,"Plugin ["+i.identifier+"] failed during processTelemetry - "+K(n)),a&&!e&&a.processTelemetry(t,r)}}else a&&(o._hasRun=!0,a.processTelemetry(t,r))},function(){return{item:t}},!t.sync)}};function Kn(e,n){var t=[];if(e&&0<e.length)for(var r=null,i=0;i<e.length;i++){var o=e[i];o&&d(o.processTelemetry)&&(o=new jn(o,n),t.push(o),r&&r.setNext(o),r=o)}return 0<t.length?t[0]:null}var qn=function Ji(e,i,t,n){var r,o,a,s,u=this,l=null;null!==n&&(e&&d(e.getPlugin)?l=function(e,n,t){var r=[],i=!t;if(e)for(;e;){var o=e.getPlugin();!i&&o!==t||(i=!0,r.push(o)),e=e.getNext()}return i||r.push(t),Kn(r,n)}(e,u,n||e.getPlugin()):n?(r=u,a=e,s=!1,(o=n)&&e&&(a=[],O(e,function(e){!s&&e!==o||(s=!0,a.push(e))})),o&&!s&&(a=a||[]).push(o),l=Kn(a,r)):g(n)&&(l=Kn(e,u))),u.core=function(){return t},u.diagLog=function(){return kn(t,i)},u.getCfg=function(){return i},u.getExtCfg=function(e,n){var t,r;return void 0===n&&(n={}),(t=i&&(r=i.extensionConfig)&&e?r[e]:t)||n},u.getConfig=function(e,n,t){void 0===t&&(t=!1);var r,e=u.getExtCfg(e,null);return e&&!D(e[n])?r=e[n]:i&&!D(i[n])&&(r=i[n]),D(r)?t:r},u.hasNext=function(){return null!=l},u.getNext=function(){return l},u.setNext=function(e){l=e},u.processNext=function(e){var n=l;n&&(l=n.getNext(),n.processTelemetry(e,u))},u.createNew=function(e,n){return new Ji((e=void 0===e?null:e)||l,i,t,n)}},Vn="extensionConfig",Wn="getPlugin",Ae=(Gn.prototype.initialize=function(e,n,t,r){this._baseTelInit(e,n,t,r)},Gn);function Gn(){var o=this,a=!1,s=null,u=null;o.core=null,o.diagLog=function(e){return o._getTelCtx(e).diagLog()},o.isInitialized=function(){return a},o.setInitialized=function(e){a=e},o.setNextPlugin=function(e){u=e},o.processNext=function(e,n){n?n.processNext(e):u&&d(u.processTelemetry)&&u.processTelemetry(e,null)},o._getTelCtx=function(e){var n,e=e=void 0===e?null:e;return e||(n=s||new qn(null,{},o.core),e=u&&u[Wn]?n.createNew(null,u[Wn]):n.createNew(null,u)),e},o._baseTelInit=function(e,n,t,r){e&&y(e,Vn,[],null,D),!r&&n&&(r=n.getProcessTelContext().getNext());var i=u;u&&u[Wn]&&(i=u[Wn]()),o.core=n,s=new qn(r,e,n,i),a=!0}}var Hn="processTelemetry",Xn="priority",Yn="setNextPlugin",Jn="isInitialized";function Zn(n,t){for(var e=[],r=null,i=n.getNext();i;){var o=i.getPlugin();o&&(r&&d(r[Yn])&&d(o[Hn])&&r[Yn](o),d(o[Jn])&&o[Jn]()||e.push(o),r=o,i=i.getNext())}O(e,function(e){e.initialize(n.getCfg(),n.core(),t,n.getNext())})}function Qn(e){return e.sort(function(e,n){var t=0,r=d(n[Hn]);return d(e[Hn])?t=r?e[Xn]-n[Xn]:1:r&&(t=-1),t})}n(nt,$n=Ae),nt._staticInit=(Xe(e=nt.prototype,"ChannelControls",e.getChannelControls),void Xe(e,"channelQueue",e.getChannelControls));var $n,et=nt;function nt(){var u,r=$n.call(this)||this;function l(e){e&&0<e.length&&(O(e=e.sort(function(e,n){return e.priority-n.priority}),function(e){e.priority<500&&Qe("Channel has invalid priority"+e.identifier)}),u.push(e))}return r.identifier="ChannelControllerPlugin",r.priority=500,h(nt,r,function(a,s){a.setNextPlugin=function(e){},a.processTelemetry=function(n,t){u&&O(u,function(e){0<e.length&&r._getTelCtx(t).createNew(e).processNext(n)})},a.getChannelControls=function(){return u},a.initialize=function(n,t,r){var e,i,o;a.isInitialized()||(s.initialize(n,t,r),e=(n||{}).channels,i=r,u=[],e&&O(e,l),i&&(o=[],O(i,function(e){500<e.priority&&o.push(e)}),l(o)),O(u,function(e){return Zn(new qn(e,n,t),r)}))}}),r}var tt="toGMTString",rt="toUTCString",it="cookie",ot="expires",at="enabled",st="isCookieUseDisabled",ut="disableCookiesUsage",lt="_ckMgr",C="",ct=null,ft=null,dt=null,gt=vn(),pt={},ht={};function mt(e){return!e||e.isEnabled()}function vt(e,i){y(t=(e=e||ht).cookieCfg=e.cookieCfg||{},"domain",e.cookieDomain,Pe,D),y(t,"path",e.cookiePath||"/",null,D),D(t[at])&&(n=void 0,g(e[st])||(n=!e[st]),g(e[ut])||(n=!e[ut]),t[at]=n);var n,t,l=t,c=l.path||"/",f=l.domain,r=!1!==l[at],d={isEnabled:function(){var e=r&&yt(i),n=ht[lt];return e&&n&&d!==n?mt(n):e},setEnabled:function(e){r=!1!==e},set:function(e,n,t,r,i){var o,a,s,u=!1;return mt(d)&&(o={},-1!=(s=(a=v(n||C)).indexOf(";"))&&(a=v(n.substring(0,s)),o=It(n.substring(1+s))),y(o,"domain",r||f,Ze,g),D(t)||(s=Sn(),g(o[ot])&&0<(n=Ye()+1e3*t)&&((r=new Date).setTime(n),y(o,ot,Ct(r,s?tt:rt)||Ct(r,s?tt:rt)||C,Ze)),s||y(o,"max-age",C+t,null,g)),(n=typeof location===R&&location?location:I(tn))&&"https:"===n.protocol&&(y(o,"secure",null,null,g),(ft=null===ft?!(m(r=(In()||{}).userAgent)&&(B(r,"CPU iPhone OS 12")||B(r,"iPad; CPU OS 12")||B(r,"Macintosh; Intel Mac OS X 10_14")&&B(r,"Version/")&&B(r,"Safari")||B(r,"Macintosh; Intel Mac OS X 10_14")&&function(e,n){var t=!1;if(!e||(t=e===n))return t;if(Me)return e[Ne](n);var r=e,i=n,t=!1,e=r?r.length:0;if(e&&40<=e&&!(t=r===i)){for(var o=e-1,a=39;0<=a;a--){if(r[o]!=i[a])return;o--}t=!0}return t}(r,"AppleWebKit/605.1.15 (KHTML, like Gecko)")||B(r,"Chrome/5")||B(r,"Chrome/6")||B(r,"UnrealEngine")&&!B(r,"Chrome")||B(r,"UCBrowser/12")||B(r,"UCBrowser/11"))):ft)&&y(o,"SameSite","None",null,g)),y(o,"path",i||c,null,g),(l.setCookie||xt)(e,St(a,o)),u=!0),u},get:function(e){var n=C;return mt(d)?(l.getCookie||function(e){var n,t=C;return gt&&(n=gt[it]||C,dt!==n&&(pt=It(n),dt=n),t=v(pt[e]||C)),t})(e):n},del:function(e,n){return!!mt(d)&&d.purge(e,n)},purge:function(e,n){var t,r=!1;return yt(i)&&((t={}).path=n||"/",t[ot]="Thu, 01 Jan 1970 00:00:01 GMT",n=t,Sn()||(n["max-age"]="0"),(l.delCookie||xt)(e,St(C,n)),r=!0),r}};return d[lt]=d}function yt(e){if(null===ct){ct=!1;try{ct=(gt||{})[it]!==undefined}catch(n){e&&e.throwInternal(M.WARNING,k.CannotAccessCookie,"Cannot access document.cookie - "+z(n),{exception:K(n)})}}return ct}function It(e){var t={};return e&&e.length&&O(v(e).split(";"),function(e){var n;(e=v(e||C))&&(-1==(n=e.indexOf("="))?t[e]=null:t[v(e.substring(0,n))]=v(e.substring(1+n)))}),t}function Ct(e,n){return d(e[n])?e[n]():null}function St(e,n){var t=e||C;return P(n,function(e,n){t+="; "+e+(D(n)?C:"="+n)}),t}function xt(e,n){gt&&(gt[it]=e+"="+n)}var Tt="_notificationManager";function wt(e,n){return new Un(n)}var bt,Nt=function Zi(e){this.listeners=[];var n=!!(e||{}).perfEvtsSendAll;h(Zi,this,function(i){i.addNotificationListener=function(e){i.listeners.push(e)},i.removeNotificationListener=function(e){for(var n=qe(i.listeners,e);-1<n;)i.listeners.splice(n,1),n=qe(i.listeners,e)},i.eventsSent=function(n){O(i.listeners,function(e){e&&e.eventsSent&&setTimeout(function(){return e.eventsSent(n)},0)})},i.eventsDiscarded=function(n,t){O(i.listeners,function(e){e&&e.eventsDiscarded&&setTimeout(function(){return e.eventsDiscarded(n,t)},0)})},i.eventsSendRequest=function(t,r){O(i.listeners,function(e){if(e&&e.eventsSendRequest)if(r)setTimeout(function(){return e.eventsSendRequest(t,r)},0);else try{e.eventsSendRequest(t,r)}catch(n){}})},i.perfEvent=function(t){!t||!n&&t.isChildEvt()||O(i.listeners,function(e){if(e&&e.perfEvent)if(t.isAsync)setTimeout(function(){return e.perfEvent(t)},0);else try{e.perfEvent(t)}catch(n){}})}})},_t=(n(Rt,bt=function Qi(){var n,l,c,t,r,f=!1;h(Qi,this,function(u){u._extensions=[],l=new et,u.logger=new Dn({loggingLevelConsole:M.CRITICAL}),n=[],u.isInitialized=function(){return f},u.initialize=function(e,n,r,t){u.isInitialized()&&Qe("Core should not be initialized more than once"),e&&!D(e.instrumentationKey)||Qe("Please provide instrumentation key"),c=t,u[Tt]=t,u.config=e||{},t&&!0!==u.config.disableDbgExt&&t.addNotificationListener(function(e){if(!Nn){Nn={};for(var n=0;n<_n.length;n++)Nn[_n[n]]=function(n,t){return function(){var e=An(t);e&&(e=e.listener)&&e[n]&&e[n].apply(e,arguments)}}(_n[n],e)}return Nn}(e)),u.config.enablePerfMgr&&y(u.config,"createPerfMgr",wt),e.extensions=D(e.extensions)?[]:e.extensions,e?!(i=e[Vn])&&D(i)&&(i=g(o)?{}:o,e[Vn]=i):i=g(o)?{}:o,i.NotificationManager=t,r&&(u.logger=r);var i,o=[],a=(o.push.apply(o,Z(Z([],n),e.extensions)),o=Qn(o),[]),s={};O(o,function(e){(D(e)||D(e.initialize))&&Qe("Extensions must provide callback to initialize");var n=e.priority,t=e.identifier;e&&n&&(D(s[n])?s[n]=t:r.warnToConsole("Two extensions have same priority #"+n+" - "+s[n]+", "+t)),(!n||n<l.priority)&&a.push(e)}),o.push(l),a.push(l),o=Qn(o),u._extensions=o,Zn(new qn([l],e,u),o),Zn(new qn(a,e,u),o),u._extensions=a,0===u.getTransmissionControls().length&&Qe("No channels available"),f=!0,u.releaseQueue()},u.getTransmissionControls=function(){return l.getChannelControls()},u.track=function(e){y(e,"iKey",u.config.instrumentationKey,null,Je),y(e,"time",Ke(new Date),null,Je),y(e,"ver","4.0",null,D),u.isInitialized()?u.getProcessTelContext().processNext(e):n.push(e)},u.getProcessTelContext=function(){var e=u._extensions,n=e;return e&&0!==e.length||(n=[l]),new qn(n,u.config,u)},u.getNotifyMgr=function(){return c||(c=X({addNotificationListener:function(e){},removeNotificationListener:function(e){},eventsSent:function(e){},eventsDiscarded:function(e,n){},eventsSendRequest:function(e,n){}}),u[Tt]=c),c},u.getCookieMgr=function(){return r=r||vt(u.config,u.logger)},u.setCookieMgr=function(e){r=e},u.getPerfMgr=function(){return t||u.config&&u.config.enablePerfMgr&&d(u.config.createPerfMgr)&&(t=u.config.createPerfMgr(u,u.getNotifyMgr())),t||null},u.setPerfMgr=function(e){t=e},u.eventCnt=function(){return n.length},u.releaseQueue=function(){0<n.length&&(O(n,function(e){u.getProcessTelContext().processNext(e)}),n=[])}})}),Rt);function Rt(){var e=bt.call(this)||this,r=0;return h(Rt,e,function(t,i){function n(e){var n=t.getNotifyMgr();n&&n.eventsDiscarded([e],2)}t.initialize=function(e,n,t,r){i.initialize(e,n,t||new Dn(e),r||new Nt(e))},t.track=function(e){zn(t.getPerfMgr(),function(){return"AppInsightsCore:track"},function(){if(null===e&&(n(e),Qe("Invalid telemetry item")),D(e.name))throw n(e),Error("telemetry name required");i.track(e)},function(){return{item:e}},!e.sync)},t.addNotificationListener=function(e){var n=t.getNotifyMgr();n&&n.addNotificationListener(e)},t.removeNotificationListener=function(e){var n=t.getNotifyMgr();n&&n.removeNotificationListener(e)},t.pollInternalLogs=function(n){var e=t.config.diagnosticLogInterval;return e&&0<e||(e=1e4),r&&t.stopPollingInternalLogs(),r=setInterval(function(){var e=t.logger?t.logger.queue:[];O(e,function(e){e={name:n||"InternalMessageId: "+e.messageId,iKey:t.config.instrumentationKey,time:Ke(new Date),baseType:Fn.dataType,baseData:{message:e.message}};t.track(e)}),e.length=0},e)},t.stopPollingInternalLogs=function(){r&&(clearInterval(r),r=0)}}),e}var At=4294967296,Lt=4294967295,Et=!1,Ft=123456789,Mt=987654321;function kt(e){e<0&&(e>>>=0),Ft=123456789+e&Lt,Mt=987654321-e&Lt,Et=!0}function Dt(){try{var e=2147483647&Ye();kt((Math.random()*At^e)+e)}catch(n){}}function Pt(e){return 0<e?Math.floor(Bt()/Lt*(e+1))>>>0:0}function Bt(e){var n=I(an)||I(sn),n=n&&n.getRandomValues?n.getRandomValues(new Uint32Array(1))[0]&Lt:Sn()?(Et||Dt(),Ut()&Lt):Math.floor(At*Math.random()|0);return e||(n>>>=0),n}function Ut(e){var n=((Mt=36969*(65535&Mt)+(Mt>>16)&Lt)<<16)+(65535&(Ft=18e3*(65535&Ft)+(Ft>>16)&Lt))>>>0&Lt|0;return e||(n>>>=0),n}var Ot,zt=null,jt={_canUseCookies:undefined,isTypeof:function(e,n){return typeof e===n},isUndefined:g,isNullOrUndefined:D,hasOwnProperty:function(e,n){return!(!e||!V.call(e,n))},isFunction:d,isObject:Be,isDate:function(e){return!(!e||"[object Date]"!==De.call(e))},isArray:U,isError:Oe,isString:m,isNumber:ze,isBoolean:je,toISOString:Ke,arrForEach:O,arrIndexOf:qe,arrMap:Ve,arrReduce:function(e,n,t){var r;if(e){if(e.reduce)return e.reduce(n,t);var i=e.length,o=0;if(3<=arguments.length)r=t;else{for(;o<i&&!(o in e);)o++;r=e[o++]}for(;o<i;)o in e&&(r=n(r,e[o],o,e)),o++}return r},strTrim:v,objCreate:X,objKeys:He,objDefineAccessors:Xe,addEventHandler:function(e,n){var t=!1,r=mn(),r=(r&&(t=Ue(r,e,n),t=Ue(r.body,e,n)||t),vn());return r&&Ue(r,e,n)||t},dateNow:Ye,isIE:Sn,disableCookies:function(){var e,n;(e=vt[lt]||ht[lt])||(e=vt[lt]=vt(void 0,void 0),ht[lt]=e),e=e,n=jt._canUseCookies,null===zt&&(zt=[],Ot=n,Xe(jt,"_canUseCookies",function(){return Ot},function(n){Ot=n,O(zt,function(e){e.setEnabled(n)})})),-1===qe(zt,e)&&zt.push(e),je(n)&&e.setEnabled(n),je(Ot)&&e.setEnabled(Ot),e.setEnabled(!1)},newGuid:function(){return"xxxxxxxx-xxxx-4xxx-yxxx-xxxxxxxxxxxx".replace(Kt,function(e){var n=0|Pt(15);return("x"===e?n:3&n|8).toString(16)})},perfNow:function(){var e=I("performance");return e&&e.now?e.now():Ye()},newId:function(e){void 0===e&&(e=22);for(var n=Bt()>>>0,t=0,r="";r.length<e;)r+="ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789+/"[0|63&n]||"",n>>>=6,5==++t&&(n=(Bt()<<2&4294967295|3&n)>>>0,t=0);return r},randomValue:Pt,random32:Bt,mwcRandomSeed:function(e){e?kt(e):Dt()},mwcRandom32:Ut,generateW3CId:function(){for(var e,n=["0","1","2","3","4","5","6","7","8","9","a","b","c","d","e","f"],t="",r=0;r<4;r++)t+=n[15&(e=Bt())]+n[e>>4&15]+n[e>>8&15]+n[e>>12&15]+n[e>>16&15]+n[e>>20&15]+n[e>>24&15]+n[e>>28&15];var i=n[8+(3&Bt())|0];return t.substr(0,8)+t.substr(9,4)+"4"+t.substr(13,3)+i+t.substr(16,3)+t.substr(19,12)}},Kt=/[xy]/g;function qt(e,n,t){var r,i,o=n.length,a=(e=e,(n=n)&&150<(n=v(n.toString())).length&&(i=n.substring(0,150),e&&e.throwInternal(M.WARNING,k.NameTooLong,"name is too long. It has been truncated to 150 characters.",{name:n},!0)),i||n);if(a.length!==o){for(var s=0,u=a;t[u]!==undefined;)s++,u=a.substring(0,147)+(r=void 0,(r="00"+s).substr(r.length-3));a=u}return a}function S(e,n,t){var r;return void 0===t&&(t=1024),n&&(t=t||1024,(n=v(n)).toString().length>t&&(r=n.toString().substring(0,t),e&&e.throwInternal(M.WARNING,k.StringValueTooLong,"string value is too long. It has been truncated to "+t+" characters.",{value:n},!0))),r||n}function Vt(e,n){return Xt(e,n,2048,k.UrlTooLong)}function Wt(e,n){var t;return n&&32768<n.length&&(t=n.substring(0,32768),e&&e.throwInternal(M.WARNING,k.MessageTruncated,"message is too long, it has been truncated to 32768 characters.",{message:n},!0)),t||n}function Gt(r,e){var i;return e&&(i={},P(e,function(e,n){if(Be(n)&&Cn())try{n=j().stringify(n)}catch(t){r&&r.throwInternal(M.WARNING,k.CannotSerializeObjectNonSerializable,"custom property is not valid",{exception:t},!0)}n=S(r,n,8192),e=qt(r,e,i),i[e]=n}),e=i),e}function Ht(t,e){var r;return e&&(r={},P(e,function(e,n){e=qt(t,e,r),r[e]=n}),e=r),e}function Xt(e,n,t,r){var i;return n&&(n=v(n)).length>t&&(i=n.substring(0,t),e&&e.throwInternal(M.WARNING,r,"input is too long, it has been truncated to "+t+" characters.",{data:n},!0)),i||n}function Yt(e){var n=""+Math.floor((e=Math.round(e=isNaN(e)||e<0?0:e))/1e3)%60,t=""+Math.floor(e/6e4)%60,r=""+Math.floor(e/36e5)%24,i=Math.floor(e/864e5),e=1===(e=""+e%1e3).length?"00"+e:2===e.length?"0"+e:e,n=n.length<2?"0"+n:n,t=t.length<2?"0"+t:t;return(0<i?i+".":"")+(r=r.length<2?"0"+r:r)+":"+t+":"+n+"."+e}var Jt,Zt="Microsoft_ApplicationInsights_BypassAjaxInstrumentation",Qt="sampleRate",$t="ProcessLegacy",er="http.method",nr="not_specified",tr=((e=Jt=Jt||{})[e.LocalStorage=0]="LocalStorage",e[e.SessionStorage=1]="SessionStorage",undefined);function rr(e){try{if(D(G()))return null;var n=new Date,t=I(e===Jt.LocalStorage?"localStorage":"sessionStorage"),r=(t.setItem(n.toString(),n.toString()),t.getItem(n.toString())!==n.toString());if(t.removeItem(n.toString()),!r)return t}catch(i){}return null}function ir(){return or()?rr(Jt.SessionStorage):null}function or(){return tr=tr===undefined?!!rr(Jt.SessionStorage):tr}function ar(e,n){var t=ir();if(null!==t)try{return t.getItem(n)}catch(r){tr=!1,e.throwInternal(M.WARNING,k.BrowserCannotReadSessionStorage,"Browser failed read of session storage. "+z(r),{exception:K(r)})}return null}function sr(e,n,t){var r=ir();if(null!==r)try{r.setItem(n,t)}catch(i){tr=!1,e.throwInternal(M.WARNING,k.BrowserCannotWriteSessionStorage,"Browser failed write to session storage. "+z(i),{exception:K(i)})}}var ur=vn()||{},lr=0,cr=[null,null,null,null,null];var fr=["https://dc.services.visualstudio.com/v2/track","https://breeze.aimon.applicationinsights.io/v2/track","https://dc-int.services.visualstudio.com/v2/track"];function dr(e){return-1!==qe(fr,e.toLowerCase())}n(pr,gr=function(){});var gr,e=pr;function pr(){return gr.call(this)||this}n(vr,hr=function(){this.ver=1,this.sampleRate=100,this.tags={}});var hr,mr=vr;function vr(e,n,t){var r=hr.call(this)||this;return r.name=S(e,t)||nr,r.data=n,r.time=Ke(new Date),r.aiDataContract={time:1,iKey:1,name:1,sampleRate:function(){return 100===r.sampleRate?4:1},tags:1,data:1},r}var yr,r=function(){this.ver=2,this.properties={},this.measurements={}},Ir=(n(Cr,yr=r),Cr.envelopeType="Microsoft.ApplicationInsights.{0}.Event",Cr.dataType="EventData",Cr);function Cr(e,n,t,r){var i=yr.call(this)||this;return i.aiDataContract={ver:1,name:1,properties:0,measurements:0},i.name=S(e,n)||nr,i.properties=Gt(e,t),i.measurements=Ht(e,r),i}var Sr="error",u="stack",xr="stackDetails",Tr="errorSrc",wr="message",br="description";function Nr(e,n){var t=e;return t&&!m(t)&&(JSON&&JSON.stringify?(t=JSON.stringify(e),!n||t&&"{}"!==t||(t=d(e.toString)?e.toString():""+e)):t=e+" - (Missing JSON.stringify)"),t||""}function _r(e,n){var t=e;return e&&((t=t&&!m(t)&&(e[wr]||e[br])||t)&&!m(t)&&(t=Nr(t,!0)),e.filename&&(t=t+" @"+(e.filename||"")+":"+(e.lineno||"?")+":"+(e.colno||"?"))),(n&&"String"!==n&&"Object"!==n&&"Error"!==n&&!~(t||"").indexOf(n)?n+": "+t:t)||""}function Rr(e){return e&&e.src&&m(e.src)&&e.obj&&U(e.obj)}function Ar(e){var e=e||"",n=(e=m(e)?e:m(e[u])?e[u]:""+e).split("\n");return{src:e,obj:n}}function Lr(e){var n,t=null;if(e)try{e[u]?t=Ar(e[u]):e[Sr]&&e[Sr][u]?t=Ar(e[Sr][u]):e.exception&&e.exception[u]?t=Ar(e.exception[u]):Rr(e)?t=e:Rr(e[xr])?t=e[xr]:window&&window.opera&&e[wr]?t=function(e){for(var n=[],t=e.split("\n"),r=0;r<t.length;r++){var i=t[r];t[r+1]&&(i+="@"+t[r+1],r++),n.push(i)}return{src:e,obj:n}}(e.message):m(e)?t=Ar(e):(n=e[wr]||e[br]||"",m(e[Tr])&&(n&&(n+="\n"),n+=" from "+e[Tr]),n&&(t=Ar(n)))}catch(r){t=Ar(r)}return t||{src:"",obj:null}}function Er(e){var n="";if(e&&!(n=e.typeName||e.name||""))try{var t=/function (.{1,200})\(/.exec(e.constructor.toString()),n=t&&1<t.length?t[1]:""}catch(r){}return n}function Fr(e){if(e)try{var n,t;if(!m(e))return n=Er(e),(t=Nr(e,!1))&&"{}"!==t||(e[Sr]&&(n=Er(e=e[Sr])),t=Nr(e,!0)),t.indexOf(n)&&"String"!==n?n+":"+t:t}catch(r){}return""+(e||"")}n(a,Mr=function(){this.ver=2,this.exceptions=[],this.properties={},this.measurements={}}),a.CreateAutoException=function(e,n,t,r,i,o,a,s){var u=Er(i||o||e);return{message:_r(e,u),url:n,lineNumber:t,columnNumber:r,error:Fr(i||o||e),evt:Fr(o||e),typeName:u,stackDetails:Lr(a||i||o),errorSrc:s}},a.CreateFromInterface=function(n,e,t,r){var i=e.exceptions&&Ve(e.exceptions,function(e){return Pr.CreateFromInterface(n,e)});return new a(n,Y(Y({},e),{exceptions:i}),t,r)},a.prototype.toInterface=function(){var e=this,n=e.exceptions,t=e.properties,r=e.measurements,i=e.severityLevel,o=e.problemGroup,a=e.id,e=e.isManual;return{ver:"4.0",exceptions:n instanceof Array&&Ve(n,function(e){return e.toInterface()})||undefined,severityLevel:i,properties:t,measurements:r,problemGroup:o,id:a,isManual:e}},a.CreateSimpleException=function(e,n,t,r,i,o){return{exceptions:[{hasFullStack:!0,message:e,stack:i,typeName:n}]}},a.envelopeType="Microsoft.ApplicationInsights.{0}.Exception",a.dataType="ExceptionData",a.formatError=Fr;var Mr,kr=a;function a(e,n,t,r,i,o){var a=Mr.call(this)||this;return a.aiDataContract={ver:1,exceptions:1,severityLevel:0,properties:0,measurements:0},function(e){try{if(Be(e))return"ver"in e&&"exceptions"in e&&"properties"in e}catch(n){}}(n)?(a.exceptions=n.exceptions,a.properties=n.properties,a.measurements=n.measurements,n.severityLevel&&(a.severityLevel=n.severityLevel),n.id&&(a.id=n.id),n.problemGroup&&(a.problemGroup=n.problemGroup),a.ver=2,D(n.isManual)||(a.isManual=n.isManual)):(a.exceptions=[new Pr(e,n,t=t||{})],a.properties=Gt(e,t),a.measurements=Ht(e,r),i&&(a.severityLevel=i),o&&(a.id=o)),a}n(Br,Dr=function(){this.hasFullStack=!0,this.parsedStack=[]}),Br.prototype.toInterface=function(){var e=this.parsedStack instanceof Array&&Ve(this.parsedStack,function(e){return e.toInterface()});return{id:this.id,outerId:this.outerId,typeName:this.typeName,message:this.message,hasFullStack:this.hasFullStack,stack:this[u],parsedStack:e||undefined}},Br.CreateFromInterface=function(e,n){var t=n.parsedStack instanceof Array&&Ve(n.parsedStack,function(e){return zr.CreateFromInterface(e)})||n.parsedStack;return new Br(e,Y(Y({},n),{parsedStack:t}))};var Dr,Pr=Br;function Br(e,n,t){var l,r,i,o,a,s=Dr.call(this)||this;return s.aiDataContract={id:0,outerId:0,typeName:1,message:1,hasFullStack:0,stack:0,parsedStack:2},function(e){try{if(Be(e))return"hasFullStack"in e&&"typeName"in e}catch(n){}}(n)?(s.typeName=n.typeName,s.message=n.message,s[u]=n[u],s.parsedStack=n.parsedStack,s.hasFullStack=n.hasFullStack):(r=(o=n)&&o.evt,Oe(o)||(o=o[Sr]||r||o),s.typeName=S(e,Er(o))||nr,s.message=Wt(e,_r(n||o,s.typeName))||nr,l=n[xr]||Lr(n),s.parsedStack=function(){var e=l.obj;if(e&&0<e.length){var n=[],t=0,r=0;if(O(e,function(e){var e=e.toString();zr.regex.test(e)&&(e=new zr(e,t++),r+=e.sizeInBytes,n.push(e))}),32768<r)for(var i=0,o=n.length-1,a=0,s=i,u=o;i<o;){if(32768<(a+=n[i].sizeInBytes+n[o].sizeInBytes)){n.splice(s,u-s+1);break}s=i,u=o,i++,o--}}return n}(),s[u]=(r=e,a="",(o=l)&&(o.obj?O(o.obj,function(e){a+=e+"\n"}):a=o.src||""),(n=a)&&32768<(e=""+n).length&&(i=e.substring(0,32768),r&&r.throwInternal(M.WARNING,k.ExceptionTruncated,"exception is too long, it has been truncated to 32768 characters.",{exception:n},!0)),i||n),s.hasFullStack=U(s.parsedStack)&&0<s.parsedStack.length,t&&(t.typeName=t.typeName||s.typeName)),s}n(i,Ur=function(){}),i.CreateFromInterface=function(e){return new i(e,null)},i.prototype.toInterface=function(){return{level:this.level,method:this.method,assembly:this.assembly,fileName:this.fileName,line:this.line}},i.regex=/^([\s]+at)?[\s]{0,50}([^\@\()]+?)[\s]{0,50}(\@|\()([^\(\n]+):([0-9]+):([0-9]+)(\)?)$/,i.baseSize=58;var Ur,Or,zr=i;function i(e,n){var t,r=Ur.call(this)||this;return r.sizeInBytes=0,r.aiDataContract={level:1,method:1,assembly:0,fileName:0,line:0},"string"==typeof e?(t=e,r.level=n,r.method="<no_method>",r.assembly=v(t),r.fileName="",r.line=0,(n=t.match(i.regex))&&5<=n.length&&(r.method=v(n[2])||r.method,r.fileName=v(n[4]),r.line=parseInt(n[5])||0)):(r.level=e.level,r.method=e.method,r.assembly=e.assembly,r.fileName=e.fileName,r.line=e.line,r.sizeInBytes=0),r.sizeInBytes+=r.method.length,r.sizeInBytes+=r.fileName.length,r.sizeInBytes+=r.assembly.length,r.sizeInBytes+=i.baseSize,r.sizeInBytes+=r.level.toString().length,r.sizeInBytes+=r.line.toString().length,r}Or=0,n(qr,jr=function(){this.kind=Or});var jr,Kr=qr;function qr(){var e=null!==jr&&jr.apply(this,arguments)||this;return e.aiDataContract={name:1,kind:0,value:1,count:0,min:0,max:0,stdDev:0},e}n(Gr,Vr=function(){this.ver=2,this.metrics=[],this.properties={},this.measurements={}}),Gr.envelopeType="Microsoft.ApplicationInsights.{0}.Metric",Gr.dataType="MetricData";var Vr,Wr=Gr;function Gr(e,n,t,r,i,o,a,s,u){var l=Vr.call(this)||this,c=(l.aiDataContract={ver:1,metrics:1,properties:0},new Kr);return c.count=0<r?r:undefined,c.max=isNaN(o)||null===o?undefined:o,c.min=isNaN(i)||null===i?undefined:i,c.name=S(e,n)||nr,c.value=t,c.stdDev=isNaN(a)||null===a?undefined:a,l.metrics=[c],l.properties=Gt(e,s),l.measurements=Ht(e,u),l}n(Xr,Hr=r);var Hr,r=Xr;function Xr(){var e=Hr.call(this)||this;return e.ver=2,e.properties={},e.measurements={},e}n(Zr,Yr=r),Zr.envelopeType="Microsoft.ApplicationInsights.{0}.Pageview",Zr.dataType="PageviewData";var Yr,Jr=Zr;function Zr(e,n,t,r,i,o,a){var s=Yr.call(this)||this;return s.aiDataContract={ver:1,name:0,url:0,duration:0,properties:0,measurements:0,id:0},s.id=a&&Xt(e,a,128,k.IdTooLong).toString(),s.url=Vt(e,t),s.name=S(e,n)||nr,isNaN(r)||(s.duration=Yt(r)),s.properties=Gt(e,i),s.measurements=Ht(e,o),s}n(ei,Qr=function(){this.ver=2,this.success=!0,this.properties={},this.measurements={}}),ei.envelopeType="Microsoft.ApplicationInsights.{0}.RemoteDependency",ei.dataType="RemoteDependencyData";var Qr,$r=ei;function ei(e,n,t,r,i,o,a,s,u,l,c,f){void 0===u&&(u="Ajax");var d,g,p,h=Qr.call(this)||this,t=(h.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},h.id=n,h.duration=Yt(i),h.success=o,h.resultCode=a+"",h.type=S(e,u),n=e,i=s,u=a=o=r,a=(s=t)&&0<s.length?(d=s,p=(t=cr)[g=lr],ur.createElement?t[g]||(p=t[g]=ur.createElement("a")):p={host:function(){e=null,d&&null!=(t=d.match(/(\w*):\/\/(.[^/:]+)(\:[\d]+)?/i))&&2<t.length&&m(t[2])&&0<t[2].length&&(e=t[2]||"",2<t.length&&(n=(t[1]||"").toLowerCase(),t=t[3]||"",e+=t="http"==n&&":80"===t||"https"==n&&":443"===t?"":t));var e,n=e||"";if(n){var t=n.match(/(www[0-9]?\.)?(.[^/:]+)(\:[\d]+)?/i);if(null!=t&&3<t.length&&m(t[2])&&0<t[2].length)return t[2]+(t[3]||"")}return n}()},p.href=d,++g>=t.length&&(g=0),lr=g,g=(t=p).host,a||(null!=t.pathname?("/"!=((p=0===t.pathname.length?"/":t.pathname)[0]||"")&&(p="/"+p),u=t.pathname,S(n,i?i+" "+p:p)):S(n,s))):g=o,{target:g,name:a,data:u});return h.data=Vt(e,r)||t.data,h.target=S(e,t.target),l&&(h.target="".concat(h.target," | ").concat(l)),h.name=S(e,t.name),h.properties=Gt(e,c),h.measurements=Ht(e,f),h}n(ii,ni=function(){this.ver=2,this.properties={},this.measurements={}}),ii.envelopeType="Microsoft.ApplicationInsights.{0}.Message",ii.dataType="MessageData";var ni,ti,ri=ii;function ii(e,n,t,r,i){var o=ni.call(this)||this;return o.aiDataContract={ver:1,message:1,severityLevel:0,properties:0},o.message=Wt(e,n=n||nr),o.properties=Gt(e,r),o.measurements=Ht(e,i),t&&(o.severityLevel=t),o}function oi(){var e=ti.call(this)||this;return e.ver=2,e.properties={},e.measurements={},e}n(oi,ti=r),n(ui,ai=oi),ui.envelopeType="Microsoft.ApplicationInsights.{0}.PageviewPerformance",ui.dataType="PageviewPerformanceData";var ai,si=ui;function ui(e,n,t,r,i,o,a){var s=ai.call(this)||this;return s.aiDataContract={ver:1,name:0,url:0,duration:0,perfTotal:0,networkConnect:0,sentRequest:0,receivedResponse:0,domProcessing:0,properties:0,measurements:0},s.url=Vt(e,t),s.name=S(e,n)||nr,s.properties=Gt(e,i),s.measurements=Ht(e,o),a&&(s.domProcessing=a.domProcessing,s.duration=a.duration,s.networkConnect=a.networkConnect,s.perfTotal=a.perfTotal,s.receivedResponse=a.receivedResponse,s.sentRequest=a.sentRequest),s}n(fi,li=e);var li,ci=fi;function fi(e,n){var t=li.call(this)||this;return t.aiDataContract={baseType:1,baseData:1},t.baseType=e,t.baseData=n,t}function di(e){var n="ai."+e+".";return function(e){return n+e}}N.SeverityLevel=void 0,(r=N.SeverityLevel||(N.SeverityLevel={}))[r.Verbose=0]="Verbose",r[r.Information=1]="Information",r[r.Warning=2]="Warning",r[r.Error=3]="Error",r[r.Critical=4]="Critical";var gi,pi,e=di("application"),r=di("device"),hi=di("location"),s=di("operation"),mi=di("session"),l=di("user"),c=di("cloud"),vi=di("internal"),yi=(pi={applicationVersion:e("ver"),applicationBuild:e("build"),applicationTypeId:e("typeId"),applicationId:e("applicationId"),applicationLayer:e("layer"),deviceId:r("id"),deviceIp:r("ip"),deviceLanguage:r("language"),deviceLocale:r("locale"),deviceModel:r("model"),deviceFriendlyName:r("friendlyName"),deviceNetwork:r("network"),deviceNetworkName:r("networkName"),deviceOEMName:r("oemName"),deviceOS:r("os"),deviceOSVersion:r("osVersion"),deviceRoleInstance:r("roleInstance"),deviceRoleName:r("roleName"),deviceScreenResolution:r("screenResolution"),deviceType:r("type"),deviceMachineName:r("machineName"),deviceVMName:r("vmName"),deviceBrowser:r("browser"),deviceBrowserVersion:r("browserVersion"),locationIp:hi("ip"),locationCountry:hi("country"),locationProvince:hi("province"),locationCity:hi("city"),operationId:s("id"),operationName:s("name"),operationParentId:s("parentId"),operationRootId:s("rootId"),operationSyntheticSource:s("syntheticSource"),operationCorrelationVector:s("correlationVector"),sessionId:mi("id"),sessionIsFirst:mi("isFirst"),sessionIsNew:mi("isNew"),userAccountAcquisitionDate:l("accountAcquisitionDate"),userAccountId:l("accountId"),userAgent:l("userAgent"),userId:l("id"),userStoreRegion:l("storeRegion"),userAuthUserId:l("authUserId"),userAnonymousUserAcquisitionDate:l("anonUserAcquisitionDate"),userAuthenticatedUserAcquisitionDate:l("authUserAcquisitionDate"),cloudName:c("name"),cloudRole:c("role"),cloudRoleVer:c("roleVer"),cloudRoleInstance:c("roleInstance"),cloudEnvironment:c("environment"),cloudLocation:c("location"),cloudDeploymentUnit:c("deploymentUnit"),internalNodeName:vi("nodeName"),internalSdkVersion:vi("sdkVersion"),internalAgentVersion:vi("agentVersion"),internalSnippet:vi("snippet"),internalSdkSrc:vi("sdkSrc")},n(Ii,gi=function(){var t=this;P(pi,function(e,n){t[e]=n})}),Ii);function Ii(){return gi.call(this)||this}var Ci,f=new yi,e=function $i(t,r){var i=[],o=!1;this._get=function(){return i},this._set=function(e){return i=e},h($i,this,function(n){n.enqueue=function(e){n.count()>=r.eventsLimitInMem()?o||(t.throwInternal(M.WARNING,k.InMemoryStorageBufferFull,"Maximum in-memory buffer size reached: "+n.count(),!0),o=!0):i.push(e)},n.count=function(){return i.length},n.size=function(){for(var e=i.length,n=0;n<i.length;n++)e+=i[n].length;return r.emitLineDelimitedJson()||(e+=2),e},n.clear=function(){o=!(i=[])},n.getItems=function(){return i.slice(0)},n.batchPayloads=function(e){return e&&0<e.length?r.emitLineDelimitedJson()?e.join("\n"):"["+e.join(",")+"]":null}})},Si=(n(xi,Ci=e),xi);function xi(e,n){e=Ci.call(this,e,n)||this;return h(xi,e,function(e,n){e.markAsSent=function(e){n.clear()},e.clearSent=function(e){}}),e}n(x,Ti=e),x.BUFFER_KEY="AI_buffer",x.SENT_BUFFER_KEY="AI_sentBuffer",x.MAX_BUFFER_SIZE=2e3;var Ti,wi=x;function x(s,u){var e=Ti.call(this,s,u)||this,l=!1;return h(x,e,function(t,n){var e=o(x.BUFFER_KEY),r=o(x.SENT_BUFFER_KEY),r=t._set(e.concat(r));function i(n,e){var t=[];return O(e,function(e){d(e)||-1!==qe(n,e)||t.push(e)}),t}function o(e){try{var e=u.namePrefix&&u.namePrefix()?u.namePrefix()+"_"+e:e,n=ar(s,e);if(n){var t=j().parse(n);if((t=m(t)?j().parse(t):t)&&U(t))return t}}catch(r){s.throwInternal(M.CRITICAL,k.FailedToRestoreStorageBuffer," storage key: "+e+", "+z(r),{exception:K(r)})}return[]}function a(e,n){try{var e=u.namePrefix&&u.namePrefix()?u.namePrefix()+"_"+e:e,t=JSON.stringify(n);sr(s,e,t)}catch(r){sr(s,e,JSON.stringify([])),s.throwInternal(M.WARNING,k.FailedToSetStorageBuffer," storage key: "+e+", "+z(r)+". Buffer cleared",{exception:K(r)})}}r.length>x.MAX_BUFFER_SIZE&&(r.length=x.MAX_BUFFER_SIZE),a(x.SENT_BUFFER_KEY,[]),a(x.BUFFER_KEY,r),t.enqueue=function(e){t.count()>=x.MAX_BUFFER_SIZE?l||(s.throwInternal(M.WARNING,k.SessionStorageBufferFull,"Maximum buffer size reached: "+t.count(),!0),l=!0):(n.enqueue(e),a(x.BUFFER_KEY,t._get()))},t.clear=function(){n.clear(),a(x.BUFFER_KEY,t._get()),a(x.SENT_BUFFER_KEY,[]),l=!1},t.markAsSent=function(e){a(x.BUFFER_KEY,t._set(i(e,t._get())));var n=o(x.SENT_BUFFER_KEY);n instanceof Array&&e instanceof Array&&((n=n.concat(e)).length>x.MAX_BUFFER_SIZE&&(s.throwInternal(M.CRITICAL,k.SessionStorageBufferFull,"Sent buffer reached its maximum size: "+n.length,!0),n.length=x.MAX_BUFFER_SIZE),a(x.SENT_BUFFER_KEY,n))},t.clearSent=function(e){e=i(e,o(x.SENT_BUFFER_KEY));a(x.SENT_BUFFER_KEY,e)}}),e}var bi="baseType",T="baseData",w="properties",Ni="true";function b(e,n,t){y(e,n,t,Ze)}function _i(e,t,r){D(e)||P(e,function(e,n){ze(n)?r[e]=n:m(n)?t[e]=n:Cn()&&(t[e]=j().stringify(n))})}function Ri(t,r){D(t)||P(t,function(e,n){t[e]=n||r})}function Ai(e,n,t,r){for(var r=new mr(e,r,n),n=(b(r,"sampleRate",t[Qt]),(t[T]||{}).startTime&&(r.time=Ke(t[T].startTime)),r.iKey=t.iKey,t.iKey.replace(/-/g,"")),n=(r.name=r.name.replace("{0}",n),e),e=t,i=r,o=i.tags=i.tags||{},a=e.ext=e.ext||{},s=e.tags=e.tags||[],u=a.user,u=(u&&(b(o,f.userAuthUserId,u.authId),b(o,f.userId,u.id||u.localId)),a.app),u=(u&&b(o,f.sessionId,u.sesId),a.device),u=(u&&(b(o,f.deviceId,u.id||u.localId),b(o,f.deviceType,u.deviceClass),b(o,f.deviceIp,u.ip),b(o,f.deviceModel,u.model),b(o,f.deviceType,u.deviceType)),e.ext.web),e=(u&&(b(o,f.deviceLanguage,u.browserLang),b(o,f.deviceBrowserVersion,u.browserVer),b(o,f.deviceBrowser,u.browser),b(e=(e=(e=i.data=i.data||{})[T]=e[T]||{})[w]=e[w]||{},"domain",u.domain),b(e,"isManual",u.isManual?Ni:null),b(e,"screenRes",u.screenRes),b(e,"userConsent",u.userConsent?Ni:null)),a.os),u=(e&&b(o,f.deviceOS,e.name),a.trace),l=(u&&(b(o,f.operationParentId,u.parentID),b(o,f.operationName,S(n,u.name)),b(o,f.operationId,u.traceID)),{}),c=s.length-1;0<=c;c--)P(s[c],function(e,n){l[e]=n}),s.splice(c,1);P(s,function(e,n){l[e]=n});e=Y(Y({},o),l);return e[f.internalSdkVersion]||(e[f.internalSdkVersion]="javascript:".concat(Ei.Version)),i.tags=$e(e),t.tags=t.tags||[],$e(r)}function Li(e,n){D(n[T])&&e.throwInternal(M.CRITICAL,k.TelemetryEnvelopeInvalid,"telemetryItem.baseData cannot be null.")}var Ei={Version:"2.7.5-nightly.2204-23"};function Fi(e,n,t){Li(e,n);var r={},i={},t=(n[bi]!==Ir.dataType&&(r.baseTypeSource=n[bi]),n[bi]===Ir.dataType?(r=n[T][w]||{},i=n[T].measurements||{}):n[T]&&_i(n[T],r,i),_i(n.data,r,i),D(t)||Ri(r,t),n[T].name),t=new Ir(e,t,r,i),r=new ci(Ir.dataType,t);return Ai(e,Ir.envelopeType,n,r)}var Mi=function eo(f){h(eo,this,function(e){function l(a,s){var e="__aiCircularRefCheck",u={};if(!a)return f.throwInternal(M.CRITICAL,k.CannotSerializeObject,"cannot serialize object because it is null or undefined",{name:s},!0),u;if(a[e])return f.throwInternal(M.WARNING,k.CircularReferenceDetected,"Circular reference detected while serializing object",{name:s},!0),u;if(a.aiDataContract)return a[e]=!0,P(a.aiDataContract,function(e,n){var t=d(n)?1&n():1&n,r=d(n)?4&n():4&n,n=2&n,i=a[e]!==undefined,o=Be(a[e])&&null!==a[e];!t||i||n?r||(t=o?(n?c:l)(a[e],e):a[e])!==undefined&&(u[e]=t):f.throwInternal(M.CRITICAL,k.MissingRequiredFieldSpecification,"Missing required field specification. The field is required but not present on source",{field:e,name:s})}),delete a[e],u;if("measurements"===s)u=t(a,"number",s);else if("properties"===s)u=t(a,"string",s);else if("tags"===s)u=t(a,"string",s);else if(U(a))u=c(a,s);else{f.throwInternal(M.WARNING,k.CannotSerializeObjectNonSerializable,"Attempting to serialize an object which does not implement ISerializable",{name:s},!0);try{j().stringify(a),u=a}catch(n){f.throwInternal(M.CRITICAL,k.CannotSerializeObject,n&&d(n.toString)?n.toString():"Error serializing object",null,!0)}}return u}function c(e,n){if(e)if(U(e))for(var t=[],r=0;r<e.length;r++){var i=l(e[r],n+"["+r+"]");t.push(i)}else f.throwInternal(M.CRITICAL,k.ItemNotInArray,"This field was specified as an array in the contract but the item is not an array.\r\n",{name:n},!0);return t}function t(e,t,r){var i;return e&&(i={},P(e,function(e,n){"string"===t?n===undefined?i[e]="undefined":null===n?i[e]="null":n.toString?i[e]=n.toString():i[e]="invalid field: toString() is not defined.":"number"===t?n===undefined?i[e]="undefined":i[e]=null===n?"null":isNaN(n=parseFloat(n))?"NaN":n:(i[e]="invalid field: "+r+" is of unknown type.",f.throwInternal(M.CRITICAL,i[e],null,!0))})),i}e.serialize=function(e){e=l(e,"root");try{return j().stringify(e)}catch(n){f.throwInternal(M.CRITICAL,k.CannotSerializeObject,n&&d(n.toString)?n.toString():"Error serializing object",null,!0)}}})};function ki(){var a=mn(),s=vn(),u=!1,l=!0;h(ki,this,function(e){try{var n,t;a&&Ue(a,"online",r)&&(Ue(a,"offline",i),u=!0),s&&!g((n=s.body||s).ononline)&&(n.ononline=r,n.onoffline=i,u=!0),u&&(t=In())&&!D(t.onLine)&&(l=t.onLine)}catch(o){u=!1}function r(){l=!0}function i(){l=!1}e.isListening=u,e.isOnline=function(){var e=!0,n=In();return u?e=l:n&&!D(n.onLine)&&(e=n.onLine),e},e.isOffline=function(){return!e.isOnline()}})}var Di=ki.Offline=new ki,Pi=(Bi.prototype.getHashCodeScore=function(e){return this.getHashCode(e)/Bi.INT_MAX_VALUE*100},Bi.prototype.getHashCode=function(e){if(""===e)return 0;for(;e.length<8;)e=e.concat(e);for(var n=5381,t=0;t<e.length;++t)n=(n<<5)+n+e.charCodeAt(t),n&=n;return Math.abs(n)},Bi.INT_MAX_VALUE=2147483647,Bi);function Bi(){}var Ui=function(){var n=new Pi,t=new yi;this.getSamplingScore=function(e){return e.tags&&e.tags[t.userId]?n.getHashCodeScore(e.tags[t.userId]):e.ext&&e.ext.user&&e.ext.user.id?n.getHashCodeScore(e.ext.user.id):e.tags&&e.tags[t.operationId]?n.getHashCodeScore(e.tags[t.operationId]):e.ext&&e.ext.telemetryTrace&&e.ext.telemetryTrace.traceID?n.getHashCodeScore(e.ext.telemetryTrace.traceID):100*Math.random()}},Oi=(zi.prototype.isSampledIn=function(e){var n=this.sampleRate;return null===n||n===undefined||100<=n||e.baseType===Wr.dataType||this.samplingScoreGenerator.getSamplingScore(e)<n},zi);function zi(e,n){this.INT_MAX_VALUE=2147483647;n=n||kn(null);(100<e||e<0)&&(n.throwInternal(M.WARNING,k.SampleRateOutOfRange,"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 Ui}function ji(e){try{return e.responseText}catch(n){}return null}function Ki(){return{endpointUrl:function(){return"https://dc.services.visualstudio.com/v2/track"},emitLineDelimitedJson:function(){return!1},maxBatchInterval:function(){return 15e3},maxBatchSizeInBytes:function(){return 102400},disableTelemetry:function(){return!1},enableSessionStorageBuffer:function(){return!0},isRetryDisabled:function(){return!1},isBeaconApiDisabled:function(){return!0},disableXhr:function(){return!1},onunloadDisableFetch:function(){return!1},onunloadDisableBeacon:function(){return!1},instrumentationKey:function(){return undefined},namePrefix:function(){return undefined},samplingPercentage:function(){return 100},customHeaders:function(){return undefined},convertUndefined:function(){return undefined},eventsLimitInMem:function(){return 1e4}}}(r={})[Ir.dataType]=Fi,r[ri.dataType]=function(e,n,t){Li(e,n);var r=n[T].message,i=n[T].severityLevel,o=n[T][w]||{},a=n[T].measurements||{},t=(_i(n.data,o,a),D(t)||Ri(o,t),new ri(e,r,i,o,a)),r=new ci(ri.dataType,t);return Ai(e,ri.envelopeType,n,r)},r[Jr.dataType]=function(e,n,t){Li(e,n);var r,i="duration",o=n[T],i=(D(o)||D(o[w])||D(o[w][i])?D(n.data)||D(n.data[i])||(r=n.data[i],delete n.data[i]):(r=o[w][i],delete o[w][i]),n[T]),o=(((n.ext||{}).trace||{}).traceID&&(a=n.ext.trace.traceID),i.id||a),a=i.name,s=i.uri,u=i[w]||{},l=i.measurements||{},i=(D(i.refUri)||(u.refUri=i.refUri),D(i.pageType)||(u.pageType=i.pageType),D(i.isLoggedIn)||(u.isLoggedIn=i.isLoggedIn.toString()),D(i[w])||P(i[w],function(e,n){u[e]=n}),_i(n.data,u,l),D(t)||Ri(u,t),new Jr(e,a,s,r,u,l,o)),t=new ci(Jr.dataType,i);return Ai(e,Jr.envelopeType,n,t)},r[si.dataType]=function(e,n,t){Li(e,n);var r=n[T],i=r.name,o=r.uri||r.url,a=r[w]||{},s=r.measurements||{},t=(_i(n.data,a,s),D(t)||Ri(a,t),new si(e,i,o,undefined,a,s,r)),i=new ci(si.dataType,t);return Ai(e,si.envelopeType,n,i)},r[kr.dataType]=function(e,n,t){Li(e,n);var r=n[T].measurements||{},i=n[T][w]||{},t=(_i(n.data,i,r),D(t)||Ri(i,t),n[T]),t=kr.CreateFromInterface(e,t,i,r),i=new ci(kr.dataType,t);return Ai(e,kr.envelopeType,n,i)},r[Wr.dataType]=function(e,n,t){Li(e,n);var r=n[T],i=r[w]||{},o=r.measurements||{},t=(_i(n.data,i,o),D(t)||Ri(i,t),new Wr(e,r.name,r.average,r.sampleCount,r.min,r.max,r.stdDev,i,o)),r=new ci(Wr.dataType,t);return Ai(e,Wr.envelopeType,n,r)},r[$r.dataType]=function(e,n,t){Li(e,n);var r=n[T].measurements||{},i=n[T][w]||{},t=(_i(n.data,i,r),D(t)||Ri(i,t),n[T]);if(D(t))return e.warnToConsole("Invalid input for dependency data"),null;var o=t[w]&&t[w][er]?t[w][er]:"GET",o=new $r(e,t.id,t.target,t.name,t.duration,t.success,t.responseCode,o,t.type,t.correlationContext,i,r),t=new ci($r.dataType,o);return Ai(e,$r.envelopeType,n,t)};var qi,Vi=r,Wi=(n(Gi,qi=Ae),Gi.constructEnvelope=function(e,n,t,r){e=n===e.iKey||D(n)?e:Y(Y({},e),{iKey:n});return(Vi[e.baseType]||Fi)(t,e,r)},Gi);function Gi(){var T,w,t,b,N,_,R,A=qi.call(this)||this,L=(A.priority=1001,!(A.identifier="AppInsightsChannelPlugin")),E={},F=0;return A._senderConfig=Ki(),h(Gi,A,function(l,a){function c(e,n,t,r,i,o){var a=null;l._appId||(a=p(o))&&a.appId&&(l._appId=a.appId),(e<200||300<=e)&&0!==e?(301!==e&&307!==e&&308!==e||s(t))&&!l._senderConfig.isRetryDisabled()&&y(e)?(h(n),l.diagLog().throwInternal(M.WARNING,k.TransmissionFailed,". Response code "+e+". Will retry to send "+n.length+" items.")):l._onError(n,i):Di.isOffline()?l._senderConfig.isRetryDisabled()||(h(n,10),l.diagLog().throwInternal(M.WARNING,k.TransmissionFailed,". Offline - Response Code: ".concat(e,". Offline status: ").concat(Di.isOffline(),". Will retry to send ").concat(n.length," items."))):(s(t),206===e?(a=a||p(o))&&!l._senderConfig.isRetryDisabled()?l._onPartialSuccess(n,a):l._onError(n,i):(T=0,l._onSuccess(n,r)))}function s(e){return!(10<=N)&&!D(e)&&""!==e&&e!==l._senderConfig.endpointUrl()&&(l._senderConfig.endpointUrl=function(){return e},++N,1)}function n(e,n){R?R(e,!1):u(e)}function o(e){var n=In(),t=l._buffer,r=l._senderConfig.endpointUrl(),i=l._buffer.batchPayloads(e),i=new Blob([i],{type:"text/plain;charset=UTF-8"}),r=n.sendBeacon(r,i);return r&&(t.markAsSent(e),l._onSuccess(e,e.length)),r}function u(e,n){if(U(e)&&0<e.length&&!o(e)){for(var t=[],r=0;r<e.length;r++){var i=e[r];o([i])||t.push(i)}0<t.length&&(_(t,!0),l.diagLog().throwInternal(M.WARNING,k.TransmissionFailed,". Failed to send telemetry with Beacon API, retried with normal sender."))}}function f(n,e){var t=new XMLHttpRequest,r=l._senderConfig.endpointUrl();try{t[Zt]=!0}catch(i){}t.open("POST",r,e),t.setRequestHeader("Content-type","application/json"),dr(r)&&t.setRequestHeader("Sdk-Context","appId"),O(He(E),function(e){t.setRequestHeader(e,E[e])}),t.onreadystatechange=function(){return l._xhrReadyStateChange(t,n,n.length)},t.onerror=function(e){return l._onError(n,I(t),e)};e=l._buffer.batchPayloads(n);t.send(e),l._buffer.markAsSent(n)}function d(e,n){if(U(e)){for(var t=e.length,r=0;r<e.length;r++)t+=e[r].length;F+t<=65e3?i(e,!1):xn()?u(e):(_&&_(e,!0),l.diagLog().throwInternal(M.WARNING,k.TransmissionFailed,". Failed to send telemetry with Beacon API, retried with xhrSender."))}}function g(e,n){i(e,!0)}function i(t,r){var e=l._senderConfig.endpointUrl(),n=l._buffer.batchPayloads(t),i=new Blob([n],{type:"application/json"}),o=new Headers,a=n.length,n=!1,s=!1,e=(dr(e)&&o.append("Sdk-Context","appId"),O(He(E),function(e){o.append(e,E[e])}),(i={method:"POST",headers:o,body:i})[Zt]=!0,r||(n=i.keepalive=!0,F+=a),new Request(e,i));try{e[Zt]=!0}catch(u){}l._buffer.markAsSent(t);try{fetch(e).then(function(n){r||(F-=a,a=0),s||(s=!0,n.ok?n.text().then(function(e){c(n.status,t,n.url,t.length,n.statusText,e)}):l._onError(t,n.statusText))})["catch"](function(e){r||(F-=a,a=0),s||(s=!0,l._onError(t,e.message))})}catch(u){s||l._onError(t,K(u))}n&&!s&&(s=!0,l._onSuccess(t,t.length))}function p(e){try{if(e&&""!==e){var n=j().parse(e);if(n&&n.itemsReceived&&n.itemsReceived>=n.itemsAccepted&&n.itemsReceived-n.itemsAccepted===n.errors.length)return n}}catch(t){l.diagLog().throwInternal(M.CRITICAL,k.InvalidBackendResponse,"Cannot parse the response. "+z(t),{response:e})}return null}function h(e,n){if(void 0===n&&(n=1),e&&0!==e.length){var t=l._buffer;t.clearSent(e),T++;for(var r=0,i=e;r<i.length;r++){var o=i[r];t.enqueue(o)}n=T<=1?10:(e=1+Math.floor((Math.pow(2,T)-1)/2*Math.random()*10),Math.max(Math.min(e*=n,3600),10)),e=Ye()+1e3*n;w=e,m()}}function m(){var e;t||L||(e=w?Math.max(0,w-Ye()):0,e=Math.max(l._senderConfig.maxBatchInterval(),e),t=setTimeout(function(){t=null,l.triggerSend(!0,null,1)},e))}function v(){clearTimeout(t),w=t=null}function y(e){return 408===e||429===e||500===e||503===e}function I(e,n){return e?"XMLHttpRequest,Status:"+e.status+",Response:"+ji(e)||e.response||"":n}function C(n,e){var t=l._buffer,r=mn(),i=new XDomainRequest,r=(i.onload=function(){return l._xdrOnLoad(i,n)},i.onerror=function(e){return l._onError(n,S(i),e)},r&&r.location&&r.location.protocol||"");if(l._senderConfig.endpointUrl().lastIndexOf(r,0))return l.diagLog().throwInternal(M.WARNING,k.TransmissionFailed,". Cannot send XDomain request. The endpoint URL protocol doesn't match the hosting page protocol."),void t.clear();r=l._senderConfig.endpointUrl().replace(/^(https?:)/,""),i.open("POST",r),r=t.batchPayloads(n);i.send(r),t.markAsSent(n)}function S(e,n){return e?"XDomainRequest,Response:"+ji(e)||"":n}function x(e,n){var t="getNotifyMgr",t=l.core[t]?l.core[t]():l.core._notificationManager;if(t&&t.eventsSendRequest)try{t.eventsSendRequest(e,n)}catch(r){l.diagLog().throwInternal(M.CRITICAL,k.NotificationException,"send request notification failed: "+z(r),{exception:K(r)})}}l.pause=function(){v(),L=!0},l.resume=function(){L&&(L=!1,w=null,l._buffer.size()>l._senderConfig.maxBatchSizeInBytes()&&l.triggerSend(!0,null,10),m())},l.flush=function(){if(!L){v();try{l.triggerSend(!0,null,1)}catch(e){l.diagLog().throwInternal(M.CRITICAL,k.FlushFailed,"flush failed, telemetry will not be collected: "+z(e),{exception:K(e)})}}},l.onunloadFlush=function(){if(!L)if(!1!==l._senderConfig.onunloadDisableBeacon()&&!1!==l._senderConfig.isBeaconApiDisabled()||!xn())l.flush();else try{l.triggerSend(!0,n,2)}catch(e){l.diagLog().throwInternal(M.CRITICAL,k.FailedToSendQueuedTelemetry,"failed to flush with beacon sender on page unload, telemetry will not be collected: "+z(e),{exception:K(e)})}},l.teardown=function(){Qe("Method not implemented.")},l.addHeader=function(e,n){E[e]=n},l.initialize=function(e,n,t,r){a.initialize(e,n,t,r);var i=l._getTelCtx(),o=l.identifier,t=(b=new Mi(n.logger),w=null,T=0,l._sender=null,N=0,l.diagLog()),r=(P(Ki(),function(e,n){l._senderConfig[e]=function(){return i.getConfig(o,e,n())}}),l._buffer=new(l._senderConfig.enableSessionStorageBuffer()&&or()?wi:Si)(t,l._senderConfig),l._sample=new Oi(l._senderConfig.samplingPercentage(),t),!D(e.disableInstrumentationKeyValidation)&&e.disableInstrumentationKeyValidation||/^[0-9a-f]{8}-[0-9a-f]{4}-[0-9a-f]{4}-[0-9a-f]{4}-[0-9a-f]{12}$/.test(e.instrumentationKey)||t.throwInternal(M.CRITICAL,k.InvalidInstrumentationKey,"Invalid Instrumentation key "+e.instrumentationKey),!dr(l._senderConfig.endpointUrl())&&l._senderConfig.customHeaders()&&0<l._senderConfig.customHeaders().length&&O(l._senderConfig.customHeaders(),function(e){A.addHeader(e.header,e.value)}),l._senderConfig),n=null;!r.disableXhr()&&wn()?n=C:!r.disableXhr()&&bn()&&(n=f),!n&&Tn()&&(n=g),_=n||f,!r.isBeaconApiDisabled()&&xn()&&(n=u),l._sender=n||f,R=!r.onunloadDisableFetch()&&Tn(!0)?d:xn()?u:!r.disableXhr()&&wn()?C:!r.disableXhr()&&bn()?f:_},l.processTelemetry=function(e,t){t=l._getTelCtx(t);try{if(l._senderConfig.disableTelemetry())return;if(!e)return void t.diagLog().throwInternal(M.CRITICAL,k.CannotSendEmptyTelemetry,"Cannot send empty telemetry");if(e.baseData&&!e.baseType)return void t.diagLog().throwInternal(M.CRITICAL,k.InvalidEvent,"Cannot send telemetry without baseData and baseType");if(e.baseType||(e.baseType="EventData"),!l._sender)return void t.diagLog().throwInternal(M.CRITICAL,k.SenderNotInitialized,"Sender was not initialized");if(!l._sample.isSampledIn(e))return void t.diagLog().throwInternal(M.WARNING,k.TelemetrySampledAndNotSent,"Telemetry item was sampled out and not sent",{SampleRate:l._sample.sampleRate});e[Qt]=l._sample.sampleRate;var n=l._senderConfig.convertUndefined()||undefined,r=e.iKey||l._senderConfig.instrumentationKey(),i=Gi.constructEnvelope(e,r,t.diagLog(),n);if(!i)return void t.diagLog().throwInternal(M.CRITICAL,k.CreateEnvelopeError,"Unable to create an AppInsights envelope");var o=!1;if(e.tags&&e.tags[$t]&&(O(e.tags[$t],function(e){try{e&&!1===e(i)&&(o=!0,t.diagLog().warnToConsole("Telemetry processor check returns false"))}catch(n){t.diagLog().throwInternal(M.CRITICAL,k.TelemetryInitializerFailed,"One of telemetry initializers failed, telemetry item will not be sent: "+z(n),{exception:K(n)},!0)}}),delete e.tags[$t]),o)return;var a=b.serialize(i),s=l._buffer;s.size()+a.length>l._senderConfig.maxBatchSizeInBytes()&&l.triggerSend(!0,null,10),s.enqueue(a),m()}catch(u){t.diagLog().throwInternal(M.WARNING,k.FailedAddingTelemetryToBuffer,"Failed adding telemetry to the sender's buffer, some telemetry will be lost: "+z(u),{exception:K(u)})}l.processNext(e,t)},l._xhrReadyStateChange=function(e,n,t){4===e.readyState&&c(e.status,n,e.responseURL,t,I(e),ji(e)||e.response)},l.triggerSend=function(e,n,t){if(void 0===e&&(e=!0),!L)try{var r,i=l._buffer;l._senderConfig.disableTelemetry()?i.clear():0<i.count()&&(r=i.getItems(),x(t||0,e),n?n.call(A,r,e):l._sender(r,e)),v()}catch(o){i=function(e){var n=((e=(e=void 0===e?null:e)?e:(n=In()||{})?(n.userAgent||"").toLowerCase():"")||"").toLowerCase();if(B(n,un))return e=vn()||{},Math.max(parseInt(n.split(un)[1]),e.documentMode||0);if(B(n,ln)){e=parseInt(n.split(ln)[1]);if(e)return e+4}return null}();(!i||9<i)&&l.diagLog().throwInternal(M.CRITICAL,k.TransmissionFailed,"Telemetry transmission failed, some telemetry will be lost: "+z(o),{exception:K(o)})}},l._onError=function(e,n,t){l.diagLog().throwInternal(M.WARNING,k.OnError,"Failed to send telemetry.",{message:n}),l._buffer.clearSent(e)},l._onPartialSuccess=function(e,n){for(var t=[],r=[],i=0,o=n.errors.reverse();i<o.length;i++){var a=o[i],s=e.splice(a.index,1)[0];(y(a.statusCode)?r:t).push(s)}0<e.length&&l._onSuccess(e,n.itemsAccepted),0<t.length&&l._onError(t,I(null,["partial success",n.itemsAccepted,"of",n.itemsReceived].join(" "))),0<r.length&&(h(r),l.diagLog().throwInternal(M.WARNING,k.TransmissionFailed,"Partial success. Delivered: "+e.length+", Failed: "+t.length+". Will retry to send "+r.length+" our of "+n.itemsReceived+" items"))},l._onSuccess=function(e,n){l._buffer.clearSent(e)},l._xdrOnLoad=function(e,n){var t=ji(e);!e||t+""!="200"&&""!==t?(t=p(t))&&t.itemsReceived&&t.itemsReceived>t.itemsAccepted&&!l._senderConfig.isRetryDisabled()?l._onPartialSuccess(n,t):l._onError(n,S(e)):(T=0,l._onSuccess(n,0))}}),A}Hi.prototype.initialize=function(){this.core=new _t;var e=[],n=new Wi;e.push(n),this.core.initialize(this.config,e),n.initialize(this.config,this.core,e),this.pollInternalLogs()},Hi.prototype.track=function(e){this.core.track(e)},Hi.prototype.flush=function(n){void 0===n&&(n=!0),O(this.core.getTransmissionControls(),function(e){O(e,function(e){n?e.flush():e.triggerSend(n,null,1)})})},Hi.prototype.pollInternalLogs=function(){this.core.pollInternalLogs()},Hi.prototype.stopPollingInternalLogs=function(){this.core.stopPollingInternalLogs()},Hi.prototype.getSKUDefaults=function(){this.config.diagnosticLogInterval=this.config.diagnosticLogInterval&&0<this.config.diagnosticLogInterval?this.config.diagnosticLogInterval:1e4};hi=Hi;function Hi(e){(D(e)||D(e.instrumentationKey))&&Qe("Invalid input configuration"),this.config=e,this.getSKUDefaults(),this.initialize()}N.AppInsightsCore=_t,N.ApplicationInsights=hi,N.CoreUtils=jt,N.Sender=Wi;s=N,mi="__esModule",l={value:!0},c=Object.defineProperty;if(c)try{return void c(s,mi,l)}catch(no){}typeof l.value!==undefined&&(s[mi]=l.value)};"object"==typeof exports&&"undefined"!=typeof module?n(exports):"function"==typeof define&&define.amd?define(["exports"],n):n(((e="undefined"!=typeof globalThis?globalThis:e||self).Microsoft=e.Microsoft||{},e.Microsoft.ApplicationInsights=e.Microsoft.ApplicationInsights||{}));
6
6
  //# sourceMappingURL=aib.2.min.js.map