-
Notifications
You must be signed in to change notification settings - Fork 0
Expand file tree
/
Copy pathbundle.tracing.min.js
More file actions
3 lines (3 loc) · 110 KB
/
bundle.tracing.min.js
File metadata and controls
3 lines (3 loc) · 110 KB
1
2
3
/*! @sentry/browser (Performance Monitoring) 9.11.0 (392c061) | https://github.com/getsentry/sentry-javascript */
var Sentry=function(t){t=window.Sentry||{};const n=globalThis,e="9.11.0";function r(){return o(n),n}function o(t){const n=t.__SENTRY__=t.__SENTRY__||{};return n.version=n.version||e,n[e]=n[e]||{}}function i(t,r,o=n){const i=o.__SENTRY__=o.__SENTRY__||{},s=i[e]=i[e]||{};return s[t]||(s[t]=r())}const s=["debug","info","warn","error","log","assert","trace"],c={};function a(t){if(!("console"in n))return t();const e=n.console,r={},o=Object.keys(c);o.forEach((t=>{const n=c[t];r[t]=e[t],e[t]=n}));try{return t()}finally{o.forEach((t=>{e[t]=r[t]}))}}const u=i("logger",(function(){let t=!1;const n={enable:()=>{t=!0},disable:()=>{t=!1},isEnabled:()=>t};return s.forEach((t=>{n[t]=()=>{}})),n})),f=50,d="?",l=/\(error: (.*)\)/,p=/captureMessage|captureException/;function h(...t){const n=t.sort(((t,n)=>t[0]-n[0])).map((t=>t[1]));return(t,e=0,r=0)=>{const o=[],i=t.split("\n");for(let t=e;t<i.length;t++){const e=i[t];if(e.length>1024)continue;const s=l.test(e)?e.replace(l,"$1"):e;if(!s.match(/\S*Error: /)){for(const t of n){const n=t(s);if(n){o.push(n);break}}if(o.length>=f+r)break}}return function(t){if(!t.length)return[];const n=Array.from(t);/sentryWrapped/.test(m(n).function||"")&&n.pop();n.reverse(),p.test(m(n).function||"")&&(n.pop(),p.test(m(n).function||"")&&n.pop());return n.slice(0,f).map((t=>({...t,filename:t.filename||m(n).filename,function:t.function||d})))}(o.slice(r))}}function m(t){return t[t.length-1]||{}}const g="<anonymous>";function y(t){try{return t&&"function"==typeof t&&t.name||g}catch(t){return g}}function v(t){const n=t.exception;if(n){const t=[];try{return n.values.forEach((n=>{n.stacktrace.frames&&t.push(...n.stacktrace.frames)})),t}catch(t){return}}}const b={},_={};function S(t,n){b[t]=b[t]||[],b[t].push(n)}function w(t,n){if(!_[t]){_[t]=!0;try{n()}catch(t){}}}function E(t,n){const e=t&&b[t];if(e)for(const t of e)try{t(n)}catch(t){}}let T=null;function k(t){const n="error";S(n,t),w(n,$)}function $(){T=n.onerror,n.onerror=function(t,n,e,r,o){return E("error",{column:r,error:o,line:e,msg:t,url:n}),!!T&&T.apply(this,arguments)},n.onerror.__SENTRY_INSTRUMENTED__=!0}let x=null;function I(t){const n="unhandledrejection";S(n,t),w(n,R)}function R(){x=n.onunhandledrejection,n.onunhandledrejection=function(t){return E("unhandledrejection",t),!x||x.apply(this,arguments)},n.onunhandledrejection.__SENTRY_INSTRUMENTED__=!0}const O=1e3;function C(){return Date.now()/O}const j=function(){const{performance:t}=n;if(!t?.now)return C;const e=Date.now()-t.now(),r=null==t.timeOrigin?e:t.timeOrigin;return()=>(r+t.now())/O}();let M;function L(){return M||(M=function(){const{performance:t}=n;if(!t?.now)return[void 0,"none"];const e=36e5,r=t.now(),o=Date.now(),i=t.timeOrigin?Math.abs(t.timeOrigin+r-o):e,s=i<e,c=t.timing?.navigationStart,a="number"==typeof c?Math.abs(c+r-o):e;return s||a<e?i<=a?[t.timeOrigin,"timeOrigin"]:[c,"navigationStart"]:[o,"dateNow"]}()),M[0]}const P=Object.prototype.toString;function A(t){switch(P.call(t)){case"[object Error]":case"[object Exception]":case"[object DOMException]":case"[object WebAssembly.Exception]":return!0;default:return X(t,Error)}}function N(t,n){return P.call(t)===`[object ${n}]`}function D(t){return N(t,"ErrorEvent")}function F(t){return N(t,"DOMError")}function q(t){return N(t,"String")}function U(t){return"object"==typeof t&&null!==t&&"__sentry_template_string__"in t&&"__sentry_template_values__"in t}function H(t){return null===t||U(t)||"object"!=typeof t&&"function"!=typeof t}function B(t){return N(t,"Object")}function z(t){return"undefined"!=typeof Event&&X(t,Event)}function W(t){return Boolean(t?.then&&"function"==typeof t.then)}function X(t,n){try{return t instanceof n}catch(t){return!1}}function J(t){return!("object"!=typeof t||null===t||!t.__isVue&&!t.t)}const G=n,K=80;function V(t,n={}){if(!t)return"<unknown>";try{let e=t;const r=5,o=[];let i=0,s=0;const c=" > ",a=c.length;let u;const f=Array.isArray(n)?n:n.keyAttrs,d=!Array.isArray(n)&&n.maxStringLength||K;for(;e&&i++<r&&(u=Y(e,f),!("html"===u||i>1&&s+o.length*a+u.length>=d));)o.push(u),s+=u.length,e=e.parentNode;return o.reverse().join(c)}catch(t){return"<unknown>"}}function Y(t,n){const e=t,r=[];if(!e?.tagName)return"";if(G.HTMLElement&&e instanceof HTMLElement&&e.dataset){if(e.dataset.sentryComponent)return e.dataset.sentryComponent;if(e.dataset.sentryElement)return e.dataset.sentryElement}r.push(e.tagName.toLowerCase());const o=n?.length?n.filter((t=>e.getAttribute(t))).map((t=>[t,e.getAttribute(t)])):null;if(o?.length)o.forEach((t=>{r.push(`[${t[0]}="${t[1]}"]`)}));else{e.id&&r.push(`#${e.id}`);const t=e.className;if(t&&q(t)){const n=t.split(/\s+/);for(const t of n)r.push(`.${t}`)}}const i=["aria-label","type","name","title","alt"];for(const t of i){const n=e.getAttribute(t);n&&r.push(`[${t}="${n}"]`)}return r.join("")}function Z(){try{return G.document.location.href}catch(t){return""}}function Q(t){if(!G.HTMLElement)return null;let n=t;for(let t=0;t<5;t++){if(!n)return null;if(n instanceof HTMLElement){if(n.dataset.sentryComponent)return n.dataset.sentryComponent;if(n.dataset.sentryElement)return n.dataset.sentryElement}n=n.parentNode}return null}function tt(t,n=0){return"string"!=typeof t||0===n||t.length<=n?t:`${t.slice(0,n)}...`}function nt(t,n){if(!Array.isArray(t))return"";const e=[];for(let n=0;n<t.length;n++){const r=t[n];try{J(r)?e.push("[VueViewModel]"):e.push(String(r))}catch(t){e.push("[value cannot be serialized]")}}return e.join(n)}function et(t,n,e=!1){return!!q(t)&&(N(n,"RegExp")?n.test(t):!!q(n)&&(e?t===n:t.includes(n)))}function rt(t,n=[],e=!1){return n.some((n=>et(t,n,e)))}function ot(t,n,e){if(!(n in t))return;const r=t[n];if("function"!=typeof r)return;const o=e(r);"function"==typeof o&&st(o,r);try{t[n]=o}catch{}}function it(t,n,e){try{Object.defineProperty(t,n,{value:e,writable:!0,configurable:!0})}catch(t){}}function st(t,n){try{const e=n.prototype||{};t.prototype=n.prototype=e,it(t,"__sentry_original__",n)}catch(t){}}function ct(t){return t.__sentry_original__}function at(t){if(A(t))return{message:t.message,name:t.name,stack:t.stack,...ft(t)};if(z(t)){const n={type:t.type,target:ut(t.target),currentTarget:ut(t.currentTarget),...ft(t)};return"undefined"!=typeof CustomEvent&&X(t,CustomEvent)&&(n.detail=t.detail),n}return t}function ut(t){try{return n=t,"undefined"!=typeof Element&&X(n,Element)?V(t):Object.prototype.toString.call(t)}catch(t){return"<unknown>"}var n}function ft(t){if("object"==typeof t&&null!==t){const n={};for(const e in t)Object.prototype.hasOwnProperty.call(t,e)&&(n[e]=t[e]);return n}return{}}function dt(t=function(){const t=n;return t.crypto||t.msCrypto}()){let e=()=>16*Math.random();try{if(t?.randomUUID)return t.randomUUID().replace(/-/g,"");t?.getRandomValues&&(e=()=>{const n=new Uint8Array(1);return t.getRandomValues(n),n[0]})}catch(t){}return([1e7]+1e3+4e3+8e3+1e11).replace(/[018]/g,(t=>(t^(15&e())>>t/4).toString(16)))}function lt(t){return t.exception?.values?.[0]}function pt(t){const{message:n,event_id:e}=t;if(n)return n;const r=lt(t);return r?r.type&&r.value?`${r.type}: ${r.value}`:r.type||r.value||e||"<unknown>":e||"<unknown>"}function ht(t,n,e){const r=t.exception=t.exception||{},o=r.values=r.values||[],i=o[0]=o[0]||{};i.value||(i.value=n||""),i.type||(i.type="Error")}function mt(t,n){const e=lt(t);if(!e)return;const r=e.mechanism;if(e.mechanism={type:"generic",handled:!0,...r,...n},n&&"data"in n){const t={...r?.data,...n.data};e.mechanism.data=t}}function gt(t){if(function(t){try{return t.__sentry_captured__}catch{}}(t))return!0;try{it(t,"__sentry_captured__",!0)}catch(t){}return!1}var yt;function vt(t){return new _t((n=>{n(t)}))}function bt(t){return new _t(((n,e)=>{e(t)}))}!function(t){t[t.PENDING=0]="PENDING";t[t.RESOLVED=1]="RESOLVED";t[t.REJECTED=2]="REJECTED"}(yt||(yt={}));class _t{constructor(t){this.o=yt.PENDING,this.i=[],this.u(t)}then(t,n){return new _t(((e,r)=>{this.i.push([!1,n=>{if(t)try{e(t(n))}catch(t){r(t)}else e(n)},t=>{if(n)try{e(n(t))}catch(t){r(t)}else r(t)}]),this.l()}))}catch(t){return this.then((t=>t),t)}finally(t){return new _t(((n,e)=>{let r,o;return this.then((n=>{o=!1,r=n,t&&t()}),(n=>{o=!0,r=n,t&&t()})).then((()=>{o?e(r):n(r)}))}))}l(){if(this.o===yt.PENDING)return;const t=this.i.slice();this.i=[],t.forEach((t=>{t[0]||(this.o===yt.RESOLVED&&t[1](this.p),this.o===yt.REJECTED&&t[2](this.p),t[0]=!0)}))}u(t){const n=(t,n)=>{this.o===yt.PENDING&&(W(n)?n.then(e,r):(this.o=t,this.p=n,this.l()))},e=t=>{n(yt.RESOLVED,t)},r=t=>{n(yt.REJECTED,t)};try{t(e,r)}catch(t){r(t)}}}function St(t){const n=j(),e={sid:dt(),init:!0,timestamp:n,started:n,duration:0,status:"ok",errors:0,ignoreDuration:!1,toJSON:()=>function(t){return{sid:`${t.sid}`,init:t.init,started:new Date(1e3*t.started).toISOString(),timestamp:new Date(1e3*t.timestamp).toISOString(),status:t.status,errors:t.errors,did:"number"==typeof t.did||"string"==typeof t.did?`${t.did}`:void 0,duration:t.duration,abnormal_mechanism:t.abnormal_mechanism,attrs:{release:t.release,environment:t.environment,ip_address:t.ipAddress,user_agent:t.userAgent}}}(e)};return t&&wt(e,t),e}function wt(t,n={}){if(n.user&&(!t.ipAddress&&n.user.ip_address&&(t.ipAddress=n.user.ip_address),t.did||n.did||(t.did=n.user.id||n.user.email||n.user.username)),t.timestamp=n.timestamp||j(),n.abnormal_mechanism&&(t.abnormal_mechanism=n.abnormal_mechanism),n.ignoreDuration&&(t.ignoreDuration=n.ignoreDuration),n.sid&&(t.sid=32===n.sid.length?n.sid:dt()),void 0!==n.init&&(t.init=n.init),!t.did&&n.did&&(t.did=`${n.did}`),"number"==typeof n.started&&(t.started=n.started),t.ignoreDuration)t.duration=void 0;else if("number"==typeof n.duration)t.duration=n.duration;else{const n=t.timestamp-t.started;t.duration=n>=0?n:0}n.release&&(t.release=n.release),n.environment&&(t.environment=n.environment),!t.ipAddress&&n.ipAddress&&(t.ipAddress=n.ipAddress),!t.userAgent&&n.userAgent&&(t.userAgent=n.userAgent),"number"==typeof n.errors&&(t.errors=n.errors),n.status&&(t.status=n.status)}function Et(){return dt()}function Tt(){return dt().substring(16)}function kt(t,n,e=2){if(!n||"object"!=typeof n||e<=0)return n;if(t&&0===Object.keys(n).length)return t;const r={...t};for(const t in n)Object.prototype.hasOwnProperty.call(n,t)&&(r[t]=kt(r[t],n[t],e-1));return r}const $t="_sentrySpan";function xt(t,n){n?it(t,$t,n):delete t[$t]}function It(t){return t[$t]}class Rt{constructor(){this.h=!1,this.m=[],this.v=[],this._=[],this.S=[],this.T={},this.k={},this.I={},this.R={},this.O={},this.C={traceId:Et(),sampleRand:Math.random()}}clone(){const t=new Rt;return t._=[...this._],t.k={...this.k},t.I={...this.I},t.R={...this.R},this.R.flags&&(t.R.flags={values:[...this.R.flags.values]}),t.T=this.T,t.j=this.j,t.M=this.M,t.L=this.L,t.P=this.P,t.v=[...this.v],t.S=[...this.S],t.O={...this.O},t.C={...this.C},t.A=this.A,t.N=this.N,xt(t,It(this)),t}setClient(t){this.A=t}setLastEventId(t){this.N=t}getClient(){return this.A}lastEventId(){return this.N}addScopeListener(t){this.m.push(t)}addEventProcessor(t){return this.v.push(t),this}setUser(t){return this.T=t||{email:void 0,id:void 0,ip_address:void 0,username:void 0},this.M&&wt(this.M,{user:t}),this.D(),this}getUser(){return this.T}setTags(t){return this.k={...this.k,...t},this.D(),this}setTag(t,n){return this.k={...this.k,[t]:n},this.D(),this}setExtras(t){return this.I={...this.I,...t},this.D(),this}setExtra(t,n){return this.I={...this.I,[t]:n},this.D(),this}setFingerprint(t){return this.P=t,this.D(),this}setLevel(t){return this.j=t,this.D(),this}setTransactionName(t){return this.L=t,this.D(),this}setContext(t,n){return null===n?delete this.R[t]:this.R[t]=n,this.D(),this}setSession(t){return t?this.M=t:delete this.M,this.D(),this}getSession(){return this.M}update(t){if(!t)return this;const n="function"==typeof t?t(this):t,e=n instanceof Rt?n.getScopeData():B(n)?t:void 0,{tags:r,extra:o,user:i,contexts:s,level:c,fingerprint:a=[],propagationContext:u}=e||{};return this.k={...this.k,...r},this.I={...this.I,...o},this.R={...this.R,...s},i&&Object.keys(i).length&&(this.T=i),c&&(this.j=c),a.length&&(this.P=a),u&&(this.C=u),this}clear(){return this._=[],this.k={},this.I={},this.T={},this.R={},this.j=void 0,this.L=void 0,this.P=void 0,this.M=void 0,xt(this,void 0),this.S=[],this.setPropagationContext({traceId:Et(),sampleRand:Math.random()}),this.D(),this}addBreadcrumb(t,n){const e="number"==typeof n?n:100;if(e<=0)return this;const r={timestamp:C(),...t,message:t.message?tt(t.message,2048):t.message};return this._.push(r),this._.length>e&&(this._=this._.slice(-e),this.A?.recordDroppedEvent("buffer_overflow","log_item")),this.D(),this}getLastBreadcrumb(){return this._[this._.length-1]}clearBreadcrumbs(){return this._=[],this.D(),this}addAttachment(t){return this.S.push(t),this}clearAttachments(){return this.S=[],this}getScopeData(){return{breadcrumbs:this._,attachments:this.S,contexts:this.R,tags:this.k,extra:this.I,user:this.T,level:this.j,fingerprint:this.P||[],eventProcessors:this.v,propagationContext:this.C,sdkProcessingMetadata:this.O,transactionName:this.L,span:It(this)}}setSDKProcessingMetadata(t){return this.O=kt(this.O,t,2),this}setPropagationContext(t){return this.C=t,this}getPropagationContext(){return this.C}captureException(t,n){const e=n?.event_id||dt();if(!this.A)return u.warn("No client configured on scope - will not capture exception!"),e;const r=new Error("Sentry syntheticException");return this.A.captureException(t,{originalException:t,syntheticException:r,...n,event_id:e},this),e}captureMessage(t,n,e){const r=e?.event_id||dt();if(!this.A)return u.warn("No client configured on scope - will not capture message!"),r;const o=new Error(t);return this.A.captureMessage(t,n,{originalException:t,syntheticException:o,...e,event_id:r},this),r}captureEvent(t,n){const e=n?.event_id||dt();return this.A?(this.A.captureEvent(t,{...n,event_id:e},this),e):(u.warn("No client configured on scope - will not capture event!"),e)}D(){this.h||(this.h=!0,this.m.forEach((t=>{t(this)})),this.h=!1)}}class Ot{constructor(t,n){let e,r;e=t||new Rt,r=n||new Rt,this.F=[{scope:e}],this.q=r}withScope(t){const n=this.U();let e;try{e=t(n)}catch(t){throw this.H(),t}return W(e)?e.then((t=>(this.H(),t)),(t=>{throw this.H(),t})):(this.H(),e)}getClient(){return this.getStackTop().client}getScope(){return this.getStackTop().scope}getIsolationScope(){return this.q}getStackTop(){return this.F[this.F.length-1]}U(){const t=this.getScope().clone();return this.F.push({client:this.getClient(),scope:t}),t}H(){return!(this.F.length<=1)&&!!this.F.pop()}}function Ct(){const t=o(r());return t.stack=t.stack||new Ot(i("defaultCurrentScope",(()=>new Rt)),i("defaultIsolationScope",(()=>new Rt)))}function jt(t){return Ct().withScope(t)}function Mt(t,n){const e=Ct();return e.withScope((()=>(e.getStackTop().scope=t,n(t))))}function Lt(t){return Ct().withScope((()=>t(Ct().getIsolationScope())))}function Pt(t){const n=o(t);return n.acs?n.acs:{withIsolationScope:Lt,withScope:jt,withSetScope:Mt,withSetIsolationScope:(t,n)=>Lt(n),getCurrentScope:()=>Ct().getScope(),getIsolationScope:()=>Ct().getIsolationScope()}}function At(){return Pt(r()).getCurrentScope()}function Nt(){return Pt(r()).getIsolationScope()}function Dt(){return i("globalScope",(()=>new Rt))}function Ft(...t){const n=Pt(r());if(2===t.length){const[e,r]=t;return e?n.withSetScope(e,r):n.withScope(r)}return n.withScope(t[0])}function qt(){return At().getClient()}function Ut(t){const n=t.getPropagationContext(),{traceId:e,parentSpanId:r,propagationSpanId:o}=n,i={trace_id:e,span_id:o||Tt()};return r&&(i.parent_span_id=r),i}const Ht="sentry.source",Bt="sentry.sample_rate",zt="sentry.op",Wt="sentry.origin",Xt="sentry.idle_span_finish_reason",Jt="sentry.measurement_unit",Gt="sentry.measurement_value",Kt="sentry.custom_span_name",Vt="sentry.profile_id",Yt="sentry.exclusive_time",Zt=0,Qt=1,tn=2;function nn(t,n){t.setAttribute("http.response.status_code",n);const e=function(t){if(t<400&&t>=100)return{code:Qt};if(t>=400&&t<500)switch(t){case 401:return{code:tn,message:"unauthenticated"};case 403:return{code:tn,message:"permission_denied"};case 404:return{code:tn,message:"not_found"};case 409:return{code:tn,message:"already_exists"};case 413:return{code:tn,message:"failed_precondition"};case 429:return{code:tn,message:"resource_exhausted"};case 499:return{code:tn,message:"cancelled"};default:return{code:tn,message:"invalid_argument"}}if(t>=500&&t<600)switch(t){case 501:return{code:tn,message:"unimplemented"};case 503:return{code:tn,message:"unavailable"};case 504:return{code:tn,message:"deadline_exceeded"};default:return{code:tn,message:"internal_error"}}return{code:tn,message:"unknown_error"}}(n);"unknown_error"!==e.message&&t.setStatus(e)}const en="_sentryScope",rn="_sentryIsolationScope";function on(t){return{scope:t[en],isolationScope:t[rn]}}function sn(t){if("boolean"==typeof t)return Number(t);const n="string"==typeof t?parseFloat(t):t;return"number"!=typeof n||isNaN(n)||n<0||n>1?void 0:n}const cn="sentry-",an=/^sentry-/,un=8192;function fn(t){const n=function(t){if(!t||!q(t)&&!Array.isArray(t))return;if(Array.isArray(t))return t.reduce(((t,n)=>{const e=ln(n);return Object.entries(e).forEach((([n,e])=>{t[n]=e})),t}),{});return ln(t)}(t);if(!n)return;const e=Object.entries(n).reduce(((t,[n,e])=>{if(n.match(an)){t[n.slice(cn.length)]=e}return t}),{});return Object.keys(e).length>0?e:void 0}function dn(t){if(!t)return;return function(t){if(0===Object.keys(t).length)return;return Object.entries(t).reduce(((t,[n,e],r)=>{const o=`${encodeURIComponent(n)}=${encodeURIComponent(e)}`,i=0===r?o:`${t},${o}`;return i.length>un?t:i}),"")}(Object.entries(t).reduce(((t,[n,e])=>(e&&(t[`${cn}${n}`]=e),t)),{}))}function ln(t){return t.split(",").map((t=>t.split("=").map((t=>decodeURIComponent(t.trim()))))).reduce(((t,[n,e])=>(n&&e&&(t[n]=e),t)),{})}const pn=new RegExp("^[ \\t]*([0-9a-f]{32})?-?([0-9a-f]{16})?-?([01])?[ \\t]*$");function hn(t,n){const e=function(t){if(!t)return;const n=t.match(pn);if(!n)return;let e;return"1"===n[3]?e=!0:"0"===n[3]&&(e=!1),{traceId:n[1],parentSampled:e,parentSpanId:n[2]}}(t),r=fn(n);if(!e?.traceId)return{traceId:Et(),sampleRand:Math.random()};const o=function(t,n){const e=sn(n?.sample_rand);if(void 0!==e)return e;const r=sn(n?.sample_rate);return r&&void 0!==t?.parentSampled?t.parentSampled?Math.random()*r:r+Math.random()*(1-r):Math.random()}(e,r);r&&(r.sample_rand=o.toString());const{traceId:i,parentSpanId:s,parentSampled:c}=e;return{traceId:i,parentSpanId:s,sampled:c,dsc:r||{},sampleRand:o}}function mn(t=Et(),n=Tt(),e){let r="";return void 0!==e&&(r=e?"-1":"-0"),`${t}-${n}${r}`}const gn=1;let yn=!1;function vn(t){const{spanId:n,traceId:e}=t.spanContext(),{data:r,op:o,parent_span_id:i,status:s,origin:c,links:a}=Tn(t);return{parent_span_id:i,span_id:n,trace_id:e,data:r,op:o,status:s,origin:c,links:a}}function bn(t){const{spanId:n,traceId:e,isRemote:r}=t.spanContext(),o=r?n:Tn(t).parent_span_id,i=on(t).scope;return{parent_span_id:o,span_id:r?i?.getPropagationContext().propagationSpanId||Tt():n,trace_id:e}}function _n(t){const{traceId:n,spanId:e}=t.spanContext();return mn(n,e,kn(t))}function Sn(t){return t&&t.length>0?t.map((({context:{spanId:t,traceId:n,traceFlags:e,...r},attributes:o})=>({span_id:t,trace_id:n,sampled:e===gn,attributes:o,...r}))):void 0}function wn(t){return"number"==typeof t?En(t):Array.isArray(t)?t[0]+t[1]/1e9:t instanceof Date?En(t.getTime()):j()}function En(t){return t>9999999999?t/1e3:t}function Tn(t){if(function(t){return"function"==typeof t.getSpanJSON}(t))return t.getSpanJSON();const{spanId:n,traceId:e}=t.spanContext();if(function(t){const n=t;return!!(n.attributes&&n.startTime&&n.name&&n.endTime&&n.status)}(t)){const{attributes:r,startTime:o,name:i,endTime:s,parentSpanId:c,status:a,links:u}=t;return{span_id:n,trace_id:e,data:r,description:i,parent_span_id:c,start_timestamp:wn(o),timestamp:wn(s)||void 0,status:$n(a),op:r[zt],origin:r[Wt],links:Sn(u)}}return{span_id:n,trace_id:e,start_timestamp:0,data:{}}}function kn(t){const{traceFlags:n}=t.spanContext();return n===gn}function $n(t){if(t&&t.code!==Zt)return t.code===Qt?"ok":t.message||"unknown_error"}const xn="_sentryChildSpans",In="_sentryRootSpan";function Rn(t,n){const e=t[In]||t;it(n,In,e),t[xn]?t[xn].add(n):it(t,xn,new Set([n]))}function On(t){const n=new Set;return function t(e){if(!n.has(e)&&kn(e)){n.add(e);const r=e[xn]?Array.from(e[xn]):[];for(const n of r)t(n)}}(t),Array.from(n)}function Cn(t){return t[In]||t}function jn(){const t=Pt(r());return t.getActiveSpan?t.getActiveSpan():It(At())}function Mn(){yn||(a((()=>{console.warn("[Sentry] Returning null from `beforeSendSpan` is disallowed. To drop certain spans, configure the respective integrations directly.")})),yn=!0)}let Ln=!1;function Pn(){Ln||(Ln=!0,k(An),I(An))}function An(){const t=jn(),n=t&&Cn(t);if(n){const t="internal_error";n.setStatus({code:tn,message:t})}}function Nn(t){if("boolean"==typeof __SENTRY_TRACING__&&!__SENTRY_TRACING__)return!1;const n=t||qt()?.getOptions();return!(!n||null==n.tracesSampleRate&&!n.tracesSampler)}An.tag="sentry_tracingErrorCallback";const Dn="production",Fn="_frozenDsc";function qn(t,n){it(t,Fn,n)}function Un(t,n){const e=n.getOptions(),{publicKey:r}=n.getDsn()||{},o={environment:e.environment||Dn,release:e.release,public_key:r,trace_id:t};return n.emit("createDsc",o),o}function Hn(t,n){const e=n.getPropagationContext();return e.dsc||Un(e.traceId,t)}function Bn(t){const n=qt();if(!n)return{};const e=Cn(t),r=Tn(e),o=r.data,i=e.spanContext().traceState,s=i?.get("sentry.sample_rate")??o[Bt];function c(t){return"number"!=typeof s&&"string"!=typeof s||(t.sample_rate=`${s}`),t}const a=e[Fn];if(a)return c(a);const u=i?.get("sentry.dsc"),f=u&&fn(u);if(f)return c(f);const d=Un(t.spanContext().traceId,n),l=o[Ht],p=r.description;return"url"!==l&&p&&(d.transaction=p),Nn()&&(d.sampled=String(kn(e)),d.sample_rand=i?.get("sentry.sample_rand")??on(e).scope?.getPropagationContext().sampleRand.toString()),c(d),n.emit("createDsc",d,e),d}class zn{constructor(t={}){this.B=t.traceId||Et(),this.W=t.spanId||Tt()}spanContext(){return{spanId:this.W,traceId:this.B,traceFlags:0}}end(t){}setAttribute(t,n){return this}setAttributes(t){return this}setStatus(t){return this}updateName(t){return this}isRecording(){return!1}addEvent(t,n,e){return this}addLink(t){return this}addLinks(t){return this}recordException(t,n){}}function Wn(t,n,e=(()=>{})){let r;try{r=t()}catch(t){throw n(t),e(),t}return function(t,n,e){if(W(t))return t.then((t=>(e(),t)),(t=>{throw n(t),e(),t}));return e(),t}(r,n,e)}const Xn=/^(?:(\w+):)\/\/(?:(\w+)(?::(\w+)?)?@)([\w.-]+)(?::(\d+))?\/(.+)/;function Jn(t,n=!1){const{host:e,path:r,pass:o,port:i,projectId:s,protocol:c,publicKey:a}=t;return`${c}://${a}${n&&o?`:${o}`:""}@${e}${i?`:${i}`:""}/${r?`${r}/`:r}${s}`}function Gn(t){return{protocol:t.protocol,publicKey:t.publicKey||"",pass:t.pass||"",host:t.host,port:t.port||"",path:t.path||"",projectId:t.projectId}}function Kn(t){const n="string"==typeof t?function(t){const n=Xn.exec(t);if(!n)return void a((()=>{console.error(`Invalid Sentry Dsn: ${t}`)}));const[e,r,o="",i="",s="",c=""]=n.slice(1);let u="",f=c;const d=f.split("/");if(d.length>1&&(u=d.slice(0,-1).join("/"),f=d.pop()),f){const t=f.match(/^\d+/);t&&(f=t[0])}return Gn({host:i,pass:o,path:u,projectId:f,port:s,protocol:e,publicKey:r})}(t):Gn(t);if(n)return n}function Vn(t,n=100,e=1/0){try{return Zn("",t,n,e)}catch(t){return{ERROR:`**non-serializable** (${t})`}}}function Yn(t,n=3,e=102400){const r=Vn(t,n);return o=r,function(t){return~-encodeURI(t).split(/%..|./).length}(JSON.stringify(o))>e?Yn(t,n-1,e):r;var o}function Zn(t,n,e=1/0,r=1/0,o=function(){const t=new WeakSet;function n(n){return!!t.has(n)||(t.add(n),!1)}function e(n){t.delete(n)}return[n,e]}()){const[i,s]=o;if(null==n||["boolean","string"].includes(typeof n)||"number"==typeof n&&Number.isFinite(n))return n;const c=function(t,n){try{if("domain"===t&&n&&"object"==typeof n&&n.X)return"[Domain]";if("domainEmitter"===t)return"[DomainEmitter]";if("undefined"!=typeof global&&n===global)return"[Global]";if("undefined"!=typeof window&&n===window)return"[Window]";if("undefined"!=typeof document&&n===document)return"[Document]";if(J(n))return"[VueViewModel]";if(B(e=n)&&"nativeEvent"in e&&"preventDefault"in e&&"stopPropagation"in e)return"[SyntheticEvent]";if("number"==typeof n&&!Number.isFinite(n))return`[${n}]`;if("function"==typeof n)return`[Function: ${y(n)}]`;if("symbol"==typeof n)return`[${String(n)}]`;if("bigint"==typeof n)return`[BigInt: ${String(n)}]`;const r=function(t){const n=Object.getPrototypeOf(t);return n?.constructor?n.constructor.name:"null prototype"}(n);return/^HTML(\w*)Element$/.test(r)?`[HTMLElement: ${r}]`:`[object ${r}]`}catch(t){return`**non-serializable** (${t})`}var e}(t,n);if(!c.startsWith("[object "))return c;if(n.__sentry_skip_normalization__)return n;const a="number"==typeof n.__sentry_override_normalization_depth__?n.__sentry_override_normalization_depth__:e;if(0===a)return c.replace("object ","");if(i(n))return"[Circular ~]";const u=n;if(u&&"function"==typeof u.toJSON)try{return Zn("",u.toJSON(),a-1,r,o)}catch(t){}const f=Array.isArray(n)?[]:{};let d=0;const l=at(n);for(const t in l){if(!Object.prototype.hasOwnProperty.call(l,t))continue;if(d>=r){f[t]="[MaxProperties ~]";break}const n=l[t];f[t]=Zn(t,n,a-1,r,o),d++}return s(n),f}function Qn(t,n=[]){return[t,n]}function te(t,n){const[e,r]=t;return[e,[...r,n]]}function ne(t,n){const e=t[1];for(const t of e){if(n(t,t[0].type))return!0}return!1}function ee(t){const e=o(n);return e.encodePolyfill?e.encodePolyfill(t):(new TextEncoder).encode(t)}function re(t){const[n,e]=t;let r=JSON.stringify(n);function o(t){"string"==typeof r?r="string"==typeof t?r+t:[ee(r),t]:r.push("string"==typeof t?ee(t):t)}for(const t of e){const[n,e]=t;if(o(`\n${JSON.stringify(n)}\n`),"string"==typeof e||e instanceof Uint8Array)o(e);else{let t;try{t=JSON.stringify(e)}catch(n){t=JSON.stringify(Vn(e))}o(t)}}return"string"==typeof r?r:function(t){const n=t.reduce(((t,n)=>t+n.length),0),e=new Uint8Array(n);let r=0;for(const n of t)e.set(n,r),r+=n.length;return e}(r)}function oe(t){return[{type:"span"},t]}function ie(t){const n="string"==typeof t.data?ee(t.data):t.data;return[{type:"attachment",length:n.length,filename:t.filename,content_type:t.contentType,attachment_type:t.attachmentType},n]}const se={session:"session",sessions:"session",attachment:"attachment",transaction:"transaction",event:"error",client_report:"internal",user_report:"default",profile:"profile",profile_chunk:"profile",replay_event:"replay",replay_recording:"replay",check_in:"monitor",feedback:"feedback",span:"span",raw_security:"security",otel_log:"log_item"};function ce(t){return se[t]}function ae(t){if(!t?.sdk)return;const{name:n,version:e}=t.sdk;return{name:n,version:e}}function ue(t,n,e,r){const o=ae(e),i=t.type&&"replay_event"!==t.type?t.type:"event";!function(t,n){n&&(t.sdk=t.sdk||{},t.sdk.name=t.sdk.name||n.name,t.sdk.version=t.sdk.version||n.version,t.sdk.integrations=[...t.sdk.integrations||[],...n.integrations||[]],t.sdk.packages=[...t.sdk.packages||[],...n.packages||[]])}(t,e?.sdk);const s=function(t,n,e,r){const o=t.sdkProcessingMetadata?.dynamicSamplingContext;return{event_id:t.event_id,sent_at:(new Date).toISOString(),...n&&{sdk:n},...!!e&&r&&{dsn:Jn(r)},...o&&{trace:o}}}(t,o,r,n);delete t.sdkProcessingMetadata;return Qn(s,[[{type:i},t]])}function fe(t,n,e,r=jn()){const o=r&&Cn(r);o&&o.addEvent(t,{[Gt]:n,[Jt]:e})}function de(t){if(!t||0===t.length)return;const n={};return t.forEach((t=>{const e=t.attributes||{},r=e[Jt],o=e[Gt];"string"==typeof r&&"number"==typeof o&&(n[t.name]={value:o,unit:r})})),n}class le{constructor(t={}){this.B=t.traceId||Et(),this.W=t.spanId||Tt(),this.J=t.startTimestamp||j(),this.G=t.links,this.K={},this.setAttributes({[Wt]:"manual",[zt]:t.op,...t.attributes}),this.V=t.name,t.parentSpanId&&(this.Y=t.parentSpanId),"sampled"in t&&(this.Z=t.sampled),t.endTimestamp&&(this.tt=t.endTimestamp),this.X=[],this.nt=t.isStandalone,this.tt&&this.et()}addLink(t){return this.G?this.G.push(t):this.G=[t],this}addLinks(t){return this.G?this.G.push(...t):this.G=t,this}recordException(t,n){}spanContext(){const{W:t,B:n,Z:e}=this;return{spanId:t,traceId:n,traceFlags:e?gn:0}}setAttribute(t,n){return void 0===n?delete this.K[t]:this.K[t]=n,this}setAttributes(t){return Object.keys(t).forEach((n=>this.setAttribute(n,t[n]))),this}updateStartTime(t){this.J=wn(t)}setStatus(t){return this.rt=t,this}updateName(t){return this.V=t,this.setAttribute(Ht,"custom"),this}end(t){this.tt||(this.tt=wn(t),this.et())}getSpanJSON(){return{data:this.K,description:this.V,op:this.K[zt],parent_span_id:this.Y,span_id:this.W,start_timestamp:this.J,status:$n(this.rt),timestamp:this.tt,trace_id:this.B,origin:this.K[Wt],profile_id:this.K[Vt],exclusive_time:this.K[Yt],measurements:de(this.X),is_segment:this.nt&&Cn(this)===this||void 0,segment_id:this.nt?Cn(this).spanContext().spanId:void 0,links:Sn(this.G)}}isRecording(){return!this.tt&&!!this.Z}addEvent(t,n,e){const r=pe(n)?n:e||j(),o=pe(n)?{}:n||{},i={name:t,time:wn(r),attributes:o};return this.X.push(i),this}isStandaloneSpan(){return!!this.nt}et(){const t=qt();t&&t.emit("spanEnd",this);if(!(this.nt||this===Cn(this)))return;if(this.nt)return void(this.Z?function(t){const n=qt();if(!n)return;const e=t[1];if(!e||0===e.length)return void n.recordDroppedEvent("before_send","span");n.sendEnvelope(t)}(function(t,n){const e=Bn(t[0]),r=n?.getDsn(),o=n?.getOptions().tunnel,i={sent_at:(new Date).toISOString(),...function(t){return!!t.trace_id&&!!t.public_key}(e)&&{trace:e},...!!o&&r&&{dsn:Jn(r)}},s=n?.getOptions().beforeSendSpan,c=s?t=>{const n=Tn(t);return s(n)||(Mn(),n)}:Tn,a=[];for(const n of t){const t=c(n);t&&a.push(oe(t))}return Qn(i,a)}([this],t)):t&&t.recordDroppedEvent("sample_rate","span"));const n=this.ot();if(n){(on(this).scope||At()).captureEvent(n)}}ot(){if(!he(Tn(this)))return;this.V||(this.V="<unlabeled transaction>");const{scope:t,isolationScope:n}=on(this);if(!0!==this.Z)return;const e=On(this).filter((t=>t!==this&&!function(t){return t instanceof le&&t.isStandaloneSpan()}(t))).map((t=>Tn(t))).filter(he),r=this.K[Ht];delete this.K[Kt],e.forEach((t=>{delete t.data[Kt]}));const o={contexts:{trace:vn(this)},spans:e.length>1e3?e.sort(((t,n)=>t.start_timestamp-n.start_timestamp)).slice(0,1e3):e,start_timestamp:this.J,timestamp:this.tt,transaction:this.V,type:"transaction",sdkProcessingMetadata:{capturedSpanScope:t,capturedSpanIsolationScope:n,dynamicSamplingContext:Bn(this)},...r&&{transaction_info:{source:r}}},i=de(this.X);return i&&Object.keys(i).length&&(o.measurements=i),o}}function pe(t){return t&&"number"==typeof t||t instanceof Date||Array.isArray(t)}function he(t){return!!(t.start_timestamp&&t.timestamp&&t.span_id&&t.trace_id)}const me="__SENTRY_SUPPRESS_TRACING__";function ge(t){const n=_e();if(n.startInactiveSpan)return n.startInactiveSpan(t);const e=be(t),{forceTransaction:r,parentSpan:o}=t;return(t.scope?n=>Ft(t.scope,n):void 0!==o?t=>ye(o,t):t=>t())((()=>{const n=At(),o=we(n);return t.onlyIfParent&&!o?new zn:ve({parentSpan:o,spanArguments:e,forceTransaction:r,scope:n})}))}function ye(t,n){const e=_e();return e.withActiveSpan?e.withActiveSpan(t,n):Ft((e=>(xt(e,t||void 0),n(e))))}function ve({parentSpan:t,spanArguments:n,forceTransaction:e,scope:r}){if(!Nn()){const r=new zn;if(e||!t){qn(r,{sampled:"false",sample_rate:"0",transaction:n.name,...Bn(r)})}return r}const o=Nt();let i;if(t&&!e)i=function(t,n,e){const{spanId:r,traceId:o}=t.spanContext(),i=!n.getScopeData().sdkProcessingMetadata[me]&&kn(t),s=i?new le({...e,parentSpanId:r,traceId:o,sampled:i}):new zn({traceId:o});Rn(t,s);const c=qt();c&&(c.emit("spanStart",s),e.endTimestamp&&c.emit("spanEnd",s));return s}(t,r,n),Rn(t,i);else if(t){const e=Bn(t),{traceId:o,spanId:s}=t.spanContext(),c=kn(t);i=Se({traceId:o,parentSpanId:s,...n},r,c),qn(i,e)}else{const{traceId:t,dsc:e,parentSpanId:s,sampled:c}={...o.getPropagationContext(),...r.getPropagationContext()};i=Se({traceId:t,parentSpanId:s,...n},r,c),e&&qn(i,e)}return function(t,n,e){t&&(it(t,rn,e),it(t,en,n))}(i,r,o),i}function be(t){const n={isStandalone:(t.experimental||{}).standalone,...t};if(t.startTime){const e={...n};return e.startTimestamp=wn(t.startTime),delete e.startTime,e}return n}function _e(){return Pt(r())}function Se(t,n,e){const r=qt(),o=r?.getOptions()||{},{name:i="",attributes:s}=t,c=n.getPropagationContext(),[a,u,f]=n.getScopeData().sdkProcessingMetadata[me]?[!1]:function(t,n,e){if(!Nn(t))return[!1];let r,o;"function"==typeof t.tracesSampler?(o=t.tracesSampler({...n,inheritOrSampleWith:t=>"number"==typeof n.parentSampleRate?n.parentSampleRate:"boolean"==typeof n.parentSampled?Number(n.parentSampled):t}),r=!0):void 0!==n.parentSampled?o=n.parentSampled:void 0!==t.tracesSampleRate&&(o=t.tracesSampleRate,r=!0);const i=sn(o);return void 0===i?[!1]:i?[e<i,i,r]:[!1,i,r]}(o,{name:i,parentSampled:e,attributes:s,parentSampleRate:sn(c.dsc?.sample_rate)},c.sampleRand),d=new le({...t,attributes:{[Ht]:"custom",[Bt]:void 0!==u&&f?u:void 0,...t.attributes},sampled:a});return!a&&r&&r.recordDroppedEvent("sample_rate","transaction"),r&&r.emit("spanStart",d),d}function we(t){const n=It(t);if(!n)return;const e=qt();return(e?e.getOptions():{}).parentSpanIsAlwaysRootSpan?Cn(n):n}function Ee(t){return void 0!==t?n=>ye(t,n):t=>t()}const Te={idleTimeout:1e3,finalTimeout:3e4,childSpanTimeout:15e3},ke="heartbeatFailed",$e="idleTimeout",xe="finalTimeout",Ie="externalFinish";function Re(t,n={}){const e=new Map;let r,o=!1,i=Ie,s=!n.disableAutoFinish;const c=[],{idleTimeout:a=Te.idleTimeout,finalTimeout:f=Te.finalTimeout,childSpanTimeout:d=Te.childSpanTimeout,beforeSpanEnd:l}=n,p=qt();if(!p||!Nn()){const t=new zn;return qn(t,{sample_rate:"0",sampled:"false",...Bn(t)}),t}const h=At(),m=jn(),g=function(t){const n=ge(t);return xt(At(),n),n}(t);function y(){r&&(clearTimeout(r),r=void 0)}function v(t){y(),r=setTimeout((()=>{!o&&0===e.size&&s&&(i=$e,g.end(t))}),a)}function b(t){r=setTimeout((()=>{!o&&s&&(i=ke,g.end(t))}),d)}function _(t){o=!0,e.clear(),c.forEach((t=>t())),xt(h,m);const n=Tn(g),{start_timestamp:r}=n;if(!r)return;n.data[Xt]||g.setAttribute(Xt,i),u.log(`[Tracing] Idle span "${n.op}" finished`);const s=On(g).filter((t=>t!==g));let d=0;s.forEach((n=>{n.isRecording()&&(n.setStatus({code:tn,message:"cancelled"}),n.end(t));const e=Tn(n),{timestamp:r=0,start_timestamp:o=0}=e;r-o<=(f+a)/1e3&&o<=t||(!function(t,n){t[xn]&&t[xn].delete(n)}(g,n),d++)})),d>0&&g.setAttribute("sentry.idle_span_discarded_spans",d)}return g.end=new Proxy(g.end,{apply(t,n,e){if(l&&l(g),n instanceof zn)return;const[r,...o]=e,i=wn(r||j()),s=On(g).filter((t=>t!==g));if(!s.length)return _(i),Reflect.apply(t,n,[i,...o]);const c=s.map((t=>Tn(t).timestamp)).filter((t=>!!t)),a=c.length?Math.max(...c):void 0,u=Tn(g).start_timestamp,d=Math.min(u?u+f/1e3:1/0,Math.max(u||-1/0,Math.min(i,a||1/0)));return _(d),Reflect.apply(t,n,[d,...o])}}),c.push(p.on("spanStart",(t=>{if(o||t===g||Tn(t).timestamp)return;var n;On(g).includes(t)&&(n=t.spanContext().spanId,y(),e.set(n,!0),b(j()+d/1e3))}))),c.push(p.on("spanEnd",(t=>{var n;o||(n=t.spanContext().spanId,e.has(n)&&e.delete(n),0===e.size&&v(j()+a/1e3))}))),c.push(p.on("idleSpanEnableAutoFinish",(t=>{t===g&&(s=!0,v(),e.size&&b())}))),n.disableAutoFinish||v(),setTimeout((()=>{o||(g.setStatus({code:tn,message:"deadline_exceeded"}),i=xe,g.end())}),f),g}function Oe(t,n,e,r=0){return new _t(((o,i)=>{const s=t[r];if(null===n||"function"!=typeof s)o(n);else{const c=s({...n},e);W(c)?c.then((n=>Oe(t,n,e,r+1).then(o))).then(null,i):Oe(t,c,e,r+1).then(o).then(null,i)}}))}let Ce,je,Me;function Le(t,n){const{fingerprint:e,span:r,breadcrumbs:o,sdkProcessingMetadata:i}=n;!function(t,n){const{extra:e,tags:r,user:o,contexts:i,level:s,transactionName:c}=n;Object.keys(e).length&&(t.extra={...e,...t.extra});Object.keys(r).length&&(t.tags={...r,...t.tags});Object.keys(o).length&&(t.user={...o,...t.user});Object.keys(i).length&&(t.contexts={...i,...t.contexts});s&&(t.level=s);c&&"transaction"!==t.type&&(t.transaction=c)}(t,n),r&&function(t,n){t.contexts={trace:bn(n),...t.contexts},t.sdkProcessingMetadata={dynamicSamplingContext:Bn(n),...t.sdkProcessingMetadata};const e=Cn(n),r=Tn(e).description;r&&!t.transaction&&"transaction"===t.type&&(t.transaction=r)}(t,r),function(t,n){t.fingerprint=t.fingerprint?Array.isArray(t.fingerprint)?t.fingerprint:[t.fingerprint]:[],n&&(t.fingerprint=t.fingerprint.concat(n));t.fingerprint.length||delete t.fingerprint}(t,e),function(t,n){const e=[...t.breadcrumbs||[],...n];t.breadcrumbs=e.length?e:void 0}(t,o),function(t,n){t.sdkProcessingMetadata={...t.sdkProcessingMetadata,...n}}(t,i)}function Pe(t,n){const{extra:e,tags:r,user:o,contexts:i,level:s,sdkProcessingMetadata:c,breadcrumbs:a,fingerprint:u,eventProcessors:f,attachments:d,propagationContext:l,transactionName:p,span:h}=n;Ae(t,"extra",e),Ae(t,"tags",r),Ae(t,"user",o),Ae(t,"contexts",i),t.sdkProcessingMetadata=kt(t.sdkProcessingMetadata,c,2),s&&(t.level=s),p&&(t.transactionName=p),h&&(t.span=h),a.length&&(t.breadcrumbs=[...t.breadcrumbs,...a]),u.length&&(t.fingerprint=[...t.fingerprint,...u]),f.length&&(t.eventProcessors=[...t.eventProcessors,...f]),d.length&&(t.attachments=[...t.attachments,...d]),t.propagationContext={...t.propagationContext,...l}}function Ae(t,n,e){t[n]=kt(t[n],e,1)}function Ne(t,e,r,o,i,s){const{normalizeDepth:c=3,normalizeMaxBreadth:a=1e3}=t,u={...e,event_id:e.event_id||r.event_id||dt(),timestamp:e.timestamp||C()},f=r.integrations||t.integrations.map((t=>t.name));!function(t,n){const{environment:e,release:r,dist:o,maxValueLength:i=250}=n;t.environment=t.environment||e||Dn,!t.release&&r&&(t.release=r);!t.dist&&o&&(t.dist=o);const s=t.request;s?.url&&(s.url=tt(s.url,i))}(u,t),function(t,n){n.length>0&&(t.sdk=t.sdk||{},t.sdk.integrations=[...t.sdk.integrations||[],...n])}(u,f),i&&i.emit("applyFrameMetadata",e),void 0===e.type&&function(t,e){const r=function(t){const e=n._sentryDebugIds;if(!e)return{};const r=Object.keys(e);return Me&&r.length===je||(je=r.length,Me=r.reduce(((n,r)=>{Ce||(Ce={});const o=Ce[r];if(o)n[o[0]]=o[1];else{const o=t(r);for(let t=o.length-1;t>=0;t--){const i=o[t],s=i?.filename,c=e[r];if(s&&c){n[s]=c,Ce[r]=[s,c];break}}}return n}),{})),Me}(e);t.exception?.values?.forEach((t=>{t.stacktrace?.frames?.forEach((t=>{t.filename&&(t.debug_id=r[t.filename])}))}))}(u,t.stackParser);const d=function(t,n){if(!n)return t;const e=t?t.clone():new Rt;return e.update(n),e}(o,r.captureContext);r.mechanism&&mt(u,r.mechanism);const l=i?i.getEventProcessors():[],p=Dt().getScopeData();if(s){Pe(p,s.getScopeData())}if(d){Pe(p,d.getScopeData())}const h=[...r.attachments||[],...p.attachments];h.length&&(r.attachments=h),Le(u,p);return Oe([...l,...p.eventProcessors],u,r).then((t=>(t&&function(t){const n={};if(t.exception?.values?.forEach((t=>{t.stacktrace?.frames?.forEach((t=>{t.debug_id&&(t.abs_path?n[t.abs_path]=t.debug_id:t.filename&&(n[t.filename]=t.debug_id),delete t.debug_id)}))})),0===Object.keys(n).length)return;t.debug_meta=t.debug_meta||{},t.debug_meta.images=t.debug_meta.images||[];const e=t.debug_meta.images;Object.entries(n).forEach((([t,n])=>{e.push({type:"sourcemap",code_file:t,debug_id:n})}))}(t),"number"==typeof c&&c>0?function(t,n,e){if(!t)return null;const r={...t,...t.breadcrumbs&&{breadcrumbs:t.breadcrumbs.map((t=>({...t,...t.data&&{data:Vn(t.data,n,e)}})))},...t.user&&{user:Vn(t.user,n,e)},...t.contexts&&{contexts:Vn(t.contexts,n,e)},...t.extra&&{extra:Vn(t.extra,n,e)}};t.contexts?.trace&&r.contexts&&(r.contexts.trace=t.contexts.trace,t.contexts.trace.data&&(r.contexts.trace.data=Vn(t.contexts.trace.data,n,e)));t.spans&&(r.spans=t.spans.map((t=>({...t,...t.data&&{data:Vn(t.data,n,e)}}))));t.contexts?.flags&&r.contexts&&(r.contexts.flags=Vn(t.contexts.flags,3,e));return r}(t,c,a):t)))}function De(t){if(t)return function(t){return t instanceof Rt||"function"==typeof t}(t)||function(t){return Object.keys(t).some((t=>Fe.includes(t)))}(t)?{captureContext:t}:t}const Fe=["user","level","extra","contexts","tags","fingerprint","propagationContext"];function captureException(t,n){return At().captureException(t,De(n))}function qe(t,n){return At().captureEvent(t,n)}function Ue(){return Nt().lastEventId()}function He(t){const e=Nt(),r=At(),{userAgent:o}=n.navigator||{},i=St({user:r.getUser()||e.getUser(),...o&&{userAgent:o},...t}),s=e.getSession();return"ok"===s?.status&&wt(s,{status:"exited"}),Be(),e.setSession(i),i}function Be(){const t=Nt(),n=At().getSession()||t.getSession();n&&function(t,n){let e={};"ok"===t.status&&(e={status:"exited"}),wt(t,e)}(n),ze(),t.setSession()}function ze(){const t=Nt(),n=qt(),e=t.getSession();e&&n&&n.captureSession(e)}function We(t=!1){t?Be():ze()}const Xe="7";function Je(t){const n=t.protocol?`${t.protocol}:`:"",e=t.port?`:${t.port}`:"";return`${n}//${t.host}${e}${t.path?`/${t.path}`:""}/api/`}function Ge(t,n,e){return n||`${function(t){return`${Je(t)}${t.projectId}/envelope/`}(t)}?${function(t,n){const e={sentry_version:Xe};return t.publicKey&&(e.sentry_key=t.publicKey),n&&(e.sentry_client=`${n.name}/${n.version}`),new URLSearchParams(e).toString()}(t,e)}`}const Ke=[];function Ve(t){const n=t.defaultIntegrations||[],e=t.integrations;let r;if(n.forEach((t=>{t.isDefaultInstance=!0})),Array.isArray(e))r=[...n,...e];else if("function"==typeof e){const t=e(n);r=Array.isArray(t)?t:[t]}else r=n;return function(t){const n={};return t.forEach((t=>{const{name:e}=t,r=n[e];r&&!r.isDefaultInstance&&t.isDefaultInstance||(n[e]=t)})),Object.values(n)}(r)}function Ye(t,n){for(const e of n)e?.afterAllSetup&&e.afterAllSetup(t)}function Ze(t,n,e){if(!e[n.name]){if(e[n.name]=n,-1===Ke.indexOf(n.name)&&"function"==typeof n.setupOnce&&(n.setupOnce(),Ke.push(n.name)),n.setup&&"function"==typeof n.setup&&n.setup(t),"function"==typeof n.preprocessEvent){const e=n.preprocessEvent.bind(n);t.on("preprocessEvent",((n,r)=>e(n,r,t)))}if("function"==typeof n.processEvent){const e=n.processEvent.bind(n),r=Object.assign(((n,r)=>e(n,r,t)),{id:n.name});t.addEventProcessor(r)}}}const Qe=Symbol.for("SentryInternalError"),tr=Symbol.for("SentryDoNotSendEventError");function nr(t){return{message:t,[Qe]:!0}}function er(t){return{message:t,[tr]:!0}}class rr{constructor(t){if(this.it=t,this._integrations={},this.st=0,this.ct={},this.ut={},this.v=[],t.dsn&&(this.ft=Kn(t.dsn)),this.ft){const n=Ge(this.ft,t.tunnel,t._metadata?t._metadata.sdk:void 0);this.dt=t.transport({tunnel:this.it.tunnel,recordDroppedEvent:this.recordDroppedEvent.bind(this),...t.transportOptions,url:n})}}captureException(t,n,e){const r=dt();if(gt(t))return r;const o={event_id:r,...n};return this.lt(this.eventFromException(t,o).then((t=>this.ht(t,o,e)))),o.event_id}captureMessage(t,n,e,r){const o={event_id:dt(),...e},i=U(t)?t:String(t),s=H(t)?this.eventFromMessage(i,n,o):this.eventFromException(t,o);return this.lt(s.then((t=>this.ht(t,o,r)))),o.event_id}captureEvent(t,n,e){const r=dt();if(n?.originalException&>(n.originalException))return r;const o={event_id:r,...n},i=t.sdkProcessingMetadata||{},s=i.capturedSpanScope,c=i.capturedSpanIsolationScope;return this.lt(this.ht(t,o,s||e,c)),o.event_id}captureSession(t){this.sendSession(t),wt(t,{init:!1})}getDsn(){return this.ft}getOptions(){return this.it}getSdkMetadata(){return this.it._metadata}getTransport(){return this.dt}flush(t){const n=this.dt;return n?(this.emit("flush"),this.gt(t).then((e=>n.flush(t).then((t=>e&&t))))):vt(!0)}close(t){return this.flush(t).then((t=>(this.getOptions().enabled=!1,this.emit("close"),t)))}getEventProcessors(){return this.v}addEventProcessor(t){this.v.push(t)}init(){(this.yt()||this.it.integrations.some((({name:t})=>t.startsWith("Spotlight"))))&&this.vt()}getIntegrationByName(t){return this._integrations[t]}addIntegration(t){const n=this._integrations[t.name];Ze(this,t,this._integrations),n||Ye(this,[t])}sendEvent(t,n={}){this.emit("beforeSendEvent",t,n);let e=ue(t,this.ft,this.it._metadata,this.it.tunnel);for(const t of n.attachments||[])e=te(e,ie(t));const r=this.sendEnvelope(e);r&&r.then((n=>this.emit("afterSendEvent",t,n)),null)}sendSession(t){const{release:n,environment:e=Dn}=this.it;if("aggregates"in t){const r=t.attrs||{};if(!r.release&&!n)return;r.release=r.release||n,r.environment=r.environment||e,t.attrs=r}else{if(!t.release&&!n)return;t.release=t.release||n,t.environment=t.environment||e}this.emit("beforeSendSession",t);const r=function(t,n,e,r){const o=ae(e);return Qn({sent_at:(new Date).toISOString(),...o&&{sdk:o},...!!r&&n&&{dsn:Jn(n)}},["aggregates"in t?[{type:"sessions"},t]:[{type:"session"},t.toJSON()]])}(t,this.ft,this.it._metadata,this.it.tunnel);this.sendEnvelope(r)}recordDroppedEvent(t,n,e=1){if(this.it.sendClientReports){const r=`${t}:${n}`;this.ct[r]=(this.ct[r]||0)+e}}on(t,n){const e=this.ut[t]=this.ut[t]||[];return e.push(n),()=>{const t=e.indexOf(n);t>-1&&e.splice(t,1)}}emit(t,...n){const e=this.ut[t];e&&e.forEach((t=>t(...n)))}sendEnvelope(t){return this.emit("beforeEnvelope",t),this.yt()&&this.dt?this.dt.send(t).then(null,(t=>t)):vt({})}vt(){const{integrations:t}=this.it;this._integrations=function(t,n){const e={};return n.forEach((n=>{n&&Ze(t,n,e)})),e}(this,t),Ye(this,t)}bt(t,n){let e="fatal"===n.level,r=!1;const o=n.exception?.values;if(o){r=!0;for(const t of o){const n=t.mechanism;if(!1===n?.handled){e=!0;break}}}const i="ok"===t.status;(i&&0===t.errors||i&&e)&&(wt(t,{...e&&{status:"crashed"},errors:t.errors||Number(r||e)}),this.captureSession(t))}gt(t){return new _t((n=>{let e=0;const r=setInterval((()=>{0==this.st?(clearInterval(r),n(!0)):(e+=1,t&&e>=t&&(clearInterval(r),n(!1)))}),1)}))}yt(){return!1!==this.getOptions().enabled&&void 0!==this.dt}_t(t,n,e,r){const o=this.getOptions(),i=Object.keys(this._integrations);return!n.integrations&&i?.length&&(n.integrations=i),this.emit("preprocessEvent",t,n),t.type||r.setLastEventId(t.event_id||n.event_id),Ne(o,t,n,e,this,r).then((t=>{if(null===t)return t;this.emit("postprocessEvent",t,n),t.contexts={trace:Ut(e),...t.contexts};const r=Hn(this,e);return t.sdkProcessingMetadata={dynamicSamplingContext:r,...t.sdkProcessingMetadata},t}))}ht(t,n={},e=At(),r=Nt()){return this.St(t,n,e,r).then((t=>t.event_id),(t=>{}))}St(t,n,e,r){const o=this.getOptions(),{sampleRate:i}=o,s=ir(t),c=or(t),a=t.type||"error",u=`before send for type \`${a}\``,f=void 0===i?void 0:sn(i);if(c&&"number"==typeof f&&Math.random()>f)return this.recordDroppedEvent("sample_rate","error"),bt(er(`Discarding event because it's not included in the random sample (sampling rate = ${i})`));const d="replay_event"===a?"replay":a;return this._t(t,n,e,r).then((t=>{if(null===t)throw this.recordDroppedEvent("event_processor",d),er("An event processor returned `null`, will not send event.");if(n.data&&!0===n.data.__sentry__)return t;const e=function(t,n,e,r){const{beforeSend:o,beforeSendTransaction:i,beforeSendSpan:s}=n;let c=e;if(or(c)&&o)return o(c,r);if(ir(c)){if(s){const t=s(function(t){const{trace_id:n,parent_span_id:e,span_id:r,status:o,origin:i,data:s,op:c}=t.contexts?.trace??{};return{data:s??{},description:t.transaction,op:c,parent_span_id:e,span_id:r??"",start_timestamp:t.start_timestamp??0,status:o,timestamp:t.timestamp,trace_id:n??"",origin:i,profile_id:s?.[Vt],exclusive_time:s?.[Yt],measurements:t.measurements,is_segment:!0}}(c));if(t?c=kt(e,{type:"transaction",timestamp:(a=t).timestamp,start_timestamp:a.start_timestamp,transaction:a.description,contexts:{trace:{trace_id:a.trace_id,span_id:a.span_id,parent_span_id:a.parent_span_id,op:a.op,status:a.status,origin:a.origin,data:{...a.data,...a.profile_id&&{[Vt]:a.profile_id},...a.exclusive_time&&{[Yt]:a.exclusive_time}}}},measurements:a.measurements}):Mn(),c.spans){const t=[];for(const n of c.spans){const e=s(n);e?t.push(e):(Mn(),t.push(n))}c.spans=t}}if(i){if(c.spans){const t=c.spans.length;c.sdkProcessingMetadata={...e.sdkProcessingMetadata,spanCountBeforeProcessing:t}}return i(c,r)}}var a;return c}(0,o,t,n);return function(t,n){const e=`${n} must return \`null\` or a valid event.`;if(W(t))return t.then((t=>{if(!B(t)&&null!==t)throw nr(e);return t}),(t=>{throw nr(`${n} rejected with ${t}`)}));if(!B(t)&&null!==t)throw nr(e);return t}(e,u)})).then((o=>{if(null===o){if(this.recordDroppedEvent("before_send",d),s){const n=1+(t.spans||[]).length;this.recordDroppedEvent("before_send","span",n)}throw er(`${u} returned \`null\`, will not send event.`)}const i=e.getSession()||r.getSession();if(c&&i&&this.bt(i,o),s){const t=(o.sdkProcessingMetadata?.spanCountBeforeProcessing||0)-(o.spans?o.spans.length:0);t>0&&this.recordDroppedEvent("before_send","span",t)}const a=o.transaction_info;if(s&&a&&o.transaction!==t.transaction){const t="custom";o.transaction_info={...a,source:t}}return this.sendEvent(o,n),o})).then(null,(t=>{if((n=t)&&"object"==typeof n&&tr in n||function(t){return!!t&&"object"==typeof t&&Qe in t}(t))throw t;var n;throw this.captureException(t,{data:{__sentry__:!0},originalException:t}),nr(`Event processing pipeline threw an error, original event will not be sent. Details have been sent as a new event.\nReason: ${t}`)}))}lt(t){this.st++,t.then((t=>(this.st--,t)),(t=>(this.st--,t)))}wt(){const t=this.ct;return this.ct={},Object.entries(t).map((([t,n])=>{const[e,r]=t.split(":");return{reason:e,category:r,quantity:n}}))}Et(){const t=this.wt();if(0===t.length)return;if(!this.ft)return;const n=(e=t,Qn((r=this.it.tunnel&&Jn(this.ft))?{dsn:r}:{},[[{type:"client_report"},{timestamp:C(),discarded_events:e}]]));var e,r;this.sendEnvelope(n)}}function or(t){return void 0===t.type}function ir(t){return"transaction"===t.type}function sr(t){return[{type:"otel_log"},t]}const cr=new WeakMap;function ar(t,n){const e=cr.get(t)??[];if(0===e.length)return;const r=t.getOptions(),o=function(t,n,e,r){const o={};return n?.sdk&&(o.sdk={name:n.sdk.name,version:n.sdk.version}),e&&r&&(o.dsn=Jn(r)),Qn(o,t.map(sr))}(e,r._metadata,r.tunnel,t.getDsn());e.length=0,t.sendEnvelope(o)}function ur(t){At().setClient(t)}const fr=Symbol.for("SentryBufferFullError");function dr(t){const n=[];function e(t){return n.splice(n.indexOf(t),1)[0]||Promise.resolve(void 0)}return{$:n,add:function(r){if(!(void 0===t||n.length<t))return bt(fr);const o=r();return-1===n.indexOf(o)&&n.push(o),o.then((()=>e(o))).then(null,(()=>e(o).then(null,(()=>{})))),o},drain:function(t){return new _t(((e,r)=>{let o=n.length;if(!o)return e(!0);const i=setTimeout((()=>{t&&t>0&&e(!1)}),t);n.forEach((t=>{vt(t).then((()=>{--o||(clearTimeout(i),e(!0))}),r)}))}))}}}const lr=6e4;function pr(t,{statusCode:n,headers:e},r=Date.now()){const o={...t},i=e?.["x-sentry-rate-limits"],s=e?.["retry-after"];if(i)for(const t of i.trim().split(",")){const[n,e,,,i]=t.split(":",5),s=parseInt(n,10),c=1e3*(isNaN(s)?60:s);if(e)for(const t of e.split(";"))"metric_bucket"===t&&i&&!i.split(";").includes("custom")||(o[t]=r+c);else o.all=r+c}else s?o.all=r+function(t,n=Date.now()){const e=parseInt(`${t}`,10);if(!isNaN(e))return 1e3*e;const r=Date.parse(`${t}`);return isNaN(r)?lr:r-n}(s,r):429===n&&(o.all=r+6e4);return o}const hr=64;function mr(t,n,e=dr(t.bufferSize||hr)){let r={};return{send:function(o){const i=[];if(ne(o,((n,e)=>{const o=ce(e);!function(t,n,e=Date.now()){return function(t,n){return t[n]||t.all||0}(t,n)>e}(r,o)?i.push(n):t.recordDroppedEvent("ratelimit_backoff",o)})),0===i.length)return vt({});const s=Qn(o[0],i),c=n=>{ne(s,((e,r)=>{t.recordDroppedEvent(n,ce(r))}))};return e.add((()=>n({body:re(s)}).then((t=>(r=pr(r,t),t)),(t=>{throw c("network_error"),t})))).then((t=>t),(t=>{if(t===fr)return c("queue_overflow"),vt({});throw t}))},flush:t=>e.drain(t)}}function gr(t){void 0===t.user?.ip_address&&(t.user={...t.user,ip_address:"{{auto}}"})}function yr(t){"aggregates"in t?void 0===t.attrs?.ip_address&&(t.attrs={...t.attrs,ip_address:"{{auto}}"}):void 0===t.ipAddress&&(t.ipAddress="{{auto}}")}function vr(t={}){const n=qt();if(!function(){const t=qt();return!1!==t?.getOptions().enabled&&!!t?.getTransport()}()||!n)return{};const e=Pt(r());if(e.getTraceData)return e.getTraceData(t);const o=At(),i=t.span||jn(),s=i?_n(i):function(t){const{traceId:n,sampled:e,propagationSpanId:r}=t.getPropagationContext();return mn(n,r,e)}(o),c=dn(i?Bn(i):Hn(n,o));return pn.test(s)?{"sentry-trace":s,baggage:c}:(u.warn("Invalid sentry-trace data. Cannot generate trace data"),{})}const br=100;function _r(t,n){const e=qt(),r=Nt();if(!e)return;const{beforeBreadcrumb:o=null,maxBreadcrumbs:i=br}=e.getOptions();if(i<=0)return;const s={timestamp:C(),...t},c=o?a((()=>o(s,n))):s;null!==c&&(e.emit&&e.emit("beforeAddBreadcrumb",c,n),r.addBreadcrumb(c,i))}let Sr;const wr=new WeakMap,Er=()=>({name:"FunctionToString",setupOnce(){Sr=Function.prototype.toString;try{Function.prototype.toString=function(...t){const n=ct(this),e=wr.has(qt())&&void 0!==n?n:this;return Sr.apply(e,t)}}catch{}},setup(t){wr.set(t,!0)}}),Tr=[/^Script error\.?$/,/^Javascript error: Script error\.? on line 0$/,/^ResizeObserver loop completed with undelivered notifications.$/,/^Cannot redefine property: googletag$/,/^Can't find variable: gmo$/,/^undefined is not an object \(evaluating 'a\.[A-Z]'\)$/,'can\'t redefine non-configurable property "solana"',"vv().getRestrictions is not a function. (In 'vv().getRestrictions(1,a)', 'vv().getRestrictions' is undefined)","Can't find variable: _AutofillCallbackHandler",/^Non-Error promise rejection captured with value: Object Not Found Matching Id:\d+, MethodName:simulateEvent, ParamCount:\d+$/,/^Java exception was raised during method invocation$/],kr=(t={})=>{let n;return{name:"EventFilters",setup(e){const r=e.getOptions();n=xr(t,r)},processEvent(e,r,o){if(!n){const e=o.getOptions();n=xr(t,e)}return function(t,n){if(t.type){if("transaction"===t.type&&function(t,n){if(!n?.length)return!1;const e=t.transaction;return!!e&&rt(e,n)}(t,n.ignoreTransactions))return!0}else{if(function(t,n){if(!n?.length)return!1;return function(t){const n=[];t.message&&n.push(t.message);try{const e=t.exception.values[t.exception.values.length-1];e?.value&&(n.push(e.value),e.type&&n.push(`${e.type}: ${e.value}`))}catch(t){}return n}(t).some((t=>rt(t,n)))}(t,n.ignoreErrors))return!0;if(function(t){if(!t.exception?.values?.length)return!1;return!t.message&&!t.exception.values.some((t=>t.stacktrace||t.type&&"Error"!==t.type||t.value))}(t))return!0;if(function(t,n){if(!n?.length)return!1;const e=Ir(t);return!!e&&rt(e,n)}(t,n.denyUrls))return!0;if(!function(t,n){if(!n?.length)return!0;const e=Ir(t);return!e||rt(e,n)}(t,n.allowUrls))return!0}return!1}(e,n)?null:e}}},$r=(t={})=>({...kr(t),name:"InboundFilters"});function xr(t={},n={}){return{allowUrls:[...t.allowUrls||[],...n.allowUrls||[]],denyUrls:[...t.denyUrls||[],...n.denyUrls||[]],ignoreErrors:[...t.ignoreErrors||[],...n.ignoreErrors||[],...t.disableErrorDefaults?[]:Tr],ignoreTransactions:[...t.ignoreTransactions||[],...n.ignoreTransactions||[]]}}function Ir(t){try{const n=[...t.exception?.values??[]].reverse().find((t=>void 0===t.mechanism?.parent_id&&t.stacktrace?.frames?.length)),e=n?.stacktrace?.frames;return e?function(t=[]){for(let n=t.length-1;n>=0;n--){const e=t[n];if(e&&"<anonymous>"!==e.filename&&"[native code]"!==e.filename)return e.filename||null}return null}(e):null}catch(t){return null}}function Rr(t,n,e,r,o,i){if(!o.exception?.values||!i||!X(i.originalException,Error))return;const s=o.exception.values.length>0?o.exception.values[o.exception.values.length-1]:void 0;s&&(o.exception.values=Or(t,n,r,i.originalException,e,o.exception.values,s,0))}function Or(t,n,e,r,o,i,s,c){if(i.length>=e+1)return i;let a=[...i];if(X(r[o],Error)){Cr(s,c);const i=t(n,r[o]),u=a.length;jr(i,o,u,c),a=Or(t,n,e,r[o],o,[i,...a],i,u)}return Array.isArray(r.errors)&&r.errors.forEach(((r,i)=>{if(X(r,Error)){Cr(s,c);const u=t(n,r),f=a.length;jr(u,`errors[${i}]`,f,c),a=Or(t,n,e,r,o,[u,...a],u,f)}})),a}function Cr(t,n){t.mechanism=t.mechanism||{type:"generic",handled:!0},t.mechanism={...t.mechanism,..."AggregateError"===t.type&&{is_exception_group:!0},exception_id:n}}function jr(t,n,e,r){t.mechanism=t.mechanism||{type:"generic",handled:!0},t.mechanism={...t.mechanism,type:"chained",source:n,exception_id:e,parent_id:r}}function Mr(){"console"in n&&s.forEach((function(t){t in n.console&&ot(n.console,t,(function(e){return c[t]=e,function(...e){E("console",{args:e,level:t});const r=c[t];r?.apply(n.console,e)}}))}))}function Lr(t){return"warn"===t?"warning":["fatal","error","warning","log","info","debug"].includes(t)?t:"log"}const Pr=()=>{let t;return{name:"Dedupe",processEvent(n){if(n.type)return n;try{if(function(t,n){if(!n)return!1;if(function(t,n){const e=t.message,r=n.message;if(!e&&!r)return!1;if(e&&!r||!e&&r)return!1;if(e!==r)return!1;if(!Nr(t,n))return!1;if(!Ar(t,n))return!1;return!0}(t,n))return!0;if(function(t,n){const e=Dr(n),r=Dr(t);if(!e||!r)return!1;if(e.type!==r.type||e.value!==r.value)return!1;if(!Nr(t,n))return!1;if(!Ar(t,n))return!1;return!0}(t,n))return!0;return!1}(n,t))return null}catch(t){}return t=n}}};function Ar(t,n){let e=v(t),r=v(n);if(!e&&!r)return!0;if(e&&!r||!e&&r)return!1;if(r.length!==e.length)return!1;for(let t=0;t<r.length;t++){const n=r[t],o=e[t];if(n.filename!==o.filename||n.lineno!==o.lineno||n.colno!==o.colno||n.function!==o.function)return!1}return!0}function Nr(t,n){let e=t.fingerprint,r=n.fingerprint;if(!e&&!r)return!0;if(e&&!r||!e&&r)return!1;try{return!(e.join("")!==r.join(""))}catch(t){return!1}}function Dr(t){return t.exception?.values&&t.exception.values[0]}const Fr="thismessage:/";function qr(t){return"isRelative"in t}function Ur(t){if(qr(t))return t.pathname;const n=new URL(t);return n.search="",n.hash="",["80","443"].includes(n.port)&&(n.port=""),n.password&&(n.password="%filtered%"),n.username&&(n.username="%filtered%"),n.toString()}function Hr(t){if(!t)return{};const n=t.match(/^(([^:/?#]+):)?(\/\/([^/?#]*))?([^?#]*)(\?([^#]*))?(#(.*))?$/);if(!n)return{};const e=n[6]||"",r=n[8]||"";return{host:n[4],path:n[5],protocol:n[2],search:e,hash:r,relative:n[5]+e+r}}function Br(t,n,e,r,o="auto.http.browser"){if(!t.fetchData)return;const{method:i,url:s}=t.fetchData,c=Nn()&&n(s);if(t.endTimestamp&&c){const n=t.fetchData.__span;if(!n)return;const e=r[n];return void(e&&(!function(t,n){if(n.response){nn(t,n.response.status);const e=n.response?.headers&&n.response.headers.get("content-length");if(e){const n=parseInt(e);n>0&&t.setAttribute("http.response_content_length",n)}}else n.error&&t.setStatus({code:tn,message:"internal_error"});t.end()}(e,t),delete r[n]))}const a=!!jn(),u=c&&a?ge(function(t,n,e){const r=function(t,n){const e=t.startsWith("/"),r=e?Fr:void 0;try{if("canParse"in URL&&!URL.canParse(t,r))return;const n=new URL(t,r);return e?{isRelative:e,pathname:n.pathname,search:n.search,hash:n.hash}:n}catch{}}(t);return{name:r?`${n} ${Ur(r)}`:n,attributes:Wr(t,r,n,e)}}(s,i,o)):new zn;if(t.fetchData.__span=u.spanContext().spanId,r[u.spanContext().spanId]=u,e(t.fetchData.url)){const n=t.args[0],e=t.args[1]||{},r=function(t,n,e){const r=vr({span:e}),o=r["sentry-trace"],i=r.baggage;if(!o)return;const s=n.headers||(function(t){return"undefined"!=typeof Request&&X(t,Request)}(t)?t.headers:void 0);if(s){if(function(t){return"undefined"!=typeof Headers&&X(t,Headers)}(s)){const t=new Headers(s);if(t.set("sentry-trace",o),i){const n=t.get("baggage");if(n){const e=zr(n);t.set("baggage",e?`${e},${i}`:i)}else t.set("baggage",i)}return t}if(Array.isArray(s)){const t=[...s.filter((t=>!(Array.isArray(t)&&"sentry-trace"===t[0]))).map((t=>{if(Array.isArray(t)&&"baggage"===t[0]&&"string"==typeof t[1]){const[n,e,...r]=t;return[n,zr(e),...r]}return t})),["sentry-trace",o]];return i&&t.push(["baggage",i]),t}{const t="baggage"in s?s.baggage:void 0;let n=[];return Array.isArray(t)?n=t.map((t=>"string"==typeof t?zr(t):t)).filter((t=>""===t)):t&&n.push(zr(t)),i&&n.push(i),{...s,"sentry-trace":o,baggage:n.length>0?n.join(","):void 0}}}return{...r}}(n,e,Nn()&&a?u:void 0);r&&(t.args[1]=e,e.headers=r)}const f=qt();if(f){const n={input:t.args,response:t.response,startTimestamp:t.startTimestamp,endTimestamp:t.endTimestamp};f.emit("beforeOutgoingRequestSpan",u,n)}return u}function zr(t){return t.split(",").filter((t=>!t.split("=")[0].startsWith(cn))).join(",")}function Wr(t,n,e,r){const o={url:t,type:"fetch","http.method":e,[Wt]:r,[zt]:"http.client"};return n&&(qr(n)||(o["http.url"]=n.href,o["server.address"]=n.host),n.search&&(o["http.query"]=n.search),n.hash&&(o["http.fragment"]=n.hash)),o}function Xr(t){return void 0===t?void 0:t>=400&&t<500?"warning":t>=500?"error":void 0}const Jr=n;function Gr(t){return t&&/^function\s+\w+\(\)\s+\{\s+\[native code\]\s+\}$/.test(t.toString())}function Kr(){if("string"==typeof EdgeRuntime)return!0;if(!function(){if(!("fetch"in Jr))return!1;try{return new Headers,new Request("http://www.example.com"),new Response,!0}catch(t){return!1}}())return!1;if(Gr(Jr.fetch))return!0;let t=!1;const n=Jr.document;if(n&&"function"==typeof n.createElement)try{const e=n.createElement("iframe");e.hidden=!0,n.head.appendChild(e),e.contentWindow?.fetch&&(t=Gr(e.contentWindow.fetch)),n.head.removeChild(e)}catch(t){}return t}function Vr(t,n){const e="fetch";S(e,t),w(e,(()=>Yr(void 0,n)))}function Yr(t,e=!1){e&&!Kr()||ot(n,"fetch",(function(e){return function(...r){const o=new Error,{method:i,url:s}=function(t){if(0===t.length)return{method:"GET",url:""};if(2===t.length){const[n,e]=t;return{url:to(n),method:Qr(e,"method")?String(e.method).toUpperCase():"GET"}}const n=t[0];return{url:to(n),method:Qr(n,"method")?String(n.method).toUpperCase():"GET"}}(r),c={args:r,fetchData:{method:i,url:s},startTimestamp:1e3*j(),virtualError:o};return t||E("fetch",{...c}),e.apply(n,r).then((async n=>(t?t(n):E("fetch",{...c,endTimestamp:1e3*j(),response:n}),n)),(t=>{if(E("fetch",{...c,endTimestamp:1e3*j(),error:t}),A(t)&&void 0===t.stack&&(t.stack=o.stack,it(t,"framesToPop",1)),t instanceof TypeError&&("Failed to fetch"===t.message||"Load failed"===t.message||"NetworkError when attempting to fetch resource."===t.message))try{const n=new URL(c.fetchData.url);t.message=`${t.message} (${n.host})`}catch{}throw t}))}}))}function Zr(t){let n;try{n=t.clone()}catch{return}!async function(t,n){if(t?.body){const e=t.body,r=e.getReader(),o=setTimeout((()=>{e.cancel().then(null,(()=>{}))}),9e4);let i=!0;for(;i;){let t;try{t=setTimeout((()=>{e.cancel().then(null,(()=>{}))}),5e3);const{done:o}=await r.read();clearTimeout(t),o&&(n(),i=!1)}catch(t){i=!1}finally{clearTimeout(t)}}clearTimeout(o),r.releaseLock(),e.cancel().then(null,(()=>{}))}}(n,(()=>{E("fetch-body-resolved",{endTimestamp:1e3*j(),response:t})}))}function Qr(t,n){return!!t&&"object"==typeof t&&!!t[n]}function to(t){return"string"==typeof t?t:t?Qr(t,"url")?t.url:t.toString?t.toString():"":""}const no=()=>{},eo=["attachTo","createForm","createWidget","remove"],ro=Object.assign((t=>(a((()=>{console.warn("You are using feedbackIntegration() even though this bundle does not include feedback.")})),{name:"Feedback",...eo.reduce(((t,n)=>(t[n]=no,t)),{})})),{_isShim:!0}),oo=["start","stop","flush"];const io=n;let so=0;function co(){return so>0}function ao(t,n={}){if(!function(t){return"function"==typeof t}(t))return t;try{const n=t.__sentry_wrapped__;if(n)return"function"==typeof n?n:t;if(ct(t))return t}catch(n){return t}const sentryWrapped=function(...e){try{const r=e.map((t=>ao(t,n)));return t.apply(this,r)}catch(t){throw so++,setTimeout((()=>{so--})),Ft((r=>{r.addEventProcessor((t=>(n.mechanism&&(ht(t,void 0),mt(t,n.mechanism)),t.extra={...t.extra,arguments:e},t))),captureException(t)})),t}};try{for(const n in t)Object.prototype.hasOwnProperty.call(t,n)&&(sentryWrapped[n]=t[n])}catch{}st(sentryWrapped,t),it(t,"__sentry_wrapped__",sentryWrapped);try{Object.getOwnPropertyDescriptor(sentryWrapped,"name").configurable&&Object.defineProperty(sentryWrapped,"name",{get:()=>t.name})}catch{}return sentryWrapped}function uo(t,n){const e=po(t,n),r={type:go(n),value:yo(n)};return e.length&&(r.stacktrace={frames:e}),void 0===r.type&&""===r.value&&(r.value="Unrecoverable error caught"),r}function fo(t,n,e,r){const o=qt(),i=o?.getOptions().normalizeDepth,s=function(t){for(const n in t)if(Object.prototype.hasOwnProperty.call(t,n)){const e=t[n];if(e instanceof Error)return e}return}(n),c={__serialized__:Yn(n,i)};if(s)return{exception:{values:[uo(t,s)]},extra:c};const a={exception:{values:[{type:z(n)?n.constructor.name:r?"UnhandledRejection":"Error",value:wo(n,{isUnhandledRejection:r})}]},extra:c};if(e){const n=po(t,e);n.length&&(a.exception.values[0].stacktrace={frames:n})}return a}function lo(t,n){return{exception:{values:[uo(t,n)]}}}function po(t,n){const e=n.stacktrace||n.stack||"",r=function(t){if(t&&ho.test(t.message))return 1;return 0}(n),o=function(t){if("number"==typeof t.framesToPop)return t.framesToPop;return 0}(n);try{return t(e,r,o)}catch(t){}return[]}const ho=/Minified React error #\d+;/i;function mo(t){return"undefined"!=typeof WebAssembly&&void 0!==WebAssembly.Exception&&t instanceof WebAssembly.Exception}function go(t){const n=t?.name;if(!n&&mo(t)){return t.message&&Array.isArray(t.message)&&2==t.message.length?t.message[0]:"WebAssembly.Exception"}return n}function yo(t){const n=t?.message;return mo(t)?Array.isArray(t.message)&&2==t.message.length?t.message[1]:"wasm exception":n?n.error&&"string"==typeof n.error.message?n.error.message:n:"No error message"}function vo(t,n,e,r){const o=_o(t,n,e?.syntheticException||void 0,r);return mt(o),o.level="error",e?.event_id&&(o.event_id=e.event_id),vt(o)}function bo(t,n,e="info",r,o){const i=So(t,n,r?.syntheticException||void 0,o);return i.level=e,r?.event_id&&(i.event_id=r.event_id),vt(i)}function _o(t,n,e,r,o){let i;if(D(n)&&n.error){return lo(t,n.error)}if(F(n)||N(n,"DOMException")){const o=n;if("stack"in n)i=lo(t,n);else{const n=o.name||(F(o)?"DOMError":"DOMException"),s=o.message?`${n}: ${o.message}`:n;i=So(t,s,e,r),ht(i,s)}return"code"in o&&(i.tags={...i.tags,"DOMException.code":`${o.code}`}),i}if(A(n))return lo(t,n);if(B(n)||z(n)){return i=fo(t,n,e,o),mt(i,{synthetic:!0}),i}return i=So(t,n,e,r),ht(i,`${n}`),mt(i,{synthetic:!0}),i}function So(t,n,e,r){const o={};if(r&&e){const r=po(t,e);r.length&&(o.exception={values:[{value:n,stacktrace:{frames:r}}]}),mt(o,{synthetic:!0})}if(U(n)){const{__sentry_template_string__:t,__sentry_template_values__:e}=n;return o.logentry={message:t,params:e},o}return o.message=n,o}function wo(t,{isUnhandledRejection:n}){const e=function(t,n=40){const e=Object.keys(at(t));e.sort();const r=e[0];if(!r)return"[object has no keys]";if(r.length>=n)return tt(r,n);for(let t=e.length;t>0;t--){const r=e.slice(0,t).join(", ");if(!(r.length>n))return t===e.length?r:tt(r,n)}return""}(t),r=n?"promise rejection":"exception";if(D(t))return`Event \`ErrorEvent\` captured as ${r} with message \`${t.message}\``;if(z(t)){return`Event \`${function(t){try{const n=Object.getPrototypeOf(t);return n?n.constructor.name:void 0}catch(t){}}(t)}\` (type=${t.type}) captured as ${r}`}return`Object captured as ${r} with keys: ${e}`}class Eo extends rr{constructor(t){const n={parentSpanIsAlwaysRootSpan:!0,...t};!function(t,n,r=[n],o="npm"){const i=t._metadata||{};i.sdk||(i.sdk={name:`sentry.javascript.${n}`,packages:r.map((t=>({name:`${o}:@sentry/${t}`,version:e}))),version:e}),t._metadata=i}(n,"browser",["browser"],io.SENTRY_SDK_SOURCE||"cdn"),super(n);const r=this,{sendDefaultPii:o,_experiments:i}=r.it,s=i?.enableLogs;n.sendClientReports&&io.document&&io.document.addEventListener("visibilitychange",(()=>{"hidden"===io.document.visibilityState&&(this.Et(),s&&ar(r))})),s&&(r.on("flush",(()=>{ar(r)})),r.on("afterCaptureLog",(()=>{r.Tt&&clearTimeout(r.Tt),r.Tt=setTimeout((()=>{ar(r)}),5e3)}))),o&&(r.on("postprocessEvent",gr),r.on("beforeSendSession",yr))}eventFromException(t,n){return vo(this.it.stackParser,t,n,this.it.attachStacktrace)}eventFromMessage(t,n="info",e){return bo(this.it.stackParser,t,n,e,this.it.attachStacktrace)}_t(t,n,e,r){return t.platform=t.platform||"javascript",super._t(t,n,e,r)}}const To=(t,n,e,r)=>{let o,i;return s=>{n.value>=0&&(s||r)&&(i=n.value-(o||0),(i||void 0===o)&&(o=n.value,n.delta=i,n.rating=((t,n)=>t>n[1]?"poor":t>n[0]?"needs-improvement":"good")(n.value,e),t(n)))}},ko=n,$o=(t=!0)=>{const n=ko.performance?.getEntriesByType?.("navigation")[0];if(!t||n&&n.responseStart>0&&n.responseStart<performance.now())return n},xo=()=>{const t=$o();return t?.activationStart||0},Io=(t,n)=>{const e=$o();let r="navigate";e&&(ko.document?.prerendering||xo()>0?r="prerender":ko.document?.wasDiscarded?r="restore":e.type&&(r=e.type.replace(/_/g,"-")));return{name:t,value:void 0===n?-1:n,rating:"good",delta:0,entries:[],id:`v4-${Date.now()}-${Math.floor(8999999999999*Math.random())+1e12}`,navigationType:r}},Ro=(t,n,e)=>{try{if(PerformanceObserver.supportedEntryTypes.includes(t)){const r=new PerformanceObserver((t=>{Promise.resolve().then((()=>{n(t.getEntries())}))}));return r.observe(Object.assign({type:t,buffered:!0},e||{})),r}}catch(t){}},Oo=t=>{const n=n=>{"pagehide"!==n.type&&"hidden"!==ko.document?.visibilityState||t(n)};ko.document&&(addEventListener("visibilitychange",n,!0),addEventListener("pagehide",n,!0))},Co=t=>{let n=!1;return()=>{n||(t(),n=!0)}};let jo=-1;const Mo=t=>{"hidden"===ko.document.visibilityState&&jo>-1&&(jo="visibilitychange"===t.type?t.timeStamp:0,Lo())},Lo=()=>{removeEventListener("visibilitychange",Mo,!0),removeEventListener("prerenderingchange",Mo,!0)},Po=()=>(ko.document&&jo<0&&(jo="hidden"!==ko.document.visibilityState||ko.document.prerendering?1/0:0,addEventListener("visibilitychange",Mo,!0),addEventListener("prerenderingchange",Mo,!0)),{get firstHiddenTime(){return jo}}),Ao=t=>{ko.document?.prerendering?addEventListener("prerenderingchange",(()=>t()),!0):t()},No=[1800,3e3],Do=[.1,.25],Fo=(t,n={})=>{((t,n={})=>{Ao((()=>{const e=Po(),r=Io("FCP");let o;const i=Ro("paint",(t=>{t.forEach((t=>{"first-contentful-paint"===t.name&&(i.disconnect(),t.startTime<e.firstHiddenTime&&(r.value=Math.max(t.startTime-xo(),0),r.entries.push(t),o(!0)))}))}));i&&(o=To(t,r,No,n.reportAllChanges))}))})(Co((()=>{const e=Io("CLS",0);let r,o=0,i=[];const s=t=>{t.forEach((t=>{if(!t.hadRecentInput){const n=i[0],e=i[i.length-1];o&&n&&e&&t.startTime-e.startTime<1e3&&t.startTime-n.startTime<5e3?(o+=t.value,i.push(t)):(o=t.value,i=[t])}})),o>e.value&&(e.value=o,e.entries=i,r())},c=Ro("layout-shift",s);c&&(r=To(t,e,Do,n.reportAllChanges),Oo((()=>{s(c.takeRecords()),r(!0)})),setTimeout(r,0))})))},qo=[100,300],Uo=(t,n={})=>{Ao((()=>{const e=Po(),r=Io("FID");let o;const i=t=>{t.startTime<e.firstHiddenTime&&(r.value=t.processingStart-t.startTime,r.entries.push(t),o(!0))},s=t=>{t.forEach(i)},c=Ro("first-input",s);o=To(t,r,qo,n.reportAllChanges),c&&Oo(Co((()=>{s(c.takeRecords()),c.disconnect()})))}))};let Ho=0,Bo=1/0,zo=0;const Wo=t=>{t.forEach((t=>{t.interactionId&&(Bo=Math.min(Bo,t.interactionId),zo=Math.max(zo,t.interactionId),Ho=zo?(zo-Bo)/7+1:0)}))};let Xo;const Jo=()=>{"interactionCount"in performance||Xo||(Xo=Ro("event",Wo,{type:"event",buffered:!0,durationThreshold:0}))},Go=[],Ko=new Map;const Vo=()=>(Xo?Ho:performance.interactionCount||0)-0,Yo=[],Zo=t=>{if(Yo.forEach((n=>n(t))),!t.interactionId&&"first-input"!==t.entryType)return;const n=Go[Go.length-1],e=Ko.get(t.interactionId);if(e||Go.length<10||n&&t.duration>n.latency){if(e)t.duration>e.latency?(e.entries=[t],e.latency=t.duration):t.duration===e.latency&&t.startTime===e.entries[0]?.startTime&&e.entries.push(t);else{const n={id:t.interactionId,latency:t.duration,entries:[t]};Ko.set(n.id,n),Go.push(n)}Go.sort(((t,n)=>n.latency-t.latency)),Go.length>10&&Go.splice(10).forEach((t=>Ko.delete(t.id)))}},Qo=t=>{const n=ko.requestIdleCallback||ko.setTimeout;let e=-1;return t=Co(t),"hidden"===ko.document?.visibilityState?t():(e=n(t),Oo(t)),e},ti=[200,500],ni=(t,n={})=>{"PerformanceEventTiming"in ko&&"interactionId"in PerformanceEventTiming.prototype&&Ao((()=>{Jo();const e=Io("INP");let r;const o=t=>{Qo((()=>{t.forEach(Zo);const n=(()=>{const t=Math.min(Go.length-1,Math.floor(Vo()/50));return Go[t]})();n&&n.latency!==e.value&&(e.value=n.latency,e.entries=n.entries,r())}))},i=Ro("event",o,{durationThreshold:null!=n.durationThreshold?n.durationThreshold:40});r=To(t,e,ti,n.reportAllChanges),i&&(i.observe({type:"first-input",buffered:!0}),Oo((()=>{o(i.takeRecords()),r(!0)})))}))},ei=[2500,4e3],ri={},oi=(t,n={})=>{Ao((()=>{const e=Po(),r=Io("LCP");let o;const i=t=>{n.reportAllChanges||(t=t.slice(-1)),t.forEach((t=>{t.startTime<e.firstHiddenTime&&(r.value=Math.max(t.startTime-xo(),0),r.entries=[t],o())}))},s=Ro("largest-contentful-paint",i);if(s){o=To(t,r,ei,n.reportAllChanges);const e=Co((()=>{ri[r.id]||(i(s.takeRecords()),s.disconnect(),ri[r.id]=!0,o(!0))}));["keydown","click"].forEach((t=>{ko.document&&addEventListener(t,(()=>Qo(e)),{once:!0,capture:!0})})),Oo(e)}}))},ii=[800,1800],si=t=>{ko.document?.prerendering?Ao((()=>si(t))):"complete"!==ko.document?.readyState?addEventListener("load",(()=>si(t)),!0):setTimeout(t,0)},ci=(t,n={})=>{const e=Io("TTFB"),r=To(t,e,ii,n.reportAllChanges);si((()=>{const t=$o();t&&(e.value=Math.max(t.responseStart-xo(),0),e.entries=[t],r(!0))}))},ai={},ui={};let fi,di,li,pi,hi;function mi(t,n=!1){return Ei("cls",t,vi,fi,n)}function gi(t,n){return Ti(t,n),ui[t]||(!function(t){const n={};"event"===t&&(n.durationThreshold=0);Ro(t,(n=>{yi(t,{entries:n})}),n)}(t),ui[t]=!0),ki(t,n)}function yi(t,n){const e=ai[t];if(e?.length)for(const t of e)try{t(n)}catch(t){}}function vi(){return Fo((t=>{yi("cls",{metric:t}),fi=t}),{reportAllChanges:!0})}function bi(){return Uo((t=>{yi("fid",{metric:t}),di=t}))}function _i(){return oi((t=>{yi("lcp",{metric:t}),li=t}),{reportAllChanges:!0})}function Si(){return ci((t=>{yi("ttfb",{metric:t}),pi=t}))}function wi(){return ni((t=>{yi("inp",{metric:t}),hi=t}))}function Ei(t,n,e,r,o=!1){let i;return Ti(t,n),ui[t]||(i=e(),ui[t]=!0),r&&n({metric:r}),ki(t,n,o?i:void 0)}function Ti(t,n){ai[t]=ai[t]||[],ai[t].push(n)}function ki(t,n,e){return()=>{e&&e();const r=ai[t];if(!r)return;const o=r.indexOf(n);-1!==o&&r.splice(o,1)}}function $i(t){return"number"==typeof t&&isFinite(t)}function xi(t,n,e,{...r}){const o=Tn(t).start_timestamp;return o&&o>n&&"function"==typeof t.updateStartTime&&t.updateStartTime(n),ye(t,(()=>{const t=ge({startTime:n,...r});return t&&t.end(e),t}))}function Ii(t){const n=qt();if(!n)return;const{name:e,transaction:r,attributes:o,startTime:i}=t,{release:s,environment:c,sendDefaultPii:a}=n.getOptions(),u=n.getIntegrationByName("Replay"),f=u?.getReplayId(),d=At(),l=d.getUser(),p=void 0!==l?l.email||l.id||l.ip_address:void 0;let h;try{h=d.getScopeData().contexts.profile.profile_id}catch{}return ge({name:e,attributes:{release:s,environment:c,user:p||void 0,profile_id:h||void 0,replay_id:f||void 0,transaction:r,"user_agent.original":ko.navigator?.userAgent,"client.address":a?"{{auto}}":void 0,...o},startTime:i,experimental:{standalone:!0}})}function Ri(){return ko.addEventListener&&ko.performance}function Oi(t){return t/1e3}function Ci(t){let n="unknown",e="unknown",r="";for(const o of t){if("/"===o){[n,e]=t.split("/");break}if(!isNaN(Number(o))){n="h"===r?"http":r,e=t.split(r)[1];break}r+=o}return r===t&&(n=r),{name:n,version:e}}function ji(){let t,n,e=0;if(!function(){try{return PerformanceObserver.supportedEntryTypes.includes("layout-shift")}catch{return!1}}())return;let r=!1;function o(){r||(r=!0,n&&function(t,n,e){const r=Oi((L()||0)+(n?.startTime||0)),o=At().getScopeData().transactionName,i=n?V(n.sources[0]?.node):"Layout shift",s={[Wt]:"auto.http.browser.cls",[zt]:"ui.webvital.cls",[Yt]:n?.duration||0,"sentry.pageload.span_id":e},c=Ii({name:i,transaction:o,attributes:s,startTime:r});c&&(c.addEvent("cls",{[Jt]:"",[Gt]:t}),c.end(r))}(e,t,n),i())}const i=mi((({metric:n})=>{const r=n.entries[n.entries.length-1];r&&(e=n.value,t=r)}),!0);Oo((()=>{o()})),setTimeout((()=>{const t=qt();if(!t)return;const e=t.on("startNavigationSpan",(()=>{o(),e?.()})),r=jn();if(r){const t=Cn(r);"pageload"===Tn(t).op&&(n=t.spanContext().spanId)}}),0)}const Mi=2147483647;let Li,Pi,Ai=0,Ni={};function Di({recordClsStandaloneSpans:t}){const n=Ri();if(n&&L()){n.mark&&ko.performance.mark("sentry-tracing-init");const e=Ei("fid",(({metric:t})=>{const n=t.entries[t.entries.length-1];if(!n)return;const e=Oi(L()),r=Oi(n.startTime);Ni.fid={value:t.value,unit:"millisecond"},Ni["mark.fid"]={value:e+r,unit:"second"}}),bi,di),r=function(t,n=!1){return Ei("lcp",t,_i,li,n)}((({metric:t})=>{const n=t.entries[t.entries.length-1];n&&(Ni.lcp={value:t.value,unit:"millisecond"},Li=n)}),!0),o=function(t){return Ei("ttfb",t,Si,pi)}((({metric:t})=>{t.entries[t.entries.length-1]&&(Ni.ttfb={value:t.value,unit:"millisecond"})})),i=t?ji():mi((({metric:t})=>{const n=t.entries[t.entries.length-1];n&&(Ni.cls={value:t.value,unit:""},Pi=n)}),!0);return()=>{e(),r(),o(),i?.()}}return()=>{}}function Fi(t,n){const e=Ri(),r=L();if(!e?.getEntries||!r)return;const o=Oi(r),i=e.getEntries(),{op:s,start_timestamp:c}=Tn(t);if(i.slice(Ai).forEach((n=>{const e=Oi(n.startTime),r=Oi(Math.max(0,n.duration));if(!("navigation"===s&&c&&o+e<c))switch(n.entryType){case"navigation":!function(t,n,e){["unloadEvent","redirect","domContentLoadedEvent","loadEvent","connect"].forEach((r=>{qi(t,n,r,e)})),qi(t,n,"secureConnection",e,"TLS/SSL"),qi(t,n,"fetch",e,"cache"),qi(t,n,"domainLookup",e,"DNS"),function(t,n,e){const r=e+Oi(n.requestStart),o=e+Oi(n.responseEnd),i=e+Oi(n.responseStart);n.responseEnd&&(xi(t,r,o,{op:"browser.request",name:n.name,attributes:{[Wt]:"auto.ui.browser.metrics"}}),xi(t,i,o,{op:"browser.response",name:n.name,attributes:{[Wt]:"auto.ui.browser.metrics"}}))}(t,n,e)}(t,n,o);break;case"mark":case"paint":case"measure":{!function(t,n,e,r,o){const i=$o(!1),s=Oi(i?i.requestStart:0),c=o+Math.max(e,s),a=o+e,u=a+r,f={[Wt]:"auto.resource.browser.metrics"};c!==a&&(f["sentry.browser.measure_happened_before_request"]=!0,f["sentry.browser.measure_start_time"]=c);c<=u&&xi(t,c,u,{name:n.name,op:n.entryType,attributes:f})}(t,n,e,r,o);const i=Po(),s=n.startTime<i.firstHiddenTime;"first-paint"===n.name&&s&&(Ni.fp={value:n.startTime,unit:"millisecond"}),"first-contentful-paint"===n.name&&s&&(Ni.fcp={value:n.startTime,unit:"millisecond"});break}case"resource":!function(t,n,e,r,o,i){if("xmlhttprequest"===n.initiatorType||"fetch"===n.initiatorType)return;const s=Hr(e),c={[Wt]:"auto.resource.browser.metrics"};Ui(c,n,"transferSize","http.response_transfer_size"),Ui(c,n,"encodedBodySize","http.response_content_length"),Ui(c,n,"decodedBodySize","http.decoded_response_content_length");const a=n.deliveryType;null!=a&&(c["http.response_delivery_type"]=a);const u=n.renderBlockingStatus;u&&(c["resource.render_blocking_status"]=u);s.protocol&&(c["url.scheme"]=s.protocol.split(":").pop());s.host&&(c["server.address"]=s.host);c["url.same_origin"]=e.includes(ko.location.origin);const{name:f,version:d}=Ci(n.nextHopProtocol);c["network.protocol.name"]=f,c["network.protocol.version"]=d;const l=i+r,p=l+o;xi(t,l,p,{name:e.replace(ko.location.origin,""),op:n.initiatorType?`resource.${n.initiatorType}`:"resource.other",attributes:c})}(t,n,n.name,e,r,o)}})),Ai=Math.max(i.length-1,0),function(t){const n=ko.navigator;if(!n)return;const e=n.connection;e&&(e.effectiveType&&t.setAttribute("effectiveConnectionType",e.effectiveType),e.type&&t.setAttribute("connectionType",e.type),$i(e.rtt)&&(Ni["connection.rtt"]={value:e.rtt,unit:"millisecond"}));$i(n.deviceMemory)&&t.setAttribute("deviceMemory",`${n.deviceMemory} GB`);$i(n.hardwareConcurrency)&&t.setAttribute("hardwareConcurrency",String(n.hardwareConcurrency))}(t),"pageload"===s){!function(t){const n=$o(!1);if(!n)return;const{responseStart:e,requestStart:r}=n;r<=e&&(t["ttfb.requestTime"]={value:e-r,unit:"millisecond"})}(Ni);const e=Ni["mark.fid"];e&&Ni.fid&&(xi(t,e.value,e.value+Oi(Ni.fid.value),{name:"first input delay",op:"ui.action",attributes:{[Wt]:"auto.ui.browser.metrics"}}),delete Ni["mark.fid"]),"fcp"in Ni&&n.recordClsOnPageloadSpan||delete Ni.cls,Object.entries(Ni).forEach((([t,n])=>{fe(t,n.value,n.unit)})),t.setAttribute("performance.timeOrigin",o),t.setAttribute("performance.activationStart",xo()),function(t){Li&&(Li.element&&t.setAttribute("lcp.element",V(Li.element)),Li.id&&t.setAttribute("lcp.id",Li.id),Li.url&&t.setAttribute("lcp.url",Li.url.trim().slice(0,200)),null!=Li.loadTime&&t.setAttribute("lcp.loadTime",Li.loadTime),null!=Li.renderTime&&t.setAttribute("lcp.renderTime",Li.renderTime),t.setAttribute("lcp.size",Li.size));Pi?.sources&&Pi.sources.forEach(((n,e)=>t.setAttribute(`cls.source.${e+1}`,V(n.node))))}(t)}Li=void 0,Pi=void 0,Ni={}}function qi(t,n,e,r,o=e){const i=function(t){if("secureConnection"===t)return"connectEnd";if("fetch"===t)return"domainLookupStart";return`${t}End`}(e),s=n[i],c=n[`${e}Start`];c&&s&&xi(t,r+Oi(c),r+Oi(s),{op:`browser.${o}`,name:n.name,attributes:{[Wt]:"auto.ui.browser.metrics",..."redirect"===e&&null!=n.redirectCount?{"http.redirect_count":n.redirectCount}:{}}})}function Ui(t,n,e,r){const o=n[e];null!=o&&o<Mi&&(t[r]=o)}const Hi=1e3;let Bi,zi,Wi,Xi;function Ji(){if(!ko.document)return;const t=E.bind(null,"dom"),n=Gi(t,!0);ko.document.addEventListener("click",n,!1),ko.document.addEventListener("keypress",n,!1),["EventTarget","Node"].forEach((n=>{const e=ko,r=e[n]?.prototype;r?.hasOwnProperty?.("addEventListener")&&(ot(r,"addEventListener",(function(n){return function(e,r,o){if("click"===e||"keypress"==e)try{const r=this.__sentry_instrumentation_handlers__=this.__sentry_instrumentation_handlers__||{},i=r[e]=r[e]||{refCount:0};if(!i.handler){const r=Gi(t);i.handler=r,n.call(this,e,r,o)}i.refCount++}catch(t){}return n.call(this,e,r,o)}})),ot(r,"removeEventListener",(function(t){return function(n,e,r){if("click"===n||"keypress"==n)try{const e=this.__sentry_instrumentation_handlers__||{},o=e[n];o&&(o.refCount--,o.refCount<=0&&(t.call(this,n,o.handler,r),o.handler=void 0,delete e[n]),0===Object.keys(e).length&&delete this.__sentry_instrumentation_handlers__)}catch(t){}return t.call(this,n,e,r)}})))}))}function Gi(t,n=!1){return e=>{if(!e||e._sentryCaptured)return;const r=function(t){try{return t.target}catch(t){return null}}(e);if(function(t,n){return"keypress"===t&&(!n?.tagName||"INPUT"!==n.tagName&&"TEXTAREA"!==n.tagName&&!n.isContentEditable)}(e.type,r))return;it(e,"_sentryCaptured",!0),r&&!r._sentryId&&it(r,"_sentryId",dt());const o="keypress"===e.type?"input":e.type;if(!function(t){if(t.type!==zi)return!1;try{if(!t.target||t.target._sentryId!==Wi)return!1}catch(t){}return!0}(e)){t({event:e,name:o,global:n}),zi=e.type,Wi=r?r._sentryId:void 0}clearTimeout(Bi),Bi=ko.setTimeout((()=>{Wi=void 0,zi=void 0}),Hi)}}function Ki(t){const n="history";S(n,t),w(n,Vi)}function Vi(){function t(t){return function(...n){const e=n.length>2?n[2]:void 0;if(e){const r=Xi,o=String(e);if(Xi=o,r===o)return t.apply(this,n);E("history",{from:r,to:o})}return t.apply(this,n)}}ko.addEventListener("popstate",(()=>{const t=ko.location.href,n=Xi;if(Xi=t,n===t)return;E("history",{from:n,to:t})})),"history"in Jr&&Jr.history&&(ot(ko.history,"pushState",t),ot(ko.history,"replaceState",t))}const Yi={};function Zi(t){Yi[t]=void 0}const Qi="__sentry_xhr_v3__";function ts(t){S("xhr",t),w("xhr",ns)}function ns(){if(!ko.XMLHttpRequest)return;const t=XMLHttpRequest.prototype;t.open=new Proxy(t.open,{apply(t,n,e){const r=new Error,o=1e3*j(),i=q(e[0])?e[0].toUpperCase():void 0,s=function(t){if(q(t))return t;try{return t.toString()}catch{}return}(e[1]);if(!i||!s)return t.apply(n,e);n[Qi]={method:i,url:s,request_headers:{}},"POST"===i&&s.match(/sentry_key/)&&(n.__sentry_own_request__=!0);const c=()=>{const t=n[Qi];if(t&&4===n.readyState){try{t.status_code=n.status}catch(t){}E("xhr",{endTimestamp:1e3*j(),startTimestamp:o,xhr:n,virtualError:r})}};return"onreadystatechange"in n&&"function"==typeof n.onreadystatechange?n.onreadystatechange=new Proxy(n.onreadystatechange,{apply:(t,n,e)=>(c(),t.apply(n,e))}):n.addEventListener("readystatechange",c),n.setRequestHeader=new Proxy(n.setRequestHeader,{apply(t,n,e){const[r,o]=e,i=n[Qi];return i&&q(r)&&q(o)&&(i.request_headers[r.toLowerCase()]=o),t.apply(n,e)}}),t.apply(n,e)}}),t.send=new Proxy(t.send,{apply(t,n,e){const r=n[Qi];if(!r)return t.apply(n,e);void 0!==e[0]&&(r.body=e[0]);return E("xhr",{startTimestamp:1e3*j(),xhr:n}),t.apply(n,e)}})}const es=[],rs=new Map;function os(){if(Ri()&&L()){const t=Ei("inp",(({metric:t})=>{if(null==t.value)return;const n=t.entries.find((n=>n.duration===t.value&&is[n.name]));if(!n)return;const{interactionId:e}=n,r=is[n.name],o=Oi(L()+n.startTime),i=Oi(t.value),s=jn(),c=s?Cn(s):void 0,a=(null!=e?rs.get(e):void 0)||c,u=a?Tn(a).description:At().getScopeData().transactionName,f=Ii({name:V(n.target),transaction:u,attributes:{[Wt]:"auto.http.browser.inp",[zt]:`ui.interaction.${r}`,[Yt]:n.duration},startTime:o});f&&(f.addEvent("inp",{[Jt]:"millisecond",[Gt]:t.value}),f.end(o+i))}),wi,hi);return()=>{t()}}return()=>{}}const is={click:"click",pointerdown:"click",pointerup:"click",mousedown:"click",mouseup:"click",touchstart:"click",touchend:"click",mouseover:"hover",mouseout:"hover",mouseenter:"hover",mouseleave:"hover",pointerover:"hover",pointerout:"hover",pointerenter:"hover",pointerleave:"hover",dragstart:"drag",dragend:"drag",drag:"drag",dragenter:"drag",dragleave:"drag",dragover:"drag",drop:"drag",keydown:"press",keyup:"press",keypress:"press",input:"press"};function ss(t,n=function(t){const n=Yi[t];if(n)return n;let e=ko[t];if(Gr(e))return Yi[t]=e.bind(ko);const r=ko.document;if(r&&"function"==typeof r.createElement)try{const n=r.createElement("iframe");n.hidden=!0,r.head.appendChild(n);const o=n.contentWindow;o?.[t]&&(e=o[t]),r.head.removeChild(n)}catch(t){}return e?Yi[t]=e.bind(ko):e}("fetch")){let e=0,r=0;return mr(t,(function(o){const i=o.body.length;e+=i,r++;const s={body:o.body,method:"POST",referrerPolicy:"strict-origin",headers:t.headers,keepalive:e<=6e4&&r<15,...t.fetchOptions};if(!n)return Zi("fetch"),bt("No fetch implementation available");try{return n(t.url,s).then((t=>(e-=i,r--,{statusCode:t.status,headers:{"x-sentry-rate-limits":t.headers.get("X-Sentry-Rate-Limits"),"retry-after":t.headers.get("Retry-After")}})))}catch(t){return Zi("fetch"),e-=i,r--,bt(t)}}))}function cs(t,n,e,r){const o={filename:t,function:"<anonymous>"===n?d:n,in_app:!0};return void 0!==e&&(o.lineno=e),void 0!==r&&(o.colno=r),o}const as=/^\s*at (\S+?)(?::(\d+))(?::(\d+))\s*$/i,us=/^\s*at (?:(.+?\)(?: \[.+\])?|.*?) ?\((?:address at )?)?(?:async )?((?:<anonymous>|[-a-z]+:|.*bundle|\/)?.*?)(?::(\d+))?(?::(\d+))?\)?\s*$/i,fs=/\((\S*)(?::(\d+))(?::(\d+))\)/,ds=[30,t=>{const n=as.exec(t);if(n){const[,t,e,r]=n;return cs(t,d,+e,+r)}const e=us.exec(t);if(e){if(e[2]&&0===e[2].indexOf("eval")){const t=fs.exec(e[2]);t&&(e[2]=t[1],e[3]=t[2],e[4]=t[3])}const[t,n]=Es(e[1]||d,e[2]);return cs(n,t,e[3]?+e[3]:void 0,e[4]?+e[4]:void 0)}}],ls=/^\s*(.*?)(?:\((.*?)\))?(?:^|@)?((?:[-a-z]+)?:\/.*?|\[native code\]|[^@]*(?:bundle|\d+\.js)|\/[\w\-. /=]+)(?::(\d+))?(?::(\d+))?\s*$/i,ps=/(\S+) line (\d+)(?: > eval line \d+)* > eval/i,hs=[50,t=>{const n=ls.exec(t);if(n){if(n[3]&&n[3].indexOf(" > eval")>-1){const t=ps.exec(n[3]);t&&(n[1]=n[1]||"eval",n[3]=t[1],n[4]=t[2],n[5]="")}let t=n[3],e=n[1]||d;return[e,t]=Es(e,t),cs(t,e,n[4]?+n[4]:void 0,n[5]?+n[5]:void 0)}}],ms=/^\s*at (?:((?:\[object object\])?.+) )?\(?((?:[-a-z]+):.*?):(\d+)(?::(\d+))?\)?\s*$/i,gs=[40,t=>{const n=ms.exec(t);return n?cs(n[2],n[1]||d,+n[3],n[4]?+n[4]:void 0):void 0}],ys=/ line (\d+).*script (?:in )?(\S+)(?:: in function (\S+))?$/i,vs=[10,t=>{const n=ys.exec(t);return n?cs(n[2],n[3]||d,+n[1]):void 0}],bs=/ line (\d+), column (\d+)\s*(?:in (?:<anonymous function: ([^>]+)>|([^)]+))\(.*\))? in (.*):\s*$/i,_s=[20,t=>{const n=bs.exec(t);return n?cs(n[5],n[3]||n[4]||d,+n[1],+n[2]):void 0}],Ss=[ds,hs],ws=h(...Ss),Es=(t,n)=>{const e=-1!==t.indexOf("safari-extension"),r=-1!==t.indexOf("safari-web-extension");return e||r?[-1!==t.indexOf("@")?t.split("@")[0]:d,e?`safari-extension:${n}`:`safari-web-extension:${n}`]:[t,n]};const Ts=1024,ks=(t={})=>{const n={console:!0,dom:!0,fetch:!0,history:!0,sentry:!0,xhr:!0,...t};return{name:"Breadcrumbs",setup(t){var e;n.console&&function(t){const n="console";S(n,t),w(n,Mr)}(function(t){return function(n){if(qt()!==t)return;const e={category:"console",data:{arguments:n.args,logger:"console"},level:Lr(n.level),message:nt(n.args," ")};if("assert"===n.level){if(!1!==n.args[0])return;e.message=`Assertion failed: ${nt(n.args.slice(1)," ")||"console.assert"}`,e.data.arguments=n.args.slice(1)}_r(e,{input:n.args,level:n.level})}}(t)),n.dom&&(e=function(t,n){return function(e){if(qt()!==t)return;let r,o,i="object"==typeof n?n.serializeAttribute:void 0,s="object"==typeof n&&"number"==typeof n.maxStringLength?n.maxStringLength:void 0;s&&s>Ts&&(s=Ts),"string"==typeof i&&(i=[i]);try{const t=e.event,n=function(t){return!!t&&!!t.target}(t)?t.target:t;r=V(n,{keyAttrs:i,maxStringLength:s}),o=Q(n)}catch(t){r="<unknown>"}if(0===r.length)return;const c={category:`ui.${e.name}`,message:r};o&&(c.data={"ui.component_name":o}),_r(c,{event:e.event,name:e.name,global:e.global})}}(t,n.dom),S("dom",e),w("dom",Ji)),n.xhr&&ts(function(t){return function(n){if(qt()!==t)return;const{startTimestamp:e,endTimestamp:r}=n,o=n.xhr[Qi];if(!e||!r||!o)return;const{method:i,url:s,status_code:c,body:a}=o,u={method:i,url:s,status_code:c},f={xhr:n.xhr,input:a,startTimestamp:e,endTimestamp:r},d={category:"xhr",data:u,type:"http",level:Xr(c)};t.emit("beforeOutgoingRequestBreadcrumb",d,f),_r(d,f)}}(t)),n.fetch&&Vr(function(t){return function(n){if(qt()!==t)return;const{startTimestamp:e,endTimestamp:r}=n;if(r&&(!n.fetchData.url.match(/sentry_key/)||"POST"!==n.fetchData.method))if(n.error){const o=n.fetchData,i={data:n.error,input:n.args,startTimestamp:e,endTimestamp:r},s={category:"fetch",data:o,level:"error",type:"http"};t.emit("beforeOutgoingRequestBreadcrumb",s,i),_r(s,i)}else{const o=n.response,i={...n.fetchData,status_code:o?.status},s={input:n.args,response:o,startTimestamp:e,endTimestamp:r},c={category:"fetch",data:i,type:"http",level:Xr(i.status_code)};t.emit("beforeOutgoingRequestBreadcrumb",c,s),_r(c,s)}}}(t)),n.history&&Ki(function(t){return function(n){if(qt()!==t)return;let e=n.from,r=n.to;const o=Hr(io.location.href);let i=e?Hr(e):void 0;const s=Hr(r);i?.path||(i=o),o.protocol===s.protocol&&o.host===s.host&&(r=s.relative),o.protocol===i.protocol&&o.host===i.host&&(e=i.relative),_r({category:"navigation",data:{from:e,to:r}})}}(t)),n.sentry&&t.on("beforeSendEvent",function(t){return function(n){qt()===t&&_r({category:"sentry."+("transaction"===n.type?"transaction":"event"),event_id:n.event_id,level:n.level,message:pt(n)},{event:n})}}(t))}}};const $s=["EventTarget","Window","Node","ApplicationCache","AudioTrackList","BroadcastChannel","ChannelMergerNode","CryptoOperation","EventSource","FileReader","HTMLUnknownElement","IDBDatabase","IDBRequest","IDBTransaction","KeyOperation","MediaController","MessagePort","ModalWindow","Notification","SVGElementInstance","Screen","SharedWorker","TextTrack","TextTrackCue","TextTrackList","WebSocket","WebSocketWorker","Worker","XMLHttpRequest","XMLHttpRequestEventTarget","XMLHttpRequestUpload"],xs=(t={})=>{const n={XMLHttpRequest:!0,eventTarget:!0,requestAnimationFrame:!0,setInterval:!0,setTimeout:!0,...t};return{name:"BrowserApiErrors",setupOnce(){n.setTimeout&&ot(io,"setTimeout",Is),n.setInterval&&ot(io,"setInterval",Is),n.requestAnimationFrame&&ot(io,"requestAnimationFrame",Rs),n.XMLHttpRequest&&"XMLHttpRequest"in io&&ot(XMLHttpRequest.prototype,"send",Os);const t=n.eventTarget;if(t){(Array.isArray(t)?t:$s).forEach(Cs)}}}};function Is(t){return function(...n){const e=n[0];return n[0]=ao(e,{mechanism:{data:{function:y(t)},handled:!1,type:"instrument"}}),t.apply(this,n)}}function Rs(t){return function(n){return t.apply(this,[ao(n,{mechanism:{data:{function:"requestAnimationFrame",handler:y(t)},handled:!1,type:"instrument"}})])}}function Os(t){return function(...n){const e=this;return["onload","onerror","onprogress","onreadystatechange"].forEach((t=>{t in e&&"function"==typeof e[t]&&ot(e,t,(function(n){const e={mechanism:{data:{function:t,handler:y(n)},handled:!1,type:"instrument"}},r=ct(n);return r&&(e.mechanism.data.handler=y(r)),ao(n,e)}))})),t.apply(this,n)}}function Cs(t){const n=io,e=n[t]?.prototype;e?.hasOwnProperty?.("addEventListener")&&(ot(e,"addEventListener",(function(n){return function(e,r,o){try{"function"==typeof r.handleEvent&&(r.handleEvent=ao(r.handleEvent,{mechanism:{data:{function:"handleEvent",handler:y(r),target:t},handled:!1,type:"instrument"}}))}catch{}return n.apply(this,[e,ao(r,{mechanism:{data:{function:"addEventListener",handler:y(r),target:t},handled:!1,type:"instrument"}}),o])}})),ot(e,"removeEventListener",(function(t){return function(n,e,r){try{const o=e.__sentry_wrapped__;o&&t.call(this,n,o,r)}catch(t){}return t.call(this,n,e,r)}})))}const js=()=>({name:"BrowserSession",setupOnce(){void 0!==io.document&&(He({ignoreDuration:!0}),We(),Ki((({from:t,to:n})=>{void 0!==t&&t!==n&&(He({ignoreDuration:!0}),We())})))}}),Ms=(t={})=>{const n={onerror:!0,onunhandledrejection:!0,...t};return{name:"GlobalHandlers",setupOnce(){Error.stackTraceLimit=50},setup(t){n.onerror&&function(t){k((n=>{const{stackParser:e,attachStacktrace:r}=Ls();if(qt()!==t||co())return;const{msg:o,url:i,line:s,column:c,error:a}=n,u=function(t,n,e,r){const o=t.exception=t.exception||{},i=o.values=o.values||[],s=i[0]=i[0]||{},c=s.stacktrace=s.stacktrace||{},a=c.frames=c.frames||[],u=r,f=e,l=q(n)&&n.length>0?n:Z();0===a.length&&a.push({colno:u,filename:l,function:d,in_app:!0,lineno:f});return t}(_o(e,a||o,void 0,r,!1),i,s,c);u.level="error",qe(u,{originalException:a,mechanism:{handled:!1,type:"onerror"}})}))}(t),n.onunhandledrejection&&function(t){I((n=>{const{stackParser:e,attachStacktrace:r}=Ls();if(qt()!==t||co())return;const o=function(t){if(H(t))return t;try{if("reason"in t)return t.reason;if("detail"in t&&"reason"in t.detail)return t.detail.reason}catch{}return t}(n),i=H(o)?{exception:{values:[{type:"UnhandledRejection",value:`Non-Error promise rejection captured with value: ${String(o)}`}]}}:_o(e,o,void 0,r,!0);i.level="error",qe(i,{originalException:o,mechanism:{handled:!1,type:"onunhandledrejection"}})}))}(t)}}};function Ls(){const t=qt();return t?.getOptions()||{stackParser:()=>[],attachStacktrace:!1}}const Ps=()=>({name:"HttpContext",preprocessEvent(t){if(!io.navigator&&!io.location&&!io.document)return;const n=t.request?.url||Z(),{referrer:e}=io.document||{},{userAgent:r}=io.navigator||{},o={...t.request?.headers,...e&&{Referer:e},...r&&{"User-Agent":r}},i={...t.request,...n&&{url:n},headers:o};t.request=i}}),As=(t={})=>{const n=t.limit||5,e=t.key||"cause";return{name:"LinkedErrors",preprocessEvent(t,r,o){Rr(uo,o.getOptions().stackParser,e,n,t,r)}}};function Ns(t){return[$r(),Er(),xs(),ks(),Ms(),As(),Pr(),Ps(),js()]}function Ds(t){const n={};for(const e of Object.getOwnPropertyNames(t)){const r=e;void 0!==t[r]&&(n[r]=t[r])}return n}const Fs={replayIntegration:"replay",replayCanvasIntegration:"replay-canvas",feedbackIntegration:"feedback",feedbackModalIntegration:"feedback-modal",feedbackScreenshotIntegration:"feedback-screenshot",captureConsoleIntegration:"captureconsole",contextLinesIntegration:"contextlines",linkedErrorsIntegration:"linkederrors",dedupeIntegration:"dedupe",extraErrorDataIntegration:"extraerrordata",graphqlClientIntegration:"graphqlclient",httpClientIntegration:"httpclient",reportingObserverIntegration:"reportingobserver",rewriteFramesIntegration:"rewriteframes",browserProfilingIntegration:"browserprofiling",moduleMetadataIntegration:"modulemetadata"},qs=io;const Us=new WeakMap,Hs=new Map,Bs={traceFetch:!0,traceXHR:!0,enableHTTPTimings:!0,trackFetchStreamPerformance:!1};function zs(t,n){const{traceFetch:e,traceXHR:r,trackFetchStreamPerformance:o,shouldCreateSpanForRequest:i,enableHTTPTimings:s,tracePropagationTargets:c}={traceFetch:Bs.traceFetch,traceXHR:Bs.traceXHR,trackFetchStreamPerformance:Bs.trackFetchStreamPerformance,...n},a="function"==typeof i?i:t=>!0,u=t=>function(t,n){const e=Z();if(e){let r,o;try{r=new URL(t,e),o=new URL(e).origin}catch(t){return!1}const i=r.origin===o;return n?rt(r.toString(),n)||i&&rt(r.pathname,n):i}{const e=!!t.match(/^\/(?!\/)/);return n?rt(t,n):e}}(t,c),f={};e&&(t.addEventProcessor((t=>("transaction"===t.type&&t.spans&&t.spans.forEach((t=>{if("http.client"===t.op){const n=Hs.get(t.span_id);n&&(t.timestamp=n/1e3,Hs.delete(t.span_id))}})),t))),o&&function(t){const n="fetch-body-resolved";S(n,t),w(n,(()=>Yr(Zr)))}((t=>{if(t.response){const n=Us.get(t.response);n&&t.endTimestamp&&Hs.set(n,t.endTimestamp)}})),Vr((t=>{const n=Br(t,a,u,f);if(t.response&&t.fetchData.__span&&Us.set(t.response,t.fetchData.__span),n){const e=Js(t.fetchData.url),r=e?Hr(e).host:void 0;n.setAttributes({"http.url":e,"server.address":r})}s&&n&&Ws(n)}))),r&&ts((t=>{const n=function(t,n,e,r){const o=t.xhr,i=o?.[Qi];if(!o||o.__sentry_own_request__||!i)return;const{url:s,method:c}=i,a=Nn()&&n(s);if(t.endTimestamp&&a){const t=o.__sentry_xhr_span_id__;if(!t)return;const n=r[t];return void(n&&void 0!==i.status_code&&(nn(n,i.status_code),n.end(),delete r[t]))}const u=Js(s),f=Hr(u||s),d=(h=s,h.split(/[?#]/,1)[0]),l=!!jn(),p=a&&l?ge({name:`${c} ${d}`,attributes:{url:s,type:"xhr","http.method":c,"http.url":u,"server.address":f?.host,[Wt]:"auto.http.browser",[zt]:"http.client",...f?.search&&{"http.query":f?.search},...f?.hash&&{"http.fragment":f?.hash}}}):new zn;var h;o.__sentry_xhr_span_id__=p.spanContext().spanId,r[o.__sentry_xhr_span_id__]=p,e(s)&&function(t,n){const{"sentry-trace":e,baggage:r}=vr({span:n});e&&function(t,n,e){try{t.setRequestHeader("sentry-trace",n),e&&t.setRequestHeader("baggage",e)}catch(t){}}(t,e,r)}(o,Nn()&&l?p:void 0);const m=qt();m&&m.emit("beforeOutgoingRequestSpan",p,t);return p}(t,a,u,f);s&&n&&Ws(n)}))}function Ws(t){const{url:n}=Tn(t).data;if(!n||"string"!=typeof n)return;const e=gi("resource",(({entries:r})=>{r.forEach((r=>{if(function(t){return"resource"===t.entryType&&"initiatorType"in t&&"string"==typeof t.nextHopProtocol&&("fetch"===t.initiatorType||"xmlhttprequest"===t.initiatorType)}(r)&&r.name.endsWith(n)){(function(t){const{name:n,version:e}=Ci(t.nextHopProtocol),r=[];if(r.push(["network.protocol.version",e],["network.protocol.name",n]),!L())return r;return[...r,["http.request.redirect_start",Xs(t.redirectStart)],["http.request.fetch_start",Xs(t.fetchStart)],["http.request.domain_lookup_start",Xs(t.domainLookupStart)],["http.request.domain_lookup_end",Xs(t.domainLookupEnd)],["http.request.connect_start",Xs(t.connectStart)],["http.request.secure_connection_start",Xs(t.secureConnectionStart)],["http.request.connection_end",Xs(t.connectEnd)],["http.request.request_start",Xs(t.requestStart)],["http.request.response_start",Xs(t.responseStart)],["http.request.response_end",Xs(t.responseEnd)]]})(r).forEach((n=>t.setAttribute(...n))),setTimeout(e)}}))}))}function Xs(t=0){return((L()||performance.timeOrigin)+t)/1e3}function Js(t){try{return new URL(t,io.location.origin).href}catch{return}}const Gs="sentry_previous_trace";function Ks(t,n){const e=Tn(n);if(!t)return{spanContext:n.spanContext(),startTimestamp:e.start_timestamp};const r=t.spanContext;return r.traceId===e.trace_id?t:(Date.now()/1e3-t.startTimestamp<=3600&&(n.addLink({context:r,attributes:{"sentry.link.type":"previous_trace"}}),n.setAttribute("sentry.previous_trace",`${r.traceId}-${r.spanId}-${1===r.traceFlags?1:0}`)),{spanContext:n.spanContext(),startTimestamp:Tn(n).start_timestamp})}const Vs={...Te,instrumentNavigation:!0,instrumentPageLoad:!0,markBackgroundSpan:!0,enableLongTask:!0,enableLongAnimationFrame:!0,enableInp:!0,linkPreviousTrace:"in-memory",_experiments:{},...Bs};function Ys(t,n,e){return t.emit("startPageLoadSpan",n,e),At().setTransactionName(n.name),nc(t)}function Zs(t,n){return t.emit("startNavigationSpan",n),At().setTransactionName(n.name),nc(t)}function Qs(t){const n=io.document,e=n?.querySelector(`meta[name=${t}]`);return e?.getAttribute("content")||void 0}const tc="_sentry_idleSpan";function nc(t){return t[tc]}function ec(t,n){it(t,tc,n)}return Pn(),t.BrowserClient=Eo,t.SDK_VERSION=e,t.SEMANTIC_ATTRIBUTE_SENTRY_OP=zt,t.SEMANTIC_ATTRIBUTE_SENTRY_ORIGIN=Wt,t.SEMANTIC_ATTRIBUTE_SENTRY_SAMPLE_RATE=Bt,t.SEMANTIC_ATTRIBUTE_SENTRY_SOURCE=Ht,t.Scope=Rt,t.WINDOW=io,t.addBreadcrumb=_r,t.addEventProcessor=function(t){Nt().addEventProcessor(t)},t.addIntegration=function(t){const n=qt();n&&n.addIntegration(t)},t.breadcrumbsIntegration=ks,t.browserApiErrorsIntegration=xs,t.browserTracingIntegration=(t={})=>{const e=io.document;Pn();const{enableInp:r,enableLongTask:o,enableLongAnimationFrame:i,_experiments:{enableInteractions:s,enableStandaloneClsSpans:c},beforeStartSpan:a,idleTimeout:u,finalTimeout:f,childSpanTimeout:d,markBackgroundSpan:l,traceFetch:p,traceXHR:h,trackFetchStreamPerformance:m,shouldCreateSpanForRequest:g,enableHTTPTimings:y,instrumentPageLoad:v,instrumentNavigation:b,linkPreviousTrace:_}={...Vs,...t},S=Di({recordClsStandaloneSpans:c||!1});r&&os(),i&&n.PerformanceObserver&&PerformanceObserver.supportedEntryTypes&&PerformanceObserver.supportedEntryTypes.includes("long-animation-frame")?new PerformanceObserver((t=>{const n=jn();if(n)for(const e of t.getEntries()){if(!e.scripts[0])continue;const t=Oi(L()+e.startTime),{start_timestamp:r,op:o}=Tn(n);if("navigation"===o&&r&&t<r)continue;const i=Oi(e.duration),s={[Wt]:"auto.ui.browser.metrics"},c=e.scripts[0],{invoker:a,invokerType:u,sourceURL:f,sourceFunctionName:d,sourceCharPosition:l}=c;s["browser.script.invoker"]=a,s["browser.script.invoker_type"]=u,f&&(s["code.filepath"]=f),d&&(s["code.function"]=d),-1!==l&&(s["browser.script.source_char_position"]=l),xi(n,t,t+i,{name:"Main UI thread blocked",op:"ui.long-animation-frame",attributes:s})}})).observe({type:"long-animation-frame",buffered:!0}):o&&gi("longtask",(({entries:t})=>{const n=jn();if(!n)return;const{op:e,start_timestamp:r}=Tn(n);for(const o of t){const t=Oi(L()+o.startTime),i=Oi(o.duration);"navigation"===e&&r&&t<r||xi(n,t,t+i,{name:"Main UI thread blocked",op:"ui.long-task",attributes:{[Wt]:"auto.ui.browser.metrics"}})}})),s&&gi("event",(({entries:t})=>{const n=jn();if(n)for(const e of t)if("click"===e.name){const t=Oi(L()+e.startTime),r=Oi(e.duration),o={name:V(e.target),op:`ui.interaction.${e.name}`,startTime:t,attributes:{[Wt]:"auto.ui.browser.metrics"}},i=Q(e.target);i&&(o.attributes["ui.component_name"]=i),xi(n,t,t+r,o)}}));const w={name:void 0,source:void 0};function E(t,n){const r="pageload"===n.op,o=a?a(n):n,i=o.attributes||{};n.name!==o.name&&(i[Ht]="custom",o.attributes=i),w.name=o.name,w.source=i[Ht];const s=Re(o,{idleTimeout:u,finalTimeout:f,childSpanTimeout:d,disableAutoFinish:r,beforeSpanEnd:n=>{S(),Fi(n,{recordClsOnPageloadSpan:!c}),ec(t,void 0);const e=At(),r=e.getPropagationContext();e.setPropagationContext({...r,traceId:s.spanContext().traceId,sampled:kn(s),dsc:Bn(n)})}});function l(){e&&["interactive","complete"].includes(e.readyState)&&t.emit("idleSpanEnableAutoFinish",s)}ec(t,s),r&&e&&(e.addEventListener("readystatechange",(()=>{l()})),l())}return{name:"BrowserTracing",afterAllSetup(t){let n=Z();function e(){const n=nc(t);n&&!Tn(n).timestamp&&n.end()}if(t.on("startNavigationSpan",(n=>{qt()===t&&(e(),Nt().setPropagationContext({traceId:Et(),sampleRand:Math.random()}),At().setPropagationContext({traceId:Et(),sampleRand:Math.random()}),E(t,{op:"navigation",...n}))})),t.on("startPageLoadSpan",((n,r={})=>{if(qt()!==t)return;e();const o=hn(r.sentryTrace||Qs("sentry-trace"),r.baggage||Qs("baggage"));At().setPropagationContext(o),E(t,{op:"pageload",...n})})),"off"!==_){let n;t.on("spanStart",(t=>{if(Cn(t)===t)if("session-storage"===_){!function(t){try{io.sessionStorage.setItem(Gs,JSON.stringify(t))}catch(t){}}(Ks(function(){try{const t=io.sessionStorage?.getItem(Gs);return JSON.parse(t)}catch(t){return}}(),t))}else n=Ks(n,t)}))}if(io.location){if(v){const n=L();Ys(t,{name:io.location.pathname,startTime:n?n/1e3:void 0,attributes:{[Ht]:"url",[Wt]:"auto.pageload.browser"}})}b&&Ki((({to:e,from:r})=>{void 0!==r||-1===n?.indexOf(e)?r!==e&&(n=void 0,Zs(t,{name:io.location.pathname,attributes:{[Ht]:"url",[Wt]:"auto.navigation.browser"}})):n=void 0}))}l&&io.document&&io.document.addEventListener("visibilitychange",(()=>{const t=jn();if(!t)return;const n=Cn(t);if(io.document.hidden&&n){const t="cancelled",{status:e}=Tn(n);e||n.setStatus({code:tn,message:t}),n.setAttribute("sentry.cancellation_reason","document.hidden"),n.end()}})),s&&function(t,n,e,r,o){const i=io.document;let s;const c=()=>{const i="ui.action.click",c=nc(t);if(c){const t=Tn(c).op;if(["navigation","pageload"].includes(t))return}s&&(s.setAttribute(Xt,"interactionInterrupted"),s.end(),s=void 0),o.name&&(s=Re({name:o.name,op:i,attributes:{[Ht]:o.source||"url"}},{idleTimeout:n,finalTimeout:e,childSpanTimeout:r}))};i&&addEventListener("click",c,{once:!1,capture:!0})}(t,u,f,d,w),r&&function(){const t=({entries:t})=>{const n=jn(),e=n&&Cn(n);t.forEach((t=>{if(!function(t){return"duration"in t}(t)||!e)return;const n=t.interactionId;if(null!=n&&!rs.has(n)){if(es.length>10){const t=es.shift();rs.delete(t)}es.push(n),rs.set(n,e)}}))};gi("event",t),gi("first-input",t)}(),zs(t,{traceFetch:p,traceXHR:h,trackFetchStreamPerformance:m,tracePropagationTargets:t.getOptions().tracePropagationTargets,shouldCreateSpanForRequest:g,enableHTTPTimings:y})}}},t.captureEvent=qe,t.captureException=captureException,t.captureFeedback=function(t,n={},e=At()){const{message:r,name:o,email:i,url:s,source:c,associatedEventId:a,tags:u}=t,f={contexts:{feedback:{contact_email:i,name:o,message:r,url:s,source:c,associated_event_id:a}},type:"feedback",level:"info",tags:u},d=e?.getClient()||qt();return d&&d.emit("beforeSendFeedback",f,n),e.captureEvent(f,n)},t.captureMessage=function(t,n){const e="string"==typeof n?n:void 0,r="string"!=typeof n?{captureContext:n}:void 0;return At().captureMessage(t,e,r)},t.captureSession=We,t.chromeStackLineParser=ds,t.close=async function(t){const n=qt();return n?n.close(t):Promise.resolve(!1)},t.continueTrace=(t,n)=>{const e=Pt(r());if(e.continueTrace)return e.continueTrace(t,n);const{sentryTrace:o,baggage:i}=t;return Ft((t=>{const e=hn(o,i);return t.setPropagationContext(e),n()}))},t.createTransport=mr,t.createUserFeedbackEnvelope=function(t,{metadata:n,tunnel:e,dsn:r}){const o={event_id:t.event_id,sent_at:(new Date).toISOString(),...n?.sdk&&{sdk:{name:n.sdk.name,version:n.sdk.version}},...!!e&&!!r&&{dsn:Jn(r)}},i=function(t){return[{type:"user_report"},t]}(t);return Qn(o,[i])},t.dedupeIntegration=Pr,t.defaultStackLineParsers=Ss,t.defaultStackParser=ws,t.endSession=Be,t.eventFiltersIntegration=kr,t.eventFromException=vo,t.eventFromMessage=bo,t.exceptionFromError=uo,t.feedbackAsyncIntegration=ro,t.feedbackIntegration=ro,t.flush=async function(t){const n=qt();return n?n.flush(t):Promise.resolve(!1)},t.forceLoad=function(){},t.functionToStringIntegration=Er,t.geckoStackLineParser=hs,t.getActiveSpan=jn,t.getClient=qt,t.getCurrentScope=At,t.getDefaultIntegrations=Ns,t.getGlobalScope=Dt,t.getIsolationScope=Nt,t.getRootSpan=Cn,t.getSpanDescendants=On,t.globalHandlersIntegration=Ms,t.httpContextIntegration=Ps,t.inboundFiltersIntegration=$r,t.init=function(t={}){const n=function(t={}){return{defaultIntegrations:Ns(),release:"string"==typeof __SENTRY_RELEASE__?__SENTRY_RELEASE__:io.SENTRY_RELEASE?.id,sendClientReports:!0,...Ds(t)}}(t);if(!n.skipBrowserExtensionCheck&&function(){const t=void 0!==io.window&&io;if(!t)return!1;const n=t[t.chrome?"chrome":"browser"],e=n?.runtime?.id,r=Z()||"",o=!!e&&io===io.top&&["chrome-extension:","moz-extension:","ms-browser-extension:","safari-web-extension:"].some((t=>r.startsWith(`${t}//`))),i=void 0!==t.nw;return!!e&&!o&&!i}())return;const e={...n,stackParser:(r=n.stackParser||ws,Array.isArray(r)?h(...r):r),integrations:Ve(n),transport:n.transport||ss};var r;return function(t,n){!0===n.debug&&a((()=>{console.warn("[Sentry] Cannot initialize SDK with `debug` option using a non-debug bundle.")})),At().update(n.initialScope);const e=new t(n);return ur(e),e.init(),e}(Eo,e)},t.isInitialized=function(){return!!qt()},t.lastEventId=Ue,t.lazyLoadIntegration=async function(t,n){const r=Fs[t],o=qs.Sentry=qs.Sentry||{};if(!r)throw new Error(`Cannot lazy load integration: ${t}`);const i=o[t];if("function"==typeof i&&!("_isShim"in i))return i;const s=function(t){const n=qt(),r=n?.getOptions()?.cdnBaseUrl||"https://browser.sentry-cdn.com";return new URL(`/${e}/${t}.min.js`,r).toString()}(r),c=io.document.createElement("script");c.src=s,c.crossOrigin="anonymous",c.referrerPolicy="strict-origin",n&&c.setAttribute("nonce",n);const a=new Promise(((t,n)=>{c.addEventListener("load",(()=>t())),c.addEventListener("error",n)})),u=io.document.currentScript,f=io.document.body||io.document.head||u?.parentElement;if(!f)throw new Error(`Could not find parent element to insert lazy-loaded ${t} script`);f.appendChild(c);try{await a}catch{throw new Error(`Error when loading integration: ${t}`)}const d=o[t];if("function"!=typeof d)throw new Error(`Could not load integration: ${t}`);return d},t.linkedErrorsIntegration=As,t.makeFetchTransport=ss,t.onLoad=function(t){t()},t.opera10StackLineParser=vs,t.opera11StackLineParser=_s,t.parameterize=function(t,...n){const e=new String(String.raw(t,...n));return e.__sentry_template_string__=t.join("\0").replace(/%/g,"%%").replace(/\0/g,"%s"),e.__sentry_template_values__=n,e},t.replayIntegration=function(t){return a((()=>{console.warn("You are using replayIntegration() even though this bundle does not include replay.")})),{name:"Replay",...oo.reduce(((t,n)=>(t[n]=no,t)),{})}},t.setContext=function(t,n){Nt().setContext(t,n)},t.setCurrentClient=ur,t.setExtra=function(t,n){Nt().setExtra(t,n)},t.setExtras=function(t){Nt().setExtras(t)},t.setMeasurement=fe,t.setTag=function(t,n){Nt().setTag(t,n)},t.setTags=function(t){Nt().setTags(t)},t.setUser=function(t){Nt().setUser(t)},t.showReportDialog=function(t={}){if(!io.document)return;const n=At(),e=n.getClient(),r=e?.getDsn();if(!r)return;if(n&&(t.user={...n.getUser(),...t.user}),!t.eventId){const n=Ue();n&&(t.eventId=n)}const o=io.document.createElement("script");o.async=!0,o.crossOrigin="anonymous",o.src=function(t,n){const e=Kn(t);if(!e)return"";const r=`${Je(e)}embed/error-page/`;let o=`dsn=${Jn(e)}`;for(const t in n)if("dsn"!==t&&"onClose"!==t)if("user"===t){const t=n.user;if(!t)continue;t.name&&(o+=`&name=${encodeURIComponent(t.name)}`),t.email&&(o+=`&email=${encodeURIComponent(t.email)}`)}else o+=`&${encodeURIComponent(t)}=${encodeURIComponent(n[t])}`;return`${r}?${o}`}(r,t),t.onLoad&&(o.onload=t.onLoad);const{onClose:i}=t;if(i){const t=n=>{if("__sentry_reportdialog_closed__"===n.data)try{i()}finally{io.removeEventListener("message",t)}};io.addEventListener("message",t)}const s=io.document.head||io.document.body;s&&s.appendChild(o)},t.spanToBaggageHeader=function(t){return dn(Bn(t))},t.spanToJSON=Tn,t.spanToTraceHeader=_n,t.startBrowserTracingNavigationSpan=Zs,t.startBrowserTracingPageLoadSpan=Ys,t.startInactiveSpan=ge,t.startNewTrace=function(t){return Ft((n=>(n.setPropagationContext({traceId:Et(),sampleRand:Math.random()}),ye(null,t))))},t.startSession=He,t.startSpan=function(t,n){const e=_e();if(e.startSpan)return e.startSpan(t,n);const r=be(t),{forceTransaction:o,parentSpan:i,scope:s}=t,c=s?.clone();return Ft(c,(()=>Ee(i)((()=>{const e=At(),i=we(e),s=t.onlyIfParent&&!i?new zn:ve({parentSpan:i,spanArguments:r,forceTransaction:o,scope:e});return xt(e,s),Wn((()=>n(s)),(()=>{const{status:t}=Tn(s);!s.isRecording()||t&&"ok"!==t||s.setStatus({code:tn,message:"internal_error"})}),(()=>{s.end()}))}))))},t.startSpanManual=function(t,n){const e=_e();if(e.startSpanManual)return e.startSpanManual(t,n);const r=be(t),{forceTransaction:o,parentSpan:i,scope:s}=t,c=s?.clone();return Ft(c,(()=>Ee(i)((()=>{const e=At(),i=we(e),s=t.onlyIfParent&&!i?new zn:ve({parentSpan:i,spanArguments:r,forceTransaction:o,scope:e});return xt(e,s),Wn((()=>n(s,(()=>s.end()))),(()=>{const{status:t}=Tn(s);!s.isRecording()||t&&"ok"!==t||s.setStatus({code:tn,message:"internal_error"})}))}))))},t.suppressTracing=function(t){const n=_e();return n.suppressTracing?n.suppressTracing(t):Ft((n=>(n.setSDKProcessingMetadata({[me]:!0}),t())))},t.updateSpanName=function(t,n){t.updateName(n),t.setAttributes({[Ht]:"custom",[Kt]:n})},t.winjsStackLineParser=gs,t.withActiveSpan=ye,t.withIsolationScope=function(...t){const n=Pt(r());if(2===t.length){const[e,r]=t;return e?n.withSetIsolationScope(e,r):n.withIsolationScope(r)}return n.withIsolationScope(t[0])},t.withScope=Ft,t}({});
//# sourceMappingURL=bundle.tracing.min.js.map