@wellesley/sentry 1.0.21 → 1.0.25

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (2) hide show
  1. package/index.mjs +3 -3
  2. package/package.json +1 -1
package/index.mjs CHANGED
@@ -1,4 +1,4 @@
1
- import{logErrorToSentry as Uc}from"https://cdn.jsdelivr.net/npm/@wellesley/sentry@1.0.21";function jc(e,t){for(var n=0;n<t.length;n++){const r=t[n];if("string"!=typeof r&&!Array.isArray(r))for(const t in r)if("default"!==t&&!(t in e)){const n=Object.getOwnPropertyDescriptor(r,t);n&&Object.defineProperty(e,t,n.get?n:{enumerable:!0,get:()=>r[t]})}}return Object.freeze(Object.defineProperty(e,Symbol.toStringTag,{value:"Module"}))}const V=typeof __SENTRY_DEBUG__>"u"||__SENTRY_DEBUG__,nt="8.48.0",j=globalThis;function Hn(e,t,n){const r=j,o=r.__SENTRY__=r.__SENTRY__||{},s=o[nt]=o[nt]||{};return s[e]||(s[e]=t())}const ct=typeof __SENTRY_DEBUG__>"u"||__SENTRY_DEBUG__,Bc="Sentry Logger ",Or=["debug","info","warn","error","log","assert","trace"],kn={};function Je(e){if(!("console"in j))return e();const t=j.console,n={},r=Object.keys(kn);r.forEach((e=>{const r=kn[e];n[e]=t[e],t[e]=r}));try{return e()}finally{r.forEach((e=>{t[e]=n[e]}))}}function $c(){let e=!1;const t={enable:()=>{e=!0},disable:()=>{e=!1},isEnabled:()=>e};return ct?Or.forEach((n=>{t[n]=(...t)=>{e&&Je((()=>{j.console[n](`${Bc}[${n}]:`,...t)}))}})):Or.forEach((e=>{t[e]=()=>{}})),t}const C=Hn("logger",$c),Oi=50,rt="?",Xs=/\(error: (.*)\)/,Qs=/captureMessage|captureException/;function Di(...e){const t=e.sort(((e,t)=>e[0]-t[0])).map((e=>e[1]));return(e,n=0,r=0)=>{const o=[],s=e.split("\n");for(let e=n;e<s.length;e++){const n=s[e];if(n.length>1024)continue;const i=Xs.test(n)?n.replace(Xs,"$1"):n;if(!i.match(/\S*Error: /)){for(const e of t){const t=e(i);if(t){o.push(t);break}}if(o.length>=50+r)break}}return zc(o.slice(r))}}function Hc(e){return Array.isArray(e)?Di(...e):e}function zc(e){if(!e.length)return[];const t=Array.from(e);return/sentryWrapped/.test(an(t).function||"")&&t.pop(),t.reverse(),Qs.test(an(t).function||"")&&(t.pop(),Qs.test(an(t).function||"")&&t.pop()),t.slice(0,50).map((e=>({...e,filename:e.filename||an(t).filename,function:e.function||rt})))}function an(e){return e[e.length-1]||{}}const pr="<anonymous>";function je(e){try{return e&&"function"==typeof e&&e.name||pr}catch{return pr}}function Zs(e){const t=e.exception;if(t){const e=[];try{return t.values.forEach((t=>{t.stacktrace.frames&&e.push(...t.stacktrace.frames)})),e}catch{return}}}const vn={},eo={};function ut(e,t){vn[e]=vn[e]||[],vn[e].push(t)}function lt(e,t){if(!eo[e]){eo[e]=!0;try{t()}catch(t){ct&&C.error(`Error while instrumenting ${e}`,t)}}}function Ce(e,t){const n=e&&vn[e];if(n)for(const r of n)try{r(t)}catch(t){ct&&C.error(`Error while triggering instrumentation handler.\nType: ${e}\nName: ${je(r)}\nError:`,t)}}let hr=null;function Wc(e){const t="error";ut(t,e),lt(t,Gc)}function Gc(){hr=j.onerror,j.onerror=function(e,t,n,r,o){return Ce("error",{column:r,error:o,line:n,msg:e,url:t}),!!hr&&hr.apply(this,arguments)},j.onerror.__SENTRY_INSTRUMENTED__=!0}let mr=null;function Yc(e){const t="unhandledrejection";ut(t,e),lt(t,qc)}function qc(){mr=j.onunhandledrejection,j.onunhandledrejection=function(e){return Ce("unhandledrejection",e),!mr||mr.apply(this,arguments)},j.onunhandledrejection.__SENTRY_INSTRUMENTED__=!0}function Kt(){return ps(j),j}function ps(e){const t=e.__SENTRY__=e.__SENTRY__||{};return t.version=t.version||nt,t[nt]=t[nt]||{}}const Ai=Object.prototype.toString;function hs(e){switch(Ai.call(e)){case"[object Error]":case"[object Exception]":case"[object DOMException]":case"[object WebAssembly.Exception]":return!0;default:return st(e,Error)}}function Dt(e,t){return Ai.call(e)===`[object ${t}]`}function xi(e){return Dt(e,"ErrorEvent")}function to(e){return Dt(e,"DOMError")}function Kc(e){return Dt(e,"DOMException")}function Le(e){return Dt(e,"String")}function ms(e){return"object"==typeof e&&null!==e&&"__sentry_template_string__"in e&&"__sentry_template_values__"in e}function _s(e){return null===e||ms(e)||"object"!=typeof e&&"function"!=typeof e}function St(e){return Dt(e,"Object")}function zn(e){return typeof Event<"u"&&st(e,Event)}function Vc(e){return typeof Element<"u"&&st(e,Element)}function Jc(e){return Dt(e,"RegExp")}function Wn(e){return!(!e||!e.then||"function"!=typeof e.then)}function Xc(e){return St(e)&&"nativeEvent"in e&&"preventDefault"in e&&"stopPropagation"in e}function st(e,t){try{return e instanceof t}catch{return!1}}function Ni(e){return!("object"!=typeof e||null===e||!e.__isVue&&!e._isVue)}const gs=j,Qc=80;function Gn(e,t={}){if(!e)return"<unknown>";try{let n=e;const r=5,o=[];let s=0,i=0;const a=" > ",c=a.length;let u;const l=Array.isArray(t)?t:t.keyAttrs,d=!Array.isArray(t)&&t.maxStringLength||80;for(;n&&s++<r&&(u=Zc(n,l),!("html"===u||s>1&&i+o.length*c+u.length>=d));)o.push(u),i+=u.length,n=n.parentNode;return o.reverse().join(a)}catch{return"<unknown>"}}function Zc(e,t){const n=e,r=[];if(!n||!n.tagName)return"";if(gs.HTMLElement&&n instanceof HTMLElement&&n.dataset){if(n.dataset.sentryComponent)return n.dataset.sentryComponent;if(n.dataset.sentryElement)return n.dataset.sentryElement}r.push(n.tagName.toLowerCase());const o=t&&t.length?t.filter((e=>n.getAttribute(e))).map((e=>[e,n.getAttribute(e)])):null;if(o&&o.length)o.forEach((e=>{r.push(`[${e[0]}="${e[1]}"]`)}));else{n.id&&r.push(`#${n.id}`);const e=n.className;if(e&&Le(e)){const t=e.split(/\s+/);for(const e of t)r.push(`.${e}`)}}const s=["aria-label","type","name","title","alt"];for(const e of s){const t=n.getAttribute(e);t&&r.push(`[${e}="${t}"]`)}return r.join("")}function Pi(){try{return gs.document.location.href}catch{return""}}function eu(e){if(!gs.HTMLElement)return null;let t=e;for(let e=0;e<5;e++){if(!t)return null;if(t instanceof HTMLElement){if(t.dataset.sentryComponent)return t.dataset.sentryComponent;if(t.dataset.sentryElement)return t.dataset.sentryElement}t=t.parentNode}return null}function Et(e,t=0){return"string"!=typeof e||0===t||e.length<=t?e:`${e.slice(0,t)}...`}function no(e,t){if(!Array.isArray(e))return"";const n=[];for(let t=0;t<e.length;t++){const r=e[t];try{Ni(r)?n.push("[VueViewModel]"):n.push(String(r))}catch{n.push("[value cannot be serialized]")}}return n.join(t)}function tu(e,t,n=!1){return!!Le(e)&&(Jc(t)?t.test(e):!!Le(t)&&(n?e===t:e.includes(t)))}function Vt(e,t=[],n=!1){return t.some((t=>tu(e,t,n)))}function pe(e,t,n){if(!(t in e))return;const r=e[t],o=n(r);"function"==typeof o&&Li(o,r);try{e[t]=o}catch{ct&&C.log(`Failed to replace method "${t}" in object`,e)}}function ot(e,t,n){try{Object.defineProperty(e,t,{value:n,writable:!0,configurable:!0})}catch{ct&&C.log(`Failed to add non-enumerable property "${t}" to object`,e)}}function Li(e,t){try{const n=t.prototype||{};e.prototype=t.prototype=n,ot(e,"__sentry_original__",t)}catch{}}function ys(e){return e.__sentry_original__}function Fi(e){if(hs(e))return{message:e.message,name:e.name,stack:e.stack,...so(e)};if(zn(e)){const t={type:e.type,target:ro(e.target),currentTarget:ro(e.currentTarget),...so(e)};return typeof CustomEvent<"u"&&st(e,CustomEvent)&&(t.detail=e.detail),t}return e}function ro(e){try{return Vc(e)?Gn(e):Object.prototype.toString.call(e)}catch{return"<unknown>"}}function so(e){if("object"==typeof e&&null!==e){const t={};for(const n in e)Object.prototype.hasOwnProperty.call(e,n)&&(t[n]=e[n]);return t}return{}}function nu(e,t=40){const n=Object.keys(Fi(e));n.sort();const r=n[0];if(!r)return"[object has no keys]";if(r.length>=t)return Et(r,t);for(let e=n.length;e>0;e--){const r=n.slice(0,e).join(", ");if(!(r.length>t))return e===n.length?r:Et(r,t)}return""}function he(e){return Dr(e,new Map)}function Dr(e,t){if(ru(e)){const n=t.get(e);if(void 0!==n)return n;const r={};t.set(e,r);for(const n of Object.getOwnPropertyNames(e))typeof e[n]<"u"&&(r[n]=Dr(e[n],t));return r}if(Array.isArray(e)){const n=t.get(e);if(void 0!==n)return n;const r=[];return t.set(e,r),e.forEach((e=>{r.push(Dr(e,t))})),r}return e}function ru(e){if(!St(e))return!1;try{const t=Object.getPrototypeOf(e).constructor.name;return!t||"Object"===t}catch{return!0}}const Ui=1e3;function Jt(){return Date.now()/Ui}function su(){const{performance:e}=j;if(!e||!e.now)return Jt;const t=Date.now()-e.now(),n=null==e.timeOrigin?t:e.timeOrigin;return()=>(n+e.now())/Ui}const Fe=su(),ou=(()=>{const{performance:e}=j;if(!e||!e.now)return;const t=36e5,n=e.now(),r=Date.now(),o=e.timeOrigin?Math.abs(e.timeOrigin+n-r):t,s=o<t,i=e.timing&&e.timing.navigationStart,a="number"==typeof i?Math.abs(i+n-r):t;return s||a<t?o<=a?e.timeOrigin:i:r})();function ge(){const e=j,t=e.crypto||e.msCrypto;let n=()=>16*Math.random();try{if(t&&t.randomUUID)return t.randomUUID().replace(/-/g,"");t&&t.getRandomValues&&(n=()=>{const e=new Uint8Array(1);return t.getRandomValues(e),e[0]})}catch{}return"10000000100040008000100000000000".replace(/[018]/g,(e=>(e^(15&n())>>e/4).toString(16)))}function ji(e){return e.exception&&e.exception.values?e.exception.values[0]:void 0}function He(e){const{message:t,event_id:n}=e;if(t)return t;const r=ji(e);return r?r.type&&r.value?`${r.type}: ${r.value}`:r.type||r.value||n||"<unknown>":n||"<unknown>"}function Ar(e,t,n){const r=e.exception=e.exception||{},o=r.values=r.values||[],s=o[0]=o[0]||{};s.value||(s.value=t||""),s.type||(s.type="Error")}function bt(e,t){const n=ji(e);if(!n)return;const r=n.mechanism;if(n.mechanism={type:"generic",handled:!0,...r,...t},t&&"data"in t){const e={...r&&r.data,...t.data};n.mechanism.data=e}}function oo(e){if(iu(e))return!0;try{ot(e,"__sentry_captured__",!0)}catch{}return!1}function iu(e){try{return e.__sentry_captured__}catch{}}var Ne;function Be(e){return new ve((t=>{t(e)}))}function Rn(e){return new ve(((t,n)=>{n(e)}))}!function(e){e[e.PENDING=0]="PENDING";e[e.RESOLVED=1]="RESOLVED";e[e.REJECTED=2]="REJECTED"}(Ne||(Ne={}));class ve{constructor(e){ve.prototype.__init.call(this),ve.prototype.__init2.call(this),ve.prototype.__init3.call(this),ve.prototype.__init4.call(this),this._state=Ne.PENDING,this._handlers=[];try{e(this._resolve,this._reject)}catch(e){this._reject(e)}}then(e,t){return new ve(((n,r)=>{this._handlers.push([!1,t=>{if(e)try{n(e(t))}catch(e){r(e)}else n(t)},e=>{if(t)try{n(t(e))}catch(e){r(e)}else r(e)}]),this._executeHandlers()}))}catch(e){return this.then((e=>e),e)}finally(e){return new ve(((t,n)=>{let r,o;return this.then((t=>{o=!1,r=t,e&&e()}),(t=>{o=!0,r=t,e&&e()})).then((()=>{o?n(r):t(r)}))}))}__init(){this._resolve=e=>{this._setResult(Ne.RESOLVED,e)}}__init2(){this._reject=e=>{this._setResult(Ne.REJECTED,e)}}__init3(){this._setResult=(e,t)=>{if(this._state===Ne.PENDING){if(Wn(t))return void t.then(this._resolve,this._reject);this._state=e,this._value=t,this._executeHandlers()}}}__init4(){this._executeHandlers=()=>{if(this._state===Ne.PENDING)return;const e=this._handlers.slice();this._handlers=[],e.forEach((e=>{e[0]||(this._state===Ne.RESOLVED&&e[1](this._value),this._state===Ne.REJECTED&&e[2](this._value),e[0]=!0)}))}}}function au(e){const t=Fe(),n={sid:ge(),init:!0,timestamp:t,started:t,duration:0,status:"ok",errors:0,ignoreDuration:!1,toJSON:()=>uu(n)};return vt(n,e),n}function vt(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||Fe(),t.abnormal_mechanism&&(e.abnormal_mechanism=t.abnormal_mechanism),t.ignoreDuration&&(e.ignoreDuration=t.ignoreDuration),t.sid&&(e.sid=32===t.sid.length?t.sid:ge()),void 0!==t.init&&(e.init=t.init),!e.did&&t.did&&(e.did=`${t.did}`),"number"==typeof t.started&&(e.started=t.started),e.ignoreDuration)e.duration=void 0;else if("number"==typeof t.duration)e.duration=t.duration;else{const t=e.timestamp-e.started;e.duration=t>=0?t: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),"number"==typeof t.errors&&(e.errors=t.errors),t.status&&(e.status=t.status)}function cu(e,t){let n={};"ok"===e.status&&(n={status:"exited"}),vt(e,n)}function uu(e){return he({sid:`${e.sid}`,init:e.init,started:new Date(1e3*e.started).toISOString(),timestamp:new Date(1e3*e.timestamp).toISOString(),status:e.status,errors:e.errors,did:"number"==typeof e.did||"string"==typeof e.did?`${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}})}function io(){return ge()}function xr(){return ge().substring(16)}function Yn(e,t,n=2){if(!t||"object"!=typeof t||n<=0)return t;if(e&&t&&0===Object.keys(t).length)return e;const r={...e};for(const e in t)Object.prototype.hasOwnProperty.call(t,e)&&(r[e]=Yn(r[e],t[e],n-1));return r}const Nr="_sentrySpan";function ao(e,t){t?ot(e,Nr,t):delete e[Nr]}function Pr(e){return e[Nr]}const lu=100;class Es{constructor(){this._notifyingListeners=!1,this._scopeListeners=[],this._eventProcessors=[],this._breadcrumbs=[],this._attachments=[],this._user={},this._tags={},this._extra={},this._contexts={},this._sdkProcessingMetadata={},this._propagationContext={traceId:io(),spanId:xr()}}clone(){const e=new Es;return e._breadcrumbs=[...this._breadcrumbs],e._tags={...this._tags},e._extra={...this._extra},e._contexts={...this._contexts},this._contexts.flags&&(e._contexts.flags={values:[...this._contexts.flags.values]}),e._user=this._user,e._level=this._level,e._session=this._session,e._transactionName=this._transactionName,e._fingerprint=this._fingerprint,e._eventProcessors=[...this._eventProcessors],e._requestSession=this._requestSession,e._attachments=[...this._attachments],e._sdkProcessingMetadata={...this._sdkProcessingMetadata},e._propagationContext={...this._propagationContext},e._client=this._client,e._lastEventId=this._lastEventId,ao(e,Pr(this)),e}setClient(e){this._client=e}setLastEventId(e){this._lastEventId=e}getClient(){return this._client}lastEventId(){return this._lastEventId}addScopeListener(e){this._scopeListeners.push(e)}addEventProcessor(e){return this._eventProcessors.push(e),this}setUser(e){return this._user=e||{email:void 0,id:void 0,ip_address:void 0,username:void 0},this._session&&vt(this._session,{user:e}),this._notifyScopeListeners(),this}getUser(){return this._user}getRequestSession(){return this._requestSession}setRequestSession(e){return this._requestSession=e,this}setTags(e){return this._tags={...this._tags,...e},this._notifyScopeListeners(),this}setTag(e,t){return this._tags={...this._tags,[e]:t},this._notifyScopeListeners(),this}setExtras(e){return this._extra={...this._extra,...e},this._notifyScopeListeners(),this}setExtra(e,t){return this._extra={...this._extra,[e]:t},this._notifyScopeListeners(),this}setFingerprint(e){return this._fingerprint=e,this._notifyScopeListeners(),this}setLevel(e){return this._level=e,this._notifyScopeListeners(),this}setTransactionName(e){return this._transactionName=e,this._notifyScopeListeners(),this}setContext(e,t){return null===t?delete this._contexts[e]:this._contexts[e]=t,this._notifyScopeListeners(),this}setSession(e){return e?this._session=e:delete this._session,this._notifyScopeListeners(),this}getSession(){return this._session}update(e){if(!e)return this;const t="function"==typeof e?e(this):e,[n,r]=t instanceof it?[t.getScopeData(),t.getRequestSession()]:St(t)?[e,e.requestSession]:[],{tags:o,extra:s,user:i,contexts:a,level:c,fingerprint:u=[],propagationContext:l}=n||{};return this._tags={...this._tags,...o},this._extra={...this._extra,...s},this._contexts={...this._contexts,...a},i&&Object.keys(i).length&&(this._user=i),c&&(this._level=c),u.length&&(this._fingerprint=u),l&&(this._propagationContext=l),r&&(this._requestSession=r),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._session=void 0,ao(this,void 0),this._attachments=[],this.setPropagationContext({traceId:io()}),this._notifyScopeListeners(),this}addBreadcrumb(e,t){const n="number"==typeof t?t:lu;if(n<=0)return this;const r={timestamp:Jt(),...e},o=this._breadcrumbs;return o.push(r),this._breadcrumbs=o.length>n?o.slice(-n):o,this._notifyScopeListeners(),this}getLastBreadcrumb(){return this._breadcrumbs[this._breadcrumbs.length-1]}clearBreadcrumbs(){return this._breadcrumbs=[],this._notifyScopeListeners(),this}addAttachment(e){return this._attachments.push(e),this}clearAttachments(){return this._attachments=[],this}getScopeData(){return{breadcrumbs:this._breadcrumbs,attachments:this._attachments,contexts:this._contexts,tags:this._tags,extra:this._extra,user:this._user,level:this._level,fingerprint:this._fingerprint||[],eventProcessors:this._eventProcessors,propagationContext:this._propagationContext,sdkProcessingMetadata:this._sdkProcessingMetadata,transactionName:this._transactionName,span:Pr(this)}}setSDKProcessingMetadata(e){return this._sdkProcessingMetadata=Yn(this._sdkProcessingMetadata,e,2),this}setPropagationContext(e){return this._propagationContext={spanId:xr(),...e},this}getPropagationContext(){return this._propagationContext}captureException(e,t){const n=t&&t.event_id?t.event_id:ge();if(!this._client)return C.warn("No client configured on scope - will not capture exception!"),n;const r=new Error("Sentry syntheticException");return this._client.captureException(e,{originalException:e,syntheticException:r,...t,event_id:n},this),n}captureMessage(e,t,n){const r=n&&n.event_id?n.event_id:ge();if(!this._client)return C.warn("No client configured on scope - will not capture message!"),r;const o=new Error(e);return this._client.captureMessage(e,t,{originalException:e,syntheticException:o,...n,event_id:r},this),r}captureEvent(e,t){const n=t&&t.event_id?t.event_id:ge();return this._client?(this._client.captureEvent(e,{...t,event_id:n},this),n):(C.warn("No client configured on scope - will not capture event!"),n)}_notifyScopeListeners(){this._notifyingListeners||(this._notifyingListeners=!0,this._scopeListeners.forEach((e=>{e(this)})),this._notifyingListeners=!1)}}const it=Es;function du(){return Hn("defaultCurrentScope",(()=>new it))}function fu(){return Hn("defaultIsolationScope",(()=>new it))}class pu{constructor(e,t){let n,r;n=e||new it,r=t||new it,this._stack=[{scope:n}],this._isolationScope=r}withScope(e){const t=this._pushScope();let n;try{n=e(t)}catch(e){throw this._popScope(),e}return Wn(n)?n.then((e=>(this._popScope(),e)),(e=>{throw this._popScope(),e})):(this._popScope(),n)}getClient(){return this.getStackTop().client}getScope(){return this.getStackTop().scope}getIsolationScope(){return this._isolationScope}getStackTop(){return this._stack[this._stack.length-1]}_pushScope(){const e=this.getScope().clone();return this._stack.push({client:this.getClient(),scope:e}),e}_popScope(){return!(this._stack.length<=1)&&!!this._stack.pop()}}function It(){const e=ps(Kt());return e.stack=e.stack||new pu(du(),fu())}function hu(e){return It().withScope(e)}function mu(e,t){const n=It();return n.withScope((()=>(n.getStackTop().scope=e,t(e))))}function co(e){return It().withScope((()=>e(It().getIsolationScope())))}function _u(){return{withIsolationScope:co,withScope:hu,withSetScope:mu,withSetIsolationScope:(e,t)=>co(t),getCurrentScope:()=>It().getScope(),getIsolationScope:()=>It().getIsolationScope()}}function qn(e){const t=ps(e);return t.acs?t.acs:_u()}function be(){return qn(Kt()).getCurrentScope()}function Ae(){return qn(Kt()).getIsolationScope()}function gu(){return Hn("globalScope",(()=>new it))}function yu(...e){const t=qn(Kt());if(2===e.length){const[n,r]=e;return n?t.withSetScope(n,r):t.withScope(r)}return t.withScope(e[0])}function ie(){return be().getClient()}function Eu(e){const t=e.getPropagationContext(),{traceId:n,spanId:r,parentSpanId:o}=t;return he({trace_id:n,span_id:r,parent_span_id:o})}const Su="_sentryMetrics";function bu(e){const t=e[Su];if(!t)return;const n={};for(const[,[e,r]]of t)(n[e]||(n[e]=[])).push(he(r));return n}const Bi="sentry.source",vu="sentry.sample_rate",Iu="sentry.op",wu="sentry.origin",Tu=0,ku=1,Ru="sentry-",Cu=/^sentry-/;function Mu(e){const t=Ou(e);if(!t)return;const n=Object.entries(t).reduce(((e,[t,n])=>{if(t.match(Cu)){e[t.slice(7)]=n}return e}),{});return Object.keys(n).length>0?n:void 0}function Ou(e){if(e&&(Le(e)||Array.isArray(e)))return Array.isArray(e)?e.reduce(((e,t)=>{const n=uo(t);return Object.entries(n).forEach((([t,n])=>{e[t]=n})),e}),{}):uo(e)}function uo(e){return e.split(",").map((e=>e.split("=").map((e=>decodeURIComponent(e.trim()))))).reduce(((e,[t,n])=>(t&&n&&(e[t]=n),e)),{})}const Du=1;let lo=!1;function Au(e){const{spanId:t,traceId:n,isRemote:r}=e.spanContext();return he({parent_span_id:r?t:jt(e).parent_span_id,span_id:r?xr():t,trace_id:n})}function fo(e){return"number"==typeof e?po(e):Array.isArray(e)?e[0]+e[1]/1e9:e instanceof Date?po(e.getTime()):Fe()}function po(e){return e>9999999999?e/1e3:e}function jt(e){if(Nu(e))return e.getSpanJSON();try{const{spanId:t,traceId:n}=e.spanContext();if(xu(e)){const{attributes:r,startTime:o,name:s,endTime:i,parentSpanId:a,status:c}=e;return he({span_id:t,trace_id:n,data:r,description:s,parent_span_id:a,start_timestamp:fo(o),timestamp:fo(i)||void 0,status:Lu(c),op:r[Iu],origin:r[wu],_metrics_summary:bu(e)})}return{span_id:t,trace_id:n}}catch{return{}}}function xu(e){const t=e;return!!(t.attributes&&t.startTime&&t.name&&t.endTime&&t.status)}function Nu(e){return"function"==typeof e.getSpanJSON}function Pu(e){const{traceFlags:t}=e.spanContext();return 1===t}function Lu(e){if(e&&0!==e.code)return 1===e.code?"ok":e.message||"unknown_error"}const Fu="_sentryRootSpan";function Ss(e){return e[Fu]||e}function $i(){const e=qn(Kt());return e.getActiveSpan?e.getActiveSpan():Pr(be())}function Uu(){lo||(Je((()=>{console.warn("[Sentry] Deprecation warning: Returning null from `beforeSendSpan` will be disallowed from SDK version 9.0.0 onwards. The callback will only support mutating spans. To drop certain spans, configure the respective integrations directly.")})),lo=!0)}function ju(e){if("boolean"==typeof __SENTRY_TRACING__&&!__SENTRY_TRACING__)return!1;const t=ie(),n=t&&t.getOptions();return!!n&&(n.enableTracing||"tracesSampleRate"in n||"tracesSampler"in n)}const bs="production",Bu="_frozenDsc";function Hi(e,t){const n=t.getOptions(),{publicKey:r}=t.getDsn()||{},o=he({environment:n.environment||bs,release:n.release,public_key:r,trace_id:e});return t.emit("createDsc",o),o}function $u(e,t){const n=t.getPropagationContext();return n.dsc||Hi(n.traceId,e)}function zi(e){const t=ie();if(!t)return{};const n=Ss(e),r=n[Bu];if(r)return r;const o=n.spanContext().traceState,s=o&&o.get("sentry.dsc"),i=s&&Mu(s);if(i)return i;const a=Hi(e.spanContext().traceId,t),c=jt(n),u=c.data||{},l=u[vu];null!=l&&(a.sample_rate=`${l}`);const d=u[Bi],p=c.description;return"url"!==d&&p&&(a.transaction=p),ju()&&(a.sampled=String(Pu(n))),t.emit("createDsc",a,n),a}function Lr(e){if("boolean"==typeof e)return Number(e);const t="string"==typeof e?parseFloat(e):e;if(!("number"!=typeof t||isNaN(t)||t<0||t>1))return t;V&&C.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)}.`)}const Hu=/^(?:(\w+):)\/\/(?:(\w+)(?::(\w+)?)?@)([\w.-]+)(?::(\d+))?\/(.+)/;function zu(e){return"http"===e||"https"===e}function Kn(e,t=!1){const{host:n,path:r,pass:o,port:s,projectId:i,protocol:a,publicKey:c}=e;return`${a}://${c}${t&&o?`:${o}`:""}@${n}${s?`:${s}`:""}/${r&&`${r}/`}${i}`}function Wu(e){const t=Hu.exec(e);if(!t)return void Je((()=>{console.error(`Invalid Sentry Dsn: ${e}`)}));const[n,r,o="",s="",i="",a=""]=t.slice(1);let c="",u=a;const l=u.split("/");if(l.length>1&&(c=l.slice(0,-1).join("/"),u=l.pop()),u){const e=u.match(/^\d+/);e&&(u=e[0])}return Wi({host:s,pass:o,path:c,projectId:u,port:i,protocol:n,publicKey:r})}function Wi(e){return{protocol:e.protocol,publicKey:e.publicKey||"",pass:e.pass||"",host:e.host,port:e.port||"",path:e.path||"",projectId:e.projectId}}function Gu(e){if(!ct)return!0;const{port:t,projectId:n,protocol:r}=e;return!["protocol","publicKey","host","projectId"].find((t=>!e[t]&&(C.error(`Invalid Sentry Dsn: ${t} missing`),!0)))&&(n.match(/^\d+$/)?zu(r)?!t||!isNaN(parseInt(t,10))||(C.error(`Invalid Sentry Dsn: Invalid port ${t}`),!1):(C.error(`Invalid Sentry Dsn: Invalid protocol ${r}`),!1):(C.error(`Invalid Sentry Dsn: Invalid projectId ${n}`),!1))}function Yu(e){const t="string"==typeof e?Wu(e):Wi(e);if(t&&Gu(t))return t}function qu(){const e="function"==typeof WeakSet,t=e?new WeakSet:[];return[function(n){if(e)return!!t.has(n)||(t.add(n),!1);for(let e=0;e<t.length;e++)if(t[e]===n)return!0;return t.push(n),!1},function(n){if(e)t.delete(n);else for(let e=0;e<t.length;e++)if(t[e]===n){t.splice(e,1);break}}]}function Te(e,t=100,n=1/0){try{return Fr("",e,t,n)}catch(e){return{ERROR:`**non-serializable** (${e})`}}}function Gi(e,t=3,n=102400){const r=Te(e,t);return Xu(r)>n?Gi(e,t-1,n):r}function Fr(e,t,n=1/0,r=1/0,o=qu()){const[s,i]=o;if(null==t||["boolean","string"].includes(typeof t)||"number"==typeof t&&Number.isFinite(t))return t;const a=Ku(e,t);if(!a.startsWith("[object "))return a;if(t.__sentry_skip_normalization__)return t;const c="number"==typeof t.__sentry_override_normalization_depth__?t.__sentry_override_normalization_depth__:n;if(0===c)return a.replace("object ","");if(s(t))return"[Circular ~]";const u=t;if(u&&"function"==typeof u.toJSON)try{return Fr("",u.toJSON(),c-1,r,o)}catch{}const l=Array.isArray(t)?[]:{};let d=0;const p=Fi(t);for(const e in p){if(!Object.prototype.hasOwnProperty.call(p,e))continue;if(d>=r){l[e]="[MaxProperties ~]";break}const t=p[e];l[e]=Fr(e,t,c-1,r,o),d++}return i(t),l}function Ku(e,t){try{if("domain"===e&&t&&"object"==typeof t&&t._events)return"[Domain]";if("domainEmitter"===e)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(Ni(t))return"[VueViewModel]";if(Xc(t))return"[SyntheticEvent]";if("number"==typeof t&&!Number.isFinite(t))return`[${t}]`;if("function"==typeof t)return`[Function: ${je(t)}]`;if("symbol"==typeof t)return`[${String(t)}]`;if("bigint"==typeof t)return`[BigInt: ${String(t)}]`;const n=Vu(t);return/^HTML(\w*)Element$/.test(n)?`[HTMLElement: ${n}]`:`[object ${n}]`}catch(e){return`**non-serializable** (${e})`}}function Vu(e){const t=Object.getPrototypeOf(e);return t?t.constructor.name:"null prototype"}function Ju(e){return~-encodeURI(e).split(/%..|./).length}function Xu(e){return Ju(JSON.stringify(e))}function At(e,t=[]){return[e,t]}function Qu(e,t){const[n,r]=e;return[n,[...r,t]]}function ho(e,t){const n=e[1];for(const e of n){if(t(e,e[0].type))return!0}return!1}function Ur(e){return j.__SENTRY__&&j.__SENTRY__.encodePolyfill?j.__SENTRY__.encodePolyfill(e):(new TextEncoder).encode(e)}function Zu(e){const[t,n]=e;let r=JSON.stringify(t);function o(e){"string"==typeof r?r="string"==typeof e?r+e:[Ur(r),e]:r.push("string"==typeof e?Ur(e):e)}for(const e of n){const[t,n]=e;if(o(`\n${JSON.stringify(t)}\n`),"string"==typeof n||n instanceof Uint8Array)o(n);else{let e;try{e=JSON.stringify(n)}catch{e=JSON.stringify(Te(n))}o(e)}}return"string"==typeof r?r:el(r)}function el(e){const t=e.reduce(((e,t)=>e+t.length),0),n=new Uint8Array(t);let r=0;for(const t of e)n.set(t,r),r+=t.length;return n}function tl(e){const t="string"==typeof e.data?Ur(e.data):e.data;return[he({type:"attachment",length:t.length,filename:e.filename,content_type:e.contentType,attachment_type:e.attachmentType}),t]}const nl={session:"session",sessions:"session",attachment:"attachment",transaction:"transaction",event:"error",client_report:"internal",user_report:"default",profile:"profile",profile_chunk:"profile",replay_event:"replay",replay_recording:"replay",check_in:"monitor",feedback:"feedback",span:"span",statsd:"metric_bucket",raw_security:"security"};function mo(e){return nl[e]}function vs(e){if(!e||!e.sdk)return;const{name:t,version:n}=e.sdk;return{name:t,version:n}}function Yi(e,t,n,r){const o=e.sdkProcessingMetadata&&e.sdkProcessingMetadata.dynamicSamplingContext;return{event_id:e.event_id,sent_at:(new Date).toISOString(),...t&&{sdk:t},...!!n&&r&&{dsn:Kn(r)},...o&&{trace:he({...o})}}}function rl(e,t){return t&&(e.sdk=e.sdk||{},e.sdk.name=e.sdk.name||t.name,e.sdk.version=e.sdk.version||t.version,e.sdk.integrations=[...e.sdk.integrations||[],...t.integrations||[]],e.sdk.packages=[...e.sdk.packages||[],...t.packages||[]]),e}function sl(e,t,n,r){const o=vs(n);return At({sent_at:(new Date).toISOString(),...o&&{sdk:o},...!!r&&t&&{dsn:Kn(t)}},["aggregates"in e?[{type:"sessions"},e]:[{type:"session"},e.toJSON()]])}function ol(e,t,n,r){const o=vs(n),s=e.type&&"replay_event"!==e.type?e.type:"event";rl(e,n&&n.sdk);const i=Yi(e,o,r,t);return delete e.sdkProcessingMetadata,At(i,[[{type:s},e]])}function jr(e,t,n,r=0){return new ve(((o,s)=>{const i=e[r];if(null===t||"function"!=typeof i)o(t);else{const a=i({...t},n);V&&i.id&&null===a&&C.log(`Event processor "${i.id}" dropped event`),Wn(a)?a.then((t=>jr(e,t,n,r+1).then(o))).then(null,s):jr(e,a,n,r+1).then(o).then(null,s)}}))}let cn,_o,un;function il(e){const t=j._sentryDebugIds;if(!t)return{};const n=Object.keys(t);return un&&n.length===_o||(_o=n.length,un=n.reduce(((n,r)=>{cn||(cn={});const o=cn[r];if(o)n[o[0]]=o[1];else{const o=e(r);for(let e=o.length-1;e>=0;e--){const s=o[e],i=s&&s.filename,a=t[r];if(i&&a){n[i]=a,cn[r]=[i,a];break}}}return n}),{})),un}function al(e,t){const{fingerprint:n,span:r,breadcrumbs:o,sdkProcessingMetadata:s}=t;cl(e,t),r&&dl(e,r),fl(e,n),ul(e,o),ll(e,s)}function go(e,t){const{extra:n,tags:r,user:o,contexts:s,level:i,sdkProcessingMetadata:a,breadcrumbs:c,fingerprint:u,eventProcessors:l,attachments:d,propagationContext:p,transactionName:h,span:m}=t;ln(e,"extra",n),ln(e,"tags",r),ln(e,"user",o),ln(e,"contexts",s),e.sdkProcessingMetadata=Yn(e.sdkProcessingMetadata,a,2),i&&(e.level=i),h&&(e.transactionName=h),m&&(e.span=m),c.length&&(e.breadcrumbs=[...e.breadcrumbs,...c]),u.length&&(e.fingerprint=[...e.fingerprint,...u]),l.length&&(e.eventProcessors=[...e.eventProcessors,...l]),d.length&&(e.attachments=[...e.attachments,...d]),e.propagationContext={...e.propagationContext,...p}}function ln(e,t,n){e[t]=Yn(e[t],n,1)}function cl(e,t){const{extra:n,tags:r,user:o,contexts:s,level:i,transactionName:a}=t,c=he(n);c&&Object.keys(c).length&&(e.extra={...c,...e.extra});const u=he(r);u&&Object.keys(u).length&&(e.tags={...u,...e.tags});const l=he(o);l&&Object.keys(l).length&&(e.user={...l,...e.user});const d=he(s);d&&Object.keys(d).length&&(e.contexts={...d,...e.contexts}),i&&(e.level=i),a&&"transaction"!==e.type&&(e.transaction=a)}function ul(e,t){const n=[...e.breadcrumbs||[],...t];e.breadcrumbs=n.length?n:void 0}function ll(e,t){e.sdkProcessingMetadata={...e.sdkProcessingMetadata,...t}}function dl(e,t){e.contexts={trace:Au(t),...e.contexts},e.sdkProcessingMetadata={dynamicSamplingContext:zi(t),...e.sdkProcessingMetadata};const n=jt(Ss(t)).description;n&&!e.transaction&&"transaction"===e.type&&(e.transaction=n)}function fl(e,t){e.fingerprint=e.fingerprint?Array.isArray(e.fingerprint)?e.fingerprint:[e.fingerprint]:[],t&&(e.fingerprint=e.fingerprint.concat(t)),e.fingerprint&&!e.fingerprint.length&&delete e.fingerprint}function qi(e,t,n,r,o,s){const{normalizeDepth:i=3,normalizeMaxBreadth:a=1e3}=e,c={...t,event_id:t.event_id||n.event_id||ge(),timestamp:t.timestamp||Jt()},u=n.integrations||e.integrations.map((e=>e.name));pl(c,e),_l(c,u),o&&o.emit("applyFrameMetadata",t),void 0===t.type&&hl(c,e.stackParser);const l=yl(r,n.captureContext);n.mechanism&&bt(c,n.mechanism);const d=o?o.getEventProcessors():[],p=gu().getScopeData();if(s){go(p,s.getScopeData())}if(l){go(p,l.getScopeData())}const h=[...n.attachments||[],...p.attachments];h.length&&(n.attachments=h),al(c,p);return jr([...d,...p.eventProcessors],c,n).then((e=>(e&&ml(e),"number"==typeof i&&i>0?gl(e,i,a):e)))}function pl(e,t){const{environment:n,release:r,dist:o,maxValueLength:s=250}=t;e.environment=e.environment||n||bs,!e.release&&r&&(e.release=r),!e.dist&&o&&(e.dist=o),e.message&&(e.message=Et(e.message,s));const i=e.exception&&e.exception.values&&e.exception.values[0];i&&i.value&&(i.value=Et(i.value,s));const a=e.request;a&&a.url&&(a.url=Et(a.url,s))}function hl(e,t){const n=il(t);try{e.exception.values.forEach((e=>{e.stacktrace.frames.forEach((e=>{n&&e.filename&&(e.debug_id=n[e.filename])}))}))}catch{}}function ml(e){const t={};try{e.exception.values.forEach((e=>{e.stacktrace.frames.forEach((e=>{e.debug_id&&(e.abs_path?t[e.abs_path]=e.debug_id:e.filename&&(t[e.filename]=e.debug_id),delete e.debug_id)}))}))}catch{}if(0===Object.keys(t).length)return;e.debug_meta=e.debug_meta||{},e.debug_meta.images=e.debug_meta.images||[];const n=e.debug_meta.images;Object.entries(t).forEach((([e,t])=>{n.push({type:"sourcemap",code_file:e,debug_id:t})}))}function _l(e,t){t.length>0&&(e.sdk=e.sdk||{},e.sdk.integrations=[...e.sdk.integrations||[],...t])}function gl(e,t,n){if(!e)return null;const r={...e,...e.breadcrumbs&&{breadcrumbs:e.breadcrumbs.map((e=>({...e,...e.data&&{data:Te(e.data,t,n)}})))},...e.user&&{user:Te(e.user,t,n)},...e.contexts&&{contexts:Te(e.contexts,t,n)},...e.extra&&{extra:Te(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=Te(e.contexts.trace.data,t,n))),e.spans&&(r.spans=e.spans.map((e=>({...e,...e.data&&{data:Te(e.data,t,n)}})))),e.contexts&&e.contexts.flags&&r.contexts&&(r.contexts.flags=Te(e.contexts.flags,3,n)),r}function yl(e,t){if(!t)return e;const n=e?e.clone():new it;return n.update(t),n}function Is(e,t){return be().captureException(e,void 0)}function El(e,t){const n={captureContext:t};return be().captureMessage(e,void 0,n)}function Ki(e,t){return be().captureEvent(e,t)}function Vi(e,t){Ae().setContext(e,t)}function Sl(e,t){Ae().setExtra(e,t)}function bl(e){Ae().setUser(e)}function vl(e){Ae().addEventProcessor(e)}function yo(e){const t=ie(),n=Ae(),r=be(),{release:o,environment:s=bs}=t&&t.getOptions()||{},{userAgent:i}=j.navigator||{},a=au({release:o,environment:s,user:r.getUser()||n.getUser(),...i&&{userAgent:i},...e}),c=n.getSession();return c&&"ok"===c.status&&vt(c,{status:"exited"}),Ji(),n.setSession(a),r.setSession(a),a}function Ji(){const e=Ae(),t=be(),n=t.getSession()||e.getSession();n&&cu(n),Xi(),e.setSession(),t.setSession()}function Xi(){const e=Ae(),t=be(),n=ie(),r=t.getSession()||e.getSession();r&&n&&n.captureSession(r)}function Eo(e=!1){e?Ji():Xi()}const Il="7";function wl(e){const t=e.protocol?`${e.protocol}:`:"",n=e.port?`:${e.port}`:"";return`${t}//${e.host}${n}${e.path?`/${e.path}`:""}/api/`}function Tl(e){return`${wl(e)}${e.projectId}/envelope/`}function kl(e,t){const n={sentry_version:Il};return e.publicKey&&(n.sentry_key=e.publicKey),t&&(n.sentry_client=`${t.name}/${t.version}`),new URLSearchParams(n).toString()}function Rl(e,t,n){return t||`${Tl(e)}?${kl(e,n)}`}const So=[];function Cl(e){const t={};return e.forEach((e=>{const{name:n}=e,r=t[n];r&&!r.isDefaultInstance&&e.isDefaultInstance||(t[n]=e)})),Object.values(t)}function Ml(e){const t=e.defaultIntegrations||[],n=e.integrations;let r;if(t.forEach((e=>{e.isDefaultInstance=!0})),Array.isArray(n))r=[...t,...n];else if("function"==typeof n){const e=n(t);r=Array.isArray(e)?e:[e]}else r=t;const o=Cl(r),s=o.findIndex((e=>"Debug"===e.name));if(s>-1){const[e]=o.splice(s,1);o.push(e)}return o}function Ol(e,t){const n={};return t.forEach((t=>{t&&Qi(e,t,n)})),n}function bo(e,t){for(const n of t)n&&n.afterAllSetup&&n.afterAllSetup(e)}function Qi(e,t,n){if(n[t.name])V&&C.log(`Integration skipped because it was already installed: ${t.name}`);else{if(n[t.name]=t,-1===So.indexOf(t.name)&&"function"==typeof t.setupOnce&&(t.setupOnce(),So.push(t.name)),t.setup&&"function"==typeof t.setup&&t.setup(e),"function"==typeof t.preprocessEvent){const n=t.preprocessEvent.bind(t);e.on("preprocessEvent",((t,r)=>n(t,r,e)))}if("function"==typeof t.processEvent){const n=t.processEvent.bind(t),r=Object.assign(((t,r)=>n(t,r,e)),{id:t.name});e.addEventProcessor(r)}V&&C.log(`Integration installed: ${t.name}`)}}function Dl(e,t,n){return At(t?{dsn:t}:{},[[{type:"client_report"},{timestamp:Jt(),discarded_events:e}]])}class Me extends Error{constructor(e,t="warn"){super(e),this.message=e,this.name=new.target.prototype.constructor.name,Object.setPrototypeOf(this,new.target.prototype),this.logLevel=t}}const vo="Not capturing exception because it's already been captured.";class Al{constructor(e){if(this._options=e,this._integrations={},this._numProcessing=0,this._outcomes={},this._hooks={},this._eventProcessors=[],e.dsn?this._dsn=Yu(e.dsn):V&&C.warn("No DSN provided, client will not send events."),this._dsn){const t=Rl(this._dsn,e.tunnel,e._metadata?e._metadata.sdk:void 0);this._transport=e.transport({tunnel:this._options.tunnel,recordDroppedEvent:this.recordDroppedEvent.bind(this),...e.transportOptions,url:t})}const t=["enableTracing","tracesSampleRate","tracesSampler"].find((t=>t in e&&null==e[t]));t&&Je((()=>{console.warn(`[Sentry] Deprecation warning: \`${t}\` is set to undefined, which leads to tracing being enabled. In v9, a value of \`undefined\` will result in tracing being disabled.`)}))}captureException(e,t,n){const r=ge();if(oo(e))return V&&C.log(vo),r;const o={event_id:r,...t};return this._process(this.eventFromException(e,o).then((e=>this._captureEvent(e,o,n)))),o.event_id}captureMessage(e,t,n,r){const o={event_id:ge(),...n},s=ms(e)?e:String(e),i=_s(e)?this.eventFromMessage(s,t,o):this.eventFromException(e,o);return this._process(i.then((e=>this._captureEvent(e,o,r)))),o.event_id}captureEvent(e,t,n){const r=ge();if(t&&t.originalException&&oo(t.originalException))return V&&C.log(vo),r;const o={event_id:r,...t},s=(e.sdkProcessingMetadata||{}).capturedSpanScope;return this._process(this._captureEvent(e,o,s||n)),o.event_id}captureSession(e){"string"!=typeof e.release?V&&C.warn("Discarded session because of missing or non-string release"):(this.sendSession(e),vt(e,{init:!1}))}getDsn(){return this._dsn}getOptions(){return this._options}getSdkMetadata(){return this._options._metadata}getTransport(){return this._transport}flush(e){const t=this._transport;return t?(this.emit("flush"),this._isClientDoneProcessing(e).then((n=>t.flush(e).then((e=>n&&e))))):Be(!0)}close(e){return this.flush(e).then((e=>(this.getOptions().enabled=!1,this.emit("close"),e)))}getEventProcessors(){return this._eventProcessors}addEventProcessor(e){this._eventProcessors.push(e)}init(){(this._isEnabled()||this._options.integrations.some((({name:e})=>e.startsWith("Spotlight"))))&&this._setupIntegrations()}getIntegrationByName(e){return this._integrations[e]}addIntegration(e){const t=this._integrations[e.name];Qi(this,e,this._integrations),t||bo(this,[e])}sendEvent(e,t={}){this.emit("beforeSendEvent",e,t);let n=ol(e,this._dsn,this._options._metadata,this._options.tunnel);for(const e of t.attachments||[])n=Qu(n,tl(e));const r=this.sendEnvelope(n);r&&r.then((t=>this.emit("afterSendEvent",e,t)),null)}sendSession(e){const t=sl(e,this._dsn,this._options._metadata,this._options.tunnel);this.sendEnvelope(t)}recordDroppedEvent(e,t,n){if(this._options.sendClientReports){const r="number"==typeof n?n:1,o=`${e}:${t}`;V&&C.log(`Recording outcome: "${o}"${r>1?` (${r} times)`:""}`),this._outcomes[o]=(this._outcomes[o]||0)+r}}on(e,t){const n=this._hooks[e]=this._hooks[e]||[];return n.push(t),()=>{const e=n.indexOf(t);e>-1&&n.splice(e,1)}}emit(e,...t){const n=this._hooks[e];n&&n.forEach((e=>e(...t)))}sendEnvelope(e){return this.emit("beforeEnvelope",e),this._isEnabled()&&this._transport?this._transport.send(e).then(null,(e=>(V&&C.error("Error while sending envelope:",e),e))):(V&&C.error("Transport disabled"),Be({}))}_setupIntegrations(){const{integrations:e}=this._options;this._integrations=Ol(this,e),bo(this,e)}_updateSessionFromEvent(e,t){let n=!1,r=!1;const o=t.exception&&t.exception.values;if(o){r=!0;for(const e of o){const t=e.mechanism;if(t&&!1===t.handled){n=!0;break}}}const s="ok"===e.status;(s&&0===e.errors||s&&n)&&(vt(e,{...n&&{status:"crashed"},errors:e.errors||Number(r||n)}),this.captureSession(e))}_isClientDoneProcessing(e){return new ve((t=>{let n=0;const r=setInterval((()=>{0==this._numProcessing?(clearInterval(r),t(!0)):(n+=1,e&&n>=e&&(clearInterval(r),t(!1)))}),1)}))}_isEnabled(){return!1!==this.getOptions().enabled&&void 0!==this._transport}_prepareEvent(e,t,n=be(),r=Ae()){const o=this.getOptions(),s=Object.keys(this._integrations);return!t.integrations&&s.length>0&&(t.integrations=s),this.emit("preprocessEvent",e,t),e.type||r.setLastEventId(e.event_id||t.event_id),qi(o,e,t,n,this,r).then((e=>{if(null===e)return e;e.contexts={trace:Eu(n),...e.contexts};const t=$u(this,n);return e.sdkProcessingMetadata={dynamicSamplingContext:t,...e.sdkProcessingMetadata},e}))}_captureEvent(e,t={},n){return this._processEvent(e,t,n).then((e=>e.event_id),(e=>{if(V){const t=e;"log"===t.logLevel?C.log(t.message):C.warn(t)}}))}_processEvent(e,t,n){const r=this.getOptions(),{sampleRate:o}=r,s=ea(e),i=Zi(e),a=e.type||"error",c=`before send for type \`${a}\``,u=typeof o>"u"?void 0:Lr(o);if(i&&"number"==typeof u&&Math.random()>u)return this.recordDroppedEvent("sample_rate","error",e),Rn(new Me(`Discarding event because it's not included in the random sample (sampling rate = ${o})`,"log"));const l="replay_event"===a?"replay":a,d=(e.sdkProcessingMetadata||{}).capturedSpanIsolationScope;return this._prepareEvent(e,t,n,d).then((n=>{if(null===n)throw this.recordDroppedEvent("event_processor",l,e),new Me("An event processor returned `null`, will not send event.","log");if(t.data&&!0===t.data.__sentry__)return n;return xl(Nl(this,r,n,t),c)})).then((r=>{if(null===r){if(this.recordDroppedEvent("before_send",l,e),s){const t=1+(e.spans||[]).length;this.recordDroppedEvent("before_send","span",t)}throw new Me(`${c} returned \`null\`, will not send event.`,"log")}const o=n&&n.getSession();if(!s&&o&&this._updateSessionFromEvent(o,r),s){const e=(r.sdkProcessingMetadata&&r.sdkProcessingMetadata.spanCountBeforeProcessing||0)-(r.spans?r.spans.length:0);e>0&&this.recordDroppedEvent("before_send","span",e)}const i=r.transaction_info;if(s&&i&&r.transaction!==e.transaction){const e="custom";r.transaction_info={...i,source:e}}return this.sendEvent(r,t),r})).then(null,(e=>{throw e instanceof Me?e:(this.captureException(e,{data:{__sentry__:!0},originalException:e}),new Me(`Event processing pipeline threw an error, original event will not be sent. Details have been sent as a new event.\nReason: ${e}`))}))}_process(e){this._numProcessing++,e.then((e=>(this._numProcessing--,e)),(e=>(this._numProcessing--,e)))}_clearOutcomes(){const e=this._outcomes;return this._outcomes={},Object.entries(e).map((([e,t])=>{const[n,r]=e.split(":");return{reason:n,category:r,quantity:t}}))}_flushOutcomes(){V&&C.log("Flushing outcomes...");const e=this._clearOutcomes();if(0===e.length)return void(V&&C.log("No outcomes to send"));if(!this._dsn)return void(V&&C.log("No dsn provided, will not send outcomes"));V&&C.log("Sending outcomes:",e);const t=Dl(e,this._options.tunnel&&Kn(this._dsn));this.sendEnvelope(t)}}function xl(e,t){const n=`${t} must return \`null\` or a valid event.`;if(Wn(e))return e.then((e=>{if(!St(e)&&null!==e)throw new Me(n);return e}),(e=>{throw new Me(`${t} rejected with ${e}`)}));if(!St(e)&&null!==e)throw new Me(n);return e}function Nl(e,t,n,r){const{beforeSend:o,beforeSendTransaction:s,beforeSendSpan:i}=t;if(Zi(n)&&o)return o(n,r);if(ea(n)){if(n.spans&&i){const t=[];for(const r of n.spans){const n=i(r);n?t.push(n):(Uu(),e.recordDroppedEvent("before_send","span"))}n.spans=t}if(s){if(n.spans){const e=n.spans.length;n.sdkProcessingMetadata={...n.sdkProcessingMetadata,spanCountBeforeProcessing:e}}return s(n,r)}}return n}function Zi(e){return void 0===e.type}function ea(e){return"transaction"===e.type}function Pl(e,t){!0===t.debug&&(V?C.enable():Je((()=>{console.warn("[Sentry] Cannot initialize SDK with `debug` option using a non-debug bundle.")}))),be().update(t.initialScope);const n=new e(t);return Ll(n),n.init(),n}function Ll(e){be().setClient(e)}function Fl(e){const t=[];function n(e){return t.splice(t.indexOf(e),1)[0]||Promise.resolve(void 0)}return{$:t,add:function(r){if(!(void 0===e||t.length<e))return Rn(new Me("Not adding Promise because buffer limit was reached."));const o=r();return-1===t.indexOf(o)&&t.push(o),o.then((()=>n(o))).then(null,(()=>n(o).then(null,(()=>{})))),o},drain:function(e){return new ve(((n,r)=>{let o=t.length;if(!o)return n(!0);const s=setTimeout((()=>{e&&e>0&&n(!1)}),e);t.forEach((e=>{Be(e).then((()=>{--o||(clearTimeout(s),n(!0))}),r)}))}))}}}const Ul=6e4;function jl(e,t=Date.now()){const n=parseInt(`${e}`,10);if(!isNaN(n))return 1e3*n;const r=Date.parse(`${e}`);return isNaN(r)?Ul:r-t}function Bl(e,t){return e[t]||e.all||0}function ta(e,t,n=Date.now()){return Bl(e,t)>n}function na(e,{statusCode:t,headers:n},r=Date.now()){const o={...e},s=n&&n["x-sentry-rate-limits"],i=n&&n["retry-after"];if(s)for(const e of s.trim().split(",")){const[t,n,,,s]=e.split(":",5),i=parseInt(t,10),a=1e3*(isNaN(i)?60:i);if(n)for(const e of n.split(";"))"metric_bucket"===e?(!s||s.split(";").includes("custom"))&&(o[e]=r+a):o[e]=r+a;else o.all=r+a}else i?o.all=r+jl(i,r):429===t&&(o.all=r+6e4);return o}const $l=64;function Hl(e,t,n=Fl(e.bufferSize||64)){let r={};return{send:function(o){const s=[];if(ho(o,((t,n)=>{const o=mo(n);if(ta(r,o)){const r=Io(t,n);e.recordDroppedEvent("ratelimit_backoff",o,r)}else s.push(t)})),0===s.length)return Be({});const i=At(o[0],s),a=t=>{ho(i,((n,r)=>{const o=Io(n,r);e.recordDroppedEvent(t,mo(r),o)}))};return n.add((()=>t({body:Zu(i)}).then((e=>(void 0!==e.statusCode&&(e.statusCode<200||e.statusCode>=300)&&V&&C.warn(`Sentry responded with status code ${e.statusCode} to sent event.`),r=na(r,e),e)),(e=>{throw a("network_error"),e})))).then((e=>e),(e=>{if(e instanceof Me)return V&&C.error("Skipped sending event because buffer is full."),a("queue_overflow"),Be({});throw e}))},flush:e=>n.drain(e)}}function Io(e,t){if("event"===t||"transaction"===t)return Array.isArray(e)?e[1]:void 0}function zl(e,t){const n=t&&t.getDsn(),r=t&&t.getOptions().tunnel;return Gl(e,n)||Wl(e,r)}function Wl(e,t){return!!t&&wo(e)===wo(t)}function Gl(e,t){return!!t&&e.includes(t.host)}function wo(e){return"/"===e[e.length-1]?e.slice(0,-1):e}function ra(e,t,n=[t],r="npm"){const o=e._metadata||{};o.sdk||(o.sdk={name:`sentry.javascript.${t}`,packages:n.map((e=>({name:`${r}:@sentry/${e}`,version:nt}))),version:nt}),e._metadata=o}const Yl=100;function Ke(e,t){const n=ie(),r=Ae();if(!n)return;const{beforeBreadcrumb:o=null,maxBreadcrumbs:s=Yl}=n.getOptions();if(s<=0)return;const i={timestamp:Jt(),...e},a=o?Je((()=>o(i,t))):i;null!==a&&(n.emit&&n.emit("beforeAddBreadcrumb",a,t),r.addBreadcrumb(a,s))}let To;const ql="FunctionToString",ko=new WeakMap,Kl=()=>({name:ql,setupOnce(){To=Function.prototype.toString;try{Function.prototype.toString=function(...e){const t=ys(this),n=ko.has(ie())&&void 0!==t?t:this;return To.apply(n,e)}}catch{}},setup(e){ko.set(e,!0)}}),Vl=Kl,Jl=[/^Script error\.?$/,/^Javascript error: Script error\.? on line 0$/,/^ResizeObserver loop completed with undelivered notifications.$/,/^Cannot redefine property: googletag$/,"undefined is not an object (evaluating 'a.L')",'can\'t redefine non-configurable property "solana"',"vv().getRestrictions is not a function. (In 'vv().getRestrictions(1,a)', 'vv().getRestrictions' is undefined)","Can't find variable: _AutofillCallbackHandler",/^Non-Error promise rejection captured with value: Object Not Found Matching Id:\d+, MethodName:simulateEvent, ParamCount:\d+$/],Xl="InboundFilters",Ql=(e={})=>({name:Xl,processEvent(t,n,r){const o=r.getOptions();return td(t,ed(e,o))?null:t}}),Zl=Ql;function ed(e={},t={}){return{allowUrls:[...e.allowUrls||[],...t.allowUrls||[]],denyUrls:[...e.denyUrls||[],...t.denyUrls||[]],ignoreErrors:[...e.ignoreErrors||[],...t.ignoreErrors||[],...e.disableErrorDefaults?[]:Jl],ignoreTransactions:[...e.ignoreTransactions||[],...t.ignoreTransactions||[]],ignoreInternal:void 0===e.ignoreInternal||e.ignoreInternal}}function td(e,t){return t.ignoreInternal&&ad(e)?(V&&C.warn(`Event dropped due to being internal Sentry Error.\nEvent: ${He(e)}`),!0):nd(e,t.ignoreErrors)?(V&&C.warn(`Event dropped due to being matched by \`ignoreErrors\` option.\nEvent: ${He(e)}`),!0):ud(e)?(V&&C.warn(`Event dropped due to not having an error message, error type or stacktrace.\nEvent: ${He(e)}`),!0):rd(e,t.ignoreTransactions)?(V&&C.warn(`Event dropped due to being matched by \`ignoreTransactions\` option.\nEvent: ${He(e)}`),!0):sd(e,t.denyUrls)?(V&&C.warn(`Event dropped due to being matched by \`denyUrls\` option.\nEvent: ${He(e)}.\nUrl: ${Cn(e)}`),!0):!od(e,t.allowUrls)&&(V&&C.warn(`Event dropped due to not being matched by \`allowUrls\` option.\nEvent: ${He(e)}.\nUrl: ${Cn(e)}`),!0)}function nd(e,t){return!(e.type||!t||!t.length)&&id(e).some((e=>Vt(e,t)))}function rd(e,t){if("transaction"!==e.type||!t||!t.length)return!1;const n=e.transaction;return!!n&&Vt(n,t)}function sd(e,t){if(!t||!t.length)return!1;const n=Cn(e);return!!n&&Vt(n,t)}function od(e,t){if(!t||!t.length)return!0;const n=Cn(e);return!n||Vt(n,t)}function id(e){const t=[];let n;e.message&&t.push(e.message);try{n=e.exception.values[e.exception.values.length-1]}catch{}return n&&n.value&&(t.push(n.value),n.type&&t.push(`${n.type}: ${n.value}`)),t}function ad(e){try{return"SentryError"===e.exception.values[0].type}catch{}return!1}function cd(e=[]){for(let t=e.length-1;t>=0;t--){const n=e[t];if(n&&"<anonymous>"!==n.filename&&"[native code]"!==n.filename)return n.filename||null}return null}function Cn(e){try{let t;try{t=e.exception.values[0].stacktrace.frames}catch{}return t?cd(t):null}catch{return V&&C.error(`Cannot extract url for event ${He(e)}`),null}}function ud(e){return!(e.type||!e.exception||!e.exception.values||0===e.exception.values.length)&&(!e.message&&!e.exception.values.some((e=>e.stacktrace||e.type&&"Error"!==e.type||e.value)))}function ld(e,t,n=250,r,o,s,i){if(!(s.exception&&s.exception.values&&i&&st(i.originalException,Error)))return;const a=s.exception.values.length>0?s.exception.values[s.exception.values.length-1]:void 0;a&&(s.exception.values=dd(Br(e,t,o,i.originalException,r,s.exception.values,a,0),n))}function Br(e,t,n,r,o,s,i,a){if(s.length>=n+1)return s;let c=[...s];if(st(r[o],Error)){Ro(i,a);const s=e(t,r[o]),u=c.length;Co(s,o,u,a),c=Br(e,t,n,r[o],o,[s,...c],s,u)}return Array.isArray(r.errors)&&r.errors.forEach(((r,s)=>{if(st(r,Error)){Ro(i,a);const u=e(t,r),l=c.length;Co(u,`errors[${s}]`,l,a),c=Br(e,t,n,r,o,[u,...c],u,l)}})),c}function Ro(e,t){e.mechanism=e.mechanism||{type:"generic",handled:!0},e.mechanism={...e.mechanism,..."AggregateError"===e.type&&{is_exception_group:!0},exception_id:t}}function Co(e,t,n,r){e.mechanism=e.mechanism||{type:"generic",handled:!0},e.mechanism={...e.mechanism,type:"chained",source:t,exception_id:n,parent_id:r}}function dd(e,t){return e.map((e=>(e.value&&(e.value=Et(e.value,t)),e)))}function _r(e){if(!e)return{};const t=e.match(/^(([^:/?#]+):)?(\/\/([^/?#]*))?([^?#]*)(\?([^#]*))?(#(.*))?$/);if(!t)return{};const 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 fd(e){const t="console";ut(t,e),lt(t,pd)}function pd(){"console"in j&&Or.forEach((function(e){e in j.console&&pe(j.console,e,(function(t){return kn[e]=t,function(...t){Ce("console",{args:t,level:e});const n=kn[e];n&&n.apply(j.console,t)}}))}))}function sa(e){return"warn"===e?"warning":["fatal","error","warning","log","info","debug"].includes(e)?e:"log"}const hd="Dedupe",md=()=>{let e;return{name:hd,processEvent(t){if(t.type)return t;try{if(_d(t,e))return V&&C.warn("Event dropped due to being a duplicate of previously captured event."),null}catch{}return e=t}}},oa=md;function _d(e,t){return!!t&&!(!gd(e,t)&&!yd(e,t))}function gd(e,t){const n=e.message,r=t.message;return!(!n&&!r||n&&!r||!n&&r||n!==r||!aa(e,t)||!ia(e,t))}function yd(e,t){const n=Mo(t),r=Mo(e);return!!(n&&r&&n.type===r.type&&n.value===r.value&&aa(e,t)&&ia(e,t))}function ia(e,t){let n=Zs(e),r=Zs(t);if(!n&&!r)return!0;if(n&&!r||!n&&r||r.length!==n.length)return!1;for(let e=0;e<r.length;e++){const t=r[e],o=n[e];if(t.filename!==o.filename||t.lineno!==o.lineno||t.colno!==o.colno||t.function!==o.function)return!1}return!0}function aa(e,t){let n=e.fingerprint,r=t.fingerprint;if(!n&&!r)return!0;if(n&&!r||!n&&r)return!1;try{return n.join("")===r.join("")}catch{return!1}}function Mo(e){return e.exception&&e.exception.values&&e.exception.values[0]}function ca(e){if(void 0!==e)return e>=400&&e<500?"warning":e>=500?"error":void 0}const $r=j;function ua(){if(!("fetch"in $r))return!1;try{return new Headers,new Request("http://www.example.com"),new Response,!0}catch{return!1}}function Hr(e){return e&&/^function\s+\w+\(\)\s+\{\s+\[native code\]\s+\}$/.test(e.toString())}function Ed(){if("string"==typeof EdgeRuntime)return!0;if(!ua())return!1;if(Hr($r.fetch))return!0;let e=!1;const t=$r.document;if(t&&"function"==typeof t.createElement)try{const n=t.createElement("iframe");n.hidden=!0,t.head.appendChild(n),n.contentWindow&&n.contentWindow.fetch&&(e=Hr(n.contentWindow.fetch)),t.head.removeChild(n)}catch(e){ct&&C.warn("Could not create sandbox iframe for pure fetch check, bailing to window.fetch: ",e)}return e}function Sd(e,t){const n="fetch";ut(n,e),lt(n,(()=>bd(void 0,t)))}function bd(e,t=!1){t&&!Ed()||pe(j,"fetch",(function(e){return function(...t){const n=new Error,{method:r,url:o}=vd(t),s={args:t,fetchData:{method:r,url:o},startTimestamp:1e3*Fe(),virtualError:n};return Ce("fetch",{...s}),e.apply(j,t).then((async e=>(Ce("fetch",{...s,endTimestamp:1e3*Fe(),response:e}),e)),(e=>{throw Ce("fetch",{...s,endTimestamp:1e3*Fe(),error:e}),hs(e)&&void 0===e.stack&&(e.stack=n.stack,ot(e,"framesToPop",1)),e}))}}))}function zr(e,t){return!!e&&"object"==typeof e&&!!e[t]}function Oo(e){return"string"==typeof e?e:e?zr(e,"url")?e.url:e.toString?e.toString():"":""}function vd(e){if(0===e.length)return{method:"GET",url:""};if(2===e.length){const[t,n]=e;return{url:Oo(t),method:zr(n,"method")?String(n.method).toUpperCase():"GET"}}const t=e[0];return{url:Oo(t),method:zr(t,"method")?String(t.method).toUpperCase():"GET"}}function Id(){return typeof __SENTRY_BROWSER_BUNDLE__<"u"&&!!__SENTRY_BROWSER_BUNDLE__}function wd(){return"npm"}function Td(){return!Id()&&"[object process]"===Object.prototype.toString.call(typeof process<"u"?process:0)}function Do(){return typeof window<"u"&&(!Td()||kd())}function kd(){const e=j.process;return!!e&&"renderer"===e.type}const dn=j;function Rd(){const e=dn.chrome,t=e&&e.app&&e.app.runtime,n="history"in dn&&!!dn.history.pushState&&!!dn.history.replaceState;return!t&&n}function Cd(e,t){return e??t()}function In(e){let t,n=e[0],r=1;for(;r<e.length;){const o=e[r],s=e[r+1];if(r+=2,("optionalAccess"===o||"optionalCall"===o)&&null==n)return;"access"===o||"optionalAccess"===o?(t=n,n=s(n)):("call"===o||"optionalCall"===o)&&(n=s(((...e)=>n.call(t,...e))),t=void 0)}return n}const J=j;let Wr=0;function la(){return Wr>0}function Md(){Wr++,setTimeout((()=>{Wr--}))}function wt(e,t={}){if("function"!=typeof e)return e;try{const t=e.__sentry_wrapped__;if(t)return"function"==typeof t?t:e;if(ys(e))return e}catch{return e}const n=function(...n){try{const r=n.map((e=>wt(e,t)));return e.apply(this,r)}catch(e){throw Md(),yu((r=>{r.addEventProcessor((e=>(t.mechanism&&(Ar(e,void 0),bt(e,t.mechanism)),e.extra={...e.extra,arguments:n},e))),Is(e)})),e}};try{for(const t in e)Object.prototype.hasOwnProperty.call(e,t)&&(n[t]=e[t])}catch{}Li(n,e),ot(e,"__sentry_wrapped__",n);try{Object.getOwnPropertyDescriptor(n,"name").configurable&&Object.defineProperty(n,"name",{get:()=>e.name})}catch{}return n}const Xt=typeof __SENTRY_DEBUG__>"u"||__SENTRY_DEBUG__;function ws(e,t){const n=Ts(e,t),r={type:Nd(t),value:Pd(t)};return n.length&&(r.stacktrace={frames:n}),void 0===r.type&&""===r.value&&(r.value="Unrecoverable error caught"),r}function Od(e,t,n,r){const o=ie(),s=o&&o.getOptions().normalizeDepth,i=Bd(t),a={__serialized__:Gi(t,s)};if(i)return{exception:{values:[ws(e,i)]},extra:a};const c={exception:{values:[{type:zn(t)?t.constructor.name:r?"UnhandledRejection":"Error",value:Ud(t,{isUnhandledRejection:r})}]},extra:a};if(n){const t=Ts(e,n);t.length&&(c.exception.values[0].stacktrace={frames:t})}return c}function gr(e,t){return{exception:{values:[ws(e,t)]}}}function Ts(e,t){const n=t.stacktrace||t.stack||"",r=Ad(t),o=xd(t);try{return e(n,r,o)}catch{}return[]}const Dd=/Minified React error #\d+;/i;function Ad(e){return e&&Dd.test(e.message)?1:0}function xd(e){return"number"==typeof e.framesToPop?e.framesToPop:0}function da(e){return typeof WebAssembly<"u"&&typeof WebAssembly.Exception<"u"&&e instanceof WebAssembly.Exception}function Nd(e){const t=e&&e.name;return!t&&da(e)?e.message&&Array.isArray(e.message)&&2==e.message.length?e.message[0]:"WebAssembly.Exception":t}function Pd(e){const t=e&&e.message;return t?t.error&&"string"==typeof t.error.message?t.error.message:da(e)&&Array.isArray(e.message)&&2==e.message.length?e.message[1]:t:"No error message"}function Ld(e,t,n,r){const o=ks(e,t,n&&n.syntheticException||void 0,r);return bt(o),o.level="error",n&&n.event_id&&(o.event_id=n.event_id),Be(o)}function Fd(e,t,n="info",r,o){const s=Gr(e,t,r&&r.syntheticException||void 0,o);return s.level=n,r&&r.event_id&&(s.event_id=r.event_id),Be(s)}function ks(e,t,n,r,o){let s;if(xi(t)&&t.error)return gr(e,t.error);if(to(t)||Kc(t)){const o=t;if("stack"in t)s=gr(e,t);else{const t=o.name||(to(o)?"DOMError":"DOMException"),i=o.message?`${t}: ${o.message}`:t;s=Gr(e,i,n,r),Ar(s,i)}return"code"in o&&(s.tags={...s.tags,"DOMException.code":`${o.code}`}),s}return hs(t)?gr(e,t):St(t)||zn(t)?(s=Od(e,t,n,o),bt(s,{synthetic:!0}),s):(s=Gr(e,t,n,r),Ar(s,`${t}`),bt(s,{synthetic:!0}),s)}function Gr(e,t,n,r){const o={};if(r&&n){const r=Ts(e,n);r.length&&(o.exception={values:[{value:t,stacktrace:{frames:r}}]}),bt(o,{synthetic:!0})}if(ms(t)){const{__sentry_template_string__:e,__sentry_template_values__:n}=t;return o.logentry={message:e,params:n},o}return o.message=t,o}function Ud(e,{isUnhandledRejection:t}){const n=nu(e),r=t?"promise rejection":"exception";return xi(e)?`Event \`ErrorEvent\` captured as ${r} with message \`${e.message}\``:zn(e)?`Event \`${jd(e)}\` (type=${e.type}) captured as ${r}`:`Object captured as ${r} with keys: ${n}`}function jd(e){try{const t=Object.getPrototypeOf(e);return t?t.constructor.name:void 0}catch{}}function Bd(e){for(const t in e)if(Object.prototype.hasOwnProperty.call(e,t)){const n=e[t];if(n instanceof Error)return n}}function $d(e,{metadata:t,tunnel:n,dsn:r}){return At({event_id:e.event_id,sent_at:(new Date).toISOString(),...t&&t.sdk&&{sdk:{name:t.sdk.name,version:t.sdk.version}},...!!n&&!!r&&{dsn:Kn(r)}},[Hd(e)])}function Hd(e){return[{type:"user_report"},e]}class zd extends Al{constructor(e){const t={parentSpanIsAlwaysRootSpan:!0,...e};ra(t,"browser",["browser"],J.SENTRY_SDK_SOURCE||wd()),super(t),t.sendClientReports&&J.document&&J.document.addEventListener("visibilitychange",(()=>{"hidden"===J.document.visibilityState&&this._flushOutcomes()}))}eventFromException(e,t){return Ld(this._options.stackParser,e,t,this._options.attachStacktrace)}eventFromMessage(e,t="info",n){return Fd(this._options.stackParser,e,t,n,this._options.attachStacktrace)}captureUserFeedback(e){if(!this._isEnabled())return void(Xt&&C.warn("SDK not enabled, will not capture user feedback."));const t=$d(e,{metadata:this.getSdkMetadata(),dsn:this.getDsn(),tunnel:this.getOptions().tunnel});this.sendEnvelope(t)}_prepareEvent(e,t,n){return e.platform=e.platform||"javascript",super._prepareEvent(e,t,n)}}const fa=typeof __SENTRY_DEBUG__>"u"||__SENTRY_DEBUG__,Wd=(e,t)=>e>t[1]?"poor":e>t[0]?"needs-improvement":"good",Qt=(e,t,n,r)=>{let o,s;return i=>{t.value>=0&&(i||r)&&(s=t.value-(o||0),(s||void 0===o)&&(o=t.value,t.delta=s,t.rating=Wd(t.value,n),e(t)))}},P=j,Gd=()=>`v4-${Date.now()}-${Math.floor(8999999999999*Math.random())+1e12}`,pa=(e=!0)=>{const t=P.performance&&P.performance.getEntriesByType&&P.performance.getEntriesByType("navigation")[0];if(!e||t&&t.responseStart>0&&t.responseStart<performance.now())return t},Rs=()=>{const e=pa();return e&&e.activationStart||0},Zt=(e,t)=>{const n=pa();let r="navigate";return n&&(P.document&&P.document.prerendering||Rs()>0?r="prerender":P.document&&P.document.wasDiscarded?r="restore":n.type&&(r=n.type.replace(/_/g,"-"))),{name:e,value:typeof t>"u"?-1:t,rating:"good",delta:0,entries:[],id:Gd(),navigationType:r}},dt=(e,t,n)=>{try{if(PerformanceObserver.supportedEntryTypes.includes(e)){const r=new PerformanceObserver((e=>{Promise.resolve().then((()=>{t(e.getEntries())}))}));return r.observe(Object.assign({type:e,buffered:!0},n||{})),r}}catch{}},en=e=>{const t=t=>{("pagehide"===t.type||P.document&&"hidden"===P.document.visibilityState)&&e(t)};P.document&&(addEventListener("visibilitychange",t,!0),addEventListener("pagehide",t,!0))},Vn=e=>{let t=!1;return()=>{t||(e(),t=!0)}};let Nt=-1;const Yd=()=>"hidden"!==P.document.visibilityState||P.document.prerendering?1/0:0,Mn=e=>{"hidden"===P.document.visibilityState&&Nt>-1&&(Nt="visibilitychange"===e.type?e.timeStamp:0,Kd())},qd=()=>{addEventListener("visibilitychange",Mn,!0),addEventListener("prerenderingchange",Mn,!0)},Kd=()=>{removeEventListener("visibilitychange",Mn,!0),removeEventListener("prerenderingchange",Mn,!0)},Cs=()=>(P.document&&Nt<0&&(Nt=Yd(),qd()),{get firstHiddenTime(){return Nt}}),Jn=e=>{P.document&&P.document.prerendering?addEventListener("prerenderingchange",(()=>e()),!0):e()},Vd=[1800,3e3],Jd=(e,t={})=>{Jn((()=>{const n=Cs(),r=Zt("FCP");let o;const s=dt("paint",(e=>{e.forEach((e=>{"first-contentful-paint"===e.name&&(s.disconnect(),e.startTime<n.firstHiddenTime&&(r.value=Math.max(e.startTime-Rs(),0),r.entries.push(e),o(!0)))}))}));s&&(o=Qt(e,r,Vd,t.reportAllChanges))}))},Xd=[.1,.25],Qd=(e,t={})=>{Jd(Vn((()=>{const n=Zt("CLS",0);let r,o=0,s=[];const i=e=>{e.forEach((e=>{if(!e.hadRecentInput){const t=s[0],n=s[s.length-1];o&&t&&n&&e.startTime-n.startTime<1e3&&e.startTime-t.startTime<5e3?(o+=e.value,s.push(e)):(o=e.value,s=[e])}})),o>n.value&&(n.value=o,n.entries=s,r())},a=dt("layout-shift",i);a&&(r=Qt(e,n,Xd,t.reportAllChanges),en((()=>{i(a.takeRecords()),r(!0)})),setTimeout(r,0))})))},Zd=[100,300],ef=(e,t={})=>{Jn((()=>{const n=Cs(),r=Zt("FID");let o;const s=e=>{e.startTime<n.firstHiddenTime&&(r.value=e.processingStart-e.startTime,r.entries.push(e),o(!0))},i=e=>{e.forEach(s)},a=dt("first-input",i);o=Qt(e,r,Zd,t.reportAllChanges),a&&en(Vn((()=>{i(a.takeRecords()),a.disconnect()})))}))};let ha=0,yr=1/0,fn=0;const tf=e=>{e.forEach((e=>{e.interactionId&&(yr=Math.min(yr,e.interactionId),fn=Math.max(fn,e.interactionId),ha=fn?(fn-yr)/7+1:0)}))};let Yr;const nf=()=>Yr?ha:performance.interactionCount||0,rf=()=>{"interactionCount"in performance||Yr||(Yr=dt("event",tf,{type:"event",buffered:!0,durationThreshold:0}))},Pe=[],Er=new Map,sf=40;let of=0;const af=()=>nf()-of,cf=()=>{const e=Math.min(Pe.length-1,Math.floor(af()/50));return Pe[e]},Sr=10,uf=[],lf=e=>{if(uf.forEach((t=>t(e))),!e.interactionId&&"first-input"!==e.entryType)return;const t=Pe[Pe.length-1],n=Er.get(e.interactionId);if(n||Pe.length<10||t&&e.duration>t.latency){if(n)e.duration>n.latency?(n.entries=[e],n.latency=e.duration):e.duration===n.latency&&e.startTime===(n.entries[0]&&n.entries[0].startTime)&&n.entries.push(e);else{const t={id:e.interactionId,latency:e.duration,entries:[e]};Er.set(t.id,t),Pe.push(t)}Pe.sort(((e,t)=>t.latency-e.latency)),Pe.length>10&&Pe.splice(10).forEach((e=>Er.delete(e.id)))}},ma=e=>{const t=P.requestIdleCallback||P.setTimeout;let n=-1;return e=Vn(e),P.document&&"hidden"===P.document.visibilityState?e():(n=t(e),en(e)),n},df=[200,500],ff=(e,t={})=>{"PerformanceEventTiming"in P&&"interactionId"in PerformanceEventTiming.prototype&&Jn((()=>{rf();const n=Zt("INP");let r;const o=e=>{ma((()=>{e.forEach(lf);const t=cf();t&&t.latency!==n.value&&(n.value=t.latency,n.entries=t.entries,r())}))},s=dt("event",o,{durationThreshold:null!=t.durationThreshold?t.durationThreshold:40});r=Qt(e,n,df,t.reportAllChanges),s&&(s.observe({type:"first-input",buffered:!0}),en((()=>{o(s.takeRecords()),r(!0)})))}))},pf=[2500,4e3],Ao={},hf=(e,t={})=>{Jn((()=>{const n=Cs(),r=Zt("LCP");let o;const s=e=>{t.reportAllChanges||(e=e.slice(-1)),e.forEach((e=>{e.startTime<n.firstHiddenTime&&(r.value=Math.max(e.startTime-Rs(),0),r.entries=[e],o())}))},i=dt("largest-contentful-paint",s);if(i){o=Qt(e,r,pf,t.reportAllChanges);const n=Vn((()=>{Ao[r.id]||(s(i.takeRecords()),i.disconnect(),Ao[r.id]=!0,o(!0))}));["keydown","click"].forEach((e=>{P.document&&addEventListener(e,(()=>ma(n)),{once:!0,capture:!0})})),en(n)}}))},Pt={},On={};let _a,ga,ya,Ea;function mf(e,t=!1){return Xn("cls",e,Sf,_a,t)}function _f(e,t=!1){return Xn("lcp",e,vf,ya,t)}function gf(e){return Xn("fid",e,bf,ga)}function yf(e){return Xn("inp",e,If,Ea)}function Ef(e,t){return Sa(e,t),On[e]||(wf(e),On[e]=!0),ba(e,t)}function tn(e,t){const n=Pt[e];if(n&&n.length)for(const r of n)try{r(t)}catch(t){fa&&C.error(`Error while triggering instrumentation handler.\nType: ${e}\nName: ${je(r)}\nError:`,t)}}function Sf(){return Qd((e=>{tn("cls",{metric:e}),_a=e}),{reportAllChanges:!0})}function bf(){return ef((e=>{tn("fid",{metric:e}),ga=e}))}function vf(){return hf((e=>{tn("lcp",{metric:e}),ya=e}),{reportAllChanges:!0})}function If(){return ff((e=>{tn("inp",{metric:e}),Ea=e}))}function Xn(e,t,n,r,o=!1){let s;return Sa(e,t),On[e]||(s=n(),On[e]=!0),r&&t({metric:r}),ba(e,t,o?s:void 0)}function wf(e){const t={};"event"===e&&(t.durationThreshold=0),dt(e,(t=>{tn(e,{entries:t})}),t)}function Sa(e,t){Pt[e]=Pt[e]||[],Pt[e].push(t)}function ba(e,t,n){return()=>{n&&n();const r=Pt[e];if(!r)return;const o=r.indexOf(t);-1!==o&&r.splice(o,1)}}const Tf=1e3;let xo,qr,Kr,pn;function va(e){ut("dom",e),lt("dom",kf)}function kf(){if(!P.document)return;const e=Ce.bind(null,"dom"),t=No(e,!0);P.document.addEventListener("click",t,!1),P.document.addEventListener("keypress",t,!1),["EventTarget","Node"].forEach((t=>{const n=P[t],r=n&&n.prototype;!r||!r.hasOwnProperty||!r.hasOwnProperty("addEventListener")||(pe(r,"addEventListener",(function(t){return function(n,r,o){if("click"===n||"keypress"==n)try{const r=this.__sentry_instrumentation_handlers__=this.__sentry_instrumentation_handlers__||{},s=r[n]=r[n]||{refCount:0};if(!s.handler){const r=No(e);s.handler=r,t.call(this,n,r,o)}s.refCount++}catch{}return t.call(this,n,r,o)}})),pe(r,"removeEventListener",(function(e){return function(t,n,r){if("click"===t||"keypress"==t)try{const n=this.__sentry_instrumentation_handlers__||{},o=n[t];o&&(o.refCount--,o.refCount<=0&&(e.call(this,t,o.handler,r),o.handler=void 0,delete n[t]),0===Object.keys(n).length&&delete this.__sentry_instrumentation_handlers__)}catch{}return e.call(this,t,n,r)}})))}))}function Rf(e){if(e.type!==qr)return!1;try{if(!e.target||e.target._sentryId!==Kr)return!1}catch{}return!0}function Cf(e,t){return"keypress"===e&&(!t||!t.tagName||!("INPUT"===t.tagName||"TEXTAREA"===t.tagName||t.isContentEditable))}function No(e,t=!1){return n=>{if(!n||n._sentryCaptured)return;const r=Mf(n);if(Cf(n.type,r))return;ot(n,"_sentryCaptured",!0),r&&!r._sentryId&&ot(r,"_sentryId",ge());const o="keypress"===n.type?"input":n.type;Rf(n)||(e({event:n,name:o,global:t}),qr=n.type,Kr=r?r._sentryId:void 0),clearTimeout(xo),xo=P.setTimeout((()=>{Kr=void 0,qr=void 0}),Tf)}}function Mf(e){try{return e.target}catch{return null}}function Ms(e){const t="history";ut(t,e),lt(t,Of)}function Of(){if(!Rd())return;const e=P.onpopstate;function t(e){return function(...t){const n=t.length>2?t[2]:void 0;if(n){const e=pn,t=String(n);pn=t,Ce("history",{from:e,to:t})}return e.apply(this,t)}}P.onpopstate=function(...t){const n=P.location.href,r=pn;if(pn=n,Ce("history",{from:r,to:n}),e)try{return e.apply(this,t)}catch{}},pe(P.history,"pushState",t),pe(P.history,"replaceState",t)}const wn={};function Ia(e){const t=wn[e];if(t)return t;let n=P[e];if(Hr(n))return wn[e]=n.bind(P);const r=P.document;if(r&&"function"==typeof r.createElement)try{const t=r.createElement("iframe");t.hidden=!0,r.head.appendChild(t);const o=t.contentWindow;o&&o[e]&&(n=o[e]),r.head.removeChild(t)}catch(t){fa&&C.warn(`Could not create sandbox iframe for ${e} check, bailing to window.${e}: `,t)}return n&&(wn[e]=n.bind(P))}function Po(e){wn[e]=void 0}function Tt(...e){return Ia("setTimeout")(...e)}const ht="__sentry_xhr_v3__";function Df(e){ut("xhr",e),lt("xhr",Af)}function Af(){if(!P.XMLHttpRequest)return;const e=XMLHttpRequest.prototype;e.open=new Proxy(e.open,{apply(e,t,n){const r=new Error,o=1e3*Fe(),s=Le(n[0])?n[0].toUpperCase():void 0,i=xf(n[1]);if(!s||!i)return e.apply(t,n);t[ht]={method:s,url:i,request_headers:{}},"POST"===s&&i.match(/sentry_key/)&&(t.__sentry_own_request__=!0);const a=()=>{const e=t[ht];if(e&&4===t.readyState){try{e.status_code=t.status}catch{}Ce("xhr",{endTimestamp:1e3*Fe(),startTimestamp:o,xhr:t,virtualError:r})}};return"onreadystatechange"in t&&"function"==typeof t.onreadystatechange?t.onreadystatechange=new Proxy(t.onreadystatechange,{apply:(e,t,n)=>(a(),e.apply(t,n))}):t.addEventListener("readystatechange",a),t.setRequestHeader=new Proxy(t.setRequestHeader,{apply(e,t,n){const[r,o]=n,s=t[ht];return s&&Le(r)&&Le(o)&&(s.request_headers[r.toLowerCase()]=o),e.apply(t,n)}}),e.apply(t,n)}}),e.send=new Proxy(e.send,{apply(e,t,n){const r=t[ht];if(!r)return e.apply(t,n);void 0!==n[0]&&(r.body=n[0]);return Ce("xhr",{startTimestamp:1e3*Fe(),xhr:t}),e.apply(t,n)}})}function xf(e){if(Le(e))return e;try{return e.toString()}catch{}}function Nf(e,t=Ia("fetch")){let n=0,r=0;return Hl(e,(function(o){const s=o.body.length;n+=s,r++;const i={body:o.body,method:"POST",referrerPolicy:"origin",headers:e.headers,keepalive:n<=6e4&&r<15,...e.fetchOptions};if(!t)return Po("fetch"),Rn("No fetch implementation available");try{return t(e.url,i).then((e=>(n-=s,r--,{statusCode:e.status,headers:{"x-sentry-rate-limits":e.headers.get("X-Sentry-Rate-Limits"),"retry-after":e.headers.get("Retry-After")}})))}catch(e){return Po("fetch"),n-=s,r--,Rn(e)}}))}const Pf=30,Lf=50;function Vr(e,t,n,r){const o={filename:e,function:"<anonymous>"===t?rt:t,in_app:!0};return void 0!==n&&(o.lineno=n),void 0!==r&&(o.colno=r),o}const Ff=/^\s*at (\S+?)(?::(\d+))(?::(\d+))\s*$/i,Uf=/^\s*at (?:(.+?\)(?: \[.+\])?|.*?) ?\((?:address at )?)?(?:async )?((?:<anonymous>|[-a-z]+:|.*bundle|\/)?.*?)(?::(\d+))?(?::(\d+))?\)?\s*$/i,jf=/\((\S*)(?::(\d+))(?::(\d+))\)/,Bf=e=>{const t=Ff.exec(e);if(t){const[,e,n,r]=t;return Vr(e,rt,+n,+r)}const n=Uf.exec(e);if(n){if(n[2]&&0===n[2].indexOf("eval")){const e=jf.exec(n[2]);e&&(n[2]=e[1],n[3]=e[2],n[4]=e[3])}const[e,t]=wa(n[1]||rt,n[2]);return Vr(t,e,n[3]?+n[3]:void 0,n[4]?+n[4]:void 0)}},$f=[30,Bf],Hf=/^\s*(.*?)(?:\((.*?)\))?(?:^|@)?((?:[-a-z]+)?:\/.*?|\[native code\]|[^@]*(?:bundle|\d+\.js)|\/[\w\-. /=]+)(?::(\d+))?(?::(\d+))?\s*$/i,zf=/(\S+) line (\d+)(?: > eval line \d+)* > eval/i,Wf=e=>{const t=Hf.exec(e);if(t){if(t[3]&&t[3].indexOf(" > eval")>-1){const e=zf.exec(t[3]);e&&(t[1]=t[1]||"eval",t[3]=e[1],t[4]=e[2],t[5]="")}let e=t[3],n=t[1]||rt;return[n,e]=wa(n,e),Vr(e,n,t[4]?+t[4]:void 0,t[5]?+t[5]:void 0)}},Gf=[50,Wf],Yf=[$f,Gf],qf=Di(...Yf),wa=(e,t)=>{const n=-1!==e.indexOf("safari-extension"),r=-1!==e.indexOf("safari-web-extension");return n||r?[-1!==e.indexOf("@")?e.split("@")[0]:rt,n?`safari-extension:${t}`:`safari-web-extension:${t}`]:[e,t]},hn=1024,Kf="Breadcrumbs",Vf=(e={})=>{const t={console:!0,dom:!0,fetch:!0,history:!0,sentry:!0,xhr:!0,...e};return{name:Kf,setup(e){t.console&&fd(Zf(e)),t.dom&&va(Qf(e,t.dom)),t.xhr&&Df(ep(e)),t.fetch&&Sd(tp(e)),t.history&&Ms(np(e)),t.sentry&&e.on("beforeSendEvent",Xf(e))}}},Jf=Vf;function Xf(e){return function(t){ie()===e&&Ke({category:"sentry."+("transaction"===t.type?"transaction":"event"),event_id:t.event_id,level:t.level,message:He(t)},{event:t})}}function Qf(e,t){return function(n){if(ie()!==e)return;let r,o,s="object"==typeof t?t.serializeAttribute:void 0,i="object"==typeof t&&"number"==typeof t.maxStringLength?t.maxStringLength:void 0;i&&i>hn&&(Xt&&C.warn(`\`dom.maxStringLength\` cannot exceed 1024, but a value of ${i} was configured. Sentry will use 1024 instead.`),i=hn),"string"==typeof s&&(s=[s]);try{const e=n.event,t=rp(e)?e.target:e;r=Gn(t,{keyAttrs:s,maxStringLength:i}),o=eu(t)}catch{r="<unknown>"}if(0===r.length)return;const a={category:`ui.${n.name}`,message:r};o&&(a.data={"ui.component_name":o}),Ke(a,{event:n.event,name:n.name,global:n.global})}}function Zf(e){return function(t){if(ie()!==e)return;const n={category:"console",data:{arguments:t.args,logger:"console"},level:sa(t.level),message:no(t.args," ")};if("assert"===t.level){if(!1!==t.args[0])return;n.message=`Assertion failed: ${no(t.args.slice(1)," ")||"console.assert"}`,n.data.arguments=t.args.slice(1)}Ke(n,{input:t.args,level:t.level})}}function ep(e){return function(t){if(ie()!==e)return;const{startTimestamp:n,endTimestamp:r}=t,o=t.xhr[ht];if(!n||!r||!o)return;const{method:s,url:i,status_code:a,body:c}=o,u={method:s,url:i,status_code:a},l={xhr:t.xhr,input:c,startTimestamp:n,endTimestamp:r};Ke({category:"xhr",data:u,type:"http",level:ca(a)},l)}}function tp(e){return function(t){if(ie()!==e)return;const{startTimestamp:n,endTimestamp:r}=t;if(r&&(!t.fetchData.url.match(/sentry_key/)||"POST"!==t.fetchData.method))if(t.error){Ke({category:"fetch",data:t.fetchData,level:"error",type:"http"},{data:t.error,input:t.args,startTimestamp:n,endTimestamp:r})}else{const e=t.response,o={...t.fetchData,status_code:e&&e.status},s={input:t.args,response:e,startTimestamp:n,endTimestamp:r};Ke({category:"fetch",data:o,type:"http",level:ca(o.status_code)},s)}}}function np(e){return function(t){if(ie()!==e)return;let n=t.from,r=t.to;const o=_r(J.location.href);let s=n?_r(n):void 0;const i=_r(r);(!s||!s.path)&&(s=o),o.protocol===i.protocol&&o.host===i.host&&(r=i.relative),o.protocol===s.protocol&&o.host===s.host&&(n=s.relative),Ke({category:"navigation",data:{from:n,to:r}})}}function rp(e){return!!e&&!!e.target}const sp=["EventTarget","Window","Node","ApplicationCache","AudioTrackList","BroadcastChannel","ChannelMergerNode","CryptoOperation","EventSource","FileReader","HTMLUnknownElement","IDBDatabase","IDBRequest","IDBTransaction","KeyOperation","MediaController","MessagePort","ModalWindow","Notification","SVGElementInstance","Screen","SharedWorker","TextTrack","TextTrackCue","TextTrackList","WebSocket","WebSocketWorker","Worker","XMLHttpRequest","XMLHttpRequestEventTarget","XMLHttpRequestUpload"],op="BrowserApiErrors",ip=(e={})=>{const t={XMLHttpRequest:!0,eventTarget:!0,requestAnimationFrame:!0,setInterval:!0,setTimeout:!0,...e};return{name:op,setupOnce(){t.setTimeout&&pe(J,"setTimeout",Lo),t.setInterval&&pe(J,"setInterval",Lo),t.requestAnimationFrame&&pe(J,"requestAnimationFrame",ap),t.XMLHttpRequest&&"XMLHttpRequest"in J&&pe(XMLHttpRequest.prototype,"send",cp);const e=t.eventTarget;e&&(Array.isArray(e)?e:sp).forEach(up)}}},Ta=ip;function Lo(e){return function(...t){const n=t[0];return t[0]=wt(n,{mechanism:{data:{function:je(e)},handled:!1,type:"instrument"}}),e.apply(this,t)}}function ap(e){return function(t){return e.apply(this,[wt(t,{mechanism:{data:{function:"requestAnimationFrame",handler:je(e)},handled:!1,type:"instrument"}})])}}function cp(e){return function(...t){const n=this;return["onload","onerror","onprogress","onreadystatechange"].forEach((e=>{e in n&&"function"==typeof n[e]&&pe(n,e,(function(t){const n={mechanism:{data:{function:e,handler:je(t)},handled:!1,type:"instrument"}},r=ys(t);return r&&(n.mechanism.data.handler=je(r)),wt(t,n)}))})),e.apply(this,t)}}function up(e){const t=J[e],n=t&&t.prototype;!n||!n.hasOwnProperty||!n.hasOwnProperty("addEventListener")||(pe(n,"addEventListener",(function(t){return function(n,r,o){try{lp(r)&&(r.handleEvent=wt(r.handleEvent,{mechanism:{data:{function:"handleEvent",handler:je(r),target:e},handled:!1,type:"instrument"}}))}catch{}return t.apply(this,[n,wt(r,{mechanism:{data:{function:"addEventListener",handler:je(r),target:e},handled:!1,type:"instrument"}}),o])}})),pe(n,"removeEventListener",(function(e){return function(t,n,r){try{const o=n.__sentry_wrapped__;o&&e.call(this,t,o,r)}catch{}return e.call(this,t,n,r)}})))}function lp(e){return"function"==typeof e.handleEvent}const dp=()=>({name:"BrowserSession",setupOnce(){typeof J.document>"u"?Xt&&C.warn("Using the `browserSessionIntegration` in non-browser environments is not supported."):(yo({ignoreDuration:!0}),Eo(),Ms((({from:e,to:t})=>{void 0!==e&&e!==t&&(yo({ignoreDuration:!0}),Eo())})))}}),fp="GlobalHandlers",pp=(e={})=>{const t={onerror:!0,onunhandledrejection:!0,...e};return{name:fp,setupOnce(){Error.stackTraceLimit=50},setup(e){t.onerror&&(mp(e),Fo("onerror")),t.onunhandledrejection&&(_p(e),Fo("onunhandledrejection"))}}},hp=pp;function mp(e){Wc((t=>{const{stackParser:n,attachStacktrace:r}=ka();if(ie()!==e||la())return;const{msg:o,url:s,line:i,column:a,error:c}=t,u=Ep(ks(n,c||o,void 0,r,!1),s,i,a);u.level="error",Ki(u,{originalException:c,mechanism:{handled:!1,type:"onerror"}})}))}function _p(e){Yc((t=>{const{stackParser:n,attachStacktrace:r}=ka();if(ie()!==e||la())return;const o=gp(t),s=_s(o)?yp(o):ks(n,o,void 0,r,!0);s.level="error",Ki(s,{originalException:o,mechanism:{handled:!1,type:"onunhandledrejection"}})}))}function gp(e){if(_s(e))return e;try{if("reason"in e)return e.reason;if("detail"in e&&"reason"in e.detail)return e.detail.reason}catch{}return e}function yp(e){return{exception:{values:[{type:"UnhandledRejection",value:`Non-Error promise rejection captured with value: ${String(e)}`}]}}}function Ep(e,t,n,r){const o=e.exception=e.exception||{},s=o.values=o.values||[],i=s[0]=s[0]||{},a=i.stacktrace=i.stacktrace||{},c=a.frames=a.frames||[],u=r,l=n,d=Le(t)&&t.length>0?t:Pi();return 0===c.length&&c.push({colno:u,filename:d,function:rt,in_app:!0,lineno:l}),e}function Fo(e){Xt&&C.log(`Global Handler attached: ${e}`)}function ka(){const e=ie();return e&&e.getOptions()||{stackParser:()=>[],attachStacktrace:!1}}const Sp=()=>({name:"HttpContext",preprocessEvent(e){if(!J.navigator&&!J.location&&!J.document)return;const t=e.request&&e.request.url||J.location&&J.location.href,{referrer:n}=J.document||{},{userAgent:r}=J.navigator||{},o={...e.request&&e.request.headers,...n&&{Referer:n},...r&&{"User-Agent":r}},s={...e.request,...t&&{url:t},headers:o};e.request=s}}),bp="cause",vp=5,Ip="LinkedErrors",wp=(e={})=>{const t=e.limit||5,n=e.key||bp;return{name:Ip,preprocessEvent(e,r,o){const s=o.getOptions();ld(ws,s.stackParser,s.maxValueLength,n,t,e,r)}}},Tp=wp;function kp(e){const t=[Zl(),Vl(),Ta(),Jf(),hp(),Tp(),oa(),Sp()];return!1!==e.autoSessionTracking&&t.push(dp()),t}function Rp(e={}){const t={defaultIntegrations:kp(e),release:"string"==typeof __SENTRY_RELEASE__?__SENTRY_RELEASE__:J.SENTRY_RELEASE&&J.SENTRY_RELEASE.id?J.SENTRY_RELEASE.id:void 0,autoSessionTracking:!0,sendClientReports:!0};return null==e.defaultIntegrations&&delete e.defaultIntegrations,{...t,...e}}function Cp(){const e=typeof J.window<"u"&&J;if(!e)return!1;const t=e[e.chrome?"chrome":"browser"],n=t&&t.runtime&&t.runtime.id,r=J.location&&J.location.href||"",o=!!n&&J===J.top&&["chrome-extension:","moz-extension:","ms-browser-extension:","safari-web-extension:"].some((e=>r.startsWith(`${e}//`))),s=typeof e.nw<"u";return!!n&&!o&&!s}function Mp(e={}){const t=Rp(e);if(!t.skipBrowserExtensionCheck&&Cp())return void Je((()=>{console.error("[Sentry] You cannot run Sentry this way in a browser extension, check: https://docs.sentry.io/platforms/javascript/best-practices/browser-extensions/")}));Xt&&(ua()||C.warn("No Fetch API detected. The Sentry SDK requires a Fetch API compatible environment to send events. Please add a Fetch API polyfill."));const n={...t,stackParser:Hc(t.stackParser||qf),integrations:Ml(t),transport:t.transport||Nf};return Pl(zd,n)}const ee=j,Os="sentryReplaySession",Op="replay_event",Ds="Unable to send Replay",Dp=3e5,Ap=9e5,xp=5e3,Np=5500,Pp=6e4,Lp=5e3,Fp=3,Uo=15e4,mn=5e3,Up=3e3,jp=300,As=2e7,Bp=4999,$p=15e3,jo=36e5;function Jr(e,t){return e??t()}function Bt(e){let t,n=e[0],r=1;for(;r<e.length;){const o=e[r],s=e[r+1];if(r+=2,("optionalAccess"===o||"optionalCall"===o)&&null==n)return;"access"===o||"optionalAccess"===o?(t=n,n=s(n)):("call"===o||"optionalCall"===o)&&(n=s(((...e)=>n.call(t,...e))),t=void 0)}return n}var ce;function Hp(e){return e.nodeType===e.ELEMENT_NODE}function Lt(e){const t=Bt([e,"optionalAccess",e=>e.host]);return Bt([t,"optionalAccess",e=>e.shadowRoot])===e}function Ft(e){return"[object ShadowRoot]"===Object.prototype.toString.call(e)}function zp(e){return e.includes(" background-clip: text;")&&!e.includes(" -webkit-background-clip: text;")&&(e=e.replace(/\sbackground-clip:\s*text;/g," -webkit-background-clip: text; background-clip: text;")),e}function Wp(e){const{cssText:t}=e;if(t.split('"').length<3)return t;const n=["@import",`url(${JSON.stringify(e.href)})`];return""===e.layerName?n.push("layer"):e.layerName&&n.push(`layer(${e.layerName})`),e.supportsText&&n.push(`supports(${e.supportsText})`),e.media.length&&n.push(e.media.mediaText),n.join(" ")+";"}function Dn(e){try{const t=e.rules||e.cssRules;return t?zp(Array.from(t,Ra).join("")):null}catch{return null}}function Gp(e){let t="";for(let n=0;n<e.style.length;n++){const r=e.style,o=r[n],s=r.getPropertyPriority(o);t+=`${o}:${r.getPropertyValue(o)}${s?" !important":""};`}return`${e.selectorText} { ${t} }`}function Ra(e){let t;if(qp(e))try{t=Dn(e.styleSheet)||Wp(e)}catch{}else if(Kp(e)){let t=e.cssText;const n=e.selectorText.includes(":"),r="string"==typeof e.style.all&&e.style.all;if(r&&(t=Gp(e)),n&&(t=Yp(t)),n||r)return t}return t||e.cssText}function Yp(e){return e.replace(/(\[(?:[\w-]+)[^\\])(:(?:[\w-]+)\])/gm,"$1\\$2")}function qp(e){return"styleSheet"in e}function Kp(e){return"selectorText"in e}!function(e){e[e.Document=0]="Document",e[e.DocumentType=1]="DocumentType",e[e.Element=2]="Element",e[e.Text=3]="Text",e[e.CDATA=4]="CDATA",e[e.Comment=5]="Comment"}(ce||(ce={}));class Ca{constructor(){this.idNodeMap=new Map,this.nodeMetaMap=new WeakMap}getId(e){if(!e)return-1;return Jr(Bt([this,"access",e=>e.getMeta,"call",t=>t(e),"optionalAccess",e=>e.id]),(()=>-1))}getNode(e){return this.idNodeMap.get(e)||null}getIds(){return Array.from(this.idNodeMap.keys())}getMeta(e){return this.nodeMetaMap.get(e)||null}removeNodeFromMap(e){const t=this.getId(e);this.idNodeMap.delete(t),e.childNodes&&e.childNodes.forEach((e=>this.removeNodeFromMap(e)))}has(e){return this.idNodeMap.has(e)}hasNode(e){return this.nodeMetaMap.has(e)}add(e,t){const n=t.id;this.idNodeMap.set(n,e),this.nodeMetaMap.set(e,t)}replace(e,t){const n=this.getNode(e);if(n){const e=this.nodeMetaMap.get(n);e&&this.nodeMetaMap.set(t,e)}this.idNodeMap.set(e,t)}reset(){this.idNodeMap=new Map,this.nodeMetaMap=new WeakMap}}function Vp(){return new Ca}function Qn({maskInputOptions:e,tagName:t,type:n}){return"OPTION"===t&&(t="SELECT"),!!(e[t.toLowerCase()]||n&&e[n]||"password"===n||"INPUT"===t&&!n&&e.text)}function $t({isMasked:e,element:t,value:n,maskInputFn:r}){let o=n||"";return e?(r&&(o=r(o,t)),"*".repeat(o.length)):o}function kt(e){return e.toLowerCase()}function Xr(e){return e.toUpperCase()}const Bo="__rrweb_original__";function Jp(e){const t=e.getContext("2d");if(!t)return!0;for(let n=0;n<e.width;n+=50)for(let r=0;r<e.height;r+=50){const o=t.getImageData,s=Bo in o?o[Bo]:o;if(new Uint32Array(s.call(t,n,r,Math.min(50,e.width-n),Math.min(50,e.height-r)).data.buffer).some((e=>0!==e)))return!1}return!0}function xs(e){const t=e.type;return e.hasAttribute("data-rr-is-password")?"password":t?kt(t):null}function An(e,t,n){return"INPUT"!==t||"radio"!==n&&"checkbox"!==n?e.value:e.getAttribute("value")||""}function Ma(e,t){let n;try{n=new URL(e,Jr(t,(()=>window.location.href)))}catch{return null}return Jr(Bt([n.pathname.match(/\.([0-9a-z]+)(?:$)/i),"optionalAccess",e=>e[1]]),(()=>null))}const $o={};function Oa(e){const t=$o[e];if(t)return t;const n=window.document;let r=window[e];if(n&&"function"==typeof n.createElement)try{const t=n.createElement("iframe");t.hidden=!0,n.head.appendChild(t);const o=t.contentWindow;o&&o[e]&&(r=o[e]),n.head.removeChild(t)}catch{}return $o[e]=r.bind(window)}function Qr(...e){return Oa("setTimeout")(...e)}function Da(...e){return Oa("clearTimeout")(...e)}function Aa(e){try{return e.contentDocument}catch{}}let Xp=1;const Qp=new RegExp("[^a-z0-9-_:]"),Ht=-2;function Ns(){return Xp++}function Zp(e){if(e instanceof HTMLFormElement)return"form";const t=kt(e.tagName);return Qp.test(t)?"div":t}function eh(e){let t="";return t=e.indexOf("//")>-1?e.split("/").slice(0,3).join("/"):e.split("/")[0],t=t.split("?")[0],t}let ft,Ho;const th=/url\((?:(')([^']*)'|(")(.*?)"|([^)]*))\)/gm,nh=/^(?:[a-z+]+:)?\/\//i,rh=/^www\..*/i,sh=/^(data:)([^,]*),(.*)/i;function xn(e,t){return(e||"").replace(th,((e,n,r,o,s,i)=>{const a=r||s||i,c=n||o||"";if(!a)return e;if(nh.test(a)||rh.test(a))return`url(${c}${a}${c})`;if(sh.test(a))return`url(${c}${a}${c})`;if("/"===a[0])return`url(${c}${eh(t)+a}${c})`;const u=t.split("/"),l=a.split("/");u.pop();for(const e of l)"."!==e&&(".."===e?u.pop():u.push(e));return`url(${c}${u.join("/")}${c})`}))}const oh=/^[^ \t\n\r\u000c]+/,ih=/^[, \t\n\r\u000c]+/;function ah(e,t){if(""===t.trim())return t;let n=0;function r(e){let r;const o=e.exec(t.substring(n));return o?(r=o[0],n+=r.length,r):""}const o=[];for(;r(ih),!(n>=t.length);){let s=r(oh);if(","===s.slice(-1))s=mt(e,s.substring(0,s.length-1)),o.push(s);else{let r="";s=mt(e,s);let i=!1;for(;;){const e=t.charAt(n);if(""===e){o.push((s+r).trim());break}if(i)")"===e&&(i=!1);else{if(","===e){n+=1,o.push((s+r).trim());break}"("===e&&(i=!0)}r+=e,n+=1}}}return o.join(", ")}const zo=new WeakMap;function mt(e,t){return t&&""!==t.trim()?Zn(e,t):t}function ch(e){return!("svg"!==e.tagName&&!e.ownerSVGElement)}function Zn(e,t){let n=zo.get(e);if(n||(n=e.createElement("a"),zo.set(e,n)),t){if(t.startsWith("blob:")||t.startsWith("data:"))return t}else t="";return n.setAttribute("href",t),n.href}function xa(e,t,n,r,o,s){return r&&("src"===n||"href"===n&&("use"!==t||"#"!==r[0])||"xlink:href"===n&&"#"!==r[0]||"background"===n&&("table"===t||"td"===t||"th"===t)?mt(e,r):"srcset"===n?ah(e,r):"style"===n?xn(r,Zn(e)):"object"===t&&"data"===n?mt(e,r):"function"==typeof s?s(n,r,o):r)}function Na(e,t,n){return("video"===e||"audio"===e)&&"autoplay"===t}function uh(e,t,n,r){try{if(r&&e.matches(r))return!1;if("string"==typeof t){if(e.classList.contains(t))return!0}else for(let n=e.classList.length;n--;){const r=e.classList[n];if(t.test(r))return!0}if(n)return e.matches(n)}catch{}return!1}function lh(e,t){for(let n=e.classList.length;n--;){const r=e.classList[n];if(t.test(r))return!0}return!1}function tt(e,t,n=1/0,r=0){return!e||e.nodeType!==e.ELEMENT_NODE||r>n?-1:t(e)?r:tt(e.parentNode,t,n,r+1)}function _t(e,t){return n=>{const r=n;if(null===r)return!1;try{if(e)if("string"==typeof e){if(r.matches(`.${e}`))return!0}else if(lh(r,e))return!0;return!(!t||!r.matches(t))}catch{return!1}}}function Rt(e,t,n,r,o,s){try{const i=e.nodeType===e.ELEMENT_NODE?e:e.parentElement;if(null===i)return!1;if("INPUT"===i.tagName){const e=i.getAttribute("autocomplete");if(["current-password","new-password","cc-number","cc-exp","cc-exp-month","cc-exp-year","cc-csc"].includes(e))return!0}let a=-1,c=-1;if(s){if(c=tt(i,_t(r,o)),c<0)return!0;a=tt(i,_t(t,n),c>=0?c:1/0)}else{if(a=tt(i,_t(t,n)),a<0)return!1;c=tt(i,_t(r,o),a>=0?a:1/0)}return a>=0?!(c>=0)||a<=c:!(c>=0)&&!!s}catch{}return!!s}function dh(e,t,n){const r=e.contentWindow;if(!r)return;let o,s=!1;try{o=r.document.readyState}catch{return}if("complete"!==o){const r=Qr((()=>{s||(t(),s=!0)}),n);return void e.addEventListener("load",(()=>{Da(r),s=!0,t()}))}const i="about:blank";if(r.location.href!==i||e.src===i||""===e.src)return Qr(t,0),e.addEventListener("load",t);e.addEventListener("load",t)}function fh(e,t,n){let r,o=!1;try{r=e.sheet}catch{return}if(r)return;const s=Qr((()=>{o||(t(),o=!0)}),n);e.addEventListener("load",(()=>{Da(s),o=!0,t()}))}function ph(e,t){const{doc:n,mirror:r,blockClass:o,blockSelector:s,unblockSelector:i,maskAllText:a,maskAttributeFn:c,maskTextClass:u,unmaskTextClass:l,maskTextSelector:d,unmaskTextSelector:p,inlineStylesheet:h,maskInputOptions:m={},maskTextFn:f,maskInputFn:y,dataURLOptions:_={},inlineImages:g,recordCanvas:v,keepIframeSrcFn:b,newlyAddedElement:S=!1}=t,E=hh(n,r);switch(e.nodeType){case e.DOCUMENT_NODE:return"CSS1Compat"!==e.compatMode?{type:ce.Document,childNodes:[],compatMode:e.compatMode}:{type:ce.Document,childNodes:[]};case e.DOCUMENT_TYPE_NODE:return{type:ce.DocumentType,name:e.name,publicId:e.publicId,systemId:e.systemId,rootId:E};case e.ELEMENT_NODE:return _h(e,{doc:n,blockClass:o,blockSelector:s,unblockSelector:i,inlineStylesheet:h,maskAttributeFn:c,maskInputOptions:m,maskInputFn:y,dataURLOptions:_,inlineImages:g,recordCanvas:v,keepIframeSrcFn:b,newlyAddedElement:S,rootId:E,maskAllText:a,maskTextClass:u,unmaskTextClass:l,maskTextSelector:d,unmaskTextSelector:p});case e.TEXT_NODE:return mh(e,{doc:n,maskAllText:a,maskTextClass:u,unmaskTextClass:l,maskTextSelector:d,unmaskTextSelector:p,maskTextFn:f,maskInputOptions:m,maskInputFn:y,rootId:E});case e.CDATA_SECTION_NODE:return{type:ce.CDATA,textContent:"",rootId:E};case e.COMMENT_NODE:return{type:ce.Comment,textContent:e.textContent||"",rootId:E};default:return!1}}function hh(e,t){if(!t.hasNode(e))return;const n=t.getId(e);return 1===n?void 0:n}function mh(e,t){const{maskAllText:n,maskTextClass:r,unmaskTextClass:o,maskTextSelector:s,unmaskTextSelector:i,maskTextFn:a,maskInputOptions:c,maskInputFn:u,rootId:l}=t,d=e.parentNode&&e.parentNode.tagName;let p=e.textContent;const h="STYLE"===d||void 0,m="SCRIPT"===d||void 0,f="TEXTAREA"===d||void 0;if(h&&p){try{e.nextSibling||e.previousSibling||Bt([e,"access",e=>e.parentNode,"access",e=>e.sheet,"optionalAccess",e=>e.cssRules])&&(p=Dn(e.parentNode.sheet))}catch(t){console.warn(`Cannot get CSS styles from text's parentNode. Error: ${t}`,e)}p=xn(p,Zn(t.doc))}m&&(p="SCRIPT_PLACEHOLDER");const y=Rt(e,r,s,o,i,n);if(!h&&!m&&!f&&p&&y&&(p=a?a(p,e.parentElement):p.replace(/[\S]/g,"*")),f&&p&&(c.textarea||y)&&(p=u?u(p,e.parentNode):p.replace(/[\S]/g,"*")),"OPTION"===d&&p){p=$t({isMasked:Rt(e,r,s,o,i,Qn({type:null,tagName:d,maskInputOptions:c})),element:e,value:p,maskInputFn:u})}return{type:ce.Text,textContent:p||"",isStyle:h,rootId:l}}function _h(e,t){const{doc:n,blockClass:r,blockSelector:o,unblockSelector:s,inlineStylesheet:i,maskInputOptions:a={},maskAttributeFn:c,maskInputFn:u,dataURLOptions:l={},inlineImages:d,recordCanvas:p,keepIframeSrcFn:h,newlyAddedElement:m=!1,rootId:f,maskAllText:y,maskTextClass:_,unmaskTextClass:g,maskTextSelector:v,unmaskTextSelector:b}=t,S=uh(e,r,o,s),E=Zp(e);let k={};const w=e.attributes.length;for(let t=0;t<w;t++){const r=e.attributes[t];r.name&&!Na(E,r.name,r.value)&&(k[r.name]=xa(n,E,kt(r.name),r.value,e,c))}if("link"===E&&i){const t=Array.from(n.styleSheets).find((t=>t.href===e.href));let r=null;t&&(r=Dn(t)),r&&(k.rel=null,k.href=null,k.crossorigin=null,k._cssText=xn(r,t.href))}if("style"===E&&e.sheet&&!(e.innerText||e.textContent||"").trim().length){const t=Dn(e.sheet);t&&(k._cssText=xn(t,Zn(n)))}if("input"===E||"textarea"===E||"select"===E||"option"===E){const t=e,n=xs(t),r=An(t,Xr(E),n),o=t.checked;if("submit"!==n&&"button"!==n&&r){const e=Rt(t,_,v,g,b,Qn({type:n,tagName:Xr(E),maskInputOptions:a}));k.value=$t({isMasked:e,element:t,value:r,maskInputFn:u})}o&&(k.checked=o)}if("option"===E&&(e.selected&&!a.select?k.selected=!0:delete k.selected),"canvas"===E&&p)if("2d"===e.__context)Jp(e)||(k.rr_dataURL=e.toDataURL(l.type,l.quality));else if(!("__context"in e)){const t=e.toDataURL(l.type,l.quality),r=n.createElement("canvas");r.width=e.width,r.height=e.height;t!==r.toDataURL(l.type,l.quality)&&(k.rr_dataURL=t)}if("img"===E&&d){ft||(ft=n.createElement("canvas"),Ho=ft.getContext("2d"));const t=e,r=t.currentSrc||t.getAttribute("src")||"<unknown-src>",o=t.crossOrigin,s=()=>{t.removeEventListener("load",s);try{ft.width=t.naturalWidth,ft.height=t.naturalHeight,Ho.drawImage(t,0,0),k.rr_dataURL=ft.toDataURL(l.type,l.quality)}catch(e){if("anonymous"!==t.crossOrigin)return t.crossOrigin="anonymous",void(t.complete&&0!==t.naturalWidth?s():t.addEventListener("load",s));console.warn(`Cannot inline img src=${r}! Error: ${e}`)}"anonymous"===t.crossOrigin&&(o?k.crossOrigin=o:t.removeAttribute("crossorigin"))};t.complete&&0!==t.naturalWidth?s():t.addEventListener("load",s)}if(("audio"===E||"video"===E)&&(k.rr_mediaState=e.paused?"paused":"played",k.rr_mediaCurrentTime=e.currentTime),m||(e.scrollLeft&&(k.rr_scrollLeft=e.scrollLeft),e.scrollTop&&(k.rr_scrollTop=e.scrollTop)),S){const{width:t,height:n}=e.getBoundingClientRect();k={class:k.class,rr_width:`${t}px`,rr_height:`${n}px`}}let T;"iframe"===E&&!h(k.src)&&(!S&&!Aa(e)&&(k.rr_src=k.src),delete k.src);try{customElements.get(E)&&(T=!0)}catch{}return{type:ce.Element,tagName:E,attributes:k,childNodes:[],isSVG:ch(e)||void 0,needBlock:S,rootId:f,isCustom:T}}function Z(e){return null==e?"":e.toLowerCase()}function gh(e,t){if(t.comment&&e.type===ce.Comment)return!0;if(e.type===ce.Element){if(t.script&&("script"===e.tagName||"link"===e.tagName&&("preload"===e.attributes.rel||"modulepreload"===e.attributes.rel)||"link"===e.tagName&&"prefetch"===e.attributes.rel&&"string"==typeof e.attributes.href&&"js"===Ma(e.attributes.href)))return!0;if(t.headFavicon&&("link"===e.tagName&&"shortcut icon"===e.attributes.rel||"meta"===e.tagName&&(Z(e.attributes.name).match(/^msapplication-tile(image|color)$/)||"application-name"===Z(e.attributes.name)||"icon"===Z(e.attributes.rel)||"apple-touch-icon"===Z(e.attributes.rel)||"shortcut icon"===Z(e.attributes.rel))))return!0;if("meta"===e.tagName){if(t.headMetaDescKeywords&&Z(e.attributes.name).match(/^description|keywords$/))return!0;if(t.headMetaSocial&&(Z(e.attributes.property).match(/^(og|twitter|fb):/)||Z(e.attributes.name).match(/^(og|twitter):/)||"pinterest"===Z(e.attributes.name)))return!0;if(t.headMetaRobots&&("robots"===Z(e.attributes.name)||"googlebot"===Z(e.attributes.name)||"bingbot"===Z(e.attributes.name)))return!0;if(t.headMetaHttpEquiv&&void 0!==e.attributes["http-equiv"])return!0;if(t.headMetaAuthorship&&("author"===Z(e.attributes.name)||"generator"===Z(e.attributes.name)||"framework"===Z(e.attributes.name)||"publisher"===Z(e.attributes.name)||"progid"===Z(e.attributes.name)||Z(e.attributes.property).match(/^article:/)||Z(e.attributes.property).match(/^product:/)))return!0;if(t.headMetaVerification&&("google-site-verification"===Z(e.attributes.name)||"yandex-verification"===Z(e.attributes.name)||"csrf-token"===Z(e.attributes.name)||"p:domain_verify"===Z(e.attributes.name)||"verify-v1"===Z(e.attributes.name)||"verification"===Z(e.attributes.name)||"shopify-checkout-api-token"===Z(e.attributes.name)))return!0}}return!1}function gt(e,t){const{doc:n,mirror:r,blockClass:o,blockSelector:s,unblockSelector:i,maskAllText:a,maskTextClass:c,unmaskTextClass:u,maskTextSelector:l,unmaskTextSelector:d,skipChild:p=!1,inlineStylesheet:h=!0,maskInputOptions:m={},maskAttributeFn:f,maskTextFn:y,maskInputFn:_,slimDOMOptions:g,dataURLOptions:v={},inlineImages:b=!1,recordCanvas:S=!1,onSerialize:E,onIframeLoad:k,iframeLoadTimeout:w=5e3,onStylesheetLoad:T,stylesheetLoadTimeout:I=5e3,keepIframeSrcFn:x=()=>!1,newlyAddedElement:C=!1}=t;let{preserveWhiteSpace:M=!0}=t;const O=ph(e,{doc:n,mirror:r,blockClass:o,blockSelector:s,maskAllText:a,unblockSelector:i,maskTextClass:c,unmaskTextClass:u,maskTextSelector:l,unmaskTextSelector:d,inlineStylesheet:h,maskInputOptions:m,maskAttributeFn:f,maskTextFn:y,maskInputFn:_,dataURLOptions:v,inlineImages:b,recordCanvas:S,keepIframeSrcFn:x,newlyAddedElement:C});if(!O)return console.warn(e,"not serialized"),null;let A;A=r.hasNode(e)?r.getId(e):gh(O,g)||!M&&O.type===ce.Text&&!O.isStyle&&!O.textContent.replace(/^\s+|\s+$/gm,"").length?-2:Ns();const R=Object.assign(O,{id:A});if(r.add(e,R),-2===A)return null;E&&E(e);let D=!p;if(R.type===ce.Element){D=D&&!R.needBlock,delete R.needBlock;const t=e.shadowRoot;t&&Ft(t)&&(R.isShadowHost=!0)}if((R.type===ce.Document||R.type===ce.Element)&&D){g.headWhitespace&&R.type===ce.Element&&"head"===R.tagName&&(M=!1);const t={doc:n,mirror:r,blockClass:o,blockSelector:s,maskAllText:a,unblockSelector:i,maskTextClass:c,unmaskTextClass:u,maskTextSelector:l,unmaskTextSelector:d,skipChild:p,inlineStylesheet:h,maskInputOptions:m,maskAttributeFn:f,maskTextFn:y,maskInputFn:_,slimDOMOptions:g,dataURLOptions:v,inlineImages:b,recordCanvas:S,preserveWhiteSpace:M,onSerialize:E,onIframeLoad:k,iframeLoadTimeout:w,onStylesheetLoad:T,stylesheetLoadTimeout:I,keepIframeSrcFn:x};for(const n of Array.from(e.childNodes)){const e=gt(n,t);e&&R.childNodes.push(e)}if(Hp(e)&&e.shadowRoot)for(const n of Array.from(e.shadowRoot.childNodes)){const r=gt(n,t);r&&(Ft(e.shadowRoot)&&(r.isShadow=!0),R.childNodes.push(r))}}return e.parentNode&&Lt(e.parentNode)&&Ft(e.parentNode)&&(R.isShadow=!0),R.type===ce.Element&&"iframe"===R.tagName&&dh(e,(()=>{const t=Aa(e);if(t&&k){const n=gt(t,{doc:t,mirror:r,blockClass:o,blockSelector:s,unblockSelector:i,maskAllText:a,maskTextClass:c,unmaskTextClass:u,maskTextSelector:l,unmaskTextSelector:d,skipChild:!1,inlineStylesheet:h,maskInputOptions:m,maskAttributeFn:f,maskTextFn:y,maskInputFn:_,slimDOMOptions:g,dataURLOptions:v,inlineImages:b,recordCanvas:S,preserveWhiteSpace:M,onSerialize:E,onIframeLoad:k,iframeLoadTimeout:w,onStylesheetLoad:T,stylesheetLoadTimeout:I,keepIframeSrcFn:x});n&&k(e,n)}}),w),R.type===ce.Element&&"link"===R.tagName&&"string"==typeof R.attributes.rel&&("stylesheet"===R.attributes.rel||"preload"===R.attributes.rel&&"string"==typeof R.attributes.href&&"css"===Ma(R.attributes.href))&&fh(e,(()=>{if(T){const t=gt(e,{doc:n,mirror:r,blockClass:o,blockSelector:s,unblockSelector:i,maskAllText:a,maskTextClass:c,unmaskTextClass:u,maskTextSelector:l,unmaskTextSelector:d,skipChild:!1,inlineStylesheet:h,maskInputOptions:m,maskAttributeFn:f,maskTextFn:y,maskInputFn:_,slimDOMOptions:g,dataURLOptions:v,inlineImages:b,recordCanvas:S,preserveWhiteSpace:M,onSerialize:E,onIframeLoad:k,iframeLoadTimeout:w,onStylesheetLoad:T,stylesheetLoadTimeout:I,keepIframeSrcFn:x});t&&T(e,t)}}),I),R}function yh(e,t){const{mirror:n=new Ca,blockClass:r="rr-block",blockSelector:o=null,unblockSelector:s=null,maskAllText:i=!1,maskTextClass:a="rr-mask",unmaskTextClass:c=null,maskTextSelector:u=null,unmaskTextSelector:l=null,inlineStylesheet:d=!0,inlineImages:p=!1,recordCanvas:h=!1,maskAllInputs:m=!1,maskAttributeFn:f,maskTextFn:y,maskInputFn:_,slimDOM:g=!1,dataURLOptions:v,preserveWhiteSpace:b,onSerialize:S,onIframeLoad:E,iframeLoadTimeout:k,onStylesheetLoad:w,stylesheetLoadTimeout:T,keepIframeSrcFn:I=()=>!1}=t;return gt(e,{doc:e,mirror:n,blockClass:r,blockSelector:o,unblockSelector:s,maskAllText:i,maskTextClass:a,unmaskTextClass:c,maskTextSelector:u,unmaskTextSelector:l,skipChild:!1,inlineStylesheet:d,maskInputOptions:!0===m?{color:!0,date:!0,"datetime-local":!0,email:!0,month:!0,number:!0,range:!0,search:!0,tel:!0,text:!0,time:!0,url:!0,week:!0,textarea:!0,select:!0}:!1===m?{}:m,maskAttributeFn:f,maskTextFn:y,maskInputFn:_,slimDOMOptions:!0===g||"all"===g?{script:!0,comment:!0,headFavicon:!0,headWhitespace:!0,headMetaDescKeywords:"all"===g,headMetaSocial:!0,headMetaRobots:!0,headMetaHttpEquiv:!0,headMetaAuthorship:!0,headMetaVerification:!0}:!1===g?{}:g,dataURLOptions:v,inlineImages:p,recordCanvas:h,preserveWhiteSpace:b,onSerialize:S,onIframeLoad:E,iframeLoadTimeout:k,onStylesheetLoad:w,stylesheetLoadTimeout:T,keepIframeSrcFn:I,newlyAddedElement:!1})}function ze(e){let t,n=e[0],r=1;for(;r<e.length;){const o=e[r],s=e[r+1];if(r+=2,("optionalAccess"===o||"optionalCall"===o)&&null==n)return;"access"===o||"optionalAccess"===o?(t=n,n=s(n)):("call"===o||"optionalCall"===o)&&(n=s(((...e)=>n.call(t,...e))),t=void 0)}return n}function de(e,t,n=document){const r={capture:!0,passive:!0};return n.addEventListener(e,t,r),()=>n.removeEventListener(e,t,r)}const pt="Please stop import mirror directly. Instead of that,\r\nnow you can use replayer.getMirror() to access the mirror instance of a replayer,\r\nor you can use record.mirror to access the mirror instance during recording.";let Wo={map:{},getId:()=>(console.error(pt),-1),getNode:()=>(console.error(pt),null),removeNodeFromMap(){console.error(pt)},has:()=>(console.error(pt),!1),reset(){console.error(pt)}};function zt(e,t,n={}){let r=null,o=0;return function(...s){const i=Date.now();!o&&!1===n.leading&&(o=i);const a=t-(i-o),c=this;a<=0||a>t?(r&&(Th(r),r=null),o=i,e.apply(c,s)):!r&&!1!==n.trailing&&(r=er((()=>{o=!1===n.leading?0:Date.now(),r=null,e.apply(c,s)}),a))}}function Pa(e,t,n,r,o=window){const s=o.Object.getOwnPropertyDescriptor(e,t);return o.Object.defineProperty(e,t,r?n:{set(e){er((()=>{n.set.call(this,e)}),0),s&&s.set&&s.set.call(this,e)}}),()=>Pa(e,t,s||{},!0)}function Ps(e,t,n){try{if(!(t in e))return()=>{};const r=e[t],o=n(r);return"function"==typeof o&&(o.prototype=o.prototype||{},Object.defineProperties(o,{__rrweb_original__:{enumerable:!1,value:r}})),e[t]=o,()=>{e[t]=r}}catch{return()=>{}}}typeof window<"u"&&window.Proxy&&window.Reflect&&(Wo=new Proxy(Wo,{get:(e,t,n)=>("map"===t&&console.error(pt),Reflect.get(e,t,n))}));let Nn=Date.now;function La(e){const t=e.document;return{left:t.scrollingElement?t.scrollingElement.scrollLeft:void 0!==e.pageXOffset?e.pageXOffset:ze([t,"optionalAccess",e=>e.documentElement,"access",e=>e.scrollLeft])||ze([t,"optionalAccess",e=>e.body,"optionalAccess",e=>e.parentElement,"optionalAccess",e=>e.scrollLeft])||ze([t,"optionalAccess",e=>e.body,"optionalAccess",e=>e.scrollLeft])||0,top:t.scrollingElement?t.scrollingElement.scrollTop:void 0!==e.pageYOffset?e.pageYOffset:ze([t,"optionalAccess",e=>e.documentElement,"access",e=>e.scrollTop])||ze([t,"optionalAccess",e=>e.body,"optionalAccess",e=>e.parentElement,"optionalAccess",e=>e.scrollTop])||ze([t,"optionalAccess",e=>e.body,"optionalAccess",e=>e.scrollTop])||0}}function Fa(){return window.innerHeight||document.documentElement&&document.documentElement.clientHeight||document.body&&document.body.clientHeight}function Ua(){return window.innerWidth||document.documentElement&&document.documentElement.clientWidth||document.body&&document.body.clientWidth}function ja(e){return e?e.nodeType===e.ELEMENT_NODE?e:e.parentElement:null}function _e(e,t,n,r,o){if(!e)return!1;const s=ja(e);if(!s)return!1;const i=_t(t,n);if(!o){const e=r&&s.matches(r);return i(s)&&!e}const a=tt(s,i);let c=-1;return!(a<0)&&(r&&(c=tt(s,_t(null,r))),a>-1&&c<0||a<c)}function Eh(e,t){return-1!==t.getId(e)}function br(e,t){return-2===t.getId(e)}function Ba(e,t){if(Lt(e))return!1;const n=t.getId(e);return!t.has(n)||(!e.parentNode||e.parentNode.nodeType!==e.DOCUMENT_NODE)&&(!e.parentNode||Ba(e.parentNode,t))}function Zr(e){return!!e.changedTouches}function Sh(e=window){"NodeList"in e&&!e.NodeList.prototype.forEach&&(e.NodeList.prototype.forEach=Array.prototype.forEach),"DOMTokenList"in e&&!e.DOMTokenList.prototype.forEach&&(e.DOMTokenList.prototype.forEach=Array.prototype.forEach),Node.prototype.contains||(Node.prototype.contains=(...e)=>{let t=e[0];if(!(0 in e))throw new TypeError("1 argument is required");do{if(this===t)return!0}while(t=t&&t.parentNode);return!1})}function $a(e,t){return!("IFRAME"!==e.nodeName||!t.getMeta(e))}function Ha(e,t){return!("LINK"!==e.nodeName||e.nodeType!==e.ELEMENT_NODE||!e.getAttribute||"stylesheet"!==e.getAttribute("rel")||!t.getMeta(e))}function es(e){return!!ze([e,"optionalAccess",e=>e.shadowRoot])}/[1-9][0-9]{12}/.test(Date.now().toString())||(Nn=()=>(new Date).getTime());class bh{constructor(){this.id=1,this.styleIDMap=new WeakMap,this.idStyleMap=new Map}getId(e){return Cd(this.styleIDMap.get(e),(()=>-1))}has(e){return this.styleIDMap.has(e)}add(e,t){if(this.has(e))return this.getId(e);let n;return n=void 0===t?this.id++:t,this.styleIDMap.set(e,n),this.idStyleMap.set(n,e),n}getStyle(e){return this.idStyleMap.get(e)||null}reset(){this.styleIDMap=new WeakMap,this.idStyleMap=new Map,this.id=1}generateId(){return this.id++}}function za(e){let t=null;return ze([e,"access",e=>e.getRootNode,"optionalCall",e=>e(),"optionalAccess",e=>e.nodeType])===Node.DOCUMENT_FRAGMENT_NODE&&e.getRootNode().host&&(t=e.getRootNode().host),t}function vh(e){let t,n=e;for(;t=za(n);)n=t;return n}function Ih(e){const t=e.ownerDocument;if(!t)return!1;const n=vh(e);return t.contains(n)}function Wa(e){const t=e.ownerDocument;return!!t&&(t.contains(e)||Ih(e))}const Go={};function Ls(e){const t=Go[e];if(t)return t;const n=window.document;let r=window[e];if(n&&"function"==typeof n.createElement)try{const t=n.createElement("iframe");t.hidden=!0,n.head.appendChild(t);const o=t.contentWindow;o&&o[e]&&(r=o[e]),n.head.removeChild(t)}catch{}return Go[e]=r.bind(window)}function wh(...e){return Ls("requestAnimationFrame")(...e)}function er(...e){return Ls("setTimeout")(...e)}function Th(...e){return Ls("clearTimeout")(...e)}var Yo,qo,x=(e=>(e[e.DomContentLoaded=0]="DomContentLoaded",e[e.Load=1]="Load",e[e.FullSnapshot=2]="FullSnapshot",e[e.IncrementalSnapshot=3]="IncrementalSnapshot",e[e.Meta=4]="Meta",e[e.Custom=5]="Custom",e[e.Plugin=6]="Plugin",e))(x||{}),A=(e=>(e[e.Mutation=0]="Mutation",e[e.MouseMove=1]="MouseMove",e[e.MouseInteraction=2]="MouseInteraction",e[e.Scroll=3]="Scroll",e[e.ViewportResize=4]="ViewportResize",e[e.Input=5]="Input",e[e.TouchMove=6]="TouchMove",e[e.MediaInteraction=7]="MediaInteraction",e[e.StyleSheetRule=8]="StyleSheetRule",e[e.CanvasMutation=9]="CanvasMutation",e[e.Font=10]="Font",e[e.Log=11]="Log",e[e.Drag=12]="Drag",e[e.StyleDeclaration=13]="StyleDeclaration",e[e.Selection=14]="Selection",e[e.AdoptedStyleSheet=15]="AdoptedStyleSheet",e[e.CustomElement=16]="CustomElement",e))(A||{}),le=(e=>(e[e.MouseUp=0]="MouseUp",e[e.MouseDown=1]="MouseDown",e[e.Click=2]="Click",e[e.ContextMenu=3]="ContextMenu",e[e.DblClick=4]="DblClick",e[e.Focus=5]="Focus",e[e.Blur=6]="Blur",e[e.TouchStart=7]="TouchStart",e[e.TouchMove_Departed=8]="TouchMove_Departed",e[e.TouchEnd=9]="TouchEnd",e[e.TouchCancel=10]="TouchCancel",e))(le||{}),xe=(e=>(e[e.Mouse=0]="Mouse",e[e.Pen=1]="Pen",e[e.Touch=2]="Touch",e))(xe||{});function Fs(e){try{return e.contentDocument}catch{}}function kh(e){try{return e.contentWindow}catch{}}function Rh(e){let t,n=e[0],r=1;for(;r<e.length;){const o=e[r],s=e[r+1];if(r+=2,("optionalAccess"===o||"optionalCall"===o)&&null==n)return;"access"===o||"optionalAccess"===o?(t=n,n=s(n)):("call"===o||"optionalCall"===o)&&(n=s(((...e)=>n.call(t,...e))),t=void 0)}return n}function Ko(e){return"__ln"in e}!function(e){e[e.Document=0]="Document",e[e.DocumentType=1]="DocumentType",e[e.Element=2]="Element",e[e.Text=3]="Text",e[e.CDATA=4]="CDATA",e[e.Comment=5]="Comment"}(Yo||(Yo={})),function(e){e[e.PLACEHOLDER=0]="PLACEHOLDER",e[e.ELEMENT_NODE=1]="ELEMENT_NODE",e[e.ATTRIBUTE_NODE=2]="ATTRIBUTE_NODE",e[e.TEXT_NODE=3]="TEXT_NODE",e[e.CDATA_SECTION_NODE=4]="CDATA_SECTION_NODE",e[e.ENTITY_REFERENCE_NODE=5]="ENTITY_REFERENCE_NODE",e[e.ENTITY_NODE=6]="ENTITY_NODE",e[e.PROCESSING_INSTRUCTION_NODE=7]="PROCESSING_INSTRUCTION_NODE",e[e.COMMENT_NODE=8]="COMMENT_NODE",e[e.DOCUMENT_NODE=9]="DOCUMENT_NODE",e[e.DOCUMENT_TYPE_NODE=10]="DOCUMENT_TYPE_NODE",e[e.DOCUMENT_FRAGMENT_NODE=11]="DOCUMENT_FRAGMENT_NODE"}(qo||(qo={}));class Ch{constructor(){this.length=0,this.head=null,this.tail=null}get(e){if(e>=this.length)throw new Error("Position outside of list range");let t=this.head;for(let n=0;n<e;n++)t=Rh([t,"optionalAccess",e=>e.next])||null;return t}addNode(e){const t={value:e,previous:null,next:null};if(e.__ln=t,e.previousSibling&&Ko(e.previousSibling)){const n=e.previousSibling.__ln.next;t.next=n,t.previous=e.previousSibling.__ln,e.previousSibling.__ln.next=t,n&&(n.previous=t)}else if(e.nextSibling&&Ko(e.nextSibling)&&e.nextSibling.__ln.previous){const n=e.nextSibling.__ln.previous;t.previous=n,t.next=e.nextSibling.__ln,e.nextSibling.__ln.previous=t,n&&(n.next=t)}else this.head&&(this.head.previous=t),t.next=this.head,this.head=t;null===t.next&&(this.tail=t),this.length++}removeNode(e){const t=e.__ln;this.head&&(t.previous?(t.previous.next=t.next,t.next?t.next.previous=t.previous:this.tail=t.previous):(this.head=t.next,this.head?this.head.previous=null:this.tail=null),e.__ln&&delete e.__ln,this.length--)}}const Vo=(e,t)=>`${e}@${t}`;class Mh{constructor(){this.frozen=!1,this.locked=!1,this.texts=[],this.attributes=[],this.attributeMap=new WeakMap,this.removes=[],this.mapRemoves=[],this.movedMap={},this.addedSet=new Set,this.movedSet=new Set,this.droppedSet=new Set,this.processMutations=e=>{e.forEach(this.processMutation),this.emit()},this.emit=()=>{if(this.frozen||this.locked)return;const e=[],t=new Set,n=new Ch,r=e=>{let t=e,n=-2;for(;-2===n;)t=t&&t.nextSibling,n=t&&this.mirror.getId(t);return n},o=o=>{if(!o.parentNode||!Wa(o))return;const s=Lt(o.parentNode)?this.mirror.getId(za(o)):this.mirror.getId(o.parentNode),i=r(o);if(-1===s||-1===i)return n.addNode(o);const a=gt(o,{doc:this.doc,mirror:this.mirror,blockClass:this.blockClass,blockSelector:this.blockSelector,maskAllText:this.maskAllText,unblockSelector:this.unblockSelector,maskTextClass:this.maskTextClass,unmaskTextClass:this.unmaskTextClass,maskTextSelector:this.maskTextSelector,unmaskTextSelector:this.unmaskTextSelector,skipChild:!0,newlyAddedElement:!0,inlineStylesheet:this.inlineStylesheet,maskInputOptions:this.maskInputOptions,maskAttributeFn:this.maskAttributeFn,maskTextFn:this.maskTextFn,maskInputFn:this.maskInputFn,slimDOMOptions:this.slimDOMOptions,dataURLOptions:this.dataURLOptions,recordCanvas:this.recordCanvas,inlineImages:this.inlineImages,onSerialize:e=>{$a(e,this.mirror)&&!_e(e,this.blockClass,this.blockSelector,this.unblockSelector,!1)&&this.iframeManager.addIframe(e),Ha(e,this.mirror)&&this.stylesheetManager.trackLinkElement(e),es(o)&&this.shadowDomManager.addShadowRoot(o.shadowRoot,this.doc)},onIframeLoad:(e,t)=>{_e(e,this.blockClass,this.blockSelector,this.unblockSelector,!1)||(this.iframeManager.attachIframe(e,t),e.contentWindow&&this.canvasManager.addWindow(e.contentWindow),this.shadowDomManager.observeAttachShadow(e))},onStylesheetLoad:(e,t)=>{this.stylesheetManager.attachLinkElement(e,t)}});a&&(e.push({parentId:s,nextId:i,node:a}),t.add(a.id))};for(;this.mapRemoves.length;)this.mirror.removeNodeFromMap(this.mapRemoves.shift());for(const e of this.movedSet)Jo(this.removes,e,this.mirror)&&!this.movedSet.has(e.parentNode)||o(e);for(const e of this.addedSet)!Xo(this.droppedSet,e)&&!Jo(this.removes,e,this.mirror)||Xo(this.movedSet,e)?o(e):this.droppedSet.add(e);let s=null;for(;n.length;){let e=null;if(s){const t=this.mirror.getId(s.value.parentNode),n=r(s.value);-1!==t&&-1!==n&&(e=s)}if(!e){let t=n.tail;for(;t;){const n=t;if(t=t.previous,n){const t=this.mirror.getId(n.value.parentNode);if(-1===r(n.value))continue;if(-1!==t){e=n;break}{const t=n.value;if(t.parentNode&&t.parentNode.nodeType===Node.DOCUMENT_FRAGMENT_NODE){const r=t.parentNode.host;if(-1!==this.mirror.getId(r)){e=n;break}}}}}}if(!e){for(;n.head;)n.removeNode(n.head.value);break}s=e.previous,n.removeNode(e.value),o(e.value)}const i={texts:this.texts.map((e=>({id:this.mirror.getId(e.node),value:e.value}))).filter((e=>!t.has(e.id))).filter((e=>this.mirror.has(e.id))),attributes:this.attributes.map((e=>{const{attributes:t}=e;if("string"==typeof t.style){const n=JSON.stringify(e.styleDiff),r=JSON.stringify(e._unchangedStyles);n.length<t.style.length&&(n+r).split("var(").length===t.style.split("var(").length&&(t.style=e.styleDiff)}return{id:this.mirror.getId(e.node),attributes:t}})).filter((e=>!t.has(e.id))).filter((e=>this.mirror.has(e.id))),removes:this.removes,adds:e};!i.texts.length&&!i.attributes.length&&!i.removes.length&&!i.adds.length||(this.texts=[],this.attributes=[],this.attributeMap=new WeakMap,this.removes=[],this.addedSet=new Set,this.movedSet=new Set,this.droppedSet=new Set,this.movedMap={},this.mutationCb(i))},this.processMutation=e=>{if(!br(e.target,this.mirror))switch(e.type){case"characterData":{const t=e.target.textContent;!_e(e.target,this.blockClass,this.blockSelector,this.unblockSelector,!1)&&t!==e.oldValue&&this.texts.push({value:Rt(e.target,this.maskTextClass,this.maskTextSelector,this.unmaskTextClass,this.unmaskTextSelector,this.maskAllText)&&t?this.maskTextFn?this.maskTextFn(t,ja(e.target)):t.replace(/[\S]/g,"*"):t,node:e.target});break}case"attributes":{const t=e.target;let n=e.attributeName,r=e.target.getAttribute(n);if("value"===n){const n=xs(t),o=t.tagName;r=An(t,o,n);const s=Qn({maskInputOptions:this.maskInputOptions,tagName:o,type:n});r=$t({isMasked:Rt(e.target,this.maskTextClass,this.maskTextSelector,this.unmaskTextClass,this.unmaskTextSelector,s),element:t,value:r,maskInputFn:this.maskInputFn})}if(_e(e.target,this.blockClass,this.blockSelector,this.unblockSelector,!1)||r===e.oldValue)return;let o=this.attributeMap.get(e.target);if("IFRAME"===t.tagName&&"src"===n&&!this.keepIframeSrcFn(r)){if(Fs(t))return;n="rr_src"}if(o||(o={node:e.target,attributes:{},styleDiff:{},_unchangedStyles:{}},this.attributes.push(o),this.attributeMap.set(e.target,o)),"type"===n&&"INPUT"===t.tagName&&"password"===(e.oldValue||"").toLowerCase()&&t.setAttribute("data-rr-is-password","true"),!Na(t.tagName,n)&&(o.attributes[n]=xa(this.doc,kt(t.tagName),kt(n),r,t,this.maskAttributeFn),"style"===n)){if(!this.unattachedDoc)try{this.unattachedDoc=document.implementation.createHTMLDocument()}catch{this.unattachedDoc=this.doc}const n=this.unattachedDoc.createElement("span");e.oldValue&&n.setAttribute("style",e.oldValue);for(const e of Array.from(t.style)){const r=t.style.getPropertyValue(e),s=t.style.getPropertyPriority(e);r!==n.style.getPropertyValue(e)||s!==n.style.getPropertyPriority(e)?o.styleDiff[e]=""===s?r:[r,s]:o._unchangedStyles[e]=[r,s]}for(const e of Array.from(n.style))""===t.style.getPropertyValue(e)&&(o.styleDiff[e]=!1)}break}case"childList":if(_e(e.target,this.blockClass,this.blockSelector,this.unblockSelector,!0))return;e.addedNodes.forEach((t=>this.genAdds(t,e.target))),e.removedNodes.forEach((t=>{const n=this.mirror.getId(t),r=Lt(e.target)?this.mirror.getId(e.target.host):this.mirror.getId(e.target);_e(e.target,this.blockClass,this.blockSelector,this.unblockSelector,!1)||br(t,this.mirror)||!Eh(t,this.mirror)||(this.addedSet.has(t)?(ts(this.addedSet,t),this.droppedSet.add(t)):this.addedSet.has(e.target)&&-1===n||Ba(e.target,this.mirror)||(this.movedSet.has(t)&&this.movedMap[Vo(n,r)]?ts(this.movedSet,t):this.removes.push({parentId:r,id:n,isShadow:!(!Lt(e.target)||!Ft(e.target))||void 0})),this.mapRemoves.push(t))}))}},this.genAdds=(e,t)=>{if(!this.processedNodeManager.inOtherBuffer(e,this)&&!this.addedSet.has(e)&&!this.movedSet.has(e)){if(this.mirror.hasNode(e)){if(br(e,this.mirror))return;this.movedSet.add(e);let n=null;t&&this.mirror.hasNode(t)&&(n=this.mirror.getId(t)),n&&-1!==n&&(this.movedMap[Vo(this.mirror.getId(e),n)]=!0)}else this.addedSet.add(e),this.droppedSet.delete(e);_e(e,this.blockClass,this.blockSelector,this.unblockSelector,!1)||(e.childNodes.forEach((e=>this.genAdds(e))),es(e)&&e.shadowRoot.childNodes.forEach((t=>{this.processedNodeManager.add(t,this),this.genAdds(t,e)})))}}}init(e){["mutationCb","blockClass","blockSelector","unblockSelector","maskAllText","maskTextClass","unmaskTextClass","maskTextSelector","unmaskTextSelector","inlineStylesheet","maskInputOptions","maskAttributeFn","maskTextFn","maskInputFn","keepIframeSrcFn","recordCanvas","inlineImages","slimDOMOptions","dataURLOptions","doc","mirror","iframeManager","stylesheetManager","shadowDomManager","canvasManager","processedNodeManager"].forEach((t=>{this[t]=e[t]}))}freeze(){this.frozen=!0,this.canvasManager.freeze()}unfreeze(){this.frozen=!1,this.canvasManager.unfreeze(),this.emit()}isFrozen(){return this.frozen}lock(){this.locked=!0,this.canvasManager.lock()}unlock(){this.locked=!1,this.canvasManager.unlock(),this.emit()}reset(){this.shadowDomManager.reset(),this.canvasManager.reset()}}function ts(e,t){e.delete(t),t.childNodes.forEach((t=>ts(e,t)))}function Jo(e,t,n){return 0!==e.length&&Oh(e,t,n)}function Oh(e,t,n){let r=t.parentNode;for(;r;){const t=n.getId(r);if(e.some((e=>e.id===t)))return!0;r=r.parentNode}return!1}function Xo(e,t){return 0!==e.size&&Ga(e,t)}function Ga(e,t){const{parentNode:n}=t;return!!n&&(!!e.has(n)||Ga(e,n))}let Ut;function Dh(e){Ut=e}function Ah(){Ut=void 0}const U=e=>Ut?(...t)=>{try{return e(...t)}catch(e){if(Ut&&!0===Ut(e))return()=>{};throw e}}:e;function ke(e){let t,n=e[0],r=1;for(;r<e.length;){const o=e[r],s=e[r+1];if(r+=2,("optionalAccess"===o||"optionalCall"===o)&&null==n)return;"access"===o||"optionalAccess"===o?(t=n,n=s(n)):("call"===o||"optionalCall"===o)&&(n=s(((...e)=>n.call(t,...e))),t=void 0)}return n}const yt=[];function nn(e){try{if("composedPath"in e){const t=e.composedPath();if(t.length)return t[0]}else if("path"in e&&e.path.length)return e.path[0]}catch{}return e&&e.target}function Ya(e,t){const n=new Mh;yt.push(n),n.init(e);let r=window.MutationObserver||window.__rrMutationObserver;const o=ke([window,"optionalAccess",e=>e.Zone,"optionalAccess",e=>e.__symbol__,"optionalCall",e=>e("MutationObserver")]);o&&window[o]&&(r=window[o]);const s=new r(U((t=>{e.onMutation&&!1===e.onMutation(t)||n.processMutations.bind(n)(t)})));return s.observe(t,{attributes:!0,attributeOldValue:!0,characterData:!0,characterDataOldValue:!0,childList:!0,subtree:!0}),s}function xh({mousemoveCb:e,sampling:t,doc:n,mirror:r}){if(!1===t.mousemove)return()=>{};const o="number"==typeof t.mousemove?t.mousemove:50,s="number"==typeof t.mousemoveCallback?t.mousemoveCallback:500;let i,a=[];const c=zt(U((t=>{const n=Date.now()-i;e(a.map((e=>(e.timeOffset-=n,e))),t),a=[],i=null})),s),u=U(zt(U((e=>{const t=nn(e),{clientX:n,clientY:o}=Zr(e)?e.changedTouches[0]:e;i||(i=Nn()),a.push({x:n,y:o,id:r.getId(t),timeOffset:Nn()-i}),c(typeof DragEvent<"u"&&e instanceof DragEvent?A.Drag:e instanceof MouseEvent?A.MouseMove:A.TouchMove)})),o,{trailing:!1})),l=[de("mousemove",u,n),de("touchmove",u,n),de("drag",u,n)];return U((()=>{l.forEach((e=>e()))}))}function Nh({mouseInteractionCb:e,doc:t,mirror:n,blockClass:r,blockSelector:o,unblockSelector:s,sampling:i}){if(!1===i.mouseInteraction)return()=>{};const a=!0===i.mouseInteraction||void 0===i.mouseInteraction?{}:i.mouseInteraction,c=[];let u=null;return Object.keys(le).filter((e=>Number.isNaN(Number(e))&&!e.endsWith("_Departed")&&!1!==a[e])).forEach((i=>{let a=kt(i);const l=(t=>i=>{const a=nn(i);if(_e(a,r,o,s,!0))return;let c=null,l=t;if("pointerType"in i){switch(i.pointerType){case"mouse":c=xe.Mouse;break;case"touch":c=xe.Touch;break;case"pen":c=xe.Pen}c===xe.Touch?le[t]===le.MouseDown?l="TouchStart":le[t]===le.MouseUp&&(l="TouchEnd"):xe.Pen}else Zr(i)&&(c=xe.Touch);null!==c?(u=c,(l.startsWith("Touch")&&c===xe.Touch||l.startsWith("Mouse")&&c===xe.Mouse)&&(c=null)):le[t]===le.Click&&(c=u,u=null);const d=Zr(i)?i.changedTouches[0]:i;if(!d)return;const p=n.getId(a),{clientX:h,clientY:m}=d;U(e)({type:le[l],id:p,x:h,y:m,...null!==c&&{pointerType:c}})})(i);if(window.PointerEvent)switch(le[i]){case le.MouseDown:case le.MouseUp:a=a.replace("mouse","pointer");break;case le.TouchStart:case le.TouchEnd:return}c.push(de(a,l,t))})),U((()=>{c.forEach((e=>e()))}))}function qa({scrollCb:e,doc:t,mirror:n,blockClass:r,blockSelector:o,unblockSelector:s,sampling:i}){return de("scroll",U(zt(U((i=>{const a=nn(i);if(!a||_e(a,r,o,s,!0))return;const c=n.getId(a);if(a===t&&t.defaultView){const n=La(t.defaultView);e({id:c,x:n.left,y:n.top})}else e({id:c,x:a.scrollLeft,y:a.scrollTop})})),i.scroll||100)),t)}function Ph({viewportResizeCb:e},{win:t}){let n=-1,r=-1;return de("resize",U(zt(U((()=>{const t=Fa(),o=Ua();(n!==t||r!==o)&&(e({width:Number(o),height:Number(t)}),n=t,r=o)})),200)),t)}const Lh=["INPUT","TEXTAREA","SELECT"],Qo=new WeakMap;function Fh({inputCb:e,doc:t,mirror:n,blockClass:r,blockSelector:o,unblockSelector:s,ignoreClass:i,ignoreSelector:a,maskInputOptions:c,maskInputFn:u,sampling:l,userTriggeredOnInput:d,maskTextClass:p,unmaskTextClass:h,maskTextSelector:m,unmaskTextSelector:f}){function y(e){let n=nn(e);const l=e.isTrusted,y=n&&Xr(n.tagName);if("OPTION"===y&&(n=n.parentElement),!n||!y||Lh.indexOf(y)<0||_e(n,r,o,s,!0))return;const g=n;if(g.classList.contains(i)||a&&g.matches(a))return;const v=xs(n);let b=An(g,y,v),S=!1;const E=Qn({maskInputOptions:c,tagName:y,type:v}),k=Rt(n,p,m,h,f,E);("radio"===v||"checkbox"===v)&&(S=n.checked),b=$t({isMasked:k,element:n,value:b,maskInputFn:u}),_(n,d?{text:b,isChecked:S,userTriggered:l}:{text:b,isChecked:S});const w=n.name;"radio"===v&&w&&S&&t.querySelectorAll(`input[type="radio"][name="${w}"]`).forEach((e=>{if(e!==n){const t=$t({isMasked:k,element:e,value:An(e,y,v),maskInputFn:u});_(e,d?{text:t,isChecked:!S,userTriggered:!1}:{text:t,isChecked:!S})}}))}function _(t,r){const o=Qo.get(t);if(!o||o.text!==r.text||o.isChecked!==r.isChecked){Qo.set(t,r);const o=n.getId(t);U(e)({...r,id:o})}}const g=("last"===l.input?["change"]:["input","change"]).map((e=>de(e,U(y),t))),v=t.defaultView;if(!v)return()=>{g.forEach((e=>e()))};const b=v.Object.getOwnPropertyDescriptor(v.HTMLInputElement.prototype,"value"),S=[[v.HTMLInputElement.prototype,"value"],[v.HTMLInputElement.prototype,"checked"],[v.HTMLSelectElement.prototype,"value"],[v.HTMLTextAreaElement.prototype,"value"],[v.HTMLSelectElement.prototype,"selectedIndex"],[v.HTMLOptionElement.prototype,"selected"]];return b&&b.set&&g.push(...S.map((e=>Pa(e[0],e[1],{set(){U(y)({target:this,isTrusted:!1})}},!1,v)))),U((()=>{g.forEach((e=>e()))}))}function Pn(e){return function(e,t){if(_n("CSSGroupingRule")&&e.parentRule instanceof CSSGroupingRule||_n("CSSMediaRule")&&e.parentRule instanceof CSSMediaRule||_n("CSSSupportsRule")&&e.parentRule instanceof CSSSupportsRule||_n("CSSConditionRule")&&e.parentRule instanceof CSSConditionRule){const n=Array.from(e.parentRule.cssRules).indexOf(e);t.unshift(n)}else if(e.parentStyleSheet){const n=Array.from(e.parentStyleSheet.cssRules).indexOf(e);t.unshift(n)}return t}(e,[])}function We(e,t,n){let r,o;return e?(e.ownerNode?r=t.getId(e.ownerNode):o=n.getId(e),{styleId:o,id:r}):{}}function Uh({styleSheetRuleCb:e,mirror:t,stylesheetManager:n},{win:r}){if(!r.CSSStyleSheet||!r.CSSStyleSheet.prototype)return()=>{};const o=r.CSSStyleSheet.prototype.insertRule;r.CSSStyleSheet.prototype.insertRule=new Proxy(o,{apply:U(((r,o,s)=>{const[i,a]=s,{id:c,styleId:u}=We(o,t,n.styleMirror);return(c&&-1!==c||u&&-1!==u)&&e({id:c,styleId:u,adds:[{rule:i,index:a}]}),r.apply(o,s)}))});const s=r.CSSStyleSheet.prototype.deleteRule;let i,a;r.CSSStyleSheet.prototype.deleteRule=new Proxy(s,{apply:U(((r,o,s)=>{const[i]=s,{id:a,styleId:c}=We(o,t,n.styleMirror);return(a&&-1!==a||c&&-1!==c)&&e({id:a,styleId:c,removes:[{index:i}]}),r.apply(o,s)}))}),r.CSSStyleSheet.prototype.replace&&(i=r.CSSStyleSheet.prototype.replace,r.CSSStyleSheet.prototype.replace=new Proxy(i,{apply:U(((r,o,s)=>{const[i]=s,{id:a,styleId:c}=We(o,t,n.styleMirror);return(a&&-1!==a||c&&-1!==c)&&e({id:a,styleId:c,replace:i}),r.apply(o,s)}))})),r.CSSStyleSheet.prototype.replaceSync&&(a=r.CSSStyleSheet.prototype.replaceSync,r.CSSStyleSheet.prototype.replaceSync=new Proxy(a,{apply:U(((r,o,s)=>{const[i]=s,{id:a,styleId:c}=We(o,t,n.styleMirror);return(a&&-1!==a||c&&-1!==c)&&e({id:a,styleId:c,replaceSync:i}),r.apply(o,s)}))}));const c={};gn("CSSGroupingRule")?c.CSSGroupingRule=r.CSSGroupingRule:(gn("CSSMediaRule")&&(c.CSSMediaRule=r.CSSMediaRule),gn("CSSConditionRule")&&(c.CSSConditionRule=r.CSSConditionRule),gn("CSSSupportsRule")&&(c.CSSSupportsRule=r.CSSSupportsRule));const u={};return Object.entries(c).forEach((([r,o])=>{u[r]={insertRule:o.prototype.insertRule,deleteRule:o.prototype.deleteRule},o.prototype.insertRule=new Proxy(u[r].insertRule,{apply:U(((r,o,s)=>{const[i,a]=s,{id:c,styleId:u}=We(o.parentStyleSheet,t,n.styleMirror);return(c&&-1!==c||u&&-1!==u)&&e({id:c,styleId:u,adds:[{rule:i,index:[...Pn(o),a||0]}]}),r.apply(o,s)}))}),o.prototype.deleteRule=new Proxy(u[r].deleteRule,{apply:U(((r,o,s)=>{const[i]=s,{id:a,styleId:c}=We(o.parentStyleSheet,t,n.styleMirror);return(a&&-1!==a||c&&-1!==c)&&e({id:a,styleId:c,removes:[{index:[...Pn(o),i]}]}),r.apply(o,s)}))})})),U((()=>{r.CSSStyleSheet.prototype.insertRule=o,r.CSSStyleSheet.prototype.deleteRule=s,i&&(r.CSSStyleSheet.prototype.replace=i),a&&(r.CSSStyleSheet.prototype.replaceSync=a),Object.entries(c).forEach((([e,t])=>{t.prototype.insertRule=u[e].insertRule,t.prototype.deleteRule=u[e].deleteRule}))}))}function Ka({mirror:e,stylesheetManager:t},n){let r=null;r="#document"===n.nodeName?e.getId(n):e.getId(n.host);const o="#document"===n.nodeName?ke([n,"access",e=>e.defaultView,"optionalAccess",e=>e.Document]):ke([n,"access",e=>e.ownerDocument,"optionalAccess",e=>e.defaultView,"optionalAccess",e=>e.ShadowRoot]),s=ke([o,"optionalAccess",e=>e.prototype])?Object.getOwnPropertyDescriptor(ke([o,"optionalAccess",e=>e.prototype]),"adoptedStyleSheets"):void 0;return null!==r&&-1!==r&&o&&s?(Object.defineProperty(n,"adoptedStyleSheets",{configurable:s.configurable,enumerable:s.enumerable,get(){return ke([s,"access",e=>e.get,"optionalAccess",e=>e.call,"call",e=>e(this)])},set(e){const n=ke([s,"access",e=>e.set,"optionalAccess",e=>e.call,"call",t=>t(this,e)]);if(null!==r&&-1!==r)try{t.adoptStyleSheets(e,r)}catch{}return n}}),U((()=>{Object.defineProperty(n,"adoptedStyleSheets",{configurable:s.configurable,enumerable:s.enumerable,get:s.get,set:s.set})}))):()=>{}}function jh({styleDeclarationCb:e,mirror:t,ignoreCSSAttributes:n,stylesheetManager:r},{win:o}){const s=o.CSSStyleDeclaration.prototype.setProperty;o.CSSStyleDeclaration.prototype.setProperty=new Proxy(s,{apply:U(((o,i,a)=>{const[c,u,l]=a;if(n.has(c))return s.apply(i,[c,u,l]);const{id:d,styleId:p}=We(ke([i,"access",e=>e.parentRule,"optionalAccess",e=>e.parentStyleSheet]),t,r.styleMirror);return(d&&-1!==d||p&&-1!==p)&&e({id:d,styleId:p,set:{property:c,value:u,priority:l},index:Pn(i.parentRule)}),o.apply(i,a)}))});const i=o.CSSStyleDeclaration.prototype.removeProperty;return o.CSSStyleDeclaration.prototype.removeProperty=new Proxy(i,{apply:U(((o,s,a)=>{const[c]=a;if(n.has(c))return i.apply(s,[c]);const{id:u,styleId:l}=We(ke([s,"access",e=>e.parentRule,"optionalAccess",e=>e.parentStyleSheet]),t,r.styleMirror);return(u&&-1!==u||l&&-1!==l)&&e({id:u,styleId:l,remove:{property:c},index:Pn(s.parentRule)}),o.apply(s,a)}))}),U((()=>{o.CSSStyleDeclaration.prototype.setProperty=s,o.CSSStyleDeclaration.prototype.removeProperty=i}))}function Bh({mediaInteractionCb:e,blockClass:t,blockSelector:n,unblockSelector:r,mirror:o,sampling:s,doc:i}){const a=U((i=>zt(U((s=>{const a=nn(s);if(!a||_e(a,t,n,r,!0))return;const{currentTime:c,volume:u,muted:l,playbackRate:d}=a;e({type:i,id:o.getId(a),currentTime:c,volume:u,muted:l,playbackRate:d})})),s.media||500))),c=[de("play",a(0),i),de("pause",a(1),i),de("seeked",a(2),i),de("volumechange",a(3),i),de("ratechange",a(4),i)];return U((()=>{c.forEach((e=>e()))}))}function $h({fontCb:e,doc:t}){const n=t.defaultView;if(!n)return()=>{};const r=[],o=new WeakMap,s=n.FontFace;n.FontFace=function(e,t,n){const r=new s(e,t,n);return o.set(r,{family:e,buffer:"string"!=typeof t,descriptors:n,fontSource:"string"==typeof t?t:JSON.stringify(Array.from(new Uint8Array(t)))}),r};const i=Ps(t.fonts,"add",(function(t){return function(n){return er(U((()=>{const t=o.get(n);t&&(e(t),o.delete(n))})),0),t.apply(this,[n])}}));return r.push((()=>{n.FontFace=s})),r.push(i),U((()=>{r.forEach((e=>e()))}))}function Hh(e){const{doc:t,mirror:n,blockClass:r,blockSelector:o,unblockSelector:s,selectionCb:i}=e;let a=!0;const c=U((()=>{const e=t.getSelection();if(!e||a&&ke([e,"optionalAccess",e=>e.isCollapsed]))return;a=e.isCollapsed||!1;const c=[],u=e.rangeCount||0;for(let t=0;t<u;t++){const i=e.getRangeAt(t),{startContainer:a,startOffset:u,endContainer:l,endOffset:d}=i;_e(a,r,o,s,!0)||_e(l,r,o,s,!0)||c.push({start:n.getId(a),startOffset:u,end:n.getId(l),endOffset:d})}i({ranges:c})}));return c(),de("selectionchange",c)}function zh({doc:e,customElementCb:t}){const n=e.defaultView;return n&&n.customElements?Ps(n.customElements,"define",(function(e){return function(n,r,o){try{t({define:{name:n}})}catch{}return e.apply(this,[n,r,o])}})):()=>{}}function Wh(e,t={}){const n=e.doc.defaultView;if(!n)return()=>{};let r;e.recordDOM&&(r=Ya(e,e.doc));const o=xh(e),s=Nh(e),i=qa(e),a=Ph(e,{win:n}),c=Fh(e),u=Bh(e);let l=()=>{},d=()=>{},p=()=>{},h=()=>{};e.recordDOM&&(l=Uh(e,{win:n}),d=Ka(e,e.doc),p=jh(e,{win:n}),e.collectFonts&&(h=$h(e)));const m=Hh(e),f=zh(e),y=[];for(const t of e.plugins)y.push(t.observer(t.callback,n,t.options));return U((()=>{yt.forEach((e=>e.reset())),ke([r,"optionalAccess",e=>e.disconnect,"call",e=>e()]),o(),s(),i(),a(),c(),u(),l(),d(),p(),h(),m(),f(),y.forEach((e=>e()))}))}function _n(e){return typeof window[e]<"u"}function gn(e){return!!(typeof window[e]<"u"&&window[e].prototype&&"insertRule"in window[e].prototype&&"deleteRule"in window[e].prototype)}class ns{constructor(e){this.generateIdFn=e,this.iframeIdToRemoteIdMap=new WeakMap,this.iframeRemoteIdToIdMap=new WeakMap}getId(e,t,n,r){const o=n||this.getIdToRemoteIdMap(e),s=r||this.getRemoteIdToIdMap(e);let i=o.get(t);return i||(i=this.generateIdFn(),o.set(t,i),s.set(i,t)),i}getIds(e,t){const n=this.getIdToRemoteIdMap(e),r=this.getRemoteIdToIdMap(e);return t.map((t=>this.getId(e,t,n,r)))}getRemoteId(e,t,n){const r=n||this.getRemoteIdToIdMap(e);if("number"!=typeof t)return t;return r.get(t)||-1}getRemoteIds(e,t){const n=this.getRemoteIdToIdMap(e);return t.map((t=>this.getRemoteId(e,t,n)))}reset(e){if(!e)return this.iframeIdToRemoteIdMap=new WeakMap,void(this.iframeRemoteIdToIdMap=new WeakMap);this.iframeIdToRemoteIdMap.delete(e),this.iframeRemoteIdToIdMap.delete(e)}getIdToRemoteIdMap(e){let t=this.iframeIdToRemoteIdMap.get(e);return t||(t=new Map,this.iframeIdToRemoteIdMap.set(e,t)),t}getRemoteIdToIdMap(e){let t=this.iframeRemoteIdToIdMap.get(e);return t||(t=new Map,this.iframeRemoteIdToIdMap.set(e,t)),t}}function Zo(e){let t,n=e[0],r=1;for(;r<e.length;){const o=e[r],s=e[r+1];if(r+=2,("optionalAccess"===o||"optionalCall"===o)&&null==n)return;"access"===o||"optionalAccess"===o?(t=n,n=s(n)):("call"===o||"optionalCall"===o)&&(n=s(((...e)=>n.call(t,...e))),t=void 0)}return n}class Gh{constructor(){this.crossOriginIframeMirror=new ns(Ns),this.crossOriginIframeRootIdMap=new WeakMap}addIframe(){}addLoadListener(){}attachIframe(){}}class Yh{constructor(e){this.iframes=new WeakMap,this.crossOriginIframeMap=new WeakMap,this.crossOriginIframeMirror=new ns(Ns),this.crossOriginIframeRootIdMap=new WeakMap,this.mutationCb=e.mutationCb,this.wrappedEmit=e.wrappedEmit,this.stylesheetManager=e.stylesheetManager,this.recordCrossOriginIframes=e.recordCrossOriginIframes,this.crossOriginIframeStyleMirror=new ns(this.stylesheetManager.styleMirror.generateId.bind(this.stylesheetManager.styleMirror)),this.mirror=e.mirror,this.recordCrossOriginIframes&&window.addEventListener("message",this.handleMessage.bind(this))}addIframe(e){this.iframes.set(e,!0),e.contentWindow&&this.crossOriginIframeMap.set(e.contentWindow,e)}addLoadListener(e){this.loadListener=e}attachIframe(e,t){this.mutationCb({adds:[{parentId:this.mirror.getId(e),nextId:null,node:t}],removes:[],texts:[],attributes:[],isAttachIframe:!0}),Zo([this,"access",e=>e.loadListener,"optionalCall",t=>t(e)]);const n=Fs(e);n&&n.adoptedStyleSheets&&n.adoptedStyleSheets.length>0&&this.stylesheetManager.adoptStyleSheets(n.adoptedStyleSheets,this.mirror.getId(n))}handleMessage(e){const t=e;if("rrweb"!==t.data.type||t.origin!==t.data.origin||!e.source)return;const n=this.crossOriginIframeMap.get(e.source);if(!n)return;const r=this.transformCrossOriginEvent(n,t.data.event);r&&this.wrappedEmit(r,t.data.isCheckout)}transformCrossOriginEvent(e,t){switch(t.type){case x.FullSnapshot:{this.crossOriginIframeMirror.reset(e),this.crossOriginIframeStyleMirror.reset(e),this.replaceIdOnNode(t.data.node,e);const n=t.data.node.id;return this.crossOriginIframeRootIdMap.set(e,n),this.patchRootIdOnNode(t.data.node,n),{timestamp:t.timestamp,type:x.IncrementalSnapshot,data:{source:A.Mutation,adds:[{parentId:this.mirror.getId(e),nextId:null,node:t.data.node}],removes:[],texts:[],attributes:[],isAttachIframe:!0}}}case x.Meta:case x.Load:case x.DomContentLoaded:return!1;case x.Plugin:return t;case x.Custom:return this.replaceIds(t.data.payload,e,["id","parentId","previousId","nextId"]),t;case x.IncrementalSnapshot:switch(t.data.source){case A.Mutation:return t.data.adds.forEach((t=>{this.replaceIds(t,e,["parentId","nextId","previousId"]),this.replaceIdOnNode(t.node,e);const n=this.crossOriginIframeRootIdMap.get(e);n&&this.patchRootIdOnNode(t.node,n)})),t.data.removes.forEach((t=>{this.replaceIds(t,e,["parentId","id"])})),t.data.attributes.forEach((t=>{this.replaceIds(t,e,["id"])})),t.data.texts.forEach((t=>{this.replaceIds(t,e,["id"])})),t;case A.Drag:case A.TouchMove:case A.MouseMove:return t.data.positions.forEach((t=>{this.replaceIds(t,e,["id"])})),t;case A.ViewportResize:return!1;case A.MediaInteraction:case A.MouseInteraction:case A.Scroll:case A.CanvasMutation:case A.Input:return this.replaceIds(t.data,e,["id"]),t;case A.StyleSheetRule:case A.StyleDeclaration:return this.replaceIds(t.data,e,["id"]),this.replaceStyleIds(t.data,e,["styleId"]),t;case A.Font:return t;case A.Selection:return t.data.ranges.forEach((t=>{this.replaceIds(t,e,["start","end"])})),t;case A.AdoptedStyleSheet:return this.replaceIds(t.data,e,["id"]),this.replaceStyleIds(t.data,e,["styleIds"]),Zo([t,"access",e=>e.data,"access",e=>e.styles,"optionalAccess",e=>e.forEach,"call",t=>t((t=>{this.replaceStyleIds(t,e,["styleId"])}))]),t}}return!1}replace(e,t,n,r){for(const o of r)!Array.isArray(t[o])&&"number"!=typeof t[o]||(Array.isArray(t[o])?t[o]=e.getIds(n,t[o]):t[o]=e.getId(n,t[o]));return t}replaceIds(e,t,n){return this.replace(this.crossOriginIframeMirror,e,t,n)}replaceStyleIds(e,t,n){return this.replace(this.crossOriginIframeStyleMirror,e,t,n)}replaceIdOnNode(e,t){this.replaceIds(e,t,["id","rootId"]),"childNodes"in e&&e.childNodes.forEach((e=>{this.replaceIdOnNode(e,t)}))}patchRootIdOnNode(e,t){e.type!==ce.Document&&!e.rootId&&(e.rootId=t),"childNodes"in e&&e.childNodes.forEach((e=>{this.patchRootIdOnNode(e,t)}))}}class qh{init(){}addShadowRoot(){}observeAttachShadow(){}reset(){}}class Kh{constructor(e){this.shadowDoms=new WeakSet,this.restoreHandlers=[],this.mutationCb=e.mutationCb,this.scrollCb=e.scrollCb,this.bypassOptions=e.bypassOptions,this.mirror=e.mirror,this.init()}init(){this.reset(),this.patchAttachShadow(Element,document)}addShadowRoot(e,t){if(!Ft(e)||this.shadowDoms.has(e))return;this.shadowDoms.add(e),this.bypassOptions.canvasManager.addShadowRoot(e);const n=Ya({...this.bypassOptions,doc:t,mutationCb:this.mutationCb,mirror:this.mirror,shadowDomManager:this},e);this.restoreHandlers.push((()=>n.disconnect())),this.restoreHandlers.push(qa({...this.bypassOptions,scrollCb:this.scrollCb,doc:e,mirror:this.mirror})),er((()=>{e.adoptedStyleSheets&&e.adoptedStyleSheets.length>0&&this.bypassOptions.stylesheetManager.adoptStyleSheets(e.adoptedStyleSheets,this.mirror.getId(e.host)),this.restoreHandlers.push(Ka({mirror:this.mirror,stylesheetManager:this.bypassOptions.stylesheetManager},e))}),0)}observeAttachShadow(e){const t=Fs(e),n=kh(e);!t||!n||this.patchAttachShadow(n.Element,t)}patchAttachShadow(e,t){const n=this;this.restoreHandlers.push(Ps(e.prototype,"attachShadow",(function(e){return function(r){const o=e.call(this,r);return this.shadowRoot&&Wa(this)&&n.addShadowRoot(this.shadowRoot,t),o}})))}reset(){this.restoreHandlers.forEach((e=>{try{e()}catch{}})),this.restoreHandlers=[],this.shadowDoms=new WeakSet,this.bypassOptions.canvasManager.resetShadowRoots()}}class ei{reset(){}freeze(){}unfreeze(){}lock(){}unlock(){}snapshot(){}addWindow(){}addShadowRoot(){}resetShadowRoots(){}}class Vh{constructor(e){this.trackedLinkElements=new WeakSet,this.styleMirror=new bh,this.mutationCb=e.mutationCb,this.adoptedStyleSheetCb=e.adoptedStyleSheetCb}attachLinkElement(e,t){"_cssText"in t.attributes&&this.mutationCb({adds:[],removes:[],texts:[],attributes:[{id:t.id,attributes:t.attributes}]}),this.trackLinkElement(e)}trackLinkElement(e){this.trackedLinkElements.has(e)||(this.trackedLinkElements.add(e),this.trackStylesheetInLinkElement(e))}adoptStyleSheets(e,t){if(0===e.length)return;const n={id:t,styleIds:[]},r=[];for(const t of e){let e;this.styleMirror.has(t)?e=this.styleMirror.getId(t):(e=this.styleMirror.add(t),r.push({styleId:e,rules:Array.from(t.rules||CSSRule,((e,t)=>({rule:Ra(e),index:t})))})),n.styleIds.push(e)}r.length>0&&(n.styles=r),this.adoptedStyleSheetCb(n)}reset(){this.styleMirror.reset(),this.trackedLinkElements=new WeakSet}trackStylesheetInLinkElement(e){}}class Jh{constructor(){this.nodeMap=new WeakMap,this.active=!1}inOtherBuffer(e,t){const n=this.nodeMap.get(e);return n&&Array.from(n).some((e=>e!==t))}add(e,t){this.active||(this.active=!0,wh((()=>{this.nodeMap=new WeakMap,this.active=!1}))),this.nodeMap.set(e,(this.nodeMap.get(e)||new Set).add(t))}destroy(){}}let ae,Ln;try{if(2!==Array.from([1],(e=>2*e))[0]){const e=document.createElement("iframe");document.body.appendChild(e),Array.from=In([e,"access",e=>e.contentWindow,"optionalAccess",e=>e.Array,"access",e=>e.from])||Array.from,document.body.removeChild(e)}}catch(e){console.debug("Unable to override Array.from",e)}const we=Vp();function Ue(e={}){const{emit:t,checkoutEveryNms:n,checkoutEveryNth:r,blockClass:o="rr-block",blockSelector:s=null,unblockSelector:i=null,ignoreClass:a="rr-ignore",ignoreSelector:c=null,maskAllText:u=!1,maskTextClass:l="rr-mask",unmaskTextClass:d=null,maskTextSelector:p=null,unmaskTextSelector:h=null,inlineStylesheet:m=!0,maskAllInputs:f,maskInputOptions:y,slimDOMOptions:_,maskAttributeFn:g,maskInputFn:v,maskTextFn:b,maxCanvasSize:S=null,packFn:E,sampling:k={},dataURLOptions:w={},mousemoveWait:T,recordDOM:I=!0,recordCanvas:C=!1,recordCrossOriginIframes:M=!1,recordAfter:O=("DOMContentLoaded"===e.recordAfter?e.recordAfter:"load"),userTriggeredOnInput:R=!1,collectFonts:D=!1,inlineImages:N=!1,plugins:P,keepIframeSrcFn:L=()=>!1,ignoreCSSAttributes:j=new Set([]),errorHandler:F,onMutation:$,getCanvasManager:B}=e;Dh(F);const z=!M||window.parent===window;let H=!1;if(!z)try{window.parent.document&&(H=!1)}catch{H=!0}if(z&&!t)throw new Error("emit function is required");if(!z&&!H)return()=>{};void 0!==T&&void 0===k.mousemove&&(k.mousemove=T),we.reset();const W=!0===f?{color:!0,date:!0,"datetime-local":!0,email:!0,month:!0,number:!0,range:!0,search:!0,tel:!0,text:!0,time:!0,url:!0,week:!0,textarea:!0,select:!0,radio:!0,checkbox:!0}:void 0!==y?y:{},V=!0===_||"all"===_?{script:!0,comment:!0,headFavicon:!0,headWhitespace:!0,headMetaSocial:!0,headMetaRobots:!0,headMetaHttpEquiv:!0,headMetaVerification:!0,headMetaAuthorship:"all"===_,headMetaDescKeywords:"all"===_}:_||{};Sh();let J,Y=0;const G=e=>{for(const t of P||[])t.eventProcessor&&(e=t.eventProcessor(e));return E&&!H&&(e=E(e)),e};ae=(e,o)=>{const s=e;if(s.timestamp=Nn(),In([yt,"access",e=>e[0],"optionalAccess",e=>e.isFrozen,"call",e=>e()])&&s.type!==x.FullSnapshot&&!(s.type===x.IncrementalSnapshot&&s.data.source===A.Mutation)&&yt.forEach((e=>e.unfreeze())),z)In([t,"optionalCall",e=>e(G(s),o)]);else if(H){const e={type:"rrweb",event:G(s),origin:window.location.origin,isCheckout:o};window.parent.postMessage(e,"*")}if(s.type===x.FullSnapshot)J=s,Y=0;else if(s.type===x.IncrementalSnapshot){if(s.data.source===A.Mutation&&s.data.isAttachIframe)return;Y++;const e=r&&Y>=r,t=n&&J&&s.timestamp-J.timestamp>n;(e||t)&&re(!0)}};const K=e=>{ae({type:x.IncrementalSnapshot,data:{source:A.Mutation,...e}})},q=e=>ae({type:x.IncrementalSnapshot,data:{source:A.Scroll,...e}}),X=e=>ae({type:x.IncrementalSnapshot,data:{source:A.CanvasMutation,...e}}),Z=new Vh({mutationCb:K,adoptedStyleSheetCb:e=>ae({type:x.IncrementalSnapshot,data:{source:A.AdoptedStyleSheet,...e}})}),Q="boolean"==typeof __RRWEB_EXCLUDE_IFRAME__&&__RRWEB_EXCLUDE_IFRAME__?new Gh:new Yh({mirror:we,mutationCb:K,stylesheetManager:Z,recordCrossOriginIframes:M,wrappedEmit:ae});for(const e of P||[])e.getMirror&&e.getMirror({nodeMirror:we,crossOriginIframeMirror:Q.crossOriginIframeMirror,crossOriginIframeStyleMirror:Q.crossOriginIframeStyleMirror});const ee=new Jh,te=Qh(B,{mirror:we,win:window,mutationCb:e=>ae({type:x.IncrementalSnapshot,data:{source:A.CanvasMutation,...e}}),recordCanvas:C,blockClass:o,blockSelector:s,unblockSelector:i,maxCanvasSize:S,sampling:k.canvas,dataURLOptions:w,errorHandler:F}),ne="boolean"==typeof __RRWEB_EXCLUDE_SHADOW_DOM__&&__RRWEB_EXCLUDE_SHADOW_DOM__?new qh:new Kh({mutationCb:K,scrollCb:q,bypassOptions:{onMutation:$,blockClass:o,blockSelector:s,unblockSelector:i,maskAllText:u,maskTextClass:l,unmaskTextClass:d,maskTextSelector:p,unmaskTextSelector:h,inlineStylesheet:m,maskInputOptions:W,dataURLOptions:w,maskAttributeFn:g,maskTextFn:b,maskInputFn:v,recordCanvas:C,inlineImages:N,sampling:k,slimDOMOptions:V,iframeManager:Q,stylesheetManager:Z,canvasManager:te,keepIframeSrcFn:L,processedNodeManager:ee},mirror:we}),re=(e=!1)=>{if(!I)return;ae({type:x.Meta,data:{href:window.location.href,width:Ua(),height:Fa()}},e),Z.reset(),ne.init(),yt.forEach((e=>e.lock()));const t=yh(document,{mirror:we,blockClass:o,blockSelector:s,unblockSelector:i,maskAllText:u,maskTextClass:l,unmaskTextClass:d,maskTextSelector:p,unmaskTextSelector:h,inlineStylesheet:m,maskAllInputs:W,maskAttributeFn:g,maskInputFn:v,maskTextFn:b,slimDOM:V,dataURLOptions:w,recordCanvas:C,inlineImages:N,onSerialize:e=>{$a(e,we)&&Q.addIframe(e),Ha(e,we)&&Z.trackLinkElement(e),es(e)&&ne.addShadowRoot(e.shadowRoot,document)},onIframeLoad:(e,t)=>{Q.attachIframe(e,t),e.contentWindow&&te.addWindow(e.contentWindow),ne.observeAttachShadow(e)},onStylesheetLoad:(e,t)=>{Z.attachLinkElement(e,t)},keepIframeSrcFn:L});if(!t)return console.warn("Failed to snapshot the document");ae({type:x.FullSnapshot,data:{node:t,initialOffset:La(window)}}),yt.forEach((e=>e.unlock())),document.adoptedStyleSheets&&document.adoptedStyleSheets.length>0&&Z.adoptStyleSheets(document.adoptedStyleSheets,we.getId(document))};Ln=re;try{const e=[],t=e=>U(Wh)({onMutation:$,mutationCb:K,mousemoveCb:(e,t)=>ae({type:x.IncrementalSnapshot,data:{source:t,positions:e}}),mouseInteractionCb:e=>ae({type:x.IncrementalSnapshot,data:{source:A.MouseInteraction,...e}}),scrollCb:q,viewportResizeCb:e=>ae({type:x.IncrementalSnapshot,data:{source:A.ViewportResize,...e}}),inputCb:e=>ae({type:x.IncrementalSnapshot,data:{source:A.Input,...e}}),mediaInteractionCb:e=>ae({type:x.IncrementalSnapshot,data:{source:A.MediaInteraction,...e}}),styleSheetRuleCb:e=>ae({type:x.IncrementalSnapshot,data:{source:A.StyleSheetRule,...e}}),styleDeclarationCb:e=>ae({type:x.IncrementalSnapshot,data:{source:A.StyleDeclaration,...e}}),canvasMutationCb:X,fontCb:e=>ae({type:x.IncrementalSnapshot,data:{source:A.Font,...e}}),selectionCb:e=>{ae({type:x.IncrementalSnapshot,data:{source:A.Selection,...e}})},customElementCb:e=>{ae({type:x.IncrementalSnapshot,data:{source:A.CustomElement,...e}})},blockClass:o,ignoreClass:a,ignoreSelector:c,maskAllText:u,maskTextClass:l,unmaskTextClass:d,maskTextSelector:p,unmaskTextSelector:h,maskInputOptions:W,inlineStylesheet:m,sampling:k,recordDOM:I,recordCanvas:C,inlineImages:N,userTriggeredOnInput:R,collectFonts:D,doc:e,maskAttributeFn:g,maskInputFn:v,maskTextFn:b,keepIframeSrcFn:L,blockSelector:s,unblockSelector:i,slimDOMOptions:V,dataURLOptions:w,mirror:we,iframeManager:Q,stylesheetManager:Z,shadowDomManager:ne,processedNodeManager:ee,canvasManager:te,ignoreCSSAttributes:j,plugins:In([P,"optionalAccess",e=>e.filter,"call",e=>e((e=>e.observer)),"optionalAccess",e=>e.map,"call",e=>e((e=>({observer:e.observer,options:e.options,callback:t=>ae({type:x.Plugin,data:{plugin:e.name,payload:t}})})))])||[]},{});Q.addLoadListener((n=>{try{e.push(t(n.contentDocument))}catch(e){console.warn(e)}}));const n=()=>{re(),e.push(t(document))};return"interactive"===document.readyState||"complete"===document.readyState?n():(e.push(de("DOMContentLoaded",(()=>{ae({type:x.DomContentLoaded,data:{}}),"DOMContentLoaded"===O&&n()}))),e.push(de("load",(()=>{ae({type:x.Load,data:{}}),"load"===O&&n()}),window))),()=>{e.forEach((e=>e())),ee.destroy(),Ln=void 0,Ah()}}catch(e){console.warn(e)}}function Xh(e){if(!Ln)throw new Error("please take full snapshot after start recording");Ln(e)}function Qh(e,t){try{return e?e(t):new ei}catch{return console.warn("Unable to initialize CanvasManager"),new ei}}Ue.mirror=we,Ue.takeFullSnapshot=Xh;const Zh=3,em=5;function Us(e){return e>9999999999?e:1e3*e}function vr(e){return e>9999999999?e/1e3:e}function rn(e,t){"sentry.transaction"!==t.category&&(["ui.click","ui.input"].includes(t.category)?e.triggerUserActivity():e.checkAndHandleExpiredSession(),e.addUpdate((()=>(e.throttledAddEvent({type:x.Custom,timestamp:1e3*(t.timestamp||0),data:{tag:"breadcrumb",payload:Te(t,10,1e3)}}),"console"===t.category))))}const tm="button,a";function Va(e){return e.closest(tm)||e}function Ja(e){const t=Xa(e);return t&&t instanceof Element?Va(t):t}function Xa(e){return nm(e)?e.target:e}function nm(e){return"object"==typeof e&&!!e&&"target"in e}let Ge;function rm(e){return Ge||(Ge=[],sm()),Ge.push(e),()=>{const t=Ge?Ge.indexOf(e):-1;t>-1&&Ge.splice(t,1)}}function sm(){pe(ee,"open",(function(e){return function(...t){if(Ge)try{Ge.forEach((e=>e()))}catch{}return e.apply(ee,t)}}))}const om=new Set([A.Mutation,A.StyleSheetRule,A.StyleDeclaration,A.AdoptedStyleSheet,A.CanvasMutation,A.Selection,A.MediaInteraction]);function im(e,t,n){e.handleClick(t,n)}class am{constructor(e,t,n=rn){this._lastMutation=0,this._lastScroll=0,this._clicks=[],this._timeout=t.timeout/1e3,this._threshold=t.threshold/1e3,this._scrollTimeout=t.scrollTimeout/1e3,this._replay=e,this._ignoreSelector=t.ignoreSelector,this._addBreadcrumbEvent=n}addListeners(){const e=rm((()=>{this._lastMutation=ti()}));this._teardown=()=>{e(),this._clicks=[],this._lastMutation=0,this._lastScroll=0}}removeListeners(){this._teardown&&this._teardown(),this._checkClickTimeout&&clearTimeout(this._checkClickTimeout)}handleClick(e,t){if(um(t,this._ignoreSelector)||!lm(e))return;const n={timestamp:vr(e.timestamp),clickBreadcrumb:e,clickCount:0,node:t};this._clicks.some((e=>e.node===n.node&&Math.abs(e.timestamp-n.timestamp)<1))||(this._clicks.push(n),1===this._clicks.length&&this._scheduleCheckClicks())}registerMutation(e=Date.now()){this._lastMutation=vr(e)}registerScroll(e=Date.now()){this._lastScroll=vr(e)}registerClick(e){const t=Va(e);this._handleMultiClick(t)}_handleMultiClick(e){this._getClicks(e).forEach((e=>{e.clickCount++}))}_getClicks(e){return this._clicks.filter((t=>t.node===e))}_checkClicks(){const e=[],t=ti();this._clicks.forEach((n=>{!n.mutationAfter&&this._lastMutation&&(n.mutationAfter=n.timestamp<=this._lastMutation?this._lastMutation-n.timestamp:void 0),!n.scrollAfter&&this._lastScroll&&(n.scrollAfter=n.timestamp<=this._lastScroll?this._lastScroll-n.timestamp:void 0),n.timestamp+this._timeout<=t&&e.push(n)}));for(const t of e){const e=this._clicks.indexOf(t);e>-1&&(this._generateBreadcrumbs(t),this._clicks.splice(e,1))}this._clicks.length&&this._scheduleCheckClicks()}_generateBreadcrumbs(e){const t=this._replay,n=e.scrollAfter&&e.scrollAfter<=this._scrollTimeout,r=e.mutationAfter&&e.mutationAfter<=this._threshold,o=!n&&!r,{clickCount:s,clickBreadcrumb:i}=e;if(o){const n=1e3*Math.min(e.mutationAfter||this._timeout,this._timeout),r=n<1e3*this._timeout?"mutation":"timeout",o={type:"default",message:i.message,timestamp:i.timestamp,category:"ui.slowClickDetected",data:{...i.data,url:ee.location.href,route:t.getCurrentRoute(),timeAfterClickMs:n,endReason:r,clickCount:s||1}};this._addBreadcrumbEvent(t,o)}else if(s>1){const e={type:"default",message:i.message,timestamp:i.timestamp,category:"ui.multiClick",data:{...i.data,url:ee.location.href,route:t.getCurrentRoute(),clickCount:s,metric:!0}};this._addBreadcrumbEvent(t,e)}}_scheduleCheckClicks(){this._checkClickTimeout&&clearTimeout(this._checkClickTimeout),this._checkClickTimeout=Tt((()=>this._checkClicks()),1e3)}}const cm=["A","BUTTON","INPUT"];function um(e,t){return!!(!cm.includes(e.tagName)||"INPUT"===e.tagName&&!["submit","button"].includes(e.getAttribute("type")||"")||"A"===e.tagName&&(e.hasAttribute("download")||e.hasAttribute("target")&&"_self"!==e.getAttribute("target"))||t&&e.matches(t))}function lm(e){return!(!e.data||"number"!=typeof e.data.nodeId||!e.timestamp)}function ti(){return Date.now()/1e3}function dm(e,t){try{if(!fm(t))return;const{source:n}=t.data;if(om.has(n)&&e.registerMutation(t.timestamp),n===A.Scroll&&e.registerScroll(t.timestamp),pm(t)){const{type:n,id:r}=t.data,o=Ue.mirror.getNode(r);o instanceof HTMLElement&&n===le.Click&&e.registerClick(o)}}catch{}}function fm(e){return 3===e.type}function pm(e){return e.data.source===A.MouseInteraction}function Oe(e){return{timestamp:Date.now()/1e3,type:"default",...e}}var Fn;!function(e){e[e.Document=0]="Document",e[e.DocumentType=1]="DocumentType",e[e.Element=2]="Element",e[e.Text=3]="Text",e[e.CDATA=4]="CDATA",e[e.Comment=5]="Comment"}(Fn||(Fn={}));const hm=new Set(["id","class","aria-label","role","name","alt","title","data-test-id","data-testid","disabled","aria-disabled","data-sentry-component"]);function mm(e){const t={};!e["data-sentry-component"]&&e["data-sentry-element"]&&(e["data-sentry-component"]=e["data-sentry-element"]);for(const n in e)if(hm.has(n)){let r=n;("data-testid"===n||"data-test-id"===n)&&(r="testId"),t[r]=e[n]}return t}const _m=e=>t=>{if(!e.isEnabled())return;const n=gm(t);if(!n)return;const r="click"===t.name,o=r?t.event:void 0;r&&e.clickDetector&&o&&o.target&&!o.altKey&&!o.metaKey&&!o.ctrlKey&&!o.shiftKey&&im(e.clickDetector,n,Ja(t.event)),rn(e,n)};function Qa(e,t){const n=Ue.mirror.getId(e),r=n&&Ue.mirror.getNode(n),o=r&&Ue.mirror.getMeta(r),s=o&&Em(o)?o:null;return{message:t,data:s?{nodeId:n,node:{id:n,tagName:s.tagName,textContent:Array.from(s.childNodes).map((e=>e.type===Fn.Text&&e.textContent)).filter(Boolean).map((e=>e.trim())).join(""),attributes:mm(s.attributes)}}:{}}}function gm(e){const{target:t,message:n}=ym(e);return Oe({category:`ui.${e.name}`,...Qa(t,n)})}function ym(e){const t="click"===e.name;let n,r=null;try{r=t?Ja(e.event):Xa(e.event),n=Gn(r,{maxStringLength:200})||"<unknown>"}catch{n="<unknown>"}return{target:r,message:n}}function Em(e){return e.type===Fn.Element}function Sm(e,t){if(!e.isEnabled())return;e.updateUserActivity();const n=bm(t);n&&rn(e,n)}function bm(e){const{metaKey:t,shiftKey:n,ctrlKey:r,altKey:o,key:s,target:i}=e;if(!i||vm(i)||!s)return null;const a=t||r||o,c=1===s.length;if(!a&&c)return null;const u=Gn(i,{maxStringLength:200})||"<unknown>";return Oe({category:"ui.keyDown",message:u,data:{...Qa(i,u).data,metaKey:t,shiftKey:n,ctrlKey:r,altKey:o,key:s}})}function vm(e){return"INPUT"===e.tagName||"TEXTAREA"===e.tagName||e.isContentEditable}const Im={resource:Cm,paint:km,navigation:Rm};function yn(e,t){return({metric:n})=>{t.replayPerformanceEntries.push(e(n))}}function wm(e){return e.map(Tm).filter(Boolean)}function Tm(e){const t=Im[e.entryType];return t?t(e):null}function Ct(e){return((ou||ee.performance.timeOrigin)+e)/1e3}function km(e){const{duration:t,entryType:n,name:r,startTime:o}=e,s=Ct(o);return{type:n,name:r,start:s,end:s+t,data:void 0}}function Rm(e){const{entryType:t,name:n,decodedBodySize:r,duration:o,domComplete:s,encodedBodySize:i,domContentLoadedEventStart:a,domContentLoadedEventEnd:c,domInteractive:u,loadEventStart:l,loadEventEnd:d,redirectCount:p,startTime:h,transferSize:m,type:f}=e;return 0===o?null:{type:`${t}.${f}`,start:Ct(h),end:Ct(s),name:n,data:{size:m,decodedBodySize:r,encodedBodySize:i,duration:o,domInteractive:u,domContentLoadedEventStart:a,domContentLoadedEventEnd:c,loadEventStart:l,loadEventEnd:d,domComplete:s,redirectCount:p}}}function Cm(e){const{entryType:t,initiatorType:n,name:r,responseEnd:o,startTime:s,decodedBodySize:i,encodedBodySize:a,responseStatus:c,transferSize:u}=e;return["fetch","xmlhttprequest"].includes(n)?null:{type:`${t}.${n}`,start:Ct(s),end:Ct(o),name:r,data:{size:u,statusCode:c,decodedBodySize:i,encodedBodySize:a}}}function Mm(e){const t=e.entries[e.entries.length-1];return tr(e,"largest-contentful-paint",t&&t.element?[t.element]:void 0)}function Om(e){return void 0!==e.sources}function Dm(e){const t=[],n=[];for(const r of e.entries)if(Om(r)){const e=[];for(const t of r.sources)if(t.node){n.push(t.node);const r=Ue.mirror.getId(t.node);r&&e.push(r)}t.push({value:r.value,nodeIds:e.length?e:void 0})}return tr(e,"cumulative-layout-shift",n,t)}function Am(e){const t=e.entries[e.entries.length-1];return tr(e,"first-input-delay",t&&t.target?[t.target]:void 0)}function xm(e){const t=e.entries[e.entries.length-1];return tr(e,"interaction-to-next-paint",t&&t.target?[t.target]:void 0)}function tr(e,t,n,r){const o=e.value,s=e.rating,i=Ct(o);return{type:"web-vital",name:t,start:i,end:i,data:{value:o,size:o,rating:s,nodeIds:n?n.map((e=>Ue.mirror.getId(e))):void 0,attributions:r}}}function Nm(e){function t(t){e.performanceEntries.includes(t)||e.performanceEntries.push(t)}function n({entries:e}){e.forEach(t)}const r=[];return["navigation","paint","resource"].forEach((e=>{r.push(Ef(e,n))})),r.push(_f(yn(Mm,e)),mf(yn(Dm,e)),gf(yn(Am,e)),yf(yn(xm,e))),()=>{r.forEach((e=>e()))}}const M=typeof __SENTRY_DEBUG__>"u"||__SENTRY_DEBUG__,Pm='var t=Uint8Array,n=Uint16Array,r=Int32Array,e=new t([0,0,0,0,0,0,0,0,1,1,1,1,2,2,2,2,3,3,3,3,4,4,4,4,5,5,5,5,0,0,0,0]),i=new t([0,0,0,0,1,1,2,2,3,3,4,4,5,5,6,6,7,7,8,8,9,9,10,10,11,11,12,12,13,13,0,0]),a=new t([16,17,18,0,8,7,9,6,10,5,11,4,12,3,13,2,14,1,15]),s=function(t,e){for(var i=new n(31),a=0;a<31;++a)i[a]=e+=1<<t[a-1];var s=new r(i[30]);for(a=1;a<30;++a)for(var o=i[a];o<i[a+1];++o)s[o]=o-i[a]<<5|a;return{b:i,r:s}},o=s(e,2),f=o.b,h=o.r;f[28]=258,h[258]=28;for(var l=s(i,0).r,u=new n(32768),c=0;c<32768;++c){var v=(43690&c)>>1|(21845&c)<<1;v=(61680&(v=(52428&v)>>2|(13107&v)<<2))>>4|(3855&v)<<4,u[c]=((65280&v)>>8|(255&v)<<8)>>1}var d=function(t,r,e){for(var i=t.length,a=0,s=new n(r);a<i;++a)t[a]&&++s[t[a]-1];var o,f=new n(r);for(a=1;a<r;++a)f[a]=f[a-1]+s[a-1]<<1;if(e){o=new n(1<<r);var h=15-r;for(a=0;a<i;++a)if(t[a])for(var l=a<<4|t[a],c=r-t[a],v=f[t[a]-1]++<<c,d=v|(1<<c)-1;v<=d;++v)o[u[v]>>h]=l}else for(o=new n(i),a=0;a<i;++a)t[a]&&(o[a]=u[f[t[a]-1]++]>>15-t[a]);return o},g=new t(288);for(c=0;c<144;++c)g[c]=8;for(c=144;c<256;++c)g[c]=9;for(c=256;c<280;++c)g[c]=7;for(c=280;c<288;++c)g[c]=8;var w=new t(32);for(c=0;c<32;++c)w[c]=5;var p=d(g,9,0),y=d(w,5,0),m=function(t){return(t+7)/8|0},b=function(n,r,e){return(null==e||e>n.length)&&(e=n.length),new t(n.subarray(r,e))},M=["unexpected EOF","invalid block type","invalid length/literal","invalid distance","stream finished","no stream handler",,"no callback","invalid UTF-8 data","extra field too long","date not in range 1980-2099","filename too long","stream finishing","invalid zip data"],E=function(t,n,r){var e=new Error(n||M[t]);if(e.code=t,Error.captureStackTrace&&Error.captureStackTrace(e,E),!r)throw e;return e},z=function(t,n,r){r<<=7&n;var e=n/8|0;t[e]|=r,t[e+1]|=r>>8},_=function(t,n,r){r<<=7&n;var e=n/8|0;t[e]|=r,t[e+1]|=r>>8,t[e+2]|=r>>16},x=function(r,e){for(var i=[],a=0;a<r.length;++a)r[a]&&i.push({s:a,f:r[a]});var s=i.length,o=i.slice();if(!s)return{t:F,l:0};if(1==s){var f=new t(i[0].s+1);return f[i[0].s]=1,{t:f,l:1}}i.sort((function(t,n){return t.f-n.f})),i.push({s:-1,f:25001});var h=i[0],l=i[1],u=0,c=1,v=2;for(i[0]={s:-1,f:h.f+l.f,l:h,r:l};c!=s-1;)h=i[i[u].f<i[v].f?u++:v++],l=i[u!=c&&i[u].f<i[v].f?u++:v++],i[c++]={s:-1,f:h.f+l.f,l:h,r:l};var d=o[0].s;for(a=1;a<s;++a)o[a].s>d&&(d=o[a].s);var g=new n(d+1),w=A(i[c-1],g,0);if(w>e){a=0;var p=0,y=w-e,m=1<<y;for(o.sort((function(t,n){return g[n.s]-g[t.s]||t.f-n.f}));a<s;++a){var b=o[a].s;if(!(g[b]>e))break;p+=m-(1<<w-g[b]),g[b]=e}for(p>>=y;p>0;){var M=o[a].s;g[M]<e?p-=1<<e-g[M]++-1:++a}for(;a>=0&&p;--a){var E=o[a].s;g[E]==e&&(--g[E],++p)}w=e}return{t:new t(g),l:w}},A=function(t,n,r){return-1==t.s?Math.max(A(t.l,n,r+1),A(t.r,n,r+1)):n[t.s]=r},D=function(t){for(var r=t.length;r&&!t[--r];);for(var e=new n(++r),i=0,a=t[0],s=1,o=function(t){e[i++]=t},f=1;f<=r;++f)if(t[f]==a&&f!=r)++s;else{if(!a&&s>2){for(;s>138;s-=138)o(32754);s>2&&(o(s>10?s-11<<5|28690:s-3<<5|12305),s=0)}else if(s>3){for(o(a),--s;s>6;s-=6)o(8304);s>2&&(o(s-3<<5|8208),s=0)}for(;s--;)o(a);s=1,a=t[f]}return{c:e.subarray(0,i),n:r}},T=function(t,n){for(var r=0,e=0;e<n.length;++e)r+=t[e]*n[e];return r},k=function(t,n,r){var e=r.length,i=m(n+2);t[i]=255&e,t[i+1]=e>>8,t[i+2]=255^t[i],t[i+3]=255^t[i+1];for(var a=0;a<e;++a)t[i+a+4]=r[a];return 8*(i+4+e)},U=function(t,r,s,o,f,h,l,u,c,v,m){z(r,m++,s),++f[256];for(var b=x(f,15),M=b.t,E=b.l,A=x(h,15),U=A.t,C=A.l,F=D(M),I=F.c,S=F.n,L=D(U),O=L.c,j=L.n,q=new n(19),B=0;B<I.length;++B)++q[31&I[B]];for(B=0;B<O.length;++B)++q[31&O[B]];for(var G=x(q,7),H=G.t,J=G.l,K=19;K>4&&!H[a[K-1]];--K);var N,P,Q,R,V=v+5<<3,W=T(f,g)+T(h,w)+l,X=T(f,M)+T(h,U)+l+14+3*K+T(q,H)+2*q[16]+3*q[17]+7*q[18];if(c>=0&&V<=W&&V<=X)return k(r,m,t.subarray(c,c+v));if(z(r,m,1+(X<W)),m+=2,X<W){N=d(M,E,0),P=M,Q=d(U,C,0),R=U;var Y=d(H,J,0);z(r,m,S-257),z(r,m+5,j-1),z(r,m+10,K-4),m+=14;for(B=0;B<K;++B)z(r,m+3*B,H[a[B]]);m+=3*K;for(var Z=[I,O],$=0;$<2;++$){var tt=Z[$];for(B=0;B<tt.length;++B){var nt=31&tt[B];z(r,m,Y[nt]),m+=H[nt],nt>15&&(z(r,m,tt[B]>>5&127),m+=tt[B]>>12)}}}else N=p,P=g,Q=y,R=w;for(B=0;B<u;++B){var rt=o[B];if(rt>255){_(r,m,N[(nt=rt>>18&31)+257]),m+=P[nt+257],nt>7&&(z(r,m,rt>>23&31),m+=e[nt]);var et=31&rt;_(r,m,Q[et]),m+=R[et],et>3&&(_(r,m,rt>>5&8191),m+=i[et])}else _(r,m,N[rt]),m+=P[rt]}return _(r,m,N[256]),m+P[256]},C=new r([65540,131080,131088,131104,262176,1048704,1048832,2114560,2117632]),F=new t(0),I=function(){for(var t=new Int32Array(256),n=0;n<256;++n){for(var r=n,e=9;--e;)r=(1&r&&-306674912)^r>>>1;t[n]=r}return t}(),S=function(){var t=-1;return{p:function(n){for(var r=t,e=0;e<n.length;++e)r=I[255&r^n[e]]^r>>>8;t=r},d:function(){return~t}}},L=function(){var t=1,n=0;return{p:function(r){for(var e=t,i=n,a=0|r.length,s=0;s!=a;){for(var o=Math.min(s+2655,a);s<o;++s)i+=e+=r[s];e=(65535&e)+15*(e>>16),i=(65535&i)+15*(i>>16)}t=e,n=i},d:function(){return(255&(t%=65521))<<24|(65280&t)<<8|(255&(n%=65521))<<8|n>>8}}},O=function(a,s,o,f,u){if(!u&&(u={l:1},s.dictionary)){var c=s.dictionary.subarray(-32768),v=new t(c.length+a.length);v.set(c),v.set(a,c.length),a=v,u.w=c.length}return function(a,s,o,f,u,c){var v=c.z||a.length,d=new t(f+v+5*(1+Math.ceil(v/7e3))+u),g=d.subarray(f,d.length-u),w=c.l,p=7&(c.r||0);if(s){p&&(g[0]=c.r>>3);for(var y=C[s-1],M=y>>13,E=8191&y,z=(1<<o)-1,_=c.p||new n(32768),x=c.h||new n(z+1),A=Math.ceil(o/3),D=2*A,T=function(t){return(a[t]^a[t+1]<<A^a[t+2]<<D)&z},F=new r(25e3),I=new n(288),S=new n(32),L=0,O=0,j=c.i||0,q=0,B=c.w||0,G=0;j+2<v;++j){var H=T(j),J=32767&j,K=x[H];if(_[J]=K,x[H]=J,B<=j){var N=v-j;if((L>7e3||q>24576)&&(N>423||!w)){p=U(a,g,0,F,I,S,O,q,G,j-G,p),q=L=O=0,G=j;for(var P=0;P<286;++P)I[P]=0;for(P=0;P<30;++P)S[P]=0}var Q=2,R=0,V=E,W=J-K&32767;if(N>2&&H==T(j-W))for(var X=Math.min(M,N)-1,Y=Math.min(32767,j),Z=Math.min(258,N);W<=Y&&--V&&J!=K;){if(a[j+Q]==a[j+Q-W]){for(var $=0;$<Z&&a[j+$]==a[j+$-W];++$);if($>Q){if(Q=$,R=W,$>X)break;var tt=Math.min(W,$-2),nt=0;for(P=0;P<tt;++P){var rt=j-W+P&32767,et=rt-_[rt]&32767;et>nt&&(nt=et,K=rt)}}}W+=(J=K)-(K=_[J])&32767}if(R){F[q++]=268435456|h[Q]<<18|l[R];var it=31&h[Q],at=31&l[R];O+=e[it]+i[at],++I[257+it],++S[at],B=j+Q,++L}else F[q++]=a[j],++I[a[j]]}}for(j=Math.max(j,B);j<v;++j)F[q++]=a[j],++I[a[j]];p=U(a,g,w,F,I,S,O,q,G,j-G,p),w||(c.r=7&p|g[p/8|0]<<3,p-=7,c.h=x,c.p=_,c.i=j,c.w=B)}else{for(j=c.w||0;j<v+w;j+=65535){var st=j+65535;st>=v&&(g[p/8|0]=w,st=v),p=k(g,p+1,a.subarray(j,st))}c.i=v}return b(d,0,f+m(p)+u)}(a,null==s.level?6:s.level,null==s.mem?Math.ceil(1.5*Math.max(8,Math.min(13,Math.log(a.length)))):12+s.mem,o,f,u)},j=function(t,n,r){for(;r;++n)t[n]=r,r>>>=8},q=function(t,n){var r=n.filename;if(t[0]=31,t[1]=139,t[2]=8,t[8]=n.level<2?4:9==n.level?2:0,t[9]=3,0!=n.mtime&&j(t,4,Math.floor(new Date(n.mtime||Date.now())/1e3)),r){t[3]=8;for(var e=0;e<=r.length;++e)t[e+10]=r.charCodeAt(e)}},B=function(t){return 10+(t.filename?t.filename.length+1:0)},G=function(){function n(n,r){if("function"==typeof n&&(r=n,n={}),this.ondata=r,this.o=n||{},this.s={l:0,i:32768,w:32768,z:32768},this.b=new t(98304),this.o.dictionary){var e=this.o.dictionary.subarray(-32768);this.b.set(e,32768-e.length),this.s.i=32768-e.length}}return n.prototype.p=function(t,n){this.ondata(O(t,this.o,0,0,this.s),n)},n.prototype.push=function(n,r){this.ondata||E(5),this.s.l&&E(4);var e=n.length+this.s.z;if(e>this.b.length){if(e>2*this.b.length-32768){var i=new t(-32768&e);i.set(this.b.subarray(0,this.s.z)),this.b=i}var a=this.b.length-this.s.z;a&&(this.b.set(n.subarray(0,a),this.s.z),this.s.z=this.b.length,this.p(this.b,!1)),this.b.set(this.b.subarray(-32768)),this.b.set(n.subarray(a),32768),this.s.z=n.length-a+32768,this.s.i=32766,this.s.w=32768}else this.b.set(n,this.s.z),this.s.z+=n.length;this.s.l=1&r,(this.s.z>this.s.w+8191||r)&&(this.p(this.b,r||!1),this.s.w=this.s.i,this.s.i-=2)},n}();var H=function(){function t(t,n){this.c=L(),this.v=1,G.call(this,t,n)}return t.prototype.push=function(t,n){this.c.p(t),G.prototype.push.call(this,t,n)},t.prototype.p=function(t,n){var r=O(t,this.o,this.v&&(this.o.dictionary?6:2),n&&4,this.s);this.v&&(function(t,n){var r=n.level,e=0==r?0:r<6?1:9==r?3:2;if(t[0]=120,t[1]=e<<6|(n.dictionary&&32),t[1]|=31-(t[0]<<8|t[1])%31,n.dictionary){var i=L();i.p(n.dictionary),j(t,2,i.d())}}(r,this.o),this.v=0),n&&j(r,r.length-4,this.c.d()),this.ondata(r,n)},t}(),J="undefined"!=typeof TextEncoder&&new TextEncoder,K="undefined"!=typeof TextDecoder&&new TextDecoder;try{K.decode(F,{stream:!0})}catch(t){}var N=function(){function t(t){this.ondata=t}return t.prototype.push=function(t,n){this.ondata||E(5),this.d&&E(4),this.ondata(P(t),this.d=n||!1)},t}();function P(n,r){if(J)return J.encode(n);for(var e=n.length,i=new t(n.length+(n.length>>1)),a=0,s=function(t){i[a++]=t},o=0;o<e;++o){if(a+5>i.length){var f=new t(a+8+(e-o<<1));f.set(i),i=f}var h=n.charCodeAt(o);h<128||r?s(h):h<2048?(s(192|h>>6),s(128|63&h)):h>55295&&h<57344?(s(240|(h=65536+(1047552&h)|1023&n.charCodeAt(++o))>>18),s(128|h>>12&63),s(128|h>>6&63),s(128|63&h)):(s(224|h>>12),s(128|h>>6&63),s(128|63&h))}return b(i,0,a)}function Q(t){return function(t,n){n||(n={});var r=S(),e=t.length;r.p(t);var i=O(t,n,B(n),8),a=i.length;return q(i,n),j(i,a-8,r.d()),j(i,a-4,e),i}(P(t))}const R=new class{constructor(){this._init()}clear(){this._init()}addEvent(t){if(!t)throw new Error("Adding invalid event");const n=this._hasEvents?",":"";this.stream.push(n+t),this._hasEvents=!0}finish(){this.stream.push("]",!0);const t=function(t){let n=0;for(const r of t)n+=r.length;const r=new Uint8Array(n);for(let n=0,e=0,i=t.length;n<i;n++){const i=t[n];r.set(i,e),e+=i.length}return r}(this._deflatedData);return this._init(),t}_init(){this._hasEvents=!1,this._deflatedData=[],this.deflate=new H,this.deflate.ondata=(t,n)=>{this._deflatedData.push(t)},this.stream=new N(((t,n)=>{this.deflate.push(t,n)})),this.stream.push("[")}},V={clear:()=>{R.clear()},addEvent:t=>R.addEvent(t),finish:()=>R.finish(),compress:t=>Q(t)};addEventListener("message",(function(t){const n=t.data.method,r=t.data.id,e=t.data.arg;if(n in V&&"function"==typeof V[n])try{const t=V[n](e);postMessage({id:r,method:n,success:!0,response:t})}catch(t){postMessage({id:r,method:n,success:!1,response:t.message}),console.error(t)}})),postMessage({id:void 0,method:"init",success:!0,response:void 0});';function Lm(){const e=new Blob([Pm]);return URL.createObjectURL(e)}const ni=["info","warn","error","log"],Tn="[Replay] ";function Ir(e,t="info"){Ke({category:"console",data:{logger:"replay"},level:t,message:`${Tn}${e}`},{level:t})}function Fm(){let e=!1,t=!1;const n={exception:()=>{},infoTick:()=>{},setConfig:n=>{e=n.captureExceptions,t=n.traceInternals}};return M?(ni.forEach((e=>{n[e]=(...n)=>{C[e](Tn,...n),t&&Ir(n.join(""),sa(e))}})),n.exception=(r,...o)=>{o.length&&n.error&&n.error(...o),C.error(Tn,r),e?Is(r):t&&Ir(r,"error")},n.infoTick=(...e)=>{C.info(Tn,...e),t&&setTimeout((()=>Ir(e[0])),0)}):ni.forEach((e=>{n[e]=()=>{}})),n}const O=Fm();class js extends Error{constructor(){super(`Event buffer exceeded maximum size of ${As}.`)}}class Za{constructor(){this.events=[],this._totalSize=0,this.hasCheckout=!1,this.waitForCheckout=!1}get hasEvents(){return this.events.length>0}get type(){return"sync"}destroy(){this.events=[]}async addEvent(e){const t=JSON.stringify(e).length;if(this._totalSize+=t,this._totalSize>As)throw new js;this.events.push(e)}finish(){return new Promise((e=>{const t=this.events;this.clear(),e(JSON.stringify(t))}))}clear(){this.events=[],this._totalSize=0,this.hasCheckout=!1}getEarliestTimestamp(){const e=this.events.map((e=>e.timestamp)).sort()[0];return e?Us(e):null}}class Um{constructor(e){this._worker=e,this._id=0}ensureReady(){return this._ensureReadyPromise||(this._ensureReadyPromise=new Promise(((e,t)=>{this._worker.addEventListener("message",(({data:n})=>{n.success?e():t()}),{once:!0}),this._worker.addEventListener("error",(e=>{t(e)}),{once:!0})}))),this._ensureReadyPromise}destroy(){M&&O.info("Destroying compression worker"),this._worker.terminate()}postMessage(e,t){const n=this._getAndIncrementId();return new Promise(((r,o)=>{const s=({data:t})=>{const i=t;if(i.method===e&&i.id===n){if(this._worker.removeEventListener("message",s),!i.success)return M&&O.error("Error in compression worker: ",i.response),void o(new Error("Error in compression worker"));r(i.response)}};this._worker.addEventListener("message",s),this._worker.postMessage({id:n,method:e,arg:t})}))}_getAndIncrementId(){return this._id++}}class jm{constructor(e){this._worker=new Um(e),this._earliestTimestamp=null,this._totalSize=0,this.hasCheckout=!1,this.waitForCheckout=!1}get hasEvents(){return!!this._earliestTimestamp}get type(){return"worker"}ensureReady(){return this._worker.ensureReady()}destroy(){this._worker.destroy()}addEvent(e){const t=Us(e.timestamp);(!this._earliestTimestamp||t<this._earliestTimestamp)&&(this._earliestTimestamp=t);const n=JSON.stringify(e);return this._totalSize+=n.length,this._totalSize>As?Promise.reject(new js):this._sendEventToWorker(n)}finish(){return this._finishRequest()}clear(){this._earliestTimestamp=null,this._totalSize=0,this.hasCheckout=!1,this._worker.postMessage("clear").then(null,(e=>{M&&O.exception(e,'Sending "clear" message to worker failed',e)}))}getEarliestTimestamp(){return this._earliestTimestamp}_sendEventToWorker(e){return this._worker.postMessage("addEvent",e)}async _finishRequest(){const e=await this._worker.postMessage("finish");return this._earliestTimestamp=null,this._totalSize=0,e}}class Bm{constructor(e){this._fallback=new Za,this._compression=new jm(e),this._used=this._fallback,this._ensureWorkerIsLoadedPromise=this._ensureWorkerIsLoaded()}get waitForCheckout(){return this._used.waitForCheckout}get type(){return this._used.type}get hasEvents(){return this._used.hasEvents}get hasCheckout(){return this._used.hasCheckout}set hasCheckout(e){this._used.hasCheckout=e}set waitForCheckout(e){this._used.waitForCheckout=e}destroy(){this._fallback.destroy(),this._compression.destroy()}clear(){return this._used.clear()}getEarliestTimestamp(){return this._used.getEarliestTimestamp()}addEvent(e){return this._used.addEvent(e)}async finish(){return await this.ensureWorkerIsLoaded(),this._used.finish()}ensureWorkerIsLoaded(){return this._ensureWorkerIsLoadedPromise}async _ensureWorkerIsLoaded(){try{await this._compression.ensureReady()}catch(e){return void(M&&O.exception(e,"Failed to load the compression worker, falling back to simple buffer"))}await this._switchToCompressionWorker()}async _switchToCompressionWorker(){const{events:e,hasCheckout:t,waitForCheckout:n}=this._fallback,r=[];for(const t of e)r.push(this._compression.addEvent(t));this._compression.hasCheckout=t,this._compression.waitForCheckout=n,this._used=this._compression;try{await Promise.all(r),this._fallback.clear()}catch(e){M&&O.exception(e,"Failed to add events when switching buffers.")}}}function $m({useCompression:e,workerUrl:t}){if(e&&window.Worker){const e=Hm(t);if(e)return e}return M&&O.info("Using simple buffer"),new Za}function Hm(e){try{const t=e||zm();if(!t)return;M&&O.info("Using compression worker"+(e?` from ${e}`:""));const n=new Worker(t);return new Bm(n)}catch(e){M&&O.exception(e,"Failed to create compression worker")}}function zm(){return typeof __SENTRY_EXCLUDE_REPLAY_WORKER__>"u"||!__SENTRY_EXCLUDE_REPLAY_WORKER__?Lm():""}function Bs(){try{return"sessionStorage"in ee&&!!ee.sessionStorage}catch{return!1}}function Wm(e){Gm(),e.session=void 0}function Gm(){if(Bs())try{ee.sessionStorage.removeItem(Os)}catch{}}function ec(e){return void 0!==e&&Math.random()<e}function tc(e){const t=Date.now();return{id:e.id||ge(),started:e.started||t,lastActivity:e.lastActivity||t,segmentId:e.segmentId||0,sampled:e.sampled,previousSessionId:e.previousSessionId}}function $s(e){if(Bs())try{ee.sessionStorage.setItem(Os,JSON.stringify(e))}catch{}}function Ym(e,t){return ec(e)?"session":!!t&&"buffer"}function ri({sessionSampleRate:e,allowBuffering:t,stickySession:n=!1},{previousSessionId:r}={}){const o=tc({sampled:Ym(e,t),previousSessionId:r});return n&&$s(o),o}function qm(){if(!Bs())return null;try{const e=ee.sessionStorage.getItem(Os);if(!e)return null;const t=JSON.parse(e);return M&&O.infoTick("Loading existing session"),tc(t)}catch{return null}}function rs(e,t,n=+new Date){return null===e||void 0===t||t<0||0!==t&&e+t<=n}function nc(e,{maxReplayDuration:t,sessionIdleExpire:n,targetTime:r=Date.now()}){return rs(e.started,t,r)||rs(e.lastActivity,n,r)}function rc(e,{sessionIdleExpire:t,maxReplayDuration:n}){return!(!nc(e,{sessionIdleExpire:t,maxReplayDuration:n})||"buffer"===e.sampled&&0===e.segmentId)}function wr({sessionIdleExpire:e,maxReplayDuration:t,previousSessionId:n},r){const o=r.stickySession&&qm();return o?rc(o,{sessionIdleExpire:e,maxReplayDuration:t})?(M&&O.infoTick("Session in sessionStorage is expired, creating new one..."),ri(r,{previousSessionId:o.id})):o:(M&&O.infoTick("Creating new session"),ri(r,{previousSessionId:n}))}function Km(e){return e.type===x.Custom}function Hs(e,t,n){return!!oc(e,t)&&(sc(e,t,n),!0)}function Vm(e,t,n){return oc(e,t)?sc(e,t,n):Promise.resolve(null)}async function sc(e,t,n){const{eventBuffer:r}=e;if(!r||r.waitForCheckout&&!n)return null;const o="buffer"===e.recordingMode;try{n&&o&&r.clear(),n&&(r.hasCheckout=!0,r.waitForCheckout=!1);const s=Jm(t,e.getOptions().beforeAddRecordingEvent);return s?await r.addEvent(s):void 0}catch(t){const n=t&&t instanceof js,s=n?"addEventSizeExceeded":"addEvent";if(n&&o)return r.clear(),r.waitForCheckout=!0,null;e.handleException(t),await e.stop({reason:s});const i=ie();i&&i.recordDroppedEvent("internal_sdk_error","replay")}}function oc(e,t){if(!e.eventBuffer||e.isPaused()||!e.isEnabled())return!1;const n=Us(t.timestamp);return!(n+e.timeouts.sessionIdlePause<Date.now())&&(!(n>e.getContext().initialTimestamp+e.getOptions().maxReplayDuration)||(M&&O.infoTick(`Skipping event with timestamp ${n} because it is after maxReplayDuration`),!1))}function Jm(e,t){try{if("function"==typeof t&&Km(e))return t(e)}catch(e){return M&&O.exception(e,"An error occurred in the `beforeAddRecordingEvent` callback, skipping the event..."),null}return e}function zs(e){return!e.type}function ss(e){return"transaction"===e.type}function Xm(e){return"replay_event"===e.type}function si(e){return"feedback"===e.type}function Qm(e){return(t,n)=>{if(!e.isEnabled()||!zs(t)&&!ss(t))return;const r=n&&n.statusCode;if(!(!r||r<200||r>=300)){if(ss(t))return void Zm(e,t);e_(e,t)}}}function Zm(e,t){const n=e.getContext();t.contexts&&t.contexts.trace&&t.contexts.trace.trace_id&&n.traceIds.size<100&&n.traceIds.add(t.contexts.trace.trace_id)}function e_(e,t){const n=e.getContext();if(t.event_id&&n.errorIds.size<100&&n.errorIds.add(t.event_id),"buffer"!==e.recordingMode||!t.tags||!t.tags.replayId)return;const{beforeErrorSampling:r}=e.getOptions();"function"==typeof r&&!r(t)||Tt((async()=>{try{await e.sendBufferedReplayOrFlush()}catch(t){e.handleException(t)}}))}function t_(e){return t=>{!e.isEnabled()||!zs(t)||n_(e,t)}}function n_(e,t){const n=t.exception&&t.exception.values&&t.exception.values[0]&&t.exception.values[0].value;if("string"==typeof n&&(n.match(/(reactjs\.org\/docs\/error-decoder\.html\?invariant=|react\.dev\/errors\/)(418|419|422|423|425)/)||n.match(/(does not match server-rendered HTML|Hydration failed because)/i))){rn(e,Oe({category:"replay.hydrate-error",data:{url:Pi()}}))}}function r_(e){const t=ie();t&&t.on("beforeAddBreadcrumb",(t=>s_(e,t)))}function s_(e,t){if(!e.isEnabled()||!ic(t))return;const n=o_(t);n&&rn(e,n)}function o_(e){return!ic(e)||["fetch","xhr","sentry.event","sentry.transaction"].includes(e.category)||e.category.startsWith("ui.")?null:"console"===e.category?i_(e):Oe(e)}function i_(e){const t=e.data&&e.data.arguments;if(!Array.isArray(t)||0===t.length)return Oe(e);let n=!1;const r=t.map((e=>{if(!e)return e;if("string"==typeof e)return e.length>mn?(n=!0,`${e.slice(0,mn)}…`):e;if("object"==typeof e)try{const t=Te(e,7);return JSON.stringify(t).length>mn?(n=!0,`${JSON.stringify(t,null,2).slice(0,mn)}…`):t}catch{}return e}));return Oe({...e,data:{...e.data,arguments:r,...n?{_meta:{warnings:["CONSOLE_ARG_TRUNCATED"]}}:{}}})}function ic(e){return!!e.category}function a_(e,t){return!(e.type||!e.exception||!e.exception.values||!e.exception.values.length)&&!(!t.originalException||!t.originalException.__rrweb__)}function ac(){const e=be().getPropagationContext().dsc;e&&delete e.replay_id;const t=$i();if(t){delete zi(t).replay_id}}function c_(e,t){e.triggerUserActivity(),e.addUpdate((()=>!t.timestamp||(e.throttledAddEvent({type:x.Custom,timestamp:1e3*t.timestamp,data:{tag:"breadcrumb",payload:{timestamp:t.timestamp,type:"default",category:"sentry.feedback",data:{feedbackId:t.event_id}}}}),!1)))}function u_(e,t){return!("buffer"!==e.recordingMode||t.message===Ds||!t.exception||t.type)&&ec(e.getOptions().errorSampleRate)}function l_(e){return Object.assign(((t,n)=>!e.isEnabled()||e.isPaused()?t:Xm(t)?(delete t.breadcrumbs,t):zs(t)||ss(t)||si(t)?e.checkAndHandleExpiredSession()?si(t)?(e.flush(),t.contexts.feedback.replay_id=e.getSessionId(),c_(e,t),t):a_(t,n)&&!e.getOptions()._experiments.captureExceptions?(M&&O.log("Ignoring error from rrweb internals",t),null):((u_(e,t)||"session"===e.recordingMode)&&(t.tags={...t.tags,replayId:e.getSessionId()}),t):(ac(),t):t),{id:"Replay"})}function nr(e,t){return t.map((({type:t,start:n,end:r,name:o,data:s})=>{const i=e.throttledAddEvent({type:x.Custom,timestamp:n,data:{tag:"performanceSpan",payload:{op:t,description:o,startTimestamp:n,endTimestamp:r,data:s}}});return"string"==typeof i?Promise.resolve(null):i}))}function d_(e){const{from:t,to:n}=e,r=Date.now()/1e3;return{type:"navigation.push",start:r,end:r,name:n,data:{previous:t}}}function f_(e){return t=>{if(!e.isEnabled())return;const n=d_(t);null!==n&&(e.getContext().urls.push(n.name),e.triggerUserActivity(),e.addUpdate((()=>(nr(e,[n]),!1))))}}function p_(e,t){return(!M||!e.getOptions()._experiments.traceInternals)&&zl(t,ie())}function cc(e,t){e.isEnabled()&&null!==t&&(p_(e,t.name)||e.addUpdate((()=>(nr(e,[t]),!0))))}function rr(e){if(!e)return;const t=new TextEncoder;try{if("string"==typeof e)return t.encode(e).length;if(e instanceof URLSearchParams)return t.encode(e.toString()).length;if(e instanceof FormData){const n=fc(e);return t.encode(n).length}if(e instanceof Blob)return e.size;if(e instanceof ArrayBuffer)return e.byteLength}catch{}}function uc(e){if(!e)return;const t=parseInt(e,10);return isNaN(t)?void 0:t}function lc(e){try{if("string"==typeof e)return[e];if(e instanceof URLSearchParams)return[e.toString()];if(e instanceof FormData)return[fc(e)];if(!e)return[void 0]}catch(t){return M&&O.exception(t,"Failed to serialize body",e),[void 0,"BODY_PARSE_ERROR"]}return M&&O.info("Skipping network body because of body type",e),[void 0,"UNPARSEABLE_BODY_TYPE"]}function Un(e,t){if(!e)return{headers:{},size:void 0,_meta:{warnings:[t]}};const n={...e._meta},r=n.warnings||[];return n.warnings=[...r,t],e._meta=n,e}function dc(e,t){if(!t)return null;const{startTimestamp:n,endTimestamp:r,url:o,method:s,statusCode:i,request:a,response:c}=t;return{type:e,start:n/1e3,end:r/1e3,name:o,data:he({method:s,statusCode:i,request:a,response:c})}}function Wt(e){return{headers:{},size:e,_meta:{warnings:["URL_SKIPPED"]}}}function qe(e,t,n){if(!t&&0===Object.keys(e).length)return;if(!t)return{headers:e};if(!n)return{headers:e,size:t};const r={headers:e,size:t},{body:o,warnings:s}=h_(n);return r.body=o,s&&s.length>0&&(r._meta={warnings:s}),r}function os(e,t){return Object.entries(e).reduce(((n,[r,o])=>{const s=r.toLowerCase();return t.includes(s)&&e[r]&&(n[s]=o),n}),{})}function fc(e){return new URLSearchParams(e).toString()}function h_(e){if(!e||"string"!=typeof e)return{body:e};const t=e.length>Uo,n=m_(e);if(t){const t=e.slice(0,Uo);return n?{body:t,warnings:["MAYBE_JSON_TRUNCATED"]}:{body:`${t}…`,warnings:["TEXT_TRUNCATED"]}}if(n)try{return{body:JSON.parse(e)}}catch{}return{body:e}}function m_(e){const t=e[0],n=e[e.length-1];return"["===t&&"]"===n||"{"===t&&"}"===n}function jn(e,t){return Vt(__(e),t)}function __(e,t=ee.document.baseURI){if(e.startsWith("http://")||e.startsWith("https://")||e.startsWith(ee.location.origin))return e;const n=new URL(e,t);if(n.origin!==new URL(t).origin)return e;const r=n.href;return!e.endsWith("/")&&r.endsWith("/")?r.slice(0,-1):r}async function g_(e,t,n){try{const r=dc("resource.fetch",await E_(e,t,n));cc(n.replay,r)}catch(e){M&&O.exception(e,"Failed to capture fetch breadcrumb")}}function y_(e,t){const{input:n,response:r}=t,o=rr(n?pc(n):void 0),s=r?uc(r.headers.get("content-length")):void 0;void 0!==o&&(e.data.request_body_size=o),void 0!==s&&(e.data.response_body_size=s)}async function E_(e,t,n){const r=Date.now(),{startTimestamp:o=r,endTimestamp:s=r}=t,{url:i,method:a,status_code:c=0,request_body_size:u,response_body_size:l}=e.data,d=jn(i,n.networkDetailAllowUrls)&&!jn(i,n.networkDetailDenyUrls);return{startTimestamp:o,endTimestamp:s,url:i,method:a,statusCode:c,request:d?S_(n,t.input,u):Wt(u),response:await b_(d,n,t.response,l)}}function S_({networkCaptureBodies:e,networkRequestHeaders:t},n,r){const o=n?w_(n,t):{};if(!e)return qe(o,r,void 0);const s=pc(n),[i,a]=lc(s),c=qe(o,r,i);return a?Un(c,a):c}async function b_(e,{networkCaptureBodies:t,networkResponseHeaders:n},r,o){if(!e&&void 0!==o)return Wt(o);const s=r?hc(r.headers,n):{};if(!r||!t&&void 0!==o)return qe(s,o,void 0);const[i,a]=await I_(r),c=v_(i,{networkCaptureBodies:t,responseBodySize:o,captureDetails:e,headers:s});return a?Un(c,a):c}function v_(e,{networkCaptureBodies:t,responseBodySize:n,captureDetails:r,headers:o}){try{const s=e&&e.length&&void 0===n?rr(e):n;return r?qe(o,s,t?e:void 0):Wt(s)}catch(e){return M&&O.exception(e,"Failed to serialize response body"),qe(o,n,void 0)}}async function I_(e){const t=T_(e);if(!t)return[void 0,"BODY_PARSE_ERROR"];try{return[await k_(t)]}catch(e){return e instanceof Error&&e.message.indexOf("Timeout")>-1?(M&&O.warn("Parsing text body from response timed out"),[void 0,"BODY_PARSE_TIMEOUT"]):(M&&O.exception(e,"Failed to get text body from response"),[void 0,"BODY_PARSE_ERROR"])}}function pc(e=[]){if(2===e.length&&"object"==typeof e[1])return e[1].body}function hc(e,t){const n={};return t.forEach((t=>{e.get(t)&&(n[t]=e.get(t))})),n}function w_(e,t){return 1===e.length&&"string"!=typeof e[0]?oi(e[0],t):2===e.length?oi(e[1],t):{}}function oi(e,t){if(!e)return{};const n=e.headers;return n?n instanceof Headers?hc(n,t):Array.isArray(n)?{}:os(n,t):{}}function T_(e){try{return e.clone()}catch(e){M&&O.exception(e,"Failed to clone response body")}}function k_(e){return new Promise(((t,n)=>{const r=Tt((()=>n(new Error("Timeout while trying to read response body"))),500);R_(e).then((e=>t(e)),(e=>n(e))).finally((()=>clearTimeout(r)))}))}async function R_(e){return await e.text()}async function C_(e,t,n){try{const r=dc("resource.xhr",O_(e,t,n));cc(n.replay,r)}catch(e){M&&O.exception(e,"Failed to capture xhr breadcrumb")}}function M_(e,t){const{xhr:n,input:r}=t;if(!n)return;const o=rr(r),s=n.getResponseHeader("content-length")?uc(n.getResponseHeader("content-length")):N_(n.response,n.responseType);void 0!==o&&(e.data.request_body_size=o),void 0!==s&&(e.data.response_body_size=s)}function O_(e,t,n){const r=Date.now(),{startTimestamp:o=r,endTimestamp:s=r,input:i,xhr:a}=t,{url:c,method:u,status_code:l=0,request_body_size:d,response_body_size:p}=e.data;if(!c)return null;if(!a||!jn(c,n.networkDetailAllowUrls)||jn(c,n.networkDetailDenyUrls)){return{startTimestamp:o,endTimestamp:s,url:c,method:u,statusCode:l,request:Wt(d),response:Wt(p)}}const h=a[ht],m=h?os(h.request_headers,n.networkRequestHeaders):{},f=os(D_(a),n.networkResponseHeaders),[y,_]=n.networkCaptureBodies?lc(i):[void 0],[g,v]=n.networkCaptureBodies?A_(a):[void 0],b=qe(m,d,y),S=qe(f,p,g);return{startTimestamp:o,endTimestamp:s,url:c,method:u,statusCode:l,request:_?Un(b,_):b,response:v?Un(S,v):S}}function D_(e){const t=e.getAllResponseHeaders();return t?t.split("\r\n").reduce(((e,t)=>{const[n,r]=t.split(": ");return r&&(e[n.toLowerCase()]=r),e}),{}):{}}function A_(e){const t=[];try{return[e.responseText]}catch(e){t.push(e)}try{return x_(e.response,e.responseType)}catch(e){t.push(e)}return M&&O.warn("Failed to get xhr response body",...t),[void 0]}function x_(e,t){try{if("string"==typeof e)return[e];if(e instanceof Document)return[e.body.outerHTML];if("json"===t&&e&&"object"==typeof e)return[JSON.stringify(e)];if(!e)return[void 0]}catch(t){return M&&O.exception(t,"Failed to serialize body",e),[void 0,"BODY_PARSE_ERROR"]}return M&&O.info("Skipping network body because of body type",e),[void 0,"UNPARSEABLE_BODY_TYPE"]}function N_(e,t){try{return rr("json"===t&&e&&"object"==typeof e?JSON.stringify(e):e)}catch{return}}function P_(e){const t=ie();try{const{networkDetailAllowUrls:n,networkDetailDenyUrls:r,networkCaptureBodies:o,networkRequestHeaders:s,networkResponseHeaders:i}=e.getOptions(),a={replay:e,networkDetailAllowUrls:n,networkDetailDenyUrls:r,networkCaptureBodies:o,networkRequestHeaders:s,networkResponseHeaders:i};t&&t.on("beforeAddBreadcrumb",((e,t)=>L_(a,e,t)))}catch{}}function L_(e,t,n){if(t.data)try{F_(t)&&j_(n)&&(M_(t,n),C_(t,n,e)),U_(t)&&B_(n)&&(y_(t,n),g_(t,n,e))}catch(e){M&&O.exception(e,"Error when enriching network breadcrumb")}}function F_(e){return"xhr"===e.category}function U_(e){return"fetch"===e.category}function j_(e){return e&&e.xhr}function B_(e){return e&&e.response}function $_(e){const t=ie();va(_m(e)),Ms(f_(e)),r_(e),P_(e);vl(l_(e)),t&&(t.on("beforeSendEvent",t_(e)),t.on("afterSendEvent",Qm(e)),t.on("createDsc",(t=>{const n=e.getSessionId();n&&e.isEnabled()&&"session"===e.recordingMode&&e.checkAndHandleExpiredSession()&&(t.replay_id=n)})),t.on("spanStart",(t=>{e.lastActiveSpan=t})),t.on("spanEnd",(t=>{e.lastActiveSpan=t})),t.on("beforeSendFeedback",((t,n)=>{const r=e.getSessionId();n&&n.includeReplay&&e.isEnabled()&&r&&t.contexts&&t.contexts.feedback&&(t.contexts.feedback.replay_id=r)})))}async function H_(e){try{return Promise.all(nr(e,[z_(ee.performance.memory)]))}catch{return[]}}function z_(e){const{jsHeapSizeLimit:t,totalJSHeapSize:n,usedJSHeapSize:r}=e,o=Date.now()/1e3;return{type:"memory",name:"memory",start:o,end:o,data:{memory:{jsHeapSizeLimit:t,totalJSHeapSize:n,usedJSHeapSize:r}}}}function W_(e,t,n){let r,o,s;const i=n.maxWait?Math.max(n.maxWait,t):0;function a(){return c(),r=e(),r}function c(){void 0!==o&&clearTimeout(o),void 0!==s&&clearTimeout(s),o=s=void 0}function u(){return o&&clearTimeout(o),o=Tt(a,t),i&&void 0===s&&(s=Tt(a,i)),r}return u.cancel=c,u.flush=function(){return void 0!==o||void 0!==s?a():r},u}function G_(e){let t=!1;return(n,r)=>{if(!e.checkAndHandleExpiredSession())return void(M&&O.warn("Received replay event after session expired."));const o=r||!t;t=!0,e.clickDetector&&dm(e.clickDetector,n),e.addUpdate((()=>{if("buffer"===e.recordingMode&&o&&e.setInitialState(),!Hs(e,n,o))return!0;if(!o)return!1;const t=e.session;if(q_(e,o),"buffer"===e.recordingMode&&t&&e.eventBuffer){const n=e.eventBuffer.getEarliestTimestamp();n&&(M&&O.info(`Updating session start time to earliest event in buffer to ${new Date(n)}`),t.started=n,e.getOptions().stickySession&&$s(t))}return t&&t.previousSessionId||"session"===e.recordingMode&&e.flush(),!0}))}}function Y_(e){const t=e.getOptions();return{type:x.Custom,timestamp:Date.now(),data:{tag:"options",payload:{shouldRecordCanvas:e.isRecordingCanvas(),sessionSampleRate:t.sessionSampleRate,errorSampleRate:t.errorSampleRate,useCompressionOption:t.useCompression,blockAllMedia:t.blockAllMedia,maskAllText:t.maskAllText,maskAllInputs:t.maskAllInputs,useCompression:!!e.eventBuffer&&"worker"===e.eventBuffer.type,networkDetailHasUrls:t.networkDetailAllowUrls.length>0,networkCaptureBodies:t.networkCaptureBodies,networkRequestHasHeaders:t.networkRequestHeaders.length>0,networkResponseHasHeaders:t.networkResponseHeaders.length>0}}}}function q_(e,t){!t||!e.session||0!==e.session.segmentId||Hs(e,Y_(e),!1)}function K_(e,t,n,r){return At(Yi(e,vs(e),r,n),[[{type:"replay_event"},e],[{type:"replay_recording",length:"string"==typeof t?(new TextEncoder).encode(t).length:t.length},t]])}function V_({recordingData:e,headers:t}){let n;const r=`${JSON.stringify(t)}\n`;if("string"==typeof e)n=`${r}${e}`;else{const t=(new TextEncoder).encode(r);n=new Uint8Array(t.length+e.length),n.set(t),n.set(e,t.length)}return n}async function J_({client:e,scope:t,replayId:n,event:r}){const o={event_id:n,integrations:"object"!=typeof e._integrations||null===e._integrations||Array.isArray(e._integrations)?void 0:Object.keys(e._integrations)};e.emit("preprocessEvent",r,o);const s=await qi(e.getOptions(),r,o,t,e,Ae());if(!s)return null;s.platform=s.platform||"javascript";const i=e.getSdkMetadata(),{name:a,version:c}=i&&i.sdk||{};return s.sdk={...s.sdk,name:a||"sentry.javascript.unknown",version:c||"0.0.0"},s}async function X_({recordingData:e,replayId:t,segmentId:n,eventContext:r,timestamp:o,session:s}){const i=V_({recordingData:e,headers:{segment_id:n}}),{urls:a,errorIds:c,traceIds:u,initialTimestamp:l}=r,d=ie(),p=be(),h=d&&d.getTransport(),m=d&&d.getDsn();if(!(d&&h&&m&&s.sampled))return Be({});const f={type:Op,replay_start_timestamp:l/1e3,timestamp:o/1e3,error_ids:c,trace_ids:u,urls:a,replay_id:t,segment_id:n,replay_type:s.sampled},y=await J_({scope:p,client:d,replayId:t,event:f});if(!y)return d.recordDroppedEvent("event_processor","replay",f),M&&O.info("An event processor returned `null`, will not send event."),Be({});delete y.sdkProcessingMetadata;const _=K_(y,i,m,d.getOptions().tunnel);let g;try{g=await h.send(_)}catch(e){const t=new Error(Ds);try{t.cause=e}catch{}throw t}if("number"==typeof g.statusCode&&(g.statusCode<200||g.statusCode>=300))throw new mc(g.statusCode);const v=na({},g);if(ta(v,"replay"))throw new Ws(v);return g}class mc extends Error{constructor(e){super(`Transport returned status code ${e}`)}}class Ws extends Error{constructor(e){super("Rate limit hit"),this.rateLimits=e}}async function _c(e,t={count:0,interval:Lp}){const{recordingData:n,onError:r}=e;if(n.length)try{return await X_(e),!0}catch(n){if(n instanceof mc||n instanceof Ws)throw n;if(Vi("Replays",{_retryCount:t.count}),r&&r(n),t.count>=3){const e=new Error(`${Ds} - max retries exceeded`);try{e.cause=n}catch{}throw e}return t.interval*=++t.count,new Promise(((n,r)=>{Tt((async()=>{try{await _c(e,t),n(!0)}catch(e){r(e)}}),t.interval)}))}}const gc="__THROTTLED",Q_="__SKIPPED";function Z_(e,t,n){const r=new Map;let o=!1;return(...s)=>{const i=Math.floor(Date.now()/1e3);if((e=>{const t=e-n;r.forEach(((e,n)=>{n<t&&r.delete(n)}))})(i),[...r.values()].reduce(((e,t)=>e+t),0)>=t){const e=o;return o=!0,e?Q_:gc}o=!1;const a=r.get(i)||0;return r.set(i,a+1),e(...s)}}class Ye{constructor({options:e,recordingOptions:t}){Ye.prototype.__init.call(this),Ye.prototype.__init2.call(this),Ye.prototype.__init3.call(this),Ye.prototype.__init4.call(this),Ye.prototype.__init5.call(this),Ye.prototype.__init6.call(this),this.eventBuffer=null,this.performanceEntries=[],this.replayPerformanceEntries=[],this.recordingMode="session",this.timeouts={sessionIdlePause:Dp,sessionIdleExpire:Ap},this._lastActivity=Date.now(),this._isEnabled=!1,this._isPaused=!1,this._requiresManualStart=!1,this._hasInitializedCoreListeners=!1,this._context={errorIds:new Set,traceIds:new Set,urls:[],initialTimestamp:Date.now(),initialUrl:""},this._recordingOptions=t,this._options=e,this._debouncedFlush=W_((()=>this._flush()),this._options.flushMinDelay,{maxWait:this._options.flushMaxDelay}),this._throttledAddEvent=Z_(((e,t)=>Vm(this,e,t)),300,5);const{slowClickTimeout:n,slowClickIgnoreSelectors:r}=this.getOptions(),o=n?{threshold:Math.min(Up,n),timeout:n,scrollTimeout:jp,ignoreSelector:r?r.join(","):""}:void 0;if(o&&(this.clickDetector=new am(this,o)),M){const t=e._experiments;O.setConfig({captureExceptions:!!t.captureExceptions,traceInternals:!!t.traceInternals})}}getContext(){return this._context}isEnabled(){return this._isEnabled}isPaused(){return this._isPaused}isRecordingCanvas(){return!!this._canvas}getOptions(){return this._options}handleException(e){M&&O.exception(e),this._options.onError&&this._options.onError(e)}initializeSampling(e){const{errorSampleRate:t,sessionSampleRate:n}=this._options,r=t<=0&&n<=0;if(this._requiresManualStart=r,!r){if(this._initializeSessionForSampling(e),!this.session)return void(M&&O.exception(new Error("Unable to initialize and create session")));!1!==this.session.sampled&&(this.recordingMode="buffer"===this.session.sampled&&0===this.session.segmentId?"buffer":"session",M&&O.infoTick(`Starting replay in ${this.recordingMode} mode`),this._initializeRecording())}}start(){if(this._isEnabled&&"session"===this.recordingMode)return void(M&&O.info("Recording is already in progress"));if(this._isEnabled&&"buffer"===this.recordingMode)return void(M&&O.info("Buffering is in progress, call `flush()` to save the replay"));M&&O.infoTick("Starting replay in session mode"),this._updateUserActivity();const e=wr({maxReplayDuration:this._options.maxReplayDuration,sessionIdleExpire:this.timeouts.sessionIdleExpire},{stickySession:this._options.stickySession,sessionSampleRate:1,allowBuffering:!1});this.session=e,this._initializeRecording()}startBuffering(){if(this._isEnabled)return void(M&&O.info("Buffering is in progress, call `flush()` to save the replay"));M&&O.infoTick("Starting replay in buffer mode");const e=wr({sessionIdleExpire:this.timeouts.sessionIdleExpire,maxReplayDuration:this._options.maxReplayDuration},{stickySession:this._options.stickySession,sessionSampleRate:0,allowBuffering:!0});this.session=e,this.recordingMode="buffer",this._initializeRecording()}startRecording(){try{const e=this._canvas;this._stopRecording=Ue({...this._recordingOptions,..."buffer"===this.recordingMode?{checkoutEveryNms:Pp}:this._options._experiments.continuousCheckout&&{checkoutEveryNms:Math.max(36e4,this._options._experiments.continuousCheckout)},emit:G_(this),onMutation:this._onMutationHandler,...e?{recordCanvas:e.recordCanvas,getCanvasManager:e.getCanvasManager,sampling:e.sampling,dataURLOptions:e.dataURLOptions}:{}})}catch(e){this.handleException(e)}}stopRecording(){try{return this._stopRecording&&(this._stopRecording(),this._stopRecording=void 0),!0}catch(e){return this.handleException(e),!1}}async stop({forceFlush:e=!1,reason:t}={}){if(this._isEnabled){this._isEnabled=!1;try{M&&O.info("Stopping Replay"+(t?` triggered by ${t}`:"")),ac(),this._removeListeners(),this.stopRecording(),this._debouncedFlush.cancel(),e&&await this._flush({force:!0}),this.eventBuffer&&this.eventBuffer.destroy(),this.eventBuffer=null,Wm(this)}catch(e){this.handleException(e)}}}pause(){this._isPaused||(this._isPaused=!0,this.stopRecording(),M&&O.info("Pausing replay"))}resume(){!this._isPaused||!this._checkSession()||(this._isPaused=!1,this.startRecording(),M&&O.info("Resuming replay"))}async sendBufferedReplayOrFlush({continueRecording:e=!0}={}){if("session"===this.recordingMode)return this.flushImmediate();const t=Date.now();M&&O.info("Converting buffer to session"),await this.flushImmediate();const n=this.stopRecording();!e||!n||"session"!==this.recordingMode&&(this.recordingMode="session",this.session&&(this._updateUserActivity(t),this._updateSessionActivity(t),this._maybeSaveSession()),this.startRecording())}addUpdate(e){const t=e();"buffer"!==this.recordingMode&&!0!==t&&this._debouncedFlush()}triggerUserActivity(){if(this._updateUserActivity(),this._stopRecording)this.checkAndHandleExpiredSession(),this._updateSessionActivity();else{if(!this._checkSession())return;this.resume()}}updateUserActivity(){this._updateUserActivity(),this._updateSessionActivity()}conditionalFlush(){return"buffer"===this.recordingMode?Promise.resolve():this.flushImmediate()}flush(){return this._debouncedFlush()}flushImmediate(){return this._debouncedFlush(),this._debouncedFlush.flush()}cancelFlush(){this._debouncedFlush.cancel()}getSessionId(){return this.session&&this.session.id}checkAndHandleExpiredSession(){if(!(this._lastActivity&&rs(this._lastActivity,this.timeouts.sessionIdlePause)&&this.session&&"session"===this.session.sampled))return!!this._checkSession();this.pause()}setInitialState(){const e=`${ee.location.pathname}${ee.location.hash}${ee.location.search}`,t=`${ee.location.origin}${e}`;this.performanceEntries=[],this.replayPerformanceEntries=[],this._clearContext(),this._context.initialUrl=t,this._context.initialTimestamp=Date.now(),this._context.urls.push(t)}throttledAddEvent(e,t){const n=this._throttledAddEvent(e,t);if(n===gc){const e=Oe({category:"replay.throttled"});this.addUpdate((()=>!Hs(this,{type:5,timestamp:e.timestamp||0,data:{tag:"breadcrumb",payload:e,metric:!0}})))}return n}getCurrentRoute(){const e=this.lastActiveSpan||$i(),t=e&&Ss(e),n=(t&&jt(t).data||{})[Bi];if(t&&n&&["route","custom"].includes(n))return jt(t).description}_initializeRecording(){this.setInitialState(),this._updateSessionActivity(),this.eventBuffer=$m({useCompression:this._options.useCompression,workerUrl:this._options.workerUrl}),this._removeListeners(),this._addListeners(),this._isEnabled=!0,this._isPaused=!1,this.startRecording()}_initializeSessionForSampling(e){const t=this._options.errorSampleRate>0,n=wr({sessionIdleExpire:this.timeouts.sessionIdleExpire,maxReplayDuration:this._options.maxReplayDuration,previousSessionId:e},{stickySession:this._options.stickySession,sessionSampleRate:this._options.sessionSampleRate,allowBuffering:t});this.session=n}_checkSession(){if(!this.session)return!1;const e=this.session;return!rc(e,{sessionIdleExpire:this.timeouts.sessionIdleExpire,maxReplayDuration:this._options.maxReplayDuration})||(this._refreshSession(e),!1)}async _refreshSession(e){this._isEnabled&&(await this.stop({reason:"refresh session"}),this.initializeSampling(e.id))}_addListeners(){try{ee.document.addEventListener("visibilitychange",this._handleVisibilityChange),ee.addEventListener("blur",this._handleWindowBlur),ee.addEventListener("focus",this._handleWindowFocus),ee.addEventListener("keydown",this._handleKeyboardEvent),this.clickDetector&&this.clickDetector.addListeners(),this._hasInitializedCoreListeners||($_(this),this._hasInitializedCoreListeners=!0)}catch(e){this.handleException(e)}this._performanceCleanupCallback=Nm(this)}_removeListeners(){try{ee.document.removeEventListener("visibilitychange",this._handleVisibilityChange),ee.removeEventListener("blur",this._handleWindowBlur),ee.removeEventListener("focus",this._handleWindowFocus),ee.removeEventListener("keydown",this._handleKeyboardEvent),this.clickDetector&&this.clickDetector.removeListeners(),this._performanceCleanupCallback&&this._performanceCleanupCallback()}catch(e){this.handleException(e)}}__init(){this._handleVisibilityChange=()=>{"visible"===ee.document.visibilityState?this._doChangeToForegroundTasks():this._doChangeToBackgroundTasks()}}__init2(){this._handleWindowBlur=()=>{const e=Oe({category:"ui.blur"});this._doChangeToBackgroundTasks(e)}}__init3(){this._handleWindowFocus=()=>{const e=Oe({category:"ui.focus"});this._doChangeToForegroundTasks(e)}}__init4(){this._handleKeyboardEvent=e=>{Sm(this,e)}}_doChangeToBackgroundTasks(e){!this.session||nc(this.session,{maxReplayDuration:this._options.maxReplayDuration,sessionIdleExpire:this.timeouts.sessionIdleExpire})||(e&&this._createCustomBreadcrumb(e),this.conditionalFlush())}_doChangeToForegroundTasks(e){this.session&&(this.checkAndHandleExpiredSession()?e&&this._createCustomBreadcrumb(e):M&&O.info("Document has become active, but session has expired"))}_updateUserActivity(e=Date.now()){this._lastActivity=e}_updateSessionActivity(e=Date.now()){this.session&&(this.session.lastActivity=e,this._maybeSaveSession())}_createCustomBreadcrumb(e){this.addUpdate((()=>{this.throttledAddEvent({type:x.Custom,timestamp:e.timestamp||0,data:{tag:"breadcrumb",payload:e}})}))}_addPerformanceEntries(){let e=wm(this.performanceEntries).concat(this.replayPerformanceEntries);if(this.performanceEntries=[],this.replayPerformanceEntries=[],this._requiresManualStart){const t=this._context.initialTimestamp/1e3;e=e.filter((e=>e.start>=t))}return Promise.all(nr(this,e))}_clearContext(){this._context.errorIds.clear(),this._context.traceIds.clear(),this._context.urls=[]}_updateInitialTimestampFromEventBuffer(){const{session:e,eventBuffer:t}=this;if(!e||!t||this._requiresManualStart||e.segmentId)return;const n=t.getEarliestTimestamp();n&&n<this._context.initialTimestamp&&(this._context.initialTimestamp=n)}_popEventContext(){const e={initialTimestamp:this._context.initialTimestamp,initialUrl:this._context.initialUrl,errorIds:Array.from(this._context.errorIds),traceIds:Array.from(this._context.traceIds),urls:this._context.urls};return this._clearContext(),e}async _runFlush(){const e=this.getSessionId();if(this.session&&this.eventBuffer&&e){if(await this._addPerformanceEntries(),this.eventBuffer&&this.eventBuffer.hasEvents&&(await H_(this),this.eventBuffer&&e===this.getSessionId()))try{this._updateInitialTimestampFromEventBuffer();const t=Date.now();if(t-this._context.initialTimestamp>this._options.maxReplayDuration+3e4)throw new Error("Session is too long, not sending replay");const n=this._popEventContext(),r=this.session.segmentId++;this._maybeSaveSession();const o=await this.eventBuffer.finish();await _c({replayId:e,recordingData:o,segmentId:r,eventContext:n,session:this.session,timestamp:t,onError:e=>this.handleException(e)})}catch(e){this.handleException(e),this.stop({reason:"sendReplay"});const t=ie();if(t){const n=e instanceof Ws?"ratelimit_backoff":"send_error";t.recordDroppedEvent(n,"replay")}}}else M&&O.error("No session or eventBuffer found to flush.")}__init5(){this._flush=async({force:e=!1}={})=>{if(!this._isEnabled&&!e)return;if(!this.checkAndHandleExpiredSession())return void(M&&O.error("Attempting to finish replay event after session expired."));if(!this.session)return;const t=this.session.started,n=Date.now()-t;this._debouncedFlush.cancel();const r=n<this._options.minReplayDuration,o=n>this._options.maxReplayDuration+5e3;if(r||o)return M&&O.info(`Session duration (${Math.floor(n/1e3)}s) is too ${r?"short":"long"}, not sending replay.`),void(r&&this._debouncedFlush());const s=this.eventBuffer;s&&0===this.session.segmentId&&!s.hasCheckout&&M&&O.info("Flushing initial segment without checkout.");const i=!!this._flushLock;this._flushLock||(this._flushLock=this._runFlush());try{await this._flushLock}catch(e){this.handleException(e)}finally{this._flushLock=void 0,i&&this._debouncedFlush()}}}_maybeSaveSession(){this.session&&this._options.stickySession&&$s(this.session)}__init6(){this._onMutationHandler=e=>{const t=e.length,n=this._options.mutationLimit,r=n&&t>n;if(t>this._options.mutationBreadcrumbLimit||r){const e=Oe({category:"replay.mutations",data:{count:t,limit:r}});this._createCustomBreadcrumb(e)}return!r||(this.stop({reason:"mutationLimit",forceFlush:"session"===this.recordingMode}),!1)}}}function xt(e,t){return[...e,...t].join(",")}function eg({mask:e,unmask:t,block:n,unblock:r,ignore:o}){return{maskTextSelector:xt(e,[".sentry-mask","[data-sentry-mask]"]),unmaskTextSelector:xt(t,[]),blockSelector:xt(n,[".sentry-block","[data-sentry-block]","base","iframe[srcdoc]:not([src])"]),unblockSelector:xt(r,[]),ignoreSelector:xt(o,[".sentry-ignore","[data-sentry-ignore]",'input[type="file"]'])}}function tg({el:e,key:t,maskAttributes:n,maskAllText:r,privacyOptions:o,value:s}){return!r||o.unmaskTextSelector&&e.matches(o.unmaskTextSelector)?s:n.includes(t)||"value"===t&&"INPUT"===e.tagName&&["submit","button"].includes(e.getAttribute("type")||"")?s.replace(/[\S]/g,"*"):s}const ii='img,image,svg,video,object,picture,embed,map,audio,link[rel="icon"],link[rel="apple-touch-icon"]',ng=["content-length","content-type","accept"];let ai=!1;const rg=e=>new sr(e);class sr{static __initStatic(){this.id="Replay"}constructor({flushMinDelay:e=xp,flushMaxDelay:t=Np,minReplayDuration:n=Bp,maxReplayDuration:r=jo,stickySession:o=!0,useCompression:s=!0,workerUrl:i,_experiments:a={},maskAllText:c=!0,maskAllInputs:u=!0,blockAllMedia:l=!0,mutationBreadcrumbLimit:d=750,mutationLimit:p=1e4,slowClickTimeout:h=7e3,slowClickIgnoreSelectors:m=[],networkDetailAllowUrls:f=[],networkDetailDenyUrls:y=[],networkCaptureBodies:_=!0,networkRequestHeaders:g=[],networkResponseHeaders:v=[],mask:b=[],maskAttributes:S=["title","placeholder"],unmask:E=[],block:k=[],unblock:w=[],ignore:T=[],maskFn:I,beforeAddRecordingEvent:x,beforeErrorSampling:C,onError:M}={}){this.name=sr.id;const O=eg({mask:b,unmask:E,block:k,unblock:w,ignore:T});if(this._recordingOptions={maskAllInputs:u,maskAllText:c,maskInputOptions:{password:!0},maskTextFn:I,maskInputFn:I,maskAttributeFn:(e,t,n)=>tg({maskAttributes:S,maskAllText:c,privacyOptions:O,key:e,value:t,el:n}),...O,slimDOMOptions:"all",inlineStylesheet:!0,inlineImages:!1,collectFonts:!0,errorHandler:e=>{try{e.__rrweb__=!0}catch{}}},this._initialOptions={flushMinDelay:e,flushMaxDelay:t,minReplayDuration:Math.min(n,$p),maxReplayDuration:Math.min(r,jo),stickySession:o,useCompression:s,workerUrl:i,blockAllMedia:l,maskAllInputs:u,maskAllText:c,mutationBreadcrumbLimit:d,mutationLimit:p,slowClickTimeout:h,slowClickIgnoreSelectors:m,networkDetailAllowUrls:f,networkDetailDenyUrls:y,networkCaptureBodies:_,networkRequestHeaders:ci(g),networkResponseHeaders:ci(v),beforeAddRecordingEvent:x,beforeErrorSampling:C,onError:M,_experiments:a},this._initialOptions.blockAllMedia&&(this._recordingOptions.blockSelector=this._recordingOptions.blockSelector?`${this._recordingOptions.blockSelector},${ii}`:ii),this._isInitialized&&Do())throw new Error("Multiple Sentry Session Replay instances are not supported");this._isInitialized=!0}get _isInitialized(){return ai}set _isInitialized(e){ai=e}afterAllSetup(e){!Do()||this._replay||(this._setup(e),this._initialize(e))}start(){this._replay&&this._replay.start()}startBuffering(){this._replay&&this._replay.startBuffering()}stop(){return this._replay?this._replay.stop({forceFlush:"session"===this._replay.recordingMode}):Promise.resolve()}flush(e){return this._replay?this._replay.isEnabled()?this._replay.sendBufferedReplayOrFlush(e):(this._replay.start(),Promise.resolve()):Promise.resolve()}getReplayId(){if(this._replay&&this._replay.isEnabled())return this._replay.getSessionId()}getRecordingMode(){if(this._replay&&this._replay.isEnabled())return this._replay.recordingMode}_initialize(e){this._replay&&(this._maybeLoadFromReplayCanvasIntegration(e),this._replay.initializeSampling())}_setup(e){const t=sg(this._initialOptions,e);this._replay=new Ye({options:t,recordingOptions:this._recordingOptions})}_maybeLoadFromReplayCanvasIntegration(e){try{const t=e.getIntegrationByName("ReplayCanvas");if(!t)return;this._replay._canvas=t.getOptions()}catch{}}}function sg(e,t){const n=t.getOptions(),r={sessionSampleRate:0,errorSampleRate:0,...he(e)},o=Lr(n.replaysSessionSampleRate),s=Lr(n.replaysOnErrorSampleRate);return null==o&&null==s&&Je((()=>{console.warn("Replay is disabled because neither `replaysSessionSampleRate` nor `replaysOnErrorSampleRate` are set.")})),null!=o&&(r.sessionSampleRate=o),null!=s&&(r.errorSampleRate=s),r}function ci(e){return[...ng,...e.map((e=>e.toLowerCase()))]}function og(e){return e&&e.__esModule&&Object.prototype.hasOwnProperty.call(e,"default")?e.default:e}sr.__initStatic();var ui,li,Tr={exports:{}},N={};
1
+ function Uc(e,t){for(var n=0;n<t.length;n++){const r=t[n];if("string"!=typeof r&&!Array.isArray(r))for(const t in r)if("default"!==t&&!(t in e)){const n=Object.getOwnPropertyDescriptor(r,t);n&&Object.defineProperty(e,t,n.get?n:{enumerable:!0,get:()=>r[t]})}}return Object.freeze(Object.defineProperty(e,Symbol.toStringTag,{value:"Module"}))}const V=typeof __SENTRY_DEBUG__>"u"||__SENTRY_DEBUG__,nt="8.48.0",j=globalThis;function Hn(e,t,n){const r=j,o=r.__SENTRY__=r.__SENTRY__||{},s=o[nt]=o[nt]||{};return s[e]||(s[e]=t())}const ct=typeof __SENTRY_DEBUG__>"u"||__SENTRY_DEBUG__,jc="Sentry Logger ",Or=["debug","info","warn","error","log","assert","trace"],kn={};function Je(e){if(!("console"in j))return e();const t=j.console,n={},r=Object.keys(kn);r.forEach((e=>{const r=kn[e];n[e]=t[e],t[e]=r}));try{return e()}finally{r.forEach((e=>{t[e]=n[e]}))}}function Bc(){let e=!1;const t={enable:()=>{e=!0},disable:()=>{e=!1},isEnabled:()=>e};return ct?Or.forEach((n=>{t[n]=(...t)=>{e&&Je((()=>{j.console[n](`${jc}[${n}]:`,...t)}))}})):Or.forEach((e=>{t[e]=()=>{}})),t}const C=Hn("logger",Bc),Oi=50,rt="?",Xs=/\(error: (.*)\)/,Qs=/captureMessage|captureException/;function Di(...e){const t=e.sort(((e,t)=>e[0]-t[0])).map((e=>e[1]));return(e,n=0,r=0)=>{const o=[],s=e.split("\n");for(let e=n;e<s.length;e++){const n=s[e];if(n.length>1024)continue;const i=Xs.test(n)?n.replace(Xs,"$1"):n;if(!i.match(/\S*Error: /)){for(const e of t){const t=e(i);if(t){o.push(t);break}}if(o.length>=50+r)break}}return Hc(o.slice(r))}}function $c(e){return Array.isArray(e)?Di(...e):e}function Hc(e){if(!e.length)return[];const t=Array.from(e);return/sentryWrapped/.test(an(t).function||"")&&t.pop(),t.reverse(),Qs.test(an(t).function||"")&&(t.pop(),Qs.test(an(t).function||"")&&t.pop()),t.slice(0,50).map((e=>({...e,filename:e.filename||an(t).filename,function:e.function||rt})))}function an(e){return e[e.length-1]||{}}const pr="<anonymous>";function je(e){try{return e&&"function"==typeof e&&e.name||pr}catch{return pr}}function Zs(e){const t=e.exception;if(t){const e=[];try{return t.values.forEach((t=>{t.stacktrace.frames&&e.push(...t.stacktrace.frames)})),e}catch{return}}}const vn={},eo={};function ut(e,t){vn[e]=vn[e]||[],vn[e].push(t)}function lt(e,t){if(!eo[e]){eo[e]=!0;try{t()}catch(t){ct&&C.error(`Error while instrumenting ${e}`,t)}}}function Ce(e,t){const n=e&&vn[e];if(n)for(const r of n)try{r(t)}catch(t){ct&&C.error(`Error while triggering instrumentation handler.\nType: ${e}\nName: ${je(r)}\nError:`,t)}}let hr=null;function zc(e){const t="error";ut(t,e),lt(t,Wc)}function Wc(){hr=j.onerror,j.onerror=function(e,t,n,r,o){return Ce("error",{column:r,error:o,line:n,msg:e,url:t}),!!hr&&hr.apply(this,arguments)},j.onerror.__SENTRY_INSTRUMENTED__=!0}let mr=null;function Gc(e){const t="unhandledrejection";ut(t,e),lt(t,Yc)}function Yc(){mr=j.onunhandledrejection,j.onunhandledrejection=function(e){return Ce("unhandledrejection",e),!mr||mr.apply(this,arguments)},j.onunhandledrejection.__SENTRY_INSTRUMENTED__=!0}function qt(){return ps(j),j}function ps(e){const t=e.__SENTRY__=e.__SENTRY__||{};return t.version=t.version||nt,t[nt]=t[nt]||{}}const Ai=Object.prototype.toString;function hs(e){switch(Ai.call(e)){case"[object Error]":case"[object Exception]":case"[object DOMException]":case"[object WebAssembly.Exception]":return!0;default:return st(e,Error)}}function Dt(e,t){return Ai.call(e)===`[object ${t}]`}function xi(e){return Dt(e,"ErrorEvent")}function to(e){return Dt(e,"DOMError")}function Kc(e){return Dt(e,"DOMException")}function Le(e){return Dt(e,"String")}function ms(e){return"object"==typeof e&&null!==e&&"__sentry_template_string__"in e&&"__sentry_template_values__"in e}function _s(e){return null===e||ms(e)||"object"!=typeof e&&"function"!=typeof e}function St(e){return Dt(e,"Object")}function zn(e){return typeof Event<"u"&&st(e,Event)}function qc(e){return typeof Element<"u"&&st(e,Element)}function Vc(e){return Dt(e,"RegExp")}function Wn(e){return!(!e||!e.then||"function"!=typeof e.then)}function Jc(e){return St(e)&&"nativeEvent"in e&&"preventDefault"in e&&"stopPropagation"in e}function st(e,t){try{return e instanceof t}catch{return!1}}function Ni(e){return!("object"!=typeof e||null===e||!e.__isVue&&!e._isVue)}const gs=j,Xc=80;function Gn(e,t={}){if(!e)return"<unknown>";try{let n=e;const r=5,o=[];let s=0,i=0;const a=" > ",c=a.length;let u;const l=Array.isArray(t)?t:t.keyAttrs,d=!Array.isArray(t)&&t.maxStringLength||80;for(;n&&s++<r&&(u=Qc(n,l),!("html"===u||s>1&&i+o.length*c+u.length>=d));)o.push(u),i+=u.length,n=n.parentNode;return o.reverse().join(a)}catch{return"<unknown>"}}function Qc(e,t){const n=e,r=[];if(!n||!n.tagName)return"";if(gs.HTMLElement&&n instanceof HTMLElement&&n.dataset){if(n.dataset.sentryComponent)return n.dataset.sentryComponent;if(n.dataset.sentryElement)return n.dataset.sentryElement}r.push(n.tagName.toLowerCase());const o=t&&t.length?t.filter((e=>n.getAttribute(e))).map((e=>[e,n.getAttribute(e)])):null;if(o&&o.length)o.forEach((e=>{r.push(`[${e[0]}="${e[1]}"]`)}));else{n.id&&r.push(`#${n.id}`);const e=n.className;if(e&&Le(e)){const t=e.split(/\s+/);for(const e of t)r.push(`.${e}`)}}const s=["aria-label","type","name","title","alt"];for(const e of s){const t=n.getAttribute(e);t&&r.push(`[${e}="${t}"]`)}return r.join("")}function Pi(){try{return gs.document.location.href}catch{return""}}function Zc(e){if(!gs.HTMLElement)return null;let t=e;for(let e=0;e<5;e++){if(!t)return null;if(t instanceof HTMLElement){if(t.dataset.sentryComponent)return t.dataset.sentryComponent;if(t.dataset.sentryElement)return t.dataset.sentryElement}t=t.parentNode}return null}function Et(e,t=0){return"string"!=typeof e||0===t||e.length<=t?e:`${e.slice(0,t)}...`}function no(e,t){if(!Array.isArray(e))return"";const n=[];for(let t=0;t<e.length;t++){const r=e[t];try{Ni(r)?n.push("[VueViewModel]"):n.push(String(r))}catch{n.push("[value cannot be serialized]")}}return n.join(t)}function eu(e,t,n=!1){return!!Le(e)&&(Vc(t)?t.test(e):!!Le(t)&&(n?e===t:e.includes(t)))}function Vt(e,t=[],n=!1){return t.some((t=>eu(e,t,n)))}function pe(e,t,n){if(!(t in e))return;const r=e[t],o=n(r);"function"==typeof o&&Li(o,r);try{e[t]=o}catch{ct&&C.log(`Failed to replace method "${t}" in object`,e)}}function ot(e,t,n){try{Object.defineProperty(e,t,{value:n,writable:!0,configurable:!0})}catch{ct&&C.log(`Failed to add non-enumerable property "${t}" to object`,e)}}function Li(e,t){try{const n=t.prototype||{};e.prototype=t.prototype=n,ot(e,"__sentry_original__",t)}catch{}}function ys(e){return e.__sentry_original__}function Fi(e){if(hs(e))return{message:e.message,name:e.name,stack:e.stack,...so(e)};if(zn(e)){const t={type:e.type,target:ro(e.target),currentTarget:ro(e.currentTarget),...so(e)};return typeof CustomEvent<"u"&&st(e,CustomEvent)&&(t.detail=e.detail),t}return e}function ro(e){try{return qc(e)?Gn(e):Object.prototype.toString.call(e)}catch{return"<unknown>"}}function so(e){if("object"==typeof e&&null!==e){const t={};for(const n in e)Object.prototype.hasOwnProperty.call(e,n)&&(t[n]=e[n]);return t}return{}}function tu(e,t=40){const n=Object.keys(Fi(e));n.sort();const r=n[0];if(!r)return"[object has no keys]";if(r.length>=t)return Et(r,t);for(let e=n.length;e>0;e--){const r=n.slice(0,e).join(", ");if(!(r.length>t))return e===n.length?r:Et(r,t)}return""}function he(e){return Dr(e,new Map)}function Dr(e,t){if(nu(e)){const n=t.get(e);if(void 0!==n)return n;const r={};t.set(e,r);for(const n of Object.getOwnPropertyNames(e))typeof e[n]<"u"&&(r[n]=Dr(e[n],t));return r}if(Array.isArray(e)){const n=t.get(e);if(void 0!==n)return n;const r=[];return t.set(e,r),e.forEach((e=>{r.push(Dr(e,t))})),r}return e}function nu(e){if(!St(e))return!1;try{const t=Object.getPrototypeOf(e).constructor.name;return!t||"Object"===t}catch{return!0}}const Ui=1e3;function Jt(){return Date.now()/Ui}function ru(){const{performance:e}=j;if(!e||!e.now)return Jt;const t=Date.now()-e.now(),n=null==e.timeOrigin?t:e.timeOrigin;return()=>(n+e.now())/Ui}const Fe=ru(),su=(()=>{const{performance:e}=j;if(!e||!e.now)return;const t=36e5,n=e.now(),r=Date.now(),o=e.timeOrigin?Math.abs(e.timeOrigin+n-r):t,s=o<t,i=e.timing&&e.timing.navigationStart,a="number"==typeof i?Math.abs(i+n-r):t;return s||a<t?o<=a?e.timeOrigin:i:r})();function ge(){const e=j,t=e.crypto||e.msCrypto;let n=()=>16*Math.random();try{if(t&&t.randomUUID)return t.randomUUID().replace(/-/g,"");t&&t.getRandomValues&&(n=()=>{const e=new Uint8Array(1);return t.getRandomValues(e),e[0]})}catch{}return"10000000100040008000100000000000".replace(/[018]/g,(e=>(e^(15&n())>>e/4).toString(16)))}function ji(e){return e.exception&&e.exception.values?e.exception.values[0]:void 0}function He(e){const{message:t,event_id:n}=e;if(t)return t;const r=ji(e);return r?r.type&&r.value?`${r.type}: ${r.value}`:r.type||r.value||n||"<unknown>":n||"<unknown>"}function Ar(e,t,n){const r=e.exception=e.exception||{},o=r.values=r.values||[],s=o[0]=o[0]||{};s.value||(s.value=t||""),s.type||(s.type="Error")}function bt(e,t){const n=ji(e);if(!n)return;const r=n.mechanism;if(n.mechanism={type:"generic",handled:!0,...r,...t},t&&"data"in t){const e={...r&&r.data,...t.data};n.mechanism.data=e}}function oo(e){if(ou(e))return!0;try{ot(e,"__sentry_captured__",!0)}catch{}return!1}function ou(e){try{return e.__sentry_captured__}catch{}}var Ne;function Be(e){return new ve((t=>{t(e)}))}function Rn(e){return new ve(((t,n)=>{n(e)}))}!function(e){e[e.PENDING=0]="PENDING";e[e.RESOLVED=1]="RESOLVED";e[e.REJECTED=2]="REJECTED"}(Ne||(Ne={}));class ve{constructor(e){ve.prototype.__init.call(this),ve.prototype.__init2.call(this),ve.prototype.__init3.call(this),ve.prototype.__init4.call(this),this._state=Ne.PENDING,this._handlers=[];try{e(this._resolve,this._reject)}catch(e){this._reject(e)}}then(e,t){return new ve(((n,r)=>{this._handlers.push([!1,t=>{if(e)try{n(e(t))}catch(e){r(e)}else n(t)},e=>{if(t)try{n(t(e))}catch(e){r(e)}else r(e)}]),this._executeHandlers()}))}catch(e){return this.then((e=>e),e)}finally(e){return new ve(((t,n)=>{let r,o;return this.then((t=>{o=!1,r=t,e&&e()}),(t=>{o=!0,r=t,e&&e()})).then((()=>{o?n(r):t(r)}))}))}__init(){this._resolve=e=>{this._setResult(Ne.RESOLVED,e)}}__init2(){this._reject=e=>{this._setResult(Ne.REJECTED,e)}}__init3(){this._setResult=(e,t)=>{if(this._state===Ne.PENDING){if(Wn(t))return void t.then(this._resolve,this._reject);this._state=e,this._value=t,this._executeHandlers()}}}__init4(){this._executeHandlers=()=>{if(this._state===Ne.PENDING)return;const e=this._handlers.slice();this._handlers=[],e.forEach((e=>{e[0]||(this._state===Ne.RESOLVED&&e[1](this._value),this._state===Ne.REJECTED&&e[2](this._value),e[0]=!0)}))}}}function iu(e){const t=Fe(),n={sid:ge(),init:!0,timestamp:t,started:t,duration:0,status:"ok",errors:0,ignoreDuration:!1,toJSON:()=>cu(n)};return vt(n,e),n}function vt(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||Fe(),t.abnormal_mechanism&&(e.abnormal_mechanism=t.abnormal_mechanism),t.ignoreDuration&&(e.ignoreDuration=t.ignoreDuration),t.sid&&(e.sid=32===t.sid.length?t.sid:ge()),void 0!==t.init&&(e.init=t.init),!e.did&&t.did&&(e.did=`${t.did}`),"number"==typeof t.started&&(e.started=t.started),e.ignoreDuration)e.duration=void 0;else if("number"==typeof t.duration)e.duration=t.duration;else{const t=e.timestamp-e.started;e.duration=t>=0?t: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),"number"==typeof t.errors&&(e.errors=t.errors),t.status&&(e.status=t.status)}function au(e,t){let n={};"ok"===e.status&&(n={status:"exited"}),vt(e,n)}function cu(e){return he({sid:`${e.sid}`,init:e.init,started:new Date(1e3*e.started).toISOString(),timestamp:new Date(1e3*e.timestamp).toISOString(),status:e.status,errors:e.errors,did:"number"==typeof e.did||"string"==typeof e.did?`${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}})}function io(){return ge()}function xr(){return ge().substring(16)}function Yn(e,t,n=2){if(!t||"object"!=typeof t||n<=0)return t;if(e&&t&&0===Object.keys(t).length)return e;const r={...e};for(const e in t)Object.prototype.hasOwnProperty.call(t,e)&&(r[e]=Yn(r[e],t[e],n-1));return r}const Nr="_sentrySpan";function ao(e,t){t?ot(e,Nr,t):delete e[Nr]}function Pr(e){return e[Nr]}const uu=100;class Es{constructor(){this._notifyingListeners=!1,this._scopeListeners=[],this._eventProcessors=[],this._breadcrumbs=[],this._attachments=[],this._user={},this._tags={},this._extra={},this._contexts={},this._sdkProcessingMetadata={},this._propagationContext={traceId:io(),spanId:xr()}}clone(){const e=new Es;return e._breadcrumbs=[...this._breadcrumbs],e._tags={...this._tags},e._extra={...this._extra},e._contexts={...this._contexts},this._contexts.flags&&(e._contexts.flags={values:[...this._contexts.flags.values]}),e._user=this._user,e._level=this._level,e._session=this._session,e._transactionName=this._transactionName,e._fingerprint=this._fingerprint,e._eventProcessors=[...this._eventProcessors],e._requestSession=this._requestSession,e._attachments=[...this._attachments],e._sdkProcessingMetadata={...this._sdkProcessingMetadata},e._propagationContext={...this._propagationContext},e._client=this._client,e._lastEventId=this._lastEventId,ao(e,Pr(this)),e}setClient(e){this._client=e}setLastEventId(e){this._lastEventId=e}getClient(){return this._client}lastEventId(){return this._lastEventId}addScopeListener(e){this._scopeListeners.push(e)}addEventProcessor(e){return this._eventProcessors.push(e),this}setUser(e){return this._user=e||{email:void 0,id:void 0,ip_address:void 0,username:void 0},this._session&&vt(this._session,{user:e}),this._notifyScopeListeners(),this}getUser(){return this._user}getRequestSession(){return this._requestSession}setRequestSession(e){return this._requestSession=e,this}setTags(e){return this._tags={...this._tags,...e},this._notifyScopeListeners(),this}setTag(e,t){return this._tags={...this._tags,[e]:t},this._notifyScopeListeners(),this}setExtras(e){return this._extra={...this._extra,...e},this._notifyScopeListeners(),this}setExtra(e,t){return this._extra={...this._extra,[e]:t},this._notifyScopeListeners(),this}setFingerprint(e){return this._fingerprint=e,this._notifyScopeListeners(),this}setLevel(e){return this._level=e,this._notifyScopeListeners(),this}setTransactionName(e){return this._transactionName=e,this._notifyScopeListeners(),this}setContext(e,t){return null===t?delete this._contexts[e]:this._contexts[e]=t,this._notifyScopeListeners(),this}setSession(e){return e?this._session=e:delete this._session,this._notifyScopeListeners(),this}getSession(){return this._session}update(e){if(!e)return this;const t="function"==typeof e?e(this):e,[n,r]=t instanceof it?[t.getScopeData(),t.getRequestSession()]:St(t)?[e,e.requestSession]:[],{tags:o,extra:s,user:i,contexts:a,level:c,fingerprint:u=[],propagationContext:l}=n||{};return this._tags={...this._tags,...o},this._extra={...this._extra,...s},this._contexts={...this._contexts,...a},i&&Object.keys(i).length&&(this._user=i),c&&(this._level=c),u.length&&(this._fingerprint=u),l&&(this._propagationContext=l),r&&(this._requestSession=r),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._session=void 0,ao(this,void 0),this._attachments=[],this.setPropagationContext({traceId:io()}),this._notifyScopeListeners(),this}addBreadcrumb(e,t){const n="number"==typeof t?t:uu;if(n<=0)return this;const r={timestamp:Jt(),...e},o=this._breadcrumbs;return o.push(r),this._breadcrumbs=o.length>n?o.slice(-n):o,this._notifyScopeListeners(),this}getLastBreadcrumb(){return this._breadcrumbs[this._breadcrumbs.length-1]}clearBreadcrumbs(){return this._breadcrumbs=[],this._notifyScopeListeners(),this}addAttachment(e){return this._attachments.push(e),this}clearAttachments(){return this._attachments=[],this}getScopeData(){return{breadcrumbs:this._breadcrumbs,attachments:this._attachments,contexts:this._contexts,tags:this._tags,extra:this._extra,user:this._user,level:this._level,fingerprint:this._fingerprint||[],eventProcessors:this._eventProcessors,propagationContext:this._propagationContext,sdkProcessingMetadata:this._sdkProcessingMetadata,transactionName:this._transactionName,span:Pr(this)}}setSDKProcessingMetadata(e){return this._sdkProcessingMetadata=Yn(this._sdkProcessingMetadata,e,2),this}setPropagationContext(e){return this._propagationContext={spanId:xr(),...e},this}getPropagationContext(){return this._propagationContext}captureException(e,t){const n=t&&t.event_id?t.event_id:ge();if(!this._client)return C.warn("No client configured on scope - will not capture exception!"),n;const r=new Error("Sentry syntheticException");return this._client.captureException(e,{originalException:e,syntheticException:r,...t,event_id:n},this),n}captureMessage(e,t,n){const r=n&&n.event_id?n.event_id:ge();if(!this._client)return C.warn("No client configured on scope - will not capture message!"),r;const o=new Error(e);return this._client.captureMessage(e,t,{originalException:e,syntheticException:o,...n,event_id:r},this),r}captureEvent(e,t){const n=t&&t.event_id?t.event_id:ge();return this._client?(this._client.captureEvent(e,{...t,event_id:n},this),n):(C.warn("No client configured on scope - will not capture event!"),n)}_notifyScopeListeners(){this._notifyingListeners||(this._notifyingListeners=!0,this._scopeListeners.forEach((e=>{e(this)})),this._notifyingListeners=!1)}}const it=Es;function lu(){return Hn("defaultCurrentScope",(()=>new it))}function du(){return Hn("defaultIsolationScope",(()=>new it))}class fu{constructor(e,t){let n,r;n=e||new it,r=t||new it,this._stack=[{scope:n}],this._isolationScope=r}withScope(e){const t=this._pushScope();let n;try{n=e(t)}catch(e){throw this._popScope(),e}return Wn(n)?n.then((e=>(this._popScope(),e)),(e=>{throw this._popScope(),e})):(this._popScope(),n)}getClient(){return this.getStackTop().client}getScope(){return this.getStackTop().scope}getIsolationScope(){return this._isolationScope}getStackTop(){return this._stack[this._stack.length-1]}_pushScope(){const e=this.getScope().clone();return this._stack.push({client:this.getClient(),scope:e}),e}_popScope(){return!(this._stack.length<=1)&&!!this._stack.pop()}}function It(){const e=ps(qt());return e.stack=e.stack||new fu(lu(),du())}function pu(e){return It().withScope(e)}function hu(e,t){const n=It();return n.withScope((()=>(n.getStackTop().scope=e,t(e))))}function co(e){return It().withScope((()=>e(It().getIsolationScope())))}function mu(){return{withIsolationScope:co,withScope:pu,withSetScope:hu,withSetIsolationScope:(e,t)=>co(t),getCurrentScope:()=>It().getScope(),getIsolationScope:()=>It().getIsolationScope()}}function Kn(e){const t=ps(e);return t.acs?t.acs:mu()}function be(){return Kn(qt()).getCurrentScope()}function Ae(){return Kn(qt()).getIsolationScope()}function _u(){return Hn("globalScope",(()=>new it))}function gu(...e){const t=Kn(qt());if(2===e.length){const[n,r]=e;return n?t.withSetScope(n,r):t.withScope(r)}return t.withScope(e[0])}function ie(){return be().getClient()}function yu(e){const t=e.getPropagationContext(),{traceId:n,spanId:r,parentSpanId:o}=t;return he({trace_id:n,span_id:r,parent_span_id:o})}const Eu="_sentryMetrics";function Su(e){const t=e[Eu];if(!t)return;const n={};for(const[,[e,r]]of t)(n[e]||(n[e]=[])).push(he(r));return n}const Bi="sentry.source",bu="sentry.sample_rate",vu="sentry.op",Iu="sentry.origin",wu=0,Tu=1,ku="sentry-",Ru=/^sentry-/;function Cu(e){const t=Mu(e);if(!t)return;const n=Object.entries(t).reduce(((e,[t,n])=>{if(t.match(Ru)){e[t.slice(7)]=n}return e}),{});return Object.keys(n).length>0?n:void 0}function Mu(e){if(e&&(Le(e)||Array.isArray(e)))return Array.isArray(e)?e.reduce(((e,t)=>{const n=uo(t);return Object.entries(n).forEach((([t,n])=>{e[t]=n})),e}),{}):uo(e)}function uo(e){return e.split(",").map((e=>e.split("=").map((e=>decodeURIComponent(e.trim()))))).reduce(((e,[t,n])=>(t&&n&&(e[t]=n),e)),{})}const Ou=1;let lo=!1;function Du(e){const{spanId:t,traceId:n,isRemote:r}=e.spanContext();return he({parent_span_id:r?t:jt(e).parent_span_id,span_id:r?xr():t,trace_id:n})}function fo(e){return"number"==typeof e?po(e):Array.isArray(e)?e[0]+e[1]/1e9:e instanceof Date?po(e.getTime()):Fe()}function po(e){return e>9999999999?e/1e3:e}function jt(e){if(xu(e))return e.getSpanJSON();try{const{spanId:t,traceId:n}=e.spanContext();if(Au(e)){const{attributes:r,startTime:o,name:s,endTime:i,parentSpanId:a,status:c}=e;return he({span_id:t,trace_id:n,data:r,description:s,parent_span_id:a,start_timestamp:fo(o),timestamp:fo(i)||void 0,status:Pu(c),op:r[vu],origin:r[Iu],_metrics_summary:Su(e)})}return{span_id:t,trace_id:n}}catch{return{}}}function Au(e){const t=e;return!!(t.attributes&&t.startTime&&t.name&&t.endTime&&t.status)}function xu(e){return"function"==typeof e.getSpanJSON}function Nu(e){const{traceFlags:t}=e.spanContext();return 1===t}function Pu(e){if(e&&0!==e.code)return 1===e.code?"ok":e.message||"unknown_error"}const Lu="_sentryRootSpan";function Ss(e){return e[Lu]||e}function $i(){const e=Kn(qt());return e.getActiveSpan?e.getActiveSpan():Pr(be())}function Fu(){lo||(Je((()=>{console.warn("[Sentry] Deprecation warning: Returning null from `beforeSendSpan` will be disallowed from SDK version 9.0.0 onwards. The callback will only support mutating spans. To drop certain spans, configure the respective integrations directly.")})),lo=!0)}function Uu(e){if("boolean"==typeof __SENTRY_TRACING__&&!__SENTRY_TRACING__)return!1;const t=ie(),n=t&&t.getOptions();return!!n&&(n.enableTracing||"tracesSampleRate"in n||"tracesSampler"in n)}const bs="production",ju="_frozenDsc";function Hi(e,t){const n=t.getOptions(),{publicKey:r}=t.getDsn()||{},o=he({environment:n.environment||bs,release:n.release,public_key:r,trace_id:e});return t.emit("createDsc",o),o}function Bu(e,t){const n=t.getPropagationContext();return n.dsc||Hi(n.traceId,e)}function zi(e){const t=ie();if(!t)return{};const n=Ss(e),r=n[ju];if(r)return r;const o=n.spanContext().traceState,s=o&&o.get("sentry.dsc"),i=s&&Cu(s);if(i)return i;const a=Hi(e.spanContext().traceId,t),c=jt(n),u=c.data||{},l=u[bu];null!=l&&(a.sample_rate=`${l}`);const d=u[Bi],p=c.description;return"url"!==d&&p&&(a.transaction=p),Uu()&&(a.sampled=String(Nu(n))),t.emit("createDsc",a,n),a}function Lr(e){if("boolean"==typeof e)return Number(e);const t="string"==typeof e?parseFloat(e):e;if(!("number"!=typeof t||isNaN(t)||t<0||t>1))return t;V&&C.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)}.`)}const $u=/^(?:(\w+):)\/\/(?:(\w+)(?::(\w+)?)?@)([\w.-]+)(?::(\d+))?\/(.+)/;function Hu(e){return"http"===e||"https"===e}function qn(e,t=!1){const{host:n,path:r,pass:o,port:s,projectId:i,protocol:a,publicKey:c}=e;return`${a}://${c}${t&&o?`:${o}`:""}@${n}${s?`:${s}`:""}/${r&&`${r}/`}${i}`}function zu(e){const t=$u.exec(e);if(!t)return void Je((()=>{console.error(`Invalid Sentry Dsn: ${e}`)}));const[n,r,o="",s="",i="",a=""]=t.slice(1);let c="",u=a;const l=u.split("/");if(l.length>1&&(c=l.slice(0,-1).join("/"),u=l.pop()),u){const e=u.match(/^\d+/);e&&(u=e[0])}return Wi({host:s,pass:o,path:c,projectId:u,port:i,protocol:n,publicKey:r})}function Wi(e){return{protocol:e.protocol,publicKey:e.publicKey||"",pass:e.pass||"",host:e.host,port:e.port||"",path:e.path||"",projectId:e.projectId}}function Wu(e){if(!ct)return!0;const{port:t,projectId:n,protocol:r}=e;return!["protocol","publicKey","host","projectId"].find((t=>!e[t]&&(C.error(`Invalid Sentry Dsn: ${t} missing`),!0)))&&(n.match(/^\d+$/)?Hu(r)?!t||!isNaN(parseInt(t,10))||(C.error(`Invalid Sentry Dsn: Invalid port ${t}`),!1):(C.error(`Invalid Sentry Dsn: Invalid protocol ${r}`),!1):(C.error(`Invalid Sentry Dsn: Invalid projectId ${n}`),!1))}function Gu(e){const t="string"==typeof e?zu(e):Wi(e);if(t&&Wu(t))return t}function Yu(){const e="function"==typeof WeakSet,t=e?new WeakSet:[];return[function(n){if(e)return!!t.has(n)||(t.add(n),!1);for(let e=0;e<t.length;e++)if(t[e]===n)return!0;return t.push(n),!1},function(n){if(e)t.delete(n);else for(let e=0;e<t.length;e++)if(t[e]===n){t.splice(e,1);break}}]}function Te(e,t=100,n=1/0){try{return Fr("",e,t,n)}catch(e){return{ERROR:`**non-serializable** (${e})`}}}function Gi(e,t=3,n=102400){const r=Te(e,t);return Ju(r)>n?Gi(e,t-1,n):r}function Fr(e,t,n=1/0,r=1/0,o=Yu()){const[s,i]=o;if(null==t||["boolean","string"].includes(typeof t)||"number"==typeof t&&Number.isFinite(t))return t;const a=Ku(e,t);if(!a.startsWith("[object "))return a;if(t.__sentry_skip_normalization__)return t;const c="number"==typeof t.__sentry_override_normalization_depth__?t.__sentry_override_normalization_depth__:n;if(0===c)return a.replace("object ","");if(s(t))return"[Circular ~]";const u=t;if(u&&"function"==typeof u.toJSON)try{return Fr("",u.toJSON(),c-1,r,o)}catch{}const l=Array.isArray(t)?[]:{};let d=0;const p=Fi(t);for(const e in p){if(!Object.prototype.hasOwnProperty.call(p,e))continue;if(d>=r){l[e]="[MaxProperties ~]";break}const t=p[e];l[e]=Fr(e,t,c-1,r,o),d++}return i(t),l}function Ku(e,t){try{if("domain"===e&&t&&"object"==typeof t&&t._events)return"[Domain]";if("domainEmitter"===e)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(Ni(t))return"[VueViewModel]";if(Jc(t))return"[SyntheticEvent]";if("number"==typeof t&&!Number.isFinite(t))return`[${t}]`;if("function"==typeof t)return`[Function: ${je(t)}]`;if("symbol"==typeof t)return`[${String(t)}]`;if("bigint"==typeof t)return`[BigInt: ${String(t)}]`;const n=qu(t);return/^HTML(\w*)Element$/.test(n)?`[HTMLElement: ${n}]`:`[object ${n}]`}catch(e){return`**non-serializable** (${e})`}}function qu(e){const t=Object.getPrototypeOf(e);return t?t.constructor.name:"null prototype"}function Vu(e){return~-encodeURI(e).split(/%..|./).length}function Ju(e){return Vu(JSON.stringify(e))}function At(e,t=[]){return[e,t]}function Xu(e,t){const[n,r]=e;return[n,[...r,t]]}function ho(e,t){const n=e[1];for(const e of n){if(t(e,e[0].type))return!0}return!1}function Ur(e){return j.__SENTRY__&&j.__SENTRY__.encodePolyfill?j.__SENTRY__.encodePolyfill(e):(new TextEncoder).encode(e)}function Qu(e){const[t,n]=e;let r=JSON.stringify(t);function o(e){"string"==typeof r?r="string"==typeof e?r+e:[Ur(r),e]:r.push("string"==typeof e?Ur(e):e)}for(const e of n){const[t,n]=e;if(o(`\n${JSON.stringify(t)}\n`),"string"==typeof n||n instanceof Uint8Array)o(n);else{let e;try{e=JSON.stringify(n)}catch{e=JSON.stringify(Te(n))}o(e)}}return"string"==typeof r?r:Zu(r)}function Zu(e){const t=e.reduce(((e,t)=>e+t.length),0),n=new Uint8Array(t);let r=0;for(const t of e)n.set(t,r),r+=t.length;return n}function el(e){const t="string"==typeof e.data?Ur(e.data):e.data;return[he({type:"attachment",length:t.length,filename:e.filename,content_type:e.contentType,attachment_type:e.attachmentType}),t]}const tl={session:"session",sessions:"session",attachment:"attachment",transaction:"transaction",event:"error",client_report:"internal",user_report:"default",profile:"profile",profile_chunk:"profile",replay_event:"replay",replay_recording:"replay",check_in:"monitor",feedback:"feedback",span:"span",statsd:"metric_bucket",raw_security:"security"};function mo(e){return tl[e]}function vs(e){if(!e||!e.sdk)return;const{name:t,version:n}=e.sdk;return{name:t,version:n}}function Yi(e,t,n,r){const o=e.sdkProcessingMetadata&&e.sdkProcessingMetadata.dynamicSamplingContext;return{event_id:e.event_id,sent_at:(new Date).toISOString(),...t&&{sdk:t},...!!n&&r&&{dsn:qn(r)},...o&&{trace:he({...o})}}}function nl(e,t){return t&&(e.sdk=e.sdk||{},e.sdk.name=e.sdk.name||t.name,e.sdk.version=e.sdk.version||t.version,e.sdk.integrations=[...e.sdk.integrations||[],...t.integrations||[]],e.sdk.packages=[...e.sdk.packages||[],...t.packages||[]]),e}function rl(e,t,n,r){const o=vs(n);return At({sent_at:(new Date).toISOString(),...o&&{sdk:o},...!!r&&t&&{dsn:qn(t)}},["aggregates"in e?[{type:"sessions"},e]:[{type:"session"},e.toJSON()]])}function sl(e,t,n,r){const o=vs(n),s=e.type&&"replay_event"!==e.type?e.type:"event";nl(e,n&&n.sdk);const i=Yi(e,o,r,t);return delete e.sdkProcessingMetadata,At(i,[[{type:s},e]])}function jr(e,t,n,r=0){return new ve(((o,s)=>{const i=e[r];if(null===t||"function"!=typeof i)o(t);else{const a=i({...t},n);V&&i.id&&null===a&&C.log(`Event processor "${i.id}" dropped event`),Wn(a)?a.then((t=>jr(e,t,n,r+1).then(o))).then(null,s):jr(e,a,n,r+1).then(o).then(null,s)}}))}let cn,_o,un;function ol(e){const t=j._sentryDebugIds;if(!t)return{};const n=Object.keys(t);return un&&n.length===_o||(_o=n.length,un=n.reduce(((n,r)=>{cn||(cn={});const o=cn[r];if(o)n[o[0]]=o[1];else{const o=e(r);for(let e=o.length-1;e>=0;e--){const s=o[e],i=s&&s.filename,a=t[r];if(i&&a){n[i]=a,cn[r]=[i,a];break}}}return n}),{})),un}function il(e,t){const{fingerprint:n,span:r,breadcrumbs:o,sdkProcessingMetadata:s}=t;al(e,t),r&&ll(e,r),dl(e,n),cl(e,o),ul(e,s)}function go(e,t){const{extra:n,tags:r,user:o,contexts:s,level:i,sdkProcessingMetadata:a,breadcrumbs:c,fingerprint:u,eventProcessors:l,attachments:d,propagationContext:p,transactionName:h,span:m}=t;ln(e,"extra",n),ln(e,"tags",r),ln(e,"user",o),ln(e,"contexts",s),e.sdkProcessingMetadata=Yn(e.sdkProcessingMetadata,a,2),i&&(e.level=i),h&&(e.transactionName=h),m&&(e.span=m),c.length&&(e.breadcrumbs=[...e.breadcrumbs,...c]),u.length&&(e.fingerprint=[...e.fingerprint,...u]),l.length&&(e.eventProcessors=[...e.eventProcessors,...l]),d.length&&(e.attachments=[...e.attachments,...d]),e.propagationContext={...e.propagationContext,...p}}function ln(e,t,n){e[t]=Yn(e[t],n,1)}function al(e,t){const{extra:n,tags:r,user:o,contexts:s,level:i,transactionName:a}=t,c=he(n);c&&Object.keys(c).length&&(e.extra={...c,...e.extra});const u=he(r);u&&Object.keys(u).length&&(e.tags={...u,...e.tags});const l=he(o);l&&Object.keys(l).length&&(e.user={...l,...e.user});const d=he(s);d&&Object.keys(d).length&&(e.contexts={...d,...e.contexts}),i&&(e.level=i),a&&"transaction"!==e.type&&(e.transaction=a)}function cl(e,t){const n=[...e.breadcrumbs||[],...t];e.breadcrumbs=n.length?n:void 0}function ul(e,t){e.sdkProcessingMetadata={...e.sdkProcessingMetadata,...t}}function ll(e,t){e.contexts={trace:Du(t),...e.contexts},e.sdkProcessingMetadata={dynamicSamplingContext:zi(t),...e.sdkProcessingMetadata};const n=jt(Ss(t)).description;n&&!e.transaction&&"transaction"===e.type&&(e.transaction=n)}function dl(e,t){e.fingerprint=e.fingerprint?Array.isArray(e.fingerprint)?e.fingerprint:[e.fingerprint]:[],t&&(e.fingerprint=e.fingerprint.concat(t)),e.fingerprint&&!e.fingerprint.length&&delete e.fingerprint}function Ki(e,t,n,r,o,s){const{normalizeDepth:i=3,normalizeMaxBreadth:a=1e3}=e,c={...t,event_id:t.event_id||n.event_id||ge(),timestamp:t.timestamp||Jt()},u=n.integrations||e.integrations.map((e=>e.name));fl(c,e),ml(c,u),o&&o.emit("applyFrameMetadata",t),void 0===t.type&&pl(c,e.stackParser);const l=gl(r,n.captureContext);n.mechanism&&bt(c,n.mechanism);const d=o?o.getEventProcessors():[],p=_u().getScopeData();if(s){go(p,s.getScopeData())}if(l){go(p,l.getScopeData())}const h=[...n.attachments||[],...p.attachments];h.length&&(n.attachments=h),il(c,p);return jr([...d,...p.eventProcessors],c,n).then((e=>(e&&hl(e),"number"==typeof i&&i>0?_l(e,i,a):e)))}function fl(e,t){const{environment:n,release:r,dist:o,maxValueLength:s=250}=t;e.environment=e.environment||n||bs,!e.release&&r&&(e.release=r),!e.dist&&o&&(e.dist=o),e.message&&(e.message=Et(e.message,s));const i=e.exception&&e.exception.values&&e.exception.values[0];i&&i.value&&(i.value=Et(i.value,s));const a=e.request;a&&a.url&&(a.url=Et(a.url,s))}function pl(e,t){const n=ol(t);try{e.exception.values.forEach((e=>{e.stacktrace.frames.forEach((e=>{n&&e.filename&&(e.debug_id=n[e.filename])}))}))}catch{}}function hl(e){const t={};try{e.exception.values.forEach((e=>{e.stacktrace.frames.forEach((e=>{e.debug_id&&(e.abs_path?t[e.abs_path]=e.debug_id:e.filename&&(t[e.filename]=e.debug_id),delete e.debug_id)}))}))}catch{}if(0===Object.keys(t).length)return;e.debug_meta=e.debug_meta||{},e.debug_meta.images=e.debug_meta.images||[];const n=e.debug_meta.images;Object.entries(t).forEach((([e,t])=>{n.push({type:"sourcemap",code_file:e,debug_id:t})}))}function ml(e,t){t.length>0&&(e.sdk=e.sdk||{},e.sdk.integrations=[...e.sdk.integrations||[],...t])}function _l(e,t,n){if(!e)return null;const r={...e,...e.breadcrumbs&&{breadcrumbs:e.breadcrumbs.map((e=>({...e,...e.data&&{data:Te(e.data,t,n)}})))},...e.user&&{user:Te(e.user,t,n)},...e.contexts&&{contexts:Te(e.contexts,t,n)},...e.extra&&{extra:Te(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=Te(e.contexts.trace.data,t,n))),e.spans&&(r.spans=e.spans.map((e=>({...e,...e.data&&{data:Te(e.data,t,n)}})))),e.contexts&&e.contexts.flags&&r.contexts&&(r.contexts.flags=Te(e.contexts.flags,3,n)),r}function gl(e,t){if(!t)return e;const n=e?e.clone():new it;return n.update(t),n}function Is(e,t){return be().captureException(e,void 0)}function yl(e,t){const n={captureContext:t};return be().captureMessage(e,void 0,n)}function qi(e,t){return be().captureEvent(e,t)}function Vi(e,t){Ae().setContext(e,t)}function El(e,t){Ae().setExtra(e,t)}function Sl(e){Ae().setUser(e)}function bl(e){Ae().addEventProcessor(e)}function yo(e){const t=ie(),n=Ae(),r=be(),{release:o,environment:s=bs}=t&&t.getOptions()||{},{userAgent:i}=j.navigator||{},a=iu({release:o,environment:s,user:r.getUser()||n.getUser(),...i&&{userAgent:i},...e}),c=n.getSession();return c&&"ok"===c.status&&vt(c,{status:"exited"}),Ji(),n.setSession(a),r.setSession(a),a}function Ji(){const e=Ae(),t=be(),n=t.getSession()||e.getSession();n&&au(n),Xi(),e.setSession(),t.setSession()}function Xi(){const e=Ae(),t=be(),n=ie(),r=t.getSession()||e.getSession();r&&n&&n.captureSession(r)}function Eo(e=!1){e?Ji():Xi()}const vl="7";function Il(e){const t=e.protocol?`${e.protocol}:`:"",n=e.port?`:${e.port}`:"";return`${t}//${e.host}${n}${e.path?`/${e.path}`:""}/api/`}function wl(e){return`${Il(e)}${e.projectId}/envelope/`}function Tl(e,t){const n={sentry_version:vl};return e.publicKey&&(n.sentry_key=e.publicKey),t&&(n.sentry_client=`${t.name}/${t.version}`),new URLSearchParams(n).toString()}function kl(e,t,n){return t||`${wl(e)}?${Tl(e,n)}`}const So=[];function Rl(e){const t={};return e.forEach((e=>{const{name:n}=e,r=t[n];r&&!r.isDefaultInstance&&e.isDefaultInstance||(t[n]=e)})),Object.values(t)}function Cl(e){const t=e.defaultIntegrations||[],n=e.integrations;let r;if(t.forEach((e=>{e.isDefaultInstance=!0})),Array.isArray(n))r=[...t,...n];else if("function"==typeof n){const e=n(t);r=Array.isArray(e)?e:[e]}else r=t;const o=Rl(r),s=o.findIndex((e=>"Debug"===e.name));if(s>-1){const[e]=o.splice(s,1);o.push(e)}return o}function Ml(e,t){const n={};return t.forEach((t=>{t&&Qi(e,t,n)})),n}function bo(e,t){for(const n of t)n&&n.afterAllSetup&&n.afterAllSetup(e)}function Qi(e,t,n){if(n[t.name])V&&C.log(`Integration skipped because it was already installed: ${t.name}`);else{if(n[t.name]=t,-1===So.indexOf(t.name)&&"function"==typeof t.setupOnce&&(t.setupOnce(),So.push(t.name)),t.setup&&"function"==typeof t.setup&&t.setup(e),"function"==typeof t.preprocessEvent){const n=t.preprocessEvent.bind(t);e.on("preprocessEvent",((t,r)=>n(t,r,e)))}if("function"==typeof t.processEvent){const n=t.processEvent.bind(t),r=Object.assign(((t,r)=>n(t,r,e)),{id:t.name});e.addEventProcessor(r)}V&&C.log(`Integration installed: ${t.name}`)}}function Ol(e,t,n){return At(t?{dsn:t}:{},[[{type:"client_report"},{timestamp:Jt(),discarded_events:e}]])}class Me extends Error{constructor(e,t="warn"){super(e),this.message=e,this.name=new.target.prototype.constructor.name,Object.setPrototypeOf(this,new.target.prototype),this.logLevel=t}}const vo="Not capturing exception because it's already been captured.";class Dl{constructor(e){if(this._options=e,this._integrations={},this._numProcessing=0,this._outcomes={},this._hooks={},this._eventProcessors=[],e.dsn?this._dsn=Gu(e.dsn):V&&C.warn("No DSN provided, client will not send events."),this._dsn){const t=kl(this._dsn,e.tunnel,e._metadata?e._metadata.sdk:void 0);this._transport=e.transport({tunnel:this._options.tunnel,recordDroppedEvent:this.recordDroppedEvent.bind(this),...e.transportOptions,url:t})}const t=["enableTracing","tracesSampleRate","tracesSampler"].find((t=>t in e&&null==e[t]));t&&Je((()=>{console.warn(`[Sentry] Deprecation warning: \`${t}\` is set to undefined, which leads to tracing being enabled. In v9, a value of \`undefined\` will result in tracing being disabled.`)}))}captureException(e,t,n){const r=ge();if(oo(e))return V&&C.log(vo),r;const o={event_id:r,...t};return this._process(this.eventFromException(e,o).then((e=>this._captureEvent(e,o,n)))),o.event_id}captureMessage(e,t,n,r){const o={event_id:ge(),...n},s=ms(e)?e:String(e),i=_s(e)?this.eventFromMessage(s,t,o):this.eventFromException(e,o);return this._process(i.then((e=>this._captureEvent(e,o,r)))),o.event_id}captureEvent(e,t,n){const r=ge();if(t&&t.originalException&&oo(t.originalException))return V&&C.log(vo),r;const o={event_id:r,...t},s=(e.sdkProcessingMetadata||{}).capturedSpanScope;return this._process(this._captureEvent(e,o,s||n)),o.event_id}captureSession(e){"string"!=typeof e.release?V&&C.warn("Discarded session because of missing or non-string release"):(this.sendSession(e),vt(e,{init:!1}))}getDsn(){return this._dsn}getOptions(){return this._options}getSdkMetadata(){return this._options._metadata}getTransport(){return this._transport}flush(e){const t=this._transport;return t?(this.emit("flush"),this._isClientDoneProcessing(e).then((n=>t.flush(e).then((e=>n&&e))))):Be(!0)}close(e){return this.flush(e).then((e=>(this.getOptions().enabled=!1,this.emit("close"),e)))}getEventProcessors(){return this._eventProcessors}addEventProcessor(e){this._eventProcessors.push(e)}init(){(this._isEnabled()||this._options.integrations.some((({name:e})=>e.startsWith("Spotlight"))))&&this._setupIntegrations()}getIntegrationByName(e){return this._integrations[e]}addIntegration(e){const t=this._integrations[e.name];Qi(this,e,this._integrations),t||bo(this,[e])}sendEvent(e,t={}){this.emit("beforeSendEvent",e,t);let n=sl(e,this._dsn,this._options._metadata,this._options.tunnel);for(const e of t.attachments||[])n=Xu(n,el(e));const r=this.sendEnvelope(n);r&&r.then((t=>this.emit("afterSendEvent",e,t)),null)}sendSession(e){const t=rl(e,this._dsn,this._options._metadata,this._options.tunnel);this.sendEnvelope(t)}recordDroppedEvent(e,t,n){if(this._options.sendClientReports){const r="number"==typeof n?n:1,o=`${e}:${t}`;V&&C.log(`Recording outcome: "${o}"${r>1?` (${r} times)`:""}`),this._outcomes[o]=(this._outcomes[o]||0)+r}}on(e,t){const n=this._hooks[e]=this._hooks[e]||[];return n.push(t),()=>{const e=n.indexOf(t);e>-1&&n.splice(e,1)}}emit(e,...t){const n=this._hooks[e];n&&n.forEach((e=>e(...t)))}sendEnvelope(e){return this.emit("beforeEnvelope",e),this._isEnabled()&&this._transport?this._transport.send(e).then(null,(e=>(V&&C.error("Error while sending envelope:",e),e))):(V&&C.error("Transport disabled"),Be({}))}_setupIntegrations(){const{integrations:e}=this._options;this._integrations=Ml(this,e),bo(this,e)}_updateSessionFromEvent(e,t){let n=!1,r=!1;const o=t.exception&&t.exception.values;if(o){r=!0;for(const e of o){const t=e.mechanism;if(t&&!1===t.handled){n=!0;break}}}const s="ok"===e.status;(s&&0===e.errors||s&&n)&&(vt(e,{...n&&{status:"crashed"},errors:e.errors||Number(r||n)}),this.captureSession(e))}_isClientDoneProcessing(e){return new ve((t=>{let n=0;const r=setInterval((()=>{0==this._numProcessing?(clearInterval(r),t(!0)):(n+=1,e&&n>=e&&(clearInterval(r),t(!1)))}),1)}))}_isEnabled(){return!1!==this.getOptions().enabled&&void 0!==this._transport}_prepareEvent(e,t,n=be(),r=Ae()){const o=this.getOptions(),s=Object.keys(this._integrations);return!t.integrations&&s.length>0&&(t.integrations=s),this.emit("preprocessEvent",e,t),e.type||r.setLastEventId(e.event_id||t.event_id),Ki(o,e,t,n,this,r).then((e=>{if(null===e)return e;e.contexts={trace:yu(n),...e.contexts};const t=Bu(this,n);return e.sdkProcessingMetadata={dynamicSamplingContext:t,...e.sdkProcessingMetadata},e}))}_captureEvent(e,t={},n){return this._processEvent(e,t,n).then((e=>e.event_id),(e=>{if(V){const t=e;"log"===t.logLevel?C.log(t.message):C.warn(t)}}))}_processEvent(e,t,n){const r=this.getOptions(),{sampleRate:o}=r,s=ea(e),i=Zi(e),a=e.type||"error",c=`before send for type \`${a}\``,u=typeof o>"u"?void 0:Lr(o);if(i&&"number"==typeof u&&Math.random()>u)return this.recordDroppedEvent("sample_rate","error",e),Rn(new Me(`Discarding event because it's not included in the random sample (sampling rate = ${o})`,"log"));const l="replay_event"===a?"replay":a,d=(e.sdkProcessingMetadata||{}).capturedSpanIsolationScope;return this._prepareEvent(e,t,n,d).then((n=>{if(null===n)throw this.recordDroppedEvent("event_processor",l,e),new Me("An event processor returned `null`, will not send event.","log");if(t.data&&!0===t.data.__sentry__)return n;return Al(xl(this,r,n,t),c)})).then((r=>{if(null===r){if(this.recordDroppedEvent("before_send",l,e),s){const t=1+(e.spans||[]).length;this.recordDroppedEvent("before_send","span",t)}throw new Me(`${c} returned \`null\`, will not send event.`,"log")}const o=n&&n.getSession();if(!s&&o&&this._updateSessionFromEvent(o,r),s){const e=(r.sdkProcessingMetadata&&r.sdkProcessingMetadata.spanCountBeforeProcessing||0)-(r.spans?r.spans.length:0);e>0&&this.recordDroppedEvent("before_send","span",e)}const i=r.transaction_info;if(s&&i&&r.transaction!==e.transaction){const e="custom";r.transaction_info={...i,source:e}}return this.sendEvent(r,t),r})).then(null,(e=>{throw e instanceof Me?e:(this.captureException(e,{data:{__sentry__:!0},originalException:e}),new Me(`Event processing pipeline threw an error, original event will not be sent. Details have been sent as a new event.\nReason: ${e}`))}))}_process(e){this._numProcessing++,e.then((e=>(this._numProcessing--,e)),(e=>(this._numProcessing--,e)))}_clearOutcomes(){const e=this._outcomes;return this._outcomes={},Object.entries(e).map((([e,t])=>{const[n,r]=e.split(":");return{reason:n,category:r,quantity:t}}))}_flushOutcomes(){V&&C.log("Flushing outcomes...");const e=this._clearOutcomes();if(0===e.length)return void(V&&C.log("No outcomes to send"));if(!this._dsn)return void(V&&C.log("No dsn provided, will not send outcomes"));V&&C.log("Sending outcomes:",e);const t=Ol(e,this._options.tunnel&&qn(this._dsn));this.sendEnvelope(t)}}function Al(e,t){const n=`${t} must return \`null\` or a valid event.`;if(Wn(e))return e.then((e=>{if(!St(e)&&null!==e)throw new Me(n);return e}),(e=>{throw new Me(`${t} rejected with ${e}`)}));if(!St(e)&&null!==e)throw new Me(n);return e}function xl(e,t,n,r){const{beforeSend:o,beforeSendTransaction:s,beforeSendSpan:i}=t;if(Zi(n)&&o)return o(n,r);if(ea(n)){if(n.spans&&i){const t=[];for(const r of n.spans){const n=i(r);n?t.push(n):(Fu(),e.recordDroppedEvent("before_send","span"))}n.spans=t}if(s){if(n.spans){const e=n.spans.length;n.sdkProcessingMetadata={...n.sdkProcessingMetadata,spanCountBeforeProcessing:e}}return s(n,r)}}return n}function Zi(e){return void 0===e.type}function ea(e){return"transaction"===e.type}function Nl(e,t){!0===t.debug&&(V?C.enable():Je((()=>{console.warn("[Sentry] Cannot initialize SDK with `debug` option using a non-debug bundle.")}))),be().update(t.initialScope);const n=new e(t);return Pl(n),n.init(),n}function Pl(e){be().setClient(e)}function Ll(e){const t=[];function n(e){return t.splice(t.indexOf(e),1)[0]||Promise.resolve(void 0)}return{$:t,add:function(r){if(!(void 0===e||t.length<e))return Rn(new Me("Not adding Promise because buffer limit was reached."));const o=r();return-1===t.indexOf(o)&&t.push(o),o.then((()=>n(o))).then(null,(()=>n(o).then(null,(()=>{})))),o},drain:function(e){return new ve(((n,r)=>{let o=t.length;if(!o)return n(!0);const s=setTimeout((()=>{e&&e>0&&n(!1)}),e);t.forEach((e=>{Be(e).then((()=>{--o||(clearTimeout(s),n(!0))}),r)}))}))}}}const Fl=6e4;function Ul(e,t=Date.now()){const n=parseInt(`${e}`,10);if(!isNaN(n))return 1e3*n;const r=Date.parse(`${e}`);return isNaN(r)?Fl:r-t}function jl(e,t){return e[t]||e.all||0}function ta(e,t,n=Date.now()){return jl(e,t)>n}function na(e,{statusCode:t,headers:n},r=Date.now()){const o={...e},s=n&&n["x-sentry-rate-limits"],i=n&&n["retry-after"];if(s)for(const e of s.trim().split(",")){const[t,n,,,s]=e.split(":",5),i=parseInt(t,10),a=1e3*(isNaN(i)?60:i);if(n)for(const e of n.split(";"))"metric_bucket"===e?(!s||s.split(";").includes("custom"))&&(o[e]=r+a):o[e]=r+a;else o.all=r+a}else i?o.all=r+Ul(i,r):429===t&&(o.all=r+6e4);return o}const Bl=64;function $l(e,t,n=Ll(e.bufferSize||64)){let r={};return{send:function(o){const s=[];if(ho(o,((t,n)=>{const o=mo(n);if(ta(r,o)){const r=Io(t,n);e.recordDroppedEvent("ratelimit_backoff",o,r)}else s.push(t)})),0===s.length)return Be({});const i=At(o[0],s),a=t=>{ho(i,((n,r)=>{const o=Io(n,r);e.recordDroppedEvent(t,mo(r),o)}))};return n.add((()=>t({body:Qu(i)}).then((e=>(void 0!==e.statusCode&&(e.statusCode<200||e.statusCode>=300)&&V&&C.warn(`Sentry responded with status code ${e.statusCode} to sent event.`),r=na(r,e),e)),(e=>{throw a("network_error"),e})))).then((e=>e),(e=>{if(e instanceof Me)return V&&C.error("Skipped sending event because buffer is full."),a("queue_overflow"),Be({});throw e}))},flush:e=>n.drain(e)}}function Io(e,t){if("event"===t||"transaction"===t)return Array.isArray(e)?e[1]:void 0}function Hl(e,t){const n=t&&t.getDsn(),r=t&&t.getOptions().tunnel;return Wl(e,n)||zl(e,r)}function zl(e,t){return!!t&&wo(e)===wo(t)}function Wl(e,t){return!!t&&e.includes(t.host)}function wo(e){return"/"===e[e.length-1]?e.slice(0,-1):e}function ra(e,t,n=[t],r="npm"){const o=e._metadata||{};o.sdk||(o.sdk={name:`sentry.javascript.${t}`,packages:n.map((e=>({name:`${r}:@sentry/${e}`,version:nt}))),version:nt}),e._metadata=o}const Gl=100;function qe(e,t){const n=ie(),r=Ae();if(!n)return;const{beforeBreadcrumb:o=null,maxBreadcrumbs:s=Gl}=n.getOptions();if(s<=0)return;const i={timestamp:Jt(),...e},a=o?Je((()=>o(i,t))):i;null!==a&&(n.emit&&n.emit("beforeAddBreadcrumb",a,t),r.addBreadcrumb(a,s))}let To;const Yl="FunctionToString",ko=new WeakMap,Kl=()=>({name:Yl,setupOnce(){To=Function.prototype.toString;try{Function.prototype.toString=function(...e){const t=ys(this),n=ko.has(ie())&&void 0!==t?t:this;return To.apply(n,e)}}catch{}},setup(e){ko.set(e,!0)}}),ql=Kl,Vl=[/^Script error\.?$/,/^Javascript error: Script error\.? on line 0$/,/^ResizeObserver loop completed with undelivered notifications.$/,/^Cannot redefine property: googletag$/,"undefined is not an object (evaluating 'a.L')",'can\'t redefine non-configurable property "solana"',"vv().getRestrictions is not a function. (In 'vv().getRestrictions(1,a)', 'vv().getRestrictions' is undefined)","Can't find variable: _AutofillCallbackHandler",/^Non-Error promise rejection captured with value: Object Not Found Matching Id:\d+, MethodName:simulateEvent, ParamCount:\d+$/],Jl="InboundFilters",Xl=(e={})=>({name:Jl,processEvent(t,n,r){const o=r.getOptions();return ed(t,Zl(e,o))?null:t}}),Ql=Xl;function Zl(e={},t={}){return{allowUrls:[...e.allowUrls||[],...t.allowUrls||[]],denyUrls:[...e.denyUrls||[],...t.denyUrls||[]],ignoreErrors:[...e.ignoreErrors||[],...t.ignoreErrors||[],...e.disableErrorDefaults?[]:Vl],ignoreTransactions:[...e.ignoreTransactions||[],...t.ignoreTransactions||[]],ignoreInternal:void 0===e.ignoreInternal||e.ignoreInternal}}function ed(e,t){return t.ignoreInternal&&id(e)?(V&&C.warn(`Event dropped due to being internal Sentry Error.\nEvent: ${He(e)}`),!0):td(e,t.ignoreErrors)?(V&&C.warn(`Event dropped due to being matched by \`ignoreErrors\` option.\nEvent: ${He(e)}`),!0):cd(e)?(V&&C.warn(`Event dropped due to not having an error message, error type or stacktrace.\nEvent: ${He(e)}`),!0):nd(e,t.ignoreTransactions)?(V&&C.warn(`Event dropped due to being matched by \`ignoreTransactions\` option.\nEvent: ${He(e)}`),!0):rd(e,t.denyUrls)?(V&&C.warn(`Event dropped due to being matched by \`denyUrls\` option.\nEvent: ${He(e)}.\nUrl: ${Cn(e)}`),!0):!sd(e,t.allowUrls)&&(V&&C.warn(`Event dropped due to not being matched by \`allowUrls\` option.\nEvent: ${He(e)}.\nUrl: ${Cn(e)}`),!0)}function td(e,t){return!(e.type||!t||!t.length)&&od(e).some((e=>Vt(e,t)))}function nd(e,t){if("transaction"!==e.type||!t||!t.length)return!1;const n=e.transaction;return!!n&&Vt(n,t)}function rd(e,t){if(!t||!t.length)return!1;const n=Cn(e);return!!n&&Vt(n,t)}function sd(e,t){if(!t||!t.length)return!0;const n=Cn(e);return!n||Vt(n,t)}function od(e){const t=[];let n;e.message&&t.push(e.message);try{n=e.exception.values[e.exception.values.length-1]}catch{}return n&&n.value&&(t.push(n.value),n.type&&t.push(`${n.type}: ${n.value}`)),t}function id(e){try{return"SentryError"===e.exception.values[0].type}catch{}return!1}function ad(e=[]){for(let t=e.length-1;t>=0;t--){const n=e[t];if(n&&"<anonymous>"!==n.filename&&"[native code]"!==n.filename)return n.filename||null}return null}function Cn(e){try{let t;try{t=e.exception.values[0].stacktrace.frames}catch{}return t?ad(t):null}catch{return V&&C.error(`Cannot extract url for event ${He(e)}`),null}}function cd(e){return!(e.type||!e.exception||!e.exception.values||0===e.exception.values.length)&&(!e.message&&!e.exception.values.some((e=>e.stacktrace||e.type&&"Error"!==e.type||e.value)))}function ud(e,t,n=250,r,o,s,i){if(!(s.exception&&s.exception.values&&i&&st(i.originalException,Error)))return;const a=s.exception.values.length>0?s.exception.values[s.exception.values.length-1]:void 0;a&&(s.exception.values=ld(Br(e,t,o,i.originalException,r,s.exception.values,a,0),n))}function Br(e,t,n,r,o,s,i,a){if(s.length>=n+1)return s;let c=[...s];if(st(r[o],Error)){Ro(i,a);const s=e(t,r[o]),u=c.length;Co(s,o,u,a),c=Br(e,t,n,r[o],o,[s,...c],s,u)}return Array.isArray(r.errors)&&r.errors.forEach(((r,s)=>{if(st(r,Error)){Ro(i,a);const u=e(t,r),l=c.length;Co(u,`errors[${s}]`,l,a),c=Br(e,t,n,r,o,[u,...c],u,l)}})),c}function Ro(e,t){e.mechanism=e.mechanism||{type:"generic",handled:!0},e.mechanism={...e.mechanism,..."AggregateError"===e.type&&{is_exception_group:!0},exception_id:t}}function Co(e,t,n,r){e.mechanism=e.mechanism||{type:"generic",handled:!0},e.mechanism={...e.mechanism,type:"chained",source:t,exception_id:n,parent_id:r}}function ld(e,t){return e.map((e=>(e.value&&(e.value=Et(e.value,t)),e)))}function _r(e){if(!e)return{};const t=e.match(/^(([^:/?#]+):)?(\/\/([^/?#]*))?([^?#]*)(\?([^#]*))?(#(.*))?$/);if(!t)return{};const 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 dd(e){const t="console";ut(t,e),lt(t,fd)}function fd(){"console"in j&&Or.forEach((function(e){e in j.console&&pe(j.console,e,(function(t){return kn[e]=t,function(...t){Ce("console",{args:t,level:e});const n=kn[e];n&&n.apply(j.console,t)}}))}))}function sa(e){return"warn"===e?"warning":["fatal","error","warning","log","info","debug"].includes(e)?e:"log"}const pd="Dedupe",hd=()=>{let e;return{name:pd,processEvent(t){if(t.type)return t;try{if(md(t,e))return V&&C.warn("Event dropped due to being a duplicate of previously captured event."),null}catch{}return e=t}}},oa=hd;function md(e,t){return!!t&&!(!_d(e,t)&&!gd(e,t))}function _d(e,t){const n=e.message,r=t.message;return!(!n&&!r||n&&!r||!n&&r||n!==r||!aa(e,t)||!ia(e,t))}function gd(e,t){const n=Mo(t),r=Mo(e);return!!(n&&r&&n.type===r.type&&n.value===r.value&&aa(e,t)&&ia(e,t))}function ia(e,t){let n=Zs(e),r=Zs(t);if(!n&&!r)return!0;if(n&&!r||!n&&r||r.length!==n.length)return!1;for(let e=0;e<r.length;e++){const t=r[e],o=n[e];if(t.filename!==o.filename||t.lineno!==o.lineno||t.colno!==o.colno||t.function!==o.function)return!1}return!0}function aa(e,t){let n=e.fingerprint,r=t.fingerprint;if(!n&&!r)return!0;if(n&&!r||!n&&r)return!1;try{return n.join("")===r.join("")}catch{return!1}}function Mo(e){return e.exception&&e.exception.values&&e.exception.values[0]}function ca(e){if(void 0!==e)return e>=400&&e<500?"warning":e>=500?"error":void 0}const $r=j;function ua(){if(!("fetch"in $r))return!1;try{return new Headers,new Request("http://www.example.com"),new Response,!0}catch{return!1}}function Hr(e){return e&&/^function\s+\w+\(\)\s+\{\s+\[native code\]\s+\}$/.test(e.toString())}function yd(){if("string"==typeof EdgeRuntime)return!0;if(!ua())return!1;if(Hr($r.fetch))return!0;let e=!1;const t=$r.document;if(t&&"function"==typeof t.createElement)try{const n=t.createElement("iframe");n.hidden=!0,t.head.appendChild(n),n.contentWindow&&n.contentWindow.fetch&&(e=Hr(n.contentWindow.fetch)),t.head.removeChild(n)}catch(e){ct&&C.warn("Could not create sandbox iframe for pure fetch check, bailing to window.fetch: ",e)}return e}function Ed(e,t){const n="fetch";ut(n,e),lt(n,(()=>Sd(void 0,t)))}function Sd(e,t=!1){t&&!yd()||pe(j,"fetch",(function(e){return function(...t){const n=new Error,{method:r,url:o}=bd(t),s={args:t,fetchData:{method:r,url:o},startTimestamp:1e3*Fe(),virtualError:n};return Ce("fetch",{...s}),e.apply(j,t).then((async e=>(Ce("fetch",{...s,endTimestamp:1e3*Fe(),response:e}),e)),(e=>{throw Ce("fetch",{...s,endTimestamp:1e3*Fe(),error:e}),hs(e)&&void 0===e.stack&&(e.stack=n.stack,ot(e,"framesToPop",1)),e}))}}))}function zr(e,t){return!!e&&"object"==typeof e&&!!e[t]}function Oo(e){return"string"==typeof e?e:e?zr(e,"url")?e.url:e.toString?e.toString():"":""}function bd(e){if(0===e.length)return{method:"GET",url:""};if(2===e.length){const[t,n]=e;return{url:Oo(t),method:zr(n,"method")?String(n.method).toUpperCase():"GET"}}const t=e[0];return{url:Oo(t),method:zr(t,"method")?String(t.method).toUpperCase():"GET"}}function vd(){return typeof __SENTRY_BROWSER_BUNDLE__<"u"&&!!__SENTRY_BROWSER_BUNDLE__}function Id(){return"npm"}function wd(){return!vd()&&"[object process]"===Object.prototype.toString.call(typeof process<"u"?process:0)}function Do(){return typeof window<"u"&&(!wd()||Td())}function Td(){const e=j.process;return!!e&&"renderer"===e.type}const dn=j;function kd(){const e=dn.chrome,t=e&&e.app&&e.app.runtime,n="history"in dn&&!!dn.history.pushState&&!!dn.history.replaceState;return!t&&n}function Rd(e,t){return e??t()}function In(e){let t,n=e[0],r=1;for(;r<e.length;){const o=e[r],s=e[r+1];if(r+=2,("optionalAccess"===o||"optionalCall"===o)&&null==n)return;"access"===o||"optionalAccess"===o?(t=n,n=s(n)):("call"===o||"optionalCall"===o)&&(n=s(((...e)=>n.call(t,...e))),t=void 0)}return n}const J=j;let Wr=0;function la(){return Wr>0}function Cd(){Wr++,setTimeout((()=>{Wr--}))}function wt(e,t={}){if("function"!=typeof e)return e;try{const t=e.__sentry_wrapped__;if(t)return"function"==typeof t?t:e;if(ys(e))return e}catch{return e}const n=function(...n){try{const r=n.map((e=>wt(e,t)));return e.apply(this,r)}catch(e){throw Cd(),gu((r=>{r.addEventProcessor((e=>(t.mechanism&&(Ar(e,void 0),bt(e,t.mechanism)),e.extra={...e.extra,arguments:n},e))),Is(e)})),e}};try{for(const t in e)Object.prototype.hasOwnProperty.call(e,t)&&(n[t]=e[t])}catch{}Li(n,e),ot(e,"__sentry_wrapped__",n);try{Object.getOwnPropertyDescriptor(n,"name").configurable&&Object.defineProperty(n,"name",{get:()=>e.name})}catch{}return n}const Xt=typeof __SENTRY_DEBUG__>"u"||__SENTRY_DEBUG__;function ws(e,t){const n=Ts(e,t),r={type:xd(t),value:Nd(t)};return n.length&&(r.stacktrace={frames:n}),void 0===r.type&&""===r.value&&(r.value="Unrecoverable error caught"),r}function Md(e,t,n,r){const o=ie(),s=o&&o.getOptions().normalizeDepth,i=jd(t),a={__serialized__:Gi(t,s)};if(i)return{exception:{values:[ws(e,i)]},extra:a};const c={exception:{values:[{type:zn(t)?t.constructor.name:r?"UnhandledRejection":"Error",value:Fd(t,{isUnhandledRejection:r})}]},extra:a};if(n){const t=Ts(e,n);t.length&&(c.exception.values[0].stacktrace={frames:t})}return c}function gr(e,t){return{exception:{values:[ws(e,t)]}}}function Ts(e,t){const n=t.stacktrace||t.stack||"",r=Dd(t),o=Ad(t);try{return e(n,r,o)}catch{}return[]}const Od=/Minified React error #\d+;/i;function Dd(e){return e&&Od.test(e.message)?1:0}function Ad(e){return"number"==typeof e.framesToPop?e.framesToPop:0}function da(e){return typeof WebAssembly<"u"&&typeof WebAssembly.Exception<"u"&&e instanceof WebAssembly.Exception}function xd(e){const t=e&&e.name;return!t&&da(e)?e.message&&Array.isArray(e.message)&&2==e.message.length?e.message[0]:"WebAssembly.Exception":t}function Nd(e){const t=e&&e.message;return t?t.error&&"string"==typeof t.error.message?t.error.message:da(e)&&Array.isArray(e.message)&&2==e.message.length?e.message[1]:t:"No error message"}function Pd(e,t,n,r){const o=ks(e,t,n&&n.syntheticException||void 0,r);return bt(o),o.level="error",n&&n.event_id&&(o.event_id=n.event_id),Be(o)}function Ld(e,t,n="info",r,o){const s=Gr(e,t,r&&r.syntheticException||void 0,o);return s.level=n,r&&r.event_id&&(s.event_id=r.event_id),Be(s)}function ks(e,t,n,r,o){let s;if(xi(t)&&t.error)return gr(e,t.error);if(to(t)||Kc(t)){const o=t;if("stack"in t)s=gr(e,t);else{const t=o.name||(to(o)?"DOMError":"DOMException"),i=o.message?`${t}: ${o.message}`:t;s=Gr(e,i,n,r),Ar(s,i)}return"code"in o&&(s.tags={...s.tags,"DOMException.code":`${o.code}`}),s}return hs(t)?gr(e,t):St(t)||zn(t)?(s=Md(e,t,n,o),bt(s,{synthetic:!0}),s):(s=Gr(e,t,n,r),Ar(s,`${t}`),bt(s,{synthetic:!0}),s)}function Gr(e,t,n,r){const o={};if(r&&n){const r=Ts(e,n);r.length&&(o.exception={values:[{value:t,stacktrace:{frames:r}}]}),bt(o,{synthetic:!0})}if(ms(t)){const{__sentry_template_string__:e,__sentry_template_values__:n}=t;return o.logentry={message:e,params:n},o}return o.message=t,o}function Fd(e,{isUnhandledRejection:t}){const n=tu(e),r=t?"promise rejection":"exception";return xi(e)?`Event \`ErrorEvent\` captured as ${r} with message \`${e.message}\``:zn(e)?`Event \`${Ud(e)}\` (type=${e.type}) captured as ${r}`:`Object captured as ${r} with keys: ${n}`}function Ud(e){try{const t=Object.getPrototypeOf(e);return t?t.constructor.name:void 0}catch{}}function jd(e){for(const t in e)if(Object.prototype.hasOwnProperty.call(e,t)){const n=e[t];if(n instanceof Error)return n}}function Bd(e,{metadata:t,tunnel:n,dsn:r}){return At({event_id:e.event_id,sent_at:(new Date).toISOString(),...t&&t.sdk&&{sdk:{name:t.sdk.name,version:t.sdk.version}},...!!n&&!!r&&{dsn:qn(r)}},[$d(e)])}function $d(e){return[{type:"user_report"},e]}class Hd extends Dl{constructor(e){const t={parentSpanIsAlwaysRootSpan:!0,...e};ra(t,"browser",["browser"],J.SENTRY_SDK_SOURCE||Id()),super(t),t.sendClientReports&&J.document&&J.document.addEventListener("visibilitychange",(()=>{"hidden"===J.document.visibilityState&&this._flushOutcomes()}))}eventFromException(e,t){return Pd(this._options.stackParser,e,t,this._options.attachStacktrace)}eventFromMessage(e,t="info",n){return Ld(this._options.stackParser,e,t,n,this._options.attachStacktrace)}captureUserFeedback(e){if(!this._isEnabled())return void(Xt&&C.warn("SDK not enabled, will not capture user feedback."));const t=Bd(e,{metadata:this.getSdkMetadata(),dsn:this.getDsn(),tunnel:this.getOptions().tunnel});this.sendEnvelope(t)}_prepareEvent(e,t,n){return e.platform=e.platform||"javascript",super._prepareEvent(e,t,n)}}const fa=typeof __SENTRY_DEBUG__>"u"||__SENTRY_DEBUG__,zd=(e,t)=>e>t[1]?"poor":e>t[0]?"needs-improvement":"good",Qt=(e,t,n,r)=>{let o,s;return i=>{t.value>=0&&(i||r)&&(s=t.value-(o||0),(s||void 0===o)&&(o=t.value,t.delta=s,t.rating=zd(t.value,n),e(t)))}},P=j,Wd=()=>`v4-${Date.now()}-${Math.floor(8999999999999*Math.random())+1e12}`,pa=(e=!0)=>{const t=P.performance&&P.performance.getEntriesByType&&P.performance.getEntriesByType("navigation")[0];if(!e||t&&t.responseStart>0&&t.responseStart<performance.now())return t},Rs=()=>{const e=pa();return e&&e.activationStart||0},Zt=(e,t)=>{const n=pa();let r="navigate";return n&&(P.document&&P.document.prerendering||Rs()>0?r="prerender":P.document&&P.document.wasDiscarded?r="restore":n.type&&(r=n.type.replace(/_/g,"-"))),{name:e,value:typeof t>"u"?-1:t,rating:"good",delta:0,entries:[],id:Wd(),navigationType:r}},dt=(e,t,n)=>{try{if(PerformanceObserver.supportedEntryTypes.includes(e)){const r=new PerformanceObserver((e=>{Promise.resolve().then((()=>{t(e.getEntries())}))}));return r.observe(Object.assign({type:e,buffered:!0},n||{})),r}}catch{}},en=e=>{const t=t=>{("pagehide"===t.type||P.document&&"hidden"===P.document.visibilityState)&&e(t)};P.document&&(addEventListener("visibilitychange",t,!0),addEventListener("pagehide",t,!0))},Vn=e=>{let t=!1;return()=>{t||(e(),t=!0)}};let Nt=-1;const Gd=()=>"hidden"!==P.document.visibilityState||P.document.prerendering?1/0:0,Mn=e=>{"hidden"===P.document.visibilityState&&Nt>-1&&(Nt="visibilitychange"===e.type?e.timeStamp:0,Kd())},Yd=()=>{addEventListener("visibilitychange",Mn,!0),addEventListener("prerenderingchange",Mn,!0)},Kd=()=>{removeEventListener("visibilitychange",Mn,!0),removeEventListener("prerenderingchange",Mn,!0)},Cs=()=>(P.document&&Nt<0&&(Nt=Gd(),Yd()),{get firstHiddenTime(){return Nt}}),Jn=e=>{P.document&&P.document.prerendering?addEventListener("prerenderingchange",(()=>e()),!0):e()},qd=[1800,3e3],Vd=(e,t={})=>{Jn((()=>{const n=Cs(),r=Zt("FCP");let o;const s=dt("paint",(e=>{e.forEach((e=>{"first-contentful-paint"===e.name&&(s.disconnect(),e.startTime<n.firstHiddenTime&&(r.value=Math.max(e.startTime-Rs(),0),r.entries.push(e),o(!0)))}))}));s&&(o=Qt(e,r,qd,t.reportAllChanges))}))},Jd=[.1,.25],Xd=(e,t={})=>{Vd(Vn((()=>{const n=Zt("CLS",0);let r,o=0,s=[];const i=e=>{e.forEach((e=>{if(!e.hadRecentInput){const t=s[0],n=s[s.length-1];o&&t&&n&&e.startTime-n.startTime<1e3&&e.startTime-t.startTime<5e3?(o+=e.value,s.push(e)):(o=e.value,s=[e])}})),o>n.value&&(n.value=o,n.entries=s,r())},a=dt("layout-shift",i);a&&(r=Qt(e,n,Jd,t.reportAllChanges),en((()=>{i(a.takeRecords()),r(!0)})),setTimeout(r,0))})))},Qd=[100,300],Zd=(e,t={})=>{Jn((()=>{const n=Cs(),r=Zt("FID");let o;const s=e=>{e.startTime<n.firstHiddenTime&&(r.value=e.processingStart-e.startTime,r.entries.push(e),o(!0))},i=e=>{e.forEach(s)},a=dt("first-input",i);o=Qt(e,r,Qd,t.reportAllChanges),a&&en(Vn((()=>{i(a.takeRecords()),a.disconnect()})))}))};let ha=0,yr=1/0,fn=0;const ef=e=>{e.forEach((e=>{e.interactionId&&(yr=Math.min(yr,e.interactionId),fn=Math.max(fn,e.interactionId),ha=fn?(fn-yr)/7+1:0)}))};let Yr;const tf=()=>Yr?ha:performance.interactionCount||0,nf=()=>{"interactionCount"in performance||Yr||(Yr=dt("event",ef,{type:"event",buffered:!0,durationThreshold:0}))},Pe=[],Er=new Map,rf=40;let sf=0;const of=()=>tf()-sf,af=()=>{const e=Math.min(Pe.length-1,Math.floor(of()/50));return Pe[e]},Sr=10,cf=[],uf=e=>{if(cf.forEach((t=>t(e))),!e.interactionId&&"first-input"!==e.entryType)return;const t=Pe[Pe.length-1],n=Er.get(e.interactionId);if(n||Pe.length<10||t&&e.duration>t.latency){if(n)e.duration>n.latency?(n.entries=[e],n.latency=e.duration):e.duration===n.latency&&e.startTime===(n.entries[0]&&n.entries[0].startTime)&&n.entries.push(e);else{const t={id:e.interactionId,latency:e.duration,entries:[e]};Er.set(t.id,t),Pe.push(t)}Pe.sort(((e,t)=>t.latency-e.latency)),Pe.length>10&&Pe.splice(10).forEach((e=>Er.delete(e.id)))}},ma=e=>{const t=P.requestIdleCallback||P.setTimeout;let n=-1;return e=Vn(e),P.document&&"hidden"===P.document.visibilityState?e():(n=t(e),en(e)),n},lf=[200,500],df=(e,t={})=>{"PerformanceEventTiming"in P&&"interactionId"in PerformanceEventTiming.prototype&&Jn((()=>{nf();const n=Zt("INP");let r;const o=e=>{ma((()=>{e.forEach(uf);const t=af();t&&t.latency!==n.value&&(n.value=t.latency,n.entries=t.entries,r())}))},s=dt("event",o,{durationThreshold:null!=t.durationThreshold?t.durationThreshold:40});r=Qt(e,n,lf,t.reportAllChanges),s&&(s.observe({type:"first-input",buffered:!0}),en((()=>{o(s.takeRecords()),r(!0)})))}))},ff=[2500,4e3],Ao={},pf=(e,t={})=>{Jn((()=>{const n=Cs(),r=Zt("LCP");let o;const s=e=>{t.reportAllChanges||(e=e.slice(-1)),e.forEach((e=>{e.startTime<n.firstHiddenTime&&(r.value=Math.max(e.startTime-Rs(),0),r.entries=[e],o())}))},i=dt("largest-contentful-paint",s);if(i){o=Qt(e,r,ff,t.reportAllChanges);const n=Vn((()=>{Ao[r.id]||(s(i.takeRecords()),i.disconnect(),Ao[r.id]=!0,o(!0))}));["keydown","click"].forEach((e=>{P.document&&addEventListener(e,(()=>ma(n)),{once:!0,capture:!0})})),en(n)}}))},Pt={},On={};let _a,ga,ya,Ea;function hf(e,t=!1){return Xn("cls",e,Ef,_a,t)}function mf(e,t=!1){return Xn("lcp",e,bf,ya,t)}function _f(e){return Xn("fid",e,Sf,ga)}function gf(e){return Xn("inp",e,vf,Ea)}function yf(e,t){return Sa(e,t),On[e]||(If(e),On[e]=!0),ba(e,t)}function tn(e,t){const n=Pt[e];if(n&&n.length)for(const r of n)try{r(t)}catch(t){fa&&C.error(`Error while triggering instrumentation handler.\nType: ${e}\nName: ${je(r)}\nError:`,t)}}function Ef(){return Xd((e=>{tn("cls",{metric:e}),_a=e}),{reportAllChanges:!0})}function Sf(){return Zd((e=>{tn("fid",{metric:e}),ga=e}))}function bf(){return pf((e=>{tn("lcp",{metric:e}),ya=e}),{reportAllChanges:!0})}function vf(){return df((e=>{tn("inp",{metric:e}),Ea=e}))}function Xn(e,t,n,r,o=!1){let s;return Sa(e,t),On[e]||(s=n(),On[e]=!0),r&&t({metric:r}),ba(e,t,o?s:void 0)}function If(e){const t={};"event"===e&&(t.durationThreshold=0),dt(e,(t=>{tn(e,{entries:t})}),t)}function Sa(e,t){Pt[e]=Pt[e]||[],Pt[e].push(t)}function ba(e,t,n){return()=>{n&&n();const r=Pt[e];if(!r)return;const o=r.indexOf(t);-1!==o&&r.splice(o,1)}}const wf=1e3;let xo,Kr,qr,pn;function va(e){ut("dom",e),lt("dom",Tf)}function Tf(){if(!P.document)return;const e=Ce.bind(null,"dom"),t=No(e,!0);P.document.addEventListener("click",t,!1),P.document.addEventListener("keypress",t,!1),["EventTarget","Node"].forEach((t=>{const n=P[t],r=n&&n.prototype;!r||!r.hasOwnProperty||!r.hasOwnProperty("addEventListener")||(pe(r,"addEventListener",(function(t){return function(n,r,o){if("click"===n||"keypress"==n)try{const r=this.__sentry_instrumentation_handlers__=this.__sentry_instrumentation_handlers__||{},s=r[n]=r[n]||{refCount:0};if(!s.handler){const r=No(e);s.handler=r,t.call(this,n,r,o)}s.refCount++}catch{}return t.call(this,n,r,o)}})),pe(r,"removeEventListener",(function(e){return function(t,n,r){if("click"===t||"keypress"==t)try{const n=this.__sentry_instrumentation_handlers__||{},o=n[t];o&&(o.refCount--,o.refCount<=0&&(e.call(this,t,o.handler,r),o.handler=void 0,delete n[t]),0===Object.keys(n).length&&delete this.__sentry_instrumentation_handlers__)}catch{}return e.call(this,t,n,r)}})))}))}function kf(e){if(e.type!==Kr)return!1;try{if(!e.target||e.target._sentryId!==qr)return!1}catch{}return!0}function Rf(e,t){return"keypress"===e&&(!t||!t.tagName||!("INPUT"===t.tagName||"TEXTAREA"===t.tagName||t.isContentEditable))}function No(e,t=!1){return n=>{if(!n||n._sentryCaptured)return;const r=Cf(n);if(Rf(n.type,r))return;ot(n,"_sentryCaptured",!0),r&&!r._sentryId&&ot(r,"_sentryId",ge());const o="keypress"===n.type?"input":n.type;kf(n)||(e({event:n,name:o,global:t}),Kr=n.type,qr=r?r._sentryId:void 0),clearTimeout(xo),xo=P.setTimeout((()=>{qr=void 0,Kr=void 0}),wf)}}function Cf(e){try{return e.target}catch{return null}}function Ms(e){const t="history";ut(t,e),lt(t,Mf)}function Mf(){if(!kd())return;const e=P.onpopstate;function t(e){return function(...t){const n=t.length>2?t[2]:void 0;if(n){const e=pn,t=String(n);pn=t,Ce("history",{from:e,to:t})}return e.apply(this,t)}}P.onpopstate=function(...t){const n=P.location.href,r=pn;if(pn=n,Ce("history",{from:r,to:n}),e)try{return e.apply(this,t)}catch{}},pe(P.history,"pushState",t),pe(P.history,"replaceState",t)}const wn={};function Ia(e){const t=wn[e];if(t)return t;let n=P[e];if(Hr(n))return wn[e]=n.bind(P);const r=P.document;if(r&&"function"==typeof r.createElement)try{const t=r.createElement("iframe");t.hidden=!0,r.head.appendChild(t);const o=t.contentWindow;o&&o[e]&&(n=o[e]),r.head.removeChild(t)}catch(t){fa&&C.warn(`Could not create sandbox iframe for ${e} check, bailing to window.${e}: `,t)}return n&&(wn[e]=n.bind(P))}function Po(e){wn[e]=void 0}function Tt(...e){return Ia("setTimeout")(...e)}const ht="__sentry_xhr_v3__";function Of(e){ut("xhr",e),lt("xhr",Df)}function Df(){if(!P.XMLHttpRequest)return;const e=XMLHttpRequest.prototype;e.open=new Proxy(e.open,{apply(e,t,n){const r=new Error,o=1e3*Fe(),s=Le(n[0])?n[0].toUpperCase():void 0,i=Af(n[1]);if(!s||!i)return e.apply(t,n);t[ht]={method:s,url:i,request_headers:{}},"POST"===s&&i.match(/sentry_key/)&&(t.__sentry_own_request__=!0);const a=()=>{const e=t[ht];if(e&&4===t.readyState){try{e.status_code=t.status}catch{}Ce("xhr",{endTimestamp:1e3*Fe(),startTimestamp:o,xhr:t,virtualError:r})}};return"onreadystatechange"in t&&"function"==typeof t.onreadystatechange?t.onreadystatechange=new Proxy(t.onreadystatechange,{apply:(e,t,n)=>(a(),e.apply(t,n))}):t.addEventListener("readystatechange",a),t.setRequestHeader=new Proxy(t.setRequestHeader,{apply(e,t,n){const[r,o]=n,s=t[ht];return s&&Le(r)&&Le(o)&&(s.request_headers[r.toLowerCase()]=o),e.apply(t,n)}}),e.apply(t,n)}}),e.send=new Proxy(e.send,{apply(e,t,n){const r=t[ht];if(!r)return e.apply(t,n);void 0!==n[0]&&(r.body=n[0]);return Ce("xhr",{startTimestamp:1e3*Fe(),xhr:t}),e.apply(t,n)}})}function Af(e){if(Le(e))return e;try{return e.toString()}catch{}}function xf(e,t=Ia("fetch")){let n=0,r=0;return $l(e,(function(o){const s=o.body.length;n+=s,r++;const i={body:o.body,method:"POST",referrerPolicy:"origin",headers:e.headers,keepalive:n<=6e4&&r<15,...e.fetchOptions};if(!t)return Po("fetch"),Rn("No fetch implementation available");try{return t(e.url,i).then((e=>(n-=s,r--,{statusCode:e.status,headers:{"x-sentry-rate-limits":e.headers.get("X-Sentry-Rate-Limits"),"retry-after":e.headers.get("Retry-After")}})))}catch(e){return Po("fetch"),n-=s,r--,Rn(e)}}))}const Nf=30,Pf=50;function Vr(e,t,n,r){const o={filename:e,function:"<anonymous>"===t?rt:t,in_app:!0};return void 0!==n&&(o.lineno=n),void 0!==r&&(o.colno=r),o}const Lf=/^\s*at (\S+?)(?::(\d+))(?::(\d+))\s*$/i,Ff=/^\s*at (?:(.+?\)(?: \[.+\])?|.*?) ?\((?:address at )?)?(?:async )?((?:<anonymous>|[-a-z]+:|.*bundle|\/)?.*?)(?::(\d+))?(?::(\d+))?\)?\s*$/i,Uf=/\((\S*)(?::(\d+))(?::(\d+))\)/,jf=e=>{const t=Lf.exec(e);if(t){const[,e,n,r]=t;return Vr(e,rt,+n,+r)}const n=Ff.exec(e);if(n){if(n[2]&&0===n[2].indexOf("eval")){const e=Uf.exec(n[2]);e&&(n[2]=e[1],n[3]=e[2],n[4]=e[3])}const[e,t]=wa(n[1]||rt,n[2]);return Vr(t,e,n[3]?+n[3]:void 0,n[4]?+n[4]:void 0)}},Bf=[30,jf],$f=/^\s*(.*?)(?:\((.*?)\))?(?:^|@)?((?:[-a-z]+)?:\/.*?|\[native code\]|[^@]*(?:bundle|\d+\.js)|\/[\w\-. /=]+)(?::(\d+))?(?::(\d+))?\s*$/i,Hf=/(\S+) line (\d+)(?: > eval line \d+)* > eval/i,zf=e=>{const t=$f.exec(e);if(t){if(t[3]&&t[3].indexOf(" > eval")>-1){const e=Hf.exec(t[3]);e&&(t[1]=t[1]||"eval",t[3]=e[1],t[4]=e[2],t[5]="")}let e=t[3],n=t[1]||rt;return[n,e]=wa(n,e),Vr(e,n,t[4]?+t[4]:void 0,t[5]?+t[5]:void 0)}},Wf=[50,zf],Gf=[Bf,Wf],Yf=Di(...Gf),wa=(e,t)=>{const n=-1!==e.indexOf("safari-extension"),r=-1!==e.indexOf("safari-web-extension");return n||r?[-1!==e.indexOf("@")?e.split("@")[0]:rt,n?`safari-extension:${t}`:`safari-web-extension:${t}`]:[e,t]},hn=1024,Kf="Breadcrumbs",qf=(e={})=>{const t={console:!0,dom:!0,fetch:!0,history:!0,sentry:!0,xhr:!0,...e};return{name:Kf,setup(e){t.console&&dd(Qf(e)),t.dom&&va(Xf(e,t.dom)),t.xhr&&Of(Zf(e)),t.fetch&&Ed(ep(e)),t.history&&Ms(tp(e)),t.sentry&&e.on("beforeSendEvent",Jf(e))}}},Vf=qf;function Jf(e){return function(t){ie()===e&&qe({category:"sentry."+("transaction"===t.type?"transaction":"event"),event_id:t.event_id,level:t.level,message:He(t)},{event:t})}}function Xf(e,t){return function(n){if(ie()!==e)return;let r,o,s="object"==typeof t?t.serializeAttribute:void 0,i="object"==typeof t&&"number"==typeof t.maxStringLength?t.maxStringLength:void 0;i&&i>hn&&(Xt&&C.warn(`\`dom.maxStringLength\` cannot exceed 1024, but a value of ${i} was configured. Sentry will use 1024 instead.`),i=hn),"string"==typeof s&&(s=[s]);try{const e=n.event,t=np(e)?e.target:e;r=Gn(t,{keyAttrs:s,maxStringLength:i}),o=Zc(t)}catch{r="<unknown>"}if(0===r.length)return;const a={category:`ui.${n.name}`,message:r};o&&(a.data={"ui.component_name":o}),qe(a,{event:n.event,name:n.name,global:n.global})}}function Qf(e){return function(t){if(ie()!==e)return;const n={category:"console",data:{arguments:t.args,logger:"console"},level:sa(t.level),message:no(t.args," ")};if("assert"===t.level){if(!1!==t.args[0])return;n.message=`Assertion failed: ${no(t.args.slice(1)," ")||"console.assert"}`,n.data.arguments=t.args.slice(1)}qe(n,{input:t.args,level:t.level})}}function Zf(e){return function(t){if(ie()!==e)return;const{startTimestamp:n,endTimestamp:r}=t,o=t.xhr[ht];if(!n||!r||!o)return;const{method:s,url:i,status_code:a,body:c}=o,u={method:s,url:i,status_code:a},l={xhr:t.xhr,input:c,startTimestamp:n,endTimestamp:r};qe({category:"xhr",data:u,type:"http",level:ca(a)},l)}}function ep(e){return function(t){if(ie()!==e)return;const{startTimestamp:n,endTimestamp:r}=t;if(r&&(!t.fetchData.url.match(/sentry_key/)||"POST"!==t.fetchData.method))if(t.error){qe({category:"fetch",data:t.fetchData,level:"error",type:"http"},{data:t.error,input:t.args,startTimestamp:n,endTimestamp:r})}else{const e=t.response,o={...t.fetchData,status_code:e&&e.status},s={input:t.args,response:e,startTimestamp:n,endTimestamp:r};qe({category:"fetch",data:o,type:"http",level:ca(o.status_code)},s)}}}function tp(e){return function(t){if(ie()!==e)return;let n=t.from,r=t.to;const o=_r(J.location.href);let s=n?_r(n):void 0;const i=_r(r);(!s||!s.path)&&(s=o),o.protocol===i.protocol&&o.host===i.host&&(r=i.relative),o.protocol===s.protocol&&o.host===s.host&&(n=s.relative),qe({category:"navigation",data:{from:n,to:r}})}}function np(e){return!!e&&!!e.target}const rp=["EventTarget","Window","Node","ApplicationCache","AudioTrackList","BroadcastChannel","ChannelMergerNode","CryptoOperation","EventSource","FileReader","HTMLUnknownElement","IDBDatabase","IDBRequest","IDBTransaction","KeyOperation","MediaController","MessagePort","ModalWindow","Notification","SVGElementInstance","Screen","SharedWorker","TextTrack","TextTrackCue","TextTrackList","WebSocket","WebSocketWorker","Worker","XMLHttpRequest","XMLHttpRequestEventTarget","XMLHttpRequestUpload"],sp="BrowserApiErrors",op=(e={})=>{const t={XMLHttpRequest:!0,eventTarget:!0,requestAnimationFrame:!0,setInterval:!0,setTimeout:!0,...e};return{name:sp,setupOnce(){t.setTimeout&&pe(J,"setTimeout",Lo),t.setInterval&&pe(J,"setInterval",Lo),t.requestAnimationFrame&&pe(J,"requestAnimationFrame",ip),t.XMLHttpRequest&&"XMLHttpRequest"in J&&pe(XMLHttpRequest.prototype,"send",ap);const e=t.eventTarget;e&&(Array.isArray(e)?e:rp).forEach(cp)}}},Ta=op;function Lo(e){return function(...t){const n=t[0];return t[0]=wt(n,{mechanism:{data:{function:je(e)},handled:!1,type:"instrument"}}),e.apply(this,t)}}function ip(e){return function(t){return e.apply(this,[wt(t,{mechanism:{data:{function:"requestAnimationFrame",handler:je(e)},handled:!1,type:"instrument"}})])}}function ap(e){return function(...t){const n=this;return["onload","onerror","onprogress","onreadystatechange"].forEach((e=>{e in n&&"function"==typeof n[e]&&pe(n,e,(function(t){const n={mechanism:{data:{function:e,handler:je(t)},handled:!1,type:"instrument"}},r=ys(t);return r&&(n.mechanism.data.handler=je(r)),wt(t,n)}))})),e.apply(this,t)}}function cp(e){const t=J[e],n=t&&t.prototype;!n||!n.hasOwnProperty||!n.hasOwnProperty("addEventListener")||(pe(n,"addEventListener",(function(t){return function(n,r,o){try{up(r)&&(r.handleEvent=wt(r.handleEvent,{mechanism:{data:{function:"handleEvent",handler:je(r),target:e},handled:!1,type:"instrument"}}))}catch{}return t.apply(this,[n,wt(r,{mechanism:{data:{function:"addEventListener",handler:je(r),target:e},handled:!1,type:"instrument"}}),o])}})),pe(n,"removeEventListener",(function(e){return function(t,n,r){try{const o=n.__sentry_wrapped__;o&&e.call(this,t,o,r)}catch{}return e.call(this,t,n,r)}})))}function up(e){return"function"==typeof e.handleEvent}const lp=()=>({name:"BrowserSession",setupOnce(){typeof J.document>"u"?Xt&&C.warn("Using the `browserSessionIntegration` in non-browser environments is not supported."):(yo({ignoreDuration:!0}),Eo(),Ms((({from:e,to:t})=>{void 0!==e&&e!==t&&(yo({ignoreDuration:!0}),Eo())})))}}),dp="GlobalHandlers",fp=(e={})=>{const t={onerror:!0,onunhandledrejection:!0,...e};return{name:dp,setupOnce(){Error.stackTraceLimit=50},setup(e){t.onerror&&(hp(e),Fo("onerror")),t.onunhandledrejection&&(mp(e),Fo("onunhandledrejection"))}}},pp=fp;function hp(e){zc((t=>{const{stackParser:n,attachStacktrace:r}=ka();if(ie()!==e||la())return;const{msg:o,url:s,line:i,column:a,error:c}=t,u=yp(ks(n,c||o,void 0,r,!1),s,i,a);u.level="error",qi(u,{originalException:c,mechanism:{handled:!1,type:"onerror"}})}))}function mp(e){Gc((t=>{const{stackParser:n,attachStacktrace:r}=ka();if(ie()!==e||la())return;const o=_p(t),s=_s(o)?gp(o):ks(n,o,void 0,r,!0);s.level="error",qi(s,{originalException:o,mechanism:{handled:!1,type:"onunhandledrejection"}})}))}function _p(e){if(_s(e))return e;try{if("reason"in e)return e.reason;if("detail"in e&&"reason"in e.detail)return e.detail.reason}catch{}return e}function gp(e){return{exception:{values:[{type:"UnhandledRejection",value:`Non-Error promise rejection captured with value: ${String(e)}`}]}}}function yp(e,t,n,r){const o=e.exception=e.exception||{},s=o.values=o.values||[],i=s[0]=s[0]||{},a=i.stacktrace=i.stacktrace||{},c=a.frames=a.frames||[],u=r,l=n,d=Le(t)&&t.length>0?t:Pi();return 0===c.length&&c.push({colno:u,filename:d,function:rt,in_app:!0,lineno:l}),e}function Fo(e){Xt&&C.log(`Global Handler attached: ${e}`)}function ka(){const e=ie();return e&&e.getOptions()||{stackParser:()=>[],attachStacktrace:!1}}const Ep=()=>({name:"HttpContext",preprocessEvent(e){if(!J.navigator&&!J.location&&!J.document)return;const t=e.request&&e.request.url||J.location&&J.location.href,{referrer:n}=J.document||{},{userAgent:r}=J.navigator||{},o={...e.request&&e.request.headers,...n&&{Referer:n},...r&&{"User-Agent":r}},s={...e.request,...t&&{url:t},headers:o};e.request=s}}),Sp="cause",bp=5,vp="LinkedErrors",Ip=(e={})=>{const t=e.limit||5,n=e.key||Sp;return{name:vp,preprocessEvent(e,r,o){const s=o.getOptions();ud(ws,s.stackParser,s.maxValueLength,n,t,e,r)}}},wp=Ip;function Tp(e){const t=[Ql(),ql(),Ta(),Vf(),pp(),wp(),oa(),Ep()];return!1!==e.autoSessionTracking&&t.push(lp()),t}function kp(e={}){const t={defaultIntegrations:Tp(e),release:"string"==typeof __SENTRY_RELEASE__?__SENTRY_RELEASE__:J.SENTRY_RELEASE&&J.SENTRY_RELEASE.id?J.SENTRY_RELEASE.id:void 0,autoSessionTracking:!0,sendClientReports:!0};return null==e.defaultIntegrations&&delete e.defaultIntegrations,{...t,...e}}function Rp(){const e=typeof J.window<"u"&&J;if(!e)return!1;const t=e[e.chrome?"chrome":"browser"],n=t&&t.runtime&&t.runtime.id,r=J.location&&J.location.href||"",o=!!n&&J===J.top&&["chrome-extension:","moz-extension:","ms-browser-extension:","safari-web-extension:"].some((e=>r.startsWith(`${e}//`))),s=typeof e.nw<"u";return!!n&&!o&&!s}function Cp(e={}){const t=kp(e);if(!t.skipBrowserExtensionCheck&&Rp())return void Je((()=>{console.error("[Sentry] You cannot run Sentry this way in a browser extension, check: https://docs.sentry.io/platforms/javascript/best-practices/browser-extensions/")}));Xt&&(ua()||C.warn("No Fetch API detected. The Sentry SDK requires a Fetch API compatible environment to send events. Please add a Fetch API polyfill."));const n={...t,stackParser:$c(t.stackParser||Yf),integrations:Cl(t),transport:t.transport||xf};return Nl(Hd,n)}const ee=j,Os="sentryReplaySession",Mp="replay_event",Ds="Unable to send Replay",Op=3e5,Dp=9e5,Ap=5e3,xp=5500,Np=6e4,Pp=5e3,Lp=3,Uo=15e4,mn=5e3,Fp=3e3,Up=300,As=2e7,jp=4999,Bp=15e3,jo=36e5;function Jr(e,t){return e??t()}function Bt(e){let t,n=e[0],r=1;for(;r<e.length;){const o=e[r],s=e[r+1];if(r+=2,("optionalAccess"===o||"optionalCall"===o)&&null==n)return;"access"===o||"optionalAccess"===o?(t=n,n=s(n)):("call"===o||"optionalCall"===o)&&(n=s(((...e)=>n.call(t,...e))),t=void 0)}return n}var ce;function $p(e){return e.nodeType===e.ELEMENT_NODE}function Lt(e){const t=Bt([e,"optionalAccess",e=>e.host]);return Bt([t,"optionalAccess",e=>e.shadowRoot])===e}function Ft(e){return"[object ShadowRoot]"===Object.prototype.toString.call(e)}function Hp(e){return e.includes(" background-clip: text;")&&!e.includes(" -webkit-background-clip: text;")&&(e=e.replace(/\sbackground-clip:\s*text;/g," -webkit-background-clip: text; background-clip: text;")),e}function zp(e){const{cssText:t}=e;if(t.split('"').length<3)return t;const n=["@import",`url(${JSON.stringify(e.href)})`];return""===e.layerName?n.push("layer"):e.layerName&&n.push(`layer(${e.layerName})`),e.supportsText&&n.push(`supports(${e.supportsText})`),e.media.length&&n.push(e.media.mediaText),n.join(" ")+";"}function Dn(e){try{const t=e.rules||e.cssRules;return t?Hp(Array.from(t,Ra).join("")):null}catch{return null}}function Wp(e){let t="";for(let n=0;n<e.style.length;n++){const r=e.style,o=r[n],s=r.getPropertyPriority(o);t+=`${o}:${r.getPropertyValue(o)}${s?" !important":""};`}return`${e.selectorText} { ${t} }`}function Ra(e){let t;if(Yp(e))try{t=Dn(e.styleSheet)||zp(e)}catch{}else if(Kp(e)){let t=e.cssText;const n=e.selectorText.includes(":"),r="string"==typeof e.style.all&&e.style.all;if(r&&(t=Wp(e)),n&&(t=Gp(t)),n||r)return t}return t||e.cssText}function Gp(e){return e.replace(/(\[(?:[\w-]+)[^\\])(:(?:[\w-]+)\])/gm,"$1\\$2")}function Yp(e){return"styleSheet"in e}function Kp(e){return"selectorText"in e}!function(e){e[e.Document=0]="Document",e[e.DocumentType=1]="DocumentType",e[e.Element=2]="Element",e[e.Text=3]="Text",e[e.CDATA=4]="CDATA",e[e.Comment=5]="Comment"}(ce||(ce={}));class Ca{constructor(){this.idNodeMap=new Map,this.nodeMetaMap=new WeakMap}getId(e){if(!e)return-1;return Jr(Bt([this,"access",e=>e.getMeta,"call",t=>t(e),"optionalAccess",e=>e.id]),(()=>-1))}getNode(e){return this.idNodeMap.get(e)||null}getIds(){return Array.from(this.idNodeMap.keys())}getMeta(e){return this.nodeMetaMap.get(e)||null}removeNodeFromMap(e){const t=this.getId(e);this.idNodeMap.delete(t),e.childNodes&&e.childNodes.forEach((e=>this.removeNodeFromMap(e)))}has(e){return this.idNodeMap.has(e)}hasNode(e){return this.nodeMetaMap.has(e)}add(e,t){const n=t.id;this.idNodeMap.set(n,e),this.nodeMetaMap.set(e,t)}replace(e,t){const n=this.getNode(e);if(n){const e=this.nodeMetaMap.get(n);e&&this.nodeMetaMap.set(t,e)}this.idNodeMap.set(e,t)}reset(){this.idNodeMap=new Map,this.nodeMetaMap=new WeakMap}}function qp(){return new Ca}function Qn({maskInputOptions:e,tagName:t,type:n}){return"OPTION"===t&&(t="SELECT"),!!(e[t.toLowerCase()]||n&&e[n]||"password"===n||"INPUT"===t&&!n&&e.text)}function $t({isMasked:e,element:t,value:n,maskInputFn:r}){let o=n||"";return e?(r&&(o=r(o,t)),"*".repeat(o.length)):o}function kt(e){return e.toLowerCase()}function Xr(e){return e.toUpperCase()}const Bo="__rrweb_original__";function Vp(e){const t=e.getContext("2d");if(!t)return!0;for(let n=0;n<e.width;n+=50)for(let r=0;r<e.height;r+=50){const o=t.getImageData,s=Bo in o?o[Bo]:o;if(new Uint32Array(s.call(t,n,r,Math.min(50,e.width-n),Math.min(50,e.height-r)).data.buffer).some((e=>0!==e)))return!1}return!0}function xs(e){const t=e.type;return e.hasAttribute("data-rr-is-password")?"password":t?kt(t):null}function An(e,t,n){return"INPUT"!==t||"radio"!==n&&"checkbox"!==n?e.value:e.getAttribute("value")||""}function Ma(e,t){let n;try{n=new URL(e,Jr(t,(()=>window.location.href)))}catch{return null}return Jr(Bt([n.pathname.match(/\.([0-9a-z]+)(?:$)/i),"optionalAccess",e=>e[1]]),(()=>null))}const $o={};function Oa(e){const t=$o[e];if(t)return t;const n=window.document;let r=window[e];if(n&&"function"==typeof n.createElement)try{const t=n.createElement("iframe");t.hidden=!0,n.head.appendChild(t);const o=t.contentWindow;o&&o[e]&&(r=o[e]),n.head.removeChild(t)}catch{}return $o[e]=r.bind(window)}function Qr(...e){return Oa("setTimeout")(...e)}function Da(...e){return Oa("clearTimeout")(...e)}function Aa(e){try{return e.contentDocument}catch{}}let Jp=1;const Xp=new RegExp("[^a-z0-9-_:]"),Ht=-2;function Ns(){return Jp++}function Qp(e){if(e instanceof HTMLFormElement)return"form";const t=kt(e.tagName);return Xp.test(t)?"div":t}function Zp(e){let t="";return t=e.indexOf("//")>-1?e.split("/").slice(0,3).join("/"):e.split("/")[0],t=t.split("?")[0],t}let ft,Ho;const eh=/url\((?:(')([^']*)'|(")(.*?)"|([^)]*))\)/gm,th=/^(?:[a-z+]+:)?\/\//i,nh=/^www\..*/i,rh=/^(data:)([^,]*),(.*)/i;function xn(e,t){return(e||"").replace(eh,((e,n,r,o,s,i)=>{const a=r||s||i,c=n||o||"";if(!a)return e;if(th.test(a)||nh.test(a))return`url(${c}${a}${c})`;if(rh.test(a))return`url(${c}${a}${c})`;if("/"===a[0])return`url(${c}${Zp(t)+a}${c})`;const u=t.split("/"),l=a.split("/");u.pop();for(const e of l)"."!==e&&(".."===e?u.pop():u.push(e));return`url(${c}${u.join("/")}${c})`}))}const sh=/^[^ \t\n\r\u000c]+/,oh=/^[, \t\n\r\u000c]+/;function ih(e,t){if(""===t.trim())return t;let n=0;function r(e){let r;const o=e.exec(t.substring(n));return o?(r=o[0],n+=r.length,r):""}const o=[];for(;r(oh),!(n>=t.length);){let s=r(sh);if(","===s.slice(-1))s=mt(e,s.substring(0,s.length-1)),o.push(s);else{let r="";s=mt(e,s);let i=!1;for(;;){const e=t.charAt(n);if(""===e){o.push((s+r).trim());break}if(i)")"===e&&(i=!1);else{if(","===e){n+=1,o.push((s+r).trim());break}"("===e&&(i=!0)}r+=e,n+=1}}}return o.join(", ")}const zo=new WeakMap;function mt(e,t){return t&&""!==t.trim()?Zn(e,t):t}function ah(e){return!("svg"!==e.tagName&&!e.ownerSVGElement)}function Zn(e,t){let n=zo.get(e);if(n||(n=e.createElement("a"),zo.set(e,n)),t){if(t.startsWith("blob:")||t.startsWith("data:"))return t}else t="";return n.setAttribute("href",t),n.href}function xa(e,t,n,r,o,s){return r&&("src"===n||"href"===n&&("use"!==t||"#"!==r[0])||"xlink:href"===n&&"#"!==r[0]||"background"===n&&("table"===t||"td"===t||"th"===t)?mt(e,r):"srcset"===n?ih(e,r):"style"===n?xn(r,Zn(e)):"object"===t&&"data"===n?mt(e,r):"function"==typeof s?s(n,r,o):r)}function Na(e,t,n){return("video"===e||"audio"===e)&&"autoplay"===t}function ch(e,t,n,r){try{if(r&&e.matches(r))return!1;if("string"==typeof t){if(e.classList.contains(t))return!0}else for(let n=e.classList.length;n--;){const r=e.classList[n];if(t.test(r))return!0}if(n)return e.matches(n)}catch{}return!1}function uh(e,t){for(let n=e.classList.length;n--;){const r=e.classList[n];if(t.test(r))return!0}return!1}function tt(e,t,n=1/0,r=0){return!e||e.nodeType!==e.ELEMENT_NODE||r>n?-1:t(e)?r:tt(e.parentNode,t,n,r+1)}function _t(e,t){return n=>{const r=n;if(null===r)return!1;try{if(e)if("string"==typeof e){if(r.matches(`.${e}`))return!0}else if(uh(r,e))return!0;return!(!t||!r.matches(t))}catch{return!1}}}function Rt(e,t,n,r,o,s){try{const i=e.nodeType===e.ELEMENT_NODE?e:e.parentElement;if(null===i)return!1;if("INPUT"===i.tagName){const e=i.getAttribute("autocomplete");if(["current-password","new-password","cc-number","cc-exp","cc-exp-month","cc-exp-year","cc-csc"].includes(e))return!0}let a=-1,c=-1;if(s){if(c=tt(i,_t(r,o)),c<0)return!0;a=tt(i,_t(t,n),c>=0?c:1/0)}else{if(a=tt(i,_t(t,n)),a<0)return!1;c=tt(i,_t(r,o),a>=0?a:1/0)}return a>=0?!(c>=0)||a<=c:!(c>=0)&&!!s}catch{}return!!s}function lh(e,t,n){const r=e.contentWindow;if(!r)return;let o,s=!1;try{o=r.document.readyState}catch{return}if("complete"!==o){const r=Qr((()=>{s||(t(),s=!0)}),n);return void e.addEventListener("load",(()=>{Da(r),s=!0,t()}))}const i="about:blank";if(r.location.href!==i||e.src===i||""===e.src)return Qr(t,0),e.addEventListener("load",t);e.addEventListener("load",t)}function dh(e,t,n){let r,o=!1;try{r=e.sheet}catch{return}if(r)return;const s=Qr((()=>{o||(t(),o=!0)}),n);e.addEventListener("load",(()=>{Da(s),o=!0,t()}))}function fh(e,t){const{doc:n,mirror:r,blockClass:o,blockSelector:s,unblockSelector:i,maskAllText:a,maskAttributeFn:c,maskTextClass:u,unmaskTextClass:l,maskTextSelector:d,unmaskTextSelector:p,inlineStylesheet:h,maskInputOptions:m={},maskTextFn:f,maskInputFn:y,dataURLOptions:_={},inlineImages:g,recordCanvas:v,keepIframeSrcFn:b,newlyAddedElement:S=!1}=t,E=ph(n,r);switch(e.nodeType){case e.DOCUMENT_NODE:return"CSS1Compat"!==e.compatMode?{type:ce.Document,childNodes:[],compatMode:e.compatMode}:{type:ce.Document,childNodes:[]};case e.DOCUMENT_TYPE_NODE:return{type:ce.DocumentType,name:e.name,publicId:e.publicId,systemId:e.systemId,rootId:E};case e.ELEMENT_NODE:return mh(e,{doc:n,blockClass:o,blockSelector:s,unblockSelector:i,inlineStylesheet:h,maskAttributeFn:c,maskInputOptions:m,maskInputFn:y,dataURLOptions:_,inlineImages:g,recordCanvas:v,keepIframeSrcFn:b,newlyAddedElement:S,rootId:E,maskAllText:a,maskTextClass:u,unmaskTextClass:l,maskTextSelector:d,unmaskTextSelector:p});case e.TEXT_NODE:return hh(e,{doc:n,maskAllText:a,maskTextClass:u,unmaskTextClass:l,maskTextSelector:d,unmaskTextSelector:p,maskTextFn:f,maskInputOptions:m,maskInputFn:y,rootId:E});case e.CDATA_SECTION_NODE:return{type:ce.CDATA,textContent:"",rootId:E};case e.COMMENT_NODE:return{type:ce.Comment,textContent:e.textContent||"",rootId:E};default:return!1}}function ph(e,t){if(!t.hasNode(e))return;const n=t.getId(e);return 1===n?void 0:n}function hh(e,t){const{maskAllText:n,maskTextClass:r,unmaskTextClass:o,maskTextSelector:s,unmaskTextSelector:i,maskTextFn:a,maskInputOptions:c,maskInputFn:u,rootId:l}=t,d=e.parentNode&&e.parentNode.tagName;let p=e.textContent;const h="STYLE"===d||void 0,m="SCRIPT"===d||void 0,f="TEXTAREA"===d||void 0;if(h&&p){try{e.nextSibling||e.previousSibling||Bt([e,"access",e=>e.parentNode,"access",e=>e.sheet,"optionalAccess",e=>e.cssRules])&&(p=Dn(e.parentNode.sheet))}catch(t){console.warn(`Cannot get CSS styles from text's parentNode. Error: ${t}`,e)}p=xn(p,Zn(t.doc))}m&&(p="SCRIPT_PLACEHOLDER");const y=Rt(e,r,s,o,i,n);if(!h&&!m&&!f&&p&&y&&(p=a?a(p,e.parentElement):p.replace(/[\S]/g,"*")),f&&p&&(c.textarea||y)&&(p=u?u(p,e.parentNode):p.replace(/[\S]/g,"*")),"OPTION"===d&&p){p=$t({isMasked:Rt(e,r,s,o,i,Qn({type:null,tagName:d,maskInputOptions:c})),element:e,value:p,maskInputFn:u})}return{type:ce.Text,textContent:p||"",isStyle:h,rootId:l}}function mh(e,t){const{doc:n,blockClass:r,blockSelector:o,unblockSelector:s,inlineStylesheet:i,maskInputOptions:a={},maskAttributeFn:c,maskInputFn:u,dataURLOptions:l={},inlineImages:d,recordCanvas:p,keepIframeSrcFn:h,newlyAddedElement:m=!1,rootId:f,maskAllText:y,maskTextClass:_,unmaskTextClass:g,maskTextSelector:v,unmaskTextSelector:b}=t,S=ch(e,r,o,s),E=Qp(e);let k={};const w=e.attributes.length;for(let t=0;t<w;t++){const r=e.attributes[t];r.name&&!Na(E,r.name,r.value)&&(k[r.name]=xa(n,E,kt(r.name),r.value,e,c))}if("link"===E&&i){const t=Array.from(n.styleSheets).find((t=>t.href===e.href));let r=null;t&&(r=Dn(t)),r&&(k.rel=null,k.href=null,k.crossorigin=null,k._cssText=xn(r,t.href))}if("style"===E&&e.sheet&&!(e.innerText||e.textContent||"").trim().length){const t=Dn(e.sheet);t&&(k._cssText=xn(t,Zn(n)))}if("input"===E||"textarea"===E||"select"===E||"option"===E){const t=e,n=xs(t),r=An(t,Xr(E),n),o=t.checked;if("submit"!==n&&"button"!==n&&r){const e=Rt(t,_,v,g,b,Qn({type:n,tagName:Xr(E),maskInputOptions:a}));k.value=$t({isMasked:e,element:t,value:r,maskInputFn:u})}o&&(k.checked=o)}if("option"===E&&(e.selected&&!a.select?k.selected=!0:delete k.selected),"canvas"===E&&p)if("2d"===e.__context)Vp(e)||(k.rr_dataURL=e.toDataURL(l.type,l.quality));else if(!("__context"in e)){const t=e.toDataURL(l.type,l.quality),r=n.createElement("canvas");r.width=e.width,r.height=e.height;t!==r.toDataURL(l.type,l.quality)&&(k.rr_dataURL=t)}if("img"===E&&d){ft||(ft=n.createElement("canvas"),Ho=ft.getContext("2d"));const t=e,r=t.currentSrc||t.getAttribute("src")||"<unknown-src>",o=t.crossOrigin,s=()=>{t.removeEventListener("load",s);try{ft.width=t.naturalWidth,ft.height=t.naturalHeight,Ho.drawImage(t,0,0),k.rr_dataURL=ft.toDataURL(l.type,l.quality)}catch(e){if("anonymous"!==t.crossOrigin)return t.crossOrigin="anonymous",void(t.complete&&0!==t.naturalWidth?s():t.addEventListener("load",s));console.warn(`Cannot inline img src=${r}! Error: ${e}`)}"anonymous"===t.crossOrigin&&(o?k.crossOrigin=o:t.removeAttribute("crossorigin"))};t.complete&&0!==t.naturalWidth?s():t.addEventListener("load",s)}if(("audio"===E||"video"===E)&&(k.rr_mediaState=e.paused?"paused":"played",k.rr_mediaCurrentTime=e.currentTime),m||(e.scrollLeft&&(k.rr_scrollLeft=e.scrollLeft),e.scrollTop&&(k.rr_scrollTop=e.scrollTop)),S){const{width:t,height:n}=e.getBoundingClientRect();k={class:k.class,rr_width:`${t}px`,rr_height:`${n}px`}}let T;"iframe"===E&&!h(k.src)&&(!S&&!Aa(e)&&(k.rr_src=k.src),delete k.src);try{customElements.get(E)&&(T=!0)}catch{}return{type:ce.Element,tagName:E,attributes:k,childNodes:[],isSVG:ah(e)||void 0,needBlock:S,rootId:f,isCustom:T}}function Z(e){return null==e?"":e.toLowerCase()}function _h(e,t){if(t.comment&&e.type===ce.Comment)return!0;if(e.type===ce.Element){if(t.script&&("script"===e.tagName||"link"===e.tagName&&("preload"===e.attributes.rel||"modulepreload"===e.attributes.rel)||"link"===e.tagName&&"prefetch"===e.attributes.rel&&"string"==typeof e.attributes.href&&"js"===Ma(e.attributes.href)))return!0;if(t.headFavicon&&("link"===e.tagName&&"shortcut icon"===e.attributes.rel||"meta"===e.tagName&&(Z(e.attributes.name).match(/^msapplication-tile(image|color)$/)||"application-name"===Z(e.attributes.name)||"icon"===Z(e.attributes.rel)||"apple-touch-icon"===Z(e.attributes.rel)||"shortcut icon"===Z(e.attributes.rel))))return!0;if("meta"===e.tagName){if(t.headMetaDescKeywords&&Z(e.attributes.name).match(/^description|keywords$/))return!0;if(t.headMetaSocial&&(Z(e.attributes.property).match(/^(og|twitter|fb):/)||Z(e.attributes.name).match(/^(og|twitter):/)||"pinterest"===Z(e.attributes.name)))return!0;if(t.headMetaRobots&&("robots"===Z(e.attributes.name)||"googlebot"===Z(e.attributes.name)||"bingbot"===Z(e.attributes.name)))return!0;if(t.headMetaHttpEquiv&&void 0!==e.attributes["http-equiv"])return!0;if(t.headMetaAuthorship&&("author"===Z(e.attributes.name)||"generator"===Z(e.attributes.name)||"framework"===Z(e.attributes.name)||"publisher"===Z(e.attributes.name)||"progid"===Z(e.attributes.name)||Z(e.attributes.property).match(/^article:/)||Z(e.attributes.property).match(/^product:/)))return!0;if(t.headMetaVerification&&("google-site-verification"===Z(e.attributes.name)||"yandex-verification"===Z(e.attributes.name)||"csrf-token"===Z(e.attributes.name)||"p:domain_verify"===Z(e.attributes.name)||"verify-v1"===Z(e.attributes.name)||"verification"===Z(e.attributes.name)||"shopify-checkout-api-token"===Z(e.attributes.name)))return!0}}return!1}function gt(e,t){const{doc:n,mirror:r,blockClass:o,blockSelector:s,unblockSelector:i,maskAllText:a,maskTextClass:c,unmaskTextClass:u,maskTextSelector:l,unmaskTextSelector:d,skipChild:p=!1,inlineStylesheet:h=!0,maskInputOptions:m={},maskAttributeFn:f,maskTextFn:y,maskInputFn:_,slimDOMOptions:g,dataURLOptions:v={},inlineImages:b=!1,recordCanvas:S=!1,onSerialize:E,onIframeLoad:k,iframeLoadTimeout:w=5e3,onStylesheetLoad:T,stylesheetLoadTimeout:I=5e3,keepIframeSrcFn:C=()=>!1,newlyAddedElement:x=!1}=t;let{preserveWhiteSpace:M=!0}=t;const O=fh(e,{doc:n,mirror:r,blockClass:o,blockSelector:s,maskAllText:a,unblockSelector:i,maskTextClass:c,unmaskTextClass:u,maskTextSelector:l,unmaskTextSelector:d,inlineStylesheet:h,maskInputOptions:m,maskAttributeFn:f,maskTextFn:y,maskInputFn:_,dataURLOptions:v,inlineImages:b,recordCanvas:S,keepIframeSrcFn:C,newlyAddedElement:x});if(!O)return console.warn(e,"not serialized"),null;let A;A=r.hasNode(e)?r.getId(e):_h(O,g)||!M&&O.type===ce.Text&&!O.isStyle&&!O.textContent.replace(/^\s+|\s+$/gm,"").length?-2:Ns();const R=Object.assign(O,{id:A});if(r.add(e,R),-2===A)return null;E&&E(e);let D=!p;if(R.type===ce.Element){D=D&&!R.needBlock,delete R.needBlock;const t=e.shadowRoot;t&&Ft(t)&&(R.isShadowHost=!0)}if((R.type===ce.Document||R.type===ce.Element)&&D){g.headWhitespace&&R.type===ce.Element&&"head"===R.tagName&&(M=!1);const t={doc:n,mirror:r,blockClass:o,blockSelector:s,maskAllText:a,unblockSelector:i,maskTextClass:c,unmaskTextClass:u,maskTextSelector:l,unmaskTextSelector:d,skipChild:p,inlineStylesheet:h,maskInputOptions:m,maskAttributeFn:f,maskTextFn:y,maskInputFn:_,slimDOMOptions:g,dataURLOptions:v,inlineImages:b,recordCanvas:S,preserveWhiteSpace:M,onSerialize:E,onIframeLoad:k,iframeLoadTimeout:w,onStylesheetLoad:T,stylesheetLoadTimeout:I,keepIframeSrcFn:C};for(const n of Array.from(e.childNodes)){const e=gt(n,t);e&&R.childNodes.push(e)}if($p(e)&&e.shadowRoot)for(const n of Array.from(e.shadowRoot.childNodes)){const r=gt(n,t);r&&(Ft(e.shadowRoot)&&(r.isShadow=!0),R.childNodes.push(r))}}return e.parentNode&&Lt(e.parentNode)&&Ft(e.parentNode)&&(R.isShadow=!0),R.type===ce.Element&&"iframe"===R.tagName&&lh(e,(()=>{const t=Aa(e);if(t&&k){const n=gt(t,{doc:t,mirror:r,blockClass:o,blockSelector:s,unblockSelector:i,maskAllText:a,maskTextClass:c,unmaskTextClass:u,maskTextSelector:l,unmaskTextSelector:d,skipChild:!1,inlineStylesheet:h,maskInputOptions:m,maskAttributeFn:f,maskTextFn:y,maskInputFn:_,slimDOMOptions:g,dataURLOptions:v,inlineImages:b,recordCanvas:S,preserveWhiteSpace:M,onSerialize:E,onIframeLoad:k,iframeLoadTimeout:w,onStylesheetLoad:T,stylesheetLoadTimeout:I,keepIframeSrcFn:C});n&&k(e,n)}}),w),R.type===ce.Element&&"link"===R.tagName&&"string"==typeof R.attributes.rel&&("stylesheet"===R.attributes.rel||"preload"===R.attributes.rel&&"string"==typeof R.attributes.href&&"css"===Ma(R.attributes.href))&&dh(e,(()=>{if(T){const t=gt(e,{doc:n,mirror:r,blockClass:o,blockSelector:s,unblockSelector:i,maskAllText:a,maskTextClass:c,unmaskTextClass:u,maskTextSelector:l,unmaskTextSelector:d,skipChild:!1,inlineStylesheet:h,maskInputOptions:m,maskAttributeFn:f,maskTextFn:y,maskInputFn:_,slimDOMOptions:g,dataURLOptions:v,inlineImages:b,recordCanvas:S,preserveWhiteSpace:M,onSerialize:E,onIframeLoad:k,iframeLoadTimeout:w,onStylesheetLoad:T,stylesheetLoadTimeout:I,keepIframeSrcFn:C});t&&T(e,t)}}),I),R}function gh(e,t){const{mirror:n=new Ca,blockClass:r="rr-block",blockSelector:o=null,unblockSelector:s=null,maskAllText:i=!1,maskTextClass:a="rr-mask",unmaskTextClass:c=null,maskTextSelector:u=null,unmaskTextSelector:l=null,inlineStylesheet:d=!0,inlineImages:p=!1,recordCanvas:h=!1,maskAllInputs:m=!1,maskAttributeFn:f,maskTextFn:y,maskInputFn:_,slimDOM:g=!1,dataURLOptions:v,preserveWhiteSpace:b,onSerialize:S,onIframeLoad:E,iframeLoadTimeout:k,onStylesheetLoad:w,stylesheetLoadTimeout:T,keepIframeSrcFn:I=()=>!1}=t;return gt(e,{doc:e,mirror:n,blockClass:r,blockSelector:o,unblockSelector:s,maskAllText:i,maskTextClass:a,unmaskTextClass:c,maskTextSelector:u,unmaskTextSelector:l,skipChild:!1,inlineStylesheet:d,maskInputOptions:!0===m?{color:!0,date:!0,"datetime-local":!0,email:!0,month:!0,number:!0,range:!0,search:!0,tel:!0,text:!0,time:!0,url:!0,week:!0,textarea:!0,select:!0}:!1===m?{}:m,maskAttributeFn:f,maskTextFn:y,maskInputFn:_,slimDOMOptions:!0===g||"all"===g?{script:!0,comment:!0,headFavicon:!0,headWhitespace:!0,headMetaDescKeywords:"all"===g,headMetaSocial:!0,headMetaRobots:!0,headMetaHttpEquiv:!0,headMetaAuthorship:!0,headMetaVerification:!0}:!1===g?{}:g,dataURLOptions:v,inlineImages:p,recordCanvas:h,preserveWhiteSpace:b,onSerialize:S,onIframeLoad:E,iframeLoadTimeout:k,onStylesheetLoad:w,stylesheetLoadTimeout:T,keepIframeSrcFn:I,newlyAddedElement:!1})}function ze(e){let t,n=e[0],r=1;for(;r<e.length;){const o=e[r],s=e[r+1];if(r+=2,("optionalAccess"===o||"optionalCall"===o)&&null==n)return;"access"===o||"optionalAccess"===o?(t=n,n=s(n)):("call"===o||"optionalCall"===o)&&(n=s(((...e)=>n.call(t,...e))),t=void 0)}return n}function de(e,t,n=document){const r={capture:!0,passive:!0};return n.addEventListener(e,t,r),()=>n.removeEventListener(e,t,r)}const pt="Please stop import mirror directly. Instead of that,\r\nnow you can use replayer.getMirror() to access the mirror instance of a replayer,\r\nor you can use record.mirror to access the mirror instance during recording.";let Wo={map:{},getId:()=>(console.error(pt),-1),getNode:()=>(console.error(pt),null),removeNodeFromMap(){console.error(pt)},has:()=>(console.error(pt),!1),reset(){console.error(pt)}};function zt(e,t,n={}){let r=null,o=0;return function(...s){const i=Date.now();!o&&!1===n.leading&&(o=i);const a=t-(i-o),c=this;a<=0||a>t?(r&&(wh(r),r=null),o=i,e.apply(c,s)):!r&&!1!==n.trailing&&(r=er((()=>{o=!1===n.leading?0:Date.now(),r=null,e.apply(c,s)}),a))}}function Pa(e,t,n,r,o=window){const s=o.Object.getOwnPropertyDescriptor(e,t);return o.Object.defineProperty(e,t,r?n:{set(e){er((()=>{n.set.call(this,e)}),0),s&&s.set&&s.set.call(this,e)}}),()=>Pa(e,t,s||{},!0)}function Ps(e,t,n){try{if(!(t in e))return()=>{};const r=e[t],o=n(r);return"function"==typeof o&&(o.prototype=o.prototype||{},Object.defineProperties(o,{__rrweb_original__:{enumerable:!1,value:r}})),e[t]=o,()=>{e[t]=r}}catch{return()=>{}}}typeof window<"u"&&window.Proxy&&window.Reflect&&(Wo=new Proxy(Wo,{get:(e,t,n)=>("map"===t&&console.error(pt),Reflect.get(e,t,n))}));let Nn=Date.now;function La(e){const t=e.document;return{left:t.scrollingElement?t.scrollingElement.scrollLeft:void 0!==e.pageXOffset?e.pageXOffset:ze([t,"optionalAccess",e=>e.documentElement,"access",e=>e.scrollLeft])||ze([t,"optionalAccess",e=>e.body,"optionalAccess",e=>e.parentElement,"optionalAccess",e=>e.scrollLeft])||ze([t,"optionalAccess",e=>e.body,"optionalAccess",e=>e.scrollLeft])||0,top:t.scrollingElement?t.scrollingElement.scrollTop:void 0!==e.pageYOffset?e.pageYOffset:ze([t,"optionalAccess",e=>e.documentElement,"access",e=>e.scrollTop])||ze([t,"optionalAccess",e=>e.body,"optionalAccess",e=>e.parentElement,"optionalAccess",e=>e.scrollTop])||ze([t,"optionalAccess",e=>e.body,"optionalAccess",e=>e.scrollTop])||0}}function Fa(){return window.innerHeight||document.documentElement&&document.documentElement.clientHeight||document.body&&document.body.clientHeight}function Ua(){return window.innerWidth||document.documentElement&&document.documentElement.clientWidth||document.body&&document.body.clientWidth}function ja(e){return e?e.nodeType===e.ELEMENT_NODE?e:e.parentElement:null}function _e(e,t,n,r,o){if(!e)return!1;const s=ja(e);if(!s)return!1;const i=_t(t,n);if(!o){const e=r&&s.matches(r);return i(s)&&!e}const a=tt(s,i);let c=-1;return!(a<0)&&(r&&(c=tt(s,_t(null,r))),a>-1&&c<0||a<c)}function yh(e,t){return-1!==t.getId(e)}function br(e,t){return-2===t.getId(e)}function Ba(e,t){if(Lt(e))return!1;const n=t.getId(e);return!t.has(n)||(!e.parentNode||e.parentNode.nodeType!==e.DOCUMENT_NODE)&&(!e.parentNode||Ba(e.parentNode,t))}function Zr(e){return!!e.changedTouches}function Eh(e=window){"NodeList"in e&&!e.NodeList.prototype.forEach&&(e.NodeList.prototype.forEach=Array.prototype.forEach),"DOMTokenList"in e&&!e.DOMTokenList.prototype.forEach&&(e.DOMTokenList.prototype.forEach=Array.prototype.forEach),Node.prototype.contains||(Node.prototype.contains=(...e)=>{let t=e[0];if(!(0 in e))throw new TypeError("1 argument is required");do{if(this===t)return!0}while(t=t&&t.parentNode);return!1})}function $a(e,t){return!("IFRAME"!==e.nodeName||!t.getMeta(e))}function Ha(e,t){return!("LINK"!==e.nodeName||e.nodeType!==e.ELEMENT_NODE||!e.getAttribute||"stylesheet"!==e.getAttribute("rel")||!t.getMeta(e))}function es(e){return!!ze([e,"optionalAccess",e=>e.shadowRoot])}/[1-9][0-9]{12}/.test(Date.now().toString())||(Nn=()=>(new Date).getTime());class Sh{constructor(){this.id=1,this.styleIDMap=new WeakMap,this.idStyleMap=new Map}getId(e){return Rd(this.styleIDMap.get(e),(()=>-1))}has(e){return this.styleIDMap.has(e)}add(e,t){if(this.has(e))return this.getId(e);let n;return n=void 0===t?this.id++:t,this.styleIDMap.set(e,n),this.idStyleMap.set(n,e),n}getStyle(e){return this.idStyleMap.get(e)||null}reset(){this.styleIDMap=new WeakMap,this.idStyleMap=new Map,this.id=1}generateId(){return this.id++}}function za(e){let t=null;return ze([e,"access",e=>e.getRootNode,"optionalCall",e=>e(),"optionalAccess",e=>e.nodeType])===Node.DOCUMENT_FRAGMENT_NODE&&e.getRootNode().host&&(t=e.getRootNode().host),t}function bh(e){let t,n=e;for(;t=za(n);)n=t;return n}function vh(e){const t=e.ownerDocument;if(!t)return!1;const n=bh(e);return t.contains(n)}function Wa(e){const t=e.ownerDocument;return!!t&&(t.contains(e)||vh(e))}const Go={};function Ls(e){const t=Go[e];if(t)return t;const n=window.document;let r=window[e];if(n&&"function"==typeof n.createElement)try{const t=n.createElement("iframe");t.hidden=!0,n.head.appendChild(t);const o=t.contentWindow;o&&o[e]&&(r=o[e]),n.head.removeChild(t)}catch{}return Go[e]=r.bind(window)}function Ih(...e){return Ls("requestAnimationFrame")(...e)}function er(...e){return Ls("setTimeout")(...e)}function wh(...e){return Ls("clearTimeout")(...e)}var Yo,Ko,x=(e=>(e[e.DomContentLoaded=0]="DomContentLoaded",e[e.Load=1]="Load",e[e.FullSnapshot=2]="FullSnapshot",e[e.IncrementalSnapshot=3]="IncrementalSnapshot",e[e.Meta=4]="Meta",e[e.Custom=5]="Custom",e[e.Plugin=6]="Plugin",e))(x||{}),A=(e=>(e[e.Mutation=0]="Mutation",e[e.MouseMove=1]="MouseMove",e[e.MouseInteraction=2]="MouseInteraction",e[e.Scroll=3]="Scroll",e[e.ViewportResize=4]="ViewportResize",e[e.Input=5]="Input",e[e.TouchMove=6]="TouchMove",e[e.MediaInteraction=7]="MediaInteraction",e[e.StyleSheetRule=8]="StyleSheetRule",e[e.CanvasMutation=9]="CanvasMutation",e[e.Font=10]="Font",e[e.Log=11]="Log",e[e.Drag=12]="Drag",e[e.StyleDeclaration=13]="StyleDeclaration",e[e.Selection=14]="Selection",e[e.AdoptedStyleSheet=15]="AdoptedStyleSheet",e[e.CustomElement=16]="CustomElement",e))(A||{}),le=(e=>(e[e.MouseUp=0]="MouseUp",e[e.MouseDown=1]="MouseDown",e[e.Click=2]="Click",e[e.ContextMenu=3]="ContextMenu",e[e.DblClick=4]="DblClick",e[e.Focus=5]="Focus",e[e.Blur=6]="Blur",e[e.TouchStart=7]="TouchStart",e[e.TouchMove_Departed=8]="TouchMove_Departed",e[e.TouchEnd=9]="TouchEnd",e[e.TouchCancel=10]="TouchCancel",e))(le||{}),xe=(e=>(e[e.Mouse=0]="Mouse",e[e.Pen=1]="Pen",e[e.Touch=2]="Touch",e))(xe||{});function Fs(e){try{return e.contentDocument}catch{}}function Th(e){try{return e.contentWindow}catch{}}function kh(e){let t,n=e[0],r=1;for(;r<e.length;){const o=e[r],s=e[r+1];if(r+=2,("optionalAccess"===o||"optionalCall"===o)&&null==n)return;"access"===o||"optionalAccess"===o?(t=n,n=s(n)):("call"===o||"optionalCall"===o)&&(n=s(((...e)=>n.call(t,...e))),t=void 0)}return n}function qo(e){return"__ln"in e}!function(e){e[e.Document=0]="Document",e[e.DocumentType=1]="DocumentType",e[e.Element=2]="Element",e[e.Text=3]="Text",e[e.CDATA=4]="CDATA",e[e.Comment=5]="Comment"}(Yo||(Yo={})),function(e){e[e.PLACEHOLDER=0]="PLACEHOLDER",e[e.ELEMENT_NODE=1]="ELEMENT_NODE",e[e.ATTRIBUTE_NODE=2]="ATTRIBUTE_NODE",e[e.TEXT_NODE=3]="TEXT_NODE",e[e.CDATA_SECTION_NODE=4]="CDATA_SECTION_NODE",e[e.ENTITY_REFERENCE_NODE=5]="ENTITY_REFERENCE_NODE",e[e.ENTITY_NODE=6]="ENTITY_NODE",e[e.PROCESSING_INSTRUCTION_NODE=7]="PROCESSING_INSTRUCTION_NODE",e[e.COMMENT_NODE=8]="COMMENT_NODE",e[e.DOCUMENT_NODE=9]="DOCUMENT_NODE",e[e.DOCUMENT_TYPE_NODE=10]="DOCUMENT_TYPE_NODE",e[e.DOCUMENT_FRAGMENT_NODE=11]="DOCUMENT_FRAGMENT_NODE"}(Ko||(Ko={}));class Rh{constructor(){this.length=0,this.head=null,this.tail=null}get(e){if(e>=this.length)throw new Error("Position outside of list range");let t=this.head;for(let n=0;n<e;n++)t=kh([t,"optionalAccess",e=>e.next])||null;return t}addNode(e){const t={value:e,previous:null,next:null};if(e.__ln=t,e.previousSibling&&qo(e.previousSibling)){const n=e.previousSibling.__ln.next;t.next=n,t.previous=e.previousSibling.__ln,e.previousSibling.__ln.next=t,n&&(n.previous=t)}else if(e.nextSibling&&qo(e.nextSibling)&&e.nextSibling.__ln.previous){const n=e.nextSibling.__ln.previous;t.previous=n,t.next=e.nextSibling.__ln,e.nextSibling.__ln.previous=t,n&&(n.next=t)}else this.head&&(this.head.previous=t),t.next=this.head,this.head=t;null===t.next&&(this.tail=t),this.length++}removeNode(e){const t=e.__ln;this.head&&(t.previous?(t.previous.next=t.next,t.next?t.next.previous=t.previous:this.tail=t.previous):(this.head=t.next,this.head?this.head.previous=null:this.tail=null),e.__ln&&delete e.__ln,this.length--)}}const Vo=(e,t)=>`${e}@${t}`;class Ch{constructor(){this.frozen=!1,this.locked=!1,this.texts=[],this.attributes=[],this.attributeMap=new WeakMap,this.removes=[],this.mapRemoves=[],this.movedMap={},this.addedSet=new Set,this.movedSet=new Set,this.droppedSet=new Set,this.processMutations=e=>{e.forEach(this.processMutation),this.emit()},this.emit=()=>{if(this.frozen||this.locked)return;const e=[],t=new Set,n=new Rh,r=e=>{let t=e,n=-2;for(;-2===n;)t=t&&t.nextSibling,n=t&&this.mirror.getId(t);return n},o=o=>{if(!o.parentNode||!Wa(o))return;const s=Lt(o.parentNode)?this.mirror.getId(za(o)):this.mirror.getId(o.parentNode),i=r(o);if(-1===s||-1===i)return n.addNode(o);const a=gt(o,{doc:this.doc,mirror:this.mirror,blockClass:this.blockClass,blockSelector:this.blockSelector,maskAllText:this.maskAllText,unblockSelector:this.unblockSelector,maskTextClass:this.maskTextClass,unmaskTextClass:this.unmaskTextClass,maskTextSelector:this.maskTextSelector,unmaskTextSelector:this.unmaskTextSelector,skipChild:!0,newlyAddedElement:!0,inlineStylesheet:this.inlineStylesheet,maskInputOptions:this.maskInputOptions,maskAttributeFn:this.maskAttributeFn,maskTextFn:this.maskTextFn,maskInputFn:this.maskInputFn,slimDOMOptions:this.slimDOMOptions,dataURLOptions:this.dataURLOptions,recordCanvas:this.recordCanvas,inlineImages:this.inlineImages,onSerialize:e=>{$a(e,this.mirror)&&!_e(e,this.blockClass,this.blockSelector,this.unblockSelector,!1)&&this.iframeManager.addIframe(e),Ha(e,this.mirror)&&this.stylesheetManager.trackLinkElement(e),es(o)&&this.shadowDomManager.addShadowRoot(o.shadowRoot,this.doc)},onIframeLoad:(e,t)=>{_e(e,this.blockClass,this.blockSelector,this.unblockSelector,!1)||(this.iframeManager.attachIframe(e,t),e.contentWindow&&this.canvasManager.addWindow(e.contentWindow),this.shadowDomManager.observeAttachShadow(e))},onStylesheetLoad:(e,t)=>{this.stylesheetManager.attachLinkElement(e,t)}});a&&(e.push({parentId:s,nextId:i,node:a}),t.add(a.id))};for(;this.mapRemoves.length;)this.mirror.removeNodeFromMap(this.mapRemoves.shift());for(const e of this.movedSet)Jo(this.removes,e,this.mirror)&&!this.movedSet.has(e.parentNode)||o(e);for(const e of this.addedSet)!Xo(this.droppedSet,e)&&!Jo(this.removes,e,this.mirror)||Xo(this.movedSet,e)?o(e):this.droppedSet.add(e);let s=null;for(;n.length;){let e=null;if(s){const t=this.mirror.getId(s.value.parentNode),n=r(s.value);-1!==t&&-1!==n&&(e=s)}if(!e){let t=n.tail;for(;t;){const n=t;if(t=t.previous,n){const t=this.mirror.getId(n.value.parentNode);if(-1===r(n.value))continue;if(-1!==t){e=n;break}{const t=n.value;if(t.parentNode&&t.parentNode.nodeType===Node.DOCUMENT_FRAGMENT_NODE){const r=t.parentNode.host;if(-1!==this.mirror.getId(r)){e=n;break}}}}}}if(!e){for(;n.head;)n.removeNode(n.head.value);break}s=e.previous,n.removeNode(e.value),o(e.value)}const i={texts:this.texts.map((e=>({id:this.mirror.getId(e.node),value:e.value}))).filter((e=>!t.has(e.id))).filter((e=>this.mirror.has(e.id))),attributes:this.attributes.map((e=>{const{attributes:t}=e;if("string"==typeof t.style){const n=JSON.stringify(e.styleDiff),r=JSON.stringify(e._unchangedStyles);n.length<t.style.length&&(n+r).split("var(").length===t.style.split("var(").length&&(t.style=e.styleDiff)}return{id:this.mirror.getId(e.node),attributes:t}})).filter((e=>!t.has(e.id))).filter((e=>this.mirror.has(e.id))),removes:this.removes,adds:e};!i.texts.length&&!i.attributes.length&&!i.removes.length&&!i.adds.length||(this.texts=[],this.attributes=[],this.attributeMap=new WeakMap,this.removes=[],this.addedSet=new Set,this.movedSet=new Set,this.droppedSet=new Set,this.movedMap={},this.mutationCb(i))},this.processMutation=e=>{if(!br(e.target,this.mirror))switch(e.type){case"characterData":{const t=e.target.textContent;!_e(e.target,this.blockClass,this.blockSelector,this.unblockSelector,!1)&&t!==e.oldValue&&this.texts.push({value:Rt(e.target,this.maskTextClass,this.maskTextSelector,this.unmaskTextClass,this.unmaskTextSelector,this.maskAllText)&&t?this.maskTextFn?this.maskTextFn(t,ja(e.target)):t.replace(/[\S]/g,"*"):t,node:e.target});break}case"attributes":{const t=e.target;let n=e.attributeName,r=e.target.getAttribute(n);if("value"===n){const n=xs(t),o=t.tagName;r=An(t,o,n);const s=Qn({maskInputOptions:this.maskInputOptions,tagName:o,type:n});r=$t({isMasked:Rt(e.target,this.maskTextClass,this.maskTextSelector,this.unmaskTextClass,this.unmaskTextSelector,s),element:t,value:r,maskInputFn:this.maskInputFn})}if(_e(e.target,this.blockClass,this.blockSelector,this.unblockSelector,!1)||r===e.oldValue)return;let o=this.attributeMap.get(e.target);if("IFRAME"===t.tagName&&"src"===n&&!this.keepIframeSrcFn(r)){if(Fs(t))return;n="rr_src"}if(o||(o={node:e.target,attributes:{},styleDiff:{},_unchangedStyles:{}},this.attributes.push(o),this.attributeMap.set(e.target,o)),"type"===n&&"INPUT"===t.tagName&&"password"===(e.oldValue||"").toLowerCase()&&t.setAttribute("data-rr-is-password","true"),!Na(t.tagName,n)&&(o.attributes[n]=xa(this.doc,kt(t.tagName),kt(n),r,t,this.maskAttributeFn),"style"===n)){if(!this.unattachedDoc)try{this.unattachedDoc=document.implementation.createHTMLDocument()}catch{this.unattachedDoc=this.doc}const n=this.unattachedDoc.createElement("span");e.oldValue&&n.setAttribute("style",e.oldValue);for(const e of Array.from(t.style)){const r=t.style.getPropertyValue(e),s=t.style.getPropertyPriority(e);r!==n.style.getPropertyValue(e)||s!==n.style.getPropertyPriority(e)?o.styleDiff[e]=""===s?r:[r,s]:o._unchangedStyles[e]=[r,s]}for(const e of Array.from(n.style))""===t.style.getPropertyValue(e)&&(o.styleDiff[e]=!1)}break}case"childList":if(_e(e.target,this.blockClass,this.blockSelector,this.unblockSelector,!0))return;e.addedNodes.forEach((t=>this.genAdds(t,e.target))),e.removedNodes.forEach((t=>{const n=this.mirror.getId(t),r=Lt(e.target)?this.mirror.getId(e.target.host):this.mirror.getId(e.target);_e(e.target,this.blockClass,this.blockSelector,this.unblockSelector,!1)||br(t,this.mirror)||!yh(t,this.mirror)||(this.addedSet.has(t)?(ts(this.addedSet,t),this.droppedSet.add(t)):this.addedSet.has(e.target)&&-1===n||Ba(e.target,this.mirror)||(this.movedSet.has(t)&&this.movedMap[Vo(n,r)]?ts(this.movedSet,t):this.removes.push({parentId:r,id:n,isShadow:!(!Lt(e.target)||!Ft(e.target))||void 0})),this.mapRemoves.push(t))}))}},this.genAdds=(e,t)=>{if(!this.processedNodeManager.inOtherBuffer(e,this)&&!this.addedSet.has(e)&&!this.movedSet.has(e)){if(this.mirror.hasNode(e)){if(br(e,this.mirror))return;this.movedSet.add(e);let n=null;t&&this.mirror.hasNode(t)&&(n=this.mirror.getId(t)),n&&-1!==n&&(this.movedMap[Vo(this.mirror.getId(e),n)]=!0)}else this.addedSet.add(e),this.droppedSet.delete(e);_e(e,this.blockClass,this.blockSelector,this.unblockSelector,!1)||(e.childNodes.forEach((e=>this.genAdds(e))),es(e)&&e.shadowRoot.childNodes.forEach((t=>{this.processedNodeManager.add(t,this),this.genAdds(t,e)})))}}}init(e){["mutationCb","blockClass","blockSelector","unblockSelector","maskAllText","maskTextClass","unmaskTextClass","maskTextSelector","unmaskTextSelector","inlineStylesheet","maskInputOptions","maskAttributeFn","maskTextFn","maskInputFn","keepIframeSrcFn","recordCanvas","inlineImages","slimDOMOptions","dataURLOptions","doc","mirror","iframeManager","stylesheetManager","shadowDomManager","canvasManager","processedNodeManager"].forEach((t=>{this[t]=e[t]}))}freeze(){this.frozen=!0,this.canvasManager.freeze()}unfreeze(){this.frozen=!1,this.canvasManager.unfreeze(),this.emit()}isFrozen(){return this.frozen}lock(){this.locked=!0,this.canvasManager.lock()}unlock(){this.locked=!1,this.canvasManager.unlock(),this.emit()}reset(){this.shadowDomManager.reset(),this.canvasManager.reset()}}function ts(e,t){e.delete(t),t.childNodes.forEach((t=>ts(e,t)))}function Jo(e,t,n){return 0!==e.length&&Mh(e,t,n)}function Mh(e,t,n){let r=t.parentNode;for(;r;){const t=n.getId(r);if(e.some((e=>e.id===t)))return!0;r=r.parentNode}return!1}function Xo(e,t){return 0!==e.size&&Ga(e,t)}function Ga(e,t){const{parentNode:n}=t;return!!n&&(!!e.has(n)||Ga(e,n))}let Ut;function Oh(e){Ut=e}function Dh(){Ut=void 0}const U=e=>Ut?(...t)=>{try{return e(...t)}catch(e){if(Ut&&!0===Ut(e))return()=>{};throw e}}:e;function ke(e){let t,n=e[0],r=1;for(;r<e.length;){const o=e[r],s=e[r+1];if(r+=2,("optionalAccess"===o||"optionalCall"===o)&&null==n)return;"access"===o||"optionalAccess"===o?(t=n,n=s(n)):("call"===o||"optionalCall"===o)&&(n=s(((...e)=>n.call(t,...e))),t=void 0)}return n}const yt=[];function nn(e){try{if("composedPath"in e){const t=e.composedPath();if(t.length)return t[0]}else if("path"in e&&e.path.length)return e.path[0]}catch{}return e&&e.target}function Ya(e,t){const n=new Ch;yt.push(n),n.init(e);let r=window.MutationObserver||window.__rrMutationObserver;const o=ke([window,"optionalAccess",e=>e.Zone,"optionalAccess",e=>e.__symbol__,"optionalCall",e=>e("MutationObserver")]);o&&window[o]&&(r=window[o]);const s=new r(U((t=>{e.onMutation&&!1===e.onMutation(t)||n.processMutations.bind(n)(t)})));return s.observe(t,{attributes:!0,attributeOldValue:!0,characterData:!0,characterDataOldValue:!0,childList:!0,subtree:!0}),s}function Ah({mousemoveCb:e,sampling:t,doc:n,mirror:r}){if(!1===t.mousemove)return()=>{};const o="number"==typeof t.mousemove?t.mousemove:50,s="number"==typeof t.mousemoveCallback?t.mousemoveCallback:500;let i,a=[];const c=zt(U((t=>{const n=Date.now()-i;e(a.map((e=>(e.timeOffset-=n,e))),t),a=[],i=null})),s),u=U(zt(U((e=>{const t=nn(e),{clientX:n,clientY:o}=Zr(e)?e.changedTouches[0]:e;i||(i=Nn()),a.push({x:n,y:o,id:r.getId(t),timeOffset:Nn()-i}),c(typeof DragEvent<"u"&&e instanceof DragEvent?A.Drag:e instanceof MouseEvent?A.MouseMove:A.TouchMove)})),o,{trailing:!1})),l=[de("mousemove",u,n),de("touchmove",u,n),de("drag",u,n)];return U((()=>{l.forEach((e=>e()))}))}function xh({mouseInteractionCb:e,doc:t,mirror:n,blockClass:r,blockSelector:o,unblockSelector:s,sampling:i}){if(!1===i.mouseInteraction)return()=>{};const a=!0===i.mouseInteraction||void 0===i.mouseInteraction?{}:i.mouseInteraction,c=[];let u=null;return Object.keys(le).filter((e=>Number.isNaN(Number(e))&&!e.endsWith("_Departed")&&!1!==a[e])).forEach((i=>{let a=kt(i);const l=(t=>i=>{const a=nn(i);if(_e(a,r,o,s,!0))return;let c=null,l=t;if("pointerType"in i){switch(i.pointerType){case"mouse":c=xe.Mouse;break;case"touch":c=xe.Touch;break;case"pen":c=xe.Pen}c===xe.Touch?le[t]===le.MouseDown?l="TouchStart":le[t]===le.MouseUp&&(l="TouchEnd"):xe.Pen}else Zr(i)&&(c=xe.Touch);null!==c?(u=c,(l.startsWith("Touch")&&c===xe.Touch||l.startsWith("Mouse")&&c===xe.Mouse)&&(c=null)):le[t]===le.Click&&(c=u,u=null);const d=Zr(i)?i.changedTouches[0]:i;if(!d)return;const p=n.getId(a),{clientX:h,clientY:m}=d;U(e)({type:le[l],id:p,x:h,y:m,...null!==c&&{pointerType:c}})})(i);if(window.PointerEvent)switch(le[i]){case le.MouseDown:case le.MouseUp:a=a.replace("mouse","pointer");break;case le.TouchStart:case le.TouchEnd:return}c.push(de(a,l,t))})),U((()=>{c.forEach((e=>e()))}))}function Ka({scrollCb:e,doc:t,mirror:n,blockClass:r,blockSelector:o,unblockSelector:s,sampling:i}){return de("scroll",U(zt(U((i=>{const a=nn(i);if(!a||_e(a,r,o,s,!0))return;const c=n.getId(a);if(a===t&&t.defaultView){const n=La(t.defaultView);e({id:c,x:n.left,y:n.top})}else e({id:c,x:a.scrollLeft,y:a.scrollTop})})),i.scroll||100)),t)}function Nh({viewportResizeCb:e},{win:t}){let n=-1,r=-1;return de("resize",U(zt(U((()=>{const t=Fa(),o=Ua();(n!==t||r!==o)&&(e({width:Number(o),height:Number(t)}),n=t,r=o)})),200)),t)}const Ph=["INPUT","TEXTAREA","SELECT"],Qo=new WeakMap;function Lh({inputCb:e,doc:t,mirror:n,blockClass:r,blockSelector:o,unblockSelector:s,ignoreClass:i,ignoreSelector:a,maskInputOptions:c,maskInputFn:u,sampling:l,userTriggeredOnInput:d,maskTextClass:p,unmaskTextClass:h,maskTextSelector:m,unmaskTextSelector:f}){function y(e){let n=nn(e);const l=e.isTrusted,y=n&&Xr(n.tagName);if("OPTION"===y&&(n=n.parentElement),!n||!y||Ph.indexOf(y)<0||_e(n,r,o,s,!0))return;const g=n;if(g.classList.contains(i)||a&&g.matches(a))return;const v=xs(n);let b=An(g,y,v),S=!1;const E=Qn({maskInputOptions:c,tagName:y,type:v}),k=Rt(n,p,m,h,f,E);("radio"===v||"checkbox"===v)&&(S=n.checked),b=$t({isMasked:k,element:n,value:b,maskInputFn:u}),_(n,d?{text:b,isChecked:S,userTriggered:l}:{text:b,isChecked:S});const w=n.name;"radio"===v&&w&&S&&t.querySelectorAll(`input[type="radio"][name="${w}"]`).forEach((e=>{if(e!==n){const t=$t({isMasked:k,element:e,value:An(e,y,v),maskInputFn:u});_(e,d?{text:t,isChecked:!S,userTriggered:!1}:{text:t,isChecked:!S})}}))}function _(t,r){const o=Qo.get(t);if(!o||o.text!==r.text||o.isChecked!==r.isChecked){Qo.set(t,r);const o=n.getId(t);U(e)({...r,id:o})}}const g=("last"===l.input?["change"]:["input","change"]).map((e=>de(e,U(y),t))),v=t.defaultView;if(!v)return()=>{g.forEach((e=>e()))};const b=v.Object.getOwnPropertyDescriptor(v.HTMLInputElement.prototype,"value"),S=[[v.HTMLInputElement.prototype,"value"],[v.HTMLInputElement.prototype,"checked"],[v.HTMLSelectElement.prototype,"value"],[v.HTMLTextAreaElement.prototype,"value"],[v.HTMLSelectElement.prototype,"selectedIndex"],[v.HTMLOptionElement.prototype,"selected"]];return b&&b.set&&g.push(...S.map((e=>Pa(e[0],e[1],{set(){U(y)({target:this,isTrusted:!1})}},!1,v)))),U((()=>{g.forEach((e=>e()))}))}function Pn(e){return function(e,t){if(_n("CSSGroupingRule")&&e.parentRule instanceof CSSGroupingRule||_n("CSSMediaRule")&&e.parentRule instanceof CSSMediaRule||_n("CSSSupportsRule")&&e.parentRule instanceof CSSSupportsRule||_n("CSSConditionRule")&&e.parentRule instanceof CSSConditionRule){const n=Array.from(e.parentRule.cssRules).indexOf(e);t.unshift(n)}else if(e.parentStyleSheet){const n=Array.from(e.parentStyleSheet.cssRules).indexOf(e);t.unshift(n)}return t}(e,[])}function We(e,t,n){let r,o;return e?(e.ownerNode?r=t.getId(e.ownerNode):o=n.getId(e),{styleId:o,id:r}):{}}function Fh({styleSheetRuleCb:e,mirror:t,stylesheetManager:n},{win:r}){if(!r.CSSStyleSheet||!r.CSSStyleSheet.prototype)return()=>{};const o=r.CSSStyleSheet.prototype.insertRule;r.CSSStyleSheet.prototype.insertRule=new Proxy(o,{apply:U(((r,o,s)=>{const[i,a]=s,{id:c,styleId:u}=We(o,t,n.styleMirror);return(c&&-1!==c||u&&-1!==u)&&e({id:c,styleId:u,adds:[{rule:i,index:a}]}),r.apply(o,s)}))});const s=r.CSSStyleSheet.prototype.deleteRule;let i,a;r.CSSStyleSheet.prototype.deleteRule=new Proxy(s,{apply:U(((r,o,s)=>{const[i]=s,{id:a,styleId:c}=We(o,t,n.styleMirror);return(a&&-1!==a||c&&-1!==c)&&e({id:a,styleId:c,removes:[{index:i}]}),r.apply(o,s)}))}),r.CSSStyleSheet.prototype.replace&&(i=r.CSSStyleSheet.prototype.replace,r.CSSStyleSheet.prototype.replace=new Proxy(i,{apply:U(((r,o,s)=>{const[i]=s,{id:a,styleId:c}=We(o,t,n.styleMirror);return(a&&-1!==a||c&&-1!==c)&&e({id:a,styleId:c,replace:i}),r.apply(o,s)}))})),r.CSSStyleSheet.prototype.replaceSync&&(a=r.CSSStyleSheet.prototype.replaceSync,r.CSSStyleSheet.prototype.replaceSync=new Proxy(a,{apply:U(((r,o,s)=>{const[i]=s,{id:a,styleId:c}=We(o,t,n.styleMirror);return(a&&-1!==a||c&&-1!==c)&&e({id:a,styleId:c,replaceSync:i}),r.apply(o,s)}))}));const c={};gn("CSSGroupingRule")?c.CSSGroupingRule=r.CSSGroupingRule:(gn("CSSMediaRule")&&(c.CSSMediaRule=r.CSSMediaRule),gn("CSSConditionRule")&&(c.CSSConditionRule=r.CSSConditionRule),gn("CSSSupportsRule")&&(c.CSSSupportsRule=r.CSSSupportsRule));const u={};return Object.entries(c).forEach((([r,o])=>{u[r]={insertRule:o.prototype.insertRule,deleteRule:o.prototype.deleteRule},o.prototype.insertRule=new Proxy(u[r].insertRule,{apply:U(((r,o,s)=>{const[i,a]=s,{id:c,styleId:u}=We(o.parentStyleSheet,t,n.styleMirror);return(c&&-1!==c||u&&-1!==u)&&e({id:c,styleId:u,adds:[{rule:i,index:[...Pn(o),a||0]}]}),r.apply(o,s)}))}),o.prototype.deleteRule=new Proxy(u[r].deleteRule,{apply:U(((r,o,s)=>{const[i]=s,{id:a,styleId:c}=We(o.parentStyleSheet,t,n.styleMirror);return(a&&-1!==a||c&&-1!==c)&&e({id:a,styleId:c,removes:[{index:[...Pn(o),i]}]}),r.apply(o,s)}))})})),U((()=>{r.CSSStyleSheet.prototype.insertRule=o,r.CSSStyleSheet.prototype.deleteRule=s,i&&(r.CSSStyleSheet.prototype.replace=i),a&&(r.CSSStyleSheet.prototype.replaceSync=a),Object.entries(c).forEach((([e,t])=>{t.prototype.insertRule=u[e].insertRule,t.prototype.deleteRule=u[e].deleteRule}))}))}function qa({mirror:e,stylesheetManager:t},n){let r=null;r="#document"===n.nodeName?e.getId(n):e.getId(n.host);const o="#document"===n.nodeName?ke([n,"access",e=>e.defaultView,"optionalAccess",e=>e.Document]):ke([n,"access",e=>e.ownerDocument,"optionalAccess",e=>e.defaultView,"optionalAccess",e=>e.ShadowRoot]),s=ke([o,"optionalAccess",e=>e.prototype])?Object.getOwnPropertyDescriptor(ke([o,"optionalAccess",e=>e.prototype]),"adoptedStyleSheets"):void 0;return null!==r&&-1!==r&&o&&s?(Object.defineProperty(n,"adoptedStyleSheets",{configurable:s.configurable,enumerable:s.enumerable,get(){return ke([s,"access",e=>e.get,"optionalAccess",e=>e.call,"call",e=>e(this)])},set(e){const n=ke([s,"access",e=>e.set,"optionalAccess",e=>e.call,"call",t=>t(this,e)]);if(null!==r&&-1!==r)try{t.adoptStyleSheets(e,r)}catch{}return n}}),U((()=>{Object.defineProperty(n,"adoptedStyleSheets",{configurable:s.configurable,enumerable:s.enumerable,get:s.get,set:s.set})}))):()=>{}}function Uh({styleDeclarationCb:e,mirror:t,ignoreCSSAttributes:n,stylesheetManager:r},{win:o}){const s=o.CSSStyleDeclaration.prototype.setProperty;o.CSSStyleDeclaration.prototype.setProperty=new Proxy(s,{apply:U(((o,i,a)=>{const[c,u,l]=a;if(n.has(c))return s.apply(i,[c,u,l]);const{id:d,styleId:p}=We(ke([i,"access",e=>e.parentRule,"optionalAccess",e=>e.parentStyleSheet]),t,r.styleMirror);return(d&&-1!==d||p&&-1!==p)&&e({id:d,styleId:p,set:{property:c,value:u,priority:l},index:Pn(i.parentRule)}),o.apply(i,a)}))});const i=o.CSSStyleDeclaration.prototype.removeProperty;return o.CSSStyleDeclaration.prototype.removeProperty=new Proxy(i,{apply:U(((o,s,a)=>{const[c]=a;if(n.has(c))return i.apply(s,[c]);const{id:u,styleId:l}=We(ke([s,"access",e=>e.parentRule,"optionalAccess",e=>e.parentStyleSheet]),t,r.styleMirror);return(u&&-1!==u||l&&-1!==l)&&e({id:u,styleId:l,remove:{property:c},index:Pn(s.parentRule)}),o.apply(s,a)}))}),U((()=>{o.CSSStyleDeclaration.prototype.setProperty=s,o.CSSStyleDeclaration.prototype.removeProperty=i}))}function jh({mediaInteractionCb:e,blockClass:t,blockSelector:n,unblockSelector:r,mirror:o,sampling:s,doc:i}){const a=U((i=>zt(U((s=>{const a=nn(s);if(!a||_e(a,t,n,r,!0))return;const{currentTime:c,volume:u,muted:l,playbackRate:d}=a;e({type:i,id:o.getId(a),currentTime:c,volume:u,muted:l,playbackRate:d})})),s.media||500))),c=[de("play",a(0),i),de("pause",a(1),i),de("seeked",a(2),i),de("volumechange",a(3),i),de("ratechange",a(4),i)];return U((()=>{c.forEach((e=>e()))}))}function Bh({fontCb:e,doc:t}){const n=t.defaultView;if(!n)return()=>{};const r=[],o=new WeakMap,s=n.FontFace;n.FontFace=function(e,t,n){const r=new s(e,t,n);return o.set(r,{family:e,buffer:"string"!=typeof t,descriptors:n,fontSource:"string"==typeof t?t:JSON.stringify(Array.from(new Uint8Array(t)))}),r};const i=Ps(t.fonts,"add",(function(t){return function(n){return er(U((()=>{const t=o.get(n);t&&(e(t),o.delete(n))})),0),t.apply(this,[n])}}));return r.push((()=>{n.FontFace=s})),r.push(i),U((()=>{r.forEach((e=>e()))}))}function $h(e){const{doc:t,mirror:n,blockClass:r,blockSelector:o,unblockSelector:s,selectionCb:i}=e;let a=!0;const c=U((()=>{const e=t.getSelection();if(!e||a&&ke([e,"optionalAccess",e=>e.isCollapsed]))return;a=e.isCollapsed||!1;const c=[],u=e.rangeCount||0;for(let t=0;t<u;t++){const i=e.getRangeAt(t),{startContainer:a,startOffset:u,endContainer:l,endOffset:d}=i;_e(a,r,o,s,!0)||_e(l,r,o,s,!0)||c.push({start:n.getId(a),startOffset:u,end:n.getId(l),endOffset:d})}i({ranges:c})}));return c(),de("selectionchange",c)}function Hh({doc:e,customElementCb:t}){const n=e.defaultView;return n&&n.customElements?Ps(n.customElements,"define",(function(e){return function(n,r,o){try{t({define:{name:n}})}catch{}return e.apply(this,[n,r,o])}})):()=>{}}function zh(e,t={}){const n=e.doc.defaultView;if(!n)return()=>{};let r;e.recordDOM&&(r=Ya(e,e.doc));const o=Ah(e),s=xh(e),i=Ka(e),a=Nh(e,{win:n}),c=Lh(e),u=jh(e);let l=()=>{},d=()=>{},p=()=>{},h=()=>{};e.recordDOM&&(l=Fh(e,{win:n}),d=qa(e,e.doc),p=Uh(e,{win:n}),e.collectFonts&&(h=Bh(e)));const m=$h(e),f=Hh(e),y=[];for(const t of e.plugins)y.push(t.observer(t.callback,n,t.options));return U((()=>{yt.forEach((e=>e.reset())),ke([r,"optionalAccess",e=>e.disconnect,"call",e=>e()]),o(),s(),i(),a(),c(),u(),l(),d(),p(),h(),m(),f(),y.forEach((e=>e()))}))}function _n(e){return typeof window[e]<"u"}function gn(e){return!!(typeof window[e]<"u"&&window[e].prototype&&"insertRule"in window[e].prototype&&"deleteRule"in window[e].prototype)}class ns{constructor(e){this.generateIdFn=e,this.iframeIdToRemoteIdMap=new WeakMap,this.iframeRemoteIdToIdMap=new WeakMap}getId(e,t,n,r){const o=n||this.getIdToRemoteIdMap(e),s=r||this.getRemoteIdToIdMap(e);let i=o.get(t);return i||(i=this.generateIdFn(),o.set(t,i),s.set(i,t)),i}getIds(e,t){const n=this.getIdToRemoteIdMap(e),r=this.getRemoteIdToIdMap(e);return t.map((t=>this.getId(e,t,n,r)))}getRemoteId(e,t,n){const r=n||this.getRemoteIdToIdMap(e);if("number"!=typeof t)return t;return r.get(t)||-1}getRemoteIds(e,t){const n=this.getRemoteIdToIdMap(e);return t.map((t=>this.getRemoteId(e,t,n)))}reset(e){if(!e)return this.iframeIdToRemoteIdMap=new WeakMap,void(this.iframeRemoteIdToIdMap=new WeakMap);this.iframeIdToRemoteIdMap.delete(e),this.iframeRemoteIdToIdMap.delete(e)}getIdToRemoteIdMap(e){let t=this.iframeIdToRemoteIdMap.get(e);return t||(t=new Map,this.iframeIdToRemoteIdMap.set(e,t)),t}getRemoteIdToIdMap(e){let t=this.iframeRemoteIdToIdMap.get(e);return t||(t=new Map,this.iframeRemoteIdToIdMap.set(e,t)),t}}function Zo(e){let t,n=e[0],r=1;for(;r<e.length;){const o=e[r],s=e[r+1];if(r+=2,("optionalAccess"===o||"optionalCall"===o)&&null==n)return;"access"===o||"optionalAccess"===o?(t=n,n=s(n)):("call"===o||"optionalCall"===o)&&(n=s(((...e)=>n.call(t,...e))),t=void 0)}return n}class Wh{constructor(){this.crossOriginIframeMirror=new ns(Ns),this.crossOriginIframeRootIdMap=new WeakMap}addIframe(){}addLoadListener(){}attachIframe(){}}class Gh{constructor(e){this.iframes=new WeakMap,this.crossOriginIframeMap=new WeakMap,this.crossOriginIframeMirror=new ns(Ns),this.crossOriginIframeRootIdMap=new WeakMap,this.mutationCb=e.mutationCb,this.wrappedEmit=e.wrappedEmit,this.stylesheetManager=e.stylesheetManager,this.recordCrossOriginIframes=e.recordCrossOriginIframes,this.crossOriginIframeStyleMirror=new ns(this.stylesheetManager.styleMirror.generateId.bind(this.stylesheetManager.styleMirror)),this.mirror=e.mirror,this.recordCrossOriginIframes&&window.addEventListener("message",this.handleMessage.bind(this))}addIframe(e){this.iframes.set(e,!0),e.contentWindow&&this.crossOriginIframeMap.set(e.contentWindow,e)}addLoadListener(e){this.loadListener=e}attachIframe(e,t){this.mutationCb({adds:[{parentId:this.mirror.getId(e),nextId:null,node:t}],removes:[],texts:[],attributes:[],isAttachIframe:!0}),Zo([this,"access",e=>e.loadListener,"optionalCall",t=>t(e)]);const n=Fs(e);n&&n.adoptedStyleSheets&&n.adoptedStyleSheets.length>0&&this.stylesheetManager.adoptStyleSheets(n.adoptedStyleSheets,this.mirror.getId(n))}handleMessage(e){const t=e;if("rrweb"!==t.data.type||t.origin!==t.data.origin||!e.source)return;const n=this.crossOriginIframeMap.get(e.source);if(!n)return;const r=this.transformCrossOriginEvent(n,t.data.event);r&&this.wrappedEmit(r,t.data.isCheckout)}transformCrossOriginEvent(e,t){switch(t.type){case x.FullSnapshot:{this.crossOriginIframeMirror.reset(e),this.crossOriginIframeStyleMirror.reset(e),this.replaceIdOnNode(t.data.node,e);const n=t.data.node.id;return this.crossOriginIframeRootIdMap.set(e,n),this.patchRootIdOnNode(t.data.node,n),{timestamp:t.timestamp,type:x.IncrementalSnapshot,data:{source:A.Mutation,adds:[{parentId:this.mirror.getId(e),nextId:null,node:t.data.node}],removes:[],texts:[],attributes:[],isAttachIframe:!0}}}case x.Meta:case x.Load:case x.DomContentLoaded:return!1;case x.Plugin:return t;case x.Custom:return this.replaceIds(t.data.payload,e,["id","parentId","previousId","nextId"]),t;case x.IncrementalSnapshot:switch(t.data.source){case A.Mutation:return t.data.adds.forEach((t=>{this.replaceIds(t,e,["parentId","nextId","previousId"]),this.replaceIdOnNode(t.node,e);const n=this.crossOriginIframeRootIdMap.get(e);n&&this.patchRootIdOnNode(t.node,n)})),t.data.removes.forEach((t=>{this.replaceIds(t,e,["parentId","id"])})),t.data.attributes.forEach((t=>{this.replaceIds(t,e,["id"])})),t.data.texts.forEach((t=>{this.replaceIds(t,e,["id"])})),t;case A.Drag:case A.TouchMove:case A.MouseMove:return t.data.positions.forEach((t=>{this.replaceIds(t,e,["id"])})),t;case A.ViewportResize:return!1;case A.MediaInteraction:case A.MouseInteraction:case A.Scroll:case A.CanvasMutation:case A.Input:return this.replaceIds(t.data,e,["id"]),t;case A.StyleSheetRule:case A.StyleDeclaration:return this.replaceIds(t.data,e,["id"]),this.replaceStyleIds(t.data,e,["styleId"]),t;case A.Font:return t;case A.Selection:return t.data.ranges.forEach((t=>{this.replaceIds(t,e,["start","end"])})),t;case A.AdoptedStyleSheet:return this.replaceIds(t.data,e,["id"]),this.replaceStyleIds(t.data,e,["styleIds"]),Zo([t,"access",e=>e.data,"access",e=>e.styles,"optionalAccess",e=>e.forEach,"call",t=>t((t=>{this.replaceStyleIds(t,e,["styleId"])}))]),t}}return!1}replace(e,t,n,r){for(const o of r)!Array.isArray(t[o])&&"number"!=typeof t[o]||(Array.isArray(t[o])?t[o]=e.getIds(n,t[o]):t[o]=e.getId(n,t[o]));return t}replaceIds(e,t,n){return this.replace(this.crossOriginIframeMirror,e,t,n)}replaceStyleIds(e,t,n){return this.replace(this.crossOriginIframeStyleMirror,e,t,n)}replaceIdOnNode(e,t){this.replaceIds(e,t,["id","rootId"]),"childNodes"in e&&e.childNodes.forEach((e=>{this.replaceIdOnNode(e,t)}))}patchRootIdOnNode(e,t){e.type!==ce.Document&&!e.rootId&&(e.rootId=t),"childNodes"in e&&e.childNodes.forEach((e=>{this.patchRootIdOnNode(e,t)}))}}class Yh{init(){}addShadowRoot(){}observeAttachShadow(){}reset(){}}class Kh{constructor(e){this.shadowDoms=new WeakSet,this.restoreHandlers=[],this.mutationCb=e.mutationCb,this.scrollCb=e.scrollCb,this.bypassOptions=e.bypassOptions,this.mirror=e.mirror,this.init()}init(){this.reset(),this.patchAttachShadow(Element,document)}addShadowRoot(e,t){if(!Ft(e)||this.shadowDoms.has(e))return;this.shadowDoms.add(e),this.bypassOptions.canvasManager.addShadowRoot(e);const n=Ya({...this.bypassOptions,doc:t,mutationCb:this.mutationCb,mirror:this.mirror,shadowDomManager:this},e);this.restoreHandlers.push((()=>n.disconnect())),this.restoreHandlers.push(Ka({...this.bypassOptions,scrollCb:this.scrollCb,doc:e,mirror:this.mirror})),er((()=>{e.adoptedStyleSheets&&e.adoptedStyleSheets.length>0&&this.bypassOptions.stylesheetManager.adoptStyleSheets(e.adoptedStyleSheets,this.mirror.getId(e.host)),this.restoreHandlers.push(qa({mirror:this.mirror,stylesheetManager:this.bypassOptions.stylesheetManager},e))}),0)}observeAttachShadow(e){const t=Fs(e),n=Th(e);!t||!n||this.patchAttachShadow(n.Element,t)}patchAttachShadow(e,t){const n=this;this.restoreHandlers.push(Ps(e.prototype,"attachShadow",(function(e){return function(r){const o=e.call(this,r);return this.shadowRoot&&Wa(this)&&n.addShadowRoot(this.shadowRoot,t),o}})))}reset(){this.restoreHandlers.forEach((e=>{try{e()}catch{}})),this.restoreHandlers=[],this.shadowDoms=new WeakSet,this.bypassOptions.canvasManager.resetShadowRoots()}}class ei{reset(){}freeze(){}unfreeze(){}lock(){}unlock(){}snapshot(){}addWindow(){}addShadowRoot(){}resetShadowRoots(){}}class qh{constructor(e){this.trackedLinkElements=new WeakSet,this.styleMirror=new Sh,this.mutationCb=e.mutationCb,this.adoptedStyleSheetCb=e.adoptedStyleSheetCb}attachLinkElement(e,t){"_cssText"in t.attributes&&this.mutationCb({adds:[],removes:[],texts:[],attributes:[{id:t.id,attributes:t.attributes}]}),this.trackLinkElement(e)}trackLinkElement(e){this.trackedLinkElements.has(e)||(this.trackedLinkElements.add(e),this.trackStylesheetInLinkElement(e))}adoptStyleSheets(e,t){if(0===e.length)return;const n={id:t,styleIds:[]},r=[];for(const t of e){let e;this.styleMirror.has(t)?e=this.styleMirror.getId(t):(e=this.styleMirror.add(t),r.push({styleId:e,rules:Array.from(t.rules||CSSRule,((e,t)=>({rule:Ra(e),index:t})))})),n.styleIds.push(e)}r.length>0&&(n.styles=r),this.adoptedStyleSheetCb(n)}reset(){this.styleMirror.reset(),this.trackedLinkElements=new WeakSet}trackStylesheetInLinkElement(e){}}class Vh{constructor(){this.nodeMap=new WeakMap,this.active=!1}inOtherBuffer(e,t){const n=this.nodeMap.get(e);return n&&Array.from(n).some((e=>e!==t))}add(e,t){this.active||(this.active=!0,Ih((()=>{this.nodeMap=new WeakMap,this.active=!1}))),this.nodeMap.set(e,(this.nodeMap.get(e)||new Set).add(t))}destroy(){}}let ae,Ln;try{if(2!==Array.from([1],(e=>2*e))[0]){const e=document.createElement("iframe");document.body.appendChild(e),Array.from=In([e,"access",e=>e.contentWindow,"optionalAccess",e=>e.Array,"access",e=>e.from])||Array.from,document.body.removeChild(e)}}catch(e){console.debug("Unable to override Array.from",e)}const we=qp();function Ue(e={}){const{emit:t,checkoutEveryNms:n,checkoutEveryNth:r,blockClass:o="rr-block",blockSelector:s=null,unblockSelector:i=null,ignoreClass:a="rr-ignore",ignoreSelector:c=null,maskAllText:u=!1,maskTextClass:l="rr-mask",unmaskTextClass:d=null,maskTextSelector:p=null,unmaskTextSelector:h=null,inlineStylesheet:m=!0,maskAllInputs:f,maskInputOptions:y,slimDOMOptions:_,maskAttributeFn:g,maskInputFn:v,maskTextFn:b,maxCanvasSize:S=null,packFn:E,sampling:k={},dataURLOptions:w={},mousemoveWait:T,recordDOM:I=!0,recordCanvas:C=!1,recordCrossOriginIframes:M=!1,recordAfter:O=("DOMContentLoaded"===e.recordAfter?e.recordAfter:"load"),userTriggeredOnInput:R=!1,collectFonts:D=!1,inlineImages:N=!1,plugins:P,keepIframeSrcFn:L=()=>!1,ignoreCSSAttributes:j=new Set([]),errorHandler:F,onMutation:$,getCanvasManager:B}=e;Oh(F);const z=!M||window.parent===window;let H=!1;if(!z)try{window.parent.document&&(H=!1)}catch{H=!0}if(z&&!t)throw new Error("emit function is required");if(!z&&!H)return()=>{};void 0!==T&&void 0===k.mousemove&&(k.mousemove=T),we.reset();const W=!0===f?{color:!0,date:!0,"datetime-local":!0,email:!0,month:!0,number:!0,range:!0,search:!0,tel:!0,text:!0,time:!0,url:!0,week:!0,textarea:!0,select:!0,radio:!0,checkbox:!0}:void 0!==y?y:{},V=!0===_||"all"===_?{script:!0,comment:!0,headFavicon:!0,headWhitespace:!0,headMetaSocial:!0,headMetaRobots:!0,headMetaHttpEquiv:!0,headMetaVerification:!0,headMetaAuthorship:"all"===_,headMetaDescKeywords:"all"===_}:_||{};Eh();let J,Y=0;const G=e=>{for(const t of P||[])t.eventProcessor&&(e=t.eventProcessor(e));return E&&!H&&(e=E(e)),e};ae=(e,o)=>{const s=e;if(s.timestamp=Nn(),In([yt,"access",e=>e[0],"optionalAccess",e=>e.isFrozen,"call",e=>e()])&&s.type!==x.FullSnapshot&&!(s.type===x.IncrementalSnapshot&&s.data.source===A.Mutation)&&yt.forEach((e=>e.unfreeze())),z)In([t,"optionalCall",e=>e(G(s),o)]);else if(H){const e={type:"rrweb",event:G(s),origin:window.location.origin,isCheckout:o};window.parent.postMessage(e,"*")}if(s.type===x.FullSnapshot)J=s,Y=0;else if(s.type===x.IncrementalSnapshot){if(s.data.source===A.Mutation&&s.data.isAttachIframe)return;Y++;const e=r&&Y>=r,t=n&&J&&s.timestamp-J.timestamp>n;(e||t)&&re(!0)}};const K=e=>{ae({type:x.IncrementalSnapshot,data:{source:A.Mutation,...e}})},q=e=>ae({type:x.IncrementalSnapshot,data:{source:A.Scroll,...e}}),X=e=>ae({type:x.IncrementalSnapshot,data:{source:A.CanvasMutation,...e}}),Z=new qh({mutationCb:K,adoptedStyleSheetCb:e=>ae({type:x.IncrementalSnapshot,data:{source:A.AdoptedStyleSheet,...e}})}),Q="boolean"==typeof __RRWEB_EXCLUDE_IFRAME__&&__RRWEB_EXCLUDE_IFRAME__?new Wh:new Gh({mirror:we,mutationCb:K,stylesheetManager:Z,recordCrossOriginIframes:M,wrappedEmit:ae});for(const e of P||[])e.getMirror&&e.getMirror({nodeMirror:we,crossOriginIframeMirror:Q.crossOriginIframeMirror,crossOriginIframeStyleMirror:Q.crossOriginIframeStyleMirror});const ee=new Vh,te=Xh(B,{mirror:we,win:window,mutationCb:e=>ae({type:x.IncrementalSnapshot,data:{source:A.CanvasMutation,...e}}),recordCanvas:C,blockClass:o,blockSelector:s,unblockSelector:i,maxCanvasSize:S,sampling:k.canvas,dataURLOptions:w,errorHandler:F}),ne="boolean"==typeof __RRWEB_EXCLUDE_SHADOW_DOM__&&__RRWEB_EXCLUDE_SHADOW_DOM__?new Yh:new Kh({mutationCb:K,scrollCb:q,bypassOptions:{onMutation:$,blockClass:o,blockSelector:s,unblockSelector:i,maskAllText:u,maskTextClass:l,unmaskTextClass:d,maskTextSelector:p,unmaskTextSelector:h,inlineStylesheet:m,maskInputOptions:W,dataURLOptions:w,maskAttributeFn:g,maskTextFn:b,maskInputFn:v,recordCanvas:C,inlineImages:N,sampling:k,slimDOMOptions:V,iframeManager:Q,stylesheetManager:Z,canvasManager:te,keepIframeSrcFn:L,processedNodeManager:ee},mirror:we}),re=(e=!1)=>{if(!I)return;ae({type:x.Meta,data:{href:window.location.href,width:Ua(),height:Fa()}},e),Z.reset(),ne.init(),yt.forEach((e=>e.lock()));const t=gh(document,{mirror:we,blockClass:o,blockSelector:s,unblockSelector:i,maskAllText:u,maskTextClass:l,unmaskTextClass:d,maskTextSelector:p,unmaskTextSelector:h,inlineStylesheet:m,maskAllInputs:W,maskAttributeFn:g,maskInputFn:v,maskTextFn:b,slimDOM:V,dataURLOptions:w,recordCanvas:C,inlineImages:N,onSerialize:e=>{$a(e,we)&&Q.addIframe(e),Ha(e,we)&&Z.trackLinkElement(e),es(e)&&ne.addShadowRoot(e.shadowRoot,document)},onIframeLoad:(e,t)=>{Q.attachIframe(e,t),e.contentWindow&&te.addWindow(e.contentWindow),ne.observeAttachShadow(e)},onStylesheetLoad:(e,t)=>{Z.attachLinkElement(e,t)},keepIframeSrcFn:L});if(!t)return console.warn("Failed to snapshot the document");ae({type:x.FullSnapshot,data:{node:t,initialOffset:La(window)}}),yt.forEach((e=>e.unlock())),document.adoptedStyleSheets&&document.adoptedStyleSheets.length>0&&Z.adoptStyleSheets(document.adoptedStyleSheets,we.getId(document))};Ln=re;try{const e=[],t=e=>U(zh)({onMutation:$,mutationCb:K,mousemoveCb:(e,t)=>ae({type:x.IncrementalSnapshot,data:{source:t,positions:e}}),mouseInteractionCb:e=>ae({type:x.IncrementalSnapshot,data:{source:A.MouseInteraction,...e}}),scrollCb:q,viewportResizeCb:e=>ae({type:x.IncrementalSnapshot,data:{source:A.ViewportResize,...e}}),inputCb:e=>ae({type:x.IncrementalSnapshot,data:{source:A.Input,...e}}),mediaInteractionCb:e=>ae({type:x.IncrementalSnapshot,data:{source:A.MediaInteraction,...e}}),styleSheetRuleCb:e=>ae({type:x.IncrementalSnapshot,data:{source:A.StyleSheetRule,...e}}),styleDeclarationCb:e=>ae({type:x.IncrementalSnapshot,data:{source:A.StyleDeclaration,...e}}),canvasMutationCb:X,fontCb:e=>ae({type:x.IncrementalSnapshot,data:{source:A.Font,...e}}),selectionCb:e=>{ae({type:x.IncrementalSnapshot,data:{source:A.Selection,...e}})},customElementCb:e=>{ae({type:x.IncrementalSnapshot,data:{source:A.CustomElement,...e}})},blockClass:o,ignoreClass:a,ignoreSelector:c,maskAllText:u,maskTextClass:l,unmaskTextClass:d,maskTextSelector:p,unmaskTextSelector:h,maskInputOptions:W,inlineStylesheet:m,sampling:k,recordDOM:I,recordCanvas:C,inlineImages:N,userTriggeredOnInput:R,collectFonts:D,doc:e,maskAttributeFn:g,maskInputFn:v,maskTextFn:b,keepIframeSrcFn:L,blockSelector:s,unblockSelector:i,slimDOMOptions:V,dataURLOptions:w,mirror:we,iframeManager:Q,stylesheetManager:Z,shadowDomManager:ne,processedNodeManager:ee,canvasManager:te,ignoreCSSAttributes:j,plugins:In([P,"optionalAccess",e=>e.filter,"call",e=>e((e=>e.observer)),"optionalAccess",e=>e.map,"call",e=>e((e=>({observer:e.observer,options:e.options,callback:t=>ae({type:x.Plugin,data:{plugin:e.name,payload:t}})})))])||[]},{});Q.addLoadListener((n=>{try{e.push(t(n.contentDocument))}catch(e){console.warn(e)}}));const n=()=>{re(),e.push(t(document))};return"interactive"===document.readyState||"complete"===document.readyState?n():(e.push(de("DOMContentLoaded",(()=>{ae({type:x.DomContentLoaded,data:{}}),"DOMContentLoaded"===O&&n()}))),e.push(de("load",(()=>{ae({type:x.Load,data:{}}),"load"===O&&n()}),window))),()=>{e.forEach((e=>e())),ee.destroy(),Ln=void 0,Dh()}}catch(e){console.warn(e)}}function Jh(e){if(!Ln)throw new Error("please take full snapshot after start recording");Ln(e)}function Xh(e,t){try{return e?e(t):new ei}catch{return console.warn("Unable to initialize CanvasManager"),new ei}}Ue.mirror=we,Ue.takeFullSnapshot=Jh;const Qh=3,Zh=5;function Us(e){return e>9999999999?e:1e3*e}function vr(e){return e>9999999999?e/1e3:e}function rn(e,t){"sentry.transaction"!==t.category&&(["ui.click","ui.input"].includes(t.category)?e.triggerUserActivity():e.checkAndHandleExpiredSession(),e.addUpdate((()=>(e.throttledAddEvent({type:x.Custom,timestamp:1e3*(t.timestamp||0),data:{tag:"breadcrumb",payload:Te(t,10,1e3)}}),"console"===t.category))))}const em="button,a";function Va(e){return e.closest(em)||e}function Ja(e){const t=Xa(e);return t&&t instanceof Element?Va(t):t}function Xa(e){return tm(e)?e.target:e}function tm(e){return"object"==typeof e&&!!e&&"target"in e}let Ge;function nm(e){return Ge||(Ge=[],rm()),Ge.push(e),()=>{const t=Ge?Ge.indexOf(e):-1;t>-1&&Ge.splice(t,1)}}function rm(){pe(ee,"open",(function(e){return function(...t){if(Ge)try{Ge.forEach((e=>e()))}catch{}return e.apply(ee,t)}}))}const sm=new Set([A.Mutation,A.StyleSheetRule,A.StyleDeclaration,A.AdoptedStyleSheet,A.CanvasMutation,A.Selection,A.MediaInteraction]);function om(e,t,n){e.handleClick(t,n)}class im{constructor(e,t,n=rn){this._lastMutation=0,this._lastScroll=0,this._clicks=[],this._timeout=t.timeout/1e3,this._threshold=t.threshold/1e3,this._scrollTimeout=t.scrollTimeout/1e3,this._replay=e,this._ignoreSelector=t.ignoreSelector,this._addBreadcrumbEvent=n}addListeners(){const e=nm((()=>{this._lastMutation=ti()}));this._teardown=()=>{e(),this._clicks=[],this._lastMutation=0,this._lastScroll=0}}removeListeners(){this._teardown&&this._teardown(),this._checkClickTimeout&&clearTimeout(this._checkClickTimeout)}handleClick(e,t){if(cm(t,this._ignoreSelector)||!um(e))return;const n={timestamp:vr(e.timestamp),clickBreadcrumb:e,clickCount:0,node:t};this._clicks.some((e=>e.node===n.node&&Math.abs(e.timestamp-n.timestamp)<1))||(this._clicks.push(n),1===this._clicks.length&&this._scheduleCheckClicks())}registerMutation(e=Date.now()){this._lastMutation=vr(e)}registerScroll(e=Date.now()){this._lastScroll=vr(e)}registerClick(e){const t=Va(e);this._handleMultiClick(t)}_handleMultiClick(e){this._getClicks(e).forEach((e=>{e.clickCount++}))}_getClicks(e){return this._clicks.filter((t=>t.node===e))}_checkClicks(){const e=[],t=ti();this._clicks.forEach((n=>{!n.mutationAfter&&this._lastMutation&&(n.mutationAfter=n.timestamp<=this._lastMutation?this._lastMutation-n.timestamp:void 0),!n.scrollAfter&&this._lastScroll&&(n.scrollAfter=n.timestamp<=this._lastScroll?this._lastScroll-n.timestamp:void 0),n.timestamp+this._timeout<=t&&e.push(n)}));for(const t of e){const e=this._clicks.indexOf(t);e>-1&&(this._generateBreadcrumbs(t),this._clicks.splice(e,1))}this._clicks.length&&this._scheduleCheckClicks()}_generateBreadcrumbs(e){const t=this._replay,n=e.scrollAfter&&e.scrollAfter<=this._scrollTimeout,r=e.mutationAfter&&e.mutationAfter<=this._threshold,o=!n&&!r,{clickCount:s,clickBreadcrumb:i}=e;if(o){const n=1e3*Math.min(e.mutationAfter||this._timeout,this._timeout),r=n<1e3*this._timeout?"mutation":"timeout",o={type:"default",message:i.message,timestamp:i.timestamp,category:"ui.slowClickDetected",data:{...i.data,url:ee.location.href,route:t.getCurrentRoute(),timeAfterClickMs:n,endReason:r,clickCount:s||1}};this._addBreadcrumbEvent(t,o)}else if(s>1){const e={type:"default",message:i.message,timestamp:i.timestamp,category:"ui.multiClick",data:{...i.data,url:ee.location.href,route:t.getCurrentRoute(),clickCount:s,metric:!0}};this._addBreadcrumbEvent(t,e)}}_scheduleCheckClicks(){this._checkClickTimeout&&clearTimeout(this._checkClickTimeout),this._checkClickTimeout=Tt((()=>this._checkClicks()),1e3)}}const am=["A","BUTTON","INPUT"];function cm(e,t){return!!(!am.includes(e.tagName)||"INPUT"===e.tagName&&!["submit","button"].includes(e.getAttribute("type")||"")||"A"===e.tagName&&(e.hasAttribute("download")||e.hasAttribute("target")&&"_self"!==e.getAttribute("target"))||t&&e.matches(t))}function um(e){return!(!e.data||"number"!=typeof e.data.nodeId||!e.timestamp)}function ti(){return Date.now()/1e3}function lm(e,t){try{if(!dm(t))return;const{source:n}=t.data;if(sm.has(n)&&e.registerMutation(t.timestamp),n===A.Scroll&&e.registerScroll(t.timestamp),fm(t)){const{type:n,id:r}=t.data,o=Ue.mirror.getNode(r);o instanceof HTMLElement&&n===le.Click&&e.registerClick(o)}}catch{}}function dm(e){return 3===e.type}function fm(e){return e.data.source===A.MouseInteraction}function Oe(e){return{timestamp:Date.now()/1e3,type:"default",...e}}var Fn;!function(e){e[e.Document=0]="Document",e[e.DocumentType=1]="DocumentType",e[e.Element=2]="Element",e[e.Text=3]="Text",e[e.CDATA=4]="CDATA",e[e.Comment=5]="Comment"}(Fn||(Fn={}));const pm=new Set(["id","class","aria-label","role","name","alt","title","data-test-id","data-testid","disabled","aria-disabled","data-sentry-component"]);function hm(e){const t={};!e["data-sentry-component"]&&e["data-sentry-element"]&&(e["data-sentry-component"]=e["data-sentry-element"]);for(const n in e)if(pm.has(n)){let r=n;("data-testid"===n||"data-test-id"===n)&&(r="testId"),t[r]=e[n]}return t}const mm=e=>t=>{if(!e.isEnabled())return;const n=_m(t);if(!n)return;const r="click"===t.name,o=r?t.event:void 0;r&&e.clickDetector&&o&&o.target&&!o.altKey&&!o.metaKey&&!o.ctrlKey&&!o.shiftKey&&om(e.clickDetector,n,Ja(t.event)),rn(e,n)};function Qa(e,t){const n=Ue.mirror.getId(e),r=n&&Ue.mirror.getNode(n),o=r&&Ue.mirror.getMeta(r),s=o&&ym(o)?o:null;return{message:t,data:s?{nodeId:n,node:{id:n,tagName:s.tagName,textContent:Array.from(s.childNodes).map((e=>e.type===Fn.Text&&e.textContent)).filter(Boolean).map((e=>e.trim())).join(""),attributes:hm(s.attributes)}}:{}}}function _m(e){const{target:t,message:n}=gm(e);return Oe({category:`ui.${e.name}`,...Qa(t,n)})}function gm(e){const t="click"===e.name;let n,r=null;try{r=t?Ja(e.event):Xa(e.event),n=Gn(r,{maxStringLength:200})||"<unknown>"}catch{n="<unknown>"}return{target:r,message:n}}function ym(e){return e.type===Fn.Element}function Em(e,t){if(!e.isEnabled())return;e.updateUserActivity();const n=Sm(t);n&&rn(e,n)}function Sm(e){const{metaKey:t,shiftKey:n,ctrlKey:r,altKey:o,key:s,target:i}=e;if(!i||bm(i)||!s)return null;const a=t||r||o,c=1===s.length;if(!a&&c)return null;const u=Gn(i,{maxStringLength:200})||"<unknown>";return Oe({category:"ui.keyDown",message:u,data:{...Qa(i,u).data,metaKey:t,shiftKey:n,ctrlKey:r,altKey:o,key:s}})}function bm(e){return"INPUT"===e.tagName||"TEXTAREA"===e.tagName||e.isContentEditable}const vm={resource:Rm,paint:Tm,navigation:km};function yn(e,t){return({metric:n})=>{t.replayPerformanceEntries.push(e(n))}}function Im(e){return e.map(wm).filter(Boolean)}function wm(e){const t=vm[e.entryType];return t?t(e):null}function Ct(e){return((su||ee.performance.timeOrigin)+e)/1e3}function Tm(e){const{duration:t,entryType:n,name:r,startTime:o}=e,s=Ct(o);return{type:n,name:r,start:s,end:s+t,data:void 0}}function km(e){const{entryType:t,name:n,decodedBodySize:r,duration:o,domComplete:s,encodedBodySize:i,domContentLoadedEventStart:a,domContentLoadedEventEnd:c,domInteractive:u,loadEventStart:l,loadEventEnd:d,redirectCount:p,startTime:h,transferSize:m,type:f}=e;return 0===o?null:{type:`${t}.${f}`,start:Ct(h),end:Ct(s),name:n,data:{size:m,decodedBodySize:r,encodedBodySize:i,duration:o,domInteractive:u,domContentLoadedEventStart:a,domContentLoadedEventEnd:c,loadEventStart:l,loadEventEnd:d,domComplete:s,redirectCount:p}}}function Rm(e){const{entryType:t,initiatorType:n,name:r,responseEnd:o,startTime:s,decodedBodySize:i,encodedBodySize:a,responseStatus:c,transferSize:u}=e;return["fetch","xmlhttprequest"].includes(n)?null:{type:`${t}.${n}`,start:Ct(s),end:Ct(o),name:r,data:{size:u,statusCode:c,decodedBodySize:i,encodedBodySize:a}}}function Cm(e){const t=e.entries[e.entries.length-1];return tr(e,"largest-contentful-paint",t&&t.element?[t.element]:void 0)}function Mm(e){return void 0!==e.sources}function Om(e){const t=[],n=[];for(const r of e.entries)if(Mm(r)){const e=[];for(const t of r.sources)if(t.node){n.push(t.node);const r=Ue.mirror.getId(t.node);r&&e.push(r)}t.push({value:r.value,nodeIds:e.length?e:void 0})}return tr(e,"cumulative-layout-shift",n,t)}function Dm(e){const t=e.entries[e.entries.length-1];return tr(e,"first-input-delay",t&&t.target?[t.target]:void 0)}function Am(e){const t=e.entries[e.entries.length-1];return tr(e,"interaction-to-next-paint",t&&t.target?[t.target]:void 0)}function tr(e,t,n,r){const o=e.value,s=e.rating,i=Ct(o);return{type:"web-vital",name:t,start:i,end:i,data:{value:o,size:o,rating:s,nodeIds:n?n.map((e=>Ue.mirror.getId(e))):void 0,attributions:r}}}function xm(e){function t(t){e.performanceEntries.includes(t)||e.performanceEntries.push(t)}function n({entries:e}){e.forEach(t)}const r=[];return["navigation","paint","resource"].forEach((e=>{r.push(yf(e,n))})),r.push(mf(yn(Cm,e)),hf(yn(Om,e)),_f(yn(Dm,e)),gf(yn(Am,e))),()=>{r.forEach((e=>e()))}}const M=typeof __SENTRY_DEBUG__>"u"||__SENTRY_DEBUG__,Nm='var t=Uint8Array,n=Uint16Array,r=Int32Array,e=new t([0,0,0,0,0,0,0,0,1,1,1,1,2,2,2,2,3,3,3,3,4,4,4,4,5,5,5,5,0,0,0,0]),i=new t([0,0,0,0,1,1,2,2,3,3,4,4,5,5,6,6,7,7,8,8,9,9,10,10,11,11,12,12,13,13,0,0]),a=new t([16,17,18,0,8,7,9,6,10,5,11,4,12,3,13,2,14,1,15]),s=function(t,e){for(var i=new n(31),a=0;a<31;++a)i[a]=e+=1<<t[a-1];var s=new r(i[30]);for(a=1;a<30;++a)for(var o=i[a];o<i[a+1];++o)s[o]=o-i[a]<<5|a;return{b:i,r:s}},o=s(e,2),f=o.b,h=o.r;f[28]=258,h[258]=28;for(var l=s(i,0).r,u=new n(32768),c=0;c<32768;++c){var v=(43690&c)>>1|(21845&c)<<1;v=(61680&(v=(52428&v)>>2|(13107&v)<<2))>>4|(3855&v)<<4,u[c]=((65280&v)>>8|(255&v)<<8)>>1}var d=function(t,r,e){for(var i=t.length,a=0,s=new n(r);a<i;++a)t[a]&&++s[t[a]-1];var o,f=new n(r);for(a=1;a<r;++a)f[a]=f[a-1]+s[a-1]<<1;if(e){o=new n(1<<r);var h=15-r;for(a=0;a<i;++a)if(t[a])for(var l=a<<4|t[a],c=r-t[a],v=f[t[a]-1]++<<c,d=v|(1<<c)-1;v<=d;++v)o[u[v]>>h]=l}else for(o=new n(i),a=0;a<i;++a)t[a]&&(o[a]=u[f[t[a]-1]++]>>15-t[a]);return o},g=new t(288);for(c=0;c<144;++c)g[c]=8;for(c=144;c<256;++c)g[c]=9;for(c=256;c<280;++c)g[c]=7;for(c=280;c<288;++c)g[c]=8;var w=new t(32);for(c=0;c<32;++c)w[c]=5;var p=d(g,9,0),y=d(w,5,0),m=function(t){return(t+7)/8|0},b=function(n,r,e){return(null==e||e>n.length)&&(e=n.length),new t(n.subarray(r,e))},M=["unexpected EOF","invalid block type","invalid length/literal","invalid distance","stream finished","no stream handler",,"no callback","invalid UTF-8 data","extra field too long","date not in range 1980-2099","filename too long","stream finishing","invalid zip data"],E=function(t,n,r){var e=new Error(n||M[t]);if(e.code=t,Error.captureStackTrace&&Error.captureStackTrace(e,E),!r)throw e;return e},z=function(t,n,r){r<<=7&n;var e=n/8|0;t[e]|=r,t[e+1]|=r>>8},_=function(t,n,r){r<<=7&n;var e=n/8|0;t[e]|=r,t[e+1]|=r>>8,t[e+2]|=r>>16},x=function(r,e){for(var i=[],a=0;a<r.length;++a)r[a]&&i.push({s:a,f:r[a]});var s=i.length,o=i.slice();if(!s)return{t:F,l:0};if(1==s){var f=new t(i[0].s+1);return f[i[0].s]=1,{t:f,l:1}}i.sort((function(t,n){return t.f-n.f})),i.push({s:-1,f:25001});var h=i[0],l=i[1],u=0,c=1,v=2;for(i[0]={s:-1,f:h.f+l.f,l:h,r:l};c!=s-1;)h=i[i[u].f<i[v].f?u++:v++],l=i[u!=c&&i[u].f<i[v].f?u++:v++],i[c++]={s:-1,f:h.f+l.f,l:h,r:l};var d=o[0].s;for(a=1;a<s;++a)o[a].s>d&&(d=o[a].s);var g=new n(d+1),w=A(i[c-1],g,0);if(w>e){a=0;var p=0,y=w-e,m=1<<y;for(o.sort((function(t,n){return g[n.s]-g[t.s]||t.f-n.f}));a<s;++a){var b=o[a].s;if(!(g[b]>e))break;p+=m-(1<<w-g[b]),g[b]=e}for(p>>=y;p>0;){var M=o[a].s;g[M]<e?p-=1<<e-g[M]++-1:++a}for(;a>=0&&p;--a){var E=o[a].s;g[E]==e&&(--g[E],++p)}w=e}return{t:new t(g),l:w}},A=function(t,n,r){return-1==t.s?Math.max(A(t.l,n,r+1),A(t.r,n,r+1)):n[t.s]=r},D=function(t){for(var r=t.length;r&&!t[--r];);for(var e=new n(++r),i=0,a=t[0],s=1,o=function(t){e[i++]=t},f=1;f<=r;++f)if(t[f]==a&&f!=r)++s;else{if(!a&&s>2){for(;s>138;s-=138)o(32754);s>2&&(o(s>10?s-11<<5|28690:s-3<<5|12305),s=0)}else if(s>3){for(o(a),--s;s>6;s-=6)o(8304);s>2&&(o(s-3<<5|8208),s=0)}for(;s--;)o(a);s=1,a=t[f]}return{c:e.subarray(0,i),n:r}},T=function(t,n){for(var r=0,e=0;e<n.length;++e)r+=t[e]*n[e];return r},k=function(t,n,r){var e=r.length,i=m(n+2);t[i]=255&e,t[i+1]=e>>8,t[i+2]=255^t[i],t[i+3]=255^t[i+1];for(var a=0;a<e;++a)t[i+a+4]=r[a];return 8*(i+4+e)},U=function(t,r,s,o,f,h,l,u,c,v,m){z(r,m++,s),++f[256];for(var b=x(f,15),M=b.t,E=b.l,A=x(h,15),U=A.t,C=A.l,F=D(M),I=F.c,S=F.n,L=D(U),O=L.c,j=L.n,q=new n(19),B=0;B<I.length;++B)++q[31&I[B]];for(B=0;B<O.length;++B)++q[31&O[B]];for(var G=x(q,7),H=G.t,J=G.l,K=19;K>4&&!H[a[K-1]];--K);var N,P,Q,R,V=v+5<<3,W=T(f,g)+T(h,w)+l,X=T(f,M)+T(h,U)+l+14+3*K+T(q,H)+2*q[16]+3*q[17]+7*q[18];if(c>=0&&V<=W&&V<=X)return k(r,m,t.subarray(c,c+v));if(z(r,m,1+(X<W)),m+=2,X<W){N=d(M,E,0),P=M,Q=d(U,C,0),R=U;var Y=d(H,J,0);z(r,m,S-257),z(r,m+5,j-1),z(r,m+10,K-4),m+=14;for(B=0;B<K;++B)z(r,m+3*B,H[a[B]]);m+=3*K;for(var Z=[I,O],$=0;$<2;++$){var tt=Z[$];for(B=0;B<tt.length;++B){var nt=31&tt[B];z(r,m,Y[nt]),m+=H[nt],nt>15&&(z(r,m,tt[B]>>5&127),m+=tt[B]>>12)}}}else N=p,P=g,Q=y,R=w;for(B=0;B<u;++B){var rt=o[B];if(rt>255){_(r,m,N[(nt=rt>>18&31)+257]),m+=P[nt+257],nt>7&&(z(r,m,rt>>23&31),m+=e[nt]);var et=31&rt;_(r,m,Q[et]),m+=R[et],et>3&&(_(r,m,rt>>5&8191),m+=i[et])}else _(r,m,N[rt]),m+=P[rt]}return _(r,m,N[256]),m+P[256]},C=new r([65540,131080,131088,131104,262176,1048704,1048832,2114560,2117632]),F=new t(0),I=function(){for(var t=new Int32Array(256),n=0;n<256;++n){for(var r=n,e=9;--e;)r=(1&r&&-306674912)^r>>>1;t[n]=r}return t}(),S=function(){var t=-1;return{p:function(n){for(var r=t,e=0;e<n.length;++e)r=I[255&r^n[e]]^r>>>8;t=r},d:function(){return~t}}},L=function(){var t=1,n=0;return{p:function(r){for(var e=t,i=n,a=0|r.length,s=0;s!=a;){for(var o=Math.min(s+2655,a);s<o;++s)i+=e+=r[s];e=(65535&e)+15*(e>>16),i=(65535&i)+15*(i>>16)}t=e,n=i},d:function(){return(255&(t%=65521))<<24|(65280&t)<<8|(255&(n%=65521))<<8|n>>8}}},O=function(a,s,o,f,u){if(!u&&(u={l:1},s.dictionary)){var c=s.dictionary.subarray(-32768),v=new t(c.length+a.length);v.set(c),v.set(a,c.length),a=v,u.w=c.length}return function(a,s,o,f,u,c){var v=c.z||a.length,d=new t(f+v+5*(1+Math.ceil(v/7e3))+u),g=d.subarray(f,d.length-u),w=c.l,p=7&(c.r||0);if(s){p&&(g[0]=c.r>>3);for(var y=C[s-1],M=y>>13,E=8191&y,z=(1<<o)-1,_=c.p||new n(32768),x=c.h||new n(z+1),A=Math.ceil(o/3),D=2*A,T=function(t){return(a[t]^a[t+1]<<A^a[t+2]<<D)&z},F=new r(25e3),I=new n(288),S=new n(32),L=0,O=0,j=c.i||0,q=0,B=c.w||0,G=0;j+2<v;++j){var H=T(j),J=32767&j,K=x[H];if(_[J]=K,x[H]=J,B<=j){var N=v-j;if((L>7e3||q>24576)&&(N>423||!w)){p=U(a,g,0,F,I,S,O,q,G,j-G,p),q=L=O=0,G=j;for(var P=0;P<286;++P)I[P]=0;for(P=0;P<30;++P)S[P]=0}var Q=2,R=0,V=E,W=J-K&32767;if(N>2&&H==T(j-W))for(var X=Math.min(M,N)-1,Y=Math.min(32767,j),Z=Math.min(258,N);W<=Y&&--V&&J!=K;){if(a[j+Q]==a[j+Q-W]){for(var $=0;$<Z&&a[j+$]==a[j+$-W];++$);if($>Q){if(Q=$,R=W,$>X)break;var tt=Math.min(W,$-2),nt=0;for(P=0;P<tt;++P){var rt=j-W+P&32767,et=rt-_[rt]&32767;et>nt&&(nt=et,K=rt)}}}W+=(J=K)-(K=_[J])&32767}if(R){F[q++]=268435456|h[Q]<<18|l[R];var it=31&h[Q],at=31&l[R];O+=e[it]+i[at],++I[257+it],++S[at],B=j+Q,++L}else F[q++]=a[j],++I[a[j]]}}for(j=Math.max(j,B);j<v;++j)F[q++]=a[j],++I[a[j]];p=U(a,g,w,F,I,S,O,q,G,j-G,p),w||(c.r=7&p|g[p/8|0]<<3,p-=7,c.h=x,c.p=_,c.i=j,c.w=B)}else{for(j=c.w||0;j<v+w;j+=65535){var st=j+65535;st>=v&&(g[p/8|0]=w,st=v),p=k(g,p+1,a.subarray(j,st))}c.i=v}return b(d,0,f+m(p)+u)}(a,null==s.level?6:s.level,null==s.mem?Math.ceil(1.5*Math.max(8,Math.min(13,Math.log(a.length)))):12+s.mem,o,f,u)},j=function(t,n,r){for(;r;++n)t[n]=r,r>>>=8},q=function(t,n){var r=n.filename;if(t[0]=31,t[1]=139,t[2]=8,t[8]=n.level<2?4:9==n.level?2:0,t[9]=3,0!=n.mtime&&j(t,4,Math.floor(new Date(n.mtime||Date.now())/1e3)),r){t[3]=8;for(var e=0;e<=r.length;++e)t[e+10]=r.charCodeAt(e)}},B=function(t){return 10+(t.filename?t.filename.length+1:0)},G=function(){function n(n,r){if("function"==typeof n&&(r=n,n={}),this.ondata=r,this.o=n||{},this.s={l:0,i:32768,w:32768,z:32768},this.b=new t(98304),this.o.dictionary){var e=this.o.dictionary.subarray(-32768);this.b.set(e,32768-e.length),this.s.i=32768-e.length}}return n.prototype.p=function(t,n){this.ondata(O(t,this.o,0,0,this.s),n)},n.prototype.push=function(n,r){this.ondata||E(5),this.s.l&&E(4);var e=n.length+this.s.z;if(e>this.b.length){if(e>2*this.b.length-32768){var i=new t(-32768&e);i.set(this.b.subarray(0,this.s.z)),this.b=i}var a=this.b.length-this.s.z;a&&(this.b.set(n.subarray(0,a),this.s.z),this.s.z=this.b.length,this.p(this.b,!1)),this.b.set(this.b.subarray(-32768)),this.b.set(n.subarray(a),32768),this.s.z=n.length-a+32768,this.s.i=32766,this.s.w=32768}else this.b.set(n,this.s.z),this.s.z+=n.length;this.s.l=1&r,(this.s.z>this.s.w+8191||r)&&(this.p(this.b,r||!1),this.s.w=this.s.i,this.s.i-=2)},n}();var H=function(){function t(t,n){this.c=L(),this.v=1,G.call(this,t,n)}return t.prototype.push=function(t,n){this.c.p(t),G.prototype.push.call(this,t,n)},t.prototype.p=function(t,n){var r=O(t,this.o,this.v&&(this.o.dictionary?6:2),n&&4,this.s);this.v&&(function(t,n){var r=n.level,e=0==r?0:r<6?1:9==r?3:2;if(t[0]=120,t[1]=e<<6|(n.dictionary&&32),t[1]|=31-(t[0]<<8|t[1])%31,n.dictionary){var i=L();i.p(n.dictionary),j(t,2,i.d())}}(r,this.o),this.v=0),n&&j(r,r.length-4,this.c.d()),this.ondata(r,n)},t}(),J="undefined"!=typeof TextEncoder&&new TextEncoder,K="undefined"!=typeof TextDecoder&&new TextDecoder;try{K.decode(F,{stream:!0})}catch(t){}var N=function(){function t(t){this.ondata=t}return t.prototype.push=function(t,n){this.ondata||E(5),this.d&&E(4),this.ondata(P(t),this.d=n||!1)},t}();function P(n,r){if(J)return J.encode(n);for(var e=n.length,i=new t(n.length+(n.length>>1)),a=0,s=function(t){i[a++]=t},o=0;o<e;++o){if(a+5>i.length){var f=new t(a+8+(e-o<<1));f.set(i),i=f}var h=n.charCodeAt(o);h<128||r?s(h):h<2048?(s(192|h>>6),s(128|63&h)):h>55295&&h<57344?(s(240|(h=65536+(1047552&h)|1023&n.charCodeAt(++o))>>18),s(128|h>>12&63),s(128|h>>6&63),s(128|63&h)):(s(224|h>>12),s(128|h>>6&63),s(128|63&h))}return b(i,0,a)}function Q(t){return function(t,n){n||(n={});var r=S(),e=t.length;r.p(t);var i=O(t,n,B(n),8),a=i.length;return q(i,n),j(i,a-8,r.d()),j(i,a-4,e),i}(P(t))}const R=new class{constructor(){this._init()}clear(){this._init()}addEvent(t){if(!t)throw new Error("Adding invalid event");const n=this._hasEvents?",":"";this.stream.push(n+t),this._hasEvents=!0}finish(){this.stream.push("]",!0);const t=function(t){let n=0;for(const r of t)n+=r.length;const r=new Uint8Array(n);for(let n=0,e=0,i=t.length;n<i;n++){const i=t[n];r.set(i,e),e+=i.length}return r}(this._deflatedData);return this._init(),t}_init(){this._hasEvents=!1,this._deflatedData=[],this.deflate=new H,this.deflate.ondata=(t,n)=>{this._deflatedData.push(t)},this.stream=new N(((t,n)=>{this.deflate.push(t,n)})),this.stream.push("[")}},V={clear:()=>{R.clear()},addEvent:t=>R.addEvent(t),finish:()=>R.finish(),compress:t=>Q(t)};addEventListener("message",(function(t){const n=t.data.method,r=t.data.id,e=t.data.arg;if(n in V&&"function"==typeof V[n])try{const t=V[n](e);postMessage({id:r,method:n,success:!0,response:t})}catch(t){postMessage({id:r,method:n,success:!1,response:t.message}),console.error(t)}})),postMessage({id:void 0,method:"init",success:!0,response:void 0});';function Pm(){const e=new Blob([Nm]);return URL.createObjectURL(e)}const ni=["info","warn","error","log"],Tn="[Replay] ";function Ir(e,t="info"){qe({category:"console",data:{logger:"replay"},level:t,message:`${Tn}${e}`},{level:t})}function Lm(){let e=!1,t=!1;const n={exception:()=>{},infoTick:()=>{},setConfig:n=>{e=n.captureExceptions,t=n.traceInternals}};return M?(ni.forEach((e=>{n[e]=(...n)=>{C[e](Tn,...n),t&&Ir(n.join(""),sa(e))}})),n.exception=(r,...o)=>{o.length&&n.error&&n.error(...o),C.error(Tn,r),e?Is(r):t&&Ir(r,"error")},n.infoTick=(...e)=>{C.info(Tn,...e),t&&setTimeout((()=>Ir(e[0])),0)}):ni.forEach((e=>{n[e]=()=>{}})),n}const O=Lm();class js extends Error{constructor(){super(`Event buffer exceeded maximum size of ${As}.`)}}class Za{constructor(){this.events=[],this._totalSize=0,this.hasCheckout=!1,this.waitForCheckout=!1}get hasEvents(){return this.events.length>0}get type(){return"sync"}destroy(){this.events=[]}async addEvent(e){const t=JSON.stringify(e).length;if(this._totalSize+=t,this._totalSize>As)throw new js;this.events.push(e)}finish(){return new Promise((e=>{const t=this.events;this.clear(),e(JSON.stringify(t))}))}clear(){this.events=[],this._totalSize=0,this.hasCheckout=!1}getEarliestTimestamp(){const e=this.events.map((e=>e.timestamp)).sort()[0];return e?Us(e):null}}class Fm{constructor(e){this._worker=e,this._id=0}ensureReady(){return this._ensureReadyPromise||(this._ensureReadyPromise=new Promise(((e,t)=>{this._worker.addEventListener("message",(({data:n})=>{n.success?e():t()}),{once:!0}),this._worker.addEventListener("error",(e=>{t(e)}),{once:!0})}))),this._ensureReadyPromise}destroy(){M&&O.info("Destroying compression worker"),this._worker.terminate()}postMessage(e,t){const n=this._getAndIncrementId();return new Promise(((r,o)=>{const s=({data:t})=>{const i=t;if(i.method===e&&i.id===n){if(this._worker.removeEventListener("message",s),!i.success)return M&&O.error("Error in compression worker: ",i.response),void o(new Error("Error in compression worker"));r(i.response)}};this._worker.addEventListener("message",s),this._worker.postMessage({id:n,method:e,arg:t})}))}_getAndIncrementId(){return this._id++}}class Um{constructor(e){this._worker=new Fm(e),this._earliestTimestamp=null,this._totalSize=0,this.hasCheckout=!1,this.waitForCheckout=!1}get hasEvents(){return!!this._earliestTimestamp}get type(){return"worker"}ensureReady(){return this._worker.ensureReady()}destroy(){this._worker.destroy()}addEvent(e){const t=Us(e.timestamp);(!this._earliestTimestamp||t<this._earliestTimestamp)&&(this._earliestTimestamp=t);const n=JSON.stringify(e);return this._totalSize+=n.length,this._totalSize>As?Promise.reject(new js):this._sendEventToWorker(n)}finish(){return this._finishRequest()}clear(){this._earliestTimestamp=null,this._totalSize=0,this.hasCheckout=!1,this._worker.postMessage("clear").then(null,(e=>{M&&O.exception(e,'Sending "clear" message to worker failed',e)}))}getEarliestTimestamp(){return this._earliestTimestamp}_sendEventToWorker(e){return this._worker.postMessage("addEvent",e)}async _finishRequest(){const e=await this._worker.postMessage("finish");return this._earliestTimestamp=null,this._totalSize=0,e}}class jm{constructor(e){this._fallback=new Za,this._compression=new Um(e),this._used=this._fallback,this._ensureWorkerIsLoadedPromise=this._ensureWorkerIsLoaded()}get waitForCheckout(){return this._used.waitForCheckout}get type(){return this._used.type}get hasEvents(){return this._used.hasEvents}get hasCheckout(){return this._used.hasCheckout}set hasCheckout(e){this._used.hasCheckout=e}set waitForCheckout(e){this._used.waitForCheckout=e}destroy(){this._fallback.destroy(),this._compression.destroy()}clear(){return this._used.clear()}getEarliestTimestamp(){return this._used.getEarliestTimestamp()}addEvent(e){return this._used.addEvent(e)}async finish(){return await this.ensureWorkerIsLoaded(),this._used.finish()}ensureWorkerIsLoaded(){return this._ensureWorkerIsLoadedPromise}async _ensureWorkerIsLoaded(){try{await this._compression.ensureReady()}catch(e){return void(M&&O.exception(e,"Failed to load the compression worker, falling back to simple buffer"))}await this._switchToCompressionWorker()}async _switchToCompressionWorker(){const{events:e,hasCheckout:t,waitForCheckout:n}=this._fallback,r=[];for(const t of e)r.push(this._compression.addEvent(t));this._compression.hasCheckout=t,this._compression.waitForCheckout=n,this._used=this._compression;try{await Promise.all(r),this._fallback.clear()}catch(e){M&&O.exception(e,"Failed to add events when switching buffers.")}}}function Bm({useCompression:e,workerUrl:t}){if(e&&window.Worker){const e=$m(t);if(e)return e}return M&&O.info("Using simple buffer"),new Za}function $m(e){try{const t=e||Hm();if(!t)return;M&&O.info("Using compression worker"+(e?` from ${e}`:""));const n=new Worker(t);return new jm(n)}catch(e){M&&O.exception(e,"Failed to create compression worker")}}function Hm(){return typeof __SENTRY_EXCLUDE_REPLAY_WORKER__>"u"||!__SENTRY_EXCLUDE_REPLAY_WORKER__?Pm():""}function Bs(){try{return"sessionStorage"in ee&&!!ee.sessionStorage}catch{return!1}}function zm(e){Wm(),e.session=void 0}function Wm(){if(Bs())try{ee.sessionStorage.removeItem(Os)}catch{}}function ec(e){return void 0!==e&&Math.random()<e}function tc(e){const t=Date.now();return{id:e.id||ge(),started:e.started||t,lastActivity:e.lastActivity||t,segmentId:e.segmentId||0,sampled:e.sampled,previousSessionId:e.previousSessionId}}function $s(e){if(Bs())try{ee.sessionStorage.setItem(Os,JSON.stringify(e))}catch{}}function Gm(e,t){return ec(e)?"session":!!t&&"buffer"}function ri({sessionSampleRate:e,allowBuffering:t,stickySession:n=!1},{previousSessionId:r}={}){const o=tc({sampled:Gm(e,t),previousSessionId:r});return n&&$s(o),o}function Ym(){if(!Bs())return null;try{const e=ee.sessionStorage.getItem(Os);if(!e)return null;const t=JSON.parse(e);return M&&O.infoTick("Loading existing session"),tc(t)}catch{return null}}function rs(e,t,n=+new Date){return null===e||void 0===t||t<0||0!==t&&e+t<=n}function nc(e,{maxReplayDuration:t,sessionIdleExpire:n,targetTime:r=Date.now()}){return rs(e.started,t,r)||rs(e.lastActivity,n,r)}function rc(e,{sessionIdleExpire:t,maxReplayDuration:n}){return!(!nc(e,{sessionIdleExpire:t,maxReplayDuration:n})||"buffer"===e.sampled&&0===e.segmentId)}function wr({sessionIdleExpire:e,maxReplayDuration:t,previousSessionId:n},r){const o=r.stickySession&&Ym();return o?rc(o,{sessionIdleExpire:e,maxReplayDuration:t})?(M&&O.infoTick("Session in sessionStorage is expired, creating new one..."),ri(r,{previousSessionId:o.id})):o:(M&&O.infoTick("Creating new session"),ri(r,{previousSessionId:n}))}function Km(e){return e.type===x.Custom}function Hs(e,t,n){return!!oc(e,t)&&(sc(e,t,n),!0)}function qm(e,t,n){return oc(e,t)?sc(e,t,n):Promise.resolve(null)}async function sc(e,t,n){const{eventBuffer:r}=e;if(!r||r.waitForCheckout&&!n)return null;const o="buffer"===e.recordingMode;try{n&&o&&r.clear(),n&&(r.hasCheckout=!0,r.waitForCheckout=!1);const s=Vm(t,e.getOptions().beforeAddRecordingEvent);return s?await r.addEvent(s):void 0}catch(t){const n=t&&t instanceof js,s=n?"addEventSizeExceeded":"addEvent";if(n&&o)return r.clear(),r.waitForCheckout=!0,null;e.handleException(t),await e.stop({reason:s});const i=ie();i&&i.recordDroppedEvent("internal_sdk_error","replay")}}function oc(e,t){if(!e.eventBuffer||e.isPaused()||!e.isEnabled())return!1;const n=Us(t.timestamp);return!(n+e.timeouts.sessionIdlePause<Date.now())&&(!(n>e.getContext().initialTimestamp+e.getOptions().maxReplayDuration)||(M&&O.infoTick(`Skipping event with timestamp ${n} because it is after maxReplayDuration`),!1))}function Vm(e,t){try{if("function"==typeof t&&Km(e))return t(e)}catch(e){return M&&O.exception(e,"An error occurred in the `beforeAddRecordingEvent` callback, skipping the event..."),null}return e}function zs(e){return!e.type}function ss(e){return"transaction"===e.type}function Jm(e){return"replay_event"===e.type}function si(e){return"feedback"===e.type}function Xm(e){return(t,n)=>{if(!e.isEnabled()||!zs(t)&&!ss(t))return;const r=n&&n.statusCode;if(!(!r||r<200||r>=300)){if(ss(t))return void Qm(e,t);Zm(e,t)}}}function Qm(e,t){const n=e.getContext();t.contexts&&t.contexts.trace&&t.contexts.trace.trace_id&&n.traceIds.size<100&&n.traceIds.add(t.contexts.trace.trace_id)}function Zm(e,t){const n=e.getContext();if(t.event_id&&n.errorIds.size<100&&n.errorIds.add(t.event_id),"buffer"!==e.recordingMode||!t.tags||!t.tags.replayId)return;const{beforeErrorSampling:r}=e.getOptions();"function"==typeof r&&!r(t)||Tt((async()=>{try{await e.sendBufferedReplayOrFlush()}catch(t){e.handleException(t)}}))}function e_(e){return t=>{!e.isEnabled()||!zs(t)||t_(e,t)}}function t_(e,t){const n=t.exception&&t.exception.values&&t.exception.values[0]&&t.exception.values[0].value;if("string"==typeof n&&(n.match(/(reactjs\.org\/docs\/error-decoder\.html\?invariant=|react\.dev\/errors\/)(418|419|422|423|425)/)||n.match(/(does not match server-rendered HTML|Hydration failed because)/i))){rn(e,Oe({category:"replay.hydrate-error",data:{url:Pi()}}))}}function n_(e){const t=ie();t&&t.on("beforeAddBreadcrumb",(t=>r_(e,t)))}function r_(e,t){if(!e.isEnabled()||!ic(t))return;const n=s_(t);n&&rn(e,n)}function s_(e){return!ic(e)||["fetch","xhr","sentry.event","sentry.transaction"].includes(e.category)||e.category.startsWith("ui.")?null:"console"===e.category?o_(e):Oe(e)}function o_(e){const t=e.data&&e.data.arguments;if(!Array.isArray(t)||0===t.length)return Oe(e);let n=!1;const r=t.map((e=>{if(!e)return e;if("string"==typeof e)return e.length>mn?(n=!0,`${e.slice(0,mn)}…`):e;if("object"==typeof e)try{const t=Te(e,7);return JSON.stringify(t).length>mn?(n=!0,`${JSON.stringify(t,null,2).slice(0,mn)}…`):t}catch{}return e}));return Oe({...e,data:{...e.data,arguments:r,...n?{_meta:{warnings:["CONSOLE_ARG_TRUNCATED"]}}:{}}})}function ic(e){return!!e.category}function i_(e,t){return!(e.type||!e.exception||!e.exception.values||!e.exception.values.length)&&!(!t.originalException||!t.originalException.__rrweb__)}function ac(){const e=be().getPropagationContext().dsc;e&&delete e.replay_id;const t=$i();if(t){delete zi(t).replay_id}}function a_(e,t){e.triggerUserActivity(),e.addUpdate((()=>!t.timestamp||(e.throttledAddEvent({type:x.Custom,timestamp:1e3*t.timestamp,data:{tag:"breadcrumb",payload:{timestamp:t.timestamp,type:"default",category:"sentry.feedback",data:{feedbackId:t.event_id}}}}),!1)))}function c_(e,t){return!("buffer"!==e.recordingMode||t.message===Ds||!t.exception||t.type)&&ec(e.getOptions().errorSampleRate)}function u_(e){return Object.assign(((t,n)=>!e.isEnabled()||e.isPaused()?t:Jm(t)?(delete t.breadcrumbs,t):zs(t)||ss(t)||si(t)?e.checkAndHandleExpiredSession()?si(t)?(e.flush(),t.contexts.feedback.replay_id=e.getSessionId(),a_(e,t),t):i_(t,n)&&!e.getOptions()._experiments.captureExceptions?(M&&O.log("Ignoring error from rrweb internals",t),null):((c_(e,t)||"session"===e.recordingMode)&&(t.tags={...t.tags,replayId:e.getSessionId()}),t):(ac(),t):t),{id:"Replay"})}function nr(e,t){return t.map((({type:t,start:n,end:r,name:o,data:s})=>{const i=e.throttledAddEvent({type:x.Custom,timestamp:n,data:{tag:"performanceSpan",payload:{op:t,description:o,startTimestamp:n,endTimestamp:r,data:s}}});return"string"==typeof i?Promise.resolve(null):i}))}function l_(e){const{from:t,to:n}=e,r=Date.now()/1e3;return{type:"navigation.push",start:r,end:r,name:n,data:{previous:t}}}function d_(e){return t=>{if(!e.isEnabled())return;const n=l_(t);null!==n&&(e.getContext().urls.push(n.name),e.triggerUserActivity(),e.addUpdate((()=>(nr(e,[n]),!1))))}}function f_(e,t){return(!M||!e.getOptions()._experiments.traceInternals)&&Hl(t,ie())}function cc(e,t){e.isEnabled()&&null!==t&&(f_(e,t.name)||e.addUpdate((()=>(nr(e,[t]),!0))))}function rr(e){if(!e)return;const t=new TextEncoder;try{if("string"==typeof e)return t.encode(e).length;if(e instanceof URLSearchParams)return t.encode(e.toString()).length;if(e instanceof FormData){const n=fc(e);return t.encode(n).length}if(e instanceof Blob)return e.size;if(e instanceof ArrayBuffer)return e.byteLength}catch{}}function uc(e){if(!e)return;const t=parseInt(e,10);return isNaN(t)?void 0:t}function lc(e){try{if("string"==typeof e)return[e];if(e instanceof URLSearchParams)return[e.toString()];if(e instanceof FormData)return[fc(e)];if(!e)return[void 0]}catch(t){return M&&O.exception(t,"Failed to serialize body",e),[void 0,"BODY_PARSE_ERROR"]}return M&&O.info("Skipping network body because of body type",e),[void 0,"UNPARSEABLE_BODY_TYPE"]}function Un(e,t){if(!e)return{headers:{},size:void 0,_meta:{warnings:[t]}};const n={...e._meta},r=n.warnings||[];return n.warnings=[...r,t],e._meta=n,e}function dc(e,t){if(!t)return null;const{startTimestamp:n,endTimestamp:r,url:o,method:s,statusCode:i,request:a,response:c}=t;return{type:e,start:n/1e3,end:r/1e3,name:o,data:he({method:s,statusCode:i,request:a,response:c})}}function Wt(e){return{headers:{},size:e,_meta:{warnings:["URL_SKIPPED"]}}}function Ke(e,t,n){if(!t&&0===Object.keys(e).length)return;if(!t)return{headers:e};if(!n)return{headers:e,size:t};const r={headers:e,size:t},{body:o,warnings:s}=p_(n);return r.body=o,s&&s.length>0&&(r._meta={warnings:s}),r}function os(e,t){return Object.entries(e).reduce(((n,[r,o])=>{const s=r.toLowerCase();return t.includes(s)&&e[r]&&(n[s]=o),n}),{})}function fc(e){return new URLSearchParams(e).toString()}function p_(e){if(!e||"string"!=typeof e)return{body:e};const t=e.length>Uo,n=h_(e);if(t){const t=e.slice(0,Uo);return n?{body:t,warnings:["MAYBE_JSON_TRUNCATED"]}:{body:`${t}…`,warnings:["TEXT_TRUNCATED"]}}if(n)try{return{body:JSON.parse(e)}}catch{}return{body:e}}function h_(e){const t=e[0],n=e[e.length-1];return"["===t&&"]"===n||"{"===t&&"}"===n}function jn(e,t){return Vt(m_(e),t)}function m_(e,t=ee.document.baseURI){if(e.startsWith("http://")||e.startsWith("https://")||e.startsWith(ee.location.origin))return e;const n=new URL(e,t);if(n.origin!==new URL(t).origin)return e;const r=n.href;return!e.endsWith("/")&&r.endsWith("/")?r.slice(0,-1):r}async function __(e,t,n){try{const r=dc("resource.fetch",await y_(e,t,n));cc(n.replay,r)}catch(e){M&&O.exception(e,"Failed to capture fetch breadcrumb")}}function g_(e,t){const{input:n,response:r}=t,o=rr(n?pc(n):void 0),s=r?uc(r.headers.get("content-length")):void 0;void 0!==o&&(e.data.request_body_size=o),void 0!==s&&(e.data.response_body_size=s)}async function y_(e,t,n){const r=Date.now(),{startTimestamp:o=r,endTimestamp:s=r}=t,{url:i,method:a,status_code:c=0,request_body_size:u,response_body_size:l}=e.data,d=jn(i,n.networkDetailAllowUrls)&&!jn(i,n.networkDetailDenyUrls);return{startTimestamp:o,endTimestamp:s,url:i,method:a,statusCode:c,request:d?E_(n,t.input,u):Wt(u),response:await S_(d,n,t.response,l)}}function E_({networkCaptureBodies:e,networkRequestHeaders:t},n,r){const o=n?I_(n,t):{};if(!e)return Ke(o,r,void 0);const s=pc(n),[i,a]=lc(s),c=Ke(o,r,i);return a?Un(c,a):c}async function S_(e,{networkCaptureBodies:t,networkResponseHeaders:n},r,o){if(!e&&void 0!==o)return Wt(o);const s=r?hc(r.headers,n):{};if(!r||!t&&void 0!==o)return Ke(s,o,void 0);const[i,a]=await v_(r),c=b_(i,{networkCaptureBodies:t,responseBodySize:o,captureDetails:e,headers:s});return a?Un(c,a):c}function b_(e,{networkCaptureBodies:t,responseBodySize:n,captureDetails:r,headers:o}){try{const s=e&&e.length&&void 0===n?rr(e):n;return r?Ke(o,s,t?e:void 0):Wt(s)}catch(e){return M&&O.exception(e,"Failed to serialize response body"),Ke(o,n,void 0)}}async function v_(e){const t=w_(e);if(!t)return[void 0,"BODY_PARSE_ERROR"];try{return[await T_(t)]}catch(e){return e instanceof Error&&e.message.indexOf("Timeout")>-1?(M&&O.warn("Parsing text body from response timed out"),[void 0,"BODY_PARSE_TIMEOUT"]):(M&&O.exception(e,"Failed to get text body from response"),[void 0,"BODY_PARSE_ERROR"])}}function pc(e=[]){if(2===e.length&&"object"==typeof e[1])return e[1].body}function hc(e,t){const n={};return t.forEach((t=>{e.get(t)&&(n[t]=e.get(t))})),n}function I_(e,t){return 1===e.length&&"string"!=typeof e[0]?oi(e[0],t):2===e.length?oi(e[1],t):{}}function oi(e,t){if(!e)return{};const n=e.headers;return n?n instanceof Headers?hc(n,t):Array.isArray(n)?{}:os(n,t):{}}function w_(e){try{return e.clone()}catch(e){M&&O.exception(e,"Failed to clone response body")}}function T_(e){return new Promise(((t,n)=>{const r=Tt((()=>n(new Error("Timeout while trying to read response body"))),500);k_(e).then((e=>t(e)),(e=>n(e))).finally((()=>clearTimeout(r)))}))}async function k_(e){return await e.text()}async function R_(e,t,n){try{const r=dc("resource.xhr",M_(e,t,n));cc(n.replay,r)}catch(e){M&&O.exception(e,"Failed to capture xhr breadcrumb")}}function C_(e,t){const{xhr:n,input:r}=t;if(!n)return;const o=rr(r),s=n.getResponseHeader("content-length")?uc(n.getResponseHeader("content-length")):x_(n.response,n.responseType);void 0!==o&&(e.data.request_body_size=o),void 0!==s&&(e.data.response_body_size=s)}function M_(e,t,n){const r=Date.now(),{startTimestamp:o=r,endTimestamp:s=r,input:i,xhr:a}=t,{url:c,method:u,status_code:l=0,request_body_size:d,response_body_size:p}=e.data;if(!c)return null;if(!a||!jn(c,n.networkDetailAllowUrls)||jn(c,n.networkDetailDenyUrls)){return{startTimestamp:o,endTimestamp:s,url:c,method:u,statusCode:l,request:Wt(d),response:Wt(p)}}const h=a[ht],m=h?os(h.request_headers,n.networkRequestHeaders):{},f=os(O_(a),n.networkResponseHeaders),[y,_]=n.networkCaptureBodies?lc(i):[void 0],[g,v]=n.networkCaptureBodies?D_(a):[void 0],b=Ke(m,d,y),S=Ke(f,p,g);return{startTimestamp:o,endTimestamp:s,url:c,method:u,statusCode:l,request:_?Un(b,_):b,response:v?Un(S,v):S}}function O_(e){const t=e.getAllResponseHeaders();return t?t.split("\r\n").reduce(((e,t)=>{const[n,r]=t.split(": ");return r&&(e[n.toLowerCase()]=r),e}),{}):{}}function D_(e){const t=[];try{return[e.responseText]}catch(e){t.push(e)}try{return A_(e.response,e.responseType)}catch(e){t.push(e)}return M&&O.warn("Failed to get xhr response body",...t),[void 0]}function A_(e,t){try{if("string"==typeof e)return[e];if(e instanceof Document)return[e.body.outerHTML];if("json"===t&&e&&"object"==typeof e)return[JSON.stringify(e)];if(!e)return[void 0]}catch(t){return M&&O.exception(t,"Failed to serialize body",e),[void 0,"BODY_PARSE_ERROR"]}return M&&O.info("Skipping network body because of body type",e),[void 0,"UNPARSEABLE_BODY_TYPE"]}function x_(e,t){try{return rr("json"===t&&e&&"object"==typeof e?JSON.stringify(e):e)}catch{return}}function N_(e){const t=ie();try{const{networkDetailAllowUrls:n,networkDetailDenyUrls:r,networkCaptureBodies:o,networkRequestHeaders:s,networkResponseHeaders:i}=e.getOptions(),a={replay:e,networkDetailAllowUrls:n,networkDetailDenyUrls:r,networkCaptureBodies:o,networkRequestHeaders:s,networkResponseHeaders:i};t&&t.on("beforeAddBreadcrumb",((e,t)=>P_(a,e,t)))}catch{}}function P_(e,t,n){if(t.data)try{L_(t)&&U_(n)&&(C_(t,n),R_(t,n,e)),F_(t)&&j_(n)&&(g_(t,n),__(t,n,e))}catch(e){M&&O.exception(e,"Error when enriching network breadcrumb")}}function L_(e){return"xhr"===e.category}function F_(e){return"fetch"===e.category}function U_(e){return e&&e.xhr}function j_(e){return e&&e.response}function B_(e){const t=ie();va(mm(e)),Ms(d_(e)),n_(e),N_(e);bl(u_(e)),t&&(t.on("beforeSendEvent",e_(e)),t.on("afterSendEvent",Xm(e)),t.on("createDsc",(t=>{const n=e.getSessionId();n&&e.isEnabled()&&"session"===e.recordingMode&&e.checkAndHandleExpiredSession()&&(t.replay_id=n)})),t.on("spanStart",(t=>{e.lastActiveSpan=t})),t.on("spanEnd",(t=>{e.lastActiveSpan=t})),t.on("beforeSendFeedback",((t,n)=>{const r=e.getSessionId();n&&n.includeReplay&&e.isEnabled()&&r&&t.contexts&&t.contexts.feedback&&(t.contexts.feedback.replay_id=r)})))}async function $_(e){try{return Promise.all(nr(e,[H_(ee.performance.memory)]))}catch{return[]}}function H_(e){const{jsHeapSizeLimit:t,totalJSHeapSize:n,usedJSHeapSize:r}=e,o=Date.now()/1e3;return{type:"memory",name:"memory",start:o,end:o,data:{memory:{jsHeapSizeLimit:t,totalJSHeapSize:n,usedJSHeapSize:r}}}}function z_(e,t,n){let r,o,s;const i=n.maxWait?Math.max(n.maxWait,t):0;function a(){return c(),r=e(),r}function c(){void 0!==o&&clearTimeout(o),void 0!==s&&clearTimeout(s),o=s=void 0}function u(){return o&&clearTimeout(o),o=Tt(a,t),i&&void 0===s&&(s=Tt(a,i)),r}return u.cancel=c,u.flush=function(){return void 0!==o||void 0!==s?a():r},u}function W_(e){let t=!1;return(n,r)=>{if(!e.checkAndHandleExpiredSession())return void(M&&O.warn("Received replay event after session expired."));const o=r||!t;t=!0,e.clickDetector&&lm(e.clickDetector,n),e.addUpdate((()=>{if("buffer"===e.recordingMode&&o&&e.setInitialState(),!Hs(e,n,o))return!0;if(!o)return!1;const t=e.session;if(Y_(e,o),"buffer"===e.recordingMode&&t&&e.eventBuffer){const n=e.eventBuffer.getEarliestTimestamp();n&&(M&&O.info(`Updating session start time to earliest event in buffer to ${new Date(n)}`),t.started=n,e.getOptions().stickySession&&$s(t))}return t&&t.previousSessionId||"session"===e.recordingMode&&e.flush(),!0}))}}function G_(e){const t=e.getOptions();return{type:x.Custom,timestamp:Date.now(),data:{tag:"options",payload:{shouldRecordCanvas:e.isRecordingCanvas(),sessionSampleRate:t.sessionSampleRate,errorSampleRate:t.errorSampleRate,useCompressionOption:t.useCompression,blockAllMedia:t.blockAllMedia,maskAllText:t.maskAllText,maskAllInputs:t.maskAllInputs,useCompression:!!e.eventBuffer&&"worker"===e.eventBuffer.type,networkDetailHasUrls:t.networkDetailAllowUrls.length>0,networkCaptureBodies:t.networkCaptureBodies,networkRequestHasHeaders:t.networkRequestHeaders.length>0,networkResponseHasHeaders:t.networkResponseHeaders.length>0}}}}function Y_(e,t){!t||!e.session||0!==e.session.segmentId||Hs(e,G_(e),!1)}function K_(e,t,n,r){return At(Yi(e,vs(e),r,n),[[{type:"replay_event"},e],[{type:"replay_recording",length:"string"==typeof t?(new TextEncoder).encode(t).length:t.length},t]])}function q_({recordingData:e,headers:t}){let n;const r=`${JSON.stringify(t)}\n`;if("string"==typeof e)n=`${r}${e}`;else{const t=(new TextEncoder).encode(r);n=new Uint8Array(t.length+e.length),n.set(t),n.set(e,t.length)}return n}async function V_({client:e,scope:t,replayId:n,event:r}){const o={event_id:n,integrations:"object"!=typeof e._integrations||null===e._integrations||Array.isArray(e._integrations)?void 0:Object.keys(e._integrations)};e.emit("preprocessEvent",r,o);const s=await Ki(e.getOptions(),r,o,t,e,Ae());if(!s)return null;s.platform=s.platform||"javascript";const i=e.getSdkMetadata(),{name:a,version:c}=i&&i.sdk||{};return s.sdk={...s.sdk,name:a||"sentry.javascript.unknown",version:c||"0.0.0"},s}async function J_({recordingData:e,replayId:t,segmentId:n,eventContext:r,timestamp:o,session:s}){const i=q_({recordingData:e,headers:{segment_id:n}}),{urls:a,errorIds:c,traceIds:u,initialTimestamp:l}=r,d=ie(),p=be(),h=d&&d.getTransport(),m=d&&d.getDsn();if(!(d&&h&&m&&s.sampled))return Be({});const f={type:Mp,replay_start_timestamp:l/1e3,timestamp:o/1e3,error_ids:c,trace_ids:u,urls:a,replay_id:t,segment_id:n,replay_type:s.sampled},y=await V_({scope:p,client:d,replayId:t,event:f});if(!y)return d.recordDroppedEvent("event_processor","replay",f),M&&O.info("An event processor returned `null`, will not send event."),Be({});delete y.sdkProcessingMetadata;const _=K_(y,i,m,d.getOptions().tunnel);let g;try{g=await h.send(_)}catch(e){const t=new Error(Ds);try{t.cause=e}catch{}throw t}if("number"==typeof g.statusCode&&(g.statusCode<200||g.statusCode>=300))throw new mc(g.statusCode);const v=na({},g);if(ta(v,"replay"))throw new Ws(v);return g}class mc extends Error{constructor(e){super(`Transport returned status code ${e}`)}}class Ws extends Error{constructor(e){super("Rate limit hit"),this.rateLimits=e}}async function _c(e,t={count:0,interval:Pp}){const{recordingData:n,onError:r}=e;if(n.length)try{return await J_(e),!0}catch(n){if(n instanceof mc||n instanceof Ws)throw n;if(Vi("Replays",{_retryCount:t.count}),r&&r(n),t.count>=3){const e=new Error(`${Ds} - max retries exceeded`);try{e.cause=n}catch{}throw e}return t.interval*=++t.count,new Promise(((n,r)=>{Tt((async()=>{try{await _c(e,t),n(!0)}catch(e){r(e)}}),t.interval)}))}}const gc="__THROTTLED",X_="__SKIPPED";function Q_(e,t,n){const r=new Map;let o=!1;return(...s)=>{const i=Math.floor(Date.now()/1e3);if((e=>{const t=e-n;r.forEach(((e,n)=>{n<t&&r.delete(n)}))})(i),[...r.values()].reduce(((e,t)=>e+t),0)>=t){const e=o;return o=!0,e?X_:gc}o=!1;const a=r.get(i)||0;return r.set(i,a+1),e(...s)}}class Ye{constructor({options:e,recordingOptions:t}){Ye.prototype.__init.call(this),Ye.prototype.__init2.call(this),Ye.prototype.__init3.call(this),Ye.prototype.__init4.call(this),Ye.prototype.__init5.call(this),Ye.prototype.__init6.call(this),this.eventBuffer=null,this.performanceEntries=[],this.replayPerformanceEntries=[],this.recordingMode="session",this.timeouts={sessionIdlePause:Op,sessionIdleExpire:Dp},this._lastActivity=Date.now(),this._isEnabled=!1,this._isPaused=!1,this._requiresManualStart=!1,this._hasInitializedCoreListeners=!1,this._context={errorIds:new Set,traceIds:new Set,urls:[],initialTimestamp:Date.now(),initialUrl:""},this._recordingOptions=t,this._options=e,this._debouncedFlush=z_((()=>this._flush()),this._options.flushMinDelay,{maxWait:this._options.flushMaxDelay}),this._throttledAddEvent=Q_(((e,t)=>qm(this,e,t)),300,5);const{slowClickTimeout:n,slowClickIgnoreSelectors:r}=this.getOptions(),o=n?{threshold:Math.min(Fp,n),timeout:n,scrollTimeout:Up,ignoreSelector:r?r.join(","):""}:void 0;if(o&&(this.clickDetector=new im(this,o)),M){const t=e._experiments;O.setConfig({captureExceptions:!!t.captureExceptions,traceInternals:!!t.traceInternals})}}getContext(){return this._context}isEnabled(){return this._isEnabled}isPaused(){return this._isPaused}isRecordingCanvas(){return!!this._canvas}getOptions(){return this._options}handleException(e){M&&O.exception(e),this._options.onError&&this._options.onError(e)}initializeSampling(e){const{errorSampleRate:t,sessionSampleRate:n}=this._options,r=t<=0&&n<=0;if(this._requiresManualStart=r,!r){if(this._initializeSessionForSampling(e),!this.session)return void(M&&O.exception(new Error("Unable to initialize and create session")));!1!==this.session.sampled&&(this.recordingMode="buffer"===this.session.sampled&&0===this.session.segmentId?"buffer":"session",M&&O.infoTick(`Starting replay in ${this.recordingMode} mode`),this._initializeRecording())}}start(){if(this._isEnabled&&"session"===this.recordingMode)return void(M&&O.info("Recording is already in progress"));if(this._isEnabled&&"buffer"===this.recordingMode)return void(M&&O.info("Buffering is in progress, call `flush()` to save the replay"));M&&O.infoTick("Starting replay in session mode"),this._updateUserActivity();const e=wr({maxReplayDuration:this._options.maxReplayDuration,sessionIdleExpire:this.timeouts.sessionIdleExpire},{stickySession:this._options.stickySession,sessionSampleRate:1,allowBuffering:!1});this.session=e,this._initializeRecording()}startBuffering(){if(this._isEnabled)return void(M&&O.info("Buffering is in progress, call `flush()` to save the replay"));M&&O.infoTick("Starting replay in buffer mode");const e=wr({sessionIdleExpire:this.timeouts.sessionIdleExpire,maxReplayDuration:this._options.maxReplayDuration},{stickySession:this._options.stickySession,sessionSampleRate:0,allowBuffering:!0});this.session=e,this.recordingMode="buffer",this._initializeRecording()}startRecording(){try{const e=this._canvas;this._stopRecording=Ue({...this._recordingOptions,..."buffer"===this.recordingMode?{checkoutEveryNms:Np}:this._options._experiments.continuousCheckout&&{checkoutEveryNms:Math.max(36e4,this._options._experiments.continuousCheckout)},emit:W_(this),onMutation:this._onMutationHandler,...e?{recordCanvas:e.recordCanvas,getCanvasManager:e.getCanvasManager,sampling:e.sampling,dataURLOptions:e.dataURLOptions}:{}})}catch(e){this.handleException(e)}}stopRecording(){try{return this._stopRecording&&(this._stopRecording(),this._stopRecording=void 0),!0}catch(e){return this.handleException(e),!1}}async stop({forceFlush:e=!1,reason:t}={}){if(this._isEnabled){this._isEnabled=!1;try{M&&O.info("Stopping Replay"+(t?` triggered by ${t}`:"")),ac(),this._removeListeners(),this.stopRecording(),this._debouncedFlush.cancel(),e&&await this._flush({force:!0}),this.eventBuffer&&this.eventBuffer.destroy(),this.eventBuffer=null,zm(this)}catch(e){this.handleException(e)}}}pause(){this._isPaused||(this._isPaused=!0,this.stopRecording(),M&&O.info("Pausing replay"))}resume(){!this._isPaused||!this._checkSession()||(this._isPaused=!1,this.startRecording(),M&&O.info("Resuming replay"))}async sendBufferedReplayOrFlush({continueRecording:e=!0}={}){if("session"===this.recordingMode)return this.flushImmediate();const t=Date.now();M&&O.info("Converting buffer to session"),await this.flushImmediate();const n=this.stopRecording();!e||!n||"session"!==this.recordingMode&&(this.recordingMode="session",this.session&&(this._updateUserActivity(t),this._updateSessionActivity(t),this._maybeSaveSession()),this.startRecording())}addUpdate(e){const t=e();"buffer"!==this.recordingMode&&!0!==t&&this._debouncedFlush()}triggerUserActivity(){if(this._updateUserActivity(),this._stopRecording)this.checkAndHandleExpiredSession(),this._updateSessionActivity();else{if(!this._checkSession())return;this.resume()}}updateUserActivity(){this._updateUserActivity(),this._updateSessionActivity()}conditionalFlush(){return"buffer"===this.recordingMode?Promise.resolve():this.flushImmediate()}flush(){return this._debouncedFlush()}flushImmediate(){return this._debouncedFlush(),this._debouncedFlush.flush()}cancelFlush(){this._debouncedFlush.cancel()}getSessionId(){return this.session&&this.session.id}checkAndHandleExpiredSession(){if(!(this._lastActivity&&rs(this._lastActivity,this.timeouts.sessionIdlePause)&&this.session&&"session"===this.session.sampled))return!!this._checkSession();this.pause()}setInitialState(){const e=`${ee.location.pathname}${ee.location.hash}${ee.location.search}`,t=`${ee.location.origin}${e}`;this.performanceEntries=[],this.replayPerformanceEntries=[],this._clearContext(),this._context.initialUrl=t,this._context.initialTimestamp=Date.now(),this._context.urls.push(t)}throttledAddEvent(e,t){const n=this._throttledAddEvent(e,t);if(n===gc){const e=Oe({category:"replay.throttled"});this.addUpdate((()=>!Hs(this,{type:5,timestamp:e.timestamp||0,data:{tag:"breadcrumb",payload:e,metric:!0}})))}return n}getCurrentRoute(){const e=this.lastActiveSpan||$i(),t=e&&Ss(e),n=(t&&jt(t).data||{})[Bi];if(t&&n&&["route","custom"].includes(n))return jt(t).description}_initializeRecording(){this.setInitialState(),this._updateSessionActivity(),this.eventBuffer=Bm({useCompression:this._options.useCompression,workerUrl:this._options.workerUrl}),this._removeListeners(),this._addListeners(),this._isEnabled=!0,this._isPaused=!1,this.startRecording()}_initializeSessionForSampling(e){const t=this._options.errorSampleRate>0,n=wr({sessionIdleExpire:this.timeouts.sessionIdleExpire,maxReplayDuration:this._options.maxReplayDuration,previousSessionId:e},{stickySession:this._options.stickySession,sessionSampleRate:this._options.sessionSampleRate,allowBuffering:t});this.session=n}_checkSession(){if(!this.session)return!1;const e=this.session;return!rc(e,{sessionIdleExpire:this.timeouts.sessionIdleExpire,maxReplayDuration:this._options.maxReplayDuration})||(this._refreshSession(e),!1)}async _refreshSession(e){this._isEnabled&&(await this.stop({reason:"refresh session"}),this.initializeSampling(e.id))}_addListeners(){try{ee.document.addEventListener("visibilitychange",this._handleVisibilityChange),ee.addEventListener("blur",this._handleWindowBlur),ee.addEventListener("focus",this._handleWindowFocus),ee.addEventListener("keydown",this._handleKeyboardEvent),this.clickDetector&&this.clickDetector.addListeners(),this._hasInitializedCoreListeners||(B_(this),this._hasInitializedCoreListeners=!0)}catch(e){this.handleException(e)}this._performanceCleanupCallback=xm(this)}_removeListeners(){try{ee.document.removeEventListener("visibilitychange",this._handleVisibilityChange),ee.removeEventListener("blur",this._handleWindowBlur),ee.removeEventListener("focus",this._handleWindowFocus),ee.removeEventListener("keydown",this._handleKeyboardEvent),this.clickDetector&&this.clickDetector.removeListeners(),this._performanceCleanupCallback&&this._performanceCleanupCallback()}catch(e){this.handleException(e)}}__init(){this._handleVisibilityChange=()=>{"visible"===ee.document.visibilityState?this._doChangeToForegroundTasks():this._doChangeToBackgroundTasks()}}__init2(){this._handleWindowBlur=()=>{const e=Oe({category:"ui.blur"});this._doChangeToBackgroundTasks(e)}}__init3(){this._handleWindowFocus=()=>{const e=Oe({category:"ui.focus"});this._doChangeToForegroundTasks(e)}}__init4(){this._handleKeyboardEvent=e=>{Em(this,e)}}_doChangeToBackgroundTasks(e){!this.session||nc(this.session,{maxReplayDuration:this._options.maxReplayDuration,sessionIdleExpire:this.timeouts.sessionIdleExpire})||(e&&this._createCustomBreadcrumb(e),this.conditionalFlush())}_doChangeToForegroundTasks(e){this.session&&(this.checkAndHandleExpiredSession()?e&&this._createCustomBreadcrumb(e):M&&O.info("Document has become active, but session has expired"))}_updateUserActivity(e=Date.now()){this._lastActivity=e}_updateSessionActivity(e=Date.now()){this.session&&(this.session.lastActivity=e,this._maybeSaveSession())}_createCustomBreadcrumb(e){this.addUpdate((()=>{this.throttledAddEvent({type:x.Custom,timestamp:e.timestamp||0,data:{tag:"breadcrumb",payload:e}})}))}_addPerformanceEntries(){let e=Im(this.performanceEntries).concat(this.replayPerformanceEntries);if(this.performanceEntries=[],this.replayPerformanceEntries=[],this._requiresManualStart){const t=this._context.initialTimestamp/1e3;e=e.filter((e=>e.start>=t))}return Promise.all(nr(this,e))}_clearContext(){this._context.errorIds.clear(),this._context.traceIds.clear(),this._context.urls=[]}_updateInitialTimestampFromEventBuffer(){const{session:e,eventBuffer:t}=this;if(!e||!t||this._requiresManualStart||e.segmentId)return;const n=t.getEarliestTimestamp();n&&n<this._context.initialTimestamp&&(this._context.initialTimestamp=n)}_popEventContext(){const e={initialTimestamp:this._context.initialTimestamp,initialUrl:this._context.initialUrl,errorIds:Array.from(this._context.errorIds),traceIds:Array.from(this._context.traceIds),urls:this._context.urls};return this._clearContext(),e}async _runFlush(){const e=this.getSessionId();if(this.session&&this.eventBuffer&&e){if(await this._addPerformanceEntries(),this.eventBuffer&&this.eventBuffer.hasEvents&&(await $_(this),this.eventBuffer&&e===this.getSessionId()))try{this._updateInitialTimestampFromEventBuffer();const t=Date.now();if(t-this._context.initialTimestamp>this._options.maxReplayDuration+3e4)throw new Error("Session is too long, not sending replay");const n=this._popEventContext(),r=this.session.segmentId++;this._maybeSaveSession();const o=await this.eventBuffer.finish();await _c({replayId:e,recordingData:o,segmentId:r,eventContext:n,session:this.session,timestamp:t,onError:e=>this.handleException(e)})}catch(e){this.handleException(e),this.stop({reason:"sendReplay"});const t=ie();if(t){const n=e instanceof Ws?"ratelimit_backoff":"send_error";t.recordDroppedEvent(n,"replay")}}}else M&&O.error("No session or eventBuffer found to flush.")}__init5(){this._flush=async({force:e=!1}={})=>{if(!this._isEnabled&&!e)return;if(!this.checkAndHandleExpiredSession())return void(M&&O.error("Attempting to finish replay event after session expired."));if(!this.session)return;const t=this.session.started,n=Date.now()-t;this._debouncedFlush.cancel();const r=n<this._options.minReplayDuration,o=n>this._options.maxReplayDuration+5e3;if(r||o)return M&&O.info(`Session duration (${Math.floor(n/1e3)}s) is too ${r?"short":"long"}, not sending replay.`),void(r&&this._debouncedFlush());const s=this.eventBuffer;s&&0===this.session.segmentId&&!s.hasCheckout&&M&&O.info("Flushing initial segment without checkout.");const i=!!this._flushLock;this._flushLock||(this._flushLock=this._runFlush());try{await this._flushLock}catch(e){this.handleException(e)}finally{this._flushLock=void 0,i&&this._debouncedFlush()}}}_maybeSaveSession(){this.session&&this._options.stickySession&&$s(this.session)}__init6(){this._onMutationHandler=e=>{const t=e.length,n=this._options.mutationLimit,r=n&&t>n;if(t>this._options.mutationBreadcrumbLimit||r){const e=Oe({category:"replay.mutations",data:{count:t,limit:r}});this._createCustomBreadcrumb(e)}return!r||(this.stop({reason:"mutationLimit",forceFlush:"session"===this.recordingMode}),!1)}}}function xt(e,t){return[...e,...t].join(",")}function Z_({mask:e,unmask:t,block:n,unblock:r,ignore:o}){return{maskTextSelector:xt(e,[".sentry-mask","[data-sentry-mask]"]),unmaskTextSelector:xt(t,[]),blockSelector:xt(n,[".sentry-block","[data-sentry-block]","base","iframe[srcdoc]:not([src])"]),unblockSelector:xt(r,[]),ignoreSelector:xt(o,[".sentry-ignore","[data-sentry-ignore]",'input[type="file"]'])}}function eg({el:e,key:t,maskAttributes:n,maskAllText:r,privacyOptions:o,value:s}){return!r||o.unmaskTextSelector&&e.matches(o.unmaskTextSelector)?s:n.includes(t)||"value"===t&&"INPUT"===e.tagName&&["submit","button"].includes(e.getAttribute("type")||"")?s.replace(/[\S]/g,"*"):s}const ii='img,image,svg,video,object,picture,embed,map,audio,link[rel="icon"],link[rel="apple-touch-icon"]',tg=["content-length","content-type","accept"];let ai=!1;const ng=e=>new sr(e);class sr{static __initStatic(){this.id="Replay"}constructor({flushMinDelay:e=Ap,flushMaxDelay:t=xp,minReplayDuration:n=jp,maxReplayDuration:r=jo,stickySession:o=!0,useCompression:s=!0,workerUrl:i,_experiments:a={},maskAllText:c=!0,maskAllInputs:u=!0,blockAllMedia:l=!0,mutationBreadcrumbLimit:d=750,mutationLimit:p=1e4,slowClickTimeout:h=7e3,slowClickIgnoreSelectors:m=[],networkDetailAllowUrls:f=[],networkDetailDenyUrls:y=[],networkCaptureBodies:_=!0,networkRequestHeaders:g=[],networkResponseHeaders:v=[],mask:b=[],maskAttributes:S=["title","placeholder"],unmask:E=[],block:k=[],unblock:w=[],ignore:T=[],maskFn:I,beforeAddRecordingEvent:C,beforeErrorSampling:x,onError:M}={}){this.name=sr.id;const O=Z_({mask:b,unmask:E,block:k,unblock:w,ignore:T});if(this._recordingOptions={maskAllInputs:u,maskAllText:c,maskInputOptions:{password:!0},maskTextFn:I,maskInputFn:I,maskAttributeFn:(e,t,n)=>eg({maskAttributes:S,maskAllText:c,privacyOptions:O,key:e,value:t,el:n}),...O,slimDOMOptions:"all",inlineStylesheet:!0,inlineImages:!1,collectFonts:!0,errorHandler:e=>{try{e.__rrweb__=!0}catch{}}},this._initialOptions={flushMinDelay:e,flushMaxDelay:t,minReplayDuration:Math.min(n,Bp),maxReplayDuration:Math.min(r,jo),stickySession:o,useCompression:s,workerUrl:i,blockAllMedia:l,maskAllInputs:u,maskAllText:c,mutationBreadcrumbLimit:d,mutationLimit:p,slowClickTimeout:h,slowClickIgnoreSelectors:m,networkDetailAllowUrls:f,networkDetailDenyUrls:y,networkCaptureBodies:_,networkRequestHeaders:ci(g),networkResponseHeaders:ci(v),beforeAddRecordingEvent:C,beforeErrorSampling:x,onError:M,_experiments:a},this._initialOptions.blockAllMedia&&(this._recordingOptions.blockSelector=this._recordingOptions.blockSelector?`${this._recordingOptions.blockSelector},${ii}`:ii),this._isInitialized&&Do())throw new Error("Multiple Sentry Session Replay instances are not supported");this._isInitialized=!0}get _isInitialized(){return ai}set _isInitialized(e){ai=e}afterAllSetup(e){!Do()||this._replay||(this._setup(e),this._initialize(e))}start(){this._replay&&this._replay.start()}startBuffering(){this._replay&&this._replay.startBuffering()}stop(){return this._replay?this._replay.stop({forceFlush:"session"===this._replay.recordingMode}):Promise.resolve()}flush(e){return this._replay?this._replay.isEnabled()?this._replay.sendBufferedReplayOrFlush(e):(this._replay.start(),Promise.resolve()):Promise.resolve()}getReplayId(){if(this._replay&&this._replay.isEnabled())return this._replay.getSessionId()}getRecordingMode(){if(this._replay&&this._replay.isEnabled())return this._replay.recordingMode}_initialize(e){this._replay&&(this._maybeLoadFromReplayCanvasIntegration(e),this._replay.initializeSampling())}_setup(e){const t=rg(this._initialOptions,e);this._replay=new Ye({options:t,recordingOptions:this._recordingOptions})}_maybeLoadFromReplayCanvasIntegration(e){try{const t=e.getIntegrationByName("ReplayCanvas");if(!t)return;this._replay._canvas=t.getOptions()}catch{}}}function rg(e,t){const n=t.getOptions(),r={sessionSampleRate:0,errorSampleRate:0,...he(e)},o=Lr(n.replaysSessionSampleRate),s=Lr(n.replaysOnErrorSampleRate);return null==o&&null==s&&Je((()=>{console.warn("Replay is disabled because neither `replaysSessionSampleRate` nor `replaysOnErrorSampleRate` are set.")})),null!=o&&(r.sessionSampleRate=o),null!=s&&(r.errorSampleRate=s),r}function ci(e){return[...tg,...e.map((e=>e.toLowerCase()))]}function sg(e){return e&&e.__esModule&&Object.prototype.hasOwnProperty.call(e,"default")?e.default:e}sr.__initStatic();var ui,li,Tr={exports:{}},N={};
2
2
  /**
3
3
  * @license React
4
4
  * react.production.min.js
@@ -7,7 +7,7 @@ import{logErrorToSentry as Uc}from"https://cdn.jsdelivr.net/npm/@wellesley/sentr
7
7
  *
8
8
  * This source code is licensed under the MIT license found in the
9
9
  * LICENSE file in the root directory of this source tree.
10
- */function ig(){if(ui)return N;ui=1;var e=Symbol.for("react.element"),t=Symbol.for("react.portal"),n=Symbol.for("react.fragment"),r=Symbol.for("react.strict_mode"),o=Symbol.for("react.profiler"),s=Symbol.for("react.provider"),i=Symbol.for("react.context"),a=Symbol.for("react.forward_ref"),c=Symbol.for("react.suspense"),u=Symbol.for("react.memo"),l=Symbol.for("react.lazy"),d=Symbol.iterator;var p={isMounted:function(){return!1},enqueueForceUpdate:function(){},enqueueReplaceState:function(){},enqueueSetState:function(){}},h=Object.assign,m={};function f(e,t,n){this.props=e,this.context=t,this.refs=m,this.updater=n||p}function y(){}function _(e,t,n){this.props=e,this.context=t,this.refs=m,this.updater=n||p}f.prototype.isReactComponent={},f.prototype.setState=function(e,t){if("object"!=typeof e&&"function"!=typeof e&&null!=e)throw Error("setState(...): takes an object of state variables to update or a function which returns an object of state variables.");this.updater.enqueueSetState(this,e,t,"setState")},f.prototype.forceUpdate=function(e){this.updater.enqueueForceUpdate(this,e,"forceUpdate")},y.prototype=f.prototype;var g=_.prototype=new y;g.constructor=_,h(g,f.prototype),g.isPureReactComponent=!0;var v=Array.isArray,b=Object.prototype.hasOwnProperty,S={current:null},E={key:!0,ref:!0,__self:!0,__source:!0};function k(t,n,r){var o,s={},i=null,a=null;if(null!=n)for(o in void 0!==n.ref&&(a=n.ref),void 0!==n.key&&(i=""+n.key),n)b.call(n,o)&&!E.hasOwnProperty(o)&&(s[o]=n[o]);var c=arguments.length-2;if(1===c)s.children=r;else if(1<c){for(var u=Array(c),l=0;l<c;l++)u[l]=arguments[l+2];s.children=u}if(t&&t.defaultProps)for(o in c=t.defaultProps)void 0===s[o]&&(s[o]=c[o]);return{$$typeof:e,type:t,key:i,ref:a,props:s,_owner:S.current}}function w(t){return"object"==typeof t&&null!==t&&t.$$typeof===e}var T=/\/+/g;function I(e,t){return"object"==typeof e&&null!==e&&null!=e.key?function(e){var t={"=":"=0",":":"=2"};return"$"+e.replace(/[=:]/g,(function(e){return t[e]}))}(""+e.key):t.toString(36)}function x(n,r,o,s,i){var a=typeof n;("undefined"===a||"boolean"===a)&&(n=null);var c=!1;if(null===n)c=!0;else switch(a){case"string":case"number":c=!0;break;case"object":switch(n.$$typeof){case e:case t:c=!0}}if(c)return i=i(c=n),n=""===s?"."+I(c,0):s,v(i)?(o="",null!=n&&(o=n.replace(T,"$&/")+"/"),x(i,r,o,"",(function(e){return e}))):null!=i&&(w(i)&&(i=function(t,n){return{$$typeof:e,type:t.type,key:n,ref:t.ref,props:t.props,_owner:t._owner}}(i,o+(!i.key||c&&c.key===i.key?"":(""+i.key).replace(T,"$&/")+"/")+n)),r.push(i)),1;if(c=0,s=""===s?".":s+":",v(n))for(var u=0;u<n.length;u++){var l=s+I(a=n[u],u);c+=x(a,r,o,l,i)}else if(l=function(e){return null===e||"object"!=typeof e?null:"function"==typeof(e=d&&e[d]||e["@@iterator"])?e:null}(n),"function"==typeof l)for(n=l.call(n),u=0;!(a=n.next()).done;)c+=x(a=a.value,r,o,l=s+I(a,u++),i);else if("object"===a)throw r=String(n),Error("Objects are not valid as a React child (found: "+("[object Object]"===r?"object with keys {"+Object.keys(n).join(", ")+"}":r)+"). If you meant to render a collection of children, use an array instead.");return c}function C(e,t,n){if(null==e)return e;var r=[],o=0;return x(e,r,"","",(function(e){return t.call(n,e,o++)})),r}function M(e){if(-1===e._status){var t=e._result;(t=t()).then((function(t){(0===e._status||-1===e._status)&&(e._status=1,e._result=t)}),(function(t){(0===e._status||-1===e._status)&&(e._status=2,e._result=t)})),-1===e._status&&(e._status=0,e._result=t)}if(1===e._status)return e._result.default;throw e._result}var O={current:null},A={transition:null},R={ReactCurrentDispatcher:O,ReactCurrentBatchConfig:A,ReactCurrentOwner:S};return N.Children={map:C,forEach:function(e,t,n){C(e,(function(){t.apply(this,arguments)}),n)},count:function(e){var t=0;return C(e,(function(){t++})),t},toArray:function(e){return C(e,(function(e){return e}))||[]},only:function(e){if(!w(e))throw Error("React.Children.only expected to receive a single React element child.");return e}},N.Component=f,N.Fragment=n,N.Profiler=o,N.PureComponent=_,N.StrictMode=r,N.Suspense=c,N.__SECRET_INTERNALS_DO_NOT_USE_OR_YOU_WILL_BE_FIRED=R,N.cloneElement=function(t,n,r){if(null==t)throw Error("React.cloneElement(...): The argument must be a React element, but you passed "+t+".");var o=h({},t.props),s=t.key,i=t.ref,a=t._owner;if(null!=n){if(void 0!==n.ref&&(i=n.ref,a=S.current),void 0!==n.key&&(s=""+n.key),t.type&&t.type.defaultProps)var c=t.type.defaultProps;for(u in n)b.call(n,u)&&!E.hasOwnProperty(u)&&(o[u]=void 0===n[u]&&void 0!==c?c[u]:n[u])}var u=arguments.length-2;if(1===u)o.children=r;else if(1<u){c=Array(u);for(var l=0;l<u;l++)c[l]=arguments[l+2];o.children=c}return{$$typeof:e,type:t.type,key:s,ref:i,props:o,_owner:a}},N.createContext=function(e){return(e={$$typeof:i,_currentValue:e,_currentValue2:e,_threadCount:0,Provider:null,Consumer:null,_defaultValue:null,_globalName:null}).Provider={$$typeof:s,_context:e},e.Consumer=e},N.createElement=k,N.createFactory=function(e){var t=k.bind(null,e);return t.type=e,t},N.createRef=function(){return{current:null}},N.forwardRef=function(e){return{$$typeof:a,render:e}},N.isValidElement=w,N.lazy=function(e){return{$$typeof:l,_payload:{_status:-1,_result:e},_init:M}},N.memo=function(e,t){return{$$typeof:u,type:e,compare:void 0===t?null:t}},N.startTransition=function(e){var t=A.transition;A.transition={};try{e()}finally{A.transition=t}},N.unstable_act=function(){throw Error("act(...) is not supported in production builds of React.")},N.useCallback=function(e,t){return O.current.useCallback(e,t)},N.useContext=function(e){return O.current.useContext(e)},N.useDebugValue=function(){},N.useDeferredValue=function(e){return O.current.useDeferredValue(e)},N.useEffect=function(e,t){return O.current.useEffect(e,t)},N.useId=function(){return O.current.useId()},N.useImperativeHandle=function(e,t,n){return O.current.useImperativeHandle(e,t,n)},N.useInsertionEffect=function(e,t){return O.current.useInsertionEffect(e,t)},N.useLayoutEffect=function(e,t){return O.current.useLayoutEffect(e,t)},N.useMemo=function(e,t){return O.current.useMemo(e,t)},N.useReducer=function(e,t,n){return O.current.useReducer(e,t,n)},N.useRef=function(e){return O.current.useRef(e)},N.useState=function(e){return O.current.useState(e)},N.useSyncExternalStore=function(e,t,n){return O.current.useSyncExternalStore(e,t,n)},N.useTransition=function(){return O.current.useTransition()},N.version="18.2.0",N}function yc(){return li||(li=1,Tr.exports=ig()),Tr.exports}var or=yc();const Ec=og(or),di=jc({__proto__:null,default:Ec},[or]);function ag(e){const t={...e};return ra(t,"react"),Vi("react",{version:or.version}),Mp(t)}const Sc=()=>"object"!=typeof window;var cg={DISTRIB_RELEASE:"24.04",JDK_18:"/usr/lib/jvm/java-1.8.0-amazon-corretto",TEAMCITY_PROJECT_NAME:"Web Apps",USER:"teamcity",npm_config_user_agent:"npm/10.9.2 node/v22.14.0 linux x64 workspaces/false ci/teamcity",rvm_pretty_print_flag:"0",NUGET_PLUGIN_HANDSHAKE_TIMEOUT_IN_SECONDS:"20",TEAMCITY_PROCESS_PARENT_FLOW_ID:"",ANDROID_SDK_HOME:"/home/teamcity/android-sdk-linux",DOTNET_CLI_TELEMETRY_OPTOUT:"true",JDK_11_x64:"/usr/lib/jvm/java-11-amazon-corretto",npm_node_execpath:"/home/teamcity/.nvm/versions/node/v22.14.0/bin/node",SHLVL:"0",npm_config_noproxy:"",BUILD_VCS_NUMBER:"6a1bbbe9156fa4c249d681503a5a4a38683ddfc1",HOME:"/home/teamcity",OLDPWD:"/",BUILD_URL:"https://wellesley.teamcity.com/build/15202",JRE_HOME:"/usr/lib/jvm/java-21-amazon-corretto",npm_package_json:"/mnt/agent/work/70fcd8585843667f/packages/sentry/package.json",ANDROID_SDKMANAGER_PATH:"/home/teamcity/android-sdk-linux/cmdline-tools/latest/bin/sdkmanager",TEAMCITY_BUILD_PROPERTIES_FILE:"/mnt/agent/temp/buildTmp/teamcity.build.parameters",npm_package_engines_node:">=20.2.0",rvm_stored_umask:"0022",GRADLE_HOME:"/opt/gradle",npm_config_local_prefix:"/mnt/agent/work/70fcd8585843667f",npm_config_userconfig:"/home/teamcity/.npmrc",rvm_user_install_flag:"1",BUILD_VCS_NUMBER_WebApps:"6a1bbbe9156fa4c249d681503a5a4a38683ddfc1",GOROOT:"/opt/go",JDK_18_x64:"/usr/lib/jvm/java-1.8.0-amazon-corretto",SYSTEMD_EXEC_PID:"1344",COLOR:"1",TEAMCITY_BUILDCONF_NAME:"Apps",DISTRIB_DESCRIPTION:"Ubuntu 24.04.2 LTS",DOTNET_SKIP_FIRST_TIME_EXPERIENCE:"true",TMPDIR:"/mnt/agent/temp/buildTmp",LOGNAME:"teamcity",JOURNAL_STREAM:"8:12308",TEMP:"/mnt/agent/temp/buildTmp",_:"/usr/bin/nohup",npm_config_npm_version:"10.9.2",npm_config_prefix:"/home/teamcity/.nvm/versions/node/v22.14.0",rvm_bin_path:"/home/teamcity/.rvm/bin",IRBRC:"/home/teamcity/.rvm/rubies/ruby-3.3.7/.irbrc",MEMORY_PRESSURE_WATCH:"/sys/fs/cgroup/system.slice/teamcity-agent.service/memory.pressure",P4CONFIG:".p4config",RUBY_VERSION:"ruby-3.3.7",npm_config_cache:"/home/teamcity/.npm",DOTNET_ROOT:"/usr/share/dotnet",JDK_1_8:"/usr/lib/jvm/java-1.8.0-amazon-corretto",MNT_MOUNT:"/dev/nvme1n1 on /mnt type ext4 (rw,noatime)",TEAMCITY_GIT_PATH:"/usr/local/bin/git",AWS_SHARED_CREDENTIALS_FILE:"/mnt/agent/temp/agentTmp/aws.credentials",DISTRIB_ID:"Ubuntu",npm_config_node_gyp:"/home/teamcity/.nvm/versions/node/v22.14.0/lib/node_modules/npm/node_modules/node-gyp/bin/node-gyp.js",PATH:"/mnt/agent/work/70fcd8585843667f/packages/sentry/node_modules/.bin:/mnt/agent/work/70fcd8585843667f/packages/node_modules/.bin:/mnt/agent/work/70fcd8585843667f/node_modules/.bin:/mnt/agent/work/node_modules/.bin:/mnt/agent/node_modules/.bin:/mnt/node_modules/.bin:/node_modules/.bin:/home/teamcity/.nvm/versions/node/v22.14.0/lib/node_modules/npm/node_modules/@npmcli/run-script/lib/node-gyp-bin:/mnt/agent/work/70fcd8585843667f/node_modules/.bin:/mnt/agent/work/node_modules/.bin:/mnt/agent/node_modules/.bin:/mnt/node_modules/.bin:/node_modules/.bin:/home/teamcity/.nvm/versions/node/v22.14.0/lib/node_modules/npm/node_modules/@npmcli/run-script/lib/node-gyp-bin:/mnt/agent/work/70fcd8585843667f/node_modules/.bin:/mnt/agent/work/node_modules/.bin:/mnt/agent/node_modules/.bin:/mnt/node_modules/.bin:/node_modules/.bin:/home/teamcity/.nvm/versions/node/v22.14.0/lib/node_modules/npm/node_modules/@npmcli/run-script/lib/node-gyp-bin:/home/teamcity/.cargo/bin:/home/teamcity/.rvm/gems/ruby-3.3.7/bin:/home/teamcity/.rvm/gems/ruby-3.3.7@global/bin:/home/teamcity/.rvm/rubies/ruby-3.3.7/bin:/home/teamcity/.rvm/bin:/home/teamcity/.local/bin:/usr/lib/jvm/java-21-amazon-corretto/bin:/usr/local/sbin:/usr/local/bin:/usr/sbin:/usr/bin:/snap/bin:/usr/share/dotnet:/usr/share/dotnet/tools:/home/teamcity/google-cloud-sdk/bin:/home/teamcity/go/bin:/usr/bin/mvn:/home/teamcity/.nvm/versions/node/v22.14.0/bin",INVOCATION_ID:"c1d04ea3c84d4e05a7330e8007678ce9",JDK_11_0:"/usr/lib/jvm/java-11-amazon-corretto",NODE:"/home/teamcity/.nvm/versions/node/v22.14.0/bin/node",TEAMCITY_CAPTURE_ENV:'"/usr/lib/jvm/java-21-amazon-corretto/bin/java" -jar "/home/teamcity/agent/plugins/environment-fetcher/lib/environment-fetcher-bin-2024.12-174504-jar-with-dependencies.jar"',TURBO_HASH:"947cea8d3af34395",npm_package_name:"@wellesley/sentry",DISTRIB_CODENAME:"noble",JDK_21_0:"/usr/lib/jvm/java-21-amazon-corretto",npm_config_color:"always",DOMAIN_ENV:"test",MY_RUBY_HOME:"/home/teamcity/.rvm/rubies/ruby-3.3.7",TEAMCITY_VERSION:"2024.12.2 (build 174504)",LANG:"en_US.UTF-8",GROOVY_HOME:"/opt/groovy",TMP:"/mnt/agent/temp/buildTmp",npm_lifecycle_script:"tsc && vite build",BUILD_NUMBER:"2143",NUGET_PLUGIN_REQUEST_TIMEOUT_IN_SECONDS:"20",UID:"1001",AWS_PROFILE:"default",GOPATH:"/home/teamcity/go",JDK_17_0:"/usr/lib/jvm/java-17-amazon-corretto",SHELL:"/bin/bash",TEAMCITY_AGENT_OPTS:"-XX:+HeapDumpOnOutOfMemoryError -XX:HeapDumpPath=../logs/agent_%p.hprof -Dteamcity.internal.hosted.server.technicalName=PREINIT_AGENT",npm_lifecycle_event:"build",npm_package_version:"1.0.21",JDK_1_8_x64:"/usr/lib/jvm/java-1.8.0-amazon-corretto",rvm_loaded_flag:"1",rvm_prefix:"/home/teamcity",GEM_HOME:"/home/teamcity/.rvm/gems/ruby-3.3.7",TURBO_INVOCATION_DIR:"/mnt/agent/work/70fcd8585843667f",JDK_11_0_x64:"/usr/lib/jvm/java-11-amazon-corretto",JDK_21_0_x64:"/usr/lib/jvm/java-21-amazon-corretto",rvm_version:"1.29.12 (latest)",npm_config_globalconfig:"/home/teamcity/.nvm/versions/node/v22.14.0/etc/npmrc",npm_config_init_module:"/home/teamcity/.npm-init.js",GEM_PATH:"/home/teamcity/.rvm/gems/ruby-3.3.7:/home/teamcity/.rvm/gems/ruby-3.3.7@global",JAVA_HOME:"/usr/lib/jvm/java-21-amazon-corretto",PWD:"/mnt/agent/work/70fcd8585843667f/packages/sentry",TEAMCITY_AGENT_MEM_OPTS:"-Xmx512m",npm_execpath:"/home/teamcity/.nvm/versions/node/v22.14.0/lib/node_modules/npm/bin/npm-cli.js",ANDROID_HOME:"/home/teamcity/android-sdk-linux",JDK_11:"/usr/lib/jvm/java-11-amazon-corretto",TEAMCITY_GIT_VERSION:"2.47.1.0",XDG_DATA_DIRS:"/usr/local/share:/usr/share:/var/lib/snapd/desktop",npm_config_global_prefix:"/home/teamcity/.nvm/versions/node/v22.14.0",TEAMCITY_PROCESS_FLOW_ID:"679780709992",npm_command:"run-script",JDK_17_0_x64:"/usr/lib/jvm/java-17-amazon-corretto",rvm_ruby_string:"ruby-3.3.7",MEMORY_PRESSURE_WRITE:"c29tZSAyMDAwMDAgMjAwMDAwMAA=",rvm_path:"/home/teamcity/.rvm",EDITOR:"vi",INIT_CWD:"/mnt/agent/work/70fcd8585843667f/packages/sentry",JDK_HOME:"/usr/lib/jvm/java-21-amazon-corretto",rvm_delete_flag:"0",NODE_ENV:"production",APP_NAME:"@wellesley/sentry"};const ug=()=>!!cg.JEST_WORKER_ID,fi=["debug","info","warn","error"],lg=(e,t)=>{const n=fi.indexOf(e);return fi.indexOf(t)>=n},En=(e,t,n,...r)=>{lg(t,e)&&console.log(`[${e}] ${n}`,...r)},dg=()=>null==window?void 0:window.localStorage.getItem("logger_lvl"),fg=(e=!Sc()&&dg()||"warn")=>{let t=e;return{debug:(e,...n)=>En("debug",t,e,...n),info:(e,...n)=>En("info",t,e,...n),warn:(e,...n)=>En("warn",t,e,...n),error:(e,...n)=>(Uc(e,...n),En("error",t,e,...n)),setLevel:e=>{t=e},getLevel:()=>t}},pg=fg();var pi={DISTRIB_RELEASE:"24.04",JDK_18:"/usr/lib/jvm/java-1.8.0-amazon-corretto",TEAMCITY_PROJECT_NAME:"Web Apps",USER:"teamcity",npm_config_user_agent:"npm/10.9.2 node/v22.14.0 linux x64 workspaces/false ci/teamcity",rvm_pretty_print_flag:"0",NUGET_PLUGIN_HANDSHAKE_TIMEOUT_IN_SECONDS:"20",TEAMCITY_PROCESS_PARENT_FLOW_ID:"",ANDROID_SDK_HOME:"/home/teamcity/android-sdk-linux",DOTNET_CLI_TELEMETRY_OPTOUT:"true",JDK_11_x64:"/usr/lib/jvm/java-11-amazon-corretto",npm_node_execpath:"/home/teamcity/.nvm/versions/node/v22.14.0/bin/node",SHLVL:"0",npm_config_noproxy:"",BUILD_VCS_NUMBER:"6a1bbbe9156fa4c249d681503a5a4a38683ddfc1",HOME:"/home/teamcity",OLDPWD:"/",BUILD_URL:"https://wellesley.teamcity.com/build/15202",JRE_HOME:"/usr/lib/jvm/java-21-amazon-corretto",npm_package_json:"/mnt/agent/work/70fcd8585843667f/packages/sentry/package.json",ANDROID_SDKMANAGER_PATH:"/home/teamcity/android-sdk-linux/cmdline-tools/latest/bin/sdkmanager",TEAMCITY_BUILD_PROPERTIES_FILE:"/mnt/agent/temp/buildTmp/teamcity.build.parameters",npm_package_engines_node:">=20.2.0",rvm_stored_umask:"0022",GRADLE_HOME:"/opt/gradle",npm_config_local_prefix:"/mnt/agent/work/70fcd8585843667f",npm_config_userconfig:"/home/teamcity/.npmrc",rvm_user_install_flag:"1",BUILD_VCS_NUMBER_WebApps:"6a1bbbe9156fa4c249d681503a5a4a38683ddfc1",GOROOT:"/opt/go",JDK_18_x64:"/usr/lib/jvm/java-1.8.0-amazon-corretto",SYSTEMD_EXEC_PID:"1344",COLOR:"1",TEAMCITY_BUILDCONF_NAME:"Apps",DISTRIB_DESCRIPTION:"Ubuntu 24.04.2 LTS",DOTNET_SKIP_FIRST_TIME_EXPERIENCE:"true",TMPDIR:"/mnt/agent/temp/buildTmp",LOGNAME:"teamcity",JOURNAL_STREAM:"8:12308",TEMP:"/mnt/agent/temp/buildTmp",_:"/usr/bin/nohup",npm_config_npm_version:"10.9.2",npm_config_prefix:"/home/teamcity/.nvm/versions/node/v22.14.0",rvm_bin_path:"/home/teamcity/.rvm/bin",IRBRC:"/home/teamcity/.rvm/rubies/ruby-3.3.7/.irbrc",MEMORY_PRESSURE_WATCH:"/sys/fs/cgroup/system.slice/teamcity-agent.service/memory.pressure",P4CONFIG:".p4config",RUBY_VERSION:"ruby-3.3.7",npm_config_cache:"/home/teamcity/.npm",DOTNET_ROOT:"/usr/share/dotnet",JDK_1_8:"/usr/lib/jvm/java-1.8.0-amazon-corretto",MNT_MOUNT:"/dev/nvme1n1 on /mnt type ext4 (rw,noatime)",TEAMCITY_GIT_PATH:"/usr/local/bin/git",AWS_SHARED_CREDENTIALS_FILE:"/mnt/agent/temp/agentTmp/aws.credentials",DISTRIB_ID:"Ubuntu",npm_config_node_gyp:"/home/teamcity/.nvm/versions/node/v22.14.0/lib/node_modules/npm/node_modules/node-gyp/bin/node-gyp.js",PATH:"/mnt/agent/work/70fcd8585843667f/packages/sentry/node_modules/.bin:/mnt/agent/work/70fcd8585843667f/packages/node_modules/.bin:/mnt/agent/work/70fcd8585843667f/node_modules/.bin:/mnt/agent/work/node_modules/.bin:/mnt/agent/node_modules/.bin:/mnt/node_modules/.bin:/node_modules/.bin:/home/teamcity/.nvm/versions/node/v22.14.0/lib/node_modules/npm/node_modules/@npmcli/run-script/lib/node-gyp-bin:/mnt/agent/work/70fcd8585843667f/node_modules/.bin:/mnt/agent/work/node_modules/.bin:/mnt/agent/node_modules/.bin:/mnt/node_modules/.bin:/node_modules/.bin:/home/teamcity/.nvm/versions/node/v22.14.0/lib/node_modules/npm/node_modules/@npmcli/run-script/lib/node-gyp-bin:/mnt/agent/work/70fcd8585843667f/node_modules/.bin:/mnt/agent/work/node_modules/.bin:/mnt/agent/node_modules/.bin:/mnt/node_modules/.bin:/node_modules/.bin:/home/teamcity/.nvm/versions/node/v22.14.0/lib/node_modules/npm/node_modules/@npmcli/run-script/lib/node-gyp-bin:/home/teamcity/.cargo/bin:/home/teamcity/.rvm/gems/ruby-3.3.7/bin:/home/teamcity/.rvm/gems/ruby-3.3.7@global/bin:/home/teamcity/.rvm/rubies/ruby-3.3.7/bin:/home/teamcity/.rvm/bin:/home/teamcity/.local/bin:/usr/lib/jvm/java-21-amazon-corretto/bin:/usr/local/sbin:/usr/local/bin:/usr/sbin:/usr/bin:/snap/bin:/usr/share/dotnet:/usr/share/dotnet/tools:/home/teamcity/google-cloud-sdk/bin:/home/teamcity/go/bin:/usr/bin/mvn:/home/teamcity/.nvm/versions/node/v22.14.0/bin",INVOCATION_ID:"c1d04ea3c84d4e05a7330e8007678ce9",JDK_11_0:"/usr/lib/jvm/java-11-amazon-corretto",NODE:"/home/teamcity/.nvm/versions/node/v22.14.0/bin/node",TEAMCITY_CAPTURE_ENV:'"/usr/lib/jvm/java-21-amazon-corretto/bin/java" -jar "/home/teamcity/agent/plugins/environment-fetcher/lib/environment-fetcher-bin-2024.12-174504-jar-with-dependencies.jar"',TURBO_HASH:"947cea8d3af34395",npm_package_name:"@wellesley/sentry",DISTRIB_CODENAME:"noble",JDK_21_0:"/usr/lib/jvm/java-21-amazon-corretto",npm_config_color:"always",DOMAIN_ENV:"test",MY_RUBY_HOME:"/home/teamcity/.rvm/rubies/ruby-3.3.7",TEAMCITY_VERSION:"2024.12.2 (build 174504)",LANG:"en_US.UTF-8",GROOVY_HOME:"/opt/groovy",TMP:"/mnt/agent/temp/buildTmp",npm_lifecycle_script:"tsc && vite build",BUILD_NUMBER:"2143",NUGET_PLUGIN_REQUEST_TIMEOUT_IN_SECONDS:"20",UID:"1001",AWS_PROFILE:"default",GOPATH:"/home/teamcity/go",JDK_17_0:"/usr/lib/jvm/java-17-amazon-corretto",SHELL:"/bin/bash",TEAMCITY_AGENT_OPTS:"-XX:+HeapDumpOnOutOfMemoryError -XX:HeapDumpPath=../logs/agent_%p.hprof -Dteamcity.internal.hosted.server.technicalName=PREINIT_AGENT",npm_lifecycle_event:"build",npm_package_version:"1.0.21",JDK_1_8_x64:"/usr/lib/jvm/java-1.8.0-amazon-corretto",rvm_loaded_flag:"1",rvm_prefix:"/home/teamcity",GEM_HOME:"/home/teamcity/.rvm/gems/ruby-3.3.7",TURBO_INVOCATION_DIR:"/mnt/agent/work/70fcd8585843667f",JDK_11_0_x64:"/usr/lib/jvm/java-11-amazon-corretto",JDK_21_0_x64:"/usr/lib/jvm/java-21-amazon-corretto",rvm_version:"1.29.12 (latest)",npm_config_globalconfig:"/home/teamcity/.nvm/versions/node/v22.14.0/etc/npmrc",npm_config_init_module:"/home/teamcity/.npm-init.js",GEM_PATH:"/home/teamcity/.rvm/gems/ruby-3.3.7:/home/teamcity/.rvm/gems/ruby-3.3.7@global",JAVA_HOME:"/usr/lib/jvm/java-21-amazon-corretto",PWD:"/mnt/agent/work/70fcd8585843667f/packages/sentry",TEAMCITY_AGENT_MEM_OPTS:"-Xmx512m",npm_execpath:"/home/teamcity/.nvm/versions/node/v22.14.0/lib/node_modules/npm/bin/npm-cli.js",ANDROID_HOME:"/home/teamcity/android-sdk-linux",JDK_11:"/usr/lib/jvm/java-11-amazon-corretto",TEAMCITY_GIT_VERSION:"2.47.1.0",XDG_DATA_DIRS:"/usr/local/share:/usr/share:/var/lib/snapd/desktop",npm_config_global_prefix:"/home/teamcity/.nvm/versions/node/v22.14.0",TEAMCITY_PROCESS_FLOW_ID:"679780709992",npm_command:"run-script",JDK_17_0_x64:"/usr/lib/jvm/java-17-amazon-corretto",rvm_ruby_string:"ruby-3.3.7",MEMORY_PRESSURE_WRITE:"c29tZSAyMDAwMDAgMjAwMDAwMAA=",rvm_path:"/home/teamcity/.rvm",EDITOR:"vi",INIT_CWD:"/mnt/agent/work/70fcd8585843667f/packages/sentry",JDK_HOME:"/usr/lib/jvm/java-21-amazon-corretto",rvm_delete_flag:"0",NODE_ENV:"production",APP_NAME:"@wellesley/sentry"};const hg=e=>`${e||"wlsy"}-${pi.DOMAIN_ENV}#${pi.BUILD_NUMBER}`;var bc={DISTRIB_RELEASE:"24.04",JDK_18:"/usr/lib/jvm/java-1.8.0-amazon-corretto",TEAMCITY_PROJECT_NAME:"Web Apps",USER:"teamcity",npm_config_user_agent:"npm/10.9.2 node/v22.14.0 linux x64 workspaces/false ci/teamcity",rvm_pretty_print_flag:"0",NUGET_PLUGIN_HANDSHAKE_TIMEOUT_IN_SECONDS:"20",TEAMCITY_PROCESS_PARENT_FLOW_ID:"",ANDROID_SDK_HOME:"/home/teamcity/android-sdk-linux",DOTNET_CLI_TELEMETRY_OPTOUT:"true",JDK_11_x64:"/usr/lib/jvm/java-11-amazon-corretto",npm_node_execpath:"/home/teamcity/.nvm/versions/node/v22.14.0/bin/node",SHLVL:"0",npm_config_noproxy:"",BUILD_VCS_NUMBER:"6a1bbbe9156fa4c249d681503a5a4a38683ddfc1",HOME:"/home/teamcity",OLDPWD:"/",BUILD_URL:"https://wellesley.teamcity.com/build/15202",JRE_HOME:"/usr/lib/jvm/java-21-amazon-corretto",npm_package_json:"/mnt/agent/work/70fcd8585843667f/packages/sentry/package.json",ANDROID_SDKMANAGER_PATH:"/home/teamcity/android-sdk-linux/cmdline-tools/latest/bin/sdkmanager",TEAMCITY_BUILD_PROPERTIES_FILE:"/mnt/agent/temp/buildTmp/teamcity.build.parameters",npm_package_engines_node:">=20.2.0",rvm_stored_umask:"0022",GRADLE_HOME:"/opt/gradle",npm_config_local_prefix:"/mnt/agent/work/70fcd8585843667f",npm_config_userconfig:"/home/teamcity/.npmrc",rvm_user_install_flag:"1",BUILD_VCS_NUMBER_WebApps:"6a1bbbe9156fa4c249d681503a5a4a38683ddfc1",GOROOT:"/opt/go",JDK_18_x64:"/usr/lib/jvm/java-1.8.0-amazon-corretto",SYSTEMD_EXEC_PID:"1344",COLOR:"1",TEAMCITY_BUILDCONF_NAME:"Apps",DISTRIB_DESCRIPTION:"Ubuntu 24.04.2 LTS",DOTNET_SKIP_FIRST_TIME_EXPERIENCE:"true",TMPDIR:"/mnt/agent/temp/buildTmp",LOGNAME:"teamcity",JOURNAL_STREAM:"8:12308",TEMP:"/mnt/agent/temp/buildTmp",_:"/usr/bin/nohup",npm_config_npm_version:"10.9.2",npm_config_prefix:"/home/teamcity/.nvm/versions/node/v22.14.0",rvm_bin_path:"/home/teamcity/.rvm/bin",IRBRC:"/home/teamcity/.rvm/rubies/ruby-3.3.7/.irbrc",MEMORY_PRESSURE_WATCH:"/sys/fs/cgroup/system.slice/teamcity-agent.service/memory.pressure",P4CONFIG:".p4config",RUBY_VERSION:"ruby-3.3.7",npm_config_cache:"/home/teamcity/.npm",DOTNET_ROOT:"/usr/share/dotnet",JDK_1_8:"/usr/lib/jvm/java-1.8.0-amazon-corretto",MNT_MOUNT:"/dev/nvme1n1 on /mnt type ext4 (rw,noatime)",TEAMCITY_GIT_PATH:"/usr/local/bin/git",AWS_SHARED_CREDENTIALS_FILE:"/mnt/agent/temp/agentTmp/aws.credentials",DISTRIB_ID:"Ubuntu",npm_config_node_gyp:"/home/teamcity/.nvm/versions/node/v22.14.0/lib/node_modules/npm/node_modules/node-gyp/bin/node-gyp.js",PATH:"/mnt/agent/work/70fcd8585843667f/packages/sentry/node_modules/.bin:/mnt/agent/work/70fcd8585843667f/packages/node_modules/.bin:/mnt/agent/work/70fcd8585843667f/node_modules/.bin:/mnt/agent/work/node_modules/.bin:/mnt/agent/node_modules/.bin:/mnt/node_modules/.bin:/node_modules/.bin:/home/teamcity/.nvm/versions/node/v22.14.0/lib/node_modules/npm/node_modules/@npmcli/run-script/lib/node-gyp-bin:/mnt/agent/work/70fcd8585843667f/node_modules/.bin:/mnt/agent/work/node_modules/.bin:/mnt/agent/node_modules/.bin:/mnt/node_modules/.bin:/node_modules/.bin:/home/teamcity/.nvm/versions/node/v22.14.0/lib/node_modules/npm/node_modules/@npmcli/run-script/lib/node-gyp-bin:/mnt/agent/work/70fcd8585843667f/node_modules/.bin:/mnt/agent/work/node_modules/.bin:/mnt/agent/node_modules/.bin:/mnt/node_modules/.bin:/node_modules/.bin:/home/teamcity/.nvm/versions/node/v22.14.0/lib/node_modules/npm/node_modules/@npmcli/run-script/lib/node-gyp-bin:/home/teamcity/.cargo/bin:/home/teamcity/.rvm/gems/ruby-3.3.7/bin:/home/teamcity/.rvm/gems/ruby-3.3.7@global/bin:/home/teamcity/.rvm/rubies/ruby-3.3.7/bin:/home/teamcity/.rvm/bin:/home/teamcity/.local/bin:/usr/lib/jvm/java-21-amazon-corretto/bin:/usr/local/sbin:/usr/local/bin:/usr/sbin:/usr/bin:/snap/bin:/usr/share/dotnet:/usr/share/dotnet/tools:/home/teamcity/google-cloud-sdk/bin:/home/teamcity/go/bin:/usr/bin/mvn:/home/teamcity/.nvm/versions/node/v22.14.0/bin",INVOCATION_ID:"c1d04ea3c84d4e05a7330e8007678ce9",JDK_11_0:"/usr/lib/jvm/java-11-amazon-corretto",NODE:"/home/teamcity/.nvm/versions/node/v22.14.0/bin/node",TEAMCITY_CAPTURE_ENV:'"/usr/lib/jvm/java-21-amazon-corretto/bin/java" -jar "/home/teamcity/agent/plugins/environment-fetcher/lib/environment-fetcher-bin-2024.12-174504-jar-with-dependencies.jar"',TURBO_HASH:"947cea8d3af34395",npm_package_name:"@wellesley/sentry",DISTRIB_CODENAME:"noble",JDK_21_0:"/usr/lib/jvm/java-21-amazon-corretto",npm_config_color:"always",DOMAIN_ENV:"test",MY_RUBY_HOME:"/home/teamcity/.rvm/rubies/ruby-3.3.7",TEAMCITY_VERSION:"2024.12.2 (build 174504)",LANG:"en_US.UTF-8",GROOVY_HOME:"/opt/groovy",TMP:"/mnt/agent/temp/buildTmp",npm_lifecycle_script:"tsc && vite build",BUILD_NUMBER:"2143",NUGET_PLUGIN_REQUEST_TIMEOUT_IN_SECONDS:"20",UID:"1001",AWS_PROFILE:"default",GOPATH:"/home/teamcity/go",JDK_17_0:"/usr/lib/jvm/java-17-amazon-corretto",SHELL:"/bin/bash",TEAMCITY_AGENT_OPTS:"-XX:+HeapDumpOnOutOfMemoryError -XX:HeapDumpPath=../logs/agent_%p.hprof -Dteamcity.internal.hosted.server.technicalName=PREINIT_AGENT",npm_lifecycle_event:"build",npm_package_version:"1.0.21",JDK_1_8_x64:"/usr/lib/jvm/java-1.8.0-amazon-corretto",rvm_loaded_flag:"1",rvm_prefix:"/home/teamcity",GEM_HOME:"/home/teamcity/.rvm/gems/ruby-3.3.7",TURBO_INVOCATION_DIR:"/mnt/agent/work/70fcd8585843667f",JDK_11_0_x64:"/usr/lib/jvm/java-11-amazon-corretto",JDK_21_0_x64:"/usr/lib/jvm/java-21-amazon-corretto",rvm_version:"1.29.12 (latest)",npm_config_globalconfig:"/home/teamcity/.nvm/versions/node/v22.14.0/etc/npmrc",npm_config_init_module:"/home/teamcity/.npm-init.js",GEM_PATH:"/home/teamcity/.rvm/gems/ruby-3.3.7:/home/teamcity/.rvm/gems/ruby-3.3.7@global",JAVA_HOME:"/usr/lib/jvm/java-21-amazon-corretto",PWD:"/mnt/agent/work/70fcd8585843667f/packages/sentry",TEAMCITY_AGENT_MEM_OPTS:"-Xmx512m",npm_execpath:"/home/teamcity/.nvm/versions/node/v22.14.0/lib/node_modules/npm/bin/npm-cli.js",ANDROID_HOME:"/home/teamcity/android-sdk-linux",JDK_11:"/usr/lib/jvm/java-11-amazon-corretto",TEAMCITY_GIT_VERSION:"2.47.1.0",XDG_DATA_DIRS:"/usr/local/share:/usr/share:/var/lib/snapd/desktop",npm_config_global_prefix:"/home/teamcity/.nvm/versions/node/v22.14.0",TEAMCITY_PROCESS_FLOW_ID:"679780709992",npm_command:"run-script",JDK_17_0_x64:"/usr/lib/jvm/java-17-amazon-corretto",rvm_ruby_string:"ruby-3.3.7",MEMORY_PRESSURE_WRITE:"c29tZSAyMDAwMDAgMjAwMDAwMAA=",rvm_path:"/home/teamcity/.rvm",EDITOR:"vi",INIT_CWD:"/mnt/agent/work/70fcd8585843667f/packages/sentry",JDK_HOME:"/usr/lib/jvm/java-21-amazon-corretto",rvm_delete_flag:"0",NODE_ENV:"production",APP_NAME:"@wellesley/sentry"};const mg=bc.DOMAIN_ENV;Sc()||(window.build=bc.BUILD_NUMBER);const Gs=()=>!ug(),_g=[rg(),Ta(),oa()],gg=({dsn:e,release:t,integrations:n=_g,...r})=>{if(Gs()&&e)try{ag({dsn:e,integrations:n,replaysSessionSampleRate:.1,replaysOnErrorSampleRate:1,release:hg(t),environment:mg,maxValueLength:1024,...r})}catch(e){return void pg.error("Sentry init error: ",e)}},vc=e=>{if(Gs()&&e){const{email:t,username:n,userId:r}=e;bl({email:t,username:n,id:r})}},_y=Object.freeze(Object.defineProperty({__proto__:null,init:gg,isEnabled:Gs,setUser:vc},Symbol.toStringTag,{value:"Module"}));var hi,mi,kr={exports:{}},Rr={};
10
+ */function og(){if(ui)return N;ui=1;var e=Symbol.for("react.element"),t=Symbol.for("react.portal"),n=Symbol.for("react.fragment"),r=Symbol.for("react.strict_mode"),o=Symbol.for("react.profiler"),s=Symbol.for("react.provider"),i=Symbol.for("react.context"),a=Symbol.for("react.forward_ref"),c=Symbol.for("react.suspense"),u=Symbol.for("react.memo"),l=Symbol.for("react.lazy"),d=Symbol.iterator;var p={isMounted:function(){return!1},enqueueForceUpdate:function(){},enqueueReplaceState:function(){},enqueueSetState:function(){}},h=Object.assign,m={};function f(e,t,n){this.props=e,this.context=t,this.refs=m,this.updater=n||p}function y(){}function _(e,t,n){this.props=e,this.context=t,this.refs=m,this.updater=n||p}f.prototype.isReactComponent={},f.prototype.setState=function(e,t){if("object"!=typeof e&&"function"!=typeof e&&null!=e)throw Error("setState(...): takes an object of state variables to update or a function which returns an object of state variables.");this.updater.enqueueSetState(this,e,t,"setState")},f.prototype.forceUpdate=function(e){this.updater.enqueueForceUpdate(this,e,"forceUpdate")},y.prototype=f.prototype;var g=_.prototype=new y;g.constructor=_,h(g,f.prototype),g.isPureReactComponent=!0;var v=Array.isArray,b=Object.prototype.hasOwnProperty,S={current:null},E={key:!0,ref:!0,__self:!0,__source:!0};function k(t,n,r){var o,s={},i=null,a=null;if(null!=n)for(o in void 0!==n.ref&&(a=n.ref),void 0!==n.key&&(i=""+n.key),n)b.call(n,o)&&!E.hasOwnProperty(o)&&(s[o]=n[o]);var c=arguments.length-2;if(1===c)s.children=r;else if(1<c){for(var u=Array(c),l=0;l<c;l++)u[l]=arguments[l+2];s.children=u}if(t&&t.defaultProps)for(o in c=t.defaultProps)void 0===s[o]&&(s[o]=c[o]);return{$$typeof:e,type:t,key:i,ref:a,props:s,_owner:S.current}}function w(t){return"object"==typeof t&&null!==t&&t.$$typeof===e}var T=/\/+/g;function I(e,t){return"object"==typeof e&&null!==e&&null!=e.key?function(e){var t={"=":"=0",":":"=2"};return"$"+e.replace(/[=:]/g,(function(e){return t[e]}))}(""+e.key):t.toString(36)}function C(n,r,o,s,i){var a=typeof n;("undefined"===a||"boolean"===a)&&(n=null);var c=!1;if(null===n)c=!0;else switch(a){case"string":case"number":c=!0;break;case"object":switch(n.$$typeof){case e:case t:c=!0}}if(c)return i=i(c=n),n=""===s?"."+I(c,0):s,v(i)?(o="",null!=n&&(o=n.replace(T,"$&/")+"/"),C(i,r,o,"",(function(e){return e}))):null!=i&&(w(i)&&(i=function(t,n){return{$$typeof:e,type:t.type,key:n,ref:t.ref,props:t.props,_owner:t._owner}}(i,o+(!i.key||c&&c.key===i.key?"":(""+i.key).replace(T,"$&/")+"/")+n)),r.push(i)),1;if(c=0,s=""===s?".":s+":",v(n))for(var u=0;u<n.length;u++){var l=s+I(a=n[u],u);c+=C(a,r,o,l,i)}else if(l=function(e){return null===e||"object"!=typeof e?null:"function"==typeof(e=d&&e[d]||e["@@iterator"])?e:null}(n),"function"==typeof l)for(n=l.call(n),u=0;!(a=n.next()).done;)c+=C(a=a.value,r,o,l=s+I(a,u++),i);else if("object"===a)throw r=String(n),Error("Objects are not valid as a React child (found: "+("[object Object]"===r?"object with keys {"+Object.keys(n).join(", ")+"}":r)+"). If you meant to render a collection of children, use an array instead.");return c}function x(e,t,n){if(null==e)return e;var r=[],o=0;return C(e,r,"","",(function(e){return t.call(n,e,o++)})),r}function M(e){if(-1===e._status){var t=e._result;(t=t()).then((function(t){(0===e._status||-1===e._status)&&(e._status=1,e._result=t)}),(function(t){(0===e._status||-1===e._status)&&(e._status=2,e._result=t)})),-1===e._status&&(e._status=0,e._result=t)}if(1===e._status)return e._result.default;throw e._result}var O={current:null},A={transition:null},R={ReactCurrentDispatcher:O,ReactCurrentBatchConfig:A,ReactCurrentOwner:S};return N.Children={map:x,forEach:function(e,t,n){x(e,(function(){t.apply(this,arguments)}),n)},count:function(e){var t=0;return x(e,(function(){t++})),t},toArray:function(e){return x(e,(function(e){return e}))||[]},only:function(e){if(!w(e))throw Error("React.Children.only expected to receive a single React element child.");return e}},N.Component=f,N.Fragment=n,N.Profiler=o,N.PureComponent=_,N.StrictMode=r,N.Suspense=c,N.__SECRET_INTERNALS_DO_NOT_USE_OR_YOU_WILL_BE_FIRED=R,N.cloneElement=function(t,n,r){if(null==t)throw Error("React.cloneElement(...): The argument must be a React element, but you passed "+t+".");var o=h({},t.props),s=t.key,i=t.ref,a=t._owner;if(null!=n){if(void 0!==n.ref&&(i=n.ref,a=S.current),void 0!==n.key&&(s=""+n.key),t.type&&t.type.defaultProps)var c=t.type.defaultProps;for(u in n)b.call(n,u)&&!E.hasOwnProperty(u)&&(o[u]=void 0===n[u]&&void 0!==c?c[u]:n[u])}var u=arguments.length-2;if(1===u)o.children=r;else if(1<u){c=Array(u);for(var l=0;l<u;l++)c[l]=arguments[l+2];o.children=c}return{$$typeof:e,type:t.type,key:s,ref:i,props:o,_owner:a}},N.createContext=function(e){return(e={$$typeof:i,_currentValue:e,_currentValue2:e,_threadCount:0,Provider:null,Consumer:null,_defaultValue:null,_globalName:null}).Provider={$$typeof:s,_context:e},e.Consumer=e},N.createElement=k,N.createFactory=function(e){var t=k.bind(null,e);return t.type=e,t},N.createRef=function(){return{current:null}},N.forwardRef=function(e){return{$$typeof:a,render:e}},N.isValidElement=w,N.lazy=function(e){return{$$typeof:l,_payload:{_status:-1,_result:e},_init:M}},N.memo=function(e,t){return{$$typeof:u,type:e,compare:void 0===t?null:t}},N.startTransition=function(e){var t=A.transition;A.transition={};try{e()}finally{A.transition=t}},N.unstable_act=function(){throw Error("act(...) is not supported in production builds of React.")},N.useCallback=function(e,t){return O.current.useCallback(e,t)},N.useContext=function(e){return O.current.useContext(e)},N.useDebugValue=function(){},N.useDeferredValue=function(e){return O.current.useDeferredValue(e)},N.useEffect=function(e,t){return O.current.useEffect(e,t)},N.useId=function(){return O.current.useId()},N.useImperativeHandle=function(e,t,n){return O.current.useImperativeHandle(e,t,n)},N.useInsertionEffect=function(e,t){return O.current.useInsertionEffect(e,t)},N.useLayoutEffect=function(e,t){return O.current.useLayoutEffect(e,t)},N.useMemo=function(e,t){return O.current.useMemo(e,t)},N.useReducer=function(e,t,n){return O.current.useReducer(e,t,n)},N.useRef=function(e){return O.current.useRef(e)},N.useState=function(e){return O.current.useState(e)},N.useSyncExternalStore=function(e,t,n){return O.current.useSyncExternalStore(e,t,n)},N.useTransition=function(){return O.current.useTransition()},N.version="18.2.0",N}function yc(){return li||(li=1,Tr.exports=og()),Tr.exports}var or=yc();const Ec=sg(or),di=Uc({__proto__:null,default:Ec},[or]);function ig(e){const t={...e};return ra(t,"react"),Vi("react",{version:or.version}),Cp(t)}const Sc=()=>"object"!=typeof window;var ag={DISTRIB_RELEASE:"24.04",JDK_18:"/usr/lib/jvm/java-1.8.0-amazon-corretto",TEAMCITY_PROJECT_NAME:"Web Apps",USER:"teamcity",npm_config_user_agent:"npm/10.9.2 node/v22.14.0 linux x64 workspaces/false ci/teamcity",rvm_pretty_print_flag:"0",NUGET_PLUGIN_HANDSHAKE_TIMEOUT_IN_SECONDS:"20",TEAMCITY_PROCESS_PARENT_FLOW_ID:"",ANDROID_SDK_HOME:"/home/teamcity/android-sdk-linux",DOTNET_CLI_TELEMETRY_OPTOUT:"true",JDK_11_x64:"/usr/lib/jvm/java-11-amazon-corretto",npm_node_execpath:"/home/teamcity/.nvm/versions/node/v22.14.0/bin/node",SHLVL:"0",npm_config_noproxy:"",BUILD_VCS_NUMBER:"97cf47b3e9c701aee56eb0f587f592580a450114",HOME:"/home/teamcity",OLDPWD:"/",BUILD_URL:"https://wellesley.teamcity.com/build/16263",JRE_HOME:"/usr/lib/jvm/java-21-amazon-corretto",npm_package_json:"/mnt/agent/work/70fcd8585843667f/packages/sentry/package.json",ANDROID_SDKMANAGER_PATH:"/home/teamcity/android-sdk-linux/cmdline-tools/latest/bin/sdkmanager",TEAMCITY_BUILD_PROPERTIES_FILE:"/mnt/agent/temp/buildTmp/teamcity.build.parameters",npm_package_engines_node:">=20.2.0",rvm_stored_umask:"0022",GRADLE_HOME:"/opt/gradle",npm_config_local_prefix:"/mnt/agent/work/70fcd8585843667f",npm_config_userconfig:"/home/teamcity/.npmrc",rvm_user_install_flag:"1",BUILD_VCS_NUMBER_WebApps:"97cf47b3e9c701aee56eb0f587f592580a450114",GOROOT:"/opt/go",JDK_18_x64:"/usr/lib/jvm/java-1.8.0-amazon-corretto",SYSTEMD_EXEC_PID:"1297",COLOR:"1",TEAMCITY_BUILDCONF_NAME:"Apps",DISTRIB_DESCRIPTION:"Ubuntu 24.04.2 LTS",DOTNET_SKIP_FIRST_TIME_EXPERIENCE:"true",TMPDIR:"/mnt/agent/temp/buildTmp",LOGNAME:"teamcity",JOURNAL_STREAM:"8:9533",TEMP:"/mnt/agent/temp/buildTmp",_:"/usr/bin/nohup",npm_config_npm_version:"10.9.2",npm_config_prefix:"/home/teamcity/.nvm/versions/node/v22.14.0",rvm_bin_path:"/home/teamcity/.rvm/bin",IRBRC:"/home/teamcity/.rvm/rubies/ruby-3.3.7/.irbrc",MEMORY_PRESSURE_WATCH:"/sys/fs/cgroup/system.slice/teamcity-agent.service/memory.pressure",P4CONFIG:".p4config",RUBY_VERSION:"ruby-3.3.7",npm_config_cache:"/home/teamcity/.npm",DOTNET_ROOT:"/usr/share/dotnet",JDK_1_8:"/usr/lib/jvm/java-1.8.0-amazon-corretto",MNT_MOUNT:"/dev/nvme0n1 on /mnt type ext4 (rw,noatime)",TEAMCITY_GIT_PATH:"/usr/local/bin/git",AWS_SHARED_CREDENTIALS_FILE:"/mnt/agent/temp/agentTmp/aws.credentials",DISTRIB_ID:"Ubuntu",npm_config_node_gyp:"/home/teamcity/.nvm/versions/node/v22.14.0/lib/node_modules/npm/node_modules/node-gyp/bin/node-gyp.js",PATH:"/mnt/agent/work/70fcd8585843667f/packages/sentry/node_modules/.bin:/mnt/agent/work/70fcd8585843667f/packages/node_modules/.bin:/mnt/agent/work/70fcd8585843667f/node_modules/.bin:/mnt/agent/work/node_modules/.bin:/mnt/agent/node_modules/.bin:/mnt/node_modules/.bin:/node_modules/.bin:/home/teamcity/.nvm/versions/node/v22.14.0/lib/node_modules/npm/node_modules/@npmcli/run-script/lib/node-gyp-bin:/mnt/agent/work/70fcd8585843667f/node_modules/.bin:/mnt/agent/work/node_modules/.bin:/mnt/agent/node_modules/.bin:/mnt/node_modules/.bin:/node_modules/.bin:/home/teamcity/.nvm/versions/node/v22.14.0/lib/node_modules/npm/node_modules/@npmcli/run-script/lib/node-gyp-bin:/mnt/agent/work/70fcd8585843667f/node_modules/.bin:/mnt/agent/work/node_modules/.bin:/mnt/agent/node_modules/.bin:/mnt/node_modules/.bin:/node_modules/.bin:/home/teamcity/.nvm/versions/node/v22.14.0/lib/node_modules/npm/node_modules/@npmcli/run-script/lib/node-gyp-bin:/home/teamcity/.cargo/bin:/home/teamcity/.rvm/gems/ruby-3.3.7/bin:/home/teamcity/.rvm/gems/ruby-3.3.7@global/bin:/home/teamcity/.rvm/rubies/ruby-3.3.7/bin:/home/teamcity/.rvm/bin:/home/teamcity/.local/bin:/usr/lib/jvm/java-21-amazon-corretto/bin:/usr/local/sbin:/usr/local/bin:/usr/sbin:/usr/bin:/snap/bin:/usr/share/dotnet:/usr/share/dotnet/tools:/home/teamcity/google-cloud-sdk/bin:/home/teamcity/go/bin:/usr/bin/mvn:/home/teamcity/.nvm/versions/node/v22.14.0/bin",INVOCATION_ID:"bf0f84ab1c314eab8d883b140417d45b",JDK_11_0:"/usr/lib/jvm/java-11-amazon-corretto",NODE:"/home/teamcity/.nvm/versions/node/v22.14.0/bin/node",TEAMCITY_CAPTURE_ENV:'"/usr/lib/jvm/java-21-amazon-corretto/bin/java" -jar "/home/teamcity/agent/plugins/environment-fetcher/lib/environment-fetcher-bin-2024.12-174504-jar-with-dependencies.jar"',TURBO_HASH:"7330280bbe1efb0a",npm_package_name:"@wellesley/sentry",DISTRIB_CODENAME:"noble",JDK_21_0:"/usr/lib/jvm/java-21-amazon-corretto",npm_config_color:"always",DOMAIN_ENV:"test",MY_RUBY_HOME:"/home/teamcity/.rvm/rubies/ruby-3.3.7",TEAMCITY_VERSION:"2024.12.2 (build 174504)",LANG:"en_US.UTF-8",GROOVY_HOME:"/opt/groovy",TMP:"/mnt/agent/temp/buildTmp",npm_lifecycle_script:"tsc && vite build",BUILD_NUMBER:"2216",NUGET_PLUGIN_REQUEST_TIMEOUT_IN_SECONDS:"20",UID:"1001",AWS_PROFILE:"default",GOPATH:"/home/teamcity/go",JDK_17_0:"/usr/lib/jvm/java-17-amazon-corretto",SHELL:"/bin/bash",TEAMCITY_AGENT_OPTS:"-XX:+HeapDumpOnOutOfMemoryError -XX:HeapDumpPath=../logs/agent_%p.hprof -Dteamcity.internal.hosted.server.technicalName=PREINIT_AGENT",USE_NPM_VENDOR:"false",npm_lifecycle_event:"build",npm_package_version:"1.0.25",JDK_1_8_x64:"/usr/lib/jvm/java-1.8.0-amazon-corretto",rvm_loaded_flag:"1",rvm_prefix:"/home/teamcity",GEM_HOME:"/home/teamcity/.rvm/gems/ruby-3.3.7",TURBO_INVOCATION_DIR:"/mnt/agent/work/70fcd8585843667f",JDK_11_0_x64:"/usr/lib/jvm/java-11-amazon-corretto",JDK_21_0_x64:"/usr/lib/jvm/java-21-amazon-corretto",rvm_version:"1.29.12 (latest)",npm_config_globalconfig:"/home/teamcity/.nvm/versions/node/v22.14.0/etc/npmrc",npm_config_init_module:"/home/teamcity/.npm-init.js",GEM_PATH:"/home/teamcity/.rvm/gems/ruby-3.3.7:/home/teamcity/.rvm/gems/ruby-3.3.7@global",JAVA_HOME:"/usr/lib/jvm/java-21-amazon-corretto",PWD:"/mnt/agent/work/70fcd8585843667f/packages/sentry",TEAMCITY_AGENT_MEM_OPTS:"-Xmx512m",npm_execpath:"/home/teamcity/.nvm/versions/node/v22.14.0/lib/node_modules/npm/bin/npm-cli.js",ANDROID_HOME:"/home/teamcity/android-sdk-linux",JDK_11:"/usr/lib/jvm/java-11-amazon-corretto",TEAMCITY_GIT_VERSION:"2.47.1.0",XDG_DATA_DIRS:"/usr/local/share:/usr/share:/var/lib/snapd/desktop",npm_config_global_prefix:"/home/teamcity/.nvm/versions/node/v22.14.0",TEAMCITY_PROCESS_FLOW_ID:"513689168158",npm_command:"run-script",JDK_17_0_x64:"/usr/lib/jvm/java-17-amazon-corretto",USE_PACKAGES_FROM_NPM:"false",rvm_ruby_string:"ruby-3.3.7",MEMORY_PRESSURE_WRITE:"c29tZSAyMDAwMDAgMjAwMDAwMAA=",rvm_path:"/home/teamcity/.rvm",EDITOR:"vi",INIT_CWD:"/mnt/agent/work/70fcd8585843667f/packages/sentry",JDK_HOME:"/usr/lib/jvm/java-21-amazon-corretto",rvm_delete_flag:"0",NODE_ENV:"production",APP_NAME:"@wellesley/sentry"};const cg=()=>!!ag.JEST_WORKER_ID,fi=["debug","info","warn","error"],ug=(e,t)=>{const n=fi.indexOf(e);return fi.indexOf(t)>=n},En=(e,t,n,...r)=>{ug(t,e)&&console.log(`[${e}] ${n}`,...r)},lg=()=>null==window?void 0:window.localStorage.getItem("logger_lvl"),dg=(e=!Sc()&&lg()||"warn")=>{let t=e;return{debug:(e,...n)=>En("debug",t,e,...n),info:(e,...n)=>En("info",t,e,...n),warn:(e,...n)=>En("warn",t,e,...n),error:(e,...n)=>(hy(e,...n),En("error",t,e,...n)),setLevel:e=>{t=e},getLevel:()=>t}},fg=dg();var pi={DISTRIB_RELEASE:"24.04",JDK_18:"/usr/lib/jvm/java-1.8.0-amazon-corretto",TEAMCITY_PROJECT_NAME:"Web Apps",USER:"teamcity",npm_config_user_agent:"npm/10.9.2 node/v22.14.0 linux x64 workspaces/false ci/teamcity",rvm_pretty_print_flag:"0",NUGET_PLUGIN_HANDSHAKE_TIMEOUT_IN_SECONDS:"20",TEAMCITY_PROCESS_PARENT_FLOW_ID:"",ANDROID_SDK_HOME:"/home/teamcity/android-sdk-linux",DOTNET_CLI_TELEMETRY_OPTOUT:"true",JDK_11_x64:"/usr/lib/jvm/java-11-amazon-corretto",npm_node_execpath:"/home/teamcity/.nvm/versions/node/v22.14.0/bin/node",SHLVL:"0",npm_config_noproxy:"",BUILD_VCS_NUMBER:"97cf47b3e9c701aee56eb0f587f592580a450114",HOME:"/home/teamcity",OLDPWD:"/",BUILD_URL:"https://wellesley.teamcity.com/build/16263",JRE_HOME:"/usr/lib/jvm/java-21-amazon-corretto",npm_package_json:"/mnt/agent/work/70fcd8585843667f/packages/sentry/package.json",ANDROID_SDKMANAGER_PATH:"/home/teamcity/android-sdk-linux/cmdline-tools/latest/bin/sdkmanager",TEAMCITY_BUILD_PROPERTIES_FILE:"/mnt/agent/temp/buildTmp/teamcity.build.parameters",npm_package_engines_node:">=20.2.0",rvm_stored_umask:"0022",GRADLE_HOME:"/opt/gradle",npm_config_local_prefix:"/mnt/agent/work/70fcd8585843667f",npm_config_userconfig:"/home/teamcity/.npmrc",rvm_user_install_flag:"1",BUILD_VCS_NUMBER_WebApps:"97cf47b3e9c701aee56eb0f587f592580a450114",GOROOT:"/opt/go",JDK_18_x64:"/usr/lib/jvm/java-1.8.0-amazon-corretto",SYSTEMD_EXEC_PID:"1297",COLOR:"1",TEAMCITY_BUILDCONF_NAME:"Apps",DISTRIB_DESCRIPTION:"Ubuntu 24.04.2 LTS",DOTNET_SKIP_FIRST_TIME_EXPERIENCE:"true",TMPDIR:"/mnt/agent/temp/buildTmp",LOGNAME:"teamcity",JOURNAL_STREAM:"8:9533",TEMP:"/mnt/agent/temp/buildTmp",_:"/usr/bin/nohup",npm_config_npm_version:"10.9.2",npm_config_prefix:"/home/teamcity/.nvm/versions/node/v22.14.0",rvm_bin_path:"/home/teamcity/.rvm/bin",IRBRC:"/home/teamcity/.rvm/rubies/ruby-3.3.7/.irbrc",MEMORY_PRESSURE_WATCH:"/sys/fs/cgroup/system.slice/teamcity-agent.service/memory.pressure",P4CONFIG:".p4config",RUBY_VERSION:"ruby-3.3.7",npm_config_cache:"/home/teamcity/.npm",DOTNET_ROOT:"/usr/share/dotnet",JDK_1_8:"/usr/lib/jvm/java-1.8.0-amazon-corretto",MNT_MOUNT:"/dev/nvme0n1 on /mnt type ext4 (rw,noatime)",TEAMCITY_GIT_PATH:"/usr/local/bin/git",AWS_SHARED_CREDENTIALS_FILE:"/mnt/agent/temp/agentTmp/aws.credentials",DISTRIB_ID:"Ubuntu",npm_config_node_gyp:"/home/teamcity/.nvm/versions/node/v22.14.0/lib/node_modules/npm/node_modules/node-gyp/bin/node-gyp.js",PATH:"/mnt/agent/work/70fcd8585843667f/packages/sentry/node_modules/.bin:/mnt/agent/work/70fcd8585843667f/packages/node_modules/.bin:/mnt/agent/work/70fcd8585843667f/node_modules/.bin:/mnt/agent/work/node_modules/.bin:/mnt/agent/node_modules/.bin:/mnt/node_modules/.bin:/node_modules/.bin:/home/teamcity/.nvm/versions/node/v22.14.0/lib/node_modules/npm/node_modules/@npmcli/run-script/lib/node-gyp-bin:/mnt/agent/work/70fcd8585843667f/node_modules/.bin:/mnt/agent/work/node_modules/.bin:/mnt/agent/node_modules/.bin:/mnt/node_modules/.bin:/node_modules/.bin:/home/teamcity/.nvm/versions/node/v22.14.0/lib/node_modules/npm/node_modules/@npmcli/run-script/lib/node-gyp-bin:/mnt/agent/work/70fcd8585843667f/node_modules/.bin:/mnt/agent/work/node_modules/.bin:/mnt/agent/node_modules/.bin:/mnt/node_modules/.bin:/node_modules/.bin:/home/teamcity/.nvm/versions/node/v22.14.0/lib/node_modules/npm/node_modules/@npmcli/run-script/lib/node-gyp-bin:/home/teamcity/.cargo/bin:/home/teamcity/.rvm/gems/ruby-3.3.7/bin:/home/teamcity/.rvm/gems/ruby-3.3.7@global/bin:/home/teamcity/.rvm/rubies/ruby-3.3.7/bin:/home/teamcity/.rvm/bin:/home/teamcity/.local/bin:/usr/lib/jvm/java-21-amazon-corretto/bin:/usr/local/sbin:/usr/local/bin:/usr/sbin:/usr/bin:/snap/bin:/usr/share/dotnet:/usr/share/dotnet/tools:/home/teamcity/google-cloud-sdk/bin:/home/teamcity/go/bin:/usr/bin/mvn:/home/teamcity/.nvm/versions/node/v22.14.0/bin",INVOCATION_ID:"bf0f84ab1c314eab8d883b140417d45b",JDK_11_0:"/usr/lib/jvm/java-11-amazon-corretto",NODE:"/home/teamcity/.nvm/versions/node/v22.14.0/bin/node",TEAMCITY_CAPTURE_ENV:'"/usr/lib/jvm/java-21-amazon-corretto/bin/java" -jar "/home/teamcity/agent/plugins/environment-fetcher/lib/environment-fetcher-bin-2024.12-174504-jar-with-dependencies.jar"',TURBO_HASH:"7330280bbe1efb0a",npm_package_name:"@wellesley/sentry",DISTRIB_CODENAME:"noble",JDK_21_0:"/usr/lib/jvm/java-21-amazon-corretto",npm_config_color:"always",DOMAIN_ENV:"test",MY_RUBY_HOME:"/home/teamcity/.rvm/rubies/ruby-3.3.7",TEAMCITY_VERSION:"2024.12.2 (build 174504)",LANG:"en_US.UTF-8",GROOVY_HOME:"/opt/groovy",TMP:"/mnt/agent/temp/buildTmp",npm_lifecycle_script:"tsc && vite build",BUILD_NUMBER:"2216",NUGET_PLUGIN_REQUEST_TIMEOUT_IN_SECONDS:"20",UID:"1001",AWS_PROFILE:"default",GOPATH:"/home/teamcity/go",JDK_17_0:"/usr/lib/jvm/java-17-amazon-corretto",SHELL:"/bin/bash",TEAMCITY_AGENT_OPTS:"-XX:+HeapDumpOnOutOfMemoryError -XX:HeapDumpPath=../logs/agent_%p.hprof -Dteamcity.internal.hosted.server.technicalName=PREINIT_AGENT",USE_NPM_VENDOR:"false",npm_lifecycle_event:"build",npm_package_version:"1.0.25",JDK_1_8_x64:"/usr/lib/jvm/java-1.8.0-amazon-corretto",rvm_loaded_flag:"1",rvm_prefix:"/home/teamcity",GEM_HOME:"/home/teamcity/.rvm/gems/ruby-3.3.7",TURBO_INVOCATION_DIR:"/mnt/agent/work/70fcd8585843667f",JDK_11_0_x64:"/usr/lib/jvm/java-11-amazon-corretto",JDK_21_0_x64:"/usr/lib/jvm/java-21-amazon-corretto",rvm_version:"1.29.12 (latest)",npm_config_globalconfig:"/home/teamcity/.nvm/versions/node/v22.14.0/etc/npmrc",npm_config_init_module:"/home/teamcity/.npm-init.js",GEM_PATH:"/home/teamcity/.rvm/gems/ruby-3.3.7:/home/teamcity/.rvm/gems/ruby-3.3.7@global",JAVA_HOME:"/usr/lib/jvm/java-21-amazon-corretto",PWD:"/mnt/agent/work/70fcd8585843667f/packages/sentry",TEAMCITY_AGENT_MEM_OPTS:"-Xmx512m",npm_execpath:"/home/teamcity/.nvm/versions/node/v22.14.0/lib/node_modules/npm/bin/npm-cli.js",ANDROID_HOME:"/home/teamcity/android-sdk-linux",JDK_11:"/usr/lib/jvm/java-11-amazon-corretto",TEAMCITY_GIT_VERSION:"2.47.1.0",XDG_DATA_DIRS:"/usr/local/share:/usr/share:/var/lib/snapd/desktop",npm_config_global_prefix:"/home/teamcity/.nvm/versions/node/v22.14.0",TEAMCITY_PROCESS_FLOW_ID:"513689168158",npm_command:"run-script",JDK_17_0_x64:"/usr/lib/jvm/java-17-amazon-corretto",USE_PACKAGES_FROM_NPM:"false",rvm_ruby_string:"ruby-3.3.7",MEMORY_PRESSURE_WRITE:"c29tZSAyMDAwMDAgMjAwMDAwMAA=",rvm_path:"/home/teamcity/.rvm",EDITOR:"vi",INIT_CWD:"/mnt/agent/work/70fcd8585843667f/packages/sentry",JDK_HOME:"/usr/lib/jvm/java-21-amazon-corretto",rvm_delete_flag:"0",NODE_ENV:"production",APP_NAME:"@wellesley/sentry"};const pg=e=>`${e||"wlsy"}-${pi.DOMAIN_ENV}#${pi.BUILD_NUMBER}`;var bc={DISTRIB_RELEASE:"24.04",JDK_18:"/usr/lib/jvm/java-1.8.0-amazon-corretto",TEAMCITY_PROJECT_NAME:"Web Apps",USER:"teamcity",npm_config_user_agent:"npm/10.9.2 node/v22.14.0 linux x64 workspaces/false ci/teamcity",rvm_pretty_print_flag:"0",NUGET_PLUGIN_HANDSHAKE_TIMEOUT_IN_SECONDS:"20",TEAMCITY_PROCESS_PARENT_FLOW_ID:"",ANDROID_SDK_HOME:"/home/teamcity/android-sdk-linux",DOTNET_CLI_TELEMETRY_OPTOUT:"true",JDK_11_x64:"/usr/lib/jvm/java-11-amazon-corretto",npm_node_execpath:"/home/teamcity/.nvm/versions/node/v22.14.0/bin/node",SHLVL:"0",npm_config_noproxy:"",BUILD_VCS_NUMBER:"97cf47b3e9c701aee56eb0f587f592580a450114",HOME:"/home/teamcity",OLDPWD:"/",BUILD_URL:"https://wellesley.teamcity.com/build/16263",JRE_HOME:"/usr/lib/jvm/java-21-amazon-corretto",npm_package_json:"/mnt/agent/work/70fcd8585843667f/packages/sentry/package.json",ANDROID_SDKMANAGER_PATH:"/home/teamcity/android-sdk-linux/cmdline-tools/latest/bin/sdkmanager",TEAMCITY_BUILD_PROPERTIES_FILE:"/mnt/agent/temp/buildTmp/teamcity.build.parameters",npm_package_engines_node:">=20.2.0",rvm_stored_umask:"0022",GRADLE_HOME:"/opt/gradle",npm_config_local_prefix:"/mnt/agent/work/70fcd8585843667f",npm_config_userconfig:"/home/teamcity/.npmrc",rvm_user_install_flag:"1",BUILD_VCS_NUMBER_WebApps:"97cf47b3e9c701aee56eb0f587f592580a450114",GOROOT:"/opt/go",JDK_18_x64:"/usr/lib/jvm/java-1.8.0-amazon-corretto",SYSTEMD_EXEC_PID:"1297",COLOR:"1",TEAMCITY_BUILDCONF_NAME:"Apps",DISTRIB_DESCRIPTION:"Ubuntu 24.04.2 LTS",DOTNET_SKIP_FIRST_TIME_EXPERIENCE:"true",TMPDIR:"/mnt/agent/temp/buildTmp",LOGNAME:"teamcity",JOURNAL_STREAM:"8:9533",TEMP:"/mnt/agent/temp/buildTmp",_:"/usr/bin/nohup",npm_config_npm_version:"10.9.2",npm_config_prefix:"/home/teamcity/.nvm/versions/node/v22.14.0",rvm_bin_path:"/home/teamcity/.rvm/bin",IRBRC:"/home/teamcity/.rvm/rubies/ruby-3.3.7/.irbrc",MEMORY_PRESSURE_WATCH:"/sys/fs/cgroup/system.slice/teamcity-agent.service/memory.pressure",P4CONFIG:".p4config",RUBY_VERSION:"ruby-3.3.7",npm_config_cache:"/home/teamcity/.npm",DOTNET_ROOT:"/usr/share/dotnet",JDK_1_8:"/usr/lib/jvm/java-1.8.0-amazon-corretto",MNT_MOUNT:"/dev/nvme0n1 on /mnt type ext4 (rw,noatime)",TEAMCITY_GIT_PATH:"/usr/local/bin/git",AWS_SHARED_CREDENTIALS_FILE:"/mnt/agent/temp/agentTmp/aws.credentials",DISTRIB_ID:"Ubuntu",npm_config_node_gyp:"/home/teamcity/.nvm/versions/node/v22.14.0/lib/node_modules/npm/node_modules/node-gyp/bin/node-gyp.js",PATH:"/mnt/agent/work/70fcd8585843667f/packages/sentry/node_modules/.bin:/mnt/agent/work/70fcd8585843667f/packages/node_modules/.bin:/mnt/agent/work/70fcd8585843667f/node_modules/.bin:/mnt/agent/work/node_modules/.bin:/mnt/agent/node_modules/.bin:/mnt/node_modules/.bin:/node_modules/.bin:/home/teamcity/.nvm/versions/node/v22.14.0/lib/node_modules/npm/node_modules/@npmcli/run-script/lib/node-gyp-bin:/mnt/agent/work/70fcd8585843667f/node_modules/.bin:/mnt/agent/work/node_modules/.bin:/mnt/agent/node_modules/.bin:/mnt/node_modules/.bin:/node_modules/.bin:/home/teamcity/.nvm/versions/node/v22.14.0/lib/node_modules/npm/node_modules/@npmcli/run-script/lib/node-gyp-bin:/mnt/agent/work/70fcd8585843667f/node_modules/.bin:/mnt/agent/work/node_modules/.bin:/mnt/agent/node_modules/.bin:/mnt/node_modules/.bin:/node_modules/.bin:/home/teamcity/.nvm/versions/node/v22.14.0/lib/node_modules/npm/node_modules/@npmcli/run-script/lib/node-gyp-bin:/home/teamcity/.cargo/bin:/home/teamcity/.rvm/gems/ruby-3.3.7/bin:/home/teamcity/.rvm/gems/ruby-3.3.7@global/bin:/home/teamcity/.rvm/rubies/ruby-3.3.7/bin:/home/teamcity/.rvm/bin:/home/teamcity/.local/bin:/usr/lib/jvm/java-21-amazon-corretto/bin:/usr/local/sbin:/usr/local/bin:/usr/sbin:/usr/bin:/snap/bin:/usr/share/dotnet:/usr/share/dotnet/tools:/home/teamcity/google-cloud-sdk/bin:/home/teamcity/go/bin:/usr/bin/mvn:/home/teamcity/.nvm/versions/node/v22.14.0/bin",INVOCATION_ID:"bf0f84ab1c314eab8d883b140417d45b",JDK_11_0:"/usr/lib/jvm/java-11-amazon-corretto",NODE:"/home/teamcity/.nvm/versions/node/v22.14.0/bin/node",TEAMCITY_CAPTURE_ENV:'"/usr/lib/jvm/java-21-amazon-corretto/bin/java" -jar "/home/teamcity/agent/plugins/environment-fetcher/lib/environment-fetcher-bin-2024.12-174504-jar-with-dependencies.jar"',TURBO_HASH:"7330280bbe1efb0a",npm_package_name:"@wellesley/sentry",DISTRIB_CODENAME:"noble",JDK_21_0:"/usr/lib/jvm/java-21-amazon-corretto",npm_config_color:"always",DOMAIN_ENV:"test",MY_RUBY_HOME:"/home/teamcity/.rvm/rubies/ruby-3.3.7",TEAMCITY_VERSION:"2024.12.2 (build 174504)",LANG:"en_US.UTF-8",GROOVY_HOME:"/opt/groovy",TMP:"/mnt/agent/temp/buildTmp",npm_lifecycle_script:"tsc && vite build",BUILD_NUMBER:"2216",NUGET_PLUGIN_REQUEST_TIMEOUT_IN_SECONDS:"20",UID:"1001",AWS_PROFILE:"default",GOPATH:"/home/teamcity/go",JDK_17_0:"/usr/lib/jvm/java-17-amazon-corretto",SHELL:"/bin/bash",TEAMCITY_AGENT_OPTS:"-XX:+HeapDumpOnOutOfMemoryError -XX:HeapDumpPath=../logs/agent_%p.hprof -Dteamcity.internal.hosted.server.technicalName=PREINIT_AGENT",USE_NPM_VENDOR:"false",npm_lifecycle_event:"build",npm_package_version:"1.0.25",JDK_1_8_x64:"/usr/lib/jvm/java-1.8.0-amazon-corretto",rvm_loaded_flag:"1",rvm_prefix:"/home/teamcity",GEM_HOME:"/home/teamcity/.rvm/gems/ruby-3.3.7",TURBO_INVOCATION_DIR:"/mnt/agent/work/70fcd8585843667f",JDK_11_0_x64:"/usr/lib/jvm/java-11-amazon-corretto",JDK_21_0_x64:"/usr/lib/jvm/java-21-amazon-corretto",rvm_version:"1.29.12 (latest)",npm_config_globalconfig:"/home/teamcity/.nvm/versions/node/v22.14.0/etc/npmrc",npm_config_init_module:"/home/teamcity/.npm-init.js",GEM_PATH:"/home/teamcity/.rvm/gems/ruby-3.3.7:/home/teamcity/.rvm/gems/ruby-3.3.7@global",JAVA_HOME:"/usr/lib/jvm/java-21-amazon-corretto",PWD:"/mnt/agent/work/70fcd8585843667f/packages/sentry",TEAMCITY_AGENT_MEM_OPTS:"-Xmx512m",npm_execpath:"/home/teamcity/.nvm/versions/node/v22.14.0/lib/node_modules/npm/bin/npm-cli.js",ANDROID_HOME:"/home/teamcity/android-sdk-linux",JDK_11:"/usr/lib/jvm/java-11-amazon-corretto",TEAMCITY_GIT_VERSION:"2.47.1.0",XDG_DATA_DIRS:"/usr/local/share:/usr/share:/var/lib/snapd/desktop",npm_config_global_prefix:"/home/teamcity/.nvm/versions/node/v22.14.0",TEAMCITY_PROCESS_FLOW_ID:"513689168158",npm_command:"run-script",JDK_17_0_x64:"/usr/lib/jvm/java-17-amazon-corretto",USE_PACKAGES_FROM_NPM:"false",rvm_ruby_string:"ruby-3.3.7",MEMORY_PRESSURE_WRITE:"c29tZSAyMDAwMDAgMjAwMDAwMAA=",rvm_path:"/home/teamcity/.rvm",EDITOR:"vi",INIT_CWD:"/mnt/agent/work/70fcd8585843667f/packages/sentry",JDK_HOME:"/usr/lib/jvm/java-21-amazon-corretto",rvm_delete_flag:"0",NODE_ENV:"production",APP_NAME:"@wellesley/sentry"};const hg=bc.DOMAIN_ENV;Sc()||(window.build=bc.BUILD_NUMBER);const Gs=()=>!cg(),mg=[ng(),Ta(),oa()],_g=({dsn:e,release:t,integrations:n=mg,...r})=>{if(Gs()&&e)try{ig({dsn:e,integrations:n,replaysSessionSampleRate:.1,replaysOnErrorSampleRate:1,release:pg(t),environment:hg,maxValueLength:1024,...r})}catch(e){return void fg.error("Sentry init error: ",e)}},vc=e=>{if(Gs()&&e){const{email:t,username:n,userId:r}=e;Sl({email:t,username:n,id:r})}},my=Object.freeze(Object.defineProperty({__proto__:null,init:_g,isEnabled:Gs,setUser:vc},Symbol.toStringTag,{value:"Module"}));var hi,mi,kr={exports:{}},Rr={};
11
11
  /**
12
12
  * @license React
13
13
  * use-sync-external-store-with-selector.production.min.js
@@ -16,4 +16,4 @@ import{logErrorToSentry as Uc}from"https://cdn.jsdelivr.net/npm/@wellesley/sentr
16
16
  *
17
17
  * This source code is licensed under the MIT license found in the
18
18
  * LICENSE file in the root directory of this source tree.
19
- */function yg(){if(hi)return Rr;hi=1;var e=yc();var t="function"==typeof Object.is?Object.is:function(e,t){return e===t&&(0!==e||1/e==1/t)||e!=e&&t!=t},n=e.useSyncExternalStore,r=e.useRef,o=e.useEffect,s=e.useMemo,i=e.useDebugValue;return Rr.useSyncExternalStoreWithSelector=function(e,a,c,u,l){var d=r(null);if(null===d.current){var p={hasValue:!1,value:null};d.current=p}else p=d.current;d=s((function(){function e(e){if(!o){if(o=!0,n=e,e=u(e),void 0!==l&&p.hasValue){var s=p.value;if(l(s,e))return r=s}return r=e}if(s=r,t(n,e))return s;var i=u(e);return void 0!==l&&l(s,i)?s:(n=e,r=i)}var n,r,o=!1,s=void 0===c?null:c;return[function(){return e(a())},null===s?void 0:function(){return e(s())}]}),[a,c,u,l]);var h=n(e,d[0],d[1]);return o((function(){p.hasValue=!0,p.value=h}),[h]),i(h),h},Rr}function Eg(){return mi||(mi=1,kr.exports=yg()),kr.exports}var Sg=Eg(),De="default"in di?Ec:di,_i=Symbol.for("react-redux-context"),gi=typeof globalThis<"u"?globalThis:{};function bg(){if(!De.createContext)return{};const e=gi[_i]??(gi[_i]=new Map);let t=e.get(De.createContext);return t||(t=De.createContext(null),e.set(De.createContext,t)),t}var is=bg(),vg=()=>{throw new Error("uSES not initialized!")};function Ic(e=is){return function(){return De.useContext(e)}}var Ig=Ic(),wc=vg,wg=e=>{wc=e},Tg=(e,t)=>e===t;function kg(e=is){const t=e===is?Ig:Ic(e),n=(e,n={})=>{const{equalityFn:r=Tg,devModeChecks:o={}}="function"==typeof n?{equalityFn:n}:n,{store:s,subscription:i,getServerState:a,stabilityCheck:c,identityFunctionCheck:u}=t();De.useRef(!0);const l=De.useCallback({[e.name]:t=>e(t)}[e.name],[e,c,o.stabilityCheck]),d=wc(i.addNestedSub,s.getState,a||s.getState,l,r);return De.useDebugValue(d),d};return Object.assign(n,{withTypes:()=>n}),n}var yi=kg(),Rg=typeof window<"u"&&typeof window.document<"u"&&typeof window.document.createElement<"u";function Cg(e){if("object"!=typeof e||null===e)return!1;let t=e;for(;null!==Object.getPrototypeOf(t);)t=Object.getPrototypeOf(t);return Object.getPrototypeOf(e)===t||null===Object.getPrototypeOf(e)}function Mg(e){return Cg(e)&&"type"in e&&"string"==typeof e.type}Rg?De.useLayoutEffect:De.useEffect,wg(Sg.useSyncExternalStoreWithSelector);var Tc=Symbol.for("immer-nothing"),Ei=Symbol.for("immer-draftable"),Ee=Symbol.for("immer-state");function Re(e,...t){throw new Error(`[Immer] minified error nr: ${e}. Full error at: https://bit.ly/3cXEKWf`)}var Mt=Object.getPrototypeOf;function Ve(e){return!!e&&!!e[Ee]}function $e(e){var t;return!!e&&(kc(e)||Array.isArray(e)||!!e[Ei]||!(null==(t=e.constructor)||!t[Ei])||ar(e)||cr(e))}var Og=Object.prototype.constructor.toString();function kc(e){if(!e||"object"!=typeof e)return!1;const t=Mt(e);if(null===t)return!0;const n=Object.hasOwnProperty.call(t,"constructor")&&t.constructor;return n===Object||"function"==typeof n&&Function.toString.call(n)===Og}function Gt(e,t){0===ir(e)?Object.entries(e).forEach((([n,r])=>{t(n,r,e)})):e.forEach(((n,r)=>t(r,n,e)))}function ir(e){const t=e[Ee];return t?t.type_:Array.isArray(e)?1:ar(e)?2:cr(e)?3:0}function as(e,t){return 2===ir(e)?e.has(t):Object.prototype.hasOwnProperty.call(e,t)}function Rc(e,t,n){const r=ir(e);2===r?e.set(t,n):3===r?e.add(n):e[t]=n}function Dg(e,t){return e===t?0!==e||1/e==1/t:e!=e&&t!=t}function ar(e){return e instanceof Map}function cr(e){return e instanceof Set}function et(e){return e.copy_||e.base_}function cs(e,t){if(ar(e))return new Map(e);if(cr(e))return new Set(e);if(Array.isArray(e))return Array.prototype.slice.call(e);if(!t&&kc(e))return Mt(e)?{...e}:Object.assign(Object.create(null),e);const n=Object.getOwnPropertyDescriptors(e);delete n[Ee];let r=Reflect.ownKeys(n);for(let t=0;t<r.length;t++){const o=r[t],s=n[o];!1===s.writable&&(s.writable=!0,s.configurable=!0),(s.get||s.set)&&(n[o]={configurable:!0,writable:!0,enumerable:s.enumerable,value:e[o]})}return Object.create(Mt(e),n)}function Ys(e,t=!1){return ur(e)||Ve(e)||!$e(e)||(ir(e)>1&&(e.set=e.add=e.clear=e.delete=Ag),Object.freeze(e),t&&Gt(e,((e,t)=>Ys(t,!0)))),e}function Ag(){Re(2)}function ur(e){return Object.isFrozen(e)}var Yt,xg={};function at(e){const t=xg[e];return t||Re(0,e),t}function Cc(){return Yt}function Ng(e,t){return{drafts_:[],parent_:e,immer_:t,canAutoFreeze_:!0,unfinalizedDrafts_:0}}function Si(e,t){t&&(at("Patches"),e.patches_=[],e.inversePatches_=[],e.patchListener_=t)}function us(e){ls(e),e.drafts_.forEach(Pg),e.drafts_=null}function ls(e){e===Yt&&(Yt=e.parent_)}function bi(e){return Yt=Ng(Yt,e)}function Pg(e){const t=e[Ee];0===t.type_||1===t.type_?t.revoke_():t.revoked_=!0}function vi(e,t){t.unfinalizedDrafts_=t.drafts_.length;const n=t.drafts_[0];return void 0!==e&&e!==n?(n[Ee].modified_&&(us(t),Re(4)),$e(e)&&(e=Bn(t,e),t.parent_||$n(t,e)),t.patches_&&at("Patches").generateReplacementPatches_(n[Ee].base_,e,t.patches_,t.inversePatches_)):e=Bn(t,n,[]),us(t),t.patches_&&t.patchListener_(t.patches_,t.inversePatches_),e!==Tc?e:void 0}function Bn(e,t,n){if(ur(t))return t;const r=t[Ee];if(!r)return Gt(t,((o,s)=>Ii(e,r,t,o,s,n))),t;if(r.scope_!==e)return t;if(!r.modified_)return $n(e,r.base_,!0),r.base_;if(!r.finalized_){r.finalized_=!0,r.scope_.unfinalizedDrafts_--;const t=r.copy_;let o=t,s=!1;3===r.type_&&(o=new Set(t),t.clear(),s=!0),Gt(o,((o,i)=>Ii(e,r,t,o,i,n,s))),$n(e,t,!1),n&&e.patches_&&at("Patches").generatePatches_(r,n,e.patches_,e.inversePatches_)}return r.copy_}function Ii(e,t,n,r,o,s,i){if(Ve(o)){const i=Bn(e,o,s&&t&&3!==t.type_&&!as(t.assigned_,r)?s.concat(r):void 0);if(Rc(n,r,i),!Ve(i))return;e.canAutoFreeze_=!1}else i&&n.add(o);if($e(o)&&!ur(o)){if(!e.immer_.autoFreeze_&&e.unfinalizedDrafts_<1)return;Bn(e,o),(!t||!t.scope_.parent_)&&$n(e,o)}}function $n(e,t,n=!1){!e.parent_&&e.immer_.autoFreeze_&&e.canAutoFreeze_&&Ys(t,n)}function Lg(e,t){const n=Array.isArray(e),r={type_:n?1:0,scope_:t?t.scope_:Cc(),modified_:!1,finalized_:!1,assigned_:{},parent_:t,base_:e,draft_:null,copy_:null,revoke_:null,isManual_:!1};let o=r,s=qs;n&&(o=[r],s=qt);const{revoke:i,proxy:a}=Proxy.revocable(o,s);return r.draft_=a,r.revoke_=i,a}var qs={get(e,t){if(t===Ee)return e;const n=et(e);if(!as(n,t))return Fg(e,n,t);const r=n[t];return e.finalized_||!$e(r)?r:r===Cr(e.base_,t)?(Mr(e),e.copy_[t]=fs(r,e)):r},has:(e,t)=>t in et(e),ownKeys:e=>Reflect.ownKeys(et(e)),set(e,t,n){const r=Mc(et(e),t);if(null!=r&&r.set)return r.set.call(e.draft_,n),!0;if(!e.modified_){const r=Cr(et(e),t),o=null==r?void 0:r[Ee];if(o&&o.base_===n)return e.copy_[t]=n,e.assigned_[t]=!1,!0;if(Dg(n,r)&&(void 0!==n||as(e.base_,t)))return!0;Mr(e),ds(e)}return e.copy_[t]===n&&(void 0!==n||t in e.copy_)||Number.isNaN(n)&&Number.isNaN(e.copy_[t])||(e.copy_[t]=n,e.assigned_[t]=!0),!0},deleteProperty:(e,t)=>(void 0!==Cr(e.base_,t)||t in e.base_?(e.assigned_[t]=!1,Mr(e),ds(e)):delete e.assigned_[t],e.copy_&&delete e.copy_[t],!0),getOwnPropertyDescriptor(e,t){const n=et(e),r=Reflect.getOwnPropertyDescriptor(n,t);return r&&{writable:!0,configurable:1!==e.type_||"length"!==t,enumerable:r.enumerable,value:n[t]}},defineProperty(){Re(11)},getPrototypeOf:e=>Mt(e.base_),setPrototypeOf(){Re(12)}},qt={};function Cr(e,t){const n=e[Ee];return(n?et(n):e)[t]}function Fg(e,t,n){var r;const o=Mc(t,n);return o?"value"in o?o.value:null==(r=o.get)?void 0:r.call(e.draft_):void 0}function Mc(e,t){if(!(t in e))return;let n=Mt(e);for(;n;){const e=Object.getOwnPropertyDescriptor(n,t);if(e)return e;n=Mt(n)}}function ds(e){e.modified_||(e.modified_=!0,e.parent_&&ds(e.parent_))}function Mr(e){e.copy_||(e.copy_=cs(e.base_,e.scope_.immer_.useStrictShallowCopy_))}Gt(qs,((e,t)=>{qt[e]=function(){return arguments[0]=arguments[0][0],t.apply(this,arguments)}})),qt.deleteProperty=function(e,t){return qt.set.call(this,e,t,void 0)},qt.set=function(e,t,n){return qs.set.call(this,e[0],t,n,e[0])};var Ug=class{constructor(e){this.autoFreeze_=!0,this.useStrictShallowCopy_=!1,this.produce=(e,t,n)=>{if("function"==typeof e&&"function"!=typeof t){const n=t;t=e;const r=this;return function(e=n,...o){return r.produce(e,(e=>t.call(this,e,...o)))}}let r;if("function"!=typeof t&&Re(6),void 0!==n&&"function"!=typeof n&&Re(7),$e(e)){const o=bi(this),s=fs(e,void 0);let i=!0;try{r=t(s),i=!1}finally{i?us(o):ls(o)}return Si(o,n),vi(r,o)}if(!e||"object"!=typeof e){if(r=t(e),void 0===r&&(r=e),r===Tc&&(r=void 0),this.autoFreeze_&&Ys(r,!0),n){const t=[],o=[];at("Patches").generateReplacementPatches_(e,r,t,o),n(t,o)}return r}Re(1,e)},this.produceWithPatches=(e,t)=>{if("function"==typeof e)return(t,...n)=>this.produceWithPatches(t,(t=>e(t,...n)));let n,r;return[this.produce(e,t,((e,t)=>{n=e,r=t})),n,r]},"boolean"==typeof(null==e?void 0:e.autoFreeze)&&this.setAutoFreeze(e.autoFreeze),"boolean"==typeof(null==e?void 0:e.useStrictShallowCopy)&&this.setUseStrictShallowCopy(e.useStrictShallowCopy)}createDraft(e){$e(e)||Re(8),Ve(e)&&(e=Oc(e));const t=bi(this),n=fs(e,void 0);return n[Ee].isManual_=!0,ls(t),n}finishDraft(e,t){const n=e&&e[Ee];(!n||!n.isManual_)&&Re(9);const{scope_:r}=n;return Si(r,t),vi(void 0,r)}setAutoFreeze(e){this.autoFreeze_=e}setUseStrictShallowCopy(e){this.useStrictShallowCopy_=e}applyPatches(e,t){let n;for(n=t.length-1;n>=0;n--){const r=t[n];if(0===r.path.length&&"replace"===r.op){e=r.value;break}}n>-1&&(t=t.slice(n+1));const r=at("Patches").applyPatches_;return Ve(e)?r(e,t):this.produce(e,(e=>r(e,t)))}};function fs(e,t){const n=ar(e)?at("MapSet").proxyMap_(e,t):cr(e)?at("MapSet").proxySet_(e,t):Lg(e,t);return(t?t.scope_:Cc()).drafts_.push(n),n}function Oc(e){return Ve(e)||Re(10,e),Dc(e)}function Dc(e){if(!$e(e)||ur(e))return e;const t=e[Ee];let n;if(t){if(!t.modified_)return t.base_;t.finalized_=!0,n=cs(e,t.scope_.immer_.useStrictShallowCopy_)}else n=cs(e,!0);return Gt(n,((e,t)=>{Rc(n,e,Dc(t))})),t&&(t.finalized_=!1),n}var Se=new Ug,Ac=Se.produce;function jg(e,t="expected a function, instead received "+typeof e){if("function"!=typeof e)throw new TypeError(t)}function Bg(e,t="expected an object, instead received "+typeof e){if("object"!=typeof e)throw new TypeError(t)}function $g(e,t="expected all items to be functions, instead received the following types: "){if(!e.every((e=>"function"==typeof e))){const n=e.map((e=>"function"==typeof e?`function ${e.name||"unnamed"}()`:typeof e)).join(", ");throw new TypeError(`${t}[${n}]`)}}Se.produceWithPatches.bind(Se),Se.setAutoFreeze.bind(Se),Se.setUseStrictShallowCopy.bind(Se),Se.applyPatches.bind(Se),Se.createDraft.bind(Se),Se.finishDraft.bind(Se);var wi=e=>Array.isArray(e)?e:[e];function Hg(e){const t=Array.isArray(e[0])?e[0]:e;return $g(t,"createSelector expects all input-selectors to be functions, but received the following types: "),t}function zg(e,t){const n=[],{length:r}=e;for(let o=0;o<r;o++)n.push(e[o].apply(null,t));return n}var Wg=class{constructor(e){this.value=e}deref(){return this.value}},Gg=typeof WeakRef<"u"?WeakRef:Wg,Yg=0,Ti=1;function Sn(){return{s:Yg,v:void 0,o:null,p:null}}function Ks(e,t={}){let n=Sn();const{resultEqualityCheck:r}=t;let o,s=0;function i(){var t;let i=n;const{length:a}=arguments;for(let e=0,t=a;e<t;e++){const t=arguments[e];if("function"==typeof t||"object"==typeof t&&null!==t){let e=i.o;null===e&&(i.o=e=new WeakMap);const n=e.get(t);void 0===n?(i=Sn(),e.set(t,i)):i=n}else{let e=i.p;null===e&&(i.p=e=new Map);const n=e.get(t);void 0===n?(i=Sn(),e.set(t,i)):i=n}}const c=i;let u;if(i.s===Ti?u=i.v:(u=e.apply(null,arguments),s++),c.s=Ti,r){const e=(null==(t=null==o?void 0:o.deref)?void 0:t.call(o))??o;null!=e&&r(e,u)&&(u=e,0!==s&&s--),o="object"==typeof u&&null!==u||"function"==typeof u?new Gg(u):u}return c.v=u,u}return i.clearCache=()=>{n=Sn(),i.resetResultsCount()},i.resultsCount=()=>s,i.resetResultsCount=()=>{s=0},i}function xc(e,...t){const n="function"==typeof e?{memoize:e,memoizeOptions:t}:e,r=(...e)=>{let t,r=0,o=0,s={},i=e.pop();"object"==typeof i&&(s=i,i=e.pop()),jg(i,`createSelector expects an output function after the inputs, but received: [${typeof i}]`);const a={...n,...s},{memoize:c,memoizeOptions:u=[],argsMemoize:l=Ks,argsMemoizeOptions:d=[],devModeChecks:p={}}=a,h=wi(u),m=wi(d),f=Hg(e),y=c((function(){return r++,i.apply(null,arguments)}),...h),_=l((function(){o++;const e=zg(f,arguments);return t=y.apply(null,e),t}),...m);return Object.assign(_,{resultFunc:i,memoizedResultFunc:y,dependencies:f,dependencyRecomputations:()=>o,resetDependencyRecomputations:()=>{o=0},lastResult:()=>t,recomputations:()=>r,resetRecomputations:()=>{r=0},memoize:c,argsMemoize:l})};return Object.assign(r,{withTypes:()=>r}),r}var qg=xc(Ks),Kg=Object.assign(((e,t=qg)=>{Bg(e,"createStructuredSelector expects first argument to be an object where each property is a selector, instead received a "+typeof e);const n=Object.keys(e);return t(n.map((t=>e[t])),((...e)=>e.reduce(((e,t,r)=>(e[n[r]]=t,e)),{})))}),{withTypes:()=>Kg}),Vg=(...e)=>{const t=xc(...e),n=Object.assign(((...e)=>{const n=t(...e),r=(e,...t)=>n(Ve(e)?Oc(e):e,...t);return Object.assign(r,n),r}),{withTypes:()=>n});return n};function Ot(e,t){function n(...n){if(t){let r=t(...n);if(!r)throw new Error(ye(0));return{type:e,payload:r.payload,..."meta"in r&&{meta:r.meta},..."error"in r&&{error:r.error}}}return{type:e,payload:n[0]}}return n.toString=()=>`${e}`,n.type=e,n.match=t=>Mg(t)&&t.type===e,n}function ki(e){return $e(e)?Ac(e,(()=>{})):e}function Ri(e,t,n){if(e.has(t)){let r=e.get(t);return n.update&&(r=n.update(r,t,e),e.set(t,r)),r}if(!n.insert)throw new Error(ye(10));const r=n.insert(t,e);return e.set(t,r),r}function Nc(e){const t={},n=[];let r;const o={addCase(e,n){const r="string"==typeof e?e:e.type;if(!r)throw new Error(ye(28));if(r in t)throw new Error(ye(29));return t[r]=n,o},addMatcher:(e,t)=>(n.push({matcher:e,reducer:t}),o),addDefaultCase:e=>(r=e,o)};return e(o),[t,n,r]}function Jg(e){return"function"==typeof e}function Xg(e,t){let n,[r,o,s]=Nc(t);if(Jg(e))n=()=>ki(e());else{const t=ki(e);n=()=>t}function i(e=n(),t){let i=[r[t.type],...o.filter((({matcher:e})=>e(t))).map((({reducer:e})=>e))];return 0===i.filter((e=>!!e)).length&&(i=[s]),i.reduce(((e,n)=>{if(n){if(Ve(e)){const r=n(e,t);return void 0===r?e:r}if($e(e))return Ac(e,(e=>n(e,t)));{const r=n(e,t);if(void 0===r){if(null===e)return e;throw new Error(ye(9))}return r}}return e}),e)}return i.getInitialState=n,i}Vg(Ks);var Qg="ModuleSymbhasOwnPr-0123456789ABCDEFGHNRVfgctiUvz_KqYTJkLxpZXIjQW",Zg=(e=21)=>{let t="",n=e;for(;n--;)t+=Qg[64*Math.random()|0];return t},ey=Symbol.for("rtk-slice-createasyncthunk");function ty(e,t){return`${e}/${t}`}function ny({creators:e}={}){var t;const n=null==(t=null==e?void 0:e.asyncThunk)?void 0:t[ey];return function(e){const{name:t,reducerPath:r=t}=e;if(!t)throw new Error(ye(11));const o=("function"==typeof e.reducers?e.reducers(oy()):e.reducers)||{},s=Object.keys(o),i={sliceCaseReducersByName:{},sliceCaseReducersByType:{},actionCreators:{},sliceMatchers:[]},a={addCase(e,t){const n="string"==typeof e?e:e.type;if(!n)throw new Error(ye(12));if(n in i.sliceCaseReducersByType)throw new Error(ye(13));return i.sliceCaseReducersByType[n]=t,a},addMatcher:(e,t)=>(i.sliceMatchers.push({matcher:e,reducer:t}),a),exposeAction:(e,t)=>(i.actionCreators[e]=t,a),exposeCaseReducer:(e,t)=>(i.sliceCaseReducersByName[e]=t,a)};function c(){const[t={},n=[],r]="function"==typeof e.extraReducers?Nc(e.extraReducers):[e.extraReducers],o={...t,...i.sliceCaseReducersByType};return Xg(e.initialState,(e=>{for(let t in o)e.addCase(t,o[t]);for(let t of i.sliceMatchers)e.addMatcher(t.matcher,t.reducer);for(let t of n)e.addMatcher(t.matcher,t.reducer);r&&e.addDefaultCase(r)}))}s.forEach((r=>{const s=o[r],i={reducerName:r,type:ty(t,r),createNotation:"function"==typeof e.reducers};ay(s)?uy(i,s,a,n):iy(i,s,a)}));const u=e=>e,l=new Map;let d;function p(e,t){return d||(d=c()),d(e,t)}function h(){return d||(d=c()),d.getInitialState()}function m(t,n=!1){function r(e){let r=e[t];return typeof r>"u"&&n&&(r=h()),r}function o(t=u){const r=Ri(l,n,{insert:()=>new WeakMap});return Ri(r,t,{insert:()=>{const r={};for(const[o,s]of Object.entries(e.selectors??{}))r[o]=ry(s,t,h,n);return r}})}return{reducerPath:t,getSelectors:o,get selectors(){return o(r)},selectSlice:r}}const f={name:t,reducer:p,actions:i.actionCreators,caseReducers:i.sliceCaseReducersByName,getInitialState:h,...m(r),injectInto(e,{reducerPath:t,...n}={}){const o=t??r;return e.inject({reducerPath:o,reducer:p},n),{...f,...m(o,!0)}}};return f}}function ry(e,t,n,r){function o(o,...s){let i=t(o);return typeof i>"u"&&r&&(i=n()),e(i,...s)}return o.unwrapped=e,o}var sy=ny();function oy(){function e(e,t){return{_reducerDefinitionType:"asyncThunk",payloadCreator:e,...t}}return e.withTypes=()=>e,{reducer:e=>Object.assign({[e.name]:(...t)=>e(...t)}[e.name],{_reducerDefinitionType:"reducer"}),preparedReducer:(e,t)=>({_reducerDefinitionType:"reducerWithPrepare",prepare:e,reducer:t}),asyncThunk:e}}function iy({type:e,reducerName:t,createNotation:n},r,o){let s,i;if("reducer"in r){if(n&&!cy(r))throw new Error(ye(17));s=r.reducer,i=r.prepare}else s=r;o.addCase(e,s).exposeCaseReducer(t,s).exposeAction(t,i?Ot(e,i):Ot(e))}function ay(e){return"asyncThunk"===e._reducerDefinitionType}function cy(e){return"reducerWithPrepare"===e._reducerDefinitionType}function uy({type:e,reducerName:t},n,r,o){if(!o)throw new Error(ye(18));const{payloadCreator:s,fulfilled:i,pending:a,rejected:c,settled:u,options:l}=n,d=o(e,s,l);r.exposeAction(t,d),i&&r.addCase(d.fulfilled,i),a&&r.addCase(d.pending,a),c&&r.addCase(d.rejected,c),u&&r.addMatcher(d.settled,u),r.exposeCaseReducer(t,{fulfilled:i||bn,pending:a||bn,rejected:c||bn,settled:u||bn})}function bn(){}var ly=(e,t)=>{if("function"!=typeof e)throw new Error(ye(32))},Vs="listenerMiddleware",dy=e=>{let{type:t,actionCreator:n,matcher:r,predicate:o,effect:s}=e;if(t)o=Ot(t).match;else if(n)t=n.type,o=n.match;else if(r)o=r;else if(!o)throw new Error(ye(21));return ly(s),{predicate:o,type:t,effect:s}},fy=Object.assign((e=>{const{type:t,predicate:n,effect:r}=dy(e);return{id:Zg(),effect:r,type:t,predicate:n,pending:new Set,unsubscribe:()=>{throw new Error(ye(22))}}}),{withTypes:()=>fy}),py=Object.assign(Ot(`${Vs}/add`),{withTypes:()=>py});Ot(`${Vs}/removeAll`);var hy=Object.assign(Ot(`${Vs}/remove`),{withTypes:()=>hy});function ye(e){return`Minified Redux Toolkit error #${e}; visit https://redux-toolkit.js.org/Errors?code=${e} for the full message or use the non-minified dev environment for full errors. `}const Ci={data:null,isError:!1,isPending:!1,isSuccess:!1},Mi=sy({name:"user",initialState:Ci,reducers:{reset:e=>{Object.assign(e,Ci)},setData:(e,{payload:t})=>{e.data=t},updateData:(e,{payload:t})=>{e.data&&Object.assign(e.data,t)},setSuccess:(e,{payload:t})=>{e.isSuccess=t},setPending:(e,{payload:t})=>{e.isPending=t},setIsError:(e,{payload:t})=>{e.isError=t},setError:(e,{payload:t})=>{e.error=t},updateUser:(e,{payload:t})=>{var n;null!=(n=e.data)&&n.users&&(e.data.users=e.data.users.map((e=>t.id===e.id?t:e)))}},selectors:{selectIsError:e=>e.isError,selectError:e=>e.error,selectPending:e=>e.isPending,selectData:e=>e.data,selectAccount:e=>{var t;return null==(t=e.data)?void 0:t.account},selectUsers:e=>{var t;return null==(t=e.data)?void 0:t.users},selectUserById:(e,t)=>{var n;return null==(n=e.data)?void 0:n.users.find((({id:e})=>e===t))},selectCurrentUser:e=>{var t;return null==(t=e.data)?void 0:t.users.find((({id:t})=>{var n;return t===(null==(n=e.data)?void 0:n.selectedUserId)}))},selectSelectedUserId:e=>{var t;return null==(t=e.data)?void 0:t.selectedUserId},selectSuccess:e=>e.isSuccess,selectIsAdmin:e=>{var t;return"ADMIN"===(null==(t=e.data)?void 0:t.account.role)}}}),gy=()=>{const e=yi(Mi.selectors.selectAccount),t=yi(Mi.selectors.selectCurrentUser),{email:n}=e||{},{username:r,id:o}=t||{};or.useEffect((()=>{n&&r&&o&&vc({email:n,username:r,userId:o})}),[n,r,o])},yy=(...e)=>{let t="";for(const n of e){if(n instanceof Error){const e=n;return Sl("exceptionMessage",t),void Is(e)}if("object"!=typeof n)t+=n;else try{t+=" "+JSON.stringify(n)}catch{t+=" "+n}}El(t)};export{yy as logErrorToSentry,_y as sentryClient,gy as useSentryUser};
19
+ */function gg(){if(hi)return Rr;hi=1;var e=yc();var t="function"==typeof Object.is?Object.is:function(e,t){return e===t&&(0!==e||1/e==1/t)||e!=e&&t!=t},n=e.useSyncExternalStore,r=e.useRef,o=e.useEffect,s=e.useMemo,i=e.useDebugValue;return Rr.useSyncExternalStoreWithSelector=function(e,a,c,u,l){var d=r(null);if(null===d.current){var p={hasValue:!1,value:null};d.current=p}else p=d.current;d=s((function(){function e(e){if(!o){if(o=!0,n=e,e=u(e),void 0!==l&&p.hasValue){var s=p.value;if(l(s,e))return r=s}return r=e}if(s=r,t(n,e))return s;var i=u(e);return void 0!==l&&l(s,i)?s:(n=e,r=i)}var n,r,o=!1,s=void 0===c?null:c;return[function(){return e(a())},null===s?void 0:function(){return e(s())}]}),[a,c,u,l]);var h=n(e,d[0],d[1]);return o((function(){p.hasValue=!0,p.value=h}),[h]),i(h),h},Rr}function yg(){return mi||(mi=1,kr.exports=gg()),kr.exports}var Eg=yg(),De="default"in di?Ec:di,_i=Symbol.for("react-redux-context"),gi=typeof globalThis<"u"?globalThis:{};function Sg(){if(!De.createContext)return{};const e=gi[_i]??(gi[_i]=new Map);let t=e.get(De.createContext);return t||(t=De.createContext(null),e.set(De.createContext,t)),t}var is=Sg(),bg=()=>{throw new Error("uSES not initialized!")};function Ic(e=is){return function(){return De.useContext(e)}}var vg=Ic(),wc=bg,Ig=e=>{wc=e},wg=(e,t)=>e===t;function Tg(e=is){const t=e===is?vg:Ic(e),n=(e,n={})=>{const{equalityFn:r=wg,devModeChecks:o={}}="function"==typeof n?{equalityFn:n}:n,{store:s,subscription:i,getServerState:a,stabilityCheck:c,identityFunctionCheck:u}=t();De.useRef(!0);const l=De.useCallback({[e.name]:t=>e(t)}[e.name],[e,c,o.stabilityCheck]),d=wc(i.addNestedSub,s.getState,a||s.getState,l,r);return De.useDebugValue(d),d};return Object.assign(n,{withTypes:()=>n}),n}var yi=Tg(),kg=typeof window<"u"&&typeof window.document<"u"&&typeof window.document.createElement<"u";function Rg(e){if("object"!=typeof e||null===e)return!1;let t=e;for(;null!==Object.getPrototypeOf(t);)t=Object.getPrototypeOf(t);return Object.getPrototypeOf(e)===t||null===Object.getPrototypeOf(e)}function Cg(e){return Rg(e)&&"type"in e&&"string"==typeof e.type}kg?De.useLayoutEffect:De.useEffect,Ig(Eg.useSyncExternalStoreWithSelector);var Tc=Symbol.for("immer-nothing"),Ei=Symbol.for("immer-draftable"),Ee=Symbol.for("immer-state");function Re(e,...t){throw new Error(`[Immer] minified error nr: ${e}. Full error at: https://bit.ly/3cXEKWf`)}var Mt=Object.getPrototypeOf;function Ve(e){return!!e&&!!e[Ee]}function $e(e){var t;return!!e&&(kc(e)||Array.isArray(e)||!!e[Ei]||!(null==(t=e.constructor)||!t[Ei])||ar(e)||cr(e))}var Mg=Object.prototype.constructor.toString();function kc(e){if(!e||"object"!=typeof e)return!1;const t=Mt(e);if(null===t)return!0;const n=Object.hasOwnProperty.call(t,"constructor")&&t.constructor;return n===Object||"function"==typeof n&&Function.toString.call(n)===Mg}function Gt(e,t){0===ir(e)?Object.entries(e).forEach((([n,r])=>{t(n,r,e)})):e.forEach(((n,r)=>t(r,n,e)))}function ir(e){const t=e[Ee];return t?t.type_:Array.isArray(e)?1:ar(e)?2:cr(e)?3:0}function as(e,t){return 2===ir(e)?e.has(t):Object.prototype.hasOwnProperty.call(e,t)}function Rc(e,t,n){const r=ir(e);2===r?e.set(t,n):3===r?e.add(n):e[t]=n}function Og(e,t){return e===t?0!==e||1/e==1/t:e!=e&&t!=t}function ar(e){return e instanceof Map}function cr(e){return e instanceof Set}function et(e){return e.copy_||e.base_}function cs(e,t){if(ar(e))return new Map(e);if(cr(e))return new Set(e);if(Array.isArray(e))return Array.prototype.slice.call(e);if(!t&&kc(e))return Mt(e)?{...e}:Object.assign(Object.create(null),e);const n=Object.getOwnPropertyDescriptors(e);delete n[Ee];let r=Reflect.ownKeys(n);for(let t=0;t<r.length;t++){const o=r[t],s=n[o];!1===s.writable&&(s.writable=!0,s.configurable=!0),(s.get||s.set)&&(n[o]={configurable:!0,writable:!0,enumerable:s.enumerable,value:e[o]})}return Object.create(Mt(e),n)}function Ys(e,t=!1){return ur(e)||Ve(e)||!$e(e)||(ir(e)>1&&(e.set=e.add=e.clear=e.delete=Dg),Object.freeze(e),t&&Gt(e,((e,t)=>Ys(t,!0)))),e}function Dg(){Re(2)}function ur(e){return Object.isFrozen(e)}var Yt,Ag={};function at(e){const t=Ag[e];return t||Re(0,e),t}function Cc(){return Yt}function xg(e,t){return{drafts_:[],parent_:e,immer_:t,canAutoFreeze_:!0,unfinalizedDrafts_:0}}function Si(e,t){t&&(at("Patches"),e.patches_=[],e.inversePatches_=[],e.patchListener_=t)}function us(e){ls(e),e.drafts_.forEach(Ng),e.drafts_=null}function ls(e){e===Yt&&(Yt=e.parent_)}function bi(e){return Yt=xg(Yt,e)}function Ng(e){const t=e[Ee];0===t.type_||1===t.type_?t.revoke_():t.revoked_=!0}function vi(e,t){t.unfinalizedDrafts_=t.drafts_.length;const n=t.drafts_[0];return void 0!==e&&e!==n?(n[Ee].modified_&&(us(t),Re(4)),$e(e)&&(e=Bn(t,e),t.parent_||$n(t,e)),t.patches_&&at("Patches").generateReplacementPatches_(n[Ee].base_,e,t.patches_,t.inversePatches_)):e=Bn(t,n,[]),us(t),t.patches_&&t.patchListener_(t.patches_,t.inversePatches_),e!==Tc?e:void 0}function Bn(e,t,n){if(ur(t))return t;const r=t[Ee];if(!r)return Gt(t,((o,s)=>Ii(e,r,t,o,s,n))),t;if(r.scope_!==e)return t;if(!r.modified_)return $n(e,r.base_,!0),r.base_;if(!r.finalized_){r.finalized_=!0,r.scope_.unfinalizedDrafts_--;const t=r.copy_;let o=t,s=!1;3===r.type_&&(o=new Set(t),t.clear(),s=!0),Gt(o,((o,i)=>Ii(e,r,t,o,i,n,s))),$n(e,t,!1),n&&e.patches_&&at("Patches").generatePatches_(r,n,e.patches_,e.inversePatches_)}return r.copy_}function Ii(e,t,n,r,o,s,i){if(Ve(o)){const i=Bn(e,o,s&&t&&3!==t.type_&&!as(t.assigned_,r)?s.concat(r):void 0);if(Rc(n,r,i),!Ve(i))return;e.canAutoFreeze_=!1}else i&&n.add(o);if($e(o)&&!ur(o)){if(!e.immer_.autoFreeze_&&e.unfinalizedDrafts_<1)return;Bn(e,o),(!t||!t.scope_.parent_)&&$n(e,o)}}function $n(e,t,n=!1){!e.parent_&&e.immer_.autoFreeze_&&e.canAutoFreeze_&&Ys(t,n)}function Pg(e,t){const n=Array.isArray(e),r={type_:n?1:0,scope_:t?t.scope_:Cc(),modified_:!1,finalized_:!1,assigned_:{},parent_:t,base_:e,draft_:null,copy_:null,revoke_:null,isManual_:!1};let o=r,s=Ks;n&&(o=[r],s=Kt);const{revoke:i,proxy:a}=Proxy.revocable(o,s);return r.draft_=a,r.revoke_=i,a}var Ks={get(e,t){if(t===Ee)return e;const n=et(e);if(!as(n,t))return Lg(e,n,t);const r=n[t];return e.finalized_||!$e(r)?r:r===Cr(e.base_,t)?(Mr(e),e.copy_[t]=fs(r,e)):r},has:(e,t)=>t in et(e),ownKeys:e=>Reflect.ownKeys(et(e)),set(e,t,n){const r=Mc(et(e),t);if(null!=r&&r.set)return r.set.call(e.draft_,n),!0;if(!e.modified_){const r=Cr(et(e),t),o=null==r?void 0:r[Ee];if(o&&o.base_===n)return e.copy_[t]=n,e.assigned_[t]=!1,!0;if(Og(n,r)&&(void 0!==n||as(e.base_,t)))return!0;Mr(e),ds(e)}return e.copy_[t]===n&&(void 0!==n||t in e.copy_)||Number.isNaN(n)&&Number.isNaN(e.copy_[t])||(e.copy_[t]=n,e.assigned_[t]=!0),!0},deleteProperty:(e,t)=>(void 0!==Cr(e.base_,t)||t in e.base_?(e.assigned_[t]=!1,Mr(e),ds(e)):delete e.assigned_[t],e.copy_&&delete e.copy_[t],!0),getOwnPropertyDescriptor(e,t){const n=et(e),r=Reflect.getOwnPropertyDescriptor(n,t);return r&&{writable:!0,configurable:1!==e.type_||"length"!==t,enumerable:r.enumerable,value:n[t]}},defineProperty(){Re(11)},getPrototypeOf:e=>Mt(e.base_),setPrototypeOf(){Re(12)}},Kt={};function Cr(e,t){const n=e[Ee];return(n?et(n):e)[t]}function Lg(e,t,n){var r;const o=Mc(t,n);return o?"value"in o?o.value:null==(r=o.get)?void 0:r.call(e.draft_):void 0}function Mc(e,t){if(!(t in e))return;let n=Mt(e);for(;n;){const e=Object.getOwnPropertyDescriptor(n,t);if(e)return e;n=Mt(n)}}function ds(e){e.modified_||(e.modified_=!0,e.parent_&&ds(e.parent_))}function Mr(e){e.copy_||(e.copy_=cs(e.base_,e.scope_.immer_.useStrictShallowCopy_))}Gt(Ks,((e,t)=>{Kt[e]=function(){return arguments[0]=arguments[0][0],t.apply(this,arguments)}})),Kt.deleteProperty=function(e,t){return Kt.set.call(this,e,t,void 0)},Kt.set=function(e,t,n){return Ks.set.call(this,e[0],t,n,e[0])};var Fg=class{constructor(e){this.autoFreeze_=!0,this.useStrictShallowCopy_=!1,this.produce=(e,t,n)=>{if("function"==typeof e&&"function"!=typeof t){const n=t;t=e;const r=this;return function(e=n,...o){return r.produce(e,(e=>t.call(this,e,...o)))}}let r;if("function"!=typeof t&&Re(6),void 0!==n&&"function"!=typeof n&&Re(7),$e(e)){const o=bi(this),s=fs(e,void 0);let i=!0;try{r=t(s),i=!1}finally{i?us(o):ls(o)}return Si(o,n),vi(r,o)}if(!e||"object"!=typeof e){if(r=t(e),void 0===r&&(r=e),r===Tc&&(r=void 0),this.autoFreeze_&&Ys(r,!0),n){const t=[],o=[];at("Patches").generateReplacementPatches_(e,r,t,o),n(t,o)}return r}Re(1,e)},this.produceWithPatches=(e,t)=>{if("function"==typeof e)return(t,...n)=>this.produceWithPatches(t,(t=>e(t,...n)));let n,r;return[this.produce(e,t,((e,t)=>{n=e,r=t})),n,r]},"boolean"==typeof(null==e?void 0:e.autoFreeze)&&this.setAutoFreeze(e.autoFreeze),"boolean"==typeof(null==e?void 0:e.useStrictShallowCopy)&&this.setUseStrictShallowCopy(e.useStrictShallowCopy)}createDraft(e){$e(e)||Re(8),Ve(e)&&(e=Oc(e));const t=bi(this),n=fs(e,void 0);return n[Ee].isManual_=!0,ls(t),n}finishDraft(e,t){const n=e&&e[Ee];(!n||!n.isManual_)&&Re(9);const{scope_:r}=n;return Si(r,t),vi(void 0,r)}setAutoFreeze(e){this.autoFreeze_=e}setUseStrictShallowCopy(e){this.useStrictShallowCopy_=e}applyPatches(e,t){let n;for(n=t.length-1;n>=0;n--){const r=t[n];if(0===r.path.length&&"replace"===r.op){e=r.value;break}}n>-1&&(t=t.slice(n+1));const r=at("Patches").applyPatches_;return Ve(e)?r(e,t):this.produce(e,(e=>r(e,t)))}};function fs(e,t){const n=ar(e)?at("MapSet").proxyMap_(e,t):cr(e)?at("MapSet").proxySet_(e,t):Pg(e,t);return(t?t.scope_:Cc()).drafts_.push(n),n}function Oc(e){return Ve(e)||Re(10,e),Dc(e)}function Dc(e){if(!$e(e)||ur(e))return e;const t=e[Ee];let n;if(t){if(!t.modified_)return t.base_;t.finalized_=!0,n=cs(e,t.scope_.immer_.useStrictShallowCopy_)}else n=cs(e,!0);return Gt(n,((e,t)=>{Rc(n,e,Dc(t))})),t&&(t.finalized_=!1),n}var Se=new Fg,Ac=Se.produce;function Ug(e,t="expected a function, instead received "+typeof e){if("function"!=typeof e)throw new TypeError(t)}function jg(e,t="expected an object, instead received "+typeof e){if("object"!=typeof e)throw new TypeError(t)}function Bg(e,t="expected all items to be functions, instead received the following types: "){if(!e.every((e=>"function"==typeof e))){const n=e.map((e=>"function"==typeof e?`function ${e.name||"unnamed"}()`:typeof e)).join(", ");throw new TypeError(`${t}[${n}]`)}}Se.produceWithPatches.bind(Se),Se.setAutoFreeze.bind(Se),Se.setUseStrictShallowCopy.bind(Se),Se.applyPatches.bind(Se),Se.createDraft.bind(Se),Se.finishDraft.bind(Se);var wi=e=>Array.isArray(e)?e:[e];function $g(e){const t=Array.isArray(e[0])?e[0]:e;return Bg(t,"createSelector expects all input-selectors to be functions, but received the following types: "),t}function Hg(e,t){const n=[],{length:r}=e;for(let o=0;o<r;o++)n.push(e[o].apply(null,t));return n}var zg=class{constructor(e){this.value=e}deref(){return this.value}},Wg=typeof WeakRef<"u"?WeakRef:zg,Gg=0,Ti=1;function Sn(){return{s:Gg,v:void 0,o:null,p:null}}function qs(e,t={}){let n=Sn();const{resultEqualityCheck:r}=t;let o,s=0;function i(){var t;let i=n;const{length:a}=arguments;for(let e=0,t=a;e<t;e++){const t=arguments[e];if("function"==typeof t||"object"==typeof t&&null!==t){let e=i.o;null===e&&(i.o=e=new WeakMap);const n=e.get(t);void 0===n?(i=Sn(),e.set(t,i)):i=n}else{let e=i.p;null===e&&(i.p=e=new Map);const n=e.get(t);void 0===n?(i=Sn(),e.set(t,i)):i=n}}const c=i;let u;if(i.s===Ti?u=i.v:(u=e.apply(null,arguments),s++),c.s=Ti,r){const e=(null==(t=null==o?void 0:o.deref)?void 0:t.call(o))??o;null!=e&&r(e,u)&&(u=e,0!==s&&s--),o="object"==typeof u&&null!==u||"function"==typeof u?new Wg(u):u}return c.v=u,u}return i.clearCache=()=>{n=Sn(),i.resetResultsCount()},i.resultsCount=()=>s,i.resetResultsCount=()=>{s=0},i}function xc(e,...t){const n="function"==typeof e?{memoize:e,memoizeOptions:t}:e,r=(...e)=>{let t,r=0,o=0,s={},i=e.pop();"object"==typeof i&&(s=i,i=e.pop()),Ug(i,`createSelector expects an output function after the inputs, but received: [${typeof i}]`);const a={...n,...s},{memoize:c,memoizeOptions:u=[],argsMemoize:l=qs,argsMemoizeOptions:d=[],devModeChecks:p={}}=a,h=wi(u),m=wi(d),f=$g(e),y=c((function(){return r++,i.apply(null,arguments)}),...h),_=l((function(){o++;const e=Hg(f,arguments);return t=y.apply(null,e),t}),...m);return Object.assign(_,{resultFunc:i,memoizedResultFunc:y,dependencies:f,dependencyRecomputations:()=>o,resetDependencyRecomputations:()=>{o=0},lastResult:()=>t,recomputations:()=>r,resetRecomputations:()=>{r=0},memoize:c,argsMemoize:l})};return Object.assign(r,{withTypes:()=>r}),r}var Yg=xc(qs),Kg=Object.assign(((e,t=Yg)=>{jg(e,"createStructuredSelector expects first argument to be an object where each property is a selector, instead received a "+typeof e);const n=Object.keys(e);return t(n.map((t=>e[t])),((...e)=>e.reduce(((e,t,r)=>(e[n[r]]=t,e)),{})))}),{withTypes:()=>Kg}),qg=(...e)=>{const t=xc(...e),n=Object.assign(((...e)=>{const n=t(...e),r=(e,...t)=>n(Ve(e)?Oc(e):e,...t);return Object.assign(r,n),r}),{withTypes:()=>n});return n};function Ot(e,t){function n(...n){if(t){let r=t(...n);if(!r)throw new Error(ye(0));return{type:e,payload:r.payload,..."meta"in r&&{meta:r.meta},..."error"in r&&{error:r.error}}}return{type:e,payload:n[0]}}return n.toString=()=>`${e}`,n.type=e,n.match=t=>Cg(t)&&t.type===e,n}function ki(e){return $e(e)?Ac(e,(()=>{})):e}function Ri(e,t,n){if(e.has(t)){let r=e.get(t);return n.update&&(r=n.update(r,t,e),e.set(t,r)),r}if(!n.insert)throw new Error(ye(10));const r=n.insert(t,e);return e.set(t,r),r}function Nc(e){const t={},n=[];let r;const o={addCase(e,n){const r="string"==typeof e?e:e.type;if(!r)throw new Error(ye(28));if(r in t)throw new Error(ye(29));return t[r]=n,o},addMatcher:(e,t)=>(n.push({matcher:e,reducer:t}),o),addDefaultCase:e=>(r=e,o)};return e(o),[t,n,r]}function Vg(e){return"function"==typeof e}function Jg(e,t){let n,[r,o,s]=Nc(t);if(Vg(e))n=()=>ki(e());else{const t=ki(e);n=()=>t}function i(e=n(),t){let i=[r[t.type],...o.filter((({matcher:e})=>e(t))).map((({reducer:e})=>e))];return 0===i.filter((e=>!!e)).length&&(i=[s]),i.reduce(((e,n)=>{if(n){if(Ve(e)){const r=n(e,t);return void 0===r?e:r}if($e(e))return Ac(e,(e=>n(e,t)));{const r=n(e,t);if(void 0===r){if(null===e)return e;throw new Error(ye(9))}return r}}return e}),e)}return i.getInitialState=n,i}qg(qs);var Xg="ModuleSymbhasOwnPr-0123456789ABCDEFGHNRVfgctiUvz_KqYTJkLxpZXIjQW",Qg=(e=21)=>{let t="",n=e;for(;n--;)t+=Xg[64*Math.random()|0];return t},Zg=Symbol.for("rtk-slice-createasyncthunk");function ey(e,t){return`${e}/${t}`}function ty({creators:e}={}){var t;const n=null==(t=null==e?void 0:e.asyncThunk)?void 0:t[Zg];return function(e){const{name:t,reducerPath:r=t}=e;if(!t)throw new Error(ye(11));const o=("function"==typeof e.reducers?e.reducers(sy()):e.reducers)||{},s=Object.keys(o),i={sliceCaseReducersByName:{},sliceCaseReducersByType:{},actionCreators:{},sliceMatchers:[]},a={addCase(e,t){const n="string"==typeof e?e:e.type;if(!n)throw new Error(ye(12));if(n in i.sliceCaseReducersByType)throw new Error(ye(13));return i.sliceCaseReducersByType[n]=t,a},addMatcher:(e,t)=>(i.sliceMatchers.push({matcher:e,reducer:t}),a),exposeAction:(e,t)=>(i.actionCreators[e]=t,a),exposeCaseReducer:(e,t)=>(i.sliceCaseReducersByName[e]=t,a)};function c(){const[t={},n=[],r]="function"==typeof e.extraReducers?Nc(e.extraReducers):[e.extraReducers],o={...t,...i.sliceCaseReducersByType};return Jg(e.initialState,(e=>{for(let t in o)e.addCase(t,o[t]);for(let t of i.sliceMatchers)e.addMatcher(t.matcher,t.reducer);for(let t of n)e.addMatcher(t.matcher,t.reducer);r&&e.addDefaultCase(r)}))}s.forEach((r=>{const s=o[r],i={reducerName:r,type:ey(t,r),createNotation:"function"==typeof e.reducers};iy(s)?cy(i,s,a,n):oy(i,s,a)}));const u=e=>e,l=new Map;let d;function p(e,t){return d||(d=c()),d(e,t)}function h(){return d||(d=c()),d.getInitialState()}function m(t,n=!1){function r(e){let r=e[t];return typeof r>"u"&&n&&(r=h()),r}function o(t=u){const r=Ri(l,n,{insert:()=>new WeakMap});return Ri(r,t,{insert:()=>{const r={};for(const[o,s]of Object.entries(e.selectors??{}))r[o]=ny(s,t,h,n);return r}})}return{reducerPath:t,getSelectors:o,get selectors(){return o(r)},selectSlice:r}}const f={name:t,reducer:p,actions:i.actionCreators,caseReducers:i.sliceCaseReducersByName,getInitialState:h,...m(r),injectInto(e,{reducerPath:t,...n}={}){const o=t??r;return e.inject({reducerPath:o,reducer:p},n),{...f,...m(o,!0)}}};return f}}function ny(e,t,n,r){function o(o,...s){let i=t(o);return typeof i>"u"&&r&&(i=n()),e(i,...s)}return o.unwrapped=e,o}var ry=ty();function sy(){function e(e,t){return{_reducerDefinitionType:"asyncThunk",payloadCreator:e,...t}}return e.withTypes=()=>e,{reducer:e=>Object.assign({[e.name]:(...t)=>e(...t)}[e.name],{_reducerDefinitionType:"reducer"}),preparedReducer:(e,t)=>({_reducerDefinitionType:"reducerWithPrepare",prepare:e,reducer:t}),asyncThunk:e}}function oy({type:e,reducerName:t,createNotation:n},r,o){let s,i;if("reducer"in r){if(n&&!ay(r))throw new Error(ye(17));s=r.reducer,i=r.prepare}else s=r;o.addCase(e,s).exposeCaseReducer(t,s).exposeAction(t,i?Ot(e,i):Ot(e))}function iy(e){return"asyncThunk"===e._reducerDefinitionType}function ay(e){return"reducerWithPrepare"===e._reducerDefinitionType}function cy({type:e,reducerName:t},n,r,o){if(!o)throw new Error(ye(18));const{payloadCreator:s,fulfilled:i,pending:a,rejected:c,settled:u,options:l}=n,d=o(e,s,l);r.exposeAction(t,d),i&&r.addCase(d.fulfilled,i),a&&r.addCase(d.pending,a),c&&r.addCase(d.rejected,c),u&&r.addMatcher(d.settled,u),r.exposeCaseReducer(t,{fulfilled:i||bn,pending:a||bn,rejected:c||bn,settled:u||bn})}function bn(){}var uy=(e,t)=>{if("function"!=typeof e)throw new Error(ye(32))},Vs="listenerMiddleware",ly=e=>{let{type:t,actionCreator:n,matcher:r,predicate:o,effect:s}=e;if(t)o=Ot(t).match;else if(n)t=n.type,o=n.match;else if(r)o=r;else if(!o)throw new Error(ye(21));return uy(s),{predicate:o,type:t,effect:s}},dy=Object.assign((e=>{const{type:t,predicate:n,effect:r}=ly(e);return{id:Qg(),effect:r,type:t,predicate:n,pending:new Set,unsubscribe:()=>{throw new Error(ye(22))}}}),{withTypes:()=>dy}),fy=Object.assign(Ot(`${Vs}/add`),{withTypes:()=>fy});Ot(`${Vs}/removeAll`);var py=Object.assign(Ot(`${Vs}/remove`),{withTypes:()=>py});function ye(e){return`Minified Redux Toolkit error #${e}; visit https://redux-toolkit.js.org/Errors?code=${e} for the full message or use the non-minified dev environment for full errors. `}const Ci={data:null,isError:!1,isPending:!1,isSuccess:!1},Mi=ry({name:"user",initialState:Ci,reducers:{reset:e=>{Object.assign(e,Ci)},setData:(e,{payload:t})=>{e.data=t},updateData:(e,{payload:t})=>{e.data&&Object.assign(e.data,t)},setSuccess:(e,{payload:t})=>{e.isSuccess=t},setPending:(e,{payload:t})=>{e.isPending=t},setIsError:(e,{payload:t})=>{e.isError=t},setError:(e,{payload:t})=>{e.error=t},updateUser:(e,{payload:t})=>{var n;null!=(n=e.data)&&n.users&&(e.data.users=e.data.users.map((e=>t.id===e.id?t:e)))}},selectors:{selectIsError:e=>e.isError,selectError:e=>e.error,selectPending:e=>e.isPending,selectData:e=>e.data,selectAccount:e=>{var t;return null==(t=e.data)?void 0:t.account},selectUsers:e=>{var t;return null==(t=e.data)?void 0:t.users},selectUserById:(e,t)=>{var n;return null==(n=e.data)?void 0:n.users.find((({id:e})=>e===t))},selectCurrentUser:e=>{var t;return null==(t=e.data)?void 0:t.users.find((({id:t})=>{var n;return t===(null==(n=e.data)?void 0:n.selectedUserId)}))},selectSelectedUserId:e=>{var t;return null==(t=e.data)?void 0:t.selectedUserId},selectSuccess:e=>e.isSuccess,selectIsAdmin:e=>{var t;return"ADMIN"===(null==(t=e.data)?void 0:t.account.role)}}}),_y=()=>{const e=yi(Mi.selectors.selectAccount),t=yi(Mi.selectors.selectCurrentUser),{email:n}=e||{},{username:r,id:o}=t||{};or.useEffect((()=>{n&&r&&o&&vc({email:n,username:r,userId:o})}),[n,r,o])},hy=(...e)=>{let t="";for(const n of e){if(n instanceof Error){const e=n;return El("exceptionMessage",t),void Is(e)}if("object"!=typeof n)t+=n;else try{t+=" "+JSON.stringify(n)}catch{t+=" "+n}}yl(t)};export{hy as logErrorToSentry,my as sentryClient,_y as useSentryUser};