@wix/create-app 0.0.51 → 0.0.53

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
@@ -1,6 +1,6 @@
1
1
  import { createRequire as _createRequire } from 'node:module';
2
2
  const require = _createRequire(import.meta.url);
3
- import{$ as Ps,A as Cs,Aa as La,Ab as Xs,B as Re,Ba as qt,Bb as Js,Ca as Da,Cb as mc,D as xs,Da as le,Db as Q,E as Be,Ea as Yr,Eb as Zs,F as Ts,Fa as Na,Fb as Jr,G as at,Ga as Pa,H as He,Ha as Fa,Hb as Qs,Ia as Ba,Ib as gc,Ja as Ha,Jb as ft,K as Ut,Ka as dt,Kb as eo,L as Rs,La as Ua,Lb as yc,M as Ms,Ma as Wa,Mb as to,N as Wt,Na as za,Nb as _c,O as As,Oa as $a,Ob as ro,P as Os,Pa as ja,Pb as Sc,Q as Ue,Qa as Ga,Qb as bc,R as ct,Ra as D,S as zt,Sa as qa,T as Ls,Ta as me,Tb as Zr,Ua as Vt,Ub as vc,V as lt,Va,Vb as Qr,W as qr,Wa as Yt,Wb as Ec,X as Ds,Yb as wc,Z as Vr,Zb as no,_ as Ns,_a as Ya,a as ms,aa as $t,ab as Ka,b as ot,bb as Xa,c as Wr,ca as Fs,d as gs,da as Bs,db as Ja,e as zr,ea as ut,eb as Kr,f as ys,fb as Kt,fc as so,g as $r,gb as Za,gc as oo,h as _s,ha as jt,hb as Qa,hc as Ic,i as Nt,ia as Hs,ib as ec,ic as kc,j as jr,ja as Us,jb as tc,jc as Cc,k as Ss,ka as Ws,kb as rc,kc as xc,l as bs,la as zs,lb as nc,lc as Tc,m as Se,ma as $s,mc as Rc,n as it,na as js,nb as sc,nc as Mc,o as Pt,oa as Gs,ob as oc,oc as Ac,p as vs,pa as qs,pb as ic,pc as Oc,q as Ft,qb as ac,qc as Lc,r as y,ra as Vs,rb as cc,rc as Dc,s as Bt,sa as We,sb as lc,sc as Nc,t as fe,tb as Xr,tc as Pc,u as Es,ua as Ys,ub as uc,uc as Fc,v as ws,va as Oa,vb as dc,vc as Bc,w as Ht,wb as fc,x as Is,xa as be,xb as pc,y as Gr,ya as Gt,yb as hc,z as ks,za as ze,zb as Ks}from"./chunk-V35UWYK6.js";import{d as Aa,h as k}from"./chunk-V4TR6DCM.js";k();k();var E=Se,en=0;function tn(){return en>0}function Hc(){en++,setTimeout(()=>{en--})}function ge(e,t={},r){if(typeof e!="function")return e;try{let s=e.__sentry_wrapped__;if(s)return s;if(Ht(e))return e}catch{return e}let n=function(){let s=Array.prototype.slice.call(arguments);try{r&&typeof r=="function"&&r.apply(this,arguments);let o=s.map(i=>ge(i,t));return e.apply(this,o)}catch(o){throw Hc(),dt(i=>{i.addEventProcessor(a=>(t.mechanism&&(at(a,void 0,void 0),He(a,t.mechanism)),a.extra={...a.extra,arguments:s},a)),ze(o)}),o}};try{for(let s in e)Object.prototype.hasOwnProperty.call(e,s)&&(n[s]=e[s])}catch{}ws(n,e),Es(e,"__sentry_wrapped__",n);try{Object.getOwnPropertyDescriptor(n,"name").configurable&&Object.defineProperty(n,"name",{get(){return e.name}})}catch{}return n}k();k();var T=typeof __SENTRY_DEBUG__>"u"||__SENTRY_DEBUG__;k();function Xt(e,t){let r=sn(e,t),n={type:t&&t.name,value:$c(t)};return r.length&&(n.stacktrace={frames:r}),n.type===void 0&&n.value===""&&(n.value="Unrecoverable error caught"),n}function Uc(e,t,r,n){let s=D(),o=s&&s.getOptions().normalizeDepth,i={exception:{values:[{type:Nt(t)?t.constructor.name:n?"UnhandledRejection":"Error",value:jc(t,{isUnhandledRejection:n})}]},extra:{__serialized__:Ds(t,o)}};if(r){let a=sn(e,r);a.length&&(i.exception.values[0].stacktrace={frames:a})}return i}function rn(e,t){return{exception:{values:[Xt(e,t)]}}}function sn(e,t){let r=t.stacktrace||t.stack||"",n=zc(t);try{return e(r,n)}catch{}return[]}var Wc=/Minified React error #\d+;/i;function zc(e){if(e){if(typeof e.framesToPop=="number")return e.framesToPop;if(Wc.test(e.message))return 1}return 0}function $c(e){let t=e&&e.message;return t?t.error&&typeof t.error.message=="string"?t.error.message:t:"No error message"}function on(e,t,r,n){let s=r&&r.syntheticException||void 0,o=Jt(e,t,s,n);return He(o),o.level="error",r&&r.event_id&&(o.event_id=r.event_id),Vr(o)}function an(e,t,r="info",n,s){let o=n&&n.syntheticException||void 0,i=nn(e,t,o,s);return i.level=r,n&&n.event_id&&(i.event_id=n.event_id),Vr(i)}function Jt(e,t,r,n,s){let o;if(ot(t)&&t.error)return rn(e,t.error);if(Wr(t)||gs(t)){let i=t;if("stack"in t)o=rn(e,t);else{let a=i.name||(Wr(i)?"DOMError":"DOMException"),c=i.message?`${a}: ${i.message}`:a;o=nn(e,c,r,n),at(o,c)}return"code"in i&&(o.tags={...o.tags,"DOMException.code":`${i.code}`}),o}return ms(t)?rn(e,t):_s(t)||Nt(t)?(o=Uc(e,t,r,s),He(o,{synthetic:!0}),o):(o=nn(e,t,r,n),at(o,`${t}`,void 0),He(o,{synthetic:!0}),o)}function nn(e,t,r,n){let s={};if(n&&r){let o=sn(e,r);o.length&&(s.exception={values:[{value:t,stacktrace:{frames:o}}]})}if(ys(t)){let{__sentry_template_string__:o,__sentry_template_values__:i}=t;return s.logentry={message:o,params:i},s}return s.message=t,s}function jc(e,{isUnhandledRejection:t}){let r=Is(e),n=t?"promise rejection":"exception";return ot(e)?`Event \`ErrorEvent\` captured as ${n} with message \`${e.message}\``:Nt(e)?`Event \`${Gc(e)}\` (type=${e.type}) captured as ${n}`:`Object captured as ${n} with keys: ${r}`}function Gc(e){try{let t=Object.getPrototypeOf(e);return t?t.constructor.name:void 0}catch{}}k();function cn(e,{metadata:t,tunnel:r,dsn:n}){let s={event_id:e.event_id,sent_at:new Date().toISOString(),...t&&t.sdk&&{sdk:{name:t.sdk.name,version:t.sdk.version}},...!!r&&!!n&&{dsn:Bt(n)}},o=qc(e);return jt(s,[o])}function qc(e){return[{type:"user_report"},e]}var pt=class extends Zs{constructor(t){let r=E.SENTRY_SDK_SOURCE||Ls();ro(t,"browser",["browser"],r),super(t),t.sendClientReports&&E.document&&E.document.addEventListener("visibilitychange",()=>{E.document.visibilityState==="hidden"&&this._flushOutcomes()})}eventFromException(t,r){return on(this._options.stackParser,t,r,this._options.attachStacktrace)}eventFromMessage(t,r="info",n){return an(this._options.stackParser,t,r,n,this._options.attachStacktrace)}captureUserFeedback(t){if(!this._isEnabled()){T&&y.warn("SDK not enabled, will not capture user feedback.");return}let r=cn(t,{metadata:this.getSdkMetadata(),dsn:this.getDsn(),tunnel:this.getOptions().tunnel});this._sendEnvelope(r)}_prepareEvent(t,r,n){return t.platform=t.platform||"javascript",super._prepareEvent(t,r,n)}_flushOutcomes(){let t=this._clearOutcomes();if(t.length===0){T&&y.log("No outcomes to send");return}if(!this._dsn){T&&y.log("No dsn provided, will not send outcomes");return}T&&y.log("Sending outcomes:",t);let r=js(t,this._options.tunnel&&Bt(this._dsn));this._sendEnvelope(r)}};k();k();var ht;function io(){if(ht)return ht;if(Ms(E.fetch))return ht=E.fetch.bind(E);let e=E.document,t=E.fetch;if(e&&typeof e.createElement=="function")try{let r=e.createElement("iframe");r.hidden=!0,e.head.appendChild(r);let n=r.contentWindow;n&&n.fetch&&(t=n.fetch),e.head.removeChild(r)}catch(r){T&&y.warn("Could not create sandbox iframe for pure fetch check, bailing to window.fetch: ",r)}return ht=t.bind(E)}function ao(){ht=void 0}function ln(e,t=io()){let r=0,n=0;function s(o){let i=o.body.length;r+=i,n++;let a={body:o.body,method:"POST",referrerPolicy:"origin",headers:e.headers,keepalive:r<=6e4&&n<15,...e.fetchOptions};try{return t(e.url,a).then(c=>(r-=i,n--,{statusCode:c.status,headers:{"x-sentry-rate-limits":c.headers.get("X-Sentry-Rate-Limits"),"retry-after":c.headers.get("Retry-After")}}))}catch(c){return ao(),r-=i,n--,Ns(c)}}return ft(e,s)}k();var Vc=4;function un(e){function t(r){return new Ps((n,s)=>{let o=new XMLHttpRequest;o.onerror=s,o.onreadystatechange=()=>{o.readyState===Vc&&n({statusCode:o.status,headers:{"x-sentry-rate-limits":o.getResponseHeader("X-Sentry-Rate-Limits"),"retry-after":o.getResponseHeader("Retry-After")}})},o.open("POST",e.url);for(let i in e.headers)Object.prototype.hasOwnProperty.call(e.headers,i)&&o.setRequestHeader(i,e.headers[i]);o.send(r.body)})}return ft(e,t)}k();var $e="?",Yc=10,Kc=20,Xc=30,Jc=40,Zc=50;function mt(e,t,r,n){let s={filename:e,function:t,in_app:!0};return r!==void 0&&(s.lineno=r),n!==void 0&&(s.colno=n),s}var Qc=/^\s*at (?:(.+?\)(?: \[.+\])?|.*?) ?\((?:address at )?)?(?:async )?((?:<anonymous>|[-a-z]+:|.*bundle|\/)?.*?)(?::(\d+))?(?::(\d+))?\)?\s*$/i,el=/\((\S*)(?::(\d+))(?::(\d+))\)/,tl=e=>{let t=Qc.exec(e);if(t){if(t[2]&&t[2].indexOf("eval")===0){let o=el.exec(t[2]);o&&(t[2]=o[1],t[3]=o[2],t[4]=o[3])}let[n,s]=po(t[1]||$e,t[2]);return mt(s,n,t[3]?+t[3]:void 0,t[4]?+t[4]:void 0)}},co=[Xc,tl],rl=/^\s*(.*?)(?:\((.*?)\))?(?:^|@)?((?:[-a-z]+)?:\/.*?|\[native code\]|[^@]*(?:bundle|\d+\.js)|\/[\w\-. /=]+)(?::(\d+))?(?::(\d+))?\s*$/i,nl=/(\S+) line (\d+)(?: > eval line \d+)* > eval/i,sl=e=>{let t=rl.exec(e);if(t){if(t[3]&&t[3].indexOf(" > eval")>-1){let o=nl.exec(t[3]);o&&(t[1]=t[1]||"eval",t[3]=o[1],t[4]=o[2],t[5]="")}let n=t[3],s=t[1]||$e;return[s,n]=po(s,n),mt(n,s,t[4]?+t[4]:void 0,t[5]?+t[5]:void 0)}},lo=[Zc,sl],ol=/^\s*at (?:((?:\[object object\])?.+) )?\(?((?:[-a-z]+):.*?):(\d+)(?::(\d+))?\)?\s*$/i,il=e=>{let t=ol.exec(e);return t?mt(t[2],t[1]||$e,+t[3],t[4]?+t[4]:void 0):void 0},uo=[Jc,il],al=/ line (\d+).*script (?:in )?(\S+)(?:: in function (\S+))?$/i,cl=e=>{let t=al.exec(e);return t?mt(t[2],t[3]||$e,+t[1]):void 0},ll=[Yc,cl],ul=/ line (\d+), column (\d+)\s*(?:in (?:<anonymous function: ([^>]+)>|([^)]+))\(.*\))? in (.*):\s*$/i,dl=e=>{let t=ul.exec(e);return t?mt(t[5],t[3]||t[4]||$e,+t[1],+t[2]):void 0},fl=[Kc,dl],fo=[co,lo,uo],dn=ks(...fo),po=(e,t)=>{let r=e.indexOf("safari-extension")!==-1,n=e.indexOf("safari-web-extension")!==-1;return r||n?[e.indexOf("@")!==-1?e.split("@")[0]:$e,r?`safari-extension:${t}`:`safari-web-extension:${t}`]:[e,t]};k();k();var Zt=1024,ho="Breadcrumbs",pl=(e={})=>{let t={console:!0,dom:!0,fetch:!0,history:!0,sentry:!0,xhr:!0,...e};return{name:ho,setupOnce(){},setup(r){t.console&&xs(gl(r)),t.dom&&Ut(ml(r,t.dom)),t.xhr&&zt(yl(r)),t.fetch&&Wt(_l(r)),t.history&&Ue(Sl(r)),t.sentry&&r.on&&r.on("beforeSendEvent",hl(r))}}},Qt=pl,fn=Q(ho,Qt);function hl(e){return function(r){D()===e&&le({category:`sentry.${r.type==="transaction"?"transaction":"event"}`,event_id:r.event_id,level:r.level,message:Ts(r)},{event:r})}}function ml(e,t){return function(n){if(D()!==e)return;let s,o,i=typeof t=="object"?t.serializeAttribute:void 0,a=typeof t=="object"&&typeof t.maxStringLength=="number"?t.maxStringLength:void 0;a&&a>Zt&&(T&&y.warn(`\`dom.maxStringLength\` cannot exceed ${Zt}, but a value of ${a} was configured. Sentry will use ${Zt} instead.`),a=Zt),typeof i=="string"&&(i=[i]);try{let l=n.event,u=bl(l)?l.target:l;s=it(u,{keyAttrs:i,maxStringLength:a}),o=vs(u)}catch{s="<unknown>"}if(s.length===0)return;let c={category:`ui.${n.name}`,message:s};o&&(c.data={"ui.component_name":o}),le(c,{event:n.event,name:n.name,global:n.global})}}function gl(e){return function(r){if(D()!==e)return;let n={category:"console",data:{arguments:r.args,logger:"console"},level:Fs(r.level),message:jr(r.args," ")};if(r.level==="assert")if(r.args[0]===!1)n.message=`Assertion failed: ${jr(r.args.slice(1)," ")||"console.assert"}`,n.data.arguments=r.args.slice(1);else return;le(n,{input:r.args,level:r.level})}}function yl(e){return function(r){if(D()!==e)return;let{startTimestamp:n,endTimestamp:s}=r,o=r.xhr[ct];if(!n||!s||!o)return;let{method:i,url:a,status_code:c,body:l}=o,u={method:i,url:a,status_code:c},d={xhr:r.xhr,input:l,startTimestamp:n,endTimestamp:s};le({category:"xhr",data:u,type:"http"},d)}}function _l(e){return function(r){if(D()!==e)return;let{startTimestamp:n,endTimestamp:s}=r;if(s&&!(r.fetchData.url.match(/sentry_key/)&&r.fetchData.method==="POST"))if(r.error){let o=r.fetchData,i={data:r.error,input:r.args,startTimestamp:n,endTimestamp:s};le({category:"fetch",data:o,level:"error",type:"http"},i)}else{let o=r.response,i={...r.fetchData,status_code:o&&o.status},a={input:r.args,response:o,startTimestamp:n,endTimestamp:s};le({category:"fetch",data:i,type:"http"},a)}}}function Sl(e){return function(r){if(D()!==e)return;let n=r.from,s=r.to,o=$t(E.location.href),i=n?$t(n):void 0,a=$t(s);(!i||!i.path)&&(i=o),o.protocol===a.protocol&&o.host===a.host&&(s=a.relative),o.protocol===i.protocol&&o.host===i.host&&(n=i.relative),le({category:"navigation",data:{from:n,to:s}})}}function bl(e){return!!e&&!!e.target}k();var yo="Dedupe",vl=()=>{let e;return{name:yo,setupOnce(){},processEvent(t){if(t.type)return t;try{if(El(t,e))return T&&y.warn("Event dropped due to being a duplicate of previously captured event."),null}catch{}return e=t}}},pn=vl,hn=Q(yo,pn);function El(e,t){return t?!!(wl(e,t)||Il(e,t)):!1}function wl(e,t){let r=e.message,n=t.message;return!(!r&&!n||r&&!n||!r&&n||r!==n||!So(e,t)||!_o(e,t))}function Il(e,t){let r=mo(t),n=mo(e);return!(!r||!n||r.type!==n.type||r.value!==n.value||!So(e,t)||!_o(e,t))}function _o(e,t){let r=go(e),n=go(t);if(!r&&!n)return!0;if(r&&!n||!r&&n||(r=r,n=n,n.length!==r.length))return!1;for(let s=0;s<n.length;s++){let o=n[s],i=r[s];if(o.filename!==i.filename||o.lineno!==i.lineno||o.colno!==i.colno||o.function!==i.function)return!1}return!0}function So(e,t){let r=e.fingerprint,n=t.fingerprint;if(!r&&!n)return!0;if(r&&!n||!r&&n)return!1;r=r,n=n;try{return r.join("")===n.join("")}catch{return!1}}function mo(e){return e.exception&&e.exception.values&&e.exception.values[0]}function go(e){let t=e.exception;if(t)try{return t.values[0].stacktrace.frames}catch{return}}k();var vo="GlobalHandlers",kl=(e={})=>{let t={onerror:!0,onunhandledrejection:!0,...e};return{name:vo,setupOnce(){Error.stackTraceLimit=50},setup(r){t.onerror&&(Cl(r),bo("onerror")),t.onunhandledrejection&&(xl(r),bo("onunhandledrejection"))}}},er=kl,mn=Q(vo,er);function Cl(e){As(t=>{let{stackParser:r,attachStacktrace:n}=wo();if(D()!==e||tn())return;let{msg:s,url:o,line:i,column:a,error:c}=t,l=c===void 0&&zr(s)?Ml(s,o,i,a):Eo(Jt(r,c||s,void 0,n,!1),o,i,a);l.level="error",qt(l,{originalException:c,mechanism:{handled:!1,type:"onerror"}})})}function xl(e){Os(t=>{let{stackParser:r,attachStacktrace:n}=wo();if(D()!==e||tn())return;let s=Tl(t),o=$r(s)?Rl(s):Jt(r,s,void 0,n,!0);o.level="error",qt(o,{originalException:s,mechanism:{handled:!1,type:"onunhandledrejection"}})})}function Tl(e){if($r(e))return e;let t=e;try{if("reason"in t)return t.reason;if("detail"in t&&"reason"in t.detail)return t.detail.reason}catch{}return e}function Rl(e){return{exception:{values:[{type:"UnhandledRejection",value:`Non-Error promise rejection captured with value: ${String(e)}`}]}}}function Ml(e,t,r,n){let s=/^(?:[Uu]ncaught (?:exception: )?)?(?:((?:Eval|Internal|Range|Reference|Syntax|Type|URI|)Error): )?(.*)$/i,o=ot(e)?e.message:e,i="Error",a=o.match(s);return a&&(i=a[1],o=a[2]),Eo({exception:{values:[{type:i,value:o}]}},t,r,n)}function Eo(e,t,r,n){let s=e.exception=e.exception||{},o=s.values=s.values||[],i=o[0]=o[0]||{},a=i.stacktrace=i.stacktrace||{},c=a.frames=a.frames||[],l=isNaN(parseInt(n,10))?void 0:n,u=isNaN(parseInt(r,10))?void 0:r,d=zr(t)&&t.length>0?t:Pt();return c.length===0&&c.push({colno:l,filename:d,function:"?",in_app:!0,lineno:u}),e}function bo(e){T&&y.log(`Global Handler attached: ${e}`)}function wo(){let e=D();return e&&e.getOptions()||{stackParser:()=>[],attachStacktrace:!1}}k();var Io="HttpContext",Al=()=>({name:Io,setupOnce(){},preprocessEvent(e){if(!E.navigator&&!E.location&&!E.document)return;let t=e.request&&e.request.url||E.location&&E.location.href,{referrer:r}=E.document||{},{userAgent:n}=E.navigator||{},s={...e.request&&e.request.headers,...r&&{Referer:r},...n&&{"User-Agent":n}},o={...e.request,...t&&{url:t},headers:s};e.request=o}}),tr=Al,gn=Q(Io,tr);k();var Ol="cause",Ll=5,ko="LinkedErrors",Dl=(e={})=>{let t=e.limit||Ll,r=e.key||Ol;return{name:ko,setupOnce(){},preprocessEvent(n,s,o){let i=o.getOptions();bs(Xt,i.stackParser,i.maxValueLength,r,t,n,s)}}},rr=Dl,yn=Q(ko,rr);k();var Nl=["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"],xo="TryCatch",Pl=(e={})=>{let t={XMLHttpRequest:!0,eventTarget:!0,requestAnimationFrame:!0,setInterval:!0,setTimeout:!0,...e};return{name:xo,setupOnce(){t.setTimeout&&fe(E,"setTimeout",Co),t.setInterval&&fe(E,"setInterval",Co),t.requestAnimationFrame&&fe(E,"requestAnimationFrame",Fl),t.XMLHttpRequest&&"XMLHttpRequest"in E&&fe(XMLHttpRequest.prototype,"send",Bl);let r=t.eventTarget;r&&(Array.isArray(r)?r:Nl).forEach(Hl)}}},nr=Pl,_n=Q(xo,nr);function Co(e){return function(...t){let r=t[0];return t[0]=ge(r,{mechanism:{data:{function:Re(e)},handled:!1,type:"instrument"}}),e.apply(this,t)}}function Fl(e){return function(t){return e.apply(this,[ge(t,{mechanism:{data:{function:"requestAnimationFrame",handler:Re(e)},handled:!1,type:"instrument"}})])}}function Bl(e){return function(...t){let r=this;return["onload","onerror","onprogress","onreadystatechange"].forEach(s=>{s in r&&typeof r[s]=="function"&&fe(r,s,function(o){let i={mechanism:{data:{function:s,handler:Re(o)},handled:!1,type:"instrument"}},a=Ht(o);return a&&(i.mechanism.data.handler=Re(a)),ge(o,i)})}),e.apply(this,t)}}function Hl(e){let t=E,r=t[e]&&t[e].prototype;!r||!r.hasOwnProperty||!r.hasOwnProperty("addEventListener")||(fe(r,"addEventListener",function(n){return function(s,o,i){try{typeof o.handleEvent=="function"&&(o.handleEvent=ge(o.handleEvent,{mechanism:{data:{function:"handleEvent",handler:Re(o),target:e},handled:!1,type:"instrument"}}))}catch{}return n.apply(this,[s,ge(o,{mechanism:{data:{function:"addEventListener",handler:Re(o),target:e},handled:!1,type:"instrument"}}),i])}}),fe(r,"removeEventListener",function(n){return function(s,o,i){let a=o;try{let c=a&&a.__sentry_wrapped__;c&&n.call(this,s,c,i)}catch{}return n.call(this,s,a,i)}}))}var To=[Zr(),Qr(),nr(),Qt(),er(),rr(),pn(),tr()];function Ro(e){return[...To]}function Ul(e={}){e.defaultIntegrations===void 0&&(e.defaultIntegrations=Ro()),e.release===void 0&&(typeof __SENTRY_RELEASE__=="string"&&(e.release=__SENTRY_RELEASE__),E.SENTRY_RELEASE&&E.SENTRY_RELEASE.id&&(e.release=E.SENTRY_RELEASE.id)),e.autoSessionTracking===void 0&&(e.autoSessionTracking=!0),e.sendClientReports===void 0&&(e.sendClientReports=!0);let t={...e,stackParser:Cs(e.stackParser||dn),integrations:Js(e),transport:e.transport||(Rs()?ln:un)};Qs(pt,t),e.autoSessionTracking&&Gl()}var Wl=(e={},t=Kr())=>{if(!E.document){T&&y.error("Global document not defined in showReportDialog call");return}let{client:r,scope:n}=t.getStackTop(),s=e.dsn||r&&r.getDsn();if(!s){T&&y.error("DSN not configured for showReportDialog call");return}n&&(e.user={...n.getUser(),...e.user}),e.eventId||(e.eventId=t.lastEventId());let o=E.document.createElement("script");o.async=!0,o.crossOrigin="anonymous",o.src=Xs(s,e),e.onLoad&&(o.onload=e.onLoad);let{onClose:i}=e;if(i){let c=l=>{if(l.data==="__sentry_reportdialog_closed__")try{i()}finally{E.removeEventListener("message",c)}};E.addEventListener("message",c)}let a=E.document.head||E.document.body;a?a.appendChild(o):T&&y.error("Not injecting report dialog. No injection point found in HTML")};function zl(){}function $l(e){e()}function jl(e){return ge(e)()}function Gl(){if(typeof E.document>"u"){T&&y.warn("Session tracking in non-browser environment with @sentry/browser is not supported.");return}Vt({ignoreDuration:!0}),Yt(),Ue(({from:e,to:t})=>{e!==void 0&&e!==t&&(Vt({ignoreDuration:!0}),Yt())})}function ql(e){let t=D();t&&t.captureUserFeedback(e)}var Sn={};Aa(Sn,{Breadcrumbs:()=>fn,Dedupe:()=>hn,GlobalHandlers:()=>mn,HttpContext:()=>gn,LinkedErrors:()=>yn,TryCatch:()=>_n});k();k();var z=Se,jn="sentryReplaySession",Vl="replay_event",Gn="Unable to send Replay",Yl=3e5,Kl=9e5,Xl=5e3,Jl=5500,Zl=6e4,Ql=5e3,eu=3,Mo=15e4,sr=5e3,tu=3e3,ru=300,qn=2e7,nu=4999,su=15e3,Ao=36e5;function ou(e,t){return e??t()}function ar(e){let t,r=e[0],n=1;for(;n<e.length;){let s=e[n],o=e[n+1];if(n+=2,(s==="optionalAccess"||s==="optionalCall")&&r==null)return;s==="access"||s==="optionalAccess"?(t=r,r=o(r)):(s==="call"||s==="optionalCall")&&(r=o((...i)=>r.call(t,...i)),t=void 0)}return r}var Z;(function(e){e[e.Document=0]="Document",e[e.DocumentType=1]="DocumentType",e[e.Element=2]="Element",e[e.Text=3]="Text",e[e.CDATA=4]="CDATA",e[e.Comment=5]="Comment"})(Z||(Z={}));function iu(e){return e.nodeType===e.ELEMENT_NODE}function yt(e){let t=ar([e,"optionalAccess",r=>r.host]);return ar([t,"optionalAccess",r=>r.shadowRoot])===e}function _t(e){return Object.prototype.toString.call(e)==="[object ShadowRoot]"}function au(e){return e.includes(" background-clip: text;")&&!e.includes(" -webkit-background-clip: text;")&&(e=e.replace(" background-clip: text;"," -webkit-background-clip: text; background-clip: text;")),e}function cu(e){let{cssText:t}=e;if(t.split('"').length<3)return t;let r=["@import",`url(${JSON.stringify(e.href)})`];return e.layerName===""?r.push("layer"):e.layerName&&r.push(`layer(${e.layerName})`),e.supportsText&&r.push(`supports(${e.supportsText})`),e.media.length&&r.push(e.media.mediaText),r.join(" ")+";"}function cr(e){try{let t=e.rules||e.cssRules;return t?au(Array.from(t,Zo).join("")):null}catch{return null}}function Zo(e){let t;if(uu(e))try{t=cr(e.styleSheet)||cu(e)}catch{}else if(du(e)&&e.selectorText.includes(":"))return lu(e.cssText);return t||e.cssText}function lu(e){let t=/(\[(?:[\w-]+)[^\\])(:(?:[\w-]+)\])/gm;return e.replace(t,"$1\\$2")}function uu(e){return"styleSheet"in e}function du(e){return"selectorText"in e}var lr=class{constructor(){this.idNodeMap=new Map,this.nodeMetaMap=new WeakMap}getId(t){if(!t)return-1;let r=ar([this,"access",n=>n.getMeta,"call",n=>n(t),"optionalAccess",n=>n.id]);return ou(r,()=>-1)}getNode(t){return this.idNodeMap.get(t)||null}getIds(){return Array.from(this.idNodeMap.keys())}getMeta(t){return this.nodeMetaMap.get(t)||null}removeNodeFromMap(t){let r=this.getId(t);this.idNodeMap.delete(r),t.childNodes&&t.childNodes.forEach(n=>this.removeNodeFromMap(n))}has(t){return this.idNodeMap.has(t)}hasNode(t){return this.nodeMetaMap.has(t)}add(t,r){let n=r.id;this.idNodeMap.set(n,t),this.nodeMetaMap.set(t,r)}replace(t,r){let n=this.getNode(t);if(n){let s=this.nodeMetaMap.get(n);s&&this.nodeMetaMap.set(r,s)}this.idNodeMap.set(t,r)}reset(){this.idNodeMap=new Map,this.nodeMetaMap=new WeakMap}};function fu(){return new lr}function Er({maskInputOptions:e,tagName:t,type:r}){return t==="OPTION"&&(t="SELECT"),!!(e[t.toLowerCase()]||r&&e[r]||r==="password"||t==="INPUT"&&!r&&e.text)}function bt({isMasked:e,element:t,value:r,maskInputFn:n}){let s=r||"";return e?(n&&(s=n(s,t)),"*".repeat(s.length)):s}function Je(e){return e.toLowerCase()}function wn(e){return e.toUpperCase()}var Oo="__rrweb_original__";function pu(e){let t=e.getContext("2d");if(!t)return!0;let r=50;for(let n=0;n<e.width;n+=r)for(let s=0;s<e.height;s+=r){let o=t.getImageData,i=Oo in o?o[Oo]:o;if(new Uint32Array(i.call(t,n,s,Math.min(r,e.width-n),Math.min(r,e.height-s)).data.buffer).some(c=>c!==0))return!1}return!0}function Vn(e){let t=e.type;return e.hasAttribute("data-rr-is-password")?"password":t?Je(t):null}function ur(e,t,r){return t==="INPUT"&&(r==="radio"||r==="checkbox")?e.getAttribute("value")||"":e.value}var hu=1,mu=new RegExp("[^a-z0-9-_:]"),vt=-2;function Yn(){return hu++}function gu(e){if(e instanceof HTMLFormElement)return"form";let t=Je(e.tagName);return mu.test(t)?"div":t}function yu(e){let t="";return e.indexOf("//")>-1?t=e.split("/").slice(0,3).join("/"):t=e.split("/")[0],t=t.split("?")[0],t}var je,Lo,_u=/url\((?:(')([^']*)'|(")(.*?)"|([^)]*))\)/gm,Su=/^(?:[a-z+]+:)?\/\//i,bu=/^www\..*/i,vu=/^(data:)([^,]*),(.*)/i;function dr(e,t){return(e||"").replace(_u,(r,n,s,o,i,a)=>{let c=s||i||a,l=n||o||"";if(!c)return r;if(Su.test(c)||bu.test(c))return`url(${l}${c}${l})`;if(vu.test(c))return`url(${l}${c}${l})`;if(c[0]==="/")return`url(${l}${yu(t)+c}${l})`;let u=t.split("/"),d=c.split("/");u.pop();for(let f of d)f!=="."&&(f===".."?u.pop():u.push(f));return`url(${l}${u.join("/")}${l})`})}var Eu=/^[^ \t\n\r\u000c]+/,wu=/^[, \t\n\r\u000c]+/;function Iu(e,t){if(t.trim()==="")return t;let r=0;function n(o){let i,a=o.exec(t.substring(r));return a?(i=a[0],r+=i.length,i):""}let s=[];for(;n(wu),!(r>=t.length);){let o=n(Eu);if(o.slice(-1)===",")o=qe(e,o.substring(0,o.length-1)),s.push(o);else{let i="";o=qe(e,o);let a=!1;for(;;){let c=t.charAt(r);if(c===""){s.push((o+i).trim());break}else if(a)c===")"&&(a=!1);else if(c===","){r+=1,s.push((o+i).trim());break}else c==="("&&(a=!0);i+=c,r+=1}}}return s.join(", ")}function qe(e,t){if(!t||t.trim()==="")return t;let r=e.createElement("a");return r.href=t,r.href}function ku(e){return!!(e.tagName==="svg"||e.ownerSVGElement)}function Kn(){let e=document.createElement("a");return e.href="",e.href}function Qo(e,t,r,n,s,o){return n&&(r==="src"||r==="href"&&!(t==="use"&&n[0]==="#")||r==="xlink:href"&&n[0]!=="#"||r==="background"&&(t==="table"||t==="td"||t==="th")?qe(e,n):r==="srcset"?Iu(e,n):r==="style"?dr(n,Kn()):t==="object"&&r==="data"?qe(e,n):typeof o=="function"?o(r,n,s):n)}function ei(e,t,r){return(e==="video"||e==="audio")&&t==="autoplay"}function Cu(e,t,r,n){try{if(n&&e.matches(n))return!1;if(typeof t=="string"){if(e.classList.contains(t))return!0}else for(let s=e.classList.length;s--;){let o=e.classList[s];if(t.test(o))return!0}if(r)return e.matches(r)}catch{}return!1}function xu(e,t){for(let r=e.classList.length;r--;){let n=e.classList[r];if(t.test(n))return!0}return!1}function Ae(e,t,r=1/0,n=0){return!e||e.nodeType!==e.ELEMENT_NODE||n>r?-1:t(e)?n:Ae(e.parentNode,t,r,n+1)}function Ve(e,t){return r=>{let n=r;if(n===null)return!1;try{if(e){if(typeof e=="string"){if(n.matches(`.${e}`))return!0}else if(xu(n,e))return!0}return!!(t&&n.matches(t))}catch{return!1}}}function Ze(e,t,r,n,s,o){try{let i=e.nodeType===e.ELEMENT_NODE?e:e.parentElement;if(i===null)return!1;if(i.tagName==="INPUT"){let l=i.getAttribute("autocomplete");if(["current-password","new-password","cc-number","cc-exp","cc-exp-month","cc-exp-year","cc-csc"].includes(l))return!0}let a=-1,c=-1;if(o){if(c=Ae(i,Ve(n,s)),c<0)return!0;a=Ae(i,Ve(t,r),c>=0?c:1/0)}else{if(a=Ae(i,Ve(t,r)),a<0)return!1;c=Ae(i,Ve(n,s),a>=0?a:1/0)}return a>=0?c>=0?a<=c:!0:c>=0?!1:!!o}catch{}return!!o}function Tu(e,t,r){let n=e.contentWindow;if(!n)return;let s=!1,o;try{o=n.document.readyState}catch{return}if(o!=="complete"){let a=setTimeout(()=>{s||(t(),s=!0)},r);e.addEventListener("load",()=>{clearTimeout(a),s=!0,t()});return}let i="about:blank";if(n.location.href!==i||e.src===i||e.src==="")return setTimeout(t,0),e.addEventListener("load",t);e.addEventListener("load",t)}function Ru(e,t,r){let n=!1,s;try{s=e.sheet}catch{return}if(s)return;let o=setTimeout(()=>{n||(t(),n=!0)},r);e.addEventListener("load",()=>{clearTimeout(o),n=!0,t()})}function Mu(e,t){let{doc:r,mirror:n,blockClass:s,blockSelector:o,unblockSelector:i,maskAllText:a,maskAttributeFn:c,maskTextClass:l,unmaskTextClass:u,maskTextSelector:d,unmaskTextSelector:f,inlineStylesheet:p,maskInputOptions:h={},maskTextFn:g,maskInputFn:b,dataURLOptions:m={},inlineImages:_,recordCanvas:w,keepIframeSrcFn:C,newlyAddedElement:O=!1}=t,I=Au(r,n);switch(e.nodeType){case e.DOCUMENT_NODE:return e.compatMode!=="CSS1Compat"?{type:Z.Document,childNodes:[],compatMode:e.compatMode}:{type:Z.Document,childNodes:[]};case e.DOCUMENT_TYPE_NODE:return{type:Z.DocumentType,name:e.name,publicId:e.publicId,systemId:e.systemId,rootId:I};case e.ELEMENT_NODE:return Lu(e,{doc:r,blockClass:s,blockSelector:o,unblockSelector:i,inlineStylesheet:p,maskAttributeFn:c,maskInputOptions:h,maskInputFn:b,dataURLOptions:m,inlineImages:_,recordCanvas:w,keepIframeSrcFn:C,newlyAddedElement:O,rootId:I,maskAllText:a,maskTextClass:l,unmaskTextClass:u,maskTextSelector:d,unmaskTextSelector:f});case e.TEXT_NODE:return Ou(e,{maskAllText:a,maskTextClass:l,unmaskTextClass:u,maskTextSelector:d,unmaskTextSelector:f,maskTextFn:g,maskInputOptions:h,maskInputFn:b,rootId:I});case e.CDATA_SECTION_NODE:return{type:Z.CDATA,textContent:"",rootId:I};case e.COMMENT_NODE:return{type:Z.Comment,textContent:e.textContent||"",rootId:I};default:return!1}}function Au(e,t){if(!t.hasNode(e))return;let r=t.getId(e);return r===1?void 0:r}function Ou(e,t){let{maskAllText:r,maskTextClass:n,unmaskTextClass:s,maskTextSelector:o,unmaskTextSelector:i,maskTextFn:a,maskInputOptions:c,maskInputFn:l,rootId:u}=t,d=e.parentNode&&e.parentNode.tagName,f=e.textContent,p=d==="STYLE"?!0:void 0,h=d==="SCRIPT"?!0:void 0,g=d==="TEXTAREA"?!0:void 0;if(p&&f){try{e.nextSibling||e.previousSibling||ar([e,"access",m=>m.parentNode,"access",m=>m.sheet,"optionalAccess",m=>m.cssRules])&&(f=cr(e.parentNode.sheet))}catch(m){console.warn(`Cannot get CSS styles from text's parentNode. Error: ${m}`,e)}f=dr(f,Kn())}h&&(f="SCRIPT_PLACEHOLDER");let b=Ze(e,n,o,s,i,r);if(!p&&!h&&!g&&f&&b&&(f=a?a(f,e.parentElement):f.replace(/[\S]/g,"*")),g&&f&&(c.textarea||b)&&(f=l?l(f,e.parentNode):f.replace(/[\S]/g,"*")),d==="OPTION"&&f){let m=Er({type:null,tagName:d,maskInputOptions:c});f=bt({isMasked:Ze(e,n,o,s,i,m),element:e,value:f,maskInputFn:l})}return{type:Z.Text,textContent:f||"",isStyle:p,rootId:u}}function Lu(e,t){let{doc:r,blockClass:n,blockSelector:s,unblockSelector:o,inlineStylesheet:i,maskInputOptions:a={},maskAttributeFn:c,maskInputFn:l,dataURLOptions:u={},inlineImages:d,recordCanvas:f,keepIframeSrcFn:p,newlyAddedElement:h=!1,rootId:g,maskAllText:b,maskTextClass:m,unmaskTextClass:_,maskTextSelector:w,unmaskTextSelector:C}=t,O=Cu(e,n,s,o),I=gu(e),S={},R=e.attributes.length;for(let v=0;v<R;v++){let x=e.attributes[v];x.name&&!ei(I,x.name,x.value)&&(S[x.name]=Qo(r,I,Je(x.name),x.value,e,c))}if(I==="link"&&i){let v=Array.from(r.styleSheets).find(B=>B.href===e.href),x=null;v&&(x=cr(v)),x&&(delete S.rel,delete S.href,S._cssText=dr(x,v.href))}if(I==="style"&&e.sheet&&!(e.innerText||e.textContent||"").trim().length){let v=cr(e.sheet);v&&(S._cssText=dr(v,Kn()))}if(I==="input"||I==="textarea"||I==="select"||I==="option"){let v=e,x=Vn(v),B=ur(v,wn(I),x),Y=v.checked;if(x!=="submit"&&x!=="button"&&B){let J=Ze(v,m,w,_,C,Er({type:x,tagName:wn(I),maskInputOptions:a}));S.value=bt({isMasked:J,element:v,value:B,maskInputFn:l})}Y&&(S.checked=Y)}if(I==="option"&&(e.selected&&!a.select?S.selected=!0:delete S.selected),I==="canvas"&&f){if(e.__context==="2d")pu(e)||(S.rr_dataURL=e.toDataURL(u.type,u.quality));else if(!("__context"in e)){let v=e.toDataURL(u.type,u.quality),x=document.createElement("canvas");x.width=e.width,x.height=e.height;let B=x.toDataURL(u.type,u.quality);v!==B&&(S.rr_dataURL=v)}}if(I==="img"&&d){je||(je=r.createElement("canvas"),Lo=je.getContext("2d"));let v=e,x=v.crossOrigin;v.crossOrigin="anonymous";let B=()=>{v.removeEventListener("load",B);try{je.width=v.naturalWidth,je.height=v.naturalHeight,Lo.drawImage(v,0,0),S.rr_dataURL=je.toDataURL(u.type,u.quality)}catch(Y){console.warn(`Cannot inline img src=${v.currentSrc}! Error: ${Y}`)}x?S.crossOrigin=x:v.removeAttribute("crossorigin")};v.complete&&v.naturalWidth!==0?B():v.addEventListener("load",B)}if((I==="audio"||I==="video")&&(S.rr_mediaState=e.paused?"paused":"played",S.rr_mediaCurrentTime=e.currentTime),h||(e.scrollLeft&&(S.rr_scrollLeft=e.scrollLeft),e.scrollTop&&(S.rr_scrollTop=e.scrollTop)),O){let{width:v,height:x}=e.getBoundingClientRect();S={class:S.class,rr_width:`${v}px`,rr_height:`${x}px`}}I==="iframe"&&!p(S.src)&&(e.contentDocument||(S.rr_src=S.src),delete S.src);let $;try{customElements.get(I)&&($=!0)}catch{}return{type:Z.Element,tagName:I,attributes:S,childNodes:[],isSVG:ku(e)||void 0,needBlock:O,rootId:g,isCustom:$}}function W(e){return e==null?"":e.toLowerCase()}function Du(e,t){if(t.comment&&e.type===Z.Comment)return!0;if(e.type===Z.Element){if(t.script&&(e.tagName==="script"||e.tagName==="link"&&(e.attributes.rel==="preload"||e.attributes.rel==="modulepreload")&&e.attributes.as==="script"||e.tagName==="link"&&e.attributes.rel==="prefetch"&&typeof e.attributes.href=="string"&&e.attributes.href.endsWith(".js")))return!0;if(t.headFavicon&&(e.tagName==="link"&&e.attributes.rel==="shortcut icon"||e.tagName==="meta"&&(W(e.attributes.name).match(/^msapplication-tile(image|color)$/)||W(e.attributes.name)==="application-name"||W(e.attributes.rel)==="icon"||W(e.attributes.rel)==="apple-touch-icon"||W(e.attributes.rel)==="shortcut icon")))return!0;if(e.tagName==="meta"){if(t.headMetaDescKeywords&&W(e.attributes.name).match(/^description|keywords$/))return!0;if(t.headMetaSocial&&(W(e.attributes.property).match(/^(og|twitter|fb):/)||W(e.attributes.name).match(/^(og|twitter):/)||W(e.attributes.name)==="pinterest"))return!0;if(t.headMetaRobots&&(W(e.attributes.name)==="robots"||W(e.attributes.name)==="googlebot"||W(e.attributes.name)==="bingbot"))return!0;if(t.headMetaHttpEquiv&&e.attributes["http-equiv"]!==void 0)return!0;if(t.headMetaAuthorship&&(W(e.attributes.name)==="author"||W(e.attributes.name)==="generator"||W(e.attributes.name)==="framework"||W(e.attributes.name)==="publisher"||W(e.attributes.name)==="progid"||W(e.attributes.property).match(/^article:/)||W(e.attributes.property).match(/^product:/)))return!0;if(t.headMetaVerification&&(W(e.attributes.name)==="google-site-verification"||W(e.attributes.name)==="yandex-verification"||W(e.attributes.name)==="csrf-token"||W(e.attributes.name)==="p:domain_verify"||W(e.attributes.name)==="verify-v1"||W(e.attributes.name)==="verification"||W(e.attributes.name)==="shopify-checkout-api-token"))return!0}}return!1}function Ye(e,t){let{doc:r,mirror:n,blockClass:s,blockSelector:o,unblockSelector:i,maskAllText:a,maskTextClass:c,unmaskTextClass:l,maskTextSelector:u,unmaskTextSelector:d,skipChild:f=!1,inlineStylesheet:p=!0,maskInputOptions:h={},maskAttributeFn:g,maskTextFn:b,maskInputFn:m,slimDOMOptions:_,dataURLOptions:w={},inlineImages:C=!1,recordCanvas:O=!1,onSerialize:I,onIframeLoad:S,iframeLoadTimeout:R=5e3,onStylesheetLoad:$,stylesheetLoadTimeout:v=5e3,keepIframeSrcFn:x=()=>!1,newlyAddedElement:B=!1}=t,{preserveWhiteSpace:Y=!0}=t,J=Mu(e,{doc:r,mirror:n,blockClass:s,blockSelector:o,maskAllText:a,unblockSelector:i,maskTextClass:c,unmaskTextClass:l,maskTextSelector:u,unmaskTextSelector:d,inlineStylesheet:p,maskInputOptions:h,maskAttributeFn:g,maskTextFn:b,maskInputFn:m,dataURLOptions:w,inlineImages:C,recordCanvas:O,keepIframeSrcFn:x,newlyAddedElement:B});if(!J)return console.warn(e,"not serialized"),null;let se;n.hasNode(e)?se=n.getId(e):Du(J,_)||!Y&&J.type===Z.Text&&!J.isStyle&&!J.textContent.replace(/^\s+|\s+$/gm,"").length?se=vt:se=Yn();let H=Object.assign(J,{id:se});if(n.add(e,H),se===vt)return null;I&&I(e);let ie=!f;if(H.type===Z.Element){ie=ie&&!H.needBlock,delete H.needBlock;let X=e.shadowRoot;X&&_t(X)&&(H.isShadowHost=!0)}if((H.type===Z.Document||H.type===Z.Element)&&ie){_.headWhitespace&&H.type===Z.Element&&H.tagName==="head"&&(Y=!1);let X={doc:r,mirror:n,blockClass:s,blockSelector:o,maskAllText:a,unblockSelector:i,maskTextClass:c,unmaskTextClass:l,maskTextSelector:u,unmaskTextSelector:d,skipChild:f,inlineStylesheet:p,maskInputOptions:h,maskAttributeFn:g,maskTextFn:b,maskInputFn:m,slimDOMOptions:_,dataURLOptions:w,inlineImages:C,recordCanvas:O,preserveWhiteSpace:Y,onSerialize:I,onIframeLoad:S,iframeLoadTimeout:R,onStylesheetLoad:$,stylesheetLoadTimeout:v,keepIframeSrcFn:x};for(let ne of Array.from(e.childNodes)){let ae=Ye(ne,X);ae&&H.childNodes.push(ae)}if(iu(e)&&e.shadowRoot)for(let ne of Array.from(e.shadowRoot.childNodes)){let ae=Ye(ne,X);ae&&(_t(e.shadowRoot)&&(ae.isShadow=!0),H.childNodes.push(ae))}}return e.parentNode&&yt(e.parentNode)&&_t(e.parentNode)&&(H.isShadow=!0),H.type===Z.Element&&H.tagName==="iframe"&&Tu(e,()=>{let X=e.contentDocument;if(X&&S){let ne=Ye(X,{doc:X,mirror:n,blockClass:s,blockSelector:o,unblockSelector:i,maskAllText:a,maskTextClass:c,unmaskTextClass:l,maskTextSelector:u,unmaskTextSelector:d,skipChild:!1,inlineStylesheet:p,maskInputOptions:h,maskAttributeFn:g,maskTextFn:b,maskInputFn:m,slimDOMOptions:_,dataURLOptions:w,inlineImages:C,recordCanvas:O,preserveWhiteSpace:Y,onSerialize:I,onIframeLoad:S,iframeLoadTimeout:R,onStylesheetLoad:$,stylesheetLoadTimeout:v,keepIframeSrcFn:x});ne&&S(e,ne)}},R),H.type===Z.Element&&H.tagName==="link"&&H.attributes.rel==="stylesheet"&&Ru(e,()=>{if($){let X=Ye(e,{doc:r,mirror:n,blockClass:s,blockSelector:o,unblockSelector:i,maskAllText:a,maskTextClass:c,unmaskTextClass:l,maskTextSelector:u,unmaskTextSelector:d,skipChild:!1,inlineStylesheet:p,maskInputOptions:h,maskAttributeFn:g,maskTextFn:b,maskInputFn:m,slimDOMOptions:_,dataURLOptions:w,inlineImages:C,recordCanvas:O,preserveWhiteSpace:Y,onSerialize:I,onIframeLoad:S,iframeLoadTimeout:R,onStylesheetLoad:$,stylesheetLoadTimeout:v,keepIframeSrcFn:x});X&&$(e,X)}},v),H}function Nu(e,t){let{mirror:r=new lr,blockClass:n="rr-block",blockSelector:s=null,unblockSelector:o=null,maskAllText:i=!1,maskTextClass:a="rr-mask",unmaskTextClass:c=null,maskTextSelector:l=null,unmaskTextSelector:u=null,inlineStylesheet:d=!0,inlineImages:f=!1,recordCanvas:p=!1,maskAllInputs:h=!1,maskAttributeFn:g,maskTextFn:b,maskInputFn:m,slimDOM:_=!1,dataURLOptions:w,preserveWhiteSpace:C,onSerialize:O,onIframeLoad:I,iframeLoadTimeout:S,onStylesheetLoad:R,stylesheetLoadTimeout:$,keepIframeSrcFn:v=()=>!1}=t||{};return Ye(e,{doc:e,mirror:r,blockClass:n,blockSelector:s,unblockSelector:o,maskAllText:i,maskTextClass:a,unmaskTextClass:c,maskTextSelector:l,unmaskTextSelector:u,skipChild:!1,inlineStylesheet:d,maskInputOptions:h===!0?{color:!0,date:!0,"datetime-local":!0,email:!0,month:!0,number:!0,range:!0,search:!0,tel:!0,text:!0,time:!0,url:!0,week:!0,textarea:!0,select:!0}:h===!1?{}:h,maskAttributeFn:g,maskTextFn:b,maskInputFn:m,slimDOMOptions:_===!0||_==="all"?{script:!0,comment:!0,headFavicon:!0,headWhitespace:!0,headMetaDescKeywords:_==="all",headMetaSocial:!0,headMetaRobots:!0,headMetaHttpEquiv:!0,headMetaAuthorship:!0,headMetaVerification:!0}:_===!1?{}:_,dataURLOptions:w,inlineImages:f,recordCanvas:p,preserveWhiteSpace:C,onSerialize:O,onIframeLoad:I,iframeLoadTimeout:S,onStylesheetLoad:R,stylesheetLoadTimeout:$,keepIframeSrcFn:v,newlyAddedElement:!1})}function ve(e){let t,r=e[0],n=1;for(;n<e.length;){let s=e[n],o=e[n+1];if(n+=2,(s==="optionalAccess"||s==="optionalCall")&&r==null)return;s==="access"||s==="optionalAccess"?(t=r,r=o(r)):(s==="call"||s==="optionalCall")&&(r=o((...i)=>r.call(t,...i)),t=void 0)}return r}function re(e,t,r=document){let n={capture:!0,passive:!0};return r.addEventListener(e,t,n),()=>r.removeEventListener(e,t,n)}var Ge=`Please stop import mirror directly. Instead of that,\r
3
+ import{$ as Ps,A as Cs,Aa as La,Ab as Xs,B as Re,Ba as qt,Bb as Js,Ca as Da,Cb as mc,D as xs,Da as le,Db as Q,E as Be,Ea as Yr,Eb as Zs,F as Ts,Fa as Na,Fb as Jr,G as at,Ga as Pa,H as He,Ha as Fa,Hb as Qs,Ia as Ba,Ib as gc,Ja as Ha,Jb as ft,K as Ut,Ka as dt,Kb as eo,L as Rs,La as Ua,Lb as yc,M as Ms,Ma as Wa,Mb as to,N as Wt,Na as za,Nb as _c,O as As,Oa as $a,Ob as ro,P as Os,Pa as ja,Pb as Sc,Q as Ue,Qa as Ga,Qb as bc,R as ct,Ra as D,S as zt,Sa as qa,T as Ls,Ta as me,Tb as Zr,Ua as Vt,Ub as vc,V as lt,Va,Vb as Qr,W as qr,Wa as Yt,Wb as Ec,X as Ds,Yb as wc,Z as Vr,Zb as no,_ as Ns,_a as Ya,a as ms,aa as $t,ab as Ka,b as ot,bb as Xa,c as Wr,ca as Fs,d as gs,da as Bs,db as Ja,e as zr,ea as ut,eb as Kr,f as ys,fb as Kt,fc as so,g as $r,gb as Za,gc as oo,h as _s,ha as jt,hb as Qa,hc as Ic,i as Nt,ia as Hs,ib as ec,ic as kc,j as jr,ja as Us,jb as tc,jc as Cc,k as Ss,ka as Ws,kb as rc,kc as xc,l as bs,la as zs,lb as nc,lc as Tc,m as Se,ma as $s,mc as Rc,n as it,na as js,nb as sc,nc as Mc,o as Pt,oa as Gs,ob as oc,oc as Ac,p as vs,pa as qs,pb as ic,pc as Oc,q as Ft,qb as ac,qc as Lc,r as y,ra as Vs,rb as cc,rc as Dc,s as Bt,sa as We,sb as lc,sc as Nc,t as fe,tb as Xr,tc as Pc,u as Es,ua as Ys,ub as uc,uc as Fc,v as ws,va as Oa,vb as dc,vc as Bc,w as Ht,wb as fc,x as Is,xa as be,xb as pc,y as Gr,ya as Gt,yb as hc,z as ks,za as ze,zb as Ks}from"./chunk-GLLV5RPM.js";import{d as Aa,h as k}from"./chunk-V4TR6DCM.js";k();k();var E=Se,en=0;function tn(){return en>0}function Hc(){en++,setTimeout(()=>{en--})}function ge(e,t={},r){if(typeof e!="function")return e;try{let s=e.__sentry_wrapped__;if(s)return s;if(Ht(e))return e}catch{return e}let n=function(){let s=Array.prototype.slice.call(arguments);try{r&&typeof r=="function"&&r.apply(this,arguments);let o=s.map(i=>ge(i,t));return e.apply(this,o)}catch(o){throw Hc(),dt(i=>{i.addEventProcessor(a=>(t.mechanism&&(at(a,void 0,void 0),He(a,t.mechanism)),a.extra={...a.extra,arguments:s},a)),ze(o)}),o}};try{for(let s in e)Object.prototype.hasOwnProperty.call(e,s)&&(n[s]=e[s])}catch{}ws(n,e),Es(e,"__sentry_wrapped__",n);try{Object.getOwnPropertyDescriptor(n,"name").configurable&&Object.defineProperty(n,"name",{get(){return e.name}})}catch{}return n}k();k();var T=typeof __SENTRY_DEBUG__>"u"||__SENTRY_DEBUG__;k();function Xt(e,t){let r=sn(e,t),n={type:t&&t.name,value:$c(t)};return r.length&&(n.stacktrace={frames:r}),n.type===void 0&&n.value===""&&(n.value="Unrecoverable error caught"),n}function Uc(e,t,r,n){let s=D(),o=s&&s.getOptions().normalizeDepth,i={exception:{values:[{type:Nt(t)?t.constructor.name:n?"UnhandledRejection":"Error",value:jc(t,{isUnhandledRejection:n})}]},extra:{__serialized__:Ds(t,o)}};if(r){let a=sn(e,r);a.length&&(i.exception.values[0].stacktrace={frames:a})}return i}function rn(e,t){return{exception:{values:[Xt(e,t)]}}}function sn(e,t){let r=t.stacktrace||t.stack||"",n=zc(t);try{return e(r,n)}catch{}return[]}var Wc=/Minified React error #\d+;/i;function zc(e){if(e){if(typeof e.framesToPop=="number")return e.framesToPop;if(Wc.test(e.message))return 1}return 0}function $c(e){let t=e&&e.message;return t?t.error&&typeof t.error.message=="string"?t.error.message:t:"No error message"}function on(e,t,r,n){let s=r&&r.syntheticException||void 0,o=Jt(e,t,s,n);return He(o),o.level="error",r&&r.event_id&&(o.event_id=r.event_id),Vr(o)}function an(e,t,r="info",n,s){let o=n&&n.syntheticException||void 0,i=nn(e,t,o,s);return i.level=r,n&&n.event_id&&(i.event_id=n.event_id),Vr(i)}function Jt(e,t,r,n,s){let o;if(ot(t)&&t.error)return rn(e,t.error);if(Wr(t)||gs(t)){let i=t;if("stack"in t)o=rn(e,t);else{let a=i.name||(Wr(i)?"DOMError":"DOMException"),c=i.message?`${a}: ${i.message}`:a;o=nn(e,c,r,n),at(o,c)}return"code"in i&&(o.tags={...o.tags,"DOMException.code":`${i.code}`}),o}return ms(t)?rn(e,t):_s(t)||Nt(t)?(o=Uc(e,t,r,s),He(o,{synthetic:!0}),o):(o=nn(e,t,r,n),at(o,`${t}`,void 0),He(o,{synthetic:!0}),o)}function nn(e,t,r,n){let s={};if(n&&r){let o=sn(e,r);o.length&&(s.exception={values:[{value:t,stacktrace:{frames:o}}]})}if(ys(t)){let{__sentry_template_string__:o,__sentry_template_values__:i}=t;return s.logentry={message:o,params:i},s}return s.message=t,s}function jc(e,{isUnhandledRejection:t}){let r=Is(e),n=t?"promise rejection":"exception";return ot(e)?`Event \`ErrorEvent\` captured as ${n} with message \`${e.message}\``:Nt(e)?`Event \`${Gc(e)}\` (type=${e.type}) captured as ${n}`:`Object captured as ${n} with keys: ${r}`}function Gc(e){try{let t=Object.getPrototypeOf(e);return t?t.constructor.name:void 0}catch{}}k();function cn(e,{metadata:t,tunnel:r,dsn:n}){let s={event_id:e.event_id,sent_at:new Date().toISOString(),...t&&t.sdk&&{sdk:{name:t.sdk.name,version:t.sdk.version}},...!!r&&!!n&&{dsn:Bt(n)}},o=qc(e);return jt(s,[o])}function qc(e){return[{type:"user_report"},e]}var pt=class extends Zs{constructor(t){let r=E.SENTRY_SDK_SOURCE||Ls();ro(t,"browser",["browser"],r),super(t),t.sendClientReports&&E.document&&E.document.addEventListener("visibilitychange",()=>{E.document.visibilityState==="hidden"&&this._flushOutcomes()})}eventFromException(t,r){return on(this._options.stackParser,t,r,this._options.attachStacktrace)}eventFromMessage(t,r="info",n){return an(this._options.stackParser,t,r,n,this._options.attachStacktrace)}captureUserFeedback(t){if(!this._isEnabled()){T&&y.warn("SDK not enabled, will not capture user feedback.");return}let r=cn(t,{metadata:this.getSdkMetadata(),dsn:this.getDsn(),tunnel:this.getOptions().tunnel});this._sendEnvelope(r)}_prepareEvent(t,r,n){return t.platform=t.platform||"javascript",super._prepareEvent(t,r,n)}_flushOutcomes(){let t=this._clearOutcomes();if(t.length===0){T&&y.log("No outcomes to send");return}if(!this._dsn){T&&y.log("No dsn provided, will not send outcomes");return}T&&y.log("Sending outcomes:",t);let r=js(t,this._options.tunnel&&Bt(this._dsn));this._sendEnvelope(r)}};k();k();var ht;function io(){if(ht)return ht;if(Ms(E.fetch))return ht=E.fetch.bind(E);let e=E.document,t=E.fetch;if(e&&typeof e.createElement=="function")try{let r=e.createElement("iframe");r.hidden=!0,e.head.appendChild(r);let n=r.contentWindow;n&&n.fetch&&(t=n.fetch),e.head.removeChild(r)}catch(r){T&&y.warn("Could not create sandbox iframe for pure fetch check, bailing to window.fetch: ",r)}return ht=t.bind(E)}function ao(){ht=void 0}function ln(e,t=io()){let r=0,n=0;function s(o){let i=o.body.length;r+=i,n++;let a={body:o.body,method:"POST",referrerPolicy:"origin",headers:e.headers,keepalive:r<=6e4&&n<15,...e.fetchOptions};try{return t(e.url,a).then(c=>(r-=i,n--,{statusCode:c.status,headers:{"x-sentry-rate-limits":c.headers.get("X-Sentry-Rate-Limits"),"retry-after":c.headers.get("Retry-After")}}))}catch(c){return ao(),r-=i,n--,Ns(c)}}return ft(e,s)}k();var Vc=4;function un(e){function t(r){return new Ps((n,s)=>{let o=new XMLHttpRequest;o.onerror=s,o.onreadystatechange=()=>{o.readyState===Vc&&n({statusCode:o.status,headers:{"x-sentry-rate-limits":o.getResponseHeader("X-Sentry-Rate-Limits"),"retry-after":o.getResponseHeader("Retry-After")}})},o.open("POST",e.url);for(let i in e.headers)Object.prototype.hasOwnProperty.call(e.headers,i)&&o.setRequestHeader(i,e.headers[i]);o.send(r.body)})}return ft(e,t)}k();var $e="?",Yc=10,Kc=20,Xc=30,Jc=40,Zc=50;function mt(e,t,r,n){let s={filename:e,function:t,in_app:!0};return r!==void 0&&(s.lineno=r),n!==void 0&&(s.colno=n),s}var Qc=/^\s*at (?:(.+?\)(?: \[.+\])?|.*?) ?\((?:address at )?)?(?:async )?((?:<anonymous>|[-a-z]+:|.*bundle|\/)?.*?)(?::(\d+))?(?::(\d+))?\)?\s*$/i,el=/\((\S*)(?::(\d+))(?::(\d+))\)/,tl=e=>{let t=Qc.exec(e);if(t){if(t[2]&&t[2].indexOf("eval")===0){let o=el.exec(t[2]);o&&(t[2]=o[1],t[3]=o[2],t[4]=o[3])}let[n,s]=po(t[1]||$e,t[2]);return mt(s,n,t[3]?+t[3]:void 0,t[4]?+t[4]:void 0)}},co=[Xc,tl],rl=/^\s*(.*?)(?:\((.*?)\))?(?:^|@)?((?:[-a-z]+)?:\/.*?|\[native code\]|[^@]*(?:bundle|\d+\.js)|\/[\w\-. /=]+)(?::(\d+))?(?::(\d+))?\s*$/i,nl=/(\S+) line (\d+)(?: > eval line \d+)* > eval/i,sl=e=>{let t=rl.exec(e);if(t){if(t[3]&&t[3].indexOf(" > eval")>-1){let o=nl.exec(t[3]);o&&(t[1]=t[1]||"eval",t[3]=o[1],t[4]=o[2],t[5]="")}let n=t[3],s=t[1]||$e;return[s,n]=po(s,n),mt(n,s,t[4]?+t[4]:void 0,t[5]?+t[5]:void 0)}},lo=[Zc,sl],ol=/^\s*at (?:((?:\[object object\])?.+) )?\(?((?:[-a-z]+):.*?):(\d+)(?::(\d+))?\)?\s*$/i,il=e=>{let t=ol.exec(e);return t?mt(t[2],t[1]||$e,+t[3],t[4]?+t[4]:void 0):void 0},uo=[Jc,il],al=/ line (\d+).*script (?:in )?(\S+)(?:: in function (\S+))?$/i,cl=e=>{let t=al.exec(e);return t?mt(t[2],t[3]||$e,+t[1]):void 0},ll=[Yc,cl],ul=/ line (\d+), column (\d+)\s*(?:in (?:<anonymous function: ([^>]+)>|([^)]+))\(.*\))? in (.*):\s*$/i,dl=e=>{let t=ul.exec(e);return t?mt(t[5],t[3]||t[4]||$e,+t[1],+t[2]):void 0},fl=[Kc,dl],fo=[co,lo,uo],dn=ks(...fo),po=(e,t)=>{let r=e.indexOf("safari-extension")!==-1,n=e.indexOf("safari-web-extension")!==-1;return r||n?[e.indexOf("@")!==-1?e.split("@")[0]:$e,r?`safari-extension:${t}`:`safari-web-extension:${t}`]:[e,t]};k();k();var Zt=1024,ho="Breadcrumbs",pl=(e={})=>{let t={console:!0,dom:!0,fetch:!0,history:!0,sentry:!0,xhr:!0,...e};return{name:ho,setupOnce(){},setup(r){t.console&&xs(gl(r)),t.dom&&Ut(ml(r,t.dom)),t.xhr&&zt(yl(r)),t.fetch&&Wt(_l(r)),t.history&&Ue(Sl(r)),t.sentry&&r.on&&r.on("beforeSendEvent",hl(r))}}},Qt=pl,fn=Q(ho,Qt);function hl(e){return function(r){D()===e&&le({category:`sentry.${r.type==="transaction"?"transaction":"event"}`,event_id:r.event_id,level:r.level,message:Ts(r)},{event:r})}}function ml(e,t){return function(n){if(D()!==e)return;let s,o,i=typeof t=="object"?t.serializeAttribute:void 0,a=typeof t=="object"&&typeof t.maxStringLength=="number"?t.maxStringLength:void 0;a&&a>Zt&&(T&&y.warn(`\`dom.maxStringLength\` cannot exceed ${Zt}, but a value of ${a} was configured. Sentry will use ${Zt} instead.`),a=Zt),typeof i=="string"&&(i=[i]);try{let l=n.event,u=bl(l)?l.target:l;s=it(u,{keyAttrs:i,maxStringLength:a}),o=vs(u)}catch{s="<unknown>"}if(s.length===0)return;let c={category:`ui.${n.name}`,message:s};o&&(c.data={"ui.component_name":o}),le(c,{event:n.event,name:n.name,global:n.global})}}function gl(e){return function(r){if(D()!==e)return;let n={category:"console",data:{arguments:r.args,logger:"console"},level:Fs(r.level),message:jr(r.args," ")};if(r.level==="assert")if(r.args[0]===!1)n.message=`Assertion failed: ${jr(r.args.slice(1)," ")||"console.assert"}`,n.data.arguments=r.args.slice(1);else return;le(n,{input:r.args,level:r.level})}}function yl(e){return function(r){if(D()!==e)return;let{startTimestamp:n,endTimestamp:s}=r,o=r.xhr[ct];if(!n||!s||!o)return;let{method:i,url:a,status_code:c,body:l}=o,u={method:i,url:a,status_code:c},d={xhr:r.xhr,input:l,startTimestamp:n,endTimestamp:s};le({category:"xhr",data:u,type:"http"},d)}}function _l(e){return function(r){if(D()!==e)return;let{startTimestamp:n,endTimestamp:s}=r;if(s&&!(r.fetchData.url.match(/sentry_key/)&&r.fetchData.method==="POST"))if(r.error){let o=r.fetchData,i={data:r.error,input:r.args,startTimestamp:n,endTimestamp:s};le({category:"fetch",data:o,level:"error",type:"http"},i)}else{let o=r.response,i={...r.fetchData,status_code:o&&o.status},a={input:r.args,response:o,startTimestamp:n,endTimestamp:s};le({category:"fetch",data:i,type:"http"},a)}}}function Sl(e){return function(r){if(D()!==e)return;let n=r.from,s=r.to,o=$t(E.location.href),i=n?$t(n):void 0,a=$t(s);(!i||!i.path)&&(i=o),o.protocol===a.protocol&&o.host===a.host&&(s=a.relative),o.protocol===i.protocol&&o.host===i.host&&(n=i.relative),le({category:"navigation",data:{from:n,to:s}})}}function bl(e){return!!e&&!!e.target}k();var yo="Dedupe",vl=()=>{let e;return{name:yo,setupOnce(){},processEvent(t){if(t.type)return t;try{if(El(t,e))return T&&y.warn("Event dropped due to being a duplicate of previously captured event."),null}catch{}return e=t}}},pn=vl,hn=Q(yo,pn);function El(e,t){return t?!!(wl(e,t)||Il(e,t)):!1}function wl(e,t){let r=e.message,n=t.message;return!(!r&&!n||r&&!n||!r&&n||r!==n||!So(e,t)||!_o(e,t))}function Il(e,t){let r=mo(t),n=mo(e);return!(!r||!n||r.type!==n.type||r.value!==n.value||!So(e,t)||!_o(e,t))}function _o(e,t){let r=go(e),n=go(t);if(!r&&!n)return!0;if(r&&!n||!r&&n||(r=r,n=n,n.length!==r.length))return!1;for(let s=0;s<n.length;s++){let o=n[s],i=r[s];if(o.filename!==i.filename||o.lineno!==i.lineno||o.colno!==i.colno||o.function!==i.function)return!1}return!0}function So(e,t){let r=e.fingerprint,n=t.fingerprint;if(!r&&!n)return!0;if(r&&!n||!r&&n)return!1;r=r,n=n;try{return r.join("")===n.join("")}catch{return!1}}function mo(e){return e.exception&&e.exception.values&&e.exception.values[0]}function go(e){let t=e.exception;if(t)try{return t.values[0].stacktrace.frames}catch{return}}k();var vo="GlobalHandlers",kl=(e={})=>{let t={onerror:!0,onunhandledrejection:!0,...e};return{name:vo,setupOnce(){Error.stackTraceLimit=50},setup(r){t.onerror&&(Cl(r),bo("onerror")),t.onunhandledrejection&&(xl(r),bo("onunhandledrejection"))}}},er=kl,mn=Q(vo,er);function Cl(e){As(t=>{let{stackParser:r,attachStacktrace:n}=wo();if(D()!==e||tn())return;let{msg:s,url:o,line:i,column:a,error:c}=t,l=c===void 0&&zr(s)?Ml(s,o,i,a):Eo(Jt(r,c||s,void 0,n,!1),o,i,a);l.level="error",qt(l,{originalException:c,mechanism:{handled:!1,type:"onerror"}})})}function xl(e){Os(t=>{let{stackParser:r,attachStacktrace:n}=wo();if(D()!==e||tn())return;let s=Tl(t),o=$r(s)?Rl(s):Jt(r,s,void 0,n,!0);o.level="error",qt(o,{originalException:s,mechanism:{handled:!1,type:"onunhandledrejection"}})})}function Tl(e){if($r(e))return e;let t=e;try{if("reason"in t)return t.reason;if("detail"in t&&"reason"in t.detail)return t.detail.reason}catch{}return e}function Rl(e){return{exception:{values:[{type:"UnhandledRejection",value:`Non-Error promise rejection captured with value: ${String(e)}`}]}}}function Ml(e,t,r,n){let s=/^(?:[Uu]ncaught (?:exception: )?)?(?:((?:Eval|Internal|Range|Reference|Syntax|Type|URI|)Error): )?(.*)$/i,o=ot(e)?e.message:e,i="Error",a=o.match(s);return a&&(i=a[1],o=a[2]),Eo({exception:{values:[{type:i,value:o}]}},t,r,n)}function Eo(e,t,r,n){let s=e.exception=e.exception||{},o=s.values=s.values||[],i=o[0]=o[0]||{},a=i.stacktrace=i.stacktrace||{},c=a.frames=a.frames||[],l=isNaN(parseInt(n,10))?void 0:n,u=isNaN(parseInt(r,10))?void 0:r,d=zr(t)&&t.length>0?t:Pt();return c.length===0&&c.push({colno:l,filename:d,function:"?",in_app:!0,lineno:u}),e}function bo(e){T&&y.log(`Global Handler attached: ${e}`)}function wo(){let e=D();return e&&e.getOptions()||{stackParser:()=>[],attachStacktrace:!1}}k();var Io="HttpContext",Al=()=>({name:Io,setupOnce(){},preprocessEvent(e){if(!E.navigator&&!E.location&&!E.document)return;let t=e.request&&e.request.url||E.location&&E.location.href,{referrer:r}=E.document||{},{userAgent:n}=E.navigator||{},s={...e.request&&e.request.headers,...r&&{Referer:r},...n&&{"User-Agent":n}},o={...e.request,...t&&{url:t},headers:s};e.request=o}}),tr=Al,gn=Q(Io,tr);k();var Ol="cause",Ll=5,ko="LinkedErrors",Dl=(e={})=>{let t=e.limit||Ll,r=e.key||Ol;return{name:ko,setupOnce(){},preprocessEvent(n,s,o){let i=o.getOptions();bs(Xt,i.stackParser,i.maxValueLength,r,t,n,s)}}},rr=Dl,yn=Q(ko,rr);k();var Nl=["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"],xo="TryCatch",Pl=(e={})=>{let t={XMLHttpRequest:!0,eventTarget:!0,requestAnimationFrame:!0,setInterval:!0,setTimeout:!0,...e};return{name:xo,setupOnce(){t.setTimeout&&fe(E,"setTimeout",Co),t.setInterval&&fe(E,"setInterval",Co),t.requestAnimationFrame&&fe(E,"requestAnimationFrame",Fl),t.XMLHttpRequest&&"XMLHttpRequest"in E&&fe(XMLHttpRequest.prototype,"send",Bl);let r=t.eventTarget;r&&(Array.isArray(r)?r:Nl).forEach(Hl)}}},nr=Pl,_n=Q(xo,nr);function Co(e){return function(...t){let r=t[0];return t[0]=ge(r,{mechanism:{data:{function:Re(e)},handled:!1,type:"instrument"}}),e.apply(this,t)}}function Fl(e){return function(t){return e.apply(this,[ge(t,{mechanism:{data:{function:"requestAnimationFrame",handler:Re(e)},handled:!1,type:"instrument"}})])}}function Bl(e){return function(...t){let r=this;return["onload","onerror","onprogress","onreadystatechange"].forEach(s=>{s in r&&typeof r[s]=="function"&&fe(r,s,function(o){let i={mechanism:{data:{function:s,handler:Re(o)},handled:!1,type:"instrument"}},a=Ht(o);return a&&(i.mechanism.data.handler=Re(a)),ge(o,i)})}),e.apply(this,t)}}function Hl(e){let t=E,r=t[e]&&t[e].prototype;!r||!r.hasOwnProperty||!r.hasOwnProperty("addEventListener")||(fe(r,"addEventListener",function(n){return function(s,o,i){try{typeof o.handleEvent=="function"&&(o.handleEvent=ge(o.handleEvent,{mechanism:{data:{function:"handleEvent",handler:Re(o),target:e},handled:!1,type:"instrument"}}))}catch{}return n.apply(this,[s,ge(o,{mechanism:{data:{function:"addEventListener",handler:Re(o),target:e},handled:!1,type:"instrument"}}),i])}}),fe(r,"removeEventListener",function(n){return function(s,o,i){let a=o;try{let c=a&&a.__sentry_wrapped__;c&&n.call(this,s,c,i)}catch{}return n.call(this,s,a,i)}}))}var To=[Zr(),Qr(),nr(),Qt(),er(),rr(),pn(),tr()];function Ro(e){return[...To]}function Ul(e={}){e.defaultIntegrations===void 0&&(e.defaultIntegrations=Ro()),e.release===void 0&&(typeof __SENTRY_RELEASE__=="string"&&(e.release=__SENTRY_RELEASE__),E.SENTRY_RELEASE&&E.SENTRY_RELEASE.id&&(e.release=E.SENTRY_RELEASE.id)),e.autoSessionTracking===void 0&&(e.autoSessionTracking=!0),e.sendClientReports===void 0&&(e.sendClientReports=!0);let t={...e,stackParser:Cs(e.stackParser||dn),integrations:Js(e),transport:e.transport||(Rs()?ln:un)};Qs(pt,t),e.autoSessionTracking&&Gl()}var Wl=(e={},t=Kr())=>{if(!E.document){T&&y.error("Global document not defined in showReportDialog call");return}let{client:r,scope:n}=t.getStackTop(),s=e.dsn||r&&r.getDsn();if(!s){T&&y.error("DSN not configured for showReportDialog call");return}n&&(e.user={...n.getUser(),...e.user}),e.eventId||(e.eventId=t.lastEventId());let o=E.document.createElement("script");o.async=!0,o.crossOrigin="anonymous",o.src=Xs(s,e),e.onLoad&&(o.onload=e.onLoad);let{onClose:i}=e;if(i){let c=l=>{if(l.data==="__sentry_reportdialog_closed__")try{i()}finally{E.removeEventListener("message",c)}};E.addEventListener("message",c)}let a=E.document.head||E.document.body;a?a.appendChild(o):T&&y.error("Not injecting report dialog. No injection point found in HTML")};function zl(){}function $l(e){e()}function jl(e){return ge(e)()}function Gl(){if(typeof E.document>"u"){T&&y.warn("Session tracking in non-browser environment with @sentry/browser is not supported.");return}Vt({ignoreDuration:!0}),Yt(),Ue(({from:e,to:t})=>{e!==void 0&&e!==t&&(Vt({ignoreDuration:!0}),Yt())})}function ql(e){let t=D();t&&t.captureUserFeedback(e)}var Sn={};Aa(Sn,{Breadcrumbs:()=>fn,Dedupe:()=>hn,GlobalHandlers:()=>mn,HttpContext:()=>gn,LinkedErrors:()=>yn,TryCatch:()=>_n});k();k();var z=Se,jn="sentryReplaySession",Vl="replay_event",Gn="Unable to send Replay",Yl=3e5,Kl=9e5,Xl=5e3,Jl=5500,Zl=6e4,Ql=5e3,eu=3,Mo=15e4,sr=5e3,tu=3e3,ru=300,qn=2e7,nu=4999,su=15e3,Ao=36e5;function ou(e,t){return e??t()}function ar(e){let t,r=e[0],n=1;for(;n<e.length;){let s=e[n],o=e[n+1];if(n+=2,(s==="optionalAccess"||s==="optionalCall")&&r==null)return;s==="access"||s==="optionalAccess"?(t=r,r=o(r)):(s==="call"||s==="optionalCall")&&(r=o((...i)=>r.call(t,...i)),t=void 0)}return r}var Z;(function(e){e[e.Document=0]="Document",e[e.DocumentType=1]="DocumentType",e[e.Element=2]="Element",e[e.Text=3]="Text",e[e.CDATA=4]="CDATA",e[e.Comment=5]="Comment"})(Z||(Z={}));function iu(e){return e.nodeType===e.ELEMENT_NODE}function yt(e){let t=ar([e,"optionalAccess",r=>r.host]);return ar([t,"optionalAccess",r=>r.shadowRoot])===e}function _t(e){return Object.prototype.toString.call(e)==="[object ShadowRoot]"}function au(e){return e.includes(" background-clip: text;")&&!e.includes(" -webkit-background-clip: text;")&&(e=e.replace(" background-clip: text;"," -webkit-background-clip: text; background-clip: text;")),e}function cu(e){let{cssText:t}=e;if(t.split('"').length<3)return t;let r=["@import",`url(${JSON.stringify(e.href)})`];return e.layerName===""?r.push("layer"):e.layerName&&r.push(`layer(${e.layerName})`),e.supportsText&&r.push(`supports(${e.supportsText})`),e.media.length&&r.push(e.media.mediaText),r.join(" ")+";"}function cr(e){try{let t=e.rules||e.cssRules;return t?au(Array.from(t,Zo).join("")):null}catch{return null}}function Zo(e){let t;if(uu(e))try{t=cr(e.styleSheet)||cu(e)}catch{}else if(du(e)&&e.selectorText.includes(":"))return lu(e.cssText);return t||e.cssText}function lu(e){let t=/(\[(?:[\w-]+)[^\\])(:(?:[\w-]+)\])/gm;return e.replace(t,"$1\\$2")}function uu(e){return"styleSheet"in e}function du(e){return"selectorText"in e}var lr=class{constructor(){this.idNodeMap=new Map,this.nodeMetaMap=new WeakMap}getId(t){if(!t)return-1;let r=ar([this,"access",n=>n.getMeta,"call",n=>n(t),"optionalAccess",n=>n.id]);return ou(r,()=>-1)}getNode(t){return this.idNodeMap.get(t)||null}getIds(){return Array.from(this.idNodeMap.keys())}getMeta(t){return this.nodeMetaMap.get(t)||null}removeNodeFromMap(t){let r=this.getId(t);this.idNodeMap.delete(r),t.childNodes&&t.childNodes.forEach(n=>this.removeNodeFromMap(n))}has(t){return this.idNodeMap.has(t)}hasNode(t){return this.nodeMetaMap.has(t)}add(t,r){let n=r.id;this.idNodeMap.set(n,t),this.nodeMetaMap.set(t,r)}replace(t,r){let n=this.getNode(t);if(n){let s=this.nodeMetaMap.get(n);s&&this.nodeMetaMap.set(r,s)}this.idNodeMap.set(t,r)}reset(){this.idNodeMap=new Map,this.nodeMetaMap=new WeakMap}};function fu(){return new lr}function Er({maskInputOptions:e,tagName:t,type:r}){return t==="OPTION"&&(t="SELECT"),!!(e[t.toLowerCase()]||r&&e[r]||r==="password"||t==="INPUT"&&!r&&e.text)}function bt({isMasked:e,element:t,value:r,maskInputFn:n}){let s=r||"";return e?(n&&(s=n(s,t)),"*".repeat(s.length)):s}function Je(e){return e.toLowerCase()}function wn(e){return e.toUpperCase()}var Oo="__rrweb_original__";function pu(e){let t=e.getContext("2d");if(!t)return!0;let r=50;for(let n=0;n<e.width;n+=r)for(let s=0;s<e.height;s+=r){let o=t.getImageData,i=Oo in o?o[Oo]:o;if(new Uint32Array(i.call(t,n,s,Math.min(r,e.width-n),Math.min(r,e.height-s)).data.buffer).some(c=>c!==0))return!1}return!0}function Vn(e){let t=e.type;return e.hasAttribute("data-rr-is-password")?"password":t?Je(t):null}function ur(e,t,r){return t==="INPUT"&&(r==="radio"||r==="checkbox")?e.getAttribute("value")||"":e.value}var hu=1,mu=new RegExp("[^a-z0-9-_:]"),vt=-2;function Yn(){return hu++}function gu(e){if(e instanceof HTMLFormElement)return"form";let t=Je(e.tagName);return mu.test(t)?"div":t}function yu(e){let t="";return e.indexOf("//")>-1?t=e.split("/").slice(0,3).join("/"):t=e.split("/")[0],t=t.split("?")[0],t}var je,Lo,_u=/url\((?:(')([^']*)'|(")(.*?)"|([^)]*))\)/gm,Su=/^(?:[a-z+]+:)?\/\//i,bu=/^www\..*/i,vu=/^(data:)([^,]*),(.*)/i;function dr(e,t){return(e||"").replace(_u,(r,n,s,o,i,a)=>{let c=s||i||a,l=n||o||"";if(!c)return r;if(Su.test(c)||bu.test(c))return`url(${l}${c}${l})`;if(vu.test(c))return`url(${l}${c}${l})`;if(c[0]==="/")return`url(${l}${yu(t)+c}${l})`;let u=t.split("/"),d=c.split("/");u.pop();for(let f of d)f!=="."&&(f===".."?u.pop():u.push(f));return`url(${l}${u.join("/")}${l})`})}var Eu=/^[^ \t\n\r\u000c]+/,wu=/^[, \t\n\r\u000c]+/;function Iu(e,t){if(t.trim()==="")return t;let r=0;function n(o){let i,a=o.exec(t.substring(r));return a?(i=a[0],r+=i.length,i):""}let s=[];for(;n(wu),!(r>=t.length);){let o=n(Eu);if(o.slice(-1)===",")o=qe(e,o.substring(0,o.length-1)),s.push(o);else{let i="";o=qe(e,o);let a=!1;for(;;){let c=t.charAt(r);if(c===""){s.push((o+i).trim());break}else if(a)c===")"&&(a=!1);else if(c===","){r+=1,s.push((o+i).trim());break}else c==="("&&(a=!0);i+=c,r+=1}}}return s.join(", ")}function qe(e,t){if(!t||t.trim()==="")return t;let r=e.createElement("a");return r.href=t,r.href}function ku(e){return!!(e.tagName==="svg"||e.ownerSVGElement)}function Kn(){let e=document.createElement("a");return e.href="",e.href}function Qo(e,t,r,n,s,o){return n&&(r==="src"||r==="href"&&!(t==="use"&&n[0]==="#")||r==="xlink:href"&&n[0]!=="#"||r==="background"&&(t==="table"||t==="td"||t==="th")?qe(e,n):r==="srcset"?Iu(e,n):r==="style"?dr(n,Kn()):t==="object"&&r==="data"?qe(e,n):typeof o=="function"?o(r,n,s):n)}function ei(e,t,r){return(e==="video"||e==="audio")&&t==="autoplay"}function Cu(e,t,r,n){try{if(n&&e.matches(n))return!1;if(typeof t=="string"){if(e.classList.contains(t))return!0}else for(let s=e.classList.length;s--;){let o=e.classList[s];if(t.test(o))return!0}if(r)return e.matches(r)}catch{}return!1}function xu(e,t){for(let r=e.classList.length;r--;){let n=e.classList[r];if(t.test(n))return!0}return!1}function Ae(e,t,r=1/0,n=0){return!e||e.nodeType!==e.ELEMENT_NODE||n>r?-1:t(e)?n:Ae(e.parentNode,t,r,n+1)}function Ve(e,t){return r=>{let n=r;if(n===null)return!1;try{if(e){if(typeof e=="string"){if(n.matches(`.${e}`))return!0}else if(xu(n,e))return!0}return!!(t&&n.matches(t))}catch{return!1}}}function Ze(e,t,r,n,s,o){try{let i=e.nodeType===e.ELEMENT_NODE?e:e.parentElement;if(i===null)return!1;if(i.tagName==="INPUT"){let l=i.getAttribute("autocomplete");if(["current-password","new-password","cc-number","cc-exp","cc-exp-month","cc-exp-year","cc-csc"].includes(l))return!0}let a=-1,c=-1;if(o){if(c=Ae(i,Ve(n,s)),c<0)return!0;a=Ae(i,Ve(t,r),c>=0?c:1/0)}else{if(a=Ae(i,Ve(t,r)),a<0)return!1;c=Ae(i,Ve(n,s),a>=0?a:1/0)}return a>=0?c>=0?a<=c:!0:c>=0?!1:!!o}catch{}return!!o}function Tu(e,t,r){let n=e.contentWindow;if(!n)return;let s=!1,o;try{o=n.document.readyState}catch{return}if(o!=="complete"){let a=setTimeout(()=>{s||(t(),s=!0)},r);e.addEventListener("load",()=>{clearTimeout(a),s=!0,t()});return}let i="about:blank";if(n.location.href!==i||e.src===i||e.src==="")return setTimeout(t,0),e.addEventListener("load",t);e.addEventListener("load",t)}function Ru(e,t,r){let n=!1,s;try{s=e.sheet}catch{return}if(s)return;let o=setTimeout(()=>{n||(t(),n=!0)},r);e.addEventListener("load",()=>{clearTimeout(o),n=!0,t()})}function Mu(e,t){let{doc:r,mirror:n,blockClass:s,blockSelector:o,unblockSelector:i,maskAllText:a,maskAttributeFn:c,maskTextClass:l,unmaskTextClass:u,maskTextSelector:d,unmaskTextSelector:f,inlineStylesheet:p,maskInputOptions:h={},maskTextFn:g,maskInputFn:b,dataURLOptions:m={},inlineImages:_,recordCanvas:w,keepIframeSrcFn:C,newlyAddedElement:O=!1}=t,I=Au(r,n);switch(e.nodeType){case e.DOCUMENT_NODE:return e.compatMode!=="CSS1Compat"?{type:Z.Document,childNodes:[],compatMode:e.compatMode}:{type:Z.Document,childNodes:[]};case e.DOCUMENT_TYPE_NODE:return{type:Z.DocumentType,name:e.name,publicId:e.publicId,systemId:e.systemId,rootId:I};case e.ELEMENT_NODE:return Lu(e,{doc:r,blockClass:s,blockSelector:o,unblockSelector:i,inlineStylesheet:p,maskAttributeFn:c,maskInputOptions:h,maskInputFn:b,dataURLOptions:m,inlineImages:_,recordCanvas:w,keepIframeSrcFn:C,newlyAddedElement:O,rootId:I,maskAllText:a,maskTextClass:l,unmaskTextClass:u,maskTextSelector:d,unmaskTextSelector:f});case e.TEXT_NODE:return Ou(e,{maskAllText:a,maskTextClass:l,unmaskTextClass:u,maskTextSelector:d,unmaskTextSelector:f,maskTextFn:g,maskInputOptions:h,maskInputFn:b,rootId:I});case e.CDATA_SECTION_NODE:return{type:Z.CDATA,textContent:"",rootId:I};case e.COMMENT_NODE:return{type:Z.Comment,textContent:e.textContent||"",rootId:I};default:return!1}}function Au(e,t){if(!t.hasNode(e))return;let r=t.getId(e);return r===1?void 0:r}function Ou(e,t){let{maskAllText:r,maskTextClass:n,unmaskTextClass:s,maskTextSelector:o,unmaskTextSelector:i,maskTextFn:a,maskInputOptions:c,maskInputFn:l,rootId:u}=t,d=e.parentNode&&e.parentNode.tagName,f=e.textContent,p=d==="STYLE"?!0:void 0,h=d==="SCRIPT"?!0:void 0,g=d==="TEXTAREA"?!0:void 0;if(p&&f){try{e.nextSibling||e.previousSibling||ar([e,"access",m=>m.parentNode,"access",m=>m.sheet,"optionalAccess",m=>m.cssRules])&&(f=cr(e.parentNode.sheet))}catch(m){console.warn(`Cannot get CSS styles from text's parentNode. Error: ${m}`,e)}f=dr(f,Kn())}h&&(f="SCRIPT_PLACEHOLDER");let b=Ze(e,n,o,s,i,r);if(!p&&!h&&!g&&f&&b&&(f=a?a(f,e.parentElement):f.replace(/[\S]/g,"*")),g&&f&&(c.textarea||b)&&(f=l?l(f,e.parentNode):f.replace(/[\S]/g,"*")),d==="OPTION"&&f){let m=Er({type:null,tagName:d,maskInputOptions:c});f=bt({isMasked:Ze(e,n,o,s,i,m),element:e,value:f,maskInputFn:l})}return{type:Z.Text,textContent:f||"",isStyle:p,rootId:u}}function Lu(e,t){let{doc:r,blockClass:n,blockSelector:s,unblockSelector:o,inlineStylesheet:i,maskInputOptions:a={},maskAttributeFn:c,maskInputFn:l,dataURLOptions:u={},inlineImages:d,recordCanvas:f,keepIframeSrcFn:p,newlyAddedElement:h=!1,rootId:g,maskAllText:b,maskTextClass:m,unmaskTextClass:_,maskTextSelector:w,unmaskTextSelector:C}=t,O=Cu(e,n,s,o),I=gu(e),S={},R=e.attributes.length;for(let v=0;v<R;v++){let x=e.attributes[v];x.name&&!ei(I,x.name,x.value)&&(S[x.name]=Qo(r,I,Je(x.name),x.value,e,c))}if(I==="link"&&i){let v=Array.from(r.styleSheets).find(B=>B.href===e.href),x=null;v&&(x=cr(v)),x&&(delete S.rel,delete S.href,S._cssText=dr(x,v.href))}if(I==="style"&&e.sheet&&!(e.innerText||e.textContent||"").trim().length){let v=cr(e.sheet);v&&(S._cssText=dr(v,Kn()))}if(I==="input"||I==="textarea"||I==="select"||I==="option"){let v=e,x=Vn(v),B=ur(v,wn(I),x),Y=v.checked;if(x!=="submit"&&x!=="button"&&B){let J=Ze(v,m,w,_,C,Er({type:x,tagName:wn(I),maskInputOptions:a}));S.value=bt({isMasked:J,element:v,value:B,maskInputFn:l})}Y&&(S.checked=Y)}if(I==="option"&&(e.selected&&!a.select?S.selected=!0:delete S.selected),I==="canvas"&&f){if(e.__context==="2d")pu(e)||(S.rr_dataURL=e.toDataURL(u.type,u.quality));else if(!("__context"in e)){let v=e.toDataURL(u.type,u.quality),x=document.createElement("canvas");x.width=e.width,x.height=e.height;let B=x.toDataURL(u.type,u.quality);v!==B&&(S.rr_dataURL=v)}}if(I==="img"&&d){je||(je=r.createElement("canvas"),Lo=je.getContext("2d"));let v=e,x=v.crossOrigin;v.crossOrigin="anonymous";let B=()=>{v.removeEventListener("load",B);try{je.width=v.naturalWidth,je.height=v.naturalHeight,Lo.drawImage(v,0,0),S.rr_dataURL=je.toDataURL(u.type,u.quality)}catch(Y){console.warn(`Cannot inline img src=${v.currentSrc}! Error: ${Y}`)}x?S.crossOrigin=x:v.removeAttribute("crossorigin")};v.complete&&v.naturalWidth!==0?B():v.addEventListener("load",B)}if((I==="audio"||I==="video")&&(S.rr_mediaState=e.paused?"paused":"played",S.rr_mediaCurrentTime=e.currentTime),h||(e.scrollLeft&&(S.rr_scrollLeft=e.scrollLeft),e.scrollTop&&(S.rr_scrollTop=e.scrollTop)),O){let{width:v,height:x}=e.getBoundingClientRect();S={class:S.class,rr_width:`${v}px`,rr_height:`${x}px`}}I==="iframe"&&!p(S.src)&&(e.contentDocument||(S.rr_src=S.src),delete S.src);let $;try{customElements.get(I)&&($=!0)}catch{}return{type:Z.Element,tagName:I,attributes:S,childNodes:[],isSVG:ku(e)||void 0,needBlock:O,rootId:g,isCustom:$}}function W(e){return e==null?"":e.toLowerCase()}function Du(e,t){if(t.comment&&e.type===Z.Comment)return!0;if(e.type===Z.Element){if(t.script&&(e.tagName==="script"||e.tagName==="link"&&(e.attributes.rel==="preload"||e.attributes.rel==="modulepreload")&&e.attributes.as==="script"||e.tagName==="link"&&e.attributes.rel==="prefetch"&&typeof e.attributes.href=="string"&&e.attributes.href.endsWith(".js")))return!0;if(t.headFavicon&&(e.tagName==="link"&&e.attributes.rel==="shortcut icon"||e.tagName==="meta"&&(W(e.attributes.name).match(/^msapplication-tile(image|color)$/)||W(e.attributes.name)==="application-name"||W(e.attributes.rel)==="icon"||W(e.attributes.rel)==="apple-touch-icon"||W(e.attributes.rel)==="shortcut icon")))return!0;if(e.tagName==="meta"){if(t.headMetaDescKeywords&&W(e.attributes.name).match(/^description|keywords$/))return!0;if(t.headMetaSocial&&(W(e.attributes.property).match(/^(og|twitter|fb):/)||W(e.attributes.name).match(/^(og|twitter):/)||W(e.attributes.name)==="pinterest"))return!0;if(t.headMetaRobots&&(W(e.attributes.name)==="robots"||W(e.attributes.name)==="googlebot"||W(e.attributes.name)==="bingbot"))return!0;if(t.headMetaHttpEquiv&&e.attributes["http-equiv"]!==void 0)return!0;if(t.headMetaAuthorship&&(W(e.attributes.name)==="author"||W(e.attributes.name)==="generator"||W(e.attributes.name)==="framework"||W(e.attributes.name)==="publisher"||W(e.attributes.name)==="progid"||W(e.attributes.property).match(/^article:/)||W(e.attributes.property).match(/^product:/)))return!0;if(t.headMetaVerification&&(W(e.attributes.name)==="google-site-verification"||W(e.attributes.name)==="yandex-verification"||W(e.attributes.name)==="csrf-token"||W(e.attributes.name)==="p:domain_verify"||W(e.attributes.name)==="verify-v1"||W(e.attributes.name)==="verification"||W(e.attributes.name)==="shopify-checkout-api-token"))return!0}}return!1}function Ye(e,t){let{doc:r,mirror:n,blockClass:s,blockSelector:o,unblockSelector:i,maskAllText:a,maskTextClass:c,unmaskTextClass:l,maskTextSelector:u,unmaskTextSelector:d,skipChild:f=!1,inlineStylesheet:p=!0,maskInputOptions:h={},maskAttributeFn:g,maskTextFn:b,maskInputFn:m,slimDOMOptions:_,dataURLOptions:w={},inlineImages:C=!1,recordCanvas:O=!1,onSerialize:I,onIframeLoad:S,iframeLoadTimeout:R=5e3,onStylesheetLoad:$,stylesheetLoadTimeout:v=5e3,keepIframeSrcFn:x=()=>!1,newlyAddedElement:B=!1}=t,{preserveWhiteSpace:Y=!0}=t,J=Mu(e,{doc:r,mirror:n,blockClass:s,blockSelector:o,maskAllText:a,unblockSelector:i,maskTextClass:c,unmaskTextClass:l,maskTextSelector:u,unmaskTextSelector:d,inlineStylesheet:p,maskInputOptions:h,maskAttributeFn:g,maskTextFn:b,maskInputFn:m,dataURLOptions:w,inlineImages:C,recordCanvas:O,keepIframeSrcFn:x,newlyAddedElement:B});if(!J)return console.warn(e,"not serialized"),null;let se;n.hasNode(e)?se=n.getId(e):Du(J,_)||!Y&&J.type===Z.Text&&!J.isStyle&&!J.textContent.replace(/^\s+|\s+$/gm,"").length?se=vt:se=Yn();let H=Object.assign(J,{id:se});if(n.add(e,H),se===vt)return null;I&&I(e);let ie=!f;if(H.type===Z.Element){ie=ie&&!H.needBlock,delete H.needBlock;let X=e.shadowRoot;X&&_t(X)&&(H.isShadowHost=!0)}if((H.type===Z.Document||H.type===Z.Element)&&ie){_.headWhitespace&&H.type===Z.Element&&H.tagName==="head"&&(Y=!1);let X={doc:r,mirror:n,blockClass:s,blockSelector:o,maskAllText:a,unblockSelector:i,maskTextClass:c,unmaskTextClass:l,maskTextSelector:u,unmaskTextSelector:d,skipChild:f,inlineStylesheet:p,maskInputOptions:h,maskAttributeFn:g,maskTextFn:b,maskInputFn:m,slimDOMOptions:_,dataURLOptions:w,inlineImages:C,recordCanvas:O,preserveWhiteSpace:Y,onSerialize:I,onIframeLoad:S,iframeLoadTimeout:R,onStylesheetLoad:$,stylesheetLoadTimeout:v,keepIframeSrcFn:x};for(let ne of Array.from(e.childNodes)){let ae=Ye(ne,X);ae&&H.childNodes.push(ae)}if(iu(e)&&e.shadowRoot)for(let ne of Array.from(e.shadowRoot.childNodes)){let ae=Ye(ne,X);ae&&(_t(e.shadowRoot)&&(ae.isShadow=!0),H.childNodes.push(ae))}}return e.parentNode&&yt(e.parentNode)&&_t(e.parentNode)&&(H.isShadow=!0),H.type===Z.Element&&H.tagName==="iframe"&&Tu(e,()=>{let X=e.contentDocument;if(X&&S){let ne=Ye(X,{doc:X,mirror:n,blockClass:s,blockSelector:o,unblockSelector:i,maskAllText:a,maskTextClass:c,unmaskTextClass:l,maskTextSelector:u,unmaskTextSelector:d,skipChild:!1,inlineStylesheet:p,maskInputOptions:h,maskAttributeFn:g,maskTextFn:b,maskInputFn:m,slimDOMOptions:_,dataURLOptions:w,inlineImages:C,recordCanvas:O,preserveWhiteSpace:Y,onSerialize:I,onIframeLoad:S,iframeLoadTimeout:R,onStylesheetLoad:$,stylesheetLoadTimeout:v,keepIframeSrcFn:x});ne&&S(e,ne)}},R),H.type===Z.Element&&H.tagName==="link"&&H.attributes.rel==="stylesheet"&&Ru(e,()=>{if($){let X=Ye(e,{doc:r,mirror:n,blockClass:s,blockSelector:o,unblockSelector:i,maskAllText:a,maskTextClass:c,unmaskTextClass:l,maskTextSelector:u,unmaskTextSelector:d,skipChild:!1,inlineStylesheet:p,maskInputOptions:h,maskAttributeFn:g,maskTextFn:b,maskInputFn:m,slimDOMOptions:_,dataURLOptions:w,inlineImages:C,recordCanvas:O,preserveWhiteSpace:Y,onSerialize:I,onIframeLoad:S,iframeLoadTimeout:R,onStylesheetLoad:$,stylesheetLoadTimeout:v,keepIframeSrcFn:x});X&&$(e,X)}},v),H}function Nu(e,t){let{mirror:r=new lr,blockClass:n="rr-block",blockSelector:s=null,unblockSelector:o=null,maskAllText:i=!1,maskTextClass:a="rr-mask",unmaskTextClass:c=null,maskTextSelector:l=null,unmaskTextSelector:u=null,inlineStylesheet:d=!0,inlineImages:f=!1,recordCanvas:p=!1,maskAllInputs:h=!1,maskAttributeFn:g,maskTextFn:b,maskInputFn:m,slimDOM:_=!1,dataURLOptions:w,preserveWhiteSpace:C,onSerialize:O,onIframeLoad:I,iframeLoadTimeout:S,onStylesheetLoad:R,stylesheetLoadTimeout:$,keepIframeSrcFn:v=()=>!1}=t||{};return Ye(e,{doc:e,mirror:r,blockClass:n,blockSelector:s,unblockSelector:o,maskAllText:i,maskTextClass:a,unmaskTextClass:c,maskTextSelector:l,unmaskTextSelector:u,skipChild:!1,inlineStylesheet:d,maskInputOptions:h===!0?{color:!0,date:!0,"datetime-local":!0,email:!0,month:!0,number:!0,range:!0,search:!0,tel:!0,text:!0,time:!0,url:!0,week:!0,textarea:!0,select:!0}:h===!1?{}:h,maskAttributeFn:g,maskTextFn:b,maskInputFn:m,slimDOMOptions:_===!0||_==="all"?{script:!0,comment:!0,headFavicon:!0,headWhitespace:!0,headMetaDescKeywords:_==="all",headMetaSocial:!0,headMetaRobots:!0,headMetaHttpEquiv:!0,headMetaAuthorship:!0,headMetaVerification:!0}:_===!1?{}:_,dataURLOptions:w,inlineImages:f,recordCanvas:p,preserveWhiteSpace:C,onSerialize:O,onIframeLoad:I,iframeLoadTimeout:S,onStylesheetLoad:R,stylesheetLoadTimeout:$,keepIframeSrcFn:v,newlyAddedElement:!1})}function ve(e){let t,r=e[0],n=1;for(;n<e.length;){let s=e[n],o=e[n+1];if(n+=2,(s==="optionalAccess"||s==="optionalCall")&&r==null)return;s==="access"||s==="optionalAccess"?(t=r,r=o(r)):(s==="call"||s==="optionalCall")&&(r=o((...i)=>r.call(t,...i)),t=void 0)}return r}function re(e,t,r=document){let n={capture:!0,passive:!0};return r.addEventListener(e,t,n),()=>r.removeEventListener(e,t,n)}var Ge=`Please stop import mirror directly. Instead of that,\r
4
4
  now you can use replayer.getMirror() to access the mirror instance of a replayer,\r
