@cloudcare/browser-logs 3.2.25 → 3.2.28

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 +1 @@
1
- !function(){"use strict";var e={log:"log",debug:"debug",info:"info",warn:"warn",error:"error"},t=console,n={};Object.keys(e).forEach((function(e){n[e]=t[e]}));var r,o="GUANCE Browser SDK:",i={debug:n.debug.bind(t,o),log:n.log.bind(t,o),info:n.info.bind(t,o),warn:n.warn.bind(t,o),error:n.error.bind(t,o)},s=!1;function a(e){s=e}function u(e){return function(){return c(e,this,arguments)}}function c(e,t,n){try{return e.apply(t,n)}catch(e){if(f(e),r)try{r(e)}catch(e){f(e)}}}function f(){var e=[].slice.call(arguments);s&&i.error.apply(null,["[MONITOR]"].concat(e))}function l(e,t){return function(){var n=[].slice.call(arguments);try{return e.apply(this,n)}catch(e){i.error(t,e)}}}function d(e){return d="function"==typeof Symbol&&"symbol"==typeof Symbol.iterator?function(e){return typeof e}:function(e){return e&&"function"==typeof Symbol&&e.constructor===Symbol&&e!==Symbol.prototype?"symbol":typeof e},d(e)}function p(){if("object"===("undefined"==typeof globalThis?"undefined":d(globalThis)))return globalThis;Object.defineProperty(Object.prototype,"_gc_temp_",{get:function(){return this},configurable:!0});var e=_gc_temp_;return delete Object.prototype._gc_temp_,"object"!==d(e)&&(e="object"===("undefined"==typeof self?"undefined":d(self))?self:"object"===("undefined"==typeof window?"undefined":d(window))?window:{}),e}function v(e,t){var n,r=p();return r.Zone&&"function"==typeof r.Zone.__symbol__&&(n=e[r.Zone.__symbol__(t)]),n||(n=e[t]),n}function g(e,t){return v(p(),"setTimeout")(u(e),t)}function y(e){v(p(),"clearTimeout")(e)}function m(e,t){return v(p(),"setInterval")(u(e),t)}function h(e){v(p(),"clearInterval")(e)}function b(e){return b="function"==typeof Symbol&&"symbol"==typeof Symbol.iterator?function(e){return typeof e}:function(e){return e&&"function"==typeof Symbol&&e.constructor===Symbol&&e!==Symbol.prototype?"symbol":typeof e},b(e)}var _=Array.prototype,w=(Function.prototype,Object.prototype),S=_.slice,x=w.toString,O=w.hasOwnProperty,k=_.forEach,C=Array.isArray,E=!1,T=function(e,t,n){if(null===e)return!1;if(k&&e.forEach===k)e.forEach(t,n);else if(e.length===+e.length){for(var r=0,o=e.length;r<o;r++)if(r in e&&t.call(n,e[r],r,e)===E)return!1}else for(var i in e)if(O.call(e,i)&&t.call(n,e[i],i,e)===E)return!1};function L(e){return T(S.call(arguments,1),(function(t){for(var n in t)Object.prototype.hasOwnProperty.call(t,n)&&(e[n]=t[n])})),e}var M=function(e){return T(S.call(arguments,1),(function(t){for(var n in t)void 0!==t[n]&&(e[n]=t[n])})),e},$=function(e){return T(S.call(arguments,1),(function(t){for(var n in t)void 0!==t[n]&&(D(t[n])&&D(e[n])?M(e[n],t[n]):e[n]=t[n])})),e},A=C||function(e){return"[object Array]"===x.call(e)},R=function(e){if(!e)return!1;try{return/^\s*\bfunction\b/.test(e)}catch(e){return!1}},P=function(e){var t=[];return null===e||T(e,(function(e){t[t.length]=e})),t},B=function(e){var t=[];return null===e||T(e,(function(e,n){t[t.length]=n})),t},j=function(e,t,n){if(e.filter)return e.filter(t);for(var r=[],o=0;o<e.length;o++)if(O.call(e,o)){var i=e[o];t.call(n,i,o,e)&&r.push(i)}return r},I=function(e,t,n){if(e.map)return e.map(t);for(var r=[],o=0;o<e.length;o++)if(O.call(e,o)){var i=e[o];r.push(t.call(n,i,o,e))}return r},U=function(e,t,n){if(e.some)return e.some(t);for(var r=!1,o=0;o<e.length;o++)if(O.call(e,o)){var i=e[o];if(t.call(n,i,o,e)){r=!0;break}}return r},D=function(e){return null!==e&&"[object Object]"===x.call(e)},N=function(e){if(D(e)){for(var t in e)if(O.call(e,t))return!1;return!0}return!1},q=function(e){return"[object String]"===x.call(e)},W=function(e){return"[object Boolean]"===x.call(e)},F=function(e){return"[object Number]"===x.call(e)&&/[\d\.]+/.test(String(e))},V=(Date.now,function(e,t,n){var r,o,i=!n||void 0===n.leading||n.leading,s=!n||void 0===n.trailing||n.trailing,a=!1,u=this;return{throttled:function(){a?r=arguments:(i?e.apply(u,arguments):r=arguments,a=!0,o=g((function(){s&&r&&e.apply(u,r),a=!1,r=void 0}),t))},cancel:function(){y(o),a=!1,r=void 0}}});function Q(e){return e?(parseInt(e,10)^16*Math.random()>>parseInt(e,10)/4).toString(16):"".concat(1e7,"-",1e3,"-",4e3,"-",8e3,"-",1e11).replace(/[018]/g,Q)}function H(e){return null===e?"null":Array.isArray(e)?"array":b(e)}function z(e,t,n){if(void 0===n&&(n=function(){if("undefined"!=typeof WeakSet){var e=new WeakSet;return{hasAlreadyBeenSeen:function(t){var n=e.has(t);return n||e.add(t),n}}}var t=[];return{hasAlreadyBeenSeen:function(e){var n=t.indexOf(e)>=0;return n||t.push(e),n}}}()),void 0===t)return e;if("object"!==b(t)||null===t)return t;if(t instanceof Date)return new Date(t.getTime());if(t instanceof RegExp){var r=t.flags||[t.global?"g":"",t.ignoreCase?"i":"",t.multiline?"m":"",t.sticky?"y":"",t.unicode?"u":""].join("");return new RegExp(t.source,r)}if(!n.hasAlreadyBeenSeen(t)){if(Array.isArray(t)){for(var o=Array.isArray(e)?e:[],i=0;i<t.length;++i)o[i]=z(o[i],t[i],n);return o}o="object"===H(e)?e:{};for(var s in t)Object.prototype.hasOwnProperty.call(t,s)&&(o[s]=z(o[s],t[s],n));return o}}function G(e){return z(void 0,e)}function J(){}var K,X=1e3,Z=6e4;function Y(e){return 0!==e&&100*Math.random()<=e}function ee(){return performance.now()}function te(){return{relative:ee(),timeStamp:ne()}}function ne(){return re()}function re(){return(new Date).getTime()}function oe(){return void 0===K&&(K=performance.timing.navigationStart),K}var ie=/([\w-]+)\s*=\s*([^;]+)/g;function se(e,t){for(var n=t.split(".");n.length;){var r=n.shift();if(!(e&&D(e)&&r in e&&O.call(e,r)))return;e=e[r]}return e}function ae(e,t){var n=e.charCodeAt(t-1);return n>=55296&&n<=56319?e.slice(0,t+1):e.slice(0,t)}function ue(e,t){return-1!==e.indexOf(t)}function ce(e){if(Array.from)return Array.from(e);var t=[];if(e instanceof Set)e.forEach((function(e){t.push(e)}));else for(var n=0;n<e.length;n++)t.push(e[n]);return t}function fe(e){return F(e)&&e>=0&&e<=100}var le,de=0,pe=1,ve=2,ge=3;function ye(){return be(le,le=function(e){var t;void 0===e&&(e=window);var n=e.navigator.userAgent;if(e.chrome||/HeadlessChrome/.test(n))return pe;if(0===(null===(t=e.navigator.vendor)||void 0===t?void 0:t.indexOf("Apple"))||/safari/i.test(n)&&!/chrome|android/i.test(n))return ve;if(e.document.documentMode)return de;return ge}())}function me(e){var t={};return T(e,(function(e,n){var r;t[(r=n,r.replace(/[A-Z]/g,(function(e,t){return(0!==t?"_":"")+e.toLowerCase()})).replace(/-/g,"_"))]=he(e)})),t}function he(e){return A(e)?I(e,(function(e){return he(e)})):"object"===b(e)&&null!==e?me(e):e}function be(e,t){return null!=e?e:t}function _e(e,t){return e.slice(0,t.length)===t}function we(e,t){var n=e.indexOf(t);n>=0&&e.splice(n,1)}function Se(){var e=[],t=function(t){e.push(t)>500&&e.splice(0,1)};return{add:t,remove:t,drain:function(t){e.forEach((function(e){e(t)})),e.length=0}}}var xe=1/0,Oe=null,ke=new Set;var Ce={navigator:"undefined"!=typeof window&&void 0!==window.navigator?window.navigator:{},infoMap:{engine:["WebKit","Trident","Gecko","Presto"],browser:["Safari","Chrome","Edge","IE","IE 11","IE 10","IE 9","IE 8","IE 7","Firefox","Firefox Focus","Chromium","Opera","Vivaldi","Yandex","Arora","Lunascape","QupZilla","Coc Coc","Kindle","Iceweasel","Konqueror","Iceape","SeaMonkey","Epiphany","360","360SE","360EE","UC","QQBrowser","QQ","Baidu","Maxthon","Sogou","LBBROWSER","2345Explorer","TheWorld","XiaoMi","Quark","Qiyu","Wechat",,"WechatWork","Taobao","Alipay","Weibo","Douban","Suning","iQiYi"],os:["Windows","Linux","Mac OS","Android","Ubuntu","FreeBSD","Debian","iOS","Windows Phone","BlackBerry","MeeGo","Symbian","Chrome OS","WebOS"],device:["Mobile","Tablet","iPad"]}},Ee={getMatchMap:u((function(e){return{Trident:e.indexOf("Trident")>-1||e.indexOf("NET CLR")>-1,Presto:e.indexOf("Presto")>-1,WebKit:e.indexOf("AppleWebKit")>-1,Gecko:e.indexOf("Gecko/")>-1,Safari:e.indexOf("Safari")>-1,Chrome:e.indexOf("Chrome")>-1||e.indexOf("CriOS")>-1,IE:e.indexOf("MSIE")>-1||e.indexOf("Trident")>-1,Edge:e.indexOf("Edge")>-1||e.indexOf("Edg")>-1,Firefox:e.indexOf("Firefox")>-1||e.indexOf("FxiOS")>-1,"Firefox Focus":e.indexOf("Focus")>-1,Chromium:e.indexOf("Chromium")>-1,Opera:e.indexOf("Opera")>-1||e.indexOf("OPR")>-1,Vivaldi:e.indexOf("Vivaldi")>-1,Yandex:e.indexOf("YaBrowser")>-1,Arora:e.indexOf("Arora")>-1,Lunascape:e.indexOf("Lunascape")>-1,QupZilla:e.indexOf("QupZilla")>-1,"Coc Coc":e.indexOf("coc_coc_browser")>-1,Kindle:e.indexOf("Kindle")>-1||e.indexOf("Silk/")>-1,Iceweasel:e.indexOf("Iceweasel")>-1,Konqueror:e.indexOf("Konqueror")>-1,Iceape:e.indexOf("Iceape")>-1,SeaMonkey:e.indexOf("SeaMonkey")>-1,Epiphany:e.indexOf("Epiphany")>-1,360:e.indexOf("QihooBrowser")>-1||e.indexOf("QHBrowser")>-1,"360EE":e.indexOf("360EE")>-1,"360SE":e.indexOf("360SE")>-1,UC:e.indexOf("UC")>-1||e.indexOf(" UBrowser")>-1,QQBrowser:e.indexOf("QQBrowser")>-1,QQ:e.indexOf("QQ/")>-1,Baidu:e.indexOf("Baidu")>-1||e.indexOf("BIDUBrowser")>-1,Maxthon:e.indexOf("Maxthon")>-1,Sogou:e.indexOf("MetaSr")>-1||e.indexOf("Sogou")>-1,LBBROWSER:e.indexOf("LBBROWSER")>-1,"2345Explorer":e.indexOf("2345Explorer")>-1,TheWorld:e.indexOf("TheWorld")>-1,XiaoMi:e.indexOf("MiuiBrowser")>-1,Quark:e.indexOf("Quark")>-1,Qiyu:e.indexOf("Qiyu")>-1,Wechat:e.indexOf("MicroMessenger")>-1,Taobao:e.indexOf("AliApp(TB")>-1,Alipay:e.indexOf("AliApp(AP")>-1,Weibo:e.indexOf("Weibo")>-1,Douban:e.indexOf("com.douban.frodo")>-1,Suning:e.indexOf("SNEBUY-APP")>-1,iQiYi:e.indexOf("IqiyiApp")>-1,Windows:e.indexOf("Windows")>-1,Linux:e.indexOf("Linux")>-1||e.indexOf("X11")>-1,"Mac OS":e.indexOf("Macintosh")>-1,Android:e.indexOf("Android")>-1||e.indexOf("Adr")>-1,Ubuntu:e.indexOf("Ubuntu")>-1,FreeBSD:e.indexOf("FreeBSD")>-1,Debian:e.indexOf("Debian")>-1,"Windows Phone":e.indexOf("IEMobile")>-1||e.indexOf("Windows Phone")>-1,BlackBerry:e.indexOf("BlackBerry")>-1||e.indexOf("RIM")>-1,MeeGo:e.indexOf("MeeGo")>-1,Symbian:e.indexOf("Symbian")>-1,iOS:e.indexOf("like Mac OS X")>-1,"Chrome OS":e.indexOf("CrOS")>-1,WebOS:e.indexOf("hpwOS")>-1,Mobile:e.indexOf("Mobi")>-1||e.indexOf("iPh")>-1||e.indexOf("480")>-1,Tablet:e.indexOf("Tablet")>-1||e.indexOf("Nexus 7")>-1,iPad:e.indexOf("iPad")>-1}})),matchInfoMap:u((function(e){var t=Ce.navigator.userAgent||"",n=Ee.getMatchMap(t);for(var r in Ce.infoMap)for(var o=0;o<Ce.infoMap[r].length;o++){var i=Ce.infoMap[r][o];n[i]&&(e[r]=i)}})),getOS:u((function(){return Ee.matchInfoMap(this),this.os||"Unknown"})),getOSVersion:u((function(){var e=this,t=Ce.navigator.userAgent||"";e.osVersion="",e.osMajor="";var n={Windows:function(){var e=t.replace(/^.*Windows NT ([\d.]+);.*$/,"$1");return{6.4:"10",6.3:"8.1",6.2:"8",6.1:"7","6.0":"Vista",5.2:"XP",5.1:"XP","5.0":"2000"}[e]||e},Android:function(){return t.replace(/^.*Android ([\d.]+);.*$/,"$1")},iOS:function(){return t.replace(/^.*OS ([\d_]+) like.*$/,"$1").replace(/_/g,".")},Debian:function(){return t.replace(/^.*Debian\/([\d.]+).*$/,"$1")},"Windows Phone":function(){return t.replace(/^.*Windows Phone( OS)? ([\d.]+);.*$/,"$2")},"Mac OS":function(){return t.replace(/^.*Mac OS X ([\d_]+).*$/,"$1").replace(/_/g,".")},WebOS:function(){return t.replace(/^.*hpwOS\/([\d.]+);.*$/,"$1")}};return n[e.os]&&(e.osVersion=n[e.os](),e.osVersion===t&&(e.osVersion="")),e.osVersion&&(e.osMajor=e.osVersion.split(".").length&&e.osVersion.split(".")[0]),{version:e.osVersion,osMajor:e.osMajor}})),getOrientationStatu:u((function(){return window.matchMedia("(orientation: portrait)").matches?"竖屏":"横屏"})),getDeviceType:u((function(){var e=this;return e.device="PC",Ee.matchInfoMap(e),e.device})),getNetwork:u((function(){var e=window.navigator.connection||window.navigator.mozConnection||window.navigator.webkitConnection,t="unknown",n=e?e.type||e.effectiveType:null;if(n&&"string"==typeof n)switch(n){case"bluetooth":case"cellular":case"slow-2g":case"2g":case"3g":t="cellular";break;case"none":t="none";break;case"ethernet":case"wifi":case"wimax":case"4g":t="wifi";break;case"other":case"unknown":t="unknown"}return t})),getLanguage:u((function(){var e;return this.language=((e=(Ce.navigator.browserLanguage||Ce.navigator.language||"").split("-"))[1]&&(e[1]=e[1].toUpperCase()),e.join("_")),this.language})),getTimeZone:u((function(){return Intl.DateTimeFormat().resolvedOptions().timeZone})),getBrowserInfo:u((function(){var e=this;Ee.matchInfoMap(e);var t=Ce.navigator.userAgent||"",n=function(e,t){var n=Ce.navigator.mimeTypes;for(var r in n)if(n[r][e]==t)return!0;return!1},r=Ee.getMatchMap(t),o=!1;if("undefined"!=typeof window&&window.chrome){var i=t.replace(/^.*Chrome\/([\d]+).*$/,"$1");i>36&&window.showModalDialog?o=!0:i>45&&(o=n("type","application/vnd.chromium.remoting-viewer"))}if(r.Baidu&&r.Opera&&(r.Baidu=!1),r.Mobile&&(r.Mobile=!(t.indexOf("iPad")>-1)),o&&(n("type","application/gameplugin")||Ce.navigator&&Ce.navigator.connection&&void 0===Ce.navigator.connection.saveData?r["360SE"]=!0:r["360EE"]=!0),r.IE||r.Edge)switch(window.screenTop-window.screenY){case 71:case 74:case 99:case 75:case 74:case 105:default:break;case 102:r["360EE"]=!0;break;case 104:r["360SE"]=!0}var s={Safari:function(){return t.replace(/^.*Version\/([\d.]+).*$/,"$1")},Chrome:function(){return t.replace(/^.*Chrome\/([\d.]+).*$/,"$1").replace(/^.*CriOS\/([\d.]+).*$/,"$1")},IE:function(){return t.replace(/^.*MSIE ([\d.]+).*$/,"$1").replace(/^.*rv:([\d.]+).*$/,"$1")},Edge:function(){return t.replace(/^.*Edge?\/([\d.]+).*$/,"$1")},Firefox:function(){return t.replace(/^.*Firefox\/([\d.]+).*$/,"$1").replace(/^.*FxiOS\/([\d.]+).*$/,"$1")},"Firefox Focus":function(){return t.replace(/^.*Focus\/([\d.]+).*$/,"$1")},Chromium:function(){return t.replace(/^.*Chromium\/([\d.]+).*$/,"$1")},Opera:function(){return t.replace(/^.*Opera\/([\d.]+).*$/,"$1").replace(/^.*OPR\/([\d.]+).*$/,"$1")},Vivaldi:function(){return t.replace(/^.*Vivaldi\/([\d.]+).*$/,"$1")},Yandex:function(){return t.replace(/^.*YaBrowser\/([\d.]+).*$/,"$1")},Arora:function(){return t.replace(/^.*Arora\/([\d.]+).*$/,"$1")},Lunascape:function(){return t.replace(/^.*Lunascape[\/\s]([\d.]+).*$/,"$1")},QupZilla:function(){return t.replace(/^.*QupZilla[\/\s]([\d.]+).*$/,"$1")},"Coc Coc":function(){return t.replace(/^.*coc_coc_browser\/([\d.]+).*$/,"$1")},Kindle:function(){return t.replace(/^.*Version\/([\d.]+).*$/,"$1")},Iceweasel:function(){return t.replace(/^.*Iceweasel\/([\d.]+).*$/,"$1")},Konqueror:function(){return t.replace(/^.*Konqueror\/([\d.]+).*$/,"$1")},Iceape:function(){return t.replace(/^.*Iceape\/([\d.]+).*$/,"$1")},SeaMonkey:function(){return t.replace(/^.*SeaMonkey\/([\d.]+).*$/,"$1")},Epiphany:function(){return t.replace(/^.*Epiphany\/([\d.]+).*$/,"$1")},360:function(){return t.replace(/^.*QihooBrowser\/([\d.]+).*$/,"$1")},"360SE":function(){return{63:"10.0",55:"9.1",45:"8.1",42:"8.0",31:"7.0",21:"6.3"}[t.replace(/^.*Chrome\/([\d]+).*$/,"$1")]||""},"360EE":function(){return{69:"11.0",63:"9.5",55:"9.0",50:"8.7",30:"7.5"}[t.replace(/^.*Chrome\/([\d]+).*$/,"$1")]||""},Maxthon:function(){return t.replace(/^.*Maxthon\/([\d.]+).*$/,"$1")},QQBrowser:function(){return t.replace(/^.*QQBrowser\/([\d.]+).*$/,"$1")},QQ:function(){return t.replace(/^.*QQ\/([\d.]+).*$/,"$1")},Baidu:function(){return t.replace(/^.*BIDUBrowser[\s\/]([\d.]+).*$/,"$1")},UC:function(){return t.replace(/^.*UC?Browser\/([\d.]+).*$/,"$1")},Sogou:function(){return t.replace(/^.*SE ([\d.X]+).*$/,"$1").replace(/^.*SogouMobileBrowser\/([\d.]+).*$/,"$1")},LBBROWSER:function(){var e="";t.indexOf("LieBaoFast")>-1&&(e=t.replace(/^.*LieBaoFast\/([\d.]+).*$/,"$1"));var n=t.replace(/^.*Chrome\/([\d]+).*$/,"$1");return e||{57:"6.5",49:"6.0",46:"5.9",42:"5.3",39:"5.2",34:"5.0",29:"4.5",21:"4.0"}[n]||""},"2345Explorer":function(){return t.replace(/^.*2345Explorer\/([\d.]+).*$/,"$1")},TheWorld:function(){return t.replace(/^.*TheWorld ([\d.]+).*$/,"$1")},XiaoMi:function(){return t.replace(/^.*MiuiBrowser\/([\d.]+).*$/,"$1")},Quark:function(){return t.replace(/^.*Quark\/([\d.]+).*$/,"$1")},Qiyu:function(){return t.replace(/^.*Qiyu\/([\d.]+).*$/,"$1")},Wechat:function(){return t.replace(/^.*MicroMessenger\/([\d.]+).*$/,"$1")},WechatWork:function(){return t.replace(/^.*wxwork\/([\d.]+).*$/,"$1")},Taobao:function(){return t.replace(/^.*AliApp\(TB\/([\d.]+).*$/,"$1")},Alipay:function(){return t.replace(/^.*AliApp\(AP\/([\d.]+).*$/,"$1")},Weibo:function(){return t.replace(/^.*weibo__([\d.]+).*$/,"$1")},Douban:function(){return t.replace(/^.*com.douban.frodo\/([\d.]+).*$/,"$1")},Suning:function(){return t.replace(/^.*SNEBUY-APP([\d.]+).*$/,"$1")},iQiYi:function(){return t.replace(/^.*IqiyiVersion\/([\d.]+).*$/,"$1")}};return e.browserVersion="",e.browserMajor="",s[e.browser]&&(e.browserVersion=s[e.browser](),e.browserVersion==t&&(e.browserVersion="")),"Chrome"==e.browser&&t.match(/\S+Browser/)&&(e.browser=t.match(/\S+Browser/)[0],e.version=t.replace(/^.*Browser\/([\d.]+).*$/,"$1")),"Edge"==e.browser&&(e.version>"75"?e.engine="Blink":e.engine="EdgeHTML"),("Chrome"==e.browser&&parseInt(e.browserVersion)>27||r.Chrome&&"WebKit"==e.engine&&parseInt(e.browserVersion)>27||"Opera"==e.browser&&parseInt(e.version)>12||"Yandex"==e.browser)&&(e.engine="Blink"),e.browserVersion&&(e.browserMajor=e.browserVersion.split(".").length&&this.browserVersion.split(".")[0]),{browser:e.browser,browserVersion:e.browserVersion,engine:e.engine,browserMajor:e.browserMajor}})),getGeoPostion:u((function(e){navigator&&navigator.geolocation&&navigator.geolocation.getCurrentPosition((function(t){e(t)}),(function(e){i.warn(e)}))}))},Te={};"undefined"!=typeof window&&(Te={os:Ee.getOS(),osVersion:Ee.getOSVersion().version,osVersionMajor:Ee.getOSVersion().osMajor,browser:Ee.getBrowserInfo().browser,browserVersion:Ee.getBrowserInfo().browserVersion,browserVersionMajor:Ee.getBrowserInfo().browserMajor,screenSize:window.screen.width+"*"+window.screen.height,networkType:Ee.getNetwork(),device:Ee.getDeviceType(),timeZone:Ee.getTimeZone()});var Le=Te,Me="beforeunload",$e="click",Ae="keydown",Re="scroll",Pe="touchstart",Be="visibilitychange",je="freeze",Ie="resume",Ue="securitypolicyviolation",De="storage",Ne="action",qe="error",We="long_task",Fe="view",Ve="resource",Qe="logger",He={FETCH:"fetch",XHR:"xhr"},ze="handled",Ge="unhandled",Je="Uncaught",Ke="Provided";function Xe(e){return Xe="function"==typeof Symbol&&"symbol"==typeof Symbol.iterator?function(e){return typeof e}:function(e){return e&&"function"==typeof Symbol&&e.constructor===Symbol&&e!==Symbol.prototype?"symbol":typeof e},Xe(e)}function Ze(e,t,n){if("object"!==Xe(e)||null===e)return JSON.stringify(e);var r=Ye(Object.prototype),o=Ye(Array.prototype),i=Ye(Object.getPrototypeOf(e)),s=Ye(e);try{return JSON.stringify(e,t,n)}catch(e){return"<error: unable to serialize object>"}finally{r(),o(),i(),s()}}function Ye(e){var t=e,n=t.toJSON;return n?(delete t.toJSON,function(){t.toJSON=n}):J}function et(e){return et="function"==typeof Symbol&&"symbol"==typeof Symbol.iterator?function(e){return typeof e}:function(e){return e&&"function"==typeof Symbol&&e.constructor===Symbol&&e!==Symbol.prototype?"symbol":typeof e},et(e)}var tt="?";function nt(e){var t=[],n=lt(e,"stack"),r=String(e);return n&&n.startsWith(r)&&(n=n.slice(r.length)),n&&T(n.split("\n"),(function(e){var n=function(e){var t=it.exec(e);if(!t)return;var n=t[2]&&0===t[2].indexOf("native"),r=t[2]&&0===t[2].indexOf("eval"),o=st.exec(t[2]);r&&o&&(t[2]=o[1],t[3]=o[2],t[4]=o[3]);return{args:n?[t[2]]:[],column:t[4]?+t[4]:void 0,func:t[1]||tt,line:t[3]?+t[3]:void 0,url:n?void 0:t[2]}}(e)||function(e){var t=at.exec(e);if(!t)return;return{args:[],column:t[3]?+t[3]:void 0,func:tt,line:t[2]?+t[2]:void 0,url:t[1]}}(e)||function(e){var t=ut.exec(e);if(!t)return;return{args:[],column:t[4]?+t[4]:void 0,func:t[1]||tt,line:+t[3],url:t[2]}}(e)||function(e){var t=ct.exec(e);if(!t)return;var n=t[3]&&t[3].indexOf(" > eval")>-1,r=ft.exec(t[3]);n&&r&&(t[3]=r[1],t[4]=r[2],t[5]=void 0);return{args:t[2]?t[2].split(","):[],column:t[5]?+t[5]:void 0,func:t[1]||tt,line:t[4]?+t[4]:void 0,url:t[3]}}(e);n&&(!n.func&&n.line&&(n.func=tt),t.push(n))})),{message:lt(e,"message"),name:lt(e,"name"),stack:t}}var rt="((?:file|https?|blob|chrome-extension|electron|native|eval|webpack|<anonymous>|\\w+\\.|\\/).*?)",ot="(?::(\\d+))",it=new RegExp("^\\s*at (.*?) ?\\("+rt+ot+"?"+ot+"?\\)?\\s*$","i"),st=new RegExp("\\((\\S*)"+ot+ot+"\\)");var at=new RegExp("^\\s*at ?"+rt+ot+"?"+ot+"??\\s*$","i");var ut=/^\s*at (?:((?:\[object object\])?.+) )?\(?((?:file|ms-appx|https?|webpack|blob):.*?):(\d+)(?::(\d+))?\)?\s*$/i;var ct=/^\s*(.*?)(?:\((.*?)\))?(?:^|@)((?:file|https?|blob|chrome|webpack|resource|capacitor|\[native).*?|[^@]*bundle|\[wasm code\])(?::(\d+))?(?::(\d+))?\s*$/i,ft=/(\S+) line (\d+)(?: > eval line \d+)* > eval/i;function lt(e,t){if("object"===et(e)&&e&&t in e){var n=e[t];return"string"==typeof n?n:void 0}}var dt=/^(?:[Uu]ncaught (?:exception: )?)?(?:((?:Eval|Internal|Range|Reference|Syntax|Type|URI|)Error): )?([\s\S]*)$/;function pt(e){var t=function(e){return Lt(window,"onerror",(function(t){var n,r=t.parameters,o=r[0],i=r[1],s=r[2],a=r[3],u=r[4];if(u instanceof Error)n=nt(u);else{var c={url:i,column:a,line:s},f=function(e){var t,n;if("[object String]"==={}.toString.call(e)){var r=dt.exec(e);r&&(t=r[1],n=r[2])}return{name:t,message:n}}(o);n={name:f.name,message:f.message,stack:[c]}}e(n,be(u,o))}))}(e),n=function(e){return Lt(window,"onunhandledrejection",(function(t){var n=t.parameters[0].reason||"Empty reason",r=nt(n);e(r,n)}))}(e);return{stop:function(){t.stop(),n.stop()}}}var vt=1024,gt=/[^\u0000-\u007F]/;function yt(e){return gt.test(e)?void 0!==window.TextEncoder?(new TextEncoder).encode(e).length:new Blob([e]).size:e.length}function mt(e){return mt="function"==typeof Symbol&&"symbol"==typeof Symbol.iterator?function(e){return typeof e}:function(e){return e&&"function"==typeof Symbol&&e.constructor===Symbol&&e!==Symbol.prototype?"symbol":typeof e},mt(e)}function ht(e,t){void 0===t&&(t=225280);var n=Ye(Object.prototype),r=Ye(Array.prototype),o=[],i=new WeakMap,s=bt(e,"$",void 0,o,i),a=JSON.stringify(s)&&JSON.stringify(s).length||0;if(!(a>t)){for(;o.length>0&&a<t;){var u=o.shift(),c=0;if(Array.isArray(u.source))for(var f=0;f<u.source.length;f++){if(a+=void 0!==(l=bt(u.source[f],u.path,f,o,i))?JSON.stringify(l).length:4,a+=c,c=1,a>t){wt(t,"truncated",e);break}u.target[f]=l}else for(var f in u.source)if(Object.prototype.hasOwnProperty.call(u.source,f)){var l;if(void 0!==(l=bt(u.source[f],u.path,f,o,i))&&(a+=JSON.stringify(l).length+c+f.length+3,c=1),a>t){wt(t,"truncated",e);break}u.target[f]=l}}return n(),r(),s}wt(t,"discarded",e)}function bt(e,t,n,r,o){var i=function(e){var t=e;if(t&&"function"==typeof t.toJSON)try{return t.toJSON()}catch(e){}return e}(e);if(!i||"object"!==mt(i))return function(e){if("bigint"==typeof e)return"[BigInt] "+e.toString();if("function"==typeof e)return"[Function] "+e.name||0;if("symbol"===mt(e))return"[Symbol] "+e.description||0;return e}(i);var s=_t(i);if("[Object]"!==s&&"[Array]"!==s&&"[Error]"!==s)return s;var a=e;if(o.has(a))return"[Reference seen at "+o.get(a)+"]";var u=void 0!==n?t+"."+n:t,c=Array.isArray(i)?[]:{};return o.set(a,u),r.push({source:i,target:c,path:u}),c}function _t(e){try{if(e instanceof Event)return{type:(n=e).type,isTrusted:n.isTrusted,currentTarget:n.currentTarget?_t(n.currentTarget):null,target:n.target?_t(n.target):null};if(e instanceof RegExp)return"[RegExp] ".concat(e.toString());var t=Object.prototype.toString.call(e).match(/\[object (.*)\]/);if(t&&t[1])return"["+t[1]+"]"}catch(e){}var n;return"[Unserializable]"}function wt(e,t,n){i.warn("The data provided has been "+t+" as it is over the limit of "+e+" characters:",n)}var St="No stack, consider using an instance of Error",xt={AGENT:"agent",CONSOLE:"console",NETWORK:"network",SOURCE:"source",LOGGER:"logger",CUSTOM:"custom"};function Ot(e){var t=e.stackTrace,n=e.originalError,r=e.handlingStack,o=e.startClocks,i=e.nonErrorPrefix,s=e.source,a=e.handling,u=n instanceof Error,c=function(e,t,n,r){return e&&e.message&&e&&e.name?e.message:t?"Empty message":n+" "+Ze(ht(r))}(t,u,i,n),f=function(e,t){if(void 0===t)return!1;if(e)return!0;return t.stack.length>0&&(t.stack.length>1||void 0!==t.stack[0].url)}(u,t)?Ct(t):St,l=u?Tt(n,s):void 0;return{startClocks:o,source:s,handling:a,originalError:n,message:c,stack:f,handlingStack:r,type:t&&t.name,causes:l}}function kt(){var e,t=new Error;if(!t.stack)try{throw t}catch(e){}return c((function(){var n=nt(t);n.stack=n.stack.slice(2),e=Ct(n)})),e}function Ct(e){var t=Et(e);return T(e.stack,(function(e){var n="?"===e.func?"<anonymous>":e.func,r=e.args&&e.args.length>0?"("+e.args.join(", ")+")":"",o=e.line?":"+e.line:"",i=e.line&&e.column?":"+e.column:"";t+="\n at "+n+r+" @ "+e.url+o+i})),t}function Et(e){return(e.name||"Error")+": "+e.message}function Tt(e,t){for(var n=e,r=[];n&&n.cause instanceof Error&&r.length<10;){var o=nt(n.cause);r.push({message:n.cause.message,source:t,type:o&&o.name,stack:o&&Ct(o)}),n=n.cause}return r.length?r:void 0}function Lt(e,t,n,r){var o=r&&r.computeHandlingStack,i=e[t];if("function"!=typeof i){if(!_e(t,"on"))return{stop:J};i=J}var s=!1,a=function(){if(s)return i.apply(this,arguments);var e,t=ce(arguments);c(n,null,[{target:this,parameters:t,onPostCall:function(t){e=t},handlingStack:o?kt():void 0}]);var r=i.apply(this,t);return e&&c(e,null,[r]),r};return e[t]=a,{stop:function(){s=!0,e[t]===a&&(e[t]=i)}}}var Mt=function(e){this.observers=[],this.onLastUnsubscribe=void 0,this.onFirstSubscribe=e};Mt.prototype={subscribe:function(e){this.observers.push(e),1===this.observers.length&&this.onFirstSubscribe&&(this.onLastUnsubscribe=this.onFirstSubscribe(this)||void 0);var t=this;return{unsubscribe:function(){t.observers=j(t.observers,(function(t){return e!==t})),!t.observers.length&&t.onLastUnsubscribe&&t.onLastUnsubscribe()}}},notify:function(e){T(this.observers,(function(t){t(e)}))}};var $t=Mt;function At(){var e=[].slice.call(arguments);return new $t((function(t){var n=I(e,(function(e){return e.subscribe((function(e){return t.notify(e)}))}));return function(){return T(n,(function(e){return e.unsubscribe()}))}}))}var Rt={};function Pt(t){var n=I(t,(function(t){return Rt[t]||(Rt[t]=function(t){return new $t((function(n){var r=console[t];return console[t]=function(){var o=[].slice.call(arguments);r.apply(console,arguments);var i=kt();c((function(){n.notify(function(t,n,r){var o,i=I(t,(function(e){return function(e){if("string"==typeof e)return e;if(e instanceof Error)return Et(nt(e));return Ze(e,void 0,2)}(e)})).join(" ");if(n===e.error){var s=function(e,t){for(var n=0;n<e.length;n+=1){var r=e[n];if(t(r,n,e))return r}}(t,(function(e){return e instanceof Error}));o={stack:s?Ct(nt(s)):void 0,causes:s?Tt(s,"console"):void 0,startClocks:te(),message:i,source:xt.CONSOLE,handling:ze,handlingStack:r}}return{api:n,message:i,error:o,handlingStack:r}}(o,t,i))}))},function(){console[t]=r}}))}(t)),Rt[t]}));return At.apply(this,n)}function Bt(e,t,n,r){return jt(e,[t],n,r)}function jt(e,t,n,r){var o=u(r&&r.once?function(e){a(),n(e)}:n);r=r&&r.passive?{capture:r.capture,passive:r.passive}:r&&r.capture;var i=window.EventTarget&&e instanceof EventTarget?window.EventTarget.prototype:e,s=v(i,"addEventListener");T(t,(function(t){s.call(e,t,o,r)}));var a=function(){var n=v(i,"removeEventListener");T(t,(function(t){n.call(e,t,o,r)}))};return{stop:a}}var It={intervention:"intervention",deprecation:"deprecation",cspViolation:"csp_violation"};function Ut(e,t){var n=[];ue(t,It.cspViolation)&&n.push(new $t((function(e){return Bt(document,Ue,(function(t){e.notify(function(e){var t="'"+e.blockedURI+"' blocked by '"+e.effectiveDirective+"' directive";return Dt({type:e.effectiveDirective,message:It.cspViolation+": "+t,originalError:e,csp:{disposition:e.disposition},stack:Nt(e.effectiveDirective,e.originalPolicy?"".concat(t,' of the policy "').concat(ae(e.originalPolicy,100),'"'):"no policy",e.sourceFile,e.lineNumber,e.columnNumber)})}(t))})).stop})));var r=j(t,(function(e){return e!==It.cspViolation}));return r.length&&n.push(function(e){return new $t((function(t){if(window.ReportingObserver){var n=u((function(e){T(e,(function(e){t.notify(function(e){var t=e.body,n=e.type;return Dt({type:t.id,message:n+": "+t.message,originalError:e,stack:Nt(t.id,t.message,t.sourceFile,t.lineNumber,t.columnNumber)})}(e))}))})),r=new window.ReportingObserver(n,{types:e,buffered:!0});return r.observe(),function(){r.disconnect()}}}))}(r)),At.apply(this,n)}function Dt(e){return L({startClocks:te(),source:ErrorSource.REPORT,handling:ErrorHandling.UNHANDLED},e)}function Nt(e,t,n,r,o){return n&&Ct({name:e,message:t,stack:[{func:"?",url:n,line:r,column:o}]})}var qt=function(){this._events=[],this.pendingEvents=[]};qt.prototype={emit:function(e){var t=[].slice.call(arguments,1);T(this._events,(function(n){if(n.type!==e)return!1;n.callback.apply(n.context,t)}))},on:function(e,t,n){"function"==typeof t&&this._events.push({type:e,callback:t,context:n||this})}};new qt;var Wt,Ft="RAW_LOG_COLLECTED",Vt="LOG_COLLECTED";function Qt(){this.callbacks={}}function Ht(e){return zt(e,function(e){if(e.origin&&"null"!==e.origin)return e.origin;var t=e.host.replace(/(:80|:443)$/,"");return e.protocol+"//"+t}(window.location)).href}function zt(e,t){if(function(){if(void 0!==Wt)return Wt;try{var e=new URL("http://test/path");return Wt="http://test/path"===e.href}catch(e){Wt=!1}return Wt}())return void 0!==t?new URL(e,t):new URL(e);if(void 0===t&&!/:/.test(e))throw new Error("Invalid URL: "+e);var n=document,r=n.createElement("a");if(void 0!==t){var o=(n=document.implementation.createHTMLDocument("")).createElement("base");o.href=t,n.head.appendChild(o),n.body.appendChild(r)}return r.href=e,r}Qt.prototype={notify:function(e,t){var n=this.callbacks[e];n&&T(n,(function(e){e(t)}))},subscribe:function(e,t){this.callbacks[e]||(this.callbacks[e]=[]),this.callbacks[e].push(t);var n=this;return{unsubscribe:function(){n.callbacks[e]=j(n.callbacks[e],(function(e){return e!==t}))}}}};var Gt=navigator.userAgent.toLowerCase(),Jt=function(){return/iphone os/.test(Gt)};var Kt,Xt=/^\s+|\s+$/g,Zt={rum:"/rum",log:"/logging",sessionReplay:"/rum/replay"};function Yt(e,t){var n=Zt[t];if(!n)return"";var r=e.datakitOrigin||e.datakitUrl||e.site;0===r.indexOf("/")&&(r=location.origin+en(r));var o=r;return o=r.lastIndexOf("/")===r.length-1?en(r)+"v1/write"+n:en(r)+"/v1/write"+n,e.site&&e.clientToken&&(o=o+"?token="+e.clientToken+"&to_headless=true"),o}function en(e){return e.replace(Xt,"")}function tn(e,t){return"".concat(e,"_").concat(t&&t.crossSite?"cs1":"cs0","_").concat(t&&t.domain?"d1":"d0","_").concat(t&&t.secure?"sec1":"sec0","_").concat(t&&t.partitioned?"part1":"part0")}function nn(e,t,n,r){var o=new Date;o.setTime(o.getTime()+n);var i="expires="+o.toUTCString(),s=r&&r.crossSite?"none":"strict",a=r&&r.domain?";domain="+r.domain:"",u=r&&r.secure?";secure":"",c=r&&r.partitioned?";partitioned":"";document.cookie=tn(e,r)+"="+t+";"+i+";path=/;samesite="+s+a+u+c}function rn(e,t){return function(e,t){for(ie.lastIndex=0;;){var n=ie.exec(e);if(!n)break;if(n[1]===t)return n[2]}}(document.cookie,tn(e,t))}function on(e,t){nn(e,"",0,t)}var sn=144e5,an=9e5,un="_gc_s";function cn(e,t){return function(e){if(Array.isArray(e))return e}(e)||function(e,t){var n=null==e?null:"undefined"!=typeof Symbol&&e[Symbol.iterator]||e["@@iterator"];if(null!=n){var r,o,i,s,a=[],u=!0,c=!1;try{if(i=(n=n.call(e)).next,0===t){if(Object(n)!==n)return;u=!1}else for(;!(u=(r=i.call(n)).done)&&(a.push(r.value),a.length!==t);u=!0);}catch(e){c=!0,o=e}finally{try{if(!u&&null!=n.return&&(s=n.return(),Object(s)!==s))return}finally{if(c)throw o}}return a}}(e,t)||function(e,t){if(e){if("string"==typeof e)return fn(e,t);var n={}.toString.call(e).slice(8,-1);return"Object"===n&&e.constructor&&(n=e.constructor.name),"Map"===n||"Set"===n?Array.from(e):"Arguments"===n||/^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(n)?fn(e,t):void 0}}(e,t)||function(){throw new TypeError("Invalid attempt to destructure non-iterable instance.\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method.")}()}function fn(e,t){(null==t||t>e.length)&&(t=e.length);for(var n=0,r=Array(t);n<t;n++)r[n]=e[n];return r}var ln=/^([a-zA-Z]+)=([a-z0-9-]+)$/,dn="&";function pn(e){return N(e)}function vn(e){return void 0!==e.isExpired||!((void 0===(t=e).created||re()-Number(t.created)<sn)&&(void 0===t.expire||re()<Number(t.expire)));var t}function gn(e){return I((t=e,n=[],T(t,(function(e,t){n.push([t,e])})),n),(function(e){return e[0]+"="+e[1]})).join("&");var t,n}function yn(e){var t={};return function(e){return!!e&&(-1!==e.indexOf(dn)||ln.test(e))}(e)&&e.split(dn).forEach((function(e){var n=ln.exec(e);if(null!==n){var r=cn(n,3),o=r[1],i=r[2];t[o]=i}})),t}function mn(e){var t=function(e){var t={};t.secure=!!e.useSecureSessionCookie||!!e.usePartitionedCrossSiteSessionCookie||!!e.useCrossSiteSessionCookie,t.crossSite=!!e.usePartitionedCrossSiteSessionCookie||!!e.useCrossSiteSessionCookie,t.partitioned=!!e.usePartitionedCrossSiteSessionCookie,e.trackSessionAcrossSubdomains&&(t.domain=function(){if(void 0===Kt){for(var e="gc_site_test_".concat(Q()),t=window.location.hostname.split("."),n=t.pop();t.length&&!rn(e,{domain:n});)n="".concat(t.pop(),".").concat(n),nn(e,"test",X,{domain:n});on(e,{domain:n}),Kt=n}return Kt}());return t}(e);return function(e){if(void 0===document.cookie||null===document.cookie)return!1;try{var t="gc_cookie_test_".concat(Q()),n="test";nn(t,n,Z,e);var r=rn(t,e)===n;return on(t,e),r}catch(e){return!1}}(t)?{type:"Cookie",cookieOptions:t}:void 0}function hn(e){var t;return{isLockEnabled:ye()===pe,persistSession:(t=e,function(e){nn(un,gn(e),an,t)}),retrieveSession:bn(e),expireSession:function(){return function(e){nn(un,gn({isExpired:"1"}),sn,e)}(e)}}}function bn(e){return function(){return yn(rn(un,e))}}function _n(e){localStorage.setItem(un,gn(e))}function wn(){return yn(localStorage.getItem(un))}function Sn(){_n({isExpired:"1"})}var xn,On=[];function kn(e,t){var n=arguments.length>2&&void 0!==arguments[2]?arguments[2]:0,r=t.isLockEnabled,o=t.persistSession,i=t.expireSession,s=function(e){return o(L({},e,{lock:u}))},a=function(){var e=t.retrieveSession(),n=e.lock;return e.lock&&delete e.lock,{session:e,lock:n}};if(xn||(xn=e),e===xn)if(r&&n>=100)En(t);else{var u,c=a();if(r){if(c.lock)return void Cn(e,t,n);if(u=Q(),s(c.session),(c=a()).lock!==u)return void Cn(e,t,n)}var f=e.process(c.session);if(r&&(c=a()).lock!==u)Cn(e,t,n);else{if(f&&(vn(f)?i():(f.expire=String(re()+an),r?s(f):o(f))),r&&(!f||!vn(f))){if((c=a()).lock!==u)return void Cn(e,t,n);o(c.session),f=c.session}e.after&&e.after(f||c.session),En(t)}}else On.push(e)}function Cn(e,t,n){g((function(){kn(e,t,n+1)}),10)}function En(e){xn=void 0;var t=On.shift();t&&kn(t,e)}var Tn=X;function Ln(e){var t=mn(e);return!t&&e.allowFallbackToLocalStorage&&(t=function(){try{var e=Q(),t="".concat("_gc_test_").concat(e);localStorage.setItem(t,e);var n=localStorage.getItem(t);return localStorage.removeItem(t),e===n?{type:"LocalStorage"}:void 0}catch(e){return}}()),t}function Mn(e,t,n){var r,o=new $t,i=new $t,s=new $t,a="Cookie"===e.type?hn(e.cookieOptions):{isLockEnabled:!1,persistSession:_n,retrieveSession:wn,expireSession:Sn},u=a.expireSession,c=m((function(){kn({process:function(e){return vn(e)?{isExpired:"1"}:void 0},after:p},a)}),Tn);v();var f=V((function(){kn({process:function(e){if(!pn(e)){var r=p(e);return function(e){if(pn(e))return!1;var r=n(e[t]),o=r.trackingType,i=r.isTracked;e[t]=o,delete e.isExpired,i&&!e.id&&(e.id=Q(),e.created=String(re()))}(r),r}},after:function(e){pn(e)||g()||function(e){r=e,o.notify()}(e),r=e}},a)}),Tn),l=f.throttled,d=f.cancel;function p(e){return vn(e)&&(e={isExpired:"1"}),g()&&(!function(e){return r.id!==e.id||r[t]!==e[t]}(e)?(s.notify({previousState:r,newState:e}),r=e):(r={isExpired:"1"},i.notify())),e}function v(){kn({process:function(e){if(pn(e))return{isExpired:"1"}},after:function(e){r=e}},a)}function g(){return void 0!==r[t]}return{expandOrRenewSession:l,expandSession:function(){kn({process:function(e){return g()?p(e):void 0}},a)},getSession:function(){return r||{}},renewObservable:o,expireObservable:i,sessionStateUpdateObservable:s,restartSession:v,expire:function(){d(),u(),p({isExpired:"1"})},stop:function(){h(c)},updateSessionState:function(e){kn({process:function(t){return L({},t,e)},after:p},a)}}}function $n(e){if(void 0===e.sampleRate||fe(e.sampleRate))if(void 0===e.sessionSampleRate||fe(e.sessionSampleRate)){if(void 0===e.telemetrySampleRate||fe(e.telemetrySampleRate)){var t=be(e.sessionSampleRate,e.sampleRate);return L({beforeSend:e.beforeSend&&l(e.beforeSend,"beforeSend threw an error:"),sessionStoreStrategyType:Ln(e),sessionSampleRate:be(t,100),service:e.service,version:e.version,env:e.env,telemetrySampleRate:be(e.telemetrySampleRate,100),telemetryEnabled:be(e.telemetryEnabled,!1),silentMultipleInit:!!e.silentMultipleInit,batchBytesLimit:16384,eventRateLimiterThreshold:3e3,maxTelemetryEventsPerPage:15,flushTimeout:3e4,batchMessagesLimit:50,messageBytesLimit:262144,resourceUrlLimit:5120,storeContextsToLocal:!!e.storeContextsToLocal,storeContextsKey:e.storeContextsKey,sendContentTypeByJson:!!e.sendContentTypeByJson,retryMaxSize:be(e.retryMaxSize,-1)},function(e){var t=function(e){return!1};"isIntakeUrl"in e&&R(e.isIntakeUrl)&&W(e.isIntakeUrl())&&(t=e.isIntakeUrl);var n=function(e){return!1};return"isServerError"in e&&R(e.isServerError)&&W(e.isServerError())&&(n=e.isServerError),{rumEndpoint:Yt(e,"rum"),logsEndpoint:Yt(e,"log"),sessionReplayEndPoint:Yt(e,"sessionReplay"),isIntakeUrl:t,isServerError:n}}(e))}i.error("Telemetry Sample Rate should be a number between 0 and 100")}else i.error("Sample Rate should be a number between 0 and 100");else i.error("Sample Rate should be a number between 0 and 100")}var An,Rn;function Pn(){return An||(An=new $t((function(e){if(window.fetch){var t=Lt(window,"fetch",(function(t){return function(e,t){var n=e.parameters,r=e.onPostCall,o=e.handlingStack,i=n[0],s=n[1],a=s&&s.method;void 0===a&&i instanceof Request&&(a=i.method);var c=void 0!==a?String(a).toUpperCase():"GET",f=i instanceof Request?i.url:Ht(String(i)),l=te(),d={state:"start",init:s,input:i,method:c,startClocks:l,url:f,handlingStack:o};t.notify(d),n[0]=d.input,n[1]=d.init,r((function(e){return function(e,t,n){var r=n,o=function(t){r.state="resolve",L(r,t),e.notify(r)};t.then(u((function(e){var t="";try{t=e.constructor===Response&&e.type||""}catch(e){t=""}o({response:e,responseType:t,status:e.status,isAborted:!1})})),u((function(e){o({status:0,isAborted:r.init&&r.init.signal&&r.init.signal.aborted||e instanceof DOMException&&e.code===DOMException.ABORT_ERR,error:e})})))}(t,e,d)}))}(t,e)}),{computeHandlingStack:!0});return t.stop}}))),An}var Bn=new WeakMap;function jn(){return Rn||(Rn=new $t((function(e){var t=Lt(XMLHttpRequest.prototype,"open",In),n=Lt(XMLHttpRequest.prototype,"send",(function(t){!function(e,t){var n=e.target,r=e.handlingStack,o=Bn.get(n);if(o){var i=o;i.state="start",i.startClocks=te(),i.isAborted=!1,i.xhr=n,i.handlingStack=r;var s=!1,a=Lt(n,"onreadystatechange",(function(){n.readyState===XMLHttpRequest.DONE&&u()})).stop,u=function(){if(c(),a(),!s){s=!0;var e,r=o;r.state="complete",r.duration=(e=i.startClocks.timeStamp,ne()-e),r.status=n.status,t.notify(L({},r))}},c=Bt(n,"loadend",u).stop;t.notify(i)}}(t,e)}),{computeHandlingStack:!0}),r=Lt(XMLHttpRequest.prototype,"abort",Un);return function(){t.stop(),n.stop(),r.stop()}}))),Rn}function In(e){var t=e.target,n=e.parameters[0],r=e.parameters[1];Bn.set(t,{state:"open",method:String(n).toUpperCase(),url:Ht(String(r))})}function Un(e){var t=e.target,n=Bn.get(t);n&&(n.isAborted=!0)}var Dn={HIDDEN:"visibility_hidden",UNLOADING:"before_unload",PAGEHIDE:"page_hide",FROZEN:"page_frozen"};var Nn={sdk_name:"_gc.sdk_name",sdk_version:"_gc.sdk_version",app_id:"application.id",env:"env",service:"service",version:"version",source:"source",userid:"user.id",user_email:"user.email",user_name:"user.name",session_id:"session.id",session_type:"session.type",session_sampling:"session.is_sampling",is_signin:"user.is_signin",os:"device.os",os_version:"device.os_version",os_version_major:"device.os_version_major",browser:"device.browser",browser_version:"device.browser_version",browser_version_major:"device.browser_version_major",screen_size:"device.screen_size",network_type:"device.network_type",time_zone:"device.time_zone",device:"device.device",view_id:"view.id",view_referrer:"view.referrer",view_url:"view.url",view_host:"view.host",view_path:"view.path",view_name:"view.name",view_path_group:"view.path_group"},qn={view_url_query:"view.url_query",action_id:"action.id",action_ids:"action.ids",view_in_foreground:"view.in_foreground",display:"display",session_has_replay:"session.has_replay",is_login:"user.is_login",page_states:"_gc.page_states",session_sample_rate:"_gc.configuration.session_sample_rate",session_replay_sample_rate:"_gc.configuration.session_replay_sample_rate",session_on_error_sample_rate:"_gc.configuration.session_on_error_sample_rate",session_replay_on_error_sample_rate:"_gc.configuration.session_replay_on_error_sample_rate",drift:"_gc.drift"},Wn={view:{type:Fe,tags:{view_loading_type:"view.loading_type",view_apdex_level:"view.apdex_level",view_privacy_replay_level:"privacy.replay_level"},fields:{sampled_for_replay:"session.sampled_for_replay",sampled_for_error_replay:"session.sampled_for_error_replay",sampled_for_error_session:"session.sampled_for_error_session",session_error_timestamp:"session.error_timestamp_for_session",is_active:"view.is_active",session_replay_stats:"_gc.replay_stats",session_is_active:"session.is_active",view_error_count:"view.error.count",view_resource_count:"view.resource.count",view_long_task_count:"view.long_task.count",view_action_count:"view.action.count",first_contentful_paint:"view.first_contentful_paint",largest_contentful_paint:"view.largest_contentful_paint",largest_contentful_paint_element_selector:"view.largest_contentful_paint_element_selector",cumulative_layout_shift:"view.cumulative_layout_shift",cumulative_layout_shift_time:"view.cumulative_layout_shift_time",cumulative_layout_shift_target_selector:"view.cumulative_layout_shift_target_selector",first_input_delay:"view.first_input_delay",loading_time:"view.loading_time",dom_interactive:"view.dom_interactive",dom_content_loaded:"view.dom_content_loaded",dom_complete:"view.dom_complete",load_event:"view.load_event",first_input_time:"view.first_input_time",first_input_target_selector:"view.first_input_target_selector",first_paint_time:"view.fpt",interaction_to_next_paint:"view.interaction_to_next_paint",interaction_to_next_paint_target_selector:"view.interaction_to_next_paint_target_selector",resource_load_time:"view.resource_load_time",time_to_interactive:"view.tti",dom:"view.dom",dom_ready:"view.dom_ready",time_spent:"view.time_spent",first_byte:"view.first_byte",frustration_count:"view.frustration.count",custom_timings:"view.custom_timings"}},resource:{type:Ve,tags:{trace_id:"_gc.trace_id",span_id:"_gc.span_id",resource_id:"resource.id",resource_status:"resource.status",resource_status_group:"resource.status_group",resource_method:"resource.method"},fields:{duration:"resource.duration",resource_size:"resource.size",resource_url:"resource.url",resource_url_host:"resource.url_host",resource_url_path:"resource.url_path",resource_url_path_group:"resource.url_path_group",resource_url_query:"resource.url_query",resource_delivery_type:"resource.delivery_type",resource_type:"resource.type",resource_protocol:"resource.protocol",resource_encode_size:"resource.encoded_body_size",resource_decode_size:"resource.decoded_body_size",resource_transfer_size:"resource.transfer_size",resource_render_blocking_status:"resource.render_blocking_status",resource_dns:"resource.dns",resource_tcp:"resource.tcp",resource_ssl:"resource.ssl",resource_ttfb:"resource.ttfb",resource_trans:"resource.trans",resource_redirect:"resource.redirect",resource_first_byte:"resource.firstbyte",resource_dns_time:"resource.dns_time",resource_download_time:"resource.download_time",resource_first_byte_time:"resource.first_byte_time",resource_connect_time:"resource.connect_time",resource_ssl_time:"resource.ssl_time",resource_redirect_time:"resource.redirect_time"}},error:{type:qe,tags:{error_id:"error.id",trace_id:"_gc.trace_id",span_id:"_gc.span_id",error_source:"error.source",error_type:"error.type",error_handling:"error.handling"},fields:{error_message:["string","error.message"],error_stack:["string","error.stack"],error_causes:["string","error.causes"],error_handling_stack:["string","error.handling_stack"]}},long_task:{type:We,tags:{long_task_id:"long_task.id"},fields:{duration:"long_task.duration",blocking_duration:"long_task.blocking_duration",first_ui_event_timestamp:"long_task.first_ui_event_timestamp",render_start:"long_task.render_start",style_and_layout_start:"long_task.style_and_layout_start",long_task_start_time:"long_task.start_time",scripts:["string","long_task.scripts"]}},action:{type:Ne,tags:{action_type:"action.type"},fields:{action_name:"action.target.name",duration:"action.loading_time",action_error_count:"action.error.count",action_resource_count:"action.resource.count",action_frustration_types:"action.frustration.type",action_long_task_count:"action.long_task.count",action_target:"_gc.action.target",action_position:"_gc.action.position"}},telemetry:{type:"telemetry",fields:{status:"telemetry.status",message:["string","telemetry.message"],type:"telemetry.type",error_stack:["string","telemetry.error.stack"],error_kind:["string","telemetry.error.kind"],connectivity:["string","telemetry.connectivity"],runtime_env:["string","telemetry.runtime_env"],usage:["string","telemetry.usage"],configuration:["string","telemetry.configuration"]}},browser_log:{type:Qe,tags:{error_source:"error.source",error_type:"error.type",error_resource_url:"http.url",error_resource_url_host:"http.url_host",error_resource_url_path:"http.url_path",error_resource_url_path_group:"http.url_path_group",error_resource_status:"http.status_code",error_resource_status_group:"http.status_group",error_resource_method:"http.method",action_id:"user_action.id",service:"service",status:"status"},fields:{message:["string","message"],error_message:["string","error.message"],error_stack:["string","error.stack"]}}},Fn=Z,Vn=sn,Qn=[];function Hn(e,t,n){var r=new $t,o=new $t,i=Mn(e.sessionStoreStrategyType,t,n);Qn.push((function(){return i.stop()}));var s,a=function(e){var t=e.expireDelay,n=e.maxEntries,r=[];function o(){for(var e=ee()-t;r.length>0&&r[r.length-1].endTime<e;)r.pop()}return Oe&&(Oe=m((function(){return o()}),6e4)),ke.add(o),{add:function(e,t){var o={value:e,startTime:t,endTime:xe,remove:function(){we(r,o)},close:function(e){o.endTime=e}};return n&&r.length>=n&&r.pop(),r.unshift(o),o},find:function(e,t){void 0===e&&(e=xe),void 0===t&&(t={returnInactive:!1});for(var n=0,o=r;n<o.length;n++){var i=o[n];if(i.startTime<=e){if(t.returnInactive||e<=i.endTime)return i.value;break}}},closeActive:function(e){var t=r[0];t&&t.endTime===xe&&t.close(e)},findAll:function(e,t){void 0===e&&(e=xe),void 0===t&&(t=0);var n=e+t;return r.filter((function(t){return t.startTime<=n&&e<=t.endTime})).map((function(e){return e.value}))},reset:function(){r=[]},stop:function(){ke.delete(o),0===ke.size&&Oe&&(h(Oe),Oe=null)}}}({expireDelay:Vn});function u(){return{id:i.getSession().id,trackingType:i.getSession()[t],hasError:!!i.getSession().hasError}}return Qn.push((function(){return a.stop()})),i.renewObservable.subscribe((function(){a.add(u(),ee()),r.notify()})),i.expireObservable.subscribe((function(){o.notify(),a.closeActive(ee())})),i.expandOrRenewSession(),a.add(u(),[0,oe()][0]),s=jt(window,[$e,Pe,Ae,Re],(function(){i.expandOrRenewSession()}),{capture:!0,passive:!0}).stop,Qn.push(s),function(e){var t=function(){"visible"===document.visibilityState&&e()},n=Bt(document,Be,t).stop;Qn.push(n);var r=m(t,Fn);Qn.push((function(){h(r)}))}((function(){return i.expandSession()})),function(e){var t=Bt(window,Ie,e,{capture:!0}).stop;Qn.push(t)}((function(){i.restartSession()})),{findSession:function(e,t){return a.find(e,t)},renewObservable:r,expireObservable:o,sessionStateUpdateObservable:i.sessionStateUpdateObservable,expire:i.expire,updateSessionState:i.updateSessionState}}var zn=3145728,Gn=X,Jn=0,Kn=1,Xn=2,Zn=0,Yn=1;function er(e,t,n,r,o){t.transportStatus===Jn&&0===t.queuedPayloads.size()&&t.bandwidthMonitor.canHandle(e)?nr(e,t,n,{onSuccess:function(){return rr(Zn,t,n,r,o)},onFailure:function(){t.queuedPayloads.enqueue(e),tr(t,n,r,o)}}):t.queuedPayloads.enqueue(e)}function tr(e,t,n,r){e.transportStatus===Xn&&g((function(){nr(e.queuedPayloads.first(),e,t,{onSuccess:function(){e.queuedPayloads.dequeue(),e.currentBackoffTime=Gn,rr(Yn,e,t,n,r)},onFailure:function(){e.currentBackoffTime=Math.min(256e3,2*e.currentBackoffTime),tr(e,t,n,r)}})}),e.currentBackoffTime)}function nr(e,t,n,r){var o=r.onSuccess,i=r.onFailure;t.bandwidthMonitor.add(e),n(e,(function(n){t.bandwidthMonitor.remove(e),!function(e,t,n){return!(t.retryMaxSize>-1&&n.retry&&n.retry.count>t.retryMaxSize)&&("opaque"!==e.type&&(0===e.status&&!navigator.onLine||408===e.status||429===e.status||e.status>=500))}(n,t,e)?(t.transportStatus=Jn,o()):(t.transportStatus=t.bandwidthMonitor.ongoingRequestCount>0?Kn:Xn,e.retry={count:e.retry?e.retry.count+1:1,lastFailureStatus:n.status},i())}))}function rr(e,t,n,r,o){e===Zn&&t.queuedPayloads.isFull()&&!t.queueFullReported&&(o({message:"Reached max "+r+" events size queued for upload: 3MiB",source:xt.AGENT,startClocks:te()}),t.queueFullReported=!0);var i=t.queuedPayloads;for(t.queuedPayloads=or();i.size()>0;)er(i.dequeue(),t,n,r,o)}function or(){var e=[];return{bytesCount:0,enqueue:function(t){this.isFull()||(e.push(t),this.bytesCount+=t.bytesCount)},first:function(){return e[0]},dequeue:function(){var t=e.shift();return t&&(this.bytesCount-=t.bytesCount),t},size:function(){return e.length},isFull:function(){return this.bytesCount>=zn}}}function ir(){var e,t=window.navigator;return{status:t.onLine?"connected":"not_connected",interfaces:t.connection&&t.connection.type?[t.connection.type]:void 0,effective_type:null===(e=t.connection)||void 0===e?void 0:e.effectiveType}}var sr="log",ar="configuration",ur="debug",cr="error",fr=["https://static.guance.com","http://localhost","<anonymous>"],lr="browser-logs-sdk",dr=Se(),pr=function(e){dr.add((function(){pr(e)}))};function vr(e,t){var n,o=new $t,i=new Set,s=t.telemetryEnabled&&Y(t.telemetrySampleRate),a={is_local_file:"file:"===window.location.protocol,is_worker:"WorkerGlobalScope"in self};return pr=function(r){var u=Ze(r);if(s&&i.size<t.maxTelemetryEventsPerPage&&!i.has(u)){var c=function(e,t,r){return $({type:"telemetry",date:ne(),service:e,version:"3.2.25",source:"browser",telemetry:$(t,{runtime_env:r,connectivity:ir()})},void 0!==n?n():{})}(e,r,a);o.notify(c),i.add(u)}},r=gr,{setContextProvider:function(e){n=e},observable:o,enabled:s}}function gr(e,t){pr(L({type:sr,status:cr},function(e){if(e instanceof Error){var t=nt(e);return{error:{kind:t.name,stack:Ct(yr(t))},message:t.message}}return{error:{stack:St},message:Je+" "+Ze(e)}}(e),t))}function yr(e){return e.stack=e.stack.filter((function(e){return!e.url||fr.some((function(t){return _e(e.url,t)}))})),e}function mr(e,t){return e?(e=e+(-1===e.indexOf("?")?"?":"&")+"precision=ms",t&&(e=e+"&encoding="+t),e):e}function hr(e,t,n,r){void 0===n&&(n=-1);var o=function(e){return{transportStatus:Jn,currentBackoffTime:Gn,bandwidthMonitor:{ongoingRequestCount:0,ongoingByteCount:0,canHandle:function(e){return 0===this.ongoingRequestCount||this.ongoingByteCount+e.bytesCount<=81920&&this.ongoingRequestCount<32},add:function(e){this.ongoingRequestCount+=1,this.ongoingByteCount+=e.bytesCount},remove:function(e){this.ongoingRequestCount-=1,this.ongoingByteCount-=e.bytesCount}},queuedPayloads:or(),queueFullReported:!1,retryMaxSize:e}}(n),i=function(n,r){return function(e,t,n,r){var o=n.data,i=n.bytesCount,s=mr(e,n.encoding),a=function(){try{return window.Request&&"keepalive"in new Request("http://a")}catch(e){return!1}}()&&i<t;if(a){var c={method:"POST",body:o,keepalive:!0,mode:"cors"};n.type&&(c.headers={"Content-Type":n.type}),fetch(s,c).then(u((function(e){"function"==typeof r&&r({status:e.status,type:e.type})})),u((function(){_r(s,n,r)})))}else _r(s,n,r)}(e,t,n,r)};return{send:function(t){er(t,o,i,e,r)},sendOnExit:function(n){!function(e,t,n){var r=n.data,o=n.bytesCount,i=mr(e,n.encoding),s=!!navigator.sendBeacon&&o<t;if(s)try{var a;if(a=n.type?new Blob([r],{type:n.type}):r,navigator.sendBeacon(i,a))return}catch(e){!function(e){br||(br=!0,gr(e))}(e)}_r(i,n)}(e,t,n)}}}var br=!1;function _r(e,t,n){var r=t.data,o=new XMLHttpRequest;o.open("POST",e,!0),r instanceof Blob?o.setRequestHeader("Content-Type",r.type):t.type&&o.setRequestHeader("Content-Type",t.type),Bt(o,"loadend",(function(){"function"==typeof n&&n({status:o.status})}),{once:!0}),o.send(r)}function wr(e){return wr="function"==typeof Symbol&&"symbol"==typeof Symbol.iterator?function(e){return typeof e}:function(e){return e&&"function"==typeof Symbol&&e.constructor===Symbol&&e!==Symbol.prototype?"symbol":typeof e},wr(e)}function Sr(e){if("object"===wr(e)&&e)e=Ze(e);else if(!q(e))return e;return String(e).replace(/[\s=,"]/g,(function(e){return"\\"+e}))}function xr(e,t){return"object"===wr(e)&&e?e=Ze(e):t&&(e=""+e),e}function Or(e){return'"'+e.replace(/\\/g,"\\\\").replace(/"/g,'\\"')+'"'}function kr(e){return"object"===wr(e)&&e?Or(Ze(e)):q(e)?Or(e):e}var Cr="custom_keys",Er=function(e){if(!e||!e.type)return{rowStr:"",rowData:void 0};var t={tags:{},fields:{}},n=!1,r="";return T(Wn,(function(o,i){if(o.type===e.type){r+=i+",",t.measurement=i;var s=[],a=M({},Nn,o.tags),u=["date","type",Cr];T(a,(function(n,r){var o=se(e,n);u.push(r),(o||F(o))&&(t.tags[r]=xr(o,!0),s.push(Sr(r)+"="+Sr(o)))}));var c=[],f=M({},qn,o.fields);if(T(f,(function(n,r){if(A(n)&&2===n.length){var o=n[1],i=se(e,o);u.push(r),null!=i&&(t.fields[r]=xr(i),c.push(Sr(r)+"="+kr(i)))}else if(q(n)){i=se(e,n);u.push(r),null!=i&&(t.fields[r]=xr(i),c.push(Sr(r)+"="+kr(i)))}})),e.context&&D(e.context)&&!N(e.context)){var l=[];T(e.context,(function(e,n){u.indexOf(n)>-1||(u.push(n),null!=e&&(l.push(n),t.fields[n]=xr(e),c.push(Sr(n)+"="+kr(e))))})),l.length&&(t.fields[Cr]=xr(l),c.push(Sr(Cr)+"="+kr(l)))}e.type===Qe&&T(e,(function(e,n){-1===u.indexOf(n)&&null!=e&&(t.fields[n]=xr(e),c.push(Sr(n)+"="+kr(e)))})),s.length&&(r+=s.join(",")),c.length&&(r+=" ",r+=c.join(","),n=!0),r=r+" "+e.date,t.time=e.date}})),{rowStr:n?r:"",rowData:n?t:void 0}};function Tr(e){var t=e.encoder,n=e.request,r=e.messageBytesLimit,o=e.sendContentTypeByJson,s=e.flushController,a={},u=s.flushObservable.subscribe((function(e){!function(e){var r=P(a).join(o?",":"\n");a={};var i=(u=e.reason,ue(P(Dn),u)),s=i?n.sendOnExit:n.send;var u;if(i&&t.isAsync){var f=t.finishSync();f.outputBytesCount&&s(Lr(f,o));var l=[f.pendingData,r].filter(Boolean).join("\n");l&&s({data:l,bytesCount:yt(l)})}else{if(r){var d=c([r],t.isEmpty());o&&(d+="]"),t.write(d)}else o&&t.write("]");t.finish((function(e){s(Lr(e))}))}}(e)}));function c(e){var t=arguments.length>1&&void 0!==arguments[1]&&arguments[1];return o?t?"["+e.join(","):","+e.join(","):t?e.join("\n"):"\n"+e.join("\n")}function f(e,n){var u=function(e){return o?Ze(Er(e).rowData):Er(e).rowStr}(e),f=t.estimateEncodedBytesCount(u);f>=r?i.warn("Discarded a message whose size was bigger than the maximum allowed size ".concat(r,"KB.")):(function(e){return void 0!==e&&void 0!==a[e]}(n)&&function(e){var n=a[e];delete a[e];var r=t.estimateEncodedBytesCount(n);s.notifyAfterRemoveMessage(r)}(n),function(e,n,r){s.notifyBeforeAddMessage(n),void 0!==r?(a[r]=e,s.notifyAfterAddMessage()):t.write(c([e],t.isEmpty()),(function(e){s.notifyAfterAddMessage(e-n)}))}(u,f,n))}return{flushController:s,add:f,upsert:f,stop:u.unsubscribe}}function Lr(e,t){return{data:"string"==typeof e.output?e.output:new Blob([e.output],{type:"text/plain"}),type:t?"application/json;UTF-8":void 0,bytesCount:e.outputBytesCount,encoding:e.encoding}}function Mr(e){var t=e.messagesLimit,n=e.bytesLimit,r=e.durationLimit,o=e.pageExitObservable,i=e.sessionExpireObservable;o.subscribe((function(e){return f(e.reason)})),i.subscribe((function(){return f("session_expire")}));var s,a=new $t((function(){return function(){pageExitSubscription.unsubscribe(),sessionExpireSubscription.unsubscribe()}})),u=0,c=0;function f(e){if(0!==c){var t=c,n=u;c=0,u=0,l(),a.notify({reason:e,messagesCount:t,bytesCount:n})}}function l(){y(s),s=void 0}return{flushObservable:a,getMessagesCount:function(){return c},notifyBeforeAddMessage:function(e){u+e>=n&&f("bytes_limit"),c+=1,u+=e,void 0===s&&(s=g((function(){f("duration_limit")}),r))},notifyAfterAddMessage:function(e){void 0===e&&(e=0),u+=e,c>=t?f("messages_limit"):u>=n&&f("bytes_limit")},notifyAfterRemoveMessage:function(e){u-=e,0===(c-=1)&&l()}}}function $r(e,t,n,r,o,i){void 0===i&&(i=Tr);var s=function(e,t){return i({encoder:t.encoder,request:hr(t.endpoint,e.batchBytesLimit,e.retryMaxSize,n),flushController:Mr({messagesLimit:e.batchMessagesLimit,bytesLimit:e.batchBytesLimit,durationLimit:e.flushTimeout,pageExitObservable:r,sessionExpireObservable:o}),messageBytesLimit:e.messageBytesLimit,sendContentTypeByJson:e.sendContentTypeByJson})}(e,t);return{flushObservable:s.flushController.flushObservable,add:function(e){s.add(e)},upsert:function(e,t){s.upsert(e,t)},stop:function(){s.stop()}}}function Ar(){return p().FTWebViewJavascriptBridge}function Rr(){var e=Ar();if(e)return{getCapabilities:function(){return JSON.parse(e.getCapabilities&&e.getCapabilities()||"[]")},getPrivacyLevel:function(){return e.getPrivacyLevel&&e.getPrivacyLevel()},getAllowedWebViewHosts:function(){return JSON.parse(e.getAllowedWebViewHosts&&e.getAllowedWebViewHosts()||"[]")},send:function(t,n,r){var o=r?{id:r}:void 0;e.sendEvent(JSON.stringify({name:t,data:n,view:o}))}}}function Pr(){var e,t=arguments.length>0&&void 0!==arguments[0]?arguments[0]:null===(e=p().location)||void 0===e?void 0:e.hostname,n=Ar();if(n&&void 0===n.getAllowedWebViewHosts)return!0;if(n&&n.getAllowedWebViewHosts&&(null===n.getAllowedWebViewHosts()||void 0===n.getAllowedWebViewHosts()))return!0;var r=Rr();return!!r&&r.getAllowedWebViewHosts().some((function(e){return t===e||t.endsWith(".".concat(e))}))}function Br(e){return Br="function"==typeof Symbol&&"symbol"==typeof Symbol.iterator?function(e){return typeof e}:function(e){return e&&"function"==typeof Symbol&&e.constructor===Symbol&&e!==Symbol.prototype?"symbol":typeof e},Br(e)}function jr(e,t){return function(e){if(Array.isArray(e))return e}(e)||function(e,t){var n=null==e?null:"undefined"!=typeof Symbol&&e[Symbol.iterator]||e["@@iterator"];if(null!=n){var r,o,i,s,a=[],u=!0,c=!1;try{if(i=(n=n.call(e)).next,0===t){if(Object(n)!==n)return;u=!1}else for(;!(u=(r=i.call(n)).done)&&(a.push(r.value),a.length!==t);u=!0);}catch(e){c=!0,o=e}finally{try{if(!u&&null!=n.return&&(s=n.return(),Object(s)!==s))return}finally{if(c)throw o}}return a}}(e,t)||function(e,t){if(e){if("string"==typeof e)return Ir(e,t);var n={}.toString.call(e).slice(8,-1);return"Object"===n&&e.constructor&&(n=e.constructor.name),"Map"===n||"Set"===n?Array.from(e):"Arguments"===n||/^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(n)?Ir(e,t):void 0}}(e,t)||function(){throw new TypeError("Invalid attempt to destructure non-iterable instance.\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method.")}()}function Ir(e,t){(null==t||t>e.length)&&(t=e.length);for(var n=0,r=Array(t);n<t;n++)r[n]=e[n];return r}function Ur(e,t){var n=Object.keys(e);if(Object.getOwnPropertySymbols){var r=Object.getOwnPropertySymbols(e);t&&(r=r.filter((function(t){return Object.getOwnPropertyDescriptor(e,t).enumerable}))),n.push.apply(n,r)}return n}function Dr(e,t,n){return(t=function(e){var t=function(e,t){if("object"!=Br(e)||!e)return e;var n=e[Symbol.toPrimitive];if(void 0!==n){var r=n.call(e,t||"default");if("object"!=Br(r))return r;throw new TypeError("@@toPrimitive must return a primitive value.")}return("string"===t?String:Number)(e)}(e,"string");return"symbol"==Br(t)?t:t+""}(t))in e?Object.defineProperty(e,t,{value:n,enumerable:!0,configurable:!0,writable:!0}):e[t]=n,e}function Nr(e,t,n){for(var r=function(e){for(var t=1;t<arguments.length;t++){var n=null!=arguments[t]?arguments[t]:{};t%2?Ur(Object(n),!0).forEach((function(t){Dr(e,t,n[t])})):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(n)):Ur(Object(n)).forEach((function(t){Object.defineProperty(e,t,Object.getOwnPropertyDescriptor(n,t))}))}return e}({},e),o=0,s=Object.entries(t);o<s.length;o++){var a=jr(s[o],2),u=a[0],c=a[1],f=c.required;"string"===c.type&&u in r&&(r[u]=String(r[u])),f&&!(u in e)&&i.warn("The property ".concat(u," of ").concat(n," context is required; context will not be sent to the intake."))}return r}function qr(){var e=arguments.length>0&&void 0!==arguments[0]?arguments[0]:"",t=arguments.length>1&&void 0!==arguments[1]?arguments[1]:{},n=t.customerDataTracker,r=t.propertiesConfig,o=void 0===r?{}:r,i={},s=new $t,a={getContext:function(){return G(i)},setContext:function(t){"object"===H(t)?(i=ht(Nr(t,o,e)),null==n||n.updateCustomerData(i)):a.clearContext(),s.notify()},setContextProperty:function(t,r){i[t]=ht(Nr(Dr({},t,r),o,e)[t]),null==n||n.updateCustomerData(i),s.notify()},removeContextProperty:function(t){delete i[t],null==n||n.updateCustomerData(i),Nr(i,o,e),s.notify()},clearContext:function(){i={},null==n||n.resetCustomerData(),s.notify()},changeObservable:s};return a}var Wr="user",Fr="global context",Vr="_gc_s",Qr=[];function Hr(e,t,n,r){var o=function(e,t,n){return e.storeContextsKey&&q(e.storeContextsKey)?Vr+"_"+t+"_"+n+"_"+e.storeContextsKey:Vr+"_"+t+"_"+n}(e,n,r);function i(){var e=localStorage.getItem(o);return null!==e?JSON.parse(e):{}}return Qr.push(Bt(window,De,(function(e){o===e.key&&t.setContext(i())}))),t.changeObservable.subscribe((function(){localStorage.setItem(o,JSON.stringify(t.getContext()))})),t.setContext($(i(),t.getContext())),t}var zr=0,Gr=2;function Jr(){var e=arguments.length>0&&void 0!==arguments[0]?arguments[0]:Gr,t=new Map,n=!1;function r(){if(!n&&e!==zr){var r=e===Gr?3072:16384,o=arguments.length>0&&void 0!==arguments[0]?arguments[0]:0;t.forEach((function(e){o+=e.getBytesCount()})),o>r&&(!function(e){i.warn("Customer data exceeds the recommended ".concat(e/vt,"KiB threshold."))}(r),n=!0)}}return{createDetachedTracker:function(){var e=Kr((function(){return r(e.getBytesCount())}));return e},getOrCreateTracker:function(e){return t.has(e)||t.set(e,Kr(r)),t.get(e)},setCompressionStatus:function(t){e===zr&&(e=t,r())},getCompressionStatus:function(){return e},stop:function(){t.forEach((function(e){return e.stop()})),t.clear()}}}function Kr(e){var t=0,n=V((function(n){t=yt(Ze(n)),e()}),200),r=n.throttled,o=n.cancel,i=function(){o(),t=0};return{updateCustomerData:function(e){N(e)?i():r(e)},resetCustomerData:i,getBytesCount:function(){return t},stop:function(){o()}}}function Xr(){var e="",t=0;return{isAsync:!1,isEmpty:function(){return!e},write:function(n,r){var o=yt(n);t+=o,e+=n,r&&r(o)},finish:function(e){e(this.finishSync())},finishSync:function(){var n={output:e,outputBytesCount:t,rawBytesCount:t,pendingData:""};return e="",t=0,n},estimateEncodedBytesCount:function(e){return e.length}}}function Zr(e){this.map=new WeakMap,e&&e.forEach((function(e){this.map.set(e,1)}))}function Yr(e,t){t.silentMultipleInit||i.error(e+" is already initialized.")}Zr.prototype.add=function(e){return this.map.set(e,1),this},Zr.prototype.delete=function(e){return this.map.delete(e)},Zr.prototype.has=function(e){return this.map.has(e)};var eo={ok:0,debug:1,info:2,notice:4,warn:5,error:6,critical:7,alert:8,emerg:9};function to(e){return{handleLog:function(t,r,o,i,s){var a=$(r.getContext(),t.context);if(no(t.status,io.console,r)&&function(e,t){var r=e.status,o=e.message;n[loggerToConsoleApiName[r]].call(globalConsole,o,t)}(t,a),no(t.status,io.http,r)){var u={rawLogsEvent:{date:s||ne(),message:t.message,status:t.status,origin:xt.LOGGER},messageContext:a,savedCommonContext:i};o&&(u.domainContext={handlingStack:o}),e.notify(Ft,u)}}}}function no(e,t,n){var r=n.getHandler(),o=A(r)?r:[r];return eo[e]>=eo[n.getLevel()]&&ue(o,t)}function ro(e,t){void 0===t&&(t={});var n=t.includeMessage||!1;return{stack:e.stack,kind:e.type,message:n?e.message:void 0,causes:e.causes,handling:e.handling}}var oo={ok:"ok",debug:"debug",info:"info",notice:"notice",warn:"warn",error:"error",critical:"critical",alert:"alert",emerg:"emerg"},io={console:"console",http:"http",silent:"silent"},so=B(oo);function ao(e,t,n,r,o,i){void 0===r&&(r=io.http),void 0===o&&(o=oo.debug),void 0===i&&(i={}),this.contextManager=qr("logger",{customerDataTracker:t}),this.handleLogStrategy=e,this.handlerType=r,this.level=o,this.contextManager.setContext(i),n&&this.contextManager.setContextProperty("logger",{name:n})}function uo(e){return function(t,n,r){var o;no(e,io.http,this)&&(o=kt()),this.logImplementation(t,n,e,r,o)}}ao.prototype={logImplementation:u((function(e,t,n,r,o){void 0===n&&(n=oo.info);var i,s=ht(t);if(null!=r){var a=Ot({stackTrace:r instanceof Error?nt(r):void 0,originalError:r,nonErrorPrefix:Ke,source:xt.LOGGER,handling:ze,startClocks:te()});i=$({error:ro(a,{includeMessage:!0})},s)}else i=s;this.handleLogStrategy({message:ht(e),context:i,status:n},this,o)})),log:function(e,t,n,r){var o;no(n,io.http,this)&&(o=kt()),this.logImplementation(e,t,n,r,o)},setContext:function(e){this.contextManager.setContext(e)},getContext:function(){return this.contextManager.getContext()},setContextProperty:function(e,t){this.contextManager.setContextProperty(e,t)},addContext:function(e,t){this.contextManager.setContextProperty(e,t)},removeContextProperty:function(e){this.contextManager.removeContextProperty(e)},removeContext:function(e){this.contextManager.removeContextProperty(e)},clearContext:function(){this.contextManager.clearContext()},setHandler:function(e){this.handlerType=e},getHandler:function(){return this.handlerType},setLevel:function(e){this.level=e},getLevel:function(){return this.level}},ao.prototype.ok=uo(oo.ok),ao.prototype.debug=uo(oo.debug),ao.prototype.info=uo(oo.info),ao.prototype.notice=uo(oo.notice),ao.prototype.warn=uo(oo.warn),ao.prototype.error=uo(oo.error),ao.prototype.critical=uo(oo.critical),ao.prototype.alert=uo(oo.alert),ao.prototype.emerg=uo(oo.emerg);var co={sdkVersion:"3.2.25",sdkName:"df_web_logs_sdk"};function fo(t){var n=function(e){return e.site||e.datakitOrigin||e.datakitUrl?!(e.site&&!e.clientToken&&(i.error("clientToken is not configured, no RUM data will be collected."),1)):(i.error("datakitOrigin or site is not configured, no RUM data will be collected."),!1)}(t);if(n){var r=$n(t),o=lo(t.forwardConsoleLogs,P(e),"Forward Console Logs"),s=lo(t.forwardReports,P(It),"Forward Reports");if(r&&o&&s)return t.forwardErrorsToLogs&&!ue(o,e.error)&&o.push(e.error),L({forwardErrorsToLogs:!1!==t.forwardErrorsToLogs,forwardConsoleLogs:o,forwardReports:s,requestErrorResponseLengthLimit:32768},r,co)}}function lo(e,t,n){return void 0===e?[]:"all"===e||A(e)&&function(e,t,n){if(e.every)return e.every(t);for(var r=!0,o=0;o<e.length;o++)if(O.call(e,o)){var i=e[o];if(!t.call(n,i,o,e)){r=!1;break}}return r}(e,(function(e){return ue(t,e)}))?"all"===e?t:function(e){for(var t,n=[],r={},o=0;o<e.length;o++)(t=e[o])in r||(r[t]=!0,n.push(t));return n}(e):void i.error(n+' should be "all" or an array with allowed values "'+t.join('", "')+'"')}function po(e,t){var n,r,o=Se();return{init:function(e){if(e)if(Pr()&&(e=function(e){return L({},e,{clientToken:"empty"})}(e)),n=e,r)Yr("DATAFLUX_LOGS",e);else{var s=fo(e);s&&(r=s,Pn().subscribe(J),function(){if(r&&n){var e=t(n,r);o.drain(e)}}())}else i.error("Missing configuration")},getInitConfiguration:function(){return n},getInternalContext:J,handleLog:function(t,n,r,i,s){void 0===i&&(i=e()),void 0===s&&(s=ne()),o.add((function(e){e.handleLog(t,n,r,i,s)}))}}}var vo="logs";var go="0",yo="1";function mo(e){var t=Hn(e,"logs",(function(t){return function(e,t){var n=function(e){return e===go||e===yo}(t)?t:ho(e);return{trackingType:n,isTracked:n===yo}}(e,t)}));return{findTrackedSession:function(e){var n=t.findSession(e);return n&&n.trackingType===yo?{id:n.id}:void 0},expireObservable:t.expireObservable}}function ho(e){return Y(e.sessionSampleRate)?yo:go}function bo(e,t,n,r,o){var i=so.concat(["custom"]),s={};T(i,(function(e){var n,r,i,a,u;s[e]=(n=e,r=t.eventRateLimiterThreshold,i=o,a=0,u=!1,{isLimitReached:function(){if(0===a&&g((function(){a=0}),Z),(a+=1)<=r||u)return u=!1,!1;if(a===r+1){u=!0;try{i({message:"Reached max number of "+n+"s by minute: "+r,source:xt.AGENT,startClocks:te()})}finally{u=!1}}return!0}})})),n.subscribe(Ft,(function(o){var i=o.rawLogsEvent,a=o.messageContext||void 0,u=o.savedCommonContext||void 0,c=o.domainContext,f=i.date-oe(),l=e.findTrackedSession(f);if(l){var d=u||r(),p=$({service:t.service||"browser",env:t.env||"",version:t.version||"",_gc:{sdkName:t.sdkName,sdkVersion:t.sdkVersion},session:{id:l.id},view:d.view,user:N(d.user)?void 0:d.user,device:Le,type:Qe},d.context,_o(f),i,a);t.beforeSend&&!1===t.beforeSend(p,c)||p.origin!==xt.AGENT&&be(s[p.status],s.custom).isLimitReached()||n.notify(Vt,me(p))}}))}function _o(e){return function(t){if(t&&t.getInternalContext)return t.getInternalContext(e)}(window.DATAFLUX_RUM)}function wo(e){return wo="function"==typeof Symbol&&"symbol"==typeof Symbol.iterator?function(e){return typeof e}:function(e){return e&&"function"==typeof Symbol&&e.constructor===Symbol&&e!==Symbol.prototype?"symbol":typeof e},wo(e)}function So(e){var t=function(e,t){if("object"!=wo(e)||!e)return e;var n=e[Symbol.toPrimitive];if(void 0!==n){var r=n.call(e,t||"default");if("object"!=wo(r))return r;throw new TypeError("@@toPrimitive must return a primitive value.")}return("string"===t?String:Number)(e)}(e,"string");return"symbol"==wo(t)?t:t+""}function xo(e,t,n){return(t=So(t))in e?Object.defineProperty(e,t,{value:n,enumerable:!0,configurable:!0,writable:!0}):e[t]=n,e}var Oo=xo(xo(xo(xo(xo({},e.log,oo.info),e.debug,oo.debug),e.info,oo.info),e.warn,oo.warn),e.error,oo.error);function ko(e,t){if(!e.forwardErrorsToLogs)return{stop:J};var n=jn().subscribe((function(e){"complete"===e.state&&o(He.XHR,e)})),r=Pn().subscribe((function(e){"resolve"===e.state&&o(He.FETCH,e)}));function o(n,r){function o(e){var o,i,s,a,u,c={isAborted:r.isAborted,handlingStack:r.handlingStack},f=(o=r.url,i=function(e){this._fields={Username:4,Password:5,Port:7,Protocol:2,Host:6,Path:8,URL:0,QueryString:9,Fragment:10},this._values={},this._regex=null,this._regex=/^((\w+):\/\/)?((\w+):?(\w+)?@)?([^\/\?:]+):?(\d+)?(\/?[^\?#]+)?\??([^#]+)?#?(\w*)/,void 0!==e&&this._parse(e)},i.prototype.setUrl=function(e){this._parse(e)},i.prototype._initValues=function(){for(var e in this._fields)this._values[e]=""},i.prototype.addQueryString=function(e){if("object"!==b(e))return!1;var t=this._values.QueryString||"";for(var n in e)t=new RegExp(n+"[^&]+").test(t)?t.replace(new RegExp(n+"[^&]+"),n+"="+e[n]):"&"===t.slice(-1)?t+n+"="+e[n]:""===t?n+"="+e[n]:t+"&"+n+"="+e[n];this._values.QueryString=t},i.prototype.getParse=function(){return this._values},i.prototype.getUrl=function(){var e="";return e+=this._values.Origin,(e+=this._values.Path)+(this._values.QueryString?"?"+this._values.QueryString:"")},i.prototype._parse=function(e){this._initValues();var t=this._regex.exec(e);if(!t)throw"DPURLParser::_parse -> Invalid URL";for(var n in this._fields)void 0!==t[this._fields[n]]&&(this._values[n]=t[this._fields[n]]);this._values.Path=this._values.Path||"/",this._values.Hostname=this._values.Host.replace(/:\d+$/,""),this._values.Origin=this._values.Protocol+"://"+this._values.Hostname+(this._values.Port?":"+this._values.Port:"")},new i(o)).getParse();t.notify(Ft,{rawLogsEvent:{message:Eo(n)+" error "+r.method+" "+r.url,date:r.startClocks.timeStamp,error:{stack:e||"Failed to load",handing:void 0},http:{method:r.method,status_code:r.status,url:r.url,statusGroup:(u=r.status,u?String(u).substr(0,1)+String(u).substr(1).replace(/\d*/g,"x"):0===u?void 0:u),urlHost:f.Host,urlPath:f.Path,urlPathGroup:(s=f.Path,a="",s&&(a=s.replace(/\/([^\/]*)\d([^\/]*)/g,"/?").replace(/\/$/g,"")),a||"/")},status:oo.error,origin:xt.NETWORK},domainContext:c})}!function(e,t){var n=[t.rumEndpoint];return t.logsEndpoint&&n.push(t.logsEndpoint),t.sessionReplayEndPoint&&n.push(t.sessionReplayEndPoint),U(n,(function(t){return 0===e.indexOf(t)}))||t.isIntakeUrl(e)}(r.url,e)&&(function(e){return 0===e.status&&"opaque"!==e.responseType}(r)||function(e){return e.status>=500}(r)||e.isServerError(r))&&("xhr"in r?function(e,t,n){"string"==typeof e.response?n(Co(e.response,t)):n(e.response)}(r.xhr,e,o):r.response?function(e,t,n){var r=function(e){try{return e.clone()}catch(e){return}}(e);r&&r.body?window.TextDecoder?function(e,t,n){!function(e,t,n){var r=e.getReader(),o=[],i=0;function s(){var e,s;if(r.cancel().catch(J),n.collectStreamBody){var a;if(1===o.length)a=o[0];else{a=new Uint8Array(i);var u=0;T(o,(function(e){a.set(e,u),u+=e.length}))}e=a.slice(0,n.bytesLimit),s=a.length>n.bytesLimit}t(void 0,e,s)}!function e(){r.read().then(u((function(t){t.done?s():(n.collectStreamBody&&o.push(t.value),(i+=t.value.length)>n.bytesLimit?s():e())})),u((function(e){t(e)})))}()}(e,(function(e,t,r){if(e)n(e);else{var o=(new TextDecoder).decode(t);r&&(o+="..."),n(void 0,o)}}),{bytesLimit:t,collectStreamBody:!0})}(r.body,t.requestErrorResponseLengthLimit,(function(e,t){n(e?"Unable to retrieve response: "+e:t)})):r.text().then(u((function(e){return n(Co(e,t))})),u((function(e){return n("Unable to retrieve response: "+e)}))):n()}(r.response,e,o):r.error&&function(e,t,n){n(Co(Ct(nt(e)),t))}(r.error,e,o))}return{stop:function(){n.unsubscribe(),r.unsubscribe()}}}function Co(e,t){return e.length>t.requestErrorResponseLengthLimit?e.substring(0,t.requestErrorResponseLengthLimit)+"...":e}function Eo(e){return He.XHR===e?"XHR":"Fetch"}function To(e,t){if(!e.forwardErrorsToLogs)return{stop:J};var n,r=new $t,o=(n=r,pt((function(e,t){n.notify(Ot({stackTrace:e,originalError:t,startClocks:te(),nonErrorPrefix:Je,source:xt.SOURCE,handling:Ge}))}))),i=r.subscribe((function(e){t.notify(Ft,{rawLogsEvent:{message:e.message,date:e.startClocks.timeStamp,error:ro(e),origin:xt.SOURCE,status:oo.error}})}));return{stop:function(){o.stop(),i.unsubscribe()}}}function Lo(e){return function(t){var n,r;e.notify(Ft,{rawLogsEvent:{message:t.message,date:t.startClocks.timeStamp,origin:xt.AGENT,status:oo.error}}),n="Error reported to customer",r={"error.message":t.message},f(n,r),pr(L({type:sr,message:n,status:ur},r))}}var Mo,$o,Ao,Ro,Po=function(e){var t=Jr(),n=qr("global",{customerDataTracker:t.getOrCreateTracker(Fr)}),r=qr("user",{customerDataTracker:t.getOrCreateTracker(Wr),propertiesConfig:{id:{type:"string"},name:{type:"string"},email:{type:"string"}}});function o(){return function(e,t){return{view:{referrer:document.referrer,url:window.location.href},context:e.getContext(),user:t.getContext()}}(n,r)}var s,c,f=po(o,(function(t,i){t.storeContextsToLocal&&(Hr(i,n,vo,Fr),Hr(i,r,vo,Wr));var s=e(t,i,o);return f=function(e,t){return L({init:function(e){Yr("DATAFLUX_LOGS",e)},initConfiguration:e},t)}(t,s),s})),l={},d=new ao((function(){var e;return(e=f).handleLog.apply(e,arguments)}),t.createDetachedTracker());return s={logger:d,init:u((function(e){return f.init(e)})),getGlobalContext:u((function(){return n.getContext()})),setGlobalContext:u((function(e){return n.setContext(e)})),setGlobalContextProperty:u((function(e,t){return n.setContextProperty(e,t)})),removeGlobalContextProperty:u((function(e){return n.removeContextProperty(e)})),clearGlobalContext:u((function(){return n.clearContext()})),createLogger:u((function(e,n){return void 0===n&&(n={}),l[e]=new ao((function(){var e;return(e=f).handleLog.apply(e,arguments)}),t.createDetachedTracker(),sanitize(e),n.handler,n.level,sanitize(n.context)),l[e]})),getLogger:u((function(e){return l[e]})),getInitConfiguration:u((function(){return G(f.initConfiguration)})),getInternalContext:u((function(e){return f.getInternalContext(e)})),setUser:u((function(e){(function(e){var t="object"===H(e);return t||i.error("Unsupported user:",e),t})(e)&&r.setContext(e)})),getUser:u((function(){return r.getContext()})),removeUserProperty:u((function(e){return r.removeContextProperty(e)})),setUserProperty:u((function(e,t){r.setContextProperty(e,t)})),clearUser:u((function(){return r.clearContext()}))},c=L({onReady:function(e){e()}},s),Object.defineProperty(c,"_setDebug",{get:function(){return a},enumerable:!1}),c}((function(e,t,n){var r=new Qt,o=[],i=Lo(r),s=new $t((function(e){var t=jt(window,[Be,je],(function(t){t.type===Be&&"hidden"===document.visibilityState?e.notify({reason:Dn.HIDDEN}):t.type===je&&e.notify({reason:Dn.FROZEN})}),{capture:!0}),n=Bt(window,Me,(function(){e.notify({reason:Dn.UNLOADING})}));return function(){t.stop(),n.stop()}})),a=!t.sessionStoreStrategyType||Pr()||Boolean(window._GUANCE_SYNTHETICS_INJECTS_RUM||rn("guance-synthetics-injects-rum"))?function(e){var t=ho(e)===yo?{}:void 0;return{findTrackedSession:function(){return t},expireObservable:new $t}}(t):mo(t),u=function(e,t,n,r,o){var i=vr(lr,t);i.setContextProvider((function(){var e=_o();return{application:{id:e&&e.application&&e.application.id},session:{id:o.findTrackedSession()&&o.findTrackedSession().id},view:{id:e&&e.view&&e.view.id},action:{id:e&&e.userAction&&e.userAction.id}}}));var s=[];if(!Pr()){var a=$r(t,{endpoint:t.rumEndpoint,encoder:Xr()},n,r,o.expireObservable);s.push((function(){a.stop()}));var u=i.observable.subscribe((function(e){a.add(e)}));s.push((function(){u.unsubscribe()}))}return function(){dr.drain()}(),function(e){pr({type:ar,configuration:e})}(G(e)),{telemetry:i,stop:function(){s.forEach((function(e){e()}))}}}(e,t,i,s,a);o.push((function(){u.stop()})),ko(t,r),To(t,r),function(e,t){var n=Pt(e.forwardConsoleLogs).subscribe((function(e){t.notify(Ft,{rawLogsEvent:{date:ne(),message:e.message,origin:xt.CONSOLE,error:e.error&&ro(e.error),status:Oo[e.api]},domainContext:{handlingStack:e.handlingStack}})}))}(t,r),function(e,t){var n=Ut(0,e.forwardReports).subscribe((function(e){var n,r,o,i=e.message,s="deprecation"===e.originalError.type?oo.warn:oo.error;s===oo.error?n=ro(e):report.stack&&(i+=" Found in "+(r=e.stack,(o=/@ (.+)/.exec(r))&&o[1])),t.notify(Ft,{rawLogsEvent:{date:ne(),message:i,origin:xt.REPORT,error:n,status:s}})}))}(t,r);var c=to(r);if(bo(a,t,r,n,i),Pr())!function(e){var t=Rr();e.subscribe(Vt,(function(e){t.send("log",e)}))}(r);else{var f=function(e,t,n,r,o){var i=$r(e,{endpoint:e.logsEndpoint,encoder:Xr()},n,r,o.expireObservable);return t.subscribe(Vt,(function(e){i.add(e)})),i}(t,r,i,s,a);o.push((function(){f.stop()}))}var l,d=(l=a,{get:function(e){var t=l.findTrackedSession(e);if(t)return{session:{id:t.id}}}});return{handleLog:c.handleLog,getInternalContext:d.get,stop:function(){o.forEach((function(e){e()}))}}}));Mo=p(),Ao=Po,Ro=Mo[$o="DATAFLUX_LOGS"],Mo[$o]=Ao,Ro&&Ro.q&&T(Ro.q,(function(e){l(e,"onReady callback threw an error:")()}))}();
1
+ !function(){"use strict";var e={log:"log",debug:"debug",info:"info",warn:"warn",error:"error"},t=console,n={};Object.keys(e).forEach((function(e){n[e]=t[e]}));var r,o="GUANCE Browser SDK:",i={debug:n.debug.bind(t,o),log:n.log.bind(t,o),info:n.info.bind(t,o),warn:n.warn.bind(t,o),error:n.error.bind(t,o)},s=!1;function a(e){s=e}function u(e){return function(){return c(e,this,arguments)}}function c(e,t,n){try{return e.apply(t,n)}catch(e){if(f(e),r)try{r(e)}catch(e){f(e)}}}function f(){var e=[].slice.call(arguments);s&&i.error.apply(null,["[MONITOR]"].concat(e))}function l(e,t){return function(){var n=[].slice.call(arguments);try{return e.apply(this,n)}catch(e){i.error(t,e)}}}function d(e){return d="function"==typeof Symbol&&"symbol"==typeof Symbol.iterator?function(e){return typeof e}:function(e){return e&&"function"==typeof Symbol&&e.constructor===Symbol&&e!==Symbol.prototype?"symbol":typeof e},d(e)}function p(){if("object"===("undefined"==typeof globalThis?"undefined":d(globalThis)))return globalThis;Object.defineProperty(Object.prototype,"_gc_temp_",{get:function(){return this},configurable:!0});var e=_gc_temp_;return delete Object.prototype._gc_temp_,"object"!==d(e)&&(e="object"===("undefined"==typeof self?"undefined":d(self))?self:"object"===("undefined"==typeof window?"undefined":d(window))?window:{}),e}function v(e,t){var n,r=p();return r.Zone&&"function"==typeof r.Zone.__symbol__&&(n=e[r.Zone.__symbol__(t)]),n||(n=e[t]),n}function g(e,t){return v(p(),"setTimeout")(u(e),t)}function y(e){v(p(),"clearTimeout")(e)}function m(e,t){return v(p(),"setInterval")(u(e),t)}function h(e){v(p(),"clearInterval")(e)}function b(e){return b="function"==typeof Symbol&&"symbol"==typeof Symbol.iterator?function(e){return typeof e}:function(e){return e&&"function"==typeof Symbol&&e.constructor===Symbol&&e!==Symbol.prototype?"symbol":typeof e},b(e)}var _=Array.prototype,w=(Function.prototype,Object.prototype),S=_.slice,x=w.toString,O=w.hasOwnProperty,k=_.forEach,C=Array.isArray,E=!1,T=function(e,t,n){if(null===e)return!1;if(k&&e.forEach===k)e.forEach(t,n);else if(e.length===+e.length){for(var r=0,o=e.length;r<o;r++)if(r in e&&t.call(n,e[r],r,e)===E)return!1}else for(var i in e)if(O.call(e,i)&&t.call(n,e[i],i,e)===E)return!1};function L(e){return T(S.call(arguments,1),(function(t){for(var n in t)Object.prototype.hasOwnProperty.call(t,n)&&(e[n]=t[n])})),e}var $=function(e){return T(S.call(arguments,1),(function(t){for(var n in t)void 0!==t[n]&&(e[n]=t[n])})),e},M=function(e){return T(S.call(arguments,1),(function(t){for(var n in t)void 0!==t[n]&&(U(t[n])&&U(e[n])?$(e[n],t[n]):e[n]=t[n])})),e},A=C||function(e){return"[object Array]"===x.call(e)},P=function(e){if(!e)return!1;try{return/^\s*\bfunction\b/.test(e)}catch(e){return!1}},R=function(e){var t=[];return null===e||T(e,(function(e){t[t.length]=e})),t},B=function(e){var t=[];return null===e||T(e,(function(e,n){t[t.length]=n})),t},j=function(e,t,n){if(e.filter)return e.filter(t);for(var r=[],o=0;o<e.length;o++)if(O.call(e,o)){var i=e[o];t.call(n,i,o,e)&&r.push(i)}return r},I=function(e,t,n){if(e.map)return e.map(t);for(var r=[],o=0;o<e.length;o++)if(O.call(e,o)){var i=e[o];r.push(t.call(n,i,o,e))}return r},D=function(e,t,n){if(e.some)return e.some(t);for(var r=!1,o=0;o<e.length;o++)if(O.call(e,o)){var i=e[o];if(t.call(n,i,o,e)){r=!0;break}}return r},U=function(e){return null!==e&&"[object Object]"===x.call(e)},q=function(e){if(U(e)){for(var t in e)if(O.call(e,t))return!1;return!0}return!1},F=function(e){return"[object String]"===x.call(e)},W=function(e){return"[object Boolean]"===x.call(e)},V=function(e){return"[object Number]"===x.call(e)&&/[\d\.]+/.test(String(e))},N=(Date.now,function(e,t,n){var r,o,i=!n||void 0===n.leading||n.leading,s=!n||void 0===n.trailing||n.trailing,a=!1,u=this;return{throttled:function(){a?r=arguments:(i?e.apply(u,arguments):r=arguments,a=!0,o=g((function(){s&&r&&e.apply(u,r),a=!1,r=void 0}),t))},cancel:function(){y(o),a=!1,r=void 0}}});function Q(e){return e?(parseInt(e,10)^16*Math.random()>>parseInt(e,10)/4).toString(16):"".concat(1e7,"-",1e3,"-",4e3,"-",8e3,"-",1e11).replace(/[018]/g,Q)}function H(e){return null===e?"null":Array.isArray(e)?"array":b(e)}function z(e,t,n){if(void 0===n&&(n=function(){if("undefined"!=typeof WeakSet){var e=new WeakSet;return{hasAlreadyBeenSeen:function(t){var n=e.has(t);return n||e.add(t),n}}}var t=[];return{hasAlreadyBeenSeen:function(e){var n=t.indexOf(e)>=0;return n||t.push(e),n}}}()),void 0===t)return e;if("object"!==b(t)||null===t)return t;if(t instanceof Date)return new Date(t.getTime());if(t instanceof RegExp){var r=t.flags||[t.global?"g":"",t.ignoreCase?"i":"",t.multiline?"m":"",t.sticky?"y":"",t.unicode?"u":""].join("");return new RegExp(t.source,r)}if(!n.hasAlreadyBeenSeen(t)){if(Array.isArray(t)){for(var o=Array.isArray(e)?e:[],i=0;i<t.length;++i)o[i]=z(o[i],t[i],n);return o}o="object"===H(e)?e:{};for(var s in t)Object.prototype.hasOwnProperty.call(t,s)&&(o[s]=z(o[s],t[s],n));return o}}function G(e){return z(void 0,e)}function J(){}var X,K=1e3,Z=6e4;function Y(e){return 0!==e&&100*Math.random()<=e}function ee(){return performance.now()}function te(){return{relative:ee(),timeStamp:ne()}}function ne(){return re()}function re(){return(new Date).getTime()}function oe(){return void 0===X&&(X=performance.timing.navigationStart),X}var ie=/([\w-]+)\s*=\s*([^;]+)/g;function se(e,t){for(var n=t.split(".");n.length;){var r=n.shift();if(!(e&&U(e)&&r in e&&O.call(e,r)))return;e=e[r]}return e}function ae(e,t){var n=e.charCodeAt(t-1);return n>=55296&&n<=56319?e.slice(0,t+1):e.slice(0,t)}function ue(e,t){return-1!==e.indexOf(t)}function ce(e){if(Array.from)return Array.from(e);var t=[];if(e instanceof Set)e.forEach((function(e){t.push(e)}));else for(var n=0;n<e.length;n++)t.push(e[n]);return t}function fe(e){return V(e)&&e>=0&&e<=100}var le,de=0,pe=1,ve=2,ge=3;function ye(){return be(le,le=function(e){var t;void 0===e&&(e=window);var n=e.navigator.userAgent;if(e.chrome||/HeadlessChrome/.test(n))return pe;if(0===(null===(t=e.navigator.vendor)||void 0===t?void 0:t.indexOf("Apple"))||/safari/i.test(n)&&!/chrome|android/i.test(n))return ve;if(e.document.documentMode)return de;return ge}())}function me(e){var t={};return T(e,(function(e,n){var r;t[(r=n,r.replace(/[A-Z]/g,(function(e,t){return(0!==t?"_":"")+e.toLowerCase()})).replace(/-/g,"_"))]=he(e)})),t}function he(e){return A(e)?I(e,(function(e){return he(e)})):"object"===b(e)&&null!==e?me(e):e}function be(e,t){return null!=e?e:t}function _e(e,t){return e.slice(0,t.length)===t}function we(e,t){var n=e.indexOf(t);n>=0&&e.splice(n,1)}function Se(){var e=[],t=function(t){e.push(t)>500&&e.splice(0,1)};return{add:t,remove:t,drain:function(t){e.forEach((function(e){e(t)})),e.length=0}}}var xe=1/0,Oe=null,ke=new Set;var Ce={navigator:"undefined"!=typeof window&&void 0!==window.navigator?window.navigator:{},infoMap:{engine:["WebKit","Trident","Gecko","Presto"],browser:["Safari","Chrome","Edge","IE","IE 11","IE 10","IE 9","IE 8","IE 7","Firefox","Firefox Focus","Chromium","Opera","Vivaldi","Yandex","Arora","Lunascape","QupZilla","Coc Coc","Kindle","Iceweasel","Konqueror","Iceape","SeaMonkey","Epiphany","360","360SE","360EE","UC","QQBrowser","QQ","Baidu","Maxthon","Sogou","LBBROWSER","2345Explorer","TheWorld","XiaoMi","Quark","Qiyu","Wechat",,"WechatWork","Taobao","Alipay","Weibo","Douban","Suning","iQiYi"],os:["Windows","Linux","Mac OS","Android","Ubuntu","FreeBSD","Debian","iOS","Windows Phone","BlackBerry","MeeGo","Symbian","Chrome OS","WebOS"],device:["Mobile","Tablet","iPad"]}},Ee={getMatchMap:u((function(e){return{Trident:e.indexOf("Trident")>-1||e.indexOf("NET CLR")>-1,Presto:e.indexOf("Presto")>-1,WebKit:e.indexOf("AppleWebKit")>-1,Gecko:e.indexOf("Gecko/")>-1,Safari:e.indexOf("Safari")>-1,Chrome:e.indexOf("Chrome")>-1||e.indexOf("CriOS")>-1,IE:e.indexOf("MSIE")>-1||e.indexOf("Trident")>-1,Edge:e.indexOf("Edge")>-1||e.indexOf("Edg")>-1,Firefox:e.indexOf("Firefox")>-1||e.indexOf("FxiOS")>-1,"Firefox Focus":e.indexOf("Focus")>-1,Chromium:e.indexOf("Chromium")>-1,Opera:e.indexOf("Opera")>-1||e.indexOf("OPR")>-1,Vivaldi:e.indexOf("Vivaldi")>-1,Yandex:e.indexOf("YaBrowser")>-1,Arora:e.indexOf("Arora")>-1,Lunascape:e.indexOf("Lunascape")>-1,QupZilla:e.indexOf("QupZilla")>-1,"Coc Coc":e.indexOf("coc_coc_browser")>-1,Kindle:e.indexOf("Kindle")>-1||e.indexOf("Silk/")>-1,Iceweasel:e.indexOf("Iceweasel")>-1,Konqueror:e.indexOf("Konqueror")>-1,Iceape:e.indexOf("Iceape")>-1,SeaMonkey:e.indexOf("SeaMonkey")>-1,Epiphany:e.indexOf("Epiphany")>-1,360:e.indexOf("QihooBrowser")>-1||e.indexOf("QHBrowser")>-1,"360EE":e.indexOf("360EE")>-1,"360SE":e.indexOf("360SE")>-1,UC:e.indexOf("UC")>-1||e.indexOf(" UBrowser")>-1,QQBrowser:e.indexOf("QQBrowser")>-1,QQ:e.indexOf("QQ/")>-1,Baidu:e.indexOf("Baidu")>-1||e.indexOf("BIDUBrowser")>-1,Maxthon:e.indexOf("Maxthon")>-1,Sogou:e.indexOf("MetaSr")>-1||e.indexOf("Sogou")>-1,LBBROWSER:e.indexOf("LBBROWSER")>-1,"2345Explorer":e.indexOf("2345Explorer")>-1,TheWorld:e.indexOf("TheWorld")>-1,XiaoMi:e.indexOf("MiuiBrowser")>-1,Quark:e.indexOf("Quark")>-1,Qiyu:e.indexOf("Qiyu")>-1,Wechat:e.indexOf("MicroMessenger")>-1,Taobao:e.indexOf("AliApp(TB")>-1,Alipay:e.indexOf("AliApp(AP")>-1,Weibo:e.indexOf("Weibo")>-1,Douban:e.indexOf("com.douban.frodo")>-1,Suning:e.indexOf("SNEBUY-APP")>-1,iQiYi:e.indexOf("IqiyiApp")>-1,Windows:e.indexOf("Windows")>-1,Linux:e.indexOf("Linux")>-1||e.indexOf("X11")>-1,"Mac OS":e.indexOf("Macintosh")>-1,Android:e.indexOf("Android")>-1||e.indexOf("Adr")>-1,Ubuntu:e.indexOf("Ubuntu")>-1,FreeBSD:e.indexOf("FreeBSD")>-1,Debian:e.indexOf("Debian")>-1,"Windows Phone":e.indexOf("IEMobile")>-1||e.indexOf("Windows Phone")>-1,BlackBerry:e.indexOf("BlackBerry")>-1||e.indexOf("RIM")>-1,MeeGo:e.indexOf("MeeGo")>-1,Symbian:e.indexOf("Symbian")>-1,iOS:e.indexOf("like Mac OS X")>-1,"Chrome OS":e.indexOf("CrOS")>-1,WebOS:e.indexOf("hpwOS")>-1,Mobile:e.indexOf("Mobi")>-1||e.indexOf("iPh")>-1||e.indexOf("480")>-1,Tablet:e.indexOf("Tablet")>-1||e.indexOf("Nexus 7")>-1,iPad:e.indexOf("iPad")>-1}})),matchInfoMap:u((function(e){var t=Ce.navigator.userAgent||"",n=Ee.getMatchMap(t);for(var r in Ce.infoMap)for(var o=0;o<Ce.infoMap[r].length;o++){var i=Ce.infoMap[r][o];n[i]&&(e[r]=i)}})),getOS:u((function(){return Ee.matchInfoMap(this),this.os||"Unknown"})),getOSVersion:u((function(){var e=this,t=Ce.navigator.userAgent||"";e.osVersion="",e.osMajor="";var n={Windows:function(){var e=t.replace(/^.*Windows NT ([\d.]+);.*$/,"$1");return{6.4:"10",6.3:"8.1",6.2:"8",6.1:"7","6.0":"Vista",5.2:"XP",5.1:"XP","5.0":"2000"}[e]||e},Android:function(){return t.replace(/^.*Android ([\d.]+);.*$/,"$1")},iOS:function(){return t.replace(/^.*OS ([\d_]+) like.*$/,"$1").replace(/_/g,".")},Debian:function(){return t.replace(/^.*Debian\/([\d.]+).*$/,"$1")},"Windows Phone":function(){return t.replace(/^.*Windows Phone( OS)? ([\d.]+);.*$/,"$2")},"Mac OS":function(){return t.replace(/^.*Mac OS X ([\d_]+).*$/,"$1").replace(/_/g,".")},WebOS:function(){return t.replace(/^.*hpwOS\/([\d.]+);.*$/,"$1")}};return n[e.os]&&(e.osVersion=n[e.os](),e.osVersion===t&&(e.osVersion="")),e.osVersion&&(e.osMajor=e.osVersion.split(".").length&&e.osVersion.split(".")[0]),{version:e.osVersion,osMajor:e.osMajor}})),getDeviceType:u((function(){var e=this;return e.device="PC",Ee.matchInfoMap(e),e.device})),getNetwork:u((function(){var e=window.navigator.connection||window.navigator.mozConnection||window.navigator.webkitConnection,t="unknown",n=e?e.type||e.effectiveType:null;if(n&&"string"==typeof n)switch(n){case"bluetooth":case"cellular":case"slow-2g":case"2g":case"3g":t="cellular";break;case"none":t="none";break;case"ethernet":case"wifi":case"wimax":case"4g":t="wifi";break;case"other":case"unknown":t="unknown"}return t})),getLanguage:u((function(){var e;return this.language=((e=(Ce.navigator.browserLanguage||Ce.navigator.language||"").split("-"))[1]&&(e[1]=e[1].toUpperCase()),e.join("_")),this.language})),getTimeZone:u((function(){return Intl.DateTimeFormat().resolvedOptions().timeZone})),getBrowserInfo:u((function(){var e=this;Ee.matchInfoMap(e);var t=Ce.navigator.userAgent||"",n=function(e,t){var n=Ce.navigator.mimeTypes;for(var r in n)if(n[r][e]==t)return!0;return!1},r=Ee.getMatchMap(t),o=!1;if("undefined"!=typeof window&&window.chrome){var i=t.replace(/^.*Chrome\/([\d]+).*$/,"$1");i>36&&window.showModalDialog?o=!0:i>45&&(o=n("type","application/vnd.chromium.remoting-viewer"))}if(r.Baidu&&r.Opera&&(r.Baidu=!1),r.Mobile&&(r.Mobile=!(t.indexOf("iPad")>-1)),o&&(n("type","application/gameplugin")||Ce.navigator&&Ce.navigator.connection&&void 0===Ce.navigator.connection.saveData?r["360SE"]=!0:r["360EE"]=!0),r.IE||r.Edge)switch(window.screenTop-window.screenY){case 71:case 74:case 99:case 75:case 74:case 105:default:break;case 102:r["360EE"]=!0;break;case 104:r["360SE"]=!0}var s={Safari:function(){return t.replace(/^.*Version\/([\d.]+).*$/,"$1")},Chrome:function(){return t.replace(/^.*Chrome\/([\d.]+).*$/,"$1").replace(/^.*CriOS\/([\d.]+).*$/,"$1")},IE:function(){return t.replace(/^.*MSIE ([\d.]+).*$/,"$1").replace(/^.*rv:([\d.]+).*$/,"$1")},Edge:function(){return t.replace(/^.*Edge?\/([\d.]+).*$/,"$1")},Firefox:function(){return t.replace(/^.*Firefox\/([\d.]+).*$/,"$1").replace(/^.*FxiOS\/([\d.]+).*$/,"$1")},"Firefox Focus":function(){return t.replace(/^.*Focus\/([\d.]+).*$/,"$1")},Chromium:function(){return t.replace(/^.*Chromium\/([\d.]+).*$/,"$1")},Opera:function(){return t.replace(/^.*Opera\/([\d.]+).*$/,"$1").replace(/^.*OPR\/([\d.]+).*$/,"$1")},Vivaldi:function(){return t.replace(/^.*Vivaldi\/([\d.]+).*$/,"$1")},Yandex:function(){return t.replace(/^.*YaBrowser\/([\d.]+).*$/,"$1")},Arora:function(){return t.replace(/^.*Arora\/([\d.]+).*$/,"$1")},Lunascape:function(){return t.replace(/^.*Lunascape[\/\s]([\d.]+).*$/,"$1")},QupZilla:function(){return t.replace(/^.*QupZilla[\/\s]([\d.]+).*$/,"$1")},"Coc Coc":function(){return t.replace(/^.*coc_coc_browser\/([\d.]+).*$/,"$1")},Kindle:function(){return t.replace(/^.*Version\/([\d.]+).*$/,"$1")},Iceweasel:function(){return t.replace(/^.*Iceweasel\/([\d.]+).*$/,"$1")},Konqueror:function(){return t.replace(/^.*Konqueror\/([\d.]+).*$/,"$1")},Iceape:function(){return t.replace(/^.*Iceape\/([\d.]+).*$/,"$1")},SeaMonkey:function(){return t.replace(/^.*SeaMonkey\/([\d.]+).*$/,"$1")},Epiphany:function(){return t.replace(/^.*Epiphany\/([\d.]+).*$/,"$1")},360:function(){return t.replace(/^.*QihooBrowser\/([\d.]+).*$/,"$1")},"360SE":function(){return{63:"10.0",55:"9.1",45:"8.1",42:"8.0",31:"7.0",21:"6.3"}[t.replace(/^.*Chrome\/([\d]+).*$/,"$1")]||""},"360EE":function(){return{69:"11.0",63:"9.5",55:"9.0",50:"8.7",30:"7.5"}[t.replace(/^.*Chrome\/([\d]+).*$/,"$1")]||""},Maxthon:function(){return t.replace(/^.*Maxthon\/([\d.]+).*$/,"$1")},QQBrowser:function(){return t.replace(/^.*QQBrowser\/([\d.]+).*$/,"$1")},QQ:function(){return t.replace(/^.*QQ\/([\d.]+).*$/,"$1")},Baidu:function(){return t.replace(/^.*BIDUBrowser[\s\/]([\d.]+).*$/,"$1")},UC:function(){return t.replace(/^.*UC?Browser\/([\d.]+).*$/,"$1")},Sogou:function(){return t.replace(/^.*SE ([\d.X]+).*$/,"$1").replace(/^.*SogouMobileBrowser\/([\d.]+).*$/,"$1")},LBBROWSER:function(){var e="";t.indexOf("LieBaoFast")>-1&&(e=t.replace(/^.*LieBaoFast\/([\d.]+).*$/,"$1"));var n=t.replace(/^.*Chrome\/([\d]+).*$/,"$1");return e||{57:"6.5",49:"6.0",46:"5.9",42:"5.3",39:"5.2",34:"5.0",29:"4.5",21:"4.0"}[n]||""},"2345Explorer":function(){return t.replace(/^.*2345Explorer\/([\d.]+).*$/,"$1")},TheWorld:function(){return t.replace(/^.*TheWorld ([\d.]+).*$/,"$1")},XiaoMi:function(){return t.replace(/^.*MiuiBrowser\/([\d.]+).*$/,"$1")},Quark:function(){return t.replace(/^.*Quark\/([\d.]+).*$/,"$1")},Qiyu:function(){return t.replace(/^.*Qiyu\/([\d.]+).*$/,"$1")},Wechat:function(){return t.replace(/^.*MicroMessenger\/([\d.]+).*$/,"$1")},WechatWork:function(){return t.replace(/^.*wxwork\/([\d.]+).*$/,"$1")},Taobao:function(){return t.replace(/^.*AliApp\(TB\/([\d.]+).*$/,"$1")},Alipay:function(){return t.replace(/^.*AliApp\(AP\/([\d.]+).*$/,"$1")},Weibo:function(){return t.replace(/^.*weibo__([\d.]+).*$/,"$1")},Douban:function(){return t.replace(/^.*com.douban.frodo\/([\d.]+).*$/,"$1")},Suning:function(){return t.replace(/^.*SNEBUY-APP([\d.]+).*$/,"$1")},iQiYi:function(){return t.replace(/^.*IqiyiVersion\/([\d.]+).*$/,"$1")}};return e.browserVersion="",e.browserMajor="",s[e.browser]&&(e.browserVersion=s[e.browser](),e.browserVersion==t&&(e.browserVersion="")),"Chrome"==e.browser&&t.match(/\S+Browser/)&&(e.browser=t.match(/\S+Browser/)[0],e.version=t.replace(/^.*Browser\/([\d.]+).*$/,"$1")),"Edge"==e.browser&&(e.version>"75"?e.engine="Blink":e.engine="EdgeHTML"),("Chrome"==e.browser&&parseInt(e.browserVersion)>27||r.Chrome&&"WebKit"==e.engine&&parseInt(e.browserVersion)>27||"Opera"==e.browser&&parseInt(e.version)>12||"Yandex"==e.browser)&&(e.engine="Blink"),e.browserVersion&&(e.browserMajor=e.browserVersion.split(".").length&&this.browserVersion.split(".")[0]),{browser:e.browser,browserVersion:e.browserVersion,engine:e.engine,browserMajor:e.browserMajor}})),getGeoPostion:u((function(e){navigator&&navigator.geolocation&&navigator.geolocation.getCurrentPosition((function(t){e(t)}),(function(e){i.warn(e)}))}))},Te={};"undefined"!=typeof window&&(Te={os:Ee.getOS(),osVersion:Ee.getOSVersion().version,osVersionMajor:Ee.getOSVersion().osMajor,browser:Ee.getBrowserInfo().browser,browserVersion:Ee.getBrowserInfo().browserVersion,browserVersionMajor:Ee.getBrowserInfo().browserMajor,screenSize:window.screen.width+"*"+window.screen.height,networkType:Ee.getNetwork(),device:Ee.getDeviceType(),timeZone:Ee.getTimeZone()});var Le=Te,$e="beforeunload",Me="click",Ae="keydown",Pe="scroll",Re="touchstart",Be="visibilitychange",je="freeze",Ie="resume",De="securitypolicyviolation",Ue="storage",qe="action",Fe="error",We="long_task",Ve="view",Ne="resource",Qe="logger",He={FETCH:"fetch",XHR:"xhr"},ze="handled",Ge="unhandled",Je="Uncaught",Xe="Provided";function Ke(e){return Ke="function"==typeof Symbol&&"symbol"==typeof Symbol.iterator?function(e){return typeof e}:function(e){return e&&"function"==typeof Symbol&&e.constructor===Symbol&&e!==Symbol.prototype?"symbol":typeof e},Ke(e)}function Ze(e,t,n){if("object"!==Ke(e)||null===e)return JSON.stringify(e);var r=Ye(Object.prototype),o=Ye(Array.prototype),i=Ye(Object.getPrototypeOf(e)),s=Ye(e);try{return JSON.stringify(e,t,n)}catch(e){return"<error: unable to serialize object>"}finally{r(),o(),i(),s()}}function Ye(e){var t=e,n=t.toJSON;return n?(delete t.toJSON,function(){t.toJSON=n}):J}function et(e){return et="function"==typeof Symbol&&"symbol"==typeof Symbol.iterator?function(e){return typeof e}:function(e){return e&&"function"==typeof Symbol&&e.constructor===Symbol&&e!==Symbol.prototype?"symbol":typeof e},et(e)}var tt="?";function nt(e){var t=[],n=lt(e,"stack"),r=String(e);return n&&n.startsWith(r)&&(n=n.slice(r.length)),n&&T(n.split("\n"),(function(e){var n=function(e){var t=it.exec(e);if(!t)return;var n=t[2]&&0===t[2].indexOf("native"),r=t[2]&&0===t[2].indexOf("eval"),o=st.exec(t[2]);r&&o&&(t[2]=o[1],t[3]=o[2],t[4]=o[3]);return{args:n?[t[2]]:[],column:t[4]?+t[4]:void 0,func:t[1]||tt,line:t[3]?+t[3]:void 0,url:n?void 0:t[2]}}(e)||function(e){var t=at.exec(e);if(!t)return;return{args:[],column:t[3]?+t[3]:void 0,func:tt,line:t[2]?+t[2]:void 0,url:t[1]}}(e)||function(e){var t=ut.exec(e);if(!t)return;return{args:[],column:t[4]?+t[4]:void 0,func:t[1]||tt,line:+t[3],url:t[2]}}(e)||function(e){var t=ct.exec(e);if(!t)return;var n=t[3]&&t[3].indexOf(" > eval")>-1,r=ft.exec(t[3]);n&&r&&(t[3]=r[1],t[4]=r[2],t[5]=void 0);return{args:t[2]?t[2].split(","):[],column:t[5]?+t[5]:void 0,func:t[1]||tt,line:t[4]?+t[4]:void 0,url:t[3]}}(e);n&&(!n.func&&n.line&&(n.func=tt),t.push(n))})),{message:lt(e,"message"),name:lt(e,"name"),stack:t}}var rt="((?:file|https?|blob|chrome-extension|electron|native|eval|webpack|<anonymous>|\\w+\\.|\\/).*?)",ot="(?::(\\d+))",it=new RegExp("^\\s*at (.*?) ?\\("+rt+ot+"?"+ot+"?\\)?\\s*$","i"),st=new RegExp("\\((\\S*)"+ot+ot+"\\)");var at=new RegExp("^\\s*at ?"+rt+ot+"?"+ot+"??\\s*$","i");var ut=/^\s*at (?:((?:\[object object\])?.+) )?\(?((?:file|ms-appx|https?|webpack|blob):.*?):(\d+)(?::(\d+))?\)?\s*$/i;var ct=/^\s*(.*?)(?:\((.*?)\))?(?:^|@)((?:file|https?|blob|chrome|webpack|resource|capacitor|\[native).*?|[^@]*bundle|\[wasm code\])(?::(\d+))?(?::(\d+))?\s*$/i,ft=/(\S+) line (\d+)(?: > eval line \d+)* > eval/i;function lt(e,t){if("object"===et(e)&&e&&t in e){var n=e[t];return"string"==typeof n?n:void 0}}var dt=/^(?:[Uu]ncaught (?:exception: )?)?(?:((?:Eval|Internal|Range|Reference|Syntax|Type|URI|)Error): )?([\s\S]*)$/;function pt(e){var t=function(e){return Rt(window,"onerror",(function(t){var n,r=t.parameters,o=r[0],i=r[1],s=r[2],a=r[3],u=r[4];if(u instanceof Error)n=nt(u);else{var c={url:i,column:a,line:s},f=function(e){var t,n;if("[object String]"==={}.toString.call(e)){var r=dt.exec(e);r&&(t=r[1],n=r[2])}return{name:t,message:n}}(o);n={name:f.name,message:f.message,stack:[c]}}e(n,be(u,o))}))}(e),n=function(e){return Rt(window,"onunhandledrejection",(function(t){var n=t.parameters[0].reason||"Empty reason",r=nt(n);e(r,n)}))}(e);return{stop:function(){t.stop(),n.stop()}}}var vt=1024,gt=/[^\u0000-\u007F]/;function yt(e){return gt.test(e)?void 0!==window.TextEncoder?(new TextEncoder).encode(e).length:new Blob([e]).size:e.length}function mt(e){return mt="function"==typeof Symbol&&"symbol"==typeof Symbol.iterator?function(e){return typeof e}:function(e){return e&&"function"==typeof Symbol&&e.constructor===Symbol&&e!==Symbol.prototype?"symbol":typeof e},mt(e)}function ht(e,t){void 0===t&&(t=225280);var n=Ye(Object.prototype),r=Ye(Array.prototype),o=[],i=new WeakMap,s=bt(e,"$",void 0,o,i),a=JSON.stringify(s)&&JSON.stringify(s).length||0;if(!(a>t)){for(;o.length>0&&a<t;){var u=o.shift(),c=0;if(Array.isArray(u.source))for(var f=0;f<u.source.length;f++){if(a+=void 0!==(l=bt(u.source[f],u.path,f,o,i))?JSON.stringify(l).length:4,a+=c,c=1,a>t){wt(t,"truncated",e);break}u.target[f]=l}else for(var f in u.source)if(Object.prototype.hasOwnProperty.call(u.source,f)){var l;if(void 0!==(l=bt(u.source[f],u.path,f,o,i))&&(a+=JSON.stringify(l).length+c+f.length+3,c=1),a>t){wt(t,"truncated",e);break}u.target[f]=l}}return n(),r(),s}wt(t,"discarded",e)}function bt(e,t,n,r,o){var i=function(e){var t=e;if(t&&"function"==typeof t.toJSON)try{return t.toJSON()}catch(e){}return e}(e);if(!i||"object"!==mt(i))return function(e){if("bigint"==typeof e)return"[BigInt] "+e.toString();if("function"==typeof e)return"[Function] "+e.name||0;if("symbol"===mt(e))return"[Symbol] "+e.description||0;return e}(i);var s=_t(i);if("[Object]"!==s&&"[Array]"!==s&&"[Error]"!==s)return s;var a=e;if(o.has(a))return"[Reference seen at "+o.get(a)+"]";var u=void 0!==n?t+"."+n:t,c=Array.isArray(i)?[]:{};return o.set(a,u),r.push({source:i,target:c,path:u}),c}function _t(e){try{if(e instanceof Event)return{type:(n=e).type,isTrusted:n.isTrusted,currentTarget:n.currentTarget?_t(n.currentTarget):null,target:n.target?_t(n.target):null};if(e instanceof RegExp)return"[RegExp] ".concat(e.toString());var t=Object.prototype.toString.call(e).match(/\[object (.*)\]/);if(t&&t[1])return"["+t[1]+"]"}catch(e){}var n;return"[Unserializable]"}function wt(e,t,n){i.warn("The data provided has been "+t+" as it is over the limit of "+e+" characters:",n)}var St="No stack, consider using an instance of Error",xt="agent",Ot="console",kt="network",Ct="source",Et="logger",Tt="report";function Lt(e){var t=e.stackTrace,n=e.originalError,r=e.handlingStack,o=e.startClocks,i=e.nonErrorPrefix,s=e.source,a=e.handling,u=n instanceof Error,c=function(e,t,n,r){return e&&e.message&&e&&e.name?e.message:t?"Empty message":n+" "+Ze(ht(r))}(t,u,i,n),f=function(e,t){if(void 0===t)return!1;if(e)return!0;return t.stack.length>0&&(t.stack.length>1||void 0!==t.stack[0].url)}(u,t)?Mt(t):St,l=u?Pt(n,s):void 0;return{startClocks:o,source:s,handling:a,originalError:n,message:c,stack:f,handlingStack:r,type:t&&t.name,causes:l}}function $t(){var e,t=new Error;if(!t.stack)try{throw t}catch(e){}return c((function(){var n=nt(t);n.stack=n.stack.slice(2),e=Mt(n)})),e}function Mt(e){var t=At(e);return T(e.stack,(function(e){var n="?"===e.func?"<anonymous>":e.func,r=e.args&&e.args.length>0?"("+e.args.join(", ")+")":"",o=e.line?":"+e.line:"",i=e.line&&e.column?":"+e.column:"";t+="\n at "+n+r+" @ "+e.url+o+i})),t}function At(e){return(e.name||"Error")+": "+e.message}function Pt(e,t){for(var n=e,r=[];n&&n.cause instanceof Error&&r.length<10;){var o=nt(n.cause);r.push({message:n.cause.message,source:t,type:o&&o.name,stack:o&&Mt(o)}),n=n.cause}return r.length?r:void 0}function Rt(e,t,n,r){var o=r&&r.computeHandlingStack,i=e[t];if("function"!=typeof i){if(!_e(t,"on"))return{stop:J};i=J}var s=!1,a=function(){if(s)return i.apply(this,arguments);var e,t=ce(arguments);c(n,null,[{target:this,parameters:t,onPostCall:function(t){e=t},handlingStack:o?$t():void 0}]);var r=i.apply(this,t);return e&&c(e,null,[r]),r};return e[t]=a,{stop:function(){s=!0,e[t]===a&&(e[t]=i)}}}var Bt=function(e){this.observers=[],this.onLastUnsubscribe=void 0,this.onFirstSubscribe=e};Bt.prototype={subscribe:function(e){this.observers.push(e),1===this.observers.length&&this.onFirstSubscribe&&(this.onLastUnsubscribe=this.onFirstSubscribe(this)||void 0);var t=this;return{unsubscribe:function(){t.observers=j(t.observers,(function(t){return e!==t})),!t.observers.length&&t.onLastUnsubscribe&&t.onLastUnsubscribe()}}},notify:function(e){T(this.observers,(function(t){t(e)}))}};var jt=Bt;function It(){var e=[].slice.call(arguments);return new jt((function(t){var n=I(e,(function(e){return e.subscribe((function(e){return t.notify(e)}))}));return function(){return T(n,(function(e){return e.unsubscribe()}))}}))}var Dt={};function Ut(t){var n=I(t,(function(t){return Dt[t]||(Dt[t]=function(t){return new jt((function(n){var r=console[t];return console[t]=function(){var o=[].slice.call(arguments);r.apply(console,arguments);var i=$t();c((function(){n.notify(function(t,n,r){var o,i=I(t,(function(e){return function(e){if("string"==typeof e)return e;if(e instanceof Error)return At(nt(e));return Ze(e,void 0,2)}(e)})).join(" ");if(n===e.error){var s=function(e,t){for(var n=0;n<e.length;n+=1){var r=e[n];if(t(r,n,e))return r}}(t,(function(e){return e instanceof Error}));o={stack:s?Mt(nt(s)):void 0,causes:s?Pt(s,"console"):void 0,startClocks:te(),message:i,source:Ot,handling:ze,handlingStack:r}}return{api:n,message:i,error:o,handlingStack:r}}(o,t,i))}))},function(){console[t]=r}}))}(t)),Dt[t]}));return It.apply(this,n)}function qt(e,t,n,r){return Ft(e,[t],n,r)}function Ft(e,t,n,r){var o=u(r&&r.once?function(e){a(),n(e)}:n);r=r&&r.passive?{capture:r.capture,passive:r.passive}:r&&r.capture;var i=window.EventTarget&&e instanceof EventTarget?window.EventTarget.prototype:e,s=v(i,"addEventListener");T(t,(function(t){s.call(e,t,o,r)}));var a=function(){var n=v(i,"removeEventListener");T(t,(function(t){n.call(e,t,o,r)}))};return{stop:a}}var Wt={intervention:"intervention",deprecation:"deprecation",cspViolation:"csp_violation"};function Vt(e,t){var n=[];ue(t,Wt.cspViolation)&&n.push(new jt((function(e){return qt(document,De,(function(t){e.notify(function(e){var t="'"+e.blockedURI+"' blocked by '"+e.effectiveDirective+"' directive";return Nt({type:e.effectiveDirective,message:Wt.cspViolation+": "+t,originalError:e,csp:{disposition:e.disposition},stack:Qt(e.effectiveDirective,e.originalPolicy?"".concat(t,' of the policy "').concat(ae(e.originalPolicy,100),'"'):"no policy",e.sourceFile,e.lineNumber,e.columnNumber)})}(t))})).stop})));var r=j(t,(function(e){return e!==Wt.cspViolation}));return r.length&&n.push(function(e){return new jt((function(t){if(window.ReportingObserver){var n=u((function(e){T(e,(function(e){t.notify(function(e){var t=e.body,n=e.type;return Nt({type:t.id,message:n+": "+t.message,originalError:e,stack:Qt(t.id,t.message,t.sourceFile,t.lineNumber,t.columnNumber)})}(e))}))})),r=new window.ReportingObserver(n,{types:e,buffered:!0});return r.observe(),function(){r.disconnect()}}}))}(r)),It.apply(this,n)}function Nt(e){return L({startClocks:te(),source:ErrorSource.REPORT,handling:ErrorHandling.UNHANDLED},e)}function Qt(e,t,n,r,o){return n&&Mt({name:e,message:t,stack:[{func:"?",url:n,line:r,column:o}]})}var Ht=function(){this._events=[],this.pendingEvents=[]};Ht.prototype={emit:function(e){var t=[].slice.call(arguments,1);T(this._events,(function(n){if(n.type!==e)return!1;n.callback.apply(n.context,t)}))},on:function(e,t,n){"function"==typeof t&&this._events.push({type:e,callback:t,context:n||this})}};new Ht;var zt,Gt="RAW_LOG_COLLECTED",Jt="LOG_COLLECTED";function Xt(){this.callbacks={}}function Kt(e){return Zt(e,function(e){if(e.origin&&"null"!==e.origin)return e.origin;var t=e.host.replace(/(:80|:443)$/,"");return e.protocol+"//"+t}(window.location)).href}function Zt(e,t){if(function(){if(void 0!==zt)return zt;try{var e=new URL("http://test/path");return zt="http://test/path"===e.href}catch(e){zt=!1}return zt}())return void 0!==t?new URL(e,t):new URL(e);if(void 0===t&&!/:/.test(e))throw new Error("Invalid URL: "+e);var n=document,r=n.createElement("a");if(void 0!==t){var o=(n=document.implementation.createHTMLDocument("")).createElement("base");o.href=t,n.head.appendChild(o),n.body.appendChild(r)}return r.href=e,r}Xt.prototype={notify:function(e,t){var n=this.callbacks[e];n&&T(n,(function(e){e(t)}))},subscribe:function(e,t){this.callbacks[e]||(this.callbacks[e]=[]),this.callbacks[e].push(t);var n=this;return{unsubscribe:function(){n.callbacks[e]=j(n.callbacks[e],(function(e){return e!==t}))}}}};var Yt=navigator.userAgent.toLowerCase(),en=function(){return/iphone os/.test(Yt)};var tn,nn=/^\s+|\s+$/g,rn={rum:"/rum",log:"/logging",sessionReplay:"/rum/replay"};function on(e,t){var n=rn[t];if(!n)return"";var r=e.datakitOrigin||e.datakitUrl||e.site;0===r.indexOf("/")&&(r=location.origin+sn(r));var o=r;return o=r.lastIndexOf("/")===r.length-1?sn(r)+"v1/write"+n:sn(r)+"/v1/write"+n,e.site&&e.clientToken&&(o=o+"?token="+e.clientToken+"&to_headless=true"),o}function sn(e){return e.replace(nn,"")}function an(e,t){return"".concat(e,"_").concat(t&&t.crossSite?"cs1":"cs0","_").concat(t&&t.domain?"d1":"d0","_").concat(t&&t.secure?"sec1":"sec0","_").concat(t&&t.partitioned?"part1":"part0")}function un(e,t,n,r){var o=new Date;o.setTime(o.getTime()+n);var i="expires="+o.toUTCString(),s=r&&r.crossSite?"none":"strict",a=r&&r.domain?";domain="+r.domain:"",u=r&&r.secure?";secure":"",c=r&&r.partitioned?";partitioned":"";document.cookie=an(e,r)+"="+t+";"+i+";path=/;samesite="+s+a+u+c}function cn(e,t){return function(e,t){for(ie.lastIndex=0;;){var n=ie.exec(e);if(!n)break;if(n[1]===t)return n[2]}}(document.cookie,an(e,t))}function fn(e,t){un(e,"",0,t)}var ln=144e5,dn=9e5,pn="_gc_s";function vn(e,t){return function(e){if(Array.isArray(e))return e}(e)||function(e,t){var n=null==e?null:"undefined"!=typeof Symbol&&e[Symbol.iterator]||e["@@iterator"];if(null!=n){var r,o,i,s,a=[],u=!0,c=!1;try{if(i=(n=n.call(e)).next,0===t){if(Object(n)!==n)return;u=!1}else for(;!(u=(r=i.call(n)).done)&&(a.push(r.value),a.length!==t);u=!0);}catch(e){c=!0,o=e}finally{try{if(!u&&null!=n.return&&(s=n.return(),Object(s)!==s))return}finally{if(c)throw o}}return a}}(e,t)||function(e,t){if(e){if("string"==typeof e)return gn(e,t);var n={}.toString.call(e).slice(8,-1);return"Object"===n&&e.constructor&&(n=e.constructor.name),"Map"===n||"Set"===n?Array.from(e):"Arguments"===n||/^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(n)?gn(e,t):void 0}}(e,t)||function(){throw new TypeError("Invalid attempt to destructure non-iterable instance.\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method.")}()}function gn(e,t){(null==t||t>e.length)&&(t=e.length);for(var n=0,r=Array(t);n<t;n++)r[n]=e[n];return r}var yn=/^([a-zA-Z]+)=([a-z0-9-]+)$/,mn="&";function hn(e){return q(e)}function bn(e){return void 0!==e.isExpired||!((void 0===(t=e).created||re()-Number(t.created)<ln)&&(void 0===t.expire||re()<Number(t.expire)));var t}function _n(e){return I((t=e,n=[],T(t,(function(e,t){n.push([t,e])})),n),(function(e){return e[0]+"="+e[1]})).join("&");var t,n}function wn(e){var t={};return function(e){return!!e&&(-1!==e.indexOf(mn)||yn.test(e))}(e)&&e.split(mn).forEach((function(e){var n=yn.exec(e);if(null!==n){var r=vn(n,3),o=r[1],i=r[2];t[o]=i}})),t}function Sn(e){var t=function(e){var t={};t.secure=!!e.useSecureSessionCookie||!!e.usePartitionedCrossSiteSessionCookie||!!e.useCrossSiteSessionCookie,t.crossSite=!!e.usePartitionedCrossSiteSessionCookie||!!e.useCrossSiteSessionCookie,t.partitioned=!!e.usePartitionedCrossSiteSessionCookie,e.trackSessionAcrossSubdomains&&(t.domain=function(){if(void 0===tn){for(var e="gc_site_test_".concat(Q()),t=window.location.hostname.split("."),n=t.pop();t.length&&!cn(e,{domain:n});)n="".concat(t.pop(),".").concat(n),un(e,"test",K,{domain:n});fn(e,{domain:n}),tn=n}return tn}());return t}(e);return function(e){if(void 0===document.cookie||null===document.cookie)return!1;try{var t="gc_cookie_test_".concat(Q()),n="test";un(t,n,Z,e);var r=cn(t,e)===n;return fn(t,e),r}catch(e){return!1}}(t)?{type:"Cookie",cookieOptions:t}:void 0}function xn(e){var t;return{isLockEnabled:ye()===pe,persistSession:(t=e,function(e){un(pn,_n(e),dn,t)}),retrieveSession:On(e),expireSession:function(){return function(e){un(pn,_n({isExpired:"1"}),ln,e)}(e)}}}function On(e){return function(){return wn(cn(pn,e))}}function kn(e){localStorage.setItem(pn,_n(e))}function Cn(){return wn(localStorage.getItem(pn))}function En(){kn({isExpired:"1"})}var Tn,Ln=[];function $n(e,t){var n=arguments.length>2&&void 0!==arguments[2]?arguments[2]:0,r=t.isLockEnabled,o=t.persistSession,i=t.expireSession,s=function(e){return o(L({},e,{lock:u}))},a=function(){var e=t.retrieveSession(),n=e.lock;return e.lock&&delete e.lock,{session:e,lock:n}};if(Tn||(Tn=e),e===Tn)if(r&&n>=100)An(t);else{var u,c=a();if(r){if(c.lock)return void Mn(e,t,n);if(u=Q(),s(c.session),(c=a()).lock!==u)return void Mn(e,t,n)}var f=e.process(c.session);if(r&&(c=a()).lock!==u)Mn(e,t,n);else{if(f&&(bn(f)?i():(f.expire=String(re()+dn),r?s(f):o(f))),r&&(!f||!bn(f))){if((c=a()).lock!==u)return void Mn(e,t,n);o(c.session),f=c.session}e.after&&e.after(f||c.session),An(t)}}else Ln.push(e)}function Mn(e,t,n){g((function(){$n(e,t,n+1)}),10)}function An(e){Tn=void 0;var t=Ln.shift();t&&$n(t,e)}var Pn=K;function Rn(e){var t=Sn(e);return!t&&e.allowFallbackToLocalStorage&&(t=function(){try{var e=Q(),t="".concat("_gc_test_").concat(e);localStorage.setItem(t,e);var n=localStorage.getItem(t);return localStorage.removeItem(t),e===n?{type:"LocalStorage"}:void 0}catch(e){return}}()),t}function Bn(e,t,n){var r,o=new jt,i=new jt,s=new jt,a="Cookie"===e.type?xn(e.cookieOptions):{isLockEnabled:!1,persistSession:kn,retrieveSession:Cn,expireSession:En},u=a.expireSession,c=m((function(){$n({process:function(e){return bn(e)?{isExpired:"1"}:void 0},after:p},a)}),Pn);v();var f=N((function(){$n({process:function(e){if(!hn(e)){var r=p(e);return function(e){if(hn(e))return!1;var r=n(e[t]),o=r.trackingType,i=r.isTracked;e[t]=o,delete e.isExpired,i&&!e.id&&(e.id=Q(),e.created=String(re()))}(r),r}},after:function(e){hn(e)||g()||function(e){r=e,o.notify()}(e),r=e}},a)}),Pn),l=f.throttled,d=f.cancel;function p(e){return bn(e)&&(e={isExpired:"1"}),g()&&(!function(e){return r.id!==e.id||r[t]!==e[t]}(e)?(s.notify({previousState:r,newState:e}),r=e):(r={isExpired:"1"},i.notify())),e}function v(){$n({process:function(e){if(hn(e))return{isExpired:"1"}},after:function(e){r=e}},a)}function g(){return void 0!==r[t]}return{expandOrRenewSession:l,expandSession:function(){$n({process:function(e){return g()?p(e):void 0}},a)},getSession:function(){return r||{}},renewObservable:o,expireObservable:i,sessionStateUpdateObservable:s,restartSession:v,expire:function(){d(),u(),p({isExpired:"1"})},stop:function(){h(c)},updateSessionState:function(e){$n({process:function(t){return L({},t,e)},after:p},a)}}}function jn(e){if(void 0===e.sampleRate||fe(e.sampleRate))if(void 0===e.sessionSampleRate||fe(e.sessionSampleRate)){if(void 0===e.telemetrySampleRate||fe(e.telemetrySampleRate)){var t=be(e.sessionSampleRate,e.sampleRate);return L({beforeSend:e.beforeSend&&l(e.beforeSend,"beforeSend threw an error:"),sessionStoreStrategyType:Rn(e),sessionSampleRate:be(t,100),service:e.service,version:e.version,env:e.env,telemetrySampleRate:be(e.telemetrySampleRate,100),telemetryEnabled:be(e.telemetryEnabled,!1),silentMultipleInit:!!e.silentMultipleInit,batchBytesLimit:16384,eventRateLimiterThreshold:3e3,maxTelemetryEventsPerPage:15,flushTimeout:3e4,batchMessagesLimit:50,messageBytesLimit:262144,resourceUrlLimit:5120,storeContextsToLocal:!!e.storeContextsToLocal,storeContextsKey:e.storeContextsKey,sendContentTypeByJson:!!e.sendContentTypeByJson,retryMaxSize:be(e.retryMaxSize,-1)},function(e){var t=function(e){return!1};"isIntakeUrl"in e&&P(e.isIntakeUrl)&&W(e.isIntakeUrl())&&(t=e.isIntakeUrl);var n=function(e){return!1};return"isServerError"in e&&P(e.isServerError)&&W(e.isServerError())&&(n=e.isServerError),{rumEndpoint:on(e,"rum"),logsEndpoint:on(e,"log"),sessionReplayEndPoint:on(e,"sessionReplay"),isIntakeUrl:t,isServerError:n}}(e))}i.error("Telemetry Sample Rate should be a number between 0 and 100")}else i.error("Sample Rate should be a number between 0 and 100");else i.error("Sample Rate should be a number between 0 and 100")}var In,Dn;function Un(){return In||(In=new jt((function(e){if(window.fetch){var t=Rt(window,"fetch",(function(t){return function(e,t){var n=e.parameters,r=e.onPostCall,o=e.handlingStack,i=n[0],s=n[1],a=s&&s.method;void 0===a&&i instanceof Request&&(a=i.method);var c=void 0!==a?String(a).toUpperCase():"GET",f=i instanceof Request?i.url:Kt(String(i)),l=te(),d={state:"start",init:s,input:i,method:c,startClocks:l,url:f,handlingStack:o};t.notify(d),n[0]=d.input,n[1]=d.init,r((function(e){return function(e,t,n){var r=n,o=function(t){r.state="resolve",L(r,t),e.notify(r)};t.then(u((function(e){var t="";try{t=e.constructor===Response&&e.type||""}catch(e){t=""}o({response:e,responseType:t,status:e.status,isAborted:!1})})),u((function(e){o({status:0,isAborted:r.init&&r.init.signal&&r.init.signal.aborted||e instanceof DOMException&&e.code===DOMException.ABORT_ERR,error:e})})))}(t,e,d)}))}(t,e)}),{computeHandlingStack:!0});return t.stop}}))),In}var qn=new WeakMap;function Fn(){return Dn||(Dn=new jt((function(e){var t=Rt(XMLHttpRequest.prototype,"open",Wn),n=Rt(XMLHttpRequest.prototype,"send",(function(t){!function(e,t){var n=e.target,r=e.handlingStack,o=qn.get(n);if(o){var i=o;i.state="start",i.startClocks=te(),i.isAborted=!1,i.xhr=n,i.handlingStack=r;var s=!1,a=Rt(n,"onreadystatechange",(function(){n.readyState===XMLHttpRequest.DONE&&u()})).stop,u=function(){if(c(),a(),!s){s=!0;var e,r=o;r.state="complete",r.duration=(e=i.startClocks.timeStamp,ne()-e),r.status=n.status,t.notify(L({},r))}},c=qt(n,"loadend",u).stop;t.notify(i)}}(t,e)}),{computeHandlingStack:!0}),r=Rt(XMLHttpRequest.prototype,"abort",Vn);return function(){t.stop(),n.stop(),r.stop()}}))),Dn}function Wn(e){var t=e.target,n=e.parameters[0],r=e.parameters[1];qn.set(t,{state:"open",method:String(n).toUpperCase(),url:Kt(String(r))})}function Vn(e){var t=e.target,n=qn.get(t);n&&(n.isAborted=!0)}var Nn={HIDDEN:"visibility_hidden",UNLOADING:"before_unload",PAGEHIDE:"page_hide",FROZEN:"page_frozen"};var Qn={sdk_name:"_gc.sdk_name",sdk_version:"_gc.sdk_version",app_id:"application.id",env:"env",service:"service",version:"version",source:"source",userid:"user.id",user_email:"user.email",user_name:"user.name",session_id:"session.id",session_type:"session.type",session_sampling:"session.is_sampling",is_signin:"user.is_signin",os:"device.os",os_version:"device.os_version",os_version_major:"device.os_version_major",browser:"device.browser",browser_version:"device.browser_version",browser_version_major:"device.browser_version_major",screen_size:"device.screen_size",network_type:"device.network_type",time_zone:"device.time_zone",device:"device.device",view_id:"view.id",view_referrer:"view.referrer",view_url:"view.url",view_host:"view.host",view_path:"view.path",view_name:"view.name",view_path_group:"view.path_group"},Hn={view_url_query:"view.url_query",action_id:"action.id",action_ids:"action.ids",view_in_foreground:"view.in_foreground",display:"display",session_has_replay:"session.has_replay",is_login:"user.is_login",page_states:"_gc.page_states",session_sample_rate:"_gc.configuration.session_sample_rate",session_replay_sample_rate:"_gc.configuration.session_replay_sample_rate",session_on_error_sample_rate:"_gc.configuration.session_on_error_sample_rate",session_replay_on_error_sample_rate:"_gc.configuration.session_replay_on_error_sample_rate",drift:"_gc.drift"},zn={view:{type:Ve,tags:{view_loading_type:"view.loading_type",view_apdex_level:"view.apdex_level",view_privacy_replay_level:"privacy.replay_level"},fields:{sampled_for_replay:"session.sampled_for_replay",sampled_for_error_replay:"session.sampled_for_error_replay",sampled_for_error_session:"session.sampled_for_error_session",session_error_timestamp:"session.error_timestamp_for_session",is_active:"view.is_active",session_replay_stats:"_gc.replay_stats",session_is_active:"session.is_active",view_error_count:"view.error.count",view_resource_count:"view.resource.count",view_long_task_count:"view.long_task.count",view_action_count:"view.action.count",first_contentful_paint:"view.first_contentful_paint",largest_contentful_paint:"view.largest_contentful_paint",largest_contentful_paint_element_selector:"view.largest_contentful_paint_element_selector",cumulative_layout_shift:"view.cumulative_layout_shift",cumulative_layout_shift_time:"view.cumulative_layout_shift_time",cumulative_layout_shift_target_selector:"view.cumulative_layout_shift_target_selector",first_input_delay:"view.first_input_delay",loading_time:"view.loading_time",dom_interactive:"view.dom_interactive",dom_content_loaded:"view.dom_content_loaded",dom_complete:"view.dom_complete",load_event:"view.load_event",first_input_time:"view.first_input_time",first_input_target_selector:"view.first_input_target_selector",first_paint_time:"view.fpt",interaction_to_next_paint:"view.interaction_to_next_paint",interaction_to_next_paint_target_selector:"view.interaction_to_next_paint_target_selector",resource_load_time:"view.resource_load_time",time_to_interactive:"view.tti",dom:"view.dom",dom_ready:"view.dom_ready",time_spent:"view.time_spent",first_byte:"view.first_byte",frustration_count:"view.frustration.count",custom_timings:"view.custom_timings"}},resource:{type:Ne,tags:{trace_id:"_gc.trace_id",span_id:"_gc.span_id",resource_id:"resource.id",resource_status:"resource.status",resource_status_group:"resource.status_group",resource_method:"resource.method"},fields:{duration:"resource.duration",resource_size:"resource.size",resource_url:"resource.url",resource_url_host:"resource.url_host",resource_url_path:"resource.url_path",resource_url_path_group:"resource.url_path_group",resource_url_query:"resource.url_query",resource_delivery_type:"resource.delivery_type",resource_type:"resource.type",resource_protocol:"resource.protocol",resource_encode_size:"resource.encoded_body_size",resource_decode_size:"resource.decoded_body_size",resource_transfer_size:"resource.transfer_size",resource_render_blocking_status:"resource.render_blocking_status",resource_dns:"resource.dns",resource_tcp:"resource.tcp",resource_ssl:"resource.ssl",resource_ttfb:"resource.ttfb",resource_trans:"resource.trans",resource_redirect:"resource.redirect",resource_first_byte:"resource.firstbyte",resource_dns_time:"resource.dns_time",resource_download_time:"resource.download_time",resource_first_byte_time:"resource.first_byte_time",resource_connect_time:"resource.connect_time",resource_ssl_time:"resource.ssl_time",resource_redirect_time:"resource.redirect_time"}},error:{type:Fe,tags:{error_id:"error.id",trace_id:"_gc.trace_id",span_id:"_gc.span_id",error_source:"error.source",error_type:"error.type",error_handling:"error.handling"},fields:{error_message:["string","error.message"],error_stack:["string","error.stack"],error_causes:["string","error.causes"],error_handling_stack:["string","error.handling_stack"]}},long_task:{type:We,tags:{long_task_id:"long_task.id"},fields:{duration:"long_task.duration",blocking_duration:"long_task.blocking_duration",first_ui_event_timestamp:"long_task.first_ui_event_timestamp",render_start:"long_task.render_start",style_and_layout_start:"long_task.style_and_layout_start",long_task_start_time:"long_task.start_time",scripts:["string","long_task.scripts"]}},action:{type:qe,tags:{action_type:"action.type"},fields:{action_name:"action.target.name",duration:"action.loading_time",action_error_count:"action.error.count",action_resource_count:"action.resource.count",action_frustration_types:"action.frustration.type",action_long_task_count:"action.long_task.count",action_target:"_gc.action.target",action_position:"_gc.action.position"}},telemetry:{type:"telemetry",fields:{status:"telemetry.status",message:["string","telemetry.message"],type:"telemetry.type",error_stack:["string","telemetry.error.stack"],error_kind:["string","telemetry.error.kind"],connectivity:["string","telemetry.connectivity"],runtime_env:["string","telemetry.runtime_env"],usage:["string","telemetry.usage"],configuration:["string","telemetry.configuration"]}},browser_log:{type:Qe,tags:{error_source:"error.source",error_type:"error.type",error_resource_url:"http.url",error_resource_url_host:"http.url_host",error_resource_url_path:"http.url_path",error_resource_url_path_group:"http.url_path_group",error_resource_status:"http.status_code",error_resource_status_group:"http.status_group",error_resource_method:"http.method",action_id:"user_action.id",service:"service",status:"status"},fields:{message:["string","message"],error_message:["string","error.message"],error_stack:["string","error.stack"]}}},Gn=Z,Jn=ln,Xn=[];function Kn(e,t,n){var r=new jt,o=new jt,i=Bn(e.sessionStoreStrategyType,t,n);Xn.push((function(){return i.stop()}));var s,a=function(e){var t=e.expireDelay,n=e.maxEntries,r=[];function o(){for(var e=ee()-t;r.length>0&&r[r.length-1].endTime<e;)r.pop()}return Oe&&(Oe=m((function(){return o()}),6e4)),ke.add(o),{add:function(e,t){var o={value:e,startTime:t,endTime:xe,remove:function(){we(r,o)},close:function(e){o.endTime=e}};return n&&r.length>=n&&r.pop(),r.unshift(o),o},find:function(e,t){void 0===e&&(e=xe),void 0===t&&(t={returnInactive:!1});for(var n=0,o=r;n<o.length;n++){var i=o[n];if(i.startTime<=e){if(t.returnInactive||e<=i.endTime)return i.value;break}}},closeActive:function(e){var t=r[0];t&&t.endTime===xe&&t.close(e)},findAll:function(e,t){void 0===e&&(e=xe),void 0===t&&(t=0);var n=e+t;return r.filter((function(t){return t.startTime<=n&&e<=t.endTime})).map((function(e){return e.value}))},reset:function(){r=[]},stop:function(){ke.delete(o),0===ke.size&&Oe&&(h(Oe),Oe=null)}}}({expireDelay:Jn});function u(){return{id:i.getSession().id,trackingType:i.getSession()[t],hasError:!!i.getSession().hasError}}return Xn.push((function(){return a.stop()})),i.renewObservable.subscribe((function(){a.add(u(),ee()),r.notify()})),i.expireObservable.subscribe((function(){o.notify(),a.closeActive(ee())})),i.expandOrRenewSession(),a.add(u(),[0,oe()][0]),s=Ft(window,[Me,Re,Ae,Pe],(function(){i.expandOrRenewSession()}),{capture:!0,passive:!0}).stop,Xn.push(s),function(e){var t=function(){"visible"===document.visibilityState&&e()},n=qt(document,Be,t).stop;Xn.push(n);var r=m(t,Gn);Xn.push((function(){h(r)}))}((function(){return i.expandSession()})),function(e){var t=qt(window,Ie,e,{capture:!0}).stop;Xn.push(t)}((function(){i.restartSession()})),{findSession:function(e,t){return a.find(e,t)},renewObservable:r,expireObservable:o,sessionStateUpdateObservable:i.sessionStateUpdateObservable,expire:i.expire,updateSessionState:i.updateSessionState}}var Zn=3145728,Yn=K,er=0,tr=1,nr=2,rr=0,or=1;function ir(e,t,n,r,o){t.transportStatus===er&&0===t.queuedPayloads.size()&&t.bandwidthMonitor.canHandle(e)?ar(e,t,n,{onSuccess:function(){return ur(rr,t,n,r,o)},onFailure:function(){t.queuedPayloads.enqueue(e),sr(t,n,r,o)}}):t.queuedPayloads.enqueue(e)}function sr(e,t,n,r){e.transportStatus===nr&&g((function(){ar(e.queuedPayloads.first(),e,t,{onSuccess:function(){e.queuedPayloads.dequeue(),e.currentBackoffTime=Yn,ur(or,e,t,n,r)},onFailure:function(){e.currentBackoffTime=Math.min(256e3,2*e.currentBackoffTime),sr(e,t,n,r)}})}),e.currentBackoffTime)}function ar(e,t,n,r){var o=r.onSuccess,i=r.onFailure;t.bandwidthMonitor.add(e),n(e,(function(n){t.bandwidthMonitor.remove(e),!function(e,t,n){return!(t.retryMaxSize>-1&&n.retry&&n.retry.count>t.retryMaxSize)&&("opaque"!==e.type&&(0===e.status&&!navigator.onLine||408===e.status||429===e.status||e.status>=500))}(n,t,e)?(t.transportStatus=er,o()):(t.transportStatus=t.bandwidthMonitor.ongoingRequestCount>0?tr:nr,e.retry={count:e.retry?e.retry.count+1:1,lastFailureStatus:n.status},i())}))}function ur(e,t,n,r,o){e===rr&&t.queuedPayloads.isFull()&&!t.queueFullReported&&(o({message:"Reached max "+r+" events size queued for upload: 3MiB",source:xt,startClocks:te()}),t.queueFullReported=!0);var i=t.queuedPayloads;for(t.queuedPayloads=cr();i.size()>0;)ir(i.dequeue(),t,n,r,o)}function cr(){var e=[];return{bytesCount:0,enqueue:function(t){this.isFull()||(e.push(t),this.bytesCount+=t.bytesCount)},first:function(){return e[0]},dequeue:function(){var t=e.shift();return t&&(this.bytesCount-=t.bytesCount),t},size:function(){return e.length},isFull:function(){return this.bytesCount>=Zn}}}function fr(){var e,t=window.navigator;return{status:t.onLine?"connected":"not_connected",interfaces:t.connection&&t.connection.type?[t.connection.type]:void 0,effective_type:null===(e=t.connection)||void 0===e?void 0:e.effectiveType}}var lr="log",dr="configuration",pr="debug",vr="error",gr=["https://static.guance.com","http://localhost","<anonymous>"],yr="browser-logs-sdk",mr=Se(),hr=function(e){mr.add((function(){hr(e)}))};function br(e,t){var n,o=new jt,i=new Set,s=t.telemetryEnabled&&Y(t.telemetrySampleRate),a={is_local_file:"file:"===window.location.protocol,is_worker:"WorkerGlobalScope"in self};return hr=function(r){var u=Ze(r);if(s&&i.size<t.maxTelemetryEventsPerPage&&!i.has(u)){var c=function(e,t,r){return M({type:"telemetry",date:ne(),service:e,version:"3.2.28",source:"browser",telemetry:M(t,{runtime_env:r,connectivity:fr()})},void 0!==n?n():{})}(e,r,a);o.notify(c),i.add(u)}},r=_r,{setContextProvider:function(e){n=e},observable:o,enabled:s}}function _r(e,t){hr(L({type:lr,status:vr},function(e){if(e instanceof Error){var t=nt(e);return{error:{kind:t.name,stack:Mt(wr(t))},message:t.message}}return{error:{stack:St},message:Je+" "+Ze(e)}}(e),t))}function wr(e){return e.stack=e.stack.filter((function(e){return!e.url||gr.some((function(t){return _e(e.url,t)}))})),e}function Sr(e,t){return e?(e=e+(-1===e.indexOf("?")?"?":"&")+"precision=ms",t&&(e=e+"&encoding="+t),e):e}function xr(e,t,n,r){void 0===n&&(n=-1);var o=function(e){return{transportStatus:er,currentBackoffTime:Yn,bandwidthMonitor:{ongoingRequestCount:0,ongoingByteCount:0,canHandle:function(e){return 0===this.ongoingRequestCount||this.ongoingByteCount+e.bytesCount<=81920&&this.ongoingRequestCount<32},add:function(e){this.ongoingRequestCount+=1,this.ongoingByteCount+=e.bytesCount},remove:function(e){this.ongoingRequestCount-=1,this.ongoingByteCount-=e.bytesCount}},queuedPayloads:cr(),queueFullReported:!1,retryMaxSize:e}}(n),i=function(n,r){return function(e,t,n,r){var o=n.data,i=n.bytesCount,s=Sr(e,n.encoding),a=function(){try{return window.Request&&"keepalive"in new Request("http://a")}catch(e){return!1}}()&&i<t;if(a){var c={method:"POST",body:o,keepalive:!0,mode:"cors"};n.type&&(c.headers={"Content-Type":n.type}),fetch(s,c).then(u((function(e){"function"==typeof r&&r({status:e.status,type:e.type})})),u((function(){kr(s,n,r)})))}else kr(s,n,r)}(e,t,n,r)};return{send:function(t){ir(t,o,i,e,r)},sendOnExit:function(n){!function(e,t,n){var r=n.data,o=n.bytesCount,i=Sr(e,n.encoding),s=!!navigator.sendBeacon&&o<t;if(s)try{var a;if(a=n.type?new Blob([r],{type:n.type}):r,navigator.sendBeacon(i,a))return}catch(e){!function(e){Or||(Or=!0,_r(e))}(e)}kr(i,n)}(e,t,n)}}}var Or=!1;function kr(e,t,n){var r=t.data,o=new XMLHttpRequest;o.open("POST",e,!0),r instanceof Blob?o.setRequestHeader("Content-Type",r.type):t.type&&o.setRequestHeader("Content-Type",t.type),qt(o,"loadend",(function(){"function"==typeof n&&n({status:o.status})}),{once:!0}),o.send(r)}function Cr(e){return Cr="function"==typeof Symbol&&"symbol"==typeof Symbol.iterator?function(e){return typeof e}:function(e){return e&&"function"==typeof Symbol&&e.constructor===Symbol&&e!==Symbol.prototype?"symbol":typeof e},Cr(e)}function Er(e){if("object"===Cr(e)&&e)e=Ze(e);else if(!F(e))return e;return String(e).replace(/[\s=,"]/g,(function(e){return"\\"+e}))}function Tr(e,t){return"object"===Cr(e)&&e?e=Ze(e):t&&(e=""+e),e}function Lr(e){return'"'+e.replace(/\\/g,"\\\\").replace(/"/g,'\\"')+'"'}function $r(e){return"object"===Cr(e)&&e?Lr(Ze(e)):F(e)?Lr(e):e}var Mr="custom_keys",Ar=function(e){if(!e||!e.type)return{rowStr:"",rowData:void 0};var t={tags:{},fields:{}},n=!1,r="";return T(zn,(function(o,i){if(o.type===e.type){r+=i+",",t.measurement=i;var s=[],a=$({},Qn,o.tags),u=["date","type",Mr];T(a,(function(n,r){var o=se(e,n);u.push(r),(o||V(o))&&(t.tags[r]=Tr(o,!0),s.push(Er(r)+"="+Er(o)))}));var c=[],f=$({},Hn,o.fields);if(T(f,(function(n,r){if(A(n)&&2===n.length){var o=n[1],i=se(e,o);u.push(r),null!=i&&(t.fields[r]=Tr(i),c.push(Er(r)+"="+$r(i)))}else if(F(n)){i=se(e,n);u.push(r),null!=i&&(t.fields[r]=Tr(i),c.push(Er(r)+"="+$r(i)))}})),e.context&&U(e.context)&&!q(e.context)){var l=[];T(e.context,(function(e,n){u.indexOf(n)>-1||(u.push(n),null!=e&&(l.push(n),t.fields[n]=Tr(e),c.push(Er(n)+"="+$r(e))))})),l.length&&(t.fields[Mr]=Tr(l),c.push(Er(Mr)+"="+$r(l)))}e.type===Qe&&T(e,(function(e,n){-1===u.indexOf(n)&&null!=e&&(t.fields[n]=Tr(e),c.push(Er(n)+"="+$r(e)))})),s.length&&(r+=s.join(",")),c.length&&(r+=" ",r+=c.join(","),n=!0),r=r+" "+e.date,t.time=e.date}})),{rowStr:n?r:"",rowData:n?t:void 0}};function Pr(e){var t=e.encoder,n=e.request,r=e.messageBytesLimit,o=e.sendContentTypeByJson,s=e.flushController,a={},u=s.flushObservable.subscribe((function(e){!function(e){var r=R(a).join(o?",":"\n");a={};var i=(u=e.reason,ue(R(Nn),u)),s=i?n.sendOnExit:n.send;var u;if(i&&t.isAsync){var f=t.finishSync();f.outputBytesCount&&s(Rr(f,o));var l=[f.pendingData,r].filter(Boolean).join("\n");l&&s({data:l,bytesCount:yt(l)})}else{if(r){var d=c([r],t.isEmpty());o&&(d+="]"),t.write(d)}else o&&t.write("]");t.finish((function(e){s(Rr(e))}))}}(e)}));function c(e){var t=arguments.length>1&&void 0!==arguments[1]&&arguments[1];return o?t?"["+e.join(","):","+e.join(","):t?e.join("\n"):"\n"+e.join("\n")}function f(e,n){var u=function(e){return o?Ze(Ar(e).rowData):Ar(e).rowStr}(e),f=t.estimateEncodedBytesCount(u);f>=r?i.warn("Discarded a message whose size was bigger than the maximum allowed size ".concat(r,"KB.")):(function(e){return void 0!==e&&void 0!==a[e]}(n)&&function(e){var n=a[e];delete a[e];var r=t.estimateEncodedBytesCount(n);s.notifyAfterRemoveMessage(r)}(n),function(e,n,r){s.notifyBeforeAddMessage(n),void 0!==r?(a[r]=e,s.notifyAfterAddMessage()):t.write(c([e],t.isEmpty()),(function(e){s.notifyAfterAddMessage(e-n)}))}(u,f,n))}return{flushController:s,add:f,upsert:f,stop:u.unsubscribe}}function Rr(e,t){return{data:"string"==typeof e.output?e.output:new Blob([e.output],{type:"text/plain"}),type:t?"application/json;UTF-8":void 0,bytesCount:e.outputBytesCount,encoding:e.encoding}}function Br(e){var t=e.messagesLimit,n=e.bytesLimit,r=e.durationLimit,o=e.pageExitObservable,i=e.sessionExpireObservable;o.subscribe((function(e){return f(e.reason)})),i.subscribe((function(){return f("session_expire")}));var s,a=new jt((function(){return function(){pageExitSubscription.unsubscribe(),sessionExpireSubscription.unsubscribe()}})),u=0,c=0;function f(e){if(0!==c){var t=c,n=u;c=0,u=0,l(),a.notify({reason:e,messagesCount:t,bytesCount:n})}}function l(){y(s),s=void 0}return{flushObservable:a,getMessagesCount:function(){return c},notifyBeforeAddMessage:function(e){u+e>=n&&f("bytes_limit"),c+=1,u+=e,void 0===s&&(s=g((function(){f("duration_limit")}),r))},notifyAfterAddMessage:function(e){void 0===e&&(e=0),u+=e,c>=t?f("messages_limit"):u>=n&&f("bytes_limit")},notifyAfterRemoveMessage:function(e){u-=e,0===(c-=1)&&l()}}}function jr(e,t,n,r,o,i){void 0===i&&(i=Pr);var s=function(e,t){return i({encoder:t.encoder,request:xr(t.endpoint,e.batchBytesLimit,e.retryMaxSize,n),flushController:Br({messagesLimit:e.batchMessagesLimit,bytesLimit:e.batchBytesLimit,durationLimit:e.flushTimeout,pageExitObservable:r,sessionExpireObservable:o}),messageBytesLimit:e.messageBytesLimit,sendContentTypeByJson:e.sendContentTypeByJson})}(e,t);return{flushObservable:s.flushController.flushObservable,add:function(e){s.add(e)},upsert:function(e,t){s.upsert(e,t)},stop:function(){s.stop()}}}function Ir(){return p().FTWebViewJavascriptBridge}function Dr(){var e=Ir();if(e)return{getCapabilities:function(){return JSON.parse(e.getCapabilities&&e.getCapabilities()||"[]")},getPrivacyLevel:function(){return e.getPrivacyLevel&&e.getPrivacyLevel()},getAllowedWebViewHosts:function(){return JSON.parse(e.getAllowedWebViewHosts&&e.getAllowedWebViewHosts()||"[]")},send:function(t,n,r){var o=r?{id:r}:void 0;e.sendEvent(JSON.stringify({name:t,data:n,view:o}))}}}function Ur(){var e,t=arguments.length>0&&void 0!==arguments[0]?arguments[0]:null===(e=p().location)||void 0===e?void 0:e.hostname,n=Ir();if(n&&void 0===n.getAllowedWebViewHosts)return!0;if(n&&n.getAllowedWebViewHosts&&(null===n.getAllowedWebViewHosts()||void 0===n.getAllowedWebViewHosts()))return!0;var r=Dr();return!!r&&r.getAllowedWebViewHosts().some((function(e){return t===e||t.endsWith(".".concat(e))}))}function qr(e){return qr="function"==typeof Symbol&&"symbol"==typeof Symbol.iterator?function(e){return typeof e}:function(e){return e&&"function"==typeof Symbol&&e.constructor===Symbol&&e!==Symbol.prototype?"symbol":typeof e},qr(e)}function Fr(e,t){return function(e){if(Array.isArray(e))return e}(e)||function(e,t){var n=null==e?null:"undefined"!=typeof Symbol&&e[Symbol.iterator]||e["@@iterator"];if(null!=n){var r,o,i,s,a=[],u=!0,c=!1;try{if(i=(n=n.call(e)).next,0===t){if(Object(n)!==n)return;u=!1}else for(;!(u=(r=i.call(n)).done)&&(a.push(r.value),a.length!==t);u=!0);}catch(e){c=!0,o=e}finally{try{if(!u&&null!=n.return&&(s=n.return(),Object(s)!==s))return}finally{if(c)throw o}}return a}}(e,t)||function(e,t){if(e){if("string"==typeof e)return Wr(e,t);var n={}.toString.call(e).slice(8,-1);return"Object"===n&&e.constructor&&(n=e.constructor.name),"Map"===n||"Set"===n?Array.from(e):"Arguments"===n||/^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(n)?Wr(e,t):void 0}}(e,t)||function(){throw new TypeError("Invalid attempt to destructure non-iterable instance.\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method.")}()}function Wr(e,t){(null==t||t>e.length)&&(t=e.length);for(var n=0,r=Array(t);n<t;n++)r[n]=e[n];return r}function Vr(e,t){var n=Object.keys(e);if(Object.getOwnPropertySymbols){var r=Object.getOwnPropertySymbols(e);t&&(r=r.filter((function(t){return Object.getOwnPropertyDescriptor(e,t).enumerable}))),n.push.apply(n,r)}return n}function Nr(e,t,n){return(t=function(e){var t=function(e,t){if("object"!=qr(e)||!e)return e;var n=e[Symbol.toPrimitive];if(void 0!==n){var r=n.call(e,t||"default");if("object"!=qr(r))return r;throw new TypeError("@@toPrimitive must return a primitive value.")}return("string"===t?String:Number)(e)}(e,"string");return"symbol"==qr(t)?t:t+""}(t))in e?Object.defineProperty(e,t,{value:n,enumerable:!0,configurable:!0,writable:!0}):e[t]=n,e}function Qr(e,t,n){for(var r=function(e){for(var t=1;t<arguments.length;t++){var n=null!=arguments[t]?arguments[t]:{};t%2?Vr(Object(n),!0).forEach((function(t){Nr(e,t,n[t])})):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(n)):Vr(Object(n)).forEach((function(t){Object.defineProperty(e,t,Object.getOwnPropertyDescriptor(n,t))}))}return e}({},e),o=0,s=Object.entries(t);o<s.length;o++){var a=Fr(s[o],2),u=a[0],c=a[1],f=c.required;"string"===c.type&&u in r&&(r[u]=String(r[u])),f&&!(u in e)&&i.warn("The property ".concat(u," of ").concat(n," context is required; context will not be sent to the intake."))}return r}function Hr(){var e=arguments.length>0&&void 0!==arguments[0]?arguments[0]:"",t=arguments.length>1&&void 0!==arguments[1]?arguments[1]:{},n=t.customerDataTracker,r=t.propertiesConfig,o=void 0===r?{}:r,i={},s=new jt,a={getContext:function(){return G(i)},setContext:function(t){"object"===H(t)?(i=ht(Qr(t,o,e)),null==n||n.updateCustomerData(i)):a.clearContext(),s.notify()},setContextProperty:function(t,r){i[t]=ht(Qr(Nr({},t,r),o,e)[t]),null==n||n.updateCustomerData(i),s.notify()},removeContextProperty:function(t){delete i[t],null==n||n.updateCustomerData(i),Qr(i,o,e),s.notify()},clearContext:function(){i={},null==n||n.resetCustomerData(),s.notify()},changeObservable:s};return a}var zr="user",Gr="global context",Jr="_gc_s",Xr=[];function Kr(e,t,n,r){var o=function(e,t,n){return e.storeContextsKey&&F(e.storeContextsKey)?Jr+"_"+t+"_"+n+"_"+e.storeContextsKey:Jr+"_"+t+"_"+n}(e,n,r);function i(){var e=localStorage.getItem(o);return null!==e?JSON.parse(e):{}}return Xr.push(qt(window,Ue,(function(e){o===e.key&&t.setContext(i())}))),t.changeObservable.subscribe((function(){localStorage.setItem(o,JSON.stringify(t.getContext()))})),t.setContext(M(i(),t.getContext())),t}var Zr=0,Yr=2;function eo(){var e=arguments.length>0&&void 0!==arguments[0]?arguments[0]:Yr,t=new Map,n=!1;function r(){if(!n&&e!==Zr){var r=e===Yr?3072:16384,o=arguments.length>0&&void 0!==arguments[0]?arguments[0]:0;t.forEach((function(e){o+=e.getBytesCount()})),o>r&&(!function(e){i.warn("Customer data exceeds the recommended ".concat(e/vt,"KiB threshold."))}(r),n=!0)}}return{createDetachedTracker:function(){var e=to((function(){return r(e.getBytesCount())}));return e},getOrCreateTracker:function(e){return t.has(e)||t.set(e,to(r)),t.get(e)},setCompressionStatus:function(t){e===Zr&&(e=t,r())},getCompressionStatus:function(){return e},stop:function(){t.forEach((function(e){return e.stop()})),t.clear()}}}function to(e){var t=0,n=N((function(n){t=yt(Ze(n)),e()}),200),r=n.throttled,o=n.cancel,i=function(){o(),t=0};return{updateCustomerData:function(e){q(e)?i():r(e)},resetCustomerData:i,getBytesCount:function(){return t},stop:function(){o()}}}function no(){var e="",t=0;return{isAsync:!1,isEmpty:function(){return!e},write:function(n,r){var o=yt(n);t+=o,e+=n,r&&r(o)},finish:function(e){e(this.finishSync())},finishSync:function(){var n={output:e,outputBytesCount:t,rawBytesCount:t,pendingData:""};return e="",t=0,n},estimateEncodedBytesCount:function(e){return e.length}}}function ro(e){this.map=new WeakMap,e&&e.forEach((function(e){this.map.set(e,1)}))}function oo(e,t){t.silentMultipleInit||i.error(e+" is already initialized.")}ro.prototype.add=function(e){return this.map.set(e,1),this},ro.prototype.delete=function(e){return this.map.delete(e)},ro.prototype.has=function(e){return this.map.has(e)};var io={ok:0,debug:1,info:2,notice:4,warn:5,error:6,critical:7,alert:8,emerg:9};function so(e){return{handleLog:function(t,r,o,i,s){var a=M(r.getContext(),t.context);if(ao(t.status,fo.console,r)&&function(e,t){var r=e.status,o=e.message;n[loggerToConsoleApiName[r]].call(globalConsole,o,t)}(t,a),ao(t.status,fo.http,r)){var u={rawLogsEvent:{date:s||ne(),message:t.message,status:t.status,origin:Et},messageContext:a,savedCommonContext:i};o&&(u.domainContext={handlingStack:o}),e.notify(Gt,u)}}}}function ao(e,t,n){var r=n.getHandler(),o=A(r)?r:[r];return io[e]>=io[n.getLevel()]&&ue(o,t)}function uo(e,t){void 0===t&&(t={});var n=t.includeMessage||!1;return{stack:e.stack,kind:e.type,message:n?e.message:void 0,causes:e.causes,handling:e.handling}}var co={ok:"ok",debug:"debug",info:"info",notice:"notice",warn:"warn",error:"error",critical:"critical",alert:"alert",emerg:"emerg"},fo={console:"console",http:"http",silent:"silent"},lo=B(co);function po(e,t,n,r,o,i){void 0===r&&(r=fo.http),void 0===o&&(o=co.debug),void 0===i&&(i={}),this.contextManager=Hr("logger",{customerDataTracker:t}),this.handleLogStrategy=e,this.handlerType=r,this.level=o,this.contextManager.setContext(i),n&&this.contextManager.setContextProperty("logger",{name:n})}function vo(e){return function(t,n,r){var o;ao(e,fo.http,this)&&(o=$t()),this.logImplementation(t,n,e,r,o)}}po.prototype={logImplementation:u((function(e,t,n,r,o){void 0===n&&(n=co.info);var i,s=ht(t);if(null!=r){var a=Lt({stackTrace:r instanceof Error?nt(r):void 0,originalError:r,nonErrorPrefix:Xe,source:Et,handling:ze,startClocks:te()});i=M({error:uo(a,{includeMessage:!0})},s)}else i=s;this.handleLogStrategy({message:ht(e),context:i,status:n},this,o)})),log:function(e,t,n,r){var o;ao(n,fo.http,this)&&(o=$t()),this.logImplementation(e,t,n,r,o)},setContext:function(e){this.contextManager.setContext(e)},getContext:function(){return this.contextManager.getContext()},setContextProperty:function(e,t){this.contextManager.setContextProperty(e,t)},addContext:function(e,t){this.contextManager.setContextProperty(e,t)},removeContextProperty:function(e){this.contextManager.removeContextProperty(e)},removeContext:function(e){this.contextManager.removeContextProperty(e)},clearContext:function(){this.contextManager.clearContext()},setHandler:function(e){this.handlerType=e},getHandler:function(){return this.handlerType},setLevel:function(e){this.level=e},getLevel:function(){return this.level}},po.prototype.ok=vo(co.ok),po.prototype.debug=vo(co.debug),po.prototype.info=vo(co.info),po.prototype.notice=vo(co.notice),po.prototype.warn=vo(co.warn),po.prototype.error=vo(co.error),po.prototype.critical=vo(co.critical),po.prototype.alert=vo(co.alert),po.prototype.emerg=vo(co.emerg);var go={sdkVersion:"3.2.28",sdkName:"df_web_logs_sdk"};function yo(t){var n=function(e){return e.site||e.datakitOrigin||e.datakitUrl?!(e.site&&!e.clientToken&&(i.error("clientToken is not configured, no RUM data will be collected."),1)):(i.error("datakitOrigin or site is not configured, no RUM data will be collected."),!1)}(t);if(n){var r=jn(t),o=mo(t.forwardConsoleLogs,R(e),"Forward Console Logs"),s=mo(t.forwardReports,R(Wt),"Forward Reports");if(r&&o&&s)return t.forwardErrorsToLogs&&!ue(o,e.error)&&o.push(e.error),L({forwardErrorsToLogs:!1!==t.forwardErrorsToLogs,forwardConsoleLogs:o,forwardReports:s,requestErrorResponseLengthLimit:32768},r,go)}}function mo(e,t,n){return void 0===e?[]:"all"===e||A(e)&&function(e,t,n){if(e.every)return e.every(t);for(var r=!0,o=0;o<e.length;o++)if(O.call(e,o)){var i=e[o];if(!t.call(n,i,o,e)){r=!1;break}}return r}(e,(function(e){return ue(t,e)}))?"all"===e?t:function(e){for(var t,n=[],r={},o=0;o<e.length;o++)(t=e[o])in r||(r[t]=!0,n.push(t));return n}(e):void i.error(n+' should be "all" or an array with allowed values "'+t.join('", "')+'"')}function ho(e,t){var n,r,o=Se();return{init:function(e){if(e)if(Ur()&&(e=function(e){return L({},e,{clientToken:"empty"})}(e)),n=e,r)oo("DATAFLUX_LOGS",e);else{var s=yo(e);s&&(r=s,Un().subscribe(J),function(){if(r&&n){var e=t(n,r);o.drain(e)}}())}else i.error("Missing configuration")},getInitConfiguration:function(){return n},getInternalContext:J,handleLog:function(t,n,r,i,s){void 0===i&&(i=e()),void 0===s&&(s=ne()),o.add((function(e){e.handleLog(t,n,r,i,s)}))}}}var bo="logs";var _o="0",wo="1";function So(e){var t=Kn(e,"logs",(function(t){return function(e,t){var n=function(e){return e===_o||e===wo}(t)?t:xo(e);return{trackingType:n,isTracked:n===wo}}(e,t)}));return{findTrackedSession:function(e){var n=t.findSession(e);return n&&n.trackingType===wo?{id:n.id}:void 0},expireObservable:t.expireObservable}}function xo(e){return Y(e.sessionSampleRate)?wo:_o}function Oo(e,t,n,r,o){var i=lo.concat(["custom"]),s={};T(i,(function(e){var n,r,i,a,u;s[e]=(n=e,r=t.eventRateLimiterThreshold,i=o,a=0,u=!1,{isLimitReached:function(){if(0===a&&g((function(){a=0}),Z),(a+=1)<=r||u)return u=!1,!1;if(a===r+1){u=!0;try{i({message:"Reached max number of "+n+"s by minute: "+r,source:xt,startClocks:te()})}finally{u=!1}}return!0}})})),n.subscribe(Gt,(function(o){var i=o.rawLogsEvent,a=o.messageContext||void 0,u=o.savedCommonContext||void 0,c=o.domainContext,f=i.date-oe(),l=e.findTrackedSession(f);if(l){var d=u||r(),p=M({service:t.service||"browser",env:t.env||"",version:t.version||"",_gc:{sdkName:t.sdkName,sdkVersion:t.sdkVersion},session:{id:l.id},view:d.view,user:q(d.user)?void 0:d.user,device:Le,type:Qe},d.context,ko(f),i,a);t.beforeSend&&!1===t.beforeSend(p,c)||p.origin!==xt&&be(s[p.status],s.custom).isLimitReached()||n.notify(Jt,me(p))}}))}function ko(e){return function(t){if(t&&t.getInternalContext)return t.getInternalContext(e)}(window.DATAFLUX_RUM)}function Co(e){return Co="function"==typeof Symbol&&"symbol"==typeof Symbol.iterator?function(e){return typeof e}:function(e){return e&&"function"==typeof Symbol&&e.constructor===Symbol&&e!==Symbol.prototype?"symbol":typeof e},Co(e)}function Eo(e){var t=function(e,t){if("object"!=Co(e)||!e)return e;var n=e[Symbol.toPrimitive];if(void 0!==n){var r=n.call(e,t||"default");if("object"!=Co(r))return r;throw new TypeError("@@toPrimitive must return a primitive value.")}return("string"===t?String:Number)(e)}(e,"string");return"symbol"==Co(t)?t:t+""}function To(e,t,n){return(t=Eo(t))in e?Object.defineProperty(e,t,{value:n,enumerable:!0,configurable:!0,writable:!0}):e[t]=n,e}var Lo=To(To(To(To(To({},e.log,co.info),e.debug,co.debug),e.info,co.info),e.warn,co.warn),e.error,co.error);function $o(e,t){if(!e.forwardErrorsToLogs)return{stop:J};var n=Fn().subscribe((function(e){"complete"===e.state&&o(He.XHR,e)})),r=Un().subscribe((function(e){"resolve"===e.state&&o(He.FETCH,e)}));function o(n,r){function o(e){var o,i,s,a,u,c={isAborted:r.isAborted,handlingStack:r.handlingStack},f=(o=r.url,i=function(e){this._fields={Username:4,Password:5,Port:7,Protocol:2,Host:6,Path:8,URL:0,QueryString:9,Fragment:10},this._values={},this._regex=null,this._regex=/^((\w+):\/\/)?((\w+):?(\w+)?@)?([^\/\?:]+):?(\d+)?(\/?[^\?#]+)?\??([^#]+)?#?(\w*)/,void 0!==e&&this._parse(e)},i.prototype.setUrl=function(e){this._parse(e)},i.prototype._initValues=function(){for(var e in this._fields)this._values[e]=""},i.prototype.addQueryString=function(e){if("object"!==b(e))return!1;var t=this._values.QueryString||"";for(var n in e)t=new RegExp(n+"[^&]+").test(t)?t.replace(new RegExp(n+"[^&]+"),n+"="+e[n]):"&"===t.slice(-1)?t+n+"="+e[n]:""===t?n+"="+e[n]:t+"&"+n+"="+e[n];this._values.QueryString=t},i.prototype.getParse=function(){return this._values},i.prototype.getUrl=function(){var e="";return e+=this._values.Origin,(e+=this._values.Path)+(this._values.QueryString?"?"+this._values.QueryString:"")},i.prototype._parse=function(e){this._initValues();var t=this._regex.exec(e);if(!t)throw"DPURLParser::_parse -> Invalid URL";for(var n in this._fields)void 0!==t[this._fields[n]]&&(this._values[n]=t[this._fields[n]]);this._values.Path=this._values.Path||"/",this._values.Hostname=this._values.Host.replace(/:\d+$/,""),this._values.Origin=this._values.Protocol+"://"+this._values.Hostname+(this._values.Port?":"+this._values.Port:"")},new i(o)).getParse();t.notify(Gt,{rawLogsEvent:{message:Ao(n)+" error "+r.method+" "+r.url,date:r.startClocks.timeStamp,error:{stack:e||"Failed to load",handing:void 0},http:{method:r.method,status_code:r.status,url:r.url,statusGroup:(u=r.status,u?String(u).substr(0,1)+String(u).substr(1).replace(/\d*/g,"x"):0===u?void 0:u),urlHost:f.Host,urlPath:f.Path,urlPathGroup:(s=f.Path,a="",s&&(a=s.replace(/\/([^\/]*)\d([^\/]*)/g,"/?").replace(/\/$/g,"")),a||"/")},status:co.error,origin:kt},domainContext:c})}!function(e,t){var n=[t.rumEndpoint];return t.logsEndpoint&&n.push(t.logsEndpoint),t.sessionReplayEndPoint&&n.push(t.sessionReplayEndPoint),D(n,(function(t){return 0===e.indexOf(t)}))||t.isIntakeUrl(e)}(r.url,e)&&(function(e){return 0===e.status&&"opaque"!==e.responseType}(r)||function(e){return e.status>=500}(r)||e.isServerError(r))&&("xhr"in r?function(e,t,n){"string"==typeof e.response?n(Mo(e.response,t)):n(e.response)}(r.xhr,e,o):r.response?function(e,t,n){var r=function(e){try{return e.clone()}catch(e){return}}(e);r&&r.body?window.TextDecoder?function(e,t,n){!function(e,t,n){var r=e.getReader(),o=[],i=0;function s(){var e,s;if(r.cancel().catch(J),n.collectStreamBody){var a;if(1===o.length)a=o[0];else{a=new Uint8Array(i);var u=0;T(o,(function(e){a.set(e,u),u+=e.length}))}e=a.slice(0,n.bytesLimit),s=a.length>n.bytesLimit}t(void 0,e,s)}!function e(){r.read().then(u((function(t){t.done?s():(n.collectStreamBody&&o.push(t.value),(i+=t.value.length)>n.bytesLimit?s():e())})),u((function(e){t(e)})))}()}(e,(function(e,t,r){if(e)n(e);else{var o=(new TextDecoder).decode(t);r&&(o+="..."),n(void 0,o)}}),{bytesLimit:t,collectStreamBody:!0})}(r.body,t.requestErrorResponseLengthLimit,(function(e,t){n(e?"Unable to retrieve response: "+e:t)})):r.text().then(u((function(e){return n(Mo(e,t))})),u((function(e){return n("Unable to retrieve response: "+e)}))):n()}(r.response,e,o):r.error&&function(e,t,n){n(Mo(Mt(nt(e)),t))}(r.error,e,o))}return{stop:function(){n.unsubscribe(),r.unsubscribe()}}}function Mo(e,t){return e.length>t.requestErrorResponseLengthLimit?e.substring(0,t.requestErrorResponseLengthLimit)+"...":e}function Ao(e){return He.XHR===e?"XHR":"Fetch"}function Po(e,t){if(!e.forwardErrorsToLogs)return{stop:J};var n,r=new jt,o=(n=r,pt((function(e,t){n.notify(Lt({stackTrace:e,originalError:t,startClocks:te(),nonErrorPrefix:Je,source:Ct,handling:Ge}))}))),i=r.subscribe((function(e){t.notify(Gt,{rawLogsEvent:{message:e.message,date:e.startClocks.timeStamp,error:uo(e),origin:Ct,status:co.error}})}));return{stop:function(){o.stop(),i.unsubscribe()}}}function Ro(e){return function(t){var n,r;e.notify(Gt,{rawLogsEvent:{message:t.message,date:t.startClocks.timeStamp,origin:xt,status:co.error}}),n="Error reported to customer",r={"error.message":t.message},f(n,r),hr(L({type:lr,message:n,status:pr},r))}}var Bo,jo,Io,Do,Uo=function(e){var t=eo(),n=Hr("global",{customerDataTracker:t.getOrCreateTracker(Gr)}),r=Hr("user",{customerDataTracker:t.getOrCreateTracker(zr),propertiesConfig:{id:{type:"string"},name:{type:"string"},email:{type:"string"}}});function o(){return function(e,t){return{view:{referrer:document.referrer,url:window.location.href},context:e.getContext(),user:t.getContext()}}(n,r)}var s,c,f=ho(o,(function(t,i){t.storeContextsToLocal&&(Kr(i,n,bo,Gr),Kr(i,r,bo,zr));var s=e(t,i,o);return f=function(e,t){return L({init:function(e){oo("DATAFLUX_LOGS",e)},initConfiguration:e},t)}(t,s),s})),l={},d=new po((function(){var e;return(e=f).handleLog.apply(e,arguments)}),t.createDetachedTracker());return s={logger:d,init:u((function(e){return f.init(e)})),getGlobalContext:u((function(){return n.getContext()})),setGlobalContext:u((function(e){return n.setContext(e)})),setGlobalContextProperty:u((function(e,t){return n.setContextProperty(e,t)})),removeGlobalContextProperty:u((function(e){return n.removeContextProperty(e)})),clearGlobalContext:u((function(){return n.clearContext()})),createLogger:u((function(e,n){return void 0===n&&(n={}),l[e]=new po((function(){var e;return(e=f).handleLog.apply(e,arguments)}),t.createDetachedTracker(),sanitize(e),n.handler,n.level,sanitize(n.context)),l[e]})),getLogger:u((function(e){return l[e]})),getInitConfiguration:u((function(){return G(f.initConfiguration)})),getInternalContext:u((function(e){return f.getInternalContext(e)})),setUser:u((function(e){(function(e){var t="object"===H(e);return t||i.error("Unsupported user:",e),t})(e)&&r.setContext(e)})),getUser:u((function(){return r.getContext()})),removeUserProperty:u((function(e){return r.removeContextProperty(e)})),setUserProperty:u((function(e,t){r.setContextProperty(e,t)})),clearUser:u((function(){return r.clearContext()}))},c=L({onReady:function(e){e()}},s),Object.defineProperty(c,"_setDebug",{get:function(){return a},enumerable:!1}),c}((function(e,t,n){var r=new Xt,o=[],i=Ro(r),s=new jt((function(e){var t=Ft(window,[Be,je],(function(t){t.type===Be&&"hidden"===document.visibilityState?e.notify({reason:Nn.HIDDEN}):t.type===je&&e.notify({reason:Nn.FROZEN})}),{capture:!0}),n=qt(window,$e,(function(){e.notify({reason:Nn.UNLOADING})}));return function(){t.stop(),n.stop()}})),a=!t.sessionStoreStrategyType||Ur()||Boolean(window._GUANCE_SYNTHETICS_INJECTS_RUM||cn("guance-synthetics-injects-rum"))?function(e){var t=xo(e)===wo?{}:void 0;return{findTrackedSession:function(){return t},expireObservable:new jt}}(t):So(t),u=function(e,t,n,r,o){var i=br(yr,t);i.setContextProvider((function(){var e=ko();return{application:{id:e&&e.application&&e.application.id},session:{id:o.findTrackedSession()&&o.findTrackedSession().id},view:{id:e&&e.view&&e.view.id},action:{id:e&&e.userAction&&e.userAction.id}}}));var s=[];if(!Ur()){var a=jr(t,{endpoint:t.rumEndpoint,encoder:no()},n,r,o.expireObservable);s.push((function(){a.stop()}));var u=i.observable.subscribe((function(e){a.add(e)}));s.push((function(){u.unsubscribe()}))}return function(){mr.drain()}(),function(e){hr({type:dr,configuration:e})}(G(e)),{telemetry:i,stop:function(){s.forEach((function(e){e()}))}}}(e,t,i,s,a);o.push((function(){u.stop()})),$o(t,r),Po(t,r),function(e,t){var n=Ut(e.forwardConsoleLogs).subscribe((function(e){t.notify(Gt,{rawLogsEvent:{date:ne(),message:e.message,origin:Ot,error:e.error&&uo(e.error),status:Lo[e.api]},domainContext:{handlingStack:e.handlingStack}})}))}(t,r),function(e,t){var n=Vt(0,e.forwardReports).subscribe((function(e){var n,r,o,i=e.message,s="deprecation"===e.originalError.type?co.warn:co.error;s===co.error?n=uo(e):report.stack&&(i+=" Found in "+(r=e.stack,(o=/@ (.+)/.exec(r))&&o[1])),t.notify(Gt,{rawLogsEvent:{date:ne(),message:i,origin:Tt,error:n,status:s}})}))}(t,r);var c=so(r);if(Oo(a,t,r,n,i),Ur())!function(e){var t=Dr();e.subscribe(Jt,(function(e){t.send("log",e)}))}(r);else{var f=function(e,t,n,r,o){var i=jr(e,{endpoint:e.logsEndpoint,encoder:no()},n,r,o.expireObservable);return t.subscribe(Jt,(function(e){i.add(e)})),i}(t,r,i,s,a);o.push((function(){f.stop()}))}var l,d=(l=a,{get:function(e){var t=l.findTrackedSession(e);if(t)return{session:{id:t.id}}}});return{handleLog:c.handleLog,getInternalContext:d.get,stop:function(){o.forEach((function(e){e()}))}}}));Bo=p(),Io=Uo,Do=Bo[jo="DATAFLUX_LOGS"],Bo[jo]=Io,Do&&Do.q&&T(Do.q,(function(e){l(e,"onReady callback threw an error:")()}))}();
@@ -5,7 +5,7 @@ Object.defineProperty(exports, "__esModule", {
5
5
  });
6
6
  exports.buildEnv = void 0;
7
7
  var buildEnv = exports.buildEnv = {
8
- sdkVersion: "3.2.25",
8
+ sdkVersion: "3.2.28",
9
9
  sdkName: 'df_web_logs_sdk'
10
10
  };
11
11
  //# sourceMappingURL=buildEnv.js.map
@@ -1,5 +1,5 @@
1
1
  export var buildEnv = {
2
- sdkVersion: "3.2.25",
2
+ sdkVersion: "3.2.28",
3
3
  sdkName: 'df_web_logs_sdk'
4
4
  };
5
5
  //# sourceMappingURL=buildEnv.js.map
package/package.json CHANGED
@@ -1,35 +1,34 @@
1
1
  {
2
- "name": "@cloudcare/browser-logs",
3
- "main": "cjs/index.js",
4
- "module": "esm/index.js",
5
- "version": "3.2.25",
6
- "types": "types/index.d.ts",
7
- "dependencies": {
8
- "@cloudcare/browser-core": "3.2.25"
9
- },
10
- "scripts": {
11
- "dev": "webpack serve --open --mode=development",
12
- "build": "run-p build:cjs build:esm build:bundle",
13
- "build:cjs": "rm -rf cjs && babel --config-file ./babel.cjs.json --out-dir cjs ./src && npm run replace-build-env cjs",
14
- "build:esm": "rm -rf esm && babel --config-file ./babel.esm.json --out-dir esm ./src && npm run replace-build-env esm",
15
- "build:bundle": "rm -rf bundle && webpack --mode=production",
16
- "publish:oss:current": "npm run build:bundle && node ./scripts/publish-oss.js current",
17
- "publish:oss:test": "npm run build:bundle && node ./scripts/publish-oss.js test",
18
- "publish:oss:lts": "npm run build:bundle && node ./scripts/publish-oss.js lts",
19
- "replace-build-env": "node ../../scripts/replace-build-env.js"
20
- },
21
- "keywords": [
22
- "dataflux",
23
- "logs",
24
- "sdk"
25
- ],
26
- "repository": {
27
- "url": "https://github.com/DataFlux-cn/datakit-js",
28
- "type": "git",
29
- "directory": "packages/logs"
30
- },
31
- "author": "dataflux",
32
- "license": "MIT",
33
- "description": "DataFlux RUM Web 端数据指标监控",
34
- "gitHead": "d3ea0b253be974997fac2a295c3f033c927d65eb"
2
+ "name": "@cloudcare/browser-logs",
3
+ "main": "cjs/index.js",
4
+ "module": "esm/index.js",
5
+ "version": "3.2.28",
6
+ "types": "types/index.d.ts",
7
+ "dependencies": {
8
+ "@cloudcare/browser-core": "3.2.28"
9
+ },
10
+ "scripts": {
11
+ "dev": "webpack serve --open --mode=development",
12
+ "build": "run-p build:cjs build:esm build:bundle",
13
+ "build:cjs": "rm -rf cjs && babel --config-file ./babel.cjs.json --out-dir cjs ./src && npm run replace-build-env cjs",
14
+ "build:esm": "rm -rf esm && babel --config-file ./babel.esm.json --out-dir esm ./src && npm run replace-build-env esm",
15
+ "build:bundle": "rm -rf bundle && webpack --mode=production",
16
+ "publish:oss:current": "npm run build:bundle && node ./scripts/publish-oss.js current",
17
+ "publish:oss:test": "npm run build:bundle && node ./scripts/publish-oss.js test",
18
+ "publish:oss:lts": "npm run build:bundle && node ./scripts/publish-oss.js lts",
19
+ "replace-build-env": "node ../../scripts/replace-build-env.js"
20
+ },
21
+ "keywords": [
22
+ "dataflux",
23
+ "logs",
24
+ "sdk"
25
+ ],
26
+ "repository": {
27
+ "url": "https://github.com/DataFlux-cn/datakit-js",
28
+ "type": "git",
29
+ "directory": "packages/logs"
30
+ },
31
+ "author": "dataflux",
32
+ "license": "MIT",
33
+ "gitHead": "1d42bf528926c2c13947c3298a1d18ea2a4e91f6"
35
34
  }