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