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