@dash0/sdk-web 0.13.3 → 0.13.5

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (55) hide show
  1. package/dist/dash0.iife.js +1 -1
  2. package/dist/dash0.iife.js.map +1 -1
  3. package/dist/dash0.js +1 -1
  4. package/dist/dash0.js.map +1 -1
  5. package/dist/dash0.umd.cjs +1 -1
  6. package/dist/dash0.umd.cjs.map +1 -1
  7. package/dist/modules/attributes/common.js +2 -2
  8. package/dist/modules/attributes/url.js +11 -10
  9. package/dist/modules/instrumentations/http/fetch.js +3 -3
  10. package/dist/modules/semantic-conventions.js +1 -0
  11. package/dist/modules/types/errors.js +1 -0
  12. package/dist/modules/types/globals.js +1 -0
  13. package/dist/modules/types/otlp.js +1 -0
  14. package/dist/modules/utils/otel/attributes.js +8 -0
  15. package/dist/modules/vars.js +0 -1
  16. package/dist/tsconfig.tsbuildinfo +1 -1
  17. package/dist/types/api/attributes.d.ts +1 -1
  18. package/dist/types/api/events.d.ts +1 -1
  19. package/dist/types/api/init.d.ts +1 -1
  20. package/dist/types/api/report-error.d.ts +1 -1
  21. package/dist/types/attributes/common.d.ts +4 -1
  22. package/dist/types/attributes/url.d.ts +3 -2
  23. package/dist/types/instrumentations/errors/unhandled-error.d.ts +1 -1
  24. package/dist/types/semantic-conventions.d.ts +1 -0
  25. package/dist/types/transport/index.d.ts +1 -1
  26. package/dist/types/types/errors.d.ts +8 -0
  27. package/dist/types/types/globals.d.ts +12 -0
  28. package/dist/types/types/otlp.d.ts +104 -0
  29. package/dist/types/utils/otel/attributes.d.ts +3 -1
  30. package/dist/types/utils/otel/error.d.ts +1 -1
  31. package/dist/types/utils/otel/span.d.ts +1 -1
  32. package/dist/types/vars.d.ts +1 -1
  33. package/package.json +1 -1
  34. package/src/api/attributes.ts +1 -1
  35. package/src/api/events.ts +1 -1
  36. package/src/api/init.ts +1 -1
  37. package/src/api/report-error.ts +1 -1
  38. package/src/attributes/common.ts +6 -2
  39. package/src/attributes/common_test.ts +1 -1
  40. package/src/attributes/url.ts +13 -11
  41. package/src/instrumentations/errors/unhandled-error.ts +2 -2
  42. package/src/instrumentations/http/fetch.ts +3 -3
  43. package/src/instrumentations/navigation/event.ts +1 -1
  44. package/src/instrumentations/navigation/page-load.ts +1 -1
  45. package/src/instrumentations/web-vitals.ts +1 -1
  46. package/src/semantic-conventions.ts +1 -0
  47. package/src/transport/index.ts +1 -1
  48. package/src/types/errors.ts +9 -0
  49. package/src/types/globals.ts +19 -0
  50. package/src/types/otlp.ts +121 -0
  51. package/src/utils/otel/attributes.ts +12 -1
  52. package/src/utils/otel/attributes_test.ts +1 -1
  53. package/src/utils/otel/error.ts +1 -1
  54. package/src/utils/otel/span.ts +1 -1
  55. package/src/vars.ts +1 -3
