@wix/create-app 0.0.46 → 0.0.47

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.
@@ -6,7 +6,7 @@ Type: ${e}
6
6
  Name: ${Qt(r)}
7
7
  Error:`,i)}}function vr(e){let t="console";Q(t,e),Z(t,Xa)}function Xa(){"console"in x&&Xt.forEach(function(e){e in x.console&&M(x.console,e,function(t){return fe[e]=t,function(...n){$("console",{args:n,level:e});let i=fe[e];i&&i.apply(x.console,n)}})})}u();u();function O(){let e=x,t=e.crypto||e.msCrypto,n=()=>Math.random()*16;try{if(t&&t.randomUUID)return t.randomUUID().replace(/-/g,"");t&&t.getRandomValues&&(n=()=>{let r=new Uint8Array(1);return t.getRandomValues(r),r[0]})}catch{}return("10000000100040008000"+1e11).replace(/[018]/g,r=>(r^(n()&15)>>r/4).toString(16))}function mo(e){return e.exception&&e.exception.values?e.exception.values[0]:void 0}function At(e){let{message:t,event_id:n}=e;if(t)return t;let r=mo(e);return r?r.type&&r.value?`${r.type}: ${r.value}`:r.type||r.value||n||"<unknown>":n||"<unknown>"}function Ar(e,t,n){let r=e.exception=e.exception||{},i=r.values=r.values||[],o=i[0]=i[0]||{};o.value||(o.value=t||""),o.type||(o.type=n||"Error")}function Rt(e,t){let n=mo(e);if(!n)return;let r={type:"generic",handled:!0},i=n.mechanism;if(n.mechanism={...r,...i,...t},t&&"data"in t){let o={...i&&i.data,...t.data};n.mechanism.data=o}}var Qa=/^(0|[1-9]\d*)\.(0|[1-9]\d*)\.(0|[1-9]\d*)(?:-((?:0|[1-9]\d*|\d*[a-zA-Z-][0-9a-zA-Z-]*)(?:\.(?:0|[1-9]\d*|\d*[a-zA-Z-][0-9a-zA-Z-]*))*))?(?:\+([0-9a-zA-Z-]+(?:\.[0-9a-zA-Z-]+)*))?$/;function Za(e){let t=e.match(Qa)||[],n=parseInt(t[1],10),r=parseInt(t[2],10),i=parseInt(t[3],10);return{buildmetadata:t[5],major:isNaN(n)?void 0:n,minor:isNaN(r)?void 0:r,patch:isNaN(i)?void 0:i,prerelease:t[4]}}function Rr(e,t,n=5){if(t.lineno===void 0)return;let r=e.length,i=Math.max(Math.min(r-1,t.lineno-1),0);t.pre_context=e.slice(Math.max(0,i-n),i).map(o=>De(o,0)),t.context_line=De(e[Math.min(r-1,i)],t.colno||0),t.post_context=e.slice(Math.min(i+1,r),i+1+n).map(o=>De(o,0))}function dn(e){if(e&&e.__sentry_captured__)return!0;try{X(e,"__sentry_captured__",!0)}catch{}return!1}function Gt(e){return Array.isArray(e)?e:[e]}var me=x,tc=1e3,go,Cr,Or;function ec(e){let t="dom";Q(t,e),Z(t,nc)}function nc(){if(!me.document)return;let e=$.bind(null,"dom"),t=ho(e,!0);me.document.addEventListener("click",t,!1),me.document.addEventListener("keypress",t,!1),["EventTarget","Node"].forEach(n=>{let r=me[n]&&me[n].prototype;!r||!r.hasOwnProperty||!r.hasOwnProperty("addEventListener")||(M(r,"addEventListener",function(i){return function(o,s,a){if(o==="click"||o=="keypress")try{let c=this,d=c.__sentry_instrumentation_handlers__=c.__sentry_instrumentation_handlers__||{},l=d[o]=d[o]||{refCount:0};if(!l.handler){let p=ho(e);l.handler=p,i.call(this,o,p,a)}l.refCount++}catch{}return i.call(this,o,s,a)}}),M(r,"removeEventListener",function(i){return function(o,s,a){if(o==="click"||o=="keypress")try{let c=this,d=c.__sentry_instrumentation_handlers__||{},l=d[o];l&&(l.refCount--,l.refCount<=0&&(i.call(this,o,l.handler,a),l.handler=void 0,delete d[o]),Object.keys(d).length===0&&delete c.__sentry_instrumentation_handlers__)}catch{}return i.call(this,o,s,a)}}))})}function rc(e){if(e.type!==Cr)return!1;try{if(!e.target||e.target._sentryId!==Or)return!1}catch{}return!0}function ic(e,t){return e!=="keypress"?!1:!t||!t.tagName?!0:!(t.tagName==="INPUT"||t.tagName==="TEXTAREA"||t.isContentEditable)}function ho(e,t=!1){return n=>{if(!n||n._sentryCaptured)return;let r=oc(n);if(ic(n.type,r))return;X(n,"_sentryCaptured",!0),r&&!r._sentryId&&X(r,"_sentryId",O());let i=n.type==="keypress"?"input":n.type;rc(n)||(e({event:n,name:i,global:t}),Cr=n.type,Or=r?r._sentryId:void 0),clearTimeout(go),go=me.setTimeout(()=>{Or=void 0,Cr=void 0},tc)}}function oc(e){try{return e.target}catch{return null}}u();u();var ln=Vt();function _o(){if(!("fetch"in ln))return!1;try{return new Headers,new Request("http://www.example.com"),new Response,!0}catch{return!1}}function Dr(e){return e&&/^function fetch\(\)\s+\{\s+\[native code\]\s+\}$/.test(e.toString())}function Me(){if(typeof EdgeRuntime=="string")return!0;if(!_o())return!1;if(Dr(ln.fetch))return!0;let e=!1,t=ln.document;if(t&&typeof t.createElement=="function")try{let n=t.createElement("iframe");n.hidden=!0,t.head.appendChild(n),n.contentWindow&&n.contentWindow.fetch&&(e=Dr(n.contentWindow.fetch)),t.head.removeChild(n)}catch(n){ot&&f.warn("Could not create sandbox iframe for pure fetch check, bailing to window.fetch: ",n)}return e}function Nr(){return"ReportingObserver"in ln}function Pe(e){let t="fetch";Q(t,e),Z(t,sc)}function sc(){Me()&&M(x,"fetch",function(e){return function(...t){let{method:n,url:r}=ac(t),i={args:t,fetchData:{method:n,url:r},startTimestamp:Date.now()};return $("fetch",{...i}),e.apply(x,t).then(o=>{let s={...i,endTimestamp:Date.now(),response:o};return $("fetch",s),o},o=>{let s={...i,endTimestamp:Date.now(),error:o};throw $("fetch",s),o})}})}function kr(e,t){return!!e&&typeof e=="object"&&!!e[t]}function So(e){return typeof e=="string"?e:e?kr(e,"url")?e.url:e.toString?e.toString():"":""}function ac(e){if(e.length===0)return{method:"GET",url:""};if(e.length===2){let[n,r]=e;return{url:So(n),method:kr(r,"method")?String(r.method).toUpperCase():"GET"}}let t=e[0];return{url:So(t),method:kr(t,"method")?String(t.method).toUpperCase():"GET"}}u();var pn=null;function wr(e){let t="error";Q(t,e),Z(t,cc)}function cc(){pn=x.onerror,x.onerror=function(e,t,n,r,i){return $("error",{column:r,error:i,line:n,msg:e,url:t}),pn&&!pn.__SENTRY_LOADER__?pn.apply(this,arguments):!1},x.onerror.__SENTRY_INSTRUMENTED__=!0}u();var fn=null;function Mr(e){let t="unhandledrejection";Q(t,e),Z(t,uc)}function uc(){fn=x.onunhandledrejection,x.onunhandledrejection=function(e){return $("unhandledrejection",e),fn&&!fn.__SENTRY_LOADER__?fn.apply(this,arguments):!0},x.onunhandledrejection.__SENTRY_INSTRUMENTED__=!0}u();u();var mn=Vt();function Eo(){let e=mn.chrome,t=e&&e.app&&e.app.runtime,n="history"in mn&&!!mn.history.pushState&&!!mn.history.replaceState;return!t&&n}var Le=x,gn;function Ue(e){let t="history";Q(t,e),Z(t,dc)}function dc(){if(!Eo())return;let e=Le.onpopstate;Le.onpopstate=function(...n){let r=Le.location.href,i=gn;if(gn=r,$("history",{from:i,to:r}),e)try{return e.apply(this,n)}catch{}};function t(n){return function(...r){let i=r.length>2?r[2]:void 0;if(i){let o=gn,s=String(i);gn=s,$("history",{from:o,to:s})}return n.apply(this,r)}}M(Le.history,"pushState",t),M(Le.history,"replaceState",t)}u();var lc=x,Ct="__sentry_xhr_v3__";function Fe(e){let t="xhr";Q(t,e),Z(t,pc)}function pc(){if(!lc.XMLHttpRequest)return;let e=XMLHttpRequest.prototype;M(e,"open",function(t){return function(...n){let r=Date.now(),i=Y(n[0])?n[0].toUpperCase():void 0,o=fc(n[1]);if(!i||!o)return t.apply(this,n);this[Ct]={method:i,url:o,request_headers:{}},i==="POST"&&o.match(/sentry_key/)&&(this.__sentry_own_request__=!0);let s=()=>{let a=this[Ct];if(a&&this.readyState===4){try{a.status_code=this.status}catch{}let c={args:[i,o],endTimestamp:Date.now(),startTimestamp:r,xhr:this};$("xhr",c)}};return"onreadystatechange"in this&&typeof this.onreadystatechange=="function"?M(this,"onreadystatechange",function(a){return function(...c){return s(),a.apply(this,c)}}):this.addEventListener("readystatechange",s),M(this,"setRequestHeader",function(a){return function(...c){let[d,l]=c,p=this[Ct];return p&&Y(d)&&Y(l)&&(p.request_headers[d.toLowerCase()]=l),a.apply(this,c)}}),t.apply(this,n)}}),M(e,"send",function(t){return function(...n){let r=this[Ct];if(!r)return t.apply(this,n);n[0]!==void 0&&(r.body=n[0]);let i={args:[r.method,r.url],startTimestamp:Date.now(),xhr:this};return $("xhr",i),t.apply(this,n)}})}function fc(e){if(Y(e))return e;try{return e.toString()}catch{}}u();u();u();function Pr(){return typeof __SENTRY_BROWSER_BUNDLE__<"u"&&!!__SENTRY_BROWSER_BUNDLE__}function mc(){return"npm"}function Lr(){return!Pr()&&Object.prototype.toString.call(typeof process<"u"?process:0)==="[object process]"}function hn(e,t){return e.require(t)}function st(e){let t;try{t=hn(module,e)}catch{}try{let{cwd:n}=hn(module,"process");t=hn(module,`${n()}/node_modules/${e}`)}catch{}return t}function gc(){return typeof window<"u"&&(!Lr()||hc())}function hc(){return x.process!==void 0&&x.process.type==="renderer"}u();function To(){let e=typeof WeakSet=="function",t=e?new WeakSet:[];function n(i){if(e)return t.has(i)?!0:(t.add(i),!1);for(let o=0;o<t.length;o++)if(t[o]===i)return!0;return t.push(i),!1}function r(i){if(e)t.delete(i);else for(let o=0;o<t.length;o++)if(t[o]===i){t.splice(o,1);break}}return[n,r]}u();function K(e,t=100,n=1/0){try{return _n("",e,t,n)}catch(r){return{ERROR:`**non-serializable** (${r})`}}}function Sn(e,t=3,n=100*1024){let r=K(e,t);return Tc(r)>n?Sn(e,t-1,n):r}function _n(e,t,n=1/0,r=1/0,i=To()){let[o,s]=i;if(t==null||["number","boolean","string"].includes(typeof t)&&!Ce(t))return t;let a=_c(e,t);if(!a.startsWith("[object "))return a;if(t.__sentry_skip_normalization__)return t;let c=typeof t.__sentry_override_normalization_depth__=="number"?t.__sentry_override_normalization_depth__:n;if(c===0)return a.replace("object ","");if(o(t))return"[Circular ~]";let d=t;if(d&&typeof d.toJSON=="function")try{let _=d.toJSON();return _n("",_,c-1,r,i)}catch{}let l=Array.isArray(t)?[]:{},p=0,m=cn(t);for(let _ in m){if(!Object.prototype.hasOwnProperty.call(m,_))continue;if(p>=r){l[_]="[MaxProperties ~]";break}let S=m[_];l[_]=_n(_,S,c-1,r,i),p++}return s(t),l}function _c(e,t){try{if(e==="domain"&&t&&typeof t=="object"&&t._events)return"[Domain]";if(e==="domainEmitter")return"[DomainEmitter]";if(typeof global<"u"&&t===global)return"[Global]";if(typeof window<"u"&&t===window)return"[Window]";if(typeof document<"u"&&t===document)return"[Document]";if(Oe(t))return"[VueViewModel]";if(hr(t))return"[SyntheticEvent]";if(typeof t=="number"&&t!==t)return"[NaN]";if(typeof t=="function")return`[Function: ${Qt(t)}]`;if(typeof t=="symbol")return`[${String(t)}]`;if(typeof t=="bigint")return`[BigInt: ${String(t)}]`;let n=Sc(t);return/^HTML(\w*)Element$/.test(n)?`[HTMLElement: ${n}]`:`[object ${n}]`}catch(n){return`**non-serializable** (${n})`}}function Sc(e){let t=Object.getPrototypeOf(e);return t?t.constructor.name:"null prototype"}function Ec(e){return~-encodeURI(e).split(/%..|./).length}function Tc(e){return Ec(JSON.stringify(e))}u();function yc(e,t){let n=0;for(let r=e.length-1;r>=0;r--){let i=e[r];i==="."?e.splice(r,1):i===".."?(e.splice(r,1),n++):n&&(e.splice(r,1),n--)}if(t)for(;n--;n)e.unshift("..");return e}var Ic=/^(\S+:\\|\/?)([\s\S]*?)((?:\.{1,2}|[^/\\]+?|)(\.[^./\\]*|))(?:[/\\]*)$/;function Io(e){let t=e.length>1024?`<truncated>${e.slice(-1024)}`:e,n=Ic.exec(t);return n?n.slice(1):[]}function Ur(...e){let t="",n=!1;for(let r=e.length-1;r>=-1&&!n;r--){let i=r>=0?e[r]:"/";i&&(t=`${i}/${t}`,n=i.charAt(0)==="/")}return t=yc(t.split("/").filter(r=>!!r),!n).join("/"),(n?"/":"")+t||"."}function yo(e){let t=0;for(;t<e.length&&e[t]==="";t++);let n=e.length-1;for(;n>=0&&e[n]==="";n--);return t>n?[]:e.slice(t,n-t+1)}function Fr(e,t){e=Ur(e).slice(1),t=Ur(t).slice(1);let n=yo(e.split("/")),r=yo(t.split("/")),i=Math.min(n.length,r.length),o=i;for(let a=0;a<i;a++)if(n[a]!==r[a]){o=a;break}let s=[];for(let a=o;a<n.length;a++)s.push("..");return s=s.concat(r.slice(o)),s.join("/")}function bc(e){let t=Io(e),n=t[0],r=t[1];return!n&&!r?".":(r&&(r=r.slice(0,r.length-1)),n+r)}function Br(e,t){let n=Io(e)[2];return t&&n.slice(t.length*-1)===t&&(n=n.slice(0,n.length-t.length)),n}u();u();var Ot;(function(e){e[e.PENDING=0]="PENDING";let n=1;e[e.RESOLVED=n]="RESOLVED";let r=2;e[e.REJECTED=r]="REJECTED"})(Ot||(Ot={}));function pt(e){return new lt(t=>{t(e)})}function Be(e){return new lt((t,n)=>{n(e)})}var lt=class e{constructor(t){e.prototype.__init.call(this),e.prototype.__init2.call(this),e.prototype.__init3.call(this),e.prototype.__init4.call(this),this._state=Ot.PENDING,this._handlers=[];try{t(this._resolve,this._reject)}catch(n){this._reject(n)}}then(t,n){return new e((r,i)=>{this._handlers.push([!1,o=>{if(!t)r(o);else try{r(t(o))}catch(s){i(s)}},o=>{if(!n)i(o);else try{r(n(o))}catch(s){i(s)}}]),this._executeHandlers()})}catch(t){return this.then(n=>n,t)}finally(t){return new e((n,r)=>{let i,o;return this.then(s=>{o=!1,i=s,t&&t()},s=>{o=!0,i=s,t&&t()}).then(()=>{if(o){r(i);return}n(i)})})}__init(){this._resolve=t=>{this._setResult(Ot.RESOLVED,t)}}__init2(){this._reject=t=>{this._setResult(Ot.REJECTED,t)}}__init3(){this._setResult=(t,n)=>{if(this._state===Ot.PENDING){if(F(n)){n.then(this._resolve,this._reject);return}this._state=t,this._value=n,this._executeHandlers()}}}__init4(){this._executeHandlers=()=>{if(this._state===Ot.PENDING)return;let t=this._handlers.slice();this._handlers=[],t.forEach(n=>{n[0]||(this._state===Ot.RESOLVED&&n[1](this._value),this._state===Ot.REJECTED&&n[2](this._value),n[0]=!0)})}}};function Hr(e){let t=[];function n(){return e===void 0||t.length<e}function r(s){return t.splice(t.indexOf(s),1)[0]}function i(s){if(!n())return Be(new j("Not adding Promise because buffer limit was reached."));let a=s();return t.indexOf(a)===-1&&t.push(a),a.then(()=>r(a)).then(null,()=>r(a).then(null,()=>{})),a}function o(s){return new lt((a,c)=>{let d=t.length;if(!d)return a(!0);let l=setTimeout(()=>{s&&s>0&&a(!1)},s);t.forEach(p=>{pt(p).then(()=>{--d||(clearTimeout(l),a(!0))},c)})})}return{$:t,add:i,drain:o}}u();u();function bo(e){let t={},n=0;for(;n<e.length;){let r=e.indexOf("=",n);if(r===-1)break;let i=e.indexOf(";",n);if(i===-1)i=e.length;else if(i<r){n=e.lastIndexOf(";",r-1)+1;continue}let o=e.slice(n,r).trim();if(t[o]===void 0){let s=e.slice(r+1,i).trim();s.charCodeAt(0)===34&&(s=s.slice(1,-1));try{t[o]=s.indexOf("%")!==-1?decodeURIComponent(s):s}catch{t[o]=s}}n=i+1}return t}u();function jt(e){if(!e)return{};let t=e.match(/^(([^:/?#]+):)?(\/\/([^/?#]*))?([^?#]*)(\?([^#]*))?(#(.*))?$/);if(!t)return{};let n=t[6]||"",r=t[8]||"";return{host:t[4],path:t[5],protocol:t[2],search:n,hash:r,relative:t[5]+n+r}}function Dt(e){return e.split(/[\?#]/,1)[0]}function ge(e){return e.split(/\\?\//).filter(t=>t.length>0&&t!==",").length}function xc(e){let{protocol:t,host:n,path:r}=e,i=n&&n.replace(/^.*@/,"[filtered]:[filtered]@").replace(/(:80)$/,"").replace(/(:443)$/,"")||"";return`${t?`${t}://`:""}${i}${r}`}var vc={ip:!1,request:!0,transaction:!0,user:!0},Ac=["cookies","data","headers","method","query_string","url"],xo=["id","username","email"];function Zt(e,t={}){let n=e.method&&e.method.toUpperCase(),r="",i="url";t.customRoute||e.route?(r=t.customRoute||`${e.baseUrl||""}${e.route&&e.route.path}`,i="route"):(e.originalUrl||e.url)&&(r=Dt(e.originalUrl||e.url||""));let o="";return t.method&&n&&(o+=n),t.method&&t.path&&(o+=" "),t.path&&r&&(o+=r),[o,i]}function Rc(e,t){switch(t){case"path":return Zt(e,{path:!0})[0];case"handler":return e.route&&e.route.stack&&e.route.stack[0]&&e.route.stack[0].name||"<anonymous>";case"methodPath":default:{let n=e._reconstructedRoute?e._reconstructedRoute:void 0;return Zt(e,{path:!0,method:!0,customRoute:n})[0]}}}function Cc(e,t){let n={};return(Array.isArray(t)?t:xo).forEach(i=>{e&&i in e&&(n[i]=e[i])}),n}function $r(e,t){let{include:n=Ac,deps:r}=t||{},i={},o=e.headers||{},s=e.method,a=o.host||e.hostname||e.host||"<no host>",c=e.protocol==="https"||e.socket&&e.socket.encrypted?"https":"http",d=e.originalUrl||e.url||"",l=d.startsWith(c)?d:`${c}://${a}${d}`;return n.forEach(p=>{switch(p){case"headers":{i.headers=o,n.includes("cookies")||delete i.headers.cookie;break}case"method":{i.method=s;break}case"url":{i.url=l;break}case"cookies":{i.cookies=e.cookies||o.cookie&&bo(o.cookie)||{};break}case"query_string":{i.query_string=Oc(e,r);break}case"data":{if(s==="GET"||s==="HEAD")break;e.body!==void 0&&(i.data=Y(e.body)?e.body:JSON.stringify(K(e.body)));break}default:({}).hasOwnProperty.call(e,p)&&(i[p]=e[p])}}),i}function Gr(e,t,n){let r={...vc,...n&&n.include};if(r.request){let i=Array.isArray(r.request)?$r(t,{include:r.request,deps:n&&n.deps}):$r(t,{deps:n&&n.deps});e.request={...e.request,...i}}if(r.user){let i=t.user&&J(t.user)?Cc(t.user,r.user):{};Object.keys(i).length&&(e.user={...e.user,...i})}if(r.ip){let i=t.ip||t.socket&&t.socket.remoteAddress;i&&(e.user={...e.user,ip_address:i})}return r.transaction&&!e.transaction&&(e.transaction=Rc(t,r.transaction)),e}function Oc(e,t){let n=e.originalUrl||e.url||"";if(n){n.startsWith("/")&&(n=`http://dogs.are.great${n}`);try{return e.query||typeof URL<"u"&&new URL(n).search.slice(1)||t&&t.url&&t.url.parse(n).query||void 0}catch{return}}}u();var vo=["fatal","error","warning","log","info","debug"];function jr(e){return e==="warn"?"warning":vo.includes(e)?e:"log"}u();var Ao=1e3;function _t(){return Date.now()/Ao}function Dc(){let{performance:e}=x;if(!e||!e.now)return _t;let t=Date.now()-e.now(),n=e.timeOrigin==null?t:e.timeOrigin;return()=>(n+e.now())/Ao}var W=Dc();var He,B=(()=>{let{performance:e}=x;if(!e||!e.now){He="none";return}let t=3600*1e3,n=e.now(),r=Date.now(),i=e.timeOrigin?Math.abs(e.timeOrigin+n-r):t,o=i<t,s=e.timing&&e.timing.navigationStart,c=typeof s=="number"?Math.abs(s+n-r):t,d=c<t;return o||d?i<=c?(He="timeOrigin",e.timeOrigin):(He="navigationStart",s):(He="dateNow",r)})();u();u();var he="baggage",Wr="sentry-",Co=/^sentry-/,Oo=8192;function En(e){if(!Y(e)&&!Array.isArray(e))return;let t={};if(Array.isArray(e))t=e.reduce((r,i)=>{let o=Ro(i);for(let s of Object.keys(o))r[s]=o[s];return r},{});else{if(!e)return;t=Ro(e)}let n=Object.entries(t).reduce((r,[i,o])=>{if(i.match(Co)){let s=i.slice(Wr.length);r[s]=o}return r},{});if(Object.keys(n).length>0)return n}function $e(e){if(!e)return;let t=Object.entries(e).reduce((n,[r,i])=>(i&&(n[`${Wr}${r}`]=i),n),{});return Nc(t)}function Ro(e){return e.split(",").map(t=>t.split("=").map(n=>decodeURIComponent(n.trim()))).reduce((t,[n,r])=>(t[n]=r,t),{})}function Nc(e){if(Object.keys(e).length!==0)return Object.entries(e).reduce((t,[n,r],i)=>{let o=`${encodeURIComponent(n)}=${encodeURIComponent(r)}`,s=i===0?o:`${t},${o}`;return s.length>Oo?(ot&&f.warn(`Not adding key: ${n} with val: ${r} to baggage header due to exceeding baggage size limits.`),t):s},"")}var Do=new RegExp("^[ \\t]*([0-9a-f]{32})?-?([0-9a-f]{16})?-?([01])?[ \\t]*$");function Ge(e){if(!e)return;let t=e.match(Do);if(!t)return;let n;return t[3]==="1"?n=!0:t[3]==="0"&&(n=!1),{traceId:t[1],parentSampled:n,parentSpanId:t[2]}}function qr(e,t){let n=Ge(e),r=En(t),{traceId:i,parentSpanId:o,parentSampled:s}=n||{};return n?{traceparentData:n,dynamicSamplingContext:r||{},propagationContext:{traceId:i||O(),parentSpanId:o||O().substring(16),spanId:O().substring(16),sampled:s,dsc:r||{}}}:{traceparentData:n,dynamicSamplingContext:void 0,propagationContext:{traceId:i||O(),spanId:O().substring(16)}}}function je(e,t){let n=Ge(e),r=En(t),{traceId:i,parentSpanId:o,parentSampled:s}=n||{};return n?{traceId:i||O(),parentSpanId:o||O().substring(16),spanId:O().substring(16),sampled:s,dsc:r||{}}:{traceId:i||O(),spanId:O().substring(16)}}function te(e=O(),t=O().substring(16),n){let r="";return n!==void 0&&(r=n?"-1":"-0"),`${e}-${t}${r}`}u();function q(e,t=[]){return[e,t]}function Yr(e,t){let[n,r]=e;return[n,[...r,t]]}function Nt(e,t){let n=e[1];for(let r of n){let i=r[0].type;if(t(r,i))return!0}return!1}function Jr(e,t){return Nt(e,(n,r)=>t.includes(r))}function zr(e,t){return(t||new TextEncoder).encode(e)}function Kr(e,t){let[n,r]=e,i=JSON.stringify(n);function o(s){typeof i=="string"?i=typeof s=="string"?i+s:[zr(i,t),s]:i.push(typeof s=="string"?zr(s,t):s)}for(let s of r){let[a,c]=s;if(o(`
