vendor: 7,041 bytes, lines 1-5
1import{r as zc}from"./react-tmAF-Yg_.js";const O=typeof __SENTRY_DEBUG__>"u"||__SENTRY_DEBUG__,ut="8.54.0",$=globalThis;function rr(e,t,n){const r=n||$,s=r.__SENTRY__=r.__SENTRY__||{},i=s[ut]=s[ut]||{};return i[e]||(i[e]=t())}const Ze=typeof __SENTRY_DEBUG__>"u"||__SENTRY_DEBUG__,jc="Sentry Logger ",Hr=["debug","info","warn","error","log","assert","trace"],Hn={};function et(e){if(!("console"in $))return e();const t=$.console,n={},r=Object.keys(Hn);r.forEach(s=>{const i=Hn[s];n[s]=t[s],t[s]=i});try{return e()}finally{r.forEach(s=>{t[s]=n[s]})}}function qc(){let e=!1;const t={enable:()=>{e=!0},disable:()=>{e=!1},isEnabled:()=>e};return Ze?Hr.forEach(n=>{t[n]=(...r)=>{e&&et(()=>{$.console[n](`${jc}[${n}]:`,...r)})}}):Hr.forEach(n=>{t[n]=()=>{}}),t}const y=rr("logger",qc),Io=50,pt="?",ti=/\(error: (.*)\)/,ni=/captureMessage|captureException/;function wo(...e){const t=e.sort((n,r)=>n[0]-r[0]).map(n=>n[1]);return(n,r=0,s=0)=>{const i=[],o=n.split(` 2`);for(let a=r;a<o.length;a++){const c=o[a];if(c.length>1024)continue;const u=ti.test(c)?c.replace(ti,"$1"):c;if(!u.match(/\S*Error: /)){for(const d of t){const l=d(u);if(l){i.push(l);break}}if(i.length>=Io+s)break}}return Yc(i.slice(s))}}function Gc(e){return Array.isArray(e)?wo(...e):e}function Yc(e){if(!e.length)return[];const t=Array.from(e);return/sentryWrapped/.test(Sn(t).function||"")&&t.pop(),t.reverse(),ni.test(Sn(t).function||"")&&(t.pop(),ni.test(Sn(t).function||"")&&t.pop()),t.slice(0,Io).map(n=>({...n,filename:n.filename||Sn(t).filename,function:n.function||pt}))}function Sn(e){return e[e.length-1]||{}}const kr="<anonymous>";function Fe(e){try{return!e||typeof e!="function"?kr:e.name||kr}catch{return kr}}function ri(e){const t=e.exception;if(t){const n=[];try{return t.values.forEach(r=>{r.stacktrace.frames&&n.push(...r.stacktrace.frames)}),n}catch{return}}}const Nn={},si={};function tt(e,t){Nn[e]=Nn[e]||[],Nn[e].push(t)}function nt(e,t){if(!si[e]){si[e]=!0;try{t()}catch(n){Ze&&y.error(`Error while instrumenting ${e}`,n)}}}function Se(e,t){const n=e&&Nn[e];if(n)for(const r of n)try{r(t)}catch(s){Ze&&y.error(`Error while triggering instrumentation handler. 3Type: ${e} 4Name: ${Fe(r)} 5Error:`,s)}}let Cr=null;function ko(e){const t="error";tt(t,e),nt(t,Vc)}function Vc(){Cr=$.onerror,$.onerror=function(e,t,n,r,s){return Se("error",{column:r,error:s,line:n,msg:e,url:t}),Cr?Cr.apply(this,arguments):!1},$.onerror.__SENTRY_INSTRUMENTED__=!0}let Rr=null;function Co(e){const t="unhandledrejection";tt(t,e),nt(t,Xc)}function Xc(){Rr=$.onunhandledrejection,$.onunhandledrejection=function(e){return Se("unhandledrejection",e),Rr?Rr.apply(this,arguments):!0},$.onunhandledrejection.__SENTRY_INSTRUMENTED__=!0}function gt(){return Ss($),$}function Ss(e){const t=e.__SENTRY__=e.__SENTRY__||{};return t.version=t.version||ut,t[ut]=t[ut]||{}}const Ro=Object.prototype.toString;function Es(e){switch(Ro.call(e)){case"[object Error]":case"[object Exception]":case"[object DOMException]":case"[object WebAssembly.Exception]":return!0;default:return Be(e,Error)}}function $t(e,t){return Ro.call(e)===`[object ${t}]`}function Mo(e){return $t(e,"ErrorEvent")}function ii(e){return $t(e,"DOMError")}function Kc(e){return $t(e,"DOMException")}function Le(e){return $t(e,"String")}function bs(e){return typeof e=="object"&&e!==null&&"__sentry_template_string__"in e&&"__sentry_template_values__"in e}function vs(e){return e===null||bs(e)||typeof e!="object"&&typeof e!="function"}function Mt(e){return $t(e,"Object")}function sr(e){return typeof Event<"u"&&Be(e,Event)}function Jc(e){return typeof Element<"u"&&Be(e,Element)}function Qc(e){return $t(e,"RegExp")}function ir(e){return!!(e&&e.then&&typeof e.then=="function")}function Zc(e){return Mt(e)&&"nativeEvent"in e&&"preventDefault"in e&&"stopPropagation"in e}function Be(e,t){try{return e instanceof t}catch{return!1}}function xo(e){return!!(typeof e=="object"&&e!==null&&(e.__isVue||e._isVue))}const Ct=$,eu=80;function $e(e,t={}){if(!e)return"<unknown>";try{let n=e;const r=5,s=[];let i=0,o=0;const a=" > ",c=a.length;let u;const d=Array.isArray(t)?t:t.keyAttrs,l=!Array.isArray(t)&&t.maxStringLength||eu;for(;n&&i++<r&&(u=tu(n,d),!(u==="html"||i>1&&o+s.length*c+u.length>=l));)s.push(u),o+=u.length,n=n.parentNode;return s.reverse().join(a)}catch{return"<unknown>"}}function tu(e,t){const n=e,r=[];if(!n||!n.tagName)return"";if(Ct.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 s=t&&t.length?t.filter(o=>n.getAttribute(o)).map(o=>[o,n.getAttribute(o)]):null;if(s&&s.length)s.forEach(o=>{r.push(`[${o[0]}="${o[1]}"]`)});else{n.id&&r.push(`#${n.id}`);const o=n.className;if(o&&Le(o)){const a=o.split(/\s+/);for(const c of a)r.push(`.${c}`)}}const i=["aria-label","type","name","title","alt"];for(const o of i){const a=n.getAttribute(o);a&&r.push(`[${o}="${a}"]`)}return r.join("")}function Ao(){try{return Ct.document.location.href}catch{return""}}function nu(e){return Ct.document&&Ct.document.querySelector?Ct.document.querySelector(e):null}function Oo(e){if(!Ct.HTMLElement)return null;let t=e;const n=5;for(let r=0;r<n;r++){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 Rt(e,t=0){return typeof e!="string"||t===0||e.length<=t?e:`${e.slice(0,t)}...`}function oi(e,t){if(!Array.isArray(e))return"";const n=[];for(let r=0;r<e.length;r++){const s=e[r];try{xo(s)?n.push("[VueViewModel]"):n.push(String(s))}catch{n.push("[value cannot be serialized]")}}return n.join(t)}function ru(e,t,n=!1){return Le(e)?Qc(t)?t.test(e):Le(t)?n?e===t:e.includes(t):!1:!1}function Ye(e,t=[],n=!1){return t.some(r=>ru(e,r,n))}function me(e,t,n){if(!(t in e))return;const r=e[t],s=n(r);typeof s=="function"&&No(s,r);try{e[t]=s}catch{Ze&&y.log(`Failed to replace method "${t}" in object`,e)}}function Ee(e,t,n){try{Object.defineProperty(e,t,{value:n,writable:!0,configurable:!0})}catch{Ze&&y.log(`Failed to add non-enumerable property "${t}" to object`,e)}}function No(e,t){try{const n=t.prototype||{};e.prototype=t.prototype=n,Ee(e,"__sentry_original__",t)}catch{}}function Ts(e){return e.__sentry_original__}function Do(e){if(Es(e))return{message:e.message,name:e.name,stack:e.stack,...ci(e)};if(sr(e)){const t={type:e.type,target:ai(e.target),currentTarget:ai(e.currentTarget),...ci(e)};return typeof CustomEvent<"u"&&Be(e,CustomEvent)&&(t.detail=e.detail),t}else return e}function ai(e){try{return Jc(e)?$e(e):Object.prototype.toString.call(e)}catch{return"<unknown>"}}function ci(e){if(typeof e=="object"&&e!==null){const t={};for(const n in e)Object.prototype.hasOwnProperty.call(e,n)&&(t[n]=e[n]);return t}else return{}}function su(e,t=40){const n=Object.keys(Do(e));n.sort();const r=n[0];if(!r)return"[object has no keys]";if(r.length>=t)return Rt(r,t);for(let s=n.length;s>0;s--){const i=n.slice(0,s).join(", ");
5if(!(i.length>t))return s===n.length?i:Rt(i,t)}return""}function te(e){return Wr(e,new Map)}function Wr(e,t){if(iu(e)){const n=t.get(e);if(n!==void 0)return n;const r={};t.set(e,r);for(const s of Object.getOwnPropertyNames(e))typeof e[s]<"u"&&(r[s]=Wr(e[s],t));return r}if(Array.isArray(e)){const n=t.get(e);if(n!==void 0)return n;const r=[];return t.set(e,r),e.forEach(s=>{r.push(Wr(s,t))}),r}return e}function iu(e){if(!Mt(e))return!1;try{const t=Object.getPrototypeOf(e).constructor.name;return!t||t==="Object"}catch{return!0}}const Lo=1e3;function an(){return Date.now()/Lo}function ou(){const{performance:e}=$;if(!e||!e.now)return an;const t=Date.now()-e.now(),n=e.timeOrigin==null?t:e.timeOrigin;return()=>(n+e.now())/Lo}const de=ou(),fe=(()=>{const{performance:e}=$;if(!e||!e.now)return;const t=3600*1e3,n=e.now(),r=Date.now(),s=e.timeOrigin?Math.abs(e.timeOrigin+n-r):t,i=s<t,o=e.timing&&e.timing.navigationStart,c=typeof o=="number"?Math.abs(o+n-r):t,u=c<t;return i||u?s<=c?e.timeOrigin:o:r})();function _e(){const e=$,t=e.crypto||e.msCrypto;let n=()=>Math.random()*16;try{if(t&&t.randomUUID)return t.randomUUID().replace(/-/g,"");t&&t.getRandomValues&&(n=()=>{const r=new Uint8Array(1);return t.getRandomValues(r),r[0]})}catch{}return("10000000100040008000"+1e11).replace(/[018]/g,r=>(r^(n()&15)>>r/4).toString(16))}function Po(e){return e.exception&&e.exception.values?e.exception.values[0]:void 0}function We(e){const{message:t,event_id:n}=e;if(t)return t;const r=Po(e);return r?r.type&&r.value?`${r.type}: ${r.value}`:r.type||r.value||n||"<unknown>":n||"<unknown>"}function zr(e,t,n){const r=e.exception=e.exception||{},s=r.values=r.values||[],i=s[0]=s[0]||{};i.value||(i.value=t||""),i.type||(i.type="Error")}function xt(e,t){const n=Po(e);if(!n)return;const r={type:"generic",handled:!0},s=n.mechanism;if(n.mechanism={...r,...s,...t},t&&"data"in t){const i={...s&&s.data,...t.data};n.mechanism.data=i}}function ui(e){if(au(e))return!0;try{Ee(e,"__sentry_captured__",!0)}catch{}return!1}function au(e){try{return e.__sentry_captured__}catch{}}var Ne;(function(e){e[e.PENDING=0]="PENDING";const n=1;e[e.RESOLVED=n]="RESOLVED";const r=2;e[e.REJECTED=r]="REJECTED"})(Ne||(Ne={}));function Ue(e){return new ye(t=>{t(e)})}function Wn(e){return new ye((t,n)=>{n(e)})}class ye{constructor(t){ye.prototype.__init.call(this),ye.prototype.__init2.call(this),ye.prototype.__init3.call(this),ye.prototype.__init4.call(this),this._state=Ne.PENDING,this._handlers=[];try{t(this._resolve,this._reject)}catch(n){this._reject(n)}}then(t,n){return new ye((r,s)=>{this._handlers.push([!1,i=>{if(!t)r(i);else try{r(t(i))}catch(o){s(o)}},i=>{if(!n)s(i);else try{r(n(i))}catch(o){s(o)}}]),this._executeHandlers()})}catch(t){return this.then(n=>n,t)}finally(t){return new ye((n,r)=>{let s,i;return this.then(o=>{i=!1,s=o,t&&t()},o=>{i=!0,s=o,t&&t()}).then(()=>{if(i){r(s);return}n(s)})})}__init(){this._resolve=t=>{this._setResult(Ne.RESOLVED,t)}}__init2(){this._reject=t=>{this._setResult(Ne.REJECTED,t)}}__init3(){this._setResult=(t,n)=>{if(this._state===Ne.PENDING){if(ir(n)){n.then(this._resolve,this._reject);return}this._state=t,this._value=n,this._executeHandlers()}}}__init4(){this._executeHandlers=()=>{if(this._state===Ne.PENDING)return;const t=this._handlers.slice();this._handlers=[],t.forEach(n=>{n[0]||(this._state===Ne.RESOLVED&&n[1](this._value),this._state===Ne.REJECTED&&n[2](this._value),n[0]=!0)})}}}function cu(e){const t=de(),n={sid:_e(),init:!0,timestamp:t,started:t,duration:0,status:"ok",errors:0,ignoreDuration:!1,toJSON:()=>lu(n)};return e&&At(n,e),n}function At(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||de(),t.abnormal_mechanism&&(e.abnormal_mechanism=t.abnormal_mechanism),t.ignoreDuration&&(e.ignoreDuration=t.ignoreDuration),t.sid&&(e.sid=t.sid.length===32?t.sid:_e()),t.init!==void 0&&(e.init=t.init),!e.did&&t.did&&(e.did=`${t.did}`),typeof t.started=="number"&&(e.started=t.started),e.ignoreDuration)e.duration=void 0;else if(typeof t.duration=="number")e.duration=t.duration;else{const n=e.timestamp-e.started;e.duration=n>=0?n:0}t.release&&(e.release=t.release),t.environment&&(e.environment=t.environment),!e.ipAddress&&t.ipAddress&&(e.ipAddress=t.ipAddress),!e.userAgent&&t.userAgent&&(e.userAgent=t.userAgent),t
5ypeof t.errors=="number"&&(e.errors=t.errors),t.status&&(e.status=t.status)}function uu(e,t){let n={};e.status==="ok"&&(n={status:"exited"}),At(e,n)}function lu(e){return te({sid:`${e.sid}`,init:e.init,started:new Date(e.started*1e3).toISOString(),timestamp:new Date(e.timestamp*1e3).toISOString(),status:e.status,errors:e.errors,did:typeof e.did=="number"||typeof e.did=="string"?`${e.did}`:void 0,duration:e.duration,abnormal_mechanism:e.abnormal_mechanism,attrs:{release:e.release,environment:e.environment,ip_address:e.ipAddress,user_agent:e.userAgent}})}function Xe(){return _e()}function Ke(){return _e().substring(16)}function or(e,t,n=2){if(!t||typeof t!="object"||n<=0)return t;if(e&&t&&Object.keys(t).length===0)return e;const r={...e};for(const s in t)Object.prototype.hasOwnProperty.call(t,s)&&(r[s]=or(r[s],t[s],n-1));return r}const jr="_sentrySpan";function en(e,t){t?Ee(e,jr,t):delete e[jr]}function zn(e){return e[jr]}const du=100;class Is{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:Xe(),spanId:Ke()}}clone(){const t=new Is;return t._breadcrumbs=[...this._breadcrumbs],t._tags={...this._tags},t._extra={...this._extra},t._contexts={...this._contexts},this._contexts.flags&&(t._contexts.flags={values:[...this._contexts.flags.values]}),t._user=this._user,t._level=this._level,t._session=this._session,t._transactionName=this._transactionName,t._fingerprint=this._fingerprint,t._eventProcessors=[...this._eventProcessors],t._requestSession=this._requestSession,t._attachments=[...this._attachments],t._sdkProcessingMetadata={...this._sdkProcessingMetadata},t._propagationContext={...this._propagationContext},t._client=this._client,t._lastEventId=this._lastEventId,en(t,zn(this)),t}setClient(t){this._client=t}setLastEventId(t){this._lastEventId=t}getClient(){return this._client}lastEventId(){return this._lastEventId}addScopeListener(t){this._scopeListeners.push(t)}addEventProcessor(t){return this._eventProcessors.push(t),this}setUser(t){return this._user=t||{email:void 0,id:void 0,ip_address:void 0,username:void 0},this._session&&At(this._session,{user:t}),this._notifyScopeListeners(),this}getUser(){return this._user}getRequestSession(){return this._requestSession}setRequestSession(t){return this._requestSession=t,this}setTags(t){return this._tags={...this._tags,...t},this._notifyScopeListeners(),this}setTag(t,n){return this._tags={...this._tags,[t]:n},this._notifyScopeListeners(),this}setExtras(t){return this._extra={...this._extra,...t},this._notifyScopeListeners(),this}setExtra(t,n){return this._extra={...this._extra,[t]:n},this._notifyScopeListeners(),this}setFingerprint(t){return this._fingerprint=t,this._notifyScopeListeners(),this}setLevel(t){return this._level=t,this._notifyScopeListeners(),this}setTransactionName(t){return this._transactionName=t,this._notifyScopeListeners(),this}setContext(t,n){return n===null?delete this._contexts[t]:this._contexts[t]=n,this._notifyScopeListeners(),this}setSession(t){return t?this._session=t:delete this._session,this._notifyScopeListeners(),this}getSession(){return this._session}update(t){if(!t)return this;const n=typeof t=="function"?t(this):t,[r,s]=n instanceof ht?[n.getScopeData(),n.getRequestSession()]:Mt(n)?[t,t.requestSession]:[],{tags:i,extra:o,user:a,contexts:c,level:u,fingerprint:d=[],propagationContext:l}=r||{};return this._tags={...this._tags,...i},this._extra={...this._extra,...o},this._contexts={...this._contexts,...c},a&&Object.keys(a).length&&(this._user=a),u&&(this._level=u),d.length&&(this._fingerprint=d),l&&(this._propagationContext=l),s&&(this._requestSession=s),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,en(this,void 0),this._attachments=[],this.setPropagationContext({traceId:Xe()}),this._notifyScopeListeners(),this}addBreadcrumb(t,n){const r=typeof n=="number"?n:du;if(r<=0)return this;const s={timestamp:an(),...t};return this._breadcrumbs.push(s),this._breadcrumbs.length>r&&(this._breadcrumbs=this._breadcrumbs.slice(-r),this._client&&this._client.re
5cordDroppedEvent("buffer_overflow","log_item")),this._notifyScopeListeners(),this}getLastBreadcrumb(){return this._breadcrumbs[this._breadcrumbs.length-1]}clearBreadcrumbs(){return this._breadcrumbs=[],this._notifyScopeListeners(),this}addAttachment(t){return this._attachments.push(t),this}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:zn(this)}}setSDKProcessingMetadata(t){return this._sdkProcessingMetadata=or(this._sdkProcessingMetadata,t,2),this}setPropagationContext(t){return this._propagationContext={spanId:Ke(),...t},this}getPropagationContext(){return this._propagationContext}captureException(t,n){const r=n&&n.event_id?n.event_id:_e();if(!this._client)return y.warn("No client configured on scope - will not capture exception!"),r;const s=new Error("Sentry syntheticException");return this._client.captureException(t,{originalException:t,syntheticException:s,...n,event_id:r},this),r}captureMessage(t,n,r){const s=r&&r.event_id?r.event_id:_e();if(!this._client)return y.warn("No client configured on scope - will not capture message!"),s;const i=new Error(t);return this._client.captureMessage(t,n,{originalException:t,syntheticException:i,...r,event_id:s},this),s}captureEvent(t,n){const r=n&&n.event_id?n.event_id:_e();return this._client?(this._client.captureEvent(t,{...n,event_id:r},this),r):(y.warn("No client configured on scope - will not capture event!"),r)}_notifyScopeListeners(){this._notifyingListeners||(this._notifyingListeners=!0,this._scopeListeners.forEach(t=>{t(this)}),this._notifyingListeners=!1)}}const ht=Is;function fu(){return rr("defaultCurrentScope",()=>new ht)}function pu(){return rr("defaultIsolationScope",()=>new ht)}class hu{constructor(t,n){let r;t?r=t:r=new ht;let s;n?s=n:s=new ht,this._stack=[{scope:r}],this._isolationScope=s}withScope(t){const n=this._pushScope();let r;try{r=t(n)}catch(s){throw this._popScope(),s}return ir(r)?r.then(s=>(this._popScope(),s),s=>{throw this._popScope(),s}):(this._popScope(),r)}getClient(){return this.getStackTop().client}getScope(){return this.getStackTop().scope}getIsolationScope(){return this._isolationScope}getStackTop(){return this._stack[this._stack.length-1]}_pushScope(){const t=this.getScope().clone();return this._stack.push({client:this.getClient(),scope:t}),t}_popScope(){return this._stack.length<=1?!1:!!this._stack.pop()}}function Ot(){const e=gt(),t=Ss(e);return t.stack=t.stack||new hu(fu(),pu())}function mu(e){return Ot().withScope(e)}function gu(e,t){const n=Ot();return n.withScope(()=>(n.getStackTop().scope=e,t(e)))}function li(e){return Ot().withScope(()=>e(Ot().getIsolationScope()))}function _u(){return{withIsolationScope:li,withScope:mu,withSetScope:gu,withSetIsolationScope:(e,t)=>li(t),getCurrentScope:()=>Ot().getScope(),getIsolationScope:()=>Ot().getIsolationScope()}}function Ut(e){const t=Ss(e);return t.acs?t.acs:_u()}function X(){const e=gt();return Ut(e).getCurrentScope()}function ke(){const e=gt();return Ut(e).getIsolationScope()}function yu(){return rr("globalScope",()=>new ht)}function ws(...e){const t=gt(),n=Ut(t);if(e.length===2){const[r,s]=e;return r?n.withSetScope(r,s):n.withScope(s)}return n.withScope(e[0])}function B(){return X().getClient()}function Su(e){const t=e.getPropagationContext(),{traceId:n,spanId:r,parentSpanId:s}=t;return te({trace_id:n,span_id:r,parent_span_id:s})}const Eu="_sentryMetrics";function qr(e){const t=e[Eu];if(!t)return;const n={};for(const[,[r,s]]of t)(n[r]||(n[r]=[])).push(te(s));return n}const Re="sentry.source",Fo="sentry.sample_rate",mt="sentry.op",se="sentry.origin",Gr="sentry.idle_span_finish_reason",ar="sentry.measurement_unit",cr="sentry.measurement_value",di="sentry.custom_span_name",bu="sentry.profile_id",ks="sentry.exclusive_time",vu=0,Bo=1,re=2;function Tu(e){if(e<400&&e>=100)return{code:Bo};if(e>=400&&e<500)switch(e){case 401:return{code:re,message:"unauthenticated"};case 403:return{code:re,message:"permission_denied"};case 404:return{code:re,message:"not_found"};case 409:return{code:re,message:"already_exists"};case 413:return{code:re,message:"failed_precondition"};case 429:return{code:re,message:"resource_exhausted"};case 499:return{code:re,message:"cancelled"};default:return{code:re,message:"invalid_argument"}}if(e>=500&&e<600)switch(e){case 501:return{code:re,message:"unimplemented"};case 503:return{code:re,message:"unavailable"};case 504:return{code:re,message:"deadline_exceeded"};default:return{code:re,message:"internal_error"}}return{code:re,message:"unknown_error"}}function $o(e,t){e.setAttribute("http.response.status_code",t);const n=Tu(t);n.message!=="unknown_error"&&e.setStatus(n)}const Cs="sentry-",Iu=/^sentry-/,wu=8192;function Uo(e){const t=Cu(e);if(!t)return;const n=Object.entries(t).reduce((r,[s,i])=>{if(s.match(Iu)){const o=s.slice(Cs.length);r[o]=i}return r},{});if(Object.keys(n).length>0)return n}function ku(e){if(!e)return;const t=Object.entries(e).reduce((n,[r,s])=>(s&&(n[`${Cs}${r}`]=s),n),{});return Ru(t)}function Cu(e){if(!(!e||!Le(e)&&!Array.isArray(e)))return Array.isArray(e)?e.reduce((t,n)=>{const r=fi(n);return Object.entries(r).forEach(([s,i])=>{t[s]=i}),t},{}):fi(e)}function fi(e){return e.split(",").map(t=>t.split("=").map(n=>decodeURIComponent(n.trim()))).reduce((t,[n,r])=>(n&&r&&(t[n]=r),t),{})}function Ru(e){if(Object.keys(e).length!==0)return Object.entries(e).reduce((t,[n,r],s)=>{const i=`${encodeURIComponent(n)}=${encodeURIComponent(r)}`,o=s===0?i:`${t},${i}`;return o.length>wu?(Ze&&y.warn(`Not adding key: ${n} with val: ${r} to baggage header due to exceeding baggage size limits.`),t):o},"")}const Ho=new RegExp("^[ \\t]*([0-9a-f]{32})?-?([0-9a-f]{16})?-?([01])?[ \\t]*$");function Mu(e){if(!e)return;const t=e.match(Ho);if(!t)return;let n;return t[3]==="1"?n=!0:t[3]==="0"&&(n=!1),{traceId:t[1],parentSampled:n,parentSpanId:t[2]}}function xu(e,t){const n=Mu(e),r=Uo(t);if(!n||!n.traceId)return{traceId:Xe(),spanId:Ke()};const{traceId:s,parentSpanId:i,parentSampled:o}=n,a=Ke();return{traceId:s,parentSpanId:i,spanId:a,sampled:o,dsc:r||{}}}function Wo(e=Xe(),t=Ke(),n){let r="";return n!==void 0&&(r=n?"-1":"-0"),`${e}-${t}${r}`}const zo=0,jo=1;let pi=!1;function Au(e){const{spanId:t,traceId:n}=e.spanContext(),{data:r,op:s,parent_span_id:i,status:o,origin:a}=z(e);return te({parent_span_id:i,span_id:t,trace_id:n,data:r,op:s,status:o,origin:a})}function Ou(e){const{spanId:t,traceId:n,isRemote:r}=e.spanContext(),s=r?t:z(e).parent_span_id,i=r?Ke():t;return te({parent_span_id:s,span_id:i,trace_id:n})}function Nu(e){const{traceId:t,spanId:n}=e.spanContext(),r=_t(e);return Wo(t,n,r)}function lt(e){return typeof e=="number"?hi(e):Array.isArray(e)?e[0]+e[1]/1e9:e instanceof Date?hi(e.getTime()):de()}function hi(e){return e>9999999999?e/1e3:e}function z(e){if(Lu(e))return e.getSpanJSON();try{const{spanId:t,traceId:n}=e.spanContext();if(Du(e)){const{attributes:r,startTime:s,name:i,endTime:o,parentSpanId:a,status:c}=e;return te({span_id:t,trace_id:n,data:r,description:i,parent_span_id:a,start_timestamp:lt(s),timestamp:lt(o)||void 0,status:qo(c),op:r[mt],origin:r[se],_metrics_summary:qr(e)})}return{span_id:t,trace_id:n}}catch{return{}}}function Du(e){const t=e;return!!t.attributes&&!!t.startTime&&!!t.name&&!!t.endTime&&!!t.status}function Lu(e){return typeof e.getSpanJSON=="function"}function _t(e){const{traceFlags:t}=e.spanContext();return t===jo}function qo(e){if(!(!e||e.code===vu))return e.code===Bo?"ok":e.message||"unknown_error"}const dt="_sentryChildSpans",Yr="_sentryRootSpan";function Go(e,t){const n=e[Yr]||e;Ee(t,Yr,n),e[dt]?e[dt].add(t):Ee(e,dt,new Set([t]))}function Pu(e,t){e[dt]&&e[dt].delete(t)}function Dn(e){const t=new Set;function n(r){if(!t.has(r)&&_t(r)){t.add(r);const s=r[dt]?Array.from(r[dt]):[];for(const i of s)n(i)}}return n(e),Array.from(t)}function ce(e){return e[Yr]||e}function ie(){const e=gt(),t=Ut(e);return t.getActiveSpan?t.getActiveSpan():zn(X())}function Yo(){pi||(et(()=>{console.warn("[Sentry] Deprecation warning: Returning null from `beforeSendSpan` will be disallowed from SDK ver
5sion 9.0.0 onwards. The callback will only support mutating spans. To drop certain spans, configure the respective integrations directly.")}),pi=!0)}let mi=!1;function Fu(){mi||(mi=!0,ko(Vr),Co(Vr))}function Vr(){const e=ie(),t=e&&ce(e);if(t){const n="internal_error";O&&y.log(`[Tracing] Root span: ${n} -> Global error occurred`),t.setStatus({code:re,message:n})}}Vr.tag="sentry_tracingErrorCallback";const Vo="_sentryScope",Xo="_sentryIsolationScope";function Bu(e,t,n){e&&(Ee(e,Xo,n),Ee(e,Vo,t))}function gi(e){return{scope:e[Vo],isolationScope:e[Xo]}}function Je(e){if(typeof __SENTRY_TRACING__=="boolean"&&!__SENTRY_TRACING__)return!1;const t=B(),n=e||t&&t.getOptions();return!!n&&(n.enableTracing||"tracesSampleRate"in n||"tracesSampler"in n)}class Ht{constructor(t={}){this._traceId=t.traceId||Xe(),this._spanId=t.spanId||Ke()}spanContext(){return{spanId:this._spanId,traceId:this._traceId,traceFlags:zo}}end(t){}setAttribute(t,n){return this}setAttributes(t){return this}setStatus(t){return this}updateName(t){return this}isRecording(){return!1}addEvent(t,n,r){return this}addLink(t){return this}addLinks(t){return this}recordException(t,n){}}const Rs="production",Ko="_frozenDsc";function _i(e,t){Ee(e,Ko,t)}function Jo(e,t){const n=t.getOptions(),{publicKey:r}=t.getDsn()||{},s=te({environment:n.environment||Rs,release:n.release,public_key:r,trace_id:e});return t.emit("createDsc",s),s}function Qo(e,t){const n=t.getPropagationContext();return n.dsc||Jo(n.traceId,e)}function yt(e){const t=B();if(!t)return{};const n=ce(e),r=n[Ko];if(r)return r;const s=n.spanContext().traceState,i=s&&s.get("sentry.dsc"),o=i&&Uo(i);if(o)return o;const a=Jo(e.spanContext().traceId,t),c=z(n),u=c.data||{},d=u[Fo];d!=null&&(a.sample_rate=`${d}`);const l=u[Re],f=c.description;return l!=="url"&&f&&(a.transaction=f),Je()&&(a.sampled=String(_t(n))),t.emit("createDsc",a,n),a}function $u(e){if(!O)return;const{description:t="< unknown name >",op:n="< unknown op >",parent_span_id:r}=z(e),{spanId:s}=e.spanContext(),i=_t(e),o=ce(e),a=o===e,c=`[Tracing] Starting ${i?"sampled":"unsampled"} ${a?"root ":""}span`,u=[`op: ${n}`,`name: ${t}`,`ID: ${s}`];if(r&&u.push(`parent ID: ${r}`),!a){const{op:d,description:l}=z(o);u.push(`root ID: ${o.spanContext().spanId}`),d&&u.push(`root op: ${d}`),l&&u.push(`root description: ${l}`)}y.log(`${c} 6 ${u.join(` 7 `)}`)}function Uu(e){if(!O)return;const{description:t="< unknown name >",op:n="< unknown op >"}=z(e),{spanId:r}=e.spanContext(),i=ce(e)===e,o=`[Tracing] Finishing "${n}" ${i?"root ":""}span "${t}" with ID ${r}`;y.log(o)}function jn(e){if(typeof e=="boolean")return Number(e);const t=typeof e=="string"?parseFloat(e):e;if(typeof t!="number"||isNaN(t)||t<0||t>1){O&&y.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)}.`);return}return t}function Hu(e,t){if(!Je(e))return[!1];const n=ke().getScopeData().sdkProcessingMetadata.normalizedRequest,r={...t,normalizedRequest:t.normalizedRequest||n};let s;typeof e.tracesSampler=="function"?s=e.tracesSampler(r):r.parentSampled!==void 0?s=r.parentSampled:typeof e.tracesSampleRate<"u"?s=e.tracesSampleRate:s=1;const i=jn(s);return i===void 0?(O&&y.warn("[Tracing] Discarding transaction because of invalid sample rate."),[!1]):i?Math.random()<i?[!0,i]:(O&&y.log(`[Tracing] Discarding transaction because it's not included in the random sample (sampling rate = ${Number(s)})`),[!1,i]):(O&&y.log(`[Tracing] Discarding transaction because ${typeof e.tracesSampler=="function"?"tracesSampler returned 0 or false":"a negative sampling decision was inherited or tracesSampleRate is set to 0"}`),[!1,i])}const Wu=/^(?:(\w+):)\/\/(?:(\w+)(?::(\w+)?)?@)([\w.-]+)(?::(\d+))?\/(.+)/;function zu(e){return e==="http"||e==="https"}function cn(e,t=!1){const{host:n,path:r,pass:s,port:i,projectId:o,protocol:a,publicKey:c}=e;return`${a}://${c}${t&&s?`:${s}`:""}@${n}${i?`:${i}`:""}/${r&&`${r}/`}${o}`}function ju(e){const t=Wu.exec(e);if(!t){et(()=>{console.error(`Invalid Sentry Dsn: ${e}`)});return}const[n,r,s="",i="",o="",a=""]=t.slice(1);let c="",u=a;const d=u.split("/");if(d.length>1&&(c=d.slice(0,-1).join("/"),u=d.pop()),u){const l=u.match(/^\d+/);l&&(u=l[0])}return Zo({host:i,pass:s,path:c,projectId:u,port:o,protocol:n,publicKey:r})}function Zo(e){return{protocol:e.protocol,publicKey:e.publicKey||"",pass:e.pass||"",host:e.host,port:e.port||"",path:e.path||"",projectId:e.projectId}}function qu(e){if(!Ze)return!0;const{port:t,projectId:n,protocol:r}=e;return["protocol","publicKey","host","projectId"].find(o=>e[o]?!1:(y.error(`Invalid Sentry Dsn: ${o} missing`),!0))?!1:n.match(/^\d+$/)?zu(r)?t&&isNaN(parseInt(t,10))?(y.error(`Invalid Sentry Dsn: Invalid port ${t}`),!1):!0:(y.error(`Invalid Sentry Dsn: Invalid protocol ${r}`),!1):(y.error(`Invalid Sentry Dsn: Invalid projectId ${n}`),!1)}function Gu(e){const t=typeof e=="string"?ju(e):Zo(e);if(!(!t||!qu(t)))return t}function Yu(){const e=typeof WeakSet=="function",t=e?new WeakSet:[];function n(s){if(e)return t.has(s)?!0:(t.add(s),!1);for(let i=0;i<t.length;i++)if(t[i]===s)return!0;return t.push(s),!1}function r(s){if(e)t.delete(s);else for(let i=0;i<t.length;i++)if(t[i]===s){t.splice(i,1);break}}return[n,r]}function Te(e,t=100,n=1/0){try{return Xr("",e,t,n)}catch(r){return{ERROR:`**non-serializable** (${r})`}}}function ea(e,t=3,n=100*1024){const r=Te(e,t);return Ju(r)>n?ea(e,t-1,n):r}function Xr(e,t,n=1/0,r=1/0,s=Yu()){const[i,o]=s;if(t==null||["boolean","string"].includes(typeof t)||typeof t=="number"&&Number.isFinite(t))return t;const a=Vu(e,t);if(!a.startsWith("[object "))return a;
7if(t.__sentry_skip_normalization__)return t;const c=typeof t.__sentry_override_normalization_depth__=="number"?t.__sentry_override_normalization_depth__:n;if(c===0)return a.replace("object ","");if(i(t))return"[Circular ~]";const u=t;if(u&&typeof u.toJSON=="function")try{const p=u.toJSON();return Xr("",p,c-1,r,s)}catch{}const d=Array.isArray(t)?[]:{};let l=0;const f=Do(t);for(const p in f){if(!Object.prototype.hasOwnProperty.call(f,p))continue;if(l>=r){d[p]="[MaxProperties ~]";break}const h=f[p];d[p]=Xr(p,h,c-1,r,s),l++}return o(t),d}function Vu(e,t){try{if(e==="domain"&&t&&typeof t=="object"&&t._events)return"[Domain]";if(e==="domainEmitter")return"[DomainEmitter]";if(typeof global<"u"&&t===global)return"[Global]";if(typeof window<"u"&&t===window)return"[Window]";if(typeof document<"u"&&t===document)return"[Document]";if(xo(t))return"[VueViewModel]";if(Zc(t))return"[SyntheticEvent]";if(typeof t=="number"&&!Number.isFinite(t))return`[${t}]`;if(typeof t=="function")return`[Function: ${Fe(t)}]`;if(typeof t=="symbol")return`[${String(t)}]`;if(typeof t=="bigint")return`[BigInt: ${String(t)}]`;const n=Xu(t);return/^HTML(\w*)Element$/.test(n)?`[HTMLElement: ${n}]`:`[object ${n}]`}catch(n){return`**non-serializable** (${n})`}}function Xu(e){const t=Object.getPrototypeOf(e);return t?t.constructor.name:"null prototype"}function Ku(e){return~-encodeURI(e).split(/%..|./).length}function Ju(e){return Ku(JSON.stringify(e))}function St(e,t=[]){return[e,t]}function Qu(e,t){const[n,r]=e;return[n,[...r,t]]}function yi(e,t){const n=e[1];for(const r of n){const s=r[0].type;if(t(r,s))return!0}return!1}function Kr(e){return $.__SENTRY__&&$.__SENTRY__.encodePolyfill?$.__SENTRY__.encodePolyfill(e):new TextEncoder().encode(e)}function Zu(e){const[t,n]=e;let r=JSON.stringify(t);function s(i){typeof r=="string"?r=typeof i=="string"?r+i:[Kr(r),i]:r.push(typeof i=="string"?Kr(i):i)}for(const i of n){const[o,a]=i;if(s(` 8${JSON.stringify(o)} 9`),typeof a=="string"||a instanceof Uint8Array)s(a);else{let c;try{c=JSON.stringify(a)}catch{c=JSON.stringify(Te(a))}s(c)}}return typeof r=="string"?r:el(r)}function el(e){const t=e.reduce((s,i)=>s+i.length,0),n=new Uint8Array(t);let r=0;for(const s of e)n.set(s,r),r+=s.length;return n}function tl(e){return[{type:"span"},e]}function nl(e){const t=typeof e.data=="string"?Kr(e.data):e.data;return[te({type:"attachment",length:t.length,filename:e.filename,content_type:e.contentType,attachment_type:e.attachmentType}),t]}const rl={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 Si(e){return rl[e]}function Ms(e){if(!e||!e.sdk)return;const{name:t,version:n}=e.sdk;return{name:t,version:n}}function ta(e,t,n,r){const s=e.sdkProcessingMetadata&&e.sdkProcessingMetadata.dynamicSamplingContext;return{event_id:e.event_id,sent_at:new Date().toISOString(),...t&&{sdk:t},...!!n&&r&&{dsn:cn(r)},...s&&{trace:te({...s})}}}function sl(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 il(e,t,n,r){const s=Ms(n),i={sent_at:new Date().toISOString(),...s&&{sdk:s},...!!r&&t&&{dsn:cn(t)}},o="aggregates"in e?[{type:"sessions"},e]:[{type:"session"},e.toJSON()];return St(i,[o])}function ol(e,t,n,r){const s=Ms(n),i=e.type&&e.type!=="replay_event"?e.type:"event";sl(e,n&&n.sdk);const o=ta(e,s,r,t);return delete e.sdkProcessingMetadata,St(o,[[{type:i},e]])}function al(e,t){function n(d){return!!d.trace_id&&!!d.public_key}const r=yt(e[0]),s=t&&t.getDsn(),i=t&&t.getOptions().tunnel,o={sent_at:new Date().toISOString(),...n(r)&&{trace:r},...!!i&&s&&{dsn:cn(s)}},a=t&&t.getOptions().beforeSendSpan,c=a?d=>{const l=a(z(d));return l||Yo(),l}:d=>z(d),u=[];for(const d of e){const l=c(d);l&&u.push(tl(l))}return St(o,u)}function cl(e,t,n,r=ie()){const s=r&&ce(r);s&&(O&&y.log(`[Measurement] Setting measurement on root span: ${e} = ${t} ${n}`),s.addEvent(e,{[cr]:t,[ar]:n}))}function Ei(e){if(!e||e.length===0)return;const t={};return e.forEach(n=>{const r=n.attributes||{},s=r[ar],i=r[cr];typeof s=="string"&&typeof i=="number"&&(t[n.name]={value:i,unit:s})}),t}const bi=1e3;class xs{constructor(t={}){this._traceId=t.traceId||Xe(),this._spanId=t.spanId||Ke(),this._startTime=t.startTimestamp||de(),this._attributes={},this.setAttributes({[se]:"manual",[mt]:t.op,...t.attributes}),this._name=t.name,t.parentSpanId&&(this._parentSpanId=t.parentSpanId),"sampled"in t&&(this._sampled=t.sampled),t.endTimestamp&&(this._endTime=t.endTimestamp),this._events=[],this._isStandaloneSpan=t.isStandalone,this._endTime&&this._onSpanEnded()}
9addLink(t){return this}addLinks(t){return this}recordException(t,n){}spanContext(){const{_spanId:t,_traceId:n,_sampled:r}=this;return{spanId:t,traceId:n,traceFlags:r?jo:zo}}setAttribute(t,n){return n===void 0?delete this._attributes[t]:this._attributes[t]=n,this}setAttributes(t){return Object.keys(t).forEach(n=>this.setAttribute(n,t[n])),this}updateStartTime(t){this._startTime=lt(t)}setStatus(t){return this._status=t,this}updateName(t){return this._name=t,this.setAttribute(Re,"custom"),this}end(t){this._endTime||(this._endTime=lt(t),Uu(this),this._onSpanEnded())}getSpanJSON(){return te({data:this._attributes,description:this._name,op:this._attributes[mt],parent_span_id:this._parentSpanId,span_id:this._spanId,start_timestamp:this._startTime,status:qo(this._status),timestamp:this._endTime,trace_id:this._traceId,origin:this._attributes[se],_metrics_summary:qr(this),profile_id:this._attributes[bu],exclusive_time:this._attributes[ks],measurements:Ei(this._events),is_segment:this._isStandaloneSpan&&ce(this)===this||void 0,segment_id:this._isStandaloneSpan?ce(this).spanContext().spanId:void 0})}isRecording(){return!this._endTime&&!!this._sampled}addEvent(t,n,r){O&&y.log("[Tracing] Adding an event to span:",t);const s=vi(n)?n:r||de(),i=vi(n)?{}:n||{},o={name:t,time:lt(s),attributes:i};return this._events.push(o),this}isStandaloneSpan(){return!!this._isStandaloneSpan}_onSpanEnded(){const t=B();if(t&&t.emit("spanEnd",this),!(this._isStandaloneSpan||this===ce(this)))return;if(this._isStandaloneSpan){this._sampled?ll(al([this],t)):(O&&y.log("[Tracing] Discarding standalone span because its trace was not chosen to be sampled."),t&&t.recordDroppedEvent("sample_rate","span"));return}const r=this._convertSpanToTransaction();r&&(gi(this).scope||X()).captureEvent(r)}_convertSpanToTransaction(){if(!Ti(z(this)))return;this._name||(O&&y.warn("Transaction has no name, falling back to `<unlabeled transaction>`."),this._name="<unlabeled transaction>");const{scope:t,isolationScope:n}=gi(this),s=(t||X()).getClient()||B();if(this._sampled!==!0){O&&y.log("[Tracing] Discarding transaction because its trace was not chosen to be sampled."),s&&s.recordDroppedEvent("sample_rate","transaction");return}const o=Dn(this).filter(l=>l!==this&&!ul(l)).map(l=>z(l)).filter(Ti),a=this._attributes[Re];delete this._attributes[di],o.forEach(l=>{l.data&&delete l.data[di]});const c={contexts:{trace:Au(this)},spans:o.length>bi?o.sort((l,f)=>l.start_timestamp-f.start_timestamp).slice(0,bi):o,start_timestamp:this._startTime,timestamp:this._endTime,transaction:this._name,type:"transaction",sdkProcessingMetadata:{capturedSpanScope:t,capturedSpanIsolationScope:n,...te({dynamicSamplingContext:yt(this)})},_metrics_summary:qr(this),...a&&{transaction_info:{source:a}}},u=Ei(this._events);return u&&Object.keys(u).length&&(O&&y.log("[Measurements] Adding measurements to transaction event",JSON.stringify(u,void 0,2)),c.measurements=u),c}}function vi(e){return e&&typeof e=="number"||e instanceof Date||Array.isArray(e)}function Ti(e){return!!e.start_timestamp&&!!e.timestamp&&!!e.span_id&&!!e.trace_id}function ul(e){return e instanceof xs&&e.isStandaloneSpan()}function ll(e){const t=B();if(!t)return;const n=e[1];if(!n||n.length===0){t.recordDroppedEvent("before_send","span");return}t.sendEnvelope(e)}const na="__SENTRY_SUPPRESS_TRACING__";function un(e){const t=sa();if(t.startInactiveSpan)return t.startInactiveSpan(e);const n=fl(e),{forceTransaction:r,parentSpan:s}=e;return(e.scope?o=>ws(e.scope,o):s!==void 0?o=>ra(s,o):o=>o())(()=>{const o=X(),a=hl(o);return e.onlyIfParent&&!a?new Ht:dl({parentSpan:a,spanArguments:n,forceTransaction:r,scope:o})})}function ra(e,t){const n=sa();return n.withActiveSpan?n.withActiveSpan(e,t):ws(r=>(en(r,e||void 0),t(r)))}function dl({parentSpan:e,spanArguments:t,forceTransaction:n,scope:r}){if(!Je())return new Ht;const s=ke();let i;if(e&&!n)i=pl(e,r,t),Go(e,i);else if(e){const o=yt(e),{traceId:a,spanId:c}=e.spanContext(),u=_t(e);i=Ii({traceId:a,parentSpanId:c,...t},r,u),_i(i,o)}else{const{traceId:o,dsc:a,parentSpanId:c,sampled:u}={...s.getPropagationContext(),...r.getPropagationContext()};i=Ii({traceId:o,parentSpanId:c,...t},r,u),a&&_i(i,a)}return $u(i),Bu(i,r,s),i}function fl(e){const n={isStandalone:(e.experimental||{}).standalone,...e};if(e.startTime){const r={...n};return r.startTimestamp=lt(e.startTime),delete r.startTime,r}return n}function sa(){const e=gt();return Ut(e)}function Ii(e,t,n){const r=B(),s=r&&r.getOptions()||{},{name:i="",attributes:o}=e,[a,c]=t.getScopeData().sdkProcessingMetadata[na]?[!1]:Hu(s,{name:i,parentSampled:n,attributes:o,transactionContext:{name:i,parentSampled:n}}),u=new xs({...e,attributes:{[Re]:"custom",...e.attributes},sampled:a});return c!==void 0&&u.setAttribute(Fo,c),r&&r.emit("spanStart",u),u}function pl(e,t,n){const{spanId:r,traceId:s}=e.spanContext(),i=t.getScopeData().sdkProcessingMetadata[na]?!1:_t(e),o=i?new xs({...n,parentSpanId:r,traceId:s,sampled:i}):new Ht({traceId:s});Go(e,o);const a=B();return a&&(a.emit("spanStart",o),n.endTimestamp&&a.emit("spanEnd",o)),o}function hl(e){const t=zn(e);if(!t)return;const n=B();return(n?n.getOptions():{}).parentSpanIsAlwaysRootSpan?ce(t):t}const Ln={idleTimeout:1e3,finalTimeout:3e4,childSpanTimeout:15e3},ml="heartbeatFailed",gl="idleTimeout",_l="finalTimeout",yl="externalFinish";function ia(e,t={}){const n=new Map;let r=!1,s,i=yl,o=!t.disableAutoFinish;const a=[],{idleTimeout:c=Ln.idleTimeout,finalTimeout:u=Ln.finalTimeout,childSpanTimeout:d=Ln.childSpanTimeout,beforeSpanEnd:l}=t,f=B();if(!f||!Je())return new Ht;const p=X(),h=ie(),m=Sl(e);m.end=new Proxy(m.end,{apply(g,T,w){l&&l(m);const[_,...b]=w,N=_||de(),R=lt(N),G=Dn(m).filter(W=>W!==m);if(!G.length)return v(R),Reflect.apply(g,T,[R,...b]);const J=G.map(W=>z(W).timestamp).filter(W=>!!W),oe=J.length?Math.max(...J):void 0,D=z(m).start_timestamp,ne=Math.min(D?D+u/1e3:1/0,Math.max(D||-1/0,Math.min(R,oe||1/0)));return v(ne),Reflect.apply(g,T,[ne,...b])}});function E(){s&&(clearTimeout(s),s=void 0)}function S(g){E(),s=setTimeout(()=>{!r&&n.size===0&&o&&(i=gl,m.end(g))},c)}function C(g){s=setTimeout(()=>{!r&&o&&(i=ml,m.end(g))},d)}function F(g){E(),n.set(g,!0);const T=de();C(T+d/1e3)}function L(g){if(n.has(g)&&n.delete(g),n.size===0){const T=de();S(T+c/1e3)}}function v(g){r=!0,n.clear(),a.forEach(R=>R()),en(p,h);const T=z(m),{start_timestamp:w}=T;if(!w)return;(T.data||{})[Gr]||m.setAttribute(Gr,i),y.log(`[Tracing] Idle span "${T.op}" finished`);const b=Dn(m).filter(R=>R!==m);let N=0;b.forEach(R=>{R.isRecording()&&(R.setStatus({code:re,message:"cancelled"}),R.end(g),O&&y.log("[Tracing] Cancelling span since span ended early",JSON.stringify(R,void 0,2)));const G=z(R),{timestamp:J=0,start_timestamp:oe=0}=G,D=oe<=g,ne=(u+c)/1e3,W=J-oe<=ne;if(O){const pe=JSON.stringify(R,void 0,2);D?W||y.log("[Tracing] Discarding span since it finished after idle span final timeout",pe):y.log("[Tracing] Discarding span since it happened after idle span was finished",pe)}
9(!W||!D)&&(Pu(m,R),N++)}),N>0&&m.setAttribute("sentry.idle_span_discarded_spans",N)}return a.push(f.on("spanStart",g=>{if(r||g===m||z(g).timestamp)return;Dn(m).includes(g)&&F(g.spanContext().spanId)})),a.push(f.on("spanEnd",g=>{r||L(g.spanContext().spanId)})),a.push(f.on("idleSpanEnableAutoFinish",g=>{g===m&&(o=!0,S(),n.size&&C())})),t.disableAutoFinish||S(),setTimeout(()=>{r||(m.setStatus({code:re,message:"deadline_exceeded"}),i=_l,m.end())},u),m}function Sl(e){const t=un(e);return en(X(),t),O&&y.log("[Tracing] Started span is an idle span"),t}function Jr(e,t,n,r=0){return new ye((s,i)=>{const o=e[r];if(t===null||typeof o!="function")s(t);else{const a=o({...t},n);O&&o.id&&a===null&&y.log(`Event processor "${o.id}" dropped event`),ir(a)?a.then(c=>Jr(e,c,n,r+1).then(s)).then(null,i):Jr(e,a,n,r+1).then(s).then(null,i)}})}let En,wi,bn;function El(e){const t=$._sentryDebugIds;if(!t)return{};const n=Object.keys(t);return bn&&n.length===wi||(wi=n.length,bn=n.reduce((r,s)=>{En||(En={});const i=En[s];if(i)r[i[0]]=i[1];else{const o=e(s);for(let a=o.length-1;a>=0;a--){const c=o[a],u=c&&c.filename,d=t[s];if(u&&d){r[u]=d,En[s]=[u,d];break}}}return r},{})),bn}function bl(e,t){const{fingerprint:n,span:r,breadcrumbs:s,sdkProcessingMetadata:i}=t;vl(e,t),r&&wl(e,r),kl(e,n),Tl(e,s),Il(e,i)}function ki(e,t){const{extra:n,tags:r,user:s,contexts:i,level:o,sdkProcessingMetadata:a,breadcrumbs:c,fingerprint:u,eventProcessors:d,attachments:l,propagationContext:f,transactionName:p,span:h}=t;vn(e,"extra",n),vn(e,"tags",r),vn(e,"user",s),vn(e,"contexts",i),e.sdkProcessingMetadata=or(e.sdkProcessingMetadata,a,2),o&&(e.level=o),p&&(e.transactionName=p),h&&(e.span=h),c.length&&(e.breadcrumbs=[...e.breadcrumbs,...c]),u.length&&(e.fingerprint=[...e.fingerprint,...u]),d.length&&(e.eventProcessors=[...e.eventProcessors,...d]),l.length&&(e.attachments=[...e.attachments,...l]),e.propagationContext={...e.propagationContext,...f}}
9function vn(e,t,n){e[t]=or(e[t],n,1)}function vl(e,t){const{extra:n,tags:r,user:s,contexts:i,level:o,transactionName:a}=t,c=te(n);c&&Object.keys(c).length&&(e.extra={...c,...e.extra});const u=te(r);u&&Object.keys(u).length&&(e.tags={...u,...e.tags});const d=te(s);d&&Object.keys(d).length&&(e.user={...d,...e.user});const l=te(i);l&&Object.keys(l).length&&(e.contexts={...l,...e.contexts}),o&&(e.level=o),a&&e.type!=="transaction"&&(e.transaction=a)}function Tl(e,t){const n=[...e.breadcrumbs||[],...t];e.breadcrumbs=n.length?n:void 0}function Il(e,t){e.sdkProcessingMetadata={...e.sdkProcessingMetadata,...t}}function wl(e,t){e.contexts={trace:Ou(t),...e.contexts},e.sdkProcessingMetadata={dynamicSamplingContext:yt(t),...e.sdkProcessingMetadata};const n=ce(t),r=z(n).description;r&&!e.transaction&&e.type==="transaction"&&(e.transaction=r)}function kl(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 oa(e,t,n,r,s,i){const{normalizeDepth:o=3,normalizeMaxBreadth:a=1e3}=e,c={...t,event_id:t.event_id||n.event_id||_e(),timestamp:t.timestamp||an()},u=n.integrations||e.integrations.map(E=>E.name);Cl(c,e),xl(c,u),s&&s.emit("applyFrameMetadata",t),t.type===void 0&&Rl(c,e.stackParser);const d=Ol(r,n.captureContext);n.mechanism&&xt(c,n.mechanism);const l=s?s.getEventProcessors():[],f=yu().getScopeData();if(i){const E=i.getScopeData();ki(f,E)}if(d){const E=d.getScopeData();ki(f,E)}const p=[...n.attachments||[],...f.attachments];p.length&&(n.attachments=p),bl(c,f);const h=[...l,...f.eventProcessors];return Jr(h,c,n).then(E=>(E&&Ml(E),typeof o=="number"&&o>0?Al(E,o,a):E))}function Cl(e,t){const{environment:n,release:r,dist:s,maxValueLength:i=250}=t;e.environment=e.environment||n||Rs,!e.release&&r&&(e.release=r),!e.dist&&s&&(e.dist=s),e.message&&(e.message=Rt(e.message,i));const o=e.exception&&e.exception.values&&e.exception.values[0];o&&o.value&&(o.value=Rt(o.value,i));const a=e.request;a&&a.url&&(a.url=Rt(a.url,i))}function Rl(e,t){const n=El(t);try{e.exception.values.forEach(r=>{r.stacktrace.frames.forEach(s=>{n&&s.filename&&(s.debug_id=n[s.filename])})})}catch{}}function Ml(e){const t={};try{e.exception.values.forEach(r=>{r.stacktrace.frames.forEach(s=>{s.debug_id&&(s.abs_path?t[s.abs_path]=s.debug_id:s.filename&&(t[s.filename]=s.debug_id),delete s.debug_id)})})}catch{}if(Object.keys(t).length===0)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(([r,s])=>{n.push({type:"sourcemap",code_file:r,debug_id:s})})}function xl(e,t){t.length>0&&(e.sdk=e.sdk||{},e.sdk.integrations=[...e.sdk.integrations||[],...t])}function Al(e,t,n){if(!e)return null;const r={...e,...e.breadcrumbs&&{breadcrumbs:e.breadcrumbs.map(s=>({...s,...s.data&&{data:Te(s.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(s=>({...s,...s.data&&{data:Te(s.data,t,n)}}))),e.contexts&&e.contexts.flags&&r.contexts&&(r.contexts.flags=Te(e.contexts.flags,3,n)),r}function Ol(e,t){if(!t)return e;const n=e?e.clone():new ht;return n.update(t),n}function aa(e,t){return X().captureException(e,void 0)}function ca(e,t){return X().captureEvent(e,t)}function ua(e,t){ke().setContext(e,t)}function Nl(){const e=B();return!!e&&e.getOptions().enabled!==!1&&!!e.getTransport()}function Dl(e){ke().addEventProcessor(e)}function Ci(e){const t=B(),n=ke(),r=X(),{release:s,environment:i=Rs}=t&&t.getOptions()||{},{userAgent:o}=$.navigator||{},a=cu({release:s,environment:i,user:r.getUser()||n.getUser(),...o&&{userAgent:o},...e}),c=n.getSession();return c&&c.status==="ok"&&At(c,{status:"exited"}),la(),n.setSession(a),r.setSession(a),a}function la(){const e=ke(),t=X(),n=t.getSession()||e.getSession();n&&uu(n),da(),e.setSession(),t.setSession()}function da(){const e=ke(),t=X(),n=B(),r=t.getSession()||e.getSession();r&&n&&n.captureSession(r)}function Ri(e=!1){if(e){la();return}da()}const Ll="7";function Pl(e){const t=e.protocol?`${e.protocol}:`:"",n=e.port?`:${e.port}`:"";return`${t}//${e.host}${n}${e.path?`/${e.path}`:""}/api/`}function Fl(e){return`${Pl(e)}${e.projectId}/envelope/`}function Bl(e,t){const n={sentry_version:Ll};return e.publicKey&&(n.sentry_key=e.publicKey),t&&(n.sentry_client=`${t.name}/${t.version}`),new URLSearchParams(n).toString()}function $l(e,t,n){return t||`${Fl(e)}?${Bl(e,n)}`}const Mi=[];function Ul(e){const t={};return e.forEach(n=>{const{name:r}=n,s=t[r];s&&!s.isDefaultInstance&&n.isDefaultInstance||(t[r]=n)}),Object.values(t)}function Hl(e){const t=e.defaultIntegrations||[],n=e.integrations;t.forEach(o=>{o.isDefaultInstance=!0});let r;if(Array.isArray(n))r=[...t,...n];else if(typeof n=="function"){const o=n(t);r=Array.isArray(o)?o:[o]}else r=t;const s=Ul(r),i=s.findIndex(o=>o.name==="Debug");if(i>-1){const[o]=s.splice(i,1);s.push(o)}return s}function Wl(e,t){const n={};return t.forEach(r=>{r&&fa(e,r,n)}),n}function xi(e,t){for(const n of t)n&&n.afterAllSetup&&n.afterAllSetup(e)}function fa(e,t,n){if(n[t.name]){O&&y.log(`Integration skipped because it was already installed: ${t.name}`);return}if(n[t.name]=t,Mi.indexOf(t.name)===-1&&typeof t.setupOnce=="function"&&(t.setupOnce(),Mi.push(t.name)),t.setup&&typeof t.setup=="function"&&t.setup(e),typeof t.preprocessEvent=="function"){const r=t.preprocessEvent.bind(t);e.on("preprocessEvent",(s,i)=>r(s,i,e))}if(typeof t.processEvent=="function"){const r=t.processEvent.bind(t),s=Object.assign((i,o)=>r(i,o,e),{id:t.name});e.addEventProcessor(s)}O&&y.log(`Integration installed: ${t.name}`)}function zl(e,t,n){const r=[{type:"client_report"},{timestamp:an(),discarded_events:e}];return St(t?{dsn:t}:{},[r])}
vendor: 1,872 bytes, line 9
9class Ie extends Error{constructor(t,n="warn"){super(t),this.message=t,this.logLevel=n}}const Ai="Not capturing exception because it's already been captured.";class jl{constructor(t){if(this._options=t,this._integrations={},this._numProcessing=0,this._outcomes={},this._hooks={},this._eventProcessors=[],t.dsn?this._dsn=Gu(t.dsn):O&&y.warn("No DSN provided, client will not send events."),this._dsn){const s=$l(this._dsn,t.tunnel,t._metadata?t._metadata.sdk:void 0);this._transport=t.transport({tunnel:this._options.tunnel,recordDroppedEvent:this.recordDroppedEvent.bind(this),...t.transportOptions,url:s})}const r=["enableTracing","tracesSampleRate","tracesSampler"].find(s=>s in t&&t[s]==null);r&&et(()=>{console.warn(`[Sentry] Deprecation warning: \`${r}\` is set to undefined, which leads to tracing being enabled. In v9, a value of \`undefined\` will result in tracing being disabled.`)})}captureException(t,n,r){const s=_e();if(ui(t))return O&&y.log(Ai),s;const i={event_id:s,...n};return this._process(this.eventFromException(t,i).then(o=>this._captureEvent(o,i,r))),i.event_id}captureMessage(t,n,r,s){const i={event_id:_e(),...r},o=bs(t)?t:String(t),a=vs(t)?this.eventFromMessage(o,n,i):this.eventFromException(t,i);return this._process(a.then(c=>this._captureEvent(c,i,s))),i.event_id}captureEvent(t,n,r){const s=_e();if(n&&n.originalException&&ui(n.originalException))return O&&y.log(Ai),s;const i={event_id:s,...n},a=(t.sdkProcessingMetadata||{}).capturedSpanScope;return this._process(this._captureEvent(t,i,a||r)),i.event_id}captureSession(t){typeof t.release!="string"?O&&y.warn("Discarded session because of missing or non-string release"):(this.sendSession(t),At(t,{init:!1}))}getDsn(){return this._dsn}getOptions(){return this._options}getSdkMetadata(){return this._options._metadata}getTransport(){return this._transport}flush(t){const n=this._transport;
9return n?(this.emit("flush"),this._isClientDoneProcessing(t).then(r=>n.flush(t).then(s=>r&&s))):Ue(!0)}close(t){return this.flush(t).then(n=>(this.getOptions().enabled=!1,this.emit("close"),n))}getEventProcessors(){return this._eventProcessors}addEventProcessor(t){this._eventProcessors.push(t)}init(){(this._isEnabled()||this._options.integrations.some(({name:t})=>t.startsWith("Spotlight")))&&this._setupIntegrations()}getIntegrationByName(t){return this._integrations[t]}addIntegration(t){const n=this._integrations[t.name];fa(this,t,this._integrations),n||xi(this,[t])}sendEvent(t,n={}){this.emit("beforeSendEvent",t,n);let r=ol(t,this._dsn,this._options._metadata,this._options.tunnel);for(const i of n.attachments||[])r=Qu(r,nl(i));const s=this.sendEnvelope(r);s&&s.then(i=>this.emit("afterSendEvent",t,i),null)}sendSession(t){const n=il(t,this._dsn,this._options._metadata,this._options.tunnel);this.sendEnvelope(n)}recordDroppedEvent(t,n,r){if(this._options.sendClientReports){const s=typeof r=="number"?r:1,i=`${t}:${n}`;O&&y.log(`Recording outcome: "${i}"${s>1?` (${s} times)`:""}`),this._outcomes[i]=(this._outcomes[i]||0)+s}}on(t,n){const r=this._hooks[t]=this._hooks[t]||[];return r.push(n),()=>{const s=r.indexOf(n);s>-1&&r.splice(s,1)}}emit(t,...n){const r=this._hooks[t];r&&r.forEach(s=>s(...n))}sendEnvelope(t){return this.emit("beforeEnvelope",t),this._isEnabled()&&this._transport?this._transport.send(t).then(null,n=>(O&&y.error("Error while sending envelope:",n),n)):(O&&y.error("Transport disabled"),Ue({}))}_setupIntegrations(){const{integrations:t}=this._options;this._integrations=Wl(this,t),xi(this,t)}_updateSessionFromEvent(t,n){let r=n.level==="fatal",s=!1;const i=n.exception&&n.exception.values;if(i){s=!0;for(const c of i){const u=c.mechanism;if(u&&u.handled===!1){r=!0;break}}}const o=t.status==="ok";(o&&t.errors===0||o&&r)&&(At(t,{...r&&{status:"crashed"},errors:t.errors||Number(s||r)}),this.captureSession(t))}_isClientDoneProcessing(t){return new ye(n=>{let r=0;const s=1,i=setInterval(()=>{this._numProcessing==0?(clearInterval(i),n(!0)):(r+=s,t&&r>=t&&(clearInterval(i),n(!1)))},s)})}_isEnabled(){return this.getOptions().enabled!==!1&&this._transport!==void 0}_prepareEvent(t,n,r=X(),s=ke()){const i=this.getOptions(),o=Object.keys(this._integrations);return!n.integrations&&o.length>0&&(n.integrations=o),this.emit("preprocessEvent",t,n),t.type||s.setLastEventId(t.event_id||n.event_id),oa(i,t,n,r,this,s).then(a=>{if(a===null)return a;a.contexts={trace:Su(r),...a.contexts};const c=Qo(this,r);return a.sdkProcessingMetadata={dynamicSamplingContext:c,...a.sdkProcessingMetadata},a})}_captureEvent(t,n={},r){return this._processEvent(t,n,r).then(s=>s.event_id,s=>{O&&(s instanceof Ie&&s.logLevel==="log"?y.log(s.message):y.warn(s))})}_processEvent(t,n,r){const s=this.getOptions(),{sampleRate:i}=s,o=ha(t),a=pa(t),c=t.type||"error",u=`before send for type \`${c}\``,d=typeof i>"u"?void 0:jn(i);if(a&&typeof d=="number"&&Math.random()>d)return this.recordDroppedEvent("sample_rate","error",t),Wn(new Ie(`Discarding event because it's not included in the random sample (sampling rate = ${i})`,"log"));const l=c==="replay_event"?"replay":c,p=(t.sdkProcessingMetadata||{}).capturedSpanIsolationScope;return this._prepareEvent(t,n,r,p).then(h=>{if(h===null)throw this.recordDroppedEvent("event_processor",l,t),new Ie("An event processor returned `null`, will not send event.","log");if(n.data&&n.data.__sentry__===!0)return h;const E=Gl(this,s,h,n);return ql(E,u)}).then(h=>{if(h===null){if(this.recordDroppedEvent("before_send",l,t),o){const C=1+(t.spans||[]).length;this.recordDroppedEvent("before_send","span",C)}throw new Ie(`${u} returned \`null\`, will not send event.`,"log")}const m=r&&r.getSession();if(!o&&m&&this._updateSessionFromEvent(m,h),o){const S=h.sdkProcessingMetadata&&h.sdkProcessingMetadata.spanCountBeforeProcessing||0,C=h.spans?h.spans.length:0,F=S-C;F>0&&this.recordDroppedEvent("before_send","span",F)}const E=h.transaction_info;if(o&&E&&h.transaction!==t.transaction){const S="custom";h.transaction_info={...E,source:S}}return this.sendEvent(h,n),h}).then(null,h=>{throw h instanceof Ie?h:(this.captureException(h,{data:{__sentry__:!0},originalException:h}),new Ie(`Event processing pipeline threw an error, original event will not be sent. Details have been sent as a new event. 10Reason: ${h}`))})}_process(t){this._numProcessing++,t.then(n=>(this._numProcessing--,n),n=>(this._numProcessing--,n))}_clearOutcomes(){const t=this._outcomes;return this._outcomes={},Object.entries(t).map(([n,r])=>{const[s,i]=n.split(":");return{reason:s,category:i,quantity:r}})}_flushOutcomes(){O&&y.log("Flushing outcomes...");const t=this._clearOutcomes();if(t.length===0){O&&y.log("No outcomes to send");return}if(!this._dsn){O&&y.log("No dsn provided, will not send outcomes");return}O&&y.log("Sending outcomes:",t);const n=zl(t,this._options.tunnel&&cn(this._dsn));this.sendEnvelope(n)}}function ql(e,t){const n=`${t} must return \`null\` or a valid event.`;if(ir(e))return e.then(r=>{if(!Mt(r)&&r!==null)throw new Ie(n);return r},r=>{throw new Ie(`${t} rejected with ${r}`)});if(!Mt(e)&&e!==null)throw new Ie(n);return e}function Gl(e,t,n,r){const{beforeSend:s,beforeSendTransaction:i,beforeSendSpan:o}=t;if(pa(n)&&s)return s(n,r);if(ha(n)){if(n.spans&&o){const a=[];for(const c of n.spans){const u=o(c);u?a.push(u):(Yo(),e.recordDroppedEvent("before_send","span"))}n.spans=a}if(i){if(n.spans){const a=n.spans.length;n.sdkProcessingMetadata={...n.sdkProcessingMetadata,spanCountBeforeProcessing:a}}return i(n,r)}}return n}function pa(e){return e.type===void 0}function ha(e){return e.type==="transaction"}function Yl(e,t){t.debug===!0&&(O?y.enable():et(()=>{console.warn("[Sentry] Cannot initialize SDK with `debug` option using a non-debug bundle.")})),X().update(t.initialScope);const r=new e(t);return Vl(r),r.init(),r}function Vl(e){X().setClient(e)}function Xl(e){const t=[];function n(){return e===void 0||t.length<e}function r(o){return t.splice(t.indexOf(o),1)[0]||Promise.resolve(void 0)}function s(o){if(!n())return Wn(new Ie("Not adding Promise because buffer limit was reached."));const a=o();return t.indexOf(a)===-1&&t.push(a),a.then(()=>r(a)).then(null,()=>r(a).then(null,()=>{})),a}function i(o){return new ye((a,c)=>{let u=t.length;if(!u)return a(!0);const d=setTimeout(()=>{o&&o>0&&a(!1)},o);t.forEach(l=>{Ue(l).then(()=>{--u||(clearTimeout(d),a(!0))},c)})})}return{$:t,add:s,drain:i}}const Kl=60*1e3;function Jl(e,t=Date.now()){const n=parseInt(`${e}`,10);if(!isNaN(n))return n*1e3;const r=Date.parse(`${e}`);return isNaN(r)?Kl:r-t}function Ql(e,t){return e[t]||e.all||0}function ma(e,t,n=Date.now()){return Ql(e,t)>n}function ga(e,{statusCode:t,headers:n},r=Date.now()){const s={...e},i=n&&n["x-sentry-rate-limits"],o=n&&n["retry-after"];if(i)for(const a of i.trim().split(",")){const[c,u,,,d]=a.split(":",5),l=parseInt(c,10),f=(isNaN(l)?60:l)*1e3;if(!u)s.all=r+f;else for(const p of u.split(";"))p==="metric_bucket"?(!d||d.split(";").includes("custom"))&&(s[p]=r+f):s[p]=r+f}else o?s.all=r+Jl(o,r):t===429&&(s.all=r+60*1e3);return s}const Zl=64;function ed(e,t,n=Xl(e.bufferSize||Zl)){let r={};const s=o=>n.drain(o);function i(o){const a=[];if(yi(o,(l,f)=>{const p=Si(f);if(ma(r,p)){const h=Oi(l,f);e.recordDroppedEvent("ratelimit_backoff",p,h)}else a.push(l)}),a.length===0)return Ue({});const c=St(o[0],a),u=l=>{yi(c,(f,p)=>{const h=Oi(f,p);
10e.recordDroppedEvent(l,Si(p),h)})},d=()=>t({body:Zu(c)}).then(l=>(l.statusCode!==void 0&&(l.statusCode<200||l.statusCode>=300)&&O&&y.warn(`Sentry responded with status code ${l.statusCode} to sent event.`),r=ga(r,l),l),l=>{throw u("network_error"),l});return n.add(d).then(l=>l,l=>{if(l instanceof Ie)return O&&y.error("Skipped sending event because buffer is full."),u("queue_overflow"),Ue({});throw l})}return{send:i,flush:s}}function Oi(e,t){if(!(t!=="event"&&t!=="transaction"))return Array.isArray(e)?e[1]:void 0}function td(e,t){const n=t&&t.getDsn(),r=t&&t.getOptions().tunnel;return rd(e,n)||nd(e,r)}function nd(e,t){return t?Ni(e)===Ni(t):!1}function rd(e,t){return t?e.includes(t.host):!1}function Ni(e){return e[e.length-1]==="/"?e.slice(0,-1):e}function _a(e,t,n=[t],r="npm"){const s=e._metadata||{};s.sdk||(s.sdk={name:`sentry.javascript.${t}`,packages:n.map(i=>({name:`${r}:@sentry/${i}`,version:ut})),version:ut}),e._metadata=s}function ya(e={}){const t=B();if(!Nl()||!t)return{};const n=gt(),r=Ut(n);if(r.getTraceData)return r.getTraceData(e);const s=X(),i=e.span||ie(),o=i?Nu(i):sd(s),a=i?yt(i):Qo(t,s),c=ku(a);return Ho.test(o)?{"sentry-trace":o,baggage:c}:(y.warn("Invalid sentry-trace data. Cannot generate trace data"),{})}function sd(e){const{traceId:t,sampled:n,spanId:r}=e.getPropagationContext();return Wo(t,r,n)}const id=100;function Qe(e,t){const n=B(),r=ke();if(!n)return;const{beforeBreadcrumb:s=null,maxBreadcrumbs:i=id}=n.getOptions();if(i<=0)return;const a={timestamp:an(),...e},c=s?et(()=>s(a,t)):a;c!==null&&(n.emit&&n.emit("beforeAddBreadcrumb",c,t),r.addBreadcrumb(c,i))}let Di;const od="FunctionToString",Li=new WeakMap,ad=()=>({name:od,setupOnce(){Di=Function.prototype.toString;try{Function.prototype.toString=function(...e){const t=Ts(this),n=Li.has(B())&&t!==void 0?t:this;return Di.apply(n,e)}}catch{}},setup(e){Li.set(e,!0)}}),cd=ad,ud=[/^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+$/],ld="InboundFilters",dd=(e={})=>({name:ld,processEvent(t,n,r){const s=r.getOptions(),i=pd(e,s);return hd(t,i)?null:t}}),fd=dd;function pd(e={},t={}){return{allowUrls:[...e.allowUrls||[],...t.allowUrls||[]],denyUrls:[...e.denyUrls||[],...t.denyUrls||[]],ignoreErrors:[...e.ignoreErrors||[],...t.ignoreErrors||[],...e.disableErrorDefaults?[]:ud],ignoreTransactions:[...e.ignoreTransactions||[],...t.ignoreTransactions||[]],ignoreInternal:e.ignoreInternal!==void 0?e.ignoreInternal:!0}}function hd(e,t){return t.ignoreInternal&&Ed(e)?(O&&y.warn(`Event dropped due to being internal Sentry Error. 11Event: ${We(e)}`),!0):md(e,t.ignoreErrors)?(O&&y.warn(`Event dropped due to being matched by \`ignoreErrors\` option. 12Event: ${We(e)}`),!0):vd(e)?(O&&y.warn(`Event dropped due to not having an error message, error type or stacktrace. 13Event: ${We(e)}`),!0):gd(e,t.ignoreTransactions)?(O&&y.warn(`Event dropped due to being matched by \`ignoreTransactions\` option. 14Event: ${We(e)}`),!0):_d(e,t.denyUrls)?(O&&y.warn(`Event dropped due to being matched by \`denyUrls\` option. 15Event: ${We(e)}. 16Url: ${qn(e)}`),!0):yd(e,t.allowUrls)?!1:(O&&y.warn(`Event dropped due to not being matched by \`allowUrls\` option. 17Event: ${We(e)}. 18Url: ${qn(e)}`),!0)}function md(e,t){return e.type||!t||!t.length?!1:Sd(e).some(n=>Ye(n,t))}function gd(e,t){if(e.type!=="transaction"||!t||!t.length)return!1;const n=e.transaction;return n?Ye(n,t):!1}function _d(e,t){if(!t||!t.length)return!1;const n=qn(e);return n?Ye(n,t):!1}function yd(e,t){if(!t||!t.length)return!0;const n=qn(e);return n?Ye(n,t):!0}function Sd(e){const t=[];e.message&&t.push(e.message);let n;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 Ed(e){try{return e.exception.values[0].type==="SentryError"}catch{}return!1}function bd(e=[]){for(let t=e.length-1;t>=0;t--){const n=e[t];if(n&&n.filename!=="<anonymous>"&&n.filename!=="[native code]")return n.filename||null}return null}function qn(e){try{let t;try{t=e.exception.values[0].stacktrace.frames}catch{}return t?bd(t):null}catch{return O&&y.error(`Cannot extract url for event ${We(e)}`),null}}function vd(e){return e.type||!e.exception||!e.exception.values||e.exception.values.length===0?!1:!e.message&&!e.exception.values.some(t=>t.stacktrace||t.type&&t.type!=="Error"||t.value)}function Td(e,t,n=250,r,s,i,o){if(!i.exception||!i.exception.values||!o||!Be(o.originalException,Error))return;const a=i.exception.values.length>0?i.exception.values[i.exception.values.length-1]:void 0;a&&(i.exception.values=Id(Qr(e,t,s,o.originalException,r,i.exception.values,a,0),n))}function Qr(e,t,n,r,s,i,o,a){if(i.length>=n+1)return i;let c=[...i];if(Be(r[s],Error)){Pi(o,a);const u=e(t,r[s]),d=c.length;Fi(u,s,d,a),c=Qr(e,t,n,r[s],s,[u,...c],u,d)}
18return Array.isArray(r.errors)&&r.errors.forEach((u,d)=>{if(Be(u,Error)){Pi(o,a);const l=e(t,u),f=c.length;Fi(l,`errors[${d}]`,f,a),c=Qr(e,t,n,u,s,[l,...c],l,f)}}),c}function Pi(e,t){e.mechanism=e.mechanism||{type:"generic",handled:!0},e.mechanism={...e.mechanism,...e.type==="AggregateError"&&{is_exception_group:!0},exception_id:t}}function Fi(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 Id(e,t){return e.map(n=>(n.value&&(n.value=Rt(n.value,t)),n))}function ft(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 wd(e){const t="console";tt(t,e),nt(t,kd)}function kd(){"console"in $&&Hr.forEach(function(e){e in $.console&&me($.console,e,function(t){return Hn[e]=t,function(...n){Se("console",{args:n,level:e});const s=Hn[e];s&&s.apply($.console,n)}})})}function Sa(e){return e==="warn"?"warning":["fatal","error","warning","log","info","debug"].includes(e)?e:"log"}const Cd="Dedupe",Rd=()=>{let e;return{name:Cd,processEvent(t){if(t.type)return t;try{if(xd(t,e))return O&&y.warn("Event dropped due to being a duplicate of previously captured event."),null}catch{}return e=t}}},Md=Rd;function xd(e,t){return t?!!(Ad(e,t)||Od(e,t)):!1}function Ad(e,t){const n=e.message,r=t.message;return!(!n&&!r||n&&!r||!n&&r||n!==r||!ba(e,t)||!Ea(e,t))}function Od(e,t){const n=Bi(t),r=Bi(e);return!(!n||!r||n.type!==r.type||n.value!==r.value||!ba(e,t)||!Ea(e,t))}function Ea(e,t){let n=ri(e),r=ri(t);if(!n&&!r)return!0;if(n&&!r||!n&&r||(n=n,r=r,r.length!==n.length))return!1;for(let s=0;s<r.length;s++){const i=r[s],o=n[s];if(i.filename!==o.filename||i.lineno!==o.lineno||i.colno!==o.colno||i.function!==o.function)return!1}return!0}function ba(e,t){let n=e.fingerprint,r=t.fingerprint;if(!n&&!r)return!0;if(n&&!r||!n&&r)return!1;n=n,r=r;try{return n.join("")===r.join("")}catch{return!1}}function Bi(e){return e.exception&&e.exception.values&&e.exception.values[0]}function Nd(e,t,n,r,s="auto.http.browser"){if(!e.fetchData)return;const i=Je()&&t(e.fetchData.url);if(e.endTimestamp&&i){const f=e.fetchData.__span;if(!f)return;const p=r[f];p&&(Pd(p,e),delete r[f]);return}const{method:o,url:a}=e.fetchData,c=Ld(a),u=c?ft(c).host:void 0,d=!!ie(),l=i&&d?un({name:`${o} ${a}`,attributes:{url:a,type:"fetch","http.method":o,"http.url":c,"server.address":u,[se]:s,[mt]:"http.client"}}):new Ht;if(e.fetchData.__span=l.spanContext().spanId,r[l.spanContext().spanId]=l,n(e.fetchData.url)){const f=e.args[0],p=e.args[1]||{},h=Dd(f,p,Je()&&d?l:void 0);h&&(e.args[1]=p,p.headers=h)}return l}function Dd(e,t,n){const r=ya({span:n}),s=r["sentry-trace"],i=r.baggage;if(!s)return;const o=t.headers||(Fd(e)?e.headers:void 0);if(o)if(Bd(o)){const a=new Headers(o);if(a.set("sentry-trace",s),i){const c=a.get("baggage");if(c){const u=Tn(c);a.set("baggage",u?`${u},${i}`:i)}else a.set("baggage",i)}return a}else if(Array.isArray(o)){const a=[...o.filter(c=>!(Array.isArray(c)&&c[0]==="sentry-trace")).map(c=>{if(Array.isArray(c)&&c[0]==="baggage"&&typeof c[1]=="string"){const[u,d,...l]=c;return[u,Tn(d),...l]}else return c}),["sentry-trace",s]];return i&&a.push(["baggage",i]),a}else{const a="baggage"in o?o.baggage:void 0;let c=[];return Array.isArray(a)?c=a.map(u=>typeof u=="string"?Tn(u):u).filter(u=>u===""):a&&c.push(Tn(a)),i&&c.push(i),{...o,"sentry-trace":s,baggage:c.length>0?c.join(","):void 0}}else return{...r}}function Ld(e){try{return new URL(e).href}catch{return}}function Pd(e,t){if(t.response){$o(e,t.response.status);const n=t.response&&t.response.headers&&t.response.headers.get("content-length");if(n){const r=parseInt(n);r>0&&e.setAttribute("http.response_content_length",r)}}else t.error&&e.setStatus({code:re,message:"internal_error"});e.end()}function Tn(e){return e.split(",").filter(t=>!t.split("=")[0].startsWith(Cs)).join(",")}function Fd(e){return typeof Request<"u"&&Be(e,Request)}function Bd(e){return typeof Headers<"u"&&Be(e,Headers)}function va(e){if(e!==void 0)return e>=400&&e<500?"warning":e>=500?"error":void 0}const Zr=$;function Ta(){if(!("fetch"in Zr))return!1;
18try{return new Headers,new Request("http://www.example.com"),new Response,!0}catch{return!1}}function es(e){return e&&/^function\s+\w+\(\)\s+\{\s+\[native code\]\s+\}$/.test(e.toString())}function $d(){if(typeof EdgeRuntime=="string")return!0;if(!Ta())return!1;if(es(Zr.fetch))return!0;let e=!1;const t=Zr.document;if(t&&typeof t.createElement=="function")try{const n=t.createElement("iframe");n.hidden=!0,t.head.appendChild(n),n.contentWindow&&n.contentWindow.fetch&&(e=es(n.contentWindow.fetch)),t.head.removeChild(n)}catch(n){Ze&&y.warn("Could not create sandbox iframe for pure fetch check, bailing to window.fetch: ",n)}return e}function Ia(e,t){const n="fetch";tt(n,e),nt(n,()=>wa(void 0,t))}function Ud(e){const t="fetch-body-resolved";tt(t,e),nt(t,()=>wa(Wd))}function wa(e,t=!1){t&&!$d()||me($,"fetch",function(n){return function(...r){const s=new Error,{method:i,url:o}=zd(r),a={args:r,fetchData:{method:i,url:o},startTimestamp:de()*1e3,virtualError:s};return e||Se("fetch",{...a}),n.apply($,r).then(async c=>(e?e(c):Se("fetch",{...a,endTimestamp:de()*1e3,response:c}),c),c=>{throw Se("fetch",{...a,endTimestamp:de()*1e3,error:c}),Es(c)&&c.stack===void 0&&(c.stack=s.stack,Ee(c,"framesToPop",1)),c})}})}async function Hd(e,t){if(e&&e.body){const n=e.body,r=n.getReader(),s=setTimeout(()=>{n.cancel().then(null,()=>{})},90*1e3);let i=!0;for(;i;){let o;try{o=setTimeout(()=>{n.cancel().then(null,()=>{})},5e3);const{done:a}=await r.read();clearTimeout(o),a&&(t(),i=!1)}catch{i=!1}finally{clearTimeout(o)}}clearTimeout(s),r.releaseLock(),n.cancel().then(null,()=>{})}}function Wd(e){let t;try{t=e.clone()}catch{return}Hd(t,()=>{Se("fetch-body-resolved",{endTimestamp:de()*1e3,response:e})})}function ts(e,t){return!!e&&typeof e=="object"&&!!e[t]}function $i(e){return typeof e=="string"?e:e?ts(e,"url")?e.url:e.toString?e.toString():"":""}function zd(e){if(e.length===0)return{method:"GET",url:""};if(e.length===2){const[n,r]=e;return{url:$i(n),method:ts(r,"method")?String(r.method).toUpperCase():"GET"}}const t=e[0];return{url:$i(t),method:ts(t,"method")?String(t.method).toUpperCase():"GET"}}function jd(){return typeof __SENTRY_BROWSER_BUNDLE__<"u"&&!!__SENTRY_BROWSER_BUNDLE__}function qd(){return"npm"}function Gd(){return!jd()&&Object.prototype.toString.call(typeof process<"u"?process:0)==="[object process]"}function Ui(){return typeof window<"u"&&(!Gd()||Yd())}function Yd(){const e=$.process;return!!e&&e.type==="renderer"}const In=$;function Vd(){const e=In.chrome,t=e&&e.app&&e.app.runtime,n="history"in In&&!!In.history.pushState&&!!In.history.replaceState;return!t&&n}function Xd(e,t){return e??t()}function Pn(e){let t,n=e[0],r=1;for(;r<e.length;){const s=e[r],i=e[r+1];if(r+=2,(s==="optionalAccess"||s==="optionalCall")&&n==null)return;s==="access"||s==="optionalAccess"?(t=n,n=i(n)):(s==="call"||s==="optionalCall")&&(n=i((...o)=>n.call(t,...o)),t=void 0)}return n}const A=$;let ns=0;function ka(){return ns>0}function Kd(){ns++,setTimeout(()=>{ns--})}function Nt(e,t={}){function n(s){return typeof s=="function"}if(!n(e))return e;try{const s=e.__sentry_wrapped__;if(s)return typeof s=="function"?s:e;if(Ts(e))return e}catch{return e}const r=function(...s){try{const i=s.map(o=>Nt(o,t));return e.apply(this,i)}catch(i){throw Kd(),ws(o=>{o.addEventProcessor(a=>(t.mechanism&&(zr(a,void 0),xt(a,t.mechanism)),a.extra={...a.extra,arguments:s},a)),aa(i)}),i}};try{for(const s in e)Object.prototype.hasOwnProperty.call(e,s)&&(r[s]=e[s])}catch{}No(r,e),Ee(e,"__sentry_wrapped__",r);try{Object.getOwnPropertyDescriptor(r,"name").configurable&&Object.defineProperty(r,"name",{get(){return e.name}})}catch{}return r}const xe=typeof __SENTRY_DEBUG__>"u"||__SENTRY_DEBUG__;function As(e,t){const n=Os(e,t),r={type:tf(t),value:nf(t)};return n.length&&(r.stacktrace={frames:n}),r.type===void 0&&r.value===""&&(r.value="Unrecoverable error caught"),r}function Jd(e,t,n,r){const s=B(),i=s&&s.getOptions().normalizeDepth,o=cf(t),a={__serialized__:ea(t,i)};if(o)return{exception:{values:[As(e,o)]},extra:a};const c={exception:{values:[{type:sr(t)?t.constructor.name:r?"UnhandledRejection":"Error",value:of(t,{isUnhandledRejection:r})}]},extra:a};if(n){const u=Os(e,n);u.length&&(c.exception.values[0].stacktrace={frames:u})}return c}function Mr(e,t){return{exception:{values:[As(e,t)]}}}function Os(e,t){const n=t.stacktrace||t.stack||"",r=Zd(t),s=ef(t);try{return e(n,r,s)}catch{}return[]}const Qd=/Minified React error #\d+;/i;function Zd(e){return e&&Qd.test(e.message)?1:0}function ef(e){return typeof e.framesToPop=="number"?e.framesToPop:0}function Ca(e){return typeof WebAssembly<"u"&&typeof WebAssembly.Exception<"u"?e instanceof WebAssembly.Exception:!1}function tf(e){const t=e&&e.name;return!t&&Ca(e)?e.message&&Array.isArray(e.message)&&e.message.length==2?e.message[0]:"WebAssembly.Exception":t}function nf(e){const t=e&&e.message;return t?t.error&&typeof t.error.message=="string"?t.error.message:Ca(e)&&Array.isArray(e.message)&&e.message.length==2?e.message[1]:t:"No error message"}function rf(e,t,n,r){const s=n&&n.syntheticException||void 0,i=Ns(e,t,s,r);return xt(i),i.level="error",n&&n.event_id&&(i.event_id=n.event_id),Ue(i)}function sf(e,t,n="info",r,s){const i=r&&r.syntheticException||void 0,o=rs(e,t,i,s);return o.level=n,r&&r.event_id&&(o.event_id=r.event_id),Ue(o)}
18function Ns(e,t,n,r,s){let i;if(Mo(t)&&t.error)return Mr(e,t.error);if(ii(t)||Kc(t)){const o=t;if("stack"in t)i=Mr(e,t);else{const a=o.name||(ii(o)?"DOMError":"DOMException"),c=o.message?`${a}: ${o.message}`:a;i=rs(e,c,n,r),zr(i,c)}return"code"in o&&(i.tags={...i.tags,"DOMException.code":`${o.code}`}),i}return Es(t)?Mr(e,t):Mt(t)||sr(t)?(i=Jd(e,t,n,s),xt(i,{synthetic:!0}),i):(i=rs(e,t,n,r),zr(i,`${t}`),xt(i,{synthetic:!0}),i)}function rs(e,t,n,r){const s={};if(r&&n){const i=Os(e,n);i.length&&(s.exception={values:[{value:t,stacktrace:{frames:i}}]}),xt(s,{synthetic:!0})}if(bs(t)){const{__sentry_template_string__:i,__sentry_template_values__:o}=t;return s.logentry={message:i,params:o},s}return s.message=t,s}function of(e,{isUnhandledRejection:t}){const n=su(e),r=t?"promise rejection":"exception";return Mo(e)?`Event \`ErrorEvent\` captured as ${r} with message \`${e.message}\``:sr(e)?`Event \`${af(e)}\` (type=${e.type}) captured as ${r}`:`Object captured as ${r} with keys: ${n}`}function af(e){try{const t=Object.getPrototypeOf(e);return t?t.constructor.name:void 0}catch{}}function cf(e){for(const t in e)if(Object.prototype.hasOwnProperty.call(e,t)){const n=e[t];if(n instanceof Error)return n}}function uf(e,{metadata:t,tunnel:n,dsn:r}){const s={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:cn(r)}},i=lf(e);return St(s,[i])}function lf(e){return[{type:"user_report"},e]}class df extends jl{constructor(t){const n={parentSpanIsAlwaysRootSpan:!0,...t},r=A.SENTRY_SDK_SOURCE||qd();_a(n,"browser",["browser"],r),super(n),n.sendClientReports&&A.document&&A.document.addEventListener("visibilitychange",()=>{A.document.visibilityState==="hidden"&&this._flushOutcomes()})}eventFromException(t,n){return rf(this._options.stackParser,t,n,this._options.attachStacktrace)}eventFromMessage(t,n="info",r){return sf(this._options.stackParser,t,n,r,this._options.attachStacktrace)}captureUserFeedback(t){if(!this._isEnabled()){xe&&y.warn("SDK not enabled, will not capture user feedback.");return}const n=uf(t,{metadata:this.getSdkMetadata(),dsn:this.getDsn(),tunnel:this.getOptions().tunnel});this.sendEnvelope(n)}_prepareEvent(t,n,r){return t.platform=t.platform||"javascript",super._prepareEvent(t,n,r)}}const Ds=typeof __SENTRY_DEBUG__>"u"||__SENTRY_DEBUG__,ff=(e,t)=>e>t[1]?"poor":e>t[0]?"needs-improvement":"good",Wt=(e,t,n,r)=>{let s,i;return o=>{t.value>=0&&(o||r)&&(i=t.value-(s||0),(i||s===void 0)&&(s=t.value,t.delta=i,t.rating=ff(t.value,n),e(t)))}},I=$,pf=()=>`v4-${Date.now()}-${Math.floor(Math.random()*(9e12-1))+1e12}`,ln=(e=!0)=>{const t=I.performance&&I.performance.getEntriesByType&&I.performance.getEntriesByType("navigation")[0];if(!e||t&&t.responseStart>0&&t.responseStart<performance.now())return t},dn=()=>{const e=ln();return e&&e.activationStart||0},zt=(e,t)=>{const n=ln();let r="navigate";return n&&(I.document&&I.document.prerendering||dn()>0?r="prerender":I.document&&I.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:pf(),navigationType:r}},Et=(e,t,n)=>{try{if(PerformanceObserver.supportedEntryTypes.includes(e)){const r=new PerformanceObserver(s=>{Promise.resolve().then(()=>{t(s.getEntries())})});return r.observe(Object.assign({type:e,buffered:!0},n||{})),r}}catch{}},jt=e=>{const t=n=>{(n.type==="pagehide"||I.document&&I.document.visibilityState==="hidden")&&e(n)};I.document&&(addEventListener("visibilitychange",t,!0),addEventListener("pagehide",t,!0))},ur=e=>{let t=!1;return()=>{t||(e(),t=!0)}};let Vt=-1;const hf=()=>I.document.visibilityState==="hidden"&&!I.document.prerendering?0:1/0,Gn=e=>{I.document.visibilityState==="hidden"&&Vt>-1&&(Vt=e.type==="visibilitychange"?e.timeStamp:0,gf())},mf=()=>{addEventListener("visibilitychange",Gn,!0),addEventListener("prerenderingchange",Gn,!0)},gf=()=>{removeEventListener("visibilitychange",Gn,!0),removeEventListener("prerenderingchange",Gn,!0)},lr=()=>(I.document&&Vt<0&&(Vt=hf(),mf()),{get firstHiddenTime(){return Vt}}),fn=e=>{I.document&&I.document.prerendering?addEventListener("prerenderingchange",()=>e(),!0):e()},_f=[1800,3e3],yf=(e,t={})=>{fn(()=>{const n=lr(),r=zt("FCP");let s;const o=Et("paint",a=>{a.forEach(c=>{c.name==="first-contentful-paint"&&(o.disconnect(),c.startTime<n.firstHiddenTime&&(r.value=Math.max(c.startTime-dn(),0),r.entries.push(c),s(!0)))})});o&&(s=Wt(e,r,_f,t.reportAllChanges))})},Sf=[.1,.25],Ef=(e,t={})=>{yf(ur(()=>{const n=zt("CLS",0);let r,s=0,i=[];const o=c=>
18{c.forEach(u=>{if(!u.hadRecentInput){const d=i[0],l=i[i.length-1];s&&d&&l&&u.startTime-l.startTime<1e3&&u.startTime-d.startTime<5e3?(s+=u.value,i.push(u)):(s=u.value,i=[u])}}),s>n.value&&(n.value=s,n.entries=i,r())},a=Et("layout-shift",o);a&&(r=Wt(e,n,Sf,t.reportAllChanges),jt(()=>{o(a.takeRecords()),r(!0)}),setTimeout(r,0))}))},bf=[100,300],vf=(e,t={})=>{fn(()=>{const n=lr(),r=zt("FID");let s;const i=c=>{c.startTime<n.firstHiddenTime&&(r.value=c.processingStart-c.startTime,r.entries.push(c),s(!0))},o=c=>{c.forEach(i)},a=Et("first-input",o);s=Wt(e,r,bf,t.reportAllChanges),a&&jt(ur(()=>{o(a.takeRecords()),a.disconnect()}))})};let Ra=0,xr=1/0,wn=0;const Tf=e=>{e.forEach(t=>{t.interactionId&&(xr=Math.min(xr,t.interactionId),wn=Math.max(wn,t.interactionId),Ra=wn?(wn-xr)/7+1:0)})};let ss;const If=()=>ss?Ra:performance.interactionCount||0,wf=()=>{"interactionCount"in performance||ss||(ss=Et("event",Tf,{type:"event",buffered:!0,durationThreshold:0}))},De=[],Ar=new Map,kf=40;let Cf=0;const Rf=()=>If()-Cf,Mf=()=>{const e=Math.min(De.length-1,Math.floor(Rf()/50));return De[e]},Or=10,xf=[],Af=e=>{if(xf.forEach(r=>r(e)),!(e.interactionId||e.entryType==="first-input"))return;const t=De[De.length-1],n=Ar.get(e.interactionId);if(n||De.length<Or||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 r={id:e.interactionId,latency:e.duration,entries:[e]};Ar.set(r.id,r),De.push(r)}De.sort((r,s)=>s.latency-r.latency),De.length>Or&&De.splice(Or).forEach(r=>Ar.delete(r.id))}},Ma=e=>{const t=I.requestIdleCallback||I.setTimeout;let n=-1;return e=ur(e),I.document&&I.document.visibilityState==="hidden"?e():(n=t(e),jt(e)),n},Of=[200,500],Nf=(e,t={})=>{"PerformanceEventTiming"in I&&"interactionId"in PerformanceEventTiming.prototype&&fn(()=>{wf();const n=zt("INP");let r;const s=o=>{Ma(()=>{o.forEach(Af);const a=Mf();a&&a.latency!==n.value&&(n.value=a.latency,n.entries=a.entries,r())})},i=Et("event",s,{durationThreshold:t.durationThreshold!=null?t.durationThreshold:kf});r=Wt(e,n,Of,t.reportAllChanges),i&&(i.observe({type:"first-input",buffered:!0}),jt(()=>{s(i.takeRecords()),r(!0)}))})},Df=[2500,4e3],Hi={},Lf=(e,t={})=>{fn(()=>{const n=lr(),r=zt("LCP");let s;const i=a=>{t.reportAllChanges||(a=a.slice(-1)),a.forEach(c=>{c.startTime<n.firstHiddenTime&&(r.value=Math.max(c.startTime-dn(),0),r.entries=[c],s())})},o=Et("largest-contentful-paint",i);if(o){s=Wt(e,r,Df,t.reportAllChanges);const a=ur(()=>{Hi[r.id]||(i(o.takeRecords()),o.disconnect(),Hi[r.id]=!0,s(!0))});["keydown","click"].forEach(c=>{I.document&&addEventListener(c,()=>Ma(a),{once:!0,capture:!0})}),jt(a)}})},Pf=[800,1800],is=e=>{I.document&&I.document.prerendering?fn(()=>is(e)):I.document&&I.document.readyState!=="complete"?addEventListener("load",()=>is(e),!0):setTimeout(e,0)},Ff=(e,t={})=>{const n=zt("TTFB"),r=Wt(e,n,Pf,t.reportAllChanges);is(()=>{const s=ln();s&&(n.value=Math.max(s.responseStart-dn(),0),n.entries=[s],r(!0))})},Xt={},Yn={};let xa,Aa,Oa,Na,Da;function Ls(e,t=!1){return pn("cls",e,$f,xa,t)}function La(e,t=!1){return pn("lcp",e,Hf,Oa,t)}function Pa(e){return pn("fid",e,Uf,Aa)}function Bf(e){return pn("ttfb",e,Wf,Na)}function Fa(e){return pn("inp",e,zf,Da)}function Dt(e,t){return Ba(e,t),Yn[e]||(jf(e),Yn[e]=!0),$a(e,t)}function qt(e,t){const n=Xt[e];if(!(!n||!n.length))for(const r of n)try{r(t)}catch(s){Ds&&y.error(`Error while triggering instrumentation handler. 19Type: ${e} 20Name: ${Fe(r)} 21Error:`,s)}}function $f(){return Ef(e=>{qt("cls",{metric:e}),xa=e},{reportAllChanges:!0})}function Uf(){return vf(e=>{qt("fid",{metric:e}),Aa=e})}function Hf(){return Lf(e=>{qt("lcp",{metric:e}),Oa=e},{reportAllChanges:!0})}function Wf(){return Ff(e=>{qt("ttfb",{metric:e}),Na=e})}function zf(){return Nf(e=>{qt("inp",{metric:e}),Da=e})}function pn(e,t,n,r,s=!1){Ba(e,t);let i;return Yn[e]||(i=n(),Yn[e]=!0),r&&t({metric:r}),$a(e,t,s?i:void 0)}function jf(e){const t={};e==="event"&&(t.durationThreshold=0),Et(e,n=>{qt(e,{entries:n})},t)}function Ba(e,t){Xt[e]=Xt[e]||[],Xt[e].push(t)}function $a(e,t,n){return()=>{n&&n();const r=Xt[e];if(!r)return;const s=r.indexOf(t);s!==-1&&r.splice(s,1)}}function qf(e){return"duration"in e}function Nr(e){return typeof e=="number"&&isFinite(e)}function He(e,t,n,{...r}){const s=z(e).start_timestamp;return s&&s>t&&typeof e.updateStartTime=="function"&&e.updateStartTime(t),ra(e,()=>
21{const i=un({startTime:t,...r});return i&&i.end(n),i})}function Ua(e){const t=B();if(!t)return;const{name:n,transaction:r,attributes:s,startTime:i}=e,{release:o,environment:a}=t.getOptions(),c=t.getIntegrationByName("Replay"),u=c&&c.getReplayId(),d=X(),l=d.getUser(),f=l!==void 0?l.email||l.id||l.ip_address:void 0;let p;try{p=d.getScopeData().contexts.profile.profile_id}catch{}const h={release:o,environment:a,user:f||void 0,profile_id:p||void 0,replay_id:u||void 0,transaction:r,"user_agent.original":I.navigator&&I.navigator.userAgent,...s};return un({name:n,attributes:h,startTime:i,experimental:{standalone:!0}})}function Ps(){return I&&I.addEventListener&&I.performance}function Z(e){return e/1e3}function Ha(e){let t="unknown",n="unknown",r="";for(const s of e){if(s==="/"){[t,n]=e.split("/");break}if(!isNaN(Number(s))){t=r==="h"?"http":r,n=e.split(r)[1];break}r+=s}return r===e&&(t=r),{name:t,version:n}}function Gf(){let e=0,t,n;if(!Vf())return;let r=!1;function s(){r||(r=!0,n&&Yf(e,t,n),i())}const i=Ls(({metric:o})=>{const a=o.entries[o.entries.length-1];a&&(e=o.value,t=a)},!0);jt(()=>{s()}),setTimeout(()=>{const o=B();if(!o)return;const a=o.on("startNavigationSpan",()=>{s(),a&&a()}),c=ie(),u=c&&ce(c),d=u&&z(u);d&&d.op==="pageload"&&(n=u.spanContext().spanId)},0)}function Yf(e,t,n){Ds&&y.log(`Sending CLS span (${e})`);const r=Z((fe||0)+(t&&t.startTime||0)),s=X().getScopeData().transactionName,i=t?$e(t.sources[0]&&t.sources[0].node):"Layout shift",o=te({[se]:"auto.http.browser.cls",[mt]:"ui.webvital.cls",[ks]:t&&t.duration||0,"sentry.pageload.span_id":n}),a=Ua({name:i,transaction:s,attributes:o,startTime:r});a&&(a.addEvent("cls",{[ar]:"",[cr]:e}),a.end(r))}function Vf(){try{return PerformanceObserver.supportedEntryTypes.includes("layout-shift")}catch{return!1}}const Xf=2147483647;let Wi=0,ae={},he,Kt;function Kf({recordClsStandaloneSpans:e}){const t=Ps();if(t&&fe){t.mark&&I.performance.mark("sentry-tracing-init");const n=np(),r=tp(),s=rp(),i=e?Gf():ep();return()=>{n(),r(),s(),i&&i()}}return()=>{}}function Jf(){Dt("longtask",({entries:e})=>{const t=ie();if(!t)return;const{op:n,start_timestamp:r}=z(t);for(const s of e){const i=Z(fe+s.startTime),o=Z(s.duration);n==="navigation"&&r&&i<r||He(t,i,i+o,{name:"Main UI thread blocked",op:"ui.long-task",attributes:{[se]:"auto.ui.browser.metrics"}})}})}function Qf(){new PerformanceObserver(t=>{const n=ie();if(n)for(const r of t.getEntries()){if(!r.scripts[0])continue;const s=Z(fe+r.startTime),{start_timestamp:i,op:o}=z(n);if(o==="navigation"&&i&&s<i)continue;const a=Z(r.duration),c={[se]:"auto.ui.browser.metrics"},u=r.scripts[0],{invoker:d,invokerType:l,sourceURL:f,sourceFunctionName:p,sourceCharPosition:h}=u;c["browser.script.invoker"]=d,c["browser.script.invoker_type"]=l,f&&(c["code.filepath"]=f),p&&(c["code.function"]=p),h!==-1&&(c["browser.script.source_char_position"]=h),He(n,s,s+a,{name:"Main UI thread blocked",op:"ui.long-animation-frame",attributes:c})}}).observe({type:"long-animation-frame",buffered:!0})}function Zf(){Dt("event",({entries:e})=>{const t=ie();if(t){for(const n of e)if(n.name==="click"){const r=Z(fe+n.startTime),s=Z(n.duration),i={name:$e(n.target),op:`ui.interaction.${n.name}`,startTime:r,attributes:{[se]:"auto.ui.browser.metrics"}},o=Oo(n.target);o&&(i.attributes["ui.component_name"]=o),He(t,r,r+s,i)}}})}function ep(){return Ls(({metric:e})=>{const t=e.entries[e.entries.length-1];t&&(ae.cls={value:e.value,unit:""},Kt=t)},!0)}function tp(){return La(({metric:e})=>{const t=e.entries[e.entries.length-1];t&&(ae.lcp={value:e.value,unit:"millisecond"},he=t)},!0)}function np(){return Pa(({metric:e})=>{const t=e.entries[e.entries.length-1];if(!t)return;const n=Z(fe),r=Z(t.startTime);ae.fid={value:e.value,unit:"millisecond"},ae["mark.fid"]={value:n+r,unit:"second"}})}function rp(){return Bf(({metric:e})=>{e.entries[e.entries.length-1]&&(ae.ttfb={value:e.value,unit:"millisecond"})})}function sp(e,t){const n=Ps();if(!n||!n.getEntries||!fe)return;const r=Z(fe),s=n.getEntries(),{op:i,start_timestamp:o}=z(e);if(s.slice(Wi).forEach(a=>{const c=Z(a.startTime),u=Z(Math.max(0,a.duration));if(!(i==="navigation"&&o&&r+c<o))switch(a.entryType){case"navigation":{op(e,a,r);break}case"mark":case"paint":case"measure":{ip(e,a,c,u,r);const d=lr(),l=a.startTime<d.firstHiddenTime;a.name==="first-paint"&&l&&(ae.fp={value:a.startTime,unit:"millisecond"}),a.name==="first-contentful-paint"&&l&&(ae.fcp={value:a.startTime,unit:"millisecond"});break}case"resource":{up(e,a,a.name,c,u,r);break}}}),Wi=Math.max(s.length-1,0),lp(e),i==="pageload"){fp(ae);const a=ae["mark.fid"];a&&ae.fid&&(He(e,a.value,a.value+Z(ae.fid.value),{name:"first input delay",op:"ui.action",attributes:{[se]:"auto.ui.browser.metrics"}}),delete ae["mark.fid"]),(!("fcp"in ae)||!t.recordClsOnPageloadSpan)&&delete ae.cls,Object.entries(ae).forEach(([c,u])=>{cl(c,u.value,u.unit)}),e.setAttribute("performance.timeOrigin",r),e.setAttribute("performance.activationStart",dn()),dp(e)}he=void 0,Kt=void 0,ae={}}
21function ip(e,t,n,r,s){const i=ln(!1),o=Z(i?i.requestStart:0),a=s+Math.max(n,o),c=s+n,u=c+r,d={[se]:"auto.resource.browser.metrics"};return a!==c&&(d["sentry.browser.measure_happened_before_request"]=!0,d["sentry.browser.measure_start_time"]=a),He(e,a,u,{name:t.name,op:t.entryType,attributes:d}),a}function op(e,t,n){["unloadEvent","redirect","domContentLoadedEvent","loadEvent","connect"].forEach(r=>{kn(e,t,r,n)}),kn(e,t,"secureConnection",n,"TLS/SSL"),kn(e,t,"fetch",n,"cache"),kn(e,t,"domainLookup",n,"DNS"),cp(e,t,n)}function kn(e,t,n,r,s=n){const i=ap(n),o=t[i],a=t[`${n}Start`];!a||!o||He(e,r+Z(a),r+Z(o),{op:`browser.${s}`,name:t.name,attributes:{[se]:"auto.ui.browser.metrics"}})}function ap(e){return e==="secureConnection"?"connectEnd":e==="fetch"?"domainLookupStart":`${e}End`}function cp(e,t,n){const r=n+Z(t.requestStart),s=n+Z(t.responseEnd),i=n+Z(t.responseStart);t.responseEnd&&(He(e,r,s,{op:"browser.request",name:t.name,attributes:{[se]:"auto.ui.browser.metrics"}}),He(e,i,s,{op:"browser.response",name:t.name,attributes:{[se]:"auto.ui.browser.metrics"}}))}function up(e,t,n,r,s,i){if(t.initiatorType==="xmlhttprequest"||t.initiatorType==="fetch")return;const o=ft(n),a={[se]:"auto.resource.browser.metrics"};Dr(a,t,"transferSize","http.response_transfer_size"),Dr(a,t,"encodedBodySize","http.response_content_length"),Dr(a,t,"decodedBodySize","http.decoded_response_content_length");const c=t.deliveryType;c!=null&&(a["http.response_delivery_type"]=c);const u=t.renderBlockingStatus;u&&(a["resource.render_blocking_status"]=u),o.protocol&&(a["url.scheme"]=o.protocol.split(":").pop()),o.host&&(a["server.address"]=o.host),a["url.same_origin"]=n.includes(I.location.origin);const{name:d,version:l}=Ha(t.nextHopProtocol);a["network.protocol.name"]=d,a["network.protocol.version"]=l;const f=i+r,p=f+s;He(e,f,p,{name:n.replace(I.location.origin,""),op:t.initiatorType?`resource.${t.initiatorType}`:"resource.other",attributes:a})}function lp(e){const t=I.navigator;if(!t)return;const n=t.connection;n&&(n.effectiveType&&e.setAttribute("effectiveConnectionType",n.effectiveType),n.type&&e.setAttribute("connectionType",n.type),Nr(n.rtt)&&(ae["connection.rtt"]={value:n.rtt,unit:"millisecond"})),Nr(t.deviceMemory)&&e.setAttribute("deviceMemory",`${t.deviceMemory} GB`),Nr(t.hardwareConcurrency)&&e.setAttribute("hardwareConcurrency",String(t.hardwareConcurrency))}function dp(e){he&&(he.element&&e.setAttribute("lcp.element",$e(he.element)),he.id&&e.setAttribute("lcp.id",he.id),he.url&&e.setAttribute("lcp.url",he.url.trim().slice(0,200)),he.loadTime!=null&&e.setAttribute("lcp.loadTime",he.loadTime),he.renderTime!=null&&e.setAttribute("lcp.renderTime",he.renderTime),e.setAttribute("lcp.size",he.size)),Kt&&Kt.sources&&Kt.sources.forEach((t,n)=>e.setAttribute(`cls.source.${n+1}`,$e(t.node)))}function Dr(e,t,n,r){const s=t[n];s!=null&&s<Xf&&(e[r]=s)}function fp(e){const t=ln(!1);if(!t)return;const{responseStart:n,requestStart:r}=t;r<=n&&(e["ttfb.requestTime"]={value:n-r,unit:"millisecond"})}const pp=1e3;let zi,os,as;function Wa(e){const t="dom";tt(t,e),nt(t,hp)}function hp(){if(!I.document)return;const e=Se.bind(null,"dom"),t=ji(e,!0);I.document.addEventListener("click",t,!1),I.document.addEventListener("keypress",t,!1),["EventTarget","Node"].forEach(n=>{const s=I[n],i=s&&s.prototype;!i||!i.hasOwnProperty||!i.hasOwnProperty("addEventListener")||(me(i,"addEventListener",function(o){return function(a,c,u){if(a==="click"||a=="keypress")try{const d=this.__sentry_instrumentation_handlers__=this.__sentry_instrumentation_handlers__||{},l=d[a]=d[a]||{refCount:0};if(!l.handler){const f=ji(e);l.handler=f,o.call(this,a,f,u)}l.refCount++}catch{}return o.call(this,a,c,u)}}),me(i,"removeEventListener",function(o){return function(a,c,u){if(a==="click"||a=="keypress")try{const d=this.__sentry_instrumentation_handlers__||{},l=d[a];l&&(l.refCount--,l.refCount<=0&&(o.call(this,a,l.handler,u),l.handler=void 0,delete d[a]),Object.keys(d).length===0&&delete this.__sentry_instrumentation_handlers__)}catch{}return o.call(this,a,c,u)}}))})}function mp(e){if(e.type!==os)return!1;try{if(!e.target||e.target._sentryId!==as)return!1}catch{}return!0}function gp(e,t){return e!=="keypress"?!1:!t||!t.tagName?!0:!(t.tagName==="INPUT"||t.tagName==="TEXTAREA"||t.isContentEditable)}function ji(e,t=!1){return n=>{if(!n||n._sentryCaptured)return;const r=_p(n);if(gp(n.type,r))return;Ee(n,"_sentryCaptured",!0),r&&!r._sentryId&&Ee(r,"_sentryId",_e());
21const s=n.type==="keypress"?"input":n.type;mp(n)||(e({event:n,name:s,global:t}),os=n.type,as=r?r._sentryId:void 0),clearTimeout(zi),zi=I.setTimeout(()=>{as=void 0,os=void 0},pp)}}function _p(e){try{return e.target}catch{return null}}let Cn;function dr(e){const t="history";tt(t,e),nt(t,yp)}function yp(){if(!Vd())return;const e=I.onpopstate;I.onpopstate=function(...n){const r=I.location.href,s=Cn;if(Cn=r,Se("history",{from:s,to:r}),e)try{return e.apply(this,n)}catch{}};function t(n){return function(...r){const s=r.length>2?r[2]:void 0;if(s){const i=Cn,o=String(s);Cn=o,Se("history",{from:i,to:o})}return n.apply(this,r)}}me(I.history,"pushState",t),me(I.history,"replaceState",t)}const Fn={};function za(e){const t=Fn[e];if(t)return t;let n=I[e];if(es(n))return Fn[e]=n.bind(I);const r=I.document;if(r&&typeof r.createElement=="function")try{const s=r.createElement("iframe");s.hidden=!0,r.head.appendChild(s);const i=s.contentWindow;i&&i[e]&&(n=i[e]),r.head.removeChild(s)}catch(s){Ds&&y.warn(`Could not create sandbox iframe for ${e} check, bailing to window.${e}: `,s)}return n&&(Fn[e]=n.bind(I))}function qi(e){Fn[e]=void 0}function Lt(...e){return za("setTimeout")(...e)}const at="__sentry_xhr_v3__";function ja(e){const t="xhr";tt(t,e),nt(t,Sp)}function Sp(){if(!I.XMLHttpRequest)return;const e=XMLHttpRequest.prototype;e.open=new Proxy(e.open,{apply(t,n,r){const s=new Error,i=de()*1e3,o=Le(r[0])?r[0].toUpperCase():void 0,a=Ep(r[1]);if(!o||!a)return t.apply(n,r);n[at]={method:o,url:a,request_headers:{}},o==="POST"&&a.match(/sentry_key/)&&(n.__sentry_own_request__=!0);const c=()=>{const u=n[at];if(u&&n.readyState===4){try{u.status_code=n.status}catch{}const d={endTimestamp:de()*1e3,startTimestamp:i,xhr:n,virtualError:s};Se("xhr",d)}};return"onreadystatechange"in n&&typeof n.onreadystatechange=="function"?n.onreadystatechange=new Proxy(n.onreadystatechange,{apply(u,d,l){return c(),u.apply(d,l)}}):n.addEventListener("readystatechange",c),n.setRequestHeader=new Proxy(n.setRequestHeader,{apply(u,d,l){const[f,p]=l,h=d[at];return h&&Le(f)&&Le(p)&&(h.request_headers[f.toLowerCase()]=p),u.apply(d,l)}}),t.apply(n,r)}}),e.send=new Proxy(e.send,{apply(t,n,r){const s=n[at];if(!s)return t.apply(n,r);r[0]!==void 0&&(s.body=r[0]);const i={startTimestamp:de()*1e3,xhr:n};return Se("xhr",i),t.apply(n,r)}})}function Ep(e){if(Le(e))return e;try{return e.toString()}catch{}}const Lr=[],Bn=new Map;function bp(){if(Ps()&&fe){const t=vp();return()=>{t()}}return()=>{}}const Gi={click:"click",pointerdown:"click",pointerup:"click",mousedown:"click",mouseup:"click",touchstart:"click",touchend:"click",mouseover:"hover",mouseout:"hover",mouseenter:"hover",mouseleave:"hover",pointerover:"hover",pointerout:"hover",pointerenter:"hover",pointerleave:"hover",dragstart:"drag",dragend:"drag",drag:"drag",dragenter:"drag",dragleave:"drag",dragover:"drag",drop:"drag",keydown:"press",keyup:"press",keypress:"press",input:"press"};function vp(){return Fa(({metric:e})=>{if(e.value==null)return;const t=e.entries.find(h=>h.duration===e.value&&Gi[h.name]);if(!t)return;const{interactionId:n}=t,r=Gi[t.name],s=Z(fe+t.startTime),i=Z(e.value),o=ie(),a=o?ce(o):void 0,u=(n!=null?Bn.get(n):void 0)||a,d=u?z(u).description:X().getScopeData().transactionName,l=$e(t.target),f=te({[se]:"auto.http.browser.inp",[mt]:`ui.interaction.${r}`,[ks]:t.duration}),p=Ua({name:l,transaction:d,attributes:f,startTime:s});p&&(p.addEvent("inp",{[ar]:"millisecond",[cr]:e.value}),p.end(s+i))})}function Tp(e){const t=({entries:n})=>{const r=ie(),s=r&&ce(r);n.forEach(i=>{if(!qf(i)||!s)return;const o=i.interactionId;if(o!=null&&!Bn.has(o)){if(Lr.length>10){const a=Lr.shift();Bn.delete(a)}Lr.push(o),Bn.set(o,s)}})};Dt("event",t),Dt("first-input",t)}function Ip(e,t=za("fetch")){let n=0,r=0;function s(i){const o=i.body.length;n+=o,r++;const a={body:i.body,method:"POST",referrerPolicy:"origin",headers:e.headers,keepalive:n<=6e4&&r<15,...e.fetchOptions};if(!t)return qi("fetch"),Wn("No fetch implementation available");try{return t(e.url,a).then(c=>(n-=o,r--,{statusCode:c.status,headers:{"x-sentry-rate-limits":c.headers.get("X-Sentry-Rate-Limits"),"retry-after":c.headers.get("Retry-After")}}))}catch(c){return qi("fetch"),n-=o,r--,Wn(c)}}return ed(e,s)}const wp=30,kp=50;function cs(e,t,n,r){const s={filename:e,function:t==="<anonymous>"?pt:t,in_app:!0};return n!==void 0&&(s.lineno=n),r!==void 0&&(s.colno=r),s}
vendor: 4,670 bytes, line 21
21const Cp=/^\s*at (\S+?)(?::(\d+))(?::(\d+))\s*$/i,Rp=/^\s*at (?:(.+?\)(?: \[.+\])?|.*?) ?\((?:address at )?)?(?:async )?((?:<anonymous>|[-a-z]+:|.*bundle|\/)?.*?)(?::(\d+))?(?::(\d+))?\)?\s*$/i,Mp=/\((\S*)(?::(\d+))(?::(\d+))\)/,xp=e=>{const t=Cp.exec(e);if(t){const[,r,s,i]=t;return cs(r,pt,+s,+i)}const n=Rp.exec(e);if(n){if(n[2]&&n[2].indexOf("eval")===0){const o=Mp.exec(n[2]);o&&(n[2]=o[1],n[3]=o[2],n[4]=o[3])}const[s,i]=qa(n[1]||pt,n[2]);return cs(i,s,n[3]?+n[3]:void 0,n[4]?+n[4]:void 0)}},Ap=[wp,xp],Op=/^\s*(.*?)(?:\((.*?)\))?(?:^|@)?((?:[-a-z]+)?:\/.*?|\[native code\]|[^@]*(?:bundle|\d+\.js)|\/[\w\-. /=]+)(?::(\d+))?(?::(\d+))?\s*$/i,Np=/(\S+) line (\d+)(?: > eval line \d+)* > eval/i,Dp=e=>{const t=Op.exec(e);if(t){if(t[3]&&t[3].indexOf(" > eval")>-1){const i=Np.exec(t[3]);i&&(t[1]=t[1]||"eval",t[3]=i[1],t[4]=i[2],t[5]="")}let r=t[3],s=t[1]||pt;return[s,r]=qa(s,r),cs(r,s,t[4]?+t[4]:void 0,t[5]?+t[5]:void 0)}},Lp=[kp,Dp],Pp=[Ap,Lp],Fp=wo(...Pp),qa=(e,t)=>{const n=e.indexOf("safari-extension")!==-1,r=e.indexOf("safari-web-extension")!==-1;return n||r?[e.indexOf("@")!==-1?e.split("@")[0]:pt,n?`safari-extension:${t}`:`safari-web-extension:${t}`]:[e,t]},Rn=1024,Bp="Breadcrumbs",$p=(e={})=>{const t={console:!0,dom:!0,fetch:!0,history:!0,sentry:!0,xhr:!0,...e};return{name:Bp,setup(n){t.console&&wd(zp(n)),t.dom&&Wa(Wp(n,t.dom)),t.xhr&&ja(jp(n)),t.fetch&&Ia(qp(n)),t.history&&dr(Gp(n)),t.sentry&&n.on("beforeSendEvent",Hp(n))}}},Up=$p;function Hp(e){return function(n){B()===e&&Qe({category:`sentry.${n.type==="transaction"?"transaction":"event"}`,event_id:n.event_id,level:n.level,message:We(n)},{event:n})}}function Wp(e,t){return function(r){if(B()!==e)return;let s,i,o=typeof t=="object"?t.serializeAttribute:void 0,a=typeof t=="object"&&typeof t.maxStringLength=="number"?t.maxStringLength:void 0;a&&a>Rn&&(xe&&y.warn(`\`dom.maxStringLength\` cannot exceed ${Rn}, but a value of ${a} was configured. Sentry will use ${Rn} instead.`),a=Rn),typeof o=="string"&&(o=[o]);try{const u=r.event,d=Yp(u)?u.target:u;s=$e(d,{keyAttrs:o,maxStringLength:a}),i=Oo(d)}catch{s="<unknown>"}if(s.length===0)return;const c={category:`ui.${r.name}`,message:s};i&&(c.data={"ui.component_name":i}),Qe(c,{event:r.event,name:r.name,global:r.global})}}function zp(e){return function(n){if(B()!==e)return;const r={category:"console",data:{arguments:n.args,logger:"console"},level:Sa(n.level),message:oi(n.args," ")};if(n.level==="assert")if(n.args[0]===!1)r.message=`Assertion failed: ${oi(n.args.slice(1)," ")||"console.assert"}`,r.data.arguments=n.args.slice(1);else return;Qe(r,{input:n.args,level:n.level})}}function jp(e){return function(n){if(B()!==e)return;const{startTimestamp:r,endTimestamp:s}=n,i=n.xhr[at];if(!r||!s||!i)return;const{method:o,url:a,status_code:c,body:u}=i,d={method:o,url:a,status_code:c},l={xhr:n.xhr,input:u,startTimestamp:r,endTimestamp:s},f=va(c);Qe({category:"xhr",data:d,type:"http",level:f},l)}}function qp(e){return function(n){if(B()!==e)return;const{startTimestamp:r,endTimestamp:s}=n;if(s&&!(n.fetchData.url.match(/sentry_key/)&&n.fetchData.method==="POST"))if(n.error){const i=n.fetchData,o={data:n.error,input:n.args,startTimestamp:r,endTimestamp:s};Qe({category:"fetch",data:i,level:"error",type:"http"},o)}else{const i=n.response,o={...n.fetchData,status_code:i&&i.status},a={input:n.args,response:i,startTimestamp:r,endTimestamp:s},c=va(o.status_code);Qe({category:"fetch",data:o,type:"http",level:c},a)}}}function Gp(e){return function(n){if(B()!==e)return;let r=n.from,s=n.to;const i=ft(A.location.href);let o=r?ft(r):void 0;const a=ft(s);(!o||!o.path)&&(o=i),i.protocol===a.protocol&&i.host===a.host&&(s=a.relative),i.protocol===o.protocol&&i.host===o.host&&(r=o.relative),Qe({category:"navigation",data:{from:r,to:s}})}}function Yp(e){return!!e&&!!e.target}const Vp=["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"],Xp="BrowserApiErrors",Kp=(e={})=>{const t={XMLHttpRequest:!0,eventTarget:!0,requestAnimationFrame:!0,setInterval:!0,setTimeout:!0,...e};return{name:Xp,setupOnce(){t.setTimeout&&me(A,"setTimeout",Yi),t.setInterval&&me(A,"setInterval",Yi),t.requestAnimationFrame&&me(A,"requestAnimationFrame",Qp),t.XMLHttpRequest&&"XMLHttpRequest"in A&&me(XMLHttpRequest.prototype,"send",Zp
21);const n=t.eventTarget;n&&(Array.isArray(n)?n:Vp).forEach(eh)}}},Jp=Kp;function Yi(e){return function(...t){const n=t[0];return t[0]=Nt(n,{mechanism:{data:{function:Fe(e)},handled:!1,type:"instrument"}}),e.apply(this,t)}}function Qp(e){return function(t){return e.apply(this,[Nt(t,{mechanism:{data:{function:"requestAnimationFrame",handler:Fe(e)},handled:!1,type:"instrument"}})])}}function Zp(e){return function(...t){const n=this;return["onload","onerror","onprogress","onreadystatechange"].forEach(s=>{s in n&&typeof n[s]=="function"&&me(n,s,function(i){const o={mechanism:{data:{function:s,handler:Fe(i)},handled:!1,type:"instrument"}},a=Ts(i);return a&&(o.mechanism.data.handler=Fe(a)),Nt(i,o)})}),e.apply(this,t)}}function eh(e){const n=A[e],r=n&&n.prototype;!r||!r.hasOwnProperty||!r.hasOwnProperty("addEventListener")||(me(r,"addEventListener",function(s){return function(i,o,a){try{th(o)&&(o.handleEvent=Nt(o.handleEvent,{mechanism:{data:{function:"handleEvent",handler:Fe(o),target:e},handled:!1,type:"instrument"}}))}catch{}return s.apply(this,[i,Nt(o,{mechanism:{data:{function:"addEventListener",handler:Fe(o),target:e},handled:!1,type:"instrument"}}),a])}}),me(r,"removeEventListener",function(s){return function(i,o,a){try{const c=o.__sentry_wrapped__;c&&s.call(this,i,c,a)}catch{}return s.call(this,i,o,a)}}))}function th(e){return typeof e.handleEvent=="function"}const nh=()=>({name:"BrowserSession",setupOnce(){if(typeof A.document>"u"){xe&&y.warn("Using the `browserSessionIntegration` in non-browser environments is not supported.");return}Ci({ignoreDuration:!0}),Ri(),dr(({from:e,to:t})=>{e!==void 0&&e!==t&&(Ci({ignoreDuration:!0}),Ri())})}}),rh="GlobalHandlers",sh=(e={})=>{const t={onerror:!0,onunhandledrejection:!0,...e};return{name:rh,setupOnce(){Error.stackTraceLimit=50},setup(n){t.onerror&&(oh(n),Vi("onerror")),t.onunhandledrejection&&(ah(n),Vi("onunhandledrejection"))}}},ih=sh;function oh(e){ko(t=>{const{stackParser:n,attachStacktrace:r}=Ga();if(B()!==e||ka())return;const{msg:s,url:i,line:o,column:a,error:c}=t,u=lh(Ns(n,c||s,void 0,r,!1),i,o,a);u.level="error",ca(u,{originalException:c,mechanism:{handled:!1,type:"onerror"}})})}function ah(e){Co(t=>{const{stackParser:n,attachStacktrace:r}=Ga();if(B()!==e||ka())return;const s=ch(t),i=vs(s)?uh(s):Ns(n,s,void 0,r,!0);i.level="error",ca(i,{originalException:s,mechanism:{handled:!1,type:"onunhandledrejection"}})})}function ch(e){if(vs(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 uh(e){return{exception:{values:[{type:"UnhandledRejection",value:`Non-Error promise rejection captured with value: ${String(e)}`}]}}}function lh(e,t,n,r){const s=e.exception=e.exception||{},i=s.values=s.values||[],o=i[0]=i[0]||{},a=o.stacktrace=o.stacktrace||{},c=a.frames=a.frames||[],u=r,d=n,l=Le(t)&&t.length>0?t:Ao();return c.length===0&&c.push({colno:u,filename:l,function:pt,in_app:!0,lineno:d}),e}function Vi(e){xe&&y.log(`Global Handler attached: ${e}`)}function Ga(){const e=B();return e&&e.getOptions()||{stackParser:()=>[],attachStacktrace:!1}}const dh=()=>({name:"HttpContext",preprocessEvent(e){if(!A.navigator&&!A.location&&!A.document)return;const t=e.request&&e.request.url||A.location&&A.location.href,{referrer:n}=A.document||{},{userAgent:r}=A.navigator||{},s={...e.request&&e.request.headers,...n&&{Referer:n},...r&&{"User-Agent":r}},i={...e.request,...t&&{url:t},headers:s};e.request=i}}),fh="cause",ph=5,hh="LinkedErrors",mh=(e={})=>{const t=e.limit||ph,n=e.key||fh;return{name:hh,preprocessEvent(r,s,i){const o=i.getOptions();Td(As,o.stackParser,o.maxValueLength,n,t,r,s)}}},gh=mh;function _h(e){const t=[fd(),cd(),Jp(),Up(),ih(),gh(),Md(),dh()];return e.autoSessionTracking!==!1&&t.push(nh()),t}function yh(e={}){const t={defaultIntegrations:_h(e),release:typeof __SENTRY_RELEASE__=="string"?__SENTRY_RELEASE__:A.SENTRY_RELEASE&&A.SENTRY_RELEASE.id?A.SENTRY_RELEASE.id:void 0,autoSessionTracking:!0,sendClientReports:!0};return e.defaultIntegrations==null&&delete e.defaultIntegrations,{...t,...e}}function Sh(){const e=typeof A.window<"u"&&A;if(!e)return!1;const t=e.chrome?"chrome":"browser",n=e[t],r=n&&n.runtime&&n.runtime.id,s=A.location&&A.location.href||"",i=["chrome-extension:","moz-extension:","ms-browser-extension:","safari-web-extension:"],o=!!r&&A===A.top&&i.some(c=>s.startsWith(`${c}//`)),a=typeof e.nw<"u";return!!r&&!o&&!a}function Eh(e={}){const t=yh(e);if(!t.skipBrowserExtensionCheck&&Sh()){et(()=>{console.error("[Sentry] You cannot run Sentry this way in a browser extension, check: https://docs.sentry.io/platforms/javascript/best-practices/browser-extensions/")});return}xe&&(Ta()||y.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:Gc(t.stackParser||Fp),integrations:Hl(t),transport:t.transport||Ip};return Yl(df,n)}const V=$,Fs="sentryReplaySession",bh="replay_event",Bs="Unable to send Replay",vh=3e5,Th=9e5,Ih=5e3,wh=5500,kh=6e4,Ch=5e3,Rh=3,Xi=15e4,Mn=5e3,Mh=3e3,xh=300,$s=2e7,Ah=4999,Oh=15e3,Ki=36e5;function us(e,t){return e??t()}function tn(e){let t,n=e[0],r=1;for(;r<e.length;){const s=e[r],i=e[r+1];if(r+=2,(s==="optionalAccess"||s==="optionalCall")&&n==null)return;s==="access"||s==="optionalAccess"?(t=n,n=i(n)):(s==="call"||s==="optionalCall")&&(n=i((...o)=>n.call(t,...o)),t=void 0)}return n}var ee;(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"})(ee||(ee={}));
21function Nh(e){return e.nodeType===e.ELEMENT_NODE}function Jt(e){const t=tn([e,"optionalAccess",n=>n.host]);return tn([t,"optionalAccess",n=>n.shadowRoot])===e}function Qt(e){return Object.prototype.toString.call(e)==="[object ShadowRoot]"}function Dh(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 Lh(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 Vn(e){try{const t=e.rules||e.cssRules;return t?Dh(Array.from(t,Ya).join("")):null}catch{return null}}function Ph(e){let t="";for(let n=0;n<e.style.length;n++){const r=e.style,s=r[n],i=r.getPropertyPriority(s);t+=`${s}:${r.getPropertyValue(s)}${i?" !important":""};`}return`${e.selectorText} { ${t} }`}function Ya(e){let t;if(Bh(e))try{t=Vn(e.styleSheet)||Lh(e)}catch{}else if($h(e)){let n=e.cssText;const r=e.selectorText.includes(":"),s=typeof e.style.all=="string"&&e.style.all;if(s&&(n=Ph(e)),r&&(n=Fh(n)),r||s)return n}return t||e.cssText}function Fh(e){const t=/(\[(?:[\w-]+)[^\\])(:(?:[\w-]+)\])/gm;return e.replace(t,"$1\\$2")}function Bh(e){return"styleSheet"in e}function $h(e){return"selectorText"in e}class Va{constructor(){this.idNodeMap=new Map,this.nodeMetaMap=new WeakMap}getId(t){if(!t)return-1;const n=tn([this,"access",r=>r.getMeta,"call",r=>r(t),"optionalAccess",r=>r.id]);return us(n,()=>-1)}getNode(t){return this.idNodeMap.get(t)||null}getIds(){return Array.from(this.idNodeMap.keys())}getMeta(t){return this.nodeMetaMap.get(t)||null}removeNodeFromMap(t){const n=this.getId(t);this.idNodeMap.delete(n),t.childNodes&&t.childNodes.forEach(r=>this.removeNodeFromMap(r))}has(t){return this.idNodeMap.has(t)}hasNode(t){return this.nodeMetaMap.has(t)}add(t,n){const r=n.id;this.idNodeMap.set(r,t),this.nodeMetaMap.set(t,n)}replace(t,n){const r=this.getNode(t);if(r){const s=this.nodeMetaMap.get(r);s&&this.nodeMetaMap.set(n,s)}this.idNodeMap.set(t,n)}reset(){this.idNodeMap=new Map,this.nodeMetaMap=new WeakMap}}function Uh(){return new Va}function fr({maskInputOptions:e,tagName:t,type:n}){return t==="OPTION"&&(t="SELECT"),!!(e[t.toLowerCase()]||n&&e[n]||n==="password"||t==="INPUT"&&!n&&e.text)}function nn({isMasked:e,element:t,value:n,maskInputFn:r}){let s=n||"";return e?(r&&(s=r(s,t)),"*".repeat(s.length)):s}function Pt(e){return e.toLowerCase()}function ls(e){return e.toUpperCase()}const Ji="__rrweb_original__";function Hh(e){const t=e.getContext("2d");if(!t)return!0;const n=50;for(let r=0;r<e.width;r+=n)for(let s=0;s<e.height;s+=n){const i=t.getImageData,o=Ji in i?i[Ji]:i;if(new Uint32Array(o.call(t,r,s,Math.min(n,e.width-r),Math.min(n,e.height-s)).data.buffer).some(c=>c!==0))return!1}return!0}function Us(e){const t=e.type;return e.hasAttribute("data-rr-is-password")?"password":t?Pt(t):null}function Xn(e,t,n){return t==="INPUT"&&(n==="radio"||n==="checkbox")?e.getAttribute("value")||"":e.value}function Xa(e,t){let n;try{n=new URL(e,us(t,()=>window.location.href))}catch{return null}const r=/\.([0-9a-z]+)(?:$)/i,s=n.pathname.match(r);return us(tn([s,"optionalAccess",i=>i[1]]),()=>null)}const Qi={};function Ka(e){const t=Qi[e];if(t)return t;const n=window.document;let r=window[e];if(n&&typeof n.createElement=="function")try{const s=n.createElement("iframe");s.hidden=!0,n.head.appendChild(s);const i=s.contentWindow;i&&i[e]&&(r=i[e]),n.head.removeChild(s)}catch{}return Qi[e]=r.bind(window)}function ds(...e){return Ka("setTimeout")(...e)}function Ja(...e){return Ka("clearTimeout")(...e)}function Qa(e){try{return e.contentDocument}catch{}}let Wh=1;const zh=new RegExp("[^a-z0-9-_:]"),rn=-2;function Hs(){return Wh++}function jh(e){if(e instanceof HTMLFormElement)return"form";const t=Pt(e.tagName);return zh.test(t)?"div":t}function qh(e){let t="";return e.indexOf("//")>-1?t=e.split("/").slice(0,3).join("/"):t=e.split("/")[0],t=t.split("?")[0],t}let bt,Zi;const Gh=/url\((?:(')([^']*)'|(")(.*?)"|([^)]*))\)/gm,Yh=/^(?:[a-z+]+:)?\/\//i,Vh=/^www\..*/i,Xh=/^(data:)([^,]*),(.*)/i;function Kn(e,t){return(e||"").replace(Gh,(n,r,s,i,o,a)=>{const c=s||o||a,u=r||i||"";if(!c)return n;if(Yh.test(c)||Vh.test(c))return`url(${u}${c}${u})`;if(Xh.test(c))return`url(${u}${c}${u})`;if(c[0]==="/")return`url(${u}${qh(t)+c}${u})`;const d=t.split("/"),l=c.split("/");d.pop();for(const f of l)f!=="."&&(f===".."?d.pop():d.push(f));return`url(${u}${d.join("/")}${u})`})}const Kh=/^[^ \t\n\r\u000c]+/,Jh=/^[, \t\n\r\u000c]+/;function Qh(e,t){if(t.trim()==="")return t;let n=0;function r(i){let o;const a=i.exec(t.substring(n));return a?(o=a[0],n+=o.length,o):""}const s=[];for(;r(Jh),!(n>=t.length);){let i=r(Kh);if(i.slice(-1)===",")i=Tt(e,i.substring(0,i.length-1)),s.push(i);else{let o="";
21i=Tt(e,i);let a=!1;for(;;){const c=t.charAt(n);if(c===""){s.push((i+o).trim());break}else if(a)c===")"&&(a=!1);else if(c===","){n+=1,s.push((i+o).trim());break}else c==="("&&(a=!0);o+=c,n+=1}}}return s.join(", ")}const eo=new WeakMap;function Tt(e,t){return!t||t.trim()===""?t:pr(e,t)}function Zh(e){return!!(e.tagName==="svg"||e.ownerSVGElement)}function pr(e,t){let n=eo.get(e);if(n||(n=e.createElement("a"),eo.set(e,n)),!t)t="";else if(t.startsWith("blob:")||t.startsWith("data:"))return t;return n.setAttribute("href",t),n.href}function Za(e,t,n,r,s,i){return r&&(n==="src"||n==="href"&&!(t==="use"&&r[0]==="#")||n==="xlink:href"&&r[0]!=="#"||n==="background"&&(t==="table"||t==="td"||t==="th")?Tt(e,r):n==="srcset"?Qh(e,r):n==="style"?Kn(r,pr(e)):t==="object"&&n==="data"?Tt(e,r):typeof i=="function"?i(n,r,s):r)}function ec(e,t,n){return(e==="video"||e==="audio")&&t==="autoplay"}function em(e,t,n,r){try{if(r&&e.matches(r))return!1;if(typeof t=="string"){if(e.classList.contains(t))return!0}else for(let s=e.classList.length;s--;){const i=e.classList[s];if(t.test(i))return!0}if(n)return e.matches(n)}catch{}return!1}function tm(e,t){for(let n=e.classList.length;n--;){const r=e.classList[n];if(t.test(r))return!0}return!1}function ct(e,t,n=1/0,r=0){return!e||e.nodeType!==e.ELEMENT_NODE||r>n?-1:t(e)?r:ct(e.parentNode,t,n,r+1)}function It(e,t){return n=>{const r=n;if(r===null)return!1;try{if(e){if(typeof e=="string"){if(r.matches(`.${e}`))return!0}else if(tm(r,e))return!0}return!!(t&&r.matches(t))}catch{return!1}}}function Ft(e,t,n,r,s,i){try{const o=e.nodeType===e.ELEMENT_NODE?e:e.parentElement;if(o===null)return!1;if(o.tagName==="INPUT"){const u=o.getAttribute("autocomplete");if(["current-password","new-password","cc-number","cc-exp","cc-exp-month","cc-exp-year","cc-csc"].includes(u))return!0}let a=-1,c=-1;if(i){if(c=ct(o,It(r,s)),c<0)return!0;a=ct(o,It(t,n),c>=0?c:1/0)}else{if(a=ct(o,It(t,n)),a<0)return!1;c=ct(o,It(r,s),a>=0?a:1/0)}return a>=0?c>=0?a<=c:!0:c>=0?!1:!!i}catch{}return!!i}function nm(e,t,n){const r=e.contentWindow;if(!r)return;let s=!1,i;try{i=r.document.readyState}catch{return}if(i!=="complete"){const a=ds(()=>{s||(t(),s=!0)},n);e.addEventListener("load",()=>{Ja(a),s=!0,t()});return}const o="about:blank";if(r.location.href!==o||e.src===o||e.src==="")return ds(t,0),e.addEventListener("load",t);e.addEventListener("load",t)}function rm(e,t,n){let r=!1,s;try{s=e.sheet}catch{return}if(s)return;const i=ds(()=>{r||(t(),r=!0)},n);e.addEventListener("load",()=>{Ja(i),r=!0,t()})}function sm(e,t){const{doc:n,mirror:r,blockClass:s,blockSelector:i,unblockSelector:o,maskAllText:a,maskAttributeFn:c,maskTextClass:u,unmaskTextClass:d,maskTextSelector:l,unmaskTextSelector:f,inlineStylesheet:p,maskInputOptions:h={},maskTextFn:m,maskInputFn:E,dataURLOptions:S={},inlineImages:C,recordCanvas:F,keepIframeSrcFn:L,newlyAddedElement:v=!1}=t,g=im(n,r);switch(e.nodeType){case e.DOCUMENT_NODE:return e.compatMode!=="CSS1Compat"?{type:ee.Document,childNodes:[],compatMode:e.compatMode}:{type:ee.Document,childNodes:[]};case e.DOCUMENT_TYPE_NODE:return{type:ee.DocumentType,name:e.name,publicId:e.publicId,systemId:e.systemId,rootId:g};case e.ELEMENT_NODE:return am(e,{doc:n,blockClass:s,blockSelector:i,unblockSelector:o,inlineStylesheet:p,maskAttributeFn:c,maskInputOptions:h,maskInputFn:E,dataURLOptions:S,inlineImages:C,recordCanvas:F,keepIframeSrcFn:L,newlyAddedElement:v,rootId:g,maskTextClass:u,unmaskTextClass:d,maskTextSelector:l,unmaskTextSelector:f});case e.TEXT_NODE:return om(e,{doc:n,maskAllText:a,maskTextClass:u,unmaskTextClass:d,maskTextSelector:l,unmaskTextSelector:f,maskTextFn:m,maskInputOptions:h,maskInputFn:E,rootId:g});case e.CDATA_SECTION_NODE:return{type:ee.CDATA,textContent:"",rootId:g};case e.COMMENT_NODE:return{type:ee.Comment,textContent:e.textContent||"",rootId:g};default:return!1}}function im(e,t){if(!t.hasNode(e))return;const n=t.getId(e);return n===1?void 0:n}function om(e,t){const{maskAllText:n,maskTextClass:r,unmaskTextClass:s,maskTextSelector:i,unmaskTextSelector:o,maskTextFn:a,maskInputOptions:c,maskInputFn:u,rootId:d}=t,l=e.parentNode&&e.parentNode.tagName;let f=e.textContent;const p=l==="STYLE"?!0:void 0,h=l==="SCRIPT"?!0:void 0,m=l==="TEXTAREA"?!0:void 0;if(p&&f){try{e.nextSibling||e.previousSibling||tn([e,"access",S=>S.parentNode,"access",S=>S.sheet,"optionalAccess",S=>S.cssRules])&&(f=Vn(e.parentNode.sheet))}catch(S){console.warn(`Cannot get CSS styles from text's parentNode. Error: ${S}`,e)}f=Kn(f,pr(t.doc))}h&&(f="SCRIPT_PLACEHOLDER");const E=Ft(e,r,i,s,o,n);if(!p&&!h&&!m&&f&&E&&(f=a?a(f,e.parentElement):f.replace(/[\S]/g,"*")),m&&f&&(c.textarea||E)&&(f=u?u(f,e.parentNode):f.replace(/[\S]/g,"*")),l==="OPTION"&&f){const S=fr({type:null,tagName:l,maskInputOptions:c});f=nn({isMasked:Ft(e,r,i,s,o,S),element:e,value:f,maskInputFn:u})}return{type:ee.Text,textContent:f||"",isStyle:p,rootId:d}}function am(e,t){const{doc:n,blockClass:r,blockSelector:s,unblockSelector:i,inlineStylesheet:o,maskInputOptions:a={},maskAttributeFn:c,maskInputFn:u,dataURLOptions:d={},inlineImages:l,recordCanvas:f,keepIframeSrcFn:p,newlyAddedElement:h=!1,rootId:m,maskTextClass:E,unmaskTextClass:S,maskTextSelector:C,unmaskTextSelector:F}=t,L=em(e,r,s,i),v=jh(e);let g={};const T=e.attributes.length;for(let _=0;_<T;_++){const b=e.attributes[_];b.name&&!ec(v,b.name,b.value)&&(g[b.name]=Za(n,v,Pt(b.name),b.value,e,c))}if(v==="link"&&o){const _=Array.from(n.styleSheets).find(N=>N.href===e.href);let b=null;_&&(b=Vn(_)),b&&(g.rel=null,g.href=null,g.crossorigin=null,g._cssText=Kn(b,_.href))}if(v==="style"&&e.sheet&&!(e.innerText||e.textContent||"").trim().length){const _=Vn(e.sheet);_&&(g._cssText=Kn(_,pr(n)))}if(v==="input"||v==="textarea"||v==="select"||v==="option"){const _=e,b=Us(_),N=Xn(_,ls(v),b),R=_.checked;if(b!=="submit"&&b!=="button"&&N){const G=Ft(_,E,C,S,F,fr({type:b,tagName:ls(v),maskInputOptions:a}));g.value=nn({isMasked:G,element:_,value:N,maskInputFn:u})}R&&(g.checked=R)}if(v==="option"&&(e.selected&&!a.select?g.selected=!0:delete g.selected),v==="canvas"&&f){if(e.__context==="2d")Hh(e)||(g.rr_dataURL=e.toDataURL(d.type,d.quality));else if(!("__context"in e)){const _=e.toDataURL(d.type,d.quality),b=n.createElement("canvas");b.width=e.width,b.height=e.height;const N=b.toDataURL(d.type,d.quality);_!==N&&(g.rr_dataURL=_)}}if(v==="img"&&l){bt||(bt=n.createElement("canvas"),Zi=bt.getContext("2d"));const _=e,b=_.currentSrc||_.getAttribute("src")||"<unknown-src>",N=_.crossOrigin,R=()=>{_.removeEventListener("load",R);
21try{bt.width=_.naturalWidth,bt.height=_.naturalHeight,Zi.drawImage(_,0,0),g.rr_dataURL=bt.toDataURL(d.type,d.quality)}catch(G){if(_.crossOrigin!=="anonymous"){_.crossOrigin="anonymous",_.complete&&_.naturalWidth!==0?R():_.addEventListener("load",R);return}else console.warn(`Cannot inline img src=${b}! Error: ${G}`)}_.crossOrigin==="anonymous"&&(N?g.crossOrigin=N:_.removeAttribute("crossorigin"))};_.complete&&_.naturalWidth!==0?R():_.addEventListener("load",R)}if((v==="audio"||v==="video")&&(g.rr_mediaState=e.paused?"paused":"played",g.rr_mediaCurrentTime=e.currentTime),h||(e.scrollLeft&&(g.rr_scrollLeft=e.scrollLeft),e.scrollTop&&(g.rr_scrollTop=e.scrollTop)),L){const{width:_,height:b}=e.getBoundingClientRect();g={class:g.class,rr_width:`${_}px`,rr_height:`${b}px`}}v==="iframe"&&!p(g.src)&&(!L&&!Qa(e)&&(g.rr_src=g.src),delete g.src);let w;try{customElements.get(v)&&(w=!0)}catch{}return{type:ee.Element,tagName:v,attributes:g,childNodes:[],isSVG:Zh(e)||void 0,needBlock:L,rootId:m,isCustom:w}}function Y(e){return e==null?"":e.toLowerCase()}function cm(e,t){if(t.comment&&e.type===ee.Comment)return!0;if(e.type===ee.Element){if(t.script&&(e.tagName==="script"||e.tagName==="link"&&(e.attributes.rel==="preload"||e.attributes.rel==="modulepreload")||e.tagName==="link"&&e.attributes.rel==="prefetch"&&typeof e.attributes.href=="string"&&Xa(e.attributes.href)==="js"))return!0;if(t.headFavicon&&(e.tagName==="link"&&e.attributes.rel==="shortcut icon"||e.tagName==="meta"&&(Y(e.attributes.name).match(/^msapplication-tile(image|color)$/)||Y(e.attributes.name)==="application-name"||Y(e.attributes.rel)==="icon"||Y(e.attributes.rel)==="apple-touch-icon"||Y(e.attributes.rel)==="shortcut icon")))return!0;if(e.tagName==="meta"){if(t.headMetaDescKeywords&&Y(e.attributes.name).match(/^description|keywords$/))return!0;if(t.headMetaSocial&&(Y(e.attributes.property).match(/^(og|twitter|fb):/)||Y(e.attributes.name).match(/^(og|twitter):/)||Y(e.attributes.name)==="pinterest"))return!0;if(t.headMetaRobots&&(Y(e.attributes.name)==="robots"||Y(e.attributes.name)==="googlebot"||Y(e.attributes.name)==="bingbot"))return!0;if(t.headMetaHttpEquiv&&e.attributes["http-equiv"]!==void 0)return!0;if(t.headMetaAuthorship&&(Y(e.attributes.name)==="author"||Y(e.attributes.name)==="generator"||Y(e.attributes.name)==="framework"||Y(e.attributes.name)==="publisher"||Y(e.attributes.name)==="progid"||Y(e.attributes.property).match(/^article:/)||Y(e.attributes.property).match(/^product:/)))return!0;if(t.headMetaVerification&&(Y(e.attributes.name)==="google-site-verification"||Y(e.attributes.name)==="yandex-verification"||Y(e.attributes.name)==="csrf-token"||Y(e.attributes.name)==="p:domain_verify"||Y(e.attributes.name)==="verify-v1"||Y(e.attributes.name)==="verification"||Y(e.attributes.name)==="shopify-checkout-api-token"))return!0}}return!1}function wt(e,t){const{doc:n,mirror:r,blockClass:s,blockSelector:i,unblockSelector:o,maskAllText:a,maskTextClass:c,unmaskTextClass:u,maskTextSelector:d,unmaskTextSelector:l,skipChild:f=!1,inlineStylesheet:p=!0,maskInputOptions:h={},maskAttributeFn:m,maskTextFn:E,maskInputFn:S,slimDOMOptions:C,dataURLOptions:F={},inlineImages:L=!1,recordCanvas:v=!1,onSerialize:g,onIframeLoad:T,iframeLoadTimeout:w=5e3,onStylesheetLoad:_,stylesheetLoadTimeout:b=5e3,keepIframeSrcFn:N=()=>!1,newlyAddedElement:R=!1}=t;let{preserveWhiteSpace:G=!0}=t;const J=sm(e,{doc:n,mirror:r,blockClass:s,blockSelector:i,maskAllText:a,unblockSelector:o,maskTextClass:c,unmaskTextClass:u,maskTextSelector:d,unmaskTextSelector:l,inlineStylesheet:p,maskInputOptions:h,maskAttributeFn:m,maskTextFn:E,maskInputFn:S,dataURLOptions:F,inlineImages:L,recordCanvas:v,keepIframeSrcFn:N,newlyAddedElement:R});if(!J)return console.warn(e,"not serialized"),null;let oe;r.hasNode(e)?oe=r.getId(e):cm(J,C)||!G&&J.type===ee.Text&&!J.isStyle&&!J.textContent.replace(/^\s+|\s+$/gm,"").length?oe=rn:oe=Hs();const D=Object.assign(J,{id:oe});if(r.add(e,D),oe===rn)return null;g&&g(e);let ne=!f;if(D.type===ee.Element){ne=ne&&!D.needBlock,delete D.needBlock;const W=e.shadowRoot;W&&Qt(W)&&(D.isShadowHost=!0)}if((D.type===ee.Document||D.type===ee.Element)&&ne){C.headWhitespace&&D.type===ee.Element&&D.tagName==="head"&&(G=!1);const W={doc:n,mirror:r,blockClass:s,blockSelector:i,maskAllText:a,unblockSelector:o,maskTextClass:c,unmaskTextClass:u,maskTextSelector:d,unmaskTextSelector:l,skipChild:f,inlineStylesheet:p,maskInputOptions:h,maskAttributeFn:m,maskTextFn:E,maskInputFn:S,slimDOMOptions:C,dataURLOptions:F,inlineImages:L,recordCanvas:v,preserveWhiteSpace:G,onSerialize:g,onIframeLoad:T,iframeLoadTimeout:w,onStylesheetLoad:_,stylesheetLoadTimeout:b,keepIframeSrcFn:N};for(const pe of Array.from(e.childNodes)){const Ae=wt(pe,W);Ae&&D.childNodes.push(Ae)}if(Nh(e)&&e.shadowRoot)for(const pe of Array.from(e.shadowRoot.childNodes)){const Ae=wt(pe,W);Ae&&(Qt(e.shadowRoot)&&(Ae.isShadow=!0),D.childNodes.push(Ae))}}return e.parentNode&&Jt(e.parentNode)&&Qt(e.parentNode)&&(D.isShadow=!0),D.type===ee.Element&&D.tagName==="iframe"&&nm(e,()=>{const W=Qa(e);if(W&&T){const pe=wt(W,{doc:W,mirror:r,blockClass:s,blockSelector:i,unblockSelector:o,maskAllText:a,maskTextClass:c,unmaskTextClass:u,maskTextSelector:d,unmaskTextSelector:l,skipChild:!1,inlineStylesheet:p,maskInputOptions:h,maskAttributeFn:m,maskTextFn:E,maskInputFn:S,slimDOMOptions:C,dataURLOptions:F,inlineImages:L,recordCanvas:v,preserveWhiteSpace:G,onSerialize:g,onIframeLoad:T,iframeLoadTimeout:w,onStylesheetLoad:_,stylesheetLoadTimeout:b,keepIframeSrcFn:N});pe&&T(e,pe)}},w),D.type===ee.Element&&D.tagName==="link"&&typeof D.attributes.rel=="string"&&(D.attributes.rel==="stylesheet"||D.attributes.rel==="preload"&&typeof D.attributes.href=="string"&&Xa(D.attributes.href)==="css")&&rm(e,()=>{if(_){const W=wt(e,{doc:n,mirror:r,blockClass:s,blockSelector:i,unblockSelector:o,maskAllText:a,maskTextClass:c,unmaskTextClass:u,maskTextSelector:d,unmaskTextSelector:l,skipChild:!1,inlineStylesheet:p,maskInputOptions:h,maskAttributeFn:m,maskTextFn:E,maskInputFn:S,slimDOMOptions:C,dataURLOptions:F,inlineImages:L,recordCanvas:v,preserveWhiteSpace:G,onSerialize:g,onIframeLoad:T,iframeLoadTimeout:w,onStylesheetLoad:_,stylesheetLoadTimeout:b,keepIframeSrcFn:N});W&&_(e,W)}},b),D}function um(e,t){const{mirror:n=new Va,blockClass:r="rr-block",blockSelector:s=null,unblockSelector:i=null,maskAllText:o=!1,maskTextClass:a="rr-mask",unmaskTextClass:c=null,maskTextSelector:u=null,unmaskTextSelector:d=null,inlineStylesheet:l=!0,inlineImages:f=!1,recordCanvas:p=!1,maskAllInputs:h=!1,maskAttributeFn:m,maskTextFn:E,maskInputFn:S,slimDOM:C=!1,dataURLOptions:F,preserveWhiteSpace:L,onSerialize:v,onIframeLoad:g,iframeLoadTimeout:T,onStylesheetLoad:w,stylesheetLoadTimeout:_,keepIframeSrcFn:b=()=>!1}=t||{};return wt(e,{doc:e,mirror:n,blockClass:r,blockSelector:s,unblockSelector:i,maskAllText:o,maskTextClass:a,unmaskTextClass:c,maskTextSelector:u,unmaskTextSelector:d,skipChild:!1,inlineStylesheet:l,maskInputOptions:h===!0?{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}:h===!1?{}:h,maskAttributeFn:m,maskTextFn:E,maskInputFn:S,slimDOMOptions:C===!0||C==="all"?{script:!0,comment:!0,headFavicon:!0,headWhitespace:!0,headMetaDescKeywords:C==="all",headMetaSocial:!0,headMetaRobots:!0,headMetaHttpEquiv:!0,headMetaAuthorship:!0,headMetaVerification:!0}
21:C===!1?{}:C,dataURLOptions:F,inlineImages:f,recordCanvas:p,preserveWhiteSpace:L,onSerialize:v,onIframeLoad:g,iframeLoadTimeout:T,onStylesheetLoad:w,stylesheetLoadTimeout:_,keepIframeSrcFn:b,newlyAddedElement:!1})}function ze(e){let t,n=e[0],r=1;for(;r<e.length;){const s=e[r],i=e[r+1];if(r+=2,(s==="optionalAccess"||s==="optionalCall")&&n==null)return;s==="access"||s==="optionalAccess"?(t=n,n=i(n)):(s==="call"||s==="optionalCall")&&(n=i((...o)=>n.call(t,...o)),t=void 0)}return n}function le(e,t,n=document){const r={capture:!0,passive:!0};return n.addEventListener(e,t,r),()=>n.removeEventListener(e,t,r)}const vt=`Please stop import mirror directly. Instead of that,\r 22now you can use replayer.getMirror() to access the mirror instance of a replayer,\r 23or you can use record.mirror to access the mirror instance during recording.`;let to={map:{},getId(){return console.error(vt),-1},getNode(){return console.error(vt),null},removeNodeFromMap(){console.error(vt)},has(){return console.error(vt),!1},reset(){console.error(vt)}};typeof window<"u"&&window.Proxy&&window.Reflect&&(to=new Proxy(to,{get(e,t,n){return t==="map"&&console.error(vt),Reflect.get(e,t,n)}}));function sn(e,t,n={}){let r=null,s=0;return function(...i){const o=Date.now();!s&&n.leading===!1&&(s=o);const a=t-(o-s),c=this;a<=0||a>t?(r&&(gm(r),r=null),s=o,e.apply(c,i)):!r&&n.trailing!==!1&&(r=hr(()=>{s=n.leading===!1?0:Date.now(),r=null,e.apply(c,i)},a))}}function tc(e,t,n,r,s=window){const i=s.Object.getOwnPropertyDescriptor(e,t);return s.Object.defineProperty(e,t,r?n:{set(o){hr(()=>{n.set.call(this,o)},0),i&&i.set&&i.set.call(this,o)}}),()=>tc(e,t,i||{},!0)}function Ws(e,t,n){try{if(!(t in e))return()=>{};const r=e[t],s=n(r);return typeof s=="function"&&(s.prototype=s.prototype||{},Object.defineProperties(s,{__rrweb_original__:{enumerable:!1,value:r}})),e[t]=s,()=>{e[t]=r}}catch{return()=>{}}}let Jn=Date.now;/[1-9][0-9]{12}/.test(Date.now().toString())||(Jn=()=>new Date().getTime());function nc(e){const t=e.document;return{left:t.scrollingElement?t.scrollingElement.scrollLeft:e.pageXOffset!==void 0?e.pageXOffset:ze([t,"optionalAccess",n=>n.documentElement,"access",n=>n.scrollLeft])||ze([t,"optionalAccess",n=>n.body,"optionalAccess",n=>n.parentElement,"optionalAccess",n=>n.scrollLeft])||ze([t,"optionalAccess",n=>n.body,"optionalAccess",n=>n.scrollLeft])||0,top:t.scrollingElement?t.scrollingElement.scrollTop:e.pageYOffset!==void 0?e.pageYOffset:ze([t,"optionalAccess",n=>n.documentElement,"access",n=>n.scrollTop])||ze([t,"optionalAccess",n=>n.body,"optionalAccess",n=>n.parentElement,"optionalAccess",n=>n.scrollTop])||ze([t,"optionalAccess",n=>n.body,"optionalAccess",n=>n.scrollTop])||0}}function rc(){return window.innerHeight||document.documentElement&&document.documentElement.clientHeight||document.body&&document.body.clientHeight}function sc(){return window.innerWidth||document.documentElement&&document.documentElement.clientWidth||document.body&&document.body.clientWidth}function ic(e){return e?e.nodeType===e.ELEMENT_NODE?e:e.parentElement:null}function ge(e,t,n,r,s){if(!e)return!1;const i=ic(e);if(!i)return!1;const o=It(t,n);if(!s){const u=r&&i.matches(r);return o(i)&&!u}const a=ct(i,o);let c=-1;return a<0?!1:(r&&(c=ct(i,It(null,r))),a>-1&&c<0?!0:a<c)}function lm(e,t){return t.getId(e)!==-1}function Pr(e,t){return t.getId(e)===rn}function oc(e,t){if(Jt(e))return!1;const n=t.getId(e);return t.has(n)?e.parentNode&&e.parentNode.nodeType===e.DOCUMENT_NODE?!1:e.parentNode?oc(e.parentNode,t):!0:!0}function fs(e){return!!e.changedTouches}function dm(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=(...t)=>{let n=t[0];if(!(0 in t))throw new TypeError("1 argument is required");do if(this===n)return!0;while(n=n&&n.parentNode);return!1})}function ac(e,t){return!!(e.nodeName==="IFRAME"&&t.getMeta(e))}function cc(e,t){return!!(e.nodeName==="LINK"&&e.nodeType===e.ELEMENT_NODE&&e.getAttribute&&e.getAttribute("rel")==="stylesheet"&&t.getMeta(e))}function ps(e){return!!ze([e,"optionalAccess",t=>t.shadowRoot])}class fm{constructor(){this.id=1,this.styleIDMap=new WeakMap,this.idStyleMap=new Map}getId(t){return Xd(this.styleIDMap.get(t),()=>-1)}has(t){return this.styleIDMap.has(t)}add(t,n){if(this.has(t))return this.getId(t);let r;return n===void 0?r=this.id++:r=n,this.styleIDMap.set(t,r),this.idStyleMap.set(r,t),r}getStyle(t){return this.idStyleMap.get(t)||null}reset(){this.styleIDMap=new WeakMap,this.idStyleMap=new Map,this.id=1}generateId(){return this.id++}}function uc(e){let t=null;return ze([e,"access",n=>n.getRootNode,"optionalCall",n=>n(),"optionalAccess",n=>n.nodeType])===Node.DOCUMENT_FRAGMENT_NODE&&e.getRootNode().host&&(t=e.getRootNode().host),t}function pm(e){let t=e,n;for(;n=uc(t);)t=n;return t}function hm(e){const t=e.ownerDocument;if(!t)return!1;const n=pm(e);return t.contains(n)}function lc(e){const t=e.ownerDocument;return t?t.contains(e)||hm(e):!1}const no={};function zs(e){const t=no[e];if(t)return t;const n=window.document;let r=window[e];if(n&&typeof n.createElement=="function")try{const s=n.createElement("iframe");s.hidden=!0,n.head.appendChild(s);const i=s.contentWindow;i&&i[e]&&(r=i[e]),n.head.removeChild(s)}catch{}return no[e]=r.bind(window)}function mm(...e){return zs("requestAnimationFrame")(...e)}
23function hr(...e){return zs("setTimeout")(...e)}function gm(...e){return zs("clearTimeout")(...e)}var P=(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))(P||{}),x=(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))(x||{}),ue=(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))(ue||{}),Oe=(e=>(e[e.Mouse=0]="Mouse",e[e.Pen=1]="Pen",e[e.Touch=2]="Touch",e))(Oe||{}),ro;(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"})(ro||(ro={}));var so;(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"})(so||(so={}));function js(e){try{return e.contentDocument}catch{}}function _m(e){try{return e.contentWindow}catch{}}function ym(e){let t,n=e[0],r=1;for(;r<e.length;){const s=e[r],i=e[r+1];if(r+=2,(s==="optionalAccess"||s==="optionalCall")&&n==null)return;s==="access"||s==="optionalAccess"?(t=n,n=i(n)):(s==="call"||s==="optionalCall")&&(n=i((...o)=>n.call(t,...o)),t=void 0)}return n}function io(e){return"__ln"in e}class Sm{constructor(){this.length=0,this.head=null,this.tail=null}get(t){if(t>=this.length)throw new Error("Position outside of list range");let n=this.head;for(let r=0;r<t;r++)n=ym([n,"optionalAccess",s=>s.next])||null;return n}addNode(t){const n={value:t,previous:null,next:null};if(t.__ln=n,t.previousSibling&&io(t.previousSibling)){const r=t.previousSibling.__ln.next;n.next=r,n.previous=t.previousSibling.__ln,t.previousSibling.__ln.next=n,r&&(r.previous=n)}else if(t.nextSibling&&io(t.nextSibling)&&t.nextSibling.__ln.previous){const r=t.nextSibling.__ln.previous;n.previous=r,n.next=t.nextSibling.__ln,t.nextSibling.__ln.previous=n,r&&(r.next=n)}else this.head&&(this.head.previous=n),n.next=this.head,this.head=n;n.next===null&&(this.tail=n),this.length++}removeNode(t){const n=t.__ln;this.head&&(n.previous?(n.previous.next=n.next,n.next?n.next.previous=n.previous:this.tail=n.previous):(this.head=n.next,this.head?this.head.previous=null:this.tail=null),t.__ln&&delete t.__ln,this.length--)}}const oo=(e,t)=>`${e}@${t}`;class Em{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=t=>{t.forEach(this.processMutation),this.emit()},this.emit=()=>{if(this.frozen||this.locked)return;const t=[],n=new Set,r=new Sm,s=c=>{let u=c,d=rn;for(;d===rn;)u=u&&u.nextSibling,d=u&&this.mirror.getId(u);return d},i=c=>{if(!c.parentNode||!lc(c))return;const u=Jt(c.parentNode)?this.mirror.getId(uc(c)):this.mirror.getId(c.parentNode),d=s(c);if(u===-1||d===-1)return r.addNode(c);const l=wt(c,{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.inl
23ineStylesheet,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:f=>{ac(f,this.mirror)&&!ge(f,this.blockClass,this.blockSelector,this.unblockSelector,!1)&&this.iframeManager.addIframe(f),cc(f,this.mirror)&&this.stylesheetManager.trackLinkElement(f),ps(c)&&this.shadowDomManager.addShadowRoot(c.shadowRoot,this.doc)},onIframeLoad:(f,p)=>{ge(f,this.blockClass,this.blockSelector,this.unblockSelector,!1)||(this.iframeManager.attachIframe(f,p),f.contentWindow&&this.canvasManager.addWindow(f.contentWindow),this.shadowDomManager.observeAttachShadow(f))},onStylesheetLoad:(f,p)=>{this.stylesheetManager.attachLinkElement(f,p)}});l&&(t.push({parentId:u,nextId:d,node:l}),n.add(l.id))};for(;this.mapRemoves.length;)this.mirror.removeNodeFromMap(this.mapRemoves.shift());for(const c of this.movedSet)ao(this.removes,c,this.mirror)&&!this.movedSet.has(c.parentNode)||i(c);for(const c of this.addedSet)!co(this.droppedSet,c)&&!ao(this.removes,c,this.mirror)||co(this.movedSet,c)?i(c):this.droppedSet.add(c);let o=null;for(;r.length;){let c=null;if(o){const u=this.mirror.getId(o.value.parentNode),d=s(o.value);u!==-1&&d!==-1&&(c=o)}if(!c){let u=r.tail;for(;u;){const d=u;if(u=u.previous,d){const l=this.mirror.getId(d.value.parentNode);if(s(d.value)===-1)continue;if(l!==-1){c=d;break}else{const p=d.value;if(p.parentNode&&p.parentNode.nodeType===Node.DOCUMENT_FRAGMENT_NODE){const h=p.parentNode.host;if(this.mirror.getId(h)!==-1){c=d;break}}}}}}if(!c){for(;r.head;)r.removeNode(r.head.value);break}o=c.previous,r.removeNode(c.value),i(c.value)}const a={texts:this.texts.map(c=>({id:this.mirror.getId(c.node),value:c.value})).filter(c=>!n.has(c.id)).filter(c=>this.mirror.has(c.id)),attributes:this.attributes.map(c=>{const{attributes:u}=c;if(typeof u.style=="string"){const d=JSON.stringify(c.styleDiff),l=JSON.stringify(c._unchangedStyles);d.length<u.style.length&&(d+l).split("var(").length===u.style.split("var(").length&&(u.style=c.styleDiff)}return{id:this.mirror.getId(c.node),attributes:u}}).filter(c=>!n.has(c.id)).filter(c=>this.mirror.has(c.id)),removes:this.removes,adds:t};!a.texts.length&&!a.attributes.length&&!a.removes.length&&!a.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(a))},this.processMutation=t=>{if(!Pr(t.target,this.mirror))switch(t.type){case"characterData":{const n=t.target.textContent;!ge(t.target,this.blockClass,this.blockSelector,this.unblockSelector,!1)&&n!==t.oldValue&&this.texts.push({value:Ft(t.target,this.maskTextClass,this.maskTextSelector,this.unmaskTextClass,this.unmaskTextSelector,this.maskAllText)&&n?this.maskTextFn?this.maskTextFn(n,ic(t.target)):n.replace(/[\S]/g,"*"):n,node:t.target});break}case"attributes":{const n=t.target;let r=t.attributeName,s=t.target.getAttribute(r);if(r==="value"){const o=Us(n),a=n.tagName;s=Xn(n,a,o);const c=fr({maskInputOptions:this.maskInputOptions,tagName:a,type:o}),u=Ft(t.target,this.maskTextClass,this.maskTextSelector,this.unmaskTextClass,this.unmaskTextSelector,c);s=nn({isMasked:u,element:n,value:s,maskInputFn:this.maskInputFn})}if(ge(t.target,this.blockClass,this.blockSelector,this.unblockSelector,!1)||s===t.oldValue)return;let i=this.attributeMap.get(t.target);if(n.tagName==="IFRAME"&&r==="src"&&!this.keepIframeSrcFn(s))if(!js(n))r="rr_src";else return;if(i||(i={node:t.target,attributes:{},styleDiff:{},_unchangedStyles:{}},this.attributes.push(i),this.attributeMap.set(t.target,i)),r==="type"&&n.tagName==="INPUT"&&(t.oldValue||"").toLowerCase()==="password"&&n.setAttribute("data-rr-is-password","true"),!ec(n.tagName,r)&&(i.attributes[r]=Za(this.doc,Pt(n.tagName),Pt(r),s,n,this.maskAttributeFn),r==="style")){if(!this.unattachedDoc)try{this.unattachedDoc=document.implementation.createHTMLDocument()}catch{this.unattachedDoc=this.doc}const o=this.unattachedDoc.createElement("span");t.oldValue&&o.setAttribute("style",t.oldValue);for(const a of Array.from(n.style)){const c=n.style.getPropertyValue(a),u=n.style.getPropertyPriority(a);c!==o.style.getPropertyValue(a)||u!==o.style.getPropertyPriority(a)?u===""?i.styleDiff[a]=c:i.styleDiff[a]=[c,u]:i._unchangedStyles[a]=[c,u]}for(const a of Array.from(o.style))n.style.getPropertyValue(a)===""&&(i.styleDiff[a]=!1)}break}
23case"childList":{if(ge(t.target,this.blockClass,this.blockSelector,this.unblockSelector,!0))return;t.addedNodes.forEach(n=>this.genAdds(n,t.target)),t.removedNodes.forEach(n=>{const r=this.mirror.getId(n),s=Jt(t.target)?this.mirror.getId(t.target.host):this.mirror.getId(t.target);ge(t.target,this.blockClass,this.blockSelector,this.unblockSelector,!1)||Pr(n,this.mirror)||!lm(n,this.mirror)||(this.addedSet.has(n)?(hs(this.addedSet,n),this.droppedSet.add(n)):this.addedSet.has(t.target)&&r===-1||oc(t.target,this.mirror)||(this.movedSet.has(n)&&this.movedMap[oo(r,s)]?hs(this.movedSet,n):this.removes.push({parentId:s,id:r,isShadow:Jt(t.target)&&Qt(t.target)?!0:void 0})),this.mapRemoves.push(n))});break}}},this.genAdds=(t,n)=>{if(!this.processedNodeManager.inOtherBuffer(t,this)&&!(this.addedSet.has(t)||this.movedSet.has(t))){if(this.mirror.hasNode(t)){if(Pr(t,this.mirror))return;this.movedSet.add(t);let r=null;n&&this.mirror.hasNode(n)&&(r=this.mirror.getId(n)),r&&r!==-1&&(this.movedMap[oo(this.mirror.getId(t),r)]=!0)}else this.addedSet.add(t),this.droppedSet.delete(t);ge(t,this.blockClass,this.blockSelector,this.unblockSelector,!1)||(t.childNodes.forEach(r=>this.genAdds(r)),ps(t)&&t.shadowRoot.childNodes.forEach(r=>{this.processedNodeManager.add(r,this),this.genAdds(r,t)}))}}}init(t){["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(n=>{this[n]=t[n]})}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 hs(e,t){e.delete(t),t.childNodes.forEach(n=>hs(e,n))}function ao(e,t,n){return e.length===0?!1:bm(e,t,n)}function bm(e,t,n){let r=t.parentNode;for(;r;){const s=n.getId(r);if(e.some(i=>i.id===s))return!0;r=r.parentNode}return!1}function co(e,t){return e.size===0?!1:dc(e,t)}function dc(e,t){const{parentNode:n}=t;return n?e.has(n)?!0:dc(e,n):!1}let Zt;function vm(e){Zt=e}function Tm(){Zt=void 0}const H=e=>Zt?(...n)=>{try{return e(...n)}catch(r){if(Zt&&Zt(r)===!0)return()=>{};throw r}}:e;function we(e){let t,n=e[0],r=1;for(;r<e.length;){const s=e[r],i=e[r+1];if(r+=2,(s==="optionalAccess"||s==="optionalCall")&&n==null)return;s==="access"||s==="optionalAccess"?(t=n,n=i(n)):(s==="call"||s==="optionalCall")&&(n=i((...o)=>n.call(t,...o)),t=void 0)}return n}const kt=[];function hn(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 fc(e,t){const n=new Em;kt.push(n),n.init(e);let r=window.MutationObserver||window.__rrMutationObserver;const s=we([window,"optionalAccess",o=>o.Zone,"optionalAccess",o=>o.__symbol__,"optionalCall",o=>o("MutationObserver")]);s&&window[s]&&(r=window[s]);const i=new r(H(o=>{e.onMutation&&e.onMutation(o)===!1||n.processMutations.bind(n)(o)}));return i.observe(t,{attributes:!0,attributeOldValue:!0,characterData:!0,characterDataOldValue:!0,childList:!0,subtree:!0}),i}function Im({mousemoveCb:e,sampling:t,doc:n,mirror:r}){if(t.mousemove===!1)return()=>{};const s=typeof t.mousemove=="number"?t.mousemove:50,i=typeof t.mousemoveCallback=="number"?t.mousemoveCallback:500;let o=[],a;const c=sn(H(l=>{const f=Date.now()-a;e(o.map(p=>(p.timeOffset-=f,p)),l),o=[],a=null}),i),u=H(sn(H(l=>{const f=hn(l),{clientX:p,clientY:h}=fs(l)?l.changedTouches[0]:l;a||(a=Jn()),o.push({x:p,y:h,id:r.getId(f),timeOffset:Jn()-a}),c(typeof DragEvent<"u"&&l instanceof DragEvent?x.Drag:l instanceof MouseEvent?x.MouseMove:x.TouchMove)}),s,{trailing:!1})),d=[le("mousemove",u,n),le("touchmove",u,n),le("drag",u,n)];return H(()=>{d.forEach(l=>l())})}function wm({mouseInteractionCb:e,doc:t,mirror:n,blockClass:r,blockSelector:s,unblockSelector:i,sampling:o}){if(o.mouseInteraction===!1)return()=>{};const a=o.mouseInteraction===!0||o.mouseInteraction===void 0?{}:o.mouseInteraction,c=[];let u=null;const d=l=>f=>{const p=hn(f);if(ge(p,r,s,i,!0))return;let h=null,m=l;if("pointerType"in f){switch(f.pointerType){case"mouse":h=Oe.Mouse;break;case"touch":h=Oe.Touch;break;case"pen":h=Oe.Pen;break}h===Oe.Touch?ue[l]===ue.MouseDown?m="TouchStart":ue[l]===ue.MouseUp&&(m="TouchEnd"):Oe.Pen}else fs(f)&&(h=Oe.Touch);h!==null?(u=h,(m.startsWith("Touch")&&h===Oe.Touch||m.startsWith("Mouse")&&h===Oe.Mouse)&&(h=null)):ue[l]===ue.Click&&(h=u,u=null);const E=fs(f)?f.changedTouches[0]:f;if(!E)return;const S=n.getId(p),{clientX:C,clientY:F}=E;H(e)({type:ue[m],id:S,x:C,y:F,...h!==null&&{pointerType:h}})};return Object.keys(ue).filter(l=>Number.isNaN(Number(l))&&!l.endsWith("_Departed")&&a[l]!==!1).forEac
23h(l=>{let f=Pt(l);const p=d(l);if(window.PointerEvent)switch(ue[l]){case ue.MouseDown:case ue.MouseUp:f=f.replace("mouse","pointer");break;case ue.TouchStart:case ue.TouchEnd:return}c.push(le(f,p,t))}),H(()=>{c.forEach(l=>l())})}function pc({scrollCb:e,doc:t,mirror:n,blockClass:r,blockSelector:s,unblockSelector:i,sampling:o}){const a=H(sn(H(c=>{const u=hn(c);if(!u||ge(u,r,s,i,!0))return;const d=n.getId(u);if(u===t&&t.defaultView){const l=nc(t.defaultView);e({id:d,x:l.left,y:l.top})}else e({id:d,x:u.scrollLeft,y:u.scrollTop})}),o.scroll||100));return le("scroll",a,t)}function km({viewportResizeCb:e},{win:t}){let n=-1,r=-1;const s=H(sn(H(()=>{const i=rc(),o=sc();(n!==i||r!==o)&&(e({width:Number(o),height:Number(i)}),n=i,r=o)}),200));return le("resize",s,t)}const Cm=["INPUT","TEXTAREA","SELECT"],uo=new WeakMap;function Rm({inputCb:e,doc:t,mirror:n,blockClass:r,blockSelector:s,unblockSelector:i,ignoreClass:o,ignoreSelector:a,maskInputOptions:c,maskInputFn:u,sampling:d,userTriggeredOnInput:l,maskTextClass:f,unmaskTextClass:p,maskTextSelector:h,unmaskTextSelector:m}){function E(T){let w=hn(T);const _=T.isTrusted,b=w&&ls(w.tagName);if(b==="OPTION"&&(w=w.parentElement),!w||!b||Cm.indexOf(b)<0||ge(w,r,s,i,!0))return;const N=w;if(N.classList.contains(o)||a&&N.matches(a))return;const R=Us(w);let G=Xn(N,b,R),J=!1;const oe=fr({maskInputOptions:c,tagName:b,type:R}),D=Ft(w,f,h,p,m,oe);(R==="radio"||R==="checkbox")&&(J=w.checked),G=nn({isMasked:D,element:w,value:G,maskInputFn:u}),S(w,l?{text:G,isChecked:J,userTriggered:_}:{text:G,isChecked:J});const ne=w.name;R==="radio"&&ne&&J&&t.querySelectorAll(`input[type="radio"][name="${ne}"]`).forEach(W=>{if(W!==w){const pe=nn({isMasked:D,element:W,value:Xn(W,b,R),maskInputFn:u});S(W,l?{text:pe,isChecked:!J,userTriggered:!1}:{text:pe,isChecked:!J})}})}function S(T,w){const _=uo.get(T);if(!_||_.text!==w.text||_.isChecked!==w.isChecked){uo.set(T,w);const b=n.getId(T);H(e)({...w,id:b})}}const F=(d.input==="last"?["change"]:["input","change"]).map(T=>le(T,H(E),t)),L=t.defaultView;if(!L)return()=>{F.forEach(T=>T())};const v=L.Object.getOwnPropertyDescriptor(L.HTMLInputElement.prototype,"value"),g=[[L.HTMLInputElement.prototype,"value"],[L.HTMLInputElement.prototype,"checked"],[L.HTMLSelectElement.prototype,"value"],[L.HTMLTextAreaElement.prototype,"value"],[L.HTMLSelectElement.prototype,"selectedIndex"],[L.HTMLOptionElement.prototype,"selected"]];return v&&v.set&&F.push(...g.map(T=>tc(T[0],T[1],{set(){H(E)({target:this,isTrusted:!1})}},!1,L))),H(()=>{F.forEach(T=>T())})}function Qn(e){const t=[];function n(r,s){if(xn("CSSGroupingRule")&&r.parentRule instanceof CSSGroupingRule||xn("CSSMediaRule")&&r.parentRule instanceof CSSMediaRule||xn("CSSSupportsRule")&&r.parentRule instanceof CSSSupportsRule||xn("CSSConditionRule")&&r.parentRule instanceof CSSConditionRule){const o=Array.from(r.parentRule.cssRules).indexOf(r);s.unshift(o)}else if(r.parentStyleSheet){const o=Array.from(r.parentStyleSheet.cssRules).indexOf(r);s.unshift(o)}return s}return n(e,t)}function je(e,t,n){let r,s;return e?(e.ownerNode?r=t.getId(e.ownerNode):s=n.getId(e),{styleId:s,id:r}):{}}function Mm({styleSheetRuleCb:e,mirror:t,stylesheetManager:n},{win:r}){if(!r.CSSStyleSheet||!r.CSSStyleSheet.prototype)return()=>{};const s=r.CSSStyleSheet.prototype.insertRule;r.CSSStyleSheet.prototype.insertRule=new Proxy(s,{apply:H((d,l,f)=>{const[p,h]=f,{id:m,styleId:E}=je(l,t,n.styleMirror);return(m&&m!==-1||E&&E!==-1)&&e({id:m,styleId:E,adds:[{rule:p,index:h}]}),d.apply(l,f)})});const i=r.CSSStyleSheet.prototype.deleteRule;r.CSSStyleSheet.prototype.deleteRule=new Proxy(i,{apply:H((d,l,f)=>{const[p]=f,{id:h,styleId:m}=je(l,t,n.styleMirror);return(h&&h!==-1||m&&m!==-1)&&e({id:h,styleId:m,removes:[{index:p}]}),d.apply(l,f)})});let o;r.CSSStyleSheet.prototype.replace&&(o=r.CSSStyleSheet.prototype.replace,r.CSSStyleSheet.prototype.replace=new Proxy(o,{apply:H((d,l,f)=>{const[p]=f,{id:h,styleId:m}=je(l,t,n.styleMirror);return(h&&h!==-1||m&&m!==-1)&&e({id:h,styleId:m,replace:p}),d.apply(l,f)})}));let a;r.CSSStyleSheet.prototype.replaceSync&&(a=r.CSSStyleSheet.prototype.replaceSync,r.CSSStyleSheet.prototype.replaceSync=new Proxy(a,{apply:H((d,l,f)=>{const[p]=f,{id:h,styleId:m}=je(l,t,n.styleMirror);
23return(h&&h!==-1||m&&m!==-1)&&e({id:h,styleId:m,replaceSync:p}),d.apply(l,f)})}));const c={};An("CSSGroupingRule")?c.CSSGroupingRule=r.CSSGroupingRule:(An("CSSMediaRule")&&(c.CSSMediaRule=r.CSSMediaRule),An("CSSConditionRule")&&(c.CSSConditionRule=r.CSSConditionRule),An("CSSSupportsRule")&&(c.CSSSupportsRule=r.CSSSupportsRule));const u={};return Object.entries(c).forEach(([d,l])=>{u[d]={insertRule:l.prototype.insertRule,deleteRule:l.prototype.deleteRule},l.prototype.insertRule=new Proxy(u[d].insertRule,{apply:H((f,p,h)=>{const[m,E]=h,{id:S,styleId:C}=je(p.parentStyleSheet,t,n.styleMirror);return(S&&S!==-1||C&&C!==-1)&&e({id:S,styleId:C,adds:[{rule:m,index:[...Qn(p),E||0]}]}),f.apply(p,h)})}),l.prototype.deleteRule=new Proxy(u[d].deleteRule,{apply:H((f,p,h)=>{const[m]=h,{id:E,styleId:S}=je(p.parentStyleSheet,t,n.styleMirror);return(E&&E!==-1||S&&S!==-1)&&e({id:E,styleId:S,removes:[{index:[...Qn(p),m]}]}),f.apply(p,h)})})}),H(()=>{r.CSSStyleSheet.prototype.insertRule=s,r.CSSStyleSheet.prototype.deleteRule=i,o&&(r.CSSStyleSheet.prototype.replace=o),a&&(r.CSSStyleSheet.prototype.replaceSync=a),Object.entries(c).forEach(([d,l])=>{l.prototype.insertRule=u[d].insertRule,l.prototype.deleteRule=u[d].deleteRule})})}function hc({mirror:e,stylesheetManager:t},n){let r=null;n.nodeName==="#document"?r=e.getId(n):r=e.getId(n.host);const s=n.nodeName==="#document"?we([n,"access",o=>o.defaultView,"optionalAccess",o=>o.Document]):we([n,"access",o=>o.ownerDocument,"optionalAccess",o=>o.defaultView,"optionalAccess",o=>o.ShadowRoot]),i=we([s,"optionalAccess",o=>o.prototype])?Object.getOwnPropertyDescriptor(we([s,"optionalAccess",o=>o.prototype]),"adoptedStyleSheets"):void 0;return r===null||r===-1||!s||!i?()=>{}:(Object.defineProperty(n,"adoptedStyleSheets",{configurable:i.configurable,enumerable:i.enumerable,get(){return we([i,"access",o=>o.get,"optionalAccess",o=>o.call,"call",o=>o(this)])},set(o){const a=we([i,"access",c=>c.set,"optionalAccess",c=>c.call,"call",c=>c(this,o)]);if(r!==null&&r!==-1)try{t.adoptStyleSheets(o,r)}catch{}return a}}),H(()=>{Object.defineProperty(n,"adoptedStyleSheets",{configurable:i.configurable,enumerable:i.enumerable,get:i.get,set:i.set})}))}function xm({styleDeclarationCb:e,mirror:t,ignoreCSSAttributes:n,stylesheetManager:r},{win:s}){const i=s.CSSStyleDeclaration.prototype.setProperty;s.CSSStyleDeclaration.prototype.setProperty=new Proxy(i,{apply:H((a,c,u)=>{const[d,l,f]=u;if(n.has(d))return i.apply(c,[d,l,f]);const{id:p,styleId:h}=je(we([c,"access",m=>m.parentRule,"optionalAccess",m=>m.parentStyleSheet]),t,r.styleMirror);return(p&&p!==-1||h&&h!==-1)&&e({id:p,styleId:h,set:{property:d,value:l,priority:f},index:Qn(c.parentRule)}),a.apply(c,u)})});const o=s.CSSStyleDeclaration.prototype.removeProperty;return s.CSSStyleDeclaration.prototype.removeProperty=new Proxy(o,{apply:H((a,c,u)=>{const[d]=u;if(n.has(d))return o.apply(c,[d]);const{id:l,styleId:f}=je(we([c,"access",p=>p.parentRule,"optionalAccess",p=>p.parentStyleSheet]),t,r.styleMirror);return(l&&l!==-1||f&&f!==-1)&&e({id:l,styleId:f,remove:{property:d},index:Qn(c.parentRule)}),a.apply(c,u)})}),H(()=>{s.CSSStyleDeclaration.prototype.setProperty=i,s.CSSStyleDeclaration.prototype.removeProperty=o})}function Am({mediaInteractionCb:e,blockClass:t,blockSelector:n,unblockSelector:r,mirror:s,sampling:i,doc:o}){const a=H(u=>sn(H(d=>{const l=hn(d);if(!l||ge(l,t,n,r,!0))return;const{currentTime:f,volume:p,muted:h,playbackRate:m}=l;e({type:u,id:s.getId(l),currentTime:f,volume:p,muted:h,playbackRate:m})}),i.media||500)),c=[le("play",a(0),o),le("pause",a(1),o),le("seeked",a(2),o),le("volumechange",a(3),o),le("ratechange",a(4),o)];return H(()=>{c.forEach(u=>u())})}function Om({fontCb:e,doc:t}){const n=t.defaultView;if(!n)return()=>{};const r=[],s=new WeakMap,i=n.FontFace;n.FontFace=function(c,u,d){const l=new i(c,u,d);return s.set(l,{family:c,buffer:typeof u!="string",descriptors:d,fontSource:typeof u=="string"?u:JSON.stringify(Array.from(new Uint8Array(u)))}),l};const o=Ws(t.fonts,"add",function(a){return function(c){return hr(H(()=>{const u=s.get(c);u&&(e(u),s.delete(c))}),0),a.apply(this,[c])}});return r.push(()=>{n.FontFace=i}),r.push(o),H(()=>{r.forEach(a=>a())})}function Nm(e){const{doc:t,mirror:n,blockClass:r,blockSelector:s,unblockSelector:i,selectionCb:o}=e;let a=!0;const c=H(()=>{const u=t.getSelection();if(!u||a&&we([u,"optionalAccess",f=>f.isCollapsed]))return;a=u.isCollapsed||!1;const d=[],l=u.rangeCount||0;for(let f=0;f<l;f++){const p=u.getRangeAt(f),{startContainer:h,startOffset:m,endContainer:E,endOffset:S}=p;ge(h,r,s,i,!0)||ge(E,r,s,i,!0)||d.push({start:n.getId(h),startOffset:m,end:n.getId(E),endOffset:S})}o({ranges:d})});return c(),le("selectionchange",c)}function Dm({doc:e,customElementCb:t}){const n=e.defaultView;return!n||!n.customElements?()=>{}:Ws(n.customElements,"define",function(s){return function(i,o,a){try{t({define:{name:i}})}catch{}return s.apply(this,[i,o,a])}})}function Lm(e,t={}){const n=e.doc.defaultView;if(!n)return()=>{};let r;e.recordDOM&&(r=fc(e,e.doc));const s=Im(e),i=wm(e),o=pc(e),a=km(e,{win:n}),c=Rm(e),u=Am(e);let d=()=>{},l=()=>{},f=()=>{},p=()=>{};e.recordDOM&&(d=Mm(e,{win:n}),l=hc(e,e.doc),f=xm(e,{win:n}),e.collectFonts&&(p=Om(e)));const h=Nm(e),m=Dm(e),E=[];for(const S of e.plugins)E.push(S.observer(S.callback,n,S.options));return H(()=>{kt.forEach(S=>S.reset()),we([r,"optionalAccess",S=>S.disconnect,"call",S=>
23S()]),s(),i(),o(),a(),c(),u(),d(),l(),f(),p(),h(),m(),E.forEach(S=>S())})}function xn(e){return typeof window[e]<"u"}function An(e){return!!(typeof window[e]<"u"&&window[e].prototype&&"insertRule"in window[e].prototype&&"deleteRule"in window[e].prototype)}class ms{constructor(t){this.generateIdFn=t,this.iframeIdToRemoteIdMap=new WeakMap,this.iframeRemoteIdToIdMap=new WeakMap}getId(t,n,r,s){const i=r||this.getIdToRemoteIdMap(t),o=s||this.getRemoteIdToIdMap(t);let a=i.get(n);return a||(a=this.generateIdFn(),i.set(n,a),o.set(a,n)),a}getIds(t,n){const r=this.getIdToRemoteIdMap(t),s=this.getRemoteIdToIdMap(t);return n.map(i=>this.getId(t,i,r,s))}getRemoteId(t,n,r){const s=r||this.getRemoteIdToIdMap(t);if(typeof n!="number")return n;const i=s.get(n);return i||-1}getRemoteIds(t,n){const r=this.getRemoteIdToIdMap(t);return n.map(s=>this.getRemoteId(t,s,r))}reset(t){if(!t){this.iframeIdToRemoteIdMap=new WeakMap,this.iframeRemoteIdToIdMap=new WeakMap;return}this.iframeIdToRemoteIdMap.delete(t),this.iframeRemoteIdToIdMap.delete(t)}getIdToRemoteIdMap(t){let n=this.iframeIdToRemoteIdMap.get(t);return n||(n=new Map,this.iframeIdToRemoteIdMap.set(t,n)),n}getRemoteIdToIdMap(t){let n=this.iframeRemoteIdToIdMap.get(t);return n||(n=new Map,this.iframeRemoteIdToIdMap.set(t,n)),n}}function lo(e){let t,n=e[0],r=1;for(;r<e.length;){const s=e[r],i=e[r+1];if(r+=2,(s==="optionalAccess"||s==="optionalCall")&&n==null)return;s==="access"||s==="optionalAccess"?(t=n,n=i(n)):(s==="call"||s==="optionalCall")&&(n=i((...o)=>n.call(t,...o)),t=void 0)}return n}class Pm{constructor(){this.crossOriginIframeMirror=new ms(Hs),this.crossOriginIframeRootIdMap=new WeakMap}addIframe(){}addLoadListener(){}attachIframe(){}}class Fm{constructor(t){this.iframes=new WeakMap,this.crossOriginIframeMap=new WeakMap,this.crossOriginIframeMirror=new ms(Hs),this.crossOriginIframeRootIdMap=new WeakMap,this.mutationCb=t.mutationCb,this.wrappedEmit=t.wrappedEmit,this.stylesheetManager=t.stylesheetManager,this.recordCrossOriginIframes=t.recordCrossOriginIframes,this.crossOriginIframeStyleMirror=new ms(this.stylesheetManager.styleMirror.generateId.bind(this.stylesheetManager.styleMirror)),this.mirror=t.mirror,this.recordCrossOriginIframes&&window.addEventListener("message",this.handleMessage.bind(this))}addIframe(t){this.iframes.set(t,!0),t.contentWindow&&this.crossOriginIframeMap.set(t.contentWindow,t)}addLoadListener(t){this.loadListener=t}attachIframe(t,n){this.mutationCb({adds:[{parentId:this.mirror.getId(t),nextId:null,node:n}],removes:[],texts:[],attributes:[],isAttachIframe:!0}),lo([this,"access",s=>s.loadListener,"optionalCall",s=>s(t)]);const r=js(t);r&&r.adoptedStyleSheets&&r.adoptedStyleSheets.length>0&&this.stylesheetManager.adoptStyleSheets(r.adoptedStyleSheets,this.mirror.getId(r))}handleMessage(t){const n=t;if(n.data.type!=="rrweb"||n.origin!==n.data.origin||!t.source)return;const s=this.crossOriginIframeMap.get(t.source);if(!s)return;const i=this.transformCrossOriginEvent(s,n.data.event);i&&this.wrappedEmit(i,n.data.isCheckout)}transformCrossOriginEvent(t,n){switch(n.type){case P.FullSnapshot:{this.crossOriginIframeMirror.reset(t),this.crossOriginIframeStyleMirror.reset(t),this.replaceIdOnNode(n.data.node,t);const r=n.data.node.id;return this.crossOriginIframeRootIdMap.set(t,r),this.patchRootIdOnNode(n.data.node,r),{timestamp:n.timestamp,type:P.IncrementalSnapshot,data:{source:x.Mutation,adds:[{parentId:this.mirror.getId(t),nextId:null,node:n.data.node}],removes:[],texts:[],attributes:[],isAttachIframe:!0}}}case P.Meta:case P.Load:case P.DomContentLoaded:return!1;case P.Plugin:return n;case P.Custom:return this.replaceIds(n.data.payload,t,["id","parentId","previousId","nextId"]),n;case P.IncrementalSnapshot:switch(n.data.source){case x.Mutation:return n.data.adds.forEach(r=>{this.replaceIds(r,t,["parentId","nextId","previousId"]),this.replaceIdOnNode(r.node,t);const s=this.crossOriginIframeRootIdMap.get(t);s&&this.patchRootIdOnNode(r.node,s)}),n.data.removes.forEach(r=>{this.replaceIds(r,t,["parentId","id"])}),n.data.attributes.forEach(r=>{this.replaceIds(r,t,["id"])}
23),n.data.texts.forEach(r=>{this.replaceIds(r,t,["id"])}),n;case x.Drag:case x.TouchMove:case x.MouseMove:return n.data.positions.forEach(r=>{this.replaceIds(r,t,["id"])}),n;case x.ViewportResize:return!1;case x.MediaInteraction:case x.MouseInteraction:case x.Scroll:case x.CanvasMutation:case x.Input:return this.replaceIds(n.data,t,["id"]),n;case x.StyleSheetRule:case x.StyleDeclaration:return this.replaceIds(n.data,t,["id"]),this.replaceStyleIds(n.data,t,["styleId"]),n;case x.Font:return n;case x.Selection:return n.data.ranges.forEach(r=>{this.replaceIds(r,t,["start","end"])}),n;case x.AdoptedStyleSheet:return this.replaceIds(n.data,t,["id"]),this.replaceStyleIds(n.data,t,["styleIds"]),lo([n,"access",r=>r.data,"access",r=>r.styles,"optionalAccess",r=>r.forEach,"call",r=>r(s=>{this.replaceStyleIds(s,t,["styleId"])})]),n}}return!1}replace(t,n,r,s){for(const i of s)!Array.isArray(n[i])&&typeof n[i]!="number"||(Array.isArray(n[i])?n[i]=t.getIds(r,n[i]):n[i]=t.getId(r,n[i]));return n}replaceIds(t,n,r){return this.replace(this.crossOriginIframeMirror,t,n,r)}replaceStyleIds(t,n,r){return this.replace(this.crossOriginIframeStyleMirror,t,n,r)}replaceIdOnNode(t,n){this.replaceIds(t,n,["id","rootId"]),"childNodes"in t&&t.childNodes.forEach(r=>{this.replaceIdOnNode(r,n)})}patchRootIdOnNode(t,n){t.type!==ee.Document&&!t.rootId&&(t.rootId=n),"childNodes"in t&&t.childNodes.forEach(r=>{this.patchRootIdOnNode(r,n)})}}class Bm{init(){}addShadowRoot(){}observeAttachShadow(){}reset(){}}class $m{constructor(t){this.shadowDoms=new WeakSet,this.restoreHandlers=[],this.mutationCb=t.mutationCb,this.scrollCb=t.scrollCb,this.bypassOptions=t.bypassOptions,this.mirror=t.mirror,this.init()}init(){this.reset(),this.patchAttachShadow(Element,document)}addShadowRoot(t,n){if(!Qt(t)||this.shadowDoms.has(t))return;this.shadowDoms.add(t),this.bypassOptions.canvasManager.addShadowRoot(t);const r=fc({...this.bypassOptions,doc:n,mutationCb:this.mutationCb,mirror:this.mirror,shadowDomManager:this},t);this.restoreHandlers.push(()=>r.disconnect()),this.restoreHandlers.push(pc({...this.bypassOptions,scrollCb:this.scrollCb,doc:t,mirror:this.mirror})),hr(()=>{t.adoptedStyleSheets&&t.adoptedStyleSheets.length>0&&this.bypassOptions.stylesheetManager.adoptStyleSheets(t.adoptedStyleSheets,this.mirror.getId(t.host)),this.restoreHandlers.push(hc({mirror:this.mirror,stylesheetManager:this.bypassOptions.stylesheetManager},t))},0)}observeAttachShadow(t){const n=js(t),r=_m(t);!n||!r||this.patchAttachShadow(r.Element,n)}patchAttachShadow(t,n){const r=this;this.restoreHandlers.push(Ws(t.prototype,"attachShadow",function(s){return function(i){const o=s.call(this,i);return this.shadowRoot&&lc(this)&&r.addShadowRoot(this.shadowRoot,n),o}}))}reset(){this.restoreHandlers.forEach(t=>{try{t()}catch{}}),this.restoreHandlers=[],this.shadowDoms=new WeakSet,this.bypassOptions.canvasManager.resetShadowRoots()}}class fo{reset(){}freeze(){}unfreeze(){}lock(){}unlock(){}snapshot(){}addWindow(){}addShadowRoot(){}resetShadowRoots(){}}class Um{constructor(t){this.trackedLinkElements=new WeakSet,this.styleMirror=new fm,this.mutationCb=t.mutationCb,this.adoptedStyleSheetCb=t.adoptedStyleSheetCb}attachLinkElement(t,n){"_cssText"in n.attributes&&this.mutationCb({adds:[],removes:[],texts:[],attributes:[{id:n.id,attributes:n.attributes}]}),this.trackLinkElement(t)}trackLinkElement(t){this.trackedLinkElements.has(t)||(this.trackedLinkElements.add(t),this.trackStylesheetInLinkElement(t))}adoptStyleSheets(t,n){if(t.length===0)return;const r={id:n,styleIds:[]},s=[];for(const i of t){let o;this.styleMirror.has(i)?o=this.styleMirror.getId(i):(o=this.styleMirror.add(i),s.push({styleId:o,rules:Array.from(i.rules||CSSRule,(a,c)=>({rule:Ya(a),index:c}))})),r.styleIds.push(o)}s.length>0&&(r.styles=s),this.adoptedStyleSheetCb(r)}reset(){this.styleMirror.reset(),this.trackedLinkElements=new WeakSet}trackStylesheetInLinkElement(t){}}class Hm{constructor(){this.nodeMap=new WeakMap,this.active=!1}inOtherBuffer(t,n){const r=this.nodeMap.get(t);return r&&Array.from(r).some(s=>s!==n)}add(t,n){this.active||(this.active=!0,mm(()=>{this.nodeMap=new WeakMap,this.active=!1})),this.nodeMap.set(t,(this.nodeMap.get(t)||new Set).add(n))}destroy(){}}let Q,Zn;try{if(Array.from([1],e=>e*2)[0]!==2){const e=document.createElement("iframe");document.body.appendChild(e),Array.from=Pn([e,"access",t=>t.contentWindow,"optionalAccess",t=>t.Array,"access",t=>t.from])||Array.from,document.body.removeChild(e)}}catch(e){console.debug("Unable to override Array.from",e)}const ve=Uh();function Pe(e={}){const{emit:t,checkoutEveryNms:n,checkoutEveryNth:r,blockClass:s="rr
23-block",blockSelector:i=null,unblockSelector:o=null,ignoreClass:a="rr-ignore",ignoreSelector:c=null,maskAllText:u=!1,maskTextClass:d="rr-mask",unmaskTextClass:l=null,maskTextSelector:f=null,unmaskTextSelector:p=null,inlineStylesheet:h=!0,maskAllInputs:m,maskInputOptions:E,slimDOMOptions:S,maskAttributeFn:C,maskInputFn:F,maskTextFn:L,maxCanvasSize:v=null,packFn:g,sampling:T={},dataURLOptions:w={},mousemoveWait:_,recordDOM:b=!0,recordCanvas:N=!1,recordCrossOriginIframes:R=!1,recordAfter:G=e.recordAfter==="DOMContentLoaded"?e.recordAfter:"load",userTriggeredOnInput:J=!1,collectFonts:oe=!1,inlineImages:D=!1,plugins:ne,keepIframeSrcFn:W=()=>!1,ignoreCSSAttributes:pe=new Set([]),errorHandler:Ae,onMutation:Qs,getCanvasManager:$c}=e;vm(Ae);const gn=R?window.parent===window:!0;let Gt=!1;if(!gn)try{window.parent.document&&(Gt=!1)}catch{Gt=!0}if(gn&&!t)throw new Error("emit function is required");if(!gn&&!Gt)return()=>{};_!==void 0&&T.mousemove===void 0&&(T.mousemove=_),ve.reset();const Sr=m===!0?{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}:E!==void 0?E:{},Er=S===!0||S==="all"?{script:!0,comment:!0,headFavicon:!0,headWhitespace:!0,headMetaSocial:!0,headMetaRobots:!0,headMetaHttpEquiv:!0,headMetaVerification:!0,headMetaAuthorship:S==="all",headMetaDescKeywords:S==="all"}:S||{};dm();let br,vr=0;const Zs=j=>{for(const be of ne||[])be.eventProcessor&&(j=be.eventProcessor(j));return g&&!Gt&&(j=g(j)),j};Q=(j,be)=>{const U=j;if(U.timestamp=Jn(),Pn([kt,"access",K=>K[0],"optionalAccess",K=>K.isFrozen,"call",K=>K()])&&U.type!==P.FullSnapshot&&!(U.type===P.IncrementalSnapshot&&U.data.source===x.Mutation)&&kt.forEach(K=>K.unfreeze()),gn)Pn([t,"optionalCall",K=>K(Zs(U),be)]);else if(Gt){const K={type:"rrweb",event:Zs(U),origin:window.location.origin,isCheckout:be};window.parent.postMessage(K,"*")}if(U.type===P.FullSnapshot)br=U,vr=0;else if(U.type===P.IncrementalSnapshot){if(U.data.source===x.Mutation&&U.data.isAttachIframe)return;vr++;const K=r&&vr>=r,q=n&&br&&U.timestamp-br.timestamp>n;(K||q)&&wr(!0)}};const _n=j=>{Q({type:P.IncrementalSnapshot,data:{source:x.Mutation,...j}})},ei=j=>Q({type:P.IncrementalSnapshot,data:{source:x.Scroll,...j}}),Uc=j=>Q({type:P.IncrementalSnapshot,data:{source:x.CanvasMutation,...j}}),Hc=j=>Q({type:P.IncrementalSnapshot,data:{source:x.AdoptedStyleSheet,...j}}),rt=new Um({mutationCb:_n,adoptedStyleSheetCb:Hc}),st=typeof __RRWEB_EXCLUDE_IFRAME__=="boolean"&&__RRWEB_EXCLUDE_IFRAME__?new Pm:new Fm({mirror:ve,mutationCb:_n,stylesheetManager:rt,recordCrossOriginIframes:R,wrappedEmit:Q});for(const j of ne||[])j.getMirror&&j.getMirror({nodeMirror:ve,crossOriginIframeMirror:st.crossOriginIframeMirror,crossOriginIframeStyleMirror:st.crossOriginIframeStyleMirror});const Tr=new Hm,Ir=zm($c,{mirror:ve,win:window,mutationCb:j=>Q({type:P.IncrementalSnapshot,data:{source:x.CanvasMutation,...j}}),recordCanvas:N,blockClass:s,blockSelector:i,unblockSelector:o,maxCanvasSize:v,sampling:T.canvas,dataURLOptions:w,errorHandler:Ae}),yn=typeof __RRWEB_EXCLUDE_SHADOW_DOM__=="boolean"&&__RRWEB_EXCLUDE_SHADOW_DOM__?new Bm:new $m({mutationCb:_n,scrollCb:ei,bypassOptions:{onMutation:Qs,blockClass:s,blockSelector:i,unblockSelector:o,maskAllText:u,maskTextClass:d,unmaskTextClass:l,maskTextSelector:f,unmaskTextSelector:p,inlineStylesheet:h,maskInputOptions:Sr,dataURLOptions:w,maskAttributeFn:C,maskTextFn:L,maskInputFn:F,recordCanvas:N,inlineImages:D,sampling:T,slimDOMOptions:Er,iframeManager:st,stylesheetManager:rt,canvasManager:Ir,keepIframeSrcFn:W,processedNodeManager:Tr},mirror:ve}),wr=(j=!1)=>{if(!b)return;Q({type:P.Meta,data:{href:window.location.href,width:sc(),height:rc()}},j),rt.reset(),yn.init(),kt.forEach(U=>U.lock());const be=um(document,{mirror:ve,blockClass:s,blockSelector:i,unblockSelector:o,maskAllText:u,maskTextClass:d,unmaskTextClass:l,maskTextSelector:f,unmaskTextSelector:p,inlineStylesheet:h,maskAllInputs:Sr,maskAttributeFn:C,maskInputFn:F,maskTextFn:L,slimDOM:Er,dataURLOptions:w,recordCanvas:N,inlineImages:D,onSerialize:U=>{ac(U,ve)&&st.addIframe(U),cc(U,ve)&&rt.trackLinkElement(U),ps(U)&&yn.addShadowRoot(U.shadowRoot,document)},onIframeLoad:(U,K)=>{st.attachIframe(U,K),U.contentWindow&&Ir.addWindow(U.contentWindow),yn.observeAttachShadow(U)},onStylesheetLoad:(U,K)=>{rt.attachLinkElement(U,K)},keepIframeSrcFn:W});if(!be)return console.warn("Failed to snapshot the document");Q({type:P.FullSnapshot,data:{node:be,initialOffset:nc(window)}}),kt.forEach(U=>U.unlock()),document.adoptedStyleSheets&&document.adoptedStyleSheets.length>0&&rt.adoptStyleSheets(document.adoptedStyleSheets,ve.getId(document))};Zn=wr;try{const j=[],be=K=>H(Lm)({onMutation:Qs,mutationCb:_n,mousemoveCb:(q,it)=>Q({type:P.IncrementalSnapshot,data:{source:it,positions:q}}),mouseInteractionCb:q=>Q({type:P.IncrementalSnapshot,data:{source:x.MouseInteraction,...q}}),scrollCb:ei,viewportResizeCb:q=>Q({type:P.IncrementalSnapshot,data:{source:x.ViewportResize,...q}}),inputCb:q=>Q({type:P.IncrementalSnapshot,data:{source:x.Input,...q}}),mediaInteractionCb:q=>Q({type:P.IncrementalSnapshot,data:{source:x.MediaInteraction,...q}}),styleSheetRuleCb:q=>Q({type:P.IncrementalSnapshot,data:{source:x.StyleSheetRule,...q}}),styleDeclarationCb:q=>Q({type:P.IncrementalSnapshot,data:{source:x.StyleDeclaration,...q}}),canvasMutationCb:Uc,fontCb:q=>Q({type:P.IncrementalSnapshot,data:{source:x.Font,...q}}),selectionCb:q=>{Q({type:P.IncrementalSnapshot,data:{source:x.Selection,...q}})},customElementCb:q=>{Q({type:P.IncrementalSnapshot,data:{source:x.CustomElement,...q}})},blockClass:s,ignoreClass:a,ignoreSelector:c,maskAllText:u,maskTextClass:d,unmaskTextClass:l,maskTextSelector:f,unmaskTextSelector:p,maskInputOptions:Sr,inlineStylesheet:h,sampling:T,recordDOM:b,re
23cordCanvas:N,inlineImages:D,userTriggeredOnInput:J,collectFonts:oe,doc:K,maskAttributeFn:C,maskInputFn:F,maskTextFn:L,keepIframeSrcFn:W,blockSelector:i,unblockSelector:o,slimDOMOptions:Er,dataURLOptions:w,mirror:ve,iframeManager:st,stylesheetManager:rt,shadowDomManager:yn,processedNodeManager:Tr,canvasManager:Ir,ignoreCSSAttributes:pe,plugins:Pn([ne,"optionalAccess",q=>q.filter,"call",q=>q(it=>it.observer),"optionalAccess",q=>q.map,"call",q=>q(it=>({observer:it.observer,options:it.options,callback:Wc=>Q({type:P.Plugin,data:{plugin:it.name,payload:Wc}})}))])||[]},{});st.addLoadListener(K=>{try{j.push(be(K.contentDocument))}catch(q){console.warn(q)}});const U=()=>{wr(),j.push(be(document))};return document.readyState==="interactive"||document.readyState==="complete"?U():(j.push(le("DOMContentLoaded",()=>{Q({type:P.DomContentLoaded,data:{}}),G==="DOMContentLoaded"&&U()})),j.push(le("load",()=>{Q({type:P.Load,data:{}}),G==="load"&&U()},window))),()=>{j.forEach(K=>K()),Tr.destroy(),Zn=void 0,Tm()}}catch(j){console.warn(j)}}function Wm(e){if(!Zn)throw new Error("please take full snapshot after start recording");Zn(e)}Pe.mirror=ve;Pe.takeFullSnapshot=Wm;function zm(e,t){try{return e?e(t):new fo}catch{return console.warn("Unable to initialize CanvasManager"),new fo}}const jm=3,qm=5;function qs(e){return e>9999999999?e:e*1e3}function Fr(e){return e>9999999999?e/1e3:e}function mn(e,t){t.category!=="sentry.transaction"&&(["ui.click","ui.input"].includes(t.category)?e.triggerUserActivity():e.checkAndHandleExpiredSession(),e.addUpdate(()=>(e.throttledAddEvent({type:P.Custom,timestamp:(t.timestamp||0)*1e3,data:{tag:"breadcrumb",payload:Te(t,10,1e3)}}),t.category==="console")))}const Gm="button,a";function mc(e){return e.closest(Gm)||e}function gc(e){const t=_c(e);return!t||!(t instanceof Element)?t:mc(t)}function _c(e){return Ym(e)?e.target:e}function Ym(e){return typeof e=="object"&&!!e&&"target"in e}let qe;function Vm(e){return qe||(qe=[],Xm()),qe.push(e),()=>{const t=qe?qe.indexOf(e):-1;t>-1&&qe.splice(t,1)}}function Xm(){me(V,"open",function(e){return function(...t){if(qe)try{qe.forEach(n=>n())}catch{}return e.apply(V,t)}})}const Km=new Set([x.Mutation,x.StyleSheetRule,x.StyleDeclaration,x.AdoptedStyleSheet,x.CanvasMutation,x.Selection,x.MediaInteraction]);function Jm(e,t,n){e.handleClick(t,n)}class Qm{constructor(t,n,r=mn){this._lastMutation=0,this._lastScroll=0,this._clicks=[],this._timeout=n.timeout/1e3,this._threshold=n.threshold/1e3,this._scrollTimeout=n.scrollTimeout/1e3,this._replay=t,this._ignoreSelector=n.ignoreSelector,this._addBreadcrumbEvent=r}addListeners(){const t=Vm(()=>{this._lastMutation=po()});this._teardown=()=>{t(),this._clicks=[],this._lastMutation=0,this._lastScroll=0}}removeListeners(){this._teardown&&this._teardown(),this._checkClickTimeout&&clearTimeout(this._checkClickTimeout)}handleClick(t,n){if(eg(n,this._ignoreSelector)||!tg(t))return;const r={timestamp:Fr(t.timestamp),clickBreadcrumb:t,clickCount:0,node:n};this._clicks.some(s=>s.node===r.node&&Math.abs(s.timestamp-r.timestamp)<1)||(this._clicks.push(r),this._clicks.length===1&&this._scheduleCheckClicks())}registerMutation(t=Date.now()){this._lastMutation=Fr(t)}registerScroll(t=Date.now()){this._lastScroll=Fr(t)}registerClick(t){const n=mc(t);this._handleMultiClick(n)}_handleMultiClick(t){this._getClicks(t).forEach(n=>{n.clickCount++})}_getClicks(t){return this._clicks.filter(n=>n.node===t)}_checkClicks(){const t=[],n=po();this._clicks.forEach(r=>{!r.mutationAfter&&this._lastMutation&&(r.mutationAfter=r.timestamp<=this._lastMutation?this._lastMutation-r.timestamp:void 0),!r.scrollAfter&&this._lastScroll&&(r.scrollAfter=r.timestamp<=this._lastScroll?this._lastScroll-r.timestamp:void 0),r.timestamp+this._timeout<=n&&t.push(r)});for(const r of t){const s=this._clicks.indexOf(r);s>-1&&(this._generateBreadcrumbs(r),this._clicks.splice(s,1))}this._clicks.length&&this._scheduleCheckClicks()}_generateBreadcrumbs(t){const n=this._replay,r=t.scrollAfter&&t.scrollAfter<=this._scrollTimeout,s=t.mutationAfter&&t.mutationAfter<=this._threshold,i=!r&&!s,{clickCount:o,clickBreadcrumb:a}=t;if(i){const c=Math.min(t.mutationAfter||this._timeout,this._timeout)*1e3,u=c<this._timeout*1e3?"mutation":"timeout",d={type:"default",message:a.message,timestamp:a.timestamp,category:"ui.slowClickDetected",data:{...a.data,url:V.location.href,route:n.getCurrentRoute(),timeAfterClickMs:c,endReason:u,clickCount:o||1}};this._addBreadcrumbEvent(n,d);return}if(o>1){const c={type:"default",message:a.message,timestamp:a.timestamp,category:"ui.multiClick",data:{...a.data,url:V.location.href,route:n.getCurrentRoute(),clickCount:o,metric:!0}};this._addBreadcrumbEvent(n,c)}}_scheduleCheckClicks(){this._checkClickTimeout&&clearTimeout(this._checkClickTimeout),this._checkClickTimeout=Lt(()=>this._checkClicks(),1e3)}}const Zm=["A","BUTTON","INPUT"];function eg(e,t){return!!(!Zm.includes(e.tagName)||e.tagName==="INPUT"&&!["submit","button"].includes(e.getAttribute("type")||"")||e.tagName==="A"&&(e.hasAttribute("download")||e.hasAttribute("target")&&e.getAttribute("target")!=="_self")||t&&e.matches(t))}function tg(e){return!!(e.data&&typeof e.data.nodeId=="number"&&e.timestamp)}function po(){return Date.now()/1e3}function ng(e,t){try{if(!rg(t))return;const{source:n}=t.data;if(Km.has(n)&&e.registerMutation(t.timestamp),n===x.Scroll&&e.registerScroll(t.timestamp),sg(t)){const{type:r,id:s}=t.data,i=Pe.mirror.getNode(s);i instanceof HTMLElement&&r===ue.Click&&e.registerClick(i)}}catch{}}function rg(e){return e.type===jm}function sg(e){return e.data.source===x.MouseInteraction}function Me(e){return{timestamp:Date.now()/1e3,type:"default",...e}}var er;(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"})(er||(er={}));const ig=new Set(["id","class","aria-label","role","name","alt","title","data-test-id","data-testid","disabled","aria-disabled","data-sentry-component"]);function og(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(ig.has(n)){let r=n;(n==="data-testid"||n==="data-test-id")&&(r="testId"),t[r]=e[n]}return t}const ag=e=>t=>{if(!e.isEnabled())return;const n=cg(t);if(!n)return;
23const r=t.name==="click",s=r?t.event:void 0;r&&e.clickDetector&&s&&s.target&&!s.altKey&&!s.metaKey&&!s.ctrlKey&&!s.shiftKey&&Jm(e.clickDetector,n,gc(t.event)),mn(e,n)};function yc(e,t){const n=Pe.mirror.getId(e),r=n&&Pe.mirror.getNode(n),s=r&&Pe.mirror.getMeta(r),i=s&&lg(s)?s:null;return{message:t,data:i?{nodeId:n,node:{id:n,tagName:i.tagName,textContent:Array.from(i.childNodes).map(o=>o.type===er.Text&&o.textContent).filter(Boolean).map(o=>o.trim()).join(""),attributes:og(i.attributes)}}:{}}}function cg(e){const{target:t,message:n}=ug(e);return Me({category:`ui.${e.name}`,...yc(t,n)})}function ug(e){const t=e.name==="click";let n,r=null;try{r=t?gc(e.event):_c(e.event),n=$e(r,{maxStringLength:200})||"<unknown>"}catch{n="<unknown>"}return{target:r,message:n}}function lg(e){return e.type===er.Element}function dg(e,t){if(!e.isEnabled())return;e.updateUserActivity();const n=fg(t);n&&mn(e,n)}function fg(e){const{metaKey:t,shiftKey:n,ctrlKey:r,altKey:s,key:i,target:o}=e;if(!o||pg(o)||!i)return null;const a=t||r||s,c=i.length===1;if(!a&&c)return null;const u=$e(o,{maxStringLength:200})||"<unknown>",d=yc(o,u);return Me({category:"ui.keyDown",message:u,data:{...d.data,metaKey:t,shiftKey:n,ctrlKey:r,altKey:s,key:i}})}function pg(e){return e.tagName==="INPUT"||e.tagName==="TEXTAREA"||e.isContentEditable}const hg={resource:Sg,paint:_g,navigation:yg};function On(e,t){return({metric:n})=>void t.replayPerformanceEntries.push(e(n))}function mg(e){return e.map(gg).filter(Boolean)}function gg(e){const t=hg[e.entryType];return t?t(e):null}function Bt(e){return((fe||V.performance.timeOrigin)+e)/1e3}function _g(e){const{duration:t,entryType:n,name:r,startTime:s}=e,i=Bt(s);return{type:n,name:r,start:i,end:i+t,data:void 0}}function yg(e){const{entryType:t,name:n,decodedBodySize:r,duration:s,domComplete:i,encodedBodySize:o,domContentLoadedEventStart:a,domContentLoadedEventEnd:c,domInteractive:u,loadEventStart:d,loadEventEnd:l,redirectCount:f,startTime:p,transferSize:h,type:m}=e;return s===0?null:{type:`${t}.${m}`,start:Bt(p),end:Bt(i),name:n,data:{size:h,decodedBodySize:r,encodedBodySize:o,duration:s,domInteractive:u,domContentLoadedEventStart:a,domContentLoadedEventEnd:c,loadEventStart:d,loadEventEnd:l,domComplete:i,redirectCount:f}}}function Sg(e){const{entryType:t,initiatorType:n,name:r,responseEnd:s,startTime:i,decodedBodySize:o,encodedBodySize:a,responseStatus:c,transferSize:u}=e;return["fetch","xmlhttprequest"].includes(n)?null:{type:`${t}.${n}`,start:Bt(i),end:Bt(s),name:r,data:{size:u,statusCode:c,decodedBodySize:o,encodedBodySize:a}}}function Eg(e){const t=e.entries[e.entries.length-1],n=t&&t.element?[t.element]:void 0;return mr(e,"largest-contentful-paint",n)}function bg(e){return e.sources!==void 0}function vg(e){const t=[],n=[];for(const r of e.entries)if(bg(r)){const s=[];for(const i of r.sources)if(i.node){n.push(i.node);const o=Pe.mirror.getId(i.node);o&&s.push(o)}t.push({value:r.value,nodeIds:s.length?s:void 0})}return mr(e,"cumulative-layout-shift",n,t)}function Tg(e){const t=e.entries[e.entries.length-1],n=t&&t.target?[t.target]:void 0;return mr(e,"first-input-delay",n)}function Ig(e){const t=e.entries[e.entries.length-1],n=t&&t.target?[t.target]:void 0;return mr(e,"interaction-to-next-paint",n)}function mr(e,t,n,r){const s=e.value,i=e.rating,o=Bt(s);return{type:"web-vital",name:t,start:o,end:o,data:{value:s,size:s,rating:i,nodeIds:n?n.map(a=>Pe.mirror.getId(a)):void 0,attributions:r}}}function wg(e){function t(s){e.performanceEntries.includes(s)||e.performanceEntries.push(s)}function n({entries:s}){s.forEach(t)}const r=[];return["navigation","paint","resource"].forEach(s=>{r.push(Dt(s,n))}),r.push(La(On(Eg,e)),Ls(On(vg,e)),Pa(On(Tg,e)),Fa(On(Ig,e))),()=>{r.forEach(s=>s())}}const k=typeof __SENTRY_DEBUG__>"u"||__SENTRY_DEBUG__,kg='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}
vendor: 5,457 bytes, line 23
23},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;
23++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 Cg(){const e=new Blob([kg]);return URL.createObjectURL(e)}const ho=["info","warn","error","log"],$n="[Replay] ";
23function Br(e,t="info"){Qe({category:"console",data:{logger:"replay"},level:t,message:`${$n}${e}`},{level:t})}function Rg(){let e=!1,t=!1;const n={exception:()=>{},infoTick:()=>{},setConfig:r=>{e=r.captureExceptions,t=r.traceInternals}};return k?(ho.forEach(r=>{n[r]=(...s)=>{y[r]($n,...s),t&&Br(s.join(""),Sa(r))}}),n.exception=(r,...s)=>{s.length&&n.error&&n.error(...s),y.error($n,r),e?aa(r):t&&Br(r,"error")},n.infoTick=(...r)=>{y.info($n,...r),t&&setTimeout(()=>Br(r[0]),0)}):ho.forEach(r=>{n[r]=()=>{}}),n}const M=Rg();class Gs extends Error{constructor(){super(`Event buffer exceeded maximum size of ${$s}.`)}}class Sc{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(t){const n=JSON.stringify(t).length;if(this._totalSize+=n,this._totalSize>$s)throw new Gs;this.events.push(t)}finish(){return new Promise(t=>{const n=this.events;this.clear(),t(JSON.stringify(n))})}clear(){this.events=[],this._totalSize=0,this.hasCheckout=!1}getEarliestTimestamp(){const t=this.events.map(n=>n.timestamp).sort()[0];return t?qs(t):null}}class Mg{constructor(t){this._worker=t,this._id=0}ensureReady(){return this._ensureReadyPromise?this._ensureReadyPromise:(this._ensureReadyPromise=new Promise((t,n)=>{this._worker.addEventListener("message",({data:r})=>{r.success?t():n()},{once:!0}),this._worker.addEventListener("error",r=>{n(r)},{once:!0})}),this._ensureReadyPromise)}destroy(){k&&M.info("Destroying compression worker"),this._worker.terminate()}postMessage(t,n){const r=this._getAndIncrementId();return new Promise((s,i)=>{const o=({data:a})=>{const c=a;if(c.method===t&&c.id===r){if(this._worker.removeEventListener("message",o),!c.success){k&&M.error("Error in compression worker: ",c.response),i(new Error("Error in compression worker"));return}s(c.response)}};this._worker.addEventListener("message",o),this._worker.postMessage({id:r,method:t,arg:n})})}_getAndIncrementId(){return this._id++}}class xg{constructor(t){this._worker=new Mg(t),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(t){const n=qs(t.timestamp);(!this._earliestTimestamp||n<this._earliestTimestamp)&&(this._earliestTimestamp=n);const r=JSON.stringify(t);return this._totalSize+=r.length,this._totalSize>$s?Promise.reject(new Gs):this._sendEventToWorker(r)}finish(){return this._finishRequest()}clear(){this._earliestTimestamp=null,this._totalSize=0,this.hasCheckout=!1,this._worker.postMessage("clear").then(null,t=>{k&&M.exception(t,'Sending "clear" message to worker failed',t)})}getEarliestTimestamp(){return this._earliestTimestamp}_sendEventToWorker(t){return this._worker.postMessage("addEvent",t)}async _finishRequest(){const t=await this._worker.postMessage("finish");return this._earliestTimestamp=null,this._totalSize=0,t}}class Ag{constructor(t){this._fallback=new Sc,this._compression=new xg(t),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(t){this._used.hasCheckout=t}set waitForCheckout(t){this._used.waitForCheckout=t}destroy(){this._fallback.destroy(),this._compression.destroy()}clear(){return this._used.clear()}getEarliestTimestamp(){return this._used.getEarliestTimestamp()}addEvent(t){return this._used.addEvent(t)}async finish(){return await this.ensureWorkerIsLoaded(),this._used.finish()}ensureWorkerIsLoaded(){return this._ensureWorkerIsLoadedPromise}async _ensureWorkerIsLoaded(){try{await this._compression.ensureReady()}catch(t){k&&M.exception(t,"Failed to load the compression worker, falling back to simple buffer");return}await this._switchToCompressionWorker()}async _switchToCompressionWorker(){const{events:t,hasCheckout:n,waitForCheckout:r}=this._fallback,s=[];for(const i of t)s.push(this._compression.addEvent(i));this._compression.hasCheckout=n,this._compression.waitForCheckout=r,this._used=this._compression;try{await Promise.all(s),this._fallback.clear()}catch(i){k&&M.exception(i,"Failed to add events when switching buffers.")}}}function Og({useCompression:e,workerUrl:t}){if(e&&window.Worker){const n=Ng(t);if(n)return n}return k&&M.info("Using simple buffer"),new Sc}function Ng(e){try{const t=e||Dg();if(!t)return;k&&M.info(`Using compression worker${e?` from ${e}`:""}`);const n=new Worker(t);return new Ag(n)}catch(t){k&&M.exception(t,"Failed to create compression worker")}}function Dg(){return typeof __SENTRY_EXCLUDE_REPLAY_WORKER__>
23"u"||!__SENTRY_EXCLUDE_REPLAY_WORKER__?Cg():""}function Ys(){try{return"sessionStorage"in V&&!!V.sessionStorage}catch{return!1}}function Lg(e){Pg(),e.session=void 0}function Pg(){if(Ys())try{V.sessionStorage.removeItem(Fs)}catch{}}function Ec(e){return e===void 0?!1:Math.random()<e}function bc(e){const t=Date.now(),n=e.id||_e(),r=e.started||t,s=e.lastActivity||t,i=e.segmentId||0,o=e.sampled,a=e.previousSessionId;return{id:n,started:r,lastActivity:s,segmentId:i,sampled:o,previousSessionId:a}}function Vs(e){if(Ys())try{V.sessionStorage.setItem(Fs,JSON.stringify(e))}catch{}}function Fg(e,t){return Ec(e)?"session":t?"buffer":!1}function mo({sessionSampleRate:e,allowBuffering:t,stickySession:n=!1},{previousSessionId:r}={}){const s=Fg(e,t),i=bc({sampled:s,previousSessionId:r});return n&&Vs(i),i}function Bg(){if(!Ys())return null;try{const e=V.sessionStorage.getItem(Fs);if(!e)return null;const t=JSON.parse(e);return k&&M.infoTick("Loading existing session"),bc(t)}catch{return null}}function gs(e,t,n=+new Date){return e===null||t===void 0||t<0?!0:t===0?!1:e+t<=n}function vc(e,{maxReplayDuration:t,sessionIdleExpire:n,targetTime:r=Date.now()}){return gs(e.started,t,r)||gs(e.lastActivity,n,r)}function Tc(e,{sessionIdleExpire:t,maxReplayDuration:n}){return!(!vc(e,{sessionIdleExpire:t,maxReplayDuration:n})||e.sampled==="buffer"&&e.segmentId===0)}function $r({sessionIdleExpire:e,maxReplayDuration:t,previousSessionId:n},r){const s=r.stickySession&&Bg();return s?Tc(s,{sessionIdleExpire:e,maxReplayDuration:t})?(k&&M.infoTick("Session in sessionStorage is expired, creating new one..."),mo(r,{previousSessionId:s.id})):s:(k&&M.infoTick("Creating new session"),mo(r,{previousSessionId:n}))}function $g(e){return e.type===P.Custom}function Xs(e,t,n){return wc(e,t)?(Ic(e,t,n),!0):!1}function Ug(e,t,n){return wc(e,t)?Ic(e,t,n):Promise.resolve(null)}async function Ic(e,t,n){const{eventBuffer:r}=e;if(!r||r.waitForCheckout&&!n)return null;const s=e.recordingMode==="buffer";try{n&&s&&r.clear(),n&&(r.hasCheckout=!0,r.waitForCheckout=!1);const i=e.getOptions(),o=Hg(t,i.beforeAddRecordingEvent);return o?await r.addEvent(o):void 0}catch(i){const o=i&&i instanceof Gs,a=o?"addEventSizeExceeded":"addEvent";if(o&&s)return r.clear(),r.waitForCheckout=!0,null;e.handleException(i),await e.stop({reason:a});const c=B();c&&c.recordDroppedEvent("internal_sdk_error","replay")}}function wc(e,t){if(!e.eventBuffer||e.isPaused()||!e.isEnabled())return!1;const n=qs(t.timestamp);return n+e.timeouts.sessionIdlePause<Date.now()?!1:n>e.getContext().initialTimestamp+e.getOptions().maxReplayDuration?(k&&M.infoTick(`Skipping event with timestamp ${n} because it is after maxReplayDuration`),!1):!0}function Hg(e,t){try{if(typeof t=="function"&&$g(e))return t(e)}catch(n){return k&&M.exception(n,"An error occurred in the `beforeAddRecordingEvent` callback, skipping the event..."),null}return e}function Ks(e){return!e.type}function _s(e){return e.type==="transaction"}function Wg(e){return e.type==="replay_event"}function go(e){return e.type==="feedback"}function zg(e){return(t,n)=>{if(!e.isEnabled()||!Ks(t)&&!_s(t))return;const r=n&&n.statusCode;if(!(!r||r<200||r>=300)){if(_s(t)){jg(e,t);return}qg(e,t)}}}function jg(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 qg(e,t){const n=e.getContext();if(t.event_id&&n.errorIds.size<100&&n.errorIds.add(t.event_id),e.recordingMode!=="buffer"||!t.tags||!t.tags.replayId)return;const{beforeErrorSampling:r}=e.getOptions();typeof r=="function"&&!r(t)||Lt(async()=>{try{await e.sendBufferedReplayOrFlush()}catch(s){e.handleException(s)}})}function Gg(e){return t=>{!e.isEnabled()||!Ks(t)||Yg(e,t)}}function Yg(e,t){const n=t.exception&&t.exception.values&&t.exception.values[0]&&t.exception.values[0].value;if(typeof n=="string"&&(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))){const r=Me({category:"replay.hydrate-error",data:{url:Ao()}});mn(e,r)}}function Vg(e){const t=B();t&&t.on("beforeAddBreadcrumb",n=>Xg(e,n))}function Xg(e,t){if(!e.isEnabled()||!kc(t))return;const n=Kg(t);n&&mn(e,n)}function Kg(e){return!kc(e)||["fetch","xhr","sentry.event","sentry.transaction"].includes(e.category)||e.category.startsWith("ui.")?null:e.category==="console"?Jg(e):Me(e)}function Jg(e){const t=e.data&&e.data.arguments;if(!Array.isArray(t)||t.length===0)return Me(e);let n=!1;const r=t.map(s=>{if(!s)return s;if(typeof s=="string")return s.length>Mn?(n=!0,`${s.slice(0,Mn)}â¦`):s;if(typeof s=="object")try{const i=Te(s,7);return JSON.stringify(i).length>Mn?(n=!0,`${JSON.stringify(i,null,2).slice(0,Mn)}â¦`):i}catch{}return s});return Me({...e,data:{...e.data,arguments:r,...n?{_meta:{warnings:["CONSOLE_ARG_TRUNCATED"]}}:{}}})}function kc(e){return!!e.category}function Qg(e,t){return e.type||!e.exception||!e.exception.values||!e.exception.values.length?!1:!!(t.originalException&&t.originalException.__rrweb__)}function Cc(){const e=X().getPropagationContext().dsc;e&&delete e.replay_id;const t=ie();if(t){const n=yt(t);delete n.replay_id}}function Zg(e,t){e.triggerUserActivity(),e.addUpdate(()=>t.timestamp?(e.throttledAddEvent({type:P.Custom,timestamp:t.timestamp*1e3,data:{tag:"breadcrumb",payload:{timestamp:t.timestamp,type:"default",category:"sentry.feedback",data:{feedbackId:t.event_id}}}}),!1):!0)}function e_(e,t){return e.recordingMode!=="buffer"||t.message===Bs||!t.exception||t.type?!1:Ec(e.getOptions().errorSampleRate)}function t_(e){return Object.assign((t,n)=>
23!e.isEnabled()||e.isPaused()?t:Wg(t)?(delete t.breadcrumbs,t):!Ks(t)&&!_s(t)&&!go(t)?t:e.checkAndHandleExpiredSession()?go(t)?(e.flush(),t.contexts.feedback.replay_id=e.getSessionId(),Zg(e,t),t):Qg(t,n)&&!e.getOptions()._experiments.captureExceptions?(k&&M.log("Ignoring error from rrweb internals",t),null):((e_(e,t)||e.recordingMode==="session")&&(t.tags={...t.tags,replayId:e.getSessionId()}),t):(Cc(),t),{id:"Replay"})}function gr(e,t){return t.map(({type:n,start:r,end:s,name:i,data:o})=>{const a=e.throttledAddEvent({type:P.Custom,timestamp:r,data:{tag:"performanceSpan",payload:{op:n,description:i,startTimestamp:r,endTimestamp:s,data:o}}});return typeof a=="string"?Promise.resolve(null):a})}function n_(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 r_(e){return t=>{if(!e.isEnabled())return;const n=n_(t);n!==null&&(e.getContext().urls.push(n.name),e.triggerUserActivity(),e.addUpdate(()=>(gr(e,[n]),!1)))}}function s_(e,t){return k&&e.getOptions()._experiments.traceInternals?!1:td(t,B())}function Rc(e,t){e.isEnabled()&&t!==null&&(s_(e,t.name)||e.addUpdate(()=>(gr(e,[t]),!0)))}function _r(e){if(!e)return;const t=new TextEncoder;try{if(typeof e=="string")return t.encode(e).length;if(e instanceof URLSearchParams)return t.encode(e.toString()).length;if(e instanceof FormData){const n=Oc(e);return t.encode(n).length}if(e instanceof Blob)return e.size;if(e instanceof ArrayBuffer)return e.byteLength}catch{}}function Mc(e){if(!e)return;const t=parseInt(e,10);return isNaN(t)?void 0:t}function xc(e){try{if(typeof e=="string")return[e];if(e instanceof URLSearchParams)return[e.toString()];if(e instanceof FormData)return[Oc(e)];if(!e)return[void 0]}catch(t){return k&&M.exception(t,"Failed to serialize body",e),[void 0,"BODY_PARSE_ERROR"]}return k&&M.info("Skipping network body because of body type",e),[void 0,"UNPARSEABLE_BODY_TYPE"]}function tr(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 Ac(e,t){if(!t)return null;const{startTimestamp:n,endTimestamp:r,url:s,method:i,statusCode:o,request:a,response:c}=t;return{type:e,start:n/1e3,end:r/1e3,name:s,data:te({method:i,statusCode:o,request:a,response:c})}}function on(e){return{headers:{},size:e,_meta:{warnings:["URL_SKIPPED"]}}}function Ve(e,t,n){if(!t&&Object.keys(e).length===0)return;if(!t)return{headers:e};if(!n)return{headers:e,size:t};const r={headers:e,size:t},{body:s,warnings:i}=i_(n);return r.body=s,i&&i.length>0&&(r._meta={warnings:i}),r}function ys(e,t){return Object.entries(e).reduce((n,[r,s])=>{const i=r.toLowerCase();return t.includes(i)&&e[r]&&(n[i]=s),n},{})}function Oc(e){return new URLSearchParams(e).toString()}function i_(e){if(!e||typeof e!="string")return{body:e};const t=e.length>Xi,n=o_(e);if(t){const r=e.slice(0,Xi);return n?{body:r,warnings:["MAYBE_JSON_TRUNCATED"]}:{body:`${r}â¦`,warnings:["TEXT_TRUNCATED"]}}if(n)try{return{body:JSON.parse(e)}}catch{}return{body:e}}function o_(e){const t=e[0],n=e[e.length-1];return t==="["&&n==="]"||t==="{"&&n==="}"}function nr(e,t){const n=a_(e);return Ye(n,t)}function a_(e,t=V.document.baseURI){if(e.startsWith("http://")||e.startsWith("https://")||e.startsWith(V.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 c_(e,t,n){try{const r=await l_(e,t,n),s=Ac("resource.fetch",r);Rc(n.replay,s)}catch(r){k&&M.exception(r,"Failed to capture fetch breadcrumb")}}function u_(e,t){const{input:n,response:r}=t,s=n?Nc(n):void 0,i=_r(s),o=r?Mc(r.headers.get("content-length")):void 0;i!==void 0&&(e.data.request_body_size=i),o!==void 0&&(e.data.response_body_size=o)}async function l_(e,t,n){const r=Date.now(),{startTimestamp:s=r,endTimestamp:i=r}=t,{url:o,method:a,status_code:c=0,request_body_size:u,response_body_size:d}=e.data,l=nr(o,n.networkDetailAllowUrls)&&!nr(o,n.networkDetailDenyUrls),f=l?d_(n,t.input,u):on(u),p=await f_(l,n,t.response,d);return{startTimestamp:s,endTimestamp:i,url:o,method:a,statusCode:c,request:f,response:p}}function d_({networkCaptureBodies:e,networkRequestHeaders:t},n,r){const s=n?m_(n,t):{};if(!e)return Ve(s,r,void 0);const i=Nc(n),[o,a]=xc(i),c=Ve(s,r,o);return a?tr(c,a):c}async function f_(e,{networkCaptureBodies:t,networkResponseHeaders:n}
23,r,s){if(!e&&s!==void 0)return on(s);const i=r?Dc(r.headers,n):{};if(!r||!t&&s!==void 0)return Ve(i,s,void 0);const[o,a]=await h_(r),c=p_(o,{networkCaptureBodies:t,responseBodySize:s,captureDetails:e,headers:i});return a?tr(c,a):c}function p_(e,{networkCaptureBodies:t,responseBodySize:n,captureDetails:r,headers:s}){try{const i=e&&e.length&&n===void 0?_r(e):n;return r?t?Ve(s,i,e):Ve(s,i,void 0):on(i)}catch(i){return k&&M.exception(i,"Failed to serialize response body"),Ve(s,n,void 0)}}async function h_(e){const t=g_(e);if(!t)return[void 0,"BODY_PARSE_ERROR"];try{return[await __(t)]}catch(n){return n instanceof Error&&n.message.indexOf("Timeout")>-1?(k&&M.warn("Parsing text body from response timed out"),[void 0,"BODY_PARSE_TIMEOUT"]):(k&&M.exception(n,"Failed to get text body from response"),[void 0,"BODY_PARSE_ERROR"])}}function Nc(e=[]){if(!(e.length!==2||typeof e[1]!="object"))return e[1].body}function Dc(e,t){const n={};return t.forEach(r=>{e.get(r)&&(n[r]=e.get(r))}),n}function m_(e,t){return e.length===1&&typeof e[0]!="string"?_o(e[0],t):e.length===2?_o(e[1],t):{}}function _o(e,t){if(!e)return{};const n=e.headers;return n?n instanceof Headers?Dc(n,t):Array.isArray(n)?{}:ys(n,t):{}}function g_(e){try{return e.clone()}catch(t){k&&M.exception(t,"Failed to clone response body")}}function __(e){return new Promise((t,n)=>{const r=Lt(()=>n(new Error("Timeout while trying to read response body")),500);y_(e).then(s=>t(s),s=>n(s)).finally(()=>clearTimeout(r))})}async function y_(e){return await e.text()}async function S_(e,t,n){try{const r=b_(e,t,n),s=Ac("resource.xhr",r);Rc(n.replay,s)}catch(r){k&&M.exception(r,"Failed to capture xhr breadcrumb")}}function E_(e,t){const{xhr:n,input:r}=t;if(!n)return;const s=_r(r),i=n.getResponseHeader("content-length")?Mc(n.getResponseHeader("content-length")):w_(n.response,n.responseType);s!==void 0&&(e.data.request_body_size=s),i!==void 0&&(e.data.response_body_size=i)}function b_(e,t,n){const r=Date.now(),{startTimestamp:s=r,endTimestamp:i=r,input:o,xhr:a}=t,{url:c,method:u,status_code:d=0,request_body_size:l,response_body_size:f}=e.data;if(!c)return null;if(!a||!nr(c,n.networkDetailAllowUrls)||nr(c,n.networkDetailDenyUrls)){const g=on(l),T=on(f);return{startTimestamp:s,endTimestamp:i,url:c,method:u,statusCode:d,request:g,response:T}}const p=a[at],h=p?ys(p.request_headers,n.networkRequestHeaders):{},m=ys(v_(a),n.networkResponseHeaders),[E,S]=n.networkCaptureBodies?xc(o):[void 0],[C,F]=n.networkCaptureBodies?T_(a):[void 0],L=Ve(h,l,E),v=Ve(m,f,C);return{startTimestamp:s,endTimestamp:i,url:c,method:u,statusCode:d,request:S?tr(L,S):L,response:F?tr(v,F):v}}function v_(e){const t=e.getAllResponseHeaders();return t?t.split(`\r 24`).reduce((n,r)=>{const[s,i]=r.split(": ");return i&&(n[s.toLowerCase()]=i),n},{}):{}}function T_(e){const t=[];try{return[e.responseText]}catch(n){t.push(n)}try{return I_(e.response,e.responseType)}catch(n){t.push(n)}return k&&M.warn("Failed to get xhr response body",...t),[void 0]}function I_(e,t){try{if(typeof e=="string")return[e];if(e instanceof Document)return[e.body.outerHTML];if(t==="json"&&e&&typeof e=="object")return[JSON.stringify(e)];if(!e)return[void 0]}catch(n){return k&&M.exception(n,"Failed to serialize body",e),[void 0,"BODY_PARSE_ERROR"]}return k&&M.info("Skipping network body because of body type",e),[void 0,"UNPARSEABLE_BODY_TYPE"]}function w_(e,t){try{const n=t==="json"&&e&&typeof e=="object"?JSON.stringify(e):e;return _r(n)}catch{return}}function k_(e){const t=B();try{const{networkDetailAllowUrls:n,networkDetailDenyUrls:r,networkCaptureBodies:s,networkRequestHeaders:i,networkResponseHeaders:o}=e.getOptions(),a={replay:e,networkDetailAllowUrls:n,networkDetailDenyUrls:r,networkCaptureBodies:s,networkRequestHeaders:i,networkResponseHeaders:o};t&&t.on("beforeAddBreadcrumb",(c,u)=>C_(a,c,u))}catch{}}function C_(e,t,n){if(t.data)try{R_(t)&&x_(n)&&(E_(t,n),S_(t,n,e)),M_(t)&&A_(n)&&(u_(t,n),c_(t,n,e))}catch(r){k&&M.exception(r,"Error when enriching network breadcrumb")}}function R_(e){return e.category==="xhr"}function M_(e){return e.category==="fetch"}function x_(e){return e&&e.xhr}function A_(e){return e&&e.response}function O_(e){const t=B();Wa(ag(e)),dr(r_(e)),Vg(e),k_(e);const n=t_(e);Dl(n),t&&(t.on("beforeSendEvent",Gg(e)),t.on("afterSendEvent",zg(e)),t.on("createDsc",r=>{const s=e.getSessionId();s&&e.isEnabled()&&e.recordingMode==="session"&&e.checkAndHandleExpiredSession()&&(r.replay_id=s)}),t.on("spanStart",r=>{e.lastActiveSpan=r}),t.on("spanEnd",r=>{e.lastActiveSpan=r}),t.on("beforeSendFeedback",(r,s)=>{const i=e.getSessionId();s&&s.includeReplay&&e.isEnabled()&&i&&r.contexts&&r.contexts.feedback&&(r.contexts.feedback.replay_id=i)}))}async function N_(e){try{return Promise.all(gr(e,[D_(V.performance.memory)]))}catch{return[]}}function D_(e){const{jsHeapSizeLimit:t,totalJSHeapSize:n,usedJSHeapSize:r}=e,s=Date.now()/1e3;return{type:"memory",name:"memory",start:s,end:s,data:{memory:{jsHeapSizeLimit:t,totalJSHeapSize:n,usedJSHeapSize:r}}}}function L_(e,t,n){let r,s,i;const o=n&&n.maxWait?Math.max(n.maxWait,t):0;function a(){return c(),r=e(),r}function c(){s!==void 0&&clearTimeout(s),i!==void 0&&clearTimeout(i),s=i=void 0}function u(){return s!==void 0||i!==void 0?a():r}function d(){return s&&clearTimeout(s),s=Lt(a,t),o&&i===void 0&&(i=Lt(a,o)),r}return d.cancel=c,d.flush=u,d}const ot=$.navigator;function P_(){return/iPhone|iPad|iPod/i.test(ot&&ot.userAgent||"")||/Macintosh/i.test(ot&&ot.userAgent||"")&&ot&&ot.maxTouchPoints&&ot.maxTouchPoints>1?{sampling:{mousemove:!1}}:{}}function F_(e){let t=!1;return(n,r)=>{if(!e.checkAndHandleExpiredSession()){k&&M.warn("Received replay event after session expired.");return}const s=r||!t;t=!0,e.clickDetector&&ng(e.clickDetector,n),e.addUpdate(()=>{if(e.recordingMode==="buffer"&&s&&e.setInitialState(),!Xs(e,n,s))return!0;
24if(!s)return!1;const i=e.session;if($_(e,s),e.recordingMode==="buffer"&&i&&e.eventBuffer){const o=e.eventBuffer.getEarliestTimestamp();o&&(k&&M.info(`Updating session start time to earliest event in buffer to ${new Date(o)}`),i.started=o,e.getOptions().stickySession&&Vs(i))}return i&&i.previousSessionId||e.recordingMode==="session"&&e.flush(),!0})}}function B_(e){const t=e.getOptions();return{type:P.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?e.eventBuffer.type==="worker":!1,networkDetailHasUrls:t.networkDetailAllowUrls.length>0,networkCaptureBodies:t.networkCaptureBodies,networkRequestHasHeaders:t.networkRequestHeaders.length>0,networkResponseHasHeaders:t.networkResponseHeaders.length>0}}}}function $_(e,t){!t||!e.session||e.session.segmentId!==0||Xs(e,B_(e),!1)}function U_(e,t,n,r){return St(ta(e,Ms(e),r,n),[[{type:"replay_event"},e],[{type:"replay_recording",length:typeof t=="string"?new TextEncoder().encode(t).length:t.length},t]])}function H_({recordingData:e,headers:t}){let n;const r=`${JSON.stringify(t)} 25`;if(typeof e=="string")n=`${r}${e}`;else{const i=new TextEncoder().encode(r);n=new Uint8Array(i.length+e.length),n.set(i),n.set(e,i.length)}return n}async function W_({client:e,scope:t,replayId:n,event:r}){const s=typeof e._integrations=="object"&&e._integrations!==null&&!Array.isArray(e._integrations)?Object.keys(e._integrations):void 0,i={event_id:n,integrations:s};e.emit("preprocessEvent",r,i);const o=await oa(e.getOptions(),r,i,t,e,ke());if(!o)return null;o.platform=o.platform||"javascript";const a=e.getSdkMetadata(),{name:c,version:u}=a&&a.sdk||{};return o.sdk={...o.sdk,name:c||"sentry.javascript.unknown",version:u||"0.0.0"},o}async function z_({recordingData:e,replayId:t,segmentId:n,eventContext:r,timestamp:s,session:i}){const o=H_({recordingData:e,headers:{segment_id:n}}),{urls:a,errorIds:c,traceIds:u,initialTimestamp:d}=r,l=B(),f=X(),p=l&&l.getTransport(),h=l&&l.getDsn();if(!l||!p||!h||!i.sampled)return Ue({});const m={type:bh,replay_start_timestamp:d/1e3,timestamp:s/1e3,error_ids:c,trace_ids:u,urls:a,replay_id:t,segment_id:n,replay_type:i.sampled},E=await W_({scope:f,client:l,replayId:t,event:m});if(!E)return l.recordDroppedEvent("event_processor","replay",m),k&&M.info("An event processor returned `null`, will not send event."),Ue({});delete E.sdkProcessingMetadata;const S=U_(E,o,h,l.getOptions().tunnel);let C;try{C=await p.send(S)}catch(L){const v=new Error(Bs);try{v.cause=L}catch{}throw v}if(typeof C.statusCode=="number"&&(C.statusCode<200||C.statusCode>=300))throw new Lc(C.statusCode);const F=ga({},C);if(ma(F,"replay"))throw new Js(F);return C}class Lc extends Error{constructor(t){super(`Transport returned status code ${t}`)}}class Js extends Error{constructor(t){super("Rate limit hit"),this.rateLimits=t}}async function Pc(e,t={count:0,interval:Ch}){const{recordingData:n,onError:r}=e;if(n.length)try{return await z_(e),!0}catch(s){if(s instanceof Lc||s instanceof Js)throw s;if(ua("Replays",{_retryCount:t.count}),r&&r(s),t.count>=Rh){const i=new Error(`${Bs} - max retries exceeded`);try{i.cause=s}catch{}throw i}return t.interval*=++t.count,new Promise((i,o)=>{Lt(async()=>{try{await Pc(e,t),i(!0)}catch(a){o(a)}},t.interval)})}}const Fc="__THROTTLED",j_="__SKIPPED";function q_(e,t,n){const r=new Map,s=a=>{const c=a-n;r.forEach((u,d)=>{d<c&&r.delete(d)})},i=()=>[...r.values()].reduce((a,c)=>a+c,0);let o=!1;return(...a)=>{const c=Math.floor(Date.now()/1e3);if(s(c),i()>=t){const d=o;return o=!0,d?j_:Fc}o=!1;const u=r.get(c)||0;return r.set(c,u+1),e(...a)}}class Ge{constructor({options:t,recordingOptions:n}){Ge.prototype.__init.call(this),Ge.prototype.__init2.call(this),Ge.prototype.__init3.call(this),Ge.prototype.__init4.call(this),Ge.prototype.__init5.call(this),Ge.prototype.__init6.call(this),this.eventBuffer=null,this.performanceEntries=[],this.replayPerformanceEntries=[],this.recordingMode="session",this.timeouts={sessionIdlePause:vh,sessionIdleExpire:Th},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=n,this._options=t,this._debouncedFlush=L_(()=>this._flush(),this._options.flushMinDelay,{maxWait:this._options.flushMaxDelay}),this._throttledAddEvent=q_((o,a)=>Ug(this,o,a),300,5);const{slowClickTimeout:r,slowClickIgnoreSelectors:s}=this.getOptions(),i=r?{threshold:Math.min(Mh,r),timeout:r,scrollTimeout:xh,ignoreSelector:s?s.join(","):""}:void 0;if(i&&(this.clickDetector=new Qm(this,i)),k){const o=t._experiments;M.setConfig({captureExceptions:!!o.captureExceptions,traceInternals:!!o.traceInternals})}}getContext(){return this._context}isEnabled(){return this._isEnabled}isPaused(){return this._isPaused}isRecordingCanvas(){return!!this._canvas}getOptions(){return this._options}handleException(t){k&&M.exception(t),this._options.onError&&this._options.onError(t)}initializeSampling(t){const{errorSampleRate:n,sessionSampleRate:r}=this._options,s=n<=0&&r<=0;if(this._requiresManualStart=s,!s){if(this._initializeSessionForSampling(t),!this.session){k&&M.exception(new Error("Unable to initialize and create session"));return}this.session.sampled!==!1&&(this.recordingMode=this.session.sampled==="buffer"&&this.session.segmentId===0?"buffer":"session",k&&M.infoTick(`Starting replay in ${this.recordingMode} mode`),this._initializeRecording())}}
25start(){if(this._isEnabled&&this.recordingMode==="session"){k&&M.info("Recording is already in progress");return}if(this._isEnabled&&this.recordingMode==="buffer"){k&&M.info("Buffering is in progress, call `flush()` to save the replay");return}k&&M.infoTick("Starting replay in session mode"),this._updateUserActivity();const t=$r({maxReplayDuration:this._options.maxReplayDuration,sessionIdleExpire:this.timeouts.sessionIdleExpire},{stickySession:this._options.stickySession,sessionSampleRate:1,allowBuffering:!1});this.session=t,this._initializeRecording()}startBuffering(){if(this._isEnabled){k&&M.info("Buffering is in progress, call `flush()` to save the replay");return}k&&M.infoTick("Starting replay in buffer mode");const t=$r({sessionIdleExpire:this.timeouts.sessionIdleExpire,maxReplayDuration:this._options.maxReplayDuration},{stickySession:this._options.stickySession,sessionSampleRate:0,allowBuffering:!0});this.session=t,this.recordingMode="buffer",this._initializeRecording()}startRecording(){try{const t=this._canvas;this._stopRecording=Pe({...this._recordingOptions,...this.recordingMode==="buffer"?{checkoutEveryNms:kh}:this._options._experiments.continuousCheckout&&{checkoutEveryNms:Math.max(36e4,this._options._experiments.continuousCheckout)},emit:F_(this),...P_(),onMutation:this._onMutationHandler,...t?{recordCanvas:t.recordCanvas,getCanvasManager:t.getCanvasManager,sampling:t.sampling,dataURLOptions:t.dataURLOptions}:{}})}catch(t){this.handleException(t)}}stopRecording(){try{return this._stopRecording&&(this._stopRecording(),this._stopRecording=void 0),!0}catch(t){return this.handleException(t),!1}}async stop({forceFlush:t=!1,reason:n}={}){if(this._isEnabled){this._isEnabled=!1;try{k&&M.info(`Stopping Replay${n?` triggered by ${n}`:""}`),Cc(),this._removeListeners(),this.stopRecording(),this._debouncedFlush.cancel(),t&&await this._flush({force:!0}),this.eventBuffer&&this.eventBuffer.destroy(),this.eventBuffer=null,Lg(this)}catch(r){this.handleException(r)}}}pause(){this._isPaused||(this._isPaused=!0,this.stopRecording(),k&&M.info("Pausing replay"))}resume(){!this._isPaused||!this._checkSession()||(this._isPaused=!1,this.startRecording(),k&&M.info("Resuming replay"))}async sendBufferedReplayOrFlush({continueRecording:t=!0}={}){if(this.recordingMode==="session")return this.flushImmediate();const n=Date.now();k&&M.info("Converting buffer to session"),await this.flushImmediate();const r=this.stopRecording();!t||!r||this.recordingMode!=="session"&&(this.recordingMode="session",this.session&&(this._updateUserActivity(n),this._updateSessionActivity(n),this._maybeSaveSession()),this.startRecording())}addUpdate(t){const n=t();this.recordingMode!=="buffer"&&n!==!0&&this._debouncedFlush()}triggerUserActivity(){if(this._updateUserActivity(),!this._stopRecording){if(!this._checkSession())return;this.resume();return}this.checkAndHandleExpiredSession(),this._updateSessionActivity()}updateUserActivity(){this._updateUserActivity(),this._updateSessionActivity()}conditionalFlush(){return this.recordingMode==="buffer"?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&&gs(this._lastActivity,this.timeouts.sessionIdlePause)&&this.session&&this.session.sampled==="session"){this.pause();return}return!!this._checkSession()}setInitialState(){const t=`${V.location.pathname}${V.location.hash}${V.location.search}`,n=`${V.location.origin}${t}`;this.performanceEntries=[],this.replayPerformanceEntries=[],this._clearContext(),this._context.initialUrl=n,this._context.initialTimestamp=Date.now(),this._context.urls.push(n)}throttledAddEvent(t,n){const r=this._throttledAddEvent(t,n);if(r===Fc){const s=Me({category:"replay.throttled"});this.addUpdate(()=>!Xs(this,{type:qm,timestamp:s.timestamp||0,data:{tag:"breadcrumb",payload:s,metric:!0}}))}return r}getCurrentRoute(){const t=this.lastActiveSpan||ie(),n=t&&ce(t),s=(n&&z(n).data||{})[Re];if(!(!n||!s||!["route","custom"].includes(s)))return z(n).description}_initializeRecording(){this.setInitialState(),this._updateSessionActivity(),this.eventBuffer=Og({useCompression:this._options.useCompression,workerUrl:this._options.workerUrl}),this._removeListeners(),this._addListeners(),this._isEnabled=!0,this._isPaused=!1,this.startRecording()}_initializeSessionForSampling(t){const n=this._options.errorSampleRate>0,r=$r({sessionIdleExpire:this.timeouts.sessionIdleExpire,maxReplayDuration:this._options.maxReplayDuration,previousSessionId:t},{stickySession:this._options.stickySession,sessionSampleRate:this._options.sessionSampleRate,allowBuffering:n});this.session=r}_checkSession(){if(!this.session)return!1;const t=this.session;return Tc(t,{sessionIdleExpire:this.timeouts.sessionIdleExpire,maxReplayDuration:this._options.maxReplayDuration})?(this._refreshSession(t),!1):!0}async _refreshSession(t){this._isEnabled&&(await this.stop({reason:"refresh session"}),this.initializeSampling(t.id))}_addListeners(){try{V.document.addEventListener("visibilitychange",this._handleVisibilityChange),V.addEventListener("blur",this._handleWindowBlur),V.addEventListener("focus",this._handleWindowFocus),V.addEventListener("keydown",this._handleKeyboardEvent),this.clickDetector&&this.clickDetector.addListeners(),this._hasInitializedCoreListeners||(O_(this),this._hasInitializedCoreListeners=!0)}catch(t){this.handleException(t)}this._performanceCleanupCallback=wg(this)}_removeListeners(){try{V.document.removeEventListener("visibilitychange",this._handleVisibilityChange),V.removeEventListener("blur",this._handleWindowBlur),V.removeEventListener("focus",this._handleWindowFocus),V.removeEventListener("keydown",this._handleKeyboardEvent),this.clickDetector&&this.clickDetector.removeListeners(),this._performanceCleanupCallback&&this._performanceCleanupCallback()}catch(t){this.handleException(t)}}__init(){this._handleVisibilityChange=()=>{V.document.visibilityState==="visible"?this._doChangeToForegroundTasks():this._doChangeToBackgroun
25dTasks()}}__init2(){this._handleWindowBlur=()=>{const t=Me({category:"ui.blur"});this._doChangeToBackgroundTasks(t)}}__init3(){this._handleWindowFocus=()=>{const t=Me({category:"ui.focus"});this._doChangeToForegroundTasks(t)}}__init4(){this._handleKeyboardEvent=t=>{dg(this,t)}}_doChangeToBackgroundTasks(t){!this.session||vc(this.session,{maxReplayDuration:this._options.maxReplayDuration,sessionIdleExpire:this.timeouts.sessionIdleExpire})||(t&&this._createCustomBreadcrumb(t),this.conditionalFlush())}_doChangeToForegroundTasks(t){if(!this.session)return;if(!this.checkAndHandleExpiredSession()){k&&M.info("Document has become active, but session has expired");return}t&&this._createCustomBreadcrumb(t)}_updateUserActivity(t=Date.now()){this._lastActivity=t}_updateSessionActivity(t=Date.now()){this.session&&(this.session.lastActivity=t,this._maybeSaveSession())}_createCustomBreadcrumb(t){this.addUpdate(()=>{this.throttledAddEvent({type:P.Custom,timestamp:t.timestamp||0,data:{tag:"breadcrumb",payload:t}})})}_addPerformanceEntries(){let t=mg(this.performanceEntries).concat(this.replayPerformanceEntries);if(this.performanceEntries=[],this.replayPerformanceEntries=[],this._requiresManualStart){const n=this._context.initialTimestamp/1e3;t=t.filter(r=>r.start>=n)}return Promise.all(gr(this,t))}_clearContext(){this._context.errorIds.clear(),this._context.traceIds.clear(),this._context.urls=[]}_updateInitialTimestampFromEventBuffer(){const{session:t,eventBuffer:n}=this;if(!t||!n||this._requiresManualStart||t.segmentId)return;const r=n.getEarliestTimestamp();r&&r<this._context.initialTimestamp&&(this._context.initialTimestamp=r)}_popEventContext(){const t={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(),t}async _runFlush(){const t=this.getSessionId();if(!this.session||!this.eventBuffer||!t){k&&M.error("No session or eventBuffer found to flush.");return}if(await this._addPerformanceEntries(),!(!this.eventBuffer||!this.eventBuffer.hasEvents)&&(await N_(this),!!this.eventBuffer&&t===this.getSessionId()))try{this._updateInitialTimestampFromEventBuffer();const n=Date.now();if(n-this._context.initialTimestamp>this._options.maxReplayDuration+3e4)throw new Error("Session is too long, not sending replay");const r=this._popEventContext(),s=this.session.segmentId++;this._maybeSaveSession();const i=await this.eventBuffer.finish();await Pc({replayId:t,recordingData:i,segmentId:s,eventContext:r,session:this.session,timestamp:n,onError:o=>this.handleException(o)})}catch(n){this.handleException(n),this.stop({reason:"sendReplay"});const r=B();if(r){const s=n instanceof Js?"ratelimit_backoff":"send_error";r.recordDroppedEvent(s,"replay")}}}__init5(){this._flush=async({force:t=!1}={})=>{if(!this._isEnabled&&!t)return;if(!this.checkAndHandleExpiredSession()){k&&M.error("Attempting to finish replay event after session expired.");return}if(!this.session)return;const n=this.session.started,s=Date.now()-n;this._debouncedFlush.cancel();const i=s<this._options.minReplayDuration,o=s>this._options.maxReplayDuration+5e3;if(i||o){k&&M.info(`Session duration (${Math.floor(s/1e3)}s) is too ${i?"short":"long"}, not sending replay.`),i&&this._debouncedFlush();return}const a=this.eventBuffer;a&&this.session.segmentId===0&&!a.hasCheckout&&k&&M.info("Flushing initial segment without checkout.");const c=!!this._flushLock;this._flushLock||(this._flushLock=this._runFlush());try{await this._flushLock}catch(u){this.handleException(u)}finally{this._flushLock=void 0,c&&this._debouncedFlush()}}}_maybeSaveSession(){this.session&&this._options.stickySession&&Vs(this.session)}__init6(){this._onMutationHandler=t=>{const n=t.length,r=this._options.mutationLimit,s=this._options.mutationBreadcrumbLimit,i=r&&n>r;if(n>s||i){const o=Me({category:"replay.mutations",data:{count:n,limit:i}});this._createCustomBreadcrumb(o)}return i?(this.stop({reason:"mutationLimit",forceFlush:this.recordingMode==="session"}),!1):!0}}}function Yt(e,t){return[...e,...t].join(",")}function G_({mask:e,unmask:t,block:n,unblock:r,ignore:s}
25){const i=["base","iframe[srcdoc]:not([src])"],o=Yt(e,[".sentry-mask","[data-sentry-mask]"]),a=Yt(t,[]);return{maskTextSelector:o,unmaskTextSelector:a,blockSelector:Yt(n,[".sentry-block","[data-sentry-block]",...i]),unblockSelector:Yt(r,[]),ignoreSelector:Yt(s,[".sentry-ignore","[data-sentry-ignore]",'input[type="file"]'])}}function Y_({el:e,key:t,maskAttributes:n,maskAllText:r,privacyOptions:s,value:i}){return!r||s.unmaskTextSelector&&e.matches(s.unmaskTextSelector)?i:n.includes(t)||t==="value"&&e.tagName==="INPUT"&&["submit","button"].includes(e.getAttribute("type")||"")?i.replace(/[\S]/g,"*"):i}const yo='img,image,svg,video,object,picture,embed,map,audio,link[rel="icon"],link[rel="apple-touch-icon"]',V_=["content-length","content-type","accept"];let So=!1;const ly=e=>new yr(e);class yr{static __initStatic(){this.id="Replay"}constructor({flushMinDelay:t=Ih,flushMaxDelay:n=wh,minReplayDuration:r=Ah,maxReplayDuration:s=Ki,stickySession:i=!0,useCompression:o=!0,workerUrl:a,_experiments:c={},maskAllText:u=!0,maskAllInputs:d=!0,blockAllMedia:l=!0,mutationBreadcrumbLimit:f=750,mutationLimit:p=1e4,slowClickTimeout:h=7e3,slowClickIgnoreSelectors:m=[],networkDetailAllowUrls:E=[],networkDetailDenyUrls:S=[],networkCaptureBodies:C=!0,networkRequestHeaders:F=[],networkResponseHeaders:L=[],mask:v=[],maskAttributes:g=["title","placeholder"],unmask:T=[],block:w=[],unblock:_=[],ignore:b=[],maskFn:N,beforeAddRecordingEvent:R,beforeErrorSampling:G,onError:J}={}){this.name=yr.id;const oe=G_({mask:v,unmask:T,block:w,unblock:_,ignore:b});if(this._recordingOptions={maskAllInputs:d,maskAllText:u,maskInputOptions:{password:!0},maskTextFn:N,maskInputFn:N,maskAttributeFn:(D,ne,W)=>Y_({maskAttributes:g,maskAllText:u,privacyOptions:oe,key:D,value:ne,el:W}),...oe,slimDOMOptions:"all",inlineStylesheet:!0,inlineImages:!1,collectFonts:!0,errorHandler:D=>{try{D.__rrweb__=!0}catch{}}},this._initialOptions={flushMinDelay:t,flushMaxDelay:n,minReplayDuration:Math.min(r,Oh),maxReplayDuration:Math.min(s,Ki),stickySession:i,useCompression:o,workerUrl:a,blockAllMedia:l,maskAllInputs:d,maskAllText:u,mutationBreadcrumbLimit:f,mutationLimit:p,slowClickTimeout:h,slowClickIgnoreSelectors:m,networkDetailAllowUrls:E,networkDetailDenyUrls:S,networkCaptureBodies:C,networkRequestHeaders:Eo(F),networkResponseHeaders:Eo(L),beforeAddRecordingEvent:R,beforeErrorSampling:G,onError:J,_experiments:c},this._initialOptions.blockAllMedia&&(this._recordingOptions.blockSelector=this._recordingOptions.blockSelector?`${this._recordingOptions.blockSelector},${yo}`:yo),this._isInitialized&&Ui())throw new Error("Multiple Sentry Session Replay instances are not supported");this._isInitialized=!0}get _isInitialized(){return So}set _isInitialized(t){So=t}afterAllSetup(t){!Ui()||this._replay||(this._setup(t),this._initialize(t))}start(){this._replay&&this._replay.start()}startBuffering(){this._replay&&this._replay.startBuffering()}stop(){return this._replay?this._replay.stop({forceFlush:this._replay.recordingMode==="session"}):Promise.resolve()}flush(t){return this._replay?this._replay.isEnabled()?this._replay.sendBufferedReplayOrFlush(t):(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(t){this._replay&&(this._maybeLoadFromReplayCanvasIntegration(t),this._replay.initializeSampling())}_setup(t){const n=X_(this._initialOptions,t);this._replay=new Ge({options:n,recordingOptions:this._recordingOptions})}_maybeLoadFromReplayCanvasIntegration(t){try{const n=t.getIntegrationByName("ReplayCanvas");if(!n)return;this._replay._canvas=n.getOptions()}catch{}}}yr.__initStatic();function X_(e,t){const n=t.getOptions(),r={sessionSampleRate:0,errorSampleRate:0,...te(e)},s=jn(n.replaysSessionSampleRate),i=jn(n.replaysOnErrorSampleRate);return s==null&&i==null&&et(()=>{console.warn("Replay is disabled because neither `replaysSessionSampleRate` nor `replaysOnErrorSampleRate` are set.")}),s!=null&&(r.sessionSampleRate=s),i!=null&&(r.errorSampleRate=i),r}function Eo(e){return[...V_,...e.map(t=>t.toLowerCase())]}const bo=new WeakMap,Ur=new Map,Un={traceFetch:!0,traceXHR:!0,enableHTTPTimings:!0,trackFetchStreamPerformance:!1};function K_(e,t){const{traceFetch:n,traceXHR:r,trackFetchStreamPerformance:s,shouldCreateSpanForRequest:i,enableHTTPTimings:o,tracePropagationTargets:a}={traceFetch:Un.traceFetch,traceXHR:Un.traceXHR,trackFetchStreamPerformance:Un.trackFetchStreamPerformance,...t},c=typeof i=="function"?i:l=>!0,u=l=>Z_(l,a),d={};n&&(e.addEventProcessor(l=>(l.type==="transaction"&&l.spans&&l.spans.forEach(f=>{if(f.op==="http.client"){const p=Ur.get(f.span_id);p&&(f.timestamp=p/1e3,Ur.delete(f.span_id))}}),l)),s&&Ud(l=>{if(l.response){const f=bo.get(l.response);f&&l.endTimestamp&&Ur.set(f,l.endTimestamp)}}),Ia(l=>{const f=Nd(l,c,u,d);if(l.response&&l.fetchData.__span&&bo.set(l.response,l.fetchData.__span),f){const p=Bc(l.fetchData.url),h=p?ft(p).host:void 0;f.setAttributes({"http.url":p,"server.address":h})}o&&f&&vo(f)})),r&&ja(l=>{const f=ey(l,c,u,d);o&&f&&vo(f)})}function J_(e){return e.entryType==="resource"&&"initiatorType"in e&&typeof e.nextHopProtocol=="string"&&(e.initiatorType==="fetch"||e.
25initiatorType==="xmlhttprequest")}function vo(e){const{url:t}=z(e).data||{};if(!t||typeof t!="string")return;const n=Dt("resource",({entries:r})=>{r.forEach(s=>{J_(s)&&s.name.endsWith(t)&&(Q_(s).forEach(o=>e.setAttribute(...o)),setTimeout(n))})})}function Ce(e=0){return((fe||performance.timeOrigin)+e)/1e3}function Q_(e){const{name:t,version:n}=Ha(e.nextHopProtocol),r=[];return r.push(["network.protocol.version",n],["network.protocol.name",t]),fe?[...r,["http.request.redirect_start",Ce(e.redirectStart)],["http.request.fetch_start",Ce(e.fetchStart)],["http.request.domain_lookup_start",Ce(e.domainLookupStart)],["http.request.domain_lookup_end",Ce(e.domainLookupEnd)],["http.request.connect_start",Ce(e.connectStart)],["http.request.secure_connection_start",Ce(e.secureConnectionStart)],["http.request.connection_end",Ce(e.connectEnd)],["http.request.request_start",Ce(e.requestStart)],["http.request.response_start",Ce(e.responseStart)],["http.request.response_end",Ce(e.responseEnd)]]:r}function Z_(e,t){const n=A.location&&A.location.href;if(n){let r,s;try{r=new URL(e,n),s=new URL(n).origin}catch{return!1}const i=r.origin===s;return t?Ye(r.toString(),t)||i&&Ye(r.pathname,t):i}else{const r=!!e.match(/^\/(?!\/)/);return t?Ye(e,t):r}}function ey(e,t,n,r){const s=e.xhr,i=s&&s[at];if(!s||s.__sentry_own_request__||!i)return;const o=Je()&&t(i.url);if(e.endTimestamp&&o){const l=s.__sentry_xhr_span_id__;if(!l)return;const f=r[l];f&&i.status_code!==void 0&&($o(f,i.status_code),f.end(),delete r[l]);return}const a=Bc(i.url),c=a?ft(a).host:void 0,u=!!ie(),d=o&&u?un({name:`${i.method} ${i.url}`,attributes:{type:"xhr","http.method":i.method,"http.url":a,url:i.url,"server.address":c,[se]:"auto.http.browser",[mt]:"http.client"}}):new Ht;return s.__sentry_xhr_span_id__=d.spanContext().spanId,r[s.__sentry_xhr_span_id__]=d,n(i.url)&&ty(s,Je()&&u?d:void 0),d}function ty(e,t){const{"sentry-trace":n,baggage:r}=ya({span:t});n&&ny(e,n,r)}function ny(e,t,n){try{e.setRequestHeader("sentry-trace",t),n&&e.setRequestHeader("baggage",n)}catch{}}function Bc(e){try{return new URL(e,A.location.origin).href}catch{return}}function ry(){A&&A.document?A.document.addEventListener("visibilitychange",()=>{const e=ie();if(!e)return;const t=ce(e);if(A.document.hidden&&t){const n="cancelled",{op:r,status:s}=z(t);xe&&y.log(`[Tracing] Transaction: ${n} -> since tab moved to the background, op: ${r}`),s||t.setStatus({code:re,message:n}),t.setAttribute("sentry.cancellation_reason","document.hidden"),t.end()}}):xe&&y.warn("[Tracing] Could not set up background tab detection due to lack of global document")}const sy="BrowserTracing",iy={...Ln,instrumentNavigation:!0,instrumentPageLoad:!0,markBackgroundSpan:!0,enableLongTask:!0,enableLongAnimationFrame:!0,enableInp:!0,_experiments:{},...Un},dy=(e={})=>{Fu();const{enableInp:t,enableLongTask:n,enableLongAnimationFrame:r,_experiments:{enableInteractions:s,enableStandaloneClsSpans:i},beforeStartSpan:o,idleTimeout:a,finalTimeout:c,childSpanTimeout:u,markBackgroundSpan:d,traceFetch:l,traceXHR:f,trackFetchStreamPerformance:p,shouldCreateSpanForRequest:h,enableHTTPTimings:m,instrumentPageLoad:E,instrumentNavigation:S}={...iy,...e}
25,C=Kf({recordClsStandaloneSpans:i||!1});t&&bp(),r&&$.PerformanceObserver&&PerformanceObserver.supportedEntryTypes&&PerformanceObserver.supportedEntryTypes.includes("long-animation-frame")?Qf():n&&Jf(),s&&Zf();const F={name:void 0,source:void 0};function L(v,g){const T=g.op==="pageload",w=o?o(g):g,_=w.attributes||{};g.name!==w.name&&(_[Re]="custom",w.attributes=_),F.name=w.name,F.source=_[Re];const b=ia(w,{idleTimeout:a,finalTimeout:c,childSpanTimeout:u,disableAutoFinish:T,beforeSpanEnd:R=>{C(),sp(R,{recordClsOnPageloadSpan:!i})}});function N(){["interactive","complete"].includes(A.document.readyState)&&v.emit("idleSpanEnableAutoFinish",b)}return T&&A.document&&(A.document.addEventListener("readystatechange",()=>{N()}),N()),b}return{name:sy,afterAllSetup(v){let g,T=A.location&&A.location.href;function w(){g&&!z(g).timestamp&&(xe&&y.log(`[Tracing] Finishing current active span with op: ${z(g).op}`),g.end())}v.on("startNavigationSpan",_=>{B()===v&&(w(),g=L(v,{op:"navigation",..._}))}),v.on("startPageLoadSpan",(_,b={})=>{if(B()!==v)return;w();const N=b.sentryTrace||To("sentry-trace"),R=b.baggage||To("baggage"),G=xu(N,R);X().setPropagationContext(G),g=L(v,{op:"pageload",..._})}),v.on("spanEnd",_=>{const b=z(_).op;if(_!==ce(_)||b!=="navigation"&&b!=="pageload")return;const N=X(),R=N.getPropagationContext();N.setPropagationContext({...R,sampled:R.sampled!==void 0?R.sampled:_t(_),dsc:R.dsc||yt(_)})}),A.location&&(E&&oy(v,{name:A.location.pathname,startTime:fe?fe/1e3:void 0,attributes:{[Re]:"url",[se]:"auto.pageload.browser"}}),S&&dr(({to:_,from:b})=>{if(b===void 0&&T&&T.indexOf(_)!==-1){T=void 0;return}b!==_&&(T=void 0,ay(v,{name:A.location.pathname,attributes:{[Re]:"url",[se]:"auto.navigation.browser"}}))})),d&&ry(),s&&cy(a,c,u,F),t&&Tp(),K_(v,{traceFetch:l,traceXHR:f,trackFetchStreamPerformance:p,tracePropagationTargets:v.getOptions().tracePropagationTargets,shouldCreateSpanForRequest:h,enableHTTPTimings:m})}}};function oy(e,t,n){e.emit("startPageLoadSpan",t,n),X().setTransactionName(t.name);const r=ie();return(r&&z(r).op)==="pageload"?r:void 0}function ay(e,t){ke().setPropagationContext({traceId:Xe()}),X().setPropagationContext({traceId:Xe()}),e.emit("startNavigationSpan",t),X().setTransactionName(t.name);const n=ie();return(n&&z(n).op)==="navigation"?n:void 0}function To(e){const t=nu(`meta[name=${e}]`);return t?t.getAttribute("content"):void 0}function cy(e,t,n,r){let s;const i=()=>{const o="ui.action.click",a=ie(),c=a&&ce(a);if(c){const u=z(c).op;if(["navigation","pageload"].includes(u)){xe&&y.warn(`[Tracing] Did not create ${o} span because a pageload or navigation span is in progress.`);return}}if(s&&(s.setAttribute(Gr,"interactionInterrupted"),s.end(),s=void 0),!r.name){xe&&y.warn(`[Tracing] Did not create ${o} transaction because _latestRouteName is missing.`);return}s=ia({name:r.name,op:o,attributes:{[Re]:r.source||"url"}},{idleTimeout:e,finalTimeout:t,childSpanTimeout:n})};A.document&&addEventListener("click",i,{once:!1,capture:!0})}function fy(e){const t={...e};return _a(t,"react"),ua("react",{version:zc.version}),Eh(t)}export{dy as b,fy as i,ly as r};
Line numbers count LF bytes from the start of the resource, as the search results do. Vendor segments are library code the classifier recognised; they are stored but not indexed. Bytes are shown as Latin1 characters, one per byte.