5
5
  or you can use record.mirror to access the mirror instance during recording.`,Do={map:{},getId(){return console.error(Ge),-1},getNode(){return console.error(Ge),null},removeNodeFromMap(){console.error(Ge)},has(){return console.error(Ge),!1},reset(){console.error(Ge)}};typeof window<"u"&&window.Proxy&&window.Reflect&&(Do=new Proxy(Do,{get(e,t,r){return t==="map"&&console.error(Ge),Reflect.get(e,t,r)}}));function Et(e,t,r={}){let n=null,s=0;return function(...o){let i=Date.now();!s&&r.leading===!1&&(s=i);let a=t-(i-s),c=this;a<=0||a>t?(n&&(Wu(n),n=null),s=i,e.apply(c,o)):!n&&r.trailing!==!1&&(n=wr(()=>{s=r.leading===!1?0:Date.now(),n=null,e.apply(c,o)},a))}}function ti(e,t,r,n,s=window){let o=s.Object.getOwnPropertyDescriptor(e,t);return s.Object.defineProperty(e,t,n?r:{set(i){wr(()=>{r.set.call(this,i)},0),o&&o.set&&o.set.call(this,i)}}),()=>ti(e,t,o||{},!0)}function Xn(e,t,r){try{if(!(t in e))return()=>{};let n=e[t],s=r(n);return typeof s=="function"&&(s.prototype=s.prototype||{},Object.defineProperties(s,{__rrweb_original__:{enumerable:!1,value:n}})),e[t]=s,()=>{e[t]=n}}catch{return()=>{}}}var fr=Date.now;/[1-9][0-9]{12}/.test(Date.now().toString())||(fr=()=>new Date().getTime());function ri(e){let t=e.document;return{left:t.scrollingElement?t.scrollingElement.scrollLeft:e.pageXOffset!==void 0?e.pageXOffset:ve([t,"optionalAccess",r=>r.documentElement,"access",r=>r.scrollLeft])||ve([t,"optionalAccess",r=>r.body,"optionalAccess",r=>r.parentElement,"optionalAccess",r=>r.scrollLeft])||ve([t,"optionalAccess",r=>r.body,"optionalAccess",r=>r.scrollLeft])||0,top:t.scrollingElement?t.scrollingElement.scrollTop:e.pageYOffset!==void 0?e.pageYOffset:ve([t,"optionalAccess",r=>r.documentElement,"access",r=>r.scrollTop])||ve([t,"optionalAccess",r=>r.body,"optionalAccess",r=>r.parentElement,"optionalAccess",r=>r.scrollTop])||ve([t,"optionalAccess",r=>r.body,"optionalAccess",r=>r.scrollTop])||0}}function ni(){return window.innerHeight||document.documentElement&&document.documentElement.clientHeight||document.body&&document.body.clientHeight}function si(){return window.innerWidth||document.documentElement&&document.documentElement.clientWidth||document.body&&document.body.clientWidth}function oi(e){return e?e.nodeType===e.ELEMENT_NODE?e:e.parentElement:null}function de(e,t,r,n,s){if(!e)return!1;let o=oi(e);if(!o)return!1;let i=Ve(t,r);if(!s){let l=n&&o.matches(n);return i(o)&&!l}let a=Ae(o,i),c=-1;return a<0?!1:(n&&(c=Ae(o,Ve(null,n))),a>-1&&c<0?!0:a<c)}function Pu(e,t){return t.getId(e)!==-1}function bn(e,t){return t.getId(e)===vt}function ii(e,t){if(yt(e))return!1;let r=t.getId(e);return t.has(r)?e.parentNode&&e.parentNode.nodeType===e.DOCUMENT_NODE?!1:e.parentNode?ii(e.parentNode,t):!0:!0}function In(e){return!!e.changedTouches}function Fu(e=window){"NodeList"in e&&!e.NodeList.prototype.forEach&&(e.NodeList.prototype.forEach=Array.prototype.forEach),"DOMTokenList"in e&&!e.DOMTokenList.prototype.forEach&&(e.DOMTokenList.prototype.forEach=Array.prototype.forEach),Node.prototype.contains||(Node.prototype.contains=(...t)=>{let r=t[0];if(!(0 in t))throw new TypeError("1 argument is required");do if(this===r)return!0;while(r=r&&r.parentNode);return!1})}function ai(e,t){return!!(e.nodeName==="IFRAME"&&t.getMeta(e))}function ci(e,t){return!!(e.nodeName==="LINK"&&e.nodeType===e.ELEMENT_NODE&&e.getAttribute&&e.getAttribute("rel")==="stylesheet"&&t.getMeta(e))}function kn(e){return!!ve([e,"optionalAccess",t=>t.shadowRoot])}var Cn=class{constructor(){this.id=1,this.styleIDMap=new WeakMap,this.idStyleMap=new Map}getId(t){return Vs(this.styleIDMap.get(t),()=>-1)}has(t){return this.styleIDMap.has(t)}add(t,r){if(this.has(t))return this.getId(t);let n;return r===void 0?n=this.id++:n=r,this.styleIDMap.set(t,n),this.idStyleMap.set(n,t),n}getStyle(t){return this.idStyleMap.get(t)||null}reset(){this.styleIDMap=new WeakMap,this.idStyleMap=new Map,this.id=1}generateId(){return this.id++}};function li(e){let t=null;return ve([e,"access",r=>r.getRootNode,"optionalCall",r=>r(),"optionalAccess",r=>r.nodeType])===Node.DOCUMENT_FRAGMENT_NODE&&e.getRootNode().host&&(t=e.getRootNode().host),t}function Bu(e){let t=e,r;for(;r=li(t);)t=r;return t}function Hu(e){let t=e.ownerDocument;if(!t)return!1;let r=Bu(e);return t.contains(r)}function ui(e){let t=e.ownerDocument;return t?t.contains(e)||Hu(e):!1}var No={};function Jn(e){let t=No[e];if(t)return t;let r=window.document,n=window[e];if(r&&typeof r.createElement=="function")try{let s=r.createElement("iframe");s.hidden=!0,r.head.appendChild(s);let o=s.contentWindow;o&&o[e]&&(n=o[e]),r.head.removeChild(s)}catch{}return No[e]=n.bind(window)}function Uu(...e){return Jn("requestAnimationFrame")(...e)}function wr(...e){return Jn("setTimeout")(...e)}function Wu(...e){return Jn("clearTimeout")(...e)}var M=(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))(M||{}),A=(e=>(e[e.Mutation=0]="Mutation",e[e.MouseMove=1]="MouseMove",e[e.MouseInteraction=2]="MouseInteraction",e[e.Scroll=3]="Scroll",e[e.ViewportResize=4]="ViewportResize",e[e.Input=5]="Input",e[e.TouchMove=6]="TouchMove",e[e.MediaInteraction=7]="MediaInteraction",e[e.StyleSheetRule=8]="StyleSheetRule",e[e.CanvasMutation=9]="CanvasMutation",e[e.Font=10]="Font",e[e.Log=11]="Log",e[e.Drag=12]="Drag",e[e.StyleDeclaration=13]="StyleDeclaration",e[e.Selection=14]="Selection",e[e.AdoptedStyleSheet=15]="AdoptedStyleSheet",e[e.CustomElement=16]="CustomElement",e))(A||{}),ee=(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))(ee||{}),ye=(e=>(e[e.Mouse=0]="Mouse",e[e.Pen=1]="Pen",e[e.Touch=2]="Touch",e))(ye||{});function zu(e){let t,r=e[0],n=1;for(;n<e.length;){let s=e[n],o=e[n+1];if(n+=2,(s==="optionalAccess"||s==="optionalCall")&&r==null)return;s==="access"||s==="optionalAccess"?(t=r,r=o(r)):(s==="call"||s==="optionalCall")&&(r=o((...i)=>r.call(t,...i)),t=void 0)}return r}function Po(e){return"__ln"in e}var xn=class{constructor(){this.length=0,this.head=null,this.tail=null}get(t){if(t>=this.length)throw new Error("Position outside of list range");let r=this.head;for(let n=0;n<t;n++)r=zu([r,"optionalAccess",s=>s.next])||null;return r}addNode(t){let r={value:t,previous:null,next:null};if(t.__ln=r,t.previousSibling&&Po(t.previousSibling)){let n=t.previousSibling.__ln.next;r.next=n,r.previous=t.previousSibling.__ln,t.previousSibling.__ln.next=r,n&&(n.previous=r)}else if(t.nextSibling&&Po(t.nextSibling)&&t.nextSibling.__ln.previous){let n=t.nextSibling.__ln.previous;r.previous=n,r.next=t.nextSibling.__ln,t.nextSibling.__ln.previous=r,n&&(n.next=r)}else this.head&&(this.head.previous=r),r.next=this.head,this.head=r;r.next===null&&(this.tail=r),this.length++}removeNode(t){let r=t.__ln;this.head&&(r.previous?(r.previous.next=r.next,r.next?r.next.previous=r.previous:this.tail=r.previous):(this.head=r.next,this.head?this.head.previous=null:this.tail=null),t.__ln&&delete t.__ln,this.length--)}},Fo=(e,t)=>`${e}@${t}`,Tn=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=t=>{t.forEach(this.processMutation),this.emit()},this.emit=()=>{if(this.frozen||this.locked)return;let t=[],r=new Set,n=new xn,s=c=>{let l=c,u=vt;for(;u===vt;)l=l&&l.nextSibling,u=l&&this.mirror.getId(l);return u},o=c=>{if(!c.parentNode||!ui(c))return;let l=yt(c.parentNode)?this.mirror.getId(li(c)):this.mirror.getId(c.parentNode),u=s(c);if(l===-1||u===-1)return n.addNode(c);let d=Ye(c,{doc:this.doc,mirror:this.mirror,blockClass:this.blockClass,blockSelector:this.blockSelector,maskAllText:this.maskAllText,unblockSelector:this.unblockSelector,maskTextClass:this.maskTextClass,unmaskTextClass:this.unmaskTextClass,maskTextSelector:this.maskTextSelector,unmaskTextSelector:this.unmaskTextSelector,skipChild:!0,newlyAddedElement:!0,inlineStylesheet:this.inlineStylesheet,maskInputOptions:this.maskInputOptions,maskAttributeFn:this.maskAttributeFn,maskTextFn:this.maskTextFn,maskInputFn:this.maskInputFn,slimDOMOptions:this.slimDOMOptions,dataURLOptions:this.dataURLOptions,recordCanvas:this.recordCanvas,inlineImages:this.inlineImages,onSerialize:f=>{ai(f,this.mirror)&&this.iframeManager.addIframe(f),ci(f,this.mirror)&&this.stylesheetManager.trackLinkElement(f),kn(c)&&this.shadowDomManager.addShadowRoot(c.shadowRoot,this.doc)},onIframeLoad:(f,p)=>{this.iframeManager.attachIframe(f,p),this.shadowDomManager.observeAttachShadow(f)},onStylesheetLoad:(f,p)=>{this.stylesheetManager.attachLinkElement(f,p)}});d&&(t.push({parentId:l,nextId:u,node:d}),r.add(d.id))};for(;this.mapRemoves.length;)this.mirror.removeNodeFromMap(this.mapRemoves.shift());for(let c of this.movedSet)Bo(this.removes,c,this.mirror)&&!this.movedSet.has(c.parentNode)||o(c);for(let c of this.addedSet)!Ho(this.droppedSet,c)&&!Bo(this.removes,c,this.mirror)||Ho(this.movedSet,c)?o(c):this.droppedSet.add(c);let i=null;for(;n.length;){let c=null;if(i){let l=this.mirror.getId(i.value.parentNode),u=s(i.value);l!==-1&&u!==-1&&(c=i)}if(!c){let l=n.tail;for(;l;){let u=l;if(l=l.previous,u){let d=this.mirror.getId(u.value.parentNode);if(s(u.value)===-1)continue;if(d!==-1){c=u;break}else{let p=u.value;if(p.parentNode&&p.parentNode.nodeType===Node.DOCUMENT_FRAGMENT_NODE){let h=p.parentNode.host;if(this.mirror.getId(h)!==-1){c=u;break}}}}}}if(!c){for(;n.head;)n.removeNode(n.head.value);break}i=c.previous,n.removeNode(c.value),o(c.value)}let a={texts:this.texts.map(c=>({id:this.mirror.getId(c.node),value:c.value})).filter(c=>!r.has(c.id)).filter(c=>this.mirror.has(c.id)),attributes:this.attributes.map(c=>{let{attributes:l}=c;if(typeof l.style=="string"){let u=JSON.stringify(c.styleDiff),d=JSON.stringify(c._unchangedStyles);u.length<l.style.length&&(u+d).split("var(").length===l.style.split("var(").length&&(l.style=c.styleDiff)}return{id:this.mirror.getId(c.node),attributes:l}}).filter(c=>!r.has(c.id)).filter(c=>this.mirror.has(c.id)),removes:this.removes,adds:t};!a.texts.length&&!a.attributes.length&&!a.removes.length&&!a.adds.length||(this.texts=[],this.attributes=[],this.attributeMap=new WeakMap,this.removes=[],this.addedSet=new Set,this.movedSet=new Set,this.droppedSet=new Set,this.movedMap={},this.mutationCb(a))},this.processMutation=t=>{if(!bn(t.target,this.mirror))switch(t.type){case"characterData":{let r=t.target.textContent;!de(t.target,this.blockClass,this.blockSelector,this.unblockSelector,!1)&&r!==t.oldValue&&this.texts.push({value:Ze(t.target,this.maskTextClass,this.maskTextSelector,this.unmaskTextClass,this.unmaskTextSelector,this.maskAllText)&&r?this.maskTextFn?this.maskTextFn(r,oi(t.target)):r.replace(/[\S]/g,"*"):r,node:t.target});break}case"attributes":{let r=t.target,n=t.attributeName,s=t.target.getAttribute(n);if(n==="value"){let i=Vn(r),a=r.tagName;s=ur(r,a,i);let c=Er({maskInputOptions:this.maskInputOptions,tagName:a,type:i}),l=Ze(t.target,this.maskTextClass,this.maskTextSelector,this.unmaskTextClass,this.unmaskTextSelector,c);s=bt({isMasked:l,element:r,value:s,maskInputFn:this.maskInputFn})}if(de(t.target,this.blockClass,this.blockSelector,this.unblockSelector,!1)||s===t.oldValue)return;let o=this.attributeMap.get(t.target);if(r.tagName==="IFRAME"&&n==="src"&&!this.keepIframeSrcFn(s))if(!r.contentDocument)n="rr_src";else return;if(o||(o={node:t.target,attributes:{},styleDiff:{},_unchangedStyles:{}},this.attributes.push(o),this.attributeMap.set(t.target,o)),n==="type"&&r.tagName==="INPUT"&&(t.oldValue||"").toLowerCase()==="password"&&r.setAttribute("data-rr-is-password","true"),!ei(r.tagName,n)&&(o.attributes[n]=Qo(this.doc,Je(r.tagName),Je(n),s,r,this.maskAttributeFn),n==="style")){if(!this.unattachedDoc)try{this.unattachedDoc=document.implementation.createHTMLDocument()}catch{this.unattachedDoc=this.doc}let i=this.unattachedDoc.createElement("span");t.oldValue&&i.setAttribute("style",t.oldValue);for(let a of Array.from(r.style)){let c=r.style.getPropertyValue(a),l=r.style.getPropertyPriority(a);c!==i.style.getPropertyValue(a)||l!==i.style.getPropertyPriority(a)?l===""?o.styleDiff[a]=c:o.styleDiff[a]=[c,l]:o._unchangedStyles[a]=[c,l]}for(let a of Array.from(i.style))r.style.getPropertyValue(a)===""&&(o.styleDiff[a]=!1)}break}case"childList":{if(de(t.target,this.blockClass,this.blockSelector,this.unblockSelector,!0))return;t.addedNodes.forEach(r=>this.genAdds(r,t.target)),t.removedNodes.forEach(r=>{let n=this.mirror.getId(r),s=yt(t.target)?this.mirror.getId(t.target.host):this.mirror.getId(t.target);de(t.target,this.blockClass,this.blockSelector,this.unblockSelector,!1)||bn(r,this.mirror)||!Pu(r,this.mirror)||(this.addedSet.has(r)?(Rn(this.addedSet,r),this.droppedSet.add(r)):this.addedSet.has(t.target)&&n===-1||ii(t.target,this.mirror)||(this.movedSet.has(r)&&this.movedMap[Fo(n,s)]?Rn(this.movedSet,r):this.removes.push({parentId:s,id:n,isShadow:yt(t.target)&&_t(t.target)?!0:void 0})),this.mapRemoves.push(r))});break}}},this.genAdds=(t,r)=>{if(!this.processedNodeManager.inOtherBuffer(t,this)&&!(this.addedSet.has(t)||this.movedSet.has(t))){if(this.mirror.hasNode(t)){if(bn(t,this.mirror))return;this.movedSet.add(t);let n=null;r&&this.mirror.hasNode(r)&&(n=this.mirror.getId(r)),n&&n!==-1&&(this.movedMap[Fo(this.mirror.getId(t),n)]=!0)}else this.addedSet.add(t),this.droppedSet.delete(t);de(t,this.blockClass,this.blockSelector,this.unblockSelector,!1)||(t.childNodes.forEach(n=>this.genAdds(n)),kn(t)&&t.shadowRoot.childNodes.forEach(n=>{this.processedNodeManager.add(n,this),this.genAdds(n,t)}))}}}init(t){["mutationCb","blockClass","blockSelector","unblockSelector","maskAllText","maskTextClass","unmaskTextClass","maskTextSelector","unmaskTextSelector","inlineStylesheet","maskInputOptions","maskAttributeFn","maskTextFn","maskInputFn","keepIframeSrcFn","recordCanvas","inlineImages","slimDOMOptions","dataURLOptions","doc","mirror","iframeManager","stylesheetManager","shadowDomManager","canvasManager","processedNodeManager"].forEach(r=>{this[r]=t[r]})}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 Rn(e,t){e.delete(t),t.childNodes.forEach(r=>Rn(e,r))}function Bo(e,t,r){return e.length===0?!1:di(e,t,r)}function di(e,t,r){let{parentNode:n}=t;if(!n)return!1;let s=r.getId(n);return e.some(o=>o.id===s)?!0:di(e,n,r)}function Ho(e,t){return e.size===0?!1:fi(e,t)}function fi(e,t){let{parentNode:r}=t;return r?e.has(r)?!0:fi(e,r):!1}var St;function $u(e){St=e}function ju(){St=void 0}var L=e=>St?(...r)=>{try{return e(...r)}catch(n){if(St&&St(n)===!0)return()=>{};throw n}}:e;function pe(e){let t,r=e[0],n=1;for(;n<e.length;){let s=e[n],o=e[n+1];if(n+=2,(s==="optionalAccess"||s==="optionalCall")&&r==null)return;s==="access"||s==="optionalAccess"?(t=r,r=o(r)):(s==="call"||s==="optionalCall")&&(r=o((...i)=>r.call(t,...i)),t=void 0)}return r}var Ke=[];function xt(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 pi(e,t){let r=new Tn;Ke.push(r),r.init(e);let n=window.MutationObserver||window.__rrMutationObserver,s=pe([window,"optionalAccess",i=>i.Zone,"optionalAccess",i=>i.__symbol__,"optionalCall",i=>i("MutationObserver")]);s&&window[s]&&(n=window[s]);let o=new n(L(i=>{e.onMutation&&e.onMutation(i)===!1||r.processMutations.bind(r)(i)}));return o.observe(t,{attributes:!0,attributeOldValue:!0,characterData:!0,characterDataOldValue:!0,childList:!0,subtree:!0}),o}function Gu({mousemoveCb:e,sampling:t,doc:r,mirror:n}){if(t.mousemove===!1)return()=>{};let s=typeof t.mousemove=="number"?t.mousemove:50,o=typeof t.mousemoveCallback=="number"?t.mousemoveCallback:500,i=[],a,c=Et(L(d=>{let f=Date.now()-a;e(i.map(p=>(p.timeOffset-=f,p)),d),i=[],a=null}),o),l=L(Et(L(d=>{let f=xt(d),{clientX:p,clientY:h}=In(d)?d.changedTouches[0]:d;a||(a=fr()),i.push({x:p,y:h,id:n.getId(f),timeOffset:fr()-a}),c(typeof DragEvent<"u"&&d instanceof DragEvent?A.Drag:d instanceof MouseEvent?A.MouseMove:A.TouchMove)}),s,{trailing:!1})),u=[re("mousemove",l,r),re("touchmove",l,r),re("drag",l,r)];return L(()=>{u.forEach(d=>d())})}function qu({mouseInteractionCb:e,doc:t,mirror:r,blockClass:n,blockSelector:s,unblockSelector:o,sampling:i}){if(i.mouseInteraction===!1)return()=>{};let a=i.mouseInteraction===!0||i.mouseInteraction===void 0?{}:i.mouseInteraction,c=[],l=null,u=d=>f=>{let p=xt(f);if(de(p,n,s,o,!0))return;let h=null,g=d;if("pointerType"in f){switch(f.pointerType){case"mouse":h=ye.Mouse;break;case"touch":h=ye.Touch;break;case"pen":h=ye.Pen;break}h===ye.Touch?ee[d]===ee.MouseDown?g="TouchStart":ee[d]===ee.MouseUp&&(g="TouchEnd"):ye.Pen}else In(f)&&(h=ye.Touch);h!==null?(l=h,(g.startsWith("Touch")&&h===ye.Touch||g.startsWith("Mouse")&&h===ye.Mouse)&&(h=null)):ee[d]===ee.Click&&(h=l,l=null);let b=In(f)?f.changedTouches[0]:f;if(!b)return;let m=r.getId(p),{clientX:_,clientY:w}=b;L(e)({type:ee[g],id:m,x:_,y:w,...h!==null&&{pointerType:h}})};return Object.keys(ee).filter(d=>Number.isNaN(Number(d))&&!d.endsWith("_Departed")&&a[d]!==!1).forEach(d=>{let f=Je(d),p=u(d);if(window.PointerEvent)switch(ee[d]){case ee.MouseDown:case ee.MouseUp:f=f.replace("mouse","pointer");break;case ee.TouchStart:case ee.TouchEnd:return}c.push(re(f,p,t))}),L(()=>{c.forEach(d=>d())})}function hi({scrollCb:e,doc:t,mirror:r,blockClass:n,blockSelector:s,unblockSelector:o,sampling:i}){let a=L(Et(L(c=>{let l=xt(c);if(!l||de(l,n,s,o,!0))return;let u=r.getId(l);if(l===t&&t.defaultView){let d=ri(t.defaultView);e({id:u,x:d.left,y:d.top})}else e({id:u,x:l.scrollLeft,y:l.scrollTop})}),i.scroll||100));return re("scroll",a,t)}function Vu({viewportResizeCb:e},{win:t}){let r=-1,n=-1,s=L(Et(L(()=>{let o=ni(),i=si();(r!==o||n!==i)&&(e({width:Number(i),height:Number(o)}),r=o,n=i)}),200));return re("resize",s,t)}var Yu=["INPUT","TEXTAREA","SELECT"],Uo=new WeakMap;function Ku({inputCb:e,doc:t,mirror:r,blockClass:n,blockSelector:s,unblockSelector:o,ignoreClass:i,ignoreSelector:a,maskInputOptions:c,maskInputFn:l,sampling:u,userTriggeredOnInput:d,maskTextClass:f,unmaskTextClass:p,maskTextSelector:h,unmaskTextSelector:g}){function b(S){let R=xt(S),$=S.isTrusted,v=R&&wn(R.tagName);if(v==="OPTION"&&(R=R.parentElement),!R||!v||Yu.indexOf(v)<0||de(R,n,s,o,!0))return;let x=R;if(x.classList.contains(i)||a&&x.matches(a))return;let B=Vn(R),Y=ur(x,v,B),J=!1,se=Er({maskInputOptions:c,tagName:v,type:B}),H=Ze(R,f,h,p,g,se);(B==="radio"||B==="checkbox")&&(J=R.checked),Y=bt({isMasked:H,element:R,value:Y,maskInputFn:l}),m(R,d?{text:Y,isChecked:J,userTriggered:$}:{text:Y,isChecked:J});let ie=R.name;B==="radio"&&ie&&J&&t.querySelectorAll(`input[type="radio"][name="${ie}"]`).forEach(X=>{if(X!==R){let ne=bt({isMasked:H,element:X,value:ur(X,v,B),maskInputFn:l});m(X,d?{text:ne,isChecked:!J,userTriggered:!1}:{text:ne,isChecked:!J})}})}function m(S,R){let $=Uo.get(S);if(!$||$.text!==R.text||$.isChecked!==R.isChecked){Uo.set(S,R);let v=r.getId(S);L(e)({...R,id:v})}}let w=(u.input==="last"?["change"]:["input","change"]).map(S=>re(S,L(b),t)),C=t.defaultView;if(!C)return()=>{w.forEach(S=>S())};let O=C.Object.getOwnPropertyDescriptor(C.HTMLInputElement.prototype,"value"),I=[[C.HTMLInputElement.prototype,"value"],[C.HTMLInputElement.prototype,"checked"],[C.HTMLSelectElement.prototype,"value"],[C.HTMLTextAreaElement.prototype,"value"],[C.HTMLSelectElement.prototype,"selectedIndex"],[C.HTMLOptionElement.prototype,"selected"]];return O&&O.set&&w.push(...I.map(S=>ti(S[0],S[1],{set(){L(b)({target:this,isTrusted:!1})}},!1,C))),L(()=>{w.forEach(S=>S())})}function pr(e){let t=[];function r(n,s){if(or("CSSGroupingRule")&&n.parentRule instanceof CSSGroupingRule||or("CSSMediaRule")&&n.parentRule instanceof CSSMediaRule||or("CSSSupportsRule")&&n.parentRule instanceof CSSSupportsRule||or("CSSConditionRule")&&n.parentRule instanceof CSSConditionRule){let i=Array.from(n.parentRule.cssRules).indexOf(n);s.unshift(i)}else if(n.parentStyleSheet){let i=Array.from(n.parentStyleSheet.cssRules).indexOf(n);s.unshift(i)}return s}return r(e,t)}function Ee(e,t,r){let n,s;return e?(e.ownerNode?n=t.getId(e.ownerNode):s=r.getId(e),{styleId:s,id:n}):{}}function Xu({styleSheetRuleCb:e,mirror:t,stylesheetManager:r},{win:n}){if(!n.CSSStyleSheet||!n.CSSStyleSheet.prototype)return()=>{};let s=n.CSSStyleSheet.prototype.insertRule;n.CSSStyleSheet.prototype.insertRule=new Proxy(s,{apply:L((u,d,f)=>{let[p,h]=f,{id:g,styleId:b}=Ee(d,t,r.styleMirror);return(g&&g!==-1||b&&b!==-1)&&e({id:g,styleId:b,adds:[{rule:p,index:h}]}),u.apply(d,f)})});let o=n.CSSStyleSheet.prototype.deleteRule;n.CSSStyleSheet.prototype.deleteRule=new Proxy(o,{apply:L((u,d,f)=>{let[p]=f,{id:h,styleId:g}=Ee(d,t,r.styleMirror);return(h&&h!==-1||g&&g!==-1)&&e({id:h,styleId:g,removes:[{index:p}]}),u.apply(d,f)})});let i;n.CSSStyleSheet.prototype.replace&&(i=n.CSSStyleSheet.prototype.replace,n.CSSStyleSheet.prototype.replace=new Proxy(i,{apply:L((u,d,f)=>{let[p]=f,{id:h,styleId:g}=Ee(d,t,r.styleMirror);return(h&&h!==-1||g&&g!==-1)&&e({id:h,styleId:g,replace:p}),u.apply(d,f)})}));let a;n.CSSStyleSheet.prototype.replaceSync&&(a=n.CSSStyleSheet.prototype.replaceSync,n.CSSStyleSheet.prototype.replaceSync=new Proxy(a,{apply:L((u,d,f)=>{let[p]=f,{id:h,styleId:g}=Ee(d,t,r.styleMirror);return(h&&h!==-1||g&&g!==-1)&&e({id:h,styleId:g,replaceSync:p}),u.apply(d,f)})}));let c={};ir("CSSGroupingRule")?c.CSSGroupingRule=n.CSSGroupingRule:(ir("CSSMediaRule")&&(c.CSSMediaRule=n.CSSMediaRule),ir("CSSConditionRule")&&(c.CSSConditionRule=n.CSSConditionRule),ir("CSSSupportsRule")&&(c.CSSSupportsRule=n.CSSSupportsRule));let l={};return Object.entries(c).forEach(([u,d])=>{l[u]={insertRule:d.prototype.insertRule,deleteRule:d.prototype.deleteRule},d.prototype.insertRule=new Proxy(l[u].insertRule,{apply:L((f,p,h)=>{let[g,b]=h,{id:m,styleId:_}=Ee(p.parentStyleSheet,t,r.styleMirror);return(m&&m!==-1||_&&_!==-1)&&e({id:m,styleId:_,adds:[{rule:g,index:[...pr(p),b||0]}]}),f.apply(p,h)})}),d.prototype.deleteRule=new Proxy(l[u].deleteRule,{apply:L((f,p,h)=>{let[g]=h,{id:b,styleId:m}=Ee(p.parentStyleSheet,t,r.styleMirror);return(b&&b!==-1||m&&m!==-1)&&e({id:b,styleId:m,removes:[{index:[...pr(p),g]}]}),f.apply(p,h)})})}),L(()=>{n.CSSStyleSheet.prototype.insertRule=s,n.CSSStyleSheet.prototype.deleteRule=o,i&&(n.CSSStyleSheet.prototype.replace=i),a&&(n.CSSStyleSheet.prototype.replaceSync=a),Object.entries(c).forEach(([u,d])=>{d.prototype.insertRule=l[u].insertRule,d.prototype.deleteRule=l[u].deleteRule})})}function mi({mirror:e,stylesheetManager:t},r){let n=null;r.nodeName==="#document"?n=e.getId(r):n=e.getId(r.host);let s=r.nodeName==="#document"?pe([r,"access",i=>i.defaultView,"optionalAccess",i=>i.Document]):pe([r,"access",i=>i.ownerDocument,"optionalAccess",i=>i.defaultView,"optionalAccess",i=>i.ShadowRoot]),o=pe([s,"optionalAccess",i=>i.prototype])?Object.getOwnPropertyDescriptor(pe([s,"optionalAccess",i=>i.prototype]),"adoptedStyleSheets"):void 0;return n===null||n===-1||!s||!o?()=>{}:(Object.defineProperty(r,"adoptedStyleSheets",{configurable:o.configurable,enumerable:o.enumerable,get(){return pe([o,"access",i=>i.get,"optionalAccess",i=>i.call,"call",i=>i(this)])},set(i){let a=pe([o,"access",c=>c.set,"optionalAccess",c=>c.call,"call",c=>c(this,i)]);if(n!==null&&n!==-1)try{t.adoptStyleSheets(i,n)}catch{}return a}}),L(()=>{Object.defineProperty(r,"adoptedStyleSheets",{configurable:o.configurable,enumerable:o.enumerable,get:o.get,set:o.set})}))}function Ju({styleDeclarationCb:e,mirror:t,ignoreCSSAttributes:r,stylesheetManager:n},{win:s}){let o=s.CSSStyleDeclaration.prototype.setProperty;s.CSSStyleDeclaration.prototype.setProperty=new Proxy(o,{apply:L((a,c,l)=>{let[u,d,f]=l;if(r.has(u))return o.apply(c,[u,d,f]);let{id:p,styleId:h}=Ee(pe([c,"access",g=>g.parentRule,"optionalAccess",g=>g.parentStyleSheet]),t,n.styleMirror);return(p&&p!==-1||h&&h!==-1)&&e({id:p,styleId:h,set:{property:u,value:d,priority:f},index:pr(c.parentRule)}),a.apply(c,l)})});let i=s.CSSStyleDeclaration.prototype.removeProperty;return s.CSSStyleDeclaration.prototype.removeProperty=new Proxy(i,{apply:L((a,c,l)=>{let[u]=l;if(r.has(u))return i.apply(c,[u]);let{id:d,styleId:f}=Ee(pe([c,"access",p=>p.parentRule,"optionalAccess",p=>p.parentStyleSheet]),t,n.styleMirror);return(d&&d!==-1||f&&f!==-1)&&e({id:d,styleId:f,remove:{property:u},index:pr(c.parentRule)}),a.apply(c,l)})}),L(()=>{s.CSSStyleDeclaration.prototype.setProperty=o,s.CSSStyleDeclaration.prototype.removeProperty=i})}function Zu({mediaInteractionCb:e,blockClass:t,blockSelector:r,unblockSelector:n,mirror:s,sampling:o,doc:i}){let a=L(l=>Et(L(u=>{let d=xt(u);if(!d||de(d,t,r,n,!0))return;let{currentTime:f,volume:p,muted:h,playbackRate:g}=d;e({type:l,id:s.getId(d),currentTime:f,volume:p,muted:h,playbackRate:g})}),o.media||500)),c=[re("play",a(0),i),re("pause",a(1),i),re("seeked",a(2),i),re("volumechange",a(3),i),re("ratechange",a(4),i)];return L(()=>{c.forEach(l=>l())})}function Qu({fontCb:e,doc:t}){let r=t.defaultView;if(!r)return()=>{};let n=[],s=new WeakMap,o=r.FontFace;r.FontFace=function(c,l,u){let d=new o(c,l,u);return s.set(d,{family:c,buffer:typeof l!="string",descriptors:u,fontSource:typeof l=="string"?l:JSON.stringify(Array.from(new Uint8Array(l)))}),d};let i=Xn(t.fonts,"add",function(a){return function(c){return wr(L(()=>{let l=s.get(c);l&&(e(l),s.delete(c))}),0),a.apply(this,[c])}});return n.push(()=>{r.FontFace=o}),n.push(i),L(()=>{n.forEach(a=>a())})}function ed(e){let{doc:t,mirror:r,blockClass:n,blockSelector:s,unblockSelector:o,selectionCb:i}=e,a=!0,c=L(()=>{let l=t.getSelection();if(!l||a&&pe([l,"optionalAccess",f=>f.isCollapsed]))return;a=l.isCollapsed||!1;let u=[],d=l.rangeCount||0;for(let f=0;f<d;f++){let p=l.getRangeAt(f),{startContainer:h,startOffset:g,endContainer:b,endOffset:m}=p;de(h,n,s,o,!0)||de(b,n,s,o,!0)||u.push({start:r.getId(h),startOffset:g,end:r.getId(b),endOffset:m})}i({ranges:u})});return c(),re("selectionchange",c)}function td({doc:e,customElementCb:t}){let r=e.defaultView;return!r||!r.customElements?()=>{}:Xn(r.customElements,"define",function(s){return function(o,i,a){try{t({define:{name:o}})}catch{}return s.apply(this,[o,i,a])}})}function rd(e,t={}){let r=e.doc.defaultView;if(!r)return()=>{};let n=pi(e,e.doc),s=Gu(e),o=qu(e),i=hi(e),a=Vu(e,{win:r}),c=Ku(e),l=Zu(e),u=Xu(e,{win:r}),d=mi(e,e.doc),f=Ju(e,{win:r}),p=e.collectFonts?Qu(e):()=>{},h=ed(e),g=td(e),b=[];for(let m of e.plugins)b.push(m.observer(m.callback,r,m.options));return L(()=>{Ke.forEach(m=>m.reset()),n.disconnect(),s(),o(),i(),a(),c(),l(),u(),d(),f(),p(),h(),g(),b.forEach(m=>m())})}function or(e){return typeof window[e]<"u"}function ir(e){return!!(typeof window[e]<"u"&&window[e].prototype&&"insertRule"in window[e].prototype&&"deleteRule"in window[e].prototype)}var wt=class{constructor(t){this.generateIdFn=t,this.iframeIdToRemoteIdMap=new WeakMap,this.iframeRemoteIdToIdMap=new WeakMap}getId(t,r,n,s){let o=n||this.getIdToRemoteIdMap(t),i=s||this.getRemoteIdToIdMap(t),a=o.get(r);return a||(a=this.generateIdFn(),o.set(r,a),i.set(a,r)),a}getIds(t,r){let n=this.getIdToRemoteIdMap(t),s=this.getRemoteIdToIdMap(t);return r.map(o=>this.getId(t,o,n,s))}getRemoteId(t,r,n){let s=n||this.getRemoteIdToIdMap(t);if(typeof r!="number")return r;let o=s.get(r);return o||-1}getRemoteIds(t,r){let n=this.getRemoteIdToIdMap(t);return r.map(s=>this.getRemoteId(t,s,n))}reset(t){if(!t){this.iframeIdToRemoteIdMap=new WeakMap,this.iframeRemoteIdToIdMap=new WeakMap;return}this.iframeIdToRemoteIdMap.delete(t),this.iframeRemoteIdToIdMap.delete(t)}getIdToRemoteIdMap(t){let r=this.iframeIdToRemoteIdMap.get(t);return r||(r=new Map,this.iframeIdToRemoteIdMap.set(t,r)),r}getRemoteIdToIdMap(t){let r=this.iframeRemoteIdToIdMap.get(t);return r||(r=new Map,this.iframeRemoteIdToIdMap.set(t,r)),r}};function Wo(e){let t,r=e[0],n=1;for(;n<e.length;){let s=e[n],o=e[n+1];if(n+=2,(s==="optionalAccess"||s==="optionalCall")&&r==null)return;s==="access"||s==="optionalAccess"?(t=r,r=o(r)):(s==="call"||s==="optionalCall")&&(r=o((...i)=>r.call(t,...i)),t=void 0)}return r}var Mn=class{constructor(){this.crossOriginIframeMirror=new wt(Yn),this.crossOriginIframeRootIdMap=new WeakMap}addIframe(){}addLoadListener(){}attachIframe(){}},An=class{constructor(t){this.iframes=new WeakMap,this.crossOriginIframeMap=new WeakMap,this.crossOriginIframeMirror=new wt(Yn),this.crossOriginIframeRootIdMap=new WeakMap,this.mutationCb=t.mutationCb,this.wrappedEmit=t.wrappedEmit,this.stylesheetManager=t.stylesheetManager,this.recordCrossOriginIframes=t.recordCrossOriginIframes,this.crossOriginIframeStyleMirror=new wt(this.stylesheetManager.styleMirror.generateId.bind(this.stylesheetManager.styleMirror)),this.mirror=t.mirror,this.recordCrossOriginIframes&&window.addEventListener("message",this.handleMessage.bind(this))}addIframe(t){this.iframes.set(t,!0),t.contentWindow&&this.crossOriginIframeMap.set(t.contentWindow,t)}addLoadListener(t){this.loadListener=t}attachIframe(t,r){this.mutationCb({adds:[{parentId:this.mirror.getId(t),nextId:null,node:r}],removes:[],texts:[],attributes:[],isAttachIframe:!0}),Wo([this,"access",n=>n.loadListener,"optionalCall",n=>n(t)]),t.contentDocument&&t.contentDocument.adoptedStyleSheets&&t.contentDocument.adoptedStyleSheets.length>0&&this.stylesheetManager.adoptStyleSheets(t.contentDocument.adoptedStyleSheets,this.mirror.getId(t.contentDocument))}handleMessage(t){let r=t;if(r.data.type!=="rrweb"||r.origin!==r.data.origin||!t.source)return;let s=this.crossOriginIframeMap.get(t.source);if(!s)return;let o=this.transformCrossOriginEvent(s,r.data.event);o&&this.wrappedEmit(o,r.data.isCheckout)}transformCrossOriginEvent(t,r){switch(r.type){case M.FullSnapshot:{this.crossOriginIframeMirror.reset(t),this.crossOriginIframeStyleMirror.reset(t),this.replaceIdOnNode(r.data.node,t);let n=r.data.node.id;return this.crossOriginIframeRootIdMap.set(t,n),this.patchRootIdOnNode(r.data.node,n),{timestamp:r.timestamp,type:M.IncrementalSnapshot,data:{source:A.Mutation,adds:[{parentId:this.mirror.getId(t),nextId:null,node:r.data.node}],removes:[],texts:[],attributes:[],isAttachIframe:!0}}}case M.Meta:case M.Load:case M.DomContentLoaded:return!1;case M.Plugin:return r;case M.Custom:return this.replaceIds(r.data.payload,t,["id","parentId","previousId","nextId"]),r;case M.IncrementalSnapshot:switch(r.data.source){case A.Mutation:return r.data.adds.forEach(n=>{this.replaceIds(n,t,["parentId","nextId","previousId"]),this.replaceIdOnNode(n.node,t);let s=this.crossOriginIframeRootIdMap.get(t);s&&this.patchRootIdOnNode(n.node,s)}),r.data.removes.forEach(n=>{this.replaceIds(n,t,["parentId","id"])}),r.data.attributes.forEach(n=>{this.replaceIds(n,t,["id"])}),r.data.texts.forEach(n=>{this.replaceIds(n,t,["id"])}),r;case A.Drag:case A.TouchMove:case A.MouseMove:return r.data.positions.forEach(n=>{this.replaceIds(n,t,["id"])}),r;case A.ViewportResize:return!1;case A.MediaInteraction:case A.MouseInteraction:case A.Scroll:case A.CanvasMutation:case A.Input:return this.replaceIds(r.data,t,["id"]),r;case A.StyleSheetRule:case A.StyleDeclaration:return this.replaceIds(r.data,t,["id"]),this.replaceStyleIds(r.data,t,["styleId"]),r;case A.Font:return r;case A.Selection:return r.data.ranges.forEach(n=>{this.replaceIds(n,t,["start","end"])}),r;case A.AdoptedStyleSheet:return this.replaceIds(r.data,t,["id"]),this.replaceStyleIds(r.data,t,["styleIds"]),Wo([r,"access",n=>n.data,"access",n=>n.styles,"optionalAccess",n=>n.forEach,"call",n=>n(s=>{this.replaceStyleIds(s,t,["styleId"])})]),r}}return!1}replace(t,r,n,s){for(let o of s)!Array.isArray(r[o])&&typeof r[o]!="number"||(Array.isArray(r[o])?r[o]=t.getIds(n,r[o]):r[o]=t.getId(n,r[o]));return r}replaceIds(t,r,n){return this.replace(this.crossOriginIframeMirror,t,r,n)}replaceStyleIds(t,r,n){return this.replace(this.crossOriginIframeStyleMirror,t,r,n)}replaceIdOnNode(t,r){this.replaceIds(t,r,["id","rootId"]),"childNodes"in t&&t.childNodes.forEach(n=>{this.replaceIdOnNode(n,r)})}patchRootIdOnNode(t,r){t.type!==Z.Document&&!t.rootId&&(t.rootId=r),"childNodes"in t&&t.childNodes.forEach(n=>{this.patchRootIdOnNode(n,r)})}},On=class{init(){}addShadowRoot(){}observeAttachShadow(){}reset(){}},Ln=class{constructor(t){this.shadowDoms=new WeakSet,this.restoreHandlers=[],this.mutationCb=t.mutationCb,this.scrollCb=t.scrollCb,this.bypassOptions=t.bypassOptions,this.mirror=t.mirror,this.init()}init(){this.reset(),this.patchAttachShadow(Element,document)}addShadowRoot(t,r){if(!_t(t)||this.shadowDoms.has(t))return;this.shadowDoms.add(t);let n=pi({...this.bypassOptions,doc:r,mutationCb:this.mutationCb,mirror:this.mirror,shadowDomManager:this},t);this.restoreHandlers.push(()=>n.disconnect()),this.restoreHandlers.push(hi({...this.bypassOptions,scrollCb:this.scrollCb,doc:t,mirror:this.mirror})),wr(()=>{t.adoptedStyleSheets&&t.adoptedStyleSheets.length>0&&this.bypassOptions.stylesheetManager.adoptStyleSheets(t.adoptedStyleSheets,this.mirror.getId(t.host)),this.restoreHandlers.push(mi({mirror:this.mirror,stylesheetManager:this.bypassOptions.stylesheetManager},t))},0)}observeAttachShadow(t){!t.contentWindow||!t.contentDocument||this.patchAttachShadow(t.contentWindow.Element,t.contentDocument)}patchAttachShadow(t,r){let n=this;this.restoreHandlers.push(Xn(t.prototype,"attachShadow",function(s){return function(o){let i=s.call(this,o);return this.shadowRoot&&ui(this)&&n.addShadowRoot(this.shadowRoot,r),i}}))}reset(){this.restoreHandlers.forEach(t=>{try{t()}catch{}}),this.restoreHandlers=[],this.shadowDoms=new WeakSet}},hr=class{reset(){}freeze(){}unfreeze(){}lock(){}unlock(){}snapshot(){}},Dn=class{constructor(t){this.trackedLinkElements=new WeakSet,this.styleMirror=new Cn,this.mutationCb=t.mutationCb,this.adoptedStyleSheetCb=t.adoptedStyleSheetCb}attachLinkElement(t,r){"_cssText"in r.attributes&&this.mutationCb({adds:[],removes:[],texts:[],attributes:[{id:r.id,attributes:r.attributes}]}),this.trackLinkElement(t)}trackLinkElement(t){this.trackedLinkElements.has(t)||(this.trackedLinkElements.add(t),this.trackStylesheetInLinkElement(t))}adoptStyleSheets(t,r){if(t.length===0)return;let n={id:r,styleIds:[]},s=[];for(let o of t){let i;this.styleMirror.has(o)?i=this.styleMirror.getId(o):(i=this.styleMirror.add(o),s.push({styleId:i,rules:Array.from(o.rules||CSSRule,(a,c)=>({rule:Zo(a),index:c}))})),n.styleIds.push(i)}s.length>0&&(n.styles=s),this.adoptedStyleSheetCb(n)}reset(){this.styleMirror.reset(),this.trackedLinkElements=new WeakSet}trackStylesheetInLinkElement(t){}},Nn=class{constructor(){this.nodeMap=new WeakMap,this.loop=!0,this.periodicallyClear()}periodicallyClear(){Uu(()=>{this.clear(),this.loop&&this.periodicallyClear()})}inOtherBuffer(t,r){let n=this.nodeMap.get(t);return n&&Array.from(n).some(s=>s!==r)}add(t,r){this.nodeMap.set(t,(this.nodeMap.get(t)||new Set).add(r))}clear(){this.nodeMap=new WeakMap}destroy(){this.loop=!1}},K,mr,ue=fu();function Ie(e={}){let{emit:t,checkoutEveryNms:r,checkoutEveryNth:n,blockClass:s="rr-block",blockSelector:o=null,unblockSelector:i=null,ignoreClass:a="rr-ignore",ignoreSelector:c=null,maskAllText:l=!1,maskTextClass:u="rr-mask",unmaskTextClass:d=null,maskTextSelector:f=null,unmaskTextSelector:p=null,inlineStylesheet:h=!0,maskAllInputs:g,maskInputOptions:b,slimDOMOptions:m,maskAttributeFn:_,maskInputFn:w,maskTextFn:C,maxCanvasSize:O=null,packFn:I,sampling:S={},dataURLOptions:R={},mousemoveWait:$,recordCanvas:v=!1,recordCrossOriginIframes:x=!1,recordAfter:B=e.recordAfter==="DOMContentLoaded"?e.recordAfter:"load",userTriggeredOnInput:Y=!1,collectFonts:J=!1,inlineImages:se=!1,plugins:H,keepIframeSrcFn:ie=()=>!1,ignoreCSSAttributes:X=new Set([]),errorHandler:ne,onMutation:ae,getCanvasManager:Pr}=e;$u(ne);let Pe=x?window.parent===window:!0,_e=!1;if(!Pe)try{window.parent.document&&(_e=!1)}catch{_e=!0}if(Pe&&!t)throw new Error("emit function is required");$!==void 0&&S.mousemove===void 0&&(S.mousemove=$),ue.reset();let Fe=g===!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}:b!==void 0?b:{},st=m===!0||m==="all"?{script:!0,comment:!0,headFavicon:!0,headWhitespace:!0,headMetaSocial:!0,headMetaRobots:!0,headMetaHttpEquiv:!0,headMetaVerification:!0,headMetaAuthorship:m==="all",headMetaDescKeywords:m==="all"}:m||{};Fu();let Fr,Br=0,fs=P=>{for(let ce of H||[])ce.eventProcessor&&(P=ce.eventProcessor(P));return I&&!_e&&(P=I(P)),P};K=(P,ce)=>{let N=P;if(N.timestamp=fr(),We([Ke,"access",V=>V[0],"optionalAccess",V=>V.isFrozen,"call",V=>V()])&&N.type!==M.FullSnapshot&&!(N.type===M.IncrementalSnapshot&&N.data.source===A.Mutation)&&Ke.forEach(V=>V.unfreeze()),Pe)We([t,"optionalCall",V=>V(fs(N),ce)]);else if(_e){let V={type:"rrweb",event:fs(N),origin:window.location.origin,isCheckout:ce};window.parent.postMessage(V,"*")}if(N.type===M.FullSnapshot)Fr=N,Br=0;else if(N.type===M.IncrementalSnapshot){if(N.data.source===A.Mutation&&N.data.isAttachIframe)return;Br++;let V=n&&Br>=n,F=r&&Fr&&N.timestamp-Fr.timestamp>r;(V||F)&&Ur(!0)}};let Lt=P=>{K({type:M.IncrementalSnapshot,data:{source:A.Mutation,...P}})},ps=P=>K({type:M.IncrementalSnapshot,data:{source:A.Scroll,...P}}),Ta=P=>K({type:M.IncrementalSnapshot,data:{source:A.CanvasMutation,...P}}),Ra=P=>K({type:M.IncrementalSnapshot,data:{source:A.AdoptedStyleSheet,...P}}),Ce=new Dn({mutationCb:Lt,adoptedStyleSheetCb:Ra}),xe=typeof __RRWEB_EXCLUDE_IFRAME__=="boolean"&&__RRWEB_EXCLUDE_IFRAME__?new Mn:new An({mirror:ue,mutationCb:Lt,stylesheetManager:Ce,recordCrossOriginIframes:x,wrappedEmit:K});for(let P of H||[])P.getMirror&&P.getMirror({nodeMirror:ue,crossOriginIframeMirror:xe.crossOriginIframeMirror,crossOriginIframeStyleMirror:xe.crossOriginIframeStyleMirror});let Hr=new Nn,hs=sd(Pr,{mirror:ue,win:window,mutationCb:P=>K({type:M.IncrementalSnapshot,data:{source:A.CanvasMutation,...P}}),recordCanvas:v,blockClass:s,blockSelector:o,unblockSelector:i,maxCanvasSize:O,sampling:S.canvas,dataURLOptions:R,errorHandler:ne}),Dt=typeof __RRWEB_EXCLUDE_SHADOW_DOM__=="boolean"&&__RRWEB_EXCLUDE_SHADOW_DOM__?new On:new Ln({mutationCb:Lt,scrollCb:ps,bypassOptions:{onMutation:ae,blockClass:s,blockSelector:o,unblockSelector:i,maskAllText:l,maskTextClass:u,unmaskTextClass:d,maskTextSelector:f,unmaskTextSelector:p,inlineStylesheet:h,maskInputOptions:Fe,dataURLOptions:R,maskAttributeFn:_,maskTextFn:C,maskInputFn:w,recordCanvas:v,inlineImages:se,sampling:S,slimDOMOptions:st,iframeManager:xe,stylesheetManager:Ce,canvasManager:hs,keepIframeSrcFn:ie,processedNodeManager:Hr},mirror:ue}),Ur=(P=!1)=>{K({type:M.Meta,data:{href:window.location.href,width:si(),height:ni()}},P),Ce.reset(),Dt.init(),Ke.forEach(N=>N.lock());let ce=Nu(document,{mirror:ue,blockClass:s,blockSelector:o,unblockSelector:i,maskAllText:l,maskTextClass:u,unmaskTextClass:d,maskTextSelector:f,unmaskTextSelector:p,inlineStylesheet:h,maskAllInputs:Fe,maskAttributeFn:_,maskInputFn:w,maskTextFn:C,slimDOM:st,dataURLOptions:R,recordCanvas:v,inlineImages:se,onSerialize:N=>{ai(N,ue)&&xe.addIframe(N),ci(N,ue)&&Ce.trackLinkElement(N),kn(N)&&Dt.addShadowRoot(N.shadowRoot,document)},onIframeLoad:(N,V)=>{xe.attachIframe(N,V),Dt.observeAttachShadow(N)},onStylesheetLoad:(N,V)=>{Ce.attachLinkElement(N,V)},keepIframeSrcFn:ie});if(!ce)return console.warn("Failed to snapshot the document");K({type:M.FullSnapshot,data:{node:ce,initialOffset:ri(window)}}),Ke.forEach(N=>N.unlock()),document.adoptedStyleSheets&&document.adoptedStyleSheets.length>0&&Ce.adoptStyleSheets(document.adoptedStyleSheets,ue.getId(document))};mr=Ur;try{let P=[],ce=V=>L(rd)({onMutation:ae,mutationCb:Lt,mousemoveCb:(F,Te)=>K({type:M.IncrementalSnapshot,data:{source:Te,positions:F}}),mouseInteractionCb:F=>K({type:M.IncrementalSnapshot,data:{source:A.MouseInteraction,...F}}),scrollCb:ps,viewportResizeCb:F=>K({type:M.IncrementalSnapshot,data:{source:A.ViewportResize,...F}}),inputCb:F=>K({type:M.IncrementalSnapshot,data:{source:A.Input,...F}}),mediaInteractionCb:F=>K({type:M.IncrementalSnapshot,data:{source:A.MediaInteraction,...F}}),styleSheetRuleCb:F=>K({type:M.IncrementalSnapshot,data:{source:A.StyleSheetRule,...F}}),styleDeclarationCb:F=>K({type:M.IncrementalSnapshot,data:{source:A.StyleDeclaration,...F}}),canvasMutationCb:Ta,fontCb:F=>K({type:M.IncrementalSnapshot,data:{source:A.Font,...F}}),selectionCb:F=>{K({type:M.IncrementalSnapshot,data:{source:A.Selection,...F}})},customElementCb:F=>{K({type:M.IncrementalSnapshot,data:{source:A.CustomElement,...F}})},blockClass:s,ignoreClass:a,ignoreSelector:c,maskAllText:l,maskTextClass:u,unmaskTextClass:d,maskTextSelector:f,unmaskTextSelector:p,maskInputOptions:Fe,inlineStylesheet:h,sampling:S,recordCanvas:v,inlineImages:se,userTriggeredOnInput:Y,collectFonts:J,doc:V,maskAttributeFn:_,maskInputFn:w,maskTextFn:C,keepIframeSrcFn:ie,blockSelector:o,unblockSelector:i,slimDOMOptions:st,dataURLOptions:R,mirror:ue,iframeManager:xe,stylesheetManager:Ce,shadowDomManager:Dt,processedNodeManager:Hr,canvasManager:hs,ignoreCSSAttributes:X,plugins:We([H,"optionalAccess",F=>F.filter,"call",F=>F(Te=>Te.observer),"optionalAccess",F=>F.map,"call",F=>F(Te=>({observer:Te.observer,options:Te.options,callback:Ma=>K({type:M.Plugin,data:{plugin:Te.name,payload:Ma}})}))])||[]},{});xe.addLoadListener(V=>{try{P.push(ce(V.contentDocument))}catch(F){console.warn(F)}});let N=()=>{Ur(),P.push(ce(document))};return document.readyState==="interactive"||document.readyState==="complete"?N():(P.push(re("DOMContentLoaded",()=>{K({type:M.DomContentLoaded,data:{}}),B==="DOMContentLoaded"&&N()})),P.push(re("load",()=>{K({type:M.Load,data:{}}),B==="load"&&N()},window))),()=>{P.forEach(V=>V()),Hr.destroy(),mr=void 0,ju()}}catch(P){console.warn(P)}}function nd(e){if(!mr)throw new Error("please take full snapshot after start recording");mr(e)}Ie.mirror=ue;Ie.takeFullSnapshot=nd;function sd(e,t){try{return e?e(t):new hr}catch{return console.warn("Unable to initialize CanvasManager"),new hr}}var od=3,id=5;function Zn(e){return e>9999999999?e:e*1e3}function vn(e){return e>9999999999?e/1e3:e}function Tt(e,t){t.category!=="sentry.transaction"&&(["ui.click","ui.input"].includes(t.category)?e.triggerUserActivity():e.checkAndHandleExpiredSession(),e.addUpdate(()=>(e.throttledAddEvent({type:M.Custom,timestamp:(t.timestamp||0)*1e3,data:{tag:"breadcrumb",payload:qr(t,10,1e3)}}),t.category==="console")))}var ad="button,a";function gi(e){return e.closest(ad)||e}function yi(e){let t=_i(e);return!t||!(t instanceof Element)?t:gi(t)}function _i(e){return cd(e)?e.target:e}function cd(e){return typeof e=="object"&&!!e&&"target"in e}var we;function ld(e){return we||(we=[],ud()),we.push(e),()=>{let t=we?we.indexOf(e):-1;t>-1&&we.splice(t,1)}}function ud(){fe(z,"open",function(e){return function(...t){if(we)try{we.forEach(r=>r())}catch{}return e.apply(z,t)}})}function dd(e,t,r){e.handleClick(t,r)}var Pn=class{constructor(t,r,n=Tt){this._lastMutation=0,this._lastScroll=0,this._clicks=[],this._timeout=r.timeout/1e3,this._threshold=r.threshold/1e3,this._scollTimeout=r.scrollTimeout/1e3,this._replay=t,this._ignoreSelector=r.ignoreSelector,this._addBreadcrumbEvent=n}addListeners(){let t=ld(()=>{this._lastMutation=zo()});this._teardown=()=>{t(),this._clicks=[],this._lastMutation=0,this._lastScroll=0}}removeListeners(){this._teardown&&this._teardown(),this._checkClickTimeout&&clearTimeout(this._checkClickTimeout)}handleClick(t,r){if(pd(r,this._ignoreSelector)||!hd(t))return;let n={timestamp:vn(t.timestamp),clickBreadcrumb:t,clickCount:0,node:r};this._clicks.some(s=>s.node===n.node&&Math.abs(s.timestamp-n.timestamp)<1)||(this._clicks.push(n),this._clicks.length===1&&this._scheduleCheckClicks())}registerMutation(t=Date.now()){this._lastMutation=vn(t)}registerScroll(t=Date.now()){this._lastScroll=vn(t)}registerClick(t){let r=gi(t);this._handleMultiClick(r)}_handleMultiClick(t){this._getClicks(t).forEach(r=>{r.clickCount++})}_getClicks(t){return this._clicks.filter(r=>r.node===t)}_checkClicks(){let t=[],r=zo();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<=r&&t.push(n)});for(let n of t){let s=this._clicks.indexOf(n);s>-1&&(this._generateBreadcrumbs(n),this._clicks.splice(s,1))}this._clicks.length&&this._scheduleCheckClicks()}_generateBreadcrumbs(t){let r=this._replay,n=t.scrollAfter&&t.scrollAfter<=this._scollTimeout,s=t.mutationAfter&&t.mutationAfter<=this._threshold,o=!n&&!s,{clickCount:i,clickBreadcrumb:a}=t;if(o){let c=Math.min(t.mutationAfter||this._timeout,this._timeout)*1e3,l=c<this._timeout*1e3?"mutation":"timeout",u={type:"default",message:a.message,timestamp:a.timestamp,category:"ui.slowClickDetected",data:{...a.data,url:z.location.href,route:r.getCurrentRoute(),timeAfterClickMs:c,endReason:l,clickCount:i||1}};this._addBreadcrumbEvent(r,u);return}if(i>1){let c={type:"default",message:a.message,timestamp:a.timestamp,category:"ui.multiClick",data:{...a.data,url:z.location.href,route:r.getCurrentRoute(),clickCount:i,metric:!0}};this._addBreadcrumbEvent(r,c)}}_scheduleCheckClicks(){this._checkClickTimeout&&clearTimeout(this._checkClickTimeout),this._checkClickTimeout=setTimeout(()=>this._checkClicks(),1e3)}},fd=["A","BUTTON","INPUT"];function pd(e,t){return!!(!fd.includes(e.tagName)||e.tagName==="INPUT"&&!["submit","button"].includes(e.getAttribute("type")||"")||e.tagName==="A"&&(e.hasAttribute("download")||e.hasAttribute("target")&&e.getAttribute("target")!=="_self")||t&&e.matches(t))}function hd(e){return!!(e.data&&typeof e.data.nodeId=="number"&&e.timestamp)}function zo(){return Date.now()/1e3}function md(e,t){try{if(!gd(t))return;let{source:r}=t.data;if(r===A.Mutation&&e.registerMutation(t.timestamp),r===A.Scroll&&e.registerScroll(t.timestamp),yd(t)){let{type:n,id:s}=t.data,o=Ie.mirror.getNode(s);o instanceof HTMLElement&&n===ee.Click&&e.registerClick(o)}}catch{}}function gd(e){return e.type===od}function yd(e){return e.data.source===A.MouseInteraction}function he(e){return{timestamp:Date.now()/1e3,type:"default",...e}}var gr;(function(e){e[e.Document=0]="Document",e[e.DocumentType=1]="DocumentType",e[e.Element=2]="Element",e[e.Text=3]="Text",e[e.CDATA=4]="CDATA",e[e.Comment=5]="Comment"})(gr||(gr={}));var _d=new Set(["id","class","aria-label","role","name","alt","title","data-test-id","data-testid","disabled","aria-disabled","data-sentry-component"]);function Sd(e){let t={};for(let r in e)if(_d.has(r)){let n=r;(r==="data-testid"||r==="data-test-id")&&(n="testId"),t[n]=e[r]}return t}var bd=e=>t=>{if(!e.isEnabled())return;let r=vd(t);if(!r)return;let n=t.name==="click",s=n?t.event:void 0;n&&e.clickDetector&&s&&s.target&&!s.altKey&&!s.metaKey&&!s.ctrlKey&&!s.shiftKey&&dd(e.clickDetector,r,yi(t.event)),Tt(e,r)};function Si(e,t){let r=Ie.mirror.getId(e),n=r&&Ie.mirror.getNode(r),s=n&&Ie.mirror.getMeta(n),o=s&&wd(s)?s:null;return{message:t,data:o?{nodeId:r,node:{id:r,tagName:o.tagName,textContent:Array.from(o.childNodes).map(i=>i.type===gr.Text&&i.textContent).filter(Boolean).map(i=>i.trim()).join(""),attributes:Sd(o.attributes)}}:{}}}function vd(e){let{target:t,message:r}=Ed(e);return he({category:`ui.${e.name}`,...Si(t,r)})}function Ed(e){let t=e.name==="click",r,n=null;try{n=t?yi(e.event):_i(e.event),r=it(n,{maxStringLength:200})||"<unknown>"}catch{r="<unknown>"}return{target:n,message:r}}function wd(e){return e.type===gr.Element}function Id(e,t){if(!e.isEnabled())return;e.updateUserActivity();let r=kd(t);r&&Tt(e,r)}function kd(e){let{metaKey:t,shiftKey:r,ctrlKey:n,altKey:s,key:o,target:i}=e;if(!i||Cd(i)||!o)return null;let a=t||n||s,c=o.length===1;if(!a&&c)return null;let l=it(i,{maxStringLength:200})||"<unknown>",u=Si(i,l);return he({category:"ui.keyDown",message:l,data:{...u.data,metaKey:t,shiftKey:r,ctrlKey:n,altKey:s,key:o}})}function Cd(e){return e.tagName==="INPUT"||e.tagName==="TEXTAREA"||e.isContentEditable}var $o={resource:Ad,paint:Rd,navigation:Md};function xd(e){return e.map(Td).filter(Boolean)}function Td(e){return $o[e.entryType]?$o[e.entryType](e):null}function Qe(e){return((ut||z.performance.timeOrigin)+e)/1e3}function Rd(e){let{duration:t,entryType:r,name:n,startTime:s}=e,o=Qe(s);return{type:r,name:n,start:o,end:o+t,data:void 0}}function Md(e){let{entryType:t,name:r,decodedBodySize:n,duration:s,domComplete:o,encodedBodySize:i,domContentLoadedEventStart:a,domContentLoadedEventEnd:c,domInteractive:l,loadEventStart:u,loadEventEnd:d,redirectCount:f,startTime:p,transferSize:h,type:g}=e;return s===0?null:{type:`${t}.${g}`,start:Qe(p),end:Qe(o),name:r,data:{size:h,decodedBodySize:n,encodedBodySize:i,duration:s,domInteractive:l,domContentLoadedEventStart:a,domContentLoadedEventEnd:c,loadEventStart:u,loadEventEnd:d,domComplete:o,redirectCount:f}}}function Ad(e){let{entryType:t,initiatorType:r,name:n,responseEnd:s,startTime:o,decodedBodySize:i,encodedBodySize:a,responseStatus:c,transferSize:l}=e;return["fetch","xmlhttprequest"].includes(r)?null:{type:`${t}.${r}`,start:Qe(o),end:Qe(s),name:n,data:{size:l,statusCode:c,decodedBodySize:i,encodedBodySize:a}}}function Od(e){let t=e.entries,r=t[t.length-1],n=r?r.element:void 0,s=e.value,o=Qe(s);return{type:"largest-contentful-paint",name:"largest-contentful-paint",start:o,end:o,data:{value:s,size:s,nodeId:n?Ie.mirror.getId(n):void 0}}}function Ld(e){function t(s){e.performanceEntries.includes(s)||e.performanceEntries.push(s)}function r({entries:s}){s.forEach(t)}let n=[];return["navigation","paint","resource"].forEach(s=>{n.push(oo(s,r))}),n.push(so(({metric:s})=>{e.replayPerformanceEntries.push(Od(s))})),()=>{n.forEach(s=>s())}}var U=typeof __SENTRY_DEBUG__>"u"||__SENTRY_DEBUG__,Dd='var t=Uint8Array,n=Uint16Array,r=Int32Array,e=new t([0,0,0,0,0,0,0,0,1,1,1,1,2,2,2,2,3,3,3,3,4,4,4,4,5,5,5,5,0,0,0,0]),i=new t([0,0,0,0,1,1,2,2,3,3,4,4,5,5,6,6,7,7,8,8,9,9,10,10,11,11,12,12,13,13,0,0]),a=new t([16,17,18,0,8,7,9,6,10,5,11,4,12,3,13,2,14,1,15]),s=function(t,e){for(var i=new n(31),a=0;a<31;++a)i[a]=e+=1<<t[a-1];var s=new r(i[30]);for(a=1;a<30;++a)for(var o=i[a];o<i[a+1];++o)s[o]=o-i[a]<<5|a;return{b:i,r:s}},o=s(e,2),f=o.b,h=o.r;f[28]=258,h[258]=28;for(var l=s(i,0).r,u=new n(32768),c=0;c<32768;++c){var v=(43690&c)>>1|(21845&c)<<1;v=(61680&(v=(52428&v)>>2|(13107&v)<<2))>>4|(3855&v)<<4,u[c]=((65280&v)>>8|(255&v)<<8)>>1}var d=function(t,r,e){for(var i=t.length,a=0,s=new n(r);a<i;++a)t[a]&&++s[t[a]-1];var o,f=new n(r);for(a=1;a<r;++a)f[a]=f[a-1]+s[a-1]<<1;if(e){o=new n(1<<r);var h=15-r;for(a=0;a<i;++a)if(t[a])for(var l=a<<4|t[a],c=r-t[a],v=f[t[a]-1]++<<c,d=v|(1<<c)-1;v<=d;++v)o[u[v]>>h]=l}else for(o=new n(i),a=0;a<i;++a)t[a]&&(o[a]=u[f[t[a]-1]++]>>15-t[a]);return o},g=new t(288);for(c=0;c<144;++c)g[c]=8;for(c=144;c<256;++c)g[c]=9;for(c=256;c<280;++c)g[c]=7;for(c=280;c<288;++c)g[c]=8;var w=new t(32);for(c=0;c<32;++c)w[c]=5;var p=d(g,9,0),y=d(w,5,0),m=function(t){return(t+7)/8|0},b=function(n,r,e){return(null==r||r<0)&&(r=0),(null==e||e>n.length)&&(e=n.length),new t(n.subarray(r,e))},M=["unexpected EOF","invalid block type","invalid length/literal","invalid distance","stream finished","no stream handler",,"no callback","invalid UTF-8 data","extra field too long","date not in range 1980-2099","filename too long","stream finishing","invalid zip data"],E=function(t,n,r){var e=new Error(n||M[t]);if(e.code=t,Error.captureStackTrace&&Error.captureStackTrace(e,E),!r)throw e;return e},z=function(t,n,r){r<<=7&n;var e=n/8|0;t[e]|=r,t[e+1]|=r>>8},A=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},_=function(r,e){for(var i=[],a=0;a<r.length;++a)r[a]&&i.push({s:a,f:r[a]});var s=i.length,o=i.slice();if(!s)return{t:F,l:0};if(1==s){var f=new t(i[0].s+1);return f[i[0].s]=1,{t:f,l:1}}i.sort((function(t,n){return t.f-n.f})),i.push({s:-1,f:25001});var h=i[0],l=i[1],u=0,c=1,v=2;for(i[0]={s:-1,f:h.f+l.f,l:h,r:l};c!=s-1;)h=i[i[u].f<i[v].f?u++:v++],l=i[u!=c&&i[u].f<i[v].f?u++:v++],i[c++]={s:-1,f:h.f+l.f,l:h,r:l};var d=o[0].s;for(a=1;a<s;++a)o[a].s>d&&(d=o[a].s);var g=new n(d+1),w=x(i[c-1],g,0);if(w>e){a=0;var p=0,y=w-e,m=1<<y;for(o.sort((function(t,n){return g[n.s]-g[t.s]||t.f-n.f}));a<s;++a){var b=o[a].s;if(!(g[b]>e))break;p+=m-(1<<w-g[b]),g[b]=e}for(p>>=y;p>0;){var M=o[a].s;g[M]<e?p-=1<<e-g[M]++-1:++a}for(;a>=0&&p;--a){var E=o[a].s;g[E]==e&&(--g[E],++p)}w=e}return{t:new t(g),l:w}},x=function(t,n,r){return-1==t.s?Math.max(x(t.l,n,r+1),x(t.r,n,r+1)):n[t.s]=r},D=function(t){for(var r=t.length;r&&!t[--r];);for(var e=new n(++r),i=0,a=t[0],s=1,o=function(t){e[i++]=t},f=1;f<=r;++f)if(t[f]==a&&f!=r)++s;else{if(!a&&s>2){for(;s>138;s-=138)o(32754);s>2&&(o(s>10?s-11<<5|28690:s-3<<5|12305),s=0)}else if(s>3){for(o(a),--s;s>6;s-=6)o(8304);s>2&&(o(s-3<<5|8208),s=0)}for(;s--;)o(a);s=1,a=t[f]}return{c:e.subarray(0,i),n:r}},T=function(t,n){for(var r=0,e=0;e<n.length;++e)r+=t[e]*n[e];return r},k=function(t,n,r){var e=r.length,i=m(n+2);t[i]=255&e,t[i+1]=e>>8,t[i+2]=255^t[i],t[i+3]=255^t[i+1];for(var a=0;a<e;++a)t[i+a+4]=r[a];return 8*(i+4+e)},C=function(t,r,s,o,f,h,l,u,c,v,m){z(r,m++,s),++f[256];for(var b=_(f,15),M=b.t,E=b.l,x=_(h,15),C=x.t,U=x.l,F=D(M),I=F.c,S=F.n,L=D(C),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=_(q,7),H=G.t,J=G.l,K=19;K>4&&!H[a[K-1]];--K);var N,P,Q,R,V=v+5<<3,W=T(f,g)+T(h,w)+l,X=T(f,M)+T(h,C)+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(C,U,0),R=C;var Y=d(H,J,0);z(r,m,S-257),z(r,m+5,j-1),z(r,m+10,K-4),m+=14;for(B=0;B<K;++B)z(r,m+3*B,H[a[B]]);m+=3*K;for(var Z=[I,O],$=0;$<2;++$){var tt=Z[$];for(B=0;B<tt.length;++B){var nt=31&tt[B];z(r,m,Y[nt]),m+=H[nt],nt>15&&(z(r,m,tt[B]>>5&127),m+=tt[B]>>12)}}}else N=p,P=g,Q=y,R=w;for(B=0;B<u;++B){var rt=o[B];if(rt>255){A(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;A(r,m,Q[et]),m+=R[et],et>3&&(A(r,m,rt>>5&8191),m+=i[et])}else A(r,m,N[rt]),m+=P[rt]}return A(r,m,N[256]),m+P[256]},U=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,n=0;return{p:function(r){for(var e=t,i=n,a=0|r.length,s=0;s!=a;){for(var o=Math.min(s+2655,a);s<o;++s)i+=e+=r[s];e=(65535&e)+15*(e>>16),i=(65535&i)+15*(i>>16)}t=e,n=i},d:function(){return(255&(t%=65521))<<24|(65280&t)<<8|(255&(n%=65521))<<8|n>>8}}},L=function(a,s,o,f,u){if(!u&&(u={l:1},s.dictionary)){var c=s.dictionary.subarray(-32768),v=new t(c.length+a.length);v.set(c),v.set(a,c.length),a=v,u.w=c.length}return function(a,s,o,f,u,c){var v=c.z||a.length,d=new t(f+v+5*(1+Math.ceil(v/7e3))+u),g=d.subarray(f,d.length-u),w=c.l,p=7&(c.r||0);if(s){p&&(g[0]=c.r>>3);for(var y=U[s-1],M=y>>13,E=8191&y,z=(1<<o)-1,A=c.p||new n(32768),_=c.h||new n(z+1),x=Math.ceil(o/3),D=2*x,T=function(t){return(a[t]^a[t+1]<<x^a[t+2]<<D)&z},F=new r(25e3),I=new n(288),S=new n(32),L=0,O=0,j=c.i||0,q=0,B=c.w||0,G=0;j+2<v;++j){var H=T(j),J=32767&j,K=_[H];if(A[J]=K,_[H]=J,B<=j){var N=v-j;if((L>7e3||q>24576)&&(N>423||!w)){p=C(a,g,0,F,I,S,O,q,G,j-G,p),q=L=O=0,G=j;for(var P=0;P<286;++P)I[P]=0;for(P=0;P<30;++P)S[P]=0}var Q=2,R=0,V=E,W=J-K&32767;if(N>2&&H==T(j-W))for(var X=Math.min(M,N)-1,Y=Math.min(32767,j),Z=Math.min(258,N);W<=Y&&--V&&J!=K;){if(a[j+Q]==a[j+Q-W]){for(var $=0;$<Z&&a[j+$]==a[j+$-W];++$);if($>Q){if(Q=$,R=W,$>X)break;var tt=Math.min(W,$-2),nt=0;for(P=0;P<tt;++P){var rt=j-W+P&32767,et=rt-A[rt]&32767;et>nt&&(nt=et,K=rt)}}}W+=(J=K)-(K=A[J])&32767}if(R){F[q++]=268435456|h[Q]<<18|l[R];var it=31&h[Q],at=31&l[R];O+=e[it]+i[at],++I[257+it],++S[at],B=j+Q,++L}else F[q++]=a[j],++I[a[j]]}}for(j=Math.max(j,B);j<v;++j)F[q++]=a[j],++I[a[j]];p=C(a,g,w,F,I,S,O,q,G,j-G,p),w||(c.r=7&p|g[p/8|0]<<3,p-=7,c.h=_,c.p=A,c.i=j,c.w=B)}else{for(j=c.w||0;j<v+w;j+=65535){var st=j+65535;st>=v&&(g[p/8|0]=w,st=v),p=k(g,p+1,a.subarray(j,st))}c.i=v}return b(d,0,f+m(p)+u)}(a,null==s.level?6:s.level,null==s.mem?Math.ceil(1.5*Math.max(8,Math.min(13,Math.log(a.length)))):12+s.mem,o,f,u)},O=function(t,n,r){for(;r;++n)t[n]=r,r>>>=8},j=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(L(t,this.o,0,0,this.s),n)},n.prototype.push=function(n,r){this.ondata||E(5),this.s.l&&E(4);var e=n.length+this.s.z;if(e>this.b.length){if(e>2*this.b.length-32768){var i=new t(-32768&e);i.set(this.b.subarray(0,this.s.z)),this.b=i}var a=this.b.length-this.s.z;a&&(this.b.set(n.subarray(0,a),this.s.z),this.s.z=this.b.length,this.p(this.b,!1)),this.b.set(this.b.subarray(-32768)),this.b.set(n.subarray(a),32768),this.s.z=n.length-a+32768,this.s.i=32766,this.s.w=32768}else this.b.set(n,this.s.z),this.s.z+=n.length;this.s.l=1&r,(this.s.z>this.s.w+8191||r)&&(this.p(this.b,r||!1),this.s.w=this.s.i,this.s.i-=2)},n}();function q(t,n){n||(n={});var r=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}}}(),e=t.length;r.p(t);var i,a=L(t,n,10+((i=n).filename?i.filename.length+1:0),8),s=a.length;return 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&&O(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)}}(a,n),O(a,s-8,r.d()),O(a,s-4,e),a}var B=function(){function t(t,n){this.c=S(),this.v=1,j.call(this,t,n)}return t.prototype.push=function(t,n){this.c.p(t),j.prototype.push.call(this,t,n)},t.prototype.p=function(t,n){var r=L(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=S();i.p(n.dictionary),O(t,2,i.d())}}(r,this.o),this.v=0),n&&O(r,r.length-4,this.c.d()),this.ondata(r,n)},t}(),G="undefined"!=typeof TextEncoder&&new TextEncoder,H="undefined"!=typeof TextDecoder&&new TextDecoder;try{H.decode(F,{stream:!0})}catch(t){}var J=function(){function t(t){this.ondata=t}return t.prototype.push=function(t,n){this.ondata||E(5),this.d&&E(4),this.ondata(K(t),this.d=n||!1)},t}();function K(n,r){if(r){for(var e=new t(n.length),i=0;i<n.length;++i)e[i]=n.charCodeAt(i);return e}if(G)return G.encode(n);var a=n.length,s=new t(n.length+(n.length>>1)),o=0,f=function(t){s[o++]=t};for(i=0;i<a;++i){if(o+5>s.length){var h=new t(o+8+(a-i<<1));h.set(s),s=h}var l=n.charCodeAt(i);l<128||r?f(l):l<2048?(f(192|l>>6),f(128|63&l)):l>55295&&l<57344?(f(240|(l=65536+(1047552&l)|1023&n.charCodeAt(++i))>>18),f(128|l>>12&63),f(128|l>>6&63),f(128|63&l)):(f(224|l>>12),f(128|l>>6&63),f(128|63&l))}return b(s,0,o)}const N=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(let r=0,e=t.length;r<e;r++)n+=t[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 B,this.deflate.ondata=(t,n)=>{this._deflatedData.push(t)},this.stream=new J(((t,n)=>{this.deflate.push(t,n)})),this.stream.push("[")}},P={clear:()=>{N.clear()},addEvent:t=>N.addEvent(t),finish:()=>N.finish(),compress:t=>function(t){return q(K(t))}(t)};addEventListener("message",(function(t){const n=t.data.method,r=t.data.id,e=t.data.arg;if(n in P&&"function"==typeof P[n])try{const t=P[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 Nd(){let e=new Blob([Dd]);return URL.createObjectURL(e)}function te(e,t){U&&(y.info(e),t&&bi(e))}function Xe(e,t){U&&(y.info(e),t&&setTimeout(()=>{bi(e)},0))}function bi(e){le({category:"console",data:{logger:"replay"},level:"info",message:e},{level:"info"})}var It=class extends Error{constructor(){super(`Event buffer exceeded maximum size of ${qn}.`)}},yr=class{constructor(){this.events=[],this._totalSize=0,this.hasCheckout=!1}get hasEvents(){return this.events.length>0}get type(){return"sync"}destroy(){this.events=[]}async addEvent(t){let r=JSON.stringify(t).length;if(this._totalSize+=r,this._totalSize>qn)throw new It;this.events.push(t)}finish(){return new Promise(t=>{let r=this.events;this.clear(),t(JSON.stringify(r))})}clear(){this.events=[],this._totalSize=0,this.hasCheckout=!1}getEarliestTimestamp(){let t=this.events.map(r=>r.timestamp).sort()[0];return t?Zn(t):null}},Fn=class{constructor(t){this._worker=t,this._id=0}ensureReady(){return this._ensureReadyPromise?this._ensureReadyPromise:(this._ensureReadyPromise=new Promise((t,r)=>{this._worker.addEventListener("message",({data:n})=>{n.success?t():r()},{once:!0}),this._worker.addEventListener("error",n=>{r(n)},{once:!0})}),this._ensureReadyPromise)}destroy(){te("[Replay] Destroying compression worker"),this._worker.terminate()}postMessage(t,r){let n=this._getAndIncrementId();return new Promise((s,o)=>{let i=({data:a})=>{let c=a;if(c.method===t&&c.id===n){if(this._worker.removeEventListener("message",i),!c.success){U&&y.error("[Replay]",c.response),o(new Error("Error in compression worker"));return}s(c.response)}};this._worker.addEventListener("message",i),this._worker.postMessage({id:n,method:t,arg:r})})}_getAndIncrementId(){return this._id++}},Bn=class{constructor(t){this._worker=new Fn(t),this._earliestTimestamp=null,this._totalSize=0,this.hasCheckout=!1}get hasEvents(){return!!this._earliestTimestamp}get type(){return"worker"}ensureReady(){return this._worker.ensureReady()}destroy(){this._worker.destroy()}addEvent(t){let r=Zn(t.timestamp);(!this._earliestTimestamp||r<this._earliestTimestamp)&&(this._earliestTimestamp=r);let n=JSON.stringify(t);return this._totalSize+=n.length,this._totalSize>qn?Promise.reject(new It):this._sendEventToWorker(n)}finish(){return this._finishRequest()}clear(){this._earliestTimestamp=null,this._totalSize=0,this.hasCheckout=!1,this._worker.postMessage("clear").then(null,t=>{U&&y.warn('[Replay] Sending "clear" message to worker failed',t)})}getEarliestTimestamp(){return this._earliestTimestamp}_sendEventToWorker(t){return this._worker.postMessage("addEvent",t)}async _finishRequest(){let t=await this._worker.postMessage("finish");return this._earliestTimestamp=null,this._totalSize=0,t}},Hn=class{constructor(t){this._fallback=new yr,this._compression=new Bn(t),this._used=this._fallback,this._ensureWorkerIsLoadedPromise=this._ensureWorkerIsLoaded()}get type(){return this._used.type}get hasEvents(){return this._used.hasEvents}get hasCheckout(){return this._used.hasCheckout}set hasCheckout(t){this._used.hasCheckout=t}destroy(){this._fallback.destroy(),this._compression.destroy()}clear(){return this._used.clear()}getEarliestTimestamp(){return this._used.getEarliestTimestamp()}addEvent(t){return this._used.addEvent(t)}async finish(){return await this.ensureWorkerIsLoaded(),this._used.finish()}ensureWorkerIsLoaded(){return this._ensureWorkerIsLoadedPromise}async _ensureWorkerIsLoaded(){try{await this._compression.ensureReady()}catch{te("[Replay] Failed to load the compression worker, falling back to simple buffer");return}await this._switchToCompressionWorker()}async _switchToCompressionWorker(){let{events:t,hasCheckout:r}=this._fallback,n=[];for(let s of t)n.push(this._compression.addEvent(s));this._compression.hasCheckout=r,this._used=this._compression;try{await Promise.all(n)}catch(s){U&&y.warn("[Replay] Failed to add events when switching buffers.",s)}}};function Pd({useCompression:e,workerUrl:t}){if(e&&window.Worker){let r=Fd(t);if(r)return r}return te("[Replay] Using simple buffer"),new yr}function Fd(e){try{let t=e||Bd();if(!t)return;te(`[Replay] Using compression worker${e?` from ${e}`:""}`);let r=new Worker(t);return new Hn(r)}catch{te("[Replay] Failed to create compression worker")}}function Bd(){return typeof __SENTRY_EXCLUDE_REPLAY_WORKER__>"u"||!__SENTRY_EXCLUDE_REPLAY_WORKER__?Nd():""}function Qn(){try{return"sessionStorage"in z&&!!z.sessionStorage}catch{return!1}}function Hd(e){Ud(),e.session=void 0}function Ud(){if(Qn())try{z.sessionStorage.removeItem(jn)}catch{}}function vi(e){return e===void 0?!1:Math.random()<e}function Ei(e){let t=Date.now(),r=e.id||Be(),n=e.started||t,s=e.lastActivity||t,o=e.segmentId||0,i=e.sampled,a=e.previousSessionId;return{id:r,started:n,lastActivity:s,segmentId:o,sampled:i,previousSessionId:a}}function es(e){if(Qn())try{z.sessionStorage.setItem(jn,JSON.stringify(e))}catch{}}function Wd(e,t){return vi(e)?"session":t?"buffer":!1}function jo({sessionSampleRate:e,allowBuffering:t,stickySession:r=!1},{previousSessionId:n}={}){let s=Wd(e,t),o=Ei({sampled:s,previousSessionId:n});return r&&es(o),o}function zd(e){if(!Qn())return null;try{let t=z.sessionStorage.getItem(jn);if(!t)return null;let r=JSON.parse(t);return Xe("[Replay] Loading existing session",e),Ei(r)}catch{return null}}function Un(e,t,r=+new Date){return e===null||t===void 0||t<0?!0:t===0?!1:e+t<=r}function wi(e,{maxReplayDuration:t,sessionIdleExpire:r,targetTime:n=Date.now()}){return Un(e.started,t,n)||Un(e.lastActivity,r,n)}function Ii(e,{sessionIdleExpire:t,maxReplayDuration:r}){return!(!wi(e,{sessionIdleExpire:t,maxReplayDuration:r})||e.sampled==="buffer"&&e.segmentId===0)}function En({traceInternals:e,sessionIdleExpire:t,maxReplayDuration:r,previousSessionId:n},s){let o=s.stickySession&&zd(e);return o?Ii(o,{sessionIdleExpire:t,maxReplayDuration:r})?(Xe("[Replay] Session in sessionStorage is expired, creating new one..."),jo(s,{previousSessionId:o.id})):o:(Xe("[Replay] Creating new session",e),jo(s,{previousSessionId:n}))}function $d(e){return e.type===M.Custom}function ts(e,t,r){return Ci(e,t)?(ki(e,t,r),!0):!1}function jd(e,t,r){return Ci(e,t)?ki(e,t,r):Promise.resolve(null)}async function ki(e,t,r){if(!e.eventBuffer)return null;try{r&&e.recordingMode==="buffer"&&e.eventBuffer.clear(),r&&(e.eventBuffer.hasCheckout=!0);let n=e.getOptions(),s=Gd(t,n.beforeAddRecordingEvent);return s?await e.eventBuffer.addEvent(s):void 0}catch(n){let s=n&&n instanceof It?"addEventSizeExceeded":"addEvent";U&&y.error(n),await e.stop({reason:s});let o=D();o&&o.recordDroppedEvent("internal_sdk_error","replay")}}function Ci(e,t){if(!e.eventBuffer||e.isPaused()||!e.isEnabled())return!1;let r=Zn(t.timestamp);return r+e.timeouts.sessionIdlePause<Date.now()?!1:r>e.getContext().initialTimestamp+e.getOptions().maxReplayDuration?(te(`[Replay] Skipping event with timestamp ${r} because it is after maxReplayDuration`,e.getOptions()._experiments.traceInternals),!1):!0}function Gd(e,t){try{if(typeof t=="function"&&$d(e))return t(e)}catch(r){return U&&y.error("[Replay] An error occured in the `beforeAddRecordingEvent` callback, skipping the event...",r),null}return e}function rs(e){return!e.type}function Wn(e){return e.type==="transaction"}function qd(e){return e.type==="replay_event"}function Go(e){return e.type==="feedback"}function xi(e){let t=Kd();return(r,n)=>{if(!e.isEnabled()||!rs(r)&&!Wn(r))return;let s=n&&n.statusCode;if(!(t&&(!s||s<200||s>=300))){if(Wn(r)){Vd(e,r);return}Yd(e,r)}}}function Vd(e,t){let r=e.getContext();t.contexts&&t.contexts.trace&&t.contexts.trace.trace_id&&r.traceIds.size<100&&r.traceIds.add(t.contexts.trace.trace_id)}function Yd(e,t){let r=e.getContext();if(t.event_id&&r.errorIds.size<100&&r.errorIds.add(t.event_id),e.recordingMode!=="buffer"||!t.tags||!t.tags.replayId)return;let{beforeErrorSampling:n}=e.getOptions();typeof n=="function"&&!n(t)||setTimeout(()=>{e.sendBufferedReplayOrFlush()})}function Kd(){let e=D();if(!e)return!1;let t=e.getTransport();return t&&t.send.__sentry__baseTransport__||!1}function Xd(e){return t=>{!e.isEnabled()||!rs(t)||Jd(e,t)}}function Jd(e,t){let r=t.exception&&t.exception.values&&t.exception.values[0].value;if(typeof r=="string"&&(r.match(/reactjs\.org\/docs\/error-decoder\.html\?invariant=(418|419|422|423|425)/)||r.match(/(does not match server-rendered HTML|Hydration failed because)/i))){let n=he({category:"replay.hydrate-error"});Tt(e,n)}}function Zd(e,t){return e.type||!e.exception||!e.exception.values||!e.exception.values.length?!1:!!(t.originalException&&t.originalException.__rrweb__)}function Qd(e,t){e.triggerUserActivity(),e.addUpdate(()=>t.timestamp?(e.throttledAddEvent({type:M.Custom,timestamp:t.timestamp*1e3,data:{tag:"breadcrumb",payload:{timestamp:t.timestamp,type:"default",category:"sentry.feedback",data:{feedbackId:t.event_id}}}}),!1):!0)}function ef(e,t){return e.recordingMode!=="buffer"||t.message===Gn||!t.exception||t.type?!1:vi(e.getOptions().errorSampleRate)}function tf(e,t=!1){let r=t?xi(e):void 0;return Object.assign((n,s)=>e.isEnabled()?qd(n)?(delete n.breadcrumbs,n):!rs(n)&&!Wn(n)&&!Go(n)||!e.checkAndHandleExpiredSession()?n:Go(n)?(e.flush(),n.contexts.feedback.replay_id=e.getSessionId(),Qd(e,n),n):Zd(n,s)&&!e.getOptions()._experiments.captureExceptions?(U&&y.log("[Replay] Ignoring error from rrweb internals",n),null):((ef(e,n)||e.recordingMode==="session")&&(n.tags={...n.tags,replayId:e.getSessionId()}),r&&r(n,{statusCode:200}),n):n,{id:"Replay"})}function Ir(e,t){return t.map(({type:r,start:n,end:s,name:o,data:i})=>{let a=e.throttledAddEvent({type:M.Custom,timestamp:n,data:{tag:"performanceSpan",payload:{op:r,description:o,startTimestamp:n,endTimestamp:s,data:i}}});return typeof a=="string"?Promise.resolve(null):a})}function rf(e){let{from:t,to:r}=e,n=Date.now()/1e3;return{type:"navigation.push",start:n,end:n,name:r,data:{previous:t}}}function nf(e){return t=>{if(!e.isEnabled())return;let r=rf(t);r!==null&&(e.getContext().urls.push(r.name),e.triggerUserActivity(),e.addUpdate(()=>(Ir(e,[r]),!1)))}}function sf(e,t){return U&&e.getOptions()._experiments.traceInternals?!1:to(t,D())}function kr(e,t){e.isEnabled()&&t!==null&&(sf(e,t.name)||e.addUpdate(()=>(Ir(e,[t]),!0)))}function of(e){let{startTimestamp:t,endTimestamp:r,fetchData:n,response:s}=e;if(!r)return null;let{method:o,url:i}=n;return{type:"resource.fetch",start:t/1e3,end:r/1e3,name:i,data:{method:o,statusCode:s?s.status:void 0}}}function af(e){return t=>{if(!e.isEnabled())return;let r=of(t);kr(e,r)}}function cf(e){let{startTimestamp:t,endTimestamp:r,xhr:n}=e,s=n[ct];if(!t||!r||!s)return null;let{method:o,url:i,status_code:a}=s;return i===void 0?null:{type:"resource.xhr",name:i,start:t/1e3,end:r/1e3,data:{method:o,statusCode:a}}}function lf(e){return t=>{if(!e.isEnabled())return;let r=cf(t);kr(e,r)}}function Cr(e,t){if(e)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 r=Ai(e);return t.encode(r).length}if(e instanceof Blob)return e.size;if(e instanceof ArrayBuffer)return e.byteLength}catch{}}function Ti(e){if(!e)return;let t=parseInt(e,10);return isNaN(t)?void 0:t}function Ri(e){try{if(typeof e=="string")return[e];if(e instanceof URLSearchParams)return[e.toString()];if(e instanceof FormData)return[Ai(e)];if(!e)return[void 0]}catch{return U&&y.warn("[Replay] Failed to serialize body",e),[void 0,"BODY_PARSE_ERROR"]}return U&&y.info("[Replay] Skipping network body because of body type",e),[void 0,"UNPARSEABLE_BODY_TYPE"]}function _r(e,t){if(!e)return{headers:{},size:void 0,_meta:{warnings:[t]}};let r={...e._meta},n=r.warnings||[];return r.warnings=[...n,t],e._meta=r,e}function Mi(e,t){if(!t)return null;let{startTimestamp:r,endTimestamp:n,url:s,method:o,statusCode:i,request:a,response:c}=t;return{type:e,start:r/1e3,end:n/1e3,name:s,data:Gr({method:o,statusCode:i,request:a,response:c})}}function kt(e){return{headers:{},size:e,_meta:{warnings:["URL_SKIPPED"]}}}function ke(e,t,r){if(!t&&Object.keys(e).length===0)return;if(!t)return{headers:e};if(!r)return{headers:e,size:t};let n={headers:e,size:t},{body:s,warnings:o}=uf(r);return n.body=s,o&&o.length>0&&(n._meta={warnings:o}),n}function zn(e,t){return Object.keys(e).reduce((r,n)=>{let s=n.toLowerCase();return t.includes(s)&&e[n]&&(r[s]=e[n]),r},{})}function Ai(e){return new URLSearchParams(e).toString()}function uf(e){if(!e||typeof e!="string")return{body:e};let t=e.length>Mo,r=df(e);if(t){let n=e.slice(0,Mo);return r?{body:n,warnings:["MAYBE_JSON_TRUNCATED"]}:{body:`${n}\u2026`,warnings:["TEXT_TRUNCATED"]}}if(r)try{return{body:JSON.parse(e)}}catch{}return{body:e}}function df(e){let t=e[0],r=e[e.length-1];return t==="["&&r==="]"||t==="{"&&r==="}"}function Sr(e,t){let r=ff(e);return Ss(r,t)}function ff(e,t=z.document.baseURI){if(e.startsWith("http://")||e.startsWith("https://")||e.startsWith(z.location.origin))return e;let r=new URL(e,t);if(r.origin!==new URL(t).origin)return e;let n=r.href;return!e.endsWith("/")&&n.endsWith("/")?n.slice(0,-1):n}async function pf(e,t,r){try{let n=await mf(e,t,r),s=Mi("resource.fetch",n);kr(r.replay,s)}catch(n){U&&y.error("[Replay] Failed to capture fetch breadcrumb",n)}}function hf(e,t,r){let{input:n,response:s}=t,o=n?Oi(n):void 0,i=Cr(o,r.textEncoder),a=s?Ti(s.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 mf(e,t,r){let n=Date.now(),{startTimestamp:s=n,endTimestamp:o=n}=t,{url:i,method:a,status_code:c=0,request_body_size:l,response_body_size:u}=e.data,d=Sr(i,r.networkDetailAllowUrls)&&!Sr(i,r.networkDetailDenyUrls),f=d?gf(r,t.input,l):kt(l),p=await yf(d,r,t.response,u);return{startTimestamp:s,endTimestamp:o,url:i,method:a,statusCode:c,request:f,response:p}}function gf({networkCaptureBodies:e,networkRequestHeaders:t},r,n){let s=r?bf(r,t):{};if(!e)return ke(s,n,void 0);let o=Oi(r),[i,a]=Ri(o),c=ke(s,n,i);return a?_r(c,a):c}async function yf(e,{networkCaptureBodies:t,textEncoder:r,networkResponseHeaders:n},s,o){if(!e&&o!==void 0)return kt(o);let i=s?Li(s.headers,n):{};if(!s||!t&&o!==void 0)return ke(i,o,void 0);let[a,c]=await Sf(s),l=_f(a,{networkCaptureBodies:t,textEncoder:r,responseBodySize:o,captureDetails:e,headers:i});return c?_r(l,c):l}function _f(e,{networkCaptureBodies:t,textEncoder:r,responseBodySize:n,captureDetails:s,headers:o}){try{let i=e&&e.length&&n===void 0?Cr(e,r):n;return s?t?ke(o,i,e):ke(o,i,void 0):kt(i)}catch(i){return U&&y.warn("[Replay] Failed to serialize response body",i),ke(o,n,void 0)}}async function Sf(e){let t=vf(e);if(!t)return[void 0,"BODY_PARSE_ERROR"];try{return[await Ef(t)]}catch(r){return U&&y.warn("[Replay] Failed to get text body from response",r),[void 0,"BODY_PARSE_ERROR"]}}function Oi(e=[]){if(!(e.length!==2||typeof e[1]!="object"))return e[1].body}function Li(e,t){let r={};return t.forEach(n=>{e.get(n)&&(r[n]=e.get(n))}),r}function bf(e,t){return e.length===1&&typeof e[0]!="string"?qo(e[0],t):e.length===2?qo(e[1],t):{}}function qo(e,t){if(!e)return{};let r=e.headers;return r?r instanceof Headers?Li(r,t):Array.isArray(r)?{}:zn(r,t):{}}function vf(e){try{return e.clone()}catch(t){U&&y.warn("[Replay] Failed to clone response body",t)}}function Ef(e){return new Promise((t,r)=>{let n=setTimeout(()=>r(new Error("Timeout while trying to read response body")),500);wf(e).then(s=>t(s),s=>r(s)).finally(()=>clearTimeout(n))})}async function wf(e){return await e.text()}async function If(e,t,r){try{let n=Cf(e,t,r),s=Mi("resource.xhr",n);kr(r.replay,s)}catch(n){U&&y.error("[Replay] Failed to capture xhr breadcrumb",n)}}function kf(e,t,r){let{xhr:n,input:s}=t;if(!n)return;let o=Cr(s,r.textEncoder),i=n.getResponseHeader("content-length")?Ti(n.getResponseHeader("content-length")):Mf(n.response,n.responseType,r.textEncoder);o!==void 0&&(e.data.request_body_size=o),i!==void 0&&(e.data.response_body_size=i)}function Cf(e,t,r){let n=Date.now(),{startTimestamp:s=n,endTimestamp:o=n,input:i,xhr:a}=t,{url:c,method:l,status_code:u=0,request_body_size:d,response_body_size:f}=e.data;if(!c)return null;if(!a||!Sr(c,r.networkDetailAllowUrls)||Sr(c,r.networkDetailDenyUrls)){let I=kt(d),S=kt(f);return{startTimestamp:s,endTimestamp:o,url:c,method:l,statusCode:u,request:I,response:S}}let p=a[ct],h=p?zn(p.request_headers,r.networkRequestHeaders):{},g=zn(xf(a),r.networkResponseHeaders),[b,m]=r.networkCaptureBodies?Ri(i):[void 0],[_,w]=r.networkCaptureBodies?Tf(a):[void 0],C=ke(h,d,b),O=ke(g,f,_);return{startTimestamp:s,endTimestamp:o,url:c,method:l,statusCode:u,request:m?_r(C,m):C,response:w?_r(O,w):O}}function xf(e){let t=e.getAllResponseHeaders();return t?t.split(`\r