@@ -1,2 +1,2 @@
1
- !function(){"use strict";function t(){}var e={debug:0,info:1,warn:2,error:3},n=e.warn;var r=u("info"),i=u("warn"),o=u("error"),a=u("debug");function u(r){if("undefined"!=typeof console&&console[r]&&"function"==typeof console[r].apply){var i=e[r];return function(){i>=n&&console[r].apply(console,arguments)}}return t}var s=Object.prototype.hasOwnProperty;function c(t,e){return s.call(t,e)}var l="undefined"!=typeof window?window:void 0,f=null==l?void 0:l.document,d=null==l?void 0:l.navigator,v="undefined"!=typeof location?location:void 0,p=(null==l?void 0:l.performance)||(null==l?void 0:l.webkitPerformance)||(null==l?void 0:l.msPerformance)||(null==l?void 0:l.mozPerformance);null==l||l.encodeURIComponent;var h=null==l?void 0:l.fetch,m=function(){try{var t;return null!==(t=null==l?void 0:l.localStorage)&&void 0!==t?t:null}catch(t){return null}}(),y=function(){try{var t;return null!==(t=null==l?void 0:l.sessionStorage)&&void 0!==t?t:null}catch(t){return null}}(),g=Array(32);function b(t){for(var e=0;e<2*t;e++)g[e]=Math.floor(16*Math.random())+48,g[e]>=58&&(g[e]+=39);return String.fromCharCode.apply(null,g.slice(0,2*t))}function T(t,e,n){t.addEventListener?t.addEventListener(e,n,!1):t.attachEvent&&t.attachEvent("on"+e,n)}var E=null!=m&&"function"==typeof m.getItem&&"function"==typeof m.setItem;function w(t,e){(null==e||e>t.length)&&(e=t.length);for(var n=0,r=Array(e);n<e;n++)r[n]=t[n];return r}function S(t,e,n,r,i,o,a){try{var u=t[o](a),s=u.value}catch(t){return void n(t)}u.done?e(s):Promise.resolve(s).then(r,i)}function A(t){return function(){var e=this,n=arguments;return new Promise((function(r,i){var o=t.apply(e,n);function a(t){S(o,r,i,a,u,"next",t)}function u(t){S(o,r,i,a,u,"throw",t)}a(void 0)}))}}function O(t,e){if(!(t instanceof e))throw new TypeError("Cannot call a class as a function")}function I(t,e,n){return e&&function(t,e){for(var n=0;n<e.length;n++){var r=e[n];r.enumerable=r.enumerable||!1,r.configurable=!0,"value"in r&&(r.writable=!0),Object.defineProperty(t,k(r.key),r)}}(t.prototype,e),Object.defineProperty(t,"prototype",{writable:!1}),t}function N(t,e){var n="undefined"!=typeof Symbol&&t[Symbol.iterator]||t["@@iterator"];if(!n){if(Array.isArray(t)||(n=D(t))||e){n&&(t=n);var r=0,i=function(){};return{s:i,n:function(){return r>=t.length?{done:!0}:{done:!1,value:t[r++]}},e:function(t){throw t},f:i}}throw new TypeError("Invalid attempt to iterate non-iterable instance.\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method.")}var o,a=!0,u=!1;return{s:function(){n=n.call(t)},n:function(){var t=n.next();return a=t.done,t},e:function(t){u=!0,o=t},f:function(){try{a||null==n.return||n.return()}finally{if(u)throw o}}}}function L(t,e,n){return(e=k(e))in t?Object.defineProperty(t,e,{value:n,enumerable:!0,configurable:!0,writable:!0}):t[e]=n,t}function _(t,e){var n=Object.keys(t);if(Object.getOwnPropertySymbols){var r=Object.getOwnPropertySymbols(t);e&&(r=r.filter((function(e){return Object.getOwnPropertyDescriptor(t,e).enumerable}))),n.push.apply(n,r)}return n}function C(){C=function(){return e};var t,e={},n=Object.prototype,r=n.hasOwnProperty,i=Object.defineProperty||function(t,e,n){t[e]=n.value},o="function"==typeof Symbol?Symbol:{},a=o.iterator||"@@iterator",u=o.asyncIterator||"@@asyncIterator",s=o.toStringTag||"@@toStringTag";function c(t,e,n){return Object.defineProperty(t,e,{value:n,enumerable:!0,configurable:!0,writable:!0}),t[e]}try{c({},"")}catch(t){c=function(t,e,n){return t[e]=n}}function l(t,e,n,r){var o=e&&e.prototype instanceof y?e:y,a=Object.create(o.prototype),u=new R(r||[]);return i(a,"_invoke",{value:I(t,n,u)}),a}function f(t,e,n){try{return{type:"normal",arg:t.call(e,n)}}catch(t){return{type:"throw",arg:t}}}e.wrap=l;var d="suspendedStart",v="suspendedYield",p="executing",h="completed",m={};function y(){}function g(){}function b(){}var T={};c(T,a,(function(){return this}));var E=Object.getPrototypeOf,w=E&&E(E(x([])));w&&w!==n&&r.call(w,a)&&(T=w);var S=b.prototype=y.prototype=Object.create(T);function A(t){["next","throw","return"].forEach((function(e){c(t,e,(function(t){return this._invoke(e,t)}))}))}function O(t,e){function n(i,o,a,u){var s=f(t[i],t,o);if("throw"!==s.type){var c=s.arg,l=c.value;return l&&"object"==typeof l&&r.call(l,"__await")?e.resolve(l.__await).then((function(t){n("next",t,a,u)}),(function(t){n("throw",t,a,u)})):e.resolve(l).then((function(t){c.value=t,a(c)}),(function(t){return n("throw",t,a,u)}))}u(s.arg)}var o;i(this,"_invoke",{value:function(t,r){function i(){return new e((function(e,i){n(t,r,e,i)}))}return o=o?o.then(i,i):i()}})}function I(e,n,r){var i=d;return function(o,a){if(i===p)throw Error("Generator is already running");if(i===h){if("throw"===o)throw a;return{value:t,done:!0}}for(r.method=o,r.arg=a;;){var u=r.delegate;if(u){var s=N(u,r);if(s){if(s===m)continue;return s}}if("next"===r.method)r.sent=r._sent=r.arg;else if("throw"===r.method){if(i===d)throw i=h,r.arg;r.dispatchException(r.arg)}else"return"===r.method&&r.abrupt("return",r.arg);i=p;var c=f(e,n,r);if("normal"===c.type){if(i=r.done?h:v,c.arg===m)continue;return{value:c.arg,done:r.done}}"throw"===c.type&&(i=h,r.method="throw",r.arg=c.arg)}}}function N(e,n){var r=n.method,i=e.iterator[r];if(i===t)return n.delegate=null,"throw"===r&&e.iterator.return&&(n.method="return",n.arg=t,N(e,n),"throw"===n.method)||"return"!==r&&(n.method="throw",n.arg=new TypeError("The iterator does not provide a '"+r+"' method")),m;var o=f(i,e.iterator,n.arg);if("throw"===o.type)return n.method="throw",n.arg=o.arg,n.delegate=null,m;var a=o.arg;return a?a.done?(n[e.resultName]=a.value,n.next=e.nextLoc,"return"!==n.method&&(n.method="next",n.arg=t),n.delegate=null,m):a:(n.method="throw",n.arg=new TypeError("iterator result is not an object"),n.delegate=null,m)}function L(t){var e={tryLoc:t[0]};1 in t&&(e.catchLoc=t[1]),2 in t&&(e.finallyLoc=t[2],e.afterLoc=t[3]),this.tryEntries.push(e)}function _(t){var e=t.completion||{};e.type="normal",delete e.arg,t.completion=e}function R(t){this.tryEntries=[{tryLoc:"root"}],t.forEach(L,this),this.reset(!0)}function x(e){if(e||""===e){var n=e[a];if(n)return n.call(e);if("function"==typeof e.next)return e;if(!isNaN(e.length)){var i=-1,o=function n(){for(;++i<e.length;)if(r.call(e,i))return n.value=e[i],n.done=!1,n;return n.value=t,n.done=!0,n};return o.next=o}}throw new TypeError(typeof e+" is not iterable")}return g.prototype=b,i(S,"constructor",{value:b,configurable:!0}),i(b,"constructor",{value:g,configurable:!0}),g.displayName=c(b,s,"GeneratorFunction"),e.isGeneratorFunction=function(t){var e="function"==typeof t&&t.constructor;return!!e&&(e===g||"GeneratorFunction"===(e.displayName||e.name))},e.mark=function(t){return Object.setPrototypeOf?Object.setPrototypeOf(t,b):(t.__proto__=b,c(t,s,"GeneratorFunction")),t.prototype=Object.create(S),t},e.awrap=function(t){return{__await:t}},A(O.prototype),c(O.prototype,u,(function(){return this})),e.AsyncIterator=O,e.async=function(t,n,r,i,o){void 0===o&&(o=Promise);var a=new O(l(t,n,r,i),o);return e.isGeneratorFunction(n)?a:a.next().then((function(t){return t.done?t.value:a.next()}))},A(S),c(S,s,"Generator"),c(S,a,(function(){return this})),c(S,"toString",(function(){return"[object Generator]"})),e.keys=function(t){var e=Object(t),n=[];for(var r in e)n.push(r);return n.reverse(),function t(){for(;n.length;){var r=n.pop();if(r in e)return t.value=r,t.done=!1,t}return t.done=!0,t}},e.values=x,R.prototype={constructor:R,reset:function(e){if(this.prev=0,this.next=0,this.sent=this._sent=t,this.done=!1,this.delegate=null,this.method="next",this.arg=t,this.tryEntries.forEach(_),!e)for(var n in this)"t"===n.charAt(0)&&r.call(this,n)&&!isNaN(+n.slice(1))&&(this[n]=t)},stop:function(){this.done=!0;var t=this.tryEntries[0].completion;if("throw"===t.type)throw t.arg;return this.rval},dispatchException:function(e){if(this.done)throw e;var n=this;function i(r,i){return u.type="throw",u.arg=e,n.next=r,i&&(n.method="next",n.arg=t),!!i}for(var o=this.tryEntries.length-1;o>=0;--o){var a=this.tryEntries[o],u=a.completion;if("root"===a.tryLoc)return i("end");if(a.tryLoc<=this.prev){var s=r.call(a,"catchLoc"),c=r.call(a,"finallyLoc");if(s&&c){if(this.prev<a.catchLoc)return i(a.catchLoc,!0);if(this.prev<a.finallyLoc)return i(a.finallyLoc)}else if(s){if(this.prev<a.catchLoc)return i(a.catchLoc,!0)}else{if(!c)throw Error("try statement without catch or finally");if(this.prev<a.finallyLoc)return i(a.finallyLoc)}}}},abrupt:function(t,e){for(var n=this.tryEntries.length-1;n>=0;--n){var i=this.tryEntries[n];if(i.tryLoc<=this.prev&&r.call(i,"finallyLoc")&&this.prev<i.finallyLoc){var o=i;break}}o&&("break"===t||"continue"===t)&&o.tryLoc<=e&&e<=o.finallyLoc&&(o=null);var a=o?o.completion:{};return a.type=t,a.arg=e,o?(this.method="next",this.next=o.finallyLoc,m):this.complete(a)},complete:function(t,e){if("throw"===t.type)throw t.arg;return"break"===t.type||"continue"===t.type?this.next=t.arg:"return"===t.type?(this.rval=this.arg=t.arg,this.method="return",this.next="end"):"normal"===t.type&&e&&(this.next=e),m},finish:function(t){for(var e=this.tryEntries.length-1;e>=0;--e){var n=this.tryEntries[e];if(n.finallyLoc===t)return this.complete(n.completion,n.afterLoc),_(n),m}},catch:function(t){for(var e=this.tryEntries.length-1;e>=0;--e){var n=this.tryEntries[e];if(n.tryLoc===t){var r=n.completion;if("throw"===r.type){var i=r.arg;_(n)}return i}}throw Error("illegal catch attempt")},delegateYield:function(e,n,r){return this.delegate={iterator:x(e),resultName:n,nextLoc:r},"next"===this.method&&(this.arg=t),m}},e}function R(t,e){return function(t){if(Array.isArray(t))return t}(t)||function(t,e){var n=null==t?null:"undefined"!=typeof Symbol&&t[Symbol.iterator]||t["@@iterator"];if(null!=n){var r,i,o,a,u=[],s=!0,c=!1;try{if(o=(n=n.call(t)).next,0===e);else for(;!(s=(r=o.call(n)).done)&&(u.push(r.value),u.length!==e);s=!0);}catch(t){c=!0,i=t}finally{try{if(!s&&null!=n.return&&(a=n.return(),Object(a)!==a))return}finally{if(c)throw i}}return u}}(t,e)||D(t,e)||function(){throw new TypeError("Invalid attempt to destructure non-iterable instance.\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method.")}()}function x(t){return function(t){if(Array.isArray(t))return w(t)}(t)||function(t){if("undefined"!=typeof Symbol&&null!=t[Symbol.iterator]||null!=t["@@iterator"])return Array.from(t)}(t)||D(t)||function(){throw new TypeError("Invalid attempt to spread non-iterable instance.\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method.")}()}function k(t){var e=function(t,e){if("object"!=typeof t||!t)return t;var n=t[Symbol.toPrimitive];if(void 0!==n){var r=n.call(t,e);if("object"!=typeof r)return r;throw new TypeError("@@toPrimitive must return a primitive value.")}return("string"===e?String:Number)(t)}(t,"string");return"symbol"==typeof e?e:e+""}function P(t){return P="function"==typeof Symbol&&"symbol"==typeof Symbol.iterator?function(t){return typeof t}:function(t){return t&&"function"==typeof Symbol&&t.constructor===Symbol&&t!==Symbol.prototype?"symbol":typeof t},P(t)}function D(t,e){if(t){if("string"==typeof t)return w(t,e);var n={}.toString.call(t).slice(8,-1);return"Object"===n&&t.constructor&&(n=t.constructor.name),"Map"===n||"Set"===n?Array.from(t):"Arguments"===n||/^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(n)?w(t,e):void 0}}function j(){return(new Date).getTime()}function M(){var t=F();return t?String(1e6*(p.now()+t)):U(new Date)}function U(t){return"object"===P(t)?U(t.getTime()):String(t)+"000000"}function F(){var t,e=null==p?void 0:p.timeOrigin;"number"!=typeof e&&(e=null==p||null===(t=p.timing)||void 0===t?void 0:t.fetchStart);return e}var V={setTimeout:null==l?void 0:l.setTimeout,clearTimeout:null==l?void 0:l.clearTimeout,setInterval:null==l?void 0:l.setInterval,clearInterval:null==l?void 0:l.clearInterval},B=null!=l&&null!=l.Zone&&null!=l.Zone.root&&"function"==typeof l.Zone.root.run;function W(){for(var t=arguments.length,e=new Array(t),n=0;n<t;n++)e[n]=arguments[n];return H.apply("setTimeout",arguments)}function q(){for(var t=arguments.length,e=new Array(t),n=0;n<t;n++)e[n]=arguments[n];return H.apply("setInterval",arguments)}function H(){var t,e=this;if(B)try{var n=Array.prototype.slice.apply(arguments);return l.Zone.root.run(V[e],l,n)}catch(t){i("Failed to execute %s inside of zone (via Zone.js). Falling back to execution inside currently active zone.",e,t)}return null===(t=V[e])||void 0===t?void 0:t.apply(l,arguments)}B&&a("Discovered Zone.js globals. Will attempt to register all timers inside the root Zone.");p&&p.getEntriesByType;var z=p&&"function"==typeof l.PerformanceObserver&&"function"==typeof p.now,G=Object.freeze({CONNECT_END:"connectEnd",CONNECT_START:"connectStart",DECODED_BODY_SIZE:"decodedBodySize",DOM_COMPLETE:"domComplete",DOM_CONTENT_LOADED_EVENT_END:"domContentLoadedEventEnd",DOM_CONTENT_LOADED_EVENT_START:"domContentLoadedEventStart",DOM_INTERACTIVE:"domInteractive",DOMAIN_LOOKUP_END:"domainLookupEnd",DOMAIN_LOOKUP_START:"domainLookupStart",ENCODED_BODY_SIZE:"encodedBodySize",FETCH_START:"fetchStart",LOAD_EVENT_END:"loadEventEnd",LOAD_EVENT_START:"loadEventStart",NAVIGATION_START:"navigationStart",REDIRECT_END:"redirectEnd",REDIRECT_START:"redirectStart",REQUEST_START:"requestStart",RESPONSE_END:"responseEnd",RESPONSE_START:"responseStart",SECURE_CONNECTION_START:"secureConnectionStart",START_TIME:"startTime",UNLOAD_EVENT_END:"unloadEventEnd",UNLOAD_EVENT_START:"unloadEventStart"}),K=new WeakSet;function Z(e){if(!z)return function(e){var n=0;return{start:function(){n=j()},end:function(){return e({duration:j()-n})},cancel:t}}(e.onEnd);var n,r,i,o,a,u=[];return{start:function(){n=p.now();try{var t,e=null==l?void 0:l.PerformanceObserver;if(e)null===(t=i=new e(c))||void 0===t||t.observe({type:"resource"})}catch(t){}a=W(v,6e5)},end:function(){if(r=p.now(),h(),!Y())return s();W((function(){return s()}),Math.min(300,e.maxWaitForResourceMillis)),T(f,"visibilitychange",d),o=W(s,e.maxWaitForResourceMillis)},cancel:v};function s(){v();var t=function(){if(!u.length)return;var t,i,o=u.filter((function(t){return t.responseEnd<=r+e.maxToleranceForResourceTimingsMillis&&!K.has(t)}));if(!o.length)return;1===o.length&&(t=o[0]);if(!t){var a,s=N(o);try{for(s.s();!(a=s.n()).done;){var c=a.value,l=Math.abs(r-n-c.duration)+Math.abs(c.responseEnd-r);(void 0===i||l<i)&&(i=l,t=c)}}catch(t){s.e(t)}finally{s.f()}}if(!t)return;return K.add(t),t}();null!=t&&t.duration&&t.duration<864e5?e.onEnd({resource:t,duration:t.duration}):e.onEnd({resource:t,duration:r-n})}function c(t){t.getEntriesByType("resource").filter((function(t){var r=t;return r.startTime>=n&&e.resourceMatcher(r)})).forEach((function(t){return u.push(t)}))}function d(){Y()||s()}function v(){!function(){if(i){try{var t;null===(t=i)||void 0===t||t.disconnect()}catch(t){}i=void 0}}(),o&&(clearTimeout(o),o=void 0),h(),function(){if(!f)return;t=f,e="visibilitychange",n=d,t.removeEventListener?t.removeEventListener(e,n,!1):t.detachEvent&&t.detachEvent("on"+e,n);var t,e,n}()}function h(){a&&(clearTimeout(a),a=void 0)}}function Y(){return"visible"===(null==f?void 0:f.visibilityState)||"prerender"===(null==f?void 0:f.visibilityState)}var Q="undefined";function X(t){return Math.round(100*t)/100}function $(t){var e;return"string"!=typeof t?t:new URL(t,null!==(e=null==f?void 0:f.baseURI)&&void 0!==e?e:null==v?void 0:v.href)}function J(t){try{return $(t).origin===("undefined"!=typeof location?location.origin:void 0)}catch(t){return!1}}var tt=Symbol.for("INSTRUMENTED_BY_DASH0");function et(t,e,n){var r=t[e];r?(!0===r[tt]&&a("".concat(String(e)," has already been instrumented, skipping")),function(t){t[tt]=!0}(r),t[e]=n(r)):a("".concat(String(e)," is not defined, unable to instrument"))}var nt={endpoints:[],resource:{attributes:[]},scope:{name:"dash0-web-sdk",version:"0.13.3",attributes:[]},signalAttributes:[],ignoreUrls:[],ignoreErrorMessages:[],wrapEventHandlers:!0,wrapTimers:!0,propagateTraceHeadersCorsURLs:[],maxWaitForResourceTimingsMillis:1e4,maxToleranceForResourceTimingsMillis:50,headersToCapture:[],pageViewInstrumentation:{trackVirtualPageViews:!0,includeParts:[]}};function rt(t,e){for(var n=0,r=t.length;n<r;n++)if(t[n].test(e))return!0;return!1}var it="data:";function ot(t){return!t||(!(t=String(t))||(null==t.substring||t.substring(0,5).toLowerCase()===it||(!!function(t){for(var e=t.toLowerCase(),n=0,r=nt.endpoints.length;n<r;n++){var i=nt.endpoints[n];if(e.startsWith(i.url))return!0}return!1}(t)||rt(nt.ignoreUrls,t))))}var at=!1;function ut(t){var e,n,r=[];return n=i,at&&n(),f&&l&&(T(f,"visibilitychange",(function(){"visible"!==f.visibilityState&&n()})),T(l,"pagehide",(function(){at=!0,n()})),T(l,"beforeunload",(function(){at=!0,n()}))),{send:function(n){"visible"===(null==f?void 0:f.visibilityState)?(r.push(n),r.length>=15?i():null==e&&(e=W(i,1e3))):t([n])}};function i(){null!=e&&(clearTimeout(e),e=null),r.length>0&&(t(r.slice()),r.length=0)}}function st(t,e){return ct.apply(this,arguments)}function ct(){return ct=A(C().mark((function e(n,r){var o,u,s,c;return C().wrap((function(e){for(;;)switch(e.prev=e.next){case 0:if(a("Transmitting telemetry to endpoints",r),o=JSON.stringify(r),u=o,s=o.length,c=!1,"undefined"==typeof CompressionStream){e.next=11;break}return e.next=8,lt(o);case 8:u=e.sent,s=u.byteLength,c=!0;case 11:return e.next=13,Promise.all(nt.endpoints.map(function(){var e=A(C().mark((function e(r){var o,a,l;return C().wrap((function(e){for(;;)switch(e.prev=e.next){case 0:if(e.prev=0,(o=new URL(r.url)).pathname=o.pathname+(o.pathname.endsWith("/")?n.substring(1):n),a={"Content-Type":"application/json",Authorization:"Bearer ".concat(r.authToken)},r.dataset&&(a["Dash0-Dataset"]=r.dataset),c&&(a["Content-Encoding"]="gzip"),h){e.next=9;break}return i("Unable to send telemetry, fetch is not defined"),e.abrupt("return");case 9:return e.next=11,h(o,{method:"POST",headers:a,body:u,keepalive:s<=6e4});case 11:(l=e.sent).text().catch(t),l.ok||i("Failed to send telemetry to ".concat(o,": ").concat(l.status," ").concat(l.statusText)),e.next=19;break;case 16:e.prev=16,e.t0=e.catch(0),i("Error sending telemetry to ".concat(r.url).concat(n,":"),e.t0);case 19:case"end":return e.stop()}}),e,null,[[0,16]])})));return function(t){return e.apply(this,arguments)}}()));case 13:case"end":return e.stop()}}),e)}))),ct.apply(this,arguments)}function lt(t){return ft.apply(this,arguments)}function ft(){return(ft=A(C().mark((function t(e){var n,r,i;return C().wrap((function(t){for(;;)switch(t.prev=t.next){case 0:return n=new Blob([e]),r=n.stream(),i=r.pipeThrough(new CompressionStream("gzip")),t.abrupt("return",new Response(i).arrayBuffer());case 4:case"end":return t.stop()}}),t)})))).apply(this,arguments)}var dt,vt=ut((function(t){st("/v1/logs",{resourceLogs:[{resource:nt.resource,scopeLogs:[{scope:nt.scope,logRecords:t}]}]}).catch((function(t){o("Failed to transmit logs",t)}))})),pt=ut((function(t){st("/v1/traces",{resourceSpans:[{resource:nt.resource,scopeSpans:[{scope:nt.scope,spans:t}]}]}).catch((function(t){o("Failed to transmit spans",t)}))}));function ht(){var t,e,n,r,i,o,a;return dt||(e=(t={maxCalls:8096,maxCallsPerTenMinutes:4096,maxCallsPerTenSeconds:128}).maxCalls,n=t.maxCallsPerTenMinutes,r=t.maxCallsPerTenSeconds,i=0,o=0,a=0,q((function(){o=0}),6e5),q((function(){a=0}),1e4),dt=function(){return++i>e||++o>n||++a>r}),dt()}function mt(t){ht()?a("Transport rate limit. Will not send item.",t):vt.send(t)}function yt(t){ht()?a("Transport rate limit. Will not send item.",t):pt.send(t)}var gt="service.name",bt="service.version",Tt="deployment.environment.name",Et="deployment.name",wt="deployment.id",St="event.name",At="dash0.web.event.id",Ot="page.load.id",It="user_agent.original",Nt="user.id",Lt="user.name",_t="user.full_name",Ct="user.email",Rt="user.hash",xt="user.roles",kt="exception.message",Pt="exception.type",Dt="exception.stacktrace",jt="url.full",Mt={PAGE_VIEW:"browser.page_view",NAVIGATION_TIMING:"browser.navigation_timing",WEB_VITAL:"browser.web_vital",ERROR:"browser.error"},Ut={UNSPECIFIED:0,TRACE:1,DEBUG:5,INFO:9,WARN:13,ERROR:17,FATAL:21},Ft=0,Vt=1,Bt="pushState",Wt="replaceState",qt=["stringValue","boolValue","intValue","doubleValue","arrayValue","kvlistValue","bytesValue"];function Ht(t){if(null!=t){var e={};return Array.isArray(t)?e.arrayValue={values:t.map((function(t){return Ht(t)}))}:"string"==typeof t?e.stringValue=t:"number"==typeof t?e.doubleValue=t:"boolean"==typeof t?e.boolValue=t:!function(t){if(null==t||"object"!==P(t))return!1;var e=Object.keys(t);return 1===e.length&&qt.includes(e[0])}(t)?"object"===P(t)&&(e.kvlistValue={values:Object.entries(t).map((function(t){var e=R(t,2);return zt(e[0],e[1])}))}):e=t,e}}function zt(t,e){return{key:t,value:Ht(e)}}function Gt(t,e,n){e&&t.push(zt(e,n))}function Kt(t,e){var n=t.findIndex((function(t){return t.key===e}));-1!==n&&t.splice(n,1)}var Zt="traceparent",Yt=/^00-([a-f0-9]{32})-([a-f0-9]{16})-[0-9]{1,2}$/;function Qt(){var t,e,n=((null===(t=Array.from(null!==(e=null==f?void 0:f.getElementsByTagName("meta"))&&void 0!==e?e:[]).find((function(t){var e;return(null===(e=t.getAttribute("name"))||void 0===e?void 0:e.toLowerCase())===Zt})))||void 0===t?void 0:t.content.trim())||"").match(Yt)||function(){var t=p.getEntriesByType("navigation")[0];if(!t)return"";if(!t.serverTiming)return"";return function(t){var e,n=N(t);try{for(n.s();!(e=n.n()).done;){var r=e.value;if(r.name===Zt)return r.description.trim()}}catch(t){n.e(t)}finally{n.f()}return""}(t.serverTiming)}().match(Yt);if(n)return{traceId:n[1],spanId:n[2]}}function Xt(t,e,n){t.call(e,"traceparent","00-".concat(n.traceId,"-").concat(n.spanId,"-01"))}var $t=1;function Jt(){var t,e;return"".concat((t={ephemeralSession:!E},e=0,t.ephemeralSession&&(e|=$t),e.toString(16).padStart(2,"0"))).concat(b(7))}var te="d0_session",ee="#",ne=864e5,re=null;function ie(t,e){if(!E)return a("Storage API is not available and session tracking is therefore not supported."),void(re=Jt());t||(t=108e5),e||(e=216e5),t=Math.min(t,ne),e=Math.min(e,ne);try{var n=function(t){return E&&m?m.getItem(t):null}(te),r=function(t){if(!t)return null;var e=t.split(ee);if(e.length<3)return null;var n=e[0],r=parseInt(e[1],10),i=parseInt(e[2],10);if(!n||isNaN(r)||isNaN(i))return null;return{id:n,startTime:r,lastActivityTime:i}}(n);r&&!function(t,e,n){var r=j()-e;if(t.lastActivityTime<r)return!1;var i=j()-n;return t.startTime>=i}(r,t,e)&&(r=null),r?r.lastActivityTime=j():r={id:Jt(),startTime:j(),lastActivityTime:j()},function(t,e){E&&m&&m.setItem(t,e)}(te,function(t){return t.id+ee+t.startTime+ee+t.lastActivityTime}(r)),re=r.id}catch(t){i("Failed to record session information",t)}}var oe="d042",ae=1;function ue(t){var e=0;return t.withoutSession&&(e|=ae),e.toString(16).padStart(2,"0")}for(var se=new Uint32Array(256),ce=0;ce<256;ce++){for(var le=ce,fe=0;fe<8;fe++)le=1&le?3988292384^le>>>1:le>>>1;se[ce]=le>>>0}function de(t){var e=function(t){for(var e=new Uint8Array(t.length/2),n=0;n<t.length;n+=2)e[n/2]=parseInt(t.substring(n,n+2),16);for(var r=4294967295,i=0;i<e.length;i++){var o=e[i];r=r>>>8^se[255&(r^o)]}return(4294967295^r)>>>0}(t).toString(16).padStart(8,"0");return"".concat(e).concat(b(4))}function ve(t){var e=function(t){return t?"".concat(oe).concat(ue({withoutSession:!1})).concat(t).concat(b(5)):"".concat(oe).concat(ue({withoutSession:!0})).concat(b(13))}(re),n=de(e),r=[];return Gt(r,At,n),{traceId:e,spanId:n,name:t,kind:3,startTimeUnixNano:M(),attributes:r,events:[],links:[],status:{code:0}}}function pe(t,e,n){var r=t;return e&&(r.status=e),r.endTimeUnixNano=null!=n?String(Math.round(parseInt(r.startTimeUnixNano)+n)):M(),r}function he(t,e,n,r){var i=void 0,o=void 0;"string"==typeof n?i=n:Array.isArray(n)&&(o=n),t.events.push({name:e,timeUnixNano:null!=i?i:M(),attributes:null!=o?o:[]})}var me=null!=y&&"function"==typeof y.getItem&&"function"==typeof y.setItem;var ye="d0_tab",ge=null;function be(){if(me)try{var t=function(t){return me&&y?y.getItem(t):null}(ye);if(t)return void(ge=t);ge=b(8),function(t,e){me&&y&&y.setItem(t,e)}(ye,ge)}catch(t){i("Failed to record tab ID information",t)}else a("Storage API is not available and tab tracking is therefore not supported.")}function Te(t,e){var n,r,i,o,a;void 0===t.find((function(t){return t.key===At}))&&Gt(t,At,b(8));for(var u=0;u<nt.signalAttributes.length;u++)t.push(nt.signalAttributes[u]);!function(t,e){try{var n=$(e);n.username&&(n.username="REDACTED"),n.password&&(n.password="REDACTED"),Gt(t,jt,n.href),Gt(t,"url.path",n.pathname),Gt(t,"url.domain",n.hostname),Gt(t,"url.scheme",n.protocol.replace(":","")),n.hash&&Gt(t,"url.fragment",n.hash.replace("#","")),n.search&&Gt(t,"url.query",n.search.replace("?",""))}catch(n){Gt(t,jt,String(e))}}(t,null!==(n=null!==(r=null==e?void 0:e.url)&&void 0!==r?r:null==l?void 0:l.location.href)&&void 0!==n?n:Q),re&&Gt(t,"session.id",re),ge&&Gt(t,"browser.tab.id",ge),Gt(t,"browser.window.width",null!==(i=null==l?void 0:l.innerWidth)&&void 0!==i?i:Q),Gt(t,"browser.window.height",null!==(o=null==l?void 0:l.innerHeight)&&void 0!==o?o:Q);var s=null==d||null===(a=d.connection)||void 0===a?void 0:a.effectiveType;s&&Gt(t,"network.connection.subtype",s)}var Ee,we=0,Se=0,Ae={},Oe=!1;function Ie(){Oe=!0}function Ne(t,e){t&&Le("string"==typeof t?{message:t,opts:e}:{message:t.message,type:t.name,stack:t.stack,opts:e})}function Le(t){var e=t.message,n=t.type,r=t.stack,i=t.opts;if(e&&!(we>100)&&!function(t){return!t||rt(nt.ignoreErrorMessages,t)}(e)){Se>=20&&(Ae={},Se=0);var o=(e=String(e).substring(0,300))+(r=function(t){return String(t||"").split("\n").slice(0,30).join("\n")}(r))+(null==l?void 0:l.location.href),a=Ae[o];if(a)a.seenCount++;else{var u=[];Gt(u,St,Mt.ERROR),Gt(u,kt,e),n&&Gt(u,Pt,n),r&&Gt(u,Dt,r),null!=i&&i.componentStack&&Gt(u,"exception.component_stack",null==i?void 0:i.componentStack.substring(0,2048)),Te(u),a={seenCount:1,transmittedCount:0,log:{timeUnixNano:M(),attributes:u,severityNumber:Ut.ERROR,severityText:"ERROR",body:{stringValue:e}}},Ae[o]=a,Se++}!function(){if(Ee)return;Ee=setTimeout(_e,1e3)}()}}function _e(){for(var t in Ee&&(clearTimeout(Ee),Ee=null),Ae)if(c(Ae,t)){var e=Ae[t];e.seenCount>e.transmittedCount&&(mt(e.log),we++)}Ae={},Se=0}var Ce=-1,Re=function(t){addEventListener("pageshow",(function(e){e.persisted&&(Ce=e.timeStamp,t(e))}),!0)},xe=function(t,e,n,r){var i,o;return function(a){e.value>=0&&(a||r)&&(((o=e.value-(null!=i?i:0))||void 0===i)&&(i=e.value,e.delta=o,e.rating=function(t,e){return t>e[1]?"poor":t>e[0]?"needs-improvement":"good"}(e.value,n),t(e)))}},ke=function(t){requestAnimationFrame((function(){return requestAnimationFrame((function(){return t()}))}))},Pe=function(){var t=performance.getEntriesByType("navigation")[0];if(t&&t.responseStart>0&&t.responseStart<performance.now())return t},De=function(){var t,e=Pe();return null!==(t=null==e?void 0:e.activationStart)&&void 0!==t?t:0},je=function(t){var e=arguments.length>1&&void 0!==arguments[1]?arguments[1]:-1,n=Pe(),r="navigate";return Ce>=0?r="back-forward-cache":n&&(document.prerendering||De()>0?r="prerender":document.wasDiscarded?r="restore":n.type&&(r=n.type.replace(/_/g,"-"))),{name:t,value:e,rating:"good",delta:0,entries:[],id:"v5-".concat(Date.now(),"-").concat(Math.floor(8999999999999*Math.random())+1e12),navigationType:r}},Me=new WeakMap;function Ue(t,e){return Me.get(t)||Me.set(t,new e),Me.get(t)}var Fe,Ve=function(){return I((function t(){O(this,t),L(this,"t",void 0),L(this,"i",0),L(this,"o",[])}),[{key:"h",value:function(t){var e;if(!t.hadRecentInput){var n=this.o[0],r=this.o.at(-1);this.i&&n&&r&&t.startTime-r.startTime<1e3&&t.startTime-n.startTime<5e3?(this.i+=t.value,this.o.push(t)):(this.i=t.value,this.o=[t]),null===(e=this.t)||void 0===e||e.call(this,t)}}}])}(),Be=function(t,e){var n=arguments.length>2&&void 0!==arguments[2]?arguments[2]:{};try{if(PerformanceObserver.supportedEntryTypes.includes(t)){var r=new PerformanceObserver((function(t){Promise.resolve().then((function(){e(t.getEntries())}))}));return r.observe(function(t){for(var e=1;e<arguments.length;e++){var n=null!=arguments[e]?arguments[e]:{};e%2?_(Object(n),!0).forEach((function(e){L(t,e,n[e])})):Object.getOwnPropertyDescriptors?Object.defineProperties(t,Object.getOwnPropertyDescriptors(n)):_(Object(n)).forEach((function(e){Object.defineProperty(t,e,Object.getOwnPropertyDescriptor(n,e))}))}return t}({type:t,buffered:!0},n)),r}}catch(t){}},We=function(t){var e=!1;return function(){e||(t(),e=!0)}},qe=-1,He=function(){return"hidden"!==document.visibilityState||document.prerendering?1/0:0},ze=function(t){"hidden"===document.visibilityState&&qe>-1&&(qe="visibilitychange"===t.type?t.timeStamp:0,Ke())},Ge=function(){addEventListener("visibilitychange",ze,!0),addEventListener("prerenderingchange",ze,!0)},Ke=function(){removeEventListener("visibilitychange",ze,!0),removeEventListener("prerenderingchange",ze,!0)},Ze=function(){if(qe<0){var t,e=De(),n=document.prerendering||null===(t=globalThis.performance.getEntriesByType("visibility-state").filter((function(t){return"hidden"===t.name&&t.startTime>e}))[0])||void 0===t?void 0:t.startTime;qe=null!=n?n:He(),Ge(),Re((function(){setTimeout((function(){qe=He(),Ge()}))}))}return{get firstHiddenTime(){return qe}}},Ye=function(t){document.prerendering?addEventListener("prerenderingchange",(function(){return t()}),!0):t()},Qe=[1800,3e3],Xe=[.1,.25],$e=function(t){var e=arguments.length>1&&void 0!==arguments[1]?arguments[1]:{};!function(t){var e=arguments.length>1&&void 0!==arguments[1]?arguments[1]:{};Ye((function(){var n,r=Ze(),i=je("FCP"),o=Be("paint",(function(t){var e,a=N(t);try{for(a.s();!(e=a.n()).done;){var u=e.value;"first-contentful-paint"===u.name&&(o.disconnect(),u.startTime<r.firstHiddenTime&&(i.value=Math.max(u.startTime-De(),0),i.entries.push(u),n(!0)))}}catch(t){a.e(t)}finally{a.f()}}));o&&(n=xe(t,i,Qe,e.reportAllChanges),Re((function(r){i=je("FCP"),n=xe(t,i,Qe,e.reportAllChanges),ke((function(){i.value=performance.now()-r.timeStamp,n(!0)}))})))}))}(We((function(){var n,r=je("CLS",0),i=Ue(e,Ve),o=function(t){var e,o=N(t);try{for(o.s();!(e=o.n()).done;){var a=e.value;i.h(a)}}catch(t){o.e(t)}finally{o.f()}i.i>r.value&&(r.value=i.i,r.entries=i.o,n())},a=Be("layout-shift",o);a&&(n=xe(t,r,Xe,e.reportAllChanges),document.addEventListener("visibilitychange",(function(){"hidden"===document.visibilityState&&(o(a.takeRecords()),n(!0))})),Re((function(){i.i=0,r=je("CLS",0),n=xe(t,r,Xe,e.reportAllChanges),ke((function(){return n()}))})),setTimeout(n))})))},Je=0,tn=1/0,en=0,nn=function(t){var e,n=N(t);try{for(n.s();!(e=n.n()).done;){var r=e.value;r.interactionId&&(tn=Math.min(tn,r.interactionId),en=Math.max(en,r.interactionId),Je=en?(en-tn)/7+1:0)}}catch(t){n.e(t)}finally{n.f()}},rn=function(){var t;return Fe?Je:null!==(t=performance.interactionCount)&&void 0!==t?t:0},on=0,an=function(){return I((function t(){O(this,t),L(this,"u",[]),L(this,"l",new Map),L(this,"m",void 0),L(this,"v",void 0)}),[{key:"p",value:function(){on=rn(),this.u.length=0,this.l.clear()}},{key:"P",value:function(){var t=Math.min(this.u.length-1,Math.floor((rn()-on)/50));return this.u[t]}},{key:"h",value:function(t){var e;if(null!==(e=this.m)&&void 0!==e&&e.call(this,t),t.interactionId||"first-input"===t.entryType){var n=this.u.at(-1),r=this.l.get(t.interactionId);if(r||this.u.length<10||t.duration>n.T){var i;if(r?t.duration>r.T?(r.entries=[t],r.T=t.duration):t.duration===r.T&&t.startTime===r.entries[0].startTime&&r.entries.push(t):(r={id:t.interactionId,entries:[t],T:t.duration},this.l.set(r.id,r),this.u.push(r)),this.u.sort((function(t,e){return e.T-t.T})),this.u.length>10){var o,a=N(this.u.splice(10));try{for(a.s();!(o=a.n()).done;){var u=o.value;this.l.delete(u.id)}}catch(t){a.e(t)}finally{a.f()}}null===(i=this.v)||void 0===i||i.call(this,r)}}}}])}(),un=function(t){var e=globalThis.requestIdleCallback||setTimeout;"hidden"===document.visibilityState?t():(t=We(t),document.addEventListener("visibilitychange",t,{once:!0}),e((function(){t(),document.removeEventListener("visibilitychange",t)})))},sn=[200,500],cn=function(t){var e=arguments.length>1&&void 0!==arguments[1]?arguments[1]:{};globalThis.PerformanceEventTiming&&"interactionId"in PerformanceEventTiming.prototype&&Ye((function(){var n;"interactionCount"in performance||Fe||(Fe=Be("event",nn,{type:"event",buffered:!0,durationThreshold:0}));var r,i=je("INP"),o=Ue(e,an),a=function(t){un((function(){var e,n=N(t);try{for(n.s();!(e=n.n()).done;){var a=e.value;o.h(a)}}catch(t){n.e(t)}finally{n.f()}var u=o.P();u&&u.T!==i.value&&(i.value=u.T,i.entries=u.entries,r())}))},u=Be("event",a,{durationThreshold:null!==(n=e.durationThreshold)&&void 0!==n?n:40});r=xe(t,i,sn,e.reportAllChanges),u&&(u.observe({type:"first-input",buffered:!0}),document.addEventListener("visibilitychange",(function(){"hidden"===document.visibilityState&&(a(u.takeRecords()),r(!0))})),Re((function(){o.p(),i=je("INP"),r=xe(t,i,sn,e.reportAllChanges)})))}))},ln=function(){return I((function t(){O(this,t),L(this,"m",void 0)}),[{key:"h",value:function(t){var e;null===(e=this.m)||void 0===e||e.call(this,t)}}])}(),fn=[2500,4e3];function dn(){!function(t){var e=arguments.length>1&&void 0!==arguments[1]?arguments[1]:{};Ye((function(){var n,r=Ze(),i=je("LCP"),o=Ue(e,ln),a=function(t){e.reportAllChanges||(t=t.slice(-1));var a,u=N(t);try{for(u.s();!(a=u.n()).done;){var s=a.value;o.h(s),s.startTime<r.firstHiddenTime&&(i.value=Math.max(s.startTime-De(),0),i.entries=[s],n())}}catch(t){u.e(t)}finally{u.f()}},u=Be("largest-contentful-paint",a);if(u){n=xe(t,i,fn,e.reportAllChanges);for(var s=We((function(){a(u.takeRecords()),u.disconnect(),n(!0)})),c=0,l=["keydown","click","visibilitychange"];c<l.length;c++)addEventListener(l[c],(function(){return un(s)}),{capture:!0,once:!0});Re((function(r){i=je("LCP"),n=xe(t,i,fn,e.reportAllChanges),ke((function(){i.value=performance.now()-r.timeStamp,n(!0)}))}))}}))}(vn,{reportAllChanges:!0}),cn(vn,{reportAllChanges:!0}),$e(vn,{reportAllChanges:!0})}function vn(t){var e=[];Gt(e,St,Mt.WEB_VITAL);var n=[];Gt(n,"name",t.name),Gt(n,"value",X(t.value)),Gt(n,"delta",X(t.delta));var r={timeUnixNano:M(),attributes:e,severityNumber:Ut.INFO,severityText:"INFO",body:{kvlistValue:{values:n}}};Te(r.attributes),mt(r)}var pn="Unhandled promise rejection: ",hn="<unavailable because Promise wasn't rejected with an Error object>";function mn(t){null==t.reason?Ne({message:pn+"<no reason defined>",stack:hn}):"string"==typeof t.reason.message?Ne({message:pn+t.reason.message,stack:"string"==typeof t.reason.stack?t.reason.stack:hn}):"object"!==P(t.reason)&&Ne({message:pn+t.reason,stack:hn})}var yn="__dash0OriginalFunctions";function gn(t,e){for(var n=t[yn],r=0;r<n.length;r++){if(bn(n[r].valuesForEqualityCheck,e))return r}return-1}function bn(t,e){if(t.length!==e.length)return!1;for(var n=0;n<t.length;n++)if(t[n]!==e[n])return!1;return!0}function Tn(t,e,n,r,i){return function(t,e,n){if(!t)return e;var r=t[yn]=t[yn]||[],i=gn(t,n);return-1!==i?r[i].wrappedFunction:(r.push({wrappedFunction:e,valuesForEqualityCheck:n}),e)}(t,e,En(n,r,i))}function En(t,e,n){return[t,e,wn(n)]}function wn(t){return null!=t&&("object"===P(t)?Boolean(t.capture):Boolean(t))}function Sn(t,e,n,r,i){return function(t,e,n){var r=null==t?void 0:t[yn];if(null==r)return n;var i=gn(t,e);if(-1===i)return n;var o=r[i];return r.splice(i,1),o.wrappedFunction}(t,En(e,n,r),i)}function An(){nt.wrapEventHandlers&&function(t){if(!t||"function"!=typeof t.prototype.addEventListener||"function"!=typeof t.prototype.removeEventListener)return;var e=t.prototype.addEventListener,n=t.prototype.removeEventListener;t.prototype.addEventListener=function(t,n,r){if("function"!=typeof n)return e.apply(this,arguments);for(var i=new Array(arguments.length),o=0;o<arguments.length;o++)i[o]=arguments[o];return i[1]=function(){try{return n.apply(this,arguments)}catch(t){throw reportError(t),Ie(),t}},i[1]=Tn(this,i[1],t,n,r),e.apply(this,i)},t.prototype.removeEventListener=function(t,e,r){if("function"!=typeof e)return n.apply(this,arguments);for(var i=new Array(arguments.length),o=0;o<arguments.length;o++)i[o]=arguments[o];return i[1]=Sn(this,t,e,r,e),n.apply(this,i)}}(null==l?void 0:l.EventTarget)}function On(t){var e=null==l?void 0:l[t];"function"==typeof e&&(l[t]=function(t){for(var n=new Array(arguments.length),r=0;r<arguments.length;r++)n[r]=arguments[r];return n[0]=function(t){if("function"!=typeof t)return t;return function(){try{return t.apply(this,arguments)}catch(t){throw reportError(t),Ie(),t}}}(t),e.apply(this,n)})}function In(){!function(){if(l){var t=l.onerror;l.onerror=function(e,n,r,i,o){if(Oe)return Oe=!1,"function"==typeof t?t.apply(this,arguments):void 0;var a=o&&o.stack;return a||(a="at "+n+" "+r,null!=i&&(a+=":"+i)),Le({message:String(e),stack:a}),"function"==typeof t?t.apply(this,arguments):void 0}}}(),"function"==typeof(null==l?void 0:l.addEventListener)&&l.addEventListener("unhandledrejection",mn),An(),function(){if(nt.wrapTimers){if(B)return void i("We discovered a usage of Zone.js. In order to avoid any incompatibility issues timer wrapping is not going to be enabled.");On("setTimeout"),On("setInterval")}}()}var Nn=["GET","HEAD","POST","PUT","DELETE","CONNECT","OPTIONS","TRACE","PATCH"];function Ln(t){return Nn.includes(t)}function _n(t,e){var n=0!==e.startTime;Cn(t,G.FETCH_START,e,n),Cn(t,G.DOMAIN_LOOKUP_START,e,n),Cn(t,G.DOMAIN_LOOKUP_END,e,n),Cn(t,G.CONNECT_START,e,n),Cn(t,G.SECURE_CONNECTION_START,e,n),Cn(t,G.CONNECT_END,e,n),Cn(t,G.REQUEST_START,e,n),Cn(t,G.RESPONSE_START,e,n),Cn(t,G.RESPONSE_END,e,n)}function Cn(t,e,n){var r,i=!(arguments.length>3&&void 0!==arguments[3])||arguments[3];!(e in n)||"number"!=typeof n[e]||i&&0===n[e]||he(t,e,(r=n[e],String(Math.round(1e6*(r+F())))))}function Rn(t,e){var n=e.encodedBodySize;null!=n&&Gt(t.attributes,"http.response.body.size",n)}function xn(t){return function(){var e=A(C().mark((function e(n,r){var i,o,u,s,c,l,f,d,v,p,h,m,y,g;return C().wrap((function(e){for(;;)switch(e.prev=e.next){case 0:if(u=r?Object.assign({},r):r,s=null,null!==(i=u)&&void 0!==i&&i.body&&(s=u.body,u.body=void 0),c=new Request(n,u),s&&u&&(u.body=s),!ot(l=c.url)){e.next=9;break}return a("Not creating span for fetch call because the url is ignored, URL: ".concat(l)),e.abrupt("return",t(n instanceof Request?c:n,r));case 9:return f=null!==(o=c.method)&&void 0!==o?o:"GET",d=Ln(f),v=Ln(f.toUpperCase()),p=v?f.toUpperCase():"_OTHER",Te((h=ve("HTTP ".concat(p))).attributes,{url:l}),kn(n,r),Gt(h.attributes,"http.request.method",p),d||Gt(h.attributes,"http.request.method_original",f),(J(l)||rt(nt.propagateTraceHeadersCorsURLs,l))&&(null!==(m=u)&&void 0!==m&&m.headers?(u.headers=new Headers(u.headers),Xt(u.headers.append,u.headers,h)):n instanceof Request?Xt(c.headers.append,c.headers,h):(u||(u={}),u.headers=new Headers,Xt(u.headers.append,u.headers,h))),Pn(c.headers,h,(function(t){return e=t,"".concat("http.request.header",".").concat(e.toLowerCase());var e})),(y=Z({resourceMatcher:function(t){var e=t.initiatorType,n=t.name;return("fetch"===e||"xmlhttprequest"===e)&&n===$(l).href},maxWaitForResourceMillis:nt.maxWaitForResourceTimingsMillis,maxToleranceForResourceTimingsMillis:nt.maxToleranceForResourceTimingsMillis,onEnd:function(t){var e=t.duration,n=t.resource;n&&(_n(h,n),Rn(h,n)),yt(pe(h,void 0,1e6*e))}})).start(),e.prev=23,e.next=26,t(n instanceof Request?c:n,u);case 26:return g=e.sent,Dn(h,g),jn(g).then((function(){return y.end()})).catch((function(t){y.cancel(),Mn(h,t)})),e.abrupt("return",g);case 32:throw e.prev=32,e.t0=e.catch(23),y.cancel(),Mn(h,e.t0),e.t0;case 37:case"end":return e.stop()}}),e,null,[[23,32]])})));return function(t,n){return e.apply(this,arguments)}}()}function kn(t,e,n){try{return void 0}catch(n){a("failed to analyze request for GraphQL insights",n,t,e)}}function Pn(t,e,n){try{t.forEach((function(t,r){nt.headersToCapture.some((function(t){return t.test(r)}))&&Gt(e.attributes,n(r),t)}))}catch(t){a("unable to capture http headers due to CORS policy")}}function Dn(t,e){var n=e.status;!function(t,e,n){t.status={code:e,message:n}}(t,n>=200&&n<400?0:2),0===n&&Gt(t.attributes,"error.type",e.type),Gt(t.attributes,"http.response.status_code",String(n)),Pn(e.headers,t,(function(t){return e=t,"".concat("http.response.header",".").concat(e.toLowerCase());var e}))}function jn(t){return new Promise((function(e){var n=t.clone().body;if(!n)return e();var r=n.getReader(),i=function(){var t=A(C().mark((function t(){var n;return C().wrap((function(t){for(;;)switch(t.prev=t.next){case 0:return t.next=2,r.read();case 2:if(n=t.sent,!n.done){t.next=6;break}return t.abrupt("return",e());case 6:return t.abrupt("return",i());case 7:case"end":return t.stop()}}),t)})));return function(){return t.apply(this,arguments)}}();return i()}))}function Mn(t,e){!function(t,e){var n=[];"string"==typeof e?Gt(n,kt,e):e&&(e.code?Gt(n,Pt,e.code.toString()):e.name&&Gt(n,Pt,e.name),e.message&&Gt(n,kt,e.message),e.stack&&Gt(n,Dt,e.stack),he(t,"exception",n))}(t,e),yt(pe(t,function(t){return{code:2,message:t&&"object"===P(t)&&"message"in t?t.message:String(t)}}(e),void 0))}function Un(t,e,n,r){var i,o,a=function(t){var e,n,r;return t&&null!==(e=null===(n=(r=nt.pageViewInstrumentation).generateMetadata)||void 0===n?void 0:n.call(r,t))&&void 0!==e?e:{}}(e),u=[];Gt(u,St,Mt.PAGE_VIEW),a.attributes&&Object.entries(a.attributes).forEach((function(t){var e=R(t,2),n=e[0],r=e[1];return Gt(u,n,r)})),Te(u,{url:e});var s=[];Gt(s,"title",null!==(i=null!==(o=a.title)&&void 0!==o?o:null==f?void 0:f.title)&&void 0!==i?i:Q),null!=f&&f.referrer&&Gt(s,"referrer",f.referrer),Gt(s,"type",n?Vt:Ft),Gt(s,"change_state",r?Wt:Bt);var c={timeUnixNano:t,attributes:u,severityNumber:Ut.INFO,severityText:"INFO",body:{kvlistValue:{values:s}}},l=Qt();l&&(c.traceId=l.traceId,c.spanId=l.spanId),mt(c)}function Fn(){var t=null==l?void 0:l.performance.getEntriesByType("navigation")[0];if(t){var e=[];Gt(e,St,Mt.NAVIGATION_TIMING);var n=[];Gt(n,"name",t.name),Vn(n,t,"responseStatus"),Vn(n,t,"fetchStart"),Vn(n,t,"requestStart"),Vn(n,t,"responseStart"),Vn(n,t,"domInteractive"),Vn(n,t,"domContentLoadedEventEnd"),Vn(n,t,"domComplete"),Vn(n,t,"loadEventEnd"),Vn(n,t,"transferSize"),Vn(n,t,"encodedBodySize"),Vn(n,t,"decodedBodySize");var r={timeUnixNano:Bn(),attributes:e,severityNumber:Ut.INFO,severityText:"INFO",body:{kvlistValue:{values:n}}};Te(r.attributes);var i=Qt();i&&(r.traceId=i.traceId,r.spanId=i.spanId),mt(r)}else a("Navigation timings not available. Cannot emit navigation timing log")}function Vn(t,e,n){var r=e[n];"number"!=typeof r||isNaN(r)||Gt(t,n,Number.isInteger(r)?r:X(r))}function Bn(){return U(Math.round(F()))}var Wn={},qn=!1,Hn=!1;function zn(){Kn(null==l?void 0:l.location.href)}function Gn(t){Kn(t.newURL)}function Kn(t,e){var n;if(t)try{var r=new URL(t,null==l?void 0:l.location.href);((n=r).pathname!==Wn.path||Hn&&n.search!==Wn.search||qn&&n.hash!==Wn.hash)&&(Zn(r),Un(M(),r,!0,Boolean(e)))}catch(t){a("Failed to handle url change",t)}}function Zn(t){Wn.path=t.pathname,Wn.search=t.search,Wn.hash=t.hash}function Yn(){!function(){try{Un(Bn(),null!=l&&l.location.href?new URL(null==l?void 0:l.location.href):void 0)}catch(t){o("Failed to transmit initial page view event",t)}if("complete"===(null==f?void 0:f.readyState))return Fn();l&&T(l,"load",(function(){setTimeout(Fn,0)}))}(),function(){var t,e,n,r;if(l&&l.history){if(nt.pageViewInstrumentation.trackVirtualPageViews){Hn=null!==(t=null===(e=nt.pageViewInstrumentation.includeParts)||void 0===e?void 0:e.includes("SEARCH"))&&void 0!==t&&t,qn=null!==(n=null===(r=nt.pageViewInstrumentation.includeParts)||void 0===r?void 0:r.includes("HASH"))&&void 0!==n&&n,et(l.history,"replaceState",(function(t){return function(e,n,r){return Kn(r?String(r):void 0,!0),t.apply(this,[e,n,r])}})),et(l.history,"pushState",(function(t){return function(e,n,r){return Kn(r?String(r):void 0),t.apply(this,[e,n,r])}})),l.addEventListener("hashchange",Gn),l.addEventListener("popstate",zn);try{Zn(new URL(l.location.href))}catch(t){}}}else a("Browser does not support history API, skipping instrumentation")}()}var Qn=function(t){if("object"===P(t)&&null!==t){if("function"==typeof Object.getPrototypeOf){var e=Object.getPrototypeOf(t);return e===Object.prototype||null===e}return"[object Object]"===Object.prototype.toString.call(t)}return!1},Xn=function(){for(var t=arguments.length,e=new Array(t),n=0;n<t;n++)e[n]=arguments[n];return e.reduce((function(t,e){if(void 0===e)return t;if(Array.isArray(e))throw new TypeError("Arguments provided to ts-deepmerge must be objects, not arrays.");return Object.keys(e).forEach((function(n){["__proto__","constructor","prototype"].includes(n)||(Array.isArray(t[n])&&Array.isArray(e[n])?t[n]=Xn.options.mergeArrays?Xn.options.uniqueArrayItems?Array.from(new Set(t[n].concat(e[n]))):[].concat(x(t[n]),x(e[n])):e[n]:Qn(t[n])&&Qn(e[n])?t[n]=Xn(t[n],e[n]):!Qn(t[n])&&Qn(e[n])?t[n]=Xn(e[n],void 0):t[n]=void 0===e[n]?Xn.options.allowUndefinedOverrides?e[n]:t[n]:e[n])})),t}),{})},$n={allowUndefinedOverrides:!0,mergeArrays:!0,uniqueArrayItems:!0};Xn.options=$n,Xn.withOptions=function(t){Xn.options=Object.assign(Object.assign({},$n),t);for(var e=arguments.length,n=new Array(e>1?e-1:0),r=1;r<e;r++)n[r-1]=arguments[r];var i=Xn.apply(void 0,n);return Xn.options=$n,i};var Jn=!1;var tr={init:function(t){Jn?a("Dash0 SDK is being reinitialized, skipping ..."):null!=l?"function"==typeof h&&p&&p.getEntriesByType?(nt.endpoints=t.endpoint instanceof Array?t.endpoint:[t.endpoint],0!==nt.endpoints.length?(Object.assign(nt,Xn(nt,function(t,e){var n,r={},i=N(e);try{for(i.s();!(n=i.n()).done;){var o=n.value;o in t&&(r[o]=t[o])}}catch(t){i.e(t)}finally{i.f()}return r}(t,["ignoreUrls","ignoreErrorMessages","wrapEventHandlers","wrapTimers","propagateTraceHeadersCorsURLs","maxWaitForResourceTimingsMillis","maxToleranceForResourceTimingsMillis","headersToCapture","pageViewInstrumentation"]))),function(t){Gt(nt.resource.attributes,gt,t.serviceName),t.serviceVersion&&Gt(nt.resource.attributes,bt,t.serviceVersion);var e=function(t){if(t.environment)return t.environment;try{var e;return null===(e=process)||void 0===e||null===(e=e.env)||void 0===e?void 0:e.NEXT_PUBLIC_VERCEL_ENV}catch(t){return}}(t);e&&Gt(nt.resource.attributes,Tt,e);var n=function(t){if(t.deploymentName)return t.deploymentName;try{var e;return null===(e=process)||void 0===e||null===(e=e.env)||void 0===e?void 0:e.NEXT_PUBLIC_VERCEL_TARGET_ENV}catch(t){return}}(t);n&&Gt(nt.resource.attributes,Et,n);var r=function(t){if(t.deploymentId)return t.deploymentId;try{var e;return null===(e=process)||void 0===e||null===(e=e.env)||void 0===e?void 0:e.NEXT_PUBLIC_VERCEL_BRANCH_URL}catch(t){return}}(t);r&&Gt(nt.resource.attributes,wt,r)}(t),function(t){var e;Gt(nt.signalAttributes,Ot,b(16)),Gt(nt.signalAttributes,It,null!==(e=null==d?void 0:d.userAgent)&&void 0!==e?e:Q),t.additionalSignalAttributes&&Object.entries(t.additionalSignalAttributes).forEach((function(t){var e=R(t,2),n=e[0],r=e[1];Gt(nt.signalAttributes,n,r)}))}(t),be(),ie(t.sessionInactivityTimeoutMillis,t.sessionTerminationTimeoutMillis),Yn(),dn(),In(),l&&l.fetch&&l.Request?et(l,"fetch",xn):a("Browser does not support the Fetch API, skipping instrumentation"),Jn=!0):i("No telemetry endpoint configured. Aborting Dash0 Web SDK initialization process.")):a("Stopping Dash0 Web SDK initialization. This browser does not support the necessary APIs"):a("Looks like we are not running in a browser context. Stopping Dash0 Web SDK initialization.")},debug:function(){a("Dash0 Web SDK configuration state:",nt)},identify:function(t,e){Kt(nt.signalAttributes,Nt),null!=t&&Gt(nt.signalAttributes,Nt,t),Kt(nt.signalAttributes,Lt),null!=(null==e?void 0:e.name)&&Gt(nt.signalAttributes,Lt,e.name),Kt(nt.signalAttributes,_t),null!=(null==e?void 0:e.fullName)&&Gt(nt.signalAttributes,_t,e.fullName),Kt(nt.signalAttributes,Ct),null!=(null==e?void 0:e.email)&&Gt(nt.signalAttributes,Ct,e.email),Kt(nt.signalAttributes,Rt),null!=(null==e?void 0:e.hash)&&Gt(nt.signalAttributes,Rt,e.hash),Kt(nt.signalAttributes,xt),null!=(null==e?void 0:e.roles)&&Gt(nt.signalAttributes,xt,e.roles)},terminateSession:function(){if(E)try{!function(t){E&&m&&m.removeItem(t)}(te)}catch(t){r("Failed to terminate session",t)}},reportError:function(t,e){Ne(t,e)},addSignalAttribute:function(t,e){Gt(nt.signalAttributes,t,e)},removeSignalAttribute:function(t){Kt(nt.signalAttributes,t)},setActiveLogLevel:function(t){var r;n=null!==(r=e[t])&&void 0!==r?r:e.warn},sendEvent:function(t,e){var n;if(Object.values(Mt).includes(t))i("Unable to send custom event ".concat(t,". You are not allowed to use an internal event name while sending a custom event. Dropping event..."));else{var r=[];Te(r),Object.entries(null!==(n=null==e?void 0:e.attributes)&&void 0!==n?n:{}).forEach((function(t){var e=R(t,2),n=e[0],i=e[1];return Gt(r,n,i)})),Gt(r,St,t),null!=e&&e.title&&Gt(r,"dash0.web.event.title",e.title),mt({timeUnixNano:null!=(null==e?void 0:e.timestamp)?U(e.timestamp):M(),attributes:r,body:Ht(null==e?void 0:e.data),severityText:null==e?void 0:e.severity,severityNumber:null!=e&&e.severity?Ut[e.severity]:void 0})}}};function er(t){var e=t[0],n=tr[e];if(n){for(var r=[],o=1;o<t.length;o++)r.push(t[o]);n.apply(null,r)}else i("Unsupported Dash0 Web SDK api: ",t[0])}!function(){a("".concat("Initializing Dash0 Web SDK"," (via Script)"));var t=l.dash0;if(!t)return void i("global 'dash0' not found. Did you use the correct Dash0 Web SDK initializer?");if(!t._q)return void i("Dash0 Web SDK command queue not defined. Did you add the script tag multiple times to your website?");(function(t){for(var e=0,n=t.length;e<n;e++)er(t[e])})(t._q),l.dash0=function(){return er(arguments)}}()}();
1
+ !function(){"use strict";function t(){}var e={debug:0,info:1,warn:2,error:3},n=e.warn;var r=u("info"),i=u("warn"),o=u("error"),a=u("debug");function u(r){if("undefined"!=typeof console&&console[r]&&"function"==typeof console[r].apply){var i=e[r];return function(){i>=n&&console[r].apply(console,arguments)}}return t}var s=Object.prototype.hasOwnProperty;function c(t,e){return s.call(t,e)}var l="undefined"!=typeof window?window:void 0,f=null==l?void 0:l.document,d=null==l?void 0:l.navigator,v="undefined"!=typeof location?location:void 0,p=(null==l?void 0:l.performance)||(null==l?void 0:l.webkitPerformance)||(null==l?void 0:l.msPerformance)||(null==l?void 0:l.mozPerformance);null==l||l.encodeURIComponent;var h=null==l?void 0:l.fetch,m=function(){try{var t;return null!==(t=null==l?void 0:l.localStorage)&&void 0!==t?t:null}catch(t){return null}}(),y=function(){try{var t;return null!==(t=null==l?void 0:l.sessionStorage)&&void 0!==t?t:null}catch(t){return null}}(),g=Array(32);function b(t){for(var e=0;e<2*t;e++)g[e]=Math.floor(16*Math.random())+48,g[e]>=58&&(g[e]+=39);return String.fromCharCode.apply(null,g.slice(0,2*t))}function T(t,e,n){t.addEventListener?t.addEventListener(e,n,!1):t.attachEvent&&t.attachEvent("on"+e,n)}var E=null!=m&&"function"==typeof m.getItem&&"function"==typeof m.setItem;function w(t,e){(null==e||e>t.length)&&(e=t.length);for(var n=0,r=Array(e);n<e;n++)r[n]=t[n];return r}function S(t,e,n,r,i,o,a){try{var u=t[o](a),s=u.value}catch(t){return void n(t)}u.done?e(s):Promise.resolve(s).then(r,i)}function A(t){return function(){var e=this,n=arguments;return new Promise((function(r,i){var o=t.apply(e,n);function a(t){S(o,r,i,a,u,"next",t)}function u(t){S(o,r,i,a,u,"throw",t)}a(void 0)}))}}function O(t,e){if(!(t instanceof e))throw new TypeError("Cannot call a class as a function")}function I(t,e,n){return e&&function(t,e){for(var n=0;n<e.length;n++){var r=e[n];r.enumerable=r.enumerable||!1,r.configurable=!0,"value"in r&&(r.writable=!0),Object.defineProperty(t,k(r.key),r)}}(t.prototype,e),Object.defineProperty(t,"prototype",{writable:!1}),t}function N(t,e){var n="undefined"!=typeof Symbol&&t[Symbol.iterator]||t["@@iterator"];if(!n){if(Array.isArray(t)||(n=D(t))||e){n&&(t=n);var r=0,i=function(){};return{s:i,n:function(){return r>=t.length?{done:!0}:{done:!1,value:t[r++]}},e:function(t){throw t},f:i}}throw new TypeError("Invalid attempt to iterate non-iterable instance.\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method.")}var o,a=!0,u=!1;return{s:function(){n=n.call(t)},n:function(){var t=n.next();return a=t.done,t},e:function(t){u=!0,o=t},f:function(){try{a||null==n.return||n.return()}finally{if(u)throw o}}}}function L(t,e,n){return(e=k(e))in t?Object.defineProperty(t,e,{value:n,enumerable:!0,configurable:!0,writable:!0}):t[e]=n,t}function _(t,e){var n=Object.keys(t);if(Object.getOwnPropertySymbols){var r=Object.getOwnPropertySymbols(t);e&&(r=r.filter((function(e){return Object.getOwnPropertyDescriptor(t,e).enumerable}))),n.push.apply(n,r)}return n}function C(){C=function(){return e};var t,e={},n=Object.prototype,r=n.hasOwnProperty,i=Object.defineProperty||function(t,e,n){t[e]=n.value},o="function"==typeof Symbol?Symbol:{},a=o.iterator||"@@iterator",u=o.asyncIterator||"@@asyncIterator",s=o.toStringTag||"@@toStringTag";function c(t,e,n){return Object.defineProperty(t,e,{value:n,enumerable:!0,configurable:!0,writable:!0}),t[e]}try{c({},"")}catch(t){c=function(t,e,n){return t[e]=n}}function l(t,e,n,r){var o=e&&e.prototype instanceof y?e:y,a=Object.create(o.prototype),u=new R(r||[]);return i(a,"_invoke",{value:I(t,n,u)}),a}function f(t,e,n){try{return{type:"normal",arg:t.call(e,n)}}catch(t){return{type:"throw",arg:t}}}e.wrap=l;var d="suspendedStart",v="suspendedYield",p="executing",h="completed",m={};function y(){}function g(){}function b(){}var T={};c(T,a,(function(){return this}));var E=Object.getPrototypeOf,w=E&&E(E(x([])));w&&w!==n&&r.call(w,a)&&(T=w);var S=b.prototype=y.prototype=Object.create(T);function A(t){["next","throw","return"].forEach((function(e){c(t,e,(function(t){return this._invoke(e,t)}))}))}function O(t,e){function n(i,o,a,u){var s=f(t[i],t,o);if("throw"!==s.type){var c=s.arg,l=c.value;return l&&"object"==typeof l&&r.call(l,"__await")?e.resolve(l.__await).then((function(t){n("next",t,a,u)}),(function(t){n("throw",t,a,u)})):e.resolve(l).then((function(t){c.value=t,a(c)}),(function(t){return n("throw",t,a,u)}))}u(s.arg)}var o;i(this,"_invoke",{value:function(t,r){function i(){return new e((function(e,i){n(t,r,e,i)}))}return o=o?o.then(i,i):i()}})}function I(e,n,r){var i=d;return function(o,a){if(i===p)throw Error("Generator is already running");if(i===h){if("throw"===o)throw a;return{value:t,done:!0}}for(r.method=o,r.arg=a;;){var u=r.delegate;if(u){var s=N(u,r);if(s){if(s===m)continue;return s}}if("next"===r.method)r.sent=r._sent=r.arg;else if("throw"===r.method){if(i===d)throw i=h,r.arg;r.dispatchException(r.arg)}else"return"===r.method&&r.abrupt("return",r.arg);i=p;var c=f(e,n,r);if("normal"===c.type){if(i=r.done?h:v,c.arg===m)continue;return{value:c.arg,done:r.done}}"throw"===c.type&&(i=h,r.method="throw",r.arg=c.arg)}}}function N(e,n){var r=n.method,i=e.iterator[r];if(i===t)return n.delegate=null,"throw"===r&&e.iterator.return&&(n.method="return",n.arg=t,N(e,n),"throw"===n.method)||"return"!==r&&(n.method="throw",n.arg=new TypeError("The iterator does not provide a '"+r+"' method")),m;var o=f(i,e.iterator,n.arg);if("throw"===o.type)return n.method="throw",n.arg=o.arg,n.delegate=null,m;var a=o.arg;return a?a.done?(n[e.resultName]=a.value,n.next=e.nextLoc,"return"!==n.method&&(n.method="next",n.arg=t),n.delegate=null,m):a:(n.method="throw",n.arg=new TypeError("iterator result is not an object"),n.delegate=null,m)}function L(t){var e={tryLoc:t[0]};1 in t&&(e.catchLoc=t[1]),2 in t&&(e.finallyLoc=t[2],e.afterLoc=t[3]),this.tryEntries.push(e)}function _(t){var e=t.completion||{};e.type="normal",delete e.arg,t.completion=e}function R(t){this.tryEntries=[{tryLoc:"root"}],t.forEach(L,this),this.reset(!0)}function x(e){if(e||""===e){var n=e[a];if(n)return n.call(e);if("function"==typeof e.next)return e;if(!isNaN(e.length)){var i=-1,o=function n(){for(;++i<e.length;)if(r.call(e,i))return n.value=e[i],n.done=!1,n;return n.value=t,n.done=!0,n};return o.next=o}}throw new TypeError(typeof e+" is not iterable")}return g.prototype=b,i(S,"constructor",{value:b,configurable:!0}),i(b,"constructor",{value:g,configurable:!0}),g.displayName=c(b,s,"GeneratorFunction"),e.isGeneratorFunction=function(t){var e="function"==typeof t&&t.constructor;return!!e&&(e===g||"GeneratorFunction"===(e.displayName||e.name))},e.mark=function(t){return Object.setPrototypeOf?Object.setPrototypeOf(t,b):(t.__proto__=b,c(t,s,"GeneratorFunction")),t.prototype=Object.create(S),t},e.awrap=function(t){return{__await:t}},A(O.prototype),c(O.prototype,u,(function(){return this})),e.AsyncIterator=O,e.async=function(t,n,r,i,o){void 0===o&&(o=Promise);var a=new O(l(t,n,r,i),o);return e.isGeneratorFunction(n)?a:a.next().then((function(t){return t.done?t.value:a.next()}))},A(S),c(S,s,"Generator"),c(S,a,(function(){return this})),c(S,"toString",(function(){return"[object Generator]"})),e.keys=function(t){var e=Object(t),n=[];for(var r in e)n.push(r);return n.reverse(),function t(){for(;n.length;){var r=n.pop();if(r in e)return t.value=r,t.done=!1,t}return t.done=!0,t}},e.values=x,R.prototype={constructor:R,reset:function(e){if(this.prev=0,this.next=0,this.sent=this._sent=t,this.done=!1,this.delegate=null,this.method="next",this.arg=t,this.tryEntries.forEach(_),!e)for(var n in this)"t"===n.charAt(0)&&r.call(this,n)&&!isNaN(+n.slice(1))&&(this[n]=t)},stop:function(){this.done=!0;var t=this.tryEntries[0].completion;if("throw"===t.type)throw t.arg;return this.rval},dispatchException:function(e){if(this.done)throw e;var n=this;function i(r,i){return u.type="throw",u.arg=e,n.next=r,i&&(n.method="next",n.arg=t),!!i}for(var o=this.tryEntries.length-1;o>=0;--o){var a=this.tryEntries[o],u=a.completion;if("root"===a.tryLoc)return i("end");if(a.tryLoc<=this.prev){var s=r.call(a,"catchLoc"),c=r.call(a,"finallyLoc");if(s&&c){if(this.prev<a.catchLoc)return i(a.catchLoc,!0);if(this.prev<a.finallyLoc)return i(a.finallyLoc)}else if(s){if(this.prev<a.catchLoc)return i(a.catchLoc,!0)}else{if(!c)throw Error("try statement without catch or finally");if(this.prev<a.finallyLoc)return i(a.finallyLoc)}}}},abrupt:function(t,e){for(var n=this.tryEntries.length-1;n>=0;--n){var i=this.tryEntries[n];if(i.tryLoc<=this.prev&&r.call(i,"finallyLoc")&&this.prev<i.finallyLoc){var o=i;break}}o&&("break"===t||"continue"===t)&&o.tryLoc<=e&&e<=o.finallyLoc&&(o=null);var a=o?o.completion:{};return a.type=t,a.arg=e,o?(this.method="next",this.next=o.finallyLoc,m):this.complete(a)},complete:function(t,e){if("throw"===t.type)throw t.arg;return"break"===t.type||"continue"===t.type?this.next=t.arg:"return"===t.type?(this.rval=this.arg=t.arg,this.method="return",this.next="end"):"normal"===t.type&&e&&(this.next=e),m},finish:function(t){for(var e=this.tryEntries.length-1;e>=0;--e){var n=this.tryEntries[e];if(n.finallyLoc===t)return this.complete(n.completion,n.afterLoc),_(n),m}},catch:function(t){for(var e=this.tryEntries.length-1;e>=0;--e){var n=this.tryEntries[e];if(n.tryLoc===t){var r=n.completion;if("throw"===r.type){var i=r.arg;_(n)}return i}}throw Error("illegal catch attempt")},delegateYield:function(e,n,r){return this.delegate={iterator:x(e),resultName:n,nextLoc:r},"next"===this.method&&(this.arg=t),m}},e}function R(t,e){return function(t){if(Array.isArray(t))return t}(t)||function(t,e){var n=null==t?null:"undefined"!=typeof Symbol&&t[Symbol.iterator]||t["@@iterator"];if(null!=n){var r,i,o,a,u=[],s=!0,c=!1;try{if(o=(n=n.call(t)).next,0===e);else for(;!(s=(r=o.call(n)).done)&&(u.push(r.value),u.length!==e);s=!0);}catch(t){c=!0,i=t}finally{try{if(!s&&null!=n.return&&(a=n.return(),Object(a)!==a))return}finally{if(c)throw i}}return u}}(t,e)||D(t,e)||function(){throw new TypeError("Invalid attempt to destructure non-iterable instance.\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method.")}()}function x(t){return function(t){if(Array.isArray(t))return w(t)}(t)||function(t){if("undefined"!=typeof Symbol&&null!=t[Symbol.iterator]||null!=t["@@iterator"])return Array.from(t)}(t)||D(t)||function(){throw new TypeError("Invalid attempt to spread non-iterable instance.\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method.")}()}function k(t){var e=function(t,e){if("object"!=typeof t||!t)return t;var n=t[Symbol.toPrimitive];if(void 0!==n){var r=n.call(t,e);if("object"!=typeof r)return r;throw new TypeError("@@toPrimitive must return a primitive value.")}return("string"===e?String:Number)(t)}(t,"string");return"symbol"==typeof e?e:e+""}function P(t){return P="function"==typeof Symbol&&"symbol"==typeof Symbol.iterator?function(t){return typeof t}:function(t){return t&&"function"==typeof Symbol&&t.constructor===Symbol&&t!==Symbol.prototype?"symbol":typeof t},P(t)}function D(t,e){if(t){if("string"==typeof t)return w(t,e);var n={}.toString.call(t).slice(8,-1);return"Object"===n&&t.constructor&&(n=t.constructor.name),"Map"===n||"Set"===n?Array.from(t):"Arguments"===n||/^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(n)?w(t,e):void 0}}function j(){return(new Date).getTime()}function M(){var t=F();return t?String(1e6*(p.now()+t)):U(new Date)}function U(t){return"object"===P(t)?U(t.getTime()):String(t)+"000000"}function F(){var t,e=null==p?void 0:p.timeOrigin;"number"!=typeof e&&(e=null==p||null===(t=p.timing)||void 0===t?void 0:t.fetchStart);return e}var V={setTimeout:null==l?void 0:l.setTimeout,clearTimeout:null==l?void 0:l.clearTimeout,setInterval:null==l?void 0:l.setInterval,clearInterval:null==l?void 0:l.clearInterval},B=null!=l&&null!=l.Zone&&null!=l.Zone.root&&"function"==typeof l.Zone.root.run;function W(){for(var t=arguments.length,e=new Array(t),n=0;n<t;n++)e[n]=arguments[n];return H.apply("setTimeout",arguments)}function q(){for(var t=arguments.length,e=new Array(t),n=0;n<t;n++)e[n]=arguments[n];return H.apply("setInterval",arguments)}function H(){var t,e=this;if(B)try{var n=Array.prototype.slice.apply(arguments);return l.Zone.root.run(V[e],l,n)}catch(t){i("Failed to execute %s inside of zone (via Zone.js). Falling back to execution inside currently active zone.",e,t)}return null===(t=V[e])||void 0===t?void 0:t.apply(l,arguments)}B&&a("Discovered Zone.js globals. Will attempt to register all timers inside the root Zone.");p&&p.getEntriesByType;var z=p&&"function"==typeof l.PerformanceObserver&&"function"==typeof p.now,G=Object.freeze({CONNECT_END:"connectEnd",CONNECT_START:"connectStart",DECODED_BODY_SIZE:"decodedBodySize",DOM_COMPLETE:"domComplete",DOM_CONTENT_LOADED_EVENT_END:"domContentLoadedEventEnd",DOM_CONTENT_LOADED_EVENT_START:"domContentLoadedEventStart",DOM_INTERACTIVE:"domInteractive",DOMAIN_LOOKUP_END:"domainLookupEnd",DOMAIN_LOOKUP_START:"domainLookupStart",ENCODED_BODY_SIZE:"encodedBodySize",FETCH_START:"fetchStart",LOAD_EVENT_END:"loadEventEnd",LOAD_EVENT_START:"loadEventStart",NAVIGATION_START:"navigationStart",REDIRECT_END:"redirectEnd",REDIRECT_START:"redirectStart",REQUEST_START:"requestStart",RESPONSE_END:"responseEnd",RESPONSE_START:"responseStart",SECURE_CONNECTION_START:"secureConnectionStart",START_TIME:"startTime",UNLOAD_EVENT_END:"unloadEventEnd",UNLOAD_EVENT_START:"unloadEventStart"}),K=new WeakSet;function Z(e){if(!z)return function(e){var n=0;return{start:function(){n=j()},end:function(){return e({duration:j()-n})},cancel:t}}(e.onEnd);var n,r,i,o,a,u=[];return{start:function(){n=p.now();try{var t,e=null==l?void 0:l.PerformanceObserver;if(e)null===(t=i=new e(c))||void 0===t||t.observe({type:"resource"})}catch(t){}a=W(v,6e5)},end:function(){if(r=p.now(),h(),!Y())return s();W((function(){return s()}),Math.min(300,e.maxWaitForResourceMillis)),T(f,"visibilitychange",d),o=W(s,e.maxWaitForResourceMillis)},cancel:v};function s(){v();var t=function(){if(!u.length)return;var t,i,o=u.filter((function(t){return t.responseEnd<=r+e.maxToleranceForResourceTimingsMillis&&!K.has(t)}));if(!o.length)return;1===o.length&&(t=o[0]);if(!t){var a,s=N(o);try{for(s.s();!(a=s.n()).done;){var c=a.value,l=Math.abs(r-n-c.duration)+Math.abs(c.responseEnd-r);(void 0===i||l<i)&&(i=l,t=c)}}catch(t){s.e(t)}finally{s.f()}}if(!t)return;return K.add(t),t}();null!=t&&t.duration&&t.duration<864e5?e.onEnd({resource:t,duration:t.duration}):e.onEnd({resource:t,duration:r-n})}function c(t){t.getEntriesByType("resource").filter((function(t){var r=t;return r.startTime>=n&&e.resourceMatcher(r)})).forEach((function(t){return u.push(t)}))}function d(){Y()||s()}function v(){!function(){if(i){try{var t;null===(t=i)||void 0===t||t.disconnect()}catch(t){}i=void 0}}(),o&&(clearTimeout(o),o=void 0),h(),function(){if(!f)return;t=f,e="visibilitychange",n=d,t.removeEventListener?t.removeEventListener(e,n,!1):t.detachEvent&&t.detachEvent("on"+e,n);var t,e,n}()}function h(){a&&(clearTimeout(a),a=void 0)}}function Y(){return"visible"===(null==f?void 0:f.visibilityState)||"prerender"===(null==f?void 0:f.visibilityState)}var Q="undefined";function X(t){return Math.round(100*t)/100}function $(t){var e;return"string"!=typeof t?t:new URL(t,null!==(e=null==f?void 0:f.baseURI)&&void 0!==e?e:null==v?void 0:v.href)}function J(t){try{return $(t).origin===("undefined"!=typeof location?location.origin:void 0)}catch(t){return!1}}var tt=Symbol.for("INSTRUMENTED_BY_DASH0");function et(t,e,n){var r=t[e];r?(!0===r[tt]&&a("".concat(String(e)," has already been instrumented, skipping")),function(t){t[tt]=!0}(r),t[e]=n(r)):a("".concat(String(e)," is not defined, unable to instrument"))}var nt={endpoints:[],resource:{attributes:[]},scope:{name:"dash0-web-sdk",version:"0.13.5",attributes:[]},signalAttributes:[],ignoreUrls:[],ignoreErrorMessages:[],wrapEventHandlers:!0,wrapTimers:!0,propagateTraceHeadersCorsURLs:[],maxWaitForResourceTimingsMillis:1e4,maxToleranceForResourceTimingsMillis:50,headersToCapture:[],pageViewInstrumentation:{trackVirtualPageViews:!0,includeParts:[]}};function rt(t,e){for(var n=0,r=t.length;n<r;n++)if(t[n].test(e))return!0;return!1}var it="data:";function ot(t){return!t||(!(t=String(t))||(null==t.substring||t.substring(0,5).toLowerCase()===it||(!!function(t){for(var e=t.toLowerCase(),n=0,r=nt.endpoints.length;n<r;n++){var i=nt.endpoints[n];if(e.startsWith(i.url))return!0}return!1}(t)||rt(nt.ignoreUrls,t))))}var at=!1;function ut(t){var e,n,r=[];return n=i,at&&n(),f&&l&&(T(f,"visibilitychange",(function(){"visible"!==f.visibilityState&&n()})),T(l,"pagehide",(function(){at=!0,n()})),T(l,"beforeunload",(function(){at=!0,n()}))),{send:function(n){"visible"===(null==f?void 0:f.visibilityState)?(r.push(n),r.length>=15?i():null==e&&(e=W(i,1e3))):t([n])}};function i(){null!=e&&(clearTimeout(e),e=null),r.length>0&&(t(r.slice()),r.length=0)}}function st(t,e){return ct.apply(this,arguments)}function ct(){return ct=A(C().mark((function e(n,r){var o,u,s,c;return C().wrap((function(e){for(;;)switch(e.prev=e.next){case 0:if(a("Transmitting telemetry to endpoints",r),o=JSON.stringify(r),u=o,s=o.length,c=!1,"undefined"==typeof CompressionStream){e.next=11;break}return e.next=8,lt(o);case 8:u=e.sent,s=u.byteLength,c=!0;case 11:return e.next=13,Promise.all(nt.endpoints.map(function(){var e=A(C().mark((function e(r){var o,a,l;return C().wrap((function(e){for(;;)switch(e.prev=e.next){case 0:if(e.prev=0,(o=new URL(r.url)).pathname=o.pathname+(o.pathname.endsWith("/")?n.substring(1):n),a={"Content-Type":"application/json",Authorization:"Bearer ".concat(r.authToken)},r.dataset&&(a["Dash0-Dataset"]=r.dataset),c&&(a["Content-Encoding"]="gzip"),h){e.next=9;break}return i("Unable to send telemetry, fetch is not defined"),e.abrupt("return");case 9:return e.next=11,h(o,{method:"POST",headers:a,body:u,keepalive:s<=6e4});case 11:(l=e.sent).text().catch(t),l.ok||i("Failed to send telemetry to ".concat(o,": ").concat(l.status," ").concat(l.statusText)),e.next=19;break;case 16:e.prev=16,e.t0=e.catch(0),i("Error sending telemetry to ".concat(r.url).concat(n,":"),e.t0);case 19:case"end":return e.stop()}}),e,null,[[0,16]])})));return function(t){return e.apply(this,arguments)}}()));case 13:case"end":return e.stop()}}),e)}))),ct.apply(this,arguments)}function lt(t){return ft.apply(this,arguments)}function ft(){return(ft=A(C().mark((function t(e){var n,r,i;return C().wrap((function(t){for(;;)switch(t.prev=t.next){case 0:return n=new Blob([e]),r=n.stream(),i=r.pipeThrough(new CompressionStream("gzip")),t.abrupt("return",new Response(i).arrayBuffer());case 4:case"end":return t.stop()}}),t)})))).apply(this,arguments)}var dt,vt=ut((function(t){st("/v1/logs",{resourceLogs:[{resource:nt.resource,scopeLogs:[{scope:nt.scope,logRecords:t}]}]}).catch((function(t){o("Failed to transmit logs",t)}))})),pt=ut((function(t){st("/v1/traces",{resourceSpans:[{resource:nt.resource,scopeSpans:[{scope:nt.scope,spans:t}]}]}).catch((function(t){o("Failed to transmit spans",t)}))}));function ht(){var t,e,n,r,i,o,a;return dt||(e=(t={maxCalls:8096,maxCallsPerTenMinutes:4096,maxCallsPerTenSeconds:128}).maxCalls,n=t.maxCallsPerTenMinutes,r=t.maxCallsPerTenSeconds,i=0,o=0,a=0,q((function(){o=0}),6e5),q((function(){a=0}),1e4),dt=function(){return++i>e||++o>n||++a>r}),dt()}function mt(t){ht()?a("Transport rate limit. Will not send item.",t):vt.send(t)}function yt(t){ht()?a("Transport rate limit. Will not send item.",t):pt.send(t)}var gt="service.name",bt="service.version",Tt="deployment.environment.name",Et="deployment.name",wt="deployment.id",St="event.name",At="dash0.web.event.id",Ot="page.load.id",It="user_agent.original",Nt="user.id",Lt="user.name",_t="user.full_name",Ct="user.email",Rt="user.hash",xt="user.roles",kt="exception.message",Pt="exception.type",Dt="exception.stacktrace",jt="url.full",Mt={PAGE_VIEW:"browser.page_view",NAVIGATION_TIMING:"browser.navigation_timing",WEB_VITAL:"browser.web_vital",ERROR:"browser.error"},Ut={UNSPECIFIED:0,TRACE:1,DEBUG:5,INFO:9,WARN:13,ERROR:17,FATAL:21},Ft=0,Vt=1,Bt="pushState",Wt="replaceState",qt=["stringValue","boolValue","intValue","doubleValue","arrayValue","kvlistValue","bytesValue"];function Ht(t){if(null!=t){var e={};return Array.isArray(t)?e.arrayValue={values:t.map((function(t){return Ht(t)}))}:"string"==typeof t?e.stringValue=t:"number"==typeof t?e.doubleValue=t:"boolean"==typeof t?e.boolValue=t:!function(t){if(null==t||"object"!==P(t))return!1;var e=Object.keys(t);return 1===e.length&&qt.includes(e[0])}(t)?"object"===P(t)&&(e.kvlistValue={values:Object.entries(t).map((function(t){var e=R(t,2);return zt(e[0],e[1])}))}):e=t,e}}function zt(t,e){return{key:t,value:Ht(e)}}function Gt(t,e,n){e&&t.push(zt(e,n))}function Kt(t,e){var n=t.findIndex((function(t){return t.key===e}));-1!==n&&t.splice(n,1)}var Zt="traceparent",Yt=/^00-([a-f0-9]{32})-([a-f0-9]{16})-[0-9]{1,2}$/;function Qt(){var t,e,n=((null===(t=Array.from(null!==(e=null==f?void 0:f.getElementsByTagName("meta"))&&void 0!==e?e:[]).find((function(t){var e;return(null===(e=t.getAttribute("name"))||void 0===e?void 0:e.toLowerCase())===Zt})))||void 0===t?void 0:t.content.trim())||"").match(Yt)||function(){var t=p.getEntriesByType("navigation")[0];if(!t)return"";if(!t.serverTiming)return"";return function(t){var e,n=N(t);try{for(n.s();!(e=n.n()).done;){var r=e.value;if(r.name===Zt)return r.description.trim()}}catch(t){n.e(t)}finally{n.f()}return""}(t.serverTiming)}().match(Yt);if(n)return{traceId:n[1],spanId:n[2]}}function Xt(t,e,n){t.call(e,"traceparent","00-".concat(n.traceId,"-").concat(n.spanId,"-01"))}var $t=1;function Jt(){var t,e;return"".concat((t={ephemeralSession:!E},e=0,t.ephemeralSession&&(e|=$t),e.toString(16).padStart(2,"0"))).concat(b(7))}var te="d0_session",ee="#",ne=864e5,re=null;function ie(t,e){if(!E)return a("Storage API is not available and session tracking is therefore not supported."),void(re=Jt());t||(t=108e5),e||(e=216e5),t=Math.min(t,ne),e=Math.min(e,ne);try{var n=function(t){return E&&m?m.getItem(t):null}(te),r=function(t){if(!t)return null;var e=t.split(ee);if(e.length<3)return null;var n=e[0],r=parseInt(e[1],10),i=parseInt(e[2],10);if(!n||isNaN(r)||isNaN(i))return null;return{id:n,startTime:r,lastActivityTime:i}}(n);r&&!function(t,e,n){var r=j()-e;if(t.lastActivityTime<r)return!1;var i=j()-n;return t.startTime>=i}(r,t,e)&&(r=null),r?r.lastActivityTime=j():r={id:Jt(),startTime:j(),lastActivityTime:j()},function(t,e){E&&m&&m.setItem(t,e)}(te,function(t){return t.id+ee+t.startTime+ee+t.lastActivityTime}(r)),re=r.id}catch(t){i("Failed to record session information",t)}}var oe="d042",ae=1;function ue(t){var e=0;return t.withoutSession&&(e|=ae),e.toString(16).padStart(2,"0")}for(var se=new Uint32Array(256),ce=0;ce<256;ce++){for(var le=ce,fe=0;fe<8;fe++)le=1&le?3988292384^le>>>1:le>>>1;se[ce]=le>>>0}function de(t){var e=function(t){for(var e=new Uint8Array(t.length/2),n=0;n<t.length;n+=2)e[n/2]=parseInt(t.substring(n,n+2),16);for(var r=4294967295,i=0;i<e.length;i++){var o=e[i];r=r>>>8^se[255&(r^o)]}return(4294967295^r)>>>0}(t).toString(16).padStart(8,"0");return"".concat(e).concat(b(4))}function ve(t){var e=function(t){return t?"".concat(oe).concat(ue({withoutSession:!1})).concat(t).concat(b(5)):"".concat(oe).concat(ue({withoutSession:!0})).concat(b(13))}(re),n=de(e),r=[];return Gt(r,At,n),{traceId:e,spanId:n,name:t,kind:3,startTimeUnixNano:M(),attributes:r,events:[],links:[],status:{code:0}}}function pe(t,e,n){var r=t;return e&&(r.status=e),r.endTimeUnixNano=null!=n?String(Math.round(parseInt(r.startTimeUnixNano)+n)):M(),r}function he(t,e,n,r){var i=void 0,o=void 0;"string"==typeof n?i=n:Array.isArray(n)&&(o=n),t.events.push({name:e,timeUnixNano:null!=i?i:M(),attributes:null!=o?o:[]})}function me(t,e,n){var r=function(t){return t?Array.isArray(t)?function(e){return[].concat(x(t),[e]).join(".")}:function(e){return"".concat(t,".").concat(e)}:function(t){return t}}(n);try{var i=$(e);i.username&&(i.username="REDACTED"),i.password&&(i.password="REDACTED"),Gt(t,r(jt),i.href),Gt(t,r("url.path"),i.pathname),Gt(t,r("url.domain"),i.hostname),Gt(t,r("url.scheme"),i.protocol.replace(":","")),i.hash&&Gt(t,r("url.fragment"),i.hash.replace("#","")),i.search&&Gt(t,r("url.query"),i.search.replace("?",""))}catch(n){Gt(t,r(jt),String(e))}}var ye=null!=y&&"function"==typeof y.getItem&&"function"==typeof y.setItem;var ge="d0_tab",be=null;function Te(){if(ye)try{var t=function(t){return ye&&y?y.getItem(t):null}(ge);if(t)return void(be=t);be=b(8),function(t,e){ye&&y&&y.setItem(t,e)}(ge,be)}catch(t){i("Failed to record tab ID information",t)}else a("Storage API is not available and tab tracking is therefore not supported.")}function Ee(t,e){var n,r,i,o,a;void 0===t.find((function(t){return t.key===At}))&&Gt(t,At,b(8));for(var u=0;u<nt.signalAttributes.length;u++)t.push(nt.signalAttributes[u]);me(t,null!==(n=null!==(r=null==e?void 0:e.url)&&void 0!==r?r:null==l?void 0:l.location.href)&&void 0!==n?n:Q,"page"),re&&Gt(t,"session.id",re),be&&Gt(t,"browser.tab.id",be),Gt(t,"browser.window.width",null!==(i=null==l?void 0:l.innerWidth)&&void 0!==i?i:Q),Gt(t,"browser.window.height",null!==(o=null==l?void 0:l.innerHeight)&&void 0!==o?o:Q);var s=null==d||null===(a=d.connection)||void 0===a?void 0:a.effectiveType;s&&Gt(t,"network.connection.subtype",s)}var we,Se=0,Ae=0,Oe={},Ie=!1;function Ne(){Ie=!0}function Le(t,e){t&&_e("string"==typeof t?{message:t,opts:e}:{message:t.message,type:t.name,stack:t.stack,opts:e})}function _e(t){var e=t.message,n=t.type,r=t.stack,i=t.opts;if(e&&!(Se>100)&&!function(t){return!t||rt(nt.ignoreErrorMessages,t)}(e)){Ae>=20&&(Oe={},Ae=0);var o=(e=String(e).substring(0,300))+(r=function(t){return String(t||"").split("\n").slice(0,30).join("\n")}(r))+(null==l?void 0:l.location.href),a=Oe[o];if(a)a.seenCount++;else{var u=[];Gt(u,St,Mt.ERROR),Gt(u,kt,e),n&&Gt(u,Pt,n),r&&Gt(u,Dt,r),null!=i&&i.componentStack&&Gt(u,"exception.component_stack",null==i?void 0:i.componentStack.substring(0,2048)),Ee(u),a={seenCount:1,transmittedCount:0,log:{timeUnixNano:M(),attributes:u,severityNumber:Ut.ERROR,severityText:"ERROR",body:{stringValue:e}}},Oe[o]=a,Ae++}!function(){if(we)return;we=setTimeout(Ce,1e3)}()}}function Ce(){for(var t in we&&(clearTimeout(we),we=null),Oe)if(c(Oe,t)){var e=Oe[t];e.seenCount>e.transmittedCount&&(mt(e.log),Se++)}Oe={},Ae=0}var Re=-1,xe=function(t){addEventListener("pageshow",(function(e){e.persisted&&(Re=e.timeStamp,t(e))}),!0)},ke=function(t,e,n,r){var i,o;return function(a){e.value>=0&&(a||r)&&(((o=e.value-(null!=i?i:0))||void 0===i)&&(i=e.value,e.delta=o,e.rating=function(t,e){return t>e[1]?"poor":t>e[0]?"needs-improvement":"good"}(e.value,n),t(e)))}},Pe=function(t){requestAnimationFrame((function(){return requestAnimationFrame((function(){return t()}))}))},De=function(){var t=performance.getEntriesByType("navigation")[0];if(t&&t.responseStart>0&&t.responseStart<performance.now())return t},je=function(){var t,e=De();return null!==(t=null==e?void 0:e.activationStart)&&void 0!==t?t:0},Me=function(t){var e=arguments.length>1&&void 0!==arguments[1]?arguments[1]:-1,n=De(),r="navigate";return Re>=0?r="back-forward-cache":n&&(document.prerendering||je()>0?r="prerender":document.wasDiscarded?r="restore":n.type&&(r=n.type.replace(/_/g,"-"))),{name:t,value:e,rating:"good",delta:0,entries:[],id:"v5-".concat(Date.now(),"-").concat(Math.floor(8999999999999*Math.random())+1e12),navigationType:r}},Ue=new WeakMap;function Fe(t,e){return Ue.get(t)||Ue.set(t,new e),Ue.get(t)}var Ve,Be=function(){return I((function t(){O(this,t),L(this,"t",void 0),L(this,"i",0),L(this,"o",[])}),[{key:"h",value:function(t){var e;if(!t.hadRecentInput){var n=this.o[0],r=this.o.at(-1);this.i&&n&&r&&t.startTime-r.startTime<1e3&&t.startTime-n.startTime<5e3?(this.i+=t.value,this.o.push(t)):(this.i=t.value,this.o=[t]),null===(e=this.t)||void 0===e||e.call(this,t)}}}])}(),We=function(t,e){var n=arguments.length>2&&void 0!==arguments[2]?arguments[2]:{};try{if(PerformanceObserver.supportedEntryTypes.includes(t)){var r=new PerformanceObserver((function(t){Promise.resolve().then((function(){e(t.getEntries())}))}));return r.observe(function(t){for(var e=1;e<arguments.length;e++){var n=null!=arguments[e]?arguments[e]:{};e%2?_(Object(n),!0).forEach((function(e){L(t,e,n[e])})):Object.getOwnPropertyDescriptors?Object.defineProperties(t,Object.getOwnPropertyDescriptors(n)):_(Object(n)).forEach((function(e){Object.defineProperty(t,e,Object.getOwnPropertyDescriptor(n,e))}))}return t}({type:t,buffered:!0},n)),r}}catch(t){}},qe=function(t){var e=!1;return function(){e||(t(),e=!0)}},He=-1,ze=function(){return"hidden"!==document.visibilityState||document.prerendering?1/0:0},Ge=function(t){"hidden"===document.visibilityState&&He>-1&&(He="visibilitychange"===t.type?t.timeStamp:0,Ze())},Ke=function(){addEventListener("visibilitychange",Ge,!0),addEventListener("prerenderingchange",Ge,!0)},Ze=function(){removeEventListener("visibilitychange",Ge,!0),removeEventListener("prerenderingchange",Ge,!0)},Ye=function(){if(He<0){var t,e=je(),n=document.prerendering||null===(t=globalThis.performance.getEntriesByType("visibility-state").filter((function(t){return"hidden"===t.name&&t.startTime>e}))[0])||void 0===t?void 0:t.startTime;He=null!=n?n:ze(),Ke(),xe((function(){setTimeout((function(){He=ze(),Ke()}))}))}return{get firstHiddenTime(){return He}}},Qe=function(t){document.prerendering?addEventListener("prerenderingchange",(function(){return t()}),!0):t()},Xe=[1800,3e3],$e=[.1,.25],Je=function(t){var e=arguments.length>1&&void 0!==arguments[1]?arguments[1]:{};!function(t){var e=arguments.length>1&&void 0!==arguments[1]?arguments[1]:{};Qe((function(){var n,r=Ye(),i=Me("FCP"),o=We("paint",(function(t){var e,a=N(t);try{for(a.s();!(e=a.n()).done;){var u=e.value;"first-contentful-paint"===u.name&&(o.disconnect(),u.startTime<r.firstHiddenTime&&(i.value=Math.max(u.startTime-je(),0),i.entries.push(u),n(!0)))}}catch(t){a.e(t)}finally{a.f()}}));o&&(n=ke(t,i,Xe,e.reportAllChanges),xe((function(r){i=Me("FCP"),n=ke(t,i,Xe,e.reportAllChanges),Pe((function(){i.value=performance.now()-r.timeStamp,n(!0)}))})))}))}(qe((function(){var n,r=Me("CLS",0),i=Fe(e,Be),o=function(t){var e,o=N(t);try{for(o.s();!(e=o.n()).done;){var a=e.value;i.h(a)}}catch(t){o.e(t)}finally{o.f()}i.i>r.value&&(r.value=i.i,r.entries=i.o,n())},a=We("layout-shift",o);a&&(n=ke(t,r,$e,e.reportAllChanges),document.addEventListener("visibilitychange",(function(){"hidden"===document.visibilityState&&(o(a.takeRecords()),n(!0))})),xe((function(){i.i=0,r=Me("CLS",0),n=ke(t,r,$e,e.reportAllChanges),Pe((function(){return n()}))})),setTimeout(n))})))},tn=0,en=1/0,nn=0,rn=function(t){var e,n=N(t);try{for(n.s();!(e=n.n()).done;){var r=e.value;r.interactionId&&(en=Math.min(en,r.interactionId),nn=Math.max(nn,r.interactionId),tn=nn?(nn-en)/7+1:0)}}catch(t){n.e(t)}finally{n.f()}},on=function(){var t;return Ve?tn:null!==(t=performance.interactionCount)&&void 0!==t?t:0},an=0,un=function(){return I((function t(){O(this,t),L(this,"u",[]),L(this,"l",new Map),L(this,"m",void 0),L(this,"v",void 0)}),[{key:"p",value:function(){an=on(),this.u.length=0,this.l.clear()}},{key:"P",value:function(){var t=Math.min(this.u.length-1,Math.floor((on()-an)/50));return this.u[t]}},{key:"h",value:function(t){var e;if(null!==(e=this.m)&&void 0!==e&&e.call(this,t),t.interactionId||"first-input"===t.entryType){var n=this.u.at(-1),r=this.l.get(t.interactionId);if(r||this.u.length<10||t.duration>n.T){var i;if(r?t.duration>r.T?(r.entries=[t],r.T=t.duration):t.duration===r.T&&t.startTime===r.entries[0].startTime&&r.entries.push(t):(r={id:t.interactionId,entries:[t],T:t.duration},this.l.set(r.id,r),this.u.push(r)),this.u.sort((function(t,e){return e.T-t.T})),this.u.length>10){var o,a=N(this.u.splice(10));try{for(a.s();!(o=a.n()).done;){var u=o.value;this.l.delete(u.id)}}catch(t){a.e(t)}finally{a.f()}}null===(i=this.v)||void 0===i||i.call(this,r)}}}}])}(),sn=function(t){var e=globalThis.requestIdleCallback||setTimeout;"hidden"===document.visibilityState?t():(t=qe(t),document.addEventListener("visibilitychange",t,{once:!0}),e((function(){t(),document.removeEventListener("visibilitychange",t)})))},cn=[200,500],ln=function(t){var e=arguments.length>1&&void 0!==arguments[1]?arguments[1]:{};globalThis.PerformanceEventTiming&&"interactionId"in PerformanceEventTiming.prototype&&Qe((function(){var n;"interactionCount"in performance||Ve||(Ve=We("event",rn,{type:"event",buffered:!0,durationThreshold:0}));var r,i=Me("INP"),o=Fe(e,un),a=function(t){sn((function(){var e,n=N(t);try{for(n.s();!(e=n.n()).done;){var a=e.value;o.h(a)}}catch(t){n.e(t)}finally{n.f()}var u=o.P();u&&u.T!==i.value&&(i.value=u.T,i.entries=u.entries,r())}))},u=We("event",a,{durationThreshold:null!==(n=e.durationThreshold)&&void 0!==n?n:40});r=ke(t,i,cn,e.reportAllChanges),u&&(u.observe({type:"first-input",buffered:!0}),document.addEventListener("visibilitychange",(function(){"hidden"===document.visibilityState&&(a(u.takeRecords()),r(!0))})),xe((function(){o.p(),i=Me("INP"),r=ke(t,i,cn,e.reportAllChanges)})))}))},fn=function(){return I((function t(){O(this,t),L(this,"m",void 0)}),[{key:"h",value:function(t){var e;null===(e=this.m)||void 0===e||e.call(this,t)}}])}(),dn=[2500,4e3];function vn(){!function(t){var e=arguments.length>1&&void 0!==arguments[1]?arguments[1]:{};Qe((function(){var n,r=Ye(),i=Me("LCP"),o=Fe(e,fn),a=function(t){e.reportAllChanges||(t=t.slice(-1));var a,u=N(t);try{for(u.s();!(a=u.n()).done;){var s=a.value;o.h(s),s.startTime<r.firstHiddenTime&&(i.value=Math.max(s.startTime-je(),0),i.entries=[s],n())}}catch(t){u.e(t)}finally{u.f()}},u=We("largest-contentful-paint",a);if(u){n=ke(t,i,dn,e.reportAllChanges);for(var s=qe((function(){a(u.takeRecords()),u.disconnect(),n(!0)})),c=0,l=["keydown","click","visibilitychange"];c<l.length;c++)addEventListener(l[c],(function(){return sn(s)}),{capture:!0,once:!0});xe((function(r){i=Me("LCP"),n=ke(t,i,dn,e.reportAllChanges),Pe((function(){i.value=performance.now()-r.timeStamp,n(!0)}))}))}}))}(pn,{reportAllChanges:!0}),ln(pn,{reportAllChanges:!0}),Je(pn,{reportAllChanges:!0})}function pn(t){var e=[];Gt(e,St,Mt.WEB_VITAL);var n=[];Gt(n,"name",t.name),Gt(n,"value",X(t.value)),Gt(n,"delta",X(t.delta));var r={timeUnixNano:M(),attributes:e,severityNumber:Ut.INFO,severityText:"INFO",body:{kvlistValue:{values:n}}};Ee(r.attributes),mt(r)}var hn="Unhandled promise rejection: ",mn="<unavailable because Promise wasn't rejected with an Error object>";function yn(t){null==t.reason?Le({message:hn+"<no reason defined>",stack:mn}):"string"==typeof t.reason.message?Le({message:hn+t.reason.message,stack:"string"==typeof t.reason.stack?t.reason.stack:mn}):"object"!==P(t.reason)&&Le({message:hn+t.reason,stack:mn})}var gn="__dash0OriginalFunctions";function bn(t,e){for(var n=t[gn],r=0;r<n.length;r++){if(Tn(n[r].valuesForEqualityCheck,e))return r}return-1}function Tn(t,e){if(t.length!==e.length)return!1;for(var n=0;n<t.length;n++)if(t[n]!==e[n])return!1;return!0}function En(t,e,n,r,i){return function(t,e,n){if(!t)return e;var r=t[gn]=t[gn]||[],i=bn(t,n);return-1!==i?r[i].wrappedFunction:(r.push({wrappedFunction:e,valuesForEqualityCheck:n}),e)}(t,e,wn(n,r,i))}function wn(t,e,n){return[t,e,Sn(n)]}function Sn(t){return null!=t&&("object"===P(t)?Boolean(t.capture):Boolean(t))}function An(t,e,n,r,i){return function(t,e,n){var r=null==t?void 0:t[gn];if(null==r)return n;var i=bn(t,e);if(-1===i)return n;var o=r[i];return r.splice(i,1),o.wrappedFunction}(t,wn(e,n,r),i)}function On(){nt.wrapEventHandlers&&function(t){if(!t||"function"!=typeof t.prototype.addEventListener||"function"!=typeof t.prototype.removeEventListener)return;var e=t.prototype.addEventListener,n=t.prototype.removeEventListener;t.prototype.addEventListener=function(t,n,r){if("function"!=typeof n)return e.apply(this,arguments);for(var i=new Array(arguments.length),o=0;o<arguments.length;o++)i[o]=arguments[o];return i[1]=function(){try{return n.apply(this,arguments)}catch(t){throw reportError(t),Ne(),t}},i[1]=En(this,i[1],t,n,r),e.apply(this,i)},t.prototype.removeEventListener=function(t,e,r){if("function"!=typeof e)return n.apply(this,arguments);for(var i=new Array(arguments.length),o=0;o<arguments.length;o++)i[o]=arguments[o];return i[1]=An(this,t,e,r,e),n.apply(this,i)}}(null==l?void 0:l.EventTarget)}function In(t){var e=null==l?void 0:l[t];"function"==typeof e&&(l[t]=function(t){for(var n=new Array(arguments.length),r=0;r<arguments.length;r++)n[r]=arguments[r];return n[0]=function(t){if("function"!=typeof t)return t;return function(){try{return t.apply(this,arguments)}catch(t){throw reportError(t),Ne(),t}}}(t),e.apply(this,n)})}function Nn(){!function(){if(l){var t=l.onerror;l.onerror=function(e,n,r,i,o){if(Ie)return Ie=!1,"function"==typeof t?t.apply(this,arguments):void 0;var a=o&&o.stack;return a||(a="at "+n+" "+r,null!=i&&(a+=":"+i)),_e({message:String(e),stack:a}),"function"==typeof t?t.apply(this,arguments):void 0}}}(),"function"==typeof(null==l?void 0:l.addEventListener)&&l.addEventListener("unhandledrejection",yn),On(),function(){if(nt.wrapTimers){if(B)return void i("We discovered a usage of Zone.js. In order to avoid any incompatibility issues timer wrapping is not going to be enabled.");In("setTimeout"),In("setInterval")}}()}var Ln=["GET","HEAD","POST","PUT","DELETE","CONNECT","OPTIONS","TRACE","PATCH"];function _n(t){return Ln.includes(t)}function Cn(t,e){var n=0!==e.startTime;Rn(t,G.FETCH_START,e,n),Rn(t,G.DOMAIN_LOOKUP_START,e,n),Rn(t,G.DOMAIN_LOOKUP_END,e,n),Rn(t,G.CONNECT_START,e,n),Rn(t,G.SECURE_CONNECTION_START,e,n),Rn(t,G.CONNECT_END,e,n),Rn(t,G.REQUEST_START,e,n),Rn(t,G.RESPONSE_START,e,n),Rn(t,G.RESPONSE_END,e,n)}function Rn(t,e,n){var r,i=!(arguments.length>3&&void 0!==arguments[3])||arguments[3];!(e in n)||"number"!=typeof n[e]||i&&0===n[e]||he(t,e,(r=n[e],String(Math.round(1e6*(r+F())))))}function xn(t,e){var n=e.encodedBodySize;null!=n&&Gt(t.attributes,"http.response.body.size",n)}function kn(t){return function(){var e=A(C().mark((function e(n,r){var i,o,u,s,c,l,f,d,v,p,h,m,y,g;return C().wrap((function(e){for(;;)switch(e.prev=e.next){case 0:if(u=r?Object.assign({},r):r,s=null,null!==(i=u)&&void 0!==i&&i.body&&(s=u.body,u.body=void 0),c=new Request(n,u),s&&u&&(u.body=s),!ot(l=c.url)){e.next=9;break}return a("Not creating span for fetch call because the url is ignored, URL: ".concat(l)),e.abrupt("return",t(n instanceof Request?c:n,r));case 9:return f=null!==(o=c.method)&&void 0!==o?o:"GET",d=_n(f),v=_n(f.toUpperCase()),p=v?f.toUpperCase():"_OTHER",Ee((h=ve("HTTP ".concat(p))).attributes),me(h.attributes,l),Pn(n,r),Gt(h.attributes,"http.request.method",p),d||Gt(h.attributes,"http.request.method_original",f),(J(l)||rt(nt.propagateTraceHeadersCorsURLs,l))&&(null!==(m=u)&&void 0!==m&&m.headers?(u.headers=new Headers(u.headers),Xt(u.headers.append,u.headers,h)):n instanceof Request?Xt(c.headers.append,c.headers,h):(u||(u={}),u.headers=new Headers,Xt(u.headers.append,u.headers,h))),Dn(c.headers,h,(function(t){return e=t,"".concat("http.request.header",".").concat(e.toLowerCase());var e})),(y=Z({resourceMatcher:function(t){var e=t.initiatorType,n=t.name;return("fetch"===e||"xmlhttprequest"===e)&&n===$(l).href},maxWaitForResourceMillis:nt.maxWaitForResourceTimingsMillis,maxToleranceForResourceTimingsMillis:nt.maxToleranceForResourceTimingsMillis,onEnd:function(t){var e=t.duration,n=t.resource;n&&(Cn(h,n),xn(h,n)),yt(pe(h,void 0,1e6*e))}})).start(),e.prev=24,e.next=27,t(n instanceof Request?c:n,u);case 27:return g=e.sent,jn(h,g),Mn(g).then((function(){return y.end()})).catch((function(t){y.cancel(),Un(h,t)})),e.abrupt("return",g);case 33:throw e.prev=33,e.t0=e.catch(24),y.cancel(),Un(h,e.t0),e.t0;case 38:case"end":return e.stop()}}),e,null,[[24,33]])})));return function(t,n){return e.apply(this,arguments)}}()}function Pn(t,e,n){try{return void 0}catch(n){a("failed to analyze request for GraphQL insights",n,t,e)}}function Dn(t,e,n){try{t.forEach((function(t,r){nt.headersToCapture.some((function(t){return t.test(r)}))&&Gt(e.attributes,n(r),t)}))}catch(t){a("unable to capture http headers due to CORS policy")}}function jn(t,e){var n=e.status;!function(t,e,n){t.status={code:e,message:n}}(t,n>=200&&n<400?0:2),0===n&&Gt(t.attributes,"error.type",e.type),Gt(t.attributes,"http.response.status_code",String(n)),Dn(e.headers,t,(function(t){return e=t,"".concat("http.response.header",".").concat(e.toLowerCase());var e}))}function Mn(t){return new Promise((function(e){var n=t.clone().body;if(!n)return e();var r=n.getReader(),i=function(){var t=A(C().mark((function t(){var n;return C().wrap((function(t){for(;;)switch(t.prev=t.next){case 0:return t.next=2,r.read();case 2:if(n=t.sent,!n.done){t.next=6;break}return t.abrupt("return",e());case 6:return t.abrupt("return",i());case 7:case"end":return t.stop()}}),t)})));return function(){return t.apply(this,arguments)}}();return i()}))}function Un(t,e){!function(t,e){var n=[];"string"==typeof e?Gt(n,kt,e):e&&(e.code?Gt(n,Pt,e.code.toString()):e.name&&Gt(n,Pt,e.name),e.message&&Gt(n,kt,e.message),e.stack&&Gt(n,Dt,e.stack),he(t,"exception",n))}(t,e),yt(pe(t,function(t){return{code:2,message:t&&"object"===P(t)&&"message"in t?t.message:String(t)}}(e),void 0))}function Fn(t,e,n,r){var i,o,a=function(t){var e,n,r;return t&&null!==(e=null===(n=(r=nt.pageViewInstrumentation).generateMetadata)||void 0===n?void 0:n.call(r,t))&&void 0!==e?e:{}}(e),u=[];Gt(u,St,Mt.PAGE_VIEW),a.attributes&&Object.entries(a.attributes).forEach((function(t){var e=R(t,2),n=e[0],r=e[1];return Gt(u,n,r)})),Ee(u,{url:e});var s=[];Gt(s,"title",null!==(i=null!==(o=a.title)&&void 0!==o?o:null==f?void 0:f.title)&&void 0!==i?i:Q),null!=f&&f.referrer&&Gt(s,"referrer",f.referrer),Gt(s,"type",n?Vt:Ft),Gt(s,"change_state",r?Wt:Bt);var c={timeUnixNano:t,attributes:u,severityNumber:Ut.INFO,severityText:"INFO",body:{kvlistValue:{values:s}}},l=Qt();l&&(c.traceId=l.traceId,c.spanId=l.spanId),mt(c)}function Vn(){var t=null==l?void 0:l.performance.getEntriesByType("navigation")[0];if(t){var e=[];Gt(e,St,Mt.NAVIGATION_TIMING);var n=[];Gt(n,"name",t.name),Bn(n,t,"responseStatus"),Bn(n,t,"fetchStart"),Bn(n,t,"requestStart"),Bn(n,t,"responseStart"),Bn(n,t,"domInteractive"),Bn(n,t,"domContentLoadedEventEnd"),Bn(n,t,"domComplete"),Bn(n,t,"loadEventEnd"),Bn(n,t,"transferSize"),Bn(n,t,"encodedBodySize"),Bn(n,t,"decodedBodySize");var r={timeUnixNano:Wn(),attributes:e,severityNumber:Ut.INFO,severityText:"INFO",body:{kvlistValue:{values:n}}};Ee(r.attributes);var i=Qt();i&&(r.traceId=i.traceId,r.spanId=i.spanId),mt(r)}else a("Navigation timings not available. Cannot emit navigation timing log")}function Bn(t,e,n){var r=e[n];"number"!=typeof r||isNaN(r)||Gt(t,n,Number.isInteger(r)?r:X(r))}function Wn(){return U(Math.round(F()))}var qn={},Hn=!1,zn=!1;function Gn(){Zn(null==l?void 0:l.location.href)}function Kn(t){Zn(t.newURL)}function Zn(t,e){var n;if(t)try{var r=new URL(t,null==l?void 0:l.location.href);((n=r).pathname!==qn.path||zn&&n.search!==qn.search||Hn&&n.hash!==qn.hash)&&(Yn(r),Fn(M(),r,!0,Boolean(e)))}catch(t){a("Failed to handle url change",t)}}function Yn(t){qn.path=t.pathname,qn.search=t.search,qn.hash=t.hash}function Qn(){!function(){try{Fn(Wn(),null!=l&&l.location.href?new URL(null==l?void 0:l.location.href):void 0)}catch(t){o("Failed to transmit initial page view event",t)}if("complete"===(null==f?void 0:f.readyState))return Vn();l&&T(l,"load",(function(){setTimeout(Vn,0)}))}(),function(){var t,e,n,r;if(l&&l.history){if(nt.pageViewInstrumentation.trackVirtualPageViews){zn=null!==(t=null===(e=nt.pageViewInstrumentation.includeParts)||void 0===e?void 0:e.includes("SEARCH"))&&void 0!==t&&t,Hn=null!==(n=null===(r=nt.pageViewInstrumentation.includeParts)||void 0===r?void 0:r.includes("HASH"))&&void 0!==n&&n,et(l.history,"replaceState",(function(t){return function(e,n,r){return Zn(r?String(r):void 0,!0),t.apply(this,[e,n,r])}})),et(l.history,"pushState",(function(t){return function(e,n,r){return Zn(r?String(r):void 0),t.apply(this,[e,n,r])}})),l.addEventListener("hashchange",Kn),l.addEventListener("popstate",Gn);try{Yn(new URL(l.location.href))}catch(t){}}}else a("Browser does not support history API, skipping instrumentation")}()}var Xn=function(t){if("object"===P(t)&&null!==t){if("function"==typeof Object.getPrototypeOf){var e=Object.getPrototypeOf(t);return e===Object.prototype||null===e}return"[object Object]"===Object.prototype.toString.call(t)}return!1},$n=function(){for(var t=arguments.length,e=new Array(t),n=0;n<t;n++)e[n]=arguments[n];return e.reduce((function(t,e){if(void 0===e)return t;if(Array.isArray(e))throw new TypeError("Arguments provided to ts-deepmerge must be objects, not arrays.");return Object.keys(e).forEach((function(n){["__proto__","constructor","prototype"].includes(n)||(Array.isArray(t[n])&&Array.isArray(e[n])?t[n]=$n.options.mergeArrays?$n.options.uniqueArrayItems?Array.from(new Set(t[n].concat(e[n]))):[].concat(x(t[n]),x(e[n])):e[n]:Xn(t[n])&&Xn(e[n])?t[n]=$n(t[n],e[n]):!Xn(t[n])&&Xn(e[n])?t[n]=$n(e[n],void 0):t[n]=void 0===e[n]?$n.options.allowUndefinedOverrides?e[n]:t[n]:e[n])})),t}),{})},Jn={allowUndefinedOverrides:!0,mergeArrays:!0,uniqueArrayItems:!0};$n.options=Jn,$n.withOptions=function(t){$n.options=Object.assign(Object.assign({},Jn),t);for(var e=arguments.length,n=new Array(e>1?e-1:0),r=1;r<e;r++)n[r-1]=arguments[r];var i=$n.apply(void 0,n);return $n.options=Jn,i};var tr=!1;var er={init:function(t){tr?a("Dash0 SDK is being reinitialized, skipping ..."):null!=l?"function"==typeof h&&p&&p.getEntriesByType?(nt.endpoints=t.endpoint instanceof Array?t.endpoint:[t.endpoint],0!==nt.endpoints.length?(Object.assign(nt,$n(nt,function(t,e){var n,r={},i=N(e);try{for(i.s();!(n=i.n()).done;){var o=n.value;o in t&&(r[o]=t[o])}}catch(t){i.e(t)}finally{i.f()}return r}(t,["ignoreUrls","ignoreErrorMessages","wrapEventHandlers","wrapTimers","propagateTraceHeadersCorsURLs","maxWaitForResourceTimingsMillis","maxToleranceForResourceTimingsMillis","headersToCapture","pageViewInstrumentation"]))),function(t){Gt(nt.resource.attributes,gt,t.serviceName),t.serviceVersion&&Gt(nt.resource.attributes,bt,t.serviceVersion);var e=function(t){if(t.environment)return t.environment;try{var e;return null===(e=process)||void 0===e||null===(e=e.env)||void 0===e?void 0:e.NEXT_PUBLIC_VERCEL_ENV}catch(t){return}}(t);e&&Gt(nt.resource.attributes,Tt,e);var n=function(t){if(t.deploymentName)return t.deploymentName;try{var e;return null===(e=process)||void 0===e||null===(e=e.env)||void 0===e?void 0:e.NEXT_PUBLIC_VERCEL_TARGET_ENV}catch(t){return}}(t);n&&Gt(nt.resource.attributes,Et,n);var r=function(t){if(t.deploymentId)return t.deploymentId;try{var e;return null===(e=process)||void 0===e||null===(e=e.env)||void 0===e?void 0:e.NEXT_PUBLIC_VERCEL_BRANCH_URL}catch(t){return}}(t);r&&Gt(nt.resource.attributes,wt,r)}(t),function(t){var e;Gt(nt.signalAttributes,Ot,b(16)),Gt(nt.signalAttributes,It,null!==(e=null==d?void 0:d.userAgent)&&void 0!==e?e:Q),t.additionalSignalAttributes&&Object.entries(t.additionalSignalAttributes).forEach((function(t){var e=R(t,2),n=e[0],r=e[1];Gt(nt.signalAttributes,n,r)}))}(t),Te(),ie(t.sessionInactivityTimeoutMillis,t.sessionTerminationTimeoutMillis),Qn(),vn(),Nn(),l&&l.fetch&&l.Request?et(l,"fetch",kn):a("Browser does not support the Fetch API, skipping instrumentation"),tr=!0):i("No telemetry endpoint configured. Aborting Dash0 Web SDK initialization process.")):a("Stopping Dash0 Web SDK initialization. This browser does not support the necessary APIs"):a("Looks like we are not running in a browser context. Stopping Dash0 Web SDK initialization.")},debug:function(){a("Dash0 Web SDK configuration state:",nt)},identify:function(t,e){Kt(nt.signalAttributes,Nt),null!=t&&Gt(nt.signalAttributes,Nt,t),Kt(nt.signalAttributes,Lt),null!=(null==e?void 0:e.name)&&Gt(nt.signalAttributes,Lt,e.name),Kt(nt.signalAttributes,_t),null!=(null==e?void 0:e.fullName)&&Gt(nt.signalAttributes,_t,e.fullName),Kt(nt.signalAttributes,Ct),null!=(null==e?void 0:e.email)&&Gt(nt.signalAttributes,Ct,e.email),Kt(nt.signalAttributes,Rt),null!=(null==e?void 0:e.hash)&&Gt(nt.signalAttributes,Rt,e.hash),Kt(nt.signalAttributes,xt),null!=(null==e?void 0:e.roles)&&Gt(nt.signalAttributes,xt,e.roles)},terminateSession:function(){if(E)try{!function(t){E&&m&&m.removeItem(t)}(te)}catch(t){r("Failed to terminate session",t)}},reportError:function(t,e){Le(t,e)},addSignalAttribute:function(t,e){Gt(nt.signalAttributes,t,e)},removeSignalAttribute:function(t){Kt(nt.signalAttributes,t)},setActiveLogLevel:function(t){var r;n=null!==(r=e[t])&&void 0!==r?r:e.warn},sendEvent:function(t,e){var n;if(Object.values(Mt).includes(t))i("Unable to send custom event ".concat(t,". You are not allowed to use an internal event name while sending a custom event. Dropping event..."));else{var r=[];Ee(r),Object.entries(null!==(n=null==e?void 0:e.attributes)&&void 0!==n?n:{}).forEach((function(t){var e=R(t,2),n=e[0],i=e[1];return Gt(r,n,i)})),Gt(r,St,t),null!=e&&e.title&&Gt(r,"dash0.web.event.title",e.title),mt({timeUnixNano:null!=(null==e?void 0:e.timestamp)?U(e.timestamp):M(),attributes:r,body:Ht(null==e?void 0:e.data),severityText:null==e?void 0:e.severity,severityNumber:null!=e&&e.severity?Ut[e.severity]:void 0})}}};function nr(t){var e=t[0],n=er[e];if(n){for(var r=[],o=1;o<t.length;o++)r.push(t[o]);n.apply(null,r)}else i("Unsupported Dash0 Web SDK api: ",t[0])}!function(){a("".concat("Initializing Dash0 Web SDK"," (via Script)"));var t=l.dash0;if(!t)return void i("global 'dash0' not found. Did you use the correct Dash0 Web SDK initializer?");if(!t._q)return void i("Dash0 Web SDK command queue not defined. Did you add the script tag multiple times to your website?");(function(t){for(var e=0,n=t.length;e<n;e++)nr(t[e])})(t._q),l.dash0=function(){return nr(arguments)}}()}();
2
2
  //# sourceMappingURL=dash0.iife.js.map