@microsoft/applicationinsights-properties-js 2.7.5-nightly.2203-01 → 2.8.0-beta.2203-01

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 SDK - Properties Plugin, 2.7.5-nightly.2203-01
2
+ * Application Insights JavaScript SDK - Properties Plugin, 2.8.0-beta.2203-01
3
3
  * Copyright (c) Microsoft and contributors. All rights reserved.
4
4
  */
5
- var e=this,n=function(e){"use strict";var F="function",a="object",r="undefined",o="prototype",_="hasOwnProperty",t=Object,O=t[o],B=t.create,n=t.defineProperty,V=O[_],i=null;function j(e){return void 0===e&&(e=!0),i&&e||(typeof globalThis!==r&&globalThis&&(i=globalThis),typeof self!==r&&self&&(i=self),typeof window!==r&&window&&(i=window),typeof global!==r&&global&&(i=global)),i}function W(e){throw new TypeError(e)}(j()||{}).Symbol,(j()||{}).Reflect;var q=function(e,n){return(q=t.setPrototypeOf||{__proto__:[]}instanceof Array&&function(e,n){e.__proto__=n}||function(e,n){for(var t in n)n[_](t)&&(e[t]=n[t])})(e,n)};function G(e,n){function t(){this.constructor=e}typeof n!==F&&null!==n&&W("Class extends value "+n+" is not a constructor or null"),q(e,n),e[o]=null===n?function(e){if(B)return B(e);if(null==e)return{};var n=typeof e;function t(){}return n!==a&&n!==F&&W("Object prototype may only be an Object:"+e),t[o]=e,new t}(n):(t[o]=n[o],new t)}var K="constructor",p="prototype",z="function",H="_dynInstFuncs",J="_isDynProxy",v="_dynClass",Z="_dynInstChk",X=Z,Y="_dfOpts",$="_unknown_",Q="__proto__",ee="useBaseInst",ne="setInstFuncs",te=Object,oe=te.getPrototypeOf,re=0;function h(e,n){return e&&te[p].hasOwnProperty.call(e,n)}function ie(e){return e&&(e===te[p]||e===Array[p])}function ae(e){return ie(e)||e===Function[p]}function m(e){if(e){if(oe)return oe(e);e=e[Q]||e[p]||(e[K]?e[K][p]:null);if(e)return e}return null}function se(e,n){var t=[],o=te.getOwnPropertyNames;if(o)t=o(e);else for(var r in e)"string"==typeof r&&h(e,r)&&t.push(r);if(t&&0<t.length)for(var i=0;i<t.length;i++)n(t[i])}function ue(e,n,t){return n!==K&&typeof e[n]===z&&(t||h(e,n))}function le(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 fe(e,n){return h(e,p)?e.name||n||$:((e||{})[K]||{}).name||n||$}function C(e,o,n,t){h(e,p)||le("theClass is an invalid class definition.");var r,i,a,s,u,l,c=e[p],f=(function(e){if(oe)for(var n=[],t=m(o);t&&!ae(t)&&!ce(n,t);){if(t===e)return 1;n.push(t),t=m(t)}}(c)||le("["+fe(e)+"] is not in class hierarchy of ["+fe(o)+"]"),null),e=(h(c,v)?f=c[v]:(f="_dynCls$"+fe(e,"_")+"$"+re,re++,c[v]=f),C[Y]),d=!!e[ee],g=(d&&t&&t[ee]!==undefined&&(d=!!t[ee]),i={},se(r=o,function(e){!i[e]&&ue(r,e,!1)&&(i[e]=r[e])}),i),d=(n(o,function(e,n,t,i){function o(e,n,t){var o,r=n[t];return r[J]&&i&&!1!==(o=e[H]||{})[X]&&(r=(o[n[v]]||{})[t]||r),function(){return r.apply(e,arguments)}}for(var r={},a=(se(t,function(e){r[e]=o(n,t,e)}),m(e)),s=[];a&&!ae(a)&&!ce(s,a);)se(a,function(e){!r[e]&&ue(a,e,!oe)&&(r[e]=o(n,a,e))}),s.push(a),a=m(a);return r}(c,o,g,d)),!!oe&&!!e[ne]);a=c,n=f,s=o,u=g,e=!1!==(d=d&&t?!!t[ne]:d),ie(a)||(c=s[H]=s[H]||{},l=c[n]=c[n]||{},!1!==c[X]&&(c[X]=!!e),se(s,function(e){var t,o,r;ue(s,e,!1)&&s[e]!==u[e]&&(l[e]=s[e],delete s[e],h(a,e)&&(!a[e]||a[e][J])||(a[e]=(t=a,o=e,(r=function(){var e,n;return(function(e,n,t,o){var r=null;if(e&&h(t,v)){var i=e[H]||{};if((r=(i[t[v]]||{})[n])||le("Missing ["+n+"] "+z),!r[Z]&&!1!==i[X]){for(var a=!h(e,n),s=m(e),u=[];a&&s&&!ae(s)&&!ce(u,s);){var l=s[n];if(l){a=l===o;break}u.push(s),s=m(s)}try{a&&(e[n]=r),r[Z]=1}catch(c){i[X]=!1}}}return r}(this,o,t,r)||(typeof(n=(n=t[e=o])===r?m(t)[e]:n)!==z&&le("["+e+"] is not a "+z),n)).apply(this,arguments)})[J]=1,r)))}))}C[Y]={setInstFuncs:!0,useBaseInst:!0},(s=I=I||{})[s.CRITICAL=1]="CRITICAL",s[s.WARNING=2]="WARNING";var I,y={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},de="toISOString",ge="endsWith",pe="trim",s="toString",ve=n,he=t.keys,n=String[o],me=n[pe],Ce=n[ge],Ie=Date[o][de],n=Array.isArray,ye=O[s];function g(e){return e===undefined||typeof e===r}function x(e){return null===e||g(e)}function xe(e){return!x(e)}function S(e){return!(!e||typeof e!==F)}function Se(e,n){if(e)for(var t in e)V.call(e,t)&&n.call(e,t,e[t])}function w(e,n){return!(!e||!n||!~e.indexOf(n))}V[s].call(t);var we=n||function(e){return!(!e||"[object Array]"!==ye.call(e))};function T(e){return"string"==typeof e}function Te(e,n,t){var o=e.length;try{for(var r=0;r<o&&!(r in e&&-1===n.call(t||e,e[r],r,e));r++);}catch(i){}}function N(e){return e&&(me&&e[pe]?e[pe]():e.replace?e.replace(/^\s+|\s+$/g,""):e)}var Ne=!{toString:null}.propertyIsEnumerable("toString"),Ae=["toString","toLocaleString","valueOf","hasOwnProperty","isPrototypeOf","propertyIsEnumerable","constructor"];function ke(){var e=Date;return e.now?e.now():(new e).getTime()}function be(e){return e&&"[object Error]"===ye.call(e)?e.name:""}function A(e,n,t,o,r){var i=t;!e||(i=e[n])===t||r&&!r(i)||o&&!o(t)||(e[n]=i=t)}function f(e,n,t){var o;return e?!(o=e[n])&&x(o)&&(o=g(t)?{}:t,e[n]=o):o=g(t)?{}:t,o}function Me(e){return!!e}var Pe="window",Le="navigator",Re="location",De="JSON",Ee="msie",Ue="trident/",Fe=null,_e=null,Oe=!1;function l(e){var n=j();return n&&n[e]?n[e]:e===Pe&&Be()?window:null}function Be(){return typeof window===a&&window}function Ve(){return typeof navigator===a&&navigator?navigator:l(Le)}function je(e){if(e&&Oe){e=l("__mockLocation");if(e)return e}return typeof location===a&&location?location:l(Re)}function We(){return typeof JSON===a&&JSON||null!==l(De)}function qe(){return We()?JSON||l(De):null}function Ge(){var e=Ve();return!e||e.userAgent===_e&&null!==Fe||(e=((_e=e.userAgent)||"").toLowerCase(),Fe=w(e,Ee)||w(e,Ue)),Fe}function Ke(e){var n=Object[o].toString.call(e),t="";return"[object Error]"===n?t="{ stack: '"+e.stack+"', message: '"+e.message+"', name: '"+e.name+"'":We()&&(t=qe().stringify(e)),n+t}var ze=null;function He(e){return e?'"'+e.replace(/\"/g,"")+'"':""}function Je(e,n){var t,o=typeof console!==r?console:l("console");o&&(t="log",S(o[t=o[e]?e:t])&&o[t](n))}Xe.dataType="MessageData";var Ze=Xe;function Xe(e,n,t,o){void 0===t&&(t=!1),this.messageId=e,this.message=(t?"AI: ":"AI (Internal): ")+e;t="",We()&&(t=qe().stringify(o)),e=(n?" message:"+He(n):"")+(o?" props:"+He(t):"");this.message+=e}function Ye(e,n){return(e||{}).logger||new $e(n)}var $e=function Tt(r){this.identifier="DiagnosticLogger",this.queue=[];var s=0,u={};C(Tt,this,function(i){function e(e,n){e=r[e];return x(e)?n:e}function a(e,n){var t,o=(t=(t=ze)||!0===r.disableDbgExt?t:ze||(o=l("Microsoft"),ze=o?o.ApplicationInsights:ze))?t.ChromeDbgExt:null;o&&o.diagLog&&o.diagLog(e,n)}x(r)&&(r={}),i.consoleLoggingLevel=function(){return e("loggingLevelConsole",0)},i.telemetryLoggingLevel=function(){return e("loggingLevelTelemetry",1)},i.maxInternalMessageLimit=function(){return e("maxMessageLimit",25)},i.enableDebugExceptions=function(){return e("enableDebugExceptions",!1)},i.throwInternal=function(e,n,t,o,r){n=new Ze(n,t,r=void 0!==r&&r,o);if(i.enableDebugExceptions())throw n;t=e===I.CRITICAL?"errorToConsole":"warnToConsole";g(n.message)?a("throw"+(e===I.CRITICAL?"Critical":"Warning"),n):(o=i.consoleLoggingLevel(),r?(r=+n.messageId,!u[r]&&e<=o&&(i[t](n.message),u[r]=!0)):e<=o&&i[t](n.message),i.logInternalMessage(e,n))},i.warnToConsole=function(e){Je("warn",e),a("warning",e)},i.errorToConsole=function(e){Je("error",e),a("error",e)},i.resetInternalMessageCount=function(){s=0,u={}},i.logInternalMessage=function(e,n){var t,o;s>=i.maxInternalMessageLimit()||(o=!0,t="AITR_"+n.messageId,u[t]?o=!1:u[t]=!0,o&&(e<=i.telemetryLoggingLevel()&&(i.queue.push(n),s++,a(e===I.CRITICAL?"error":"warn",n)),s===i.maxInternalMessageLimit()&&(o=new Ze(y.MessageLimitPerPVExceeded,t="Internal events throttle limit per PageView reached for this app.",!1),i.queue.push(o),e===I.CRITICAL?i.errorToConsole(t):i.warnToConsole(t))))}})},Qe=(u.ParentContextKey="parent",u.ChildrenContextKey="childEvts",u);function u(e,r,n){var o,i=this,a=!1;i.start=ke(),i.name=e,i.isAsync=n,i.isChildEvt=function(){return!1},S(r)&&(a=function(e){if(ve)try{var n={enumerable:!0,configurable:!0,get:function(){return!o&&S(r)&&(o=r(),r=null),o}};return ve(e,"payload",n),!0}catch(t){}return!1}(i)),i.getCtx=function(e){return e?(e===u.ParentContextKey||e===u.ChildrenContextKey?i:i.ctx||{})[e]:null},i.setCtx=function(e,n){e&&(e===u.ParentContextKey?(i[e]||(i.isChildEvt=function(){return!0}),i[e]=n):e===u.ChildrenContextKey?i[e]=n:(i.ctx=i.ctx||{})[e]=n)},i.complete=function(){var e=0,n=i.getCtx(u.ChildrenContextKey);if(we(n))for(var t=0;t<n.length;t++){var o=n[t];o&&(e+=o.time)}i.time=ke()-i.start,i.exTime=i.time-e,i.complete=function(){},!a&&S(r)&&(i.payload=r())}}var en="CoreUtils.doPerf";function nn(e,n,t,o,r){if(e)if(e=S(e.getPerfMgr)?e.getPerfMgr():e){var i,a=void 0,s=e.getCtx(en);try{if(a=e.create(n(),o,r))return s&&a.setCtx&&(a.setCtx(Qe.ParentContextKey,s),s.getCtx&&s.setCtx&&((i=s.getCtx(Qe.ChildrenContextKey))||(i=[],s.setCtx(Qe.ChildrenContextKey,i)),i.push(a))),e.setCtx(en,a),t(a)}catch(u){a&&a.setCtx&&a.setCtx("exception",u)}finally{a&&e.fire(a),e.setCtx(en,s)}}t()}var tn=function(r,n){var i=this,a=null,s=S(r.processTelemetry),u=S(r.setNextPlugin);i._hasRun=!1,i.getPlugin=function(){return r},i.getNext=function(){return a},i.setNext=function(e){a=e},i.processTelemetry=function(t,o){o=o||n;var e=r?r.identifier:"TelemetryPluginChain";nn(o?o.core():null,function(){return e+":processTelemetry"},function(){if(r&&s){i._hasRun=!0;try{o.setNext(a),u&&r.setNextPlugin(a),a&&(a._hasRun=!1),r.processTelemetry(t,o)}catch(n){var e=a&&a._hasRun;a&&e||o.diagLog().throwInternal(I.CRITICAL,y.PluginException,"Plugin ["+r.identifier+"] failed during processTelemetry - "+Ke(n)),a&&!e&&a.processTelemetry(t,o)}}else a&&(i._hasRun=!0,a.processTelemetry(t,o))},function(){return{item:t}},!t.sync)}};function on(e,n){var t=[];if(e&&0<e.length)for(var o=null,r=0;r<e.length;r++){var i=e[r];i&&S(i.processTelemetry)&&(i=new tn(i,n),t.push(i),o&&o.setNext(i),o=i)}return 0<t.length?t[0]:null}var rn=function Nt(e,r,t,n){var o,i,a,s,u=this,l=null;null!==n&&(e&&S(e.getPlugin)?l=function(e,n,t){var o=[],r=!t;if(e)for(;e;){var i=e.getPlugin();!r&&i!==t||(r=!0,o.push(i)),e=e.getNext()}return r||o.push(t),on(o,n)}(e,u,n||e.getPlugin()):n?(o=u,a=e,s=!1,(i=n)&&e&&(a=[],Te(e,function(e){!s&&e!==i||(s=!0,a.push(e))})),i&&!s&&(a=a||[]).push(i),l=on(a,o)):g(n)&&(l=on(e,u))),u.core=function(){return t},u.diagLog=function(){return Ye(t,r)},u.getCfg=function(){return r},u.getExtCfg=function(e,n){var t,o;return void 0===n&&(n={}),(t=r&&(o=r.extensionConfig)&&e?o[e]:t)||n},u.getConfig=function(e,n,t){void 0===t&&(t=!1);var o,e=u.getExtCfg(e,null);return e&&!x(e[n])?o=e[n]:r&&!x(r[n])&&(o=r[n]),x(o)?t:o},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 Nt((e=void 0===e?null:e)||l,r,t,n)}},an="getPlugin",O=(sn.prototype.initialize=function(e,n,t,o){this._baseTelInit(e,n,t,o)},sn);function sn(){var i=this,a=!1,s=null,u=null;i.core=null,i.diagLog=function(e){return i._getTelCtx(e).diagLog()},i.isInitialized=function(){return a},i.setInitialized=function(e){a=e},i.setNextPlugin=function(e){u=e},i.processNext=function(e,n){n?n.processNext(e):u&&S(u.processTelemetry)&&u.processTelemetry(e,null)},i._getTelCtx=function(e){var n,e=e=void 0===e?null:e;return e||(n=s||new rn(null,{},i.core),e=u&&u[an]?n.createNew(null,u[an]):n.createNew(null,u)),e},i._baseTelInit=function(e,n,t,o){e&&A(e,"extensionConfig",[],null,x),!o&&n&&(o=n.getProcessTelContext().getNext());var r=u;u&&u[an]&&(r=u[an]()),i.core=n,s=new rn(o,e,n,r),a=!0}}var un="toGMTString",ln="toUTCString",cn="cookie",fn="expires",dn="enabled",gn="isCookieUseDisabled",pn="disableCookiesUsage",k="_ckMgr",b="",vn=null,hn=null,mn=null,Cn=typeof document===a&&document?document:l("document"),In={},yn={};function xn(e){return!e||e.isEnabled()}function Sn(e,n){var t,o;return e?t=e.getCookieMgr():n&&(t=n.cookieCfg[k]||wn(n)),t||(e=(e||{}).logger,(o=wn[k]||yn[k])||(o=wn[k]=wn(n,e),yn[k]=o),t=o),t}function wn(e,r){A(t=(e=e||yn).cookieCfg=e.cookieCfg||{},"domain",e.cookieDomain,xe,x),A(t,"path",e.cookiePath||"/",null,x),x(t[dn])&&(n=void 0,g(e[gn])||(n=!e[gn]),g(e[pn])||(n=!e[pn]),t[dn]=n);var n,t,l=t,c=l.path||"/",f=l.domain,o=!1!==l[dn],d={isEnabled:function(){var e=o&&Tn(r),n=yn[k];return e&&n&&d!==n?xn(n):e},setEnabled:function(e){o=!1!==e},set:function(e,n,t,o,r){var i,a,s,u=!1;return xn(d)&&(i={},-1!=(s=(a=N(n||b)).indexOf(";"))&&(a=N(n.substring(0,s)),i=Nn(n.substring(1+s))),A(i,"domain",o||f,Me,g),x(t)||(s=Ge(),g(i[fn])&&0<(n=ke()+1e3*t)&&((o=new Date).setTime(n),A(i,fn,An(o,s?un:ln)||An(o,s?un:ln)||b,Me)),s||A(i,"max-age",b+t,null,g)),(n=je())&&"https:"===n.protocol&&(A(i,"secure",null,null,g),(hn=null===hn?!(T(o=(Ve()||{}).userAgent)&&(w(o,"CPU iPhone OS 12")||w(o,"iPad; CPU OS 12")||w(o,"Macintosh; Intel Mac OS X 10_14")&&w(o,"Version/")&&w(o,"Safari")||w(o,"Macintosh; Intel Mac OS X 10_14")&&function(e,n){var t=!1;if(!e||(t=e===n))return t;if(Ce)return e[ge](n);var o=e,r=n,t=!1,e=o?o.length:0;if(e&&40<=e&&!(t=o===r)){for(var i=e-1,a=39;0<=a;a--){if(o[i]!=r[a])return;i--}t=!0}return t}(o,"AppleWebKit/605.1.15 (KHTML, like Gecko)")||w(o,"Chrome/5")||w(o,"Chrome/6")||w(o,"UnrealEngine")&&!w(o,"Chrome")||w(o,"UCBrowser/12")||w(o,"UCBrowser/11"))):hn)&&A(i,"SameSite","None",null,g)),A(i,"path",r||c,null,g),(l.setCookie||bn)(e,kn(a,i)),u=!0),u},get:function(e){var n=b;return xn(d)?(l.getCookie||function(e){var n,t=b;return Cn&&(n=Cn[cn]||b,mn!==n&&(In=Nn(n),mn=n),t=N(In[e]||b)),t})(e):n},del:function(e,n){return!!xn(d)&&d.purge(e,n)},purge:function(e,n){var t,o=!1;return Tn(r)&&((t={}).path=n||"/",t[fn]="Thu, 01 Jan 1970 00:00:01 GMT",n=t,Ge()||(n["max-age"]="0"),(l.delCookie||bn)(e,kn(b,n)),o=!0),o}};return d[k]=d}function Tn(e){if(null===vn){vn=!1;try{vn=(Cn||{})[cn]!==undefined}catch(n){e&&e.throwInternal(I.WARNING,y.CannotAccessCookie,"Cannot access document.cookie - "+be(n),{exception:Ke(n)})}}return vn}function Nn(e){var t={};return e&&e.length&&Te(N(e).split(";"),function(e){var n;(e=N(e||b))&&(-1==(n=e.indexOf("="))?t[e]=null:t[N(e.substring(0,n))]=N(e.substring(1+n)))}),t}function An(e,n){return S(e[n])?e[n]():null}function kn(e,n){var t=e||b;return Se(n,function(e,n){t+="; "+e+(x(n)?b:"="+n)}),t}function bn(e,n){Cn&&(Cn[cn]=e+"="+n)}var Mn=4294967296,c=4294967295,Pn=!1,Ln=123456789,Rn=987654321;function Dn(e){var n=l("crypto")||l("msCrypto"),n=n&&n.getRandomValues?n.getRandomValues(new Uint32Array(1))[0]&c:Ge()?(Pn||function(){try{var e=2147483647&ke();(n=(Math.random()*Mn^e)+e)<0&&(n>>>=0),Ln=123456789+n&c,Rn=987654321-n&c,Pn=!0}catch(t){}var n}(),n=((Rn=36969*(65535&Rn)+(Rn>>16)&c)<<16)+(65535&(Ln=18e3*(65535&Ln)+(Ln>>16)&c))>>>0&c|0,(n>>>=0)&c):Math.floor(Mn*Math.random()|0);return e||(n>>>=0),n}function En(e){void 0===e&&(e=22);for(var n=Dn()>>>0,t=0,o="";o.length<e;)o+="ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789+/"[0|63&n]||"",n>>>=6,5==++t&&(n=(Dn()<<2&4294967295|3&n)>>>0,t=0);return o}function Un(e,n,t){var o,r,i=n.length,a=(e=e,(n=n)&&150<(n=N(n.toString())).length&&(r=n.substring(0,150),e&&e.throwInternal(I.WARNING,y.NameTooLong,"name is too long. It has been truncated to 150 characters.",{name:n},!0)),r||n);if(a.length!==i){for(var s=0,u=a;t[u]!==undefined;)s++,u=a.substring(0,147)+(o=void 0,(o="00"+s).substr(o.length-3));a=u}return a}function Fn(e,n,t){var o;return void 0===t&&(t=1024),n&&(t=t||1024,(n=N(n)).toString().length>t&&(o=n.toString().substring(0,t),e&&e.throwInternal(I.WARNING,y.StringValueTooLong,"string value is too long. It has been truncated to "+t+" characters.",{value:n},!0))),o||n}function _n(o,e){var r;return e&&(r={},Se(e,function(e,n){if(n&&typeof n===a&&We())try{n=qe().stringify(n)}catch(t){o&&o.throwInternal(I.WARNING,y.CannotSerializeObjectNonSerializable,"custom property is not valid",{exception:t},!0)}n=Fn(o,n,8192),e=Un(o,e,r),r[e]=n}),e=r),e}function On(e,n,t,o){var r;return n&&(n=N(n)).length>t&&(r=n.substring(0,t),e&&e.throwInternal(I.WARNING,o,"input is too long, it has been truncated to "+t+" characters.",{data:n},!0)),r||n}(s=Bn=Bn||{})[s.LocalStorage=0]="LocalStorage",s[s.SessionStorage=1]="SessionStorage";var Bn,Vn,jn=undefined;function Wn(){return Gn()?qn(Bn.LocalStorage):null}function qn(e){try{if(x(j()))return null;var n=new Date,t=l(e===Bn.LocalStorage?"localStorage":"sessionStorage"),o=(t.setItem(n.toString(),n.toString()),t.getItem(n.toString())!==n.toString());if(t.removeItem(n.toString()),!o)return t}catch(r){}return null}function Gn(){return jn=jn===undefined?!!qn(Bn.LocalStorage):jn}function Kn(e,n){var t=Wn();if(null!==t)try{return t.getItem(n)}catch(o){jn=!1,e.throwInternal(I.WARNING,y.BrowserCannotReadLocalStorage,"Browser failed read of local storage. "+be(o),{exception:Ke(o)})}return null}function zn(e,n,t){var o=Wn();if(null!==o)try{o.setItem(n,t)}catch(r){jn=!1,e.throwInternal(I.WARNING,y.BrowserCannotWriteLocalStorage,"Browser failed write to local storage. "+be(r),{exception:Ke(r)})}}function Hn(e,n){var t=Wn();if(null!==t)try{t.removeItem(n)}catch(o){jn=!1,e.throwInternal(I.WARNING,y.BrowserFailedRemovalFromLocalStorage,"Browser failed removal of local storage item. "+be(o),{exception:Ke(o)})}}function Jn(){var e=Vn.call(this)||this;return e.ver=2,e.properties={},e.measurements={},e}G(Jn,Vn=function(){this.ver=2,this.properties={},this.measurements={}}),G(Yn,Zn=Jn),Yn.envelopeType="Microsoft.ApplicationInsights.{0}.Pageview",Yn.dataType="PageviewData";var Zn,Xn=Yn;function Yn(e,n,t,o,r,i,a){var s,u,l,c=Zn.call(this)||this;return c.aiDataContract={ver:1,name:0,url:0,duration:0,properties:0,measurements:0,id:0},c.id=a&&On(e,a,128,y.IdTooLong).toString(),c.url=On(e,t,2048,y.UrlTooLong),c.name=Fn(e,n)||"not_specified",isNaN(o)||(c.duration=(t=""+Math.floor((a=Math.round(a=isNaN(a=o)||a<0?0:a))/1e3)%60,n=1===(n=""+a%1e3).length?"00"+n:2===n.length?"0"+n:n,t=t.length<2?"0"+t:t,o=(o=""+Math.floor(a/6e4)%60).length<2?"0"+o:o,(0<(s=Math.floor(a/864e5))?s+".":"")+(s=(s=""+Math.floor(a/36e5)%24).length<2?"0"+s:s)+":"+o+":"+t+"."+n)),c.properties=_n(e,r),c.measurements=(u=e,(a=i)&&(l={},Se(a,function(e,n){e=Un(u,e,l),l[e]=n}),a=l),a),c}function d(e){var n="ai."+e+".";return function(e){return n+e}}var $n,Qn,n=d("application"),s=d("device"),M=d("location"),P=d("operation"),et=d("session"),L=d("user"),R=d("cloud"),nt=d("internal");function tt(){return $n.call(this)||this}Qn={applicationVersion:n("ver"),applicationBuild:n("build"),applicationTypeId:n("typeId"),applicationId:n("applicationId"),applicationLayer:n("layer"),deviceId:s("id"),deviceIp:s("ip"),deviceLanguage:s("language"),deviceLocale:s("locale"),deviceModel:s("model"),deviceFriendlyName:s("friendlyName"),deviceNetwork:s("network"),deviceNetworkName:s("networkName"),deviceOEMName:s("oemName"),deviceOS:s("os"),deviceOSVersion:s("osVersion"),deviceRoleInstance:s("roleInstance"),deviceRoleName:s("roleName"),deviceScreenResolution:s("screenResolution"),deviceType:s("type"),deviceMachineName:s("machineName"),deviceVMName:s("vmName"),deviceBrowser:s("browser"),deviceBrowserVersion:s("browserVersion"),locationIp:M("ip"),locationCountry:M("country"),locationProvince:M("province"),locationCity:M("city"),operationId:P("id"),operationName:P("name"),operationParentId:P("parentId"),operationRootId:P("rootId"),operationSyntheticSource:P("syntheticSource"),operationCorrelationVector:P("correlationVector"),sessionId:et("id"),sessionIsFirst:et("isFirst"),sessionIsNew:et("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:R("name"),cloudRole:R("role"),cloudRoleVer:R("roleVer"),cloudRoleInstance:R("roleInstance"),cloudEnvironment:R("environment"),cloudLocation:R("location"),cloudDeploymentUnit:R("deploymentUnit"),internalNodeName:nt("nodeName"),internalSdkVersion:nt("sdkVersion"),internalAgentVersion:nt("agentVersion"),internalSnippet:nt("snippet"),internalSdkSrc:nt("sdkSrc")},G(tt,$n=function(){var t=this;Se(Qn,function(e,n){t[e]=n})});var ot="user",rt="device",it="trace",at="web",st="app",ut="os",D=new tt,lt=function(){},ct=(E.acquisitionSpan=864e5,E.renewalSpan=18e5,E.cookieUpdateInterval=6e4,E);function E(n,e){var c,f,d=Ye(e),g=Sn(e);C(E,this,function(s){S((n=n||{}).sessionExpirationMs)||(n.sessionExpirationMs=function(){return E.acquisitionSpan}),S(n.sessionRenewalMs)||(n.sessionRenewalMs=function(){return E.renewalSpan}),s.config=n;var e=s.config.sessionCookiePostfix&&s.config.sessionCookiePostfix()?s.config.sessionCookiePostfix():s.config.namePrefix&&s.config.namePrefix()?s.config.namePrefix():"";function u(e,n){var t=!1,o=", session will be reset",r=n.split("|");if(2<=r.length)try{var i=+r[1]||0,a=+r[2]||0;isNaN(i)||i<=0?d.throwInternal(I.WARNING,y.SessionRenewalDateIsZero,"AI session acquisition date is 0"+o):isNaN(a)||a<=0?d.throwInternal(I.WARNING,y.SessionRenewalDateIsZero,"AI session renewal date is 0"+o):r[0]&&(e.id=r[0],e.acquisitionDate=i,e.renewalDate=a,t=!0)}catch(s){d.throwInternal(I.CRITICAL,y.ErrorParsingAISessionCookie,"Error parsing ai_session value ["+(n||"")+"]"+o+" - "+be(s),{exception:Ke(s)})}return t}function l(e,n){var t=e.acquisitionDate,o=(e.renewalDate=n,s.config),r=o.sessionRenewalMs(),i=t+o.sessionExpirationMs()-n,e=[e.id,t,n],t=i<r?i/1e3:r/1e3,i=o.cookieDomain?o.cookieDomain():null;g.set(c(),e.join("|"),0<o.sessionExpirationMs()?t:null,i),f=n}c=function(){return"ai_session"+e},s.automaticSession=new lt,s.update=function(){var e,n,t,o=ke(),r=!1,i=s.automaticSession,a=(i.id||(n=i,t=!1,(a=g.get(c()))&&S(a.split)?t=u(n,a):(a=Kn(d,c()))&&(t=u(n,a)),r=!(t||n.id)),s.config.sessionExpirationMs());!r&&0<a&&(t=s.config.sessionRenewalMs(),n=o-i.acquisitionDate,e=o-i.renewalDate,r=(r=(r=n<0||e<0)||a<n)||t<e),r?(a=o,t=((n=s.config||{}).getNewId?n.getNewId():null)||En,s.automaticSession.id=t(n.idLength?n.idLength():22),s.automaticSession.acquisitionDate=a,l(s.automaticSession,a),Gn()||d.throwInternal(I.WARNING,y.BrowserDoesNotSupportLocalStorage,"Browser does not support local storage. Session durations will be inaccurate.")):(!f||E.cookieUpdateInterval<o-f)&&l(i,o)},s.backup=function(){var e=s.automaticSession,n=e.id,t=e.acquisitionDate,e=e.renewalDate;zn(d,c(),[n,t,e].join("|"))}})}var ft=function(){},dt=function(){this.id="browser",this.deviceClass="Browser"},gt=function(e){this.sdkVersion=(e.sdkExtension&&e.sdkExtension()?e.sdkExtension()+"_":"")+"javascript:2.7.5-nightly.2203-01"};function pt(e){return"string"==typeof e&&e&&!e.match(/,|;|=| |\|/)}U.cookieSeparator="|",U.userCookieName="ai_user",U.authUserCookieName="ai_authUser";var vt=U;function U(a,e){this.isNewUser=!1,this.isUserCookieSet=!1;var s,u=Ye(e),l=Sn(e);C(U,this,function(o){o.config=a;var e=o.config.userCookiePostfix&&o.config.userCookiePostfix()?o.config.userCookiePostfix():"",n=(s=function(){return U.userCookieName+e},l.get(s()));function t(){var e=a||{};return((e.getNewId?e.getNewId():null)||En)(e.idLength?a.idLength():22)}function r(e){var n=function(e){if(e){if(Ie)return e[de]();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}}(new Date);return o.accountAcquisitionDate=n,o.isNewUser=!0,[e,n]}function i(e){o.isUserCookieSet=l.set(s(),e,31536e3)}n&&(o.isNewUser=!1,0<(n=n.split(U.cookieSeparator)).length&&(o.id=n[0],o.isUserCookieSet=!!o.id)),o.id||(o.id=t(),i(r(o.id).join(U.cookieSeparator)),n=a.namePrefix&&a.namePrefix()?a.namePrefix()+"ai_session":"ai_session",Hn(u,n)),o.accountId=a.accountId?a.accountId():undefined;var n=l.get(U.authUserCookieName);n&&((n=(n=decodeURI(n)).split(U.cookieSeparator))[0]&&(o.authenticatedId=n[0]),1<n.length&&n[1]&&(o.accountId=n[1])),o.setAuthenticatedUserContext=function(e,n,t){void 0===t&&(t=!1),!pt(e)||n&&!pt(n)?u.throwInternal(I.WARNING,y.SetAuthContextFailedAccountName,"Setting auth user context failed. User auth/account id should be of type string, and not contain commas, semi-colons, equal signs, spaces, or vertical-bars.",!0):(o.authenticatedId=e,e=o.authenticatedId,n&&(o.accountId=n,e=[o.authenticatedId,o.accountId].join(U.cookieSeparator)),t&&l.set(U.authUserCookieName,encodeURI(e)))},o.clearAuthenticatedUserContext=function(){o.authenticatedId=null,o.accountId=null,l.del(U.authUserCookieName)},o.update=function(e){o.id===e&&o.isUserCookieSet||i(r(e||t()).join(U.cookieSeparator))}})}var ht=function(){},mt=function(e,n,t,o){var r=this,e=(r.traceID=e||function(){for(var e,n=["0","1","2","3","4","5","6","7","8","9","a","b","c","d","e","f"],t="",o=0;o<4;o++)t+=n[15&(e=Dn())]+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 r=n[8+(3&Dn())|0];return t.substr(0,8)+t.substr(9,4)+"4"+t.substr(13,3)+r+t.substr(16,3)+t.substr(19,12)}(),r.parentID=n,r.name=t,je());!t&&e&&e.pathname&&(r.name=e.pathname),r.name=Fn(o,r.name)},Ct="ext",It="tags";function yt(e,n){e&&e[n]&&0===function(e){var n=typeof e;if(n===F||n===a&&null!==e||W("objKeys called on non-object"),!Ne&&he)return he(e);var t,o=[];for(t in e)e&&V.call(e,t)&&o.push(t);if(Ne)for(var r=Ae.length,i=0;i<r;i++)e&&V.call(e,Ae[i])&&o.push(Ae[i]);return o}(e[n]).length&&delete e[n]}var xt,St=function At(e,n){var o=this,t=e.logger;this.appId=function(){return null},this.getSessionId=function(){return null},C(At,this,function(r){r.application=new ft,r.internal=new gt(n),Be()&&(r.sessionManager=new ct(n,e),r.device=new dt,r.location=new ht,r.user=new vt(n,e),r.telemetryTrace=new mt(undefined,undefined,undefined,t),r.session=new lt),r.getSessionId=function(){var e=r.session;return e&&T(e.id)?e.id:(e=(r.sessionManager||{}).automaticSession)&&T(e.id)?e.id:null},r.applySessionContext=function(e,n){A(f(e.ext,st),"sesId",r.getSessionId(),T)},r.applyOperatingSystemContxt=function(e,n){A(e.ext,ut,r.os)},r.applyApplicationContext=function(e,n){var t=r.application;t&&(A(e=f(e,It),D.applicationVersion,t.ver,T),A(e,D.applicationBuild,t.build,T))},r.applyDeviceContext=function(e,n){var t=r.device;t&&(A(e=f(f(e,Ct),rt),"localId",t.id,T),A(e,"ip",t.ip,T),A(e,"model",t.model,T),A(e,"deviceClass",t.deviceClass,T))},r.applyInternalContext=function(e,n){var t,o=r.internal;o&&(A(t=f(e,It),D.internalAgentVersion,o.agentVersion,T),A(t,D.internalSdkVersion,o.sdkVersion,T),e.baseType!==Ze.dataType&&e.baseType!==Xn.dataType||(A(t,D.internalSnippet,o.snippetVer,T),A(t,D.internalSdkSrc,o.sdkSrc,T)))},r.applyLocationContext=function(e,n){var t=o.location;t&&A(f(e,It,[]),D.locationIp,t.ip,T)},r.applyOperationContext=function(e,n){var t=r.telemetryTrace;t&&(A(e=f(f(e,Ct),it,{traceID:undefined,parentID:undefined}),"traceID",t.traceID,T),A(e,"name",t.name,T),A(e,"parentID",t.parentID,T))},r.applyWebContext=function(e,n){var t=o.web;t&&A(f(e,Ct),at,t)},r.applyUserContext=function(e,n){var t=r.user;t&&(A(f(e,It,[]),D.userAccountId,t.accountId,T),A(e=f(f(e,Ct),ot),"id",t.id,T),A(e,"authId",t.authenticatedId,T))},r.cleanUp=function(e,n){e=e.ext;e&&(yt(e,rt),yt(e,ot),yt(e,at),yt(e,ut),yt(e,st),yt(e,it))}})},n=(G(wt,xt=O),wt.getDefaultConfig=function(){return{instrumentationKey:function(){return undefined},accountId:function(){return null},sessionRenewalMs:function(){return 18e5},samplingPercentage:function(){return 100},sessionExpirationMs:function(){return 864e5},cookieDomain:function(){return null},sdkExtension:function(){return null},isBrowserLinkTrackingEnabled:function(){return!1},appId:function(){return null},getSessionId:function(){return null},namePrefix:function(){return undefined},sessionCookiePostfix:function(){return undefined},userCookiePostfix:function(){return undefined},idLength:function(){return 22},getNewId:function(){return null}}},wt);function wt(){var l,c,e=xt.call(this)||this;return e.priority=110,e.identifier="AppInsightsPropertiesPlugin",C(wt,e,function(s,u){s.initialize=function(e,n,t,o){u.initialize(e,n,t,o);var r,i=s._getTelCtx(),a=s.identifier,e=wt.getDefaultConfig();c=c||{},Se(e,function(e,n){c[e]=function(){return i.getConfig(a,e,n())}}),s.context=new St(n,c),r=null,Te(t,function(e){if("AppInsightsChannelPlugin"===e.identifier)return r=e,-1}),l=r,s.context.appId=function(){return l?l._appId:null},s._extConfig=c},s.processTelemetry=function(e,n){var t,o,r,i;x(e)||(n=s._getTelCtx(n),e.name===Xn.envelopeType&&n.diagLog().resetInternalMessageCount(),(r=s.context||{}).session&&"string"!=typeof s.context.session.id&&r.sessionManager&&r.sessionManager.update(),(t=r.user)&&!t.isUserCookieSet&&t.update(r.user.id),r=n,f(o=e,"tags",[]),f(o,"ext",{}),(i=s.context).applySessionContext(o,r),i.applyApplicationContext(o,r),i.applyDeviceContext(o,r),i.applyOperationContext(o,r),i.applyUserContext(o,r),i.applyOperatingSystemContxt(o,r),i.applyWebContext(o,r),i.applyLocationContext(o,r),i.applyInternalContext(o,r),i.cleanUp(o,r),t&&t.isNewUser&&(t.isNewUser=!1,o=new Ze(y.SendBrowserInfoOnUserInit,(Ve()||{}).userAgent||""),n.diagLog().logInternalMessage(I.CRITICAL,o)),s.processNext(e,n))}}),e}e.PropertiesPlugin=n,e.Session=lt,e.SessionManager=ct,e.TelemetryContext=St,e.TelemetryTrace=mt;s=e,M="__esModule",P={value:!0},et=Object.defineProperty;if(et)try{return void et(s,M,P)}catch(kt){}typeof P.value!==undefined&&(s[M]=P.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(e){"use strict";var F="function",a="object",r="undefined",o="prototype",_="hasOwnProperty",t=Object,O=t[o],B=t.create,n=t.defineProperty,V=O[_],j=null;function W(e){return void 0===e&&(e=!0),j&&e||(typeof globalThis!==r&&globalThis&&(j=globalThis),typeof self!==r&&self&&(j=self),typeof window!==r&&window&&(j=window),typeof global!==r&&global&&(j=global)),j}function q(e){throw new TypeError(e)}(W()||{}).Symbol,(W()||{}).Reflect;var G=function(e,n){return(G=t.setPrototypeOf||{__proto__:[]}instanceof Array&&function(e,n){e.__proto__=n}||function(e,n){for(var t in n)n[_](t)&&(e[t]=n[t])})(e,n)};function K(e,n){function t(){this.constructor=e}typeof n!==F&&null!==n&&q("Class extends value "+n+" is not a constructor or null"),G(e,n),e[o]=null===n?function(e){if(B)return B(e);if(null==e)return{};var n=typeof e;function t(){}return n!==a&&n!==F&&q("Object prototype may only be an Object:"+e),t[o]=e,new t}(n):(t[o]=n[o],new t)}var z="constructor",p="prototype",H="function",J="_dynInstFuncs",Z="_isDynProxy",X="_dynClass",Y="_dynInstChk",$=Y,Q="_dfOpts",ee="_unknown_",ne="__proto__",te="useBaseInst",oe="setInstFuncs",re=Object,ie=re.getPrototypeOf,ae=0;function v(e,n){return e&&re[p].hasOwnProperty.call(e,n)}function se(e){return e&&(e===re[p]||e===Array[p])}function ue(e){return se(e)||e===Function[p]}function h(e){if(e){if(ie)return ie(e);e=e[ne]||e[p]||(e[z]?e[z][p]:null);if(e)return e}return null}function ce(e,n){var t=[],o=re.getOwnPropertyNames;if(o)t=o(e);else for(var r in e)"string"==typeof r&&v(e,r)&&t.push(r);if(t&&0<t.length)for(var i=0;i<t.length;i++)n(t[i])}function le(e,n,t){return n!==z&&typeof e[n]===H&&(t||v(e,n))}function fe(e){throw new TypeError("DynamicProto: "+e)}function de(e,n){for(var t=e.length-1;0<=t;t--)if(e[t]===n)return 1}function ge(e,n){return v(e,p)?e.name||n||ee:((e||{})[z]||{}).name||n||ee}function m(e,o,n,t){v(e,p)||fe("theClass is an invalid class definition.");var r,i,a,s,u,c,l=e[p],f=(function(e){if(ie)for(var n=[],t=h(o);t&&!ue(t)&&!de(n,t);){if(t===e)return 1;n.push(t),t=h(t)}}(l)||fe("["+ge(e)+"] is not in class hierarchy of ["+ge(o)+"]"),null),e=(v(l,X)?f=l[X]:(f="_dynCls$"+ge(e,"_")+"$"+ae,ae++,l[X]=f),m[Q]),d=!!e[te],g=(d&&t&&t[te]!==undefined&&(d=!!t[te]),i={},ce(r=o,function(e){!i[e]&&le(r,e,!1)&&(i[e]=r[e])}),i),d=(n(o,function(e,n,t,i){function o(e,n,t){var o,r=n[t];return r[Z]&&i&&!1!==(o=e[J]||{})[$]&&(r=(o[n[X]]||{})[t]||r),function(){return r.apply(e,arguments)}}for(var r={},a=(ce(t,function(e){r[e]=o(n,t,e)}),h(e)),s=[];a&&!ue(a)&&!de(s,a);)ce(a,function(e){!r[e]&&le(a,e,!ie)&&(r[e]=o(n,a,e))}),s.push(a),a=h(a);return r}(l,o,g,d)),!!ie&&!!e[oe]);a=l,n=f,s=o,u=g,e=!1!==(d=d&&t?!!t[oe]:d),se(a)||(l=s[J]=s[J]||{},c=l[n]=l[n]||{},!1!==l[$]&&(l[$]=!!e),ce(s,function(e){var t,o,r;le(s,e,!1)&&s[e]!==u[e]&&(c[e]=s[e],delete s[e],v(a,e)&&(!a[e]||a[e][Z])||(a[e]=(t=a,o=e,(r=function(){var e,n;return(function(e,n,t,o){var r=null;if(e&&v(t,X)){var i=e[J]||{};if((r=(i[t[X]]||{})[n])||fe("Missing ["+n+"] "+H),!r[Y]&&!1!==i[$]){for(var a=!v(e,n),s=h(e),u=[];a&&s&&!ue(s)&&!de(u,s);){var c=s[n];if(c){a=c===o;break}u.push(s),s=h(s)}try{a&&(e[n]=r),r[Y]=1}catch(l){i[$]=!1}}}return r}(this,o,t,r)||(typeof(n=(n=t[e=o])===r?h(t)[e]:n)!==H&&fe("["+e+"] is not a "+H),n)).apply(this,arguments)})[Z]=1,r)))}))}m[Q]={setInstFuncs:!0,useBaseInst:!0},(i=C=C||{})[i.CRITICAL=1]="CRITICAL",i[i.WARNING=2]="WARNING";var C,I={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},pe="toISOString",ve="endsWith",he="trim",i="toString",me="constructor",Ce=n,n=t.freeze,Ie=t.keys,s=String[o],ye=s[he],xe=s[ve],Se=Date[o][pe],s=Array.isArray,we=O[i],Ne=V[i],Te=Ne.call(t),Ae=Object.getPrototypeOf;function g(e){return e===undefined||typeof e===r}function y(e){return null===e||g(e)}function ke(e){return!y(e)}function be(e){return!(!e||typeof e!==a)}function x(e){return!(!e||typeof e!==F)}function Me(e,n){if(e)for(var t in e)V.call(e,t)&&n.call(e,t,e[t])}function S(e,n){return!(!e||!n||!~e.indexOf(n))}var w=s||function(e){return!(!e||"[object Array]"!==we.call(e))};function N(e){return"string"==typeof e}function Pe(e){return e&&"object"==typeof e&&(!(e=(Ae||function(e){if(e){if(Ae)return Ae(e);e=e.__proto__||e[o]||e[me];if(e)return e}return null})(e))||typeof(e=e[me]&&V.call(e,me)?e[me]:e)===F&&Ne.call(e)===Te)}function Le(e,n,t){var o=e.length;try{for(var r=0;r<o&&!(r in e&&-1===n.call(t||e,e[r],r,e));r++);}catch(i){}}function T(e){return e&&(ye&&e[he]?e[he]():e.replace?e.replace(/^\s+|\s+$/g,""):e)}var Re=!{toString:null}.propertyIsEnumerable("toString"),De=["toString","toLocaleString","valueOf","hasOwnProperty","isPrototypeOf","propertyIsEnumerable","constructor"],Ue=n||function(e){return e};function Ee(){var e=Date;return e.now?e.now():(new e).getTime()}function Fe(e){return e&&"[object Error]"===we.call(e)?e.name:""}function A(e,n,t,o,r){var i=t;!e||(i=e[n])===t||r&&!r(i)||o&&!o(t)||(e[n]=i=t)}function f(e,n,t){var o;return e?!(o=e[n])&&y(o)&&(o=g(t)?{}:t,e[n]=o):o=g(t)?{}:t,o}function _e(e){return!!e}var Oe="window",Be="navigator",Ve="location",je="JSON",We="msie",qe="trident/",Ge=null,Ke=null,ze=!1;function c(e){var n=W();return n&&n[e]?n[e]:e===Oe&&He()?window:null}function He(){return typeof window===a&&window}function Je(){return typeof navigator===a&&navigator?navigator:c(Be)}function Ze(e){if(e&&ze){e=c("__mockLocation");if(e)return e}return typeof location===a&&location?location:c(Ve)}function Xe(){return typeof JSON===a&&JSON||null!==c(je)}function Ye(){return Xe()?JSON||c(je):null}function $e(){var e=Je();return!e||e.userAgent===Ke&&null!==Ge||(e=((Ke=e.userAgent)||"").toLowerCase(),Ge=S(e,We)||S(e,qe)),Ge}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+"'":Xe()&&(t=Ye().stringify(e)),n+t}var Qe=null;function en(e){return e?'"'+e.replace(/\"/g,"")+'"':""}function nn(e,n){var t,o=typeof console!==r?console:c("console");o&&(t="log",x(o[t=o[e]?e:t])&&o[t](n))}on.dataType="MessageData";var tn=on;function on(e,n,t,o){void 0===t&&(t=!1),this.messageId=e,this.message=(t?"AI: ":"AI (Internal): ")+e;t="",Xe()&&(t=Ye().stringify(o)),e=(n?" message:"+en(n):"")+(o?" props:"+en(t):"");this.message+=e}function rn(e,n){return(e||{}).logger||new an(n)}var an=function Ut(r){this.identifier="DiagnosticLogger",this.queue=[];var s=0,u={};m(Ut,this,function(i){function e(e,n){e=r[e];return y(e)?n:e}function a(e,n){var t,o=(t=(t=Qe)||!0===r.disableDbgExt?t:Qe||(o=c("Microsoft"),Qe=o?o.ApplicationInsights:Qe))?t.ChromeDbgExt:null;o&&o.diagLog&&o.diagLog(e,n)}y(r)&&(r={}),i.consoleLoggingLevel=function(){return e("loggingLevelConsole",0)},i.telemetryLoggingLevel=function(){return e("loggingLevelTelemetry",1)},i.maxInternalMessageLimit=function(){return e("maxMessageLimit",25)},i.enableDebugExceptions=function(){return e("enableDebugExceptions",!1)},i.throwInternal=function(e,n,t,o,r){n=new tn(n,t,r=void 0!==r&&r,o);if(i.enableDebugExceptions())throw n;t=e===C.CRITICAL?"errorToConsole":"warnToConsole";g(n.message)?a("throw"+(e===C.CRITICAL?"Critical":"Warning"),n):(o=i.consoleLoggingLevel(),r?(r=+n.messageId,!u[r]&&e<=o&&(i[t](n.message),u[r]=!0)):e<=o&&i[t](n.message),i.logInternalMessage(e,n))},i.warnToConsole=function(e){nn("warn",e),a("warning",e)},i.errorToConsole=function(e){nn("error",e),a("error",e)},i.resetInternalMessageCount=function(){s=0,u={}},i.logInternalMessage=function(e,n){var t,o;s>=i.maxInternalMessageLimit()||(o=!0,t="AITR_"+n.messageId,u[t]?o=!1:u[t]=!0,o&&(e<=i.telemetryLoggingLevel()&&(i.queue.push(n),s++,a(e===C.CRITICAL?"error":"warn",n)),s===i.maxInternalMessageLimit()&&(o=new tn(I.MessageLimitPerPVExceeded,t="Internal events throttle limit per PageView reached for this app.",!1),i.queue.push(o),e===C.CRITICAL?i.errorToConsole(t):i.warnToConsole(t))))}})},sn=(u.ParentContextKey="parent",u.ChildrenContextKey="childEvts",u);function u(e,r,n){var o,i=this,a=!1;i.start=Ee(),i.name=e,i.isAsync=n,i.isChildEvt=function(){return!1},x(r)&&(a=function(e){if(Ce)try{var n={enumerable:!0,configurable:!0,get:function(){return!o&&x(r)&&(o=r(),r=null),o}};return Ce(e,"payload",n),!0}catch(t){}return!1}(i)),i.getCtx=function(e){return e?(e===u.ParentContextKey||e===u.ChildrenContextKey?i:i.ctx||{})[e]:null},i.setCtx=function(e,n){e&&(e===u.ParentContextKey?(i[e]||(i.isChildEvt=function(){return!0}),i[e]=n):e===u.ChildrenContextKey?i[e]=n:(i.ctx=i.ctx||{})[e]=n)},i.complete=function(){var e=0,n=i.getCtx(u.ChildrenContextKey);if(w(n))for(var t=0;t<n.length;t++){var o=n[t];o&&(e+=o.time)}i.time=Ee()-i.start,i.exTime=i.time-e,i.complete=function(){},!a&&x(r)&&(i.payload=r())}}var un="CoreUtils.doPerf";function cn(e,n,t,o,r){if(e)if(e=x(e.getPerfMgr)?e.getPerfMgr():e){var i,a=void 0,s=e.getCtx(un);try{if(a=e.create(n(),o,r))return s&&a.setCtx&&(a.setCtx(sn.ParentContextKey,s),s.getCtx&&s.setCtx&&((i=s.getCtx(sn.ChildrenContextKey))||(i=[],s.setCtx(sn.ChildrenContextKey,i)),i.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 ln="TelemetryPluginChain",fn="_hasRun",dn="_getTelCtx",gn=0;function pn(e,a,t,n){var o=null,r=null,o=n?function(e,n,t,o){for(;e;){if(e.getPlugin()===o)return e;e=e.getNext()}return vn([o],n,t)}(e,a,t,n):e,i={core:function(){return t},diagLog:function(){return rn(t,a)},getCfg:function(){return a},getExtCfg:s,getConfig:function(e,n,t){void 0===t&&(t=!1);var o,e=s(e,null);return e&&!y(e[n])?o=e[n]:a&&!y(a[n])&&(o=a[n]),y(o)?t:o},hasNext:function(){return null!=o},getNext:function(){return o},setNext:function(e){o=e},processNext:function(n){u(function(e){e.processTelemetry(n,i)})},iterate:function(n){for(;o;)u(function(e){e=e.getPlugin();e&&n(e)})},createNew:function(e,n){return pn((e=w(e=void 0===e?null:e)?vn(e,a,t,n):e)||o,a,t,n)},onComplete:function(e){r=e}};function s(e,n,t){var o,r,i;return void 0===n&&(n={}),void 0===t&&(t=0),(o=a&&(r=a.extensionConfig)&&e?r[e]:o)?be(n)&&0!==t&&(i=function d(){var e=arguments,n=e[0]||{},t=e.length,o=!1,r=1;for(0<t&&"boolean"==typeof n&&(o=n,n=e[r]||{},r++),be(n)||(n={});r<t;r++){var i,a,s,u,c=e[r],l=w(c),f=be(c);for(i in c)(l&&i in c||f&&V.call(c,i))&&(a=c[i],s=void 0,o&&a&&((s=w(a))||Pe(a))&&(u=n[i],s?w(u)||(u=[]):Pe(u)||(u={}),a=d(o,u,a)),a!==undefined&&(n[i]=a))}return n}(!0,n,o),a&&2===t&&Me(n,function(e){var n;y(i[e])&&!y(n=a[e])&&(i[e]=n)})):o=n,o}function u(e){var n=o;n?(o=n.getNext(),e(n)):r&&(r(),r=null)}return i}function vn(e,n,t,o){var r,i=null,a=!o;return w(e)&&0<e.length&&(r=null,Le(e,function(e){(a=!a&&o===e||a)&&e&&x(e.processTelemetry)&&(e=hn(e,n,t),i=i||e,r&&r._setNext(e),r=e)})),o&&!i?vn([o],n,t):i}function hn(u,c,l){var f=null,t=x(u.processTelemetry),o=x(u.setNextPlugin),d=u?u.identifier+"-"+u.priority+"-"+gn++:"Unknown-0-"+gn++,g={getPlugin:function(){return u},getNext:function(){return f},processTelemetry:function(n,e){r(e,function(e){return!!t&&(o&&u.setNextPlugin(f),u.processTelemetry(n,e),!0)},function(e){f.processTelemetry(n,e)},"processTelemetry",function(){return{item:n}},!n.sync)},_id:d,_setNext:function(e){f=e}};function r(o,r,i,a,e,n){o=(o=o||(u&&x(u[dn])?u[dn]():o))||pn(g,c,l);var t=u?u.identifier:ln,s=(s=o[fn])||(o[fn]={});cn(o.core(),function(){return t+":"+a},function(){var e=!(s[d]=!0);if(o.setNext(f),u)try{var n=f?f._id:"";n&&(s[n]=!1),e=r(o)}catch(t){n=!f||s[f._id];n&&(e=!0),f&&n||o.diagLog().throwInternal(C.CRITICAL,I.PluginException,"Plugin ["+u.identifier+"] failed during "+a+" - "+k(t)+", run flags: "+k(s))}f&&!e&&i(o)},e,n)}return Ue(g)}var mn="toGMTString",Cn="toUTCString",In="cookie",yn="expires",xn="enabled",Sn="isCookieUseDisabled",wn="disableCookiesUsage",b="_ckMgr",M="",Nn=null,Tn=null,An=null,kn=typeof document===a&&document?document:c("document"),bn={},Mn={};function Pn(e){return!e||e.isEnabled()}function Ln(e,n){var t,o;return e?t=e.getCookieMgr():n&&(t=n.cookieCfg[b]||Rn(n)),t||(e=(e||{}).logger,(o=Rn[b]||Mn[b])||(o=Rn[b]=Rn(n,e),Mn[b]=o),t=o),t}function Rn(e,r){A(t=(e=e||Mn).cookieCfg=e.cookieCfg||{},"domain",e.cookieDomain,ke,y),A(t,"path",e.cookiePath||"/",null,y),y(t[xn])&&(n=void 0,g(e[Sn])||(n=!e[Sn]),g(e[wn])||(n=!e[wn]),t[xn]=n);var n,t,c=t,l=c.path||"/",f=c.domain,o=!1!==c[xn],d={isEnabled:function(){var e=o&&Dn(r),n=Mn[b];return e&&n&&d!==n?Pn(n):e},setEnabled:function(e){o=!1!==e},set:function(e,n,t,o,r){var i,a,s,u=!1;return Pn(d)&&(i={},-1!=(s=(a=T(n||M)).indexOf(";"))&&(a=T(n.substring(0,s)),i=Un(n.substring(1+s))),A(i,"domain",o||f,_e,g),y(t)||(s=$e(),g(i[yn])&&0<(n=Ee()+1e3*t)&&((o=new Date).setTime(n),A(i,yn,En(o,s?mn:Cn)||En(o,s?mn:Cn)||M,_e)),s||A(i,"max-age",M+t,null,g)),(n=Ze())&&"https:"===n.protocol&&(A(i,"secure",null,null,g),(Tn=null===Tn?!(N(o=(Je()||{}).userAgent)&&(S(o,"CPU iPhone OS 12")||S(o,"iPad; CPU OS 12")||S(o,"Macintosh; Intel Mac OS X 10_14")&&S(o,"Version/")&&S(o,"Safari")||S(o,"Macintosh; Intel Mac OS X 10_14")&&function(e,n){var t=!1;if(!e||(t=e===n))return t;if(xe)return e[ve](n);var o=e,r=n,t=!1,e=o?o.length:0;if(e&&40<=e&&!(t=o===r)){for(var i=e-1,a=39;0<=a;a--){if(o[i]!=r[a])return;i--}t=!0}return t}(o,"AppleWebKit/605.1.15 (KHTML, like Gecko)")||S(o,"Chrome/5")||S(o,"Chrome/6")||S(o,"UnrealEngine")&&!S(o,"Chrome")||S(o,"UCBrowser/12")||S(o,"UCBrowser/11"))):Tn)&&A(i,"SameSite","None",null,g)),A(i,"path",r||l,null,g),(c.setCookie||_n)(e,Fn(a,i)),u=!0),u},get:function(e){var n=M;return Pn(d)?(c.getCookie||function(e){var n,t=M;return kn&&(n=kn[In]||M,An!==n&&(bn=Un(n),An=n),t=T(bn[e]||M)),t})(e):n},del:function(e,n){return!!Pn(d)&&d.purge(e,n)},purge:function(e,n){var t,o=!1;return Dn(r)&&((t={}).path=n||"/",t[yn]="Thu, 01 Jan 1970 00:00:01 GMT",n=t,$e()||(n["max-age"]="0"),(c.delCookie||_n)(e,Fn(M,n)),o=!0),o}};return d[b]=d}function Dn(e){if(null===Nn){Nn=!1;try{Nn=(kn||{})[In]!==undefined}catch(n){e&&e.throwInternal(C.WARNING,I.CannotAccessCookie,"Cannot access document.cookie - "+Fe(n),{exception:k(n)})}}return Nn}function Un(e){var t={};return e&&e.length&&Le(T(e).split(";"),function(e){var n;(e=T(e||M))&&(-1==(n=e.indexOf("="))?t[e]=null:t[T(e.substring(0,n))]=T(e.substring(1+n)))}),t}function En(e,n){return x(e[n])?e[n]():null}function Fn(e,n){var t=e||M;return Me(n,function(e,n){t+="; "+e+(y(n)?M:"="+n)}),t}function _n(e,n){kn&&(kn[In]=e+"="+n)}var On="getPlugin",O=function Et(){var i,a,s,n,u=this;function t(e){var n,e=e=void 0===e?null:e;return e||(n=a||pn(null,{},u.core),e=s&&s[On]?n.createNew(null,s[On]):n.createNew(null,s)),e}i=!1,u.core=null,s=a=null,n=[],m(Et,u,function(e){e.initialize=function(e,n,t,o){e&&A(e,"extensionConfig",[],null,y),!o&&n&&(o=n.getProcessTelContext().getNext());var r=s;s&&s[On]&&(r=s[On]()),u.core=n,a=pn(o,e,n,r),i=!0},e._addHook=function(e){e&&(w(e)?n=n.concat(e):n.push(e))}}),u.diagLog=function(e){return t(e).diagLog()},u.isInitialized=function(){return i},u.setInitialized=function(e){i=e},u.setNextPlugin=function(e){s=e},u.processNext=function(e,n){n?n.processNext(e):s&&x(s.processTelemetry)&&s.processTelemetry(e,null)},u._getTelCtx=t},Bn=4294967296,l=4294967295,Vn=!1,jn=123456789,Wn=987654321;function qn(e){var n,t=0,o=c("crypto")||c("msCrypto");if(0===(t=o&&o.getRandomValues?o.getRandomValues(new Uint32Array(1))[0]&l:t)&&$e()){if(!Vn)try{var r=2147483647&Ee();(n=(Math.random()*Bn^r)+r)<0&&(n>>>=0),jn=123456789+n&l,Wn=987654321-n&l,Vn=!0}catch(i){}o=((Wn=36969*(65535&Wn)+(Wn>>16)&l)<<16)+(65535&(jn=18e3*(65535&jn)+(jn>>16)&l))>>>0&l|0,t=(o>>>=0)&l}return 0===t&&(t=Math.floor(Bn*Math.random()|0)),e||(t>>>=0),t}function Gn(e){void 0===e&&(e=22);for(var n=qn()>>>0,t=0,o="";o.length<e;)o+="ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789+/"[0|63&n]||"",n>>>=6,5==++t&&(n=(qn()<<2&4294967295|3&n)>>>0,t=0);return o}function Kn(e,n,t){var o,r,i=n.length,a=(e=e,(n=n)&&150<(n=T(n.toString())).length&&(r=n.substring(0,150),e&&e.throwInternal(C.WARNING,I.NameTooLong,"name is too long. It has been truncated to 150 characters.",{name:n},!0)),r||n);if(a.length!==i){for(var s=0,u=a;t[u]!==undefined;)s++,u=a.substring(0,147)+(o=void 0,(o="00"+s).substr(o.length-3));a=u}return a}function zn(e,n,t){var o;return void 0===t&&(t=1024),n&&(t=t||1024,(n=T(n)).toString().length>t&&(o=n.toString().substring(0,t),e&&e.throwInternal(C.WARNING,I.StringValueTooLong,"string value is too long. It has been truncated to "+t+" characters.",{value:n},!0))),o||n}function Hn(o,e){var r;return e&&(r={},Me(e,function(e,n){if(be(n)&&Xe())try{n=Ye().stringify(n)}catch(t){o&&o.throwInternal(C.WARNING,I.CannotSerializeObjectNonSerializable,"custom property is not valid",{exception:t},!0)}n=zn(o,n,8192),e=Kn(o,e,r),r[e]=n}),e=r),e}function Jn(e,n,t,o){var r;return n&&(n=T(n)).length>t&&(r=n.substring(0,t),e&&e.throwInternal(C.WARNING,o,"input is too long, it has been truncated to "+t+" characters.",{data:n},!0)),r||n}(i=Zn=Zn||{})[i.LocalStorage=0]="LocalStorage",i[i.SessionStorage=1]="SessionStorage";var Zn,Xn,Yn=undefined;function $n(){return et()?Qn(Zn.LocalStorage):null}function Qn(e){try{if(y(W()))return null;var n=new Date,t=c(e===Zn.LocalStorage?"localStorage":"sessionStorage"),o=(t.setItem(n.toString(),n.toString()),t.getItem(n.toString())!==n.toString());if(t.removeItem(n.toString()),!o)return t}catch(r){}return null}function et(){return Yn=Yn===undefined?!!Qn(Zn.LocalStorage):Yn}function nt(e,n){var t=$n();if(null!==t)try{return t.getItem(n)}catch(o){Yn=!1,e.throwInternal(C.WARNING,I.BrowserCannotReadLocalStorage,"Browser failed read of local storage. "+Fe(o),{exception:k(o)})}return null}function tt(e,n,t){var o=$n();if(null!==o)try{o.setItem(n,t)}catch(r){Yn=!1,e.throwInternal(C.WARNING,I.BrowserCannotWriteLocalStorage,"Browser failed write to local storage. "+Fe(r),{exception:k(r)})}}function ot(e,n){var t=$n();if(null!==t)try{t.removeItem(n)}catch(o){Yn=!1,e.throwInternal(C.WARNING,I.BrowserFailedRemovalFromLocalStorage,"Browser failed removal of local storage item. "+Fe(o),{exception:k(o)})}}function rt(){var e=Xn.call(this)||this;return e.ver=2,e.properties={},e.measurements={},e}K(rt,Xn=function(){this.ver=2,this.properties={},this.measurements={}}),K(st,it=rt),st.envelopeType="Microsoft.ApplicationInsights.{0}.Pageview",st.dataType="PageviewData";var it,at=st;function st(e,n,t,o,r,i,a){var s,u,c,l=it.call(this)||this;return l.aiDataContract={ver:1,name:0,url:0,duration:0,properties:0,measurements:0,id:0},l.id=a&&Jn(e,a,128,I.IdTooLong).toString(),l.url=Jn(e,t,2048,I.UrlTooLong),l.name=zn(e,n)||"not_specified",isNaN(o)||(l.duration=(t=""+Math.floor((a=Math.round(a=isNaN(a=o)||a<0?0:a))/1e3)%60,n=1===(n=""+a%1e3).length?"00"+n:2===n.length?"0"+n:n,t=t.length<2?"0"+t:t,o=(o=""+Math.floor(a/6e4)%60).length<2?"0"+o:o,(0<(s=Math.floor(a/864e5))?s+".":"")+(s=(s=""+Math.floor(a/36e5)%24).length<2?"0"+s:s)+":"+o+":"+t+"."+n)),l.properties=Hn(e,r),l.measurements=(u=e,(a=i)&&(c={},Me(a,function(e,n){e=Kn(u,e,c),c[e]=n}),a=c),a),l}function d(e){var n="ai."+e+".";return function(e){return n+e}}var ut,ct,s=d("application"),n=d("device"),i=d("location"),P=d("operation"),lt=d("session"),L=d("user"),R=d("cloud"),ft=d("internal");function dt(){return ut.call(this)||this}ct={applicationVersion:s("ver"),applicationBuild:s("build"),applicationTypeId:s("typeId"),applicationId:s("applicationId"),applicationLayer:s("layer"),deviceId:n("id"),deviceIp:n("ip"),deviceLanguage:n("language"),deviceLocale:n("locale"),deviceModel:n("model"),deviceFriendlyName:n("friendlyName"),deviceNetwork:n("network"),deviceNetworkName:n("networkName"),deviceOEMName:n("oemName"),deviceOS:n("os"),deviceOSVersion:n("osVersion"),deviceRoleInstance:n("roleInstance"),deviceRoleName:n("roleName"),deviceScreenResolution:n("screenResolution"),deviceType:n("type"),deviceMachineName:n("machineName"),deviceVMName:n("vmName"),deviceBrowser:n("browser"),deviceBrowserVersion:n("browserVersion"),locationIp:i("ip"),locationCountry:i("country"),locationProvince:i("province"),locationCity:i("city"),operationId:P("id"),operationName:P("name"),operationParentId:P("parentId"),operationRootId:P("rootId"),operationSyntheticSource:P("syntheticSource"),operationCorrelationVector:P("correlationVector"),sessionId:lt("id"),sessionIsFirst:lt("isFirst"),sessionIsNew:lt("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:R("name"),cloudRole:R("role"),cloudRoleVer:R("roleVer"),cloudRoleInstance:R("roleInstance"),cloudEnvironment:R("environment"),cloudLocation:R("location"),cloudDeploymentUnit:R("deploymentUnit"),internalNodeName:ft("nodeName"),internalSdkVersion:ft("sdkVersion"),internalAgentVersion:ft("agentVersion"),internalSnippet:ft("snippet"),internalSdkSrc:ft("sdkSrc")},K(dt,ut=function(){var t=this;Me(ct,function(e,n){t[e]=n})});var gt="user",pt="device",vt="trace",ht="web",mt="app",Ct="os",D=new dt,It=function(){},yt=(U.acquisitionSpan=864e5,U.renewalSpan=18e5,U.cookieUpdateInterval=6e4,U);function U(n,e){var l,f,d=rn(e),g=Ln(e);m(U,this,function(s){x((n=n||{}).sessionExpirationMs)||(n.sessionExpirationMs=function(){return U.acquisitionSpan}),x(n.sessionRenewalMs)||(n.sessionRenewalMs=function(){return U.renewalSpan}),s.config=n;var e=s.config.sessionCookiePostfix&&s.config.sessionCookiePostfix()?s.config.sessionCookiePostfix():s.config.namePrefix&&s.config.namePrefix()?s.config.namePrefix():"";function u(e,n){var t=!1,o=", session will be reset",r=n.split("|");if(2<=r.length)try{var i=+r[1]||0,a=+r[2]||0;isNaN(i)||i<=0?d.throwInternal(C.WARNING,I.SessionRenewalDateIsZero,"AI session acquisition date is 0"+o):isNaN(a)||a<=0?d.throwInternal(C.WARNING,I.SessionRenewalDateIsZero,"AI session renewal date is 0"+o):r[0]&&(e.id=r[0],e.acquisitionDate=i,e.renewalDate=a,t=!0)}catch(s){d.throwInternal(C.CRITICAL,I.ErrorParsingAISessionCookie,"Error parsing ai_session value ["+(n||"")+"]"+o+" - "+Fe(s),{exception:k(s)})}return t}function c(e,n){var t=e.acquisitionDate,o=(e.renewalDate=n,s.config),r=o.sessionRenewalMs(),i=t+o.sessionExpirationMs()-n,e=[e.id,t,n],t=i<r?i/1e3:r/1e3,i=o.cookieDomain?o.cookieDomain():null;g.set(l(),e.join("|"),0<o.sessionExpirationMs()?t:null,i),f=n}l=function(){return"ai_session"+e},s.automaticSession=new It,s.update=function(){var e,n,t,o=Ee(),r=!1,i=s.automaticSession,a=(i.id||(n=i,t=!1,(a=g.get(l()))&&x(a.split)?t=u(n,a):(a=nt(d,l()))&&(t=u(n,a)),r=!(t||n.id)),s.config.sessionExpirationMs());!r&&0<a&&(t=s.config.sessionRenewalMs(),n=o-i.acquisitionDate,e=o-i.renewalDate,r=(r=(r=n<0||e<0)||a<n)||t<e),r?(a=o,t=((n=s.config||{}).getNewId?n.getNewId():null)||Gn,s.automaticSession.id=t(n.idLength?n.idLength():22),s.automaticSession.acquisitionDate=a,c(s.automaticSession,a),et()||d.throwInternal(C.WARNING,I.BrowserDoesNotSupportLocalStorage,"Browser does not support local storage. Session durations will be inaccurate.")):(!f||U.cookieUpdateInterval<o-f)&&c(i,o)},s.backup=function(){var e=s.automaticSession,n=e.id,t=e.acquisitionDate,e=e.renewalDate;tt(d,l(),[n,t,e].join("|"))}})}var xt=function(){},St=function(){this.id="browser",this.deviceClass="Browser"},wt=function(e){this.sdkVersion=(e.sdkExtension&&e.sdkExtension()?e.sdkExtension()+"_":"")+"javascript:2.8.0-beta.2203-01"};function Nt(e){return"string"==typeof e&&e&&!e.match(/,|;|=| |\|/)}E.cookieSeparator="|",E.userCookieName="ai_user",E.authUserCookieName="ai_authUser";var Tt=E;function E(a,e){this.isNewUser=!1,this.isUserCookieSet=!1;var s,u=rn(e),c=Ln(e);m(E,this,function(o){o.config=a;var e=o.config.userCookiePostfix&&o.config.userCookiePostfix()?o.config.userCookiePostfix():"",n=(s=function(){return E.userCookieName+e},c.get(s()));function t(){var e=a||{};return((e.getNewId?e.getNewId():null)||Gn)(e.idLength?a.idLength():22)}function r(e){var n=function(e){if(e){if(Se)return e[pe]();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}}(new Date);return o.accountAcquisitionDate=n,o.isNewUser=!0,[e,n]}function i(e){o.isUserCookieSet=c.set(s(),e,31536e3)}n&&(o.isNewUser=!1,0<(n=n.split(E.cookieSeparator)).length&&(o.id=n[0],o.isUserCookieSet=!!o.id)),o.id||(o.id=t(),i(r(o.id).join(E.cookieSeparator)),n=a.namePrefix&&a.namePrefix()?a.namePrefix()+"ai_session":"ai_session",ot(u,n)),o.accountId=a.accountId?a.accountId():undefined;var n=c.get(E.authUserCookieName);n&&((n=(n=decodeURI(n)).split(E.cookieSeparator))[0]&&(o.authenticatedId=n[0]),1<n.length&&n[1]&&(o.accountId=n[1])),o.setAuthenticatedUserContext=function(e,n,t){void 0===t&&(t=!1),!Nt(e)||n&&!Nt(n)?u.throwInternal(C.WARNING,I.SetAuthContextFailedAccountName,"Setting auth user context failed. User auth/account id should be of type string, and not contain commas, semi-colons, equal signs, spaces, or vertical-bars.",!0):(o.authenticatedId=e,e=o.authenticatedId,n&&(o.accountId=n,e=[o.authenticatedId,o.accountId].join(E.cookieSeparator)),t&&c.set(E.authUserCookieName,encodeURI(e)))},o.clearAuthenticatedUserContext=function(){o.authenticatedId=null,o.accountId=null,c.del(E.authUserCookieName)},o.update=function(e){o.id===e&&o.isUserCookieSet||i(r(e||t()).join(E.cookieSeparator))}})}var At=function(){},kt=function(e,n,t,o){var r=this,e=(r.traceID=e||function(){for(var e,n=["0","1","2","3","4","5","6","7","8","9","a","b","c","d","e","f"],t="",o=0;o<4;o++)t+=n[15&(e=qn())]+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 r=n[8+(3&qn())|0];return t.substr(0,8)+t.substr(9,4)+"4"+t.substr(13,3)+r+t.substr(16,3)+t.substr(19,12)}(),r.parentID=n,r.name=t,Ze());!t&&e&&e.pathname&&(r.name=e.pathname),r.name=zn(o,r.name)},bt="ext",Mt="tags";function Pt(e,n){e&&e[n]&&0===function(e){var n=typeof e;if(n===F||n===a&&null!==e||q("objKeys called on non-object"),!Re&&Ie)return Ie(e);var t,o=[];for(t in e)e&&V.call(e,t)&&o.push(t);if(Re)for(var r=De.length,i=0;i<r;i++)e&&V.call(e,De[i])&&o.push(De[i]);return o}(e[n]).length&&delete e[n]}var Lt,Rt=function Ft(e,n){var o=this,t=e.logger;this.appId=function(){return null},this.getSessionId=function(){return null},m(Ft,this,function(r){r.application=new xt,r.internal=new wt(n),He()&&(r.sessionManager=new yt(n,e),r.device=new St,r.location=new At,r.user=new Tt(n,e),r.telemetryTrace=new kt(undefined,undefined,undefined,t),r.session=new It),r.getSessionId=function(){var e=r.session;return e&&N(e.id)?e.id:(e=(r.sessionManager||{}).automaticSession)&&N(e.id)?e.id:null},r.applySessionContext=function(e,n){A(f(e.ext,mt),"sesId",r.getSessionId(),N)},r.applyOperatingSystemContxt=function(e,n){A(e.ext,Ct,r.os)},r.applyApplicationContext=function(e,n){var t=r.application;t&&(A(e=f(e,Mt),D.applicationVersion,t.ver,N),A(e,D.applicationBuild,t.build,N))},r.applyDeviceContext=function(e,n){var t=r.device;t&&(A(e=f(f(e,bt),pt),"localId",t.id,N),A(e,"ip",t.ip,N),A(e,"model",t.model,N),A(e,"deviceClass",t.deviceClass,N))},r.applyInternalContext=function(e,n){var t,o=r.internal;o&&(A(t=f(e,Mt),D.internalAgentVersion,o.agentVersion,N),A(t,D.internalSdkVersion,o.sdkVersion,N),e.baseType!==tn.dataType&&e.baseType!==at.dataType||(A(t,D.internalSnippet,o.snippetVer,N),A(t,D.internalSdkSrc,o.sdkSrc,N)))},r.applyLocationContext=function(e,n){var t=o.location;t&&A(f(e,Mt,[]),D.locationIp,t.ip,N)},r.applyOperationContext=function(e,n){var t=r.telemetryTrace;t&&(A(e=f(f(e,bt),vt,{traceID:undefined,parentID:undefined}),"traceID",t.traceID,N),A(e,"name",t.name,N),A(e,"parentID",t.parentID,N))},r.applyWebContext=function(e,n){var t=o.web;t&&A(f(e,bt),ht,t)},r.applyUserContext=function(e,n){var t=r.user;t&&(A(f(e,Mt,[]),D.userAccountId,t.accountId,N),A(e=f(f(e,bt),gt),"id",t.id,N),A(e,"authId",t.authenticatedId,N))},r.cleanUp=function(e,n){e=e.ext;e&&(Pt(e,pt),Pt(e,gt),Pt(e,ht),Pt(e,Ct),Pt(e,mt),Pt(e,vt))}})},s=(K(Dt,Lt=O),Dt.getDefaultConfig=function(){return{instrumentationKey:function(){return undefined},accountId:function(){return null},sessionRenewalMs:function(){return 18e5},samplingPercentage:function(){return 100},sessionExpirationMs:function(){return 864e5},cookieDomain:function(){return null},sdkExtension:function(){return null},isBrowserLinkTrackingEnabled:function(){return!1},appId:function(){return null},getSessionId:function(){return null},namePrefix:function(){return undefined},sessionCookiePostfix:function(){return undefined},userCookiePostfix:function(){return undefined},idLength:function(){return 22},getNewId:function(){return null}}},Dt);function Dt(){var c,l,e=Lt.call(this)||this;return e.priority=110,e.identifier="AppInsightsPropertiesPlugin",m(Dt,e,function(s,u){s.initialize=function(e,n,t,o){u.initialize(e,n,t,o);var r,i=s._getTelCtx(),a=s.identifier,e=Dt.getDefaultConfig();l=l||{},Me(e,function(e,n){l[e]=function(){return i.getConfig(a,e,n())}}),s.context=new Rt(n,l),r=null,Le(t,function(e){if("AppInsightsChannelPlugin"===e.identifier)return r=e,-1}),c=r,s.context.appId=function(){return c?c._appId:null},s._extConfig=l},s.processTelemetry=function(e,n){var t,o,r,i;y(e)||(n=s._getTelCtx(n),e.name===at.envelopeType&&n.diagLog().resetInternalMessageCount(),(r=s.context||{}).session&&"string"!=typeof s.context.session.id&&r.sessionManager&&r.sessionManager.update(),(t=r.user)&&!t.isUserCookieSet&&t.update(r.user.id),r=n,f(o=e,"tags",[]),f(o,"ext",{}),(i=s.context).applySessionContext(o,r),i.applyApplicationContext(o,r),i.applyDeviceContext(o,r),i.applyOperationContext(o,r),i.applyUserContext(o,r),i.applyOperatingSystemContxt(o,r),i.applyWebContext(o,r),i.applyLocationContext(o,r),i.applyInternalContext(o,r),i.cleanUp(o,r),t&&t.isNewUser&&(t.isNewUser=!1,o=new tn(I.SendBrowserInfoOnUserInit,(Je()||{}).userAgent||""),n.diagLog().logInternalMessage(C.CRITICAL,o)),s.processNext(e,n))}}),e}e.PropertiesPlugin=s,e.Session=It,e.SessionManager=yt,e.TelemetryContext=Rt,e.TelemetryTrace=kt;n=e,i="__esModule",P={value:!0},lt=Object.defineProperty;if(lt)try{return void lt(n,i,P)}catch(_t){}typeof P.value!==undefined&&(n[i]=P.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=applicationinsights-properties-js.min.js.map