@sentry/browser 6.19.3 → 6.19.4
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/bundles/bundle.debug.min.js +2 -2
- package/bundles/bundle.debug.min.js.map +1 -1
- package/bundles/bundle.es6.debug.min.js +2 -2
- package/bundles/bundle.es6.debug.min.js.map +1 -1
- package/bundles/bundle.es6.js +3 -19
- package/bundles/bundle.es6.js.map +1 -1
- package/bundles/bundle.es6.min.js +2 -2
- package/bundles/bundle.es6.min.js.map +1 -1
- package/bundles/bundle.js +3 -19
- package/bundles/bundle.js.map +1 -1
- package/bundles/bundle.min.js +2 -2
- package/bundles/bundle.min.js.map +1 -1
- package/dist/transports/base.js +1 -1
- package/dist/transports/base.js.map +1 -1
- package/esm/transports/base.js +1 -1
- package/esm/transports/base.js.map +1 -1
- package/package.json +7 -7
|
@@ -1,3 +1,3 @@
|
|
|
1
|
-
/*! @sentry/browser 6.19.
|
|
2
|
-
var Sentry=function(t){var e;t.Severity=void 0,(e=t.Severity||(t.Severity={})).Fatal="fatal",e.Error="error",e.Warning="warning",e.Log="log",e.Info="info",e.Debug="debug",e.Critical="critical";const n={};function r(){return"undefined"!=typeof window?window:"undefined"!=typeof self?self:n}const i=Object.prototype.toString;function s(t){switch(i.call(t)){case"[object Error]":case"[object Exception]":case"[object DOMException]":return!0;default:return p(t,Error)}}function o(t,e){return i.call(t)===`[object ${e}]`}function c(t){return o(t,"ErrorEvent")}function u(t){return o(t,"DOMError")}function a(t){return o(t,"String")}function h(t){return null===t||"object"!=typeof t&&"function"!=typeof t}function f(t){return o(t,"Object")}function l(t){return"undefined"!=typeof Event&&p(t,Event)}function d(t){return Boolean(t&&t.then&&"function"==typeof t.then)}function p(t,e){try{return t instanceof e}catch(t){return!1}}function b(t,e){try{let n=t;const r=5,i=80,s=[];let o=0,c=0;const u=" > ",a=u.length;let h;for(;n&&o++<r&&(h=y(n,e),!("html"===h||o>1&&c+s.length*a+h.length>=i));)s.push(h),c+=h.length,n=n.parentNode;return s.reverse().join(u)}catch(t){return"<unknown>"}}function y(t,e){const n=t,r=[];let i,s,o,c,u;if(!n||!n.tagName)return"";r.push(n.tagName.toLowerCase());const h=e&&e.length?e.filter((t=>n.getAttribute(t))).map((t=>[t,n.getAttribute(t)])):null;if(h&&h.length)h.forEach((t=>{r.push(`[${t[0]}="${t[1]}"]`)}));else if(n.id&&r.push(`#${n.id}`),i=n.className,i&&a(i))for(s=i.split(/\s+/),u=0;u<s.length;u++)r.push(`.${s[u]}`);const f=["type","name","title","alt"];for(u=0;u<f.length;u++)o=f[u],c=n.getAttribute(o),c&&r.push(`[${o}="${c}"]`);return r.join("")}const m=Object.setPrototypeOf||({__proto__:[]}instanceof Array?function(t,e){return t.__proto__=e,t}:function(t,e){for(const n in e)Object.prototype.hasOwnProperty.call(t,n)||(t[n]=e[n]);return t});class v extends Error{constructor(t){super(t),this.message=t,this.name=new.target.prototype.constructor.name,m(this,new.target.prototype)}}const O=/^(?:(\w+):)\/\/(?:(\w+)(?::(\w+))?@)([\w.-]+)(?::(\d+))?\/(.+)/;function j(t,e=!1){const{host:n,path:r,pass:i,port:s,projectId:o,protocol:c,publicKey:u}=t;return`${c}://${u}${e&&i?`:${i}`:""}@${n}${s?`:${s}`:""}/${r?`${r}/`:r}${o}`}function g(t){return"user"in t&&!("publicKey"in t)&&(t.publicKey=t.user),{user:t.publicKey||"",protocol:t.protocol,publicKey:t.publicKey||"",pass:t.pass||"",host:t.host,port:t.port||"",path:t.path||"",projectId:t.projectId}}function w(t){return"string"==typeof t?function(t){const e=O.exec(t);if(!e)throw new v(`Invalid Sentry Dsn: ${t}`);const[n,r,i="",s,o="",c]=e.slice(1);let u="",a=c;const h=a.split("/");if(h.length>1&&(u=h.slice(0,-1).join("/"),a=h.pop()),a){const t=a.match(/^\d+/);t&&(a=t[0])}return g({host:s,pass:i,path:u,projectId:a,port:o,protocol:n,publicKey:r})}(t):g(t)}const x=["fatal","error","warning","log","info","debug","critical"];r();const E=["debug","info","warn","error","log","assert"];function _(t,e=0){return"string"!=typeof t||0===e||t.length<=e?t:`${t.substr(0,e)}...`}function S(t,e){if(!Array.isArray(t))return"";const n=[];for(let e=0;e<t.length;e++){const r=t[e];try{n.push(String(r))}catch(t){n.push("[value cannot be serialized]")}}return n.join(e)}function $(t,e){return!!a(t)&&(o(e,"RegExp")?e.test(t):"string"==typeof e&&-1!==t.indexOf(e))}function k(t,e,n){if(!(e in t))return;const r=t[e],i=n(r);if("function"==typeof i)try{R(i,r)}catch(t){}t[e]=i}function T(t,e,n){Object.defineProperty(t,e,{value:n,writable:!0,configurable:!0})}function R(t,e){const n=e.prototype||{};t.prototype=e.prototype=n,T(t,"__sentry_original__",e)}function D(t){return t.__sentry_original__}function M(t){let e=t;if(s(t))e=Object.assign({message:t.message,name:t.name,stack:t.stack},q(t));else if(l(t)){const n=t;e=Object.assign({type:n.type,target:N(n.target),currentTarget:N(n.currentTarget)},q(n)),"undefined"!=typeof CustomEvent&&p(t,CustomEvent)&&(e.detail=n.detail)}return e}function N(t){try{return e=t,"undefined"!=typeof Element&&p(e,Element)?b(t):Object.prototype.toString.call(t)}catch(t){return"<unknown>"}var e}function q(t){const e={};for(const n in t)Object.prototype.hasOwnProperty.call(t,n)&&(e[n]=t[n]);return e}function I(t,e=40){const n=Object.keys(M(t));if(n.sort(),!n.length)return"[object has no keys]";if(n[0].length>=e)return _(n[0],e);for(let t=n.length;t>0;t--){const r=n.slice(0,t).join(", ");if(!(r.length>e))return t===n.length?r:_(r,e)}return""}function C(t){if(f(t)){const e={};for(const n of Object.keys(t))void 0!==t[n]&&(e[n]=C(t[n]));return e}return Array.isArray(t)?t.map(C):t}function L(...t){const e=t.sort(((t,e)=>t[0]-e[0])).map((t=>t[1]));return(t,n=0)=>{const r=[];for(const i of t.split("\n").slice(n))for(const t of e){const e=t(i);if(e){r.push(e);break}}return function(t){if(!t.length)return[];let e=t;const n=e[0].function||"",r=e[e.length-1].function||"";-1===n.indexOf("captureMessage")&&-1===n.indexOf("captureException")||(e=e.slice(1));-1!==r.indexOf("sentryWrapped")&&(e=e.slice(0,-1));return e.slice(0,50).map((t=>Object.assign(Object.assign({},t),{filename:t.filename||e[0].filename,function:t.function||"?"}))).reverse()}(r)}}const A="<anonymous>";function U(t){try{return t&&"function"==typeof t&&t.name||A}catch(t){return A}}function F(){if(!("fetch"in r()))return!1;try{return new Headers,new Request(""),new Response,!0}catch(t){return!1}}function P(t){return t&&/^function fetch\(\)\s+\{\s+\[native code\]\s+\}$/.test(t.toString())}function B(){if(!F())return!1;try{return new Request("_",{referrerPolicy:"origin"}),!0}catch(t){return!1}}const H=r(),X={},z={};function J(t){if(!z[t])switch(z[t]=!0,t){case"console":!function(){if(!("console"in H))return;E.forEach((function(t){t in H.console&&k(H.console,t,(function(e){return function(...n){K("console",{args:n,level:t}),e&&e.apply(H.console,n)}}))}))}();break;case"dom":!function(){if(!("document"in H))return;const t=K.bind(null,"dom"),e=tt(t,!0);H.document.addEventListener("click",e,!1),H.document.addEventListener("keypress",e,!1),["EventTarget","Node"].forEach((e=>{const n=H[e]&&H[e].prototype;n&&n.hasOwnProperty&&n.hasOwnProperty("addEventListener")&&(k(n,"addEventListener",(function(e){return function(n,r,i){if("click"===n||"keypress"==n)try{const r=this,s=r.__sentry_instrumentation_handlers__=r.__sentry_instrumentation_handlers__||{},o=s[n]=s[n]||{refCount:0};if(!o.handler){const r=tt(t);o.handler=r,e.call(this,n,r,i)}o.refCount+=1}catch(t){}return e.call(this,n,r,i)}})),k(n,"removeEventListener",(function(t){return function(e,n,r){if("click"===e||"keypress"==e)try{const n=this,i=n.__sentry_instrumentation_handlers__||{},s=i[e];s&&(s.refCount-=1,s.refCount<=0&&(t.call(this,e,s.handler,r),s.handler=void 0,delete i[e]),0===Object.keys(i).length&&delete n.__sentry_instrumentation_handlers__)}catch(t){}return t.call(this,e,n,r)}})))}))}();break;case"xhr":!function(){if(!("XMLHttpRequest"in H))return;const t=XMLHttpRequest.prototype;k(t,"open",(function(t){return function(...e){const n=this,r=e[1],i=n.__sentry_xhr__={method:a(e[0])?e[0].toUpperCase():e[0],url:e[1]};a(r)&&"POST"===i.method&&r.match(/sentry_key/)&&(n.__sentry_own_request__=!0);const s=function(){if(4===n.readyState){try{i.status_code=n.status}catch(t){}K("xhr",{args:e,endTimestamp:Date.now(),startTimestamp:Date.now(),xhr:n})}};return"onreadystatechange"in n&&"function"==typeof n.onreadystatechange?k(n,"onreadystatechange",(function(t){return function(...e){return s(),t.apply(n,e)}})):n.addEventListener("readystatechange",s),t.apply(n,e)}})),k(t,"send",(function(t){return function(...e){return this.__sentry_xhr__&&void 0!==e[0]&&(this.__sentry_xhr__.body=e[0]),K("xhr",{args:e,startTimestamp:Date.now(),xhr:this}),t.apply(this,e)}}))}();break;case"fetch":!function(){if(!function(){if(!F())return!1;const t=r();if(P(t.fetch))return!0;let e=!1;const n=t.document;if(n&&"function"==typeof n.createElement)try{const t=n.createElement("iframe");t.hidden=!0,n.head.appendChild(t),t.contentWindow&&t.contentWindow.fetch&&(e=P(t.contentWindow.fetch)),n.head.removeChild(t)}catch(t){}return e}())return;k(H,"fetch",(function(t){return function(...e){const n={args:e,fetchData:{method:G(e),url:V(e)},startTimestamp:Date.now()};return K("fetch",Object.assign({},n)),t.apply(H,e).then((t=>(K("fetch",Object.assign(Object.assign({},n),{endTimestamp:Date.now(),response:t})),t)),(t=>{throw K("fetch",Object.assign(Object.assign({},n),{endTimestamp:Date.now(),error:t})),t}))}}))}();break;case"history":!function(){if(!function(){const t=r(),e=t.chrome,n=e&&e.app&&e.app.runtime,i="history"in t&&!!t.history.pushState&&!!t.history.replaceState;return!n&&i}())return;const t=H.onpopstate;function e(t){return function(...e){const n=e.length>2?e[2]:void 0;if(n){const t=Q,e=String(n);Q=e,K("history",{from:t,to:e})}return t.apply(this,e)}}H.onpopstate=function(...e){const n=H.location.href,r=Q;if(Q=n,K("history",{from:r,to:n}),t)try{return t.apply(this,e)}catch(t){}},k(H.history,"pushState",e),k(H.history,"replaceState",e)}();break;case"error":et=H.onerror,H.onerror=function(t,e,n,r,i){return K("error",{column:r,error:i,line:n,msg:t,url:e}),!!et&&et.apply(this,arguments)};break;case"unhandledrejection":nt=H.onunhandledrejection,H.onunhandledrejection=function(t){return K("unhandledrejection",t),!nt||nt.apply(this,arguments)};break;default:return}}function W(t,e){X[t]=X[t]||[],X[t].push(e),J(t)}function K(t,e){if(t&&X[t])for(const n of X[t]||[])try{n(e)}catch(t){}}function G(t=[]){return"Request"in H&&p(t[0],Request)&&t[0].method?String(t[0].method).toUpperCase():t[1]&&t[1].method?String(t[1].method).toUpperCase():"GET"}function V(t=[]){return"string"==typeof t[0]?t[0]:"Request"in H&&p(t[0],Request)?t[0].url:String(t[0])}let Q;let Y,Z;function tt(t,e=!1){return n=>{if(!n||Z===n)return;if(function(t){if("keypress"!==t.type)return!1;try{const e=t.target;if(!e||!e.tagName)return!0;if("INPUT"===e.tagName||"TEXTAREA"===e.tagName||e.isContentEditable)return!1}catch(t){}return!0}(n))return;const r="keypress"===n.type?"input":n.type;(void 0===Y||function(t,e){if(!t)return!0;if(t.type!==e.type)return!0;try{if(t.target!==e.target)return!0}catch(t){}return!1}(Z,n))&&(t({event:n,name:r,global:e}),Z=n),clearTimeout(Y),Y=H.setTimeout((()=>{Y=void 0}),1e3)}}let et=null;let nt=null;function rt(){const t=r(),e=t.crypto||t.msCrypto;if(void 0!==e&&e.getRandomValues){const t=new Uint16Array(8);e.getRandomValues(t),t[3]=4095&t[3]|16384,t[4]=16383&t[4]|32768;const n=t=>{let e=t.toString(16);for(;e.length<4;)e=`0${e}`;return e};return n(t[0])+n(t[1])+n(t[2])+n(t[3])+n(t[4])+n(t[5])+n(t[6])+n(t[7])}return"xxxxxxxxxxxx4xxxyxxxxxxxxxxxxxxx".replace(/[xy]/g,(t=>{const e=16*Math.random()|0;return("x"===t?e:3&e|8).toString(16)}))}function it(t){if(!t)return{};const e=t.match(/^(([^:/?#]+):)?(\/\/([^/?#]*))?([^?#]*)(\?([^#]*))?(#(.*))?$/);if(!e)return{};const n=e[6]||"",r=e[8]||"";return{host:e[4],path:e[5],protocol:e[2],relative:e[5]+n+r}}function st(t){return t.exception&&t.exception.values?t.exception.values[0]:void 0}function ot(t){const{message:e,event_id:n}=t;if(e)return e;const r=st(t);return r?r.type&&r.value?`${r.type}: ${r.value}`:r.type||r.value||n||"<unknown>":n||"<unknown>"}function ct(t,e,n){const r=t.exception=t.exception||{},i=r.values=r.values||[],s=i[0]=i[0]||{};s.value||(s.value=e||""),s.type||(s.type=n||"Error")}function ut(t,e){const n=st(t);if(!n)return;const r=n.mechanism;if(n.mechanism=Object.assign(Object.assign(Object.assign({},{type:"generic",handled:!0}),r),e),e&&"data"in e){const t=Object.assign(Object.assign({},r&&r.data),e.data);n.mechanism.data=t}}function at(t){if(t&&t.__sentry_captured__)return!0;try{T(t,"__sentry_captured__",!0)}catch(t){}return!1}function ht(t,e=1/0,n=1/0){try{return lt("",t,e,n)}catch(t){return{ERROR:`**non-serializable** (${t})`}}}function ft(t,e=3,n=102400){const r=ht(t,e);return i=r,function(t){return~-encodeURI(t).split(/%..|./).length}(JSON.stringify(i))>n?ft(t,e-1,n):r;var i}function lt(t,e,n=1/0,r=1/0,i=function(){const t="function"==typeof WeakSet,e=t?new WeakSet:[];return[function(n){if(t)return!!e.has(n)||(e.add(n),!1);for(let t=0;t<e.length;t++)if(e[t]===n)return!0;return e.push(n),!1},function(n){if(t)e.delete(n);else for(let t=0;t<e.length;t++)if(e[t]===n){e.splice(t,1);break}}]}()){const[o,c]=i,u=e;if(u&&"function"==typeof u.toJSON)try{return u.toJSON()}catch(t){}if(null===e||["number","boolean","string"].includes(typeof e)&&("number"!=typeof(a=e)||a==a))return e;var a;const h=function(t,e){try{return"domain"===t&&e&&"object"==typeof e&&e.t?"[Domain]":"domainEmitter"===t?"[DomainEmitter]":"undefined"!=typeof global&&e===global?"[Global]":"undefined"!=typeof window&&e===window?"[Window]":"undefined"!=typeof document&&e===document?"[Document]":function(t){return f(t)&&"nativeEvent"in t&&"preventDefault"in t&&"stopPropagation"in t}(e)?"[SyntheticEvent]":"number"==typeof e&&e!=e?"[NaN]":void 0===e?"[undefined]":"function"==typeof e?`[Function: ${U(e)}]`:"symbol"==typeof e?`[${String(e)}]`:"bigint"==typeof e?`[BigInt: ${String(e)}]`:`[object ${Object.getPrototypeOf(e).constructor.name}]`}catch(t){return`**non-serializable** (${t})`}}(t,e);if(!h.startsWith("[object "))return h;if(0===n)return h.replace("object ","");if(o(e))return"[Circular ~]";const d=Array.isArray(e)?[]:{};let p=0;const b=s(e)||l(e)?M(e):e;for(const t in b){if(!Object.prototype.hasOwnProperty.call(b,t))continue;if(p>=r){d[t]="[MaxProperties ~]";break}const e=b[t];d[t]=lt(t,e,n-1,r,i),p+=1}return c(e),d}function dt(t){return new bt((e=>{e(t)}))}function pt(t){return new bt(((e,n)=>{n(t)}))}class bt{constructor(t){this.i=0,this.o=[],this.u=t=>{this.h(1,t)},this.l=t=>{this.h(2,t)},this.h=(t,e)=>{0===this.i&&(d(e)?e.then(this.u,this.l):(this.i=t,this.p=e,this.m()))},this.m=()=>{if(0===this.i)return;const t=this.o.slice();this.o=[],t.forEach((t=>{t[0]||(1===this.i&&t[1](this.p),2===this.i&&t[2](this.p),t[0]=!0)}))};try{t(this.u,this.l)}catch(t){this.l(t)}}then(t,e){return new bt(((n,r)=>{this.o.push([!1,e=>{if(t)try{n(t(e))}catch(t){r(t)}else n(e)},t=>{if(e)try{n(e(t))}catch(t){r(t)}else r(t)}]),this.m()}))}catch(t){return this.then((t=>t),t)}finally(t){return new bt(((e,n)=>{let r,i;return this.then((e=>{i=!1,r=e,t&&t()}),(e=>{i=!0,r=e,t&&t()})).then((()=>{i?n(r):e(r)}))}))}}function yt(t){const e=[];function n(t){return e.splice(e.indexOf(t),1)[0]}return{$:e,add:function(r){if(!(void 0===t||e.length<t))return pt(new v("Not adding Promise due to buffer limit reached."));const i=r();return-1===e.indexOf(i)&&e.push(i),i.then((()=>n(i))).then(null,(()=>n(i).then(null,(()=>{})))),i},drain:function(t){return new bt(((n,r)=>{let i=e.length;if(!i)return n(!0);const s=setTimeout((()=>{t&&t>0&&n(!1)}),t);e.forEach((t=>{dt(t).then((()=>{--i||(clearTimeout(s),n(!0))}),r)}))}))}}}function mt(e){return"warn"===e?t.Severity.Warning:function(t){return-1!==x.indexOf(t)}(e)?e:t.Severity.Log}function vt(t){return t>=200&&t<300?"success":429===t?"rate_limit":t>=400&&t<500?"invalid":t>=500?"failed":"unknown"}const Ot={nowSeconds:()=>Date.now()/1e3};const jt=function(){const{performance:t}=r();if(!t||!t.now)return;return{now:()=>t.now(),timeOrigin:Date.now()-t.now()}}(),gt=void 0===jt?Ot:{nowSeconds:()=>(jt.timeOrigin+jt.now())/1e3},wt=Ot.nowSeconds.bind(Ot),xt=gt.nowSeconds.bind(gt);function Et(t,e=[]){return[t,e]}function _t(t){const[e,n]=t,r=JSON.stringify(e);return n.reduce(((t,e)=>{const[n,r]=e,i=h(r)?String(r):JSON.stringify(r);return`${t}\n${JSON.stringify(n)}\n${i}`}),r)}(()=>{const{performance:t}=r();if(!t||!t.now)return;const e=36e5,n=t.now(),i=Date.now(),s=t.timeOrigin?Math.abs(t.timeOrigin+n-i):e,o=s<e,c=t.timing&&t.timing.navigationStart,u="number"==typeof c?Math.abs(c+n-i):e;(o||u<e)&&(s<=u&&t.timeOrigin)})();function St(t,e){return t[e]||t.all||0}function $t(t,e,n=Date.now()){return St(t,e)>n}function kt(t,e,n=Date.now()){const r=Object.assign({},t),i=e["x-sentry-rate-limits"],s=e["retry-after"];if(i)for(const t of i.trim().split(",")){const e=t.split(":",2),i=parseInt(e[0],10),s=1e3*(isNaN(i)?60:i);if(e[1])for(const t of e[1].split(";"))r[t]=n+s;else r.all=n+s}else s&&(r.all=n+function(t,e=Date.now()){const n=parseInt(`${t}`,10);if(!isNaN(n))return 1e3*n;const r=Date.parse(`${t}`);return isNaN(r)?6e4:r-e}(s,n));return r}class Tt{constructor(){this.v=!1,this.O=[],this.j=[],this.g=[],this._={},this.S={},this.k={},this.T={},this.R={}}static clone(t){const e=new Tt;return t&&(e.g=[...t.g],e.S=Object.assign({},t.S),e.k=Object.assign({},t.k),e.T=Object.assign({},t.T),e._=t._,e.D=t.D,e.M=t.M,e.N=t.N,e.q=t.q,e.I=t.I,e.j=[...t.j],e.C=t.C),e}addScopeListener(t){this.O.push(t)}addEventProcessor(t){return this.j.push(t),this}setUser(t){return this._=t||{},this.N&&this.N.update({user:t}),this.L(),this}getUser(){return this._}getRequestSession(){return this.C}setRequestSession(t){return this.C=t,this}setTags(t){return this.S=Object.assign(Object.assign({},this.S),t),this.L(),this}setTag(t,e){return this.S=Object.assign(Object.assign({},this.S),{[t]:e}),this.L(),this}setExtras(t){return this.k=Object.assign(Object.assign({},this.k),t),this.L(),this}setExtra(t,e){return this.k=Object.assign(Object.assign({},this.k),{[t]:e}),this.L(),this}setFingerprint(t){return this.I=t,this.L(),this}setLevel(t){return this.D=t,this.L(),this}setTransactionName(t){return this.q=t,this.L(),this}setTransaction(t){return this.setTransactionName(t)}setContext(t,e){return null===e?delete this.T[t]:this.T=Object.assign(Object.assign({},this.T),{[t]:e}),this.L(),this}setSpan(t){return this.M=t,this.L(),this}getSpan(){return this.M}getTransaction(){const t=this.getSpan();return t&&t.transaction}setSession(t){return t?this.N=t:delete this.N,this.L(),this}getSession(){return this.N}update(t){if(!t)return this;if("function"==typeof t){const e=t(this);return e instanceof Tt?e:this}return t instanceof Tt?(this.S=Object.assign(Object.assign({},this.S),t.S),this.k=Object.assign(Object.assign({},this.k),t.k),this.T=Object.assign(Object.assign({},this.T),t.T),t._&&Object.keys(t._).length&&(this._=t._),t.D&&(this.D=t.D),t.I&&(this.I=t.I),t.C&&(this.C=t.C)):f(t)&&(t=t,this.S=Object.assign(Object.assign({},this.S),t.tags),this.k=Object.assign(Object.assign({},this.k),t.extra),this.T=Object.assign(Object.assign({},this.T),t.contexts),t.user&&(this._=t.user),t.level&&(this.D=t.level),t.fingerprint&&(this.I=t.fingerprint),t.requestSession&&(this.C=t.requestSession)),this}clear(){return this.g=[],this.S={},this.k={},this._={},this.T={},this.D=void 0,this.q=void 0,this.I=void 0,this.C=void 0,this.M=void 0,this.N=void 0,this.L(),this}addBreadcrumb(t,e){const n="number"==typeof e?Math.min(e,100):100;if(n<=0)return this;const r=Object.assign({timestamp:wt()},t);return this.g=[...this.g,r].slice(-n),this.L(),this}clearBreadcrumbs(){return this.g=[],this.L(),this}applyToEvent(t,e){if(this.k&&Object.keys(this.k).length&&(t.extra=Object.assign(Object.assign({},this.k),t.extra)),this.S&&Object.keys(this.S).length&&(t.tags=Object.assign(Object.assign({},this.S),t.tags)),this._&&Object.keys(this._).length&&(t.user=Object.assign(Object.assign({},this._),t.user)),this.T&&Object.keys(this.T).length&&(t.contexts=Object.assign(Object.assign({},this.T),t.contexts)),this.D&&(t.level=this.D),this.q&&(t.transaction=this.q),this.M){t.contexts=Object.assign({trace:this.M.getTraceContext()},t.contexts);const e=this.M.transaction&&this.M.transaction.name;e&&(t.tags=Object.assign({transaction:e},t.tags))}return this.A(t),t.breadcrumbs=[...t.breadcrumbs||[],...this.g],t.breadcrumbs=t.breadcrumbs.length>0?t.breadcrumbs:void 0,t.sdkProcessingMetadata=this.R,this.U([...Rt(),...this.j],t,e)}setSDKProcessingMetadata(t){return this.R=Object.assign(Object.assign({},this.R),t),this}U(t,e,n,r=0){return new bt(((i,s)=>{const o=t[r];if(null===e||"function"!=typeof o)i(e);else{const c=o(Object.assign({},e),n);d(c)?c.then((e=>this.U(t,e,n,r+1).then(i))).then(null,s):this.U(t,c,n,r+1).then(i).then(null,s)}}))}L(){this.v||(this.v=!0,this.O.forEach((t=>{t(this)})),this.v=!1)}A(t){t.fingerprint=t.fingerprint?Array.isArray(t.fingerprint)?t.fingerprint:[t.fingerprint]:[],this.I&&(t.fingerprint=t.fingerprint.concat(this.I)),t.fingerprint&&!t.fingerprint.length&&delete t.fingerprint}}function Rt(){const t=r();return t.__SENTRY__=t.__SENTRY__||{},t.__SENTRY__.globalEventProcessors=t.__SENTRY__.globalEventProcessors||[],t.__SENTRY__.globalEventProcessors}function Dt(t){Rt().push(t)}class Mt{constructor(t){this.errors=0,this.sid=rt(),this.duration=0,this.status="ok",this.init=!0,this.ignoreDuration=!1;const e=xt();this.timestamp=e,this.started=e,t&&this.update(t)}update(t={}){if(t.user&&(!this.ipAddress&&t.user.ip_address&&(this.ipAddress=t.user.ip_address),this.did||t.did||(this.did=t.user.id||t.user.email||t.user.username)),this.timestamp=t.timestamp||xt(),t.ignoreDuration&&(this.ignoreDuration=t.ignoreDuration),t.sid&&(this.sid=32===t.sid.length?t.sid:rt()),void 0!==t.init&&(this.init=t.init),!this.did&&t.did&&(this.did=`${t.did}`),"number"==typeof t.started&&(this.started=t.started),this.ignoreDuration)this.duration=void 0;else if("number"==typeof t.duration)this.duration=t.duration;else{const t=this.timestamp-this.started;this.duration=t>=0?t:0}t.release&&(this.release=t.release),t.environment&&(this.environment=t.environment),!this.ipAddress&&t.ipAddress&&(this.ipAddress=t.ipAddress),!this.userAgent&&t.userAgent&&(this.userAgent=t.userAgent),"number"==typeof t.errors&&(this.errors=t.errors),t.status&&(this.status=t.status)}close(t){t?this.update({status:t}):"ok"===this.status?this.update({status:"exited"}):this.update()}toJSON(){return C({sid:`${this.sid}`,init:this.init,started:new Date(1e3*this.started).toISOString(),timestamp:new Date(1e3*this.timestamp).toISOString(),status:this.status,errors:this.errors,did:"number"==typeof this.did||"string"==typeof this.did?`${this.did}`:void 0,duration:this.duration,attrs:{release:this.release,environment:this.environment,ip_address:this.ipAddress,user_agent:this.userAgent}})}}const Nt=100;class qt{constructor(t,e=new Tt,n=4){this.F=n,this.P=[{}],this.getStackTop().scope=e,t&&this.bindClient(t)}isOlderThan(t){return this.F<t}bindClient(t){this.getStackTop().client=t,t&&t.setupIntegrations&&t.setupIntegrations()}pushScope(){const t=Tt.clone(this.getScope());return this.getStack().push({client:this.getClient(),scope:t}),t}popScope(){return!(this.getStack().length<=1)&&!!this.getStack().pop()}withScope(t){const e=this.pushScope();try{t(e)}finally{this.popScope()}}getClient(){return this.getStackTop().client}getScope(){return this.getStackTop().scope}getStack(){return this.P}getStackTop(){return this.P[this.P.length-1]}captureException(t,e){const n=this.B=e&&e.event_id?e.event_id:rt();let r=e;if(!e){let e;try{throw new Error("Sentry syntheticException")}catch(t){e=t}r={originalException:t,syntheticException:e}}return this.H("captureException",t,Object.assign(Object.assign({},r),{event_id:n})),n}captureMessage(t,e,n){const r=this.B=n&&n.event_id?n.event_id:rt();let i=n;if(!n){let e;try{throw new Error(t)}catch(t){e=t}i={originalException:t,syntheticException:e}}return this.H("captureMessage",t,e,Object.assign(Object.assign({},i),{event_id:r})),r}captureEvent(t,e){const n=e&&e.event_id?e.event_id:rt();return"transaction"!==t.type&&(this.B=n),this.H("captureEvent",t,Object.assign(Object.assign({},e),{event_id:n})),n}lastEventId(){return this.B}addBreadcrumb(t,e){const{scope:n,client:i}=this.getStackTop();if(!n||!i)return;const{beforeBreadcrumb:s=null,maxBreadcrumbs:o=Nt}=i.getOptions&&i.getOptions()||{};if(o<=0)return;const c=wt(),u=Object.assign({timestamp:c},t),a=s?function(t){const e=r();if(!("console"in e))return t();const n=e.console,i={};E.forEach((t=>{t in e.console&&n[t].__sentry_original__&&(i[t]=n[t],n[t]=n[t].__sentry_original__)}));const s=t();return Object.keys(i).forEach((t=>{n[t]=i[t]})),s}((()=>s(u,e))):u;null!==a&&n.addBreadcrumb(a,o)}setUser(t){const e=this.getScope();e&&e.setUser(t)}setTags(t){const e=this.getScope();e&&e.setTags(t)}setExtras(t){const e=this.getScope();e&&e.setExtras(t)}setTag(t,e){const n=this.getScope();n&&n.setTag(t,e)}setExtra(t,e){const n=this.getScope();n&&n.setExtra(t,e)}setContext(t,e){const n=this.getScope();n&&n.setContext(t,e)}configureScope(t){const{scope:e,client:n}=this.getStackTop();e&&n&&t(e)}run(t){const e=Ct(this);try{t(this)}finally{Ct(e)}}getIntegration(t){const e=this.getClient();if(!e)return null;try{return e.getIntegration(t)}catch(t){return null}}startSpan(t){return this.X("startSpan",t)}startTransaction(t,e){return this.X("startTransaction",t,e)}traceHeaders(){return this.X("traceHeaders")}captureSession(t=!1){if(t)return this.endSession();this.J()}endSession(){const t=this.getStackTop(),e=t&&t.scope,n=e&&e.getSession();n&&n.close(),this.J(),e&&e.setSession()}startSession(t){const{scope:e,client:n}=this.getStackTop(),{release:i,environment:s}=n&&n.getOptions()||{},o=r(),{userAgent:c}=o.navigator||{},u=new Mt(Object.assign(Object.assign(Object.assign({release:i,environment:s},e&&{user:e.getUser()}),c&&{userAgent:c}),t));if(e){const t=e.getSession&&e.getSession();t&&"ok"===t.status&&t.update({status:"exited"}),this.endSession(),e.setSession(u)}return u}J(){const{scope:t,client:e}=this.getStackTop();if(!t)return;const n=t.getSession&&t.getSession();n&&e&&e.captureSession&&e.captureSession(n)}H(t,...e){const{scope:n,client:r}=this.getStackTop();r&&r[t]&&r[t](...e,n)}X(t,...e){const n=It().__SENTRY__;if(n&&n.extensions&&"function"==typeof n.extensions[t])return n.extensions[t].apply(this,e)}}function It(){const t=r();return t.__SENTRY__=t.__SENTRY__||{extensions:{},hub:void 0},t}function Ct(t){const e=It(),n=At(e);return Ut(e,t),n}function Lt(){const t=It();var e;return(e=t)&&e.__SENTRY__&&e.__SENTRY__.hub&&!At(t).isOlderThan(4)||Ut(t,new qt),At(t)}function At(t){return t&&t.__SENTRY__&&t.__SENTRY__.hub||(t.__SENTRY__=t.__SENTRY__||{},t.__SENTRY__.hub=new qt),t.__SENTRY__.hub}function Ut(t,e){return!!t&&(t.__SENTRY__=t.__SENTRY__||{},t.__SENTRY__.hub=e,!0)}function Ft(t,...e){const n=Lt();if(n&&n[t])return n[t](...e);throw new Error(`No hub defined or ${t} was not found on the hub, please open a bug report.`)}function captureException(t,e){return Ft("captureException",t,{captureContext:e,originalException:t,syntheticException:new Error("Sentry syntheticException")})}function Pt(t){Ft("withScope",t)}function Bt(t,e,n){return{initDsn:t,metadata:e||{},dsn:w(t),tunnel:n}}function Ht(t){const e=t.protocol?`${t.protocol}:`:"",n=t.port?`:${t.port}`:"";return`${e}//${t.host}${n}${t.path?`/${t.path}`:""}/api/`}function Xt(t,e){return`${Ht(t)}${t.projectId}/${e}/`}function zt(t){return e={sentry_key:t.publicKey,sentry_version:"7"},Object.keys(e).map((t=>`${encodeURIComponent(t)}=${encodeURIComponent(e[t])}`)).join("&");var e}function Jt(t){return`${function(t){return Xt(t,"store")}(t)}?${zt(t)}`}function Wt(t,e){return e||`${function(t){return Xt(t,"envelope")}(t)}?${zt(t)}`}const Kt=[];function Gt(t){return t.reduce(((t,e)=>(t.every((t=>e.name!==t.name))&&t.push(e),t)),[])}function Vt(t){const e={};return function(t){const e=t.defaultIntegrations&&[...t.defaultIntegrations]||[],n=t.integrations;let r=[...Gt(e)];Array.isArray(n)?r=[...r.filter((t=>n.every((e=>e.name!==t.name)))),...Gt(n)]:"function"==typeof n&&(r=n(r),r=Array.isArray(r)?r:[r]);const i=r.map((t=>t.name)),s="Debug";return-1!==i.indexOf(s)&&r.push(...r.splice(i.indexOf(s),1)),r}(t).forEach((t=>{e[t.name]=t,function(t){-1===Kt.indexOf(t.name)&&(t.setupOnce(Dt,Lt),Kt.push(t.name))}(t)})),T(e,"initialized",!0),e}function Qt(t){if(!t.metadata||!t.metadata.sdk)return;const{name:e,version:n}=t.metadata.sdk;return{name:e,version:n}}function Yt(t,e){return e?(t.sdk=t.sdk||{},t.sdk.name=t.sdk.name||e.name,t.sdk.version=t.sdk.version||e.version,t.sdk.integrations=[...t.sdk.integrations||[],...e.integrations||[]],t.sdk.packages=[...t.sdk.packages||[],...e.packages||[]],t):t}function Zt(t,e){const n=Qt(e),r="aggregates"in t?"sessions":"session";return[Et(Object.assign(Object.assign({sent_at:(new Date).toISOString()},n&&{sdk:n}),!!e.tunnel&&{dsn:j(e.dsn)}),[[{type:r},t]]),r]}class te{sendEvent(t){return dt({reason:"NoopTransport: Event has been skipped because no Dsn is configured.",status:"skipped"})}close(t){return dt(!0)}}function ee(t,e,n=yt(t.bufferSize||30)){let r={};return{send:function(t){const i=function(t){const[,[[e]]]=t;return e.type}(t),s="event"===i?"error":i,o={category:s,body:_t(t)};return $t(r,s)?pt({status:"rate_limit",reason:ne(r,s)}):n.add((()=>e(o).then((({body:t,headers:e,reason:n,statusCode:i})=>{const o=vt(i);return e&&(r=kt(r,e)),"success"===o?dt({status:o,reason:n}):pt({status:o,reason:n||t||("rate_limit"===o?ne(r,s):"Unknown transport error")})}))))},flush:t=>n.drain(t)}}function ne(t,e){return`Too many ${e} requests, backing off until: ${new Date(St(t,e)).toISOString()}`}const re="6.19.3";let ie;class se{constructor(){this.name=se.id}setupOnce(){ie=Function.prototype.toString,Function.prototype.toString=function(...t){const e=D(this)||this;return ie.apply(e,t)}}}se.id="FunctionToString";const oe=[/^Script error\.?$/,/^Javascript error: Script error\.? on line 0$/];class ce{constructor(t={}){this.W=t,this.name=ce.id}setupOnce(t,e){t((t=>{const n=e();if(n){const e=n.getIntegration(ce);if(e){const r=n.getClient(),i=r?r.getOptions():{},s=function(t={},e={}){return{allowUrls:[...t.whitelistUrls||[],...t.allowUrls||[],...e.whitelistUrls||[],...e.allowUrls||[]],denyUrls:[...t.blacklistUrls||[],...t.denyUrls||[],...e.blacklistUrls||[],...e.denyUrls||[]],ignoreErrors:[...t.ignoreErrors||[],...e.ignoreErrors||[],...oe],ignoreInternal:void 0===t.ignoreInternal||t.ignoreInternal}}(e.W,i);return function(t,e){if(e.ignoreInternal&&function(t){try{return"SentryError"===t.exception.values[0].type}catch(t){}return!1}(t))return!0;if(function(t,e){if(!e||!e.length)return!1;return function(t){if(t.message)return[t.message];if(t.exception)try{const{type:e="",value:n=""}=t.exception.values&&t.exception.values[0]||{};return[`${n}`,`${e}: ${n}`]}catch(t){return[]}return[]}(t).some((t=>e.some((e=>$(t,e)))))}(t,e.ignoreErrors))return!0;if(function(t,e){if(!e||!e.length)return!1;const n=ae(t);return!!n&&e.some((t=>$(n,t)))}(t,e.denyUrls))return!0;if(!function(t,e){if(!e||!e.length)return!0;const n=ae(t);return!n||e.some((t=>$(n,t)))}(t,e.allowUrls))return!0;return!1}(t,s)?null:t}}return t}))}}function ue(t=[]){for(let e=t.length-1;e>=0;e--){const n=t[e];if(n&&"<anonymous>"!==n.filename&&"[native code]"!==n.filename)return n.filename||null}return null}function ae(t){try{if(t.stacktrace)return ue(t.stacktrace.frames);let e;try{e=t.exception.values[0].stacktrace.frames}catch(t){}return e?ue(e):null}catch(t){return null}}ce.id="InboundFilters";var he=Object.freeze({__proto__:null,FunctionToString:se,InboundFilters:ce});const fe="?";function le(t,e,n,r){const i={filename:t,function:e,in_app:!0};return void 0!==n&&(i.lineno=n),void 0!==r&&(i.colno=r),i}const de=/^\s*at (?:(.*?) ?\((?:address at )?)?((?:file|https?|blob|chrome-extension|address|native|eval|webpack|<anonymous>|[-a-z]+:|.*bundle|\/).*?)(?::(\d+))?(?::(\d+))?\)?\s*$/i,pe=/\((\S*)(?::(\d+))(?::(\d+))\)/,be=[30,t=>{const e=de.exec(t);if(e){if(e[2]&&0===e[2].indexOf("eval")){const t=pe.exec(e[2]);t&&(e[2]=t[1],e[3]=t[2],e[4]=t[3])}const[t,n]=_e(e[1]||fe,e[2]);return le(n,t,e[3]?+e[3]:void 0,e[4]?+e[4]:void 0)}}],ye=/^\s*(.*?)(?:\((.*?)\))?(?:^|@)?((?:file|https?|blob|chrome|webpack|resource|moz-extension|capacitor).*?:\/.*?|\[native code\]|[^@]*(?:bundle|\d+\.js)|\/[\w\-. /=]+)(?::(\d+))?(?::(\d+))?\s*$/i,me=/(\S+) line (\d+)(?: > eval line \d+)* > eval/i,ve=[50,t=>{const e=ye.exec(t);if(e){if(e[3]&&e[3].indexOf(" > eval")>-1){const t=me.exec(e[3]);t&&(e[1]=e[1]||"eval",e[3]=t[1],e[4]=t[2],e[5]="")}let t=e[3],n=e[1]||fe;return[n,t]=_e(n,t),le(t,n,e[4]?+e[4]:void 0,e[5]?+e[5]:void 0)}}],Oe=/^\s*at (?:((?:\[object object\])?.+) )?\(?((?:file|ms-appx|https?|webpack|blob):.*?):(\d+)(?::(\d+))?\)?\s*$/i,je=[40,t=>{const e=Oe.exec(t);return e?le(e[2],e[1]||fe,+e[3],e[4]?+e[4]:void 0):void 0}],ge=/ line (\d+).*script (?:in )?(\S+)(?:: in function (\S+))?$/i,we=[10,t=>{const e=ge.exec(t);return e?le(e[2],e[3]||fe,+e[1]):void 0}],xe=/ line (\d+), column (\d+)\s*(?:in (?:<anonymous function: ([^>]+)>|([^)]+))\(.*\))? in (.*):\s*$/i,Ee=[20,t=>{const e=xe.exec(t);return e?le(e[5],e[3]||e[4]||fe,+e[1],+e[2]):void 0}],_e=(t,e)=>{const n=-1!==t.indexOf("safari-extension"),r=-1!==t.indexOf("safari-web-extension");return n||r?[-1!==t.indexOf("@")?t.split("@")[0]:fe,n?`safari-extension:${e}`:`safari-web-extension:${e}`]:[t,e]};function Se(t){const e=ke(t),n={type:t&&t.name,value:Re(t)};return e.length&&(n.stacktrace={frames:e}),void 0===n.type&&""===n.value&&(n.value="Unrecoverable error caught"),n}function $e(t){return{exception:{values:[Se(t)]}}}function ke(t){const e=t.stacktrace||t.stack||"",n=function(t){if(t){if("number"==typeof t.framesToPop)return t.framesToPop;if(Te.test(t.message))return 1}return 0}(t);try{return L(we,Ee,be,je,ve)(e,n)}catch(t){}return[]}const Te=/Minified React error #\d+;/i;function Re(t){const e=t&&t.message;return e?e.error&&"string"==typeof e.error.message?e.error.message:e:"No error message"}function De(e,n,r){const i=Ne(e,n&&n.syntheticException||void 0,r);return ut(i),i.level=t.Severity.Error,n&&n.event_id&&(i.event_id=n.event_id),dt(i)}function Me(e,n=t.Severity.Info,r,i){const s=qe(e,r&&r.syntheticException||void 0,i);return s.level=n,r&&r.event_id&&(s.event_id=r.event_id),dt(s)}function Ne(t,e,n,r){let i;if(c(t)&&t.error){return $e(t.error)}if(u(t)||o(t,"DOMException")){const r=t;if("stack"in t)i=$e(t);else{const t=r.name||(u(r)?"DOMError":"DOMException"),s=r.message?`${t}: ${r.message}`:t;i=qe(s,e,n),ct(i,s)}return"code"in r&&(i.tags=Object.assign(Object.assign({},i.tags),{"DOMException.code":`${r.code}`})),i}if(s(t))return $e(t);if(f(t)||l(t)){return i=function(t,e,n){const r={exception:{values:[{type:l(t)?t.constructor.name:n?"UnhandledRejection":"Error",value:`Non-Error ${n?"promise rejection":"exception"} captured with keys: ${I(t)}`}]},extra:{__serialized__:ft(t)}};if(e){const t=ke(e);t.length&&(r.stacktrace={frames:t})}return r}(t,e,r),ut(i,{synthetic:!0}),i}return i=qe(t,e,n),ct(i,`${t}`,void 0),ut(i,{synthetic:!0}),i}function qe(t,e,n){const r={message:t};if(n&&e){const t=ke(e);t.length&&(r.stacktrace={frames:t})}return r}const Ie=r();let Ce;function Le(){if(Ce)return Ce;if(P(Ie.fetch))return Ce=Ie.fetch.bind(Ie);const t=Ie.document;let e=Ie.fetch;if(t&&"function"==typeof t.createElement)try{const n=t.createElement("iframe");n.hidden=!0,t.head.appendChild(n);const r=n.contentWindow;r&&r.fetch&&(e=r.fetch),t.head.removeChild(n)}catch(t){}return Ce=e.bind(Ie)}function Ae(t,e){if("[object Navigator]"===Object.prototype.toString.call(Ie&&Ie.navigator)&&"function"==typeof Ie.navigator.sendBeacon){return Ie.navigator.sendBeacon.bind(Ie.navigator)(t,e)}if(F()){const n=Le();n(t,{body:e,method:"POST",credentials:"omit",keepalive:!0}).then(null,(t=>{console.error(t)}))}else;}function Ue(t){return"event"===t?"error":t}const Fe=r();class Pe{constructor(t){this.options=t,this.K=yt(30),this.G={},this.V={},this.Y=Bt(t.dsn,t.Z,t.tunnel),this.url=Jt(this.Y.dsn),this.options.sendClientReports&&Fe.document&&Fe.document.addEventListener("visibilitychange",(()=>{"hidden"===Fe.document.visibilityState&&this.tt()}))}sendEvent(t){return this.et(function(t,e){const n=Qt(e),r=t.type||"event",i="transaction"===r||!!e.tunnel,{transactionSampling:s}=t.sdkProcessingMetadata||{},{method:o,rate:c}=s||{};let u;Yt(t,e.metadata.sdk),t.tags=t.tags||{},t.extra=t.extra||{},t.sdkProcessingMetadata&&t.sdkProcessingMetadata.baseClientNormalized||(t.tags.skippedNormalization=!0,t.extra.normalizeDepth=t.sdkProcessingMetadata?t.sdkProcessingMetadata.normalizeDepth:"unset"),delete t.sdkProcessingMetadata;try{u=JSON.stringify(t)}catch(e){t.tags.JSONStringifyError=!0,t.extra.JSONStringifyError=e;try{u=JSON.stringify(ht(t))}catch(t){const e=t;u=JSON.stringify({message:"JSON.stringify error after renormalization",extra:{message:e.message,stack:e.stack}})}}const a={body:u,type:r,url:i?Wt(e.dsn,e.tunnel):Jt(e.dsn)};if(i){const i=Et(Object.assign(Object.assign({event_id:t.event_id,sent_at:(new Date).toISOString()},n&&{sdk:n}),!!e.tunnel&&{dsn:j(e.dsn)}),[[{type:r,sample_rates:[{id:o,rate:c}]},a.body]]);a.body=_t(i)}return a}(t,this.Y),t)}sendSession(t){return this.et(function(t,e){const[n,r]=Zt(t,e);return{body:_t(n),type:r,url:Wt(e.dsn,e.tunnel)}}(t,this.Y),t)}close(t){return this.K.drain(t)}recordLostEvent(t,e){var n;if(!this.options.sendClientReports)return;const r=`${Ue(e)}:${t}`;this.V[r]=(null!=(n=this.V[r])?n:0)+1}tt(){if(!this.options.sendClientReports)return;const t=this.V;if(this.V={},!Object.keys(t).length)return;const e=Wt(this.Y.dsn,this.Y.tunnel),n=Object.keys(t).map((e=>{const[n,r]=e.split(":");return{reason:r,category:n,quantity:t[e]}})),r=(i=n,Et((s=this.Y.tunnel&&j(this.Y.dsn))?{dsn:s}:{},[[{type:"client_report"},{timestamp:o||wt(),discarded_events:i}]]));var i,s,o;try{Ae(e,_t(r))}catch(t){}}nt({requestType:t,response:e,headers:n,resolve:r,reject:i}){const s=vt(e.status);this.G=kt(this.G,n),this.rt(t),"success"!==s?i(e):r({status:s})}it(t){const e=Ue(t);return new Date(St(this.G,e))}rt(t){const e=Ue(t);return $t(this.G,e)}}class Be extends Pe{constructor(t,e=Le()){super(t),this.st=e}et(t,e){if(this.rt(t.type))return this.recordLostEvent("ratelimit_backoff",t.type),Promise.reject({event:e,type:t.type,reason:`Transport for ${t.type} requests locked till ${this.it(t.type)} due to too many requests.`,status:429});const n={body:t.body,method:"POST",referrerPolicy:B()?"origin":""};return void 0!==this.options.fetchParameters&&Object.assign(n,this.options.fetchParameters),void 0!==this.options.headers&&(n.headers=this.options.headers),this.K.add((()=>new bt(((e,r)=>{this.st(t.url,n).then((n=>{const i={"x-sentry-rate-limits":n.headers.get("X-Sentry-Rate-Limits"),"retry-after":n.headers.get("Retry-After")};this.nt({requestType:t.type,response:n,headers:i,resolve:e,reject:r})})).catch(r)})))).then(void 0,(e=>{throw e instanceof v?this.recordLostEvent("queue_overflow",t.type):this.recordLostEvent("network_error",t.type),e}))}}class He extends Pe{et(t,e){return this.rt(t.type)?(this.recordLostEvent("ratelimit_backoff",t.type),Promise.reject({event:e,type:t.type,reason:`Transport for ${t.type} requests locked till ${this.it(t.type)} due to too many requests.`,status:429})):this.K.add((()=>new bt(((e,n)=>{const r=new XMLHttpRequest;r.onreadystatechange=()=>{if(4===r.readyState){const i={"x-sentry-rate-limits":r.getResponseHeader("X-Sentry-Rate-Limits"),"retry-after":r.getResponseHeader("Retry-After")};this.nt({requestType:t.type,response:r,headers:i,resolve:e,reject:n})}},r.open("POST",t.url);for(const t in this.options.headers)Object.prototype.hasOwnProperty.call(this.options.headers,t)&&r.setRequestHeader(t,this.options.headers[t]);r.send(t.body)})))).then(void 0,(e=>{throw e instanceof v?this.recordLostEvent("queue_overflow",t.type):this.recordLostEvent("network_error",t.type),e}))}}function Xe(t,e=Le()){return ee({bufferSize:t.bufferSize},(function(n){const r=Object.assign({body:n.body,method:"POST",referrerPolicy:"origin"},t.requestOptions);return e(t.url,r).then((t=>t.text().then((e=>({body:e,headers:{"x-sentry-rate-limits":t.headers.get("X-Sentry-Rate-Limits"),"retry-after":t.headers.get("Retry-After")},reason:t.statusText,statusCode:t.status})))))}))}function ze(t){return ee({bufferSize:t.bufferSize},(function(e){return new bt(((n,r)=>{const i=new XMLHttpRequest;i.onreadystatechange=()=>{if(4===i.readyState){const t={body:i.response,headers:{"x-sentry-rate-limits":i.getResponseHeader("X-Sentry-Rate-Limits"),"retry-after":i.getResponseHeader("Retry-After")},reason:i.statusText,statusCode:i.status};n(t)}},i.open("POST",t.url);for(const e in t.headers)Object.prototype.hasOwnProperty.call(t.headers,e)&&i.setRequestHeader(e,t.headers[e]);i.send(e.body)}))}))}var Je=Object.freeze({__proto__:null,BaseTransport:Pe,FetchTransport:Be,XHRTransport:He,makeNewFetchTransport:Xe,makeNewXHRTransport:ze});class We extends class{constructor(t){this.W=t,this.ot=this.ct()}eventFromException(t,e){throw new v("Backend has to implement `eventFromException` method")}eventFromMessage(t,e,n){throw new v("Backend has to implement `eventFromMessage` method")}sendEvent(t){if(this.ut&&this.W.dsn&&this.W._experiments&&this.W._experiments.newTransport){const e=function(t,e){const n=Qt(e),r=t.type||"event",{transactionSampling:i}=t.sdkProcessingMetadata||{},{method:s,rate:o}=i||{};return Yt(t,e.metadata.sdk),t.tags=t.tags||{},t.extra=t.extra||{},t.sdkProcessingMetadata&&t.sdkProcessingMetadata.baseClientNormalized||(t.tags.skippedNormalization=!0,t.extra.normalizeDepth=t.sdkProcessingMetadata?t.sdkProcessingMetadata.normalizeDepth:"unset"),delete t.sdkProcessingMetadata,Et(Object.assign(Object.assign({event_id:t.event_id,sent_at:(new Date).toISOString()},n&&{sdk:n}),!!e.tunnel&&{dsn:j(e.dsn)}),[[{type:r,sample_rates:[{id:s,rate:o}]},t]])}(t,Bt(this.W.dsn,this.W.Z,this.W.tunnel));this.ut.send(e).then(null,(t=>{}))}else this.ot.sendEvent(t).then(null,(t=>{}))}sendSession(t){if(this.ot.sendSession)if(this.ut&&this.W.dsn&&this.W._experiments&&this.W._experiments.newTransport){const e=Bt(this.W.dsn,this.W.Z,this.W.tunnel),[n]=Zt(t,e);this.ut.send(n).then(null,(t=>{}))}else this.ot.sendSession(t).then(null,(t=>{}))}getTransport(){return this.ot}ct(){return new te}}{eventFromException(t,e){return De(t,e,this.W.attachStacktrace)}eventFromMessage(e,n=t.Severity.Info,r){return Me(e,n,r,this.W.attachStacktrace)}ct(){if(!this.W.dsn)return super.ct();const t=Object.assign(Object.assign({},this.W.transportOptions),{dsn:this.W.dsn,tunnel:this.W.tunnel,sendClientReports:this.W.sendClientReports,Z:this.W.Z}),e=Bt(t.dsn,t.Z,t.tunnel),n=Wt(e.dsn,e.tunnel);if(this.W.transport)return new this.W.transport(t);if(F()){const e=Object.assign({},t.fetchParameters);return this.ut=Xe({requestOptions:e,url:n}),new Be(t)}return this.ut=ze({url:n,headers:t.headers}),new He(t)}}const Ke=r();let Ge=0;function Ve(){return Ge>0}function Qe(){Ge+=1,setTimeout((()=>{Ge-=1}))}function Ye(t,e={},n){if("function"!=typeof t)return t;try{const e=t.__sentry_wrapped__;if(e)return e;if(D(t))return t}catch(e){return t}const sentryWrapped=function(){const r=Array.prototype.slice.call(arguments);try{n&&"function"==typeof n&&n.apply(this,arguments);const i=r.map((t=>Ye(t,e)));return t.apply(this,i)}catch(t){throw Qe(),Pt((n=>{n.addEventProcessor((t=>(e.mechanism&&(ct(t,void 0,void 0),ut(t,e.mechanism)),t.extra=Object.assign(Object.assign({},t.extra),{arguments:r}),t))),captureException(t)})),t}};try{for(const e in t)Object.prototype.hasOwnProperty.call(t,e)&&(sentryWrapped[e]=t[e])}catch(t){}R(sentryWrapped,t),T(t,"__sentry_wrapped__",sentryWrapped);try{Object.getOwnPropertyDescriptor(sentryWrapped,"name").configurable&&Object.defineProperty(sentryWrapped,"name",{get:()=>t.name})}catch(t){}return sentryWrapped}function Ze(t={}){if(!Ke.document)return;if(!t.eventId)return;if(!t.dsn)return;const e=Ke.document.createElement("script");e.async=!0,e.src=function(t,e){const n=w(t),r=`${Ht(n)}embed/error-page/`;let i=`dsn=${j(n)}`;for(const t in e)if("dsn"!==t)if("user"===t){if(!e.user)continue;e.user.name&&(i+=`&name=${encodeURIComponent(e.user.name)}`),e.user.email&&(i+=`&email=${encodeURIComponent(e.user.email)}`)}else i+=`&${encodeURIComponent(t)}=${encodeURIComponent(e[t])}`;return`${r}?${i}`}(t.dsn,t),t.onLoad&&(e.onload=t.onLoad);const n=Ke.document.head||Ke.document.body;n&&n.appendChild(e)}class tn{constructor(t){this.name=tn.id,this.at={onerror:en,onunhandledrejection:nn},this.W=Object.assign({onerror:!0,onunhandledrejection:!0},t)}setupOnce(){Error.stackTraceLimit=50;const t=this.W;for(const e in t){const n=this.at[e];n&&t[e]&&(n(),this.at[e]=void 0)}}}function en(){W("error",(e=>{const[n,r]=on();if(!n.getIntegration(tn))return;const{msg:i,url:s,line:o,column:u,error:h}=e;if(Ve()||h&&h.__sentry_own_request__)return;const f=void 0===h&&a(i)?function(t,e,n,r){const i=/^(?:[Uu]ncaught (?:exception: )?)?(?:((?:Eval|Internal|Range|Reference|Syntax|Type|URI|)Error): )?(.*)$/i;let s=c(t)?t.message:t,o="Error";const u=s.match(i);u&&(o=u[1],s=u[2]);return rn({exception:{values:[{type:o,value:s}]}},e,n,r)}(i,s,o,u):rn(Ne(h||i,void 0,r,!1),s,o,u);f.level=t.Severity.Error,sn(n,h,f,"onerror")}))}function nn(){W("unhandledrejection",(e=>{const[n,r]=on();if(!n.getIntegration(tn))return;let i=e;try{"reason"in e?i=e.reason:"detail"in e&&"reason"in e.detail&&(i=e.detail.reason)}catch(t){}if(Ve()||i&&i.__sentry_own_request__)return!0;const s=h(i)?{exception:{values:[{type:"UnhandledRejection",value:`Non-Error promise rejection captured with value: ${String(i)}`}]}}:Ne(i,void 0,r,!0);s.level=t.Severity.Error,sn(n,i,s,"onunhandledrejection")}))}function rn(t,e,n,i){const s=t.exception=t.exception||{},o=s.values=s.values||[],c=o[0]=o[0]||{},u=c.stacktrace=c.stacktrace||{},h=u.frames=u.frames||[],f=isNaN(parseInt(i,10))?void 0:i,l=isNaN(parseInt(n,10))?void 0:n,d=a(e)&&e.length>0?e:function(){const t=r();try{return t.document.location.href}catch(t){return""}}();return 0===h.length&&h.push({colno:f,filename:d,function:"?",in_app:!0,lineno:l}),t}function sn(t,e,n,r){ut(n,{handled:!1,type:r}),t.captureEvent(n,{originalException:e})}function on(){const t=Lt(),e=t.getClient();return[t,e&&e.getOptions().attachStacktrace]}tn.id="GlobalHandlers";const cn=["EventTarget","Window","Node","ApplicationCache","AudioTrackList","ChannelMergerNode","CryptoOperation","EventSource","FileReader","HTMLUnknownElement","IDBDatabase","IDBRequest","IDBTransaction","KeyOperation","MediaController","MessagePort","ModalWindow","Notification","SVGElementInstance","Screen","TextTrack","TextTrackCue","TextTrackList","WebSocket","WebSocketWorker","Worker","XMLHttpRequest","XMLHttpRequestEventTarget","XMLHttpRequestUpload"];class un{constructor(t){this.name=un.id,this.W=Object.assign({XMLHttpRequest:!0,eventTarget:!0,requestAnimationFrame:!0,setInterval:!0,setTimeout:!0},t)}setupOnce(){const t=r();this.W.setTimeout&&k(t,"setTimeout",an),this.W.setInterval&&k(t,"setInterval",an),this.W.requestAnimationFrame&&k(t,"requestAnimationFrame",hn),this.W.XMLHttpRequest&&"XMLHttpRequest"in t&&k(XMLHttpRequest.prototype,"send",fn);const e=this.W.eventTarget;if(e){(Array.isArray(e)?e:cn).forEach(ln)}}}function an(t){return function(...e){const n=e[0];return e[0]=Ye(n,{mechanism:{data:{function:U(t)},handled:!0,type:"instrument"}}),t.apply(this,e)}}function hn(t){return function(e){return t.apply(this,[Ye(e,{mechanism:{data:{function:"requestAnimationFrame",handler:U(t)},handled:!0,type:"instrument"}})])}}function fn(t){return function(...e){const n=this;return["onload","onerror","onprogress","onreadystatechange"].forEach((t=>{t in n&&"function"==typeof n[t]&&k(n,t,(function(e){const n={mechanism:{data:{function:t,handler:U(e)},handled:!0,type:"instrument"}},r=D(e);return r&&(n.mechanism.data.handler=U(r)),Ye(e,n)}))})),t.apply(this,e)}}function ln(t){const e=r(),n=e[t]&&e[t].prototype;n&&n.hasOwnProperty&&n.hasOwnProperty("addEventListener")&&(k(n,"addEventListener",(function(e){return function(n,r,i){try{"function"==typeof r.handleEvent&&(r.handleEvent=Ye(r.handleEvent.bind(r),{mechanism:{data:{function:"handleEvent",handler:U(r),target:t},handled:!0,type:"instrument"}}))}catch(t){}return e.apply(this,[n,Ye(r,{mechanism:{data:{function:"addEventListener",handler:U(r),target:t},handled:!0,type:"instrument"}}),i])}})),k(n,"removeEventListener",(function(t){return function(e,n,r){const i=n;try{const n=i&&i.__sentry_wrapped__;n&&t.call(this,e,n,r)}catch(t){}return t.call(this,e,i,r)}})))}un.id="TryCatch";class dn{constructor(t){this.name=dn.id,this.W=Object.assign({console:!0,dom:!0,fetch:!0,history:!0,sentry:!0,xhr:!0},t)}addSentryBreadcrumb(t){this.W.sentry&&Lt().addBreadcrumb({category:"sentry."+("transaction"===t.type?"transaction":"event"),event_id:t.event_id,level:t.level,message:ot(t)},{event:t})}setupOnce(){this.W.console&&W("console",pn),this.W.dom&&W("dom",function(t){function e(e){let n,r="object"==typeof t?t.serializeAttribute:void 0;"string"==typeof r&&(r=[r]);try{n=e.event.target?b(e.event.target,r):b(e.event,r)}catch(t){n="<unknown>"}0!==n.length&&Lt().addBreadcrumb({category:`ui.${e.name}`,message:n},{event:e.event,name:e.name,global:e.global})}return e}(this.W.dom)),this.W.xhr&&W("xhr",bn),this.W.fetch&&W("fetch",yn),this.W.history&&W("history",mn)}}function pn(t){const e={category:"console",data:{arguments:t.args,logger:"console"},level:mt(t.level),message:S(t.args," ")};if("assert"===t.level){if(!1!==t.args[0])return;e.message=`Assertion failed: ${S(t.args.slice(1)," ")||"console.assert"}`,e.data.arguments=t.args.slice(1)}Lt().addBreadcrumb(e,{input:t.args,level:t.level})}function bn(t){if(t.endTimestamp){if(t.xhr.__sentry_own_request__)return;const{method:e,url:n,status_code:r,body:i}=t.xhr.__sentry_xhr__||{};Lt().addBreadcrumb({category:"xhr",data:{method:e,url:n,status_code:r},type:"http"},{xhr:t.xhr,input:i})}else;}function yn(e){e.endTimestamp&&(e.fetchData.url.match(/sentry_key/)&&"POST"===e.fetchData.method||(e.error?Lt().addBreadcrumb({category:"fetch",data:e.fetchData,level:t.Severity.Error,type:"http"},{data:e.error,input:e.args}):Lt().addBreadcrumb({category:"fetch",data:Object.assign(Object.assign({},e.fetchData),{status_code:e.response.status}),type:"http"},{input:e.args,response:e.response})))}function mn(t){const e=r();let n=t.from,i=t.to;const s=it(e.location.href);let o=it(n);const c=it(i);o.path||(o=s),s.protocol===c.protocol&&s.host===c.host&&(i=c.relative),s.protocol===o.protocol&&s.host===o.host&&(n=o.relative),Lt().addBreadcrumb({category:"navigation",data:{from:n,to:i}})}dn.id="Breadcrumbs";class vn{constructor(t={}){this.name=vn.id,this.ht=t.key||"cause",this.ft=t.limit||5}setupOnce(){Dt(((t,e)=>{const n=Lt().getIntegration(vn);return n?function(t,e,n,r){if(!(n.exception&&n.exception.values&&r&&p(r.originalException,Error)))return n;const i=On(e,r.originalException,t);return n.exception.values=[...i,...n.exception.values],n}(n.ht,n.ft,t,e):t}))}}function On(t,e,n,r=[]){if(!p(e[n],Error)||r.length+1>=t)return r;const i=Se(e[n]);return On(t,e[n],n,[i,...r])}vn.id="LinkedErrors";const jn=r();class gn{constructor(){this.name=gn.id}setupOnce(){Dt((t=>{if(Lt().getIntegration(gn)){if(!jn.navigator&&!jn.location&&!jn.document)return t;const e=t.request&&t.request.url||jn.location&&jn.location.href,{referrer:n}=jn.document||{},{userAgent:r}=jn.navigator||{},i=Object.assign(Object.assign(Object.assign({},t.request&&t.request.headers),n&&{Referer:n}),r&&{"User-Agent":r}),s=Object.assign(Object.assign({},e&&{url:e}),{headers:i});return Object.assign(Object.assign({},t),{request:s})}return t}))}}gn.id="UserAgent";class wn{constructor(){this.name=wn.id}setupOnce(t,e){t((t=>{const n=e().getIntegration(wn);if(n){try{if(function(t,e){if(!e)return!1;if(function(t,e){const n=t.message,r=e.message;if(!n&&!r)return!1;if(n&&!r||!n&&r)return!1;if(n!==r)return!1;if(!En(t,e))return!1;if(!xn(t,e))return!1;return!0}(t,e))return!0;if(function(t,e){const n=_n(e),r=_n(t);if(!n||!r)return!1;if(n.type!==r.type||n.value!==r.value)return!1;if(!En(t,e))return!1;if(!xn(t,e))return!1;return!0}(t,e))return!0;return!1}(t,n.lt))return null}catch(e){return n.lt=t}return n.lt=t}return t}))}}function xn(t,e){let n=Sn(t),r=Sn(e);if(!n&&!r)return!0;if(n&&!r||!n&&r)return!1;if(n=n,r=r,r.length!==n.length)return!1;for(let t=0;t<r.length;t++){const e=r[t],i=n[t];if(e.filename!==i.filename||e.lineno!==i.lineno||e.colno!==i.colno||e.function!==i.function)return!1}return!0}function En(t,e){let n=t.fingerprint,r=e.fingerprint;if(!n&&!r)return!0;if(n&&!r||!n&&r)return!1;n=n,r=r;try{return!(n.join("")!==r.join(""))}catch(t){return!1}}function _n(t){return t.exception&&t.exception.values&&t.exception.values[0]}function Sn(t){const e=t.exception;if(e)try{return e.values[0].stacktrace.frames}catch(t){return}else if(t.stacktrace)return t.stacktrace.frames}wn.id="Dedupe";var $n=Object.freeze({__proto__:null,GlobalHandlers:tn,TryCatch:un,Breadcrumbs:dn,LinkedErrors:vn,UserAgent:gn,Dedupe:wn});class kn extends class{constructor(t,e){this.dt={},this.bt=0,this.yt=new t(e),this.W=e,e.dsn&&(this.vt=w(e.dsn))}captureException(t,e,n){if(at(t))return;let r=e&&e.event_id;return this.Ot(this.jt().eventFromException(t,e).then((t=>this.gt(t,e,n))).then((t=>{r=t}))),r}captureMessage(t,e,n,r){let i=n&&n.event_id;const s=h(t)?this.jt().eventFromMessage(String(t),e,n):this.jt().eventFromException(t,n);return this.Ot(s.then((t=>this.gt(t,n,r))).then((t=>{i=t}))),i}captureEvent(t,e,n){if(e&&e.originalException&&at(e.originalException))return;let r=e&&e.event_id;return this.Ot(this.gt(t,e,n).then((t=>{r=t}))),r}captureSession(t){this.wt()&&("string"!=typeof t.release||(this.xt(t),t.update({init:!1})))}getDsn(){return this.vt}getOptions(){return this.W}getTransport(){return this.jt().getTransport()}flush(t){return this.Et(t).then((e=>this.getTransport().close(t).then((t=>e&&t))))}close(t){return this.flush(t).then((t=>(this.getOptions().enabled=!1,t)))}setupIntegrations(){this.wt()&&!this.dt.initialized&&(this.dt=Vt(this.W))}getIntegration(t){try{return this.dt[t.id]||null}catch(t){return null}}_t(t,e){let n=!1,r=!1;const i=e.exception&&e.exception.values;if(i){r=!0;for(const t of i){const e=t.mechanism;if(e&&!1===e.handled){n=!0;break}}}const s="ok"===t.status;(s&&0===t.errors||s&&n)&&(t.update(Object.assign(Object.assign({},n&&{status:"crashed"}),{errors:t.errors||Number(r||n)})),this.captureSession(t))}xt(t){this.jt().sendSession(t)}Et(t){return new bt((e=>{let n=0;const r=setInterval((()=>{0==this.bt?(clearInterval(r),e(!0)):(n+=1,t&&n>=t&&(clearInterval(r),e(!1)))}),1)}))}jt(){return this.yt}wt(){return!1!==this.getOptions().enabled&&void 0!==this.vt}St(t,e,n){const{normalizeDepth:r=3,normalizeMaxBreadth:i=1e3}=this.getOptions(),s=Object.assign(Object.assign({},t),{event_id:t.event_id||(n&&n.event_id?n.event_id:rt()),timestamp:t.timestamp||wt()});this.$t(s),this.kt(s);let o=e;n&&n.captureContext&&(o=Tt.clone(o).update(n.captureContext));let c=dt(s);return o&&(c=o.applyToEvent(s,n)),c.then((t=>(t&&(t.sdkProcessingMetadata=Object.assign(Object.assign({},t.sdkProcessingMetadata),{normalizeDepth:ht(r)})),"number"==typeof r&&r>0?this.Tt(t,r,i):t)))}Tt(t,e,n){if(!t)return null;const r=Object.assign(Object.assign(Object.assign(Object.assign(Object.assign({},t),t.breadcrumbs&&{breadcrumbs:t.breadcrumbs.map((t=>Object.assign(Object.assign({},t),t.data&&{data:ht(t.data,e,n)})))}),t.user&&{user:ht(t.user,e,n)}),t.contexts&&{contexts:ht(t.contexts,e,n)}),t.extra&&{extra:ht(t.extra,e,n)});return t.contexts&&t.contexts.trace&&(r.contexts.trace=t.contexts.trace),r.sdkProcessingMetadata=Object.assign(Object.assign({},r.sdkProcessingMetadata),{baseClientNormalized:!0}),r}$t(t){const e=this.getOptions(),{environment:n,release:r,dist:i,maxValueLength:s=250}=e;"environment"in t||(t.environment="environment"in e?n:"production"),void 0===t.release&&void 0!==r&&(t.release=r),void 0===t.dist&&void 0!==i&&(t.dist=i),t.message&&(t.message=_(t.message,s));const o=t.exception&&t.exception.values&&t.exception.values[0];o&&o.value&&(o.value=_(o.value,s));const c=t.request;c&&c.url&&(c.url=_(c.url,s))}kt(t){const e=Object.keys(this.dt);e.length>0&&(t.sdk=t.sdk||{},t.sdk.integrations=[...t.sdk.integrations||[],...e])}Rt(t){this.jt().sendEvent(t)}gt(t,e,n){return this.Dt(t,e,n).then((t=>t.event_id),(t=>{}))}Dt(t,e,n){const{beforeSend:r,sampleRate:i}=this.getOptions(),s=this.getTransport();function o(t,e){s.recordLostEvent&&s.recordLostEvent(t,e)}if(!this.wt())return pt(new v("SDK not enabled, will not capture event."));const c="transaction"===t.type;return!c&&"number"==typeof i&&Math.random()>i?(o("sample_rate","event"),pt(new v(`Discarding event because it's not included in the random sample (sampling rate = ${i})`))):this.St(t,n,e).then((n=>{if(null===n)throw o("event_processor",t.type||"event"),new v("An event processor returned null, will not send event.");if(e&&e.data&&!0===e.data.__sentry__||c||!r)return n;return function(t){const e="`beforeSend` method has to return `null` or a valid event.";if(d(t))return t.then((t=>{if(!f(t)&&null!==t)throw new v(e);return t}),(t=>{throw new v(`beforeSend rejected with ${t}`)}));if(!f(t)&&null!==t)throw new v(e);return t}(r(n,e))})).then((e=>{if(null===e)throw o("before_send",t.type||"event"),new v("`beforeSend` returned `null`, will not send event.");const r=n&&n.getSession&&n.getSession();return!c&&r&&this._t(r,e),this.Rt(e),e})).then(null,(t=>{if(t instanceof v)throw t;throw this.captureException(t,{data:{__sentry__:!0},originalException:t}),new v(`Event processing pipeline threw an error, original event will not be sent. Details have been sent as a new event.\nReason: ${t}`)}))}Ot(t){this.bt+=1,t.then((t=>(this.bt-=1,t)),(t=>(this.bt-=1,t)))}}{constructor(t={}){t.Z=t.Z||{},t.Z.sdk=t.Z.sdk||{name:"sentry.javascript.browser",packages:[{name:"npm:@sentry/browser",version:re}],version:re},super(We,t)}showReportDialog(t={}){r().document&&this.wt()&&Ze(Object.assign(Object.assign({},t),{dsn:t.dsn||this.getDsn()}))}St(t,e,n){return t.platform=t.platform||"javascript",super.St(t,e,n)}Rt(t){const e=this.getIntegration(dn);e&&e.addSentryBreadcrumb(t),super.Rt(t)}}const Tn=[new ce,new se,new un,new dn,new tn,new vn,new wn,new gn];function Rn(t){t.startSession({ignoreDuration:!0}),t.captureSession()}let Dn={};const Mn=r();Mn.Sentry&&Mn.Sentry.Integrations&&(Dn=Mn.Sentry.Integrations);const Nn=Object.assign(Object.assign(Object.assign({},Dn),he),$n);return t.BrowserClient=kn,t.Hub=qt,t.Integrations=Nn,t.SDK_NAME="sentry.javascript.browser",t.SDK_VERSION=re,t.Scope=Tt,t.Session=Mt,t.Transports=Je,t.addBreadcrumb=function(t){Ft("addBreadcrumb",t)},t.addGlobalEventProcessor=Dt,t.captureEvent=function(t){return Ft("captureEvent",t)},t.captureException=captureException,t.captureMessage=function(t,e){const n=new Error(t),r="string"!=typeof e?{captureContext:e}:void 0;return Ft("captureMessage",t,"string"==typeof e?e:void 0,Object.assign({originalException:t,syntheticException:n},r))},t.close=function(t){const e=Lt().getClient();return e?e.close(t):dt(!1)},t.configureScope=function(t){Ft("configureScope",t)},t.defaultIntegrations=Tn,t.eventFromException=De,t.eventFromMessage=Me,t.flush=function(t){const e=Lt().getClient();return e?e.flush(t):dt(!1)},t.forceLoad=function(){},t.getCurrentHub=Lt,t.getHubFromCarrier=At,t.init=function(t={}){if(void 0===t.defaultIntegrations&&(t.defaultIntegrations=Tn),void 0===t.release){const e=r();e.SENTRY_RELEASE&&e.SENTRY_RELEASE.id&&(t.release=e.SENTRY_RELEASE.id)}void 0===t.autoSessionTracking&&(t.autoSessionTracking=!0),void 0===t.sendClientReports&&(t.sendClientReports=!0),function(t,e){!0===e.debug&&console.warn("[Sentry] Cannot initialize SDK with `debug` option using a non-debug bundle.");const n=Lt(),r=n.getScope();r&&r.update(e.initialScope);const i=new t(e);n.bindClient(i)}(kn,t),t.autoSessionTracking&&function(){const t=r();if(void 0===t.document)return;const e=Lt();if(!e.captureSession)return;Rn(e),W("history",(({from:t,to:e})=>{void 0!==t&&t!==e&&Rn(Lt())}))}()},t.injectReportDialog=Ze,t.lastEventId=function(){return Lt().lastEventId()},t.makeMain=Ct,t.onLoad=function(t){t()},t.setContext=function(t,e){Ft("setContext",t,e)},t.setExtra=function(t,e){Ft("setExtra",t,e)},t.setExtras=function(t){Ft("setExtras",t)},t.setTag=function(t,e){Ft("setTag",t,e)},t.setTags=function(t){Ft("setTags",t)},t.setUser=function(t){Ft("setUser",t)},t.showReportDialog=function(t={}){const e=Lt(),n=e.getScope();n&&(t.user=Object.assign(Object.assign({},n.getUser()),t.user)),t.eventId||(t.eventId=e.lastEventId());const r=e.getClient();r&&r.showReportDialog(t)},t.startTransaction=function(t,e){return Ft("startTransaction",Object.assign({},t),e)},t.withScope=Pt,t.wrap=function(t){return Ye(t)()},t}({});
|
|
1
|
+
/*! @sentry/browser 6.19.4 (261f2e4) | https://github.com/getsentry/sentry-javascript */
|
|
2
|
+
var Sentry=function(t){var e;t.Severity=void 0,(e=t.Severity||(t.Severity={})).Fatal="fatal",e.Error="error",e.Warning="warning",e.Log="log",e.Info="info",e.Debug="debug",e.Critical="critical";const n={};function r(){return"undefined"!=typeof window?window:"undefined"!=typeof self?self:n}const i=Object.prototype.toString;function s(t){switch(i.call(t)){case"[object Error]":case"[object Exception]":case"[object DOMException]":return!0;default:return p(t,Error)}}function o(t,e){return i.call(t)===`[object ${e}]`}function c(t){return o(t,"ErrorEvent")}function u(t){return o(t,"DOMError")}function a(t){return o(t,"String")}function h(t){return null===t||"object"!=typeof t&&"function"!=typeof t}function f(t){return o(t,"Object")}function l(t){return"undefined"!=typeof Event&&p(t,Event)}function d(t){return Boolean(t&&t.then&&"function"==typeof t.then)}function p(t,e){try{return t instanceof e}catch(t){return!1}}function b(t,e){try{let n=t;const r=5,i=80,s=[];let o=0,c=0;const u=" > ",a=u.length;let h;for(;n&&o++<r&&(h=y(n,e),!("html"===h||o>1&&c+s.length*a+h.length>=i));)s.push(h),c+=h.length,n=n.parentNode;return s.reverse().join(u)}catch(t){return"<unknown>"}}function y(t,e){const n=t,r=[];let i,s,o,c,u;if(!n||!n.tagName)return"";r.push(n.tagName.toLowerCase());const h=e&&e.length?e.filter((t=>n.getAttribute(t))).map((t=>[t,n.getAttribute(t)])):null;if(h&&h.length)h.forEach((t=>{r.push(`[${t[0]}="${t[1]}"]`)}));else if(n.id&&r.push(`#${n.id}`),i=n.className,i&&a(i))for(s=i.split(/\s+/),u=0;u<s.length;u++)r.push(`.${s[u]}`);const f=["type","name","title","alt"];for(u=0;u<f.length;u++)o=f[u],c=n.getAttribute(o),c&&r.push(`[${o}="${c}"]`);return r.join("")}const m=Object.setPrototypeOf||({__proto__:[]}instanceof Array?function(t,e){return t.__proto__=e,t}:function(t,e){for(const n in e)Object.prototype.hasOwnProperty.call(t,n)||(t[n]=e[n]);return t});class v extends Error{constructor(t){super(t),this.message=t,this.name=new.target.prototype.constructor.name,m(this,new.target.prototype)}}const O=/^(?:(\w+):)\/\/(?:(\w+)(?::(\w+))?@)([\w.-]+)(?::(\d+))?\/(.+)/;function j(t,e=!1){const{host:n,path:r,pass:i,port:s,projectId:o,protocol:c,publicKey:u}=t;return`${c}://${u}${e&&i?`:${i}`:""}@${n}${s?`:${s}`:""}/${r?`${r}/`:r}${o}`}function g(t){return"user"in t&&!("publicKey"in t)&&(t.publicKey=t.user),{user:t.publicKey||"",protocol:t.protocol,publicKey:t.publicKey||"",pass:t.pass||"",host:t.host,port:t.port||"",path:t.path||"",projectId:t.projectId}}function w(t){return"string"==typeof t?function(t){const e=O.exec(t);if(!e)throw new v(`Invalid Sentry Dsn: ${t}`);const[n,r,i="",s,o="",c]=e.slice(1);let u="",a=c;const h=a.split("/");if(h.length>1&&(u=h.slice(0,-1).join("/"),a=h.pop()),a){const t=a.match(/^\d+/);t&&(a=t[0])}return g({host:s,pass:i,path:u,projectId:a,port:o,protocol:n,publicKey:r})}(t):g(t)}const x=["fatal","error","warning","log","info","debug","critical"];r();const E=["debug","info","warn","error","log","assert"];function _(t,e=0){return"string"!=typeof t||0===e||t.length<=e?t:`${t.substr(0,e)}...`}function S(t,e){if(!Array.isArray(t))return"";const n=[];for(let e=0;e<t.length;e++){const r=t[e];try{n.push(String(r))}catch(t){n.push("[value cannot be serialized]")}}return n.join(e)}function $(t,e){return!!a(t)&&(o(e,"RegExp")?e.test(t):"string"==typeof e&&-1!==t.indexOf(e))}function k(t,e,n){if(!(e in t))return;const r=t[e],i=n(r);if("function"==typeof i)try{R(i,r)}catch(t){}t[e]=i}function T(t,e,n){Object.defineProperty(t,e,{value:n,writable:!0,configurable:!0})}function R(t,e){const n=e.prototype||{};t.prototype=e.prototype=n,T(t,"__sentry_original__",e)}function D(t){return t.__sentry_original__}function M(t){let e=t;if(s(t))e=Object.assign({message:t.message,name:t.name,stack:t.stack},q(t));else if(l(t)){const n=t;e=Object.assign({type:n.type,target:N(n.target),currentTarget:N(n.currentTarget)},q(n)),"undefined"!=typeof CustomEvent&&p(t,CustomEvent)&&(e.detail=n.detail)}return e}function N(t){try{return e=t,"undefined"!=typeof Element&&p(e,Element)?b(t):Object.prototype.toString.call(t)}catch(t){return"<unknown>"}var e}function q(t){const e={};for(const n in t)Object.prototype.hasOwnProperty.call(t,n)&&(e[n]=t[n]);return e}function I(t,e=40){const n=Object.keys(M(t));if(n.sort(),!n.length)return"[object has no keys]";if(n[0].length>=e)return _(n[0],e);for(let t=n.length;t>0;t--){const r=n.slice(0,t).join(", ");if(!(r.length>e))return t===n.length?r:_(r,e)}return""}function C(t){if(f(t)){const e={};for(const n of Object.keys(t))void 0!==t[n]&&(e[n]=C(t[n]));return e}return Array.isArray(t)?t.map(C):t}function L(...t){const e=t.sort(((t,e)=>t[0]-e[0])).map((t=>t[1]));return(t,n=0)=>{const r=[];for(const i of t.split("\n").slice(n))for(const t of e){const e=t(i);if(e){r.push(e);break}}return function(t){if(!t.length)return[];let e=t;const n=e[0].function||"",r=e[e.length-1].function||"";-1===n.indexOf("captureMessage")&&-1===n.indexOf("captureException")||(e=e.slice(1));-1!==r.indexOf("sentryWrapped")&&(e=e.slice(0,-1));return e.slice(0,50).map((t=>Object.assign(Object.assign({},t),{filename:t.filename||e[0].filename,function:t.function||"?"}))).reverse()}(r)}}const A="<anonymous>";function U(t){try{return t&&"function"==typeof t&&t.name||A}catch(t){return A}}function F(){if(!("fetch"in r()))return!1;try{return new Headers,new Request(""),new Response,!0}catch(t){return!1}}function P(t){return t&&/^function fetch\(\)\s+\{\s+\[native code\]\s+\}$/.test(t.toString())}function B(){if(!F())return!1;try{return new Request("_",{referrerPolicy:"origin"}),!0}catch(t){return!1}}const H=r(),X={},z={};function J(t){if(!z[t])switch(z[t]=!0,t){case"console":!function(){if(!("console"in H))return;E.forEach((function(t){t in H.console&&k(H.console,t,(function(e){return function(...n){K("console",{args:n,level:t}),e&&e.apply(H.console,n)}}))}))}();break;case"dom":!function(){if(!("document"in H))return;const t=K.bind(null,"dom"),e=tt(t,!0);H.document.addEventListener("click",e,!1),H.document.addEventListener("keypress",e,!1),["EventTarget","Node"].forEach((e=>{const n=H[e]&&H[e].prototype;n&&n.hasOwnProperty&&n.hasOwnProperty("addEventListener")&&(k(n,"addEventListener",(function(e){return function(n,r,i){if("click"===n||"keypress"==n)try{const r=this,s=r.__sentry_instrumentation_handlers__=r.__sentry_instrumentation_handlers__||{},o=s[n]=s[n]||{refCount:0};if(!o.handler){const r=tt(t);o.handler=r,e.call(this,n,r,i)}o.refCount+=1}catch(t){}return e.call(this,n,r,i)}})),k(n,"removeEventListener",(function(t){return function(e,n,r){if("click"===e||"keypress"==e)try{const n=this,i=n.__sentry_instrumentation_handlers__||{},s=i[e];s&&(s.refCount-=1,s.refCount<=0&&(t.call(this,e,s.handler,r),s.handler=void 0,delete i[e]),0===Object.keys(i).length&&delete n.__sentry_instrumentation_handlers__)}catch(t){}return t.call(this,e,n,r)}})))}))}();break;case"xhr":!function(){if(!("XMLHttpRequest"in H))return;const t=XMLHttpRequest.prototype;k(t,"open",(function(t){return function(...e){const n=this,r=e[1],i=n.__sentry_xhr__={method:a(e[0])?e[0].toUpperCase():e[0],url:e[1]};a(r)&&"POST"===i.method&&r.match(/sentry_key/)&&(n.__sentry_own_request__=!0);const s=function(){if(4===n.readyState){try{i.status_code=n.status}catch(t){}K("xhr",{args:e,endTimestamp:Date.now(),startTimestamp:Date.now(),xhr:n})}};return"onreadystatechange"in n&&"function"==typeof n.onreadystatechange?k(n,"onreadystatechange",(function(t){return function(...e){return s(),t.apply(n,e)}})):n.addEventListener("readystatechange",s),t.apply(n,e)}})),k(t,"send",(function(t){return function(...e){return this.__sentry_xhr__&&void 0!==e[0]&&(this.__sentry_xhr__.body=e[0]),K("xhr",{args:e,startTimestamp:Date.now(),xhr:this}),t.apply(this,e)}}))}();break;case"fetch":!function(){if(!function(){if(!F())return!1;const t=r();if(P(t.fetch))return!0;let e=!1;const n=t.document;if(n&&"function"==typeof n.createElement)try{const t=n.createElement("iframe");t.hidden=!0,n.head.appendChild(t),t.contentWindow&&t.contentWindow.fetch&&(e=P(t.contentWindow.fetch)),n.head.removeChild(t)}catch(t){}return e}())return;k(H,"fetch",(function(t){return function(...e){const n={args:e,fetchData:{method:G(e),url:V(e)},startTimestamp:Date.now()};return K("fetch",Object.assign({},n)),t.apply(H,e).then((t=>(K("fetch",Object.assign(Object.assign({},n),{endTimestamp:Date.now(),response:t})),t)),(t=>{throw K("fetch",Object.assign(Object.assign({},n),{endTimestamp:Date.now(),error:t})),t}))}}))}();break;case"history":!function(){if(!function(){const t=r(),e=t.chrome,n=e&&e.app&&e.app.runtime,i="history"in t&&!!t.history.pushState&&!!t.history.replaceState;return!n&&i}())return;const t=H.onpopstate;function e(t){return function(...e){const n=e.length>2?e[2]:void 0;if(n){const t=Q,e=String(n);Q=e,K("history",{from:t,to:e})}return t.apply(this,e)}}H.onpopstate=function(...e){const n=H.location.href,r=Q;if(Q=n,K("history",{from:r,to:n}),t)try{return t.apply(this,e)}catch(t){}},k(H.history,"pushState",e),k(H.history,"replaceState",e)}();break;case"error":et=H.onerror,H.onerror=function(t,e,n,r,i){return K("error",{column:r,error:i,line:n,msg:t,url:e}),!!et&&et.apply(this,arguments)};break;case"unhandledrejection":nt=H.onunhandledrejection,H.onunhandledrejection=function(t){return K("unhandledrejection",t),!nt||nt.apply(this,arguments)};break;default:return}}function W(t,e){X[t]=X[t]||[],X[t].push(e),J(t)}function K(t,e){if(t&&X[t])for(const n of X[t]||[])try{n(e)}catch(t){}}function G(t=[]){return"Request"in H&&p(t[0],Request)&&t[0].method?String(t[0].method).toUpperCase():t[1]&&t[1].method?String(t[1].method).toUpperCase():"GET"}function V(t=[]){return"string"==typeof t[0]?t[0]:"Request"in H&&p(t[0],Request)?t[0].url:String(t[0])}let Q;let Y,Z;function tt(t,e=!1){return n=>{if(!n||Z===n)return;if(function(t){if("keypress"!==t.type)return!1;try{const e=t.target;if(!e||!e.tagName)return!0;if("INPUT"===e.tagName||"TEXTAREA"===e.tagName||e.isContentEditable)return!1}catch(t){}return!0}(n))return;const r="keypress"===n.type?"input":n.type;(void 0===Y||function(t,e){if(!t)return!0;if(t.type!==e.type)return!0;try{if(t.target!==e.target)return!0}catch(t){}return!1}(Z,n))&&(t({event:n,name:r,global:e}),Z=n),clearTimeout(Y),Y=H.setTimeout((()=>{Y=void 0}),1e3)}}let et=null;let nt=null;function rt(){const t=r(),e=t.crypto||t.msCrypto;if(void 0!==e&&e.getRandomValues){const t=new Uint16Array(8);e.getRandomValues(t),t[3]=4095&t[3]|16384,t[4]=16383&t[4]|32768;const n=t=>{let e=t.toString(16);for(;e.length<4;)e=`0${e}`;return e};return n(t[0])+n(t[1])+n(t[2])+n(t[3])+n(t[4])+n(t[5])+n(t[6])+n(t[7])}return"xxxxxxxxxxxx4xxxyxxxxxxxxxxxxxxx".replace(/[xy]/g,(t=>{const e=16*Math.random()|0;return("x"===t?e:3&e|8).toString(16)}))}function it(t){if(!t)return{};const e=t.match(/^(([^:/?#]+):)?(\/\/([^/?#]*))?([^?#]*)(\?([^#]*))?(#(.*))?$/);if(!e)return{};const n=e[6]||"",r=e[8]||"";return{host:e[4],path:e[5],protocol:e[2],relative:e[5]+n+r}}function st(t){return t.exception&&t.exception.values?t.exception.values[0]:void 0}function ot(t){const{message:e,event_id:n}=t;if(e)return e;const r=st(t);return r?r.type&&r.value?`${r.type}: ${r.value}`:r.type||r.value||n||"<unknown>":n||"<unknown>"}function ct(t,e,n){const r=t.exception=t.exception||{},i=r.values=r.values||[],s=i[0]=i[0]||{};s.value||(s.value=e||""),s.type||(s.type=n||"Error")}function ut(t,e){const n=st(t);if(!n)return;const r=n.mechanism;if(n.mechanism=Object.assign(Object.assign(Object.assign({},{type:"generic",handled:!0}),r),e),e&&"data"in e){const t=Object.assign(Object.assign({},r&&r.data),e.data);n.mechanism.data=t}}function at(t){if(t&&t.__sentry_captured__)return!0;try{T(t,"__sentry_captured__",!0)}catch(t){}return!1}function ht(t,e=1/0,n=1/0){try{return lt("",t,e,n)}catch(t){return{ERROR:`**non-serializable** (${t})`}}}function ft(t,e=3,n=102400){const r=ht(t,e);return i=r,function(t){return~-encodeURI(t).split(/%..|./).length}(JSON.stringify(i))>n?ft(t,e-1,n):r;var i}function lt(t,e,n=1/0,r=1/0,i=function(){const t="function"==typeof WeakSet,e=t?new WeakSet:[];return[function(n){if(t)return!!e.has(n)||(e.add(n),!1);for(let t=0;t<e.length;t++)if(e[t]===n)return!0;return e.push(n),!1},function(n){if(t)e.delete(n);else for(let t=0;t<e.length;t++)if(e[t]===n){e.splice(t,1);break}}]}()){const[o,c]=i,u=e;if(u&&"function"==typeof u.toJSON)try{return u.toJSON()}catch(t){}if(null===e||["number","boolean","string"].includes(typeof e)&&("number"!=typeof(a=e)||a==a))return e;var a;const h=function(t,e){try{return"domain"===t&&e&&"object"==typeof e&&e.t?"[Domain]":"domainEmitter"===t?"[DomainEmitter]":"undefined"!=typeof global&&e===global?"[Global]":"undefined"!=typeof window&&e===window?"[Window]":"undefined"!=typeof document&&e===document?"[Document]":function(t){return f(t)&&"nativeEvent"in t&&"preventDefault"in t&&"stopPropagation"in t}(e)?"[SyntheticEvent]":"number"==typeof e&&e!=e?"[NaN]":void 0===e?"[undefined]":"function"==typeof e?`[Function: ${U(e)}]`:"symbol"==typeof e?`[${String(e)}]`:"bigint"==typeof e?`[BigInt: ${String(e)}]`:`[object ${Object.getPrototypeOf(e).constructor.name}]`}catch(t){return`**non-serializable** (${t})`}}(t,e);if(!h.startsWith("[object "))return h;if(0===n)return h.replace("object ","");if(o(e))return"[Circular ~]";const d=Array.isArray(e)?[]:{};let p=0;const b=s(e)||l(e)?M(e):e;for(const t in b){if(!Object.prototype.hasOwnProperty.call(b,t))continue;if(p>=r){d[t]="[MaxProperties ~]";break}const e=b[t];d[t]=lt(t,e,n-1,r,i),p+=1}return c(e),d}function dt(t){return new bt((e=>{e(t)}))}function pt(t){return new bt(((e,n)=>{n(t)}))}class bt{constructor(t){this.i=0,this.o=[],this.u=t=>{this.h(1,t)},this.l=t=>{this.h(2,t)},this.h=(t,e)=>{0===this.i&&(d(e)?e.then(this.u,this.l):(this.i=t,this.p=e,this.m()))},this.m=()=>{if(0===this.i)return;const t=this.o.slice();this.o=[],t.forEach((t=>{t[0]||(1===this.i&&t[1](this.p),2===this.i&&t[2](this.p),t[0]=!0)}))};try{t(this.u,this.l)}catch(t){this.l(t)}}then(t,e){return new bt(((n,r)=>{this.o.push([!1,e=>{if(t)try{n(t(e))}catch(t){r(t)}else n(e)},t=>{if(e)try{n(e(t))}catch(t){r(t)}else r(t)}]),this.m()}))}catch(t){return this.then((t=>t),t)}finally(t){return new bt(((e,n)=>{let r,i;return this.then((e=>{i=!1,r=e,t&&t()}),(e=>{i=!0,r=e,t&&t()})).then((()=>{i?n(r):e(r)}))}))}}function yt(t){const e=[];function n(t){return e.splice(e.indexOf(t),1)[0]}return{$:e,add:function(r){if(!(void 0===t||e.length<t))return pt(new v("Not adding Promise due to buffer limit reached."));const i=r();return-1===e.indexOf(i)&&e.push(i),i.then((()=>n(i))).then(null,(()=>n(i).then(null,(()=>{})))),i},drain:function(t){return new bt(((n,r)=>{let i=e.length;if(!i)return n(!0);const s=setTimeout((()=>{t&&t>0&&n(!1)}),t);e.forEach((t=>{dt(t).then((()=>{--i||(clearTimeout(s),n(!0))}),r)}))}))}}}function mt(e){return"warn"===e?t.Severity.Warning:function(t){return-1!==x.indexOf(t)}(e)?e:t.Severity.Log}function vt(t){return t>=200&&t<300?"success":429===t?"rate_limit":t>=400&&t<500?"invalid":t>=500?"failed":"unknown"}const Ot={nowSeconds:()=>Date.now()/1e3};const jt=function(){const{performance:t}=r();if(!t||!t.now)return;return{now:()=>t.now(),timeOrigin:Date.now()-t.now()}}(),gt=void 0===jt?Ot:{nowSeconds:()=>(jt.timeOrigin+jt.now())/1e3},wt=Ot.nowSeconds.bind(Ot),xt=gt.nowSeconds.bind(gt);function Et(t,e=[]){return[t,e]}function _t(t){const[e,n]=t,r=JSON.stringify(e);return n.reduce(((t,e)=>{const[n,r]=e,i=h(r)?String(r):JSON.stringify(r);return`${t}\n${JSON.stringify(n)}\n${i}`}),r)}(()=>{const{performance:t}=r();if(!t||!t.now)return;const e=36e5,n=t.now(),i=Date.now(),s=t.timeOrigin?Math.abs(t.timeOrigin+n-i):e,o=s<e,c=t.timing&&t.timing.navigationStart,u="number"==typeof c?Math.abs(c+n-i):e;(o||u<e)&&(s<=u&&t.timeOrigin)})();function St(t,e){return t[e]||t.all||0}function $t(t,e,n=Date.now()){return St(t,e)>n}function kt(t,e,n=Date.now()){const r=Object.assign({},t),i=e["x-sentry-rate-limits"],s=e["retry-after"];if(i)for(const t of i.trim().split(",")){const e=t.split(":",2),i=parseInt(e[0],10),s=1e3*(isNaN(i)?60:i);if(e[1])for(const t of e[1].split(";"))r[t]=n+s;else r.all=n+s}else s&&(r.all=n+function(t,e=Date.now()){const n=parseInt(`${t}`,10);if(!isNaN(n))return 1e3*n;const r=Date.parse(`${t}`);return isNaN(r)?6e4:r-e}(s,n));return r}class Tt{constructor(){this.v=!1,this.O=[],this.j=[],this.g=[],this._={},this.S={},this.k={},this.T={},this.R={}}static clone(t){const e=new Tt;return t&&(e.g=[...t.g],e.S=Object.assign({},t.S),e.k=Object.assign({},t.k),e.T=Object.assign({},t.T),e._=t._,e.D=t.D,e.M=t.M,e.N=t.N,e.q=t.q,e.I=t.I,e.j=[...t.j],e.C=t.C),e}addScopeListener(t){this.O.push(t)}addEventProcessor(t){return this.j.push(t),this}setUser(t){return this._=t||{},this.N&&this.N.update({user:t}),this.L(),this}getUser(){return this._}getRequestSession(){return this.C}setRequestSession(t){return this.C=t,this}setTags(t){return this.S=Object.assign(Object.assign({},this.S),t),this.L(),this}setTag(t,e){return this.S=Object.assign(Object.assign({},this.S),{[t]:e}),this.L(),this}setExtras(t){return this.k=Object.assign(Object.assign({},this.k),t),this.L(),this}setExtra(t,e){return this.k=Object.assign(Object.assign({},this.k),{[t]:e}),this.L(),this}setFingerprint(t){return this.I=t,this.L(),this}setLevel(t){return this.D=t,this.L(),this}setTransactionName(t){return this.q=t,this.L(),this}setTransaction(t){return this.setTransactionName(t)}setContext(t,e){return null===e?delete this.T[t]:this.T=Object.assign(Object.assign({},this.T),{[t]:e}),this.L(),this}setSpan(t){return this.M=t,this.L(),this}getSpan(){return this.M}getTransaction(){const t=this.getSpan();return t&&t.transaction}setSession(t){return t?this.N=t:delete this.N,this.L(),this}getSession(){return this.N}update(t){if(!t)return this;if("function"==typeof t){const e=t(this);return e instanceof Tt?e:this}return t instanceof Tt?(this.S=Object.assign(Object.assign({},this.S),t.S),this.k=Object.assign(Object.assign({},this.k),t.k),this.T=Object.assign(Object.assign({},this.T),t.T),t._&&Object.keys(t._).length&&(this._=t._),t.D&&(this.D=t.D),t.I&&(this.I=t.I),t.C&&(this.C=t.C)):f(t)&&(t=t,this.S=Object.assign(Object.assign({},this.S),t.tags),this.k=Object.assign(Object.assign({},this.k),t.extra),this.T=Object.assign(Object.assign({},this.T),t.contexts),t.user&&(this._=t.user),t.level&&(this.D=t.level),t.fingerprint&&(this.I=t.fingerprint),t.requestSession&&(this.C=t.requestSession)),this}clear(){return this.g=[],this.S={},this.k={},this._={},this.T={},this.D=void 0,this.q=void 0,this.I=void 0,this.C=void 0,this.M=void 0,this.N=void 0,this.L(),this}addBreadcrumb(t,e){const n="number"==typeof e?Math.min(e,100):100;if(n<=0)return this;const r=Object.assign({timestamp:wt()},t);return this.g=[...this.g,r].slice(-n),this.L(),this}clearBreadcrumbs(){return this.g=[],this.L(),this}applyToEvent(t,e){if(this.k&&Object.keys(this.k).length&&(t.extra=Object.assign(Object.assign({},this.k),t.extra)),this.S&&Object.keys(this.S).length&&(t.tags=Object.assign(Object.assign({},this.S),t.tags)),this._&&Object.keys(this._).length&&(t.user=Object.assign(Object.assign({},this._),t.user)),this.T&&Object.keys(this.T).length&&(t.contexts=Object.assign(Object.assign({},this.T),t.contexts)),this.D&&(t.level=this.D),this.q&&(t.transaction=this.q),this.M){t.contexts=Object.assign({trace:this.M.getTraceContext()},t.contexts);const e=this.M.transaction&&this.M.transaction.name;e&&(t.tags=Object.assign({transaction:e},t.tags))}return this.A(t),t.breadcrumbs=[...t.breadcrumbs||[],...this.g],t.breadcrumbs=t.breadcrumbs.length>0?t.breadcrumbs:void 0,t.sdkProcessingMetadata=this.R,this.U([...Rt(),...this.j],t,e)}setSDKProcessingMetadata(t){return this.R=Object.assign(Object.assign({},this.R),t),this}U(t,e,n,r=0){return new bt(((i,s)=>{const o=t[r];if(null===e||"function"!=typeof o)i(e);else{const c=o(Object.assign({},e),n);d(c)?c.then((e=>this.U(t,e,n,r+1).then(i))).then(null,s):this.U(t,c,n,r+1).then(i).then(null,s)}}))}L(){this.v||(this.v=!0,this.O.forEach((t=>{t(this)})),this.v=!1)}A(t){t.fingerprint=t.fingerprint?Array.isArray(t.fingerprint)?t.fingerprint:[t.fingerprint]:[],this.I&&(t.fingerprint=t.fingerprint.concat(this.I)),t.fingerprint&&!t.fingerprint.length&&delete t.fingerprint}}function Rt(){const t=r();return t.__SENTRY__=t.__SENTRY__||{},t.__SENTRY__.globalEventProcessors=t.__SENTRY__.globalEventProcessors||[],t.__SENTRY__.globalEventProcessors}function Dt(t){Rt().push(t)}class Mt{constructor(t){this.errors=0,this.sid=rt(),this.duration=0,this.status="ok",this.init=!0,this.ignoreDuration=!1;const e=xt();this.timestamp=e,this.started=e,t&&this.update(t)}update(t={}){if(t.user&&(!this.ipAddress&&t.user.ip_address&&(this.ipAddress=t.user.ip_address),this.did||t.did||(this.did=t.user.id||t.user.email||t.user.username)),this.timestamp=t.timestamp||xt(),t.ignoreDuration&&(this.ignoreDuration=t.ignoreDuration),t.sid&&(this.sid=32===t.sid.length?t.sid:rt()),void 0!==t.init&&(this.init=t.init),!this.did&&t.did&&(this.did=`${t.did}`),"number"==typeof t.started&&(this.started=t.started),this.ignoreDuration)this.duration=void 0;else if("number"==typeof t.duration)this.duration=t.duration;else{const t=this.timestamp-this.started;this.duration=t>=0?t:0}t.release&&(this.release=t.release),t.environment&&(this.environment=t.environment),!this.ipAddress&&t.ipAddress&&(this.ipAddress=t.ipAddress),!this.userAgent&&t.userAgent&&(this.userAgent=t.userAgent),"number"==typeof t.errors&&(this.errors=t.errors),t.status&&(this.status=t.status)}close(t){t?this.update({status:t}):"ok"===this.status?this.update({status:"exited"}):this.update()}toJSON(){return C({sid:`${this.sid}`,init:this.init,started:new Date(1e3*this.started).toISOString(),timestamp:new Date(1e3*this.timestamp).toISOString(),status:this.status,errors:this.errors,did:"number"==typeof this.did||"string"==typeof this.did?`${this.did}`:void 0,duration:this.duration,attrs:{release:this.release,environment:this.environment,ip_address:this.ipAddress,user_agent:this.userAgent}})}}const Nt=100;class qt{constructor(t,e=new Tt,n=4){this.F=n,this.P=[{}],this.getStackTop().scope=e,t&&this.bindClient(t)}isOlderThan(t){return this.F<t}bindClient(t){this.getStackTop().client=t,t&&t.setupIntegrations&&t.setupIntegrations()}pushScope(){const t=Tt.clone(this.getScope());return this.getStack().push({client:this.getClient(),scope:t}),t}popScope(){return!(this.getStack().length<=1)&&!!this.getStack().pop()}withScope(t){const e=this.pushScope();try{t(e)}finally{this.popScope()}}getClient(){return this.getStackTop().client}getScope(){return this.getStackTop().scope}getStack(){return this.P}getStackTop(){return this.P[this.P.length-1]}captureException(t,e){const n=this.B=e&&e.event_id?e.event_id:rt();let r=e;if(!e){let e;try{throw new Error("Sentry syntheticException")}catch(t){e=t}r={originalException:t,syntheticException:e}}return this.H("captureException",t,Object.assign(Object.assign({},r),{event_id:n})),n}captureMessage(t,e,n){const r=this.B=n&&n.event_id?n.event_id:rt();let i=n;if(!n){let e;try{throw new Error(t)}catch(t){e=t}i={originalException:t,syntheticException:e}}return this.H("captureMessage",t,e,Object.assign(Object.assign({},i),{event_id:r})),r}captureEvent(t,e){const n=e&&e.event_id?e.event_id:rt();return"transaction"!==t.type&&(this.B=n),this.H("captureEvent",t,Object.assign(Object.assign({},e),{event_id:n})),n}lastEventId(){return this.B}addBreadcrumb(t,e){const{scope:n,client:i}=this.getStackTop();if(!n||!i)return;const{beforeBreadcrumb:s=null,maxBreadcrumbs:o=Nt}=i.getOptions&&i.getOptions()||{};if(o<=0)return;const c=wt(),u=Object.assign({timestamp:c},t),a=s?function(t){const e=r();if(!("console"in e))return t();const n=e.console,i={};E.forEach((t=>{t in e.console&&n[t].__sentry_original__&&(i[t]=n[t],n[t]=n[t].__sentry_original__)}));const s=t();return Object.keys(i).forEach((t=>{n[t]=i[t]})),s}((()=>s(u,e))):u;null!==a&&n.addBreadcrumb(a,o)}setUser(t){const e=this.getScope();e&&e.setUser(t)}setTags(t){const e=this.getScope();e&&e.setTags(t)}setExtras(t){const e=this.getScope();e&&e.setExtras(t)}setTag(t,e){const n=this.getScope();n&&n.setTag(t,e)}setExtra(t,e){const n=this.getScope();n&&n.setExtra(t,e)}setContext(t,e){const n=this.getScope();n&&n.setContext(t,e)}configureScope(t){const{scope:e,client:n}=this.getStackTop();e&&n&&t(e)}run(t){const e=Ct(this);try{t(this)}finally{Ct(e)}}getIntegration(t){const e=this.getClient();if(!e)return null;try{return e.getIntegration(t)}catch(t){return null}}startSpan(t){return this.X("startSpan",t)}startTransaction(t,e){return this.X("startTransaction",t,e)}traceHeaders(){return this.X("traceHeaders")}captureSession(t=!1){if(t)return this.endSession();this.J()}endSession(){const t=this.getStackTop(),e=t&&t.scope,n=e&&e.getSession();n&&n.close(),this.J(),e&&e.setSession()}startSession(t){const{scope:e,client:n}=this.getStackTop(),{release:i,environment:s}=n&&n.getOptions()||{},o=r(),{userAgent:c}=o.navigator||{},u=new Mt(Object.assign(Object.assign(Object.assign({release:i,environment:s},e&&{user:e.getUser()}),c&&{userAgent:c}),t));if(e){const t=e.getSession&&e.getSession();t&&"ok"===t.status&&t.update({status:"exited"}),this.endSession(),e.setSession(u)}return u}J(){const{scope:t,client:e}=this.getStackTop();if(!t)return;const n=t.getSession&&t.getSession();n&&e&&e.captureSession&&e.captureSession(n)}H(t,...e){const{scope:n,client:r}=this.getStackTop();r&&r[t]&&r[t](...e,n)}X(t,...e){const n=It().__SENTRY__;if(n&&n.extensions&&"function"==typeof n.extensions[t])return n.extensions[t].apply(this,e)}}function It(){const t=r();return t.__SENTRY__=t.__SENTRY__||{extensions:{},hub:void 0},t}function Ct(t){const e=It(),n=At(e);return Ut(e,t),n}function Lt(){const t=It();var e;return(e=t)&&e.__SENTRY__&&e.__SENTRY__.hub&&!At(t).isOlderThan(4)||Ut(t,new qt),At(t)}function At(t){return t&&t.__SENTRY__&&t.__SENTRY__.hub||(t.__SENTRY__=t.__SENTRY__||{},t.__SENTRY__.hub=new qt),t.__SENTRY__.hub}function Ut(t,e){return!!t&&(t.__SENTRY__=t.__SENTRY__||{},t.__SENTRY__.hub=e,!0)}function Ft(t,...e){const n=Lt();if(n&&n[t])return n[t](...e);throw new Error(`No hub defined or ${t} was not found on the hub, please open a bug report.`)}function captureException(t,e){return Ft("captureException",t,{captureContext:e,originalException:t,syntheticException:new Error("Sentry syntheticException")})}function Pt(t){Ft("withScope",t)}function Bt(t,e,n){return{initDsn:t,metadata:e||{},dsn:w(t),tunnel:n}}function Ht(t){const e=t.protocol?`${t.protocol}:`:"",n=t.port?`:${t.port}`:"";return`${e}//${t.host}${n}${t.path?`/${t.path}`:""}/api/`}function Xt(t,e){return`${Ht(t)}${t.projectId}/${e}/`}function zt(t){return e={sentry_key:t.publicKey,sentry_version:"7"},Object.keys(e).map((t=>`${encodeURIComponent(t)}=${encodeURIComponent(e[t])}`)).join("&");var e}function Jt(t){return`${function(t){return Xt(t,"store")}(t)}?${zt(t)}`}function Wt(t,e){return e||`${function(t){return Xt(t,"envelope")}(t)}?${zt(t)}`}const Kt=[];function Gt(t){return t.reduce(((t,e)=>(t.every((t=>e.name!==t.name))&&t.push(e),t)),[])}function Vt(t){const e={};return function(t){const e=t.defaultIntegrations&&[...t.defaultIntegrations]||[],n=t.integrations;let r=[...Gt(e)];Array.isArray(n)?r=[...r.filter((t=>n.every((e=>e.name!==t.name)))),...Gt(n)]:"function"==typeof n&&(r=n(r),r=Array.isArray(r)?r:[r]);const i=r.map((t=>t.name)),s="Debug";return-1!==i.indexOf(s)&&r.push(...r.splice(i.indexOf(s),1)),r}(t).forEach((t=>{e[t.name]=t,function(t){-1===Kt.indexOf(t.name)&&(t.setupOnce(Dt,Lt),Kt.push(t.name))}(t)})),T(e,"initialized",!0),e}function Qt(t){if(!t.metadata||!t.metadata.sdk)return;const{name:e,version:n}=t.metadata.sdk;return{name:e,version:n}}function Yt(t,e){return e?(t.sdk=t.sdk||{},t.sdk.name=t.sdk.name||e.name,t.sdk.version=t.sdk.version||e.version,t.sdk.integrations=[...t.sdk.integrations||[],...e.integrations||[]],t.sdk.packages=[...t.sdk.packages||[],...e.packages||[]],t):t}function Zt(t,e){const n=Qt(e),r="aggregates"in t?"sessions":"session";return[Et(Object.assign(Object.assign({sent_at:(new Date).toISOString()},n&&{sdk:n}),!!e.tunnel&&{dsn:j(e.dsn)}),[[{type:r},t]]),r]}class te{sendEvent(t){return dt({reason:"NoopTransport: Event has been skipped because no Dsn is configured.",status:"skipped"})}close(t){return dt(!0)}}function ee(t,e,n=yt(t.bufferSize||30)){let r={};return{send:function(t){const i=function(t){const[,[[e]]]=t;return e.type}(t),s="event"===i?"error":i,o={category:s,body:_t(t)};return $t(r,s)?pt({status:"rate_limit",reason:ne(r,s)}):n.add((()=>e(o).then((({body:t,headers:e,reason:n,statusCode:i})=>{const o=vt(i);return e&&(r=kt(r,e)),"success"===o?dt({status:o,reason:n}):pt({status:o,reason:n||t||("rate_limit"===o?ne(r,s):"Unknown transport error")})}))))},flush:t=>n.drain(t)}}function ne(t,e){return`Too many ${e} requests, backing off until: ${new Date(St(t,e)).toISOString()}`}const re="6.19.4";let ie;class se{constructor(){this.name=se.id}setupOnce(){ie=Function.prototype.toString,Function.prototype.toString=function(...t){const e=D(this)||this;return ie.apply(e,t)}}}se.id="FunctionToString";const oe=[/^Script error\.?$/,/^Javascript error: Script error\.? on line 0$/];class ce{constructor(t={}){this.W=t,this.name=ce.id}setupOnce(t,e){t((t=>{const n=e();if(n){const e=n.getIntegration(ce);if(e){const r=n.getClient(),i=r?r.getOptions():{},s=function(t={},e={}){return{allowUrls:[...t.whitelistUrls||[],...t.allowUrls||[],...e.whitelistUrls||[],...e.allowUrls||[]],denyUrls:[...t.blacklistUrls||[],...t.denyUrls||[],...e.blacklistUrls||[],...e.denyUrls||[]],ignoreErrors:[...t.ignoreErrors||[],...e.ignoreErrors||[],...oe],ignoreInternal:void 0===t.ignoreInternal||t.ignoreInternal}}(e.W,i);return function(t,e){if(e.ignoreInternal&&function(t){try{return"SentryError"===t.exception.values[0].type}catch(t){}return!1}(t))return!0;if(function(t,e){if(!e||!e.length)return!1;return function(t){if(t.message)return[t.message];if(t.exception)try{const{type:e="",value:n=""}=t.exception.values&&t.exception.values[0]||{};return[`${n}`,`${e}: ${n}`]}catch(t){return[]}return[]}(t).some((t=>e.some((e=>$(t,e)))))}(t,e.ignoreErrors))return!0;if(function(t,e){if(!e||!e.length)return!1;const n=ae(t);return!!n&&e.some((t=>$(n,t)))}(t,e.denyUrls))return!0;if(!function(t,e){if(!e||!e.length)return!0;const n=ae(t);return!n||e.some((t=>$(n,t)))}(t,e.allowUrls))return!0;return!1}(t,s)?null:t}}return t}))}}function ue(t=[]){for(let e=t.length-1;e>=0;e--){const n=t[e];if(n&&"<anonymous>"!==n.filename&&"[native code]"!==n.filename)return n.filename||null}return null}function ae(t){try{if(t.stacktrace)return ue(t.stacktrace.frames);let e;try{e=t.exception.values[0].stacktrace.frames}catch(t){}return e?ue(e):null}catch(t){return null}}ce.id="InboundFilters";var he=Object.freeze({__proto__:null,FunctionToString:se,InboundFilters:ce});const fe="?";function le(t,e,n,r){const i={filename:t,function:e,in_app:!0};return void 0!==n&&(i.lineno=n),void 0!==r&&(i.colno=r),i}const de=/^\s*at (?:(.*?) ?\((?:address at )?)?((?:file|https?|blob|chrome-extension|address|native|eval|webpack|<anonymous>|[-a-z]+:|.*bundle|\/).*?)(?::(\d+))?(?::(\d+))?\)?\s*$/i,pe=/\((\S*)(?::(\d+))(?::(\d+))\)/,be=[30,t=>{const e=de.exec(t);if(e){if(e[2]&&0===e[2].indexOf("eval")){const t=pe.exec(e[2]);t&&(e[2]=t[1],e[3]=t[2],e[4]=t[3])}const[t,n]=_e(e[1]||fe,e[2]);return le(n,t,e[3]?+e[3]:void 0,e[4]?+e[4]:void 0)}}],ye=/^\s*(.*?)(?:\((.*?)\))?(?:^|@)?((?:file|https?|blob|chrome|webpack|resource|moz-extension|capacitor).*?:\/.*?|\[native code\]|[^@]*(?:bundle|\d+\.js)|\/[\w\-. /=]+)(?::(\d+))?(?::(\d+))?\s*$/i,me=/(\S+) line (\d+)(?: > eval line \d+)* > eval/i,ve=[50,t=>{const e=ye.exec(t);if(e){if(e[3]&&e[3].indexOf(" > eval")>-1){const t=me.exec(e[3]);t&&(e[1]=e[1]||"eval",e[3]=t[1],e[4]=t[2],e[5]="")}let t=e[3],n=e[1]||fe;return[n,t]=_e(n,t),le(t,n,e[4]?+e[4]:void 0,e[5]?+e[5]:void 0)}}],Oe=/^\s*at (?:((?:\[object object\])?.+) )?\(?((?:file|ms-appx|https?|webpack|blob):.*?):(\d+)(?::(\d+))?\)?\s*$/i,je=[40,t=>{const e=Oe.exec(t);return e?le(e[2],e[1]||fe,+e[3],e[4]?+e[4]:void 0):void 0}],ge=/ line (\d+).*script (?:in )?(\S+)(?:: in function (\S+))?$/i,we=[10,t=>{const e=ge.exec(t);return e?le(e[2],e[3]||fe,+e[1]):void 0}],xe=/ line (\d+), column (\d+)\s*(?:in (?:<anonymous function: ([^>]+)>|([^)]+))\(.*\))? in (.*):\s*$/i,Ee=[20,t=>{const e=xe.exec(t);return e?le(e[5],e[3]||e[4]||fe,+e[1],+e[2]):void 0}],_e=(t,e)=>{const n=-1!==t.indexOf("safari-extension"),r=-1!==t.indexOf("safari-web-extension");return n||r?[-1!==t.indexOf("@")?t.split("@")[0]:fe,n?`safari-extension:${e}`:`safari-web-extension:${e}`]:[t,e]};function Se(t){const e=ke(t),n={type:t&&t.name,value:Re(t)};return e.length&&(n.stacktrace={frames:e}),void 0===n.type&&""===n.value&&(n.value="Unrecoverable error caught"),n}function $e(t){return{exception:{values:[Se(t)]}}}function ke(t){const e=t.stacktrace||t.stack||"",n=function(t){if(t){if("number"==typeof t.framesToPop)return t.framesToPop;if(Te.test(t.message))return 1}return 0}(t);try{return L(we,Ee,be,je,ve)(e,n)}catch(t){}return[]}const Te=/Minified React error #\d+;/i;function Re(t){const e=t&&t.message;return e?e.error&&"string"==typeof e.error.message?e.error.message:e:"No error message"}function De(e,n,r){const i=Ne(e,n&&n.syntheticException||void 0,r);return ut(i),i.level=t.Severity.Error,n&&n.event_id&&(i.event_id=n.event_id),dt(i)}function Me(e,n=t.Severity.Info,r,i){const s=qe(e,r&&r.syntheticException||void 0,i);return s.level=n,r&&r.event_id&&(s.event_id=r.event_id),dt(s)}function Ne(t,e,n,r){let i;if(c(t)&&t.error){return $e(t.error)}if(u(t)||o(t,"DOMException")){const r=t;if("stack"in t)i=$e(t);else{const t=r.name||(u(r)?"DOMError":"DOMException"),s=r.message?`${t}: ${r.message}`:t;i=qe(s,e,n),ct(i,s)}return"code"in r&&(i.tags=Object.assign(Object.assign({},i.tags),{"DOMException.code":`${r.code}`})),i}if(s(t))return $e(t);if(f(t)||l(t)){return i=function(t,e,n){const r={exception:{values:[{type:l(t)?t.constructor.name:n?"UnhandledRejection":"Error",value:`Non-Error ${n?"promise rejection":"exception"} captured with keys: ${I(t)}`}]},extra:{__serialized__:ft(t)}};if(e){const t=ke(e);t.length&&(r.stacktrace={frames:t})}return r}(t,e,r),ut(i,{synthetic:!0}),i}return i=qe(t,e,n),ct(i,`${t}`,void 0),ut(i,{synthetic:!0}),i}function qe(t,e,n){const r={message:t};if(n&&e){const t=ke(e);t.length&&(r.stacktrace={frames:t})}return r}const Ie=r();let Ce;function Le(){if(Ce)return Ce;if(P(Ie.fetch))return Ce=Ie.fetch.bind(Ie);const t=Ie.document;let e=Ie.fetch;if(t&&"function"==typeof t.createElement)try{const n=t.createElement("iframe");n.hidden=!0,t.head.appendChild(n);const r=n.contentWindow;r&&r.fetch&&(e=r.fetch),t.head.removeChild(n)}catch(t){}return Ce=e.bind(Ie)}function Ae(t,e){if("[object Navigator]"===Object.prototype.toString.call(Ie&&Ie.navigator)&&"function"==typeof Ie.navigator.sendBeacon){return Ie.navigator.sendBeacon.bind(Ie.navigator)(t,e)}if(F()){const n=Le();n(t,{body:e,method:"POST",credentials:"omit",keepalive:!0}).then(null,(t=>{console.error(t)}))}else;}function Ue(t){return"event"===t?"error":t}const Fe=r();class Pe{constructor(t){this.options=t,this.K=yt(30),this.G={},this.V={},this.Y=Bt(t.dsn,t.Z,t.tunnel),this.url=Jt(this.Y.dsn),this.options.sendClientReports&&Fe.document&&Fe.document.addEventListener("visibilitychange",(()=>{"hidden"===Fe.document.visibilityState&&this.tt()}))}sendEvent(t){return this.et(function(t,e){const n=Qt(e),r=t.type||"event",i="transaction"===r||!!e.tunnel,{transactionSampling:s}=t.sdkProcessingMetadata||{},{method:o,rate:c}=s||{};let u;Yt(t,e.metadata.sdk),t.tags=t.tags||{},t.extra=t.extra||{},t.sdkProcessingMetadata&&t.sdkProcessingMetadata.baseClientNormalized||(t.tags.skippedNormalization=!0,t.extra.normalizeDepth=t.sdkProcessingMetadata?t.sdkProcessingMetadata.normalizeDepth:"unset"),delete t.sdkProcessingMetadata;try{u=JSON.stringify(t)}catch(e){t.tags.JSONStringifyError=!0,t.extra.JSONStringifyError=e;try{u=JSON.stringify(ht(t))}catch(t){const e=t;u=JSON.stringify({message:"JSON.stringify error after renormalization",extra:{message:e.message,stack:e.stack}})}}const a={body:u,type:r,url:i?Wt(e.dsn,e.tunnel):Jt(e.dsn)};if(i){const i=Et(Object.assign(Object.assign({event_id:t.event_id,sent_at:(new Date).toISOString()},n&&{sdk:n}),!!e.tunnel&&{dsn:j(e.dsn)}),[[{type:r,sample_rates:[{id:o,rate:c}]},a.body]]);a.body=_t(i)}return a}(t,this.Y),t)}sendSession(t){return this.et(function(t,e){const[n,r]=Zt(t,e);return{body:_t(n),type:r,url:Wt(e.dsn,e.tunnel)}}(t,this.Y),t)}close(t){return this.K.drain(t)}recordLostEvent(t,e){var n;if(!this.options.sendClientReports)return;const r=`${Ue(e)}:${t}`;this.V[r]=(null!=(n=this.V[r])?n:0)+1}tt(){if(!this.options.sendClientReports)return;const t=this.V;if(this.V={},!Object.keys(t).length)return;const e=Wt(this.Y.dsn,this.Y.tunnel),n=Object.keys(t).map((e=>{const[n,r]=e.split(":");return{reason:r,category:n,quantity:t[e]}})),r=(i=n,Et((s=this.Y.tunnel&&j(this.Y.dsn))?{dsn:s}:{},[[{type:"client_report"},{timestamp:o||wt(),discarded_events:i}]]));var i,s,o;try{Ae(e,_t(r))}catch(t){}}nt({requestType:t,response:e,headers:n,resolve:r,reject:i}){const s=vt(e.status);this.G=kt(this.G,n),this.rt(t),"success"!==s?i(e):r({status:s})}it(t){const e=Ue(t);return new Date(St(this.G,e))}rt(t){const e=Ue(t);return $t(this.G,e)}}class Be extends Pe{constructor(t,e=Le()){super(t),this.st=e}et(t,e){if(this.rt(t.type))return this.recordLostEvent("ratelimit_backoff",t.type),Promise.reject({event:e,type:t.type,reason:`Transport for ${t.type} requests locked till ${this.it(t.type)} due to too many requests.`,status:429});const n={body:t.body,method:"POST",referrerPolicy:B()?"origin":""};return void 0!==this.options.fetchParameters&&Object.assign(n,this.options.fetchParameters),void 0!==this.options.headers&&(n.headers=this.options.headers),this.K.add((()=>new bt(((e,r)=>{this.st(t.url,n).then((n=>{const i={"x-sentry-rate-limits":n.headers.get("X-Sentry-Rate-Limits"),"retry-after":n.headers.get("Retry-After")};this.nt({requestType:t.type,response:n,headers:i,resolve:e,reject:r})})).catch(r)})))).then(void 0,(e=>{throw e instanceof v?this.recordLostEvent("queue_overflow",t.type):this.recordLostEvent("network_error",t.type),e}))}}class He extends Pe{et(t,e){return this.rt(t.type)?(this.recordLostEvent("ratelimit_backoff",t.type),Promise.reject({event:e,type:t.type,reason:`Transport for ${t.type} requests locked till ${this.it(t.type)} due to too many requests.`,status:429})):this.K.add((()=>new bt(((e,n)=>{const r=new XMLHttpRequest;r.onreadystatechange=()=>{if(4===r.readyState){const i={"x-sentry-rate-limits":r.getResponseHeader("X-Sentry-Rate-Limits"),"retry-after":r.getResponseHeader("Retry-After")};this.nt({requestType:t.type,response:r,headers:i,resolve:e,reject:n})}},r.open("POST",t.url);for(const t in this.options.headers)Object.prototype.hasOwnProperty.call(this.options.headers,t)&&r.setRequestHeader(t,this.options.headers[t]);r.send(t.body)})))).then(void 0,(e=>{throw e instanceof v?this.recordLostEvent("queue_overflow",t.type):this.recordLostEvent("network_error",t.type),e}))}}function Xe(t,e=Le()){return ee({bufferSize:t.bufferSize},(function(n){const r=Object.assign({body:n.body,method:"POST",referrerPolicy:"origin"},t.requestOptions);return e(t.url,r).then((t=>t.text().then((e=>({body:e,headers:{"x-sentry-rate-limits":t.headers.get("X-Sentry-Rate-Limits"),"retry-after":t.headers.get("Retry-After")},reason:t.statusText,statusCode:t.status})))))}))}function ze(t){return ee({bufferSize:t.bufferSize},(function(e){return new bt(((n,r)=>{const i=new XMLHttpRequest;i.onreadystatechange=()=>{if(4===i.readyState){const t={body:i.response,headers:{"x-sentry-rate-limits":i.getResponseHeader("X-Sentry-Rate-Limits"),"retry-after":i.getResponseHeader("Retry-After")},reason:i.statusText,statusCode:i.status};n(t)}},i.open("POST",t.url);for(const e in t.headers)Object.prototype.hasOwnProperty.call(t.headers,e)&&i.setRequestHeader(e,t.headers[e]);i.send(e.body)}))}))}var Je=Object.freeze({__proto__:null,BaseTransport:Pe,FetchTransport:Be,XHRTransport:He,makeNewFetchTransport:Xe,makeNewXHRTransport:ze});class We extends class{constructor(t){this.W=t,this.ot=this.ct()}eventFromException(t,e){throw new v("Backend has to implement `eventFromException` method")}eventFromMessage(t,e,n){throw new v("Backend has to implement `eventFromMessage` method")}sendEvent(t){if(this.ut&&this.W.dsn&&this.W._experiments&&this.W._experiments.newTransport){const e=function(t,e){const n=Qt(e),r=t.type||"event",{transactionSampling:i}=t.sdkProcessingMetadata||{},{method:s,rate:o}=i||{};return Yt(t,e.metadata.sdk),t.tags=t.tags||{},t.extra=t.extra||{},t.sdkProcessingMetadata&&t.sdkProcessingMetadata.baseClientNormalized||(t.tags.skippedNormalization=!0,t.extra.normalizeDepth=t.sdkProcessingMetadata?t.sdkProcessingMetadata.normalizeDepth:"unset"),delete t.sdkProcessingMetadata,Et(Object.assign(Object.assign({event_id:t.event_id,sent_at:(new Date).toISOString()},n&&{sdk:n}),!!e.tunnel&&{dsn:j(e.dsn)}),[[{type:r,sample_rates:[{id:s,rate:o}]},t]])}(t,Bt(this.W.dsn,this.W.Z,this.W.tunnel));this.ut.send(e).then(null,(t=>{}))}else this.ot.sendEvent(t).then(null,(t=>{}))}sendSession(t){if(this.ot.sendSession)if(this.ut&&this.W.dsn&&this.W._experiments&&this.W._experiments.newTransport){const e=Bt(this.W.dsn,this.W.Z,this.W.tunnel),[n]=Zt(t,e);this.ut.send(n).then(null,(t=>{}))}else this.ot.sendSession(t).then(null,(t=>{}))}getTransport(){return this.ot}ct(){return new te}}{eventFromException(t,e){return De(t,e,this.W.attachStacktrace)}eventFromMessage(e,n=t.Severity.Info,r){return Me(e,n,r,this.W.attachStacktrace)}ct(){if(!this.W.dsn)return super.ct();const t=Object.assign(Object.assign({},this.W.transportOptions),{dsn:this.W.dsn,tunnel:this.W.tunnel,sendClientReports:this.W.sendClientReports,Z:this.W.Z}),e=Bt(t.dsn,t.Z,t.tunnel),n=Wt(e.dsn,e.tunnel);if(this.W.transport)return new this.W.transport(t);if(F()){const e=Object.assign({},t.fetchParameters);return this.ut=Xe({requestOptions:e,url:n}),new Be(t)}return this.ut=ze({url:n,headers:t.headers}),new He(t)}}const Ke=r();let Ge=0;function Ve(){return Ge>0}function Qe(){Ge+=1,setTimeout((()=>{Ge-=1}))}function Ye(t,e={},n){if("function"!=typeof t)return t;try{const e=t.__sentry_wrapped__;if(e)return e;if(D(t))return t}catch(e){return t}const sentryWrapped=function(){const r=Array.prototype.slice.call(arguments);try{n&&"function"==typeof n&&n.apply(this,arguments);const i=r.map((t=>Ye(t,e)));return t.apply(this,i)}catch(t){throw Qe(),Pt((n=>{n.addEventProcessor((t=>(e.mechanism&&(ct(t,void 0,void 0),ut(t,e.mechanism)),t.extra=Object.assign(Object.assign({},t.extra),{arguments:r}),t))),captureException(t)})),t}};try{for(const e in t)Object.prototype.hasOwnProperty.call(t,e)&&(sentryWrapped[e]=t[e])}catch(t){}R(sentryWrapped,t),T(t,"__sentry_wrapped__",sentryWrapped);try{Object.getOwnPropertyDescriptor(sentryWrapped,"name").configurable&&Object.defineProperty(sentryWrapped,"name",{get:()=>t.name})}catch(t){}return sentryWrapped}function Ze(t={}){if(!Ke.document)return;if(!t.eventId)return;if(!t.dsn)return;const e=Ke.document.createElement("script");e.async=!0,e.src=function(t,e){const n=w(t),r=`${Ht(n)}embed/error-page/`;let i=`dsn=${j(n)}`;for(const t in e)if("dsn"!==t)if("user"===t){if(!e.user)continue;e.user.name&&(i+=`&name=${encodeURIComponent(e.user.name)}`),e.user.email&&(i+=`&email=${encodeURIComponent(e.user.email)}`)}else i+=`&${encodeURIComponent(t)}=${encodeURIComponent(e[t])}`;return`${r}?${i}`}(t.dsn,t),t.onLoad&&(e.onload=t.onLoad);const n=Ke.document.head||Ke.document.body;n&&n.appendChild(e)}class tn{constructor(t){this.name=tn.id,this.at={onerror:en,onunhandledrejection:nn},this.W=Object.assign({onerror:!0,onunhandledrejection:!0},t)}setupOnce(){Error.stackTraceLimit=50;const t=this.W;for(const e in t){const n=this.at[e];n&&t[e]&&(n(),this.at[e]=void 0)}}}function en(){W("error",(e=>{const[n,r]=on();if(!n.getIntegration(tn))return;const{msg:i,url:s,line:o,column:u,error:h}=e;if(Ve()||h&&h.__sentry_own_request__)return;const f=void 0===h&&a(i)?function(t,e,n,r){const i=/^(?:[Uu]ncaught (?:exception: )?)?(?:((?:Eval|Internal|Range|Reference|Syntax|Type|URI|)Error): )?(.*)$/i;let s=c(t)?t.message:t,o="Error";const u=s.match(i);u&&(o=u[1],s=u[2]);return rn({exception:{values:[{type:o,value:s}]}},e,n,r)}(i,s,o,u):rn(Ne(h||i,void 0,r,!1),s,o,u);f.level=t.Severity.Error,sn(n,h,f,"onerror")}))}function nn(){W("unhandledrejection",(e=>{const[n,r]=on();if(!n.getIntegration(tn))return;let i=e;try{"reason"in e?i=e.reason:"detail"in e&&"reason"in e.detail&&(i=e.detail.reason)}catch(t){}if(Ve()||i&&i.__sentry_own_request__)return!0;const s=h(i)?{exception:{values:[{type:"UnhandledRejection",value:`Non-Error promise rejection captured with value: ${String(i)}`}]}}:Ne(i,void 0,r,!0);s.level=t.Severity.Error,sn(n,i,s,"onunhandledrejection")}))}function rn(t,e,n,i){const s=t.exception=t.exception||{},o=s.values=s.values||[],c=o[0]=o[0]||{},u=c.stacktrace=c.stacktrace||{},h=u.frames=u.frames||[],f=isNaN(parseInt(i,10))?void 0:i,l=isNaN(parseInt(n,10))?void 0:n,d=a(e)&&e.length>0?e:function(){const t=r();try{return t.document.location.href}catch(t){return""}}();return 0===h.length&&h.push({colno:f,filename:d,function:"?",in_app:!0,lineno:l}),t}function sn(t,e,n,r){ut(n,{handled:!1,type:r}),t.captureEvent(n,{originalException:e})}function on(){const t=Lt(),e=t.getClient();return[t,e&&e.getOptions().attachStacktrace]}tn.id="GlobalHandlers";const cn=["EventTarget","Window","Node","ApplicationCache","AudioTrackList","ChannelMergerNode","CryptoOperation","EventSource","FileReader","HTMLUnknownElement","IDBDatabase","IDBRequest","IDBTransaction","KeyOperation","MediaController","MessagePort","ModalWindow","Notification","SVGElementInstance","Screen","TextTrack","TextTrackCue","TextTrackList","WebSocket","WebSocketWorker","Worker","XMLHttpRequest","XMLHttpRequestEventTarget","XMLHttpRequestUpload"];class un{constructor(t){this.name=un.id,this.W=Object.assign({XMLHttpRequest:!0,eventTarget:!0,requestAnimationFrame:!0,setInterval:!0,setTimeout:!0},t)}setupOnce(){const t=r();this.W.setTimeout&&k(t,"setTimeout",an),this.W.setInterval&&k(t,"setInterval",an),this.W.requestAnimationFrame&&k(t,"requestAnimationFrame",hn),this.W.XMLHttpRequest&&"XMLHttpRequest"in t&&k(XMLHttpRequest.prototype,"send",fn);const e=this.W.eventTarget;if(e){(Array.isArray(e)?e:cn).forEach(ln)}}}function an(t){return function(...e){const n=e[0];return e[0]=Ye(n,{mechanism:{data:{function:U(t)},handled:!0,type:"instrument"}}),t.apply(this,e)}}function hn(t){return function(e){return t.apply(this,[Ye(e,{mechanism:{data:{function:"requestAnimationFrame",handler:U(t)},handled:!0,type:"instrument"}})])}}function fn(t){return function(...e){const n=this;return["onload","onerror","onprogress","onreadystatechange"].forEach((t=>{t in n&&"function"==typeof n[t]&&k(n,t,(function(e){const n={mechanism:{data:{function:t,handler:U(e)},handled:!0,type:"instrument"}},r=D(e);return r&&(n.mechanism.data.handler=U(r)),Ye(e,n)}))})),t.apply(this,e)}}function ln(t){const e=r(),n=e[t]&&e[t].prototype;n&&n.hasOwnProperty&&n.hasOwnProperty("addEventListener")&&(k(n,"addEventListener",(function(e){return function(n,r,i){try{"function"==typeof r.handleEvent&&(r.handleEvent=Ye(r.handleEvent.bind(r),{mechanism:{data:{function:"handleEvent",handler:U(r),target:t},handled:!0,type:"instrument"}}))}catch(t){}return e.apply(this,[n,Ye(r,{mechanism:{data:{function:"addEventListener",handler:U(r),target:t},handled:!0,type:"instrument"}}),i])}})),k(n,"removeEventListener",(function(t){return function(e,n,r){const i=n;try{const n=i&&i.__sentry_wrapped__;n&&t.call(this,e,n,r)}catch(t){}return t.call(this,e,i,r)}})))}un.id="TryCatch";class dn{constructor(t){this.name=dn.id,this.W=Object.assign({console:!0,dom:!0,fetch:!0,history:!0,sentry:!0,xhr:!0},t)}addSentryBreadcrumb(t){this.W.sentry&&Lt().addBreadcrumb({category:"sentry."+("transaction"===t.type?"transaction":"event"),event_id:t.event_id,level:t.level,message:ot(t)},{event:t})}setupOnce(){this.W.console&&W("console",pn),this.W.dom&&W("dom",function(t){function e(e){let n,r="object"==typeof t?t.serializeAttribute:void 0;"string"==typeof r&&(r=[r]);try{n=e.event.target?b(e.event.target,r):b(e.event,r)}catch(t){n="<unknown>"}0!==n.length&&Lt().addBreadcrumb({category:`ui.${e.name}`,message:n},{event:e.event,name:e.name,global:e.global})}return e}(this.W.dom)),this.W.xhr&&W("xhr",bn),this.W.fetch&&W("fetch",yn),this.W.history&&W("history",mn)}}function pn(t){const e={category:"console",data:{arguments:t.args,logger:"console"},level:mt(t.level),message:S(t.args," ")};if("assert"===t.level){if(!1!==t.args[0])return;e.message=`Assertion failed: ${S(t.args.slice(1)," ")||"console.assert"}`,e.data.arguments=t.args.slice(1)}Lt().addBreadcrumb(e,{input:t.args,level:t.level})}function bn(t){if(t.endTimestamp){if(t.xhr.__sentry_own_request__)return;const{method:e,url:n,status_code:r,body:i}=t.xhr.__sentry_xhr__||{};Lt().addBreadcrumb({category:"xhr",data:{method:e,url:n,status_code:r},type:"http"},{xhr:t.xhr,input:i})}else;}function yn(e){e.endTimestamp&&(e.fetchData.url.match(/sentry_key/)&&"POST"===e.fetchData.method||(e.error?Lt().addBreadcrumb({category:"fetch",data:e.fetchData,level:t.Severity.Error,type:"http"},{data:e.error,input:e.args}):Lt().addBreadcrumb({category:"fetch",data:Object.assign(Object.assign({},e.fetchData),{status_code:e.response.status}),type:"http"},{input:e.args,response:e.response})))}function mn(t){const e=r();let n=t.from,i=t.to;const s=it(e.location.href);let o=it(n);const c=it(i);o.path||(o=s),s.protocol===c.protocol&&s.host===c.host&&(i=c.relative),s.protocol===o.protocol&&s.host===o.host&&(n=o.relative),Lt().addBreadcrumb({category:"navigation",data:{from:n,to:i}})}dn.id="Breadcrumbs";class vn{constructor(t={}){this.name=vn.id,this.ht=t.key||"cause",this.ft=t.limit||5}setupOnce(){Dt(((t,e)=>{const n=Lt().getIntegration(vn);return n?function(t,e,n,r){if(!(n.exception&&n.exception.values&&r&&p(r.originalException,Error)))return n;const i=On(e,r.originalException,t);return n.exception.values=[...i,...n.exception.values],n}(n.ht,n.ft,t,e):t}))}}function On(t,e,n,r=[]){if(!p(e[n],Error)||r.length+1>=t)return r;const i=Se(e[n]);return On(t,e[n],n,[i,...r])}vn.id="LinkedErrors";const jn=r();class gn{constructor(){this.name=gn.id}setupOnce(){Dt((t=>{if(Lt().getIntegration(gn)){if(!jn.navigator&&!jn.location&&!jn.document)return t;const e=t.request&&t.request.url||jn.location&&jn.location.href,{referrer:n}=jn.document||{},{userAgent:r}=jn.navigator||{},i=Object.assign(Object.assign(Object.assign({},t.request&&t.request.headers),n&&{Referer:n}),r&&{"User-Agent":r}),s=Object.assign(Object.assign({},e&&{url:e}),{headers:i});return Object.assign(Object.assign({},t),{request:s})}return t}))}}gn.id="UserAgent";class wn{constructor(){this.name=wn.id}setupOnce(t,e){t((t=>{const n=e().getIntegration(wn);if(n){try{if(function(t,e){if(!e)return!1;if(function(t,e){const n=t.message,r=e.message;if(!n&&!r)return!1;if(n&&!r||!n&&r)return!1;if(n!==r)return!1;if(!En(t,e))return!1;if(!xn(t,e))return!1;return!0}(t,e))return!0;if(function(t,e){const n=_n(e),r=_n(t);if(!n||!r)return!1;if(n.type!==r.type||n.value!==r.value)return!1;if(!En(t,e))return!1;if(!xn(t,e))return!1;return!0}(t,e))return!0;return!1}(t,n.lt))return null}catch(e){return n.lt=t}return n.lt=t}return t}))}}function xn(t,e){let n=Sn(t),r=Sn(e);if(!n&&!r)return!0;if(n&&!r||!n&&r)return!1;if(n=n,r=r,r.length!==n.length)return!1;for(let t=0;t<r.length;t++){const e=r[t],i=n[t];if(e.filename!==i.filename||e.lineno!==i.lineno||e.colno!==i.colno||e.function!==i.function)return!1}return!0}function En(t,e){let n=t.fingerprint,r=e.fingerprint;if(!n&&!r)return!0;if(n&&!r||!n&&r)return!1;n=n,r=r;try{return!(n.join("")!==r.join(""))}catch(t){return!1}}function _n(t){return t.exception&&t.exception.values&&t.exception.values[0]}function Sn(t){const e=t.exception;if(e)try{return e.values[0].stacktrace.frames}catch(t){return}else if(t.stacktrace)return t.stacktrace.frames}wn.id="Dedupe";var $n=Object.freeze({__proto__:null,GlobalHandlers:tn,TryCatch:un,Breadcrumbs:dn,LinkedErrors:vn,UserAgent:gn,Dedupe:wn});class kn extends class{constructor(t,e){this.dt={},this.bt=0,this.yt=new t(e),this.W=e,e.dsn&&(this.vt=w(e.dsn))}captureException(t,e,n){if(at(t))return;let r=e&&e.event_id;return this.Ot(this.jt().eventFromException(t,e).then((t=>this.gt(t,e,n))).then((t=>{r=t}))),r}captureMessage(t,e,n,r){let i=n&&n.event_id;const s=h(t)?this.jt().eventFromMessage(String(t),e,n):this.jt().eventFromException(t,n);return this.Ot(s.then((t=>this.gt(t,n,r))).then((t=>{i=t}))),i}captureEvent(t,e,n){if(e&&e.originalException&&at(e.originalException))return;let r=e&&e.event_id;return this.Ot(this.gt(t,e,n).then((t=>{r=t}))),r}captureSession(t){this.wt()&&("string"!=typeof t.release||(this.xt(t),t.update({init:!1})))}getDsn(){return this.vt}getOptions(){return this.W}getTransport(){return this.jt().getTransport()}flush(t){return this.Et(t).then((e=>this.getTransport().close(t).then((t=>e&&t))))}close(t){return this.flush(t).then((t=>(this.getOptions().enabled=!1,t)))}setupIntegrations(){this.wt()&&!this.dt.initialized&&(this.dt=Vt(this.W))}getIntegration(t){try{return this.dt[t.id]||null}catch(t){return null}}_t(t,e){let n=!1,r=!1;const i=e.exception&&e.exception.values;if(i){r=!0;for(const t of i){const e=t.mechanism;if(e&&!1===e.handled){n=!0;break}}}const s="ok"===t.status;(s&&0===t.errors||s&&n)&&(t.update(Object.assign(Object.assign({},n&&{status:"crashed"}),{errors:t.errors||Number(r||n)})),this.captureSession(t))}xt(t){this.jt().sendSession(t)}Et(t){return new bt((e=>{let n=0;const r=setInterval((()=>{0==this.bt?(clearInterval(r),e(!0)):(n+=1,t&&n>=t&&(clearInterval(r),e(!1)))}),1)}))}jt(){return this.yt}wt(){return!1!==this.getOptions().enabled&&void 0!==this.vt}St(t,e,n){const{normalizeDepth:r=3,normalizeMaxBreadth:i=1e3}=this.getOptions(),s=Object.assign(Object.assign({},t),{event_id:t.event_id||(n&&n.event_id?n.event_id:rt()),timestamp:t.timestamp||wt()});this.$t(s),this.kt(s);let o=e;n&&n.captureContext&&(o=Tt.clone(o).update(n.captureContext));let c=dt(s);return o&&(c=o.applyToEvent(s,n)),c.then((t=>(t&&(t.sdkProcessingMetadata=Object.assign(Object.assign({},t.sdkProcessingMetadata),{normalizeDepth:ht(r)})),"number"==typeof r&&r>0?this.Tt(t,r,i):t)))}Tt(t,e,n){if(!t)return null;const r=Object.assign(Object.assign(Object.assign(Object.assign(Object.assign({},t),t.breadcrumbs&&{breadcrumbs:t.breadcrumbs.map((t=>Object.assign(Object.assign({},t),t.data&&{data:ht(t.data,e,n)})))}),t.user&&{user:ht(t.user,e,n)}),t.contexts&&{contexts:ht(t.contexts,e,n)}),t.extra&&{extra:ht(t.extra,e,n)});return t.contexts&&t.contexts.trace&&(r.contexts.trace=t.contexts.trace),r.sdkProcessingMetadata=Object.assign(Object.assign({},r.sdkProcessingMetadata),{baseClientNormalized:!0}),r}$t(t){const e=this.getOptions(),{environment:n,release:r,dist:i,maxValueLength:s=250}=e;"environment"in t||(t.environment="environment"in e?n:"production"),void 0===t.release&&void 0!==r&&(t.release=r),void 0===t.dist&&void 0!==i&&(t.dist=i),t.message&&(t.message=_(t.message,s));const o=t.exception&&t.exception.values&&t.exception.values[0];o&&o.value&&(o.value=_(o.value,s));const c=t.request;c&&c.url&&(c.url=_(c.url,s))}kt(t){const e=Object.keys(this.dt);e.length>0&&(t.sdk=t.sdk||{},t.sdk.integrations=[...t.sdk.integrations||[],...e])}Rt(t){this.jt().sendEvent(t)}gt(t,e,n){return this.Dt(t,e,n).then((t=>t.event_id),(t=>{}))}Dt(t,e,n){const{beforeSend:r,sampleRate:i}=this.getOptions(),s=this.getTransport();function o(t,e){s.recordLostEvent&&s.recordLostEvent(t,e)}if(!this.wt())return pt(new v("SDK not enabled, will not capture event."));const c="transaction"===t.type;return!c&&"number"==typeof i&&Math.random()>i?(o("sample_rate","event"),pt(new v(`Discarding event because it's not included in the random sample (sampling rate = ${i})`))):this.St(t,n,e).then((n=>{if(null===n)throw o("event_processor",t.type||"event"),new v("An event processor returned null, will not send event.");if(e&&e.data&&!0===e.data.__sentry__||c||!r)return n;return function(t){const e="`beforeSend` method has to return `null` or a valid event.";if(d(t))return t.then((t=>{if(!f(t)&&null!==t)throw new v(e);return t}),(t=>{throw new v(`beforeSend rejected with ${t}`)}));if(!f(t)&&null!==t)throw new v(e);return t}(r(n,e))})).then((e=>{if(null===e)throw o("before_send",t.type||"event"),new v("`beforeSend` returned `null`, will not send event.");const r=n&&n.getSession&&n.getSession();return!c&&r&&this._t(r,e),this.Rt(e),e})).then(null,(t=>{if(t instanceof v)throw t;throw this.captureException(t,{data:{__sentry__:!0},originalException:t}),new v(`Event processing pipeline threw an error, original event will not be sent. Details have been sent as a new event.\nReason: ${t}`)}))}Ot(t){this.bt+=1,t.then((t=>(this.bt-=1,t)),(t=>(this.bt-=1,t)))}}{constructor(t={}){t.Z=t.Z||{},t.Z.sdk=t.Z.sdk||{name:"sentry.javascript.browser",packages:[{name:"npm:@sentry/browser",version:re}],version:re},super(We,t)}showReportDialog(t={}){r().document&&this.wt()&&Ze(Object.assign(Object.assign({},t),{dsn:t.dsn||this.getDsn()}))}St(t,e,n){return t.platform=t.platform||"javascript",super.St(t,e,n)}Rt(t){const e=this.getIntegration(dn);e&&e.addSentryBreadcrumb(t),super.Rt(t)}}const Tn=[new ce,new se,new un,new dn,new tn,new vn,new wn,new gn];function Rn(t){t.startSession({ignoreDuration:!0}),t.captureSession()}let Dn={};const Mn=r();Mn.Sentry&&Mn.Sentry.Integrations&&(Dn=Mn.Sentry.Integrations);const Nn=Object.assign(Object.assign(Object.assign({},Dn),he),$n);return t.BrowserClient=kn,t.Hub=qt,t.Integrations=Nn,t.SDK_NAME="sentry.javascript.browser",t.SDK_VERSION=re,t.Scope=Tt,t.Session=Mt,t.Transports=Je,t.addBreadcrumb=function(t){Ft("addBreadcrumb",t)},t.addGlobalEventProcessor=Dt,t.captureEvent=function(t){return Ft("captureEvent",t)},t.captureException=captureException,t.captureMessage=function(t,e){const n=new Error(t),r="string"!=typeof e?{captureContext:e}:void 0;return Ft("captureMessage",t,"string"==typeof e?e:void 0,Object.assign({originalException:t,syntheticException:n},r))},t.close=function(t){const e=Lt().getClient();return e?e.close(t):dt(!1)},t.configureScope=function(t){Ft("configureScope",t)},t.defaultIntegrations=Tn,t.eventFromException=De,t.eventFromMessage=Me,t.flush=function(t){const e=Lt().getClient();return e?e.flush(t):dt(!1)},t.forceLoad=function(){},t.getCurrentHub=Lt,t.getHubFromCarrier=At,t.init=function(t={}){if(void 0===t.defaultIntegrations&&(t.defaultIntegrations=Tn),void 0===t.release){const e=r();e.SENTRY_RELEASE&&e.SENTRY_RELEASE.id&&(t.release=e.SENTRY_RELEASE.id)}void 0===t.autoSessionTracking&&(t.autoSessionTracking=!0),void 0===t.sendClientReports&&(t.sendClientReports=!0),function(t,e){!0===e.debug&&console.warn("[Sentry] Cannot initialize SDK with `debug` option using a non-debug bundle.");const n=Lt(),r=n.getScope();r&&r.update(e.initialScope);const i=new t(e);n.bindClient(i)}(kn,t),t.autoSessionTracking&&function(){const t=r();if(void 0===t.document)return;const e=Lt();if(!e.captureSession)return;Rn(e),W("history",(({from:t,to:e})=>{void 0!==t&&t!==e&&Rn(Lt())}))}()},t.injectReportDialog=Ze,t.lastEventId=function(){return Lt().lastEventId()},t.makeMain=Ct,t.onLoad=function(t){t()},t.setContext=function(t,e){Ft("setContext",t,e)},t.setExtra=function(t,e){Ft("setExtra",t,e)},t.setExtras=function(t){Ft("setExtras",t)},t.setTag=function(t,e){Ft("setTag",t,e)},t.setTags=function(t){Ft("setTags",t)},t.setUser=function(t){Ft("setUser",t)},t.showReportDialog=function(t={}){const e=Lt(),n=e.getScope();n&&(t.user=Object.assign(Object.assign({},n.getUser()),t.user)),t.eventId||(t.eventId=e.lastEventId());const r=e.getClient();r&&r.showReportDialog(t)},t.startTransaction=function(t,e){return Ft("startTransaction",Object.assign({},t),e)},t.withScope=Pt,t.wrap=function(t){return Ye(t)()},t}({});
|
|
3
3
|
//# sourceMappingURL=bundle.es6.min.js.map
|