6
6
  `).reduce((r,n)=>{let[s,o]=n.split(": ");return r[s.toLowerCase()]=o,r},{}):{}}function Tf(e){let t=[];try{return[e.responseText]}catch(r){t.push(r)}try{return Rf(e.response,e.responseType)}catch(r){t.push(r)}return U&&y.warn("[Replay] Failed to get xhr response body",...t),[void 0]}function Rf(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{return U&&y.warn("[Replay] Failed to serialize body",e),[void 0,"BODY_PARSE_ERROR"]}return U&&y.info("[Replay] Skipping network body because of body type",e),[void 0,"UNPARSEABLE_BODY_TYPE"]}function Mf(e,t,r){try{let n=t==="json"&&e&&typeof e=="object"?JSON.stringify(e):e;return Cr(n,r)}catch{return}}function Af(e){let t=D();try{let r=new TextEncoder,{networkDetailAllowUrls:n,networkDetailDenyUrls:s,networkCaptureBodies:o,networkRequestHeaders:i,networkResponseHeaders:a}=e.getOptions(),c={replay:e,textEncoder:r,networkDetailAllowUrls:n,networkDetailDenyUrls:s,networkCaptureBodies:o,networkRequestHeaders:i,networkResponseHeaders:a};t&&t.on?t.on("beforeAddBreadcrumb",(l,u)=>Of(c,l,u)):(Wt(af(e)),zt(lf(e)))}catch{}}function Of(e,t,r){if(t.data)try{Lf(t)&&Nf(r)&&(kf(t,r,e),If(t,r,e)),Df(t)&&Pf(r)&&(hf(t,r,e),pf(t,r,e))}catch{U&&y.warn("Error when enriching network breadcrumb")}}function Lf(e){return e.category==="xhr"}function Df(e){return e.category==="fetch"}function Nf(e){return e&&e.xhr}function Pf(e){return e&&e.response}var Vo=null;function Ff(e){return!!e.category}var Bf=e=>t=>{if(!e.isEnabled())return;let r=Hf(t);r&&Tt(e,r)};function Hf(e){let t=e.getLastBreadcrumb&&e.getLastBreadcrumb();return Vo===t||!t||(Vo=t,!Ff(t)||["fetch","xhr","sentry.event","sentry.transaction"].includes(t.category)||t.category.startsWith("ui."))?null:t.category==="console"?Uf(t):he(t)}function Uf(e){let t=e.data&&e.data.arguments;if(!Array.isArray(t)||t.length===0)return he(e);let r=!1,n=t.map(s=>{if(!s)return s;if(typeof s=="string")return s.length>sr?(r=!0,`${s.slice(0,sr)}\u2026`):s;if(typeof s=="object")try{let o=qr(s,7);return JSON.stringify(o).length>sr?(r=!0,`${JSON.stringify(o,null,2).slice(0,sr)}\u2026`):o}catch{}return s});return he({...e,data:{...e.data,arguments:n,...r?{_meta:{warnings:["CONSOLE_ARG_TRUNCATED"]}}:{}}})}function Wf(e){let t=me(),r=D();t.addScopeListener(Bf(e)),Ut(bd(e)),Ue(nf(e)),Af(e);let n=tf(e,!Yo(r));r&&r.addEventProcessor?r.addEventProcessor(n):Jr(n),Yo(r)&&(r.on("beforeSendEvent",Xd(e)),r.on("afterSendEvent",xi(e)),r.on("createDsc",s=>{let o=e.getSessionId();o&&e.isEnabled()&&e.recordingMode==="session"&&e.checkAndHandleExpiredSession()&&(s.replay_id=o)}),r.on("startTransaction",s=>{e.lastTransaction=s}),r.on("finishTransaction",s=>{e.lastTransaction=s}),r.on("beforeSendFeedback",(s,o)=>{let i=e.getSessionId();o&&o.includeReplay&&e.isEnabled()&&i&&s.contexts&&s.contexts.feedback&&(s.contexts.feedback.replay_id=i)}))}function Yo(e){return!!(e&&e.on)}async function zf(e){try{return Promise.all(Ir(e,[$f(z.performance.memory)]))}catch{return[]}}function $f(e){let{jsHeapSizeLimit:t,totalJSHeapSize:r,usedJSHeapSize:n}=e,s=Date.now()/1e3;return{type:"memory",name:"memory",start:s,end:s,data:{memory:{jsHeapSizeLimit:t,totalJSHeapSize:r,usedJSHeapSize:n}}}}function jf(e,t,r){let n,s,o,i=r&&r.maxWait?Math.max(r.maxWait,t):0;function a(){return c(),n=e(),n}function c(){s!==void 0&&clearTimeout(s),o!==void 0&&clearTimeout(o),s=o=void 0}function l(){return s!==void 0||o!==void 0?a():n}function u(){return s&&clearTimeout(s),s=setTimeout(a,t),i&&o===void 0&&(o=setTimeout(a,i)),n}return u.cancel=c,u.flush=l,u}function Gf(e){let t=!1;return(r,n)=>{if(!e.checkAndHandleExpiredSession()){U&&y.warn("[Replay] Received replay event after session expired.");return}let s=n||!t;t=!0,e.clickDetector&&md(e.clickDetector,r),e.addUpdate(()=>{if(e.recordingMode==="buffer"&&s&&e.setInitialState(),!ts(e,r,s))return!0;if(!s)return!1;if(Vf(e,s),e.session&&e.session.previousSessionId)return!0;if(e.recordingMode==="buffer"&&e.session&&e.eventBuffer){let o=e.eventBuffer.getEarliestTimestamp();o&&(te(`[Replay] Updating session start time to earliest event in buffer to ${new Date(o)}`,e.getOptions()._experiments.traceInternals),e.session.started=o,e.getOptions().stickySession&&es(e.session))}return e.recordingMode==="session"&&e.flush(),!0})}}function qf(e){let t=e.getOptions();return{type:M.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 Vf(e,t){!t||!e.session||e.session.segmentId!==0||ts(e,qf(e),!1)}function Yf(e,t,r,n){return jt($s(e,zs(e),n,r),[[{type:"replay_event"},e],[{type:"replay_recording",length:typeof t=="string"?new TextEncoder().encode(t).length:t.length},t]])}function Kf({recordingData:e,headers:t}){let r,n=`${JSON.stringify(t)}
