@grafana/faro-web-sdk
Advanced tools
Comparing version 1.2.6 to 1.2.7
@@ -1,1 +0,1 @@ | ||
var GrafanaFaroWebSdk=function(e){"use strict";function n(e,n){return typeof e===n}function t(e,n){return Object.prototype.toString.call(e)===`[object ${n}]`}function i(e,n){try{return e instanceof n}catch(e){return!1}}const r=e=>n(e,"undefined"),s=e=>n(e,"null"),o=e=>n(e,"string"),a=e=>n(e,"number")&&!isNaN(e)||n(e,"bigint"),l=e=>!s(e)&&n(e,"object"),u=e=>n(e,"function"),c=e=>t(e,"Array"),d=e=>!l(e)&&!u(e),p=!r(Event),f=e=>p&&i(e,Event),g="undefined"!=typeof Error,b=e=>g&&i(e,Error),v=e=>t(e,"ErrorEvent"),m=e=>t(e,"DOMError"),h=e=>t(e,"DOMException"),w="undefined"!=typeof Element,y="undefined"!=typeof Map;function S(e,t){if(e===t)return!0;if(n(e,"number")&&isNaN(e))return n(t,"number")&&isNaN(t);const i=c(e),r=c(t);if(i!==r)return!1;if(i&&r){const n=e.length;if(n!==t.length)return!1;for(let i=n;0!=i--;)if(!S(e[i],t[i]))return!1;return!0}const s=l(e),o=l(t);if(s!==o)return!1;if(e&&t&&s&&o){const n=Object.keys(e),i=Object.keys(t);if(n.length!==i.length)return!1;for(let e of n)if(!i.includes(e))return!1;for(let i of n)if(!S(e[i],t[i]))return!1;return!0}return!1}function E(){return(new Date).toISOString()}var T;e.LogLevel=void 0,(T=e.LogLevel||(e.LogLevel={})).TRACE="trace",T.DEBUG="debug",T.INFO="info",T.LOG="log",T.WARN="warn",T.ERROR="error";const x=e.LogLevel.LOG,k=[e.LogLevel.TRACE,e.LogLevel.DEBUG,e.LogLevel.INFO,e.LogLevel.LOG,e.LogLevel.WARN,e.LogLevel.ERROR];function I(){}function L(e){const{size:n,concurrency:t}=e,i=[];let r=0;const s=()=>{if(r<t&&i.length){const{producer:e,resolve:n,reject:t}=i.shift();r++,e().then((e=>{r--,s(),n(e)}),(e=>{r--,s(),t(e)}))}};return{add:e=>{if(i.length+r>=n)throw new Error("Task buffer full");return new Promise(((n,t)=>{i.push({producer:e,resolve:n,reject:t}),s()}))}}}const O="abcdefghijkmnopqrstuvwxyzABCDEFGHJKLMNPQRSTUVWXYZ0123456789";function A(e=10){return Array.from(Array(e)).map((()=>O[Math.floor(Math.random()*O.length)])).join("")}function C(){return Date.now()}var N="undefined"!=typeof globalThis?globalThis:"undefined"!=typeof window?window:"undefined"!=typeof global?global:"undefined"!=typeof self?self:{},j={exports:{}},R={exports:{}};R.exports=function(e,n){var t,i,r,s,o,a,l,u;for(t=3&e.length,i=e.length-t,r=n,o=3432918353,a=461845907,u=0;u<i;)l=255&e.charCodeAt(u)|(255&e.charCodeAt(++u))<<8|(255&e.charCodeAt(++u))<<16|(255&e.charCodeAt(++u))<<24,++u,r=27492+(65535&(s=5*(65535&(r=(r^=l=(65535&(l=(l=(65535&l)*o+(((l>>>16)*o&65535)<<16)&4294967295)<<15|l>>>17))*a+(((l>>>16)*a&65535)<<16)&4294967295)<<13|r>>>19))+((5*(r>>>16)&65535)<<16)&4294967295))+((58964+(s>>>16)&65535)<<16);switch(l=0,t){case 3:l^=(255&e.charCodeAt(u+2))<<16;case 2:l^=(255&e.charCodeAt(u+1))<<8;case 1:r^=l=(65535&(l=(l=(65535&(l^=255&e.charCodeAt(u)))*o+(((l>>>16)*o&65535)<<16)&4294967295)<<15|l>>>17))*a+(((l>>>16)*a&65535)<<16)&4294967295}return r^=e.length,r=2246822507*(65535&(r^=r>>>16))+((2246822507*(r>>>16)&65535)<<16)&4294967295,r=3266489909*(65535&(r^=r>>>13))+((3266489909*(r>>>16)&65535)<<16)&4294967295,(r^=r>>>16)>>>0};var D=R.exports,U={exports:{}};!function(e){e.exports=function(e,n){for(var t,i=e.length,r=n^i,s=0;i>=4;)t=1540483477*(65535&(t=255&e.charCodeAt(s)|(255&e.charCodeAt(++s))<<8|(255&e.charCodeAt(++s))<<16|(255&e.charCodeAt(++s))<<24))+((1540483477*(t>>>16)&65535)<<16),r=1540483477*(65535&r)+((1540483477*(r>>>16)&65535)<<16)^(t=1540483477*(65535&(t^=t>>>24))+((1540483477*(t>>>16)&65535)<<16)),i-=4,++s;switch(i){case 3:r^=(255&e.charCodeAt(s+2))<<16;case 2:r^=(255&e.charCodeAt(s+1))<<8;case 1:r=1540483477*(65535&(r^=255&e.charCodeAt(s)))+((1540483477*(r>>>16)&65535)<<16)}return r=1540483477*(65535&(r^=r>>>13))+((1540483477*(r>>>16)&65535)<<16),(r^=r>>>15)>>>0}}(U);var M=D,P=U.exports;j.exports=M;var _=j.exports.murmur3=M;j.exports.murmur2=P;class B{constructor(e,n){var t,i;this.signalBuffer=[],this.itemLimit=null!==(t=null==n?void 0:n.itemLimit)&&void 0!==t?t:50,this.sendTimeout=null!==(i=null==n?void 0:n.sendTimeout)&&void 0!==i?i:250,this.paused=(null==n?void 0:n.paused)||!1,this.sendFn=e,this.flushInterval=-1,this.paused||this.start(),document.addEventListener("visibilitychange",(()=>{"hidden"===document.visibilityState&&this.flush()}))}addItem(e){this.paused||(this.signalBuffer.push(e),this.signalBuffer.length>=this.itemLimit&&this.flush())}start(){this.paused=!1,this.sendTimeout>0&&(this.flushInterval=window.setInterval((()=>this.flush()),this.sendTimeout))}pause(){this.paused=!0,clearInterval(this.flushInterval)}groupItems(e){const n=new Map;return e.forEach((e=>{const t=_(JSON.stringify(e.meta));let i=n.get(t);i=void 0===i?[e]:[...i,e],n.set(t,i)})),Array.from(n.values())}flush(){if(this.paused||0===this.signalBuffer.length)return;this.groupItems(this.signalBuffer).forEach(this.sendFn),this.signalBuffer=[]}}var z;e.TransportItemType=void 0,(z=e.TransportItemType||(e.TransportItemType={})).EXCEPTION="exception",z.LOG="log",z.MEASUREMENT="measurement",z.TRACE="trace",z.EVENT="event";const F={[e.TransportItemType.EXCEPTION]:"exceptions",[e.TransportItemType.LOG]:"logs",[e.TransportItemType.MEASUREMENT]:"measurements",[e.TransportItemType.TRACE]:"traces",[e.TransportItemType.EVENT]:"events"};function $(n){return t=>{if(t.type===e.TransportItemType.EXCEPTION&&t.payload){const e=t.payload,i=`${e.type}: ${e.value}`;if(function(e,n){return e.some((e=>o(e)?n.includes(e):!!n.match(e)))}(n,i))return null}return t}}var V;e.InternalLoggerLevel=void 0,(V=e.InternalLoggerLevel||(e.InternalLoggerLevel={}))[V.OFF=0]="OFF",V[V.ERROR=1]="ERROR",V[V.WARN=2]="WARN",V[V.INFO=3]="INFO",V[V.VERBOSE=4]="VERBOSE";const q={debug:I,error:I,info:I,prefix:"Faro",warn:I},G=e.InternalLoggerLevel.ERROR,W=Object.assign({},console);let K=W;function H(e){var n;return K=null!==(n=e.unpatchedConsole)&&void 0!==n?n:K,K}function J(n=W,t=G){const i=q;return t>e.InternalLoggerLevel.OFF&&(i.error=t>=e.InternalLoggerLevel.ERROR?function(...e){n.error(`${i.prefix}\n`,...e)}:I,i.warn=t>=e.InternalLoggerLevel.WARN?function(...e){n.warn(`${i.prefix}\n`,...e)}:I,i.info=t>=e.InternalLoggerLevel.INFO?function(...e){n.info(`${i.prefix}\n`,...e)}:I,i.debug=t>=e.InternalLoggerLevel.VERBOSE?function(...e){n.debug(`${i.prefix}\n`,...e)}:I),i}let X=q;function Z(e,n){return X=J(e,n.internalLoggerLevel),X}class Q{constructor(){this.unpatchedConsole=W,this.internalLogger=q,this.config={},this.metas={}}logDebug(...e){this.internalLogger.debug(`${this.name}\n`,...e)}logInfo(...e){this.internalLogger.info(`${this.name}\n`,...e)}logWarn(...e){this.internalLogger.warn(`${this.name}\n`,...e)}logError(...e){this.internalLogger.error(`${this.name}\n`,...e)}}class Y extends Q{isBatched(){return!1}getIgnoreUrls(){return[]}}function ee(e,n){var t,i;if(void 0===n)return e;if(void 0===e)return{resourceSpans:n};const r=null===(t=e.resourceSpans)||void 0===t?void 0:t[0];if(void 0===r)return e;const s=(null==r?void 0:r.scopeSpans)||[],o=(null===(i=null==n?void 0:n[0])||void 0===i?void 0:i.scopeSpans)||[];return Object.assign(Object.assign({},e),{resourceSpans:[Object.assign(Object.assign({},r),{scopeSpans:[...s,...o]})]})}function ne(n){let t={meta:{}};return void 0!==n[0]&&(t.meta=n[0].meta),n.forEach((n=>{switch(n.type){case e.TransportItemType.LOG:case e.TransportItemType.EVENT:case e.TransportItemType.EXCEPTION:case e.TransportItemType.MEASUREMENT:const i=F[n.type],r=t[i];t=Object.assign(Object.assign({},t),{[i]:void 0===r?[n.payload]:[...r,n.payload]});break;case e.TransportItemType.TRACE:t=Object.assign(Object.assign({},t),{traces:ee(t.traces,n.payload.resourceSpans)})}})),t}const te="Error";let ie;function re(n,t,i,r,o){t.debug("Initializing API");const a=function(n,t,i,r,s){let o;return t.debug("Initializing traces API"),{getOTEL:()=>o,getTraceContext:()=>{const e=null==o?void 0:o.trace.getSpanContext(o.context.active());return e?{trace_id:e.traceId,span_id:e.spanId}:void 0},initOTEL:(e,n)=>{t.debug("Initializing OpenTelemetry"),o={trace:e,context:n}},isOTELInitialized:()=>!!o,pushTraces:n=>{try{const i={type:e.TransportItemType.TRACE,payload:n,meta:r.value};t.debug("Pushing trace\n",i),s.execute(i)}catch(e){t.error("Error pushing trace\n",e)}}}}(0,t,0,r,o);return Object.assign(Object.assign(Object.assign(Object.assign(Object.assign(Object.assign({},a),function(n,t,i,r,o,a){var l;t.debug("Initializing exceptions API");let u=null;ie=null!==(l=i.parseStacktrace)&&void 0!==l?l:ie;const c=e=>{t.debug("Changing stacktrace parser"),ie=null!=e?e:ie};return c(i.parseStacktrace),{changeStacktraceParser:c,getStacktraceParser:()=>ie,pushError:(n,{skipDedupe:l,stackFrames:c,type:d,context:p}={})=>{d=d||n.name||te;const f={meta:r.value,payload:{type:d,value:n.message,timestamp:E(),trace:a.getTraceContext(),context:null!=p?p:{}},type:e.TransportItemType.EXCEPTION};(null==(c=null!=c?c:n.stack?null==ie?void 0:ie(n).frames:void 0)?void 0:c.length)&&(f.payload.stacktrace={frames:c});const g={type:f.payload.type,value:f.payload.value,stackTrace:f.payload.stacktrace,context:f.payload.context};l||!i.dedupe||s(u)||!S(g,u)?(u=g,t.debug("Pushing exception\n",f),o.execute(f)):t.debug("Skipping error push because it is the same as the last one\n",f.payload)}}}(0,t,i,r,o,a)),function(e,n,t,i,r){let s,o,a;n.debug("Initializing meta API");const l=e=>{o&&i.remove(o),o={user:e},i.add(o)},u=e=>{s&&i.remove(s),s={session:e},i.add(s)};return{setUser:l,resetUser:l,setSession:u,resetSession:u,getSession:()=>i.value.session,setView:e=>{a&&i.remove(a),a={view:e},i.add(a)},getView:()=>i.value.view}}(0,t,0,r)),function(n,t,i,r,o,a){t.debug("Initializing logs API");let l=null;return{pushLog:(n,{context:u,level:c,skipDedupe:d}={})=>{try{const p={type:e.TransportItemType.LOG,payload:{message:n.map((e=>{try{return String(e)}catch(e){return""}})).join(" "),level:null!=c?c:x,context:null!=u?u:{},timestamp:E(),trace:a.getTraceContext()},meta:r.value},f={message:p.payload.message,level:p.payload.level,context:p.payload.context};if(!d&&i.dedupe&&!s(l)&&S(f,l))return void t.debug("Skipping log push because it is the same as the last one\n",p.payload);l=f,t.debug("Pushing log\n",p),o.execute(p)}catch(e){t.error("Error pushing log\n",e)}}}}(0,t,i,r,o,a)),function(n,t,i,r,o,a){t.debug("Initializing measurements API");let l=null;return{pushMeasurement:(n,{skipDedupe:u,context:c}={})=>{var d;try{const p={type:e.TransportItemType.MEASUREMENT,payload:Object.assign(Object.assign({},n),{trace:a.getTraceContext(),timestamp:null!==(d=n.timestamp)&&void 0!==d?d:E(),context:null!=c?c:{}}),meta:r.value},f={type:p.payload.type,values:p.payload.values,context:p.payload.context};if(!u&&i.dedupe&&!s(l)&&S(f,l))return void t.debug("Skipping measurement push because it is the same as the last one\n",p.payload);l=f,t.debug("Pushing measurement\n",p),o.execute(p)}catch(e){t.error("Error pushing measurement\n",e)}}}}(0,t,i,r,o,a)),function(n,t,i,r,o,a){let l=null;return{pushEvent:(n,u,c,{skipDedupe:d}={})=>{try{const p={meta:r.value,payload:{name:n,domain:null!=c?c:i.eventDomain,attributes:u,timestamp:E(),trace:a.getTraceContext()},type:e.TransportItemType.EVENT},f={name:p.payload.name,attributes:p.payload.attributes,domain:p.payload.domain};if(!d&&i.dedupe&&!s(l)&&S(f,l))return void t.debug("Skipping event push because it is the same as the last one\n",p.payload);l=f,t.debug("Pushing event\n",p),o.execute(p)}catch(e){t.error("Error pushing event",e)}}}}(0,t,i,r,o,a))}const se="undefined"!=typeof globalThis?globalThis:"undefined"!=typeof global?global:"undefined"!=typeof self?self:void 0;class oe extends Q{constructor(){super(...arguments),this.api={},this.transports={}}}const ae="1.2.6";const le="_faroInternal";function ue(e){e.config.isolate?e.internalLogger.debug("Skipping registering internal Faro instance on global object"):(e.internalLogger.debug("Registering internal Faro instance on global object"),Object.defineProperty(se,le,{configurable:!1,enumerable:!1,writable:!1,value:e}))}function ce(){return le in se}function de(n,t,i,r,s,o,a){return t.debug("Initializing Faro"),e.faro={api:o,config:i,instrumentations:a,internalLogger:t,metas:r,pause:s.pause,transports:s,unpatchedConsole:n,unpause:s.unpause},ue(e.faro),function(e){if(e.config.preventGlobalExposure)e.internalLogger.debug("Skipping registering public Faro instance in the global scope");else{if(e.internalLogger.debug(`Registering public faro reference in the global scope using "${e.config.globalObjectKey}" key`),e.config.globalObjectKey in se)return void e.internalLogger.warn(`Skipping global registration due to key "${e.config.globalObjectKey}" being used already. Please set "globalObjectKey" to something else or set "preventGlobalExposure" to "true"`);Object.defineProperty(se,e.config.globalObjectKey,{configurable:!1,writable:!1,value:e})}}(e.faro),e.faro}function pe(e){const n=H(e),t=Z(n,e);if(ce()&&!e.isolate)return void t.error('Faro is already registered. Either add instrumentations, transports etc. to the global faro instance or use the "isolate" property');t.debug("Initializing");const i=function(e,n,t){let i=[],r=[];const s=()=>i.reduce(((e,n)=>Object.assign(e,u(n)?n():n)),{}),o=()=>{if(r.length){const e=s();r.forEach((n=>n(e)))}};return{add:(...e)=>{n.debug("Adding metas\n",e),i.push(...e),o()},remove:(...e)=>{n.debug("Removing metas\n",e),i=i.filter((n=>!e.includes(n))),o()},addListener:e=>{n.debug("Adding metas listener\n",e),r.push(e)},removeListener:e=>{n.debug("Removing metas listener\n",e),r=r.filter((n=>n!==e))},get value(){return s()}}}(0,t),r=function(e,n,t,i){var r;n.debug("Initializing transports");const s=[];let o=t.paused,a=[];const l=e=>{let n=e;for(const e of a){const t=n.map(e).filter(Boolean);if(0===t.length)return[];n=t}return n},u=e=>{const t=l(e);if(0!==t.length)for(const e of s)n.debug(`Transporting item using ${e.name}\n`,t),e.isBatched()&&e.send(t)},c=e=>{var i;const[r]=l([e]);if(void 0!==r)for(const e of s)n.debug(`Transporting item using ${e.name}\n`,r),e.isBatched()?(null===(i=t.batching)||void 0===i?void 0:i.enabled)||e.send([r]):e.send(r)};let d;return(null===(r=t.batching)||void 0===r?void 0:r.enabled)&&(d=new B(u,{sendTimeout:t.batching.sendTimeout,itemLimit:t.batching.itemLimit,paused:o})),{add:(...r)=>{n.debug("Adding transports"),r.forEach((r=>{n.debug(`Adding "${r.name}" transport`),s.some((e=>e===r))?n.warn(`Transport ${r.name} is already added`):(r.unpatchedConsole=e,r.internalLogger=n,r.config=t,r.metas=i,s.push(r))}))},addBeforeSendHooks:(...e)=>{n.debug("Adding beforeSendHooks\n",a),e.forEach((e=>{e&&a.push(e)}))},addIgnoreErrorsPatterns:(...e)=>{n.debug("Adding ignoreErrorsPatterns\n",e),e.forEach((e=>{e&&a.push($(e))}))},getBeforeSendHooks:()=>[...a],execute:e=>{var n;o||((null===(n=t.batching)||void 0===n?void 0:n.enabled)?(null==d||d.addItem(e),c(e)):c(e))},isPaused:()=>o,pause:()=>{n.debug("Pausing transports"),null==d||d.pause(),o=!0},remove:(...e)=>{n.debug("Removing transports"),e.forEach((e=>{n.debug(`Removing "${e.name}" transport`);const t=s.indexOf(e);-1!==t?s.splice(t,1):n.warn(`Transport "${e.name}" is not added`)}))},removeBeforeSendHooks:(...e)=>{a.filter((n=>!e.includes(n)))},get transports(){return[...s]},unpause:()=>{n.debug("Unpausing transports"),null==d||d.start(),o=!1}}}(n,t,e,i),s=re(0,t,e,i,r),o=function(e,n,t,i,r,s){n.debug("Initializing instrumentations");const o=[];return{add:(...a)=>{n.debug("Adding instrumentations"),a.forEach((a=>{n.debug(`Adding "${a.name}" instrumentation`),o.some((e=>e.name===a.name))?n.warn(`Instrumentation ${a.name} is already added`):(a.unpatchedConsole=e,a.internalLogger=n,a.config=t,a.metas=i,a.transports=r,a.api=s,o.push(a),a.initialize())}))},get instrumentations(){return[...o]},remove:(...e)=>{n.debug("Removing instrumentations"),e.forEach((e=>{var t,i;n.debug(`Removing "${e.name}" instrumentation`);const r=o.reduce(((n,t,i)=>null===n&&t.name===e.name?i:null),null);r?(null===(i=(t=o[r]).destroy)||void 0===i||i.call(t),o.splice(r,1)):n.warn(`Instrumentation "${e.name}" is not added`)}))}}}(n,t,e,i,r,s),a=de(n,t,e,i,r,s,o);return function(e){var n,t;const i={sdk:{version:ae}};let r=e.config.session;(null===(n=e.config.sessionTracking)||void 0===n?void 0:n.enabled)&&(r=e.config.sessionTracking.session),r&&e.api.setSession(r),e.config.app&&(i.app=e.config.app),e.config.user&&(i.user=e.config.user),e.config.view&&(i.view=e.config.view),e.metas.add(i,...null!==(t=e.config.metas)&&void 0!==t?t:[])}(a),function(e){e.transports.add(...e.config.transports),e.transports.addBeforeSendHooks(e.config.beforeSend),e.transports.addIgnoreErrorsPatterns(e.config.ignoreErrors)}(a),function(e){e.instrumentations.add(...e.config.instrumentations)}(a),a}e.faro={};const fe="faro",ge={enabled:!0,sendTimeout:250,itemLimit:50},be="session_start";var ve={exports:{}};!function(e,n){!function(t,i){var r="function",s="undefined",o="object",a="string",l="major",u="model",c="name",d="type",p="vendor",f="version",g="architecture",b="console",v="mobile",m="tablet",h="smarttv",w="wearable",y="embedded",S="Amazon",E="Apple",T="ASUS",x="BlackBerry",k="Browser",I="Chrome",L="Firefox",O="Google",A="Huawei",C="LG",N="Microsoft",j="Motorola",R="Opera",D="Samsung",U="Sharp",M="Sony",P="Xiaomi",_="Zebra",B="Facebook",z="Chromium OS",F="Mac OS",$=function(e){for(var n={},t=0;t<e.length;t++)n[e[t].toUpperCase()]=e[t];return n},V=function(e,n){return typeof e===a&&-1!==q(n).indexOf(q(e))},q=function(e){return e.toLowerCase()},G=function(e,n){if(typeof e===a)return e=e.replace(/^\s\s*/,""),typeof n===s?e:e.substring(0,350)},W=function(e,n){for(var t,s,a,l,u,c,d=0;d<n.length&&!u;){var p=n[d],f=n[d+1];for(t=s=0;t<p.length&&!u&&p[t];)if(u=p[t++].exec(e))for(a=0;a<f.length;a++)c=u[++s],typeof(l=f[a])===o&&l.length>0?2===l.length?typeof l[1]==r?this[l[0]]=l[1].call(this,c):this[l[0]]=l[1]:3===l.length?typeof l[1]!==r||l[1].exec&&l[1].test?this[l[0]]=c?c.replace(l[1],l[2]):i:this[l[0]]=c?l[1].call(this,c,l[2]):i:4===l.length&&(this[l[0]]=c?l[3].call(this,c.replace(l[1],l[2])):i):this[l]=c||i;d+=2}},K=function(e,n){for(var t in n)if(typeof n[t]===o&&n[t].length>0){for(var r=0;r<n[t].length;r++)if(V(n[t][r],e))return"?"===t?i:t}else if(V(n[t],e))return"?"===t?i:t;return e},H={ME:"4.90","NT 3.11":"NT3.51","NT 4.0":"NT4.0",2e3:"NT 5.0",XP:["NT 5.1","NT 5.2"],Vista:"NT 6.0",7:"NT 6.1",8:"NT 6.2",8.1:"NT 6.3",10:["NT 6.4","NT 10.0"],RT:"ARM"},J={browser:[[/\b(?:crmo|crios)\/([\w\.]+)/i],[f,[c,"Chrome"]],[/edg(?:e|ios|a)?\/([\w\.]+)/i],[f,[c,"Edge"]],[/(opera mini)\/([-\w\.]+)/i,/(opera [mobiletab]{3,6})\b.+version\/([-\w\.]+)/i,/(opera)(?:.+version\/|[\/ ]+)([\w\.]+)/i],[c,f],[/opios[\/ ]+([\w\.]+)/i],[f,[c,R+" Mini"]],[/\bopr\/([\w\.]+)/i],[f,[c,R]],[/(kindle)\/([\w\.]+)/i,/(lunascape|maxthon|netfront|jasmine|blazer)[\/ ]?([\w\.]*)/i,/(avant |iemobile|slim)(?:browser)?[\/ ]?([\w\.]*)/i,/(ba?idubrowser)[\/ ]?([\w\.]+)/i,/(?:ms|\()(ie) ([\w\.]+)/i,/(flock|rockmelt|midori|epiphany|silk|skyfire|bolt|iron|vivaldi|iridium|phantomjs|bowser|quark|qupzilla|falkon|rekonq|puffin|brave|whale(?!.+naver)|qqbrowserlite|qq|duckduckgo)\/([-\w\.]+)/i,/(heytap|ovi)browser\/([\d\.]+)/i,/(weibo)__([\d\.]+)/i],[c,f],[/(?:\buc? ?browser|(?:juc.+)ucweb)[\/ ]?([\w\.]+)/i],[f,[c,"UC"+k]],[/microm.+\bqbcore\/([\w\.]+)/i,/\bqbcore\/([\w\.]+).+microm/i],[f,[c,"WeChat(Win) Desktop"]],[/micromessenger\/([\w\.]+)/i],[f,[c,"WeChat"]],[/konqueror\/([\w\.]+)/i],[f,[c,"Konqueror"]],[/trident.+rv[: ]([\w\.]{1,9})\b.+like gecko/i],[f,[c,"IE"]],[/ya(?:search)?browser\/([\w\.]+)/i],[f,[c,"Yandex"]],[/(avast|avg)\/([\w\.]+)/i],[[c,/(.+)/,"$1 Secure "+k],f],[/\bfocus\/([\w\.]+)/i],[f,[c,L+" Focus"]],[/\bopt\/([\w\.]+)/i],[f,[c,R+" Touch"]],[/coc_coc\w+\/([\w\.]+)/i],[f,[c,"Coc Coc"]],[/dolfin\/([\w\.]+)/i],[f,[c,"Dolphin"]],[/coast\/([\w\.]+)/i],[f,[c,R+" Coast"]],[/miuibrowser\/([\w\.]+)/i],[f,[c,"MIUI "+k]],[/fxios\/([-\w\.]+)/i],[f,[c,L]],[/\bqihu|(qi?ho?o?|360)browser/i],[[c,"360 "+k]],[/(oculus|samsung|sailfish|huawei)browser\/([\w\.]+)/i],[[c,/(.+)/,"$1 "+k],f],[/(comodo_dragon)\/([\w\.]+)/i],[[c,/_/g," "],f],[/(electron)\/([\w\.]+) safari/i,/(tesla)(?: qtcarbrowser|\/(20\d\d\.[-\w\.]+))/i,/m?(qqbrowser|baiduboxapp|2345Explorer)[\/ ]?([\w\.]+)/i],[c,f],[/(metasr)[\/ ]?([\w\.]+)/i,/(lbbrowser)/i,/\[(linkedin)app\]/i],[c],[/((?:fban\/fbios|fb_iab\/fb4a)(?!.+fbav)|;fbav\/([\w\.]+);)/i],[[c,B],f],[/(kakao(?:talk|story))[\/ ]([\w\.]+)/i,/(naver)\(.*?(\d+\.[\w\.]+).*\)/i,/safari (line)\/([\w\.]+)/i,/\b(line)\/([\w\.]+)\/iab/i,/(chromium|instagram|snapchat)[\/ ]([-\w\.]+)/i],[c,f],[/\bgsa\/([\w\.]+) .*safari\//i],[f,[c,"GSA"]],[/musical_ly(?:.+app_?version\/|_)([\w\.]+)/i],[f,[c,"TikTok"]],[/headlesschrome(?:\/([\w\.]+)| )/i],[f,[c,I+" Headless"]],[/ wv\).+(chrome)\/([\w\.]+)/i],[[c,I+" WebView"],f],[/droid.+ version\/([\w\.]+)\b.+(?:mobile safari|safari)/i],[f,[c,"Android "+k]],[/(chrome|omniweb|arora|[tizenoka]{5} ?browser)\/v?([\w\.]+)/i],[c,f],[/version\/([\w\.\,]+) .*mobile\/\w+ (safari)/i],[f,[c,"Mobile Safari"]],[/version\/([\w(\.|\,)]+) .*(mobile ?safari|safari)/i],[f,c],[/webkit.+?(mobile ?safari|safari)(\/[\w\.]+)/i],[c,[f,K,{"1.0":"/8",1.2:"/1",1.3:"/3","2.0":"/412","2.0.2":"/416","2.0.3":"/417","2.0.4":"/419","?":"/"}]],[/(webkit|khtml)\/([\w\.]+)/i],[c,f],[/(navigator|netscape\d?)\/([-\w\.]+)/i],[[c,"Netscape"],f],[/mobile vr; rv:([\w\.]+)\).+firefox/i],[f,[c,L+" Reality"]],[/ekiohf.+(flow)\/([\w\.]+)/i,/(swiftfox)/i,/(icedragon|iceweasel|camino|chimera|fennec|maemo browser|minimo|conkeror|klar)[\/ ]?([\w\.\+]+)/i,/(seamonkey|k-meleon|icecat|iceape|firebird|phoenix|palemoon|basilisk|waterfox)\/([-\w\.]+)$/i,/(firefox)\/([\w\.]+)/i,/(mozilla)\/([\w\.]+) .+rv\:.+gecko\/\d+/i,/(polaris|lynx|dillo|icab|doris|amaya|w3m|netsurf|sleipnir|obigo|mosaic|(?:go|ice|up)[\. ]?browser)[-\/ ]?v?([\w\.]+)/i,/(links) \(([\w\.]+)/i,/panasonic;(viera)/i],[c,f],[/(cobalt)\/([\w\.]+)/i],[c,[f,/master.|lts./,""]]],cpu:[[/(?:(amd|x(?:(?:86|64)[-_])?|wow|win)64)[;\)]/i],[[g,"amd64"]],[/(ia32(?=;))/i],[[g,q]],[/((?:i[346]|x)86)[;\)]/i],[[g,"ia32"]],[/\b(aarch64|arm(v?8e?l?|_?64))\b/i],[[g,"arm64"]],[/\b(arm(?:v[67])?ht?n?[fl]p?)\b/i],[[g,"armhf"]],[/windows (ce|mobile); ppc;/i],[[g,"arm"]],[/((?:ppc|powerpc)(?:64)?)(?: mac|;|\))/i],[[g,/ower/,"",q]],[/(sun4\w)[;\)]/i],[[g,"sparc"]],[/((?:avr32|ia64(?=;))|68k(?=\))|\barm(?=v(?:[1-7]|[5-7]1)l?|;|eabi)|(?=atmel )avr|(?:irix|mips|sparc)(?:64)?\b|pa-risc)/i],[[g,q]]],device:[[/\b(sch-i[89]0\d|shw-m380s|sm-[ptx]\w{2,4}|gt-[pn]\d{2,4}|sgh-t8[56]9|nexus 10)/i],[u,[p,D],[d,m]],[/\b((?:s[cgp]h|gt|sm)-\w+|sc[g-]?[\d]+a?|galaxy nexus)/i,/samsung[- ]([-\w]+)/i,/sec-(sgh\w+)/i],[u,[p,D],[d,v]],[/(?:\/|\()(ip(?:hone|od)[\w, ]*)(?:\/|;)/i],[u,[p,E],[d,v]],[/\((ipad);[-\w\),; ]+apple/i,/applecoremedia\/[\w\.]+ \((ipad)/i,/\b(ipad)\d\d?,\d\d?[;\]].+ios/i],[u,[p,E],[d,m]],[/(macintosh);/i],[u,[p,E]],[/\b(sh-?[altvz]?\d\d[a-ekm]?)/i],[u,[p,U],[d,v]],[/\b((?:ag[rs][23]?|bah2?|sht?|btv)-a?[lw]\d{2})\b(?!.+d\/s)/i],[u,[p,A],[d,m]],[/(?:huawei|honor)([-\w ]+)[;\)]/i,/\b(nexus 6p|\w{2,4}e?-[atu]?[ln][\dx][012359c][adn]?)\b(?!.+d\/s)/i],[u,[p,A],[d,v]],[/\b(poco[\w ]+|m2\d{3}j\d\d[a-z]{2})(?: bui|\))/i,/\b; (\w+) build\/hm\1/i,/\b(hm[-_ ]?note?[_ ]?(?:\d\w)?) bui/i,/\b(redmi[\-_ ]?(?:note|k)?[\w_ ]+)(?: bui|\))/i,/\b(mi[-_ ]?(?:a\d|one|one[_ ]plus|note lte|max|cc)?[_ ]?(?:\d?\w?)[_ ]?(?:plus|se|lite)?)(?: bui|\))/i],[[u,/_/g," "],[p,P],[d,v]],[/\b(mi[-_ ]?(?:pad)(?:[\w_ ]+))(?: bui|\))/i],[[u,/_/g," "],[p,P],[d,m]],[/; (\w+) bui.+ oppo/i,/\b(cph[12]\d{3}|p(?:af|c[al]|d\w|e[ar])[mt]\d0|x9007|a101op)\b/i],[u,[p,"OPPO"],[d,v]],[/vivo (\w+)(?: bui|\))/i,/\b(v[12]\d{3}\w?[at])(?: bui|;)/i],[u,[p,"Vivo"],[d,v]],[/\b(rmx[12]\d{3})(?: bui|;|\))/i],[u,[p,"Realme"],[d,v]],[/\b(milestone|droid(?:[2-4x]| (?:bionic|x2|pro|razr))?:?( 4g)?)\b[\w ]+build\//i,/\bmot(?:orola)?[- ](\w*)/i,/((?:moto[\w\(\) ]+|xt\d{3,4}|nexus 6)(?= bui|\)))/i],[u,[p,j],[d,v]],[/\b(mz60\d|xoom[2 ]{0,2}) build\//i],[u,[p,j],[d,m]],[/((?=lg)?[vl]k\-?\d{3}) bui| 3\.[-\w; ]{10}lg?-([06cv9]{3,4})/i],[u,[p,C],[d,m]],[/(lm(?:-?f100[nv]?|-[\w\.]+)(?= bui|\))|nexus [45])/i,/\blg[-e;\/ ]+((?!browser|netcast|android tv)\w+)/i,/\blg-?([\d\w]+) bui/i],[u,[p,C],[d,v]],[/(ideatab[-\w ]+)/i,/lenovo ?(s[56]000[-\w]+|tab(?:[\w ]+)|yt[-\d\w]{6}|tb[-\d\w]{6})/i],[u,[p,"Lenovo"],[d,m]],[/(?:maemo|nokia).*(n900|lumia \d+)/i,/nokia[-_ ]?([-\w\.]*)/i],[[u,/_/g," "],[p,"Nokia"],[d,v]],[/(pixel c)\b/i],[u,[p,O],[d,m]],[/droid.+; (pixel[\daxl ]{0,6})(?: bui|\))/i],[u,[p,O],[d,v]],[/droid.+ (a?\d[0-2]{2}so|[c-g]\d{4}|so[-gl]\w+|xq-a\w[4-7][12])(?= bui|\).+chrome\/(?![1-6]{0,1}\d\.))/i],[u,[p,M],[d,v]],[/sony tablet [ps]/i,/\b(?:sony)?sgp\w+(?: bui|\))/i],[[u,"Xperia Tablet"],[p,M],[d,m]],[/ (kb2005|in20[12]5|be20[12][59])\b/i,/(?:one)?(?:plus)? (a\d0\d\d)(?: b|\))/i],[u,[p,"OnePlus"],[d,v]],[/(alexa)webm/i,/(kf[a-z]{2}wi|aeo[c-r]{2})( bui|\))/i,/(kf[a-z]+)( bui|\)).+silk\//i],[u,[p,S],[d,m]],[/((?:sd|kf)[0349hijorstuw]+)( bui|\)).+silk\//i],[[u,/(.+)/g,"Fire Phone $1"],[p,S],[d,v]],[/(playbook);[-\w\),; ]+(rim)/i],[u,p,[d,m]],[/\b((?:bb[a-f]|st[hv])100-\d)/i,/\(bb10; (\w+)/i],[u,[p,x],[d,v]],[/(?:\b|asus_)(transfo[prime ]{4,10} \w+|eeepc|slider \w+|nexus 7|padfone|p00[cj])/i],[u,[p,T],[d,m]],[/ (z[bes]6[027][012][km][ls]|zenfone \d\w?)\b/i],[u,[p,T],[d,v]],[/(nexus 9)/i],[u,[p,"HTC"],[d,m]],[/(htc)[-;_ ]{1,2}([\w ]+(?=\)| bui)|\w+)/i,/(zte)[- ]([\w ]+?)(?: bui|\/|\))/i,/(alcatel|geeksphone|nexian|panasonic(?!(?:;|\.))|sony(?!-bra))[-_ ]?([-\w]*)/i],[p,[u,/_/g," "],[d,v]],[/droid.+; ([ab][1-7]-?[0178a]\d\d?)/i],[u,[p,"Acer"],[d,m]],[/droid.+; (m[1-5] note) bui/i,/\bmz-([-\w]{2,})/i],[u,[p,"Meizu"],[d,v]],[/(blackberry|benq|palm(?=\-)|sonyericsson|acer|asus|dell|meizu|motorola|polytron|infinix|tecno)[-_ ]?([-\w]*)/i,/(hp) ([\w ]+\w)/i,/(asus)-?(\w+)/i,/(microsoft); (lumia[\w ]+)/i,/(lenovo)[-_ ]?([-\w]+)/i,/(jolla)/i,/(oppo) ?([\w ]+) bui/i],[p,u,[d,v]],[/(kobo)\s(ereader|touch)/i,/(archos) (gamepad2?)/i,/(hp).+(touchpad(?!.+tablet)|tablet)/i,/(kindle)\/([\w\.]+)/i,/(nook)[\w ]+build\/(\w+)/i,/(dell) (strea[kpr\d ]*[\dko])/i,/(le[- ]+pan)[- ]+(\w{1,9}) bui/i,/(trinity)[- ]*(t\d{3}) bui/i,/(gigaset)[- ]+(q\w{1,9}) bui/i,/(vodafone) ([\w ]+)(?:\)| bui)/i],[p,u,[d,m]],[/(surface duo)/i],[u,[p,N],[d,m]],[/droid [\d\.]+; (fp\du?)(?: b|\))/i],[u,[p,"Fairphone"],[d,v]],[/(u304aa)/i],[u,[p,"AT&T"],[d,v]],[/\bsie-(\w*)/i],[u,[p,"Siemens"],[d,v]],[/\b(rct\w+) b/i],[u,[p,"RCA"],[d,m]],[/\b(venue[\d ]{2,7}) b/i],[u,[p,"Dell"],[d,m]],[/\b(q(?:mv|ta)\w+) b/i],[u,[p,"Verizon"],[d,m]],[/\b(?:barnes[& ]+noble |bn[rt])([\w\+ ]*) b/i],[u,[p,"Barnes & Noble"],[d,m]],[/\b(tm\d{3}\w+) b/i],[u,[p,"NuVision"],[d,m]],[/\b(k88) b/i],[u,[p,"ZTE"],[d,m]],[/\b(nx\d{3}j) b/i],[u,[p,"ZTE"],[d,v]],[/\b(gen\d{3}) b.+49h/i],[u,[p,"Swiss"],[d,v]],[/\b(zur\d{3}) b/i],[u,[p,"Swiss"],[d,m]],[/\b((zeki)?tb.*\b) b/i],[u,[p,"Zeki"],[d,m]],[/\b([yr]\d{2}) b/i,/\b(dragon[- ]+touch |dt)(\w{5}) b/i],[[p,"Dragon Touch"],u,[d,m]],[/\b(ns-?\w{0,9}) b/i],[u,[p,"Insignia"],[d,m]],[/\b((nxa|next)-?\w{0,9}) b/i],[u,[p,"NextBook"],[d,m]],[/\b(xtreme\_)?(v(1[045]|2[015]|[3469]0|7[05])) b/i],[[p,"Voice"],u,[d,v]],[/\b(lvtel\-)?(v1[12]) b/i],[[p,"LvTel"],u,[d,v]],[/\b(ph-1) /i],[u,[p,"Essential"],[d,v]],[/\b(v(100md|700na|7011|917g).*\b) b/i],[u,[p,"Envizen"],[d,m]],[/\b(trio[-\w\. ]+) b/i],[u,[p,"MachSpeed"],[d,m]],[/\btu_(1491) b/i],[u,[p,"Rotor"],[d,m]],[/(shield[\w ]+) b/i],[u,[p,"Nvidia"],[d,m]],[/(sprint) (\w+)/i],[p,u,[d,v]],[/(kin\.[onetw]{3})/i],[[u,/\./g," "],[p,N],[d,v]],[/droid.+; (cc6666?|et5[16]|mc[239][23]x?|vc8[03]x?)\)/i],[u,[p,_],[d,m]],[/droid.+; (ec30|ps20|tc[2-8]\d[kx])\)/i],[u,[p,_],[d,v]],[/smart-tv.+(samsung)/i],[p,[d,h]],[/hbbtv.+maple;(\d+)/i],[[u,/^/,"SmartTV"],[p,D],[d,h]],[/(nux; netcast.+smarttv|lg (netcast\.tv-201\d|android tv))/i],[[p,C],[d,h]],[/(apple) ?tv/i],[p,[u,E+" TV"],[d,h]],[/crkey/i],[[u,I+"cast"],[p,O],[d,h]],[/droid.+aft(\w+)( bui|\))/i],[u,[p,S],[d,h]],[/\(dtv[\);].+(aquos)/i,/(aquos-tv[\w ]+)\)/i],[u,[p,U],[d,h]],[/(bravia[\w ]+)( bui|\))/i],[u,[p,M],[d,h]],[/(mitv-\w{5}) bui/i],[u,[p,P],[d,h]],[/Hbbtv.*(technisat) (.*);/i],[p,u,[d,h]],[/\b(roku)[\dx]*[\)\/]((?:dvp-)?[\d\.]*)/i,/hbbtv\/\d+\.\d+\.\d+ +\([\w\+ ]*; *([\w\d][^;]*);([^;]*)/i],[[p,G],[u,G],[d,h]],[/\b(android tv|smart[- ]?tv|opera tv|tv; rv:)\b/i],[[d,h]],[/(ouya)/i,/(nintendo) ([wids3utch]+)/i],[p,u,[d,b]],[/droid.+; (shield) bui/i],[u,[p,"Nvidia"],[d,b]],[/(playstation [345portablevi]+)/i],[u,[p,M],[d,b]],[/\b(xbox(?: one)?(?!; xbox))[\); ]/i],[u,[p,N],[d,b]],[/((pebble))app/i],[p,u,[d,w]],[/(watch)(?: ?os[,\/]|\d,\d\/)[\d\.]+/i],[u,[p,E],[d,w]],[/droid.+; (glass) \d/i],[u,[p,O],[d,w]],[/droid.+; (wt63?0{2,3})\)/i],[u,[p,_],[d,w]],[/(quest( 2| pro)?)/i],[u,[p,B],[d,w]],[/(tesla)(?: qtcarbrowser|\/[-\w\.]+)/i],[p,[d,y]],[/(aeobc)\b/i],[u,[p,S],[d,y]],[/droid .+?; ([^;]+?)(?: bui|\) applew).+? mobile safari/i],[u,[d,v]],[/droid .+?; ([^;]+?)(?: bui|\) applew).+?(?! mobile) safari/i],[u,[d,m]],[/\b((tablet|tab)[;\/]|focus\/\d(?!.+mobile))/i],[[d,m]],[/(phone|mobile(?:[;\/]| [ \w\/\.]*safari)|pda(?=.+windows ce))/i],[[d,v]],[/(android[-\w\. ]{0,9});.+buil/i],[u,[p,"Generic"]]],engine:[[/windows.+ edge\/([\w\.]+)/i],[f,[c,"EdgeHTML"]],[/webkit\/537\.36.+chrome\/(?!27)([\w\.]+)/i],[f,[c,"Blink"]],[/(presto)\/([\w\.]+)/i,/(webkit|trident|netfront|netsurf|amaya|lynx|w3m|goanna)\/([\w\.]+)/i,/ekioh(flow)\/([\w\.]+)/i,/(khtml|tasman|links)[\/ ]\(?([\w\.]+)/i,/(icab)[\/ ]([23]\.[\d\.]+)/i,/\b(libweb)/i],[c,f],[/rv\:([\w\.]{1,9})\b.+(gecko)/i],[f,c]],os:[[/microsoft (windows) (vista|xp)/i],[c,f],[/(windows) nt 6\.2; (arm)/i,/(windows (?:phone(?: os)?|mobile))[\/ ]?([\d\.\w ]*)/i,/(windows)[\/ ]?([ntce\d\. ]+\w)(?!.+xbox)/i],[c,[f,K,H]],[/(win(?=3|9|n)|win 9x )([nt\d\.]+)/i],[[c,"Windows"],[f,K,H]],[/ip[honead]{2,4}\b(?:.*os ([\w]+) like mac|; opera)/i,/(?:ios;fbsv\/|iphone.+ios[\/ ])([\d\.]+)/i,/cfnetwork\/.+darwin/i],[[f,/_/g,"."],[c,"iOS"]],[/(mac os x) ?([\w\. ]*)/i,/(macintosh|mac_powerpc\b)(?!.+haiku)/i],[[c,F],[f,/_/g,"."]],[/droid ([\w\.]+)\b.+(android[- ]x86|harmonyos)/i],[f,c],[/(android|webos|qnx|bada|rim tablet os|maemo|meego|sailfish)[-\/ ]?([\w\.]*)/i,/(blackberry)\w*\/([\w\.]*)/i,/(tizen|kaios)[\/ ]([\w\.]+)/i,/\((series40);/i],[c,f],[/\(bb(10);/i],[f,[c,x]],[/(?:symbian ?os|symbos|s60(?=;)|series60)[-\/ ]?([\w\.]*)/i],[f,[c,"Symbian"]],[/mozilla\/[\d\.]+ \((?:mobile|tablet|tv|mobile; [\w ]+); rv:.+ gecko\/([\w\.]+)/i],[f,[c,L+" OS"]],[/web0s;.+rt(tv)/i,/\b(?:hp)?wos(?:browser)?\/([\w\.]+)/i],[f,[c,"webOS"]],[/watch(?: ?os[,\/]|\d,\d\/)([\d\.]+)/i],[f,[c,"watchOS"]],[/crkey\/([\d\.]+)/i],[f,[c,I+"cast"]],[/(cros) [\w]+(?:\)| ([\w\.]+)\b)/i],[[c,z],f],[/panasonic;(viera)/i,/(netrange)mmh/i,/(nettv)\/(\d+\.[\w\.]+)/i,/(nintendo|playstation) ([wids345portablevuch]+)/i,/(xbox); +xbox ([^\);]+)/i,/\b(joli|palm)\b ?(?:os)?\/?([\w\.]*)/i,/(mint)[\/\(\) ]?(\w*)/i,/(mageia|vectorlinux)[; ]/i,/([kxln]?ubuntu|debian|suse|opensuse|gentoo|arch(?= linux)|slackware|fedora|mandriva|centos|pclinuxos|red ?hat|zenwalk|linpus|raspbian|plan 9|minix|risc os|contiki|deepin|manjaro|elementary os|sabayon|linspire)(?: gnu\/linux)?(?: enterprise)?(?:[- ]linux)?(?:-gnu)?[-\/ ]?(?!chrom|package)([-\w\.]*)/i,/(hurd|linux) ?([\w\.]*)/i,/(gnu) ?([\w\.]*)/i,/\b([-frentopcghs]{0,5}bsd|dragonfly)[\/ ]?(?!amd|[ix346]{1,2}86)([\w\.]*)/i,/(haiku) (\w+)/i],[c,f],[/(sunos) ?([\w\.\d]*)/i],[[c,"Solaris"],f],[/((?:open)?solaris)[-\/ ]?([\w\.]*)/i,/(aix) ((\d)(?=\.|\)| )[\w\.])*/i,/\b(beos|os\/2|amigaos|morphos|openvms|fuchsia|hp-ux|serenityos)/i,/(unix) ?([\w\.]*)/i],[c,f]]},X=function(e,n){if(typeof e===o&&(n=e,e=i),!(this instanceof X))return new X(e,n).getResult();var b=typeof t!==s&&t.navigator?t.navigator:i,h=e||(b&&b.userAgent?b.userAgent:""),w=b&&b.userAgentData?b.userAgentData:i,y=n?function(e,n){var t={};for(var i in e)n[i]&&n[i].length%2==0?t[i]=n[i].concat(e[i]):t[i]=e[i];return t}(J,n):J,S=b&&b.userAgent==h;return this.getBrowser=function(){var e,n={};return n[c]=i,n[f]=i,W.call(n,h,y.browser),n[l]=typeof(e=n[f])===a?e.replace(/[^\d\.]/g,"").split(".")[0]:i,S&&b&&b.brave&&typeof b.brave.isBrave==r&&(n[c]="Brave"),n},this.getCPU=function(){var e={};return e[g]=i,W.call(e,h,y.cpu),e},this.getDevice=function(){var e={};return e[p]=i,e[u]=i,e[d]=i,W.call(e,h,y.device),S&&!e[d]&&w&&w.mobile&&(e[d]=v),S&&"Macintosh"==e[u]&&b&&typeof b.standalone!==s&&b.maxTouchPoints&&b.maxTouchPoints>2&&(e[u]="iPad",e[d]=m),e},this.getEngine=function(){var e={};return e[c]=i,e[f]=i,W.call(e,h,y.engine),e},this.getOS=function(){var e={};return e[c]=i,e[f]=i,W.call(e,h,y.os),S&&!e[c]&&w&&"Unknown"!=w.platform&&(e[c]=w.platform.replace(/chrome os/i,z).replace(/macos/i,F)),e},this.getResult=function(){return{ua:this.getUA(),browser:this.getBrowser(),engine:this.getEngine(),os:this.getOS(),device:this.getDevice(),cpu:this.getCPU()}},this.getUA=function(){return h},this.setUA=function(e){return h=typeof e===a&&e.length>350?G(e,350):e,this},this.setUA(h),this};X.VERSION="1.0.36",X.BROWSER=$([c,f,l]),X.CPU=$([g]),X.DEVICE=$([u,p,d,b,v,h,m,w,y]),X.ENGINE=X.OS=$([c,f]),e.exports&&(n=e.exports=X),n.UAParser=X;var Z=typeof t!==s&&(t.jQuery||t.Zepto);if(Z&&!Z.ua){var Q=new X;Z.ua=Q.getResult(),Z.ua.get=function(){return Q.getUA()},Z.ua.set=function(e){Q.setUA(e);var n=Q.getResult();for(var t in n)Z.ua[t]=n[t]}}}("object"==typeof window?window:N)}(ve,ve.exports);var me=ve.exports;const he=()=>{const e=new me.UAParser,{name:n,version:t}=e.getBrowser(),{name:i,version:r}=e.getOS(),s=e.getUA(),o=navigator.language,a=navigator.userAgent.includes("Mobi"),l=function(){if(!n||!t)return;if("userAgentData"in navigator)return navigator.userAgentData.brands;return}(),u="unknown";return{browser:{name:null!=n?n:u,version:null!=t?t:u,os:`${null!=i?i:u} ${null!=r?r:u}`,userAgent:null!=s?s:u,language:null!=o?o:u,mobile:a,brands:null!=l?l:u}}},we=()=>({page:{url:location.href}}),ye=[he,we];function Se(e){return{id:A(),attributes:e}}const Ee={name:"default"},Te="sessionStorage",xe="localStorage";function ke(n){var t;try{let e;e=window[n];const t="__faro_storage_test__";return e.setItem(t,t),e.removeItem(t),!0}catch(i){return null===(t=e.faro.internalLogger)||void 0===t||t.info(`Web storage of type ${n} is not available. Reason: ${i}`),!1}}function Ie(e,n){return Ne(n)?window[n].getItem(e):null}function Le(e,n,t){if(Ne(t))try{window[t].setItem(e,n)}catch(e){}}function Oe(e,n){Ne(n)&&window[n].removeItem(e)}const Ae=ke(xe),Ce=ke(Te);function Ne(e){return e===xe?Ae:e===Te&&Ce}function je(e,n){let t,i=!1;const r=()=>{null!=t?(e(...t),t=null,setTimeout(r,n)):i=!1};return(...s)=>{i?t=s:(e(...s),i=!0,setTimeout(r,n))}}const Re="__FARO_SESSION__",De=144e5,Ue={enabled:!1,persistent:!1,maxSessionPersistenceTime:147e5};function Me(e){const n=C();return{sessionId:null!=e?e:A(),lastActivity:n,started:n}}function Pe(e){if(null==e)return!1;const n=C();if(!(n-e.started<De))return!1;return n-e.lastActivity<9e5}function _e({fetchUserSession:n,storeUserSession:t}){return function(){var i,r,s,o;if(!n||!t)return;const a=n();if(Pe(a))t(Object.assign(Object.assign({},a),{lastActivity:C()}));else{let n=Be(Me(),a);t(n),null===(i=e.faro.api)||void 0===i||i.setSession(n.sessionMeta),null===(s=null===(r=e.faro.config.sessionTracking)||void 0===r?void 0:r.onSessionChange)||void 0===s||s.call(r,null!==(o=null==a?void 0:a.sessionMeta)&&void 0!==o?o:null,n.sessionMeta)}}}function Be(n,t){var i;const r=Object.assign(Object.assign({},n),{sessionMeta:{id:n.sessionId}}),s=null===(i=e.faro.metas.value.session)||void 0===i?void 0:i.attributes;return(s||null!=t)&&(r.sessionMeta.attributes=Object.assign(Object.assign({},null!=s?s:{}),null!=t?{previousSession:t.sessionId}:{})),r}class ze{constructor(e){this.initialSessionId=e,this.updateSession=je((()=>this.updateUserSession()),1e3),this.updateUserSession=_e({fetchUserSession:ze.fetchUserSession,storeUserSession:ze.storeUserSession}),this.init()}static removeUserSession(){Oe(Re,ze.storageTypeLocal)}static storeUserSession(e){Le(Re,JSON.stringify(e),ze.storageTypeLocal)}static fetchUserSession(){const e=Ie(Re,ze.storageTypeLocal);return e?JSON.parse(e):null}init(){ze.storeUserSession(Me(this.initialSessionId)),document.addEventListener("visibilitychange",(()=>{"visible"===document.visibilityState&&this.updateSession()})),window.addEventListener("storage",(n=>{var t,i,r;if(n.key!==Re)return;const s=JSON.parse(null!==(t=n.newValue)&&void 0!==t?t:""),o=JSON.parse(null!==(i=n.oldValue)&&void 0!==i?i:"");s.sessionId!==o.sessionId&&(null===(r=e.faro.api)||void 0===r||r.setSession(s.sessionMeta))})),e.faro.metas.addListener((function(n){const t=n.session,i=ze.fetchUserSession();if(t&&t.id!==(null==i?void 0:i.sessionId)){const n=Be(Me(t.id),i);ze.storeUserSession(n),e.faro.api.setSession(n.sessionMeta)}}))}}ze.storageTypeLocal=xe;class Fe{constructor(e){this.initialSessionId=e,this.updateSession=je((()=>this.updateUserSession()),1e3),this.updateUserSession=_e({fetchUserSession:Fe.fetchUserSession,storeUserSession:Fe.storeUserSession}),this.init()}static removeUserSession(){Oe(Re,Fe.storageTypeSession)}static storeUserSession(e){Le(Re,JSON.stringify(e),Fe.storageTypeSession)}static fetchUserSession(){const e=Ie(Re,Fe.storageTypeSession);return e?JSON.parse(e):null}init(){Fe.storeUserSession(Me(this.initialSessionId)),document.addEventListener("visibilitychange",(()=>{"visible"===document.visibilityState&&this.updateSession()})),e.faro.metas.addListener((function(n){const t=n.session,i=Fe.fetchUserSession();if(t&&t.id!==(null==i?void 0:i.sessionId)){const n=Be(Me(t.id),i);Fe.storeUserSession(n),e.faro.api.setSession(n.sessionMeta)}}))}}Fe.storageTypeSession=Te;class $e extends oe{constructor(){super(...arguments),this.name="@grafana/faro-web-sdk:instrumentation-session",this.version=ae}sendSessionStartEvent(e){var n,t;const i=e.session;if(i&&i.id!==(null===(n=this.notifiedSession)||void 0===n?void 0:n.id)){if(this.notifiedSession&&this.notifiedSession.id===(null===(t=i.attributes)||void 0===t?void 0:t.previousSession))return this.api.pushEvent("session_extend",{},void 0,{skipDedupe:!0}),void(this.notifiedSession=i);this.notifiedSession=i,this.api.pushEvent(be,{},void 0,{skipDedupe:!0})}}getSessionManagerInstanceByConfiguredStrategy(e){var n;return(null===(n=this.config.sessionTracking)||void 0===n?void 0:n.persistent)&&Ae?new ze(e):Ce?new Fe(e):null}createInitialSessionMeta(e){var n,t,i;let r=(e.persistent?ze:Fe).fetchUserSession();if(e.persistent&&e.maxSessionPersistenceTime&&r){const n=C();r.lastActivity<n-e.maxSessionPersistenceTime&&(ze.removeUserSession(),r=null)}let s=null===(n=e.session)||void 0===n?void 0:n.id,o=null===(t=e.session)||void 0===t?void 0:t.attributes;Pe(r)?(s=null==r?void 0:r.sessionId,o=null===(i=null==r?void 0:r.sessionMeta)||void 0===i?void 0:i.attributes,this.api.pushEvent("session_resume",{},void 0,{skipDedupe:!0})):(s=null!=s?s:Se().id,this.api.pushEvent(be,{},void 0,{skipDedupe:!0}));const a={id:s};return o&&(a.attributes=o),this.notifiedSession=a,a}initialize(){var e,n;this.logDebug("init session instrumentation");const t=this.config.sessionTracking;if(null==t?void 0:t.enabled){const i=this.createInitialSessionMeta(t);this.api.setSession(i);const r=this.getSessionManagerInstanceByConfiguredStrategy(null===(e=this.metas.value.session)||void 0===e?void 0:e.id);null!=r&&(null===(n=this.transports)||void 0===n||n.addBeforeSendHooks(...this.transports.getBeforeSendHooks(),(e=>(null==r||r.updateSession(),e))))}else this.sendSessionStartEvent(this.metas.value);this.metas.addListener(this.sendSessionStartEvent.bind(this))}}class Ve extends oe{constructor(e={}){super(),this.options=e,this.name="@grafana/faro-web-sdk:instrumentation-console",this.version=ae}initialize(){this.logDebug("Initializing\n",this.options),k.filter((e=>{var n;return!(null!==(n=this.options.disabledLevels)&&void 0!==n?n:Ve.defaultDisabledLevels).includes(e)})).forEach((e=>{console[e]=(...n)=>{try{this.api.pushLog(n,{level:e})}catch(e){this.logError(e)}finally{this.unpatchedConsole[e](...n)}}}))}}Ve.defaultDisabledLevels=[e.LogLevel.DEBUG,e.LogLevel.TRACE,e.LogLevel.LOG];const qe=/^(?:[Uu]ncaught (?:exception: )?)?(?:((?:Eval|Internal|Range|Reference|Syntax|Type|URI|)Error): )?(.*)$/i,Ge=/^\s*at (?:(.*\).*?|.*?) ?\((?:address at )?)?((?:file|https?|blob|chrome-extension|address|native|eval|webpack|<anonymous>|[-a-z]+:|.*bundle|\/)?.*?)(?::(\d+))?(?::(\d+))?\)?\s*$/i,We=/\((\S*)(?::(\d+))(?::(\d+))\)/,Ke="address at ",He=Ke.length,Je=/^\s*(.*?)(?:\((.*?)\))?(?:^|@)?((?:file|https?|blob|chrome|webpack|resource|moz-extension|safari-extension|safari-web-extension|capacitor)?:\/.*?|\[native code]|[^@]*(?:bundle|\d+\.js)|\/[\w\-. /=]+)(?::(\d+))?(?::(\d+))?\s*$/i,Xe=/(\S+) line (\d+)(?: > eval line \d+)* > eval/i,Ze="safari-extension",Qe="safari-web-extension",Ye=/Minified React error #\d+;/i;function en(e,n,t,i){const r={filename:e||document.location.href,function:n||"?"};return void 0!==t&&(r.lineno=t),void 0!==i&&(r.colno=i),r}function nn(e,n){const t=null==e?void 0:e.includes(Ze),i=!t&&(null==e?void 0:e.includes(Qe));return t||i?[(null==e?void 0:e.includes("@"))?e.split("@")[0]:e,t?`${Ze}:${n}`:`${Qe}:${n}`]:[e,n]}function tn(e){let n=[];e.stacktrace?n=e.stacktrace.split("\n").filter(((e,n)=>n%2==0)):e.stack&&(n=e.stack.split("\n"));const t=n.reduce(((n,t,i)=>{let r,s,o,l,u;if(r=Ge.exec(t)){if(s=r[1],o=r[2],l=r[3],u=r[4],null==o?void 0:o.startsWith("eval")){const e=We.exec(o);e&&(o=e[1],l=e[2],u=e[3])}o=(null==o?void 0:o.startsWith(Ke))?o.substring(He):o,[s,o]=nn(s,o)}else if(r=Je.exec(t)){if(s=r[1],o=r[3],l=r[4],u=r[5],o&&o.includes(" > eval")){const e=Xe.exec(o);e&&(s=s||"eval",o=e[1],l=e[2])}else 0===i&&!u&&a(e.columnNumber)&&(u=String(e.columnNumber+1));[s,o]=nn(s,o)}return(o||s)&&n.push(en(o,s,l?Number(l):void 0,u?Number(u):void 0)),n}),[]);return Ye.test(e.message)?t.slice(1):t}function rn(e){return{frames:tn(e)}}function sn(e){let n,t,i,r,s=[];if(v(e)&&e.error)n=e.error.message,t=e.error.name,s=tn(e.error);else if((i=m(e))||h(e)){const{name:r,message:s}=e;t=null!=r?r:i?"DOMError":"DOMException",n=s?`${t}: ${s}`:t}else b(e)?(n=e.message,s=tn(e)):(l(e)||(r=f(e)))&&(t=r?e.constructor.name:void 0,n=`Non-Error exception captured with keys: ${Object.keys(e)}`);return[n,t,s]}function on(e){const n=window.onerror;window.onerror=(...t)=>{try{const[i,r,s,a,l]=t;let u,c,d=[];const p=o(i),f=en(r,"?",s,a);l||!p?([u,c,d]=sn(null!=l?l:i),0===d.length&&(d=[f])):p&&([u,c]=function(e){var n,t;const i=e.match(qe),r=null!==(n=null==i?void 0:i[1])&&void 0!==n?n:te;return[null!==(t=null==i?void 0:i[2])&&void 0!==t?t:e,r]}(i),d=[f]),u&&e.pushError(new Error(u),{type:c,stackFrames:d})}finally{null==n||n.apply(window,t)}}}class an extends oe{constructor(){super(...arguments),this.name="@grafana/faro-web-sdk:instrumentation-errors",this.version=ae}initialize(){var e;this.logDebug("Initializing"),on(this.api),e=this.api,window.addEventListener("unhandledrejection",(n=>{var t,i;let r,s,o=n;o.reason?o=n.reason:(null===(t=n.detail)||void 0===t?void 0:t.reason)&&(o=null===(i=n.detail)||void 0===i?void 0:i.reason);let a=[];d(o)?(r=`Non-Error promise rejection captured with value: ${String(o)}`,s="UnhandledRejection"):[r,s,a]=sn(o),r&&e.pushError(new Error(r),{type:s,stackFrames:a})}))}}class ln extends oe{constructor(){super(...arguments),this.name="@grafana/faro-web-sdk:instrumentation-view",this.version=ae}sendViewChangedEvent(e){const n=e.view;n&&n!==this.notifiedView&&(this.notifiedView=n,this.api.pushEvent("view_changed",{},void 0,{skipDedupe:!0}))}initialize(){this.sendViewChangedEvent(this.metas.value),this.metas.addListener(this.sendViewChangedEvent.bind(this))}}var un,cn,dn,pn,fn,gn=-1,bn=function(e){addEventListener("pageshow",(function(n){n.persisted&&(gn=n.timeStamp,e(n))}),!0)},vn=function(){return window.performance&&performance.getEntriesByType&&performance.getEntriesByType("navigation")[0]},mn=function(){var e=vn();return e&&e.activationStart||0},hn=function(e,n){var t=vn(),i="navigate";return gn>=0?i="back-forward-cache":t&&(document.prerendering||mn()>0?i="prerender":document.wasDiscarded?i="restore":t.type&&(i=t.type.replace(/_/g,"-"))),{name:e,value:void 0===n?-1:n,rating:"good",delta:0,entries:[],id:"v3-".concat(Date.now(),"-").concat(Math.floor(8999999999999*Math.random())+1e12),navigationType:i}},wn=function(e,n,t){try{if(PerformanceObserver.supportedEntryTypes.includes(e)){var i=new PerformanceObserver((function(e){Promise.resolve().then((function(){n(e.getEntries())}))}));return i.observe(Object.assign({type:e,buffered:!0},t||{})),i}}catch(e){}},yn=function(e,n,t,i){var r,s;return function(o){n.value>=0&&(o||i)&&((s=n.value-(r||0))||void 0===r)&&(r=n.value,n.delta=s,n.rating=function(e,n){return e>n[1]?"poor":e>n[0]?"needs-improvement":"good"}(n.value,t),e(n))}},Sn=function(e){requestAnimationFrame((function(){return requestAnimationFrame((function(){return e()}))}))},En=function(e){var n=function(n){"pagehide"!==n.type&&"hidden"!==document.visibilityState||e(n)};addEventListener("visibilitychange",n,!0),addEventListener("pagehide",n,!0)},Tn=function(e){var n=!1;return function(t){n||(e(t),n=!0)}},xn=-1,kn=function(){return"hidden"!==document.visibilityState||document.prerendering?1/0:0},In=function(e){"hidden"===document.visibilityState&&xn>-1&&(xn="visibilitychange"===e.type?e.timeStamp:0,On())},Ln=function(){addEventListener("visibilitychange",In,!0),addEventListener("prerenderingchange",In,!0)},On=function(){removeEventListener("visibilitychange",In,!0),removeEventListener("prerenderingchange",In,!0)},An=function(){return xn<0&&(xn=kn(),Ln(),bn((function(){setTimeout((function(){xn=kn(),Ln()}),0)}))),{get firstHiddenTime(){return xn}}},Cn=function(e){document.prerendering?addEventListener("prerenderingchange",(function(){return e()}),!0):e()},Nn=[1800,3e3],jn=function(e,n){n=n||{},Cn((function(){var t,i=An(),r=hn("FCP"),s=wn("paint",(function(e){e.forEach((function(e){"first-contentful-paint"===e.name&&(s.disconnect(),e.startTime<i.firstHiddenTime&&(r.value=Math.max(e.startTime-mn(),0),r.entries.push(e),t(!0)))}))}));s&&(t=yn(e,r,Nn,n.reportAllChanges),bn((function(i){r=hn("FCP"),t=yn(e,r,Nn,n.reportAllChanges),Sn((function(){r.value=performance.now()-i.timeStamp,t(!0)}))})))}))},Rn=[.1,.25],Dn={passive:!0,capture:!0},Un=new Date,Mn=function(e,n){un||(un=n,cn=e,dn=new Date,Bn(removeEventListener),Pn())},Pn=function(){if(cn>=0&&cn<dn-Un){var e={entryType:"first-input",name:un.type,target:un.target,cancelable:un.cancelable,startTime:un.timeStamp,processingStart:un.timeStamp+cn};pn.forEach((function(n){n(e)})),pn=[]}},_n=function(e){if(e.cancelable){var n=(e.timeStamp>1e12?new Date:performance.now())-e.timeStamp;"pointerdown"==e.type?function(e,n){var t=function(){Mn(e,n),r()},i=function(){r()},r=function(){removeEventListener("pointerup",t,Dn),removeEventListener("pointercancel",i,Dn)};addEventListener("pointerup",t,Dn),addEventListener("pointercancel",i,Dn)}(n,e):Mn(n,e)}},Bn=function(e){["mousedown","keydown","touchstart","pointerdown"].forEach((function(n){return e(n,_n,Dn)}))},zn=[100,300],Fn=0,$n=1/0,Vn=0,qn=function(e){e.forEach((function(e){e.interactionId&&($n=Math.min($n,e.interactionId),Vn=Math.max(Vn,e.interactionId),Fn=Vn?(Vn-$n)/7+1:0)}))},Gn=function(){return fn?Fn:performance.interactionCount||0},Wn=function(){"interactionCount"in performance||fn||(fn=wn("event",qn,{type:"event",buffered:!0,durationThreshold:0}))},Kn=[200,500],Hn=0,Jn=function(){return Gn()-Hn},Xn=[],Zn={},Qn=function(e){var n=Xn[Xn.length-1],t=Zn[e.interactionId];if(t||Xn.length<10||e.duration>n.latency){if(t)t.entries.push(e),t.latency=Math.max(t.latency,e.duration);else{var i={id:e.interactionId,latency:e.duration,entries:[e]};Zn[i.id]=i,Xn.push(i)}Xn.sort((function(e,n){return n.latency-e.latency})),Xn.splice(10).forEach((function(e){delete Zn[e.id]}))}},Yn=[2500,4e3],et={},nt=[800,1800],tt=function e(n){document.prerendering?Cn((function(){return e(n)})):"complete"!==document.readyState?addEventListener("load",(function(){return e(n)}),!0):setTimeout(n,0)};class it extends oe{constructor(){super(...arguments),this.name="@grafana/faro-web-sdk:instrumentation-web-vitals",this.version=ae}initialize(){this.logDebug("Initializing"),Object.entries(it.mapping).forEach((([e,n])=>{n((n=>{this.api.pushMeasurement({type:"web-vitals",values:{[e]:n.value}})}))}))}}function rt(e={}){const n=[new an,new it,new $e,new ln];return!1!==e.captureConsole&&n.push(new Ve({disabledLevels:e.captureConsoleDisabledLevels})),n}it.mapping={cls:function(e,n){n=n||{},jn(Tn((function(){var t,i=hn("CLS",0),r=0,s=[],o=function(e){e.forEach((function(e){if(!e.hadRecentInput){var n=s[0],t=s[s.length-1];r&&e.startTime-t.startTime<1e3&&e.startTime-n.startTime<5e3?(r+=e.value,s.push(e)):(r=e.value,s=[e])}})),r>i.value&&(i.value=r,i.entries=s,t())},a=wn("layout-shift",o);a&&(t=yn(e,i,Rn,n.reportAllChanges),En((function(){o(a.takeRecords()),t(!0)})),bn((function(){r=0,i=hn("CLS",0),t=yn(e,i,Rn,n.reportAllChanges),Sn((function(){return t()}))})),setTimeout(t,0))})))},fcp:jn,fid:function(e,n){n=n||{},Cn((function(){var t,i=An(),r=hn("FID"),s=function(e){e.startTime<i.firstHiddenTime&&(r.value=e.processingStart-e.startTime,r.entries.push(e),t(!0))},o=function(e){e.forEach(s)},a=wn("first-input",o);t=yn(e,r,zn,n.reportAllChanges),a&&En(Tn((function(){o(a.takeRecords()),a.disconnect()}))),a&&bn((function(){var i;r=hn("FID"),t=yn(e,r,zn,n.reportAllChanges),pn=[],cn=-1,un=null,Bn(addEventListener),i=s,pn.push(i),Pn()}))}))},inp:function(e,n){n=n||{},Cn((function(){var t;Wn();var i,r=hn("INP"),s=function(e){e.forEach((function(e){e.interactionId&&Qn(e),"first-input"===e.entryType&&!Xn.some((function(n){return n.entries.some((function(n){return e.duration===n.duration&&e.startTime===n.startTime}))}))&&Qn(e)}));var n,t=(n=Math.min(Xn.length-1,Math.floor(Jn()/50)),Xn[n]);t&&t.latency!==r.value&&(r.value=t.latency,r.entries=t.entries,i())},o=wn("event",s,{durationThreshold:null!==(t=n.durationThreshold)&&void 0!==t?t:40});i=yn(e,r,Kn,n.reportAllChanges),o&&("interactionId"in PerformanceEventTiming.prototype&&o.observe({type:"first-input",buffered:!0}),En((function(){s(o.takeRecords()),r.value<0&&Jn()>0&&(r.value=0,r.entries=[]),i(!0)})),bn((function(){Xn=[],Hn=Gn(),r=hn("INP"),i=yn(e,r,Kn,n.reportAllChanges)})))}))},lcp:function(e,n){n=n||{},Cn((function(){var t,i=An(),r=hn("LCP"),s=function(e){var n=e[e.length-1];n&&n.startTime<i.firstHiddenTime&&(r.value=Math.max(n.startTime-mn(),0),r.entries=[n],t())},o=wn("largest-contentful-paint",s);if(o){t=yn(e,r,Yn,n.reportAllChanges);var a=Tn((function(){et[r.id]||(s(o.takeRecords()),o.disconnect(),et[r.id]=!0,t(!0))}));["keydown","click"].forEach((function(e){addEventListener(e,(function(){return setTimeout(a,0)}),!0)})),En(a),bn((function(i){r=hn("LCP"),t=yn(e,r,Yn,n.reportAllChanges),Sn((function(){r.value=performance.now()-i.timeStamp,et[r.id]=!0,t(!0)}))}))}}))},ttfb:function(e,n){n=n||{};var t=hn("TTFB"),i=yn(e,t,nt,n.reportAllChanges);tt((function(){var r=vn();if(r){var s=r.responseStart;if(s<=0||s>performance.now())return;t.value=Math.max(s-mn(),0),t.entries=[r],i(!0),bn((function(){t=hn("TTFB",0),(i=yn(e,t,nt,n.reportAllChanges))(!0)}))}}))}};const st="browser",ot=()=>({k6:{isK6Browser:!0}});function at(e,n,t,i){return new(t||(t=Promise))((function(r,s){function o(e){try{l(i.next(e))}catch(e){s(e)}}function a(e){try{l(i.throw(e))}catch(e){s(e)}}function l(e){var n;e.done?r(e.value):(n=e.value,n instanceof t?n:new t((function(e){e(n)}))).then(o,a)}l((i=i.apply(e,n||[])).next())}))}"function"==typeof SuppressedError&&SuppressedError;class lt extends Y{constructor(e){var n,t,i,r;super(),this.options=e,this.name="@grafana/faro-web-sdk:transport-fetch",this.version=ae,this.disabledUntil=new Date,this.rateLimitBackoffMs=null!==(n=e.defaultRateLimitBackoffMs)&&void 0!==n?n:5e3,this.getNow=null!==(t=e.getNow)&&void 0!==t?t:()=>Date.now(),this.promiseBuffer=L({size:null!==(i=e.bufferSize)&&void 0!==i?i:30,concurrency:null!==(r=e.concurrency)&&void 0!==r?r:5})}send(e){return at(this,void 0,void 0,(function*(){try{if(this.disabledUntil>new Date(this.getNow()))return this.logWarn(`Dropping transport item due to too many requests. Backoff until ${this.disabledUntil}`),Promise.resolve();yield this.promiseBuffer.add((()=>{var n;const t=JSON.stringify(ne(e)),{url:i,requestOptions:r,apiKey:s}=this.options,o=null!=r?r:{},{headers:a}=o,l=function(e,n){var t={};for(var i in e)Object.prototype.hasOwnProperty.call(e,i)&&n.indexOf(i)<0&&(t[i]=e[i]);if(null!=e&&"function"==typeof Object.getOwnPropertySymbols){var r=0;for(i=Object.getOwnPropertySymbols(e);r<i.length;r++)n.indexOf(i[r])<0&&Object.prototype.propertyIsEnumerable.call(e,i[r])&&(t[i[r]]=e[i[r]])}return t}(o,["headers"]),u=null===(n=this.metas.value.session)||void 0===n?void 0:n.id;return fetch(i,Object.assign({method:"POST",headers:Object.assign(Object.assign(Object.assign({"Content-Type":"application/json"},null!=a?a:{}),s?{"x-api-key":s}:{}),u?{"x-faro-session-id":u}:{}),body:t,keepalive:t.length<=6e4},null!=l?l:{})).then((e=>(429===e.status&&(this.disabledUntil=this.getRetryAfterDate(e),this.logWarn(`Too many requests, backing off until ${this.disabledUntil}`)),e.text().catch(I),e))).catch((e=>{this.logError("Failed sending payload to the receiver\n",JSON.parse(t),e)}))}))}catch(e){this.logError(e)}}))}getIgnoreUrls(){return[this.options.url]}isBatched(){return!0}getRetryAfterDate(e){const n=this.getNow(),t=e.headers.get("Retry-After");if(t){const e=Number(t);if(!isNaN(e))return new Date(1e3*e+n);const i=Date.parse(t);if(!isNaN(i))return new Date(i)}return new Date(n+this.rateLimitBackoffMs)}}function ut(e){var n,t,i,r,s,o,a,u,c,d,p;const f=[],g=J(e.unpatchedConsole,e.internalLoggerLevel);e.transports?((e.url||e.apiKey)&&g.error('if "transports" is defined, "url" and "apiKey" should not be defined'),f.push(...e.transports)):e.url?f.push(new lt({url:e.url,apiKey:e.apiKey})):g.error('either "url" or "transports" must be defined');const b={app:e.app,batching:Object.assign(Object.assign({},ge),e.batching),dedupe:null===(n=e.dedupe)||void 0===n||n,globalObjectKey:e.globalObjectKey||fe,instrumentations:null!==(t=e.instrumentations)&&void 0!==t?t:rt(),internalLoggerLevel:null!==(i=e.internalLoggerLevel)&&void 0!==i?i:G,isolate:null!==(r=e.isolate)&&void 0!==r&&r,metas:function(){const n=ye;return e.metas&&n.push(...e.metas),l(window.k6)?[...n,ot]:n}(),parseStacktrace:rn,paused:null!==(s=e.paused)&&void 0!==s&&s,preventGlobalExposure:null!==(o=e.preventGlobalExposure)&&void 0!==o&&o,transports:f,unpatchedConsole:null!==(a=e.unpatchedConsole)&&void 0!==a?a:W,beforeSend:e.beforeSend,eventDomain:null!==(u=e.eventDomain)&&void 0!==u?u:st,ignoreErrors:e.ignoreErrors,sessionTracking:Object.assign(Object.assign({},Ue),e.sessionTracking),session:null!==(c=e.session)&&void 0!==c?c:Se(),user:e.user,view:null!==(d=e.view)&&void 0!==d?d:Ee};return(null===(p=b.sessionTracking)||void 0===p?void 0:p.enabled)&&delete b.session,b}return e.BaseExtension=Q,e.BaseInstrumentation=oe,e.BaseTransport=Y,e.ConsoleInstrumentation=Ve,e.ConsoleTransport=class extends Y{constructor(e={}){super(),this.options=e,this.name="@grafana/faro-web-sdk:transport-console",this.version=ae}send(n){var t;return this.unpatchedConsole[null!==(t=this.options.level)&&void 0!==t?t:e.LogLevel.DEBUG]("New event",ne([n]))}},e.Conventions={EventNames:{CLICK:"click",NAVIGATION:"navigation",SESSION_START:"session_start",VIEW_CHANGED:"view_changed"}},e.ErrorsInstrumentation=an,e.FetchTransport=lt,e.SessionInstrumentation=$e,e.VERSION=ae,e.ViewInstrumentation=ln,e.WebVitalsInstrumentation=it,e.allLogLevels=k,e.browserMeta=he,e.buildStackFrame=en,e.createInternalLogger=J,e.createPromiseBuffer=L,e.createSession=Se,e.deepEqual=S,e.defaultEventDomain=st,e.defaultExceptionType=te,e.defaultGlobalObjectKey=fe,e.defaultInternalLoggerLevel=G,e.defaultLogLevel=x,e.defaultMetas=ye,e.defaultViewMeta=Ee,e.genShortID=A,e.getCurrentTimestamp=E,e.getDataFromSafariExtensions=nn,e.getInternalFaroFromGlobalObject=function(){return se[le]},e.getStackFramesFromError=tn,e.getTransportBody=ne,e.getWebInstrumentations=rt,e.globalObject=se,e.initializeFaro=function(e){const n=ut(e);if(n)return pe(n)},e.internalGlobalObjectKey=le,e.isArray=c,e.isBoolean=e=>n(e,"boolean"),e.isDomError=m,e.isDomException=h,e.isElement=e=>w&&i(e,Element),e.isElementDefined=w,e.isError=b,e.isErrorDefined=g,e.isErrorEvent=v,e.isEvent=f,e.isEventDefined=p,e.isFunction=u,e.isInstanceOf=i,e.isInt=e=>a(e)&&Number.isInteger(e),e.isInternalFaroOnGlobalObject=ce,e.isMap=e=>y&&i(e,Map),e.isMapDefined=y,e.isNull=s,e.isNumber=a,e.isObject=l,e.isPrimitive=d,e.isRegExp=e=>t(e,"RegExp"),e.isString=o,e.isSymbol=e=>n(e,"symbol"),e.isSyntheticEvent=e=>l(e)&&"nativeEvent"in e&&"preventDefault"in e&&"stopPropagation"in e,e.isThenable=e=>u(null==e?void 0:e.then),e.isToString=t,e.isTypeof=n,e.isUndefined=r,e.makeCoreConfig=ut,e.noop=I,e.pageMeta=we,e.parseStacktrace=rn,e.sdkMeta=()=>({sdk:{name:"@grafana/faro-core",version:ae,integrations:e.faro.config.instrumentations.map((({name:e,version:n})=>({name:e,version:n})))}}),e.setInternalFaroOnGlobalObject=ue,e.transportItemTypeToBodyKey=F,e}({}); | ||
var GrafanaFaroWebSdk=function(e){"use strict";function n(e,n){return typeof e===n}function t(e,n){return Object.prototype.toString.call(e)===`[object ${n}]`}function i(e,n){try{return e instanceof n}catch(e){return!1}}const r=e=>n(e,"undefined"),s=e=>n(e,"null"),o=e=>n(e,"string"),a=e=>n(e,"number")&&!isNaN(e)||n(e,"bigint"),l=e=>!s(e)&&n(e,"object"),u=e=>n(e,"function"),c=e=>t(e,"Array"),d=e=>!l(e)&&!u(e),p=!r(Event),f=e=>p&&i(e,Event),g="undefined"!=typeof Error,b=e=>g&&i(e,Error),v=e=>t(e,"ErrorEvent"),m=e=>t(e,"DOMError"),h=e=>t(e,"DOMException"),w="undefined"!=typeof Element,y="undefined"!=typeof Map;function S(e,t){if(e===t)return!0;if(n(e,"number")&&isNaN(e))return n(t,"number")&&isNaN(t);const i=c(e),r=c(t);if(i!==r)return!1;if(i&&r){const n=e.length;if(n!==t.length)return!1;for(let i=n;0!=i--;)if(!S(e[i],t[i]))return!1;return!0}const s=l(e),o=l(t);if(s!==o)return!1;if(e&&t&&s&&o){const n=Object.keys(e),i=Object.keys(t);if(n.length!==i.length)return!1;for(let e of n)if(!i.includes(e))return!1;for(let i of n)if(!S(e[i],t[i]))return!1;return!0}return!1}function E(){return(new Date).toISOString()}var T;e.LogLevel=void 0,(T=e.LogLevel||(e.LogLevel={})).TRACE="trace",T.DEBUG="debug",T.INFO="info",T.LOG="log",T.WARN="warn",T.ERROR="error";const x=e.LogLevel.LOG,k=[e.LogLevel.TRACE,e.LogLevel.DEBUG,e.LogLevel.INFO,e.LogLevel.LOG,e.LogLevel.WARN,e.LogLevel.ERROR];function I(){}function L(e){const{size:n,concurrency:t}=e,i=[];let r=0;const s=()=>{if(r<t&&i.length){const{producer:e,resolve:n,reject:t}=i.shift();r++,e().then((e=>{r--,s(),n(e)}),(e=>{r--,s(),t(e)}))}};return{add:e=>{if(i.length+r>=n)throw new Error("Task buffer full");return new Promise(((n,t)=>{i.push({producer:e,resolve:n,reject:t}),s()}))}}}const O="abcdefghijkmnopqrstuvwxyzABCDEFGHJKLMNPQRSTUVWXYZ0123456789";function A(e=10){return Array.from(Array(e)).map((()=>O[Math.floor(Math.random()*O.length)])).join("")}function C(){return Date.now()}var N="undefined"!=typeof globalThis?globalThis:"undefined"!=typeof window?window:"undefined"!=typeof global?global:"undefined"!=typeof self?self:{},j={exports:{}},R={exports:{}};R.exports=function(e,n){var t,i,r,s,o,a,l,u;for(t=3&e.length,i=e.length-t,r=n,o=3432918353,a=461845907,u=0;u<i;)l=255&e.charCodeAt(u)|(255&e.charCodeAt(++u))<<8|(255&e.charCodeAt(++u))<<16|(255&e.charCodeAt(++u))<<24,++u,r=27492+(65535&(s=5*(65535&(r=(r^=l=(65535&(l=(l=(65535&l)*o+(((l>>>16)*o&65535)<<16)&4294967295)<<15|l>>>17))*a+(((l>>>16)*a&65535)<<16)&4294967295)<<13|r>>>19))+((5*(r>>>16)&65535)<<16)&4294967295))+((58964+(s>>>16)&65535)<<16);switch(l=0,t){case 3:l^=(255&e.charCodeAt(u+2))<<16;case 2:l^=(255&e.charCodeAt(u+1))<<8;case 1:r^=l=(65535&(l=(l=(65535&(l^=255&e.charCodeAt(u)))*o+(((l>>>16)*o&65535)<<16)&4294967295)<<15|l>>>17))*a+(((l>>>16)*a&65535)<<16)&4294967295}return r^=e.length,r=2246822507*(65535&(r^=r>>>16))+((2246822507*(r>>>16)&65535)<<16)&4294967295,r=3266489909*(65535&(r^=r>>>13))+((3266489909*(r>>>16)&65535)<<16)&4294967295,(r^=r>>>16)>>>0};var D=R.exports,U={exports:{}};!function(e){e.exports=function(e,n){for(var t,i=e.length,r=n^i,s=0;i>=4;)t=1540483477*(65535&(t=255&e.charCodeAt(s)|(255&e.charCodeAt(++s))<<8|(255&e.charCodeAt(++s))<<16|(255&e.charCodeAt(++s))<<24))+((1540483477*(t>>>16)&65535)<<16),r=1540483477*(65535&r)+((1540483477*(r>>>16)&65535)<<16)^(t=1540483477*(65535&(t^=t>>>24))+((1540483477*(t>>>16)&65535)<<16)),i-=4,++s;switch(i){case 3:r^=(255&e.charCodeAt(s+2))<<16;case 2:r^=(255&e.charCodeAt(s+1))<<8;case 1:r=1540483477*(65535&(r^=255&e.charCodeAt(s)))+((1540483477*(r>>>16)&65535)<<16)}return r=1540483477*(65535&(r^=r>>>13))+((1540483477*(r>>>16)&65535)<<16),(r^=r>>>15)>>>0}}(U);var M=D,P=U.exports;j.exports=M;var _=j.exports.murmur3=M;j.exports.murmur2=P;class B{constructor(e,n){var t,i;this.signalBuffer=[],this.itemLimit=null!==(t=null==n?void 0:n.itemLimit)&&void 0!==t?t:50,this.sendTimeout=null!==(i=null==n?void 0:n.sendTimeout)&&void 0!==i?i:250,this.paused=(null==n?void 0:n.paused)||!1,this.sendFn=e,this.flushInterval=-1,this.paused||this.start(),document.addEventListener("visibilitychange",(()=>{"hidden"===document.visibilityState&&this.flush()}))}addItem(e){this.paused||(this.signalBuffer.push(e),this.signalBuffer.length>=this.itemLimit&&this.flush())}start(){this.paused=!1,this.sendTimeout>0&&(this.flushInterval=window.setInterval((()=>this.flush()),this.sendTimeout))}pause(){this.paused=!0,clearInterval(this.flushInterval)}groupItems(e){const n=new Map;return e.forEach((e=>{const t=_(JSON.stringify(e.meta));let i=n.get(t);i=void 0===i?[e]:[...i,e],n.set(t,i)})),Array.from(n.values())}flush(){if(this.paused||0===this.signalBuffer.length)return;this.groupItems(this.signalBuffer).forEach(this.sendFn),this.signalBuffer=[]}}var z;e.TransportItemType=void 0,(z=e.TransportItemType||(e.TransportItemType={})).EXCEPTION="exception",z.LOG="log",z.MEASUREMENT="measurement",z.TRACE="trace",z.EVENT="event";const F={[e.TransportItemType.EXCEPTION]:"exceptions",[e.TransportItemType.LOG]:"logs",[e.TransportItemType.MEASUREMENT]:"measurements",[e.TransportItemType.TRACE]:"traces",[e.TransportItemType.EVENT]:"events"};function $(n){return t=>{if(t.type===e.TransportItemType.EXCEPTION&&t.payload){const e=t.payload,i=`${e.type}: ${e.value}`;if(function(e,n){return e.some((e=>o(e)?n.includes(e):!!n.match(e)))}(n,i))return null}return t}}var V;e.InternalLoggerLevel=void 0,(V=e.InternalLoggerLevel||(e.InternalLoggerLevel={}))[V.OFF=0]="OFF",V[V.ERROR=1]="ERROR",V[V.WARN=2]="WARN",V[V.INFO=3]="INFO",V[V.VERBOSE=4]="VERBOSE";const q={debug:I,error:I,info:I,prefix:"Faro",warn:I},G=e.InternalLoggerLevel.ERROR,W=Object.assign({},console);let K=W;function H(e){var n;return K=null!==(n=e.unpatchedConsole)&&void 0!==n?n:K,K}function J(n=W,t=G){const i=q;return t>e.InternalLoggerLevel.OFF&&(i.error=t>=e.InternalLoggerLevel.ERROR?function(...e){n.error(`${i.prefix}\n`,...e)}:I,i.warn=t>=e.InternalLoggerLevel.WARN?function(...e){n.warn(`${i.prefix}\n`,...e)}:I,i.info=t>=e.InternalLoggerLevel.INFO?function(...e){n.info(`${i.prefix}\n`,...e)}:I,i.debug=t>=e.InternalLoggerLevel.VERBOSE?function(...e){n.debug(`${i.prefix}\n`,...e)}:I),i}let X=q;function Z(e,n){return X=J(e,n.internalLoggerLevel),X}class Q{constructor(){this.unpatchedConsole=W,this.internalLogger=q,this.config={},this.metas={}}logDebug(...e){this.internalLogger.debug(`${this.name}\n`,...e)}logInfo(...e){this.internalLogger.info(`${this.name}\n`,...e)}logWarn(...e){this.internalLogger.warn(`${this.name}\n`,...e)}logError(...e){this.internalLogger.error(`${this.name}\n`,...e)}}class Y extends Q{isBatched(){return!1}getIgnoreUrls(){return[]}}function ee(e,n){var t,i;if(void 0===n)return e;if(void 0===e)return{resourceSpans:n};const r=null===(t=e.resourceSpans)||void 0===t?void 0:t[0];if(void 0===r)return e;const s=(null==r?void 0:r.scopeSpans)||[],o=(null===(i=null==n?void 0:n[0])||void 0===i?void 0:i.scopeSpans)||[];return Object.assign(Object.assign({},e),{resourceSpans:[Object.assign(Object.assign({},r),{scopeSpans:[...s,...o]})]})}function ne(n){let t={meta:{}};return void 0!==n[0]&&(t.meta=n[0].meta),n.forEach((n=>{switch(n.type){case e.TransportItemType.LOG:case e.TransportItemType.EVENT:case e.TransportItemType.EXCEPTION:case e.TransportItemType.MEASUREMENT:const i=F[n.type],r=t[i];t=Object.assign(Object.assign({},t),{[i]:void 0===r?[n.payload]:[...r,n.payload]});break;case e.TransportItemType.TRACE:t=Object.assign(Object.assign({},t),{traces:ee(t.traces,n.payload.resourceSpans)})}})),t}const te="Error";let ie;function re(n,t,i,r,o){t.debug("Initializing API");const a=function(n,t,i,r,s){let o;return t.debug("Initializing traces API"),{getOTEL:()=>o,getTraceContext:()=>{const e=null==o?void 0:o.trace.getSpanContext(o.context.active());return e?{trace_id:e.traceId,span_id:e.spanId}:void 0},initOTEL:(e,n)=>{t.debug("Initializing OpenTelemetry"),o={trace:e,context:n}},isOTELInitialized:()=>!!o,pushTraces:n=>{try{const i={type:e.TransportItemType.TRACE,payload:n,meta:r.value};t.debug("Pushing trace\n",i),s.execute(i)}catch(e){t.error("Error pushing trace\n",e)}}}}(0,t,0,r,o);return Object.assign(Object.assign(Object.assign(Object.assign(Object.assign(Object.assign({},a),function(n,t,i,r,o,a){var l;t.debug("Initializing exceptions API");let u=null;ie=null!==(l=i.parseStacktrace)&&void 0!==l?l:ie;const c=e=>{t.debug("Changing stacktrace parser"),ie=null!=e?e:ie};return c(i.parseStacktrace),{changeStacktraceParser:c,getStacktraceParser:()=>ie,pushError:(n,{skipDedupe:l,stackFrames:c,type:d,context:p}={})=>{d=d||n.name||te;const f={meta:r.value,payload:{type:d,value:n.message,timestamp:E(),trace:a.getTraceContext(),context:null!=p?p:{}},type:e.TransportItemType.EXCEPTION};(null==(c=null!=c?c:n.stack?null==ie?void 0:ie(n).frames:void 0)?void 0:c.length)&&(f.payload.stacktrace={frames:c});const g={type:f.payload.type,value:f.payload.value,stackTrace:f.payload.stacktrace,context:f.payload.context};l||!i.dedupe||s(u)||!S(g,u)?(u=g,t.debug("Pushing exception\n",f),o.execute(f)):t.debug("Skipping error push because it is the same as the last one\n",f.payload)}}}(0,t,i,r,o,a)),function(e,n,t,i,r){let s,o,a;n.debug("Initializing meta API");const l=e=>{o&&i.remove(o),o={user:e},i.add(o)},u=e=>{s&&i.remove(s),s={session:e},i.add(s)};return{setUser:l,resetUser:l,setSession:u,resetSession:u,getSession:()=>i.value.session,setView:e=>{a&&i.remove(a),a={view:e},i.add(a)},getView:()=>i.value.view}}(0,t,0,r)),function(n,t,i,r,o,a){t.debug("Initializing logs API");let l=null;return{pushLog:(n,{context:u,level:c,skipDedupe:d}={})=>{try{const p={type:e.TransportItemType.LOG,payload:{message:n.map((e=>{try{return String(e)}catch(e){return""}})).join(" "),level:null!=c?c:x,context:null!=u?u:{},timestamp:E(),trace:a.getTraceContext()},meta:r.value},f={message:p.payload.message,level:p.payload.level,context:p.payload.context};if(!d&&i.dedupe&&!s(l)&&S(f,l))return void t.debug("Skipping log push because it is the same as the last one\n",p.payload);l=f,t.debug("Pushing log\n",p),o.execute(p)}catch(e){t.error("Error pushing log\n",e)}}}}(0,t,i,r,o,a)),function(n,t,i,r,o,a){t.debug("Initializing measurements API");let l=null;return{pushMeasurement:(n,{skipDedupe:u,context:c}={})=>{var d;try{const p={type:e.TransportItemType.MEASUREMENT,payload:Object.assign(Object.assign({},n),{trace:a.getTraceContext(),timestamp:null!==(d=n.timestamp)&&void 0!==d?d:E(),context:null!=c?c:{}}),meta:r.value},f={type:p.payload.type,values:p.payload.values,context:p.payload.context};if(!u&&i.dedupe&&!s(l)&&S(f,l))return void t.debug("Skipping measurement push because it is the same as the last one\n",p.payload);l=f,t.debug("Pushing measurement\n",p),o.execute(p)}catch(e){t.error("Error pushing measurement\n",e)}}}}(0,t,i,r,o,a)),function(n,t,i,r,o,a){let l=null;return{pushEvent:(n,u,c,{skipDedupe:d}={})=>{try{const p={meta:r.value,payload:{name:n,domain:null!=c?c:i.eventDomain,attributes:u,timestamp:E(),trace:a.getTraceContext()},type:e.TransportItemType.EVENT},f={name:p.payload.name,attributes:p.payload.attributes,domain:p.payload.domain};if(!d&&i.dedupe&&!s(l)&&S(f,l))return void t.debug("Skipping event push because it is the same as the last one\n",p.payload);l=f,t.debug("Pushing event\n",p),o.execute(p)}catch(e){t.error("Error pushing event",e)}}}}(0,t,i,r,o,a))}const se="undefined"!=typeof globalThis?globalThis:"undefined"!=typeof global?global:"undefined"!=typeof self?self:void 0;class oe extends Q{constructor(){super(...arguments),this.api={},this.transports={}}}const ae="1.2.7";const le="_faroInternal";function ue(e){e.config.isolate?e.internalLogger.debug("Skipping registering internal Faro instance on global object"):(e.internalLogger.debug("Registering internal Faro instance on global object"),Object.defineProperty(se,le,{configurable:!1,enumerable:!1,writable:!1,value:e}))}function ce(){return le in se}function de(n,t,i,r,s,o,a){return t.debug("Initializing Faro"),e.faro={api:o,config:i,instrumentations:a,internalLogger:t,metas:r,pause:s.pause,transports:s,unpatchedConsole:n,unpause:s.unpause},ue(e.faro),function(e){if(e.config.preventGlobalExposure)e.internalLogger.debug("Skipping registering public Faro instance in the global scope");else{if(e.internalLogger.debug(`Registering public faro reference in the global scope using "${e.config.globalObjectKey}" key`),e.config.globalObjectKey in se)return void e.internalLogger.warn(`Skipping global registration due to key "${e.config.globalObjectKey}" being used already. Please set "globalObjectKey" to something else or set "preventGlobalExposure" to "true"`);Object.defineProperty(se,e.config.globalObjectKey,{configurable:!1,writable:!1,value:e})}}(e.faro),e.faro}function pe(e){const n=H(e),t=Z(n,e);if(ce()&&!e.isolate)return void t.error('Faro is already registered. Either add instrumentations, transports etc. to the global faro instance or use the "isolate" property');t.debug("Initializing");const i=function(e,n,t){let i=[],r=[];const s=()=>i.reduce(((e,n)=>Object.assign(e,u(n)?n():n)),{}),o=()=>{if(r.length){const e=s();r.forEach((n=>n(e)))}};return{add:(...e)=>{n.debug("Adding metas\n",e),i.push(...e),o()},remove:(...e)=>{n.debug("Removing metas\n",e),i=i.filter((n=>!e.includes(n))),o()},addListener:e=>{n.debug("Adding metas listener\n",e),r.push(e)},removeListener:e=>{n.debug("Removing metas listener\n",e),r=r.filter((n=>n!==e))},get value(){return s()}}}(0,t),r=function(e,n,t,i){var r;n.debug("Initializing transports");const s=[];let o=t.paused,a=[];const l=e=>{let n=e;for(const e of a){const t=n.map(e).filter(Boolean);if(0===t.length)return[];n=t}return n},u=e=>{const t=l(e);if(0!==t.length)for(const e of s)n.debug(`Transporting item using ${e.name}\n`,t),e.isBatched()&&e.send(t)},c=e=>{var i;const[r]=l([e]);if(void 0!==r)for(const e of s)n.debug(`Transporting item using ${e.name}\n`,r),e.isBatched()?(null===(i=t.batching)||void 0===i?void 0:i.enabled)||e.send([r]):e.send(r)};let d;return(null===(r=t.batching)||void 0===r?void 0:r.enabled)&&(d=new B(u,{sendTimeout:t.batching.sendTimeout,itemLimit:t.batching.itemLimit,paused:o})),{add:(...r)=>{n.debug("Adding transports"),r.forEach((r=>{n.debug(`Adding "${r.name}" transport`),s.some((e=>e===r))?n.warn(`Transport ${r.name} is already added`):(r.unpatchedConsole=e,r.internalLogger=n,r.config=t,r.metas=i,s.push(r))}))},addBeforeSendHooks:(...e)=>{n.debug("Adding beforeSendHooks\n",a),e.forEach((e=>{e&&a.push(e)}))},addIgnoreErrorsPatterns:(...e)=>{n.debug("Adding ignoreErrorsPatterns\n",e),e.forEach((e=>{e&&a.push($(e))}))},getBeforeSendHooks:()=>[...a],execute:e=>{var n;o||((null===(n=t.batching)||void 0===n?void 0:n.enabled)?(null==d||d.addItem(e),c(e)):c(e))},isPaused:()=>o,pause:()=>{n.debug("Pausing transports"),null==d||d.pause(),o=!0},remove:(...e)=>{n.debug("Removing transports"),e.forEach((e=>{n.debug(`Removing "${e.name}" transport`);const t=s.indexOf(e);-1!==t?s.splice(t,1):n.warn(`Transport "${e.name}" is not added`)}))},removeBeforeSendHooks:(...e)=>{a.filter((n=>!e.includes(n)))},get transports(){return[...s]},unpause:()=>{n.debug("Unpausing transports"),null==d||d.start(),o=!1}}}(n,t,e,i),s=re(0,t,e,i,r),o=function(e,n,t,i,r,s){n.debug("Initializing instrumentations");const o=[];return{add:(...a)=>{n.debug("Adding instrumentations"),a.forEach((a=>{n.debug(`Adding "${a.name}" instrumentation`),o.some((e=>e.name===a.name))?n.warn(`Instrumentation ${a.name} is already added`):(a.unpatchedConsole=e,a.internalLogger=n,a.config=t,a.metas=i,a.transports=r,a.api=s,o.push(a),a.initialize())}))},get instrumentations(){return[...o]},remove:(...e)=>{n.debug("Removing instrumentations"),e.forEach((e=>{var t,i;n.debug(`Removing "${e.name}" instrumentation`);const r=o.reduce(((n,t,i)=>null===n&&t.name===e.name?i:null),null);r?(null===(i=(t=o[r]).destroy)||void 0===i||i.call(t),o.splice(r,1)):n.warn(`Instrumentation "${e.name}" is not added`)}))}}}(n,t,e,i,r,s),a=de(n,t,e,i,r,s,o);return function(e){var n,t;const i={sdk:{version:ae}};let r=e.config.session;(null===(n=e.config.sessionTracking)||void 0===n?void 0:n.enabled)&&(r=e.config.sessionTracking.session),r&&e.api.setSession(r),e.config.app&&(i.app=e.config.app),e.config.user&&(i.user=e.config.user),e.config.view&&(i.view=e.config.view),e.metas.add(i,...null!==(t=e.config.metas)&&void 0!==t?t:[])}(a),function(e){e.transports.add(...e.config.transports),e.transports.addBeforeSendHooks(e.config.beforeSend),e.transports.addIgnoreErrorsPatterns(e.config.ignoreErrors)}(a),function(e){e.instrumentations.add(...e.config.instrumentations)}(a),a}e.faro={};const fe="faro",ge={enabled:!0,sendTimeout:250,itemLimit:50},be="session_start";var ve={exports:{}};!function(e,n){!function(t,i){var r="function",s="undefined",o="object",a="string",l="major",u="model",c="name",d="type",p="vendor",f="version",g="architecture",b="console",v="mobile",m="tablet",h="smarttv",w="wearable",y="embedded",S="Amazon",E="Apple",T="ASUS",x="BlackBerry",k="Browser",I="Chrome",L="Firefox",O="Google",A="Huawei",C="LG",N="Microsoft",j="Motorola",R="Opera",D="Samsung",U="Sharp",M="Sony",P="Xiaomi",_="Zebra",B="Facebook",z="Chromium OS",F="Mac OS",$=function(e){for(var n={},t=0;t<e.length;t++)n[e[t].toUpperCase()]=e[t];return n},V=function(e,n){return typeof e===a&&-1!==q(n).indexOf(q(e))},q=function(e){return e.toLowerCase()},G=function(e,n){if(typeof e===a)return e=e.replace(/^\s\s*/,""),typeof n===s?e:e.substring(0,350)},W=function(e,n){for(var t,s,a,l,u,c,d=0;d<n.length&&!u;){var p=n[d],f=n[d+1];for(t=s=0;t<p.length&&!u&&p[t];)if(u=p[t++].exec(e))for(a=0;a<f.length;a++)c=u[++s],typeof(l=f[a])===o&&l.length>0?2===l.length?typeof l[1]==r?this[l[0]]=l[1].call(this,c):this[l[0]]=l[1]:3===l.length?typeof l[1]!==r||l[1].exec&&l[1].test?this[l[0]]=c?c.replace(l[1],l[2]):i:this[l[0]]=c?l[1].call(this,c,l[2]):i:4===l.length&&(this[l[0]]=c?l[3].call(this,c.replace(l[1],l[2])):i):this[l]=c||i;d+=2}},K=function(e,n){for(var t in n)if(typeof n[t]===o&&n[t].length>0){for(var r=0;r<n[t].length;r++)if(V(n[t][r],e))return"?"===t?i:t}else if(V(n[t],e))return"?"===t?i:t;return e},H={ME:"4.90","NT 3.11":"NT3.51","NT 4.0":"NT4.0",2e3:"NT 5.0",XP:["NT 5.1","NT 5.2"],Vista:"NT 6.0",7:"NT 6.1",8:"NT 6.2",8.1:"NT 6.3",10:["NT 6.4","NT 10.0"],RT:"ARM"},J={browser:[[/\b(?:crmo|crios)\/([\w\.]+)/i],[f,[c,"Chrome"]],[/edg(?:e|ios|a)?\/([\w\.]+)/i],[f,[c,"Edge"]],[/(opera mini)\/([-\w\.]+)/i,/(opera [mobiletab]{3,6})\b.+version\/([-\w\.]+)/i,/(opera)(?:.+version\/|[\/ ]+)([\w\.]+)/i],[c,f],[/opios[\/ ]+([\w\.]+)/i],[f,[c,R+" Mini"]],[/\bopr\/([\w\.]+)/i],[f,[c,R]],[/(kindle)\/([\w\.]+)/i,/(lunascape|maxthon|netfront|jasmine|blazer)[\/ ]?([\w\.]*)/i,/(avant |iemobile|slim)(?:browser)?[\/ ]?([\w\.]*)/i,/(ba?idubrowser)[\/ ]?([\w\.]+)/i,/(?:ms|\()(ie) ([\w\.]+)/i,/(flock|rockmelt|midori|epiphany|silk|skyfire|bolt|iron|vivaldi|iridium|phantomjs|bowser|quark|qupzilla|falkon|rekonq|puffin|brave|whale(?!.+naver)|qqbrowserlite|qq|duckduckgo)\/([-\w\.]+)/i,/(heytap|ovi)browser\/([\d\.]+)/i,/(weibo)__([\d\.]+)/i],[c,f],[/(?:\buc? ?browser|(?:juc.+)ucweb)[\/ ]?([\w\.]+)/i],[f,[c,"UC"+k]],[/microm.+\bqbcore\/([\w\.]+)/i,/\bqbcore\/([\w\.]+).+microm/i],[f,[c,"WeChat(Win) Desktop"]],[/micromessenger\/([\w\.]+)/i],[f,[c,"WeChat"]],[/konqueror\/([\w\.]+)/i],[f,[c,"Konqueror"]],[/trident.+rv[: ]([\w\.]{1,9})\b.+like gecko/i],[f,[c,"IE"]],[/ya(?:search)?browser\/([\w\.]+)/i],[f,[c,"Yandex"]],[/(avast|avg)\/([\w\.]+)/i],[[c,/(.+)/,"$1 Secure "+k],f],[/\bfocus\/([\w\.]+)/i],[f,[c,L+" Focus"]],[/\bopt\/([\w\.]+)/i],[f,[c,R+" Touch"]],[/coc_coc\w+\/([\w\.]+)/i],[f,[c,"Coc Coc"]],[/dolfin\/([\w\.]+)/i],[f,[c,"Dolphin"]],[/coast\/([\w\.]+)/i],[f,[c,R+" Coast"]],[/miuibrowser\/([\w\.]+)/i],[f,[c,"MIUI "+k]],[/fxios\/([-\w\.]+)/i],[f,[c,L]],[/\bqihu|(qi?ho?o?|360)browser/i],[[c,"360 "+k]],[/(oculus|samsung|sailfish|huawei)browser\/([\w\.]+)/i],[[c,/(.+)/,"$1 "+k],f],[/(comodo_dragon)\/([\w\.]+)/i],[[c,/_/g," "],f],[/(electron)\/([\w\.]+) safari/i,/(tesla)(?: qtcarbrowser|\/(20\d\d\.[-\w\.]+))/i,/m?(qqbrowser|baiduboxapp|2345Explorer)[\/ ]?([\w\.]+)/i],[c,f],[/(metasr)[\/ ]?([\w\.]+)/i,/(lbbrowser)/i,/\[(linkedin)app\]/i],[c],[/((?:fban\/fbios|fb_iab\/fb4a)(?!.+fbav)|;fbav\/([\w\.]+);)/i],[[c,B],f],[/(kakao(?:talk|story))[\/ ]([\w\.]+)/i,/(naver)\(.*?(\d+\.[\w\.]+).*\)/i,/safari (line)\/([\w\.]+)/i,/\b(line)\/([\w\.]+)\/iab/i,/(chromium|instagram|snapchat)[\/ ]([-\w\.]+)/i],[c,f],[/\bgsa\/([\w\.]+) .*safari\//i],[f,[c,"GSA"]],[/musical_ly(?:.+app_?version\/|_)([\w\.]+)/i],[f,[c,"TikTok"]],[/headlesschrome(?:\/([\w\.]+)| )/i],[f,[c,I+" Headless"]],[/ wv\).+(chrome)\/([\w\.]+)/i],[[c,I+" WebView"],f],[/droid.+ version\/([\w\.]+)\b.+(?:mobile safari|safari)/i],[f,[c,"Android "+k]],[/(chrome|omniweb|arora|[tizenoka]{5} ?browser)\/v?([\w\.]+)/i],[c,f],[/version\/([\w\.\,]+) .*mobile\/\w+ (safari)/i],[f,[c,"Mobile Safari"]],[/version\/([\w(\.|\,)]+) .*(mobile ?safari|safari)/i],[f,c],[/webkit.+?(mobile ?safari|safari)(\/[\w\.]+)/i],[c,[f,K,{"1.0":"/8",1.2:"/1",1.3:"/3","2.0":"/412","2.0.2":"/416","2.0.3":"/417","2.0.4":"/419","?":"/"}]],[/(webkit|khtml)\/([\w\.]+)/i],[c,f],[/(navigator|netscape\d?)\/([-\w\.]+)/i],[[c,"Netscape"],f],[/mobile vr; rv:([\w\.]+)\).+firefox/i],[f,[c,L+" Reality"]],[/ekiohf.+(flow)\/([\w\.]+)/i,/(swiftfox)/i,/(icedragon|iceweasel|camino|chimera|fennec|maemo browser|minimo|conkeror|klar)[\/ ]?([\w\.\+]+)/i,/(seamonkey|k-meleon|icecat|iceape|firebird|phoenix|palemoon|basilisk|waterfox)\/([-\w\.]+)$/i,/(firefox)\/([\w\.]+)/i,/(mozilla)\/([\w\.]+) .+rv\:.+gecko\/\d+/i,/(polaris|lynx|dillo|icab|doris|amaya|w3m|netsurf|sleipnir|obigo|mosaic|(?:go|ice|up)[\. ]?browser)[-\/ ]?v?([\w\.]+)/i,/(links) \(([\w\.]+)/i,/panasonic;(viera)/i],[c,f],[/(cobalt)\/([\w\.]+)/i],[c,[f,/master.|lts./,""]]],cpu:[[/(?:(amd|x(?:(?:86|64)[-_])?|wow|win)64)[;\)]/i],[[g,"amd64"]],[/(ia32(?=;))/i],[[g,q]],[/((?:i[346]|x)86)[;\)]/i],[[g,"ia32"]],[/\b(aarch64|arm(v?8e?l?|_?64))\b/i],[[g,"arm64"]],[/\b(arm(?:v[67])?ht?n?[fl]p?)\b/i],[[g,"armhf"]],[/windows (ce|mobile); ppc;/i],[[g,"arm"]],[/((?:ppc|powerpc)(?:64)?)(?: mac|;|\))/i],[[g,/ower/,"",q]],[/(sun4\w)[;\)]/i],[[g,"sparc"]],[/((?:avr32|ia64(?=;))|68k(?=\))|\barm(?=v(?:[1-7]|[5-7]1)l?|;|eabi)|(?=atmel )avr|(?:irix|mips|sparc)(?:64)?\b|pa-risc)/i],[[g,q]]],device:[[/\b(sch-i[89]0\d|shw-m380s|sm-[ptx]\w{2,4}|gt-[pn]\d{2,4}|sgh-t8[56]9|nexus 10)/i],[u,[p,D],[d,m]],[/\b((?:s[cgp]h|gt|sm)-\w+|sc[g-]?[\d]+a?|galaxy nexus)/i,/samsung[- ]([-\w]+)/i,/sec-(sgh\w+)/i],[u,[p,D],[d,v]],[/(?:\/|\()(ip(?:hone|od)[\w, ]*)(?:\/|;)/i],[u,[p,E],[d,v]],[/\((ipad);[-\w\),; ]+apple/i,/applecoremedia\/[\w\.]+ \((ipad)/i,/\b(ipad)\d\d?,\d\d?[;\]].+ios/i],[u,[p,E],[d,m]],[/(macintosh);/i],[u,[p,E]],[/\b(sh-?[altvz]?\d\d[a-ekm]?)/i],[u,[p,U],[d,v]],[/\b((?:ag[rs][23]?|bah2?|sht?|btv)-a?[lw]\d{2})\b(?!.+d\/s)/i],[u,[p,A],[d,m]],[/(?:huawei|honor)([-\w ]+)[;\)]/i,/\b(nexus 6p|\w{2,4}e?-[atu]?[ln][\dx][012359c][adn]?)\b(?!.+d\/s)/i],[u,[p,A],[d,v]],[/\b(poco[\w ]+|m2\d{3}j\d\d[a-z]{2})(?: bui|\))/i,/\b; (\w+) build\/hm\1/i,/\b(hm[-_ ]?note?[_ ]?(?:\d\w)?) bui/i,/\b(redmi[\-_ ]?(?:note|k)?[\w_ ]+)(?: bui|\))/i,/\b(mi[-_ ]?(?:a\d|one|one[_ ]plus|note lte|max|cc)?[_ ]?(?:\d?\w?)[_ ]?(?:plus|se|lite)?)(?: bui|\))/i],[[u,/_/g," "],[p,P],[d,v]],[/\b(mi[-_ ]?(?:pad)(?:[\w_ ]+))(?: bui|\))/i],[[u,/_/g," "],[p,P],[d,m]],[/; (\w+) bui.+ oppo/i,/\b(cph[12]\d{3}|p(?:af|c[al]|d\w|e[ar])[mt]\d0|x9007|a101op)\b/i],[u,[p,"OPPO"],[d,v]],[/vivo (\w+)(?: bui|\))/i,/\b(v[12]\d{3}\w?[at])(?: bui|;)/i],[u,[p,"Vivo"],[d,v]],[/\b(rmx[12]\d{3})(?: bui|;|\))/i],[u,[p,"Realme"],[d,v]],[/\b(milestone|droid(?:[2-4x]| (?:bionic|x2|pro|razr))?:?( 4g)?)\b[\w ]+build\//i,/\bmot(?:orola)?[- ](\w*)/i,/((?:moto[\w\(\) ]+|xt\d{3,4}|nexus 6)(?= bui|\)))/i],[u,[p,j],[d,v]],[/\b(mz60\d|xoom[2 ]{0,2}) build\//i],[u,[p,j],[d,m]],[/((?=lg)?[vl]k\-?\d{3}) bui| 3\.[-\w; ]{10}lg?-([06cv9]{3,4})/i],[u,[p,C],[d,m]],[/(lm(?:-?f100[nv]?|-[\w\.]+)(?= bui|\))|nexus [45])/i,/\blg[-e;\/ ]+((?!browser|netcast|android tv)\w+)/i,/\blg-?([\d\w]+) bui/i],[u,[p,C],[d,v]],[/(ideatab[-\w ]+)/i,/lenovo ?(s[56]000[-\w]+|tab(?:[\w ]+)|yt[-\d\w]{6}|tb[-\d\w]{6})/i],[u,[p,"Lenovo"],[d,m]],[/(?:maemo|nokia).*(n900|lumia \d+)/i,/nokia[-_ ]?([-\w\.]*)/i],[[u,/_/g," "],[p,"Nokia"],[d,v]],[/(pixel c)\b/i],[u,[p,O],[d,m]],[/droid.+; (pixel[\daxl ]{0,6})(?: bui|\))/i],[u,[p,O],[d,v]],[/droid.+ (a?\d[0-2]{2}so|[c-g]\d{4}|so[-gl]\w+|xq-a\w[4-7][12])(?= bui|\).+chrome\/(?![1-6]{0,1}\d\.))/i],[u,[p,M],[d,v]],[/sony tablet [ps]/i,/\b(?:sony)?sgp\w+(?: bui|\))/i],[[u,"Xperia Tablet"],[p,M],[d,m]],[/ (kb2005|in20[12]5|be20[12][59])\b/i,/(?:one)?(?:plus)? (a\d0\d\d)(?: b|\))/i],[u,[p,"OnePlus"],[d,v]],[/(alexa)webm/i,/(kf[a-z]{2}wi|aeo[c-r]{2})( bui|\))/i,/(kf[a-z]+)( bui|\)).+silk\//i],[u,[p,S],[d,m]],[/((?:sd|kf)[0349hijorstuw]+)( bui|\)).+silk\//i],[[u,/(.+)/g,"Fire Phone $1"],[p,S],[d,v]],[/(playbook);[-\w\),; ]+(rim)/i],[u,p,[d,m]],[/\b((?:bb[a-f]|st[hv])100-\d)/i,/\(bb10; (\w+)/i],[u,[p,x],[d,v]],[/(?:\b|asus_)(transfo[prime ]{4,10} \w+|eeepc|slider \w+|nexus 7|padfone|p00[cj])/i],[u,[p,T],[d,m]],[/ (z[bes]6[027][012][km][ls]|zenfone \d\w?)\b/i],[u,[p,T],[d,v]],[/(nexus 9)/i],[u,[p,"HTC"],[d,m]],[/(htc)[-;_ ]{1,2}([\w ]+(?=\)| bui)|\w+)/i,/(zte)[- ]([\w ]+?)(?: bui|\/|\))/i,/(alcatel|geeksphone|nexian|panasonic(?!(?:;|\.))|sony(?!-bra))[-_ ]?([-\w]*)/i],[p,[u,/_/g," "],[d,v]],[/droid.+; ([ab][1-7]-?[0178a]\d\d?)/i],[u,[p,"Acer"],[d,m]],[/droid.+; (m[1-5] note) bui/i,/\bmz-([-\w]{2,})/i],[u,[p,"Meizu"],[d,v]],[/(blackberry|benq|palm(?=\-)|sonyericsson|acer|asus|dell|meizu|motorola|polytron|infinix|tecno)[-_ ]?([-\w]*)/i,/(hp) ([\w ]+\w)/i,/(asus)-?(\w+)/i,/(microsoft); (lumia[\w ]+)/i,/(lenovo)[-_ ]?([-\w]+)/i,/(jolla)/i,/(oppo) ?([\w ]+) bui/i],[p,u,[d,v]],[/(kobo)\s(ereader|touch)/i,/(archos) (gamepad2?)/i,/(hp).+(touchpad(?!.+tablet)|tablet)/i,/(kindle)\/([\w\.]+)/i,/(nook)[\w ]+build\/(\w+)/i,/(dell) (strea[kpr\d ]*[\dko])/i,/(le[- ]+pan)[- ]+(\w{1,9}) bui/i,/(trinity)[- ]*(t\d{3}) bui/i,/(gigaset)[- ]+(q\w{1,9}) bui/i,/(vodafone) ([\w ]+)(?:\)| bui)/i],[p,u,[d,m]],[/(surface duo)/i],[u,[p,N],[d,m]],[/droid [\d\.]+; (fp\du?)(?: b|\))/i],[u,[p,"Fairphone"],[d,v]],[/(u304aa)/i],[u,[p,"AT&T"],[d,v]],[/\bsie-(\w*)/i],[u,[p,"Siemens"],[d,v]],[/\b(rct\w+) b/i],[u,[p,"RCA"],[d,m]],[/\b(venue[\d ]{2,7}) b/i],[u,[p,"Dell"],[d,m]],[/\b(q(?:mv|ta)\w+) b/i],[u,[p,"Verizon"],[d,m]],[/\b(?:barnes[& ]+noble |bn[rt])([\w\+ ]*) b/i],[u,[p,"Barnes & Noble"],[d,m]],[/\b(tm\d{3}\w+) b/i],[u,[p,"NuVision"],[d,m]],[/\b(k88) b/i],[u,[p,"ZTE"],[d,m]],[/\b(nx\d{3}j) b/i],[u,[p,"ZTE"],[d,v]],[/\b(gen\d{3}) b.+49h/i],[u,[p,"Swiss"],[d,v]],[/\b(zur\d{3}) b/i],[u,[p,"Swiss"],[d,m]],[/\b((zeki)?tb.*\b) b/i],[u,[p,"Zeki"],[d,m]],[/\b([yr]\d{2}) b/i,/\b(dragon[- ]+touch |dt)(\w{5}) b/i],[[p,"Dragon Touch"],u,[d,m]],[/\b(ns-?\w{0,9}) b/i],[u,[p,"Insignia"],[d,m]],[/\b((nxa|next)-?\w{0,9}) b/i],[u,[p,"NextBook"],[d,m]],[/\b(xtreme\_)?(v(1[045]|2[015]|[3469]0|7[05])) b/i],[[p,"Voice"],u,[d,v]],[/\b(lvtel\-)?(v1[12]) b/i],[[p,"LvTel"],u,[d,v]],[/\b(ph-1) /i],[u,[p,"Essential"],[d,v]],[/\b(v(100md|700na|7011|917g).*\b) b/i],[u,[p,"Envizen"],[d,m]],[/\b(trio[-\w\. ]+) b/i],[u,[p,"MachSpeed"],[d,m]],[/\btu_(1491) b/i],[u,[p,"Rotor"],[d,m]],[/(shield[\w ]+) b/i],[u,[p,"Nvidia"],[d,m]],[/(sprint) (\w+)/i],[p,u,[d,v]],[/(kin\.[onetw]{3})/i],[[u,/\./g," "],[p,N],[d,v]],[/droid.+; (cc6666?|et5[16]|mc[239][23]x?|vc8[03]x?)\)/i],[u,[p,_],[d,m]],[/droid.+; (ec30|ps20|tc[2-8]\d[kx])\)/i],[u,[p,_],[d,v]],[/smart-tv.+(samsung)/i],[p,[d,h]],[/hbbtv.+maple;(\d+)/i],[[u,/^/,"SmartTV"],[p,D],[d,h]],[/(nux; netcast.+smarttv|lg (netcast\.tv-201\d|android tv))/i],[[p,C],[d,h]],[/(apple) ?tv/i],[p,[u,E+" TV"],[d,h]],[/crkey/i],[[u,I+"cast"],[p,O],[d,h]],[/droid.+aft(\w+)( bui|\))/i],[u,[p,S],[d,h]],[/\(dtv[\);].+(aquos)/i,/(aquos-tv[\w ]+)\)/i],[u,[p,U],[d,h]],[/(bravia[\w ]+)( bui|\))/i],[u,[p,M],[d,h]],[/(mitv-\w{5}) bui/i],[u,[p,P],[d,h]],[/Hbbtv.*(technisat) (.*);/i],[p,u,[d,h]],[/\b(roku)[\dx]*[\)\/]((?:dvp-)?[\d\.]*)/i,/hbbtv\/\d+\.\d+\.\d+ +\([\w\+ ]*; *([\w\d][^;]*);([^;]*)/i],[[p,G],[u,G],[d,h]],[/\b(android tv|smart[- ]?tv|opera tv|tv; rv:)\b/i],[[d,h]],[/(ouya)/i,/(nintendo) ([wids3utch]+)/i],[p,u,[d,b]],[/droid.+; (shield) bui/i],[u,[p,"Nvidia"],[d,b]],[/(playstation [345portablevi]+)/i],[u,[p,M],[d,b]],[/\b(xbox(?: one)?(?!; xbox))[\); ]/i],[u,[p,N],[d,b]],[/((pebble))app/i],[p,u,[d,w]],[/(watch)(?: ?os[,\/]|\d,\d\/)[\d\.]+/i],[u,[p,E],[d,w]],[/droid.+; (glass) \d/i],[u,[p,O],[d,w]],[/droid.+; (wt63?0{2,3})\)/i],[u,[p,_],[d,w]],[/(quest( 2| pro)?)/i],[u,[p,B],[d,w]],[/(tesla)(?: qtcarbrowser|\/[-\w\.]+)/i],[p,[d,y]],[/(aeobc)\b/i],[u,[p,S],[d,y]],[/droid .+?; ([^;]+?)(?: bui|\) applew).+? mobile safari/i],[u,[d,v]],[/droid .+?; ([^;]+?)(?: bui|\) applew).+?(?! mobile) safari/i],[u,[d,m]],[/\b((tablet|tab)[;\/]|focus\/\d(?!.+mobile))/i],[[d,m]],[/(phone|mobile(?:[;\/]| [ \w\/\.]*safari)|pda(?=.+windows ce))/i],[[d,v]],[/(android[-\w\. ]{0,9});.+buil/i],[u,[p,"Generic"]]],engine:[[/windows.+ edge\/([\w\.]+)/i],[f,[c,"EdgeHTML"]],[/webkit\/537\.36.+chrome\/(?!27)([\w\.]+)/i],[f,[c,"Blink"]],[/(presto)\/([\w\.]+)/i,/(webkit|trident|netfront|netsurf|amaya|lynx|w3m|goanna)\/([\w\.]+)/i,/ekioh(flow)\/([\w\.]+)/i,/(khtml|tasman|links)[\/ ]\(?([\w\.]+)/i,/(icab)[\/ ]([23]\.[\d\.]+)/i,/\b(libweb)/i],[c,f],[/rv\:([\w\.]{1,9})\b.+(gecko)/i],[f,c]],os:[[/microsoft (windows) (vista|xp)/i],[c,f],[/(windows) nt 6\.2; (arm)/i,/(windows (?:phone(?: os)?|mobile))[\/ ]?([\d\.\w ]*)/i,/(windows)[\/ ]?([ntce\d\. ]+\w)(?!.+xbox)/i],[c,[f,K,H]],[/(win(?=3|9|n)|win 9x )([nt\d\.]+)/i],[[c,"Windows"],[f,K,H]],[/ip[honead]{2,4}\b(?:.*os ([\w]+) like mac|; opera)/i,/(?:ios;fbsv\/|iphone.+ios[\/ ])([\d\.]+)/i,/cfnetwork\/.+darwin/i],[[f,/_/g,"."],[c,"iOS"]],[/(mac os x) ?([\w\. ]*)/i,/(macintosh|mac_powerpc\b)(?!.+haiku)/i],[[c,F],[f,/_/g,"."]],[/droid ([\w\.]+)\b.+(android[- ]x86|harmonyos)/i],[f,c],[/(android|webos|qnx|bada|rim tablet os|maemo|meego|sailfish)[-\/ ]?([\w\.]*)/i,/(blackberry)\w*\/([\w\.]*)/i,/(tizen|kaios)[\/ ]([\w\.]+)/i,/\((series40);/i],[c,f],[/\(bb(10);/i],[f,[c,x]],[/(?:symbian ?os|symbos|s60(?=;)|series60)[-\/ ]?([\w\.]*)/i],[f,[c,"Symbian"]],[/mozilla\/[\d\.]+ \((?:mobile|tablet|tv|mobile; [\w ]+); rv:.+ gecko\/([\w\.]+)/i],[f,[c,L+" OS"]],[/web0s;.+rt(tv)/i,/\b(?:hp)?wos(?:browser)?\/([\w\.]+)/i],[f,[c,"webOS"]],[/watch(?: ?os[,\/]|\d,\d\/)([\d\.]+)/i],[f,[c,"watchOS"]],[/crkey\/([\d\.]+)/i],[f,[c,I+"cast"]],[/(cros) [\w]+(?:\)| ([\w\.]+)\b)/i],[[c,z],f],[/panasonic;(viera)/i,/(netrange)mmh/i,/(nettv)\/(\d+\.[\w\.]+)/i,/(nintendo|playstation) ([wids345portablevuch]+)/i,/(xbox); +xbox ([^\);]+)/i,/\b(joli|palm)\b ?(?:os)?\/?([\w\.]*)/i,/(mint)[\/\(\) ]?(\w*)/i,/(mageia|vectorlinux)[; ]/i,/([kxln]?ubuntu|debian|suse|opensuse|gentoo|arch(?= linux)|slackware|fedora|mandriva|centos|pclinuxos|red ?hat|zenwalk|linpus|raspbian|plan 9|minix|risc os|contiki|deepin|manjaro|elementary os|sabayon|linspire)(?: gnu\/linux)?(?: enterprise)?(?:[- ]linux)?(?:-gnu)?[-\/ ]?(?!chrom|package)([-\w\.]*)/i,/(hurd|linux) ?([\w\.]*)/i,/(gnu) ?([\w\.]*)/i,/\b([-frentopcghs]{0,5}bsd|dragonfly)[\/ ]?(?!amd|[ix346]{1,2}86)([\w\.]*)/i,/(haiku) (\w+)/i],[c,f],[/(sunos) ?([\w\.\d]*)/i],[[c,"Solaris"],f],[/((?:open)?solaris)[-\/ ]?([\w\.]*)/i,/(aix) ((\d)(?=\.|\)| )[\w\.])*/i,/\b(beos|os\/2|amigaos|morphos|openvms|fuchsia|hp-ux|serenityos)/i,/(unix) ?([\w\.]*)/i],[c,f]]},X=function(e,n){if(typeof e===o&&(n=e,e=i),!(this instanceof X))return new X(e,n).getResult();var b=typeof t!==s&&t.navigator?t.navigator:i,h=e||(b&&b.userAgent?b.userAgent:""),w=b&&b.userAgentData?b.userAgentData:i,y=n?function(e,n){var t={};for(var i in e)n[i]&&n[i].length%2==0?t[i]=n[i].concat(e[i]):t[i]=e[i];return t}(J,n):J,S=b&&b.userAgent==h;return this.getBrowser=function(){var e,n={};return n[c]=i,n[f]=i,W.call(n,h,y.browser),n[l]=typeof(e=n[f])===a?e.replace(/[^\d\.]/g,"").split(".")[0]:i,S&&b&&b.brave&&typeof b.brave.isBrave==r&&(n[c]="Brave"),n},this.getCPU=function(){var e={};return e[g]=i,W.call(e,h,y.cpu),e},this.getDevice=function(){var e={};return e[p]=i,e[u]=i,e[d]=i,W.call(e,h,y.device),S&&!e[d]&&w&&w.mobile&&(e[d]=v),S&&"Macintosh"==e[u]&&b&&typeof b.standalone!==s&&b.maxTouchPoints&&b.maxTouchPoints>2&&(e[u]="iPad",e[d]=m),e},this.getEngine=function(){var e={};return e[c]=i,e[f]=i,W.call(e,h,y.engine),e},this.getOS=function(){var e={};return e[c]=i,e[f]=i,W.call(e,h,y.os),S&&!e[c]&&w&&"Unknown"!=w.platform&&(e[c]=w.platform.replace(/chrome os/i,z).replace(/macos/i,F)),e},this.getResult=function(){return{ua:this.getUA(),browser:this.getBrowser(),engine:this.getEngine(),os:this.getOS(),device:this.getDevice(),cpu:this.getCPU()}},this.getUA=function(){return h},this.setUA=function(e){return h=typeof e===a&&e.length>350?G(e,350):e,this},this.setUA(h),this};X.VERSION="1.0.36",X.BROWSER=$([c,f,l]),X.CPU=$([g]),X.DEVICE=$([u,p,d,b,v,h,m,w,y]),X.ENGINE=X.OS=$([c,f]),e.exports&&(n=e.exports=X),n.UAParser=X;var Z=typeof t!==s&&(t.jQuery||t.Zepto);if(Z&&!Z.ua){var Q=new X;Z.ua=Q.getResult(),Z.ua.get=function(){return Q.getUA()},Z.ua.set=function(e){Q.setUA(e);var n=Q.getResult();for(var t in n)Z.ua[t]=n[t]}}}("object"==typeof window?window:N)}(ve,ve.exports);var me=ve.exports;const he=()=>{const e=new me.UAParser,{name:n,version:t}=e.getBrowser(),{name:i,version:r}=e.getOS(),s=e.getUA(),o=navigator.language,a=navigator.userAgent.includes("Mobi"),l=function(){if(!n||!t)return;if("userAgentData"in navigator)return navigator.userAgentData.brands;return}(),u="unknown";return{browser:{name:null!=n?n:u,version:null!=t?t:u,os:`${null!=i?i:u} ${null!=r?r:u}`,userAgent:null!=s?s:u,language:null!=o?o:u,mobile:a,brands:null!=l?l:u}}},we=()=>({page:{url:location.href}}),ye=[he,we];function Se(e){return{id:A(),attributes:e}}const Ee={name:"default"},Te="sessionStorage",xe="localStorage";function ke(n){var t;try{let e;e=window[n];const t="__faro_storage_test__";return e.setItem(t,t),e.removeItem(t),!0}catch(i){return null===(t=e.faro.internalLogger)||void 0===t||t.info(`Web storage of type ${n} is not available. Reason: ${i}`),!1}}function Ie(e,n){return Ne(n)?window[n].getItem(e):null}function Le(e,n,t){if(Ne(t))try{window[t].setItem(e,n)}catch(e){}}function Oe(e,n){Ne(n)&&window[n].removeItem(e)}const Ae=ke(xe),Ce=ke(Te);function Ne(e){return e===xe?Ae:e===Te&&Ce}function je(e,n){let t,i=!1;const r=()=>{null!=t?(e(...t),t=null,setTimeout(r,n)):i=!1};return(...s)=>{i?t=s:(e(...s),i=!0,setTimeout(r,n))}}const Re="__FARO_SESSION__",De=144e5,Ue={enabled:!1,persistent:!1,maxSessionPersistenceTime:147e5};function Me(e){const n=C();return{sessionId:null!=e?e:A(),lastActivity:n,started:n}}function Pe(e){if(null==e)return!1;const n=C();if(!(n-e.started<De))return!1;return n-e.lastActivity<9e5}function _e({fetchUserSession:n,storeUserSession:t}){return function(){var i,r,s,o;if(!n||!t)return;const a=n();if(Pe(a))t(Object.assign(Object.assign({},a),{lastActivity:C()}));else{let n=Be(Me(),a);t(n),null===(i=e.faro.api)||void 0===i||i.setSession(n.sessionMeta),null===(s=null===(r=e.faro.config.sessionTracking)||void 0===r?void 0:r.onSessionChange)||void 0===s||s.call(r,null!==(o=null==a?void 0:a.sessionMeta)&&void 0!==o?o:null,n.sessionMeta)}}}function Be(n,t){var i;const r=Object.assign(Object.assign({},n),{sessionMeta:{id:n.sessionId}}),s=null===(i=e.faro.metas.value.session)||void 0===i?void 0:i.attributes;return(s||null!=t)&&(r.sessionMeta.attributes=Object.assign(Object.assign({},null!=s?s:{}),null!=t?{previousSession:t.sessionId}:{})),r}class ze{constructor(e){this.initialSessionId=e,this.updateSession=je((()=>this.updateUserSession()),1e3),this.updateUserSession=_e({fetchUserSession:ze.fetchUserSession,storeUserSession:ze.storeUserSession}),this.init()}static removeUserSession(){Oe(Re,ze.storageTypeLocal)}static storeUserSession(e){Le(Re,JSON.stringify(e),ze.storageTypeLocal)}static fetchUserSession(){const e=Ie(Re,ze.storageTypeLocal);return e?JSON.parse(e):null}init(){ze.storeUserSession(Me(this.initialSessionId)),document.addEventListener("visibilitychange",(()=>{"visible"===document.visibilityState&&this.updateSession()})),window.addEventListener("storage",(n=>{var t,i,r;if(n.key!==Re)return;const s=JSON.parse(null!==(t=n.newValue)&&void 0!==t?t:""),o=JSON.parse(null!==(i=n.oldValue)&&void 0!==i?i:"");s.sessionId!==o.sessionId&&(null===(r=e.faro.api)||void 0===r||r.setSession(s.sessionMeta))})),e.faro.metas.addListener((function(n){const t=n.session,i=ze.fetchUserSession();if(t&&t.id!==(null==i?void 0:i.sessionId)){const n=Be(Me(t.id),i);ze.storeUserSession(n),e.faro.api.setSession(n.sessionMeta)}}))}}ze.storageTypeLocal=xe;class Fe{constructor(e){this.initialSessionId=e,this.updateSession=je((()=>this.updateUserSession()),1e3),this.updateUserSession=_e({fetchUserSession:Fe.fetchUserSession,storeUserSession:Fe.storeUserSession}),this.init()}static removeUserSession(){Oe(Re,Fe.storageTypeSession)}static storeUserSession(e){Le(Re,JSON.stringify(e),Fe.storageTypeSession)}static fetchUserSession(){const e=Ie(Re,Fe.storageTypeSession);return e?JSON.parse(e):null}init(){Fe.storeUserSession(Me(this.initialSessionId)),document.addEventListener("visibilitychange",(()=>{"visible"===document.visibilityState&&this.updateSession()})),e.faro.metas.addListener((function(n){const t=n.session,i=Fe.fetchUserSession();if(t&&t.id!==(null==i?void 0:i.sessionId)){const n=Be(Me(t.id),i);Fe.storeUserSession(n),e.faro.api.setSession(n.sessionMeta)}}))}}Fe.storageTypeSession=Te;class $e extends oe{constructor(){super(...arguments),this.name="@grafana/faro-web-sdk:instrumentation-session",this.version=ae}sendSessionStartEvent(e){var n,t;const i=e.session;if(i&&i.id!==(null===(n=this.notifiedSession)||void 0===n?void 0:n.id)){if(this.notifiedSession&&this.notifiedSession.id===(null===(t=i.attributes)||void 0===t?void 0:t.previousSession))return this.api.pushEvent("session_extend",{},void 0,{skipDedupe:!0}),void(this.notifiedSession=i);this.notifiedSession=i,this.api.pushEvent(be,{},void 0,{skipDedupe:!0})}}getSessionManagerInstanceByConfiguredStrategy(e){var n;return(null===(n=this.config.sessionTracking)||void 0===n?void 0:n.persistent)&&Ae?new ze(e):Ce?new Fe(e):null}createInitialSessionMeta(e){var n,t,i;let r=(e.persistent?ze:Fe).fetchUserSession();if(e.persistent&&e.maxSessionPersistenceTime&&r){const n=C();r.lastActivity<n-e.maxSessionPersistenceTime&&(ze.removeUserSession(),r=null)}let s=null===(n=e.session)||void 0===n?void 0:n.id,o=null===(t=e.session)||void 0===t?void 0:t.attributes;Pe(r)?(s=null==r?void 0:r.sessionId,o=null===(i=null==r?void 0:r.sessionMeta)||void 0===i?void 0:i.attributes,this.api.pushEvent("session_resume",{},void 0,{skipDedupe:!0})):(s=null!=s?s:Se().id,this.api.pushEvent(be,{},void 0,{skipDedupe:!0}));const a={id:s};return o&&(a.attributes=o),this.notifiedSession=a,a}initialize(){var e,n;this.logDebug("init session instrumentation");const t=this.config.sessionTracking;if(null==t?void 0:t.enabled){const i=this.createInitialSessionMeta(t);this.api.setSession(i);const r=this.getSessionManagerInstanceByConfiguredStrategy(null===(e=this.metas.value.session)||void 0===e?void 0:e.id);null!=r&&(null===(n=this.transports)||void 0===n||n.addBeforeSendHooks(...this.transports.getBeforeSendHooks(),(e=>(null==r||r.updateSession(),e))))}else this.sendSessionStartEvent(this.metas.value);this.metas.addListener(this.sendSessionStartEvent.bind(this))}}class Ve extends oe{constructor(e={}){super(),this.options=e,this.name="@grafana/faro-web-sdk:instrumentation-console",this.version=ae}initialize(){this.logDebug("Initializing\n",this.options),k.filter((e=>{var n;return!(null!==(n=this.options.disabledLevels)&&void 0!==n?n:Ve.defaultDisabledLevels).includes(e)})).forEach((e=>{console[e]=(...n)=>{try{this.api.pushLog(n,{level:e})}catch(e){this.logError(e)}finally{this.unpatchedConsole[e](...n)}}}))}}Ve.defaultDisabledLevels=[e.LogLevel.DEBUG,e.LogLevel.TRACE,e.LogLevel.LOG];const qe=/^(?:[Uu]ncaught (?:exception: )?)?(?:((?:Eval|Internal|Range|Reference|Syntax|Type|URI|)Error): )?(.*)$/i,Ge=/^\s*at (?:(.*\).*?|.*?) ?\((?:address at )?)?((?:file|https?|blob|chrome-extension|address|native|eval|webpack|<anonymous>|[-a-z]+:|.*bundle|\/)?.*?)(?::(\d+))?(?::(\d+))?\)?\s*$/i,We=/\((\S*)(?::(\d+))(?::(\d+))\)/,Ke="address at ",He=Ke.length,Je=/^\s*(.*?)(?:\((.*?)\))?(?:^|@)?((?:file|https?|blob|chrome|webpack|resource|moz-extension|safari-extension|safari-web-extension|capacitor)?:\/.*?|\[native code]|[^@]*(?:bundle|\d+\.js)|\/[\w\-. /=]+)(?::(\d+))?(?::(\d+))?\s*$/i,Xe=/(\S+) line (\d+)(?: > eval line \d+)* > eval/i,Ze="safari-extension",Qe="safari-web-extension",Ye=/Minified React error #\d+;/i;function en(e,n,t,i){const r={filename:e||document.location.href,function:n||"?"};return void 0!==t&&(r.lineno=t),void 0!==i&&(r.colno=i),r}function nn(e,n){const t=null==e?void 0:e.includes(Ze),i=!t&&(null==e?void 0:e.includes(Qe));return t||i?[(null==e?void 0:e.includes("@"))?e.split("@")[0]:e,t?`${Ze}:${n}`:`${Qe}:${n}`]:[e,n]}function tn(e){let n=[];e.stacktrace?n=e.stacktrace.split("\n").filter(((e,n)=>n%2==0)):e.stack&&(n=e.stack.split("\n"));const t=n.reduce(((n,t,i)=>{let r,s,o,l,u;if(r=Ge.exec(t)){if(s=r[1],o=r[2],l=r[3],u=r[4],null==o?void 0:o.startsWith("eval")){const e=We.exec(o);e&&(o=e[1],l=e[2],u=e[3])}o=(null==o?void 0:o.startsWith(Ke))?o.substring(He):o,[s,o]=nn(s,o)}else if(r=Je.exec(t)){if(s=r[1],o=r[3],l=r[4],u=r[5],o&&o.includes(" > eval")){const e=Xe.exec(o);e&&(s=s||"eval",o=e[1],l=e[2])}else 0===i&&!u&&a(e.columnNumber)&&(u=String(e.columnNumber+1));[s,o]=nn(s,o)}return(o||s)&&n.push(en(o,s,l?Number(l):void 0,u?Number(u):void 0)),n}),[]);return Ye.test(e.message)?t.slice(1):t}function rn(e){return{frames:tn(e)}}function sn(e){let n,t,i,r,s=[];if(v(e)&&e.error)n=e.error.message,t=e.error.name,s=tn(e.error);else if((i=m(e))||h(e)){const{name:r,message:s}=e;t=null!=r?r:i?"DOMError":"DOMException",n=s?`${t}: ${s}`:t}else b(e)?(n=e.message,s=tn(e)):(l(e)||(r=f(e)))&&(t=r?e.constructor.name:void 0,n=`Non-Error exception captured with keys: ${Object.keys(e)}`);return[n,t,s]}function on(e){const n=window.onerror;window.onerror=(...t)=>{try{const[i,r,s,a,l]=t;let u,c,d=[];const p=o(i),f=en(r,"?",s,a);l||!p?([u,c,d]=sn(null!=l?l:i),0===d.length&&(d=[f])):p&&([u,c]=function(e){var n,t;const i=e.match(qe),r=null!==(n=null==i?void 0:i[1])&&void 0!==n?n:te;return[null!==(t=null==i?void 0:i[2])&&void 0!==t?t:e,r]}(i),d=[f]),u&&e.pushError(new Error(u),{type:c,stackFrames:d})}finally{null==n||n.apply(window,t)}}}class an extends oe{constructor(){super(...arguments),this.name="@grafana/faro-web-sdk:instrumentation-errors",this.version=ae}initialize(){var e;this.logDebug("Initializing"),on(this.api),e=this.api,window.addEventListener("unhandledrejection",(n=>{var t,i;let r,s,o=n;o.reason?o=n.reason:(null===(t=n.detail)||void 0===t?void 0:t.reason)&&(o=null===(i=n.detail)||void 0===i?void 0:i.reason);let a=[];d(o)?(r=`Non-Error promise rejection captured with value: ${String(o)}`,s="UnhandledRejection"):[r,s,a]=sn(o),r&&e.pushError(new Error(r),{type:s,stackFrames:a})}))}}class ln extends oe{constructor(){super(...arguments),this.name="@grafana/faro-web-sdk:instrumentation-view",this.version=ae}sendViewChangedEvent(e){const n=e.view;n&&n!==this.notifiedView&&(this.notifiedView=n,this.api.pushEvent("view_changed",{},void 0,{skipDedupe:!0}))}initialize(){this.sendViewChangedEvent(this.metas.value),this.metas.addListener(this.sendViewChangedEvent.bind(this))}}var un,cn,dn,pn,fn,gn=-1,bn=function(e){addEventListener("pageshow",(function(n){n.persisted&&(gn=n.timeStamp,e(n))}),!0)},vn=function(){return window.performance&&performance.getEntriesByType&&performance.getEntriesByType("navigation")[0]},mn=function(){var e=vn();return e&&e.activationStart||0},hn=function(e,n){var t=vn(),i="navigate";return gn>=0?i="back-forward-cache":t&&(document.prerendering||mn()>0?i="prerender":document.wasDiscarded?i="restore":t.type&&(i=t.type.replace(/_/g,"-"))),{name:e,value:void 0===n?-1:n,rating:"good",delta:0,entries:[],id:"v3-".concat(Date.now(),"-").concat(Math.floor(8999999999999*Math.random())+1e12),navigationType:i}},wn=function(e,n,t){try{if(PerformanceObserver.supportedEntryTypes.includes(e)){var i=new PerformanceObserver((function(e){Promise.resolve().then((function(){n(e.getEntries())}))}));return i.observe(Object.assign({type:e,buffered:!0},t||{})),i}}catch(e){}},yn=function(e,n,t,i){var r,s;return function(o){n.value>=0&&(o||i)&&((s=n.value-(r||0))||void 0===r)&&(r=n.value,n.delta=s,n.rating=function(e,n){return e>n[1]?"poor":e>n[0]?"needs-improvement":"good"}(n.value,t),e(n))}},Sn=function(e){requestAnimationFrame((function(){return requestAnimationFrame((function(){return e()}))}))},En=function(e){var n=function(n){"pagehide"!==n.type&&"hidden"!==document.visibilityState||e(n)};addEventListener("visibilitychange",n,!0),addEventListener("pagehide",n,!0)},Tn=function(e){var n=!1;return function(t){n||(e(t),n=!0)}},xn=-1,kn=function(){return"hidden"!==document.visibilityState||document.prerendering?1/0:0},In=function(e){"hidden"===document.visibilityState&&xn>-1&&(xn="visibilitychange"===e.type?e.timeStamp:0,On())},Ln=function(){addEventListener("visibilitychange",In,!0),addEventListener("prerenderingchange",In,!0)},On=function(){removeEventListener("visibilitychange",In,!0),removeEventListener("prerenderingchange",In,!0)},An=function(){return xn<0&&(xn=kn(),Ln(),bn((function(){setTimeout((function(){xn=kn(),Ln()}),0)}))),{get firstHiddenTime(){return xn}}},Cn=function(e){document.prerendering?addEventListener("prerenderingchange",(function(){return e()}),!0):e()},Nn=[1800,3e3],jn=function(e,n){n=n||{},Cn((function(){var t,i=An(),r=hn("FCP"),s=wn("paint",(function(e){e.forEach((function(e){"first-contentful-paint"===e.name&&(s.disconnect(),e.startTime<i.firstHiddenTime&&(r.value=Math.max(e.startTime-mn(),0),r.entries.push(e),t(!0)))}))}));s&&(t=yn(e,r,Nn,n.reportAllChanges),bn((function(i){r=hn("FCP"),t=yn(e,r,Nn,n.reportAllChanges),Sn((function(){r.value=performance.now()-i.timeStamp,t(!0)}))})))}))},Rn=[.1,.25],Dn={passive:!0,capture:!0},Un=new Date,Mn=function(e,n){un||(un=n,cn=e,dn=new Date,Bn(removeEventListener),Pn())},Pn=function(){if(cn>=0&&cn<dn-Un){var e={entryType:"first-input",name:un.type,target:un.target,cancelable:un.cancelable,startTime:un.timeStamp,processingStart:un.timeStamp+cn};pn.forEach((function(n){n(e)})),pn=[]}},_n=function(e){if(e.cancelable){var n=(e.timeStamp>1e12?new Date:performance.now())-e.timeStamp;"pointerdown"==e.type?function(e,n){var t=function(){Mn(e,n),r()},i=function(){r()},r=function(){removeEventListener("pointerup",t,Dn),removeEventListener("pointercancel",i,Dn)};addEventListener("pointerup",t,Dn),addEventListener("pointercancel",i,Dn)}(n,e):Mn(n,e)}},Bn=function(e){["mousedown","keydown","touchstart","pointerdown"].forEach((function(n){return e(n,_n,Dn)}))},zn=[100,300],Fn=0,$n=1/0,Vn=0,qn=function(e){e.forEach((function(e){e.interactionId&&($n=Math.min($n,e.interactionId),Vn=Math.max(Vn,e.interactionId),Fn=Vn?(Vn-$n)/7+1:0)}))},Gn=function(){return fn?Fn:performance.interactionCount||0},Wn=function(){"interactionCount"in performance||fn||(fn=wn("event",qn,{type:"event",buffered:!0,durationThreshold:0}))},Kn=[200,500],Hn=0,Jn=function(){return Gn()-Hn},Xn=[],Zn={},Qn=function(e){var n=Xn[Xn.length-1],t=Zn[e.interactionId];if(t||Xn.length<10||e.duration>n.latency){if(t)t.entries.push(e),t.latency=Math.max(t.latency,e.duration);else{var i={id:e.interactionId,latency:e.duration,entries:[e]};Zn[i.id]=i,Xn.push(i)}Xn.sort((function(e,n){return n.latency-e.latency})),Xn.splice(10).forEach((function(e){delete Zn[e.id]}))}},Yn=[2500,4e3],et={},nt=[800,1800],tt=function e(n){document.prerendering?Cn((function(){return e(n)})):"complete"!==document.readyState?addEventListener("load",(function(){return e(n)}),!0):setTimeout(n,0)};class it extends oe{constructor(){super(...arguments),this.name="@grafana/faro-web-sdk:instrumentation-web-vitals",this.version=ae}initialize(){this.logDebug("Initializing"),Object.entries(it.mapping).forEach((([e,n])=>{n((n=>{this.api.pushMeasurement({type:"web-vitals",values:{[e]:n.value}})}))}))}}function rt(e={}){const n=[new an,new it,new $e,new ln];return!1!==e.captureConsole&&n.push(new Ve({disabledLevels:e.captureConsoleDisabledLevels})),n}it.mapping={cls:function(e,n){n=n||{},jn(Tn((function(){var t,i=hn("CLS",0),r=0,s=[],o=function(e){e.forEach((function(e){if(!e.hadRecentInput){var n=s[0],t=s[s.length-1];r&&e.startTime-t.startTime<1e3&&e.startTime-n.startTime<5e3?(r+=e.value,s.push(e)):(r=e.value,s=[e])}})),r>i.value&&(i.value=r,i.entries=s,t())},a=wn("layout-shift",o);a&&(t=yn(e,i,Rn,n.reportAllChanges),En((function(){o(a.takeRecords()),t(!0)})),bn((function(){r=0,i=hn("CLS",0),t=yn(e,i,Rn,n.reportAllChanges),Sn((function(){return t()}))})),setTimeout(t,0))})))},fcp:jn,fid:function(e,n){n=n||{},Cn((function(){var t,i=An(),r=hn("FID"),s=function(e){e.startTime<i.firstHiddenTime&&(r.value=e.processingStart-e.startTime,r.entries.push(e),t(!0))},o=function(e){e.forEach(s)},a=wn("first-input",o);t=yn(e,r,zn,n.reportAllChanges),a&&En(Tn((function(){o(a.takeRecords()),a.disconnect()}))),a&&bn((function(){var i;r=hn("FID"),t=yn(e,r,zn,n.reportAllChanges),pn=[],cn=-1,un=null,Bn(addEventListener),i=s,pn.push(i),Pn()}))}))},inp:function(e,n){n=n||{},Cn((function(){var t;Wn();var i,r=hn("INP"),s=function(e){e.forEach((function(e){e.interactionId&&Qn(e),"first-input"===e.entryType&&!Xn.some((function(n){return n.entries.some((function(n){return e.duration===n.duration&&e.startTime===n.startTime}))}))&&Qn(e)}));var n,t=(n=Math.min(Xn.length-1,Math.floor(Jn()/50)),Xn[n]);t&&t.latency!==r.value&&(r.value=t.latency,r.entries=t.entries,i())},o=wn("event",s,{durationThreshold:null!==(t=n.durationThreshold)&&void 0!==t?t:40});i=yn(e,r,Kn,n.reportAllChanges),o&&("interactionId"in PerformanceEventTiming.prototype&&o.observe({type:"first-input",buffered:!0}),En((function(){s(o.takeRecords()),r.value<0&&Jn()>0&&(r.value=0,r.entries=[]),i(!0)})),bn((function(){Xn=[],Hn=Gn(),r=hn("INP"),i=yn(e,r,Kn,n.reportAllChanges)})))}))},lcp:function(e,n){n=n||{},Cn((function(){var t,i=An(),r=hn("LCP"),s=function(e){var n=e[e.length-1];n&&n.startTime<i.firstHiddenTime&&(r.value=Math.max(n.startTime-mn(),0),r.entries=[n],t())},o=wn("largest-contentful-paint",s);if(o){t=yn(e,r,Yn,n.reportAllChanges);var a=Tn((function(){et[r.id]||(s(o.takeRecords()),o.disconnect(),et[r.id]=!0,t(!0))}));["keydown","click"].forEach((function(e){addEventListener(e,(function(){return setTimeout(a,0)}),!0)})),En(a),bn((function(i){r=hn("LCP"),t=yn(e,r,Yn,n.reportAllChanges),Sn((function(){r.value=performance.now()-i.timeStamp,et[r.id]=!0,t(!0)}))}))}}))},ttfb:function(e,n){n=n||{};var t=hn("TTFB"),i=yn(e,t,nt,n.reportAllChanges);tt((function(){var r=vn();if(r){var s=r.responseStart;if(s<=0||s>performance.now())return;t.value=Math.max(s-mn(),0),t.entries=[r],i(!0),bn((function(){t=hn("TTFB",0),(i=yn(e,t,nt,n.reportAllChanges))(!0)}))}}))}};const st="browser",ot=()=>({k6:{isK6Browser:!0}});function at(e,n,t,i){return new(t||(t=Promise))((function(r,s){function o(e){try{l(i.next(e))}catch(e){s(e)}}function a(e){try{l(i.throw(e))}catch(e){s(e)}}function l(e){var n;e.done?r(e.value):(n=e.value,n instanceof t?n:new t((function(e){e(n)}))).then(o,a)}l((i=i.apply(e,n||[])).next())}))}"function"==typeof SuppressedError&&SuppressedError;class lt extends Y{constructor(e){var n,t,i,r;super(),this.options=e,this.name="@grafana/faro-web-sdk:transport-fetch",this.version=ae,this.disabledUntil=new Date,this.rateLimitBackoffMs=null!==(n=e.defaultRateLimitBackoffMs)&&void 0!==n?n:5e3,this.getNow=null!==(t=e.getNow)&&void 0!==t?t:()=>Date.now(),this.promiseBuffer=L({size:null!==(i=e.bufferSize)&&void 0!==i?i:30,concurrency:null!==(r=e.concurrency)&&void 0!==r?r:5})}send(e){return at(this,void 0,void 0,(function*(){try{if(this.disabledUntil>new Date(this.getNow()))return this.logWarn(`Dropping transport item due to too many requests. Backoff until ${this.disabledUntil}`),Promise.resolve();yield this.promiseBuffer.add((()=>{var n,t;const i=JSON.stringify(ne(e)),{url:r,requestOptions:s,apiKey:o}=this.options,a=null!=s?s:{},{headers:l}=a,u=function(e,n){var t={};for(var i in e)Object.prototype.hasOwnProperty.call(e,i)&&n.indexOf(i)<0&&(t[i]=e[i]);if(null!=e&&"function"==typeof Object.getOwnPropertySymbols){var r=0;for(i=Object.getOwnPropertySymbols(e);r<i.length;r++)n.indexOf(i[r])<0&&Object.prototype.propertyIsEnumerable.call(e,i[r])&&(t[i[r]]=e[i[r]])}return t}(a,["headers"]),c=null===(n=this.metas.value.session)||void 0===n?void 0:n.id;return fetch(r,Object.assign({method:"POST",headers:Object.assign(Object.assign(Object.assign({"Content-Type":"application/json"},null!=l?l:{}),o?{"x-api-key":o}:{}),(null===(t=this.config.sessionTracking)||void 0===t?void 0:t.enabled)&&c?{"x-faro-session-id":c}:{}),body:i,keepalive:i.length<=6e4},null!=u?u:{})).then((e=>(429===e.status&&(this.disabledUntil=this.getRetryAfterDate(e),this.logWarn(`Too many requests, backing off until ${this.disabledUntil}`)),e.text().catch(I),e))).catch((e=>{this.logError("Failed sending payload to the receiver\n",JSON.parse(i),e)}))}))}catch(e){this.logError(e)}}))}getIgnoreUrls(){return[this.options.url]}isBatched(){return!0}getRetryAfterDate(e){const n=this.getNow(),t=e.headers.get("Retry-After");if(t){const e=Number(t);if(!isNaN(e))return new Date(1e3*e+n);const i=Date.parse(t);if(!isNaN(i))return new Date(i)}return new Date(n+this.rateLimitBackoffMs)}}function ut(e){var n,t,i,r,s,o,a,u,c,d,p;const f=[],g=J(e.unpatchedConsole,e.internalLoggerLevel);e.transports?((e.url||e.apiKey)&&g.error('if "transports" is defined, "url" and "apiKey" should not be defined'),f.push(...e.transports)):e.url?f.push(new lt({url:e.url,apiKey:e.apiKey})):g.error('either "url" or "transports" must be defined');const b={app:e.app,batching:Object.assign(Object.assign({},ge),e.batching),dedupe:null===(n=e.dedupe)||void 0===n||n,globalObjectKey:e.globalObjectKey||fe,instrumentations:null!==(t=e.instrumentations)&&void 0!==t?t:rt(),internalLoggerLevel:null!==(i=e.internalLoggerLevel)&&void 0!==i?i:G,isolate:null!==(r=e.isolate)&&void 0!==r&&r,metas:function(){const n=ye;return e.metas&&n.push(...e.metas),l(window.k6)?[...n,ot]:n}(),parseStacktrace:rn,paused:null!==(s=e.paused)&&void 0!==s&&s,preventGlobalExposure:null!==(o=e.preventGlobalExposure)&&void 0!==o&&o,transports:f,unpatchedConsole:null!==(a=e.unpatchedConsole)&&void 0!==a?a:W,beforeSend:e.beforeSend,eventDomain:null!==(u=e.eventDomain)&&void 0!==u?u:st,ignoreErrors:e.ignoreErrors,sessionTracking:Object.assign(Object.assign({},Ue),e.sessionTracking),session:null!==(c=e.session)&&void 0!==c?c:Se(),user:e.user,view:null!==(d=e.view)&&void 0!==d?d:Ee};return(null===(p=b.sessionTracking)||void 0===p?void 0:p.enabled)&&delete b.session,b}return e.BaseExtension=Q,e.BaseInstrumentation=oe,e.BaseTransport=Y,e.ConsoleInstrumentation=Ve,e.ConsoleTransport=class extends Y{constructor(e={}){super(),this.options=e,this.name="@grafana/faro-web-sdk:transport-console",this.version=ae}send(n){var t;return this.unpatchedConsole[null!==(t=this.options.level)&&void 0!==t?t:e.LogLevel.DEBUG]("New event",ne([n]))}},e.Conventions={EventNames:{CLICK:"click",NAVIGATION:"navigation",SESSION_START:"session_start",VIEW_CHANGED:"view_changed"}},e.ErrorsInstrumentation=an,e.FetchTransport=lt,e.SessionInstrumentation=$e,e.VERSION=ae,e.ViewInstrumentation=ln,e.WebVitalsInstrumentation=it,e.allLogLevels=k,e.browserMeta=he,e.buildStackFrame=en,e.createInternalLogger=J,e.createPromiseBuffer=L,e.createSession=Se,e.deepEqual=S,e.defaultEventDomain=st,e.defaultExceptionType=te,e.defaultGlobalObjectKey=fe,e.defaultInternalLoggerLevel=G,e.defaultLogLevel=x,e.defaultMetas=ye,e.defaultViewMeta=Ee,e.genShortID=A,e.getCurrentTimestamp=E,e.getDataFromSafariExtensions=nn,e.getInternalFaroFromGlobalObject=function(){return se[le]},e.getStackFramesFromError=tn,e.getTransportBody=ne,e.getWebInstrumentations=rt,e.globalObject=se,e.initializeFaro=function(e){const n=ut(e);if(n)return pe(n)},e.internalGlobalObjectKey=le,e.isArray=c,e.isBoolean=e=>n(e,"boolean"),e.isDomError=m,e.isDomException=h,e.isElement=e=>w&&i(e,Element),e.isElementDefined=w,e.isError=b,e.isErrorDefined=g,e.isErrorEvent=v,e.isEvent=f,e.isEventDefined=p,e.isFunction=u,e.isInstanceOf=i,e.isInt=e=>a(e)&&Number.isInteger(e),e.isInternalFaroOnGlobalObject=ce,e.isMap=e=>y&&i(e,Map),e.isMapDefined=y,e.isNull=s,e.isNumber=a,e.isObject=l,e.isPrimitive=d,e.isRegExp=e=>t(e,"RegExp"),e.isString=o,e.isSymbol=e=>n(e,"symbol"),e.isSyntheticEvent=e=>l(e)&&"nativeEvent"in e&&"preventDefault"in e&&"stopPropagation"in e,e.isThenable=e=>u(null==e?void 0:e.then),e.isToString=t,e.isTypeof=n,e.isUndefined=r,e.makeCoreConfig=ut,e.noop=I,e.pageMeta=we,e.parseStacktrace=rn,e.sdkMeta=()=>({sdk:{name:"@grafana/faro-core",version:ae,integrations:e.faro.config.instrumentations.map((({name:e,version:n})=>({name:e,version:n})))}}),e.setInternalFaroOnGlobalObject=ue,e.transportItemTypeToBodyKey=F,e}({}); |
@@ -6,3 +6,3 @@ import { BaseInstrumentation, LogLevel } from '@grafana/faro-core'; | ||
readonly name = "@grafana/faro-web-sdk:instrumentation-console"; | ||
readonly version = "1.2.6"; | ||
readonly version = "1.2.7"; | ||
static defaultDisabledLevels: LogLevel[]; | ||
@@ -9,0 +9,0 @@ constructor(options?: ConsoleInstrumentationOptions); |
import { BaseInstrumentation } from '@grafana/faro-core'; | ||
export declare class ErrorsInstrumentation extends BaseInstrumentation { | ||
readonly name = "@grafana/faro-web-sdk:instrumentation-errors"; | ||
readonly version = "1.2.6"; | ||
readonly version = "1.2.7"; | ||
initialize(): void; | ||
} |
import { BaseInstrumentation } from '@grafana/faro-core'; | ||
export declare class SessionInstrumentation extends BaseInstrumentation { | ||
readonly name = "@grafana/faro-web-sdk:instrumentation-session"; | ||
readonly version = "1.2.6"; | ||
readonly version = "1.2.7"; | ||
private notifiedSession; | ||
@@ -6,0 +6,0 @@ private sendSessionStartEvent; |
import { BaseInstrumentation } from '@grafana/faro-core'; | ||
export declare class ViewInstrumentation extends BaseInstrumentation { | ||
readonly name = "@grafana/faro-web-sdk:instrumentation-view"; | ||
readonly version = "1.2.6"; | ||
readonly version = "1.2.7"; | ||
private notifiedView; | ||
@@ -6,0 +6,0 @@ private sendViewChangedEvent; |
import { BaseInstrumentation } from '@grafana/faro-core'; | ||
export declare class WebVitalsInstrumentation extends BaseInstrumentation { | ||
readonly name = "@grafana/faro-web-sdk:instrumentation-web-vitals"; | ||
readonly version = "1.2.6"; | ||
readonly version = "1.2.7"; | ||
static mapping: { | ||
@@ -6,0 +6,0 @@ cls: (onReport: import("web-vitals").CLSReportCallback, opts?: import("web-vitals").ReportOpts | undefined) => void; |
@@ -7,5 +7,5 @@ import { BaseTransport } from '@grafana/faro-core'; | ||
readonly name = "@grafana/faro-web-sdk:transport-console"; | ||
readonly version = "1.2.6"; | ||
readonly version = "1.2.7"; | ||
constructor(options?: ConsoleTransportOptions); | ||
send(item: TransportItem): void; | ||
} |
@@ -7,3 +7,3 @@ import { BaseTransport, PromiseBuffer } from '@grafana/faro-core'; | ||
readonly name = "@grafana/faro-web-sdk:transport-fetch"; | ||
readonly version = "1.2.6"; | ||
readonly version = "1.2.7"; | ||
promiseBuffer: PromiseBuffer<Response | void>; | ||
@@ -10,0 +10,0 @@ private readonly rateLimitBackoffMs; |
@@ -114,8 +114,8 @@ "use strict"; | ||
return [4 /*yield*/, this.promiseBuffer.add(function () { | ||
var _a; | ||
var _a, _b; | ||
var body = JSON.stringify((0, faro_core_1.getTransportBody)(items)); | ||
var _b = _this.options, url = _b.url, requestOptions = _b.requestOptions, apiKey = _b.apiKey; | ||
var _c = requestOptions !== null && requestOptions !== void 0 ? requestOptions : {}, headers = _c.headers, restOfRequestOptions = __rest(_c, ["headers"]); | ||
var _c = _this.options, url = _c.url, requestOptions = _c.requestOptions, apiKey = _c.apiKey; | ||
var _d = requestOptions !== null && requestOptions !== void 0 ? requestOptions : {}, headers = _d.headers, restOfRequestOptions = __rest(_d, ["headers"]); | ||
var sessionId = (_a = _this.metas.value.session) === null || _a === void 0 ? void 0 : _a.id; | ||
return fetch(url, __assign({ method: 'POST', headers: __assign(__assign(__assign({ 'Content-Type': 'application/json' }, (headers !== null && headers !== void 0 ? headers : {})), (apiKey ? { 'x-api-key': apiKey } : {})), (sessionId ? { 'x-faro-session-id': sessionId } : {})), body: body, keepalive: body.length <= BEACON_BODY_SIZE_LIMIT }, (restOfRequestOptions !== null && restOfRequestOptions !== void 0 ? restOfRequestOptions : {}))) | ||
return fetch(url, __assign({ method: 'POST', headers: __assign(__assign(__assign({ 'Content-Type': 'application/json' }, (headers !== null && headers !== void 0 ? headers : {})), (apiKey ? { 'x-api-key': apiKey } : {})), (((_b = _this.config.sessionTracking) === null || _b === void 0 ? void 0 : _b.enabled) && sessionId ? { 'x-faro-session-id': sessionId } : {})), body: body, keepalive: body.length <= BEACON_BODY_SIZE_LIMIT }, (restOfRequestOptions !== null && restOfRequestOptions !== void 0 ? restOfRequestOptions : {}))) | ||
.then(function (response) { | ||
@@ -122,0 +122,0 @@ if (response.status === TOO_MANY_REQUESTS) { |
@@ -50,8 +50,8 @@ var __awaiter = (this && this.__awaiter) || function (thisArg, _arguments, P, generator) { | ||
yield this.promiseBuffer.add(() => { | ||
var _a; | ||
var _a, _b; | ||
const body = JSON.stringify(getTransportBody(items)); | ||
const { url, requestOptions, apiKey } = this.options; | ||
const _b = requestOptions !== null && requestOptions !== void 0 ? requestOptions : {}, { headers } = _b, restOfRequestOptions = __rest(_b, ["headers"]); | ||
const _c = requestOptions !== null && requestOptions !== void 0 ? requestOptions : {}, { headers } = _c, restOfRequestOptions = __rest(_c, ["headers"]); | ||
const sessionId = (_a = this.metas.value.session) === null || _a === void 0 ? void 0 : _a.id; | ||
return fetch(url, Object.assign({ method: 'POST', headers: Object.assign(Object.assign(Object.assign({ 'Content-Type': 'application/json' }, (headers !== null && headers !== void 0 ? headers : {})), (apiKey ? { 'x-api-key': apiKey } : {})), (sessionId ? { 'x-faro-session-id': sessionId } : {})), body, keepalive: body.length <= BEACON_BODY_SIZE_LIMIT }, (restOfRequestOptions !== null && restOfRequestOptions !== void 0 ? restOfRequestOptions : {}))) | ||
return fetch(url, Object.assign({ method: 'POST', headers: Object.assign(Object.assign(Object.assign({ 'Content-Type': 'application/json' }, (headers !== null && headers !== void 0 ? headers : {})), (apiKey ? { 'x-api-key': apiKey } : {})), (((_b = this.config.sessionTracking) === null || _b === void 0 ? void 0 : _b.enabled) && sessionId ? { 'x-faro-session-id': sessionId } : {})), body, keepalive: body.length <= BEACON_BODY_SIZE_LIMIT }, (restOfRequestOptions !== null && restOfRequestOptions !== void 0 ? restOfRequestOptions : {}))) | ||
.then((response) => { | ||
@@ -58,0 +58,0 @@ if (response.status === TOO_MANY_REQUESTS) { |
@@ -6,3 +6,3 @@ import { BaseInstrumentation, LogLevel } from '@grafana/faro-core'; | ||
readonly name = "@grafana/faro-web-sdk:instrumentation-console"; | ||
readonly version = "1.2.6"; | ||
readonly version = "1.2.7"; | ||
static defaultDisabledLevels: LogLevel[]; | ||
@@ -9,0 +9,0 @@ constructor(options?: ConsoleInstrumentationOptions); |
import { BaseInstrumentation } from '@grafana/faro-core'; | ||
export declare class ErrorsInstrumentation extends BaseInstrumentation { | ||
readonly name = "@grafana/faro-web-sdk:instrumentation-errors"; | ||
readonly version = "1.2.6"; | ||
readonly version = "1.2.7"; | ||
initialize(): void; | ||
} |
import { BaseInstrumentation } from '@grafana/faro-core'; | ||
export declare class SessionInstrumentation extends BaseInstrumentation { | ||
readonly name = "@grafana/faro-web-sdk:instrumentation-session"; | ||
readonly version = "1.2.6"; | ||
readonly version = "1.2.7"; | ||
private notifiedSession; | ||
@@ -6,0 +6,0 @@ private sendSessionStartEvent; |
import { BaseInstrumentation } from '@grafana/faro-core'; | ||
export declare class ViewInstrumentation extends BaseInstrumentation { | ||
readonly name = "@grafana/faro-web-sdk:instrumentation-view"; | ||
readonly version = "1.2.6"; | ||
readonly version = "1.2.7"; | ||
private notifiedView; | ||
@@ -6,0 +6,0 @@ private sendViewChangedEvent; |
import { BaseInstrumentation } from '@grafana/faro-core'; | ||
export declare class WebVitalsInstrumentation extends BaseInstrumentation { | ||
readonly name = "@grafana/faro-web-sdk:instrumentation-web-vitals"; | ||
readonly version = "1.2.6"; | ||
readonly version = "1.2.7"; | ||
static mapping: { | ||
@@ -6,0 +6,0 @@ cls: (onReport: import("web-vitals").CLSReportCallback, opts?: import("web-vitals").ReportOpts | undefined) => void; |
@@ -7,5 +7,5 @@ import { BaseTransport } from '@grafana/faro-core'; | ||
readonly name = "@grafana/faro-web-sdk:transport-console"; | ||
readonly version = "1.2.6"; | ||
readonly version = "1.2.7"; | ||
constructor(options?: ConsoleTransportOptions); | ||
send(item: TransportItem): void; | ||
} |
@@ -7,3 +7,3 @@ import { BaseTransport, PromiseBuffer } from '@grafana/faro-core'; | ||
readonly name = "@grafana/faro-web-sdk:transport-fetch"; | ||
readonly version = "1.2.6"; | ||
readonly version = "1.2.7"; | ||
promiseBuffer: PromiseBuffer<Response | void>; | ||
@@ -10,0 +10,0 @@ private readonly rateLimitBackoffMs; |
{ | ||
"name": "@grafana/faro-web-sdk", | ||
"version": "1.2.6", | ||
"version": "1.2.7", | ||
"description": "Faro instrumentations, metas, transports for web.", | ||
@@ -55,3 +55,3 @@ "keywords": [ | ||
"dependencies": { | ||
"@grafana/faro-core": "^1.2.6", | ||
"@grafana/faro-core": "^1.2.7", | ||
"ua-parser-js": "^1.0.32", | ||
@@ -67,3 +67,3 @@ "web-vitals": "^3.1.1" | ||
}, | ||
"gitHead": "9eb32b34a9b1a3153c9686337c7b5d0963389c54" | ||
"gitHead": "cc1950b05af3a33d9187a1f50c3ab327e30963da" | ||
} |
Sorry, the diff of this file is not supported yet
Sorry, the diff of this file is not supported yet
License Policy Violation
LicenseThis package is not allowed per your license policy. Review the package's license to ensure compliance.
Found 1 instance in 1 package
License Policy Violation
LicenseThis package is not allowed per your license policy. Review the package's license to ensure compliance.
Found 1 instance in 1 package
445823
Updated@grafana/faro-core@^1.2.7