8
8
  ${JSON.stringify(a)}
9
- `),typeof c=="string"||c instanceof Uint8Array)o(c);else{let d;try{d=JSON.stringify(c)}catch{d=JSON.stringify(K(c))}o(d)}}return typeof i=="string"?i:kc(i)}function kc(e){let t=e.reduce((i,o)=>i+o.length,0),n=new Uint8Array(t),r=0;for(let i of e)n.set(i,r),r+=i.length;return n}function wc(e,t,n){let r=typeof e=="string"?t.encode(e):e;function i(c){let d=r.subarray(0,c);return r=r.subarray(c+1),d}function o(){let c=r.indexOf(10);return c<0&&(c=r.length),JSON.parse(n.decode(i(c)))}let s=o(),a=[];for(;r.length;){let c=o(),d=typeof c.length=="number"?c.length:void 0;a.push([c,d?i(d):o()])}return[s,a]}function Vr(e,t){let n=typeof e.data=="string"?zr(e.data,t):e.data;return[k({type:"attachment",length:n.length,filename:e.filename,content_type:e.contentType,attachment_type:e.attachmentType}),n]}var Mc={session:"session",sessions:"session",attachment:"attachment",transaction:"transaction",event:"error",client_report:"internal",user_report:"default",profile:"profile",replay_event:"replay",replay_recording:"replay",check_in:"monitor",feedback:"feedback",span:"span",statsd:"metric_bucket"};function Tn(e){return Mc[e]}function yn(e){if(!e||!e.sdk)return;let{name:t,version:n}=e.sdk;return{name:t,version:n}}function Xr(e,t,n,r){let i=e.sdkProcessingMetadata&&e.sdkProcessingMetadata.dynamicSamplingContext;return{event_id:e.event_id,sent_at:new Date().toISOString(),...t&&{sdk:t},...!!n&&r&&{dsn:it(r)},...i&&{trace:k({...i})}}}u();function Pc(e,t,n){let r=[{type:"client_report"},{timestamp:n||_t(),discarded_events:e}];return q(t?{dsn:t}:{},[r])}u();function In(e,t=Date.now()){let n=parseInt(`${e}`,10);if(!isNaN(n))return n*1e3;let r=Date.parse(`${e}`);return isNaN(r)?6e4:r-t}function No(e,t){return e[t]||e.all||0}function Qr(e,t,n=Date.now()){return No(e,t)>n}function Zr(e,{statusCode:t,headers:n},r=Date.now()){let i={...e},o=n&&n["x-sentry-rate-limits"],s=n&&n["retry-after"];if(o)for(let a of o.trim().split(",")){let[c,d,,,l]=a.split(":",5),p=parseInt(c,10),m=(isNaN(p)?60:p)*1e3;if(!d)i.all=r+m;else for(let _ of d.split(";"))_==="metric_bucket"?(!l||l.split(";").includes("custom"))&&(i[_]=r+m):i[_]=r+m}else s?i.all=r+In(s,r):t===429&&(i.all=r+60*1e3);return i}u();function ti(e,t){return e(t.stack||"",1)}function bn(e,t){let n={type:t.name||t.constructor.name,value:t.message},r=ti(e,t);return r.length&&(n.stacktrace={frames:r}),n}function Lc(e){if("name"in e&&typeof e.name=="string"){let t=`'${e.name}' captured as exception`;return"message"in e&&typeof e.message=="string"&&(t+=` with message '${e.message}'`),t}else return"message"in e&&typeof e.message=="string"?e.message:`Object captured as exception with keys: ${br(e)}`}function ei(e,t,n,r){let i=typeof e=="function"?e().getClient():e,o=n,a=r&&r.data&&r.data.mechanism||{handled:!0,type:"generic"},c;if(!mt(n)){if(J(n)){let l=i&&i.getOptions().normalizeDepth;c={__serialized__:Sn(n,l)};let p=Lc(n);o=r&&r.syntheticException||new Error(p),o.message=p}else o=r&&r.syntheticException||new Error(n),o.message=n;a.synthetic=!0}let d={exception:{values:[bn(t,o)]}};return c&&(d.extra=c),Ar(d,void 0,void 0),Rt(d,a),{...d,event_id:r&&r.event_id}}function ni(e,t,n="info",r,i){let o={event_id:r&&r.event_id,level:n};if(i&&r&&r.syntheticException){let s=ti(e,r.syntheticException);s.length&&(o.exception={values:[{value:t,stacktrace:{frames:s}}]})}if(le(t)){let{__sentry_template_string__:s,__sentry_template_values__:a}=t;return o.logentry={message:s,params:a},o}return o.message=t,o}u();var ri=class{constructor(t){this._maxSize=t,this._cache=new Map}get size(){return this._cache.size}get(t){let n=this._cache.get(t);if(n!==void 0)return this._cache.delete(t),this._cache.set(t,n),n}set(t,n){this._cache.size>=this._maxSize&&this._cache.delete(this._cache.keys().next().value),this._cache.set(t,n)}remove(t){let n=this._cache.get(t);return n&&this._cache.delete(t),n}clear(){this._cache.clear()}keys(){return Array.from(this._cache.keys())}values(){let t=[];return this._cache.forEach(n=>t.push(n)),t}};u();function Uc(e,t){return e??t()}u();function A(e){let t,n=e[0],r=1;for(;r<e.length;){let i=e[r],o=e[r+1];if(r+=2,(i==="optionalAccess"||i==="optionalCall")&&n==null)return;i==="access"||i==="optionalAccess"?(t=n,n=o(n)):(i==="call"||i==="optionalCall")&&(n=o((...s)=>n.call(t,...s)),t=void 0)}return n}u();function Fc(e){let t=A(e);return t??!0}u();var E=typeof __SENTRY_DEBUG__>"u"||__SENTRY_DEBUG__;function We(){return Ne("globalEventProcessors",()=>[])}function ii(e){We().push(e)}function ee(e,t,n,r=0){return new lt((i,o)=>{let s=e[r];if(t===null||typeof s!="function")i(t);else{let a=s({...t},n);E&&s.id&&a===null&&f.log(`Event processor "${s.id}" dropped event`),F(a)?a.then(c=>ee(e,c,n,r+1).then(i)).then(null,o):ee(e,a,n,r+1).then(i).then(null,o)}})}u();u();var kt="production";u();u();u();function xn(e){let t=W(),n={sid:O(),init:!0,timestamp:t,started:t,duration:0,status:"ok",errors:0,ignoreDuration:!1,toJSON:()=>Bc(n)};return e&&ft(n,e),n}function ft(e,t={}){if(t.user&&(!e.ipAddress&&t.user.ip_address&&(e.ipAddress=t.user.ip_address),!e.did&&!t.did&&(e.did=t.user.id||t.user.email||t.user.username)),e.timestamp=t.timestamp||W(),t.abnormal_mechanism&&(e.abnormal_mechanism=t.abnormal_mechanism),t.ignoreDuration&&(e.ignoreDuration=t.ignoreDuration),t.sid&&(e.sid=t.sid.length===32?t.sid:O()),t.init!==void 0&&(e.init=t.init),!e.did&&t.did&&(e.did=`${t.did}`),typeof t.started=="number"&&(e.started=t.started),e.ignoreDuration)e.duration=void 0;else if(typeof t.duration=="number")e.duration=t.duration;else{let n=e.timestamp-e.started;e.duration=n>=0?n:0}t.release&&(e.release=t.release),t.environment&&(e.environment=t.environment),!e.ipAddress&&t.ipAddress&&(e.ipAddress=t.ipAddress),!e.userAgent&&t.userAgent&&(e.userAgent=t.userAgent),typeof t.errors=="number"&&(e.errors=t.errors),t.status&&(e.status=t.status)}function vn(e,t){let n={};t?n={status:t}:e.status==="ok"&&(n={status:"exited"}),ft(e,n)}function Bc(e){return k({sid:`${e.sid}`,init:e.init,started:new Date(e.started*1e3).toISOString(),timestamp:new Date(e.timestamp*1e3).toISOString(),status:e.status,errors:e.errors,did:typeof e.did=="number"||typeof e.did=="string"?`${e.did}`:void 0,duration:e.duration,abnormal_mechanism:e.abnormal_mechanism,attrs:{release:e.release,environment:e.environment,ip_address:e.ipAddress,user_agent:e.userAgent}})}u();u();u();function wt(e){return e.transaction}u();var wo=0,oi=1;function Mt(e){let{spanId:t,traceId:n}=e.spanContext(),{data:r,op:i,parent_span_id:o,status:s,tags:a,origin:c}=R(e);return k({data:r,op:i,parent_span_id:o,span_id:t,status:s,tags:a,trace_id:n,origin:c})}function Pt(e){let{traceId:t,spanId:n}=e.spanContext(),r=_e(e);return te(t,n,r)}function Wt(e){return typeof e=="number"?ko(e):Array.isArray(e)?e[0]+e[1]/1e9:e instanceof Date?ko(e.getTime()):W()}function ko(e){return e>9999999999?e/1e3:e}function R(e){return Hc(e)?e.getSpanJSON():typeof e.toJSON=="function"?e.toJSON():{}}function Hc(e){return typeof e.getSpanJSON=="function"}function _e(e){let{traceFlags:t}=e.spanContext();return!!(t&oi)}function St(e,t,n){let r=t.getOptions(),{publicKey:i}=t.getDsn()||{},{segment:o}=n&&n.getUser()||{},s=k({environment:r.environment||kt,release:r.release,user_segment:o,public_key:i,trace_id:e});return t.emit&&t.emit("createDsc",s),s}function tt(e){let t=C();if(!t)return{};let n=St(R(e).trace_id||"",t,L()),r=wt(e);if(!r)return n;let i=r&&r._frozenDynamicSamplingContext;if(i)return i;let{sampleRate:o,source:s}=r.metadata;o!=null&&(n.sample_rate=`${o}`);let a=R(r);return s&&s!=="url"&&(n.transaction=a.description),n.sampled=String(_e(r)),t.emit&&t.emit("createDsc",n),n}function ze(e,t){let{fingerprint:n,span:r,breadcrumbs:i,sdkProcessingMetadata:o}=t;$c(e,t),r&&Wc(e,r),qc(e,n),Gc(e,i),jc(e,o)}function An(e,t){let{extra:n,tags:r,user:i,contexts:o,level:s,sdkProcessingMetadata:a,breadcrumbs:c,fingerprint:d,eventProcessors:l,attachments:p,propagationContext:m,transactionName:_,span:S}=t;qe(e,"extra",n),qe(e,"tags",r),qe(e,"user",i),qe(e,"contexts",o),qe(e,"sdkProcessingMetadata",a),s&&(e.level=s),_&&(e.transactionName=_),S&&(e.span=S),c.length&&(e.breadcrumbs=[...e.breadcrumbs,...c]),d.length&&(e.fingerprint=[...e.fingerprint,...d]),l.length&&(e.eventProcessors=[...e.eventProcessors,...l]),p.length&&(e.attachments=[...e.attachments,...p]),e.propagationContext={...e.propagationContext,...m}}function qe(e,t,n){if(n&&Object.keys(n).length){e[t]={...e[t]};for(let r in n)Object.prototype.hasOwnProperty.call(n,r)&&(e[t][r]=n[r])}}function $c(e,t){let{extra:n,tags:r,user:i,contexts:o,level:s,transactionName:a}=t,c=k(n);c&&Object.keys(c).length&&(e.extra={...c,...e.extra});let d=k(r);d&&Object.keys(d).length&&(e.tags={...d,...e.tags});let l=k(i);l&&Object.keys(l).length&&(e.user={...l,...e.user});let p=k(o);p&&Object.keys(p).length&&(e.contexts={...p,...e.contexts}),s&&(e.level=s),a&&(e.transaction=a)}function Gc(e,t){let n=[...e.breadcrumbs||[],...t];e.breadcrumbs=n.length?n:void 0}function jc(e,t){e.sdkProcessingMetadata={...e.sdkProcessingMetadata,...t}}function Wc(e,t){e.contexts={trace:Mt(t),...e.contexts};let n=wt(t);if(n){e.sdkProcessingMetadata={dynamicSamplingContext:tt(t),...e.sdkProcessingMetadata};let r=R(n).description;r&&(e.tags={transaction:r,...e.tags})}}function qc(e,t){e.fingerprint=e.fingerprint?Gt(e.fingerprint):[],t&&(e.fingerprint=e.fingerprint.concat(t)),e.fingerprint&&!e.fingerprint.length&&delete e.fingerprint}var zc=100,si,Et=class e{constructor(){this._notifyingListeners=!1,this._scopeListeners=[],this._eventProcessors=[],this._breadcrumbs=[],this._attachments=[],this._user={},this._tags={},this._extra={},this._contexts={},this._sdkProcessingMetadata={},this._propagationContext=Mo()}static clone(t){return t?t.clone():new e}clone(){let t=new e;return t._breadcrumbs=[...this._breadcrumbs],t._tags={...this._tags},t._extra={...this._extra},t._contexts={...this._contexts},t._user=this._user,t._level=this._level,t._span=this._span,t._session=this._session,t._transactionName=this._transactionName,t._fingerprint=this._fingerprint,t._eventProcessors=[...this._eventProcessors],t._requestSession=this._requestSession,t._attachments=[...this._attachments],t._sdkProcessingMetadata={...this._sdkProcessingMetadata},t._propagationContext={...this._propagationContext},t._client=this._client,t}setClient(t){this._client=t}getClient(){return this._client}addScopeListener(t){this._scopeListeners.push(t)}addEventProcessor(t){return this._eventProcessors.push(t),this}setUser(t){return this._user=t||{email:void 0,id:void 0,ip_address:void 0,segment:void 0,username:void 0},this._session&&ft(this._session,{user:t}),this._notifyScopeListeners(),this}getUser(){return this._user}getRequestSession(){return this._requestSession}setRequestSession(t){return this._requestSession=t,this}setTags(t){return this._tags={...this._tags,...t},this._notifyScopeListeners(),this}setTag(t,n){return this._tags={...this._tags,[t]:n},this._notifyScopeListeners(),this}setExtras(t){return this._extra={...this._extra,...t},this._notifyScopeListeners(),this}setExtra(t,n){return this._extra={...this._extra,[t]:n},this._notifyScopeListeners(),this}setFingerprint(t){return this._fingerprint=t,this._notifyScopeListeners(),this}setLevel(t){return this._level=t,this._notifyScopeListeners(),this}setTransactionName(t){return this._transactionName=t,this._notifyScopeListeners(),this}setContext(t,n){return n===null?delete this._contexts[t]:this._contexts[t]=n,this._notifyScopeListeners(),this}setSpan(t){return this._span=t,this._notifyScopeListeners(),this}getSpan(){return this._span}getTransaction(){let t=this._span;return t&&t.transaction}setSession(t){return t?this._session=t:delete this._session,this._notifyScopeListeners(),this}getSession(){return this._session}update(t){if(!t)return this;let n=typeof t=="function"?t(this):t;if(n instanceof e){let r=n.getScopeData();this._tags={...this._tags,...r.tags},this._extra={...this._extra,...r.extra},this._contexts={...this._contexts,...r.contexts},r.user&&Object.keys(r.user).length&&(this._user=r.user),r.level&&(this._level=r.level),r.fingerprint.length&&(this._fingerprint=r.fingerprint),n.getRequestSession()&&(this._requestSession=n.getRequestSession()),r.propagationContext&&(this._propagationContext=r.propagationContext)}else if(J(n)){let r=t;this._tags={...this._tags,...r.tags},this._extra={...this._extra,...r.extra},this._contexts={...this._contexts,...r.contexts},r.user&&(this._user=r.user),r.level&&(this._level=r.level),r.fingerprint&&(this._fingerprint=r.fingerprint),r.requestSession&&(this._requestSession=r.requestSession),r.propagationContext&&(this._propagationContext=r.propagationContext)}return this}clear(){return this._breadcrumbs=[],this._tags={},this._extra={},this._user={},this._contexts={},this._level=void 0,this._transactionName=void 0,this._fingerprint=void 0,this._requestSession=void 0,this._span=void 0,this._session=void 0,this._notifyScopeListeners(),this._attachments=[],this._propagationContext=Mo(),this}addBreadcrumb(t,n){let r=typeof n=="number"?n:zc;if(r<=0)return this;let i={timestamp:_t(),...t},o=this._breadcrumbs;return o.push(i),this._breadcrumbs=o.length>r?o.slice(-r):o,this._notifyScopeListeners(),this}getLastBreadcrumb(){return this._breadcrumbs[this._breadcrumbs.length-1]}clearBreadcrumbs(){return this._breadcrumbs=[],this._notifyScopeListeners(),this}addAttachment(t){return this._attachments.push(t),this}getAttachments(){return this.getScopeData().attachments}clearAttachments(){return this._attachments=[],this}getScopeData(){let{_breadcrumbs:t,_attachments:n,_contexts:r,_tags:i,_extra:o,_user:s,_level:a,_fingerprint:c,_eventProcessors:d,_propagationContext:l,_sdkProcessingMetadata:p,_transactionName:m,_span:_}=this;return{breadcrumbs:t,attachments:n,contexts:r,tags:i,extra:o,user:s,level:a,fingerprint:c||[],eventProcessors:d,propagationContext:l,sdkProcessingMetadata:p,transactionName:m,span:_}}applyToEvent(t,n={},r=[]){ze(t,this.getScopeData());let i=[...r,...We(),...this._eventProcessors];return ee(i,t,n)}setSDKProcessingMetadata(t){return this._sdkProcessingMetadata={...this._sdkProcessingMetadata,...t},this}setPropagationContext(t){return this._propagationContext=t,this}getPropagationContext(){return this._propagationContext}captureException(t,n){let r=n&&n.event_id?n.event_id:O();if(!this._client)return f.warn("No client configured on scope - will not capture exception!"),r;let i=new Error("Sentry syntheticException");return this._client.captureException(t,{originalException:t,syntheticException:i,...n,event_id:r},this),r}captureMessage(t,n,r){let i=r&&r.event_id?r.event_id:O();if(!this._client)return f.warn("No client configured on scope - will not capture message!"),i;let o=new Error(t);return this._client.captureMessage(t,n,{originalException:t,syntheticException:o,...r,event_id:i},this),i}captureEvent(t,n){let r=n&&n.event_id?n.event_id:O();return this._client?(this._client.captureEvent(t,{...n,event_id:r},this),r):(f.warn("No client configured on scope - will not capture event!"),r)}_notifyScopeListeners(){this._notifyingListeners||(this._notifyingListeners=!0,this._scopeListeners.forEach(t=>{t(this)}),this._notifyingListeners=!1)}};function ai(){return si||(si=new Et),si}function Mo(){return{traceId:O(),spanId:O().substring(16)}}u();var Se="7.114.0";var Po=parseFloat(Se),Yc=100,Ye=class{constructor(t,n,r,i=Po){this._version=i;let o;n?o=n:(o=new Et,o.setClient(t));let s;r?s=r:(s=new Et,s.setClient(t)),this._stack=[{scope:o}],t&&this.bindClient(t),this._isolationScope=s}isOlderThan(t){return this._version<t}bindClient(t){let n=this.getStackTop();n.client=t,n.scope.setClient(t),t&&t.setupIntegrations&&t.setupIntegrations()}pushScope(){let t=this.getScope().clone();return this.getStack().push({client:this.getClient(),scope:t}),t}popScope(){return this.getStack().length<=1?!1:!!this.getStack().pop()}withScope(t){let n=this.pushScope(),r;try{r=t(n)}catch(i){throw this.popScope(),i}return F(r)?r.then(i=>(this.popScope(),i),i=>{throw this.popScope(),i}):(this.popScope(),r)}getClient(){return this.getStackTop().client}getScope(){return this.getStackTop().scope}getIsolationScope(){return this._isolationScope}getStack(){return this._stack}getStackTop(){return this._stack[this._stack.length-1]}captureException(t,n){let r=this._lastEventId=n&&n.event_id?n.event_id:O(),i=new Error("Sentry syntheticException");return this.getScope().captureException(t,{originalException:t,syntheticException:i,...n,event_id:r}),r}captureMessage(t,n,r){let i=this._lastEventId=r&&r.event_id?r.event_id:O(),o=new Error(t);return this.getScope().captureMessage(t,n,{originalException:t,syntheticException:o,...r,event_id:i}),i}captureEvent(t,n){let r=n&&n.event_id?n.event_id:O();return t.type||(this._lastEventId=r),this.getScope().captureEvent(t,{...n,event_id:r}),r}lastEventId(){return this._lastEventId}addBreadcrumb(t,n){let{scope:r,client:i}=this.getStackTop();if(!i)return;let{beforeBreadcrumb:o=null,maxBreadcrumbs:s=Yc}=i.getOptions&&i.getOptions()||{};if(s<=0)return;let c={timestamp:_t(),...t},d=o?ht(()=>o(c,n)):c;d!==null&&(i.emit&&i.emit("beforeAddBreadcrumb",d,n),r.addBreadcrumb(d,s))}setUser(t){this.getScope().setUser(t),this.getIsolationScope().setUser(t)}setTags(t){this.getScope().setTags(t),this.getIsolationScope().setTags(t)}setExtras(t){this.getScope().setExtras(t),this.getIsolationScope().setExtras(t)}setTag(t,n){this.getScope().setTag(t,n),this.getIsolationScope().setTag(t,n)}setExtra(t,n){this.getScope().setExtra(t,n),this.getIsolationScope().setExtra(t,n)}setContext(t,n){this.getScope().setContext(t,n),this.getIsolationScope().setContext(t,n)}configureScope(t){let{scope:n,client:r}=this.getStackTop();r&&t(n)}run(t){let n=ci(this);try{t(this)}finally{ci(n)}}getIntegration(t){let n=this.getClient();if(!n)return null;try{return n.getIntegration(t)}catch{return E&&f.warn(`Cannot retrieve integration ${t.id} from the current Hub`),null}}startTransaction(t,n){let r=this._callExtensionMethod("startTransaction",t,n);return E&&!r&&(this.getClient()?f.warn(`Tracing extension 'startTransaction' has not been added. Call 'addTracingExtensions' before calling 'init':
9
+ `),typeof c=="string"||c instanceof Uint8Array)o(c);else{let d;try{d=JSON.stringify(c)}catch{d=JSON.stringify(K(c))}o(d)}}return typeof i=="string"?i:kc(i)}function kc(e){let t=e.reduce((i,o)=>i+o.length,0),n=new Uint8Array(t),r=0;for(let i of e)n.set(i,r),r+=i.length;return n}function wc(e,t,n){let r=typeof e=="string"?t.encode(e):e;function i(c){let d=r.subarray(0,c);return r=r.subarray(c+1),d}function o(){let c=r.indexOf(10);return c<0&&(c=r.length),JSON.parse(n.decode(i(c)))}let s=o(),a=[];for(;r.length;){let c=o(),d=typeof c.length=="number"?c.length:void 0;a.push([c,d?i(d):o()])}return[s,a]}function Vr(e,t){let n=typeof e.data=="string"?zr(e.data,t):e.data;return[k({type:"attachment",length:n.length,filename:e.filename,content_type:e.contentType,attachment_type:e.attachmentType}),n]}var Mc={session:"session",sessions:"session",attachment:"attachment",transaction:"transaction",event:"error",client_report:"internal",user_report:"default",profile:"profile",replay_event:"replay",replay_recording:"replay",check_in:"monitor",feedback:"feedback",span:"span",statsd:"metric_bucket"};function Tn(e){return Mc[e]}function yn(e){if(!e||!e.sdk)return;let{name:t,version:n}=e.sdk;return{name:t,version:n}}function Xr(e,t,n,r){let i=e.sdkProcessingMetadata&&e.sdkProcessingMetadata.dynamicSamplingContext;return{event_id:e.event_id,sent_at:new Date().toISOString(),...t&&{sdk:t},...!!n&&r&&{dsn:it(r)},...i&&{trace:k({...i})}}}u();function Pc(e,t,n){let r=[{type:"client_report"},{timestamp:n||_t(),discarded_events:e}];return q(t?{dsn:t}:{},[r])}u();function In(e,t=Date.now()){let n=parseInt(`${e}`,10);if(!isNaN(n))return n*1e3;let r=Date.parse(`${e}`);return isNaN(r)?6e4:r-t}function No(e,t){return e[t]||e.all||0}function Qr(e,t,n=Date.now()){return No(e,t)>n}function Zr(e,{statusCode:t,headers:n},r=Date.now()){let i={...e},o=n&&n["x-sentry-rate-limits"],s=n&&n["retry-after"];if(o)for(let a of o.trim().split(",")){let[c,d,,,l]=a.split(":",5),p=parseInt(c,10),m=(isNaN(p)?60:p)*1e3;if(!d)i.all=r+m;else for(let _ of d.split(";"))_==="metric_bucket"?(!l||l.split(";").includes("custom"))&&(i[_]=r+m):i[_]=r+m}else s?i.all=r+In(s,r):t===429&&(i.all=r+60*1e3);return i}u();function ti(e,t){return e(t.stack||"",1)}function bn(e,t){let n={type:t.name||t.constructor.name,value:t.message},r=ti(e,t);return r.length&&(n.stacktrace={frames:r}),n}function Lc(e){if("name"in e&&typeof e.name=="string"){let t=`'${e.name}' captured as exception`;return"message"in e&&typeof e.message=="string"&&(t+=` with message '${e.message}'`),t}else return"message"in e&&typeof e.message=="string"?e.message:`Object captured as exception with keys: ${br(e)}`}function ei(e,t,n,r){let i=typeof e=="function"?e().getClient():e,o=n,a=r&&r.data&&r.data.mechanism||{handled:!0,type:"generic"},c;if(!mt(n)){if(J(n)){let l=i&&i.getOptions().normalizeDepth;c={__serialized__:Sn(n,l)};let p=Lc(n);o=r&&r.syntheticException||new Error(p),o.message=p}else o=r&&r.syntheticException||new Error(n),o.message=n;a.synthetic=!0}let d={exception:{values:[bn(t,o)]}};return c&&(d.extra=c),Ar(d,void 0,void 0),Rt(d,a),{...d,event_id:r&&r.event_id}}function ni(e,t,n="info",r,i){let o={event_id:r&&r.event_id,level:n};if(i&&r&&r.syntheticException){let s=ti(e,r.syntheticException);s.length&&(o.exception={values:[{value:t,stacktrace:{frames:s}}]})}if(le(t)){let{__sentry_template_string__:s,__sentry_template_values__:a}=t;return o.logentry={message:s,params:a},o}return o.message=t,o}u();var ri=class{constructor(t){this._maxSize=t,this._cache=new Map}get size(){return this._cache.size}get(t){let n=this._cache.get(t);if(n!==void 0)return this._cache.delete(t),this._cache.set(t,n),n}set(t,n){this._cache.size>=this._maxSize&&this._cache.delete(this._cache.keys().next().value),this._cache.set(t,n)}remove(t){let n=this._cache.get(t);return n&&this._cache.delete(t),n}clear(){this._cache.clear()}keys(){return Array.from(this._cache.keys())}values(){let t=[];return this._cache.forEach(n=>t.push(n)),t}};u();function Uc(e,t){return e??t()}u();function A(e){let t,n=e[0],r=1;for(;r<e.length;){let i=e[r],o=e[r+1];if(r+=2,(i==="optionalAccess"||i==="optionalCall")&&n==null)return;i==="access"||i==="optionalAccess"?(t=n,n=o(n)):(i==="call"||i==="optionalCall")&&(n=o((...s)=>n.call(t,...s)),t=void 0)}return n}u();function Fc(e){let t=A(e);return t??!0}u();var E=typeof __SENTRY_DEBUG__>"u"||__SENTRY_DEBUG__;function We(){return Ne("globalEventProcessors",()=>[])}function ii(e){We().push(e)}function ee(e,t,n,r=0){return new lt((i,o)=>{let s=e[r];if(t===null||typeof s!="function")i(t);else{let a=s({...t},n);E&&s.id&&a===null&&f.log(`Event processor "${s.id}" dropped event`),F(a)?a.then(c=>ee(e,c,n,r+1).then(i)).then(null,o):ee(e,a,n,r+1).then(i).then(null,o)}})}u();u();var kt="production";u();u();u();function xn(e){let t=W(),n={sid:O(),init:!0,timestamp:t,started:t,duration:0,status:"ok",errors:0,ignoreDuration:!1,toJSON:()=>Bc(n)};return e&&ft(n,e),n}function ft(e,t={}){if(t.user&&(!e.ipAddress&&t.user.ip_address&&(e.ipAddress=t.user.ip_address),!e.did&&!t.did&&(e.did=t.user.id||t.user.email||t.user.username)),e.timestamp=t.timestamp||W(),t.abnormal_mechanism&&(e.abnormal_mechanism=t.abnormal_mechanism),t.ignoreDuration&&(e.ignoreDuration=t.ignoreDuration),t.sid&&(e.sid=t.sid.length===32?t.sid:O()),t.init!==void 0&&(e.init=t.init),!e.did&&t.did&&(e.did=`${t.did}`),typeof t.started=="number"&&(e.started=t.started),e.ignoreDuration)e.duration=void 0;else if(typeof t.duration=="number")e.duration=t.duration;else{let n=e.timestamp-e.started;e.duration=n>=0?n:0}t.release&&(e.release=t.release),t.environment&&(e.environment=t.environment),!e.ipAddress&&t.ipAddress&&(e.ipAddress=t.ipAddress),!e.userAgent&&t.userAgent&&(e.userAgent=t.userAgent),typeof t.errors=="number"&&(e.errors=t.errors),t.status&&(e.status=t.status)}function vn(e,t){let n={};t?n={status:t}:e.status==="ok"&&(n={status:"exited"}),ft(e,n)}function Bc(e){return k({sid:`${e.sid}`,init:e.init,started:new Date(e.started*1e3).toISOString(),timestamp:new Date(e.timestamp*1e3).toISOString(),status:e.status,errors:e.errors,did:typeof e.did=="number"||typeof e.did=="string"?`${e.did}`:void 0,duration:e.duration,abnormal_mechanism:e.abnormal_mechanism,attrs:{release:e.release,environment:e.environment,ip_address:e.ipAddress,user_agent:e.userAgent}})}u();u();u();function wt(e){return e.transaction}u();var wo=0,oi=1;function Mt(e){let{spanId:t,traceId:n}=e.spanContext(),{data:r,op:i,parent_span_id:o,status:s,tags:a,origin:c}=R(e);return k({data:r,op:i,parent_span_id:o,span_id:t,status:s,tags:a,trace_id:n,origin:c})}function Pt(e){let{traceId:t,spanId:n}=e.spanContext(),r=_e(e);return te(t,n,r)}function Wt(e){return typeof e=="number"?ko(e):Array.isArray(e)?e[0]+e[1]/1e9:e instanceof Date?ko(e.getTime()):W()}function ko(e){return e>9999999999?e/1e3:e}function R(e){return Hc(e)?e.getSpanJSON():typeof e.toJSON=="function"?e.toJSON():{}}function Hc(e){return typeof e.getSpanJSON=="function"}function _e(e){let{traceFlags:t}=e.spanContext();return!!(t&oi)}function St(e,t,n){let r=t.getOptions(),{publicKey:i}=t.getDsn()||{},{segment:o}=n&&n.getUser()||{},s=k({environment:r.environment||kt,release:r.release,user_segment:o,public_key:i,trace_id:e});return t.emit&&t.emit("createDsc",s),s}function tt(e){let t=C();if(!t)return{};let n=St(R(e).trace_id||"",t,L()),r=wt(e);if(!r)return n;let i=r&&r._frozenDynamicSamplingContext;if(i)return i;let{sampleRate:o,source:s}=r.metadata;o!=null&&(n.sample_rate=`${o}`);let a=R(r);return s&&s!=="url"&&(n.transaction=a.description),n.sampled=String(_e(r)),t.emit&&t.emit("createDsc",n),n}function ze(e,t){let{fingerprint:n,span:r,breadcrumbs:i,sdkProcessingMetadata:o}=t;$c(e,t),r&&Wc(e,r),qc(e,n),Gc(e,i),jc(e,o)}function An(e,t){let{extra:n,tags:r,user:i,contexts:o,level:s,sdkProcessingMetadata:a,breadcrumbs:c,fingerprint:d,eventProcessors:l,attachments:p,propagationContext:m,transactionName:_,span:S}=t;qe(e,"extra",n),qe(e,"tags",r),qe(e,"user",i),qe(e,"contexts",o),qe(e,"sdkProcessingMetadata",a),s&&(e.level=s),_&&(e.transactionName=_),S&&(e.span=S),c.length&&(e.breadcrumbs=[...e.breadcrumbs,...c]),d.length&&(e.fingerprint=[...e.fingerprint,...d]),l.length&&(e.eventProcessors=[...e.eventProcessors,...l]),p.length&&(e.attachments=[...e.attachments,...p]),e.propagationContext={...e.propagationContext,...m}}function qe(e,t,n){if(n&&Object.keys(n).length){e[t]={...e[t]};for(let r in n)Object.prototype.hasOwnProperty.call(n,r)&&(e[t][r]=n[r])}}function $c(e,t){let{extra:n,tags:r,user:i,contexts:o,level:s,transactionName:a}=t,c=k(n);c&&Object.keys(c).length&&(e.extra={...c,...e.extra});let d=k(r);d&&Object.keys(d).length&&(e.tags={...d,...e.tags});let l=k(i);l&&Object.keys(l).length&&(e.user={...l,...e.user});let p=k(o);p&&Object.keys(p).length&&(e.contexts={...p,...e.contexts}),s&&(e.level=s),a&&(e.transaction=a)}function Gc(e,t){let n=[...e.breadcrumbs||[],...t];e.breadcrumbs=n.length?n:void 0}function jc(e,t){e.sdkProcessingMetadata={...e.sdkProcessingMetadata,...t}}function Wc(e,t){e.contexts={trace:Mt(t),...e.contexts};let n=wt(t);if(n){e.sdkProcessingMetadata={dynamicSamplingContext:tt(t),...e.sdkProcessingMetadata};let r=R(n).description;r&&(e.tags={transaction:r,...e.tags})}}function qc(e,t){e.fingerprint=e.fingerprint?Gt(e.fingerprint):[],t&&(e.fingerprint=e.fingerprint.concat(t)),e.fingerprint&&!e.fingerprint.length&&delete e.fingerprint}var zc=100,si,Et=class e{constructor(){this._notifyingListeners=!1,this._scopeListeners=[],this._eventProcessors=[],this._breadcrumbs=[],this._attachments=[],this._user={},this._tags={},this._extra={},this._contexts={},this._sdkProcessingMetadata={},this._propagationContext=Mo()}static clone(t){return t?t.clone():new e}clone(){let t=new e;return t._breadcrumbs=[...this._breadcrumbs],t._tags={...this._tags},t._extra={...this._extra},t._contexts={...this._contexts},t._user=this._user,t._level=this._level,t._span=this._span,t._session=this._session,t._transactionName=this._transactionName,t._fingerprint=this._fingerprint,t._eventProcessors=[...this._eventProcessors],t._requestSession=this._requestSession,t._attachments=[...this._attachments],t._sdkProcessingMetadata={...this._sdkProcessingMetadata},t._propagationContext={...this._propagationContext},t._client=this._client,t}setClient(t){this._client=t}getClient(){return this._client}addScopeListener(t){this._scopeListeners.push(t)}addEventProcessor(t){return this._eventProcessors.push(t),this}setUser(t){return this._user=t||{email:void 0,id:void 0,ip_address:void 0,segment:void 0,username:void 0},this._session&&ft(this._session,{user:t}),this._notifyScopeListeners(),this}getUser(){return this._user}getRequestSession(){return this._requestSession}setRequestSession(t){return this._requestSession=t,this}setTags(t){return this._tags={...this._tags,...t},this._notifyScopeListeners(),this}setTag(t,n){return this._tags={...this._tags,[t]:n},this._notifyScopeListeners(),this}setExtras(t){return this._extra={...this._extra,...t},this._notifyScopeListeners(),this}setExtra(t,n){return this._extra={...this._extra,[t]:n},this._notifyScopeListeners(),this}setFingerprint(t){return this._fingerprint=t,this._notifyScopeListeners(),this}setLevel(t){return this._level=t,this._notifyScopeListeners(),this}setTransactionName(t){return this._transactionName=t,this._notifyScopeListeners(),this}setContext(t,n){return n===null?delete this._contexts[t]:this._contexts[t]=n,this._notifyScopeListeners(),this}setSpan(t){return this._span=t,this._notifyScopeListeners(),this}getSpan(){return this._span}getTransaction(){let t=this._span;return t&&t.transaction}setSession(t){return t?this._session=t:delete this._session,this._notifyScopeListeners(),this}getSession(){return this._session}update(t){if(!t)return this;let n=typeof t=="function"?t(this):t;if(n instanceof e){let r=n.getScopeData();this._tags={...this._tags,...r.tags},this._extra={...this._extra,...r.extra},this._contexts={...this._contexts,...r.contexts},r.user&&Object.keys(r.user).length&&(this._user=r.user),r.level&&(this._level=r.level),r.fingerprint.length&&(this._fingerprint=r.fingerprint),n.getRequestSession()&&(this._requestSession=n.getRequestSession()),r.propagationContext&&(this._propagationContext=r.propagationContext)}else if(J(n)){let r=t;this._tags={...this._tags,...r.tags},this._extra={...this._extra,...r.extra},this._contexts={...this._contexts,...r.contexts},r.user&&(this._user=r.user),r.level&&(this._level=r.level),r.fingerprint&&(this._fingerprint=r.fingerprint),r.requestSession&&(this._requestSession=r.requestSession),r.propagationContext&&(this._propagationContext=r.propagationContext)}return this}clear(){return this._breadcrumbs=[],this._tags={},this._extra={},this._user={},this._contexts={},this._level=void 0,this._transactionName=void 0,this._fingerprint=void 0,this._requestSession=void 0,this._span=void 0,this._session=void 0,this._notifyScopeListeners(),this._attachments=[],this._propagationContext=Mo(),this}addBreadcrumb(t,n){let r=typeof n=="number"?n:zc;if(r<=0)return this;let i={timestamp:_t(),...t},o=this._breadcrumbs;return o.push(i),this._breadcrumbs=o.length>r?o.slice(-r):o,this._notifyScopeListeners(),this}getLastBreadcrumb(){return this._breadcrumbs[this._breadcrumbs.length-1]}clearBreadcrumbs(){return this._breadcrumbs=[],this._notifyScopeListeners(),this}addAttachment(t){return this._attachments.push(t),this}getAttachments(){return this.getScopeData().attachments}clearAttachments(){return this._attachments=[],this}getScopeData(){let{_breadcrumbs:t,_attachments:n,_contexts:r,_tags:i,_extra:o,_user:s,_level:a,_fingerprint:c,_eventProcessors:d,_propagationContext:l,_sdkProcessingMetadata:p,_transactionName:m,_span:_}=this;return{breadcrumbs:t,attachments:n,contexts:r,tags:i,extra:o,user:s,level:a,fingerprint:c||[],eventProcessors:d,propagationContext:l,sdkProcessingMetadata:p,transactionName:m,span:_}}applyToEvent(t,n={},r=[]){ze(t,this.getScopeData());let i=[...r,...We(),...this._eventProcessors];return ee(i,t,n)}setSDKProcessingMetadata(t){return this._sdkProcessingMetadata={...this._sdkProcessingMetadata,...t},this}setPropagationContext(t){return this._propagationContext=t,this}getPropagationContext(){return this._propagationContext}captureException(t,n){let r=n&&n.event_id?n.event_id:O();if(!this._client)return f.warn("No client configured on scope - will not capture exception!"),r;let i=new Error("Sentry syntheticException");return this._client.captureException(t,{originalException:t,syntheticException:i,...n,event_id:r},this),r}captureMessage(t,n,r){let i=r&&r.event_id?r.event_id:O();if(!this._client)return f.warn("No client configured on scope - will not capture message!"),i;let o=new Error(t);return this._client.captureMessage(t,n,{originalException:t,syntheticException:o,...r,event_id:i},this),i}captureEvent(t,n){let r=n&&n.event_id?n.event_id:O();return this._client?(this._client.captureEvent(t,{...n,event_id:r},this),r):(f.warn("No client configured on scope - will not capture event!"),r)}_notifyScopeListeners(){this._notifyingListeners||(this._notifyingListeners=!0,this._scopeListeners.forEach(t=>{t(this)}),this._notifyingListeners=!1)}};function ai(){return si||(si=new Et),si}function Mo(){return{traceId:O(),spanId:O().substring(16)}}u();var Se="7.116.0";var Po=parseFloat(Se),Yc=100,Ye=class{constructor(t,n,r,i=Po){this._version=i;let o;n?o=n:(o=new Et,o.setClient(t));let s;r?s=r:(s=new Et,s.setClient(t)),this._stack=[{scope:o}],t&&this.bindClient(t),this._isolationScope=s}isOlderThan(t){return this._version<t}bindClient(t){let n=this.getStackTop();n.client=t,n.scope.setClient(t),t&&t.setupIntegrations&&t.setupIntegrations()}pushScope(){let t=this.getScope().clone();return this.getStack().push({client:this.getClient(),scope:t}),t}popScope(){return this.getStack().length<=1?!1:!!this.getStack().pop()}withScope(t){let n=this.pushScope(),r;try{r=t(n)}catch(i){throw this.popScope(),i}return F(r)?r.then(i=>(this.popScope(),i),i=>{throw this.popScope(),i}):(this.popScope(),r)}getClient(){return this.getStackTop().client}getScope(){return this.getStackTop().scope}getIsolationScope(){return this._isolationScope}getStack(){return this._stack}getStackTop(){return this._stack[this._stack.length-1]}captureException(t,n){let r=this._lastEventId=n&&n.event_id?n.event_id:O(),i=new Error("Sentry syntheticException");return this.getScope().captureException(t,{originalException:t,syntheticException:i,...n,event_id:r}),r}captureMessage(t,n,r){let i=this._lastEventId=r&&r.event_id?r.event_id:O(),o=new Error(t);return this.getScope().captureMessage(t,n,{originalException:t,syntheticException:o,...r,event_id:i}),i}captureEvent(t,n){let r=n&&n.event_id?n.event_id:O();return t.type||(this._lastEventId=r),this.getScope().captureEvent(t,{...n,event_id:r}),r}lastEventId(){return this._lastEventId}addBreadcrumb(t,n){let{scope:r,client:i}=this.getStackTop();if(!i)return;let{beforeBreadcrumb:o=null,maxBreadcrumbs:s=Yc}=i.getOptions&&i.getOptions()||{};if(s<=0)return;let c={timestamp:_t(),...t},d=o?ht(()=>o(c,n)):c;d!==null&&(i.emit&&i.emit("beforeAddBreadcrumb",d,n),r.addBreadcrumb(d,s))}setUser(t){this.getScope().setUser(t),this.getIsolationScope().setUser(t)}setTags(t){this.getScope().setTags(t),this.getIsolationScope().setTags(t)}setExtras(t){this.getScope().setExtras(t),this.getIsolationScope().setExtras(t)}setTag(t,n){this.getScope().setTag(t,n),this.getIsolationScope().setTag(t,n)}setExtra(t,n){this.getScope().setExtra(t,n),this.getIsolationScope().setExtra(t,n)}setContext(t,n){this.getScope().setContext(t,n),this.getIsolationScope().setContext(t,n)}configureScope(t){let{scope:n,client:r}=this.getStackTop();r&&t(n)}run(t){let n=ci(this);try{t(this)}finally{ci(n)}}getIntegration(t){let n=this.getClient();if(!n)return null;try{return n.getIntegration(t)}catch{return E&&f.warn(`Cannot retrieve integration ${t.id} from the current Hub`),null}}startTransaction(t,n){let r=this._callExtensionMethod("startTransaction",t,n);return E&&!r&&(this.getClient()?f.warn(`Tracing extension 'startTransaction' has not been added. Call 'addTracingExtensions' before calling 'init':
10
10
  Sentry.addTracingExtensions();
