@microsoft/applicationinsights-properties-js 2.7.2-nightly.2111-16 → 2.7.2-nightly.2111-17

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.2-nightly.2111-16
2
+ * Application Insights JavaScript SDK - Properties Plugin, 2.7.2-nightly.2111-17
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);if(e=e[A]||e[m]||(e[h]?e[h][m]:null))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,l,f,d,g,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)),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},(jn=v=v||{})[jn.CRITICAL=1]="CRITICAL",jn[jn.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){return e&&ve&&(e=he("__mockLocation"))?e: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){return z(e=r[e])?n:e}function a(e,n){var t,o=(t=r,(o=(o=Ne)||!0===t.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){if(n=new be(n,t,r=void 0!==r&&r,o),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;return void 0===t&&(t=!1),(e=u.getExtCfg(e,null))&&!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=n,n=(e||{}).logger,(e=rn[Je]||nn[Je])||(e=rn[Je]=rn(o,n),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",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,t=(t=he("crypto")||he("msCrypto"))&&t.getRandomValues?t.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}(),n=((hn=36969*(65535&hn)+(hn>>16)&gn)<<16)+(65535&(vn=18e3*(65535&vn)+(vn>>16)&gn))>>>0&gn|0,(n>>>=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=(n&&150<(n=Y(n.toString())).length&&(o=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)),o||n);if(a.length!==i){for(var s=0,u=a;t[u]!==undefined;)s++,u=a.substring(0,147)+(r="00"+s).substr(r.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}(Wn=fn=fn||{})[Wn.LocalStorage=0]="LocalStorage",Wn[Wn.SessionStorage=1]="SessionStorage",(Gn=qn=qn||{})[Gn.AI=0]="AI",Gn[Gn.AI_AND_W3C=1]="AI_AND_W3C",Gn[Gn.W3C=2]="W3C";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=(s=e,a&&Sn(s,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=""+Math.floor(s/6e4)%60,n=""+Math.floor(s/36e5)%24,o=Math.floor(s/864e5),s=1===(s=""+s%1e3).length?"00"+s:2===s.length?"0"+s:s,a=a.length<2?"0"+a:a,t=t.length<2?"0"+t:t,(0<o?o+".":"")+(n=n.length<2?"0"+n:n)+":"+t+":"+a+"."+s)),l.properties=xn(e,r),l.measurements=(u=e,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"),c=Fn("operation"),Wn=Fn("session"),qn=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:c("id"),operationName:c("name"),operationParentId:c("parentId"),operationRootId:c("rootId"),operationSyntheticSource:c("syntheticSource"),operationCorrelationVector:c("correlationVector"),sessionId:Wn("id"),sessionIsFirst:Wn("isFirst"),sessionIsNew:Wn("isNew"),userAccountAcquisitionDate:qn("accountAcquisitionDate"),userAccountId:qn("accountId"),userAgent:qn("userAgent"),userId:qn("id"),userStoreRegion:qn("storeRegion"),userAuthUserId:qn("authUserId"),userAnonymousUserAcquisitionDate:qn("anonUserAcquisitionDate"),userAuthenticatedUserAcquisitionDate:qn("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,e=[e.id,t,n],t=i<r?i/1e3:r/1e3,r=o.cookieDomain?o.cookieDomain():null;p.set(f(),e.join("|"),0<o.sessionExpirationMs()?t: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,t=!((s=(e=p.get(f()))&&J(e.split)||(e=bn(g,f()))?c(r,e):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=(t=u.automaticSession).id,n=t.acquisitionDate,t=t.renewalDate;kn(g,f(),[e,n,t].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.2-nightly.2111-16"};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){return 1===(e=""+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=(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)&&(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(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);if(e=e[A]||e[m]||(e[h]?e[h][m]:null))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,l,f,d,g,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)),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},(jn=v=v||{})[jn.CRITICAL=1]="CRITICAL",jn[jn.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){return e&&ve&&(e=he("__mockLocation"))?e: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){return z(e=r[e])?n:e}function a(e,n){var t,o=(t=r,(o=(o=Ne)||!0===t.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){if(n=new be(n,t,r=void 0!==r&&r,o),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;return void 0===t&&(t=!1),(e=u.getExtCfg(e,null))&&!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=n,n=(e||{}).logger,(e=rn[Je]||nn[Je])||(e=rn[Je]=rn(o,n),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",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,t=(t=he("crypto")||he("msCrypto"))&&t.getRandomValues?t.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}(),n=((hn=36969*(65535&hn)+(hn>>16)&gn)<<16)+(65535&(vn=18e3*(65535&vn)+(vn>>16)&gn))>>>0&gn|0,(n>>>=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=(n&&150<(n=Y(n.toString())).length&&(o=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)),o||n);if(a.length!==i){for(var s=0,u=a;t[u]!==undefined;)s++,u=a.substring(0,147)+(r="00"+s).substr(r.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}(Wn=fn=fn||{})[Wn.LocalStorage=0]="LocalStorage",Wn[Wn.SessionStorage=1]="SessionStorage",(Gn=qn=qn||{})[Gn.AI=0]="AI",Gn[Gn.AI_AND_W3C=1]="AI_AND_W3C",Gn[Gn.W3C=2]="W3C";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=(s=e,a&&Sn(s,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=""+Math.floor(s/6e4)%60,n=""+Math.floor(s/36e5)%24,o=Math.floor(s/864e5),s=1===(s=""+s%1e3).length?"00"+s:2===s.length?"0"+s:s,a=a.length<2?"0"+a:a,t=t.length<2?"0"+t:t,(0<o?o+".":"")+(n=n.length<2?"0"+n:n)+":"+t+":"+a+"."+s)),l.properties=xn(e,r),l.measurements=(u=e,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"),c=Fn("operation"),Wn=Fn("session"),qn=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:c("id"),operationName:c("name"),operationParentId:c("parentId"),operationRootId:c("rootId"),operationSyntheticSource:c("syntheticSource"),operationCorrelationVector:c("correlationVector"),sessionId:Wn("id"),sessionIsFirst:Wn("isFirst"),sessionIsNew:Wn("isNew"),userAccountAcquisitionDate:qn("accountAcquisitionDate"),userAccountId:qn("accountId"),userAgent:qn("userAgent"),userId:qn("id"),userStoreRegion:qn("storeRegion"),userAuthUserId:qn("authUserId"),userAnonymousUserAcquisitionDate:qn("anonUserAcquisitionDate"),userAuthenticatedUserAcquisitionDate:qn("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,e=[e.id,t,n],t=i<r?i/1e3:r/1e3,r=o.cookieDomain?o.cookieDomain():null;p.set(f(),e.join("|"),0<o.sessionExpirationMs()?t: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,t=!((s=(e=p.get(f()))&&J(e.split)||(e=bn(g,f()))?c(r,e):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=(t=u.automaticSession).id,n=t.acquisitionDate,t=t.renewalDate;kn(g,f(),[e,n,t].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.2-nightly.2111-17"};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){return 1===(e=""+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=(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)&&(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||{}));
6
6
  //# sourceMappingURL=applicationinsights-properties-js.min.js.map