@@ -337,4 +337,4 @@ ${t==="system"?`
337
337
  }
338
338
  }
339
339
  `),s.append(o),r.append(s),{get el(){return r}}}function Gp({formTitle:e,showBranding:t,showName:r,showEmail:n,isNameRequired:s,isEmailRequired:o,colorScheme:i,defaultName:a,defaultEmail:c,onClosed:l,onCancel:u,onSubmit:d,...f}){let p=null;function h(){g(),l&&l()}function g(){p&&(p.open=!1)}function b(){p&&(p.open=!0)}function m(){return p&&p.open===!0||!1}let{el:_,showError:w,hideError:C}=zp({showEmail:n,showName:r,isEmailRequired:o,isNameRequired:s,defaultName:a,defaultEmail:c,onSubmit:d,onCancel:u,...f});return p=q("dialog",{className:"dialog",open:!0,onClick:h},q("div",{className:"dialog__content",onClick:O=>{O.stopPropagation()}},q("h2",{className:"dialog__header"},e,t&&q("a",{className:"brand-link",target:"_blank",href:"https://sentry.io/welcome/",title:"Powered by Sentry",rel:"noopener noreferrer"},jp({colorScheme:i}).el)),_)),{get el(){return p},showError:w,hideError:C,open:b,close:g,checkIsOpen:m}}var Ar=16,na=17,qp="http://www.w3.org/2000/svg";function Vp(){let e=c=>De.document.createElementNS(qp,c),t=oe(e("svg"),{class:"success-icon",width:`${Ar}`,height:`${na}`,viewBox:`0 0 ${Ar} ${na}`,fill:"none"}),r=oe(e("g"),{clipPath:"url(#clip0_57_156)"}),n=oe(e("path"),{"fill-rule":"evenodd","clip-rule":"evenodd",d:"M3.55544 15.1518C4.87103 16.0308 6.41775 16.5 8 16.5C10.1217 16.5 12.1566 15.6571 13.6569 14.1569C15.1571 12.6566 16 10.6217 16 8.5C16 6.91775 15.5308 5.37103 14.6518 4.05544C13.7727 2.73985 12.5233 1.71447 11.0615 1.10897C9.59966 0.503466 7.99113 0.34504 6.43928 0.653721C4.88743 0.962403 3.46197 1.72433 2.34315 2.84315C1.22433 3.96197 0.462403 5.38743 0.153721 6.93928C-0.15496 8.49113 0.00346625 10.0997 0.608967 11.5615C1.21447 13.0233 2.23985 14.2727 3.55544 15.1518ZM4.40546 3.1204C5.46945 2.40946 6.72036 2.03 8 2.03C9.71595 2.03 11.3616 2.71166 12.575 3.92502C13.7883 5.13838 14.47 6.78405 14.47 8.5C14.47 9.77965 14.0905 11.0306 13.3796 12.0945C12.6687 13.1585 11.6582 13.9878 10.476 14.4775C9.29373 14.9672 7.99283 15.0953 6.73777 14.8457C5.48271 14.596 4.32987 13.9798 3.42502 13.075C2.52018 12.1701 1.90397 11.0173 1.65432 9.76224C1.40468 8.50718 1.5328 7.20628 2.0225 6.02404C2.5122 4.8418 3.34148 3.83133 4.40546 3.1204Z"}),s=oe(e("path"),{d:"M6.68775 12.4297C6.78586 12.4745 6.89218 12.4984 7 12.5C7.11275 12.4955 7.22315 12.4664 7.32337 12.4145C7.4236 12.3627 7.51121 12.2894 7.58 12.2L12 5.63999C12.0848 5.47724 12.1071 5.28902 12.0625 5.11098C12.0178 4.93294 11.9095 4.77744 11.7579 4.67392C11.6064 4.57041 11.4221 4.52608 11.24 4.54931C11.0579 4.57254 10.8907 4.66173 10.77 4.79999L6.88 10.57L5.13 8.56999C5.06508 8.49566 4.98613 8.43488 4.89768 8.39111C4.80922 8.34735 4.713 8.32148 4.61453 8.31498C4.51605 8.30847 4.41727 8.32147 4.32382 8.35322C4.23038 8.38497 4.14413 8.43484 4.07 8.49999C3.92511 8.63217 3.83692 8.81523 3.82387 9.01092C3.81083 9.2066 3.87393 9.39976 4 9.54999L6.43 12.24C6.50187 12.3204 6.58964 12.385 6.68775 12.4297Z"});t.appendChild(r).append(s,n);let o=e("defs"),i=oe(e("clipPath"),{id:"clip0_57_156"}),a=oe(e("rect"),{width:`${Ar}`,height:`${Ar}`,fill:"white",transform:"translate(0 0.5)"});return i.appendChild(a),o.appendChild(i),t.appendChild(o).appendChild(i).appendChild(a),{get el(){return t}}}function Yp({message:e,onRemove:t}){function r(){n&&(n.remove(),t&&t())}let n=q("div",{className:"success-message",onClick:r},Vp().el,e);return{el:n,remove:r}}function sa({shadow:e,options:{shouldCreateActor:t=!0,...r},attachTo:n}){let s,o,i=!1;function a(){if(e)try{let m=Yp({message:r.successMessageText,onRemove:()=>{_&&clearTimeout(_),u()}});if(!m.el)throw new Error("Unable to show success message");e.appendChild(m.el);let _=setTimeout(()=>{m&&m.remove()},5e3)}catch(m){y.error(m)}}async function c(m){if(!o)return;let _=[];if(r.isNameRequired&&!m.name&&_.push(r.nameLabel),r.isEmailRequired&&!m.email&&_.push(r.emailLabel),m.message||_.push(r.messageLabel),_.length>0){o.showError(`Please enter in the following required fields: ${_.join(", ")}`);return}if(!await Fp(o,m)){r.onSubmitError&&r.onSubmitError();return}g(),a(),r.onSubmitSuccess&&r.onSubmitSuccess()}function l(){let m=D(),_=m&&m.getIntegrationByName&&m.getIntegrationByName("Replay");_&&_.flush().catch(w=>{Le&&y.error(w)})}function u(){s&&s.show()}function d(){s&&s.hide()}function f(){s&&s.el&&s.el.remove()}function p(){try{if(o){o.open(),i=!0,r.onFormOpen&&r.onFormOpen(),l();return}let m=r.useSentryUser,_=me(),w=_&&_.getUser();if(o=Gp({colorScheme:r.colorScheme,showBranding:r.showBranding,showName:r.showName||r.isNameRequired,showEmail:r.showEmail||r.isEmailRequired,isNameRequired:r.isNameRequired,isEmailRequired:r.isEmailRequired,formTitle:r.formTitle,cancelButtonLabel:r.cancelButtonLabel,submitButtonLabel:r.submitButtonLabel,emailLabel:r.emailLabel,emailPlaceholder:r.emailPlaceholder,messageLabel:r.messageLabel,messagePlaceholder:r.messagePlaceholder,nameLabel:r.nameLabel,namePlaceholder:r.namePlaceholder,isRequiredLabel:r.isRequiredLabel,defaultName:m&&w&&w[m.name]||"",defaultEmail:m&&w&&w[m.email]||"",onClosed:()=>{u(),i=!1,r.onFormClose&&r.onFormClose()},onCancel:()=>{h(),u()},onSubmit:c}),!o.el)throw new Error("Unable to open Feedback dialog");e.appendChild(o.el),d(),r.onFormOpen&&r.onFormOpen(),l()}catch(m){y.error(m)}}function h(){o&&(o.close(),i=!1,r.onFormClose&&r.onFormClose())}function g(){if(o){h();let m=o.el;m&&m.remove(),o=void 0}}function b(){i||p(),d()}return n?n.addEventListener("click",b):t&&(s=Up({buttonLabel:r.buttonLabel,onClick:b}),s.el&&e.appendChild(s.el)),{get actor(){return s},get dialog(){return o},showActor:u,hideActor:d,removeActor:f,openDialog:p,closeDialog:h,removeDialog:g}}var Or=De.document,Kp=e=>new Mt(e),Mt=class e{static __initStatic(){this.id="Feedback"}constructor({autoInject:t=!0,id:r="sentry-feedback",isEmailRequired:n=!1,isNameRequired:s=!1,showBranding:o=!0,showEmail:i=!0,showName:a=!0,useSentryUser:c={email:"email",name:"username"},themeDark:l,themeLight:u,colorScheme:d="system",buttonLabel:f=Sp,cancelButtonLabel:p=bp,submitButtonLabel:h=vp,formTitle:g=Ep,emailPlaceholder:b=wp,emailLabel:m=Ip,messagePlaceholder:_=kp,messageLabel:w=Cp,namePlaceholder:C=xp,nameLabel:O=Tp,isRequiredLabel:I=Rp,successMessageText:S=Mp,onFormClose:R,onFormOpen:$,onSubmitError:v,onSubmitSuccess:x}={}){this.name=e.id,this._host=null,this._shadow=null,this._widget=null,this._widgets=new Set,this._hasInsertedActorStyles=!1,this.options={autoInject:t,showBranding:o,id:r,isEmailRequired:n,isNameRequired:s,showEmail:i,showName:a,useSentryUser:c,colorScheme:d,themeDark:{...ea.dark,...l},themeLight:{...ea.light,...u},buttonLabel:f,cancelButtonLabel:p,submitButtonLabel:h,formTitle:g,emailLabel:m,emailPlaceholder:b,messageLabel:w,messagePlaceholder:_,nameLabel:O,namePlaceholder:C,isRequiredLabel:I,successMessageText:S,onFormClose:R,onFormOpen:$,onSubmitError:v,onSubmitSuccess:x}}setupOnce(){if(lt())try{this._cleanupWidgetIfExists();let{autoInject:t}=this.options;if(!t)return;this._createWidget(this.options)}catch(t){Le&&y.error(t)}}openDialog(){this._widget||this._createWidget({...this.options,shouldCreateActor:!1}),this._widget&&this._widget.openDialog()}closeDialog(){this._widget&&this._widget.closeDialog()}attachTo(t,r){try{let n=ta(this.options,r||{});return this._ensureShadowHost(n,({shadow:s})=>{let o=typeof t=="string"?Or.querySelector(t):typeof t.addEventListener=="function"?t:null;if(!o)return Le&&y.error("[Feedback] Unable to attach to target element"),null;let i=sa({shadow:s,options:n,attachTo:o});return this._widgets.add(i),this._widget||(this._widget=i),i})}catch(n){return Le&&y.error(n),null}}createWidget(t){try{return this._createWidget(ta(this.options,t||{}))}catch(r){return Le&&y.error(r),null}}removeWidget(t){if(!t)return!1;try{if(this._widgets.has(t))return t.removeActor(),t.removeDialog(),this._widgets.delete(t),this._widget===t&&(this._widget=null),!0}catch(r){Le&&y.error(r)}return!1}getWidget(){return this._widget}remove(){this._host&&this._host.remove(),this._initialize()}_initialize(){this._host=null,this._shadow=null,this._widget=null,this._widgets=new Set,this._hasInsertedActorStyles=!1}_cleanupWidgetIfExists(){this._host&&this.remove();let t=Or.querySelector(`#${this.options.id}`);t&&t.remove()}_createWidget(t){return this._ensureShadowHost(t,({shadow:r})=>{let n=sa({shadow:r,options:t});return!this._hasInsertedActorStyles&&n.actor&&(r.appendChild(Lp(Or)),this._hasInsertedActorStyles=!0),this._widgets.add(n),this._widget||(this._widget=n),n})}_ensureShadowHost(t,r){let n=!1;if(!this._shadow||!this._host){let{id:o,colorScheme:i,themeLight:a,themeDark:c}=t,{shadow:l,host:u}=Pp({id:o,colorScheme:i,themeLight:a,themeDark:c});this._shadow=l,this._host=u,n=!0}this._host.dataset.sentryFeedbackColorscheme=t.colorScheme;let s=r({shadow:this._shadow,host:this._host});return n&&Or.body.appendChild(this._host),s}};Mt.__initStatic();k();function At(e){return new Promise((t,r)=>{e.oncomplete=e.onsuccess=()=>t(e.result),e.onabort=e.onerror=()=>r(e.error)})}function Xp(e,t){let r=indexedDB.open(e);r.onupgradeneeded=()=>r.result.createObjectStore(t);let n=At(r);return s=>n.then(o=>s(o.transaction(t,"readwrite").objectStore(t)))}function la(e){return At(e.getAllKeys())}function Jp(e,t,r){return e(n=>la(n).then(s=>{if(!(s.length>=r))return n.put(t,Math.max(...s,0)+1),At(n.transaction)}))}function Zp(e){return e(t=>la(t).then(r=>{if(r.length!==0)return At(t.get(r[0])).then(n=>(t.delete(r[0]),At(t.transaction).then(()=>n)))}))}function Qp(e){let t;function r(){return t==null&&(t=Xp(e.dbName||"sentry-offline",e.storeName||"queue")),t}return{insert:async n=>{try{let s=await Us(n,e.textEncoder);await Jp(r(),s,e.maxQueueSize||30)}catch{}},pop:async()=>{try{let n=await Zp(r());if(n)return Ws(n,e.textEncoder||new TextEncoder,e.textDecoder||new TextDecoder)}catch{}}}}function eh(e){return t=>e({...t,createStore:Qp})}function th(e){return eh(eo(e))}k();k();var ua=1e6,Lr=String(0),rh="main",pa="",ha="",ma="",us=E.navigator&&E.navigator.userAgent||"",ga="",nh=E.navigator&&E.navigator.language||E.navigator&&E.navigator.languages&&E.navigator.languages[0]||"";function sh(e){return typeof e=="object"&&e!==null&&"getHighEntropyValues"in e}var da=E.navigator&&E.navigator.userAgentData;sh(da)&&da.getHighEntropyValues(["architecture","model","platform","platformVersion","fullVersionList"]).then(e=>{if(pa=e.platform||"",ma=e.architecture||"",ga=e.model||"",ha=e.platformVersion||"",e.fullVersionList&&e.fullVersionList.length>0){let t=e.fullVersionList[e.fullVersionList.length-1];us=`${t.brand} ${t.version}`}}).catch(e=>{});function oh(e){return!("thread_metadata"in e)}function ih(e){return oh(e)?lh(e):e}function ah(e){let t=e&&e.contexts&&e.contexts.trace&&e.contexts.trace.trace_id;return typeof t=="string"&&t.length!==32&&T&&y.log(`[Profiling] Invalid traceId: ${t} on profiled event`),typeof t!="string"?"":t}function ch(e,t,r,n){if(n.type!=="transaction")throw new TypeError("Profiling events may only be attached to transactions, this should never occur.");if(r==null)throw new TypeError(`Cannot construct profiling event envelope without a valid profile. Got ${r} instead.`);let s=ah(n),o=ih(r),i=t||(typeof n.start_timestamp=="number"?n.start_timestamp*1e3:Date.now()),a=typeof n.timestamp=="number"?n.timestamp*1e3:Date.now();return{event_id:e,timestamp:new Date(i).toISOString(),platform:"javascript",version:"1",release:n.release||"",environment:n.environment||Ys,runtime:{name:"javascript",version:E.navigator.userAgent},os:{name:pa,version:ha,build_number:us},device:{locale:nh,model:ga,manufacturer:us,architecture:ma,is_emulator:!1},debug_meta:{images:uh(r.resources)},profile:o,transactions:[{name:n.transaction||"",id:n.event_id||Be(),trace_id:s,active_thread_id:Lr,relative_start_ns:"0",relative_end_ns:((a-i)*1e6).toFixed(0)}]}}function Dr(e){return e.op==="pageload"}function lh(e){let t,r=0,n={samples:[],stacks:[],frames:[],thread_metadata:{[Lr]:{name:rh}}};if(!e.samples.length)return n;let s=e.samples[0].timestamp,o=typeof performance.timeOrigin=="number"?performance.timeOrigin:ut||0,i=o-(ut||o);for(let a=0;a<e.samples.length;a++){let c=e.samples[a];if(c.stackId===void 0){t===void 0&&(t=r,n.stacks[t]=[],r++),n.samples[a]={elapsed_since_start_ns:((c.timestamp+i-s)*ua).toFixed(0),stack_id:t,thread_id:Lr};continue}let l=e.stacks[c.stackId],u=[];for(;l;){u.push(l.frameId);let f=e.frames[l.frameId];n.frames[l.frameId]===void 0&&(n.frames[l.frameId]={function:f.name,abs_path:typeof f.resourceId=="number"?e.resources[f.resourceId]:void 0,lineno:f.line,colno:f.column}),l=l.parentId===void 0?void 0:e.stacks[l.parentId]}let d={elapsed_since_start_ns:((c.timestamp+i-s)*ua).toFixed(0),stack_id:r,thread_id:Lr};n.stacks[r]=u,n.samples[a]=d,r++}return n}function ya(e,t){if(!t.length)return e;for(let r of t)e[1].push([{type:"profile"},r]);return e}function _a(e){let t=[];return Hs(e,(r,n)=>{if(n==="transaction")for(let s=1;s<r.length;s++){let o=r[s];o&&o.contexts&&o.contexts.profile&&o.contexts.profile.profile_id&&t.push(r[s])}}),t}var fa=new WeakMap;function uh(e){let t=Se._sentryDebugIds;if(!t)return[];let r=D(),n=r&&r.getOptions(),s=n&&n.stackParser;if(!s)return[];let o,i=fa.get(s);i?o=i:(o=new Map,fa.set(s,o));let a=Object.keys(t).reduce((l,u)=>{let d,f=o.get(u);f?d=f:(d=s(u),o.set(u,d));for(let p=d.length-1;p>=0;p--){let h=d[p],g=h&&h.filename;if(h&&g){l[g]=t[u];break}}return l},{}),c=[];for(let l of e)l&&a[l]&&c.push({type:"sourcemap",code_file:l,debug_id:a[l]});return c}function dh(e){return typeof e!="number"&&typeof e!="boolean"||typeof e=="number"&&isNaN(e)?(T&&y.warn(`[Profiling] Invalid sample rate. Sample rate must be a boolean or a number between 0 and 1. Got ${JSON.stringify(e)} of type ${JSON.stringify(typeof e)}.`),!1):e===!0||e===!1?!0:e<0||e>1?(T&&y.warn(`[Profiling] Invalid sample rate. Sample rate must be between 0 and 1. Got ${e}.`),!1):!0}function fh(e){return e.samples.length<2?(T&&y.log("[Profiling] Discarding profile because it contains less than 2 samples"),!1):e.frames.length?!0:(T&&y.log("[Profiling] Discarding profile because it contains no frames"),!1)}var Sa=!1,ds=3e4;function ph(e){return typeof e=="function"}function ba(){let e=E.Profiler;if(!ph(e)){T&&y.log("[Profiling] Profiling is not supported by this browser, Profiler interface missing on window object.");return}let t=10,r=Math.floor(ds/t);try{return new e({sampleInterval:t,maxBufferSize:r})}catch{T&&(y.log("[Profiling] Failed to initialize the Profiling constructor, this is likely due to a missing 'Document-Policy': 'js-profiling' header."),y.log("[Profiling] Disabling profiling for current user session.")),Sa=!0}}function Ot(e){if(Sa)return T&&y.log("[Profiling] Profiling has been disabled for the duration of the current user session."),!1;if(!e.isRecording())return T&&y.log("[Profiling] Discarding profile because transaction was not sampled."),!1;let t=D(),r=t&&t.getOptions();if(!r)return T&&y.log("[Profiling] Profiling disabled, no options found."),!1;let n=r.profilesSampleRate;return dh(n)?n?(n===!0?!0:Math.random()<n)?!0:(T&&y.log(`[Profiling] Discarding profile because it's not included in the random sample (sampling rate = ${Number(n)})`),!1):(T&&y.log("[Profiling] Discarding profile because a negative sampling decision was inherited or profileSampleRate is set to 0"),!1):(T&&y.warn("[Profiling] Discarding profile because of invalid sample rate."),!1)}function va(e,t,r,n){return fh(r)?ch(e,t,r,n):null}var Ne=new Map;function Ea(){return Ne.size}function wa(e){let t=Ne.get(e);return t&&Ne.delete(e),t}function Ia(e,t){if(Ne.set(e,t),Ne.size>30){let r=Ne.keys().next().value;Ne.delete(r)}}function hh(e){return e?Ot(e)?Nr(e):e:(T&&y.log("[Profiling] Transaction is undefined, skipping profiling"),e)}function Nr(e){let t;Dr(e)&&(t=Bs()*1e3);let r=ba();if(!r)return e;T&&y.log(`[Profiling] started profiling transaction: ${be(e).description}`);let n=Be();async function s(){return!e||!r?null:r.stop().then(c=>(o&&(E.clearTimeout(o),o=void 0),T&&y.log(`[Profiling] stopped profiling of transaction: ${be(e).description}`),c?(Ia(n,c),null):(T&&y.log(`[Profiling] profiler returned null profile for: ${be(e).description}`,"this may indicate an overlapping transaction or a call to stopProfiling with a profile title that was never started"),null))).catch(c=>(T&&y.log("[Profiling] error while stopping profiler:",c),null))}let o=E.setTimeout(()=>{T&&y.log("[Profiling] max profile duration elapsed, stopping profiling for:",be(e).description),s()},ds),i=e.end.bind(e);function a(){return e?(s().then(()=>{e.setContext("profile",{profile_id:n,start_timestamp:t}),i()},()=>{i()}),e):i()}return e.end=a,e}k();var ka="BrowserProfiling",mh=()=>({name:ka,setupOnce(){},setup(e){let r=me().getTransaction();if(r&&Dr(r)&&Ot(r)&&Nr(r),typeof e.on!="function"){y.warn("[Profiling] Client does not support hooks, profiling will be disabled");return}e.on("startTransaction",n=>{Ot(n)&&Nr(n)}),e.on("beforeEnvelope",n=>{if(!Ea())return;let s=_a(n);if(!s.length)return;let o=[];for(let i of s){let a=i&&i.contexts,c=a&&a.profile&&a.profile.profile_id,l=a&&a.profile&&a.profile.start_timestamp;if(typeof c!="string"){T&&y.log("[Profiling] cannot find profile for a transaction without a profile context");continue}if(!c){T&&y.log("[Profiling] cannot find profile for a transaction without a profile context");continue}a&&a.profile&&delete a.profile;let u=wa(c);if(!u){T&&y.log(`[Profiling] Could not retrieve profile for transaction: ${c}`);continue}let d=va(c,l,u,i);d&&o.push(d)}ya(n,o)})}}),Ca=mh,gh=Q(ka,Ca);var xa={};E.Sentry&&E.Sentry.Integrations&&(xa=E.Sentry.Integrations);var zg={...xa,...no,...Sn};export{fn as Breadcrumbs,pt as BrowserClient,gh as BrowserProfilingIntegration,Cc as BrowserTracing,hn as Dedupe,Mt as Feedback,Ec as FunctionToString,mn as GlobalHandlers,gn as HttpContext,Xa as Hub,vc as InboundFilters,zg as Integrations,yn as LinkedErrors,bc as ModuleMetadata,Ct as Replay,_p as ReplayCanvas,Ka as SDK_VERSION,dc as SEMANTIC_ATTRIBUTE_SENTRY_OP,fc as SEMANTIC_ATTRIBUTE_SENTRY_ORIGIN,uc as SEMANTIC_ATTRIBUTE_SENTRY_SAMPLE_RATE,Xr as SEMANTIC_ATTRIBUTE_SENTRY_SOURCE,Ya as Scope,_n as TryCatch,E as WINDOW,le as addBreadcrumb,Jr as addEventProcessor,Oa as addGlobalEventProcessor,mc as addIntegration,pc as addTracingExtensions,Qt as breadcrumbsIntegration,nr as browserApiErrorsIntegration,Ca as browserProfilingIntegration,xc as browserTracingIntegration,Mc as captureConsoleIntegration,qt as captureEvent,ze as captureException,La as captureMessage,Yt as captureSession,ql as captureUserFeedback,co as chromeStackLineParser,ja as close,Da as configureScope,Bc as contextLinesIntegration,lc as continueTrace,ft as createTransport,cn as createUserFeedbackEnvelope,Ac as debugIntegration,Oc as dedupeIntegration,To as defaultIntegrations,Ic as defaultRequestInstrumentationOptions,fo as defaultStackLineParsers,dn as defaultStackParser,Va as endSession,on as eventFromException,an as eventFromMessage,Xt as exceptionFromError,Lc as extraErrorDataIntegration,ec as extractTraceparentData,Kp as feedbackIntegration,$a as flush,zl as forceLoad,Qr as functionToStringIntegration,lo as geckoStackLineParser,cc as getActiveSpan,Qa as getActiveTransaction,D as getClient,Kr as getCurrentHub,me as getCurrentScope,Ro as getDefaultIntegrations,Za as getHubFromCarrier,op as getReplay,tc as getSpanStatusFromHttpCode,er as globalHandlersIntegration,Fc as httpClientIntegration,tr as httpContextIntegration,Zr as inboundFiltersIntegration,Ul as init,kc as instrumentOutgoingRequests,qa as isInitialized,Ga as lastEventId,rr as linkedErrorsIntegration,th as makeBrowserOfflineTransport,ln as makeFetchTransport,Ja as makeMain,yc as makeMultiplexedTransport,un as makeXHRTransport,wc as metrics,Sc as moduleMetadataIntegration,$l as onLoad,hh as onProfilingStartRouteTransaction,ll as opera10StackLineParser,fl as opera11StackLineParser,_c as parameterize,Ji as replayCanvasIntegration,np as replayIntegration,Dc as reportingObserverIntegration,Nc as rewriteFramesIntegration,aa as sendFeedback,Pc as sessionTimingIntegration,Yr as setContext,gc as setCurrentClient,Pa as setExtra,Na as setExtras,nc as setHttpStatus,hc as setMeasurement,Ba as setTag,Fa as setTags,Ha as setUser,Wl as showReportDialog,rc as spanStatusfromHttpCode,Rc as startBrowserTracingNavigationSpan,Tc as startBrowserTracingPageLoadSpan,ac as startInactiveSpan,Vt as startSession,oc as startSpan,ic as startSpanManual,za as startTransaction,sc as trace,uo as winjsStackLineParser,Wa as withActiveSpan,Ua as withIsolationScope,dt as withScope,jl as wrap};
340
- //# sourceMappingURL=esm-TM36DY7C.js.map
340
+ //# sourceMappingURL=esm-VD4TZ367.js.map