11
11
  Sentry.init({...});
12
12
  `):f.warn("Tracing extension 'startTransaction' is missing. You should 'init' the SDK before calling 'startTransaction'")),r}traceHeaders(){return this._callExtensionMethod("traceHeaders")}captureSession(t=!1){if(t)return this.endSession();this._sendSessionUpdate()}endSession(){let n=this.getStackTop().scope,r=n.getSession();r&&vn(r),this._sendSessionUpdate(),n.setSession()}startSession(t){let{scope:n,client:r}=this.getStackTop(),{release:i,environment:o=kt}=r&&r.getOptions()||{},{userAgent:s}=x.navigator||{},a=xn({release:i,environment:o,user:n.getUser(),...s&&{userAgent:s},...t}),c=n.getSession&&n.getSession();return c&&c.status==="ok"&&ft(c,{status:"exited"}),this.endSession(),n.setSession(a),a}shouldSendDefaultPii(){let t=this.getClient(),n=t&&t.getOptions();return!!(n&&n.sendDefaultPii)}_sendSessionUpdate(){let{scope:t,client:n}=this.getStackTop(),r=t.getSession();r&&n&&n.captureSession&&n.captureSession(r)}_callExtensionMethod(t,...n){let i=qt().__SENTRY__;if(i&&i.extensions&&typeof i.extensions[t]=="function")return i.extensions[t].apply(this,n);E&&f.warn(`Extension method ${t} couldn't be found, doing nothing.`)}};function qt(){return x.__SENTRY__=x.__SENTRY__||{extensions:{},hub:void 0},x}function ci(e){let t=qt(),n=Rn(t);return ui(t,e),n}function D(){let e=qt();if(e.__SENTRY__&&e.__SENTRY__.acs){let t=e.__SENTRY__.acs.getCurrentHub();if(t)return t}return Jc(e)}function et(){return D().getIsolationScope()}function Jc(e=qt()){return(!Kc(e)||Rn(e).isOlderThan(Po))&&ui(e,new Ye),Rn(e)}function ne(e,t={}){let n=qt();return n.__SENTRY__&&n.__SENTRY__.acs?n.__SENTRY__.acs.runWithAsyncContext(e,t):e()}function Kc(e){return!!(e&&e.__SENTRY__&&e.__SENTRY__.hub)}function Rn(e){return Ne("hub",()=>new Ye,e)}function ui(e,t){if(!e)return!1;let n=e.__SENTRY__=e.__SENTRY__||{};return n.hub=t,!0}u();function di(e,t,n,r,i,o){let{normalizeDepth:s=3,normalizeMaxBreadth:a=1e3}=e,c={...t,event_id:t.event_id||n.event_id||O(),timestamp:t.timestamp||_t()},d=n.integrations||e.integrations.map(y=>y.name);Vc(c,e),Zc(c,d),t.type===void 0&&Xc(c,e.stackParser);let l=eu(r,n.captureContext);n.mechanism&&Rt(c,n.mechanism);let p=i&&i.getEventProcessors?i.getEventProcessors():[],m=ai().getScopeData();if(o){let y=o.getScopeData();An(m,y)}if(l){let y=l.getScopeData();An(m,y)}let _=[...n.attachments||[],...m.attachments];_.length&&(n.attachments=_),ze(c,m);let S=[...p,...We(),...m.eventProcessors];return ee(S,c,n).then(y=>(y&&Qc(y),typeof s=="number"&&s>0?tu(y,s,a):y))}function Vc(e,t){let{environment:n,release:r,dist:i,maxValueLength:o=250}=t;"environment"in e||(e.environment="environment"in t?n:kt),e.release===void 0&&r!==void 0&&(e.release=r),e.dist===void 0&&i!==void 0&&(e.dist=i),e.message&&(e.message=gt(e.message,o));let s=e.exception&&e.exception.values&&e.exception.values[0];s&&s.value&&(s.value=gt(s.value,o));let a=e.request;a&&a.url&&(a.url=gt(a.url,o))}var Lo=new WeakMap;function Xc(e,t){let n=x._sentryDebugIds;if(!n)return;let r,i=Lo.get(t);i?r=i:(r=new Map,Lo.set(t,r));let o=Object.keys(n).reduce((s,a)=>{let c,d=r.get(a);d?c=d:(c=t(a),r.set(a,c));for(let l=c.length-1;l>=0;l--){let p=c[l];if(p.filename){s[p.filename]=n[a];break}}return s},{});try{e.exception.values.forEach(s=>{s.stacktrace.frames.forEach(a=>{a.filename&&(a.debug_id=o[a.filename])})})}catch{}}function Qc(e){let t={};try{e.exception.values.forEach(r=>{r.stacktrace.frames.forEach(i=>{i.debug_id&&(i.abs_path?t[i.abs_path]=i.debug_id:i.filename&&(t[i.filename]=i.debug_id),delete i.debug_id)})})}catch{}if(Object.keys(t).length===0)return;e.debug_meta=e.debug_meta||{},e.debug_meta.images=e.debug_meta.images||[];let n=e.debug_meta.images;Object.keys(t).forEach(r=>{n.push({type:"sourcemap",code_file:r,debug_id:t[r]})})}function Zc(e,t){t.length>0&&(e.sdk=e.sdk||{},e.sdk.integrations=[...e.sdk.integrations||[],...t])}function tu(e,t,n){if(!e)return null;let r={...e,...e.breadcrumbs&&{breadcrumbs:e.breadcrumbs.map(i=>({...i,...i.data&&{data:K(i.data,t,n)}}))},...e.user&&{user:K(e.user,t,n)},...e.contexts&&{contexts:K(e.contexts,t,n)},...e.extra&&{extra:K(e.extra,t,n)}};return e.contexts&&e.contexts.trace&&r.contexts&&(r.contexts.trace=e.contexts.trace,e.contexts.trace.data&&(r.contexts.trace.data=K(e.contexts.trace.data,t,n))),e.spans&&(r.spans=e.spans.map(i=>{let o=R(i).data;return o&&(i.data=K(o,t,n)),i})),r}function eu(e,t){if(!t)return e;let n=e?e.clone():new Et;return n.update(t),n}function Uo(e){if(e)return nu(e)?{captureContext:e}:iu(e)?{captureContext:e}:e}function nu(e){return e instanceof Et||typeof e=="function"}var ru=["user","level","extra","contexts","tags","fingerprint","requestSession","propagationContext"];function iu(e){return Object.keys(e).some(t=>ru.includes(t))}function li(e,t){return D().captureException(e,Uo(t))}function Ee(e,t){let n=typeof t=="string"?t:void 0,r=typeof t!="string"?{captureContext:t}:void 0;return D().captureMessage(e,n,r)}function Cn(e,t){return D().captureEvent(e,t)}function ou(e){D().configureScope(e)}function su(e,t){D().addBreadcrumb(e,t)}function au(e,t){D().setContext(e,t)}function cu(e){D().setExtras(e)}function uu(e,t){D().setExtra(e,t)}function du(e){D().setTags(e)}function lu(e,t){D().setTag(e,t)}function pu(e){D().setUser(e)}function Lt(...e){let t=D();if(e.length===2){let[n,r]=e;return n?t.withScope(()=>(t.getStackTop().scope=n,r(n))):t.withScope(r)}return t.withScope(e[0])}function fu(e){return ne(()=>e(et()))}function mu(e,t){return Lt(n=>(n.setSpan(e),t(n)))}function gu(e,t){return D().startTransaction({...e},t)}async function hu(e){let t=C();return t?t.flush(e):(E&&f.warn("Cannot flush events. No client defined."),Promise.resolve(!1))}async function _u(e){let t=C();return t?t.close(e):(E&&f.warn("Cannot flush events and disable SDK. No client defined."),Promise.resolve(!1))}function Su(){return D().lastEventId()}function C(){return D().getClient()}function Eu(){return!!C()}function L(){return D().getScope()}function Tu(e){let t=C(),n=et(),r=L(),{release:i,environment:o=kt}=t&&t.getOptions()||{},{userAgent:s}=x.navigator||{},a=xn({release:i,environment:o,user:r.getUser()||n.getUser(),...s&&{userAgent:s},...e}),c=n.getSession();return c&&c.status==="ok"&&ft(c,{status:"exited"}),pi(),n.setSession(a),r.setSession(a),a}function pi(){let e=et(),t=L(),n=t.getSession()||e.getSession();n&&vn(n),Fo(),e.setSession(),t.setSession()}function Fo(){let e=et(),t=L(),n=C(),r=t.getSession()||e.getSession();r&&n&&n.captureSession&&n.captureSession(r)}function yu(e=!1){if(e){pi();return}Fo()}u();function z(e){return(e||D()).getScope().getTransaction()}var Iu=Ge;u();var fi;(function(e){let t="ok";e.Ok=t;let n="deadline_exceeded";e.DeadlineExceeded=n;let r="unauthenticated";e.Unauthenticated=r;let i="permission_denied";e.PermissionDenied=i;let o="not_found";e.NotFound=o;let s="resource_exhausted";e.ResourceExhausted=s;let a="invalid_argument";e.InvalidArgument=a;let c="unimplemented";e.Unimplemented=c;let d="unavailable";e.Unavailable=d;let l="internal_error";e.InternalError=l;let p="unknown_error";e.UnknownError=p;let m="cancelled";e.Cancelled=m;let _="already_exists";e.AlreadyExists=_;let S="failed_precondition";e.FailedPrecondition=S;let T="aborted";e.Aborted=T;let y="out_of_range";e.OutOfRange=y;let v="data_loss";e.DataLoss=v})(fi||(fi={}));function mi(e){if(e<400&&e>=100)return"ok";if(e>=400&&e<500)switch(e){case 401:return"unauthenticated";case 403:return"permission_denied";case 404:return"not_found";case 409:return"already_exists";case 413:return"failed_precondition";case 429:return"resource_exhausted";default:return"invalid_argument"}if(e>=500&&e<600)switch(e){case 501:return"unimplemented";case 503:return"unavailable";case 504:return"deadline_exceeded";default:return"internal_error"}return"unknown_error"}var bu=mi;function re(e,t){e.setTag("http.status_code",String(t)),e.setData("http.response.status_code",t);let n=mi(t);n!=="unknown_error"&&e.setStatus(n)}u();u();var Bo=!1;function Ho(){Bo||(Bo=!0,wr(gi),Mr(gi))}function gi(){let e=z();if(e){let t="internal_error";E&&f.log(`[Tracing] Transaction: ${t} -> Global error occured`),e.setStatus(t)}}gi.tag="sentry_tracingErrorCallback";u();function On(e,t,n=()=>{}){let r;try{r=e()}catch(i){throw t(i),n(),i}return xu(r,t,n)}function xu(e,t,n){return F(e)?e.then(r=>(n(),r),r=>{throw t(r),n(),r}):(n(),e)}u();function at(e){if(typeof __SENTRY_TRACING__=="boolean"&&!__SENTRY_TRACING__)return!1;let t=C(),n=e||t&&t.getOptions();return!!n&&(n.enableTracing||"tracesSampleRate"in n||"tracesSampler"in n)}function vu(e,t,n=()=>{},r=()=>{}){let i=D(),o=L(),s=o.getSpan(),a=Nn(e),c=Dn(i,{parentSpan:s,spanContext:a,forceTransaction:!1,scope:o});return o.setSpan(c),On(()=>t(c),d=>{c&&c.setStatus("internal_error"),n(d,c)},()=>{c&&c.end(),o.setSpan(s),r()})}function hi(e,t){let n=Nn(e);return ne(()=>Lt(e.scope,r=>{let i=D(),o=r.getSpan(),a=e.onlyIfParent&&!o?void 0:Dn(i,{parentSpan:o,spanContext:n,forceTransaction:e.forceTransaction,scope:r});return On(()=>t(a),()=>{if(a){let{status:c}=R(a);(!c||c==="ok")&&a.setStatus("internal_error")}},()=>a&&a.end())}))}function Au(e,t){let n=Nn(e);return ne(()=>Lt(e.scope,r=>{let i=D(),o=r.getSpan(),a=e.onlyIfParent&&!o?void 0:Dn(i,{parentSpan:o,spanContext:n,forceTransaction:e.forceTransaction,scope:r});function c(){a&&a.end()}return On(()=>t(a,c),()=>{if(a&&a.isRecording()){let{status:d}=R(a);(!d||d==="ok")&&a.setStatus("internal_error")}})}))}function Je(e){if(!at())return;let t=Nn(e),n=D(),r=e.scope?e.scope.getSpan():ie();if(e.onlyIfParent&&!r)return;let s=(e.scope||L()).clone();return Dn(n,{parentSpan:r,spanContext:t,forceTransaction:e.forceTransaction,scope:s})}function ie(){return L().getSpan()}var Ru=({sentryTrace:e,baggage:t},n)=>{let r=L(),{traceparentData:i,dynamicSamplingContext:o,propagationContext:s}=qr(e,t);r.setPropagationContext(s),E&&i&&f.log(`[Tracing] Continuing trace ${i.traceId}.`);let a={...i,metadata:k({dynamicSamplingContext:o})};return n?ne(()=>n(a)):a};function Dn(e,{parentSpan:t,spanContext:n,forceTransaction:r,scope:i}){if(!at())return;let o=et(),s;if(t&&!r)s=t.startChild(n);else if(t){let a=tt(t),{traceId:c,spanId:d}=t.spanContext(),l=_e(t);s=e.startTransaction({traceId:c,parentSpanId:d,parentSampled:l,...n,metadata:{dynamicSamplingContext:a,...n.metadata}})}else{let{traceId:a,dsc:c,parentSpanId:d,sampled:l}={...o.getPropagationContext(),...i.getPropagationContext()};s=e.startTransaction({traceId:a,parentSpanId:d,parentSampled:l,...n,metadata:{dynamicSamplingContext:c,...n.metadata}})}return i.setSpan(s),Cu(s,i,o),s}function Nn(e){if(e.startTime){let t={...e};return t.startTimestamp=Wt(e.startTime),delete t.startTime,t}return e}var $o="_sentryScope",Go="_sentryIsolationScope";function Cu(e,t,n){e&&(X(e,Go,n),X(e,$o,t))}function jo(e){return{scope:e[$o],isolationScope:e[Go]}}u();var G="sentry.source",Ut="sentry.sample_rate",Te="sentry.op",ct="sentry.origin",_i="profile_id";u();u();u();u();var Ke;function Wo(e){return Ke?Ke.get(e):void 0}function kn(e){let t=Wo(e);if(!t)return;let n={};for(let[,[r,i]]of t)n[r]||(n[r]=[]),n[r].push(k(i));return n}function wn(e,t,n,r,i,o){let s=ie();if(s){let a=Wo(s)||new Map,c=`${e}:${t}@${r}`,d=a.get(o);if(d){let[,l]=d;a.set(o,[c,{min:Math.min(l.min,n),max:Math.max(l.max,n),count:l.count+=1,sum:l.sum+=n,tags:l.tags}])}else a.set(o,[c,{min:n,max:n,count:1,sum:n,tags:i}]);Ke||(Ke=new WeakMap),Ke.set(s,a)}}var ye=class{constructor(t=1e3){this._maxlen=t,this.spans=[]}add(t){this.spans.length>this._maxlen?t.spanRecorder=void 0:this.spans.push(t)}},oe=class e{constructor(t={}){this._traceId=t.traceId||O(),this._spanId=t.spanId||O().substring(16),this._startTime=t.startTimestamp||W(),this.tags=t.tags?{...t.tags}:{},this.data=t.data?{...t.data}:{},this.instrumenter=t.instrumenter||"sentry",this._attributes={},this.setAttributes({[ct]:t.origin||"manual",[Te]:t.op,...t.attributes}),this._name=t.name||t.description,t.parentSpanId&&(this._parentSpanId=t.parentSpanId),"sampled"in t&&(this._sampled=t.sampled),t.status&&(this._status=t.status),t.endTimestamp&&(this._endTime=t.endTimestamp),t.exclusiveTime!==void 0&&(this._exclusiveTime=t.exclusiveTime),this._measurements=t.measurements?{...t.measurements}:{}}get name(){return this._name||""}set name(t){this.updateName(t)}get description(){return this._name}set description(t){this._name=t}get traceId(){return this._traceId}set traceId(t){this._traceId=t}get spanId(){return this._spanId}set spanId(t){this._spanId=t}set parentSpanId(t){this._parentSpanId=t}get parentSpanId(){return this._parentSpanId}get sampled(){return this._sampled}set sampled(t){this._sampled=t}get attributes(){return this._attributes}set attributes(t){this._attributes=t}get startTimestamp(){return this._startTime}set startTimestamp(t){this._startTime=t}get endTimestamp(){return this._endTime}set endTimestamp(t){this._endTime=t}get status(){return this._status}set status(t){this._status=t}get op(){return this._attributes[Te]}set op(t){this.setAttribute(Te,t)}get origin(){return this._attributes[ct]}set origin(t){this.setAttribute(ct,t)}spanContext(){let{_spanId:t,_traceId:n,_sampled:r}=this;return{spanId:t,traceId:n,traceFlags:r?oi:wo}}startChild(t){let n=new e({...t,parentSpanId:this._spanId,sampled:this._sampled,traceId:this._traceId});n.spanRecorder=this.spanRecorder,n.spanRecorder&&n.spanRecorder.add(n);let r=wt(this);if(n.transaction=r,E&&r){let i=t&&t.op||"< unknown op >",o=R(n).description||"< unknown name >",s=r.spanContext().spanId,a=`[Tracing] Starting '${i}' span on transaction '${o}' (${s}).`;f.log(a),this._logMessage=a}return n}setTag(t,n){return this.tags={...this.tags,[t]:n},this}setData(t,n){return this.data={...this.data,[t]:n},this}setAttribute(t,n){n===void 0?delete this._attributes[t]:this._attributes[t]=n}setAttributes(t){Object.keys(t).forEach(n=>this.setAttribute(n,t[n]))}setStatus(t){return this._status=t,this}setHttpStatus(t){return re(this,t),this}setName(t){this.updateName(t)}updateName(t){return this._name=t,this}isSuccess(){return this._status==="ok"}finish(t){return this.end(t)}end(t){if(this._endTime)return;let n=wt(this);if(E&&n&&n.spanContext().spanId!==this._spanId){let r=this._logMessage;r&&f.log(r.replace("Starting","Finishing"))}this._endTime=Wt(t)}toTraceparent(){return Pt(this)}toContext(){return k({data:this._getData(),description:this._name,endTimestamp:this._endTime,op:this.op,parentSpanId:this._parentSpanId,sampled:this._sampled,spanId:this._spanId,startTimestamp:this._startTime,status:this._status,tags:this.tags,traceId:this._traceId})}updateWithContext(t){return this.data=t.data||{},this._name=t.name||t.description,this._endTime=t.endTimestamp,this.op=t.op,this._parentSpanId=t.parentSpanId,this._sampled=t.sampled,this._spanId=t.spanId||this._spanId,this._startTime=t.startTimestamp||this._startTime,this._status=t.status,this.tags=t.tags||{},this._traceId=t.traceId||this._traceId,this}getTraceContext(){return Mt(this)}getSpanJSON(){return k({data:this._getData(),description:this._name,op:this._attributes[Te],parent_span_id:this._parentSpanId,span_id:this._spanId,start_timestamp:this._startTime,status:this._status,tags:Object.keys(this.tags).length>0?this.tags:void 0,timestamp:this._endTime,trace_id:this._traceId,origin:this._attributes[ct],_metrics_summary:kn(this),profile_id:this._attributes[_i],exclusive_time:this._exclusiveTime,measurements:Object.keys(this._measurements).length>0?this._measurements:void 0})}isRecording(){return!this._endTime&&!!this._sampled}toJSON(){return this.getSpanJSON()}_getData(){let{data:t,_attributes:n}=this,r=Object.keys(t).length>0,i=Object.keys(n).length>0;if(!(!r&&!i))return r&&i?{...t,...n}:r?t:n}};u();var Ie=class extends oe{constructor(t,n){super(t),this._contexts={},this._hub=n||D(),this._name=t.name||"",this._metadata={...t.metadata},this._trimEnd=t.trimEnd,this.transaction=this;let r=this._metadata.dynamicSamplingContext;r&&(this._frozenDynamicSamplingContext={...r})}get name(){return this._name}set name(t){this.setName(t)}get metadata(){return{source:"custom",spanMetadata:{},...this._metadata,...this._attributes[G]&&{source:this._attributes[G]},...this._attributes[Ut]&&{sampleRate:this._attributes[Ut]}}}set metadata(t){this._metadata=t}setName(t,n="custom"){this._name=t,this.setAttribute(G,n)}updateName(t){return this._name=t,this}initSpanRecorder(t=1e3){this.spanRecorder||(this.spanRecorder=new ye(t)),this.spanRecorder.add(this)}setContext(t,n){n===null?delete this._contexts[t]:this._contexts[t]=n}setMeasurement(t,n,r=""){this._measurements[t]={value:n,unit:r}}setMetadata(t){this._metadata={...this._metadata,...t}}end(t){let n=Wt(t),r=this._finishTransaction(n);if(r)return this._hub.captureEvent(r)}toContext(){let t=super.toContext();return k({...t,name:this._name,trimEnd:this._trimEnd})}updateWithContext(t){return super.updateWithContext(t),this._name=t.name||"",this._trimEnd=t.trimEnd,this}getDynamicSamplingContext(){return tt(this)}setHub(t){this._hub=t}getProfileId(){if(this._contexts!==void 0&&this._contexts.profile!==void 0)return this._contexts.profile.profile_id}_finishTransaction(t){if(this._endTime!==void 0)return;this._name||(E&&f.warn("Transaction has no name, falling back to `<unlabeled transaction>`."),this._name="<unlabeled transaction>"),super.end(t);let n=this._hub.getClient();if(n&&n.emit&&n.emit("finishTransaction",this),this._sampled!==!0){E&&f.log("[Tracing] Discarding transaction because its trace was not chosen to be sampled."),n&&n.recordDroppedEvent("sample_rate","transaction");return}let r=this.spanRecorder?this.spanRecorder.spans.filter(l=>l!==this&&R(l).timestamp):[];if(this._trimEnd&&r.length>0){let l=r.map(p=>R(p).timestamp).filter(Boolean);this._endTime=l.reduce((p,m)=>p>m?p:m)}let{scope:i,isolationScope:o}=jo(this),{metadata:s}=this,{source:a}=s,c={contexts:{...this._contexts,trace:Mt(this)},spans:r,start_timestamp:this._startTime,tags:this.tags,timestamp:this._endTime,transaction:this._name,type:"transaction",sdkProcessingMetadata:{...s,capturedSpanScope:i,capturedSpanIsolationScope:o,...k({dynamicSamplingContext:tt(this)})},_metrics_summary:kn(this),...a&&{transaction_info:{source:a}}};return Object.keys(this._measurements).length>0&&(E&&f.log("[Measurements] Adding measurements to transaction",JSON.stringify(this._measurements,void 0,2)),c.measurements=this._measurements),E&&f.log(`[Tracing] Finishing ${this.op} transaction: ${this._name}.`),c}};var zt={idleTimeout:1e3,finalTimeout:3e4,heartbeatInterval:5e3},Ou="finishReason",be=["heartbeatFailed","idleTimeout","documentHidden","finalTimeout","externalFinish","cancelled"],Si=class extends ye{constructor(t,n,r,i){super(i),this._pushActivity=t,this._popActivity=n,this.transactionSpanId=r}add(t){if(t.spanContext().spanId!==this.transactionSpanId){let n=t.end;t.end=(...r)=>(this._popActivity(t.spanContext().spanId),n.apply(t,r)),R(t).timestamp===void 0&&this._pushActivity(t.spanContext().spanId)}super.add(t)}},Ve=class extends Ie{constructor(t,n,r=zt.idleTimeout,i=zt.finalTimeout,o=zt.heartbeatInterval,s=!1,a=!1){super(t,n),this._idleHub=n,this._idleTimeout=r,this._finalTimeout=i,this._heartbeatInterval=o,this._onScope=s,this.activities={},this._heartbeatCounter=0,this._finished=!1,this._idleTimeoutCanceledPermanently=!1,this._beforeFinishCallbacks=[],this._finishReason=be[4],this._autoFinishAllowed=!a,s&&(E&&f.log(`Setting idle transaction on scope. Span ID: ${this.spanContext().spanId}`),n.getScope().setSpan(this)),a||this._restartIdleTimeout(),setTimeout(()=>{this._finished||(this.setStatus("deadline_exceeded"),this._finishReason=be[3],this.end())},this._finalTimeout)}end(t){let n=Wt(t);if(this._finished=!0,this.activities={},this.op==="ui.action.click"&&this.setAttribute(Ou,this._finishReason),this.spanRecorder){E&&f.log("[Tracing] finishing IdleTransaction",new Date(n*1e3).toISOString(),this.op);for(let r of this._beforeFinishCallbacks)r(this,n);this.spanRecorder.spans=this.spanRecorder.spans.filter(r=>{if(r.spanContext().spanId===this.spanContext().spanId)return!0;R(r).timestamp||(r.setStatus("cancelled"),r.end(n),E&&f.log("[Tracing] cancelling span since transaction ended early",JSON.stringify(r,void 0,2)));let{start_timestamp:i,timestamp:o}=R(r),s=i&&i<n,a=(this._finalTimeout+this._idleTimeout)/1e3,c=o&&i&&o-i<a;if(E){let d=JSON.stringify(r,void 0,2);s?c||f.log("[Tracing] discarding Span since it finished after Transaction final timeout",d):f.log("[Tracing] discarding Span since it happened after Transaction was finished",d)}return s&&c}),E&&f.log("[Tracing] flushing IdleTransaction")}else E&&f.log("[Tracing] No active IdleTransaction");if(this._onScope){let r=this._idleHub.getScope();r.getTransaction()===this&&r.setSpan(void 0)}return super.end(t)}registerBeforeFinishCallback(t){this._beforeFinishCallbacks.push(t)}initSpanRecorder(t){if(!this.spanRecorder){let n=i=>{this._finished||this._pushActivity(i)},r=i=>{this._finished||this._popActivity(i)};this.spanRecorder=new Si(n,r,this.spanContext().spanId,t),E&&f.log("Starting heartbeat"),this._pingHeartbeat()}this.spanRecorder.add(this)}cancelIdleTimeout(t,{restartOnChildSpanChange:n}={restartOnChildSpanChange:!0}){this._idleTimeoutCanceledPermanently=n===!1,this._idleTimeoutID&&(clearTimeout(this._idleTimeoutID),this._idleTimeoutID=void 0,Object.keys(this.activities).length===0&&this._idleTimeoutCanceledPermanently&&(this._finishReason=be[5],this.end(t)))}setFinishReason(t){this._finishReason=t}sendAutoFinishSignal(){this._autoFinishAllowed||(E&&f.log("[Tracing] Received finish signal for idle transaction."),this._restartIdleTimeout(),this._autoFinishAllowed=!0)}_restartIdleTimeout(t){this.cancelIdleTimeout(),this._idleTimeoutID=setTimeout(()=>{!this._finished&&Object.keys(this.activities).length===0&&(this._finishReason=be[1],this.end(t))},this._idleTimeout)}_pushActivity(t){this.cancelIdleTimeout(void 0,{restartOnChildSpanChange:!this._idleTimeoutCanceledPermanently}),E&&f.log(`[Tracing] pushActivity: ${t}`),this.activities[t]=!0,E&&f.log("[Tracing] new activities count",Object.keys(this.activities).length)}_popActivity(t){if(this.activities[t]&&(E&&f.log(`[Tracing] popActivity ${t}`),delete this.activities[t],E&&f.log("[Tracing] new activities count",Object.keys(this.activities).length)),Object.keys(this.activities).length===0){let n=W();this._idleTimeoutCanceledPermanently?this._autoFinishAllowed&&(this._finishReason=be[5],this.end(n)):this._restartIdleTimeout(n+this._idleTimeout/1e3)}}_beat(){if(this._finished)return;let t=Object.keys(this.activities).join("");t===this._prevHeartbeatString?this._heartbeatCounter++:this._heartbeatCounter=1,this._prevHeartbeatString=t,this._heartbeatCounter>=3?this._autoFinishAllowed&&(E&&f.log("[Tracing] Transaction finished because of no change for 3 heart beats"),this.setStatus("deadline_exceeded"),this._finishReason=be[0],this.end()):this._pingHeartbeat()}_pingHeartbeat(){E&&f.log(`pinging Heartbeat -> current counter: ${this._heartbeatCounter}`),setTimeout(()=>{this._beat()},this._heartbeatInterval)}};u();function Ei(e,t,n){if(!at(t))return e.sampled=!1,e;if(e.sampled!==void 0)return e.setAttribute(Ut,Number(e.sampled)),e;let r;return typeof t.tracesSampler=="function"?(r=t.tracesSampler(n),e.setAttribute(Ut,Number(r))):n.parentSampled!==void 0?r=n.parentSampled:typeof t.tracesSampleRate<"u"?(r=t.tracesSampleRate,e.setAttribute(Ut,Number(r))):(r=1,e.setAttribute(Ut,r)),Mn(r)?r?(e.sampled=Math.random()<r,e.sampled?(E&&f.log(`[Tracing] starting ${e.op} transaction - ${R(e).description}`),e):(E&&f.log(`[Tracing] Discarding transaction because it's not included in the random sample (sampling rate = ${Number(r)})`),e)):(E&&f.log(`[Tracing] Discarding transaction because ${typeof t.tracesSampler=="function"?"tracesSampler returned 0 or false":"a negative sampling decision was inherited or tracesSampleRate is set to 0"}`),e.sampled=!1,e):(E&&f.warn("[Tracing] Discarding transaction because of invalid sample rate."),e.sampled=!1,e)}function Mn(e){return Ce(e)||!(typeof e=="number"||typeof e=="boolean")?(E&&f.warn(`[Tracing] Given sample rate is invalid. Sample rate must be a boolean or a number between 0 and 1. Got ${JSON.stringify(e)} of type ${JSON.stringify(typeof e)}.`),!1):e<0||e>1?(E&&f.warn(`[Tracing] Given sample rate is invalid. Sample rate must be between 0 and 1. Got ${e}.`),!1):!0}function Du(){let t=this.getScope().getSpan();return t?{"sentry-trace":Pt(t)}:{}}function Nu(e,t){let n=this.getClient(),r=n&&n.getOptions()||{},i=r.instrumenter||"sentry",o=e.instrumenter||"sentry";i!==o&&(E&&f.error(`A transaction was started with instrumenter=\`${o}\`, but the SDK is configured with the \`${i}\` instrumenter.
@@ -26,4 +26,4 @@ Name: ${Qt(r)}
26
26
  Error:`,i)}}function Qd(){return As(e=>{Ae("cls",{metric:e}),Fs=e},{reportAllChanges:!0})}function Zd(){return Rs(e=>{Ae("fid",{metric:e}),Bs=e})}function tl(){return Ls(e=>{Ae("lcp",{metric:e}),Hs=e})}function el(){return Us(e=>{Ae("ttfb",{metric:e}),$s=e})}function nl(){return Ms(e=>{Ae("inp",{metric:e}),Gs=e})}function tn(e,t,n,r,i=!1){qs(e,t);let o;return Vn[e]||(o=n(),Vn[e]=!0),r&&t({metric:r}),zs(e,t,i?o:void 0)}function rl(e){let t={};e==="event"&&(t.durationThreshold=0),ut(e,n=>{Ae(e,{entries:n})},t)}function qs(e,t){Ze[e]=Ze[e]||[],Ze[e].push(t)}function zs(e,t,n){return()=>{n&&n();let r=Ze[e];if(!r)return;let i=r.indexOf(t);i!==-1&&r.splice(i,1)}}var Yi=["localhost",/^\/(?!\/)/],ce={traceFetch:!0,traceXHR:!0,enableHTTPTimings:!0,tracingOrigins:Yi,tracePropagationTargets:Yi};function en(e){let{traceFetch:t,traceXHR:n,tracePropagationTargets:r,tracingOrigins:i,shouldCreateSpanForRequest:o,enableHTTPTimings:s}={traceFetch:ce.traceFetch,traceXHR:ce.traceXHR,...e},a=typeof o=="function"?o:l=>!0,c=l=>al(l,r||i),d={};t&&Pe(l=>{let p=xs(l,a,c,d);if(p){let m=Js(l.fetchData.url),_=m?jt(m).host:void 0;p.setAttributes({"http.url":m,"server.address":_})}s&&p&&Ys(p)}),n&&Fe(l=>{let p=cl(l,a,c,d);s&&p&&Ys(p)})}function il(e){return e.entryType==="resource"&&"initiatorType"in e&&typeof e.nextHopProtocol=="string"&&(e.initiatorType==="fetch"||e.initiatorType==="xmlhttprequest")}function Ys(e){let{url:t}=R(e).data||{};if(!t||typeof t!="string")return;let n=dt("resource",({entries:r})=>{r.forEach(i=>{il(i)&&i.name.endsWith(t)&&(sl(i).forEach(s=>e.setAttribute(...s)),setTimeout(n))})})}function ol(e){let t="unknown",n="unknown",r="";for(let i of e){if(i==="/"){[t,n]=e.split("/");break}if(!isNaN(Number(i))){t=r==="h"?"http":r,n=e.split(r)[1];break}r+=i}return r===e&&(t=r),{name:t,version:n}}function bt(e=0){return((B||performance.timeOrigin)+e)/1e3}function sl(e){let{name:t,version:n}=ol(e.nextHopProtocol),r=[];return r.push(["network.protocol.version",n],["network.protocol.name",t]),B?[...r,["http.request.redirect_start",bt(e.redirectStart)],["http.request.fetch_start",bt(e.fetchStart)],["http.request.domain_lookup_start",bt(e.domainLookupStart)],["http.request.domain_lookup_end",bt(e.domainLookupEnd)],["http.request.connect_start",bt(e.connectStart)],["http.request.secure_connection_start",bt(e.secureConnectionStart)],["http.request.connection_end",bt(e.connectEnd)],["http.request.request_start",bt(e.requestStart)],["http.request.response_start",bt(e.responseStart)],["http.request.response_end",bt(e.responseEnd)]]:r}function al(e,t){return Ht(e,t||Yi)}function cl(e,t,n,r){let i=e.xhr,o=i&&i[Ct];if(!at()||!i||i.__sentry_own_request__||!o)return;let s=t(o.url);if(e.endTimestamp&&s){let _=i.__sentry_xhr_span_id__;if(!_)return;let S=r[_];S&&o.status_code!==void 0&&(re(S,o.status_code),S.end(),delete r[_]);return}let a=L(),c=et(),d=Js(o.url),l=d?jt(d).host:void 0,p=s?Je({name:`${o.method} ${o.url}`,onlyIfParent:!0,attributes:{type:"xhr","http.method":o.method,"http.url":d,url:o.url,"server.address":l,[ct]:"auto.http.browser"},op:"http.client"}):void 0;p&&(i.__sentry_xhr_span_id__=p.spanContext().spanId,r[i.__sentry_xhr_span_id__]=p);let m=C();if(i.setRequestHeader&&n(o.url)&&m){let{traceId:_,spanId:S,sampled:T,dsc:y}={...c.getPropagationContext(),...a.getPropagationContext()},v=p?Pt(p):te(_,S,T),N=$e(y||(p?tt(p):St(_,m,a)));ul(i,v,N)}return p}function ul(e,t,n){try{e.setRequestHeader("sentry-trace",t),n&&e.setRequestHeader(he,n)}catch{}}function Js(e){try{return new URL(e,I.location.origin).href}catch{return}}u();u();function Xn(){I.document?I.document.addEventListener("visibilitychange",()=>{let e=z();if(I.document.hidden&&e){let t="cancelled",{op:n,status:r}=R(e);b&&f.log(`[Tracing] Transaction: ${t} -> since tab moved to the background, op: ${n}`),r||e.setStatus(t),e.setTag("visibilitychange","document.hidden"),e.end()}}):b&&f.warn("[Tracing] Could not set up background tab detection due to lack of global document")}u();u();function Qn(e){return typeof e=="number"&&isFinite(e)}function ue(e,{startTimestamp:t,...n}){return t&&e.startTimestamp>t&&(e.startTimestamp=t),e.startChild({startTimestamp:t,...n})}var dl=2147483647;function H(e){return e/1e3}function Ki(){return I&&I.addEventListener&&I.performance}var Ks=0,U={},xt,nn;function tr(){let e=Ki();if(e&&B){e.mark&&I.performance.mark("sentry-tracing-init");let t=fl(),n=ll(),r=pl(),i=ml();return()=>{t(),n(),r(),i()}}return()=>{}}function er(){dt("longtask",({entries:e})=>{for(let t of e){let n=z();if(!n)return;let r=H(B+t.startTime),i=H(t.duration);n.startChild({description:"Main UI thread blocked",op:"ui.long-task",origin:"auto.ui.browser.metrics",startTimestamp:r,endTimestamp:r+i})}})}function nr(){dt("event",({entries:e})=>{for(let t of e){let n=z();if(!n)return;if(t.name==="click"){let r=H(B+t.startTime),i=H(t.duration),o={description:$t(t.target),op:`ui.interaction.${t.name}`,origin:"auto.ui.browser.metrics",startTimestamp:r,endTimestamp:r+i},s=Er(t.target);s&&(o.attributes={"ui.component_name":s}),n.startChild(o)}}})}function rr(e,t){if(Ki()&&B){let r=gl(e,t);return()=>{r()}}return()=>{}}function ll(){return Wi(({metric:e})=>{let t=e.entries[e.entries.length-1];t&&(b&&f.log("[Measurements] Adding CLS"),U.cls={value:e.value,unit:""},nn=t)},!0)}function pl(){return qi(({metric:e})=>{let t=e.entries[e.entries.length-1];t&&(b&&f.log("[Measurements] Adding LCP"),U.lcp={value:e.value,unit:"millisecond"},xt=t)},!0)}function fl(){return zi(({metric:e})=>{let t=e.entries[e.entries.length-1];if(!t)return;let n=H(B),r=H(t.startTime);b&&f.log("[Measurements] Adding FID"),U.fid={value:e.value,unit:"millisecond"},U["mark.fid"]={value:n+r,unit:"second"}})}function ml(){return js(({metric:e})=>{e.entries[e.entries.length-1]&&(b&&f.log("[Measurements] Adding TTFB"),U.ttfb={value:e.value,unit:"millisecond"})})}var Vs={click:"click",pointerdown:"click",pointerup:"click",mousedown:"click",mouseup:"click",touchstart:"click",touchend:"click",mouseover:"hover",mouseout:"hover",mouseenter:"hover",mouseleave:"hover",pointerover:"hover",pointerout:"hover",pointerenter:"hover",pointerleave:"hover",dragstart:"drag",dragend:"drag",drag:"drag",dragenter:"drag",dragleave:"drag",dragover:"drag",drop:"drag",keydown:"press",keyup:"press",keypress:"press",input:"press"};function gl(e,t){return Ws(({metric:n})=>{if(n.value===void 0)return;let r=n.entries.find(P=>P.duration===n.value&&Vs[P.name]!==void 0),i=C();if(!r||!i)return;let o=Vs[r.name],s=i.getOptions(),a=H(B+r.startTime),c=H(n.value),d=r.interactionId!==void 0?e[r.interactionId]:void 0;if(d===void 0)return;let{routeName:l,parentContext:p,activeTransaction:m,user:_,replayId:S}=d,T=_!==void 0?_.email||_.id||_.ip_address:void 0,y=m!==void 0?m.getProfileId():void 0,v=new oe({startTimestamp:a,endTimestamp:a+c,op:`ui.interaction.${o}`,name:$t(r.target),attributes:{release:s.release,environment:s.environment,transaction:l,...T!==void 0&&T!==""?{user:T}:{},...y!==void 0?{profile_id:y}:{},...S!==void 0?{replay_id:S}:{}},exclusiveTime:n.value,measurements:{inp:{value:n.value,unit:"millisecond"}}}),N=bl(p,s,t);if(N&&Math.random()<N){let P=v?Pi([v],i.getDsn()):void 0,vt=i&&i.getTransport();vt&&P&&vt.send(P).then(null,Kt=>{b&&f.error("Error while sending interaction:",Kt)});return}})}function ir(e){let t=Ki();if(!t||!I.performance.getEntries||!B)return;b&&f.log("[Tracing] Adding & adjusting spans using Performance API");let n=H(B),r=t.getEntries(),{op:i,start_timestamp:o}=R(e);if(r.slice(Ks).forEach(s=>{let a=H(s.startTime),c=H(s.duration);if(!(e.op==="navigation"&&o&&n+a<o))switch(s.entryType){case"navigation":{_l(e,s,n);break}case"mark":case"paint":case"measure":{hl(e,s,a,c,n);let d=ve(),l=s.startTime<d.firstHiddenTime;s.name==="first-paint"&&l&&(b&&f.log("[Measurements] Adding FP"),U.fp={value:s.startTime,unit:"millisecond"}),s.name==="first-contentful-paint"&&l&&(b&&f.log("[Measurements] Adding FCP"),U.fcp={value:s.startTime,unit:"millisecond"});break}case"resource":{El(e,s,s.name,a,c,n);break}}}),Ks=Math.max(r.length-1,0),Tl(e),i==="pageload"){Il(U),["fcp","fp","lcp"].forEach(a=>{if(!U[a]||!o||n>=o)return;let c=U[a].value,d=n+H(c),l=Math.abs((d-o)*1e3),p=l-c;b&&f.log(`[Measurements] Normalized ${a} from ${c} to ${l} (${p})`),U[a].value=l});let s=U["mark.fid"];s&&U.fid&&(ue(e,{description:"first input delay",endTimestamp:s.value+H(U.fid.value),op:"ui.action",origin:"auto.ui.browser.metrics",startTimestamp:s.value}),delete U["mark.fid"]),"fcp"in U||delete U.cls,Object.keys(U).forEach(a=>{Ti(a,U[a].value,U[a].unit)}),yl(e)}xt=void 0,nn=void 0,U={}}function hl(e,t,n,r,i){let o=i+n,s=o+r;return ue(e,{description:t.name,endTimestamp:s,op:t.entryType,origin:"auto.resource.browser.metrics",startTimestamp:o}),o}function _l(e,t,n){["unloadEvent","redirect","domContentLoadedEvent","loadEvent","connect"].forEach(r=>{Zn(e,t,r,n)}),Zn(e,t,"secureConnection",n,"TLS/SSL","connectEnd"),Zn(e,t,"fetch",n,"cache","domainLookupStart"),Zn(e,t,"domainLookup",n,"DNS"),Sl(e,t,n)}function Zn(e,t,n,r,i,o){let s=o?t[o]:t[`${n}End`],a=t[`${n}Start`];!a||!s||ue(e,{op:"browser",origin:"auto.browser.browser.metrics",description:i||n,startTimestamp:r+H(a),endTimestamp:r+H(s)})}function Sl(e,t,n){t.responseEnd&&(ue(e,{op:"browser",origin:"auto.browser.browser.metrics",description:"request",startTimestamp:n+H(t.requestStart),endTimestamp:n+H(t.responseEnd)}),ue(e,{op:"browser",origin:"auto.browser.browser.metrics",description:"response",startTimestamp:n+H(t.responseStart),endTimestamp:n+H(t.responseEnd)}))}function El(e,t,n,r,i,o){if(t.initiatorType==="xmlhttprequest"||t.initiatorType==="fetch")return;let s=jt(n),a={};Ji(a,t,"transferSize","http.response_transfer_size"),Ji(a,t,"encodedBodySize","http.response_content_length"),Ji(a,t,"decodedBodySize","http.decoded_response_content_length"),"renderBlockingStatus"in t&&(a["resource.render_blocking_status"]=t.renderBlockingStatus),s.protocol&&(a["url.scheme"]=s.protocol.split(":").pop()),s.host&&(a["server.address"]=s.host),a["url.same_origin"]=n.includes(I.location.origin);let c=o+r,d=c+i;ue(e,{description:n.replace(I.location.origin,""),endTimestamp:d,op:t.initiatorType?`resource.${t.initiatorType}`:"resource.other",origin:"auto.resource.browser.metrics",startTimestamp:c,data:a})}function Tl(e){let t=I.navigator;if(!t)return;let n=t.connection;n&&(n.effectiveType&&e.setTag("effectiveConnectionType",n.effectiveType),n.type&&e.setTag("connectionType",n.type),Qn(n.rtt)&&(U["connection.rtt"]={value:n.rtt,unit:"millisecond"})),Qn(t.deviceMemory)&&e.setTag("deviceMemory",`${t.deviceMemory} GB`),Qn(t.hardwareConcurrency)&&e.setTag("hardwareConcurrency",String(t.hardwareConcurrency))}function yl(e){xt&&(b&&f.log("[Measurements] Adding LCP Data"),xt.element&&e.setTag("lcp.element",$t(xt.element)),xt.id&&e.setTag("lcp.id",xt.id),xt.url&&e.setTag("lcp.url",xt.url.trim().slice(0,200)),e.setTag("lcp.size",xt.size)),nn&&nn.sources&&(b&&f.log("[Measurements] Adding CLS Data"),nn.sources.forEach((t,n)=>e.setTag(`cls.source.${n+1}`,$t(t.node))))}function Ji(e,t,n,r){let i=t[n];i!=null&&i<dl&&(e[r]=i)}function Il(e){let t=Jt();if(!t)return;let{responseStart:n,requestStart:r}=t;r<=n&&(b&&f.log("[Measurements] Adding TTFB Request Time"),e["ttfb.requestTime"]={value:n-r,unit:"millisecond"})}function bl(e,t,n){if(!at(t))return!1;let r;return e!==void 0&&typeof t.tracesSampler=="function"?r=t.tracesSampler({transactionContext:e,name:e.name,parentSampled:e.parentSampled,attributes:{...e.data,...e.attributes},location:I.location}):e!==void 0&&e.sampled!==void 0?r=e.sampled:typeof t.tracesSampleRate<"u"?r=t.tracesSampleRate:r=1,Mn(r)?r===!0?n:r===!1?0:r*n:(b&&f.warn("[Tracing] Discarding interaction span because of invalid sample rate."),!1)}u();function Xs(e,t=!0,n=!0){if(!I||!I.location){b&&f.warn("Could not initialize routing instrumentation due to invalid location");return}let r=I.location.href,i;t&&(i=e({name:I.location.pathname,startTimestamp:B?B/1e3:void 0,op:"pageload",origin:"auto.pageload.browser",metadata:{source:"url"}})),n&&Ue(({to:o,from:s})=>{if(s===void 0&&r&&r.indexOf(o)!==-1){r=void 0;return}s!==o&&(r=void 0,i&&(b&&f.log(`[Tracing] Finishing current transaction with op: ${i.op}`),i.end()),i=e({name:I.location.pathname,op:"navigation",origin:"auto.navigation.browser",metadata:{source:"url"}}))})}var ta="BrowserTracing",xl={...zt,markBackgroundTransactions:!0,routingInstrumentation:Xs,startTransactionOnLocationChange:!0,startTransactionOnPageLoad:!0,enableLongTask:!0,enableInp:!1,interactionsSampleRate:1,_experiments:{},...ce},Qs=10,Vi=class{constructor(t){this.name=ta,this._hasSetTracePropagationTargets=!1,ae(),b&&(this._hasSetTracePropagationTargets=!!(t&&(t.tracePropagationTargets||t.tracingOrigins))),this.options={...xl,...t},this.options._experiments.enableLongTask!==void 0&&(this.options.enableLongTask=this.options._experiments.enableLongTask),t&&!t.tracePropagationTargets&&t.tracingOrigins&&(this.options.tracePropagationTargets=t.tracingOrigins),this._collectWebVitals=tr(),this._interactionIdToRouteNameMapping={},this.options.enableInp&&rr(this._interactionIdToRouteNameMapping,this.options.interactionsSampleRate),this.options.enableLongTask&&er(),this.options._experiments.enableInteractions&&nr(),this._latestRoute={name:void 0,context:void 0}}setupOnce(t,n){this._getCurrentHub=n;let i=n().getClient(),o=i&&i.getOptions(),{routingInstrumentation:s,startTransactionOnLocationChange:a,startTransactionOnPageLoad:c,markBackgroundTransactions:d,traceFetch:l,traceXHR:p,shouldCreateSpanForRequest:m,enableHTTPTimings:_,_experiments:S}=this.options,T=o&&o.tracePropagationTargets,y=T||this.options.tracePropagationTargets;b&&this._hasSetTracePropagationTargets&&T&&f.warn("[Tracing] The `tracePropagationTargets` option was set in the BrowserTracing integration and top level `Sentry.init`. The top level `Sentry.init` value is being used."),s(v=>{let N=this._createRouteTransaction(v);return this.options._experiments.onStartRouteTransaction&&this.options._experiments.onStartRouteTransaction(N,v,n),N},c,a),d&&Xn(),S.enableInteractions&&this._registerInteractionListener(),this.options.enableInp&&this._registerInpInteractionListener(),en({traceFetch:l,traceXHR:p,tracePropagationTargets:y,shouldCreateSpanForRequest:m,enableHTTPTimings:_})}_createRouteTransaction(t){if(!this._getCurrentHub){b&&f.warn(`[Tracing] Did not create ${t.op} transaction because _getCurrentHub is invalid.`);return}let n=this._getCurrentHub(),{beforeNavigate:r,idleTimeout:i,finalTimeout:o,heartbeatInterval:s}=this.options,a=t.op==="pageload",c;if(a){let _=a?Zs("sentry-trace"):"",S=a?Zs("baggage"):void 0,{traceId:T,dsc:y,parentSpanId:v,sampled:N}=je(_,S);c={traceId:T,parentSpanId:v,parentSampled:N,...t,metadata:{...t.metadata,dynamicSamplingContext:y},trimEnd:!0}}else c={trimEnd:!0,...t};let d=typeof r=="function"?r(c):c,l=d===void 0?{...c,sampled:!1}:d;l.metadata=l.name!==c.name?{...l.metadata,source:"custom"}:l.metadata,this._latestRoute.name=l.name,this._latestRoute.context=l,l.sampled===!1&&b&&f.log(`[Tracing] Will not send ${l.op} transaction because of beforeNavigate.`),b&&f.log(`[Tracing] Starting ${l.op} transaction on scope`);let{location:p}=I,m=se(n,l,i,o,!0,{location:p},s,a);return a&&I.document&&(I.document.addEventListener("readystatechange",()=>{["interactive","complete"].includes(I.document.readyState)&&m.sendAutoFinishSignal()}),["interactive","complete"].includes(I.document.readyState)&&m.sendAutoFinishSignal()),m.registerBeforeFinishCallback(_=>{this._collectWebVitals(),ir(_)}),m}_registerInteractionListener(){let t,n=()=>{let{idleTimeout:r,finalTimeout:i,heartbeatInterval:o}=this.options,s="ui.action.click",a=z();if(a&&a.op&&["navigation","pageload"].includes(a.op)){b&&f.warn(`[Tracing] Did not create ${s} transaction because a pageload or navigation transaction is in progress.`);return}if(t&&(t.setFinishReason("interactionInterrupted"),t.end(),t=void 0),!this._getCurrentHub){b&&f.warn(`[Tracing] Did not create ${s} transaction because _getCurrentHub is invalid.`);return}if(!this._latestRoute.name){b&&f.warn(`[Tracing] Did not create ${s} transaction because _latestRouteName is missing.`);return}let c=this._getCurrentHub(),{location:d}=I,l={name:this._latestRoute.name,op:s,trimEnd:!0,data:{[G]:this._latestRoute.context?vl(this._latestRoute.context):"url"}};t=se(c,l,r,i,!0,{location:d},o)};["click"].forEach(r=>{I.document&&addEventListener(r,n,{once:!1,capture:!0})})}_registerInpInteractionListener(){let t=({entries:n})=>{let r=C(),i=r!==void 0&&r.getIntegrationByName!==void 0?r.getIntegrationByName("Replay"):void 0,o=i!==void 0?i.getReplayId():void 0,s=z(),a=L(),c=a!==void 0?a.getUser():void 0;n.forEach(d=>{if(Al(d)){let l=d.interactionId;if(l===void 0)return;let p=this._interactionIdToRouteNameMapping[l],m=d.duration,_=d.startTime,S=Object.keys(this._interactionIdToRouteNameMapping),T=S.length>0?S.reduce((y,v)=>this._interactionIdToRouteNameMapping[y].duration<this._interactionIdToRouteNameMapping[v].duration?y:v):void 0;if(d.entryType==="first-input"&&S.map(v=>this._interactionIdToRouteNameMapping[v]).some(v=>v.duration===m&&v.startTime===_)||!l)return;if(p)p.duration=Math.max(p.duration,m);else if(S.length<Qs||T===void 0||m>this._interactionIdToRouteNameMapping[T].duration){let y=this._latestRoute.name,v=this._latestRoute.context;y&&v&&(T&&Object.keys(this._interactionIdToRouteNameMapping).length>=Qs&&delete this._interactionIdToRouteNameMapping[T],this._interactionIdToRouteNameMapping[l]={routeName:y,duration:m,parentContext:v,user:c,activeTransaction:s,replayId:o,startTime:_})}}})};dt("event",t),dt("first-input",t)}};function Zs(e){let t=ke(`meta[name=${e}]`);return t?t.getAttribute("content"):void 0}function vl(e){let t=e.attributes&&e.attributes[G],n=e.data&&e.data[G],r=e.metadata&&e.metadata.source;return t||n||r}function Al(e){return"duration"in e}u();var Rl="BrowserTracing",Cl={...zt,instrumentNavigation:!0,instrumentPageLoad:!0,markBackgroundSpan:!0,enableLongTask:!0,enableInp:!1,interactionsSampleRate:1,_experiments:{},...ce},Ol=(e={})=>{let t=b?!!(e.tracePropagationTargets||e.tracingOrigins):!1;ae(),!e.tracePropagationTargets&&e.tracingOrigins&&(e.tracePropagationTargets=e.tracingOrigins);let n={...Cl,...e},r=tr(),i={};n.enableInp&&rr(i,n.interactionsSampleRate),n.enableLongTask&&er(),n._experiments.enableInteractions&&nr();let o={name:void 0,context:void 0};function s(a){let c=D(),{beforeStartSpan:d,idleTimeout:l,finalTimeout:p,heartbeatInterval:m}=n,_=a.op==="pageload",S;if(_){let N=_?ea("sentry-trace"):"",P=_?ea("baggage"):void 0,{traceId:vt,dsc:Kt,parentSpanId:pr,sampled:fr}=je(N,P);S={traceId:vt,parentSpanId:pr,parentSampled:fr,...a,metadata:{...a.metadata,dynamicSamplingContext:Kt},trimEnd:!0}}else S={trimEnd:!0,...a};let T=d?d(S):S;T.metadata=T.name!==S.name?{...T.metadata,source:"custom"}:T.metadata,o.name=T.name,o.context=T,T.sampled===!1&&b&&f.log(`[Tracing] Will not send ${T.op} transaction because of beforeNavigate.`),b&&f.log(`[Tracing] Starting ${T.op} transaction on scope`);let{location:y}=I,v=se(c,T,l,p,!0,{location:y},m,_);return _&&I.document&&(I.document.addEventListener("readystatechange",()=>{["interactive","complete"].includes(I.document.readyState)&&v.sendAutoFinishSignal()}),["interactive","complete"].includes(I.document.readyState)&&v.sendAutoFinishSignal()),v.registerBeforeFinishCallback(N=>{r(),ir(N)}),v}return{name:Rl,setupOnce:()=>{},afterAllSetup(a){let c=a.getOptions(),{markBackgroundSpan:d,traceFetch:l,traceXHR:p,shouldCreateSpanForRequest:m,enableHTTPTimings:_,_experiments:S}=n,T=c&&c.tracePropagationTargets,y=T||n.tracePropagationTargets;b&&t&&T&&f.warn("[Tracing] The `tracePropagationTargets` option was set in the BrowserTracing integration and top level `Sentry.init`. The top level `Sentry.init` value is being used.");let v,N=I.location&&I.location.href;if(a.on&&(a.on("startNavigationSpan",P=>{v&&(b&&f.log(`[Tracing] Finishing current transaction with op: ${R(v).op}`),v.end()),v=s({op:"navigation",...P})}),a.on("startPageLoadSpan",P=>{v&&(b&&f.log(`[Tracing] Finishing current transaction with op: ${R(v).op}`),v.end()),v=s({op:"pageload",...P})})),n.instrumentPageLoad&&a.emit&&I.location){let P={name:I.location.pathname,startTimestamp:B?B/1e3:void 0,origin:"auto.pageload.browser",attributes:{[G]:"url"}};ra(a,P)}n.instrumentNavigation&&a.emit&&I.location&&Ue(({to:P,from:vt})=>{if(vt===void 0&&N&&N.indexOf(P)!==-1){N=void 0;return}if(vt!==P){N=void 0;let Kt={name:I.location.pathname,origin:"auto.navigation.browser",attributes:{[G]:"url"}};ia(a,Kt)}}),d&&Xn(),S.enableInteractions&&Dl(n,o),n.enableInp&&kl(i,o),en({traceFetch:l,traceXHR:p,tracePropagationTargets:y,shouldCreateSpanForRequest:m,enableHTTPTimings:_})},options:n}};function ra(e,t){if(!e.emit)return;e.emit("startPageLoadSpan",t);let n=ie();return(n&&R(n).op)==="pageload"?n:void 0}function ia(e,t){if(!e.emit)return;e.emit("startNavigationSpan",t);let n=ie();return(n&&R(n).op)==="navigation"?n:void 0}function ea(e){let t=ke(`meta[name=${e}]`);return t?t.getAttribute("content"):void 0}function Dl(e,t){let n,r=()=>{let{idleTimeout:i,finalTimeout:o,heartbeatInterval:s}=e,a="ui.action.click",c=z();if(c&&c.op&&["navigation","pageload"].includes(c.op)){b&&f.warn(`[Tracing] Did not create ${a} transaction because a pageload or navigation transaction is in progress.`);return}if(n&&(n.setFinishReason("interactionInterrupted"),n.end(),n=void 0),!t.name){b&&f.warn(`[Tracing] Did not create ${a} transaction because _latestRouteName is missing.`);return}let{location:d}=I,l={name:t.name,op:a,trimEnd:!0,data:{[G]:t.context?wl(t.context):"url"}};n=se(D(),l,i,o,!0,{location:d},s)};["click"].forEach(i=>{I.document&&addEventListener(i,r,{once:!1,capture:!0})})}function Nl(e){return"duration"in e}var na=10;function kl(e,t){let n=({entries:r})=>{let i=C(),o=i!==void 0&&i.getIntegrationByName!==void 0?i.getIntegrationByName("Replay"):void 0,s=o!==void 0?o.getReplayId():void 0,a=z(),c=L(),d=c!==void 0?c.getUser():void 0;r.forEach(l=>{if(Nl(l)){let p=l.interactionId;if(p===void 0)return;let m=e[p],_=l.duration,S=l.startTime,T=Object.keys(e),y=T.length>0?T.reduce((v,N)=>e[v].duration<e[N].duration?v:N):void 0;if(l.entryType==="first-input"&&T.map(N=>e[N]).some(N=>N.duration===_&&N.startTime===S)||!p)return;if(m)m.duration=Math.max(m.duration,_);else if(T.length<na||y===void 0||_>e[y].duration){let v=t.name,N=t.context;v&&N&&(y&&Object.keys(e).length>=na&&delete e[y],e[p]={routeName:v,duration:_,parentContext:N,user:d,activeTransaction:a,replayId:s,startTime:S})}}})};dt("event",n),dt("first-input",n)}function wl(e){let t=e.attributes&&e.attributes[G],n=e.data&&e.data[G],r=e.metadata&&e.metadata.source;return t||n||r}u();u();u();function nt(e){let t=A([e,"call",r=>r(),"access",r=>r.getClient,"call",r=>r(),"optionalAccess",r=>r.getOptions,"call",r=>r()]);return(A([t,"optionalAccess",r=>r.instrumenter])||"sentry")!=="sentry"}var or=class e{static __initStatic(){this.id="Express"}constructor(t={}){this.name=e.id,this._router=t.router||t.app,this._methods=(Array.isArray(t.methods)?t.methods:[]).concat("use")}setupOnce(t,n){if(!this._router){b&&f.error("ExpressIntegration is missing an Express instance");return}if(nt(n)){b&&f.log("Express Integration is skipped because of instrumenter configuration.");return}Ll(this._router,this._methods),Ul(this._router)}};or.__initStatic();function oa(e,t){let n=e.length;switch(n){case 2:return function(r,i){let o=i.__sentry_transaction;if(o){let s=o.startChild({description:e.name,op:`middleware.express.${t}`,origin:"auto.middleware.express"});i.once("finish",()=>{s.end()})}return e.call(this,r,i)};case 3:return function(r,i,o){let s=i.__sentry_transaction,a=A([s,"optionalAccess",c=>c.startChild,"call",c=>c({description:e.name,op:`middleware.express.${t}`,origin:"auto.middleware.express"})]);e.call(this,r,i,function(...c){A([a,"optionalAccess",d=>d.end,"call",d=>d()]),o.call(this,...c)})};case 4:return function(r,i,o,s){let a=o.__sentry_transaction,c=A([a,"optionalAccess",d=>d.startChild,"call",d=>d({description:e.name,op:`middleware.express.${t}`,origin:"auto.middleware.express"})]);e.call(this,r,i,o,function(...d){A([c,"optionalAccess",l=>l.end,"call",l=>l()]),s.call(this,...d)})};default:throw new Error(`Express middleware takes 2-4 arguments. Got: ${n}`)}}function Ml(e,t){return e.map(n=>typeof n=="function"?oa(n,t):Array.isArray(n)?n.map(r=>typeof r=="function"?oa(r,t):r):n)}function Pl(e,t){let n=e[t];return e[t]=function(...r){return n.call(this,...Ml(r,t))},e}function Ll(e,t=[]){t.forEach(n=>Pl(e,n))}function Ul(e){let t="settings"in e;t&&e._router===void 0&&e.lazyrouter&&e.lazyrouter();let n=t?e._router:e;if(!n){b&&f.debug("Cannot instrument router for URL Parameterization (did not find a valid router)."),b&&f.debug("Routing instrumentation is currently only supported in Express 4.");return}let r=Object.getPrototypeOf(n),i=r.process_params;r.process_params=function(s,a,c,d,l){c._reconstructedRoute||(c._reconstructedRoute="");let{layerRoutePath:p,isRegex:m,isArray:_,numExtraSegments:S}=Bl(s);(p||m||_)&&(c._hasParameters=!0);let T;p?T=p:T=Gl(c.originalUrl,c._reconstructedRoute,s.path)||"";let y=T.split("/").filter(P=>P.length>0&&(m||_||!P.includes("*"))).join("/");y&&y.length>0&&(c._reconstructedRoute+=`/${y}${m?"/":""}`);let v=ge(Dt(c.originalUrl||""))+S,N=ge(c._reconstructedRoute);if(v===N){c._hasParameters||c._reconstructedRoute!==c.originalUrl&&(c._reconstructedRoute=c.originalUrl?Dt(c.originalUrl):c.originalUrl);let P=d.__sentry_transaction,vt=P&&R(P).data||{};if(P&&vt[G]!=="custom"){let Kt=c._reconstructedRoute||"/",[pr,fr]=Zt(c,{path:!0,method:!0,customRoute:Kt});P.updateName(pr),P.setAttribute(G,fr)}}return i.call(this,s,a,c,d,l)}}var Fl=(e,t,n)=>{if(!e||!t||!n||Object.keys(n).length===0||!A([n,"access",d=>d[0],"optionalAccess",d=>d.offset]))return;let r=n.sort((d,l)=>d.offset-l.offset),o=new RegExp(t,`${t.flags}d`).exec(e);if(!o||!o.indices)return;let[,...s]=o.indices;if(s.length!==r.length)return;let a=e,c=0;return s.forEach((d,l)=>{if(d){let[p,m]=d,_=a.substring(0,p-c),S=`:${r[l].name}`,T=a.substring(m-c);a=_+S+T,c=c+(m-p-S.length)}}),a};function Bl(e){let t=A([e,"access",s=>s.route,"optionalAccess",s=>s.path]),n=Re(t),r=Array.isArray(t);if(!t){let[s]=x.process.versions.node.split(".").map(Number);s>=16&&(t=Fl(e.path,e.regexp,e.keys))}if(!t)return{isRegex:n,isArray:r,numExtraSegments:0};let i=r?Math.max(Hl(t)-ge(e.path||""),0):0;return{layerRoutePath:$l(r,t),isRegex:n,isArray:r,numExtraSegments:i}}function Hl(e){return e.reduce((t,n)=>t+ge(n.toString()),0)}function $l(e,t){return e?t.map(n=>n.toString()).join(","):t&&t.toString()}function Gl(e,t,n){let r=Dt(e||""),i=A([r,"optionalAccess",c=>c.split,"call",c=>c("/"),"access",c=>c.filter,"call",c=>c(d=>!!d)]),o=0,s=A([t,"optionalAccess",c=>c.split,"call",c=>c("/"),"access",c=>c.filter,"call",c=>c(d=>!!d),"access",c=>c.length])||0;return A([n,"optionalAccess",c=>c.split,"call",c=>c("/"),"access",c=>c.filter,"call",c=>c(d=>A([i,"optionalAccess",l=>l[s+o]])===d?(o+=1,!0):!1),"access",c=>c.join,"call",c=>c("/")])}u();var sr=class e{static __initStatic(){this.id="Postgres"}constructor(t={}){this.name=e.id,this._usePgNative=!!t.usePgNative,this._module=t.module}loadDependency(){return this._module=this._module||st("pg")}setupOnce(t,n){if(nt(n)){b&&f.log("Postgres Integration is skipped because of instrumenter configuration.");return}let r=this.loadDependency();if(!r){b&&f.error("Postgres Integration was unable to require `pg` package.");return}let i=this._usePgNative?A([r,"access",o=>o.native,"optionalAccess",o=>o.Client]):r.Client;if(!i){b&&f.error("Postgres Integration was unable to access 'pg-native' bindings.");return}M(i.prototype,"query",function(o){return function(s,a,c){let l=n().getScope().getSpan(),p={"db.system":"postgresql"};try{this.database&&(p["db.name"]=this.database),this.host&&(p["server.address"]=this.host),this.port&&(p["server.port"]=this.port),this.user&&(p["db.user"]=this.user)}catch{}let m=A([l,"optionalAccess",S=>S.startChild,"call",S=>S({description:typeof s=="string"?s:s.text,op:"db",origin:"auto.db.postgres",data:p})]);if(typeof c=="function")return o.call(this,s,a,function(S,T){A([m,"optionalAccess",y=>y.end,"call",y=>y()]),c(S,T)});if(typeof a=="function")return o.call(this,s,function(S,T){A([m,"optionalAccess",y=>y.end,"call",y=>y()]),a(S,T)});let _=typeof a<"u"?o.call(this,s,a):o.call(this,s);return F(_)?_.then(S=>(A([m,"optionalAccess",T=>T.end,"call",T=>T()]),S)):(A([m,"optionalAccess",S=>S.end,"call",S=>S()]),_)}})}};sr.__initStatic();u();var ar=class e{static __initStatic(){this.id="Mysql"}constructor(){this.name=e.id}loadDependency(){return this._module=this._module||st("mysql/lib/Connection.js")}setupOnce(t,n){if(nt(n)){b&&f.log("Mysql Integration is skipped because of instrumenter configuration.");return}let r=this.loadDependency();if(!r){b&&f.error("Mysql Integration was unable to require `mysql` package.");return}let i;try{r.prototype.connect=new Proxy(r.prototype.connect,{apply(a,c,d){return i||(i=c.config),a.apply(c,d)}})}catch{b&&f.error("Mysql Integration was unable to instrument `mysql` config.")}function o(){return i?{"server.address":i.host,"server.port":i.port,"db.user":i.user}:{}}function s(a){if(!a)return;let c=o();Object.keys(c).forEach(d=>{a.setAttribute(d,c[d])}),a.end()}M(r,"createQuery",function(a){return function(c,d,l){let m=n().getScope().getSpan(),_=A([m,"optionalAccess",T=>T.startChild,"call",T=>T({description:typeof c=="string"?c:c.sql,op:"db",origin:"auto.db.mysql",data:{"db.system":"mysql"}})]);if(typeof l=="function")return a.call(this,c,d,function(T,y,v){s(_),l(T,y,v)});if(typeof d=="function")return a.call(this,c,function(T,y,v){s(_),d(T,y,v)});let S=a.call(this,c,d);return S.on("end",()=>{s(_)}),S}})}};ar.__initStatic();u();var jl=["aggregate","bulkWrite","countDocuments","createIndex","createIndexes","deleteMany","deleteOne","distinct","drop","dropIndex","dropIndexes","estimatedDocumentCount","find","findOne","findOneAndDelete","findOneAndReplace","findOneAndUpdate","indexes","indexExists","indexInformation","initializeOrderedBulkOp","insertMany","insertOne","isCapped","mapReduce","options","parallelCollectionScan","rename","replaceOne","stats","updateMany","updateOne"],Wl={bulkWrite:["operations"],countDocuments:["query"],createIndex:["fieldOrSpec"],createIndexes:["indexSpecs"],deleteMany:["filter"],deleteOne:["filter"],distinct:["key","query"],dropIndex:["indexName"],find:["query"],findOne:["query"],findOneAndDelete:["filter"],findOneAndReplace:["filter","replacement"],findOneAndUpdate:["filter","update"],indexExists:["indexes"],insertMany:["docs"],insertOne:["doc"],mapReduce:["map","reduce"],rename:["newName"],replaceOne:["filter","doc"],updateMany:["filter","update"],updateOne:["filter","update"]};function ql(e){return e&&typeof e=="object"&&e.once&&typeof e.once=="function"}var cr=class e{static __initStatic(){this.id="Mongo"}constructor(t={}){this.name=e.id,this._operations=Array.isArray(t.operations)?t.operations:jl,this._describeOperations="describeOperations"in t?t.describeOperations:!0,this._useMongoose=!!t.useMongoose}loadDependency(){let t=this._useMongoose?"mongoose":"mongodb";return this._module=this._module||st(t)}setupOnce(t,n){if(nt(n)){b&&f.log("Mongo Integration is skipped because of instrumenter configuration.");return}let r=this.loadDependency();if(!r){let i=this._useMongoose?"mongoose":"mongodb";b&&f.error(`Mongo Integration was unable to require \`${i}\` package.`);return}this._instrumentOperations(r.Collection,this._operations,n)}_instrumentOperations(t,n,r){n.forEach(i=>this._patchOperation(t,i,r))}_patchOperation(t,n,r){if(!(n in t.prototype))return;let i=this._getSpanContextFromOperationArguments.bind(this);M(t.prototype,n,function(o){return function(...s){let a=s[s.length-1],c=r(),d=c.getScope(),l=c.getClient(),p=d.getSpan(),m=A([l,"optionalAccess",S=>S.getOptions,"call",S=>S(),"access",S=>S.sendDefaultPii]);if(typeof a!="function"||n==="mapReduce"&&s.length===2){let S=A([p,"optionalAccess",y=>y.startChild,"call",y=>y(i(this,n,s,m))]),T=o.call(this,...s);if(F(T))return T.then(y=>(A([S,"optionalAccess",v=>v.end,"call",v=>v()]),y));if(ql(T)){let y=T;try{y.once("close",()=>{A([S,"optionalAccess",v=>v.end,"call",v=>v()])})}catch{A([S,"optionalAccess",N=>N.end,"call",N=>N()])}return y}else return A([S,"optionalAccess",y=>y.end,"call",y=>y()]),T}let _=A([p,"optionalAccess",S=>S.startChild,"call",S=>S(i(this,n,s.slice(0,-1)))]);return o.call(this,...s.slice(0,-1),function(S,T){A([_,"optionalAccess",y=>y.end,"call",y=>y()]),a(S,T)})}})}_getSpanContextFromOperationArguments(t,n,r,i=!1){let o={"db.system":"mongodb","db.name":t.dbName,"db.operation":n,"db.mongodb.collection":t.collectionName},s={op:"db",origin:"auto.db.mongo",description:n,data:o},a=Wl[n],c=Array.isArray(this._describeOperations)?this._describeOperations.includes(n):this._describeOperations;if(!a||!c||!i)return s;try{if(n==="mapReduce"){let[d,l]=r;o[a[0]]=typeof d=="string"?d:d.name||"<anonymous>",o[a[1]]=typeof l=="string"?l:l.name||"<anonymous>"}else for(let d=0;d<a.length;d++)o[`db.mongodb.${a[d]}`]=JSON.stringify(r[d])}catch{}return s}};cr.__initStatic();u();function zl(e){return!!e&&!!e.$use}var ur=class e{static __initStatic(){this.id="Prisma"}constructor(t={}){if(this.name=e.id,zl(t.client)&&!t.client._sentryInstrumented){X(t.client,"_sentryInstrumented",!0);let n={};try{let r=t.client._engineConfig;if(r){let{activeProvider:i,clientVersion:o}=r;i&&(n["db.system"]=i),o&&(n["db.prisma.version"]=o)}}catch{}t.client.$use((r,i)=>{if(nt(D))return i(r);let o=r.action,s=r.model;return hi({name:s?`${s} ${o}`:o,onlyIfParent:!0,op:"db.prisma",attributes:{[ct]:"auto.db.prisma"},data:{...n,"db.operation":o}},()=>i(r))})}else b&&f.warn("Unsupported Prisma client provided to PrismaIntegration. Provided client:",t.client)}setupOnce(){}};ur.__initStatic();u();var dr=class e{static __initStatic(){this.id="GraphQL"}constructor(){this.name=e.id}loadDependency(){return this._module=this._module||st("graphql/execution/execute.js")}setupOnce(t,n){if(nt(n)){b&&f.log("GraphQL Integration is skipped because of instrumenter configuration.");return}let r=this.loadDependency();if(!r){b&&f.error("GraphQL Integration was unable to require graphql/execution package.");return}M(r,"execute",function(i){return function(...o){let s=n().getScope(),a=s.getSpan(),c=A([a,"optionalAccess",l=>l.startChild,"call",l=>l({description:"execute",op:"graphql.execute",origin:"auto.graphql.graphql"})]);A([s,"optionalAccess",l=>l.setSpan,"call",l=>l(c)]);let d=i.call(this,...o);return F(d)?d.then(l=>(A([c,"optionalAccess",p=>p.end,"call",p=>p()]),A([s,"optionalAccess",p=>p.setSpan,"call",p=>p(a)]),l)):(A([c,"optionalAccess",l=>l.end,"call",l=>l()]),A([s,"optionalAccess",l=>l.setSpan,"call",l=>l(a)]),d)}})}};dr.__initStatic();u();var lr=class e{static __initStatic(){this.id="Apollo"}constructor(t={useNestjs:!1}){this.name=e.id,this._useNest=!!t.useNestjs}loadDependency(){return this._useNest?this._module=this._module||st("@nestjs/graphql"):this._module=this._module||st("apollo-server-core"),this._module}setupOnce(t,n){if(nt(n)){b&&f.log("Apollo Integration is skipped because of instrumenter configuration.");return}if(this._useNest){let r=this.loadDependency();if(!r){b&&f.error("Apollo-NestJS Integration was unable to require @nestjs/graphql package.");return}M(r.GraphQLFactory.prototype,"mergeWithSchema",function(i){return function(...o){return M(this.resolversExplorerService,"explore",function(s){return function(){let a=Gt(s.call(this));return sa(a,n)}}),i.call(this,...o)}})}else{let r=this.loadDependency();if(!r){b&&f.error("Apollo Integration was unable to require apollo-server-core package.");return}M(r.ApolloServerBase.prototype,"constructSchema",function(i){return function(){if(!this.config.resolvers)return b&&(this.config.schema?(f.warn("Apollo integration is not able to trace `ApolloServer` instances constructed via `schema` property.If you are using NestJS with Apollo, please use `Sentry.Integrations.Apollo({ useNestjs: true })` instead."),f.warn()):this.config.modules&&f.warn("Apollo integration is not able to trace `ApolloServer` instances constructed via `modules` property."),f.error("Skipping tracing as no resolvers found on the `ApolloServer` instance.")),i.call(this);let o=Gt(this.config.resolvers);return this.config.resolvers=sa(o,n),i.call(this)}})}}};lr.__initStatic();function sa(e,t){return e.map(n=>(Object.keys(n).forEach(r=>{Object.keys(n[r]).forEach(i=>{typeof n[r][i]=="function"&&Yl(n,r,i,t)})}),n))}function Yl(e,t,n,r){M(e[t],n,function(i){return function(...o){let a=r().getScope().getSpan(),c=A([a,"optionalAccess",l=>l.startChild,"call",l=>l({description:`${t}.${n}`,op:"graphql.resolve",origin:"auto.graphql.apollo"})]),d=i.call(this,...o);return F(d)?d.then(l=>(A([c,"optionalAccess",p=>p.end,"call",p=>p()]),l)):(A([c,"optionalAccess",l=>l.end,"call",l=>l()]),d)}})}u();var aa="CaptureConsole",Jl=(e={})=>{let t=e.levels||Xt;return{name:aa,setupOnce(){},setup(n){"console"in x&&vr(({args:r,level:i})=>{C()!==n||!t.includes(i)||Vl(r,i)})}}},ca=Jl,Kl=w(aa,ca);function Vl(e,t){let n={level:jr(t),extra:{arguments:e}};Lt(r=>{if(r.addEventProcessor(s=>(s.logger="console",Rt(s,{handled:!1,type:"console"}),s)),t==="assert"&&e[0]===!1){let s=`Assertion failed: ${on(e.slice(1)," ")||"console.assert"}`;r.setExtra("arguments",e.slice(1)),Ee(s,n);return}let i=e.find(s=>s instanceof Error);if(t==="error"&&i){li(i,n);return}let o=on(e," ");Ee(o,n)})}u();var ua="Debug",Xl=(e={})=>{let t={debugger:!1,stringify:!1,...e};return{name:ua,setupOnce(){},setup(n){n.on&&n.on("beforeSendEvent",(r,i)=>{if(t.debugger)debugger;ht(()=>{t.stringify?(console.log(JSON.stringify(r,null,2)),i&&Object.keys(i).length&&console.log(JSON.stringify(i,null,2))):(console.log(r),i&&Object.keys(i).length&&console.log(i))})})}}},da=Xl,Ql=w(ua,da);u();u();var Bt=typeof __SENTRY_DEBUG__>"u"||__SENTRY_DEBUG__;var fa="Dedupe",Zl=()=>{let e;return{name:fa,setupOnce(){},processEvent(t){if(t.type)return t;try{if(ep(t,e))return Bt&&f.warn("Event dropped due to being a duplicate of previously captured event."),null}catch{}return e=t}}},ma=Zl,tp=w(fa,ma);function ep(e,t){return t?!!(np(e,t)||rp(e,t)):!1}function np(e,t){let n=e.message,r=t.message;return!(!n&&!r||n&&!r||!n&&r||n!==r||!ha(e,t)||!ga(e,t))}function rp(e,t){let n=la(t),r=la(e);return!(!n||!r||n.type!==r.type||n.value!==r.value||!ha(e,t)||!ga(e,t))}function ga(e,t){let n=pa(e),r=pa(t);if(!n&&!r)return!0;if(n&&!r||!n&&r||(n=n,r=r,r.length!==n.length))return!1;for(let i=0;i<r.length;i++){let o=r[i],s=n[i];if(o.filename!==s.filename||o.lineno!==s.lineno||o.colno!==s.colno||o.function!==s.function)return!1}return!0}function ha(e,t){let n=e.fingerprint,r=t.fingerprint;if(!n&&!r)return!0;if(n&&!r||!n&&r)return!1;n=n,r=r;try{return n.join("")===r.join("")}catch{return!1}}function la(e){return e.exception&&e.exception.values&&e.exception.values[0]}function pa(e){let t=e.exception;if(t)try{return t.values[0].stacktrace.frames}catch{return}}u();var _a="ExtraErrorData",ip=(e={})=>{let t=e.depth||3,n=e.captureErrorCause||!1;return{name:_a,setupOnce(){},processEvent(r,i){return sp(r,i,t,n)}}},Sa=ip,op=w(_a,Sa);function sp(e,t={},n,r){if(!t.originalException||!mt(t.originalException))return e;let i=t.originalException.name||t.originalException.constructor.name,o=ap(t.originalException,r);if(o){let s={...e.contexts},a=K(o,n);return J(a)&&(X(a,"__sentry_skip_normalization__",!0),s[i]=a),{...e,contexts:s}}return e}function ap(e,t){try{let n=["name","message","stack","line","column","fileName","lineNumber","columnNumber","toJSON"],r={};for(let i of Object.keys(e)){if(n.indexOf(i)!==-1)continue;let o=e[i];r[i]=mt(o)?o.toString():o}if(t&&e.cause!==void 0&&(r.cause=mt(e.cause)?e.cause.toString():e.cause),typeof e.toJSON=="function"){let i=e.toJSON();for(let o of Object.keys(i)){let s=i[o];r[o]=mt(s)?s.toString():s}}return r}catch(n){Bt&&f.error("Unable to extract extra data from the Error object:",n)}return null}u();var cp=x,Ta="ReportingObserver",Ea=new WeakMap,up=(e={})=>{let t=e.types||["crash","deprecation","intervention"];function n(r){if(Ea.has(C()))for(let i of r)Lt(o=>{o.setExtra("url",i.url);let s=`ReportingObserver [${i.type}]`,a="No details available";if(i.body){let c={};for(let d in i.body)c[d]=i.body[d];if(o.setExtra("body",c),i.type==="crash"){let d=i.body;a=[d.crashId||"",d.reason||""].join(" ").trim()||a}else a=i.body.message||a}Ee(`${s}: ${a}`)})}return{name:Ta,setupOnce(){if(!Nr())return;new cp.ReportingObserver(n,{buffered:!0,types:t}).observe()},setup(r){Ea.set(r,!0)}}},ya=up,dp=w(Ta,ya);u();var Ia="RewriteFrames",lp=(e={})=>{let t=e.root,n=e.prefix||"app:///",r=e.iteratee||(s=>{if(!s.filename)return s;let a=/^[a-zA-Z]:\\/.test(s.filename)||s.filename.includes("\\")&&!s.filename.includes("/"),c=/^\//.test(s.filename);if(a||c){let d=a?s.filename.replace(/^[a-zA-Z]:/,"").replace(/\\/g,"/"):s.filename,l=t?Fr(t,d):Br(d);s.filename=`${n}${l}`}return s});function i(s){try{return{...s,exception:{...s.exception,values:s.exception.values.map(a=>({...a,...a.stacktrace&&{stacktrace:o(a.stacktrace)}}))}}}catch{return s}}function o(s){return{...s,frames:s&&s.frames&&s.frames.map(a=>r(a))}}return{name:Ia,setupOnce(){},processEvent(s){let a=s;return s.exception&&Array.isArray(s.exception.values)&&(a=i(a)),a}}},ba=lp,pp=w(Ia,ba);u();var xa="SessionTiming",fp=()=>{let e=Date.now();return{name:xa,setupOnce(){},processEvent(t){let n=Date.now();return{...t,extra:{...t.extra,"session:start":e,"session:duration":n-e,"session:end":n}}}}},va=fp,mp=w(xa,va);u();var Aa="HttpClient",gp=(e={})=>{let t={failedRequestStatusCodes:[[500,599]],failedRequestTargets:[/.*/],...e};return{name:Aa,setupOnce(){},setup(n){xp(n,t),vp(n,t)}}},Ra=gp,hp=w(Aa,Ra);function _p(e,t,n,r){if(Oa(e,n.status,n.url)){let i=Ap(t,r),o,s,a,c;Na()&&([{headers:o,cookies:a},{headers:s,cookies:c}]=[{cookieHeader:"Cookie",obj:i},{cookieHeader:"Set-Cookie",obj:n}].map(({cookieHeader:l,obj:p})=>{let m=Tp(p.headers),_;try{let S=m[l]||m[l.toLowerCase()]||void 0;S&&(_=Ca(S))}catch{Bt&&f.log(`Could not extract cookies from header ${l}`)}return{headers:m,cookies:_}}));let d=Da({url:i.url,method:i.method,status:n.status,requestHeaders:o,responseHeaders:s,requestCookies:a,responseCookies:c});Cn(d)}}function Sp(e,t,n,r){if(Oa(e,t.status,t.responseURL)){let i,o,s;if(Na()){try{let c=t.getResponseHeader("Set-Cookie")||t.getResponseHeader("set-cookie")||void 0;c&&(o=Ca(c))}catch{Bt&&f.log("Could not extract cookies from response headers")}try{s=yp(t)}catch{Bt&&f.log("Could not extract headers from response")}i=r}let a=Da({url:t.responseURL,method:n,status:t.status,requestHeaders:i,responseHeaders:s,responseCookies:o});Cn(a)}}function Ep(e){if(e){let t=e["Content-Length"]||e["content-length"];if(t)return parseInt(t,10)}}function Ca(e){return e.split("; ").reduce((t,n)=>{let[r,i]=n.split("=");return t[r]=i,t},{})}function Tp(e){let t={};return e.forEach((n,r)=>{t[r]=n}),t}function yp(e){let t=e.getAllResponseHeaders();return t?t.split(`\r
27
27
  `).reduce((n,r)=>{let[i,o]=r.split(": ");return n[i]=o,n},{}):{}}function Ip(e,t){return e.some(n=>typeof n=="string"?t.includes(n):n.test(t))}function bp(e,t){return e.some(n=>typeof n=="number"?n===t:t>=n[0]&&t<=n[1])}function xp(e,t){Me()&&Pe(n=>{if(C()!==e)return;let{response:r,args:i}=n,[o,s]=i;r&&_p(t,o,r,s)})}function vp(e,t){"XMLHttpRequest"in x&&Fe(n=>{if(C()!==e)return;let r=n.xhr,i=r[Ct];if(!i)return;let{method:o,request_headers:s}=i;try{Sp(t,r,o,s)}catch(a){Bt&&f.warn("Error while extracting response event form XHR response",a)}})}function Oa(e,t,n){return bp(e.failedRequestStatusCodes,t)&&Ip(e.failedRequestTargets,n)&&!Li(n,C())}function Da(e){let t=`HTTP Client Error with status code: ${e.status}`,n={message:t,exception:{values:[{type:"Error",value:t}]},request:{url:e.url,method:e.method,headers:e.requestHeaders,cookies:e.requestCookies},contexts:{response:{status_code:e.status,headers:e.responseHeaders,cookies:e.responseCookies,body_size:Ep(e.responseHeaders)}}};return Rt(n,{type:"http.client",handled:!1}),n}function Ap(e,t){return!t&&e instanceof Request||e instanceof Request&&e.bodyUsed?e:new Request(e,t)}function Na(){let e=C();return e?!!e.getOptions().sendDefaultPii:!1}u();var Xi=x,Rp=7,ka="ContextLines",Cp=(e={})=>{let t=e.frameContextLines!=null?e.frameContextLines:Rp;return{name:ka,setupOnce(){},processEvent(n){return Dp(n,t)}}},wa=Cp,Op=w(ka,wa);function Dp(e,t){let n=Xi.document,r=Xi.location&&Dt(Xi.location.href);if(!n||!r)return e;let i=e.exception&&e.exception.values;if(!i||!i.length)return e;let o=n.documentElement.innerHTML;if(!o)return e;let s=["<!DOCTYPE html>","<html>",...o.split(`
28
28
  `),"</html>"];return i.forEach(a=>{let c=a.stacktrace;c&&c.frames&&(c.frames=c.frames.map(d=>Np(d,s,r,t)))}),e}function Np(e,t,n,r){return e.filename!==n||!e.lineno||!t.length||Rr(t,e,r),e}u();export{mt as a,Pa as b,La as c,Ua as d,Y as e,le as f,rn as g,J as h,mr as i,on as j,Ht as k,Sr as l,x as m,$t as n,$a as o,Er as p,ht as q,f as r,it as s,M as t,X as u,oo as v,yr as w,br as x,k as y,lo as z,Ka as A,Qt as B,Va as C,vr as D,O as E,At as F,Ar as G,Rt as H,Za as I,Rr as J,ec as K,_o as L,Dr as M,Pe as N,wr as O,Mr as P,Ue as Q,Ct as R,Fe as S,mc as T,hn as U,gc as V,K as W,Sn as X,bc as Y,pt as Z,Be as _,lt as $,jt as aa,xc as ba,jr as ca,W as da,B as ea,$e as fa,te as ga,q as ha,Nt as ia,Kr as ja,wc as ka,yn as la,Xr as ma,Pc as na,Qr as oa,Zr as pa,ri as qa,Uc as ra,A as sa,Fc as ta,kt as ua,ii as va,Pt as wa,R as xa,di as ya,li as za,Ee as Aa,Cn as Ba,ou as Ca,su as Da,au as Ea,cu as Fa,uu as Ga,du as Ha,lu as Ia,pu as Ja,Lt as Ka,fu as La,mu as Ma,gu as Na,hu as Oa,_u as Pa,Su as Qa,C as Ra,Eu as Sa,L as Ta,Tu as Ua,pi as Va,yu as Wa,St as Xa,tt as Ya,An as Za,Et as _a,ai as $a,Se as ab,Ye as bb,qt as cb,ci as db,D as eb,et as fb,Rn as gb,z as hb,Iu as ib,mi as jb,bu as kb,re as lb,at as mb,vu as nb,hi as ob,Au as pb,Je as qb,ie as rb,Ru as sb,G as tb,Ut as ub,Te as vb,ct as wb,ae as xb,Ti as yb,xi as zb,Bu as Ab,wu as Bb,Mu as Cb,w as Db,Qe as Eb,Ju as Fb,wi as Gb,Ku as Hb,ts as Ib,Qu as Jb,Nd as Kb,ed as Lb,Li as Mb,nd as Nb,Ld as Ob,cs as Pb,sd as Qb,ys as Rb,Fd as Sb,ds as Tb,vi as Ub,ms as Vb,Ai as Wb,bs as Xb,Ad as Yb,pI as Zb,or as _b,sr as $b,ar as ac,cr as bc,ur as cc,dr as dc,lr as ec,qi as fc,dt as gc,ce as hc,en as ic,Vi as jc,Ol as kc,ra as lc,ia as mc,ca as nc,da as oc,ma as pc,Sa as qc,ya as rc,ba as sc,va as tc,Ra as uc,wa as vc};
29
- //# sourceMappingURL=chunk-NK4GGGL4.js.map
29
+ //# sourceMappingURL=chunk-ZRY56TPY.js.map