1!function(){try{var e="u">typeof window?window:"u">typeof global?global:"u">typeof globalThis?globalThis:"u">typeof self?self:{},t=(new e.Error).stack;t&&(e._sentryDebugIds=e._sentryDebugIds||{},e._sentryDebugIds[t]="6987de1f-b9fd-4456-92a0-8e1eadc184e4",e._sentryDebugIdIdentifier="sentry-dbid-6987de1f-b9fd-4456-92a0-8e1eadc184e4")}catch(e){}}(),(self.webpackChunk_N_E=self.webpackChunk_N_E||[]).push([[1130],{76002:()=>{!function(){"use strict";let e,t,r,n,i,s,a;function o(e,t,r,n,i,s,a){try{var o=e[s](a),l=o.value}catch(e){return void r(e)}o.done?t(l):Promise.resolve(l).then(n,i)}function l(e){return function(){var t=this,r=arguments;return new Promise(function(n,i){var s=e.apply(t,r);function a(e){o(s,n,i,a,l,"next",e)}function l(e){o(s,n,i,a,l,"throw",e)}a(void 0)})}}function h(){return(h=Object.assign?Object.assign.bind():function(e){for(var t=1;arguments.length>t;t++){var r=arguments[t];for(var n in r)({}).hasOwnProperty.call(r,n)&&(e[n]=r[n])}return e}).apply(null,arguments)}var u,d=["type"],c=Object.defineProperty,p=(e,t,r)=>{let n;return(n="symbol"!=typeof t?t+"":t)in e?c(e,n,{enumerable:!0,configurable:!0,writable:!0,value:r}):e[n]=r},f=((e=f||{})[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=((t=m||{})[t.Mutation=0]="Mutation",t[t.MouseMove=1]="MouseMove",t[t.MouseInteraction=2]="MouseInteraction",t[t.Scroll=3]="Scroll",t[t.ViewportResize=4]="ViewportResize",t[t.Input=5]="Input",t[t.TouchMove=6]="TouchMove",t[t.MediaInteraction=7]="MediaInteraction",t[t.StyleSheetRule=8]="StyleSheetRule",t[t.CanvasMutation=9]="CanvasMutation",t[t.Font=10]="Font",t[t.Log=11]="Log",t[t.Drag=12]="Drag",t[t.StyleDeclaration=13]="StyleDeclaration",t[t.Selection=14]="Selection",t[t.AdoptedStyleSheet=15]="AdoptedStyleSheet",t[t.CustomElement=16]="CustomElement",t),v=((r=v||{})[r.MouseUp=0]="MouseUp",r[r.MouseDown=1]="MouseDown",r[r.Click=2]="Click",r[r.ContextMenu=3]="ContextMenu",r[r.DblClick=4]="DblClick",r[r.Focus=5]="Focus",r[r.Blur=6]="Blur",r[r.TouchStart=7]="TouchStart",r[r.TouchMove_Departed=8]="TouchMove_Departed",r[r.TouchEnd=9]="TouchEnd",r[r.TouchCancel=10]="TouchCancel",r),g=((n=g||{})[n.Mouse=0]="Mouse",n[n.Pen=1]="Pen",n[n.Touch=2]="Touch",n),y=((i=y||{})[i["2D"]=0]="2D",i[i.WebGL=1]="WebGL",i[i.WebGL2=2]="WebGL2",i),b=((s=b||{})[s.Play=0]="Play",s[s.Pause=1]="Pause",s[s.Seeked=2]="Seeked",s[s.VolumeChange=3]="VolumeChange",s[s.RateChange=4]="RateChange",s),w=((a=w||{})[a.Document=0]="Document",a[a.DocumentType=1]="DocumentType",a[a.Element=2]="Element",a[a.Text=3]="Text",a[a.CDATA=4]="CDATA",a[a.Comment=5]="Comment",a);function S(e,t){return -1!==e.indexOf(t)}var k={Node:["childNodes","parentNode","parentElement","textContent"],ShadowRoot:["host","styleSheets"],Element:["shadowRoot"],MutationObserver:[]},_={Node:["contains","getRootNode"],ShadowRoot:["getSelection"],Element:["querySelector","querySelectorAll"],MutationObserver:["constructor"]},I={};function M(e){if(I[e])return I[e];var t=((u=null==(h=null==(l=null==globalThis?void 0:globalThis.Zone)?void 0:l.__symbol__)?void 0:h.call(l,e))&&globalThis[u]?globalThis[u]:void 0)||globalThis[e],r=t.prototype,n=e in k?k[e]:void 0,i=!!(n&&n.every(e=>{var t,n;return!!(null==(n=null==(t=Object.getOwnPropertyDescriptor(r,e))?void 0:t.get)?void 0:n.toString().includes("[native code]"))})),s=e in _?_[e]:void 0,a=!!(s&&s.every(e=>{var t;return"function"==typeof r[e]&&(null==(t=r[e])?void 0:t.toString().includes("[native code]"))}));if(i&&a)return I[e]=t.prototype,t.prototype;var o=document.createElement("iframe");o.style.display="none";var l,h,u,d,c=!1;try{document.body.appendChild(o);var p=o.contentWindow;if(!p)return t.prototype;var f=p[e].prototype;return f?(S(d=navigator.userAgent,"AppleWebKit")&&!S(d,"Chrome")&&(o.classList.add("rr-block","ph-no-capture"),o.setAttribute("__rrwebUntaintedPrototype",e),c=!0),I[e]=f):r}catch(e){return r}finally{!c&&o.parentNode&&document.body.removeChild(o)}}var C={};function R(e,t,r){var n,i=e+"."+String(r);if(C[i])return C[i].call(t);var s=null==(n=Object.getOwnPropertyDescriptor(M(e),r))?void 0:n.get;return s?(C[i]=s,s.call(t)):t[r]}var E={};function T(e,t,r){var n=e+"."+String(r);if(E[n])return E[n].bind(t);var i=M(e)[r];return"function"!=typeof i?t[r]:(E[n]=i,i.bind(t))}function x(e,t,r){try{if(!(t in e))return()=>{};var n=e[t],i={next:n},s=r(function(){for(var e=arguments.length,t=Array(e),r=0;e>r;r++)t[r]=arguments[r];return i.next.apply(this,t)});return"function"==typeof s&&(s.prototype=s.prototype||{},Object.defineProperties(s,{__rrweb_original__:{enumerable:!1,value:n},__rrweb_layer__:{enumerable:!1,value:i}}
1)),e[t]=s,()=>{if(e[t]!==s)for(var r=e[t];"function"==typeof r&&r.__rrweb_layer__;){var n=r.__rrweb_layer__;if(n.next===s)return void(n.next=i.next);r=n.next}else e[t]=i.next}}catch(e){return()=>{}}}var A=e=>R("Node",e,"childNodes"),L=e=>R("Node",e,"parentNode"),O=(e,t)=>T("Node",e,"contains")(t),D=e=>e&&"host"in e?R("ShadowRoot",e,"host"):null,N=e=>e&&"shadowRoot"in e?R("Element",e,"shadowRoot"):null,F=()=>({durationMs:0,stylesheetMs:0,nodeCount:0,cssRuleCount:0,nonDeferrableCssRuleCount:0,deferredStylesheetCount:0});function P(){try{if("u">typeof performance&&performance.now)return performance.now()}catch(e){}return Date.now()}var H=0,B=0;function W(){H+=1}function z(e,t){return(t!==H||e>6e4)&&(B+=1,!0)}var U=0,q=0,$=0,j=F(),G=null,V=null,Z=[],X=0,J=0,Y={slowestBatchMs:0},Q={deferredCount:0,failedCount:0,abandonedCount:0,totalMs:0,slowestSliceMs:0};function K(e){(U+=1)>1||(j=F(),Z=[],X=0,V=e&&e>0?e:null,q=P(),$=H)}function ee(){return 0===U?G||F():(U-=1)>0?j:(j.durationMs=P()-q,j.deferredStylesheetCount=X,Q.deferredCount+=X,V=null,z(j.durationMs,$)?j:G=j)}function et(e,t,r){var n=e.length;if(r>=32)return n;for(var i=0;e.length>i;i++){var s=e[i];try{var a=s.cssRules;if(a&&a.length)n+=et(a,t,r+1);else if(t&&s.styleSheet){var o=s.styleSheet;if(!t.has(o)){t.add(o);var l=o.rules||o.cssRules;l&&(n+=et(l,t,r+1))}}}catch(e){}}return n}function er(e){if(0!==U){var t=et(e,null,0);j.cssRuleCount+=t,J>0&&(j.nonDeferrableCssRuleCount+=t)}}function en(e){J+=1;try{return e()}finally{J-=1}}function ei(e){U>0&&(j.stylesheetMs+=e)}function es(e){if(0===U||null===V)return!1;var t=j.cssRuleCount-j.nonDeferrableCssRuleCount;return t>=V||t+function(e){try{var t=e&&(e.rules||e.cssRules);if(!t)return 0;var r=new WeakSet;return r.add(e),et(t,r,0)}catch(e){return 0}}(e)>V}function ea(){Q.failedCount+=1}function eo(e){e>0&&(Q.abandonedCount+=e)}function el(e){return e.nodeType===e.ELEMENT_NODE}function eh(e){var t=e&&"host"in e&&"mode"in e&&D(e)||null;return!!(t&&"shadowRoot"in t&&N(t)===e)}function eu(e){return"[object ShadowRoot]"===({}).toString.call(e)}function ed(e){return e.includes(" background-clip: text;")&&!e.includes(" -webkit-background-clip: text;")&&(e=e.replace(/\sbackground-clip:\s*text;/g," -webkit-background-clip: text; background-clip: text;")),e}function ec(e){var t=e.cssText;if(3>t.split('"').length)return t;var 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(" ")+";"}var ep=0;function ef(e){var t=0===ep,r=t?P():0;ep+=1;try{var n=e.rules||e.cssRules;if(!n)return null;er(n);var i=e.href;return!i&&e.ownerNode&&(i=e.ownerNode.baseURI),ed(Array.from(n,e=>em(e,i)).join(""))}catch(e){return null}finally{ep-=1,t&&ei(P()-r)}}function em(e,t){if(eg(e)){try{n=ef(e.styleSheet)||ec(e)}catch(t){n=e.cssText}try{if(n&&(null==(r=e.styleSheet)?void 0:r.href))return eL(n,e.styleSheet.href)}catch(e){}return n}var r,n,i=e.cssText;return ey(e)&&e.selectorText.includes(":")&&(i=ev(i)),t?eL(i,t):i}function ev(e){return e.replace(/(\[(?:[\w-]+)[^\\])(:(?:[\w-]+)\])/gm,"$1\\$2")}function eg(e){return"styleSheet"in e}function ey(e){return"selectorText"in e}var eb=/^-?[A-Za-z_][\w-]*$/,ew=/^-?[A-Za-z_][\w-]*(\.-?[A-Za-z_][\w-]*)*$/;class eS{constructor(){p(this,"idNodeMap",new Map),p(this,"nodeMetaMap",new WeakMap)}getId(e){if(!e)return -1;var t,r=null==(t=this.getMeta(e))?void 0:t.id;return null!=r?r:-1}getNode(e){return this.idNodeMap.get(e)||null}getIds(){return Array.from(this.idNodeMap.keys())}getMeta(e){return this.nodeMetaMap.get(e)||null}removeNodeFromMap(e){var t=this.getId(e);if(this.idNodeMap.delete(t),e.childNodes&&e.childNodes.forEach(e=>this.removeNodeFromMap(e)),el(e)){var r=N(e);r&&this.removeNodeFromMap(r),"IFRAME"===e.nodeName&&e.contentDocument&&this.removeNodeFromMap(e.contentDocument)}}has(e){return this.idNodeMap.has(e)}hasNode(e){return this.nodeMetaMap.has(e)}add(e,t){this.idNodeMap.set(t.id,e),this.nodeMetaMap.set(e,t)}replace(e,t){var r=this.getNode(e);if(r){var n=this.nodeMetaMap.get(r);n&&this.nodeMetaMap.set(t,n)}this.idNodeMap.set(e,t)}reset(){this.idNodeMap=new Map,this.nodeMetaMap=new WeakMap}}function ek(e){var t=e.element,r=e.maskInputOptions,n=e.tagName,i=e.type,s=e.maskInputFn,a=e.value||"",o=i&&e_(i);return(r[n.toLowerCase()]||o&&r[o])&&(a=s?s(a,t):"*".repeat(a.length)),a}function e_(e){return e.toLowerCase()}var eI=new Set(["rr_width","rr_height","rr_left","rr_top","rr_position","rr_transform","rr_display","rr_scrollleft","rr_scrolltop","rr_mediastate","rr_open_mode"]);function eM(e){var t=e.element,r=e.name,n=e.value,i=e.maskAttributeFn,s=e.isGenerated;return n?e.maskAllElementAttributes?void 0!==s&&s&&eI.has(e_(r))?n:"*".repeat(n.length):i?i(r,n,t):n:n}var eC="__rrweb_original__";function eR(e){try{var t=e.type;return e.hasAttribute("data-rr-is-password")?"password":t?e_(t):null}catch(e){return null}}var eE=/url\((?:(')([^']*)'|(")(.*?)"|([^)]*))\)/gm,eT=/^(?:[a-z+]+:)?\/\//i,ex=/^www\..*/i,eA=/^(data:)([^,]*),(.*)/i;function eL(e,t){return(e||"").replace(eE,(e,r,n,i,s,a)=>{var o=n||s||a,l=r||i||"";if(!o)return e;
1if(eT.test(o)||ex.test(o)||eA.test(o))return"url("+l+o+l+")";if("/"===o[0])return"url("+l+((t.indexOf("//")>-1?t.split("/").slice(0,3).join("/"):t.split("/")[0]).split("?")[0]+o)+l+")";var h=t.split("/"),u=o.split("/");for(var d of(h.pop(),u))"."!==d&&(".."===d?h.pop():h.push(d));return"url("+l+h.join("/")+l+")"})}var eO,eD,eN=new Map,eF=1,eP=RegExp("[^a-z0-9-_:]");function eH(){return eF++}var eB=/^[^ \t\n\r\u000c]+/,eW=/^[, \t\n\r\u000c]+/,ez=new WeakMap;function eU(e,t){return t&&""!==t.trim()?eq(e,t):t}function eq(e,t){var r=ez.get(e);if(r||(r=e.createElement("a"),ez.set(e,r)),t){if(t.startsWith("blob:")||t.startsWith("data:"))return t}else t="";return r.setAttribute("href",t),r.href}function e$(e,t){var r;return(null==t?void 0:t.maxBase64ImageLength)?(r=t.maxBase64ImageLength)&&e.length>r?"data:image/svg+xml;base64,PHN2ZyB3aWR0aD0iMTAwJSIgaGVpZ2h0PSIxMDAlIiB4bWxucz0iaHR0cDovL3d3dy53My5vcmcvMjAwMC9zdmciPgogIDxkZWZzPgogICAgPHBhdHRlcm4gaWQ9InN0cmlwZXMiIHBhdHRlcm5Vbml0cz0idXNlclNwYWNlT25Vc2UiIHdpZHRoPSIxNiIgaGVpZ2h0PSIxNiI+CiAgICAgIDxyZWN0IHdpZHRoPSIxNiIgaGVpZ2h0PSIxNiIgZmlsbD0iYmxhY2siLz4KICAgICAgPHBhdGggZD0iTTggMEgxNkwwIDE2VjhMOCAwWiIgZmlsbD0iIzJEMkQyRCIvPgogICAgICA8cGF0aCBkPSJNMTYgOFYxNkg4TDE2IDhaIiBmaWxsPSIjMkQyRDJEIi8+CiAgICA8L3BhdHRlcm4+CiAgPC9kZWZzPgogIDxyZWN0IHdpZHRoPSIxMDAlIiBoZWlnaHQ9IjEwMCUiIGZpbGw9InVybCgjc3RyaXBlcykiLz4KPC9zdmc+Cg==":e:e}function ej(e,t,r,n,i,s){var a;if(!n)return n;if("src"===r||"href"===r&&("use"!==t||"#"!==n[0])){if("link"===t&&i){var o=null==(a=i.sheet)?void 0:a.href;if(o)return o}var l=eU(e,n);if(l.startsWith("data:")){if("img"===t&&i){var h=l;return((null==s?void 0:s.type)||void 0!==(null==s?void 0:s.quality))&&(h=function(e,t,r,n){if(1e5>t.length||!e.complete||0===e.naturalWidth||e.naturalWidth>4096||e.naturalHeight>4096)return t;var i=eN.get(t);if(i&&i.type===r&&i.quality===n)return i.result;try{var s=document.createElement("canvas");s.width=e.naturalWidth,s.height=e.naturalHeight;var a=s.getContext("2d");if(!a)return t;a.drawImage(e,0,0);var o=s.toDataURL(r||"image/webp",null!=n?n:.4),l=t.length>o.length?o:t;if(eN.size>=10){var h=eN.keys().next().value;void 0!==h&&eN.delete(h)}return eN.set(t,{type:r,quality:n,result:l}),l}catch(e){return t}}(i,l,s.type,s.quality)),e$(h,s)}if("image"===t)return e$(l,s)}return l}if("xlink:href"===r&&"#"!==n[0]){var u=eU(e,n);return"image"===t&&u.startsWith("data:")?e$(u,s):u}return"background"!==r||"table"!==t&&"td"!==t&&"th"!==t?"srcset"===r?function(e,t){if(""===t.trim())return t;var r=0;function n(e){var n,i=e.exec(t.substring(r));return i?(r+=(n=i[0]).length,n):""}for(var i=[];n(eW),t.length>r;){var s=n(eB);if(","===s.slice(-1))s=eU(e,s.substring(0,s.length-1)),i.push(s);else{var a="";s=eU(e,s);for(var o=!1;;){var l=t.charAt(r);if(""===l){i.push((s+a).trim());break}if(o)")"===l&&(o=!1);else{if(","===l){r+=1,i.push((s+a).trim());break}"("===l&&(o=!0)}a+=l,r+=1}}}return i.join(", ")}(e,n):"style"===r?eL(n,eq(e)):"object"===t&&"data"===r?eU(e,n):n:eU(e,n)}function eG(e,t,r){return("video"===e||"audio"===e)&&"autoplay"===t}function eV(e,t,r){if(!e)return!1;if(e.nodeType!==e.ELEMENT_NODE)return!!r&&eV(L(e),t,r);for(var n=e.classList.length;n--;)if(t.test(e.classList[n]))return!0;return!!r&&eV(L(e),t,r)}function eZ(e,t,r,n){var i;if(el(e)){if(!A(i=e).length)return!1}else{if(null===R("Node",e,"parentElement"))return!1;i=R("Node",e,"parentElement")}try{if("string"==typeof t){if(n){if(i.closest("."+t))return!0}else if(i.classList.contains(t))return!0}else if(eV(i,t,n))return!0;if(r){if(n){if(i.closest(r))return!0}else if(i.matches(r))return!0}}catch(e){}return!1}function eX(e,t,r){var n=e.removeEventListener;"function"==typeof n&&n.call(e,t,r)}var eJ=new Map;function eY(e,t){return Array.from(e.styleSheets).find(e=>e.href===t)}function eQ(e){return null==e?"":e.toLowerCase()}var eK=!1,e0=!1;function e1(e,t){var r=t.doc,n=t.mirror,i=t.blockClass,s=t.blockSelector,a=t.maskTextClass,o=t.maskTextSelector,l=t.skipChild,h=void 0!==l&&l,u=t.inlineStylesheet,d=void 0===u||u,c=t.maskInputOptions,p=void 0===c?{}:c,f=t.maskTextFn,m=t.maskInputFn,v=t.maskAllElementAttributes,g=void 0!==v&&v,y=t.maskAttributeFn,b=t.slimDOMOptions,S=t.dataURLOptions,k=void 0===S?{}:S,_=t.inlineImages,I=void 0!==_&&_,M=t.recordCanvas,C=void 0!==M&&M,E=t.canvasMaskingConfigured,T=t.onSerialize,x=t.onIframeLoad,O=t.iframeLoadTimeout,D=void 0===O?5e3:O,F=t.onIframeListenerRegistered,P=t.onStylesheetLoad,H=t.stylesheetLoadTimeout,B=void 0===H?5e3:H,W=t.keepIframeSrcFn,z=void 0===W?()=>!1:W,q=t.newlyAddedElement,$=t.depth,G=void 0===$?0:$,V=t.maxDepth,J=void 0===V?50:V,Y=t.needsMask,Q=t.preserveWhiteSpace,K=void 0===Q||Q;if(G>=J)return e0=!0,eK||(eK=!0,console.warn("[rrweb-snapshot] DOM tree depth exceeded max depth of "+J+". Children beyond this depth will not be recorded. This may indicate deeply nested DOM structures.")),null;Y||(Y=eZ(e,a,o,void 0===Y)),U>0&&(j.nodeCount+=1);var ee,et=function(e,t){var r=t.doc,n=t.blockClass,i=t.blockSelector,s=t.needsMask,a=t.inlineStylesheet,o=t.maskInputOptions,l=t.maskTextFn,h=t.maskInputFn,u=t.maskAllElementAttributes,d=t.maskAttributeFn,c=t.dataURLOptions,p=t.inlineImages,f=t.recordCanvas,m=t.canvasMaskingConfigured,v=t.keepIframeSrcFn,g=t.newlyAddedElement,y=function(e,t){if(t.hasNode(e)){var r=t.getId(e);return 1===r?void 0:r}}(r,t.mirror);switch(e.nodeType){case e.DOCUMENT_NODE:return"CSS1Compat"!==e.compatMode?{type:w.Document,childNodes:[],compatMode:e.compatMode}:{type:w.Document,childNodes:[]};case e.DOCUMENT_TYPE_NODE:return{type:w.DocumentType,name:e.name,publicId:e.publicId,systemId:e.systemId,rootId:y};case e.ELEMENT_NODE:return function(e,t){for(var r,n,i,s=t.doc,a=t.inlineStylesheet,o=t.maskInputOptions,l=void 0===o?{}:o,h=t.maskInputFn,u=t.maskAllElementAttributes,d=void 0!==u&&u,c=t.maskAttributeFn,p=t.dataURLOptions,f=void 0===p?{}:p,m=t.inlineImages,v=t.recordCanvas,g=t.canvasMaskingConfigured,y=t.keepIframeSrcFn,b=t.newlyAddedElement,S=t.rootId,k=function(e,t,r){try{if("string"==typeof t){if(e.classList.contains(t))return!0}else for(var n=e.classList.length;n--;)if(t.test(e.classList[n]))return!0;
1if(r)return e.matches(r)}catch(e){}return!1}(e,t.blockClass,t.blockSelector),_=function(e){if(e instanceof HTMLFormElement)return"form";var t=e_(e.tagName);return eP.test(t)?"div":t}(e),I=new Set,M={},C=e.attributes.length,E=0;C>E;E++){var T=e.attributes[E];eG(_,T.name)||(M[T.name]=ej(s,_,e_(T.name),T.value,e,f))}if("link"===_&&a&&!k){var x=e.sheet;if(!x){var A=e.href;A&&!(x=eY(s,A))&&A.includes(".css")&&(x=eY(s,window.location.origin+"/"+A.replace(window.location.href,"")))}var L=null;x&&(es(x)?U>0&&(Z.push(e),X+=1):L=ef(x)),L&&(delete M.rel,delete M.href,M._cssText=L)}if("style"===_&&e.sheet&&!(e.innerText||R("Node",e,"textContent")||"").trim().length){var O=en(()=>ef(e.sheet));O&&(M._cssText=O)}if("input"===_||"textarea"===_||"select"===_){var D=e.value,N=e.checked;"radio"!==M.type&&"checkbox"!==M.type&&"submit"!==M.type&&"button"!==M.type&&D?M.value=ek({element:e,type:eR(e),tagName:_,value:D,maskInputOptions:l,maskInputFn:h}):N&&(M.checked=N)}if("option"===_&&(e.selected&&!l.select?M.selected=!0:delete M.selected),"dialog"===_&&e.open){try{M.rr_open_mode=e.matches("dialog:modal")?"modal":"non-modal"}catch(e){M.rr_open_mode="modal",M.ph_rr_could_not_detect_modal=!0}I.add("rr_open_mode")}if("canvas"===_&&v&&!(null==g?void 0:g())){if("2d"===e.__context)(function(e){var t=e.getContext("2d");if(!t)return!0;for(var r=0;e.width>r;r+=50)for(var n=0;e.height>n;n+=50){var i=t.getImageData;if(new Uint32Array((eC in i?i[eC]:i).call(t,r,n,Math.min(50,e.width-r),Math.min(50,e.height-n)).data.buffer).some(e=>0!==e))return!1}return!0})(e)||(M.rr_dataURL=e.toDataURL(f.type,f.quality));else if(!("__context"in e)){var F=e.toDataURL(f.type,f.quality),P=s.createElement("canvas");P.width=e.width,P.height=e.height,F!==P.toDataURL(f.type,f.quality)&&(M.rr_dataURL=F)}}var H,B=!1;if("img"===_&&m){eO||(eD=(eO=s.createElement("canvas")).getContext("2d"));var W=e.currentSrc||e.getAttribute("src")||"<unknown-src>",z=e.crossOrigin,q=(t,r)=>B?eM({element:e,name:t,value:r,maskAllElementAttributes:d,maskAttributeFn:c}):r,$=()=>{eX(e,"load",$);try{eO.width=e.naturalWidth,eO.height=e.naturalHeight,eD.drawImage(e,0,0);var t=eO.toDataURL(f.type,f.quality);M.rr_dataURL=q("rr_dataURL",t)}catch(t){if("anonymous"!==e.crossOrigin)return e.crossOrigin="anonymous",void(e.complete&&0!==e.naturalWidth?$():e.addEventListener("load",$));console.warn("Cannot inline img src="+W+"! Error: "+t)}"anonymous"===e.crossOrigin&&(z?M.crossOrigin=q("crossOrigin",z):e.removeAttribute("crossorigin"))};e.complete&&0!==e.naturalWidth?$():e.addEventListener("load",$)}if("audio"===_||"video"===_){var j=M;j.rr_mediaState=e.paused?"paused":"played",I.add("rr_mediaState"),j.rr_mediaCurrentTime=e.currentTime,j.rr_mediaPlaybackRate=e.playbackRate,j.rr_mediaMuted=e.muted,j.rr_mediaLoop=e.loop,j.rr_mediaVolume=e.volume}if(void 0!==b&&b||(e.scrollLeft&&(M.rr_scrollLeft=e.scrollLeft),e.scrollTop&&(M.rr_scrollTop=e.scrollTop)),k){var G=e.getBoundingClientRect(),V=G.width,J=G.height,Y=G.left,Q=G.top,K=null==(r=s.defaultView)?void 0:r.getComputedStyle(e);M={class:M.class,rr_width:V+"px",rr_height:J+"px",rr_left:Math.floor(Y+((null==(n=s.defaultView)?void 0:n.scrollX)||0))+"px",rr_top:Math.floor(Q+((null==(i=s.defaultView)?void 0:i.scrollY)||0))+"px"},I.add("rr_width"),I.add("rr_height"),I.add("rr_left"),I.add("rr_top"),K&&(M.rr_position=K.position||"static",I.add("rr_position"),K.transform&&"none"!==K.transform&&(M.rr_transform=K.transform,I.add("rr_transform")),K.display&&K.display.startsWith("inline")&&(M.rr_display=K.display,I.add("rr_display")))}if("iframe"!==_||y(M.src)||(e.contentDocument||(M.rr_src=M.src),delete M.src),d||c)for(var ee of Object.entries(M)){var et=ee[0],er=ee[1];"string"!=typeof er&&null!==er||(M[et]=eM({element:e,name:et,value:er,maskAllElementAttributes:d,maskAttributeFn:c,isGenerated:I.has(et)}))}B=!0;try{customElements.get(_)&&(H=!0)}catch(e){}return{type:w.Element,tagName:_,attributes:M,childNodes:[],isSVG:!!("svg"===e.tagName||e.ownerSVGElement)||void 0,needBlock:k,rootId:S,isCustom:H}}(e,{doc:r,blockClass:n,blockSelector:i,inlineStylesheet:a,maskInputOptions:void 0===o?{}:o,maskInputFn:h,maskAllElementAttributes:void 0!==u&&u,maskAttributeFn:d,dataURLOptions:void 0===c?{}:c,inlineImages:p,recordCanvas:f,canvasMaskingConfigured:m,keepIframeSrcFn:v,newlyAddedElement:void 0!==g&&g,rootId:y});case e.TEXT_NODE:return function(e,t){var r,n=t.needsMask,i=t.maskTextFn,s=t.rootId,a=L(e),o=a&&a.tagName,l=R("Node",e,"textContent"),h="STYLE"===o||void 0,u="SCRIPT"===o||void 0;if(h&&l){try{if(e.nextSibling||e.previousSibling);else if(es(a.sheet));else if(null==(r=a.sheet)?void 0:r.cssRules){var d=ef(a.sheet);d&&!/(?:^|[\s;{}
1])-?[a-zA-Z][\w-]*\s*:\s*;/.test(d)&&(l=d)}}catch(t){console.warn("Cannot get CSS styles from text's parentNode. Error: "+t,e)}l=eL(l,eq(t.doc))}return u&&(l="SCRIPT_PLACEHOLDER"),!h&&!u&&l&&n&&(l=i?i(l,R("Node",e,"parentElement")):l.replace(/[\S]/g,"*")),{type:w.Text,textContent:l||"",isStyle:h,rootId:s}}(e,{doc:r,needsMask:s,maskTextFn:l,rootId:y});case e.CDATA_SECTION_NODE:return{type:w.CDATA,textContent:"",rootId:y};case e.COMMENT_NODE:return{type:w.Comment,textContent:R("Node",e,"textContent")||"",rootId:y};default:return!1}}(e,{doc:r,mirror:n,blockClass:i,blockSelector:s,needsMask:Y,inlineStylesheet:d,maskInputOptions:p,maskTextFn:f,maskInputFn:m,maskAllElementAttributes:g,maskAttributeFn:y,dataURLOptions:k,inlineImages:I,recordCanvas:C,canvasMaskingConfigured:E,keepIframeSrcFn:z,newlyAddedElement:void 0!==q&&q});if(!et)return console.warn(e,"not serialized"),null;ee=n.hasNode(e)?n.getId(e):!function(e,t){if(t.comment&&e.type===w.Comment)return!0;if(e.type===w.Element&&(t.script&&("script"===e.tagName||"link"===e.tagName&&("preload"===e.attributes.rel&&"script"===e.attributes.as||"modulepreload"===e.attributes.rel)||"link"===e.tagName&&"prefetch"===e.attributes.rel&&"string"==typeof e.attributes.href&&"js"===function(e){try{r=new URL(e,window.location.href)}catch(e){return null}var t,r,n=r.pathname.match(/\.([0-9a-z]+)(?:$)/i);return null!=(t=null==n?void 0:n[1])?t:null}(e.attributes.href))||t.headFavicon&&("link"===e.tagName&&"shortcut icon"===e.attributes.rel||"meta"===e.tagName&&(eQ(e.attributes.name).match(/^msapplication-tile(image|color)$/)||"application-name"===eQ(e.attributes.name)||["icon","apple-touch-icon","shortcut icon"].includes(eQ(e.attributes.rel))))||"meta"===e.tagName&&(t.headMetaDescKeywords&&eQ(e.attributes.name).match(/^description|keywords$/)||t.headMetaSocial&&(eQ(e.attributes.property).match(/^(og|twitter|fb):/)||eQ(e.attributes.name).match(/^(og|twitter):/)||"pinterest"===eQ(e.attributes.name))||t.headMetaRobots&&["robots","googlebot","bingbot"].includes(eQ(e.attributes.name))||t.headMetaHttpEquiv&&void 0!==e.attributes["http-equiv"]||t.headMetaAuthorship&&(["author","generator","framework","publisher","progid"].includes(eQ(e.attributes.name))||eQ(e.attributes.property).match(/^article:/)||eQ(e.attributes.property).match(/^product:/))||t.headMetaVerification&&["google-site-verification","yandex-verification","csrf-token","p:domain_verify","verify-v1","verification","shopify-checkout-api-token"].includes(eQ(e.attributes.name)))))return!0;return!1}(et,b)&&(K||et.type!==w.Text||et.isStyle||et.textContent.replace(/^\s+|\s+$/gm,"").length)?eH():-2;var er=Object.assign(et,{id:ee});if(n.add(e,er),-2===ee)return null;T&&T(e);var ei=!h;if(er.type===w.Element){ei=ei&&!er.needBlock,delete er.needBlock;var ea=N(e);ea&&eu(ea)&&(er.isShadowHost=!0)}if((er.type===w.Document||er.type===w.Element)&&ei){b.headWhitespace&&er.type===w.Element&&"head"===er.tagName&&(K=!1);var eo={doc:r,mirror:n,blockClass:i,blockSelector:s,needsMask:Y,maskTextClass:a,maskTextSelector:o,skipChild:h,inlineStylesheet:d,maskInputOptions:p,maskTextFn:f,maskInputFn:m,maskAllElementAttributes:g,maskAttributeFn:y,slimDOMOptions:b,dataURLOptions:k,inlineImages:I,recordCanvas:C,canvasMaskingConfigured:E,preserveWhiteSpace:K,onSerialize:T,onIframeLoad:x,iframeLoadTimeout:D,onIframeListenerRegistered:F,onStylesheetLoad:P,stylesheetLoadTimeout:B,keepIframeSrcFn:z,depth:G+1,maxDepth:J};if(er.type===w.Element&&"textarea"===er.tagName&&void 0!==er.attributes.value);else for(var ed of Array.from(A(e))){var ec=e1(ed,eo);ec&&er.childNodes.push(ec)}var ep=null;if(el(e)&&(ep=N(e)))for(var em of Array.from(A(ep))){var ev=e1(em,eo);ev&&(eu(ep)&&(ev.isShadow=!0),er.childNodes.push(ev))}}var eg=L(e);if(eg&&eh(eg)&&eu(eg)&&(er.isShadow=!0),er.type===w.Element&&"iframe"===er.tagName){var ey=function(e,t,r){var n,i=()=>{},s=e.contentWindow;if(!s)return i;try{n=s.document.readyState}catch(e){return i}var a=()=>t();if("complete"!==n){var o=!1,l=null,h=()=>{o||(o=!0,null!==l&&(clearTimeout(l),l=null),eX(e,"load",u),e.addEventListener("load",a),t())},u=()=>h();return l=setTimeout(h,r),e.addEventListener("load",u),()=>{null!==l&&(clearTimeout(l),l=null),o?eX(e,"load",a):(o=!0,eX(e,"load",u))}}var d,c="about:blank";try{d=s.location.href}catch(e){return i}if(d!==c||e.src===c||""===e.src){var p=setTimeout(t,0);return e.addEventListener("load",a),()=>{clearTimeout(p),eX(e,"load",a)}}return e.addEventListener("load",a),()=>{eX(e,"load",a)}}(e,()=>{var t=e.contentDocument;if(t&&x){var r=e1(t,{doc:t,mirror:n,blockClass:i,blockSelector:s,needsMask:Y,maskTextClass:a,maskTextSelector:o,skipChild:!1,inlineStylesheet:d,maskInputOptions:p,maskTextFn:f,maskInputFn:m,maskAllElementAttributes:g,maskAttributeFn:y,slimDOMOptions:b,dataURLOptions:k,inlineImages:I,recordCanvas:C,canvasMaskingConfigured:E,preserveWhiteSpace:K,onSerialize:T,onIframeLoad:x,iframeLoadTimeout:D,onIframeListenerRegistered:F,onStylesheetLoad:P,stylesheetLoadTimeout:B,keepIframeSrcFn:z,depth:G+1,maxDepth:J});r&&x(e,r)}},D);null==F||F(e,ey)}return er.type===w.Element&&"link"===er.tagName&&"stylesheet"===er.attributes.rel&&function(t,l){if(!eJ.has(t)){var h;try{h=t.sheet}catch(e){return}if(!h){var u=new AbortController,c=!1,v=()=>{if(!c){c=!0;try{if(P){var l=e1(e,{doc:r,mirror:n,blockClass:i,blockSelector:s,needsMask:Y,maskTextClass:a,maskTextSelector:o,skipChild:!1,inlineStylesheet:d,maskInputOptions:p,maskTextFn:f,maskInputFn:m,maskAllElementAttributes:g,maskAttributeFn:y,slimDOMOptions:b,dataURLOptions:k,inlineImages:I,recordCanvas:C,canvasMaskingConfigured:E,preserveWhiteSpace:K,onSerialize:T,onIframeLoad:x,iframeLoadTimeout:D,onStylesheetLoad:P,stylesheetLoadTimeout:B,keepIframeSrcFn:z,depth:G,maxDepth:J});l&&P(e,l)}
1}finally{eJ.delete(t),u.abort()}}},w=setTimeout(v,l);u.signal.addEventListener("abort",()=>clearTimeout(w),{once:!0}),t.addEventListener("load",v,{signal:u.signal,once:!0}),eJ.set(t,u)}}}(e,B),er}function e2(e){return!0===e||"all"===e?{script:!0,comment:!0,headFavicon:!0,headWhitespace:!0,headMetaSocial:!0,headMetaRobots:!0,headMetaHttpEquiv:!0,headMetaVerification:!0,headMetaAuthorship:"all"===e,headMetaDescKeywords:"all"===e,headTitleMutations:"all"===e}:!1===e?{}:e}class e3{constructor(){p(this,"parentElement",null),p(this,"parentNode",null),p(this,"ownerDocument"),p(this,"firstChild",null),p(this,"lastChild",null),p(this,"previousSibling",null),p(this,"nextSibling",null),p(this,"ELEMENT_NODE",1),p(this,"TEXT_NODE",3),p(this,"nodeType"),p(this,"nodeName"),p(this,"RRNodeType")}get childNodes(){for(var e=[],t=this.firstChild;t;)e.push(t),t=t.nextSibling;return e}contains(e){if(!(e instanceof e3)||e.ownerDocument!==this.ownerDocument)return!1;if(e===this)return!0;for(;e.parentNode;){if(e.parentNode===this)return!0;e=e.parentNode}return!1}appendChild(e){throw Error("RRDomException: Failed to execute 'appendChild' on 'RRNode': This RRNode type does not support this method.")}insertBefore(e,t){throw Error("RRDomException: Failed to execute 'insertBefore' on 'RRNode': This RRNode type does not support this method.")}removeChild(e){throw Error("RRDomException: Failed to execute 'removeChild' on 'RRNode': This RRNode type does not support this method.")}toString(){return"RRNode"}}function e5(e,t,r){void 0===r&&(r=document);var n={capture:!0,passive:!0};return r.addEventListener(e,t,n),()=>e4(r,e,t,n)}function e4(e,t,r,n){e8(()=>{var i=e.removeEventListener;"function"==typeof i&&(void 0!==n?i.call(e,t,r,n):i.call(e,t,r))})}function e8(e){try{e()}catch(e){if(!(e instanceof DOMException&&"SecurityError"===e.name))throw e}}var e6="Please stop import mirror directly. Instead of that,\r\nnow you can use replayer.getMirror() to access the mirror instance of a replayer,\r\nor you can use record.mirror to access the mirror instance during recording.",e9={map:{},getId:()=>(console.error(e6),-1),getNode:()=>(console.error(e6),null),removeNodeFromMap(){console.error(e6)},has:()=>(console.error(e6),!1),reset(){console.error(e6)}};function e7(e,t,r){void 0===r&&(r={});var n=null,i=0;return function(){for(var s=arguments.length,a=Array(s),o=0;s>o;o++)a[o]=arguments[o];var l=Date.now();i||!1!==r.leading||(i=l);var h=t-(l-i),u=this;0>=h||h>t?(n&&(clearTimeout(n),n=null),i=l,e.apply(u,a)):n||!1===r.trailing||(n=setTimeout(()=>{i=!1===r.leading?0:Date.now(),n=null,e.apply(u,a)},h))}}function te(e,t,r,n,i){void 0===i&&(i=window);var s=i.Object.getOwnPropertyDescriptor(e,t);return i.Object.defineProperty(e,t,n?r:{set(e){if(setTimeout(()=>{try{r.set.call(this,e)}catch(e){}},0),s&&s.set){if(s.get)try{s.get.call(this)}catch(e){return}s.set.call(this,e)}}}),()=>te(e,t,s||{},!0)}"u">typeof window&&window.Proxy&&window.Reflect&&(e9=new Proxy(e9,{get:(e,t,r)=>("map"===t&&console.error(e6),Reflect.get(e,t,r))}));var tt=Date.now;function tr(e){var t,r,n,i,s=e.document;return{left:s.scrollingElement?s.scrollingElement.scrollLeft:void 0!==e.pageXOffset?e.pageXOffset:s.documentElement.scrollLeft||(null==s?void 0:s.body)&&(null==(t=R("Node",s.body,"parentElement"))?void 0:t.scrollLeft)||(null==(r=null==s?void 0:s.body)?void 0:r.scrollLeft)||0,top:s.scrollingElement?s.scrollingElement.scrollTop:void 0!==e.pageYOffset?e.pageYOffset:(null==s?void 0:s.documentElement.scrollTop)||(null==s?void 0:s.body)&&(null==(n=R("Node",s.body,"parentElement"))?void 0:n.scrollTop)||(null==(i=null==s?void 0:s.body)?void 0:i.scrollTop)||0}}function tn(){return window.innerHeight||document.documentElement&&document.documentElement.clientHeight||document.body&&document.body.clientHeight}function ti(){return window.innerWidth||document.documentElement&&document.documentElement.clientWidth||document.body&&document.body.clientWidth}function ts(e){return e?e.nodeType===e.ELEMENT_NODE?e:R("Node",e,"parentElement"):null}function ta(e,t,r,n){if(!e)return!1;var i=ts(e);if(!i)return!1;try{if("string"==typeof t){if(i.classList.contains(t)||n&&null!==i.closest("."+t))return!0}else if(eV(i,t,n))return!0}catch(e){}return!!(r&&(i.matches(r)||n&&null!==i.closest(r)))||!1}function to(e,t,r){return!("TITLE"!==e.tagName||!r.headTitleMutations)||-2===t.getId(e)}function tl(e){return!!e.changedTouches}
1function th(e,t){return!!("IFRAME"===e.nodeName&&t.getMeta(e))}function tu(e,t){return!!("LINK"===e.nodeName&&e.nodeType===e.ELEMENT_NODE&&e.getAttribute&&"stylesheet"===e.getAttribute("rel")&&t.getMeta(e))}function td(e){return!!e&&(e instanceof e3&&"shadowRoot"in e?!!e.shadowRoot:!!N(e))}/[1-9][0-9]{12}/.test(Date.now().toString())||(tt=()=>(new Date).getTime());class tc{constructor(){p(this,"id",1),p(this,"styleIDMap",new WeakMap),p(this,"idStyleMap",new Map)}getId(e){var t;return null!=(t=this.styleIDMap.get(e))?t:-1}has(e){return this.styleIDMap.has(e)}add(e,t){var r;return this.has(e)?this.getId(e):(r=void 0===t?this.id++:t,this.styleIDMap.set(e,r),this.idStyleMap.set(r,e),r)}getStyle(e){return this.idStyleMap.get(e)||null}reset(){this.styleIDMap=new WeakMap,this.idStyleMap=new Map,this.id=1}generateId(){return this.id++}}function tp(e){var t,r=null;return"getRootNode"in e&&(null==(t=T("Node",e,"getRootNode")())?void 0:t.nodeType)===Node.DOCUMENT_FRAGMENT_NODE&&D(T("Node",e,"getRootNode")())&&(r=D(T("Node",e,"getRootNode")())),r}function tf(e){var t,r,n=e.ownerDocument;return!!n&&(O(n,e)||!!(r=(t=e).ownerDocument)&&O(r,function(e){for(var t,r=e;t=tp(r);)r=t;return r}(t)))}class tm{constructor(){p(this,"length",0),p(this,"head",null),p(this,"tail",null)}get(e){if(e>=this.length)throw Error("Position outside of list range");for(var t=this.head,r=0;e>r;r++)t=(null==t?void 0:t.next)||null;return t}addNode(e){var t={value:e,previous:null,next:null};if(e.__ln=t,e.previousSibling&&"__ln"in e.previousSibling){var r=e.previousSibling.__ln.next;t.next=r,t.previous=e.previousSibling.__ln,e.previousSibling.__ln.next=t,r&&(r.previous=t)}else if(e.nextSibling&&"__ln"in e.nextSibling&&e.nextSibling.__ln.previous){var n=e.nextSibling.__ln.previous;t.previous=n,t.next=e.nextSibling.__ln,e.nextSibling.__ln.previous=t,n&&(n.next=t)}else this.head&&(this.head.previous=t),t.next=this.head,this.head=t;null===t.next&&(this.tail=t),this.length++}removeNode(e){var t=e.__ln;this.head&&(t.previous?(t.previous.next=t.next,t.next?t.next.previous=t.previous:this.tail=t.previous):(this.head=t.next,this.head?this.head.previous=null:this.tail=null),e.__ln&&delete e.__ln,this.length--)}}class tv{constructor(){p(this,"frozen",!1),p(this,"locked",!1),p(this,"texts",[]),p(this,"attributes",[]),p(this,"attributeMap",new WeakMap),p(this,"generatedAttributes",new WeakMap),p(this,"removes",[]),p(this,"mapRemoves",[]),p(this,"movedMap",{}),p(this,"addedSet",new Set),p(this,"movedSet",new Set),p(this,"droppedSet",new Set),p(this,"removesSubTreeCache",new Set),p(this,"mutationCb"),p(this,"blockClass"),p(this,"blockSelector"),p(this,"maskTextClass"),p(this,"maskTextSelector"),p(this,"inlineStylesheet"),p(this,"maskInputOptions"),p(this,"maskTextFn"),p(this,"maskInputFn"),p(this,"maskAllElementAttributes"),p(this,"maskAttributeFn"),p(this,"keepIframeSrcFn"),p(this,"recordCanvas"),p(this,"canvasMaskingConfigured"),p(this,"inlineImages"),p(this,"slimDOMOptions"),p(this,"dataURLOptions"),p(this,"doc"),p(this,"mirror"),p(this,"iframeManager"),p(this,"stylesheetManager"),p(this,"shadowDomManager"),p(this,"canvasManager"),p(this,"processedNodeManager"),p(this,"unattachedDoc"),p(this,"canvasManagerReleased",!1),p(this,"processMutations",e=>{e.forEach(this.processMutation),this.emit()}),p(this,"emit",()=>{if(!this.frozen&&!this.locked){var e,t=P(),r=H;try{this.processBufferedMutations()}finally{e=P()-t,U>0||z(e,null!=r?r:H)||e>Y.slowestBatchMs&&(Y.slowestBatchMs=e)}}}),p(this,"processBufferedMutations",()=>{for(var e=[],t=new Set,r=new tm,n=e=>{for(var t=e,r=-2;-2===r;)r=(t=t&&t.nextSibling)&&this.mirror.getId(t);return r},i=i=>{var s=L(i);if(s&&tf(i)&&"TEXTAREA"!==s.tagName){var a=eh(s)?this.mirror.getId(tp(i)):this.mirror.getId(s),o=n(i);if(-1===a||-1===o)return r.addNode(i);var l=e1(i,{doc:this.doc,mirror:this.mirror,blockClass:this.blockClass,blockSelector:this.blockSelector,maskTextClass:this.maskTextClass,maskTextSelector:this.maskTextSelector,skipChild:!0,newlyAddedElement:!0,inlineStylesheet:this.inlineStylesheet,maskInputOptions:this.maskInputOptions,maskTextFn:this.maskTextFn,maskInputFn:this.maskInputFn,maskAllElementAttributes:this.maskAllElementAttributes,maskAttributeFn:this.maskAttributeFn,slimDOMOptions:this.slimDOMOptions,dataURLOptions:this.dataURLOptions,recordCanvas:this.recordCanvas,canvasMaskingConfigured:this.canvasMaskingConfigured,inlineImages:this.inl
1ineImages,onSerialize:e=>{th(e,this.mirror)&&this.iframeManager.addIframe(e),tu(e,this.mirror)&&this.stylesheetManager.trackLinkElement(e),td(i)&&this.shadowDomManager.addShadowRoot(N(i),this.doc)},onIframeLoad:(e,t)=>{this.iframeManager.attachIframe(e,t),this.shadowDomManager.observeAttachShadow(e)},onIframeListenerRegistered:(e,t)=>{this.iframeManager.registerLoadListenerDisposer(e,t)},onStylesheetLoad:(e,t)=>{this.stylesheetManager.attachLinkElement(e,t)}});l&&(e.push({parentId:a,nextId:o,node:l}),t.add(l.id))}};this.mapRemoves.length;)this.mirror.removeNodeFromMap(this.mapRemoves.shift());for(var s of this.movedSet)ty(this.removesSubTreeCache,s)&&!this.movedSet.has(L(s))||i(s);for(var a of this.addedSet)tb(this.droppedSet,a)||ty(this.removesSubTreeCache,a)?tb(this.movedSet,a)?i(a):this.droppedSet.add(a):i(a);for(var o=null;r.length;){var l=null;if(o){var h=this.mirror.getId(L(o.value)),u=n(o.value);-1!==h&&-1!==u&&(l=o)}if(!l)for(var d=r.tail;d;){var c=d;if(d=d.previous,c){var p=this.mirror.getId(L(c.value));if(-1===n(c.value))continue;if(-1!==p){l=c;break}var f=L(c.value);if(f&&f.nodeType===Node.DOCUMENT_FRAGMENT_NODE){var m=D(f);if(-1!==this.mirror.getId(m)){l=c;break}}}}if(!l){for(;r.head;)r.removeNode(r.head.value);break}o=l.previous,r.removeNode(l.value),i(l.value)}var v={texts:this.texts.map(e=>{var t=e.node,r=L(t);return r&&"TEXTAREA"===r.tagName&&this.genTextAreaValueMutation(r),{id:this.mirror.getId(t),value:e.value}}).filter(e=>!t.has(e.id)).filter(e=>this.mirror.has(e.id)),attributes:this.attributes.map(e=>{var t,r=e.attributes;if(!this.maskAllElementAttributes&&!this.maskAttributeFn&&"string"==typeof r.style){var n=JSON.stringify(e.styleDiff),i=JSON.stringify(e._unchangedStyles);r.style.length>n.length&&(n+i).split("var(").length===r.style.split("var(").length&&(r.style=e.styleDiff)}if(this.maskAllElementAttributes||this.maskAttributeFn)for(var s of Object.entries(r)){var a=s[0],o=s[1];"string"!=typeof o&&null!==o||(r[a]=eM({element:e.node,name:a,value:o,maskAllElementAttributes:this.maskAllElementAttributes,maskAttributeFn:this.maskAttributeFn,isGenerated:null==(t=this.generatedAttributes.get(e.node))?void 0:t.has(a)}))}return{id:this.mirror.getId(e.node),attributes:r}}).filter(e=>!t.has(e.id)).filter(e=>this.mirror.has(e.id)),removes:this.removes,adds:e};(v.texts.length||v.attributes.length||v.removes.length||v.adds.length)&&(this.texts=[],this.attributes=[],this.attributeMap=new WeakMap,this.generatedAttributes=new WeakMap,this.removes=[],this.addedSet=new Set,this.movedSet=new Set,this.droppedSet=new Set,this.removesSubTreeCache=new Set,this.movedMap={},this.mutationCb(v))}),p(this,"bufferBelongsToIframe",e=>this.doc===e.contentDocument),p(this,"genTextAreaValueMutation",e=>{var t=this.attributeMap.get(e);t||(this.attributes.push(t={node:e,attributes:{},styleDiff:{},_unchangedStyles:{}}),this.attributeMap.set(e,t));var r=Array.from(A(e),e=>R("Node",e,"textContent")||"").join("");t.attributes.value=ek({element:e,maskInputOptions:this.maskInputOptions,tagName:e.tagName,type:eR(e),value:r,maskInputFn:this.maskInputFn})}),p(this,"processMutation",e=>{var t;if(!to(e.target,this.mirror,this.slimDOMOptions))switch(e.type){case"characterData":var r=R("Node",e.target,"textContent");ta(e.target,this.blockClass,this.blockSelector,!1)||r===e.oldValue||this.texts.push({value:eZ(e.target,this.maskTextClass,this.maskTextSelector,!0)&&r?this.maskTextFn?this.maskTextFn(r,ts(e.target)):r.replace(/[\S]/g,"*"):r,node:e.target});break;case"attributes":var n,i=e.target,s=e.attributeName,a=null!=(n=e.attributeNamespace)?n:null,o=function(e,t,r){if(!r)return t;var n=e.getAttributeNodeNS(r,t);if(n)return n.name;if("http://www.w3.org/1999/xlink"===r)return"xlink:"+t;if("http://www.w3.org/XML/1998/namespace"===r)return"xml:"+t;if("http://www.w3.org/2000/xmlns/"===r)return"xmlns"===t?t:"xmlns:"+t;var i=e.lookupPrefix(r);return i?i+":"+t:t}(i,s,a),l=a?i.getAttributeNS(a,s):e.target.getAttribute(s);if("value"===o){var h=eR(i);l=ek({element:i,maskInputOptions:this.maskInputOptions,tagName:i.tagName,type:h,value:l,maskInputFn:this.maskInputFn})}if(ta(e.target,this.blockClass,this.blockSelector,!1)||l===e.oldValue)return;var u=this.attributeMap.get(e.target),d="IFRAME"===i.tagName&&"src"===o;if(d&&!this.keepIframeSrcFn(l)&&i.contentDocument)return;if(u||(this.attributes.push(u={node:e.target,attributes:{},styleDiff:{},_unchangedStyles:{}}),this.attributeMap.set(e.target,u)),"type"===o&&"INPUT"===i.tagName&&"password"===(e.oldValue||"").toLowerCase()&&i.setAttribute("data-rr-is-password","true"),!eG(i.tagName,o)){var c=ej(this.doc,e_(i.tagName),e_(o),l,i,this.dataURLOptions);if(d&&!this.keepIframeSrcFn(l)&&(o="rr_src"),u.attributes[o]=c,null==(t=this.generatedAttributes.get(e.target))||t.delete(o),"style"===o){if(!this.unattachedDoc)try{this.unattachedDoc=document.implementation.createHTMLDocument()}catch(e){this.unattachedDoc=this.doc}var p=this.unattachedDoc.createElement("span"),f=i.style;for(var m of(e.oldValue&&(p.style.cssText=e.oldValue),Array.from(f))){var v=f.getPropertyValue(m),g=f.getPropertyPriority(m);v!==p.style.getPropertyValue(m)||g!==p.style.getPropertyPriority(m)?u.styleDiff[m]=""===g?v:[v,g]:u._unchangedStyles[m]=[v,g]}for(var y of Array.from(p.style))""===f.getPropertyValue(y)&&(u.styleDiff[y]=!1)}else if("open"===o&&"DIALOG"===i.tagName){u.attributes.rr_open_mode=i.matches("dialog:modal")?"modal":"non-modal";var b=this.generatedAttributes.get(e.target);b||this.generatedAttributes.set(e.target,b=new Set),b.add("rr_open_mode")}}break;case"childList":if(ta(e.target,this.blockClass,this.blockSelector,!0))return;if("TEXTAREA"===e.target.tagName)return void this.genTextAreaValueMutation(e.target);
1e.addedNodes.forEach(t=>this.genAdds(t,e.target)),e.removedNodes.forEach(t=>{var r=this.mirror.getId(t),n=eh(e.target)?this.mirror.getId(D(e.target)):this.mirror.getId(e.target);ta(e.target,this.blockClass,this.blockSelector,!1)||to(t,this.mirror,this.slimDOMOptions)||-1===this.mirror.getId(t)||(this.addedSet.has(t)?(tg(this.addedSet,t),this.droppedSet.add(t)):this.addedSet.has(e.target)&&-1===r||function e(t,r){if(eh(t))return!1;var n=r.getId(t);if(!r.has(n))return!0;var i=L(t);return(!i||i.nodeType!==t.DOCUMENT_NODE)&&(!i||e(i,r))}(e.target,this.mirror)||(this.movedSet.has(t)&&this.movedMap[r+"@"+n]?tg(this.movedSet,t):(this.removes.push({parentId:n,id:r,isShadow:!(!eh(e.target)||!eu(e.target))||void 0}),function(e,t){for(var r=[e];r.length;){var n=r.pop();t.has(n)||(t.add(n),A(n).forEach(e=>r.push(e)))}}(t,this.removesSubTreeCache))),this.mapRemoves.push(t))})}}),p(this,"genAdds",(e,t)=>{if(!this.processedNodeManager.inOtherBuffer(e,this)){if(this.addedSet.has(e))return this.addedSet.delete(e),void this.addedSet.add(e);if(!this.movedSet.has(e)){if(this.mirror.hasNode(e)){if(to(e,this.mirror,this.slimDOMOptions))return;this.movedSet.add(e);var r=null;t&&this.mirror.hasNode(t)&&(r=this.mirror.getId(t)),r&&-1!==r&&(this.movedMap[this.mirror.getId(e)+"@"+r]=!0)}else this.addedSet.add(e),this.droppedSet.delete(e);ta(e,this.blockClass,this.blockSelector,!1)||(A(e).forEach(e=>this.genAdds(e)),td(e)&&A(N(e)).forEach(t=>{this.processedNodeManager.add(t,this),this.genAdds(t,e)}))}}})}init(e){["mutationCb","blockClass","blockSelector","maskTextClass","maskTextSelector","inlineStylesheet","maskInputOptions","maskTextFn","maskInputFn","maskAllElementAttributes","maskAttributeFn","keepIframeSrcFn","recordCanvas","canvasMaskingConfigured","inlineImages","slimDOMOptions","dataURLOptions","doc","mirror","iframeManager","stylesheetManager","shadowDomManager","canvasManager","processedNodeManager"].forEach(t=>{this[t]=e[t]}),this.canvasManager.acquire()}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.releaseCanvasManager()}releaseCanvasManager(){this.canvasManagerReleased||(this.canvasManagerReleased=!0,this.canvasManager.reset())}bufferDoc(){return this.doc}destroy(){for(;this.mapRemoves.length;)this.mirror.removeNodeFromMap(this.mapRemoves.shift())}}function tg(e,t){e.delete(t),A(t).forEach(t=>tg(e,t))}function ty(e,t,r){var n;return 0!==e.size&&!!(n=L(t))&&e.has(n)}function tb(e,t){return 0!==e.size&&function e(t,r){var n=L(r);return!!n&&(!!t.has(n)||e(t,n))}(e,t)}var tw=function(e,t){return void 0===t&&(t="rrweb"),tJ?function(){try{return e(...arguments)}catch(e){if(tJ&&!0===tJ(e,t))return;throw e}}:e},tS=[];function tk(e){try{if("composedPath"in e){var t=e.composedPath();if(t.length)return t[0]}else if("path"in e&&e.path.length)return e.path[0]}catch(e){}return e&&e.target}function t_(e,t){var r=new tv;tS.push(r),r.init(e);var n=new(M("MutationObserver")).constructor(tw(r.processMutations.bind(r))),i={attributes:!0,attributeOldValue:!0,characterData:!0,characterDataOldValue:!0,childList:!0,subtree:!0};return e.attributeFilter&&e.attributeFilter.length>0&&(i.attributeFilter=e.attributeFilter),n.observe(t,i),{observer:n,buffer:r}}function tI(e){var t=e.scrollCb,r=e.doc,n=e.mirror,i=e.blockClass,s=e.blockSelector,a=e.sampling,o=new Map,l=e=>{var a=tk(e);if(a&&!ta(a,i,s,!0)){var l,h,u=n.getId(a);if(a===r&&r.defaultView){var d=tr(r.defaultView);l=d.left,h=d.top}else l=a.scrollLeft,h=a.scrollTop;var c=l+","+h;o.get(u)!==c&&(o.set(u,c),t({id:u,x:l,y:h}))}},h=[e5("scroll",tw(e7(tw(e=>l(e)),a.scroll||100)),r)];return"onscrollend"in r&&h.push(e5("scrollend",tw(l),r)),()=>h.forEach(e=>e())}function tM(e,t){for(var r=tS.length-1;r>=0;r--){var n=tS[r];if(n){var i=n.bufferBelongsToIframe(e);!i&&t&&t.has(n.bufferDoc())&&(i=!0),i&&(n.reset(),tS.splice(r,1))}}}var tC=["INPUT","TEXTAREA","SELECT"],tR=new WeakMap;function tE(e){return function e(t,r){if(tL("CSSGroupingRule")&&t.parentRule instanceof CSSGroupingRule||tL("CSSMediaRule")&&t.parentRule instanceof CSSMediaRule||tL("CSSSupportsRule")&&t.parentRule instanceof CSSSupportsRule||tL("CSSConditionRule")&&t.parentRule instanceof CSSConditionRule){var n=Array.from(t.parentRule.cssRules).indexOf(t);return r.unshift(n),e(t.parentRule,r)}if(t.parentStyleSheet){var i=Array.from(t.parentStyleSheet.cssRules).indexOf(t);r.unshift(i)}return r}(e,[])}function tT(e,t,r){var n,i;return e?(e.ownerNode?n=t.getId(e.ownerNode):i=r.getId(e),{styleId:i,id:n}):{}}function tx(e,t){var r,n,i,s,a=e.stylesheetManager;s=e.mirror.getId("#document"===t.nodeName?t:D(t));var o="#document"===t.nodeName?null==(r=t.defaultView)?void 0:r.Document:null==(i=null==(n=t.ownerDocument)?void 0:n.defaultView)?void 0:i.ShadowRoot,l=(null==o?void 0:o.prototype)?Object.getOwnPropertyDescriptor(null==o?void 0:o.prototype,"adoptedStyleSheets"):void 0;return null!==s&&-1!==s&&o&&l?(Object.defineProperty(t,"adoptedStyleSheets",{configurable:l.configurable,enumerable:l.enumerable,get(){var e;return null==(e=l.get)?void 0:e.call(this)},set(e){var t,r;try{r=null==(t=l.set)?void 0:t.call(this,e)}catch(e){if(e&&"object"==typeof e&&"NotAllowedError"===e.name)return;throw e}if(null!==s&&-1!==s)try{a.adoptStyleSheets(e,s)}catch(e){}return r}}),tw(()=>{Object.defineProperty(t,"adoptedStyleSheets",{configurable:l.configurable,enumerable:l.enumerable,get:l.get,set:l.set})})):()=>{}}function tA(e,t){void 0===t&&(t={});var r,n,i,s,a,o,l,u,d,c,p,f,y,w,S,k,_,I,M=e.doc.defaultView;if(!M)return()=>{};if(E=t,T=e.mutationCb,A=e.mousemoveCb,L=e.mouseInteractionCb,O=e.scrollCb,D=e.viewportResizeCb,N=e.inputCb,F=e.mediaInteractionCb,P=e.styleSheetRuleCb,H=e.styleDeclarationCb,B=e.canvasMutationCb,W=e.fontCb,z=e.selectionCb,U=e.customElementCb,e.mutationCb=function(){E.mutation&&E.mutation(...arguments),T(...arguments)},e.mousemoveCb=function(){E.mousemove&&E.mousemove(...arguments),A(...arguments)},e.mouseInteractionCb=function(){E.mouseInteraction&&E.mouseInteraction(...arguments),L(...arguments)},e.scrollCb=function(){E.scroll&&E.scroll(...arguments),O(...arguments)},e.viewportResizeCb=function(){E.viewportResize&&E.viewportResize(...arguments),D(...arguments)},e.inputCb=function(){E.input&&E.input(...arguments),N(...arguments)},e.mediaInteractionCb=function(){E.mediaInteaction&&E.mediaInteaction(...arguments),F(...arguments)},e.styleSheetRuleCb=function(){E.styleSheetRule&&E.styleSheetRule(...arguments),P(...arguments)},e.styleDeclarationCb=function(){E.styleDeclaration&&E.styleDeclaration(...arguments),H(...arguments)},e.canvasMutationCb=function(){E.canvasMutation&&E.canvasMutation(...arguments),B(...arguments)},e.fontCb=function(){E.font&&E.font(...arguments),W(...arguments)},e.selectionCb=function(){E.selection&&E.selection(...arguments),z(...arguments)},e.customElementCb=function(){E.customElement&&E.customElement(...arguments),U(...arguments)},e.recordDOM){var C=t_(e,e.doc);_=C.observer,I=C.buffer}var E,T,A,L,O,D,N,F,P,H,B,W,z,U,q,$,j,G,V,Z,X,J,Y,Q,K,ee,et,er=function(e){var t=e.mousemoveCb,r=e.sampling,n=e.doc,i=e.mirror;if(!1===r.mousemove)return()=>{};var s,a="number"==typeof r.mousemove?r.mousemove:50,o="number"==typeof r.mousemoveCallback?r.mousemoveCallback:500,l=[],h=e7(tw(e=>{var r=Date.now()-s;t(l.map(e=>(e.timeOffset-=r,e)),e),l=[],s=null}),o),u=tw(e7(tw(e=>{var t=tk(e),r=tl(e)?e.changedTouches[0]:e,n=r.clientX,a=r.clientY;s||(s=tt()),l.push({x:n,y:a,id:i.getId(t),timeOffset:tt()-s}),h("u">typeof DragEvent&&e instanceof DragEvent?m.Drag:e instanceof MouseEvent?m.MouseMove:m.TouchMove)}),a,{trailing:!1})),d=[e5("mousemove",u,n),e5("touchmove",u,n),e5("drag",u,n)];return tw(()=>
1{d.forEach(e=>e())})}(e),en=function(e){var t=e.mouseInteractionCb,r=e.doc,n=e.mirror,i=e.blockClass,s=e.blockSelector,a=e.sampling;if(!1===a.mouseInteraction)return()=>{};var o=!0===a.mouseInteraction||void 0===a.mouseInteraction?{}:a.mouseInteraction,l=[],u=null;return Object.keys(v).filter(e=>Number.isNaN(Number(e))&&!e.endsWith("_Departed")&&!1!==o[e]).forEach(e=>{var a=e_(e),o=r=>{var a=tk(r);if(!ta(a,i,s,!0)){var o=null,l=e;if("pointerType"in r){switch(r.pointerType){case"mouse":o=g.Mouse;break;case"touch":o=g.Touch;break;case"pen":o=g.Pen}o===g.Touch&&(v[e]===v.MouseDown?l="TouchStart":v[e]===v.MouseUp&&(l="TouchEnd"))}else tl(r)&&(o=g.Touch);null!==o?(u=o,(l.startsWith("Touch")&&o===g.Touch||l.startsWith("Mouse")&&o===g.Mouse)&&(o=null)):v[e]===v.Click&&(o=u,u=null);var d=tl(r)?r.changedTouches[0]:r;if(d){var c=n.getId(a),p=d.clientX,f=d.clientY;tw(t)(h({type:v[l],id:c,x:p,y:f},null!==o&&{pointerType:o}))}}};if(window.PointerEvent)switch(v[e]){case v.MouseDown:case v.MouseUp:a=a.replace("mouse","pointer");break;case v.TouchStart:case v.TouchEnd:return}l.push(e5(a,o,r))}),tw(()=>{l.forEach(e=>e())})}(e),ei=tI(e),es=(q={win:M},$=e.viewportResizeCb,j=q.win,G=-1,V=-1,e5("resize",tw(e7(tw(()=>{var e=tn(),t=ti();G===e&&V===t||($({width:Number(t),height:Number(e)}),G=e,V=t)}),200)),j)),ea=function(e){var t=e.inputCb,r=e.doc,n=e.mirror,i=e.blockClass,s=e.blockSelector,a=e.ignoreClass,o=e.ignoreSelector,l=e.maskInputOptions,u=e.maskInputFn,d=e.userTriggeredOnInput;function c(e){var t=tk(e),n=e.isTrusted,h=r.defaultView;if(!t||!h||t instanceof h.HTMLElement){var c=t&&t.tagName;if(t&&"OPTION"===c&&(t=R("Node",t,"parentElement")),t&&c&&tC.indexOf(c)>=0&&!ta(t,i,s,!0)&&!(t.classList.contains(a)||o&&t.matches(o))){var f=t.value,m=!1,v=eR(t)||"";"radio"===v||"checkbox"===v?m=t.checked:(l[c.toLowerCase()]||l[v])&&(f=ek({element:t,maskInputOptions:l,tagName:c,type:v,value:f,maskInputFn:u})),p(t,d?{text:f,isChecked:m,userTriggered:n}:{text:f,isChecked:m});var g=t.name;"radio"===v&&g&&m&&r.querySelectorAll('input[type="radio"][name="'+g+'"]').forEach(e=>{if(e!==t){var r=e.value;p(e,d?{text:r,isChecked:!m,userTriggered:!1}:{text:r,isChecked:!m})}})}}}function p(e,r){var i=tR.get(e);if(!i||i.text!==r.text||i.isChecked!==r.isChecked){tR.set(e,r);var s=n.getId(e);tw(t)(h({},r,{id:s}))}}var f=("last"===e.sampling.input?["change"]:["input","change"]).map(e=>e5(e,tw(c),r)),m=r.defaultView;if(!m)return()=>{f.forEach(e=>e())};var v=m.Object.getOwnPropertyDescriptor(m.HTMLInputElement.prototype,"value");return v&&v.set&&f.push(...[[m.HTMLInputElement.prototype,"value"],[m.HTMLInputElement.prototype,"checked"],[m.HTMLSelectElement.prototype,"value"],[m.HTMLTextAreaElement.prototype,"value"],[m.HTMLSelectElement.prototype,"selectedIndex"],[m.HTMLOptionElement.prototype,"selected"]].map(e=>te(e[0],e[1],{set(){tw(c)({target:this,isTrusted:!1})}},!1,m))),tw(()=>{f.forEach(e=>e())})}(e),eo=(Z=e.mediaInteractionCb,X=e.blockClass,J=e.blockSelector,Y=e.mirror,Q=e.sampling,K=e.doc,et=[e5("play",(ee=tw(e=>e7(tw(t=>{var r=tk(t);if(r&&!ta(r,X,J,!0)){var n=r.currentTime,i=r.volume,s=r.muted,a=r.playbackRate,o=r.loop;Z({type:e,id:Y.getId(r),currentTime:n,volume:i,muted:s,playbackRate:a,loop:o})}}),Q.media||500)))(b.Play),K),e5("pause",ee(b.Pause),K),e5("seeked",ee(b.Seeked),K),e5("volumechange",ee(b.VolumeChange),K),e5("ratechange",ee(b.RateChange),K)],tw(()=>{et.forEach(e=>e())})),el=()=>{},eh=()=>{},eu=()=>{},ed=()=>{};e.recordDOM&&(el=function(e,t){var r=e.styleSheetRuleCb,n=e.mirror,i=e.stylesheetManager,s=t.win;if(!s.CSSStyleSheet||!s.CSSStyleSheet.prototype)return()=>{};var a=s.CSSStyleSheet.prototype.insertRule;s.CSSStyleSheet.prototype.insertRule=new Proxy(a,{apply:tw((e,t,s)=>{var a=s[0],o=s[1];i.onCssomSheetMutation(t);var l=tT(t,n,i.styleMirror),h=l.id,u=l.styleId;return(h&&-1!==h||u&&-1!==u)&&r({id:h,styleId:u,adds:[{rule:a,index:o}]}),e.apply(t,s)},"host")}),s.CSSStyleSheet.prototype.addRule=function(e,t,r){return void 0===r&&(r=this.cssRules.length),s.CSSStyleSheet.prototype.insertRule.apply(this,[e+" { "+t+" }",r])};var o,l,h=s.CSSStyleSheet.prototype.deleteRule;s.CSSStyleSheet.prototype.deleteRule=new Proxy(h,{apply:tw((e,t,s)=>{var a=s[0];i.onCssomSheetMutation(t);var o=tT(t,n,i.styleMirror),l=o.id,h=o.styleId;return(l&&-1!==l||h&&-1!==h)&&r({id:l,styleId:h,removes:[{index:a}]}),e.apply(t,s)},"host")}),s.CSSStyleSheet.prototype.removeRule=function(e){return s.CSSStyleSheet.prototype.deleteRule.apply(this,[e])}
1,s.CSSStyleSheet.prototype.replace&&(o=s.CSSStyleSheet.prototype.replace,s.CSSStyleSheet.prototype.replace=new Proxy(o,{apply:tw((e,t,s)=>{var a=s[0],o=tT(t,n,i.styleMirror),l=o.id,h=o.styleId;return(l&&-1!==l||h&&-1!==h)&&r({id:l,styleId:h,replace:a}),e.apply(t,s)},"host")})),s.CSSStyleSheet.prototype.replaceSync&&(l=s.CSSStyleSheet.prototype.replaceSync,s.CSSStyleSheet.prototype.replaceSync=new Proxy(l,{apply:tw((e,t,s)=>{var a=s[0],o=tT(t,n,i.styleMirror),l=o.id,h=o.styleId;return(l&&-1!==l||h&&-1!==h)&&r({id:l,styleId:h,replaceSync:a}),e.apply(t,s)},"host")}));var u={};tO("CSSGroupingRule")?u.CSSGroupingRule=s.CSSGroupingRule:(tO("CSSMediaRule")&&(u.CSSMediaRule=s.CSSMediaRule),tO("CSSConditionRule")&&(u.CSSConditionRule=s.CSSConditionRule),tO("CSSSupportsRule")&&(u.CSSSupportsRule=s.CSSSupportsRule));var d={};return Object.entries(u).forEach(e=>{var t=e[0],s=e[1];d[t]={insertRule:s.prototype.insertRule,deleteRule:s.prototype.deleteRule},s.prototype.insertRule=new Proxy(d[t].insertRule,{apply:tw((e,t,s)=>{var a=s[0],o=s[1];i.onCssomSheetMutation(t.parentStyleSheet);var l=tT(t.parentStyleSheet,n,i.styleMirror),h=l.id,u=l.styleId;return(h&&-1!==h||u&&-1!==u)&&r({id:h,styleId:u,adds:[{rule:a,index:[...tE(t),o||0]}]}),e.apply(t,s)},"host")}),s.prototype.deleteRule=new Proxy(d[t].deleteRule,{apply:tw((e,t,s)=>{var a=s[0];i.onCssomSheetMutation(t.parentStyleSheet);var o=tT(t.parentStyleSheet,n,i.styleMirror),l=o.id,h=o.styleId;return(l&&-1!==l||h&&-1!==h)&&r({id:l,styleId:h,removes:[{index:[...tE(t),a]}]}),e.apply(t,s)},"host")})}),tw(()=>{s.CSSStyleSheet.prototype.insertRule=a,s.CSSStyleSheet.prototype.deleteRule=h,o&&(s.CSSStyleSheet.prototype.replace=o),l&&(s.CSSStyleSheet.prototype.replaceSync=l),Object.entries(u).forEach(e=>{var t=e[0],r=e[1];r.prototype.insertRule=d[t].insertRule,r.prototype.deleteRule=d[t].deleteRule})})}(e,{win:M}),eh=tx(e,e.doc),r=e.styleDeclarationCb,n=e.mirror,i=e.ignoreCSSAttributes,s=e.stylesheetManager,o=(a=({win:M}).win).CSSStyleDeclaration.prototype.setProperty,a.CSSStyleDeclaration.prototype.setProperty=new Proxy(o,{apply:tw((e,t,a)=>{var l,h,u=a[0],d=a[1],c=a[2];
1if(i.has(u))return o.apply(t,[u,d,c]);s.onCssomSheetMutation(null==(l=t.parentRule)?void 0:l.parentStyleSheet);var p=tT(null==(h=t.parentRule)?void 0:h.parentStyleSheet,n,s.styleMirror),f=p.id,m=p.styleId;return(f&&-1!==f||m&&-1!==m)&&r({id:f,styleId:m,set:{property:u,value:d,priority:c},index:tE(t.parentRule)}),e.apply(t,a)},"host")}),l=a.CSSStyleDeclaration.prototype.removeProperty,a.CSSStyleDeclaration.prototype.removeProperty=new Proxy(l,{apply:tw((e,t,a)=>{var o,h,u=a[0];if(i.has(u))return l.apply(t,[u]);s.onCssomSheetMutation(null==(o=t.parentRule)?void 0:o.parentStyleSheet);var d=tT(null==(h=t.parentRule)?void 0:h.parentStyleSheet,n,s.styleMirror),c=d.id,p=d.styleId;return(c&&-1!==c||p&&-1!==p)&&r({id:c,styleId:p,remove:{property:u},index:tE(t.parentRule)}),e.apply(t,a)},"host")}),eu=tw(()=>{a.CSSStyleDeclaration.prototype.setProperty=o,a.CSSStyleDeclaration.prototype.removeProperty=l}),e.collectFonts&&(ed=function(e){var t=e.fontCb,r=e.doc,n=r.defaultView;if(!n)return()=>{};var i=[],s=new WeakMap,a=n.FontFace;n.FontFace=function(e,t,r){var n=new a(e,t,r);return s.set(n,{family:e,buffer:"string"!=typeof t,descriptors:r,fontSource:"string"==typeof t?t:JSON.stringify(Array.from(new Uint8Array(t)))}),n};var o=x(r.fonts,"add",function(e){return function(r){return setTimeout(tw(()=>{var e=s.get(r);e&&(t(e),s.delete(r))}),0),e.apply(this,[r])}});return i.push(()=>{n.FontFace=a}),i.push(o),tw(()=>{i.forEach(e=>e())})}(e)));var ec=(u=e.doc,d=e.mirror,c=e.blockClass,p=e.blockSelector,f=e.selectionCb,y=!0,(w=tw(()=>{var e=u.getSelection();if(!(!e||y&&(null==e?void 0:e.isCollapsed))){y=e.isCollapsed||!1;for(var t=[],r=e.rangeCount||0,n=0;r>n;n++){var i=e.getRangeAt(n),s=i.startContainer,a=i.startOffset,o=i.endContainer,l=i.endOffset;ta(s,c,p,!0)||ta(o,c,p,!0)||t.push({start:d.getId(s),startOffset:a,end:d.getId(o),endOffset:l})}f({ranges:t})}}))(),e5("selectionchange",w)),ep=(S=e.customElementCb,(k=e.doc.defaultView)&&k.customElements?x(k.customElements,"define",function(e){return function(t,r,n){try{S({define:{name:t}})}catch(e){console.warn("Custom element callback failed for "+t)}return e.apply(this,[t,r,n])}}):()=>{}),ef=[];for(var em of e.plugins)ef.push(em.observer(em.callback,M,em.options));return tw(()=>{if(I){I.destroy(),I.reset();var t=tS.indexOf(I);-1!==t&&tS.splice(t,1)}e.shadowDomManager.resetForDoc(e.doc),null==_||_.disconnect(),er(),en(),ei(),es(),ea(),eo(),el(),eh(),eu(),ed(),ec(),ep(),ef.forEach(e=>e())})}function tL(e){return void 0!==window[e]}function tO(e){return!!(void 0!==window[e]&&window[e].prototype&&"insertRule"in window[e].prototype&&"deleteRule"in window[e].prototype)}class tD{constructor(e){p(this,"iframeIdToRemoteIdMap",new WeakMap),p(this,"iframeRemoteIdToIdMap",new WeakMap),this.generateIdFn=e}getId(e,t,r,n){var i=r||this.getIdToRemoteIdMap(e),s=n||this.getRemoteIdToIdMap(e),a=i.get(t);return a||(a=this.generateIdFn(),i.set(t,a),s.set(a,t)),a}getIds(e,t){var r=this.getIdToRemoteIdMap(e),n=this.getRemoteIdToIdMap(e);return t.map(t=>this.getId(e,t,r,n))}getRemoteId(e,t,r){var n=r||this.getRemoteIdToIdMap(e);return"number"!=typeof t?t:n.get(t)||-1}getRemoteIds(e,t){var r=this.getRemoteIdToIdMap(e);return t.map(t=>this.getRemoteId(e,t,r))}reset(e){e?(this.iframeIdToRemoteIdMap.delete(e),this.iframeRemoteIdToIdMap.delete(e)):(this.iframeIdToRemoteIdMap=new WeakMap,this.iframeRemoteIdToIdMap=new WeakMap)}getIdToRemoteIdMap(e){var t=this.iframeIdToRemoteIdMap.get(e);return t||this.iframeIdToRemoteIdMap.set(e,t=new Map),t}getRemoteIdToIdMap(e){var t=this.iframeRemoteIdToIdMap.get(e);return t||this.iframeRemoteIdToIdMap.set(e,t=new Map),t}}class tN{constructor(e){p(this,"iframes",new WeakMap),p(this,"crossOriginIframeMap",new WeakMap),p(this,"crossOriginIframeMirror",new tD(eH)),p(this,"crossOriginIframeStyleMirror"),p(this,"crossOriginIframeRootIdMap",new WeakMap),p(this,"mirror"),p(this,"mutationCb"),p(this,"wrappedEmit"),p(this,"loadListener"),p(this,"pageHideListener"),p(this,"stylesheetManager"),p(this,"recordCrossOriginIframes"),p(this,"messageHandler"),p(this,"nestedIframeListeners",new Map),p(this,"attachedWindows",new WeakMap),p(this,"attachedDocuments",new WeakMap),p(this,"attachedIframes",new Map),p(this,"loadListenerDisposers",new WeakMap),p(this,"iframeElementsById",new Map),p(this,"pageHideHandlers",new WeakMap),this.mutationCb=e.mutationCb,this.wrappedEmit=e.wrappedEmit,this.stylesheetManager=e.stylesheetManager,this.recordCrossOriginIframes=e.recordCrossOriginIframes,this.crossOriginIframeStyleMirror=ne
1w tD(this.stylesheetManager.styleMirror.generateId.bind(this.stylesheetManager.styleMirror)),this.mirror=e.mirror,this.messageHandler=this.handleMessage.bind(this),this.recordCrossOriginIframes&&window.addEventListener("message",this.messageHandler)}addIframe(e){this.iframes.set(e,!0),e.contentWindow&&this.crossOriginIframeMap.set(e.contentWindow,e)}registerLoadListenerDisposer(e,t){var r=this.loadListenerDisposers.get(e);r||this.loadListenerDisposers.set(e,r=new Set),r.add(t);var n=this.mirror.getId(e);-1!==n&&this.iframeElementsById.set(n,e)}getIframeElementById(e){var t,r,n;return null!=(t=null!=(r=null==(n=this.attachedIframes.get(e))?void 0:n.element)?r:this.iframeElementsById.get(e))?t:null}forgetIframeId(e){this.attachedIframes.delete(e),this.iframeElementsById.delete(e)}disposeLoadListeners(e){var t=this.loadListenerDisposers.get(e);t&&(t.forEach(e=>e8(e)),this.loadListenerDisposers.delete(e))}removePageHideListener(e){var t=this.pageHideHandlers.get(e);t&&(t.forEach(e=>{e4(e.win,"pagehide",e.handler)}),this.pageHideHandlers.delete(e))}addLoadListener(e){this.loadListener=e}addPageHideListener(e){this.pageHideListener=e}removeLoadListener(){this.loadListener=void 0}trackIframeContent(e,t){var r=this.mirror.getId(e);return this.attachedIframes.set(r,{element:e,content:t}),r}attachIframe(e,t){var r,n=this.trackIframeContent(e,t);if(e.contentDocument){var i=this.attachedDocuments.get(e);i||this.attachedDocuments.set(e,i=new Set),i.add(e.contentDocument)}this.mutationCb({adds:[{parentId:n,nextId:null,node:t}],removes:[],texts:[],attributes:[],isAttachIframe:!0});var s=e.contentWindow;if(this.recordCrossOriginIframes&&s&&!this.nestedIframeListeners.has(s)){var a=this.handleMessage.bind(this);e8(()=>{s.addEventListener("message",a),this.nestedIframeListeners.set(s,a);var t=this.attachedWindows.get(e);t||this.attachedWindows.set(e,t=new Set),t.add(s)})}e8(()=>{var t=e.contentWindow;if(t){var r=this.pageHideHandlers.get(e);if(r){for(var n of r)if(n.win===t)return}var i=()=>{var t;null==(t=this.pageHideListener)||t.call(this,e),e.contentDocument&&this.mirror.removeNodeFromMap(e.contentDocument),e.contentWindow&&this.crossOriginIframeMap.delete(e.contentWindow)};t.addEventListener("pagehide",i),r||this.pageHideHandlers.set(e,r=new Set),r.add({win:t,handler:i})}}),null==(r=this.loadListener)||r.call(this,e),e.contentDocument&&e.contentDocument.adoptedStyleSheets&&e.contentDocument.adoptedStyleSheets.length>0&&this.stylesheetManager.adoptStyleSheets(e.contentDocument.adoptedStyleSheets,this.mirror.getId(e.contentDocument))}handleMessage(e){if("rrweb"===e.data.type&&e.origin===e.data.origin&&e.source){var t=this.crossOriginIframeMap.get(e.source);if(t){var r=this.transformCrossOriginEvent(t,e.data.event);r&&this.wrappedEmit(r,e.data.isCheckout)}}}transformCrossOriginEvent(e,t){var r;switch(t.type){case f.FullSnapshot:this.crossOriginIframeMirror.reset(e),this.crossOriginIframeStyleMirror.reset(e),this.replaceIdOnNode(t.data.node,e);var n=t.data.node.id;return this.crossOriginIframeRootIdMap.set(e,n),this.patchRootIdOnNode(t.data.node,n),this.trackIframeContent(e,t.data.node),{timestamp:t.timestamp,type:f.IncrementalSnapshot,data:{source:m.Mutation,adds:[{parentId:this.mirror.getId(e),nextId:null,node:t.data.node}],removes:[],texts:[],attributes:[],isAttachIframe:!0}};case f.Meta:case f.Load:case f.DomContentLoaded:break;case f.Plugin:return t;case f.Custom:return this.replaceIds(t.data.payload,e,["id","parentId","previousId","nextId"]),t;case f.IncrementalSnapshot:switch(t.data.source){case m.Mutation:return t.data.adds.forEach(t=>{this.replaceIds(t,e,["parentId","nextId","previousId"]),this.replaceIdOnNode(t.node,e);var r=this.crossOriginIframeRootIdMap.get(e);r&&this.patchRootIdOnNode(t.node,r)}),t.data.removes.forEach(t=>{this.replaceIds(t,e,["parentId","id"])}),t.data.attributes.forEach(t=>{this.replaceIds(t,e,["id"])}),t.data.texts.forEach(t=>{this.replaceIds(t,e,["id"])}),t;case m.Drag:case m.TouchMove:case m.MouseMove:return t.data.positions.forEach(t=>{this.replaceIds(t,e,["id"])}),t;case m.ViewportResize:return!1;case m.MediaInteraction:case m.MouseInteraction:case m.Scroll:case m.CanvasMutation:case m.Input:return this.replaceIds(t.data,e,["id"]),t;case m.StyleSheetRule:case m.StyleDeclaration:return this.replaceIds(t.data,e,["id"]),this.replaceStyleIds(t.data,e,["styleId"]),t;case m.Font:return t;
1case m.Selection:return t.data.ranges.forEach(t=>{this.replaceIds(t,e,["start","end"])}),t;case m.AdoptedStyleSheet:return this.replaceIds(t.data,e,["id"]),this.replaceStyleIds(t.data,e,["styleIds"]),null==(r=t.data.styles)||r.forEach(t=>{this.replaceStyleIds(t,e,["styleId"])}),t}}return!1}replace(e,t,r,n){for(var i of n)(Array.isArray(t[i])||"number"==typeof t[i])&&(t[i]=Array.isArray(t[i])?e.getIds(r,t[i]):e.getId(r,t[i]));return t}replaceIds(e,t,r){return this.replace(this.crossOriginIframeMirror,e,t,r)}replaceStyleIds(e,t,r){return this.replace(this.crossOriginIframeStyleMirror,e,t,r)}replaceIdOnNode(e,t){this.replaceIds(e,t,["id","rootId"]),"childNodes"in e&&e.childNodes.forEach(e=>{this.replaceIdOnNode(e,t)})}patchRootIdOnNode(e,t){e.type===w.Document||e.rootId||(e.rootId=t),"childNodes"in e&&e.childNodes.forEach(e=>{this.patchRootIdOnNode(e,t)})}removeIframeById(e){var t=this.attachedIframes.get(e),r=(null==t?void 0:t.element)||this.iframeElementsById.get(e)||this.mirror.getNode(e);if(this.iframeElementsById.delete(e),r){var n=r.contentWindow,i=this.attachedWindows.get(r);i&&(i.forEach(e=>{var t=this.nestedIframeListeners.get(e);t&&(e4(e,"message",t),this.nestedIframeListeners.delete(e)),this.crossOriginIframeMap.delete(e)}),this.attachedWindows.delete(r)),n&&this.nestedIframeListeners.has(n)&&(e4(n,"message",this.nestedIframeListeners.get(n)),this.nestedIframeListeners.delete(n)),n&&this.crossOriginIframeMap.delete(n),this.iframes.delete(r),this.disposeLoadListeners(r),this.removePageHideListener(r);var s=this.attachedDocuments.get(r);s&&(s.forEach(e=>{e8(()=>this.mirror.removeNodeFromMap(e))}),e8(()=>tM(r,s)),this.attachedDocuments.delete(r))}t&&this.attachedIframes.delete(e)}cleanupDetachedIframes(){if(0!==this.attachedIframes.size){var e=[];this.attachedIframes.forEach((t,r)=>{this.mirror.has(r)||e.push(r)}),e.forEach(e=>this.removeIframeById(e))}}reattachIframes(){this.attachedIframes.forEach((e,t)=>{var r=e.content;this.mirror.has(t)?this.mutationCb({adds:[{parentId:t,nextId:null,node:r}],removes:[],texts:[],attributes:[],isAttachIframe:!0}):this.attachedIframes.delete(t)})}destroy(){this.recordCrossOriginIframes&&e4(window,"message",this.messageHandler),this.nestedIframeListeners.forEach((e,t)=>{e4(t,"message",e)}),this.nestedIframeListeners.clear();var e=new Set;this.iframeElementsById.forEach(t=>e.add(t)),this.attachedIframes.forEach(t=>e.add(t.element)),e.forEach(e=>{this.disposeLoadListeners(e),this.removePageHideListener(e)}),this.crossOriginIframeMirror.reset(),this.crossOriginIframeStyleMirror.reset(),this.attachedIframes.clear(),this.crossOriginIframeMap=new WeakMap,this.iframes=new WeakMap,this.crossOriginIframeRootIdMap=new WeakMap,this.loadListenerDisposers=new WeakMap,this.pageHideHandlers=new WeakMap,this.attachedDocuments=new WeakMap,this.attachedWindows=new WeakMap,this.iframeElementsById=new Map}}class tF{constructor(e){p(this,"shadowDoms",new WeakSet),p(this,"mutationCb"),p(this,"scrollCb"),p(this,"bypassOptions"),p(this,"mirror"),p(this,"restoreHandlers",[]),this.mutationCb=e.mutationCb,this.scrollCb=e.scrollCb,this.bypassOptions=e.bypassOptions,this.mirror=e.mirror,this.init()}init(){this.reset(),this.patchAttachShadow(Element,document)}addShadowRoot(e,t){var r,n;if(eu(e)&&!this.shadowDoms.has(e)){this.shadowDoms.add(e);var i=null!=(r=null==(n=D(e))?void 0:n.ownerDocument)?r:t,s=t_(h({},this.bypassOptions,{doc:i,mutationCb:this.mutationCb,mirror:this.mirror,shadowDomManager:this}),e),a=s.observer,o=s.buffer;this.restoreHandlers.push({doc:i,handler(){a.disconnect(),o.destroy(),o.releaseCanvasManager();var e=tS.indexOf(o);-1!==e&&tS.splice(e,1)}}),this.restoreHandlers.push({doc:i,handler:tI(h({},this.bypassOptions,{scrollCb:this.scrollCb,doc:e,mirror:this.mirror}))}),setTimeout(()=>{e.adoptedStyleSheets&&e.adoptedStyleSheets.length>0&&this.bypassOptions.stylesheetManager.adoptStyleSheets(e.adoptedStyleSheets,this.mirror.getId(D(e))),this.restoreHandlers.push({doc:i,handler:tx({mirror:this.mirror,stylesheetManager:this.bypassOptions.stylesheetManager},e)})},0)}}observeAttachShadow(e){e.contentWindow&&e.contentDocument&&this.patchAttachShadow(e.contentWindow.Element,e.contentDocument)}patchAttachShadow(e,t){var r=this;this.restoreHandlers.push({doc:t,handler:x(e.prototype,"attachShadow",function(e){return function(n){var i=e.call(this,n),s=N(this);return s&&tf(this)&&r.addShadowRoot(s,t),i}})})}
1reset(){this.restoreHandlers.forEach(e=>{var t=e.handler;try{t()}catch(e){}}),this.restoreHandlers=[],this.shadowDoms=new WeakSet}resetForDoc(e){var t=[];for(var r of this.restoreHandlers)if(r.doc===e)try{r.handler()}catch(e){}else t.push(r);this.restoreHandlers=t}}var tP="skip-frame";function tH(e){if("object"!=typeof e||null===e)return!1;var t=e.y,r=e.width,n=e.height;return Number.isFinite(e.x)&&Number.isFinite(t)&&Number.isFinite(r)&&Number.isFinite(n)&&r>=0&&n>=0}for(var tB="ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789+/",tW="u"<typeof Uint8Array?[]:new Uint8Array(256),tz=0;64>tz;tz++)tW[tB.charCodeAt(tz)]=tz;var tU=new Map,tq=(e,t,r)=>{if(e&&(tj(e,t)||"object"==typeof e)){var n,i,s=(n=e.constructor.name,(i=tU.get(r))||tU.set(r,i=new Map),i.has(n)||i.set(n,[]),i.get(n)),a=s.indexOf(e);return -1===a&&(a=s.length,s.push(e)),a}},t$=(e,t,r,n)=>e.map(e=>(function e(t,r,n,i){return t instanceof Array?t.map(t=>e(t,r,n,i)):null===t?t:t instanceof Float32Array||t instanceof Float64Array||t instanceof Int32Array||t instanceof Uint32Array||t instanceof Uint8Array||t instanceof Uint16Array||t instanceof Int16Array||t instanceof Int8Array||t instanceof Uint8ClampedArray?{rr_type:t.constructor.name,args:[Object.values(t)]}:t instanceof ArrayBuffer?{rr_type:t.constructor.name,base64:function(e){var t,r=new Uint8Array(e),n=r.length,i="";for(t=0;n>t;t+=3)i+=tB[r[t]>>2],i+=tB[(3&r[t])<<4|r[t+1]>>4],i+=tB[(15&r[t+1])<<2|r[t+2]>>6],i+=tB[63&r[t+2]];return n%3==2?i=i.substring(0,i.length-1)+"=":n%3==1&&(i=i.substring(0,i.length-2)+"=="),i}(t)}:t instanceof DataView?{rr_type:t.constructor.name,args:[e(t.buffer,r,n,i),t.byteOffset,t.byteLength]}:t instanceof HTMLImageElement?{rr_type:t.constructor.name,src:t.src}:t instanceof HTMLCanvasElement?{rr_type:"HTMLImageElement",src:t.toDataURL(i.type,i.quality)}:t instanceof ImageData?{rr_type:t.constructor.name,args:[e(t.data,r,n,i),t.width,t.height]}:tj(t,r)||"object"==typeof t?{rr_type:t.constructor.name,index:tq(t,r,n)}:t})(e,t,r,n)),tj=(e,t)=>!!["WebGLActiveInfo","WebGLBuffer","WebGLFramebuffer","WebGLProgram","WebGLRenderbuffer","WebGLShader","WebGLShaderPrecisionFormat","WebGLTexture","WebGLUniformLocation","WebGLVertexArrayObject","WebGLVertexArrayObjectOES"].filter(e=>"function"==typeof t[e]).find(r=>e instanceof t[r]),tG=["webgl","webgl2"];function tV(e){return"nodeType"in e}function tZ(e,t,r,n){var i=[];try{if(n){var s=function(e,t,r){var n=e.GPUCanvasContext;if((null==n?void 0:n.prototype)&&"function"==typeof n.prototype.configure)return x(n.prototype,"configure",function(n){return function(i){var s,a,o=(s=this.canvas)&&"object"==typeof s?s:null;if(!o||tV(o)&&ta(o,t,r,!0))return n.call(this,i);!tV(o)||"__context"in o||(o.__context="webgpu");var l=(a=e.GPUTextureUsage)?a.COPY_SRC|a.RENDER_ATTACHMENT:null;return n.call(this,null!==l&&i?h({},i,{usage:"number"==typeof i.usage?i.usage|l:l}):i)}})}(e,t,r);s&&i.push(s)}var a=x(e.HTMLCanvasElement.prototype,"getContext",function(e){return function(i){for(var s="experimental-webgl"===i?"webgl":i,a=arguments.length,o=Array(a>1?a-1:0),l=1;a>l;l++)o[l-1]=arguments[l];if(!ta(this,t,r,!0)&&("__context"in this||(this.__context=s),n&&tG.includes(s)))if(o[0]&&"object"==typeof o[0]){var h=o[0];h.preserveDrawingBuffer||(h.preserveDrawingBuffer=!0)}else o.splice(0,1,{preserveDrawingBuffer:!0});return e.apply(this,[i,...o])}});i.push(a)}catch(e){console.error("failed to patch HTMLCanvasElement.prototype.getContext")}return()=>{i.forEach(e=>e())}}function tX(e,t,r,n,i,s,a){var o=[],l=Object.getOwnPropertyNames(e),h=function(l){if(["isContextLost","canvas","drawingBufferWidth","drawingBufferHeight"].includes(l))return 0;try{if("function"!=typeof e[l])return 0;var h=x(e,l,function(e){return function(){for(var o=arguments.length,h=Array(o),u=0;o>u;u++)h[u]=arguments[u];var d=e.apply(this,h);if(tq(d,s,this),"tagName"in this.canvas&&!ta(this.canvas,n,i,!0)){var c=t$(h,s,this,a);r(this.canvas,{type:t,property:l,args:c})}return d}});o.push(h)}catch(n){var u=te(e,l,{set(e){r(this.canvas,{type:t,property:l,args:[e],setter:!0})}});o.push(u)}};for(var u of l)h(u);return o}
1var tJ,tY,tQ,tK,t0='(function() {\n "use strict";\n var chars = "ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789+/";\n var lookup = typeof Uint8Array === "undefined" ? [] : new Uint8Array(256);\n for (var i = 0; i < chars.length; i++) {\n lookup[chars.charCodeAt(i)] = i;\n }\n var encode = function(arraybuffer) {\n var bytes = new Uint8Array(arraybuffer), i2, len = bytes.length, base64 = "";\n for (i2 = 0; i2 < len; i2 += 3) {\n base64 += chars[bytes[i2] >> 2];\n base64 += chars[(bytes[i2] & 3) << 4 | bytes[i2 + 1] >> 4];\n base64 += chars[(bytes[i2 + 1] & 15) << 2 | bytes[i2 + 2] >> 6];\n base64 += chars[bytes[i2 + 2] & 63];\n }\n if (len % 3 === 2) {\n base64 = base64.substring(0, base64.length - 1) + "=";\n } else if (len % 3 === 1) {\n base64 = base64.substring(0, base64.length - 2) + "==";\n }\n return base64;\n };\n const lastFingerprintMap = /* @__PURE__ */ new Map();\n const transparentFingerprintMap = /* @__PURE__ */ new Map();\n const lastSentAtMap = /* @__PURE__ */ new Map();\n const PROVIDER_KEYFRAME_INTERVAL_MS = 3e4;\n function hashPixels(data) {\n const view = new Uint32Array(\n data.buffer,\n data.byteOffset,\n data.byteLength >>> 2\n );\n let primaryHash = 2166136261;\n let secondaryHash = 2654435769;\n for (let i2 = 0; i2 < view.length; i2++) {\n primaryHash ^= view[i2];\n primaryHash = Math.imul(primaryHash, 16777619);\n secondaryHash ^= view[i2];\n secondaryHash = Math.imul(secondaryHash, 2246822507);\n }\n return `${(primaryHash >>> 0).toString(16)}:${(secondaryHash >>> 0).toString(16)}`;\n }\n function frameFingerprint(width, height, data) {\n return `${width}x${height}:${hashPixels(data)}`;\n }\n function transparentFingerprint(width, height) {\n const pixelCount = width * height;\n let hash = transparentFingerprintMap.get(pixelCount);\n if (hash === void 0) {\n hash = hashPixels(new Uint8ClampedArray(pixelCount * 4));\n transparentFingerprintMap.set(pixelCount, hash);\n }\n return `${width}x${height}:${hash}`;\n }\n const worker = self;\n let reusableCanvas = null;\n let reusableCtx = null;\n worker.onmessage = async function(e) {\n if ("resetFrameDedup" in e.data) {\n lastFingerprintMap.clear();\n return;\n }\n if ("OffscreenCanvas" in globalThis) {\n const {\n id,\n bitmap,\n width,\n height,\n displayWidth,\n displayHeight,\n dataURLOptions,\n maskRegions\n } = e.data;\n try {\n if (!reusableCanvas || reusableCanvas.width !== width || reusableCanvas.height !== height) {\n reusableCanvas = new OffscreenCanvas(width, height);\n reusableCtx = reusableCanvas.getContext("2d", {\n willReadFrequently: true\n });\n }\n const ctx = reusableCtx;\n ctx.clearRect(0, 0, width, height);\n ctx.drawImage(bitmap, 0, 0);\n bitmap.close();\n if (maskRegions) {\n ctx.fillStyle = "black";\n for (const region of maskRegions) {\n ctx.fillRect(region.x, region.y, region.width, region.height);\n }\n }\n const fingerprint = frameFingerprint(\n width,\n height,\n ctx.getImageData(0, 0, width, height).data\n );\n const lastFingerprint = lastFingerprintMap.get(id) ?? transparentFingerprint(width, height);\n if (fingerprint === lastFingerprint) {\n const lastSentAt = lastSentAtMap.get(id);\n const keyframeDue = maskRegions !== void 0 && lastSentAt !== void 0 && Date.now() - lastSentAt >= PROVIDER_KEYFRAME_INTERVAL_MS;\n if (!keyframeDue) {\n return worker.postMessage({ id });\n }\n }\n const blob = await reusableCanvas.convertToBlob(dataURLOptions);\n const arrayBuffer = await blob.arrayBuffer();\n worker.postMessage({\n id,\n type: blob.type,\n base64: encode(arrayBuffer),\n // cpu intensive\n displayWidth,\n displayHeight\n });\n lastFingerprintMap.set(id, fingerprint);\n lastSentAtMap.set(id, Date.now());\n } catch {\n worker.postMessage({ id });\n }\n } else {\n e.data.bitmap.close();\n return worker.postMessage({ id: e.data.id });\n }\n };\n})();\n',t1="u">typeof self&&self.Blob&&new Blob([t0],{type:"text/javascript;charset=utf-8"});function t2(e){var t;try{if(!(t=t1&&(self.URL||self.webkitURL).createObjectURL(t1)))throw"";var r=new Worker(t,{name:null==e?void 0:e.name});return r.addEventListener("error",()=>{(self.URL||self.webkitURL).revokeObjectURL(t)}),r}catch(t){return new Worker("data:text/javascript;charset=utf-8,"+encodeURIComponent(t0),{name:null==e?void 0:e.name})}finally{t&&(self.URL||self.webkitURL).revokeObjectURL(t)}}class t3{constructor(e){p(this,"pendingCanvasMutations",new Map),p(this,"rafStamps",{latestId:0,invokeId:null}),p(this,"mirror"),p(this,"mutationCb"),p(this,"resetObservers"),p(this,"frozen",!1),p(this,"locked",!1),p(this,"rafIdTimestamp",null),p(this,"rafIdFlush",null),p(this,"refCount",0),p(this,"torndown",!1),p(this,"resetFrameDedup",null),p(this,"processMutation",(e,t)=>{!(this.rafStamps.invokeId&&this.rafStamps.latestId!==this.rafStamps.invokeId)&&this.rafStamps.invokeId||(this.rafStamps.invokeId=this.rafStamps.latestId),this.pendingCanvasMutations.has(e)||this.pendingCanvasMutations.set(e,[]),this.pendingCanvasMutations.get(e).push(t)});var t=e.sampling,r=void 0===t?"all":t,n=e.win,i=e.blockClass,s=e.blockSelector,a=e.recordCanvas,o=e.dataURLOptions,l=e.resolutionScale,h=e.canvasMasking;this.mutationCb=e.mutationCb,this.mirror=e.mirror,a&&"all"===r&&this.initCanvasMutationObserver(n,i,s,o),a&&"number"==typeof r&&this.initCanvasFPSObserver(r,n,i,s,{dataURLOptions:o,resolutionScale:l,canvasMasking:h})}onFullSnapshot(){var e;null==(e=this.resetFrameDedup)||e.call(this)}acquire(){this.refCount+=1}reset(){this.refCount>0&&(this.refCount-=1),this.refCount>0||this.teardown()}teardown(){this.torndown||(this.torndown=!0,this.pendingCanvasMutations.clear(),this.resetObservers&&this.resetObservers(),null!==this.rafIdTimestamp&&(cancelAnimationFrame(this.rafIdTimestamp),this.rafIdTimestamp=null),null!==this.rafIdFlush&&(cancelAnimationFrame(this.rafIdFlush),this.rafIdFlush=null))}freeze(){this.frozen=!0}unfreeze(){this.frozen=!1}lock(){this.locked=!0}unlock(){this.locked=!1}initCanvasFPSObserver(e,t,r,n,i){var s=this;if("OffscreenCanvas"in t){var a,o="number"==typeof i.resolutionScale&&Number.isFinite(i.resolutionScale)?Math.min(1,Math.max(.1,i.resolutionScale)):1,h=tZ(t,r,n,!0),u=new Map;try{a=new t2}catch(e){return}var d=!1;a.onerror=()=>{var e;d=!0,cancelAnimationFrame(c),null==(e=a.terminate)||e.call(a),this.resetFrameDedup=null},this.resetFrameDedup=()=>{a.postMessage({resetFrameDedup:!0})},a.onmessage=e=>{var t=e.data.id;if(u.set(t,!1),"base64"in e.data){var r=e.data,n=r.displayWidth,i=r.displayHeight;this.mutationCb({id:t,type:y["2D"],commands:[{property:"clearRect",args:[0,0,n,i]},{property:"drawImage",args:[{rr_type:"ImageBitmap",args:[{rr_type:"Blob",data:[{rr_type:"ArrayBuffer",base64:r.base64}],type:r.type}]},0,0,n,i]}],displayWidth:n,displayHeight:i})}};var c,p=1e3/e,f=0,m=e=>{var h,v,g;d||(f&&p>e-f||(f=e,(h=[],(v=e=>
1{try{e.querySelectorAll("canvas").forEach(e=>{ta(e,r,n,!0)||h.push(e)}),e.querySelectorAll("*").forEach(e=>{e.shadowRoot&&v(e.shadowRoot)})}catch(e){}})(t.document),h).forEach((g=l(function*(e){var t,r,n=s.mirror.getId(e);if(!u.get(n)&&0!==e.width&&0!==e.height){u.set(n,!0);try{if(["webgl","webgl2"].includes(e.__context)){var l=e.getContext(e.__context);if(null==(t=null==l?void 0:l.isContextLost)?void 0:t.call(l))return void u.set(n,!1);!1===(null==(r=null==l?void 0:l.getContextAttributes())?void 0:r.preserveDrawingBuffer)&&l.clear(l.COLOR_BUFFER_BIT)}var h=e.clientWidth||e.width,d=e.clientHeight||e.height,c=Math.max(1,Math.round(h*o)),p=Math.max(1,Math.round(d*o)),f=function(e,t,r,n,i,s){if(e&&"function"==typeof e.regionsFn){var a;try{a=e.regionsFn(t)}catch(e){return tP}if(void 0!==a){if(!Array.isArray(a)||!a.every(tH))return tP;var o=r/i,l=n/s;return a.filter(e=>e.width>0&&e.height>0).map(e=>{var t=Math.floor(e.x*o),r=Math.floor(e.y*l);return{x:t,y:r,width:Math.ceil((e.x+e.width)*o)-t,height:Math.ceil((e.y+e.height)*l)-r}})}}}(i.canvasMasking,e,c,p,h,d);if(f===tP)return void u.set(n,!1);var m=yield createImageBitmap(e,1>o?{resizeWidth:c,resizeHeight:p,resizeQuality:"medium"}:{resizeWidth:c,resizeHeight:p});a.postMessage({id:n,bitmap:m,width:c,height:p,displayWidth:h,displayHeight:d,dataURLOptions:i.dataURLOptions,maskRegions:f},[m])}catch(e){u.set(n,!1)}}}),function(e){return g.apply(this,arguments)}))),c=requestAnimationFrame(m))};c=requestAnimationFrame(m),this.resetObservers=()=>{var e;h(),cancelAnimationFrame(c),null==(e=a.terminate)||e.call(a),this.resetFrameDedup=null}}}initCanvasMutationObserver(e,t,r,n){this.startRAFTimestamping(),this.startPendingCanvasMutationFlusher();var i,s,a=tZ(e,t,r,!1),o=function(e,t,r,n,i){var s=[],a=Object.getOwnPropertyNames(t.CanvasRenderingContext2D.prototype),o=function(a){try{if("function"!=typeof t.CanvasRenderingContext2D.prototype[a])return 1;var o=x(t.CanvasRenderingContext2D.prototype,a,function(s){return function(){for(var o=arguments.length,l=Array(o),h=0;o>h;h++)l[h]=arguments[h];return ta(this.canvas,r,n,!0)||setTimeout(()=>{var r=t$(l,t,this,i);e(this.canvas,{type:y["2D"],property:a,args:r})},0),s.apply(this,l)}});s.push(o)}catch(r){var l=te(t.CanvasRenderingContext2D.prototype,a,{set(t){e(this.canvas,{type:y["2D"],property:a,args:[t],setter:!0})}});s.push(l)}};for(var l of a)o(l);return()=>{s.forEach(e=>e())}}(this.processMutation.bind(this),e,t,r,n),l=(i=this.processMutation.bind(this),s=[],void 0!==e.WebGLRenderingContext&&s.push(...tX(e.WebGLRenderingContext.prototype,y.WebGL,i,t,r,e,n)),void 0!==e.WebGL2RenderingContext&&s.push(...tX(e.WebGL2RenderingContext.prototype,y.WebGL2,i,t,r,e,n)),()=>{s.forEach(e=>e())});this.resetObservers=()=>{a(),o(),l()}}startPendingCanvasMutationFlusher(){this.rafIdFlush=requestAnimationFrame(()=>this.flushPendingCanvasMutations())}startRAFTimestamping(){var e=t=>{this.rafStamps.latestId=t,this.rafIdTimestamp=requestAnimationFrame(e)};this.rafIdTimestamp=requestAnimationFrame(e)}flushPendingCanvasMutations(){this.pendingCanvasMutations.forEach((e,t)=>{var r=this.mirror.getId(t);this.flushPendingCanvasMutationFor(t,r)}),this.rafIdFlush=requestAnimationFrame(()=>this.flushPendingCanvasMutations())}flushPendingCanvasMutationFor(e,t){if(!this.frozen&&!this.locked){var r=this.pendingCanvasMutations.get(e);if(r&&-1!==t){var n=r.map(e=>(function(e,t){if(null==e)return{};var r={};for(var n in e)if(({}).hasOwnProperty.call(e,n)){if(-1!==t.indexOf(n))continue;r[n]=e[n]}return r})(e,d));this.mutationCb({id:t,type:r[0].type,commands:n}),this.pendingCanvasMutations.delete(e)}}}}class t5{constructor(e){var t;p(this,"trackedLinkElements",new WeakSet),p(this,"pendingDeferredSheets",new Set),p(this,"mutationCb"),p(this,"adoptedStyleSheetCb"),p(this,"maskAllElementAttributes"),p(this,"maskAttributeFn"),p(this,"styleMirror",new tc),this.mutationCb=e.mutationCb,this.adoptedStyleSheetCb=e.adoptedStyleSheetCb,this.maskAllElementAttributes=null!=(t=e.maskAllElementAttributes)&&t,this.maskAttributeFn=e.maskAttributeFn}attachLinkElement(e,t){"_cssText"in t.attributes&&this.mutationCb({adds:[],removes:[],texts:[],attributes:[{id:t.id,attributes:t.attributes}]}),this.trackLinkElement(e)}beginDeferredLinkInlining(e,t){if(-1===t||!e.isConnected)return null;var r=null,n=null;try{(n=e.sheet)&&(r=function(e){var t=[],r=!1,n=null,i=new Map;function s(e){var i=t.pop();if("group"===i.kind){if(null===e){for(;t.length>0&&"group"===t[t.length-1].kind;)t.pop();return void s(null)}var o=t[t.length-1];return o.parts.push(e),void(o.index+=1)}i.importRule?a(t[t.length-1],i.importRule,e):(r=!0,n=e)}function a(e,t,r){var n,i;try{try{i=r||ec(t)}catch(e){i=t.cssText}try{i&&(null==(n=t.styleSheet)?void 0:n.href)&&(i=eL(i,t.styleSheet.href))}catch(e){}i&&e.parts.push(i),e.index+=1}catch(e){s(null)}}return function(e){try{var r=e.rules||e.cssRules;if(!r)return!1;er(r);var n=e.href;!n&&e.ownerNode&&(n=e.ownerNode.baseURI);var s=Array.from(r);return t.push({kind:"sheet",sheet:e,rules:s,sheetHref:n,index:0,parts:[],importRule:null}),function(e,t){for(var r=[{sheet:t,rules:e,index:0}];r.length>0;)!function(){var e=r[r.length-1];if(e.index>=e.rules.length)return r.pop();var t=e.rules[e.index];if(e.index+=1,!eg(t)||i.has(t))return;var n=null;try{n=t.styleSheet}catch(e){return i.set(t,null),0}if(!(!n||r.some(e=>e.sheet===n)))try{var s=n.rules||n.cssRules;if(!s)return 0;er(s);var a=n.href;!a&&n.ownerNode&&(a=n.ownerNode.baseURI);var o=Array.from(s);i.set(t,{sheet:n,rules:o,sheetHref:a}),r.push({sheet:n,rules:o,index:0})}catch(e){}}()}(s,e),!0}catch(e){return!1}}(e)||(r=!0),{advance(e){if(r)return!0;var o=P(),l=e>0?e:1;try{for(;!r&&l>0;){var h=t[t.length-1];if(h.rules.length>h.index){l-=1;try{!function(e){var r=e.rules[e.index];if("sheet"===e.kind&&eg(r)){var n=i.get(r);return null===n?(e.parts.push(r.cssText),e.index+=1):n?t.push({kind:"sheet",sheet:n.sheet,rules:n.rules,sheetHref:n.sheetHref,index:0,parts:[],importRule:r}):a(e,r,null)}if(!function(e,r){try{var n=function(e){var t;if(!e.cssRules||0===e.cssRules.length)return null;if(e.media&&"string"==typeof e.media.mediaText)return"@media "+e.media.mediaText+" {";if(ey(e)){if("number"==typeof e.type&&1!==e.type)return null;var r=e.style?e.style.cssText:"";return e.selectorText+" {"+(r?" "+r:"")}if("containerName"in e)return"string"!=typeof e.containerQuery||e.containerName&&!eb.test(e.containerName)?null:"@container "+(e.containerName?e.containerName+" ":"")+e.containerQuery+" {";if("string"==typeof e.conditionText){var n="";try{n=(null==(t=e.constructor)?void 0:t.name)||""}catch(e){return null}return""===n||"Object"===n||"CSSSupportsRule"===n?"@supports "+e.conditionText+" {":null}return"string"==typeof e.name?"keyText"in e.cssRules[0]?eb.test(e.name)?"@keyframes "+e.name+" {":null:""===e.name?"@layer {":ew.test(e.name)?"@layer "+e.name+" {":null:null}(e);if(null===n)return!1;var i=r.sheetHref;return t.push({kind:"group",rules:Array.from(e.cssRules),sheetHref:i,index:0,parts:[],prelude:i?eL(n,i):n,fixColons:"sheet"===r.kind&&ey(e)&&e.selectorText.includes(":")}),!0}catch(e){return!1}}(r,e)){var s=r.cssText;"sheet"===e.kind&&ey(r)&&r.selectorText.includes(":")&&(s=ev(s)),e.parts.push(e.sheetHref?eL(s,e.sheetHref):s),e.index+=1}}(h)}catch(e){s(null)}}else{var u=null;try{if("group"===h.kind){var d=h.prelude+h.parts.join("")+"}";u=h.fixColons?ev(d):d}else u=ed(h.parts.join(""))}catch(e){}s(u)}}}catch(e){r=!0,n=null}finally{ei(P()-o)}return r},text:()=>r?n:null,remainingRules(){if(r)return 0;var e=0;for(var n of t)e+=n.rules.length-n.index;return e}}}(n))}catch(e){}if(!r||!n)return ea(),null;var i=r,s=!1,a={sheet:n,invalidate(){s=!0}};this.pendingDeferredSheets.add(a);var o=!1;return{advance:r=>{if(o)return!0;var l,h=P(),u=H,d=!0;try{if(s)return o=!0,ea(),!0;if(!i.advance(r))return d=!1,!1;o=!0;var c=i.text();if(!e.isConnected)return!0;var p=null;try{p=e.sheet}catch(e){}return p!==n?ea():c?this.emitCssTextMutation(e,t,c):ea(),!0}finally{d&&this.pendingDeferredSheets.delete(a),z(l=P()-h,null!=u?u:H)||(Q.totalMs+=l,l>Q.slowestSliceMs&&(Q.slowestSliceMs=l))}},remainingRules:()=>i.remainingRules(),discard:()=>{this.pendingDeferredSheets.delete(a)}}}onCssomSheetMutation(e){if(e&&0!==this.pendingDeferredSheets.size)for(var t of this.pendingDeferredSheets)t.sheet===e&&(this.pendingDeferredSheets.delete(t),t.invalidate())}inlineDeferredLinkElement(e,t){var r;null==(r=this.beginDeferredLinkInlining(e,t))||r.advance(1/0)}emitCssTextMutation(e,t,r){this.mutationCb({adds:[],removes:[],texts:[],attributes:[{id:t,attributes:{_cssText:eM({element:e,name:"_cssText",value:r,maskAllElementAttributes:this.maskAllElementAttributes,maskAttributeFn:this.maskAttributeFn})}}]})}trackLinkElement(e){this.trackedLinkElements.has(e)||(this.trackedLinkElements.add(e),this.trackStylesheetInLinkElement(e))}adoptStyleSheets(e,t){var r=this;if(0!==e.length){var n={id:t,styleIds:[]},i=[],s=function(e){var t;if(r.styleMirror.has(e))t=r.styleMirror.getId(e);else{var s=r.styleMirror.add(e);t=s;var a=P();try{en(()=>{try{var t=e.rules||e.cssRules;t&&er(t)}catch(e){}i.push({styleId:s,rules:Array.from(e.rules||CSSRule,(t,r)=>({rule:em(t,e.href),index:r}))})})}finally{ei(P()-a)}}n.styleIds.push(t)};for(var a of e)s(a);i.length>0&&(n.styles=i),this.adoptedStyleSheetCb(n)}}reset(){this.styleMirror.reset(),this.trackedLinkElements=new WeakSet,this.pendingDeferredSheets.clear(),eJ.forEach(e
1=>e.abort()),eJ.clear()}trackStylesheetInLinkElement(e){}}class t4{constructor(){p(this,"nodeMap",new WeakMap),p(this,"active",!1)}inOtherBuffer(e,t){var r=this.nodeMap.get(e);return r&&Array.from(r).some(e=>e!==t)}add(e,t){this.active||(this.active=!0,requestAnimationFrame(()=>{this.nodeMap=new WeakMap,this.active=!1})),this.nodeMap.set(e,(this.nodeMap.get(e)||new Set).add(t))}destroy(){}}var t8=!1;try{if(2!==Array.from([1],e=>2*e)[0]){var t6=document.createElement("iframe");document.body.appendChild(t6),Array.from=(null==(u=t6.contentWindow)?void 0:u.Array.from)||Array.from,document.body.removeChild(t6)}}catch(e){console.debug("Unable to override Array.from",e)}var t9=new eS,t7=new Set([m.Mutation,m.MediaInteraction,m.StyleSheetRule,m.CanvasMutation,m.Font,m.Log,m.StyleDeclaration,m.AdoptedStyleSheet]);function re(e){var t=window;if("function"==typeof t.requestIdleCallback){var r=t.requestIdleCallback(e,{timeout:2e3});return{cancel(){var e;return null==(e=t.cancelIdleCallback)?void 0:e.call(t,r)}}}var n=setTimeout(e,250);return{cancel:()=>clearTimeout(n)}}function rt(e){void 0===e&&(e={});var t=e,r=t.emit,n=t.checkoutEveryNms,i=t.checkoutEveryNth,s=t.blockClass,a=void 0===s?"rr-block":s,o=t.blockSelector,l=void 0===o?null:o,u=t.ignoreClass,d=void 0===u?"rr-ignore":u,c=t.ignoreSelector,p=void 0===c?null:c,v=t.maskTextClass,g=void 0===v?"rr-mask":v,y=t.maskTextSelector,b=void 0===y?null:y,w=t.inlineStylesheet,S=void 0===w||w,k=t.inlineStylesheetBudgetRules,_=t.maskAllInputs,I=t.maskInputOptions,M=t.slimDOMOptions,C=t.maskInputFn,R=t.maskTextFn,E=t.maskAllElementAttributes,T=void 0!==E&&E,x=t.maskAttributeFn,A=t.hooks,L=t.packFn,O=t.sampling,D=void 0===O?{}:O,F=t.dataURLOptions,P=t.canvasResolutionScale,H=t.canvasMasking,B=t.mousemoveWait,z=t.recordDOM,U=void 0===z||z,q=t.recordCanvas,$=void 0!==q&&q,j=t.recordCrossOriginIframes,G=void 0!==j&&j,V=t.recordAfter,X=void 0===V?"DOMContentLoaded"===e.recordAfter?e.recordAfter:"load":V,J=t.userTriggeredOnInput,Y=void 0!==J&&J,Q=t.collectFonts,et=void 0!==Q&&Q,er=t.inlineImages,en=void 0!==er&&er,ei=t.plugins,es=t.keepIframeSrcFn,ea=void 0===es?()=>!1:es,el=t.ignoreCSSAttributes,eh=void 0===el?new Set([]):el,eu=t.attributeFilter;tJ=t.errorHandler;var ed=h({type:"image/webp",quality:.4,maxBase64ImageLength:1048576},void 0===F?{}:F),ec=!G||window.parent===window,ep=!1;if(!ec)try{window.parent.document&&(ep=!1)}catch(e){ep=!0}if(ec&&!r)throw Error("emit function is required");if(!ec&&!ep)return()=>{};void 0!==B&&void 0===D.mousemove&&(D.mousemove=B),t9.reset();var ef,em,ev=!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,password:!0}:void 0!==I?I:{password:!0},eg=e2(void 0!==M&&M);void 0===ey&&(ey=window),"NodeList"in ey&&!ey.NodeList.prototype.forEach&&(ey.NodeList.prototype.forEach=[].forEach),"DOMTokenList"in ey&&!ey.DOMTokenList.prototype.forEach&&(ey.DOMTokenList.prototype.forEach=[].forEach);var ey,eb,ew,ek=0,e_=new Map,eI=e=>{for(var t of ei||[])t.eventProcessor&&(e=t.eventProcessor(e));return L&&!ep&&(e=L(e)),e};tY=(e,t)=>{var s;if(e.timestamp=tt(),!(null==(s=tS[0])?void 0:s.isFrozen())||e.type===f.FullSnapshot||e.type===f.IncrementalSnapshot&&t7.has(e.data.source)||tS.forEach(e=>e.unfreeze()),ec)null==r||r(eI(e),t);else if(ep){var a={type:"rrweb",event:eI(e),origin:window.location.origin,isCheckout:t};window.parent.postMessage(a,"*")}if(e.type===f.FullSnapshot)em=e,ek=0;else if(e.type===f.IncrementalSnapshot){if(e.data.source===m.Mutation&&e.data.isAttachIframe)return;ek++,(i&&ek>=i||n&&e.timestamp-em.timestamp>n)&&tQ(!0)}};var eM=e=>{if(e.removes&&e.removes.length>0){var t=e.adds.length>0?new Set(e.adds.map(e=>e.node.id)):null,r=new Set;if(e.adds.length>0)for(var n of e.adds){var i=t9.getNode(n.node.id);i&&"IFRAME"===i.nodeName&&r.add(i)}e.removes.forEach(e=>{var n=e.id;if(!t||!t.has(n)){var i=eT.getIframeElementById(n);i&&r.has(i)?eT.forgetIframeId(n):(null==eb||eb(n),eT.removeIframeById(n))}}),null==ew||ew(),eT.cleanupDetachedIframes()}
1tY({type:f.IncrementalSnapshot,data:h({source:m.Mutation},e)})},eC=e=>tY({type:f.IncrementalSnapshot,data:h({source:m.Scroll},e)}),eR=e=>tY({type:f.IncrementalSnapshot,data:h({source:m.CanvasMutation},e)}),eE=new t5({mutationCb:eM,adoptedStyleSheetCb:e=>tY({type:f.IncrementalSnapshot,data:h({source:m.AdoptedStyleSheet},e)}),maskAllElementAttributes:T,maskAttributeFn:x}),eT=new tN({mirror:t9,mutationCb:eM,stylesheetManager:eE,recordCrossOriginIframes:G,wrappedEmit:tY});for(var ex of ei||[])ex.getMirror&&ex.getMirror({nodeMirror:t9,crossOriginIframeMirror:eT.crossOriginIframeMirror,crossOriginIframeStyleMirror:eT.crossOriginIframeStyleMirror});var eA=new t4,eL=null==H?void 0:H.configured;tK=new t3({recordCanvas:$,mutationCb:eR,win:window,blockClass:a,blockSelector:l,mirror:t9,sampling:D.canvas,dataURLOptions:ed,resolutionScale:P,canvasMasking:H});var eO=new tF({mutationCb:eM,scrollCb:eC,bypassOptions:{blockClass:a,blockSelector:l,maskTextClass:g,maskTextSelector:b,inlineStylesheet:S,maskInputOptions:ev,dataURLOptions:ed,maskTextFn:R,maskInputFn:C,maskAllElementAttributes:T,maskAttributeFn:x,recordCanvas:$,canvasMaskingConfigured:eL,inlineImages:en,sampling:D,slimDOMOptions:eg,iframeManager:eT,stylesheetManager:eE,canvasManager:tK,keepIframeSrcFn:ea,processedNodeManager:eA,attributeFilter:eu},mirror:t9});tQ=function(e){if(void 0===e&&(e=!1),U){K(k);try{tY({type:f.Meta,data:{href:window.location.href,width:ti(),height:tn()}},e),null==ef||ef.cancel(),ef=void 0,eE.reset(),eO.init(),tS.forEach(e=>e.lock());var t,r,n=null;try{n=function(e,t){var r=t||{},n=r.mirror,i=void 0===n?new eS:n,s=r.blockClass,a=r.blockSelector,o=r.maskTextClass,l=r.maskTextSelector,h=r.inlineStylesheet,u=r.inlineImages,d=r.recordCanvas,c=r.canvasMaskingConfigured,p=r.maskAllInputs,f=void 0!==p&&p,m=r.maskTextFn,v=r.maskInputFn,g=r.maskAllElementAttributes,y=r.maskAttributeFn,b=r.slimDOM,w=r.dataURLOptions,S=r.preserveWhiteSpace,k=r.onSerialize,_=r.onIframeLoad,I=r.iframeLoadTimeout,M=r.onIframeListenerRegistered,C=r.onStylesheetLoad,R=r.stylesheetLoadTimeout,E=r.keepIframeSrcFn,T=r.maxDepth,x=r.inlineStylesheetBudgetRules,A=e2(void 0!==b&&b);K(x);try{return e1(e,{doc:e,mirror:i,blockClass:void 0===s?"rr-block":s,blockSelector:void 0===a?null:a,maskTextClass:void 0===o?"rr-mask":o,maskTextSelector:void 0===l?null:l,skipChild:!1,inlineStylesheet:void 0===h||h,maskInputOptions:!0===f?{color:!0,date:!0,"datetime-local":!0,email:!0,month:!0,number:!0,range:!0,search:!0,tel:!0,text:!0,time:!0,url:!0,week:!0,textarea:!0,select:!0,password:!0}:!1===f?{password:!0}:f,maskTextFn:m,maskInputFn:v,maskAllElementAttributes:void 0!==g&&g,maskAttributeFn:y,slimDOMOptions:A,dataURLOptions:w,inlineImages:void 0!==u&&u,recordCanvas:void 0!==d&&d,canvasMaskingConfigured:c,preserveWhiteSpace:S,onSerialize:k,onIframeLoad:_,iframeLoadTimeout:I,onIframeListenerRegistered:M,onStylesheetLoad:C,stylesheetLoadTimeout:R,keepIframeSrcFn:void 0===E?()=>!1:E,newlyAddedElement:!1,maxDepth:T})}finally{ee()}}(document,{mirror:t9,blockClass:a,blockSelector:l,maskTextClass:g,maskTextSelector:b,inlineStylesheet:S,maskAllInputs:ev,inlineStylesheetBudgetRules:k,maskTextFn:R,maskInputFn:C,maskAllElementAttributes:T,maskAttributeFn:x,slimDOM:eg,dataURLOptions:ed,recordCanvas:$,canvasMaskingConfigured:eL,inlineImages:en,onSerialize(e){th(e,t9)&&eT.addIframe(e),tu(e,t9)&&eE.trackLinkElement(e),td(e)&&eO.addShadowRoot(N(e),document)},onIframeLoad(e,t){eT.attachIframe(e,t),eO.observeAttachShadow(e)},onIframeListenerRegistered(e,t){eT.registerLoadListenerDisposer(e,t)},onStylesheetLoad(e,t){eE.attachLinkElement(e,t)},keepIframeSrcFn:ea})}finally{t=Z,Z=[],r=t}if(!n)return console.warn("Failed to snapshot the document");if(tY({type:f.FullSnapshot,data:{node:n,initialOffset:tr(window)}},e),tS.forEach(e=>e.unlock()),tK.onFullSnapshot(),r.length){var i,s,o,h,u,d,c,p,m,v,y=(i=r,s=()=>{ef===y&&(ef=void 0)},o=!1,h=null,u=0,d=null,c=()=>null!==d||i.length>u,p=()=>{var e=i[u];i[u]=null,u+=1,e&&e8(()=>{d=eE.beginDeferredLinkInlining(e,t9.getId(e))})},m=()=>{if(d){var e=d,t=!0;e8(()=>{t=e.advance(200)}),t&&(d=null)}},v=e=>{if(h=null,!o){var t=0;do{try{d||p(),m()}catch(e){null==d||d.discard(),d=null,eo(1)}t+=1}while(!o&&c()&&(e?!e.didTimeout&&e.timeRemaining()>5:10>t));o||(c()?h=re(v):s())}},h=re(v),{cancel(){o=!0,null==d||d.discard(),d=null,null==h||h.cancel(),h=null},flush(){if(!o){o=!0,null==h||h.cancel(),h=null;for(var e=0,t=0;c()&&50>e;){d||p();var r=d;if(r)if(Math.floor(r.remainingRules()/200)+1>50-e)r.discard(),d=null,t+=1;else{try{m()}catch(e){null==d||d.discard(),d=null,t+=1}e+=1}}if(c()||t>0){for(var n=t+ +(null!==d),a=u;i.length>a;a++)null!==i[a]&&(n+=1);eo(n),null==d||d.discard(),d=null}s()}}});ef=y}G&&eT.reattachIframes(),document.adoptedStyleSheets&&document.adoptedStyleSheets.length>0&&eE.adoptStyleSheets(document.adoptedStyleSheets,t9.getId(document))}finally{ee()}}};try{var eD=[];for(var eN of(eD.push(e5("pagehide",()=>{try{null==ef||ef.flush()}catch(e){}ef=void 0},window)),["visibilitychange","freeze","resume"]))eD.push(e5(eN,W,document));eb=e=>{var t=e_.get(e);
1t&&(t.forEach(e=>{e8(e);var t=eD.indexOf(e);-1!==t&&eD.splice(t,1)}),e_.delete(e))},ew=()=>{for(var e of e_){var t=e[0],r=t9.getNode(t);if(r)try{r.contentDocument&&r.contentDocument.defaultView||null==eb||eb(t)}catch(e){null==eb||eb(t)}else null==eb||eb(t)}};var eF=e=>{var t;return tw(tA)({mutationCb:eM,mousemoveCb:(e,t)=>tY({type:f.IncrementalSnapshot,data:{source:t,positions:e}}),mouseInteractionCb:e=>tY({type:f.IncrementalSnapshot,data:h({source:m.MouseInteraction},e)}),scrollCb:eC,viewportResizeCb:e=>tY({type:f.IncrementalSnapshot,data:h({source:m.ViewportResize},e)}),inputCb:e=>tY({type:f.IncrementalSnapshot,data:h({source:m.Input},e)}),mediaInteractionCb:e=>tY({type:f.IncrementalSnapshot,data:h({source:m.MediaInteraction},e)}),styleSheetRuleCb:e=>tY({type:f.IncrementalSnapshot,data:h({source:m.StyleSheetRule},e)}),styleDeclarationCb:e=>tY({type:f.IncrementalSnapshot,data:h({source:m.StyleDeclaration},e)}),canvasMutationCb:eR,fontCb:e=>tY({type:f.IncrementalSnapshot,data:h({source:m.Font},e)}),selectionCb(e){tY({type:f.IncrementalSnapshot,data:h({source:m.Selection},e)})},customElementCb(e){tY({type:f.IncrementalSnapshot,data:h({source:m.CustomElement},e)})},blockClass:a,ignoreClass:d,ignoreSelector:p,maskTextClass:g,maskTextSelector:b,maskInputOptions:ev,inlineStylesheet:S,sampling:D,recordDOM:U,recordCanvas:$,canvasMaskingConfigured:eL,inlineImages:en,userTriggeredOnInput:Y,collectFonts:et,doc:e,maskInputFn:C,maskTextFn:R,maskAllElementAttributes:T,maskAttributeFn:x,keepIframeSrcFn:ea,blockSelector:l,slimDOMOptions:eg,dataURLOptions:ed,mirror:t9,iframeManager:eT,stylesheetManager:eE,shadowDomManager:eO,processedNodeManager:eA,canvasManager:tK,ignoreCSSAttributes:eh,attributeFilter:eu,plugins:(null==(t=null==ei?void 0:ei.filter(e=>e.observer))?void 0:t.map(e=>({observer:e.observer,options:e.options,callback:t=>tY({type:f.Plugin,data:{plugin:e.name,payload:t}})})))||[]},A)};eT.addLoadListener(e=>{try{var t=t9.getId(e),r=eF(e.contentDocument);if(eD.push(r),-1!==t){var n=e_.get(t);n||e_.set(t,n=new Set),n.add(r)}}catch(e){console.warn(e)}}),eT.addPageHideListener(e=>{var t=t9.getId(e);null==eb||eb(t),tM(e)});var eP=-1,eH=e=>tY({type:f.Custom,data:{tag:"rrweb/fullscreen",payload:e}}),eB=()=>{var e,t,r,n,i=document,s=null!=(e=null!=(t=null!=(r=null!=(n=i.fullscreenElement)?n:i.webkitFullscreenElement)?r:i.mozFullScreenElement)?t:i.msFullscreenElement)?e:null,a=s?t9.getId(s):-1;a!==eP&&(-1!==eP&&eH({id:eP,enter:!1}),eP=a,-1!==a&&eH({id:a,enter:!0}))},eW=()=>{tQ(),eD.push(eF(document)),eD.push(e5("fullscreenchange",eB)),eD.push(e5("webkitfullscreenchange",eB)),eD.push(e5("mozfullscreenchange",eB)),eD.push(e5("MSFullscreenChange",eB)),t8=!0};return["interactive","complete"].includes(document.readyState)?eW():(eD.push(e5("DOMContentLoaded",()=>{tY({type:f.DomContentLoaded,data:{}}),"DOMContentLoaded"===X&&eW()})),eD.push(e5("load",()=>{tY({type:f.Load,data:{}}),"load"===X&&eW()},window))),()=>{try{null==ef||ef.flush()}catch(e){}ef=void 0,eD.forEach(e=>e8(e)),eA.destroy(),eT.removeLoadListener(),eT.destroy(),e_.clear(),eO.reset(),t9.reset(),t8=!1,tJ=void 0}}catch(e){console.warn(e)}}rt.addCustomEvent=(e,t)=>{if(!t8)throw Error("please add custom event after start recording");tY({type:f.Custom,data:{tag:e,payload:t}})},rt.freezePage=()=>{tS.forEach(e=>e.freeze())},rt.takeFullSnapshot=e=>{if(!t8)throw Error("please take full snapshot after start recording");tQ(e)},rt.mirror=t9;var rr=Object.defineProperty,rn=(e,t,r)=>{let n;return(n="symbol"!=typeof t?t+"":t)in e?rr(e,n,{enumerable:!0,configurable:!0,writable:!0,value:r}):e[n]=r};class ri{constructor(e){rn(this,"fileName"),rn(this,"functionName"),rn(this,"lineNumber"),rn(this,"columnNumber"),this.fileName=e.fileName||"",this.functionName=e.functionName||"",this.lineNumber=e.lineNumber,this.columnNumber=e.columnNumber}toString(){var e=this.lineNumber||"",t=this.columnNumber||"";return this.functionName?this.functionName+" ("+this.fileName+":"+e+":"+t+")":this.fileName+":"+e+":"+t}}var rs=/(^|@)\S+:\d+/,ra=/^\s*at .*(\S+:\d+|\(native\))/m,ro=/^(eval@)?(\[native code])?$/,rl={parse(e){return e?void 0!==e.stacktrace||void 0!==e["opera#sourceloc"]?this.parseOpera(e):e.stack&&e.stack.match(ra)?this.parseV8OrIE(e):e.stack?this.parseFFOrSafari(e):[]:[]},extractLocation(e){if(-1===e.indexOf(":"))return[e];var t=/(.+?)(?::(\d+))?(?::(\d+))?$/.exec(e.replace(/[()]/g,""));if(!t)throw Error("Cannot parse given url: "+e);return[t[1],t[2]||void 0,t[3]||void 0]},parseV8OrIE(e){return e.stack.split("\n").filter(function(e){return!!e.match(ra)},this).map(function(e){e.indexOf("(eval ")>-1&&(e=e.replace(/eval code/g,"eval").replace(/(\(eval at [^()]*)|(\),.*$)/g,""));var t=e.replace(/^\s+/,"").replace(/\(eval code/g,"("),r=t.match(/ (\((.+):(\d+):(\d+)\)$)/),n=(t=r?t.replace(r[0],""):t).split(/\s+/).slice(1),i=this.extractLocation(r?r[1]:n.pop());return new ri({functionName:n.join(" ")||void 0,fileName:["eval","<anonymous>"].indexOf(i[0])>-1?void 0:i[0],lineNumber:i[1],columnNumber:i[2]})},this)},parseFFOrSafari(e){return e.stack.split("\n").filter(function(e){return!e.match(ro)},this).map(function(e){if(e.indexOf(" > eval")>-1&&(e=e.replace(/ line (\d+)(?: > eval line \d+)* > eval:\d+:\d+/g,":$1")),-1===e.indexOf("@")&&-1===e.indexOf(":"))return new ri({functionName:e});var t=/((.*".+"[^@]*)?[^@]*)(?:@)/,r=e.match(t),n=r&&r[1]?r[1]:void 0,i=this.extractLocation(e.replace(t,""));return new ri({functionName:n,fileName:i[0],lineNumber:i[1],columnNumber:i[2]})},this)},parseOpera(e){return!e.stacktrace||e.message.indexOf("\n")>-1&&e.message.split("\n").length>e.stacktrace.split("\n").length?this.parseOpera9(e):e.stack?this.parseOpera11(e):this.parseOpera10(e)},parseOpera9(e){for(var t=/Line (\d+).*script (?:in )?(\S+)/i,r=e.message.split("\n"),n=[],i=2,s=r.length;s>i;i+=2){var a=t.exec(r[i]);a&&n.push(new ri({fileName:a[2],lineNumber:parseFloat(a[1])}))}return n},parseOpera10(e){for(var t=/Line (\d+).*script (?:in )?(\S+)(?:: In function (\S+))?$/i,r=e.stacktrace.split("\n"),n=[],i=0,s=r.length;s>i;i+=2){var a=t.exec(r[i]);a&&n.push(new ri({functionName:a[3]||void 0,fileName:a[2],lineNumber:parseFloat(a[1])}))}return n},parseOpera11(e){return e.stack.split("\n").filter(function(e){return!!e.match(rs)&&!e.match(/^Error created at/)},this).map(function(e){var t=e.split("@"),r=this.extractLocation(t.pop());return new ri({functionName:(t.shift()||"").replace(/<anonymous function(: (\w+))?>/,"$2").replace(/\([^)]*\)/g,"")||void 0,fileName:r[0],lineNumber:r[1],columnNumber:r[2]})},this)}};function rh(e){return Array.isArray(e)}function ru(e){return"object"==typeof e&&null!==e&&!rh(e)}
1function rd(e,t){var r={numOfKeysLimit:50,depthOfLimit:4};Object.assign(r,t);var n=[],i=[];return JSON.stringify(e,function(e,t){if(n.length>0){var s,a,o=n.indexOf(this);~o?n.splice(o+1):n.push(this),~o?i.splice(o,1/0,e):i.push(e),~n.indexOf(t)&&(t=n[0]===t?"[Circular ~]":"[Circular ~."+i.slice(0,n.indexOf(t)).join(".")+"]")}else n.push(t);if(null===t)return t;if(void 0===t)return"undefined";if(ru(a=t)&&Object.keys(a).length>r.numOfKeysLimit||"function"==typeof a||ru(a)&&function e(t,r){if(0===r)return!0;for(var n of Object.keys(t))if(ru(t[n])&&e(t[n],r-1))return!0;return!1}(a,r.depthOfLimit))return s=t.toString(),r.stringLengthLimit&&s.length>r.stringLengthLimit&&(s=s.slice(0,r.stringLengthLimit)+"..."),s;if("bigint"==typeof t)return t.toString()+"n";if(t instanceof Event){var l={};for(var h in t){var u=t[h];l[h]=rh(u)?function(e){if(!e||!e.outerHTML)return"";for(var t="";e.parentElement;){var r=e.localName;if(!r)break;r=r.toLowerCase();var n=e.parentElement,i=[];if(n.children&&n.children.length>0)for(var s=0;n.children.length>s;s++){var a=n.children[s];a.localName&&a.localName.toLowerCase&&a.localName.toLowerCase()===r&&i.push(a)}i.length>1&&(r+=":eq("+i.indexOf(e)+")"),t=r+(t?">"+t:""),e=n}return t}(u.length?u[0]:null):u}return l}return t instanceof Node?t instanceof HTMLElement?t?t.outerHTML:"":t.nodeName:t instanceof Error?t.stack?t.stack+"\nEnd of stack for Error object":t.name+": "+t.message:t})}var rc={level:["assert","clear","count","countReset","debug","dir","dirxml","error","group","groupCollapsed","groupEnd","info","log","table","time","timeEnd","timeLog","trace","warn"],lengthThreshold:1e3,logger:"console"};function rp(e,t,r){var n,i=r?Object.assign({},rc,r):rc,s=i.logger;if(!s)return()=>{};n="string"==typeof s?t[s]:s;var a=0,o=!1,l=[];
1if(i.level.includes("error")){var h=t=>{var r=t.message;e({level:"error",trace:rl.parse(t.error).map(e=>e.toString()),payload:[rd(r,i.stringifyOptions)]})};t.addEventListener("error",h),l.push(()=>{t.removeEventListener("error",h)});var u=t=>{var r,n;t.reason instanceof Error?n=[rd("Uncaught (in promise) "+(r=t.reason).name+": "+r.message,i.stringifyOptions)]:(r=Error(),n=[rd("Uncaught (in promise)",i.stringifyOptions),rd(t.reason,i.stringifyOptions)]),e({level:"error",trace:rl.parse(r).map(e=>e.toString()),payload:n})};t.addEventListener("unhandledrejection",u),l.push(()=>{t.removeEventListener("unhandledrejection",u)})}for(var d of i.level)l.push(function(t,r){var n=this;return t[r]?function(t,s){try{let d;if(!(s in t))return()=>{};var l=t[s],h={next:l},u=(d=function(){for(var e=arguments.length,t=Array(e),r=0;e>r;r++)t[r]=arguments[r];return h.next.apply(this,t)},function(){for(var t=arguments.length,s=Array(t),l=0;t>l;l++)s[l]=arguments[l];if(d.apply(n,s),!("assert"===r&&s[0]||o)){o=!0;try{var h=rl.parse(Error()).map(e=>e.toString()).splice(1),u=("assert"===r?s.slice(1):s).map(e=>rd(e,i.stringifyOptions));a++,i.lengthThreshold>a?e({level:r,trace:h,payload:u}):a===i.lengthThreshold&&e({level:"warn",trace:[],payload:[rd("The number of log records reached the threshold.")]})}catch(e){d("rrweb logger error:",e,...s)}finally{o=!1}}});return"function"==typeof u&&(u.prototype=u.prototype||{},Object.defineProperties(u,{__rrweb_original__:{enumerable:!1,value:l},__rrweb_layer__:{enumerable:!1,value:h}})),t[s]=u,()=>{if(t[s]!==u)for(var e=t[s];"function"==typeof e&&e.__rrweb_layer__;){var r=e.__rrweb_layer__;if(r.next===u)return void(r.next=h.next);e=r.next}else t[s]=h.next}}catch(e){return()=>{}}}(t,r):()=>{}}(n,d));return()=>{l.forEach(e=>e())}}var rf="u">typeof window?window:void 0,rm="u">typeof globalThis?globalThis:rf,rv=null==rm?void 0:rm.document,rg=null==rm?void 0:rm.location;null!=rm&&rm.XMLHttpRequest&&new rm.XMLHttpRequest;var ry="u">typeof globalThis?globalThis:rf;ry&&"u"<typeof self&&(ry.self=ry),ry&&"u"<typeof File&&(ry.File=function(){});var rb,rw,rS=null!=rf?rf:{},rk="NativeGzipValidationError",r_=e=>{var t=Error("Native gzip produced invalid output: "+e);throw t.name=rk,t},rI=(rb=l(function*(e,t){18>e.size&&r_("too-short");var r=new Uint8Array((yield e.slice(0,10).arrayBuffer()));(2>r.length||31!==r[0]||139!==r[1]||8!==r[2])&&r_("invalid-header");var n=new DataView((yield e.slice(e.size-8).arrayBuffer()));n.getUint32(0,!0)!==(e=>{for(var t=(()=>{if(rw)return rw;rw=[];for(var e=0;256>e;e++){for(var t=e,r=0;8>r;r++)t=1&t?0xedb88320^t>>>1:t>>>1;rw[e]=t>>>0}return rw})(),r=0xffffffff,n=0;e.length>n;n++)r=t[255&(r^e[n])]^r>>>8;return(0xffffffff^r)>>>0})(t)&&r_("invalid-crc");var i=t.length>>>0;n.getUint32(4,!0)!==i&&r_("invalid-size")}),function(e,t){return rb.apply(this,arguments)});function rM(){return(rM=l(function*(e,t,r){void 0===t&&(t=!0);try{var n,i=(new TextEncoder).encode(e),s=new globalThis.CompressionStream("gzip"),a=s.writable.getWriter(),o=a.write(i).then(()=>a.close()).catch((n=l(function*(e){try{yield a.abort(e)}catch(e){}throw e}),function(e){return n.apply(this,arguments)})),h=new Response(s.readable).blob(),u=(yield Promise.all([h,o]))[0];return yield rI(u,i),u}catch(e){if(null!=r&&r.rethrow)throw e;return t&&console.error("Failed to gzip compress data",e),null}})).apply(this,arguments)}var rC=Object.prototype,rR=rC.hasOwnProperty,rE=rC.toString,rT=Array.isArray||function(e){return"[object Array]"===rE.call(e)},rx=e=>"function"==typeof e,rA=e=>e===Object(e)&&!rT(e),rL=e=>void 0===e,rO=e=>"[object String]"==rE.call(e),rD=e=>null===e,rN=e=>rL(e)||rD(e),rF=e=>"[object Number]"==rE.call(e)&&e==e,rP=e=>"[object Boolean]"===rE.call(e);function rH(e,t,r,n,i){return t>r&&(n.warn("min cannot be greater than max."),t=r),rF(e)?e>r?(n.warn(" cannot be greater than max: "+r+". Using max value instead."),r):t>e?(n.warn(" cannot be less than min: "+t+". Using min value instead."),t):e:(n.warn(" must be a number. using max or fallback. max: "+r+", fallback: "+i),rH(i||r,t,r,n))}class rB{constructor(e){this.tt={},this.et=e.et,this.it=rH(e.bucketSize,0,100,e.rt),this.nt=rH(e.refillRate,0,this.it,e.rt),this.st=rH(e.refillInterval,0,864e5,e.rt)}ot(e,t){var r=Math.floor((t-e.lastAccess)/this.st);r>0&&(e.tokens=Math.min(e.tokens+r*this.nt,this.it),e.lastAccess=e.lastAccess+r*this.st)}consumeRateLimit(e){var t,r=Date.now(),n=String(e),i=this.tt[n];return i?this.ot(i,r):this.tt[n]=i={tokens:this.it,lastAccess:r},0===i.tokens||(i.tokens--,0===i.tokens&&(null==(t=this.et)||t.call(this,e)),0===i.tokens)}stop(){this.tt={}}}function rW(e){return e?e.split("#")[0]:e}var rz={DEBUG:!1,LIB_VERSION:"0.5.0",LIB_NAME:"browser-common"},rU=function(e,t){var r=(void 0===t?{}:t).debugEnabled,n={k(t){if(rf&&(rz.DEBUG||rf.POSTHOG_DEBUG||r)&&!rL(rf.console)&&rf.console){for(var n=("__rrweb_original__"in rf.console[t])?rf.console[t].__rrweb_original__:rf.console[t],i=arguments.length,s=Array(i>1?i-1:0),a=1;i>a;a++)s[a-1]=arguments[a];n(e,...s)}},debug(){for(var e=arguments.length,t=Array(e),r=0;e>r;r++)t[r]=arguments[r];n.k("debug",...t)},info(){for(var e=arguments.length,t=Array(e),r=0;e>r;r++)t[r]=arguments[r];n.k("log",...t)},warn(){for(var e=arguments.length,t=Array(e),r=0;e>r;r++)t[r]=arguments[r];n.k("warn",...t)},error(){for(var e=arguments.length,t=Array(e),r=0;e>r;r++)t[r]=arguments[r];n.k("error",...t)},critical(){for(var t=arguments.length,r=Array(t),n=0;t>n;n++)r[n]=arguments[n];console.error(e,...r)},uninitializedWarning(e){n.error("You must initialize PostHog before calling "+e)},createLogger:(t,r)=>rU(e+" "+t,r)};return n},rq=rU("[PostHog.js]"),r$=rq.createLogger;function rj(e,t){if(!rN(e))if(rT(e))e.forEach(t);else if(e instanceof FormData)e.forEach((e,r)=>t(e,r));else for(var r in e)rR.call(e,r)&&t(e[r],r)}function rG(e,t,r,n){var i={},s=i.capture,a=i.passive;null==e||e.addEventListener(t,r,{capture:void 0!==s&&s,passive:void 0===a||a})}var rV=["localhost","127.0.0.1"],rZ=e=>{var t=null==rv?void 0:rv.createElement("a");return rL(t)?null:(t.href=e,t)},rX=function(e,t){void 0===t&&(t="&");var r,n,i=[];return rj(e,function(e,t){rL(e)||rL(t)||"undefined"===t||(r=encodeURIComponent(e instanceof File?e.name:e.toString()),n=encodeURIComponent(t),i[i.length]=n+"="+r)}),i.join(t)},rJ=()=>{};function rY(e,t,r){try{if(!(t in e))return rJ;var n={next:e[t]},i=r(function(){for(var e=arguments.length,t=Array(e),r=0;e>r;r++)t[r]=arguments[r];return n.next.apply(this,t)});return rx(i)&&(i.prototype=i.prototype||{},Object.defineProperties(i,{__posthog_wrapped__:{enumerable:!1,value:!0},__posthog_layer__:{enumerable:!1,value:n}})),e[t]=i,()=>{if(e[t]!==i)for(var r=e[t];rx(r)&&r.__posthog_layer__;){var s=r.__posthog_layer__;if(s.next===i)return void(s.next=n.next);r=s.next}else e[t]=n.next}}catch(e){return rJ}}function rQ(e,t){var r,n=function(e){try{return"string"==typeof e?new URL(e).hostname:"url"in e?new URL(e.url).hostname:e.hostname}catch(e){return null}}(e),i={hostname:n,isHostDenied:!1};if(null==(r=t.payloadHostDenyList)||!r.length||null==n||!n.trim().length)return i;for(var s of t.payloadHostDenyList)if(n.endsWith(s))return{hostname:n,isHostDenied:!0};return i}function rK(e){var t,r=null==rf||null==(t=rf.location)?void 0:t.href;return rL(r)?void 0:function(e,t){var r,n=null==e||null==(r=e.config)?void 0:r.get_current_url;if(!rx(n))return t;try{var i=n(t);return rO(i)&&i?i:t}catch(e){return rq.error("Error in get_current_url, falling back to window.location.href",e),t}}(e,r)}var r0=RegExp("^(?:(4[0-9]{12}(?:[0-9]{3})?)|(5[1-5][0-9]{14})|(6(?:011|5[0-9]{2})[0-9]{12})|(3[47][0-9]{13})|(3(?:0[0-5]|[68][0-9])[0-9]{11}
1)|((?:2131|1800|35[0-9]{3})[0-9]{11}))$"),r1=/(^|[^0-9A-Za-z_])([0-9][0-9 -]*[0-9])(?=$|[^0-9A-Za-z_])/g,r2=[16,15,14,13],r3=RegExp("(^|[^0-9])((?!000|666)[0-9]{3}-?(?!00)[0-9]{2}-?(?!0000)[0-9]{4})(?=$|([^0-9]))","g"),r5=/[0-9A-Za-z_]/,r4="[SessionRecording]",r8="redacted";function r6(e){var t;return Math.min(1e6,null!=(t=e.payloadSizeLimitBytes)?t:1e6)}var r9={initiatorTypes:["audio","beacon","body","css","early-hint","embed","fetch","frame","iframe","icon","image","img","input","link","navigation","object","ping","script","track","video","xmlhttprequest"],maskRequestFn:e=>e,recordHeaders:!1,recordBody:!1,recordInitialRequests:!1,recordPerformance:!1,performanceEntryTypeToObserve:["first-input","navigation","paint","resource"],payloadSizeLimitBytes:1e6,payloadHostDenyList:[".lr-ingest.io",".ingest.sentry.io",".clarity.ms","google-analytics.com","analytics.google.com","nr-data.net","datadoghq.com","datadoghq.eu","ddog-gov.com","segment.io","rudderstack.com","amplitude.com","mixpanel.com","hotjar.com","hotjar.io","fullstory.com"],streamNetworkBody:!1},r7=["authorization","x-forwarded-for","authorization","cookie","set-cookie","x-api-key","x-real-ip","remote-addr","forwarded","proxy-authorization","x-csrf-token","x-csrftoken","x-xsrf-token"],ne=["password","secret","passwd","api_key","apikey","auth","credentials","mysql_pwd","privatekey","private_key","token"],nt=["auth","token","secret","session","api-key","apikey","api_key","credential","password","passwd","cookie","csrf","xsrf"],nr=e=>{rN(e)||rj(Object.keys(e),t=>{var r;r=t.toLowerCase(),(r7.includes(r)||nt.some(e=>r.includes(e)))&&(e[t]=r8)})},nn=["/s/","/e/","/i/"];function ni(e,t,r,n){if(rN(e))return e;var i=(null==t?void 0:t["content-length"])||new Blob([e]).size;return rO(i)&&(i=parseInt(i)),i>r?r4+" "+n+" body too large to record ("+i+" bytes)":e}function ns(e,t){if(rN(e))return e;var r,n=e;return!(rN(r=n)||rO(r)&&(function(e){var t;for(r1.lastIndex=0;t=r1.exec(e);){var r=t[2];if(r)for(var n=r.replace(/[- ]/g,""),i=0;n.length>i;i++)for(var s of r2){var a=i+s;if(n.length>=a){var o=n.slice(i,a);if(r0.test(o)&&function(e){for(var t=0,r=!1,n=e.length-1;n>=0;n--){var i=e.charCodeAt(n)-48;r&&(i*=2)>9&&(i-=9),t+=i,r=!r}return t%10==0}(o))return!0}}}return!1}(r=r.trim())||function(e){var t;for(r3.lastIndex=0;t=r3.exec(e);){var r=t[1],n=t[3];if(!(r&&n&&r5.test(r)&&r5.test(n)))return!0}return!1}(r)))&&1||(n=r4+" "+t+" body "+r8),rj(ne,e=>{var r,i;null!=(r=n)&&r.length&&-1!==(null==(i=n)?void 0:i.indexOf(e))&&(n=r4+" "+t+" body "+r8+" as might contain: "+e)}),n}var na=new WeakSet,no=r$("[Recorder]"),nl=e=>"resource"===e.entryType;function nh(e,t){return!!t&&(rP(t)||t[e])}function nu(e){if("u"<typeof Request)return!1;if(e instanceof Request)return!0;try{return"[object Request]"===({}).toString.call(e)}catch(e){return!1}}var nd=["image/","video/","audio/","font/","application/octet-stream","application/pdf","application/zip","application/wasm"];function nc(e){var t=e.type,r=e.recordBody,n=e.headers;function i(e){var t=Object.keys(n).find(e=>"content-type"===e.toLowerCase()),r=t&&n[t];return e.some(e=>null==r?void 0:r.toLowerCase().includes(e))}if(!r||function e(t){try{return"string"==typeof t?t.startsWith("blob:"):t instanceof URL?"blob:"===t.protocol:!!nu(t)&&e(t.url)}catch(e){return!1}}(e.url)||i(nd))return!1;if(rP(r))return!0;if(rT(r))return i(r);var s=r[t];return rP(s)?s:i(s)}function np(e,t,r,n,i,s){return nf.apply(this,arguments)}function nf(){return(nf=l(function*(e,t,r,n,i,s){return(void 0===s&&(s=0),s>10)?(no.warn("Failed to get performance entry for request",{url:r,initiatorType:t}),null):function(e){for(var r,s=e.length-1;s>=0;s-=1)if(nl(r=e[s])&&r.initiatorType===t&&(rL(n)||r.startTime>=n)&&(rL(i)||i>=r.startTime))return e[s]}(e.performance.getEntriesByName(r))||(yield new Promise(e=>setTimeout(e,50*s)),np(e,t,r,n,i,s+1))})).apply(this,arguments)}function nm(e){var t=e.body,r=e.options,n=e.url;if(rN(t))return null;var i=rQ(n,r);if(i.isHostDenied)return i.hostname+" is in deny list";if(rO(t))return t;if("u">typeof Document&&t instanceof Document)return t.textContent;if(t instanceof FormData)return rX(t);if(rA(t))try{return JSON.stringify(t)}catch(e){return"[SessionReplay] Failed to stringify response object"}return"[SessionReplay] Cannot read body of type "+toString.call(t)}function nv(e){var t=e.entry,r=e.method,n=e.status,i=e.networkRequest,s=e.isInitial,a=e.start,o=e.end,l=e.url,u=e.initiatorType;a=t?t.startTime:a,o=t?t.responseEnd:o;var d=Math.floor(Date.now()-performance.now()),c=Math.floor(d+(a||0)),p=[h({},t?t.toJSON():{name:l},{startTime:rL(a)?void 0:Math.round(a),endTime:rL(o)?void 0:Math.round(o),timeOrigin:d,timestamp:c,method:r,initiatorType:u||(t?t.initiatorType:void 0),status:n,requestHeaders:i.requestHeaders,requestBody:i.requestBody,responseHeaders:i.responseHeaders,responseBody:i.responseBody,isInitial:s})];if(!rD(t)&&("navigation"===t.entryType||"resource"===t.entryType))for(var f of t.serverTiming||[])p.push({timeOrigin:d,timestamp:c,startTime:Math.round(t.startTime),name:f.name,duration:f.duration,entryType:"serverTiming"});return p}var ng=["video/","audio/"];function ny(e){return rA(e)&&rx(e.getReader)&&rx(e.tee)}var nb="[SessionReplay] Timeout while trying to read body",nw="[SessionReplay] Failed to read body";function nS(e){return"[SessionReplay] Body too large to record (> "+e+" bytes)"}function nk(e,t){if(!t.streamNetworkBody)return new Promise(t=>{var r=setTimeout(()=>t(nb),500);try{e.clone().text().then(e=>t(e),e=>t(nw+": "+e)).finally(()=>clearTimeout(r))}catch(e){clearTimeout(r),t(nw)}});var r=r6(t);return!function(e,t){try{var r,n=null==(r=e.headers)||null==r.get?void 0:r.get("content-length");if(!n)return!1;var i=parseInt(n,10);return Number.isFinite(i)&&i>t}catch(e){return!1}}(e,r)?new Promise(t=>{var n,i=!1;function s(){try{var e;null==(e=n)||e.cancel()}catch(e){}}function a(e){i||(i=!0,clearTimeout(l),s(),t(e))}var o,l=setTimeout(()=>a(nb),500);try{o=e.clone()}catch(e){return void a(nw)}var h=o.body;if(ny(h)&&"u">typeof TextDecoder){try{n=h.getReader()}catch(e){return void a(nw)}var u=[],d=0;!function e(){n.read().then(t=>{var n=t.done,o=t.value;if(i)s();
1else if(n)a((new TextDecoder).decode(function(e,t){var r=new Uint8Array(t),n=0;for(var i of e)r.set(i,n),n+=i.byteLength;return r}(u,d)));else{if(o){if(d+o.byteLength>r)return void a(nS(r));d+=o.byteLength,u.push(o)}e()}},e=>a(nw+": "+e))}()}else try{o.text().then(e=>a(e),e=>a(nw+": "+e))}catch(e){a(nw)}}):Promise.resolve(nS(r))}function n_(){return(n_=l(function*(e){var t=e.r,r=e.options,n=rQ(e.url,r);return n.isHostDenied?Promise.resolve(n.hostname+" is in deny list"):nk(t,r)})).apply(this,arguments)}function nI(){return(nI=l(function*(e){var t=e.r,r=e.options,n=function(e){var t,r=e.r,n=e.options,i=e.url;if("chunked"===r.headers.get("Transfer-Encoding"))return"Chunked Transfer-Encoding is not supported";var s=null==(t=r.headers.get("Content-Type"))?void 0:t.toLowerCase(),a=ng.some(e=>null==s?void 0:s.startsWith(e));if(s&&a)return"Content-Type "+s+" is not supported";var o=rQ(i,n);return o.isHostDenied?o.hostname+" is in deny list":null}({r:t,options:r,url:e.url});return rD(n)?nk(t,r):Promise.resolve(n)})).apply(this,arguments)}var nM=null;function nC(e,t,r){if(!("performance"in t))return()=>{};if(nM)return no.warn("Network observer already initialised, doing nothing"),()=>{};var n,i,s=r?Object.assign({},r9,r):r9,a=t=>{var r=[],n=!1;t.requests.forEach(e=>{var t="serverTiming"===e.entryType;if(!t||!n){var i=s.maskRequestFn(e);t||(n=!i||!!i&&na.has(i)),i&&r.push(i)}}),r.length>0&&e(h({},t,{requests:r}))},o=(s.recordInitialRequests&&a({requests:t.performance.getEntries().filter(e=>"navigation"===e.entryType||nl(e)&&s.initiatorTypes.includes(e.initiatorType)).flatMap(e=>nv({entry:e,method:void 0,status:void 0,networkRequest:{},isInitial:!0})),isInitial:!0}),n=new t.PerformanceObserver(e=>{a({requests:e.getEntries().filter(e=>"navigation"===e.entryType||nl(e)&&s.initiatorTypes.includes(e.initiatorType)&&(!s.recordBody&&!s.recordHeaders||"xmlhttprequest"!==e.initiatorType&&"fetch"!==e.initiatorType)).flatMap(e=>nv({entry:e,method:void 0,status:void 0,networkRequest:{}}))})}),i=PerformanceObserver.supportedEntryTypes.filter(e=>s.performanceEntryTypeToObserve.includes(e)),n.observe({entryTypes:i}),()=>{n.disconnect()}),u=()=>{},d=()=>{};return(s.recordHeaders||s.recordBody)&&(u=function(e,t,r){if(!r.initiatorTypes.includes("xmlhttprequest"))return()=>{};var n=nh("request",r.recordHeaders),i=nh("response",r.recordHeaders),s=rY(t.XMLHttpRequest.prototype,"open",s=>function(a,o,l,h,u){void 0===l&&(l=!0);var d=this;try{var c,p,f=new Request(o),m={},v={},g=d.setRequestHeader.bind(d);d.setRequestHeader=(e,t)=>(v[e]=t,g(e,t)),n&&(m.requestHeaders=v);var y=d.send.bind(d);d.send=e=>(nc({type:"request",headers:v,url:o,recordBody:r.recordBody})&&(m.requestBody=nm({body:e,options:r,url:o})),c=t.performance.now(),y(e));var b=()=>{d.removeEventListener("readystatechange",w),d.removeEventListener("error",b),d.removeEventListener("abort",b),d.removeEventListener("timeout",b)},w=()=>
1{if(d.readyState===d.DONE){b(),p=t.performance.now();var n={};d.getAllResponseHeaders().trim().split(/[\r\n]+/).forEach(e=>{var t=e.split(": "),r=t.shift(),i=t.join(": ");r&&(n[r]=i)}),i&&(m.responseHeaders=n),nc({type:"response",headers:n,url:o,recordBody:r.recordBody})&&(m.responseBody=nm({body:d.response,options:r,url:o})),np(t,"xmlhttprequest",f.url,c,p).then(t=>{var r=nv({entry:t,method:a,status:null==d?void 0:d.status,networkRequest:m,start:c,end:p,url:o.toString(),initiatorType:"xmlhttprequest"});e({requests:r})}).catch(()=>{})}};d.addEventListener("readystatechange",w),d.addEventListener("error",b),d.addEventListener("abort",b),d.addEventListener("timeout",b)}catch(e){no.error("Failed to instrument XHR for network capture",e)}s.call(d,a,o.toString(),l,h,u)});return()=>{s()}}(a,t,s),d=function(e,t,r){if(!r.initiatorTypes.includes("fetch"))return()=>{};var n=nh("request",r.recordHeaders),i=nh("response",r.recordHeaders),s=rY(t,"fetch",s=>{var a;return a=l(function*(a,o){try{l=new Request(a,o)}catch(e){return no.error("Failed to instrument fetch for network capture",e),s(a,o)}var l,h,u,d,c={};try{try{var p={};l.headers.forEach((e,t)=>{p[t]=e}),n&&(c.requestHeaders=p),!ny(null==o?void 0:o.body)&&nc({type:"request",headers:p,url:a,recordBody:r.recordBody})&&(c.requestBody=yield function(e){return n_.apply(this,arguments)}({r:l,options:r,url:a}))}catch(e){no.error("Failed to record fetch request for network capture",e)}u=t.performance.now(),h=nu(a)?yield s(l):yield s(a,o),d=t.performance.now();var f={};return h.headers.forEach((e,t)=>{f[t]=e}),i&&(c.responseHeaders=f),nc({type:"response",headers:f,url:a,recordBody:r.recordBody})&&(c.responseBody=yield function(e){return nI.apply(this,arguments)}({r:h,options:r,url:a})),h}finally{np(t,"fetch",l.url,u,d).then(t=>{var r;e({requests:nv({entry:t,method:l.method,status:null==(r=h)?void 0:r.status,networkRequest:c,start:u,end:d,url:l.url,initiatorType:"fetch"})})}).catch(()=>{})}}),function(e,t){return a.apply(this,arguments)}});return()=>{s()}}(a,t,s)),nM=()=>{o(),u(),d(),nM=null}}var nR="$session_recording_remote_config",nE="$replay_sample_rate",nT="$replay_override_sampling",nx="$replay_override_linked_flag",nA="$replay_override_url_trigger",nL="$replay_override_event_trigger",nO="$session_is_sampled",nD="$session_past_minimum_duration",nN="$session_recording_url_trigger_activated_session",nF="$session_recording_event_trigger_activated_session",nP="$posthog_sr_group_event_trigger_",nH="$posthog_sr_group_url_trigger_",nB="$posthog_sr_group_sampling_",nW="$debug_first_full_snapshot_timestamp",nz="$sess_rec_flush_size",nU="$stored_person_properties",nq="$sdk_debug_replay_remote_trigger_matching_config",n$="disabled",nj="sampled",nG="active",nV="buffering",nZ="paused",nX="rrweb_error",nJ="trigger",nY=nJ+"_activated",nQ=nJ+"_pending",nK=nJ+"_"+n$;function n0(e,t,r,n,i,s){return 0===t?nK:(null==e?void 0:e.get_property(r?n+r:i))===s?nY:nQ}function n1(e,t,r){return t.some(t=>{var n;return"regex"===t.matching&&(null!=(n=null==r?void 0:r.get(t.url))?n:new RegExp(t.url)).test(e)})}class n2{constructor(e){this.u=e}triggerStatus(e){var t=this.u.map(t=>t.triggerStatus(e));return t.includes(nY)?nY:t.includes(nQ)?nQ:nK}stop(){this.u.forEach(e=>e.stop())}}class n3{constructor(e){this.u=e}triggerStatus(e){var t=new Set;for(var r of this.u)t.add(r.triggerStatus(e));switch(t.delete(nK),t.size){case 0:return nK;case 1:return Array.from(t)[0];default:return nQ}}stop(){this.u.forEach(e=>e.stop())}}class n5{triggerStatus(){return nY}stop(){}}class n4{constructor(e,t){this.th=[],this.eh=[],this.rh=new Map,this.ih=new Map,this.nh="",this.urlBlocked=!1,this._instance=e,this.sh=t}onConfig(e){var t,r;this.th=("sessionRecording"in e?rA(e.sessionRecording)?null==(t=e.sessionRecording)?void 0:t.urlTriggers:[]:null==e?void 0:e.urlTriggers)||[],this.eh=("sessionRecording"in e?rA(e.sessionRecording)?null==(r=e.sessionRecording)?void 0:r.urlBlocklist:[]:null==e?void 0:e.urlBlocklist)||[],this.ah()}ah(){for(var e of(this.rh.clear(),this.ih.clear(),this.th))if("regex"===e.matching&&!this.rh.has(e.url))try{this.rh.set(e.url,new RegExp(e.url))}catch(t){rq.error("Invalid URL trigger regex pattern:",e.url,t)}for(var t of this.eh)if("regex"===t.matching&&!this.ih.has(t.url))try{this.ih.set(t.url,new RegExp(t.url))}catch(e){rq.error("Invalid URL blocklist regex pattern:",t.url,e)}}onRemoteConfig(e){this.onConfig(e)}oh(e){return n0(this._instance,this.th.length,this.sh,nH,nN,e)}triggerStatus(e){var t=this.oh(e),r=t===nY?nY:t===nQ?nQ:nK;return this._instance.register_for_session({$sdk_debug_replay_url_trigger_status:r}),r}checkUrlBlocklist(e,t){var r=rK(this._instance);if(r&&r!==this.nh){this.nh=r;var n=this.urlBlocked,i=n1(r,this.eh,this.ih);n&&i||(i&&!n?e():!i&&n&&t())}}checkUrlTriggerConditions(e,t,r,n){var i=rK(this._instance);if(i&&i!==this.nh){this.nh=i;var s=this.urlBlocked,a=n1(i,this.eh,this.ih);a&&!s?e():!a&&s&&t();var o=this.oh(n)===nY,l=n1(i,this.th,this.rh);!o&&l&&r("url",i)}}stop(){this.nh=""}}class n8{constructor(e){this.linkedFlag=null,this.linkedFlagSeen=!1,this.uh=()=>{},this._instance=e}triggerStatus(){var e=nQ;return rN(this.linkedFlag)&&(e=nK),this.linkedFlagSeen&&(e=nY),this._instance.register_for_session({$sdk_debug_replay_linked_flag_trigger_status:e}),e}onConfig(e,t){var r;if(this.linkedFlag=("sessionRecording"in e?rA(e.sessionRecording)?null==(r=e.sessionRecording)?void 0:r.linkedFlag:null:null==e?void 0:e.linkedFlag)||null,!rN(this.linkedFlag)&&!this.linkedFlagSeen){var n=rO(this.linkedFlag)?this.linkedFlag:this.linkedFlag.flag,i=rO(this.linkedFlag)?null:this.linkedFlag.variant;this.uh=this._instance.onFeatureFlags((e,r)=>{var s=!1;if(rA(r)&&n in r){var a=r[n];s=rP(a)?!0===a:i?a===i:!!a}var o=s&&!this.linkedFlagSeen;this.linkedFlagSeen=s,o&&t(n,i)})}}onRemoteConfig(e,t){this.onConfig(e,t)}stop(){this.uh()}}class n6{constructor(e,t){this.lh=[],this._instance=e,this.sh=t}onConfig(e){var t;this.lh=("sessionRecording"in e?rA(e.sessionRecording)?null==(t=e.sessionRecording)?void 0:t.eventTriggers:[]:null==e?void 0:e.eventTriggers)||[]}onRemoteConfig(e){this.onConfig(e)}hh(e){return n0(this._instance,this.lh.length,this.sh,nP,nF,e)}triggerStatus(e){var t=this.hh(e),r=t===nY?nY:t===nQ?nQ:nK;return this._instance.register_for_session({$sdk_debug_replay_event_trigger_status:r}),r}checkEventTriggerConditions(e,t,r){if(0!==this.lh.length){var n=this.hh(r)===nY,i=this.lh.includes(e);!n&&i&&t("event",e)}}stop(){}}class n9{constructor(e,t,r){if(this._instance=e,this.group=t,this.dh=new n4(e,t.id),this.fh=new n6(e,t.id),this.ph=new n8(e),t.conditions.events&&t.conditions.events.length>0||t.conditions.urls&&t.conditions.urls.length>0||t.conditions.flag){var n=(t.conditions.events||[]).map(e=>e.name),i={urlTriggers:t.conditions.urls||[],eventTriggers:n,linkedFlag:t.conditions.flag||null,urlBlocklist:[]};this.dh.onConfig(i),this.fh.onConfig(i),this.ph.onConfig(i,r);var s=[this.fh,this.dh,this.ph];this.mh="any"===t.conditions.matchType?new n2(s):new n3(s)}else this.mh=new n5}triggerStatus(e){return this.mh.triggerStatus(e)}checkEventTriggerConditions(e,t,r){this.fh.checkEventTriggerConditions(e,t,r)}checkUrlTriggerConditions(e,t,r,n){this.dh.checkUrlTriggerConditions(e,t,r,n)}activateTrigger(e,t){var r;null==(r=this._instance.persistence)||r.register({["url"===e?nH+this.group.id:nP+this.group.id]:t})}stop(){this.dh.stop(),this.fh.stop(),this.ph.stop()}}function n7(e){if(e.rrwebError)return nX;if(!e.receivedFlags)return nV;if(!e.isRecordingEnabled)return n$;if(e.urlTriggerMatching.urlBlocked)return nZ;var t=!0===e.isSampled,r=new n2([e.eventTriggerMatching,e.urlTriggerMatching,e.linkedFlagMatching]).triggerStatus(e.sessionId);return t?nj:r===nY?nG:r===nQ?nV:!1===e.isSampled?n$:nG}function ie(e){if(e.rrwebError)return nX;if(!e.receivedFlags)return nV;if(!e.isRecordingEnabled)return n$;if(e.urlTriggerMatching.urlBlocked)return nZ;var t=new n3([e.eventTriggerMatching,e.urlTriggerMatching,e.linkedFlagMatching]).triggerStatus(e.sessionId),r=t!==nK,n=rP(e.isSampled);return r&&t===nQ?nV:r&&t===nK||n&&!e.isSampled?n$:!0===e.isSampled?nj:nG}function it(){var e=[];return function(t,r){if(rA(r)||rT(r)){for(;e.length>0&&e[e.length-1]!==this;)e.pop();return e.includes(r)?"[Circular]":(e.push(r),r)}return r}}function ir(e){var t=JSON.stringify(e,it());return t?new Blob([t]).size:0}var ii=Uint8Array,is=Uint16Array,ia=Uint32Array,io=new ii([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]),il=new ii([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]),ih=new ii([16,17,18,0,8,7,9,6,10,5,11,4,12,3,13,2,14,1,15]),iu=function(e,t){for(var r=new is(31),n=0;31>n;++n)r[n]=t+=1<<e[n-1];var i=new ia(r[30]);for(n=1;30>n;++n)for(var s=r[n];r[n+1]>s;++s)i[s]=s-r[n]<<5|n;return[r,i]},id=iu(io,2),ic=id[1];id[0][28]=258,ic[258]=28;for(var ip=iu(il,0)[1],im=new is(32768),iv=0;32768>iv;++iv){var ig=(43690&iv)>>>1|(21845&iv)<<1;im[iv]=((65280&(ig=(61680&(ig=(52428&ig)>>>2|(13107&ig)<<2))>>>4|(3855&ig)<<4))>>>8|(255&ig)<<8)>>>1}var iy=function(e,t,r){for(var n=e.length,i=0,s=new is(t);n>i;++i)++s[e[i]-1];var a,o=new is(t);for(i=0;t>i;++i)o[i]=o[i-1]+s[i-1]<<1;if(r){a=new is(1<<t);var l=15-t;for(i=0;n>i;++i)if(e[i])for(var h=i<<4|e[i],u=t-e[i],d=o[e[i]-1]++<<u,c=d|(1<<u)-1;c>=d;++d)a[im[d]>>>l]=h}else for(a=new is(n),i=0;n>i;++i)a[i]=im[o[e[i]-1]++]>>>15-e[i];return a},ib=new ii(288);for(iv=0;144>iv;++iv)ib[iv]=8;for(iv=144;256>iv;++iv)ib[iv]=9;for(iv=256;280>iv;++iv)ib[iv]=7;for(iv=280;288>iv;++iv)ib[iv]=8;var iw=new ii(32);for(iv=0;32>iv;++iv)iw[iv]=5;var iS=iy(ib,9,0),ik=iy(iw,5,0),i_=function(e){return(e/8|0)+(7&e&&1)},iI=function(e,t,r){(null==r||r>e.length)&&(r=e.length);var n=new(e instanceof is?is:e instanceof ia?ia:ii)(r-t);return n.set(e.subarray(t,r)),n}
1,iM=function(e,t,r){var n=t/8|0;e[n]|=r<<=7&t,e[n+1]|=r>>>8},iC=function(e,t,r){var n=t/8|0;e[n]|=r<<=7&t,e[n+1]|=r>>>8,e[n+2]|=r>>>16},iR=function(e,t){for(var r=[],n=0;e.length>n;++n)e[n]&&r.push({s:n,f:e[n]});var i=r.length,s=r.slice();if(!i)return[new ii(0),0];if(1==i){var a=new ii(r[0].s+1);return a[r[0].s]=1,[a,1]}r.sort(function(e,t){return e.f-t.f}),r.push({s:-1,f:25001});var o=r[0],l=r[1],h=0,u=1,d=2;for(r[0]={s:-1,f:o.f+l.f,l:o,r:l};u!=i-1;)o=r[r[d].f>r[h].f?h++:d++],l=r[h!=u&&r[d].f>r[h].f?h++:d++],r[u++]={s:-1,f:o.f+l.f,l:o,r:l};var c=s[0].s;for(n=1;i>n;++n)s[n].s>c&&(c=s[n].s);var p=new is(c+1),f=iE(r[u-1],p,0);if(f>t){n=0;var m=0,v=f-t,g=1<<v;for(s.sort(function(e,t){return p[t.s]-p[e.s]||e.f-t.f});i>n;++n){var y=s[n].s;if(t>=p[y])break;m+=g-(1<<f-p[y]),p[y]=t}for(m>>>=v;m>0;){var b=s[n].s;t>p[b]?m-=1<<t-p[b]++-1:++n}for(;n>=0&&m;--n){var w=s[n].s;p[w]==t&&(--p[w],++m)}f=t}return[new ii(p),f]},iE=function(e,t,r){return -1==e.s?Math.max(iE(e.l,t,r+1),iE(e.r,t,r+1)):t[e.s]=r},iT=function(e){for(var t=e.length;t&&!e[--t];);for(var r=new is(++t),n=0,i=e[0],s=1,a=function(e){r[n++]=e},o=1;t>=o;++o)if(e[o]==i&&o!=t)++s;else{if(!i&&s>2){for(;s>138;s-=138)a(32754);s>2&&(a(s>10?s-11<<5|28690:s-3<<5|12305),s=0)}else if(s>3){for(a(i),--s;s>6;s-=6)a(8304);s>2&&(a(s-3<<5|8208),s=0)}for(;s--;)a(i);s=1,i=e[o]}return[r.subarray(0,n),t]},ix=function(e,t){for(var r=0,n=0;t.length>n;++n)r+=e[n]*t[n];return r},iA=function(e,t,r){var n=r.length,i=i_(t+2);e[i]=255&n,e[i+1]=n>>>8,e[i+2]=255^e[i],e[i+3]=255^e[i+1];for(var s=0;n>s;++s)e[i+s+4]=r[s];return 8*(i+4+n)},iL=function(e,t,r,n,i,s,a,o,l,h,u){iM(t,u++,r),++i[256];for(var d=iR(i,15),c=d[0],p=d[1],f=iR(s,15),m=f[0],v=f[1],g=iT(c),y=g[0],b=g[1],w=iT(m),S=w[0],k=w[1],_=new is(19),I=0;y.length>I;++I)_[31&y[I]]++;for(I=0;S.length>I;++I)_[31&S[I]]++;for(var M=iR(_,7),C=M[0],R=M[1],E=19;E>4&&!C[ih[E-1]];--E);var T,x,A,L,O=h+5<<3,D=ix(i,ib)+ix(s,iw)+a,N=ix(i,c)+ix(s,m)+a+14+3*E+ix(_,C)+(2*_[16]+3*_[17]+7*_[18]);if(D>=O&&N>=O)return iA(t,u,e.subarray(l,l+h));if(iM(t,u,1+(D>N)),u+=2,D>N){T=iy(c,p,0),x=c,A=iy(m,v,0),L=m;var F=iy(C,R,0);for(iM(t,u,b-257),iM(t,u+5,k-1),iM(t,u+10,E-4),u+=14,I=0;E>I;++I)iM(t,u+3*I,C[ih[I]]);u+=3*E;for(var P=[y,S],H=0;2>H;++H){var B=P[H];for(I=0;B.length>I;++I)iM(t,u,F[W=31&B[I]]),u+=C[W],W>15&&(iM(t,u,B[I]>>>5&127),u+=B[I]>>>12)}}else T=iS,x=ib,A=ik,L=iw;for(I=0;o>I;++I)if(n[I]>255){iC(t,u,T[257+(W=n[I]>>>18&31)]),u+=x[W+257],W>7&&(iM(t,u,n[I]>>>23&31),u+=io[W]);var W,z=31&n[I];iC(t,u,A[z]),u+=L[z],z>3&&(iC(t,u,n[I]>>>5&8191),u+=il[z])}else iC(t,u,T[n[I]]),u+=x[n[I]];return iC(t,u,T[256]),u+x[256]},iO=new ia([65540,131080,131088,131104,262176,1048704,1048832,2114560,2117632]),iD=function(){for(var e=new ia(256),t=0;256>t;++t){for(var r=t,n=9;--n;)r=(1&r&&0xedb88320)^r>>>1;e[t]=r}return e}(),iN=function(){var e=0xffffffff;return{p(t){for(var r=e,n=0;t.length>n;++n)r=iD[255&r^t[n]]^r>>>8;e=r},d:()=>0xffffffff^e}},iF=function(e,t,r){for(;r;++t)e[t]=r,r>>>=8},iP=function(e,t){var r=t.filename;if(e[0]=31,e[1]=139,e[2]=8,e[8]=2>t.level?4:2*(9==t.level),e[9]=3,0!=t.mtime&&iF(e,4,Math.floor(new Date(t.mtime||Date.now())/1e3)),r){e[3]=8;for(var n=0;r.length>=n;++n)e[n+10]=r.charCodeAt(n)}};function iH(e,t){for(var r="",n=0;e.length>n;)r+=String.fromCharCode(e[n++]);return r}class iB{constructor(e,t){var r,n;void 0===t&&(t={}),this.gh={},this.yh=e=>{if(!this.gh[e]){this.gh[e]=!0;var t,r,n=this.wh(e);null==(t=(r=this.bh).onBlockedNode)||t.call(r,e,n)}},this.kh=e=>{var t=this.wh(e);if("svg"!==(null==t?void 0:t.nodeName)&&t instanceof Element){var r=t.closest("svg");if(r)return[this._rrweb.mirror.getId(r),r]}return[e,t]},this.wh=e=>this._rrweb.mirror.getNode(e),this._h=e=>{var t,r,n,i,s,a,o,l;return(null!=(t=null==(r=e.removes)?void 0:r.length)?t:0)+(null!=(n=null==(i=e.attributes)?void 0:i.length)?n:0)+(null!=(s=null==(a=e.texts)?void 0:a.length)?s:0)+(null!=(o=null==(l=e.adds)?void 0:l.length)?o:0)},this.throttleMutations=e=>{if(3!==e.type||0!==e.data.source)return e;var t=e.data,r=this._h(t);t.attributes&&(t.attributes=t.attributes.filter(e=>{var t=this.kh(e.id);return!this.el.consumeRateLimit(t[0])&&e}));var n=this._h(t);return 0!==n||r===n?e:void 0},this._rrweb=e,this.bh=t,this.el=new rB({bucketSize:null!=(r=this.bh.bucketSize)?r:100,refillRate:null!=(n=this.bh.refillRate)?n:10,refillInterval:1e3,et:this.yh,rt:rq})}reset(){this.gh={}}stop(){this.el.stop(),this.reset()}}rz.DEBUG=!1,rz.LIB_VERSION="1.417.0",rz.LIB_NAME="web";class iW{constructor(e){if(!e.persistence)throw Error("it is not val
1id to not have persistence and be this far into setting up the application");this.Sh=e.get_property.bind(e),this.Mh=e.persistence.set_property.bind(e.persistence)}trackSize(e,t){this.Mh(nz,{sessionId:e,size:this.currentTrackedSize(e)+t})}currentTrackedSize(e){var t=this.Sh(nz);return rA(t)&&rO(t.sessionId)&&rF(t.size)&&t.sessionId===e?t.size:0}}function iz(e,t){return function(e){for(var t=0,r=0;e.length>r;r++)t=(t<<5)-t+e.charCodeAt(r)|0;return Math.abs(t)}(e)%100<rH(100*t,0,100,rq)}var iU=function(e,t){if(!function(e){try{new RegExp(e)}catch(e){return!1}return!0}(t))return!1;try{return new RegExp(t).test(e)}catch(e){return!1}},iq={exact:(e,t)=>t.some(t=>e.some(e=>t===e)),is_not:(e,t)=>t.every(t=>e.every(e=>t!==e)),regex:(e,t)=>t.some(t=>e.some(e=>iU(t,e))),not_regex:(e,t)=>t.every(t=>e.every(e=>!iU(t,e))),icontains:(e,t)=>t.map(i$).some(t=>e.map(i$).some(e=>t.includes(e))),not_icontains:(e,t)=>t.map(i$).every(t=>e.map(i$).every(e=>!t.includes(e))),gt:(e,t)=>t.some(t=>{var r=parseFloat(t);return!isNaN(r)&&e.some(e=>r>parseFloat(e))}),lt:(e,t)=>t.some(t=>{var r=parseFloat(t);return!isNaN(r)&&e.some(e=>r<parseFloat(e))})},i$=e=>e.toLowerCase(),ij=new Set(["is_not","not_icontains","not_regex"]);function iG(e,t,r){return!e||0===e.length||e.every(e=>{var n="person"===e.type?r:t,i=null==n?void 0:n[e.key],s=e.operator||"exact";if(rL(i)||rD(i))return ij.has(s);var a=iq[s];return!!a&&!rL(e.value)&&!rD(e.value)&&a(rT(e.value)?e.value.map(String):[String(e.value)],rT(i)?i.map(String):[String(i)])})}var iV=r$("[SessionRecording]");function iZ(e,t){return e===t||e!=="!"+t&&null}class iX{constructor(e,t,r,n,i,s,a){this.Ih=null,this.Ch=ie,this._instance=e,this.dh=t,this.fh=r,this.ph=n,this.Rh=i,this.xh=s,this.Ah=a}onRemoteConfig(e){this.Ih=rF(e.sampleRate)?e.sampleRate:null,"any"===e.triggerMatchType?(this.Th=new n2([this.fh,this.dh]),this.Ch=n7):(this.Th=new n3([this.fh,this.dh]),this.Ch=ie),this._instance.register_for_session({[nq]:e.triggerMatchType}),this.dh.onConfig(e),this.fh.onConfig(e),this.ph.onConfig(e,(e,t)=>{this.Rh("linked_flag_matched",{flag:e,variant:t}),this.Ah()})}getStatus(e){return this.Ch({receivedFlags:!0,isRecordingEnabled:!0,isSampled:e.isSampled,rrwebError:e.rrwebError,urlTriggerMatching:e.urlTriggerMatching,eventTriggerMatching:e.eventTriggerMatching,linkedFlagMatching:e.linkedFlagMatching,sessionId:e.sessionId})}getMinimumDuration(e){var t=this._instance.get_property("$session_recording_remote_config"),r=null==t?void 0:t.minimumDurationMilliseconds;return rF(r)?r:null}checkUrlTriggers(e,t,r,n){this.dh.checkUrlTriggerConditions(t,r,n,e)}setupEventTriggerListeners(e,t,r){if(0!==this.fh.lh.length&&rN(this.Eh))return this.Eh=e(e=>{try{this.fh.checkEventTriggerConditions(e.event,r,t)}catch(e){iV.error("Could not activate event trigger",e)}}),this.Eh}makeSamplingDecisions(e){var t,r,n,i=this.Ih;if(!rF(i))return null==(r=this._instance.persistence)||r.unregister(nO),void(null==(n=this._instance.persistence)||n.unregister(nE));var s=this._instance.get_property(nO),a=this._instance.get_property(nE),o=iZ(s,e),l=rF(a)&&a!==i,h=rL(a)&&s===e,u=l||h||!rP(o),d=u?iz(e,i):o;u&&(d?this.Rh("sampled"):iV.warn("Sample rate ("+i+") has determined that this sessionId ("+e+") will not be sent to the server.")),null==(t=this._instance.persistence)||t.register({[nO]:d?e:"!"+e,[nE]:rD(a)&&s===e?null:i})}ensureSamplingDecision(e){rF(this.Ih)&&(rP(iZ(this._instance.get_property(nO),e))||this.makeSamplingDecisions(e))}onFlushComplete(){}clearConditionalRecordingPersistence(){var e,t,r,n,i;null==(e=this._instance.persistence)||e.unregister(nF),null==(t=this._instance.persistence)||t.unregister(nN),null==(r=this._instance.persistence)||r.unregister(nO),null==(n=this._instance.persistence)||n.unregister(nE),null==(i=this._instance.persistence)||i.unregister(nD)}updateActiveTriggers(e){}hasPendingTriggers(e){var t;return(null==(t=this.Th)?void 0:t.triggerStatus(e))===nQ}stop(){var e;null==(e=this.Eh)||e.call(this),this.Eh=void 0,this.fh.stop(),this.dh.stop(),this.ph.stop()}}class iJ{constructor(e,t,r,n,i){this.Fh=[],this.Oh=new Map,this.Nh=!1,this._instance=e,this.dh=t,this.Rh=r,this.Lh=n,this.Ah=i}onRemoteConfig(e){e.triggerGroups&&0!==e.triggerGroups.length?(this.Dh(e.triggerGroups),this._instance.register_for_session({[nq]:"v2_trigger_groups",$sdk_debug_replay_trigger_groups_count:e.triggerGroups.length}),this.dh.onConfig(e)):iV.warn("[V2Strategy] No trigger groups configured")}getStatus(e){return function(e){if(e.rrwebError)return nX;if(e.urlTriggerMatching.urlBlocked)return nZ;var t=e.triggerGroupMatchers,r=e.triggerGroupSamplingResults;if(0===t.length)return n$;var n=!1,i=!1;for(var s of t){var a=s.triggerStatus(e.sessionId);if(a===nY){var o=s.group.id,l=r.get(o);rL(l)?rq.warn("[V2 Triggers] Group activated but no sampling decision found",{groupId:o}):!0===l&&(i=!0)}else a===nQ&&(n=!0)}return i?nj:n?nV:n$}({isSampled:e.isSampled,rrwebError:e.rrwebError,urlTriggerMatching:e.urlTriggerMatching,eventTriggerMatching:e.eventTriggerMatching,linkedFlagMatching:e.linkedFlagMatching,sessionId:e.sessionId,triggerGroupMatchers:this.Fh,triggerGroupSamplingResults:this.Oh,minimumDuration:this.getMinimumDuration(e.sessionId)})}getMinimumDuration(e){var t=null;for(var r of this.Fh)if("trigger_activated"===r.triggerStatus(e)){var n=r.group.minDurationMs;rF(n)&&(rD(t)||t>n)&&(t=n)}return t}checkUrlTriggers(e,t,r,n){var i=this;this.dh.checkUrlBlocklist(t,r);var s=function(n){n.checkUrlTriggerConditions(t,r,t=>{i.$h(n,void 0)&&(n.activateTrigger(t,e),i.updateActiveTriggers(e),i.Ah(t))},e)};for(var a of this.Fh)s(a)}setupEventTriggerListeners(e,t,r){var n=this;return this.Eh=e(e=>{var r;if(this.Nh)return iV.info("[SessionRecorder] Stopping trigger checks - initial buffer flushed"),null==(r=this.Eh)||r.call(this),void(this.Eh=void 0);try{var i=function(r){r.checkEventTriggerConditions(e.event,i=>{if(n.$h(r,e.properties)){var s=(r.group.conditions.events||[]).filter(t=>t.name===e.event),a=n._instance.get_property(nU);s.some(t=>!t.properties||0===t.properties.length||iG(t.properties,e.properties,a))&&(r.activateTrigger(i,t),n.updateActiveTriggers(t),n.Ah(i))}},t)};for(var s of this.Fh)i(s)}catch(e){iV.error("Could not activate event trigger for trigger groups",e)}}),this.Eh}makeSamplingDecisions(e){for(var t of this.Fh){var r,n=t.group,i=n.id,s=n.sampleRate,a=nB+i,o=this._instance.get_property(a),l=null,h=!1,u=!1,d=!1;if(rA(o)){var c=o.sessionId,p=o.sampleRate,f=o.sampled;
1h="string"==typeof c&&c!==e,u=rF(p)&&p!==s,l=c===e&&rF(p)&&p===s&&rP(f)?f:null}else l=o===e||null,h="string"==typeof o&&o!==e,d=o===e;var m=h||u||d||!rP(l),v=m?iz(e+i,s):l;m&&this.Lh("triggerGroupSamplingDecisionMade",{group_id:i,group_name:n.name,sampleRate:s,isSampled:v}),this.Oh.set(i,v),null==(r=this._instance.persistence)||r.register({[a]:{sessionId:e,sampleRate:s,sampled:v}})}this.updateActiveTriggers(e)}ensureSamplingDecision(e){}onFlushComplete(){this.Nh=!0}clearConditionalRecordingPersistence(){var e,t,r;for(var n of(null==(e=this._instance.persistence)||e.unregister(nO),null==(t=this._instance.persistence)||t.unregister(nE),null==(r=this._instance.persistence)||r.unregister(nD),this.Fh)){var i,s,a,o=n.group.id;null==(i=this._instance.persistence)||i.unregister(nP+o),null==(s=this._instance.persistence)||s.unregister(nH+o),null==(a=this._instance.persistence)||a.unregister(nB+o)}}updateActiveTriggers(e){var t=[];for(var r of this.Fh){var n=r.group,i=n.id,s="trigger_activated"===r.triggerStatus(e),a=!0===this.Oh.get(i);s&&t.push({id:i,name:n.name,matched:!0,sampled:a})}this._instance.register_for_session({$sdk_debug_replay_matched_recording_trigger_groups:t})}hasPendingTriggers(e){for(var t of this.Fh)if(t.triggerStatus(e)===nQ)return!0;return!1}stop(){var e;null==(e=this.Eh)||e.call(this),this.Eh=void 0,this.Fh.forEach(e=>e.stop()),this.Fh=[],this.Oh.clear(),this.dh.stop()}$h(e,t){var r=e.group.conditions.properties;return!r||0===r.length||iG(r,t,this._instance.get_property(nU))}Dh(e){var t=this;this.Fh.forEach(e=>e.stop()),this.Fh=[],this.Oh.clear();var r=function(e){var r=new n9(t._instance,e,(r,n)=>{t.Rh("linked_flag_matched",{flag:r,variant:n,group_id:e.id,group_name:e.name}),t.Ah()});t.Fh.push(r)};for(var n of e)r(n)}}var iY=["gclid","gclsrc","dclid","gbraid","wbraid","fbclid","msclkid","twclid","li_fat_id","igshid","ttclid","rdt_cid","epik","qclid","sccid","irclid","_kx"];function iQ(e){return rL(e)?void 0:Math.round(e)}function iK(e){return rA(e)?e.network_timing:e}var i0,i1,i2="[SessionRecording]",i3=r$(i2),i5=[1,2,3,4,5,6,7,12],i4=e=>({rrwebMethod:e,enqueuedAt:Date.now(),attempt:1});function i8(){var e;return null==rS||null==(e=rS.__PosthogExtensions__)?void 0:e.rrweb}function i6(){var e;return null==(e=i8())?void 0:e.record}function i9(e){try{return JSON.stringify(e)}catch(t){return JSON.stringify(e,it())}}function i7(e){var t,r,n,i,s,a,o,l,h;return iH((t=function(e){var t=e.length;if("u">typeof TextEncoder)return(new TextEncoder).encode(e);for(var r=new ii(e.length+(e.length>>>1)),n=0,i=function(e){r[n++]=e},s=0;t>s;++s){if(n+5>r.length){var a=new ii(n+8+(t-s<<1));a.set(r),r=a}var o=e.charCodeAt(s);128>o?i(o):(2048>o?i(192|o>>>6):(o>55295&&57344>o?(i(240|(o=65536+(1047552&o)|1023&e.charCodeAt(++s))>>>18),i(128|o>>>12&63)):i(224|o>>>12),i(128|o>>>6&63)),i(128|63&o))}return iI(r,0,n)}(i9(e)),void 0===r&&(r={}),n=iN(),i=t.length,n.p(t),h=(a=r,o=10+((s=r).filename&&s.filename.length+1||0),l=function(e,t,r,n){var i=e.length,s=new ii(n+i+5*(1+Math.floor(i/7e3))+8),a=s.subarray(n,s.length-8),o=0;if(!t||8>i)for(var l=0;i>=l;l+=65535){var h=l+65535;i>h?o=iA(a,o,e.subarray(l,h)):(a[l]=!0,o=iA(a,o,e.subarray(l,i)))}else{for(var u=iO[t-1],d=u>>>13,c=8191&u,p=(1<<r)-1,f=new is(32768),m=new is(p+1),v=Math.ceil(r/3),g=2*v,y=function(t){return(e[t]^e[t+1]<<v^e[t+2]<<g)&p},b=new ia(25e3),w=new is(288),S=new is(32),k=0,_=0,I=(l=0,0),M=0,C=0;i>l;++l){var R=y(l),E=32767&l,T=m[R];if(f[E]=T,m[R]=E,l>=M){var x=i-l;if((k>7e3||I>24576)&&x>423){o=iL(e,a,0,b,w,S,_,I,C,l-C,o),I=k=_=0,C=l;for(var A=0;286>A;++A)w[A]=0;for(A=0;30>A;++A)S[A]=0}var L=2,O=0,D=c,N=E-T&32767;if(x>2&&R==y(l-N))for(var F=Math.min(d,x)-1,P=Math.min(32767,l),H=Math.min(258,x);P>=N&&--D&&E!=T;){if(e[l+L]==e[l+L-N]){for(var B=0;H>B&&e[l+B]==e[l+B-N];++B);if(B>L){if(L=B,O=N,B>F)break;var W=Math.min(N,B-2),z=0;for(A=0;W>A;++A){var U=l-N+A+32768&32767,q=U-f[U]+32768&32767;q>z&&(z=q,T=U)}}}N+=(E=T)-(T=f[E])+32768&32767}if(O){b[I++]=0x10000000|ic[L]<<18|ip[O];var $=31&ic[L],j=31&ip[O];_+=io[$]+il[j],++w[257+$],++S[j],M=l+L,++k}else b[I++]=e[l],++w[e[l]]}}o=iL(e,a,!0,b,w,S,_,I,C,l-C,o)}return iI(s,0,n+i_(o)+8)}(t,null==a.level?6:a.level,null==a.mem?Math.ceil(1.5*Math.max(8,Math.min(13,Math.log(t.length)))):12+a.mem,o)).length,iP(l,r),iF(l,h-8,n.d()),iF(l,h-4,i),l))}function se(e){return st.apply(this,arguments)}function st(){return(st=l(function*(e){var t=i9(e),r=yield function(e,t,r){return rM.apply(this,arguments)}(t,rz.DEBUG,{rethrow:!0});return iH(new Uint8Array((yield r.arrayBuffer())))}
1)).apply(this,arguments)}var sr="u">typeof globalThis&&"CompressionStream"in globalThis&&"TextEncoder"in globalThis&&"Response"in globalThis&&"function"==typeof Response.prototype.blob,sn=!1;function si(e){return rT(e)&&0===e.length?i0=null!=i0?i0:i7([]):i7(e)}function ss(e){return sa.apply(this,arguments)}function sa(){return(sa=l(function*(e){return rT(e)&&0===e.length?i0||(i1=null!=i1?i1:se([]).then(e=>(i0=e,e)).catch(e=>{throw i0=void 0,i1=void 0,e})):se(e)})).apply(this,arguments)}function so(e){return sr&&!sn&&(2===e.type||3===e.type&&(0===e.data.source||8===e.data.source))}function sl(e){return{event:e,size:function e(t){if(rD(t))return 4;if(rL(t))return 0;switch(typeof t){case"string":return t.length+2;case"number":return String(t).length;case"boolean":return t?4:5;case"object":if(rT(t)){for(var r=2,n=0;t.length>n;n++){n>0&&(r+=1);var i=t[n];r+=rL(i)||rD(i)?4:e(i)}return r}var s=2,a=!0;for(var o in t)if(({}).hasOwnProperty.call(t,o)){var l=t[o];rL(l)||(a||(s+=1),a=!1,s+=o.length+3+e(l))}return s;default:return 0}}(e)}}function sh(e,t){return h({},e,{data:t,cv:"2024-10"})}function su(e,t){return h({},e,{cv:"2024-10",data:h({},e.data,t)})}function sd(e){try{if(2===e.type)return sl(sh(e,i7(e.data)));if(3===e.type&&0===e.data.source)return sl(su(e,{texts:si(e.data.texts),attributes:si(e.data.attributes),removes:si(e.data.removes),adds:si(e.data.adds)}));if(3===e.type&&8===e.data.source)return sl(su(e,{adds:e.data.adds?i7(e.data.adds):void 0,removes:e.data.removes?i7(e.data.removes):void 0}))}catch(e){i3.error("could not compress event - will use uncompressed event",e)}return{event:e,size:ir(e)}}function sc(){return(sc=l(function*(e){try{if(2===e.type)return sl(sh(e,(yield se(e.data))));if(3===e.type&&0===e.data.source){var t=yield Promise.all([ss(e.data.texts),ss(e.data.attributes),ss(e.data.removes),ss(e.data.adds)]);return sl(su(e,{texts:t[0],attributes:t[1],removes:t[2],adds:t[3]}))}if(3===e.type&&8===e.data.source){var r=yield Promise.all([e.data.adds?se(e.data.adds):void 0,e.data.removes?se(e.data.removes):void 0]);return sl(su(e,{adds:r[0],removes:r[1]}))}}catch(t){return(e=>{if(!e||"object"!=typeof e)return!1;var t="name"in e?String(e.name):"";return!(!e||"object"!=typeof e)&&"NotReadableError"===("name"in e?String(e.name):"")||t===rk})(t)&&(sn=!0),i3.error("could not compress event asynchronously - trying synchronous compression",t),sd(e)}return{event:e,size:ir(e)}})).apply(this,arguments)}function sp(e,t){return 5===e.type&&e.data.tag===t}function sf(e){return sp(e,"sessionIdle")}function sm(e){return sp(e,"$session_ending")}function sv(e){return sp(e,"$session_starting")}class sg{get sessionId(){return this.Dr}get Ph(){if(!this._instance.sessionManager)throw Error(i2+" must be started with a valid sessionManager.");return this._instance.sessionManager}get Wh(){return this._instance.config.session_recording.session_idle_threshold_ms||3e5}get Bh(){return iZ(this._instance.get_property(nO),this.sessionId)}get Ih(){var e,t=null==(e=this.eu)?void 0:e.sampleRate;return rF(t)?t:null}get zh(){var e,t;return null!=(e=null==(t=this.Uh)?void 0:t.getMinimumDuration(this.sessionId))?e:null}constructor(e,t){this.jh="/s/",this._forceAllowLocalhostNetworkCapture=!1,this.qh=void 0,this.Hh=Date.now(),this.Gh=!1,this.Vh=[],this.Zh="unknown",this.Jh=!1,this.Qh=!1,this.Xh=!1,this.Kh=!1,this.Yh=!1,this.Zd=!1,this.Qd=!1,this.tc=!1,this.ec=!1,this.rc=!1,this.ic=!1,this.nc=!1,this.sc=[],this.ac=void 0,this.oc=void 0,this.uc=[],this.lc=0,this.hc=0,this.dc=!1,this.cc=void 0,this.Eh=void 0,this.vc=void 0,this.fc=void 0,this.mc=void 0,this.kr=(e,t,r)=>{var n,i,s;if(r&&(e!==this.Dr||t!==this.Or)){var a,o=!r.noSessionId&&(r.activityTimeout||r.sessionPastMaximumLength),l=this.Dr,h=this.Or;if(o&&this.Lh("$session_ending",{currentSessionId:l,currentWindowId:h,nextSessionId:e,nextWindowId:t,changeReason:r,lastActivityTimestamp:this.Hh,flushed_size:null==(a=this.gc)?void 0:a.currentTrackedSize(l)}),null==(n=this._instance.persistence)||n.unregister(nW),this.Qd=!1,null==(i=i8())||null==i.resetMaxDepthState||i.resetMaxDepthState(),this.Lh("$session_id_change",{sessionId:e,windowId:t,changeReason:r}),this.yc(),!(!1===this.Zh&&this.isStarted||this.Dr===e&&this.Or===t)){var u=this.Dr!==e&&!1!==this.Zh;this.Zh="unknown",this.wc(u)}o&&this.Lh("$session_starting",{previousSessionId:l,previousWindowId:h,nextSessionId:e,nextWindowId:t,changeReason:r,lastActivityTimestamp:this.Hh}),null==(s=this.Uh)||s.makeSamplingDecisions(e)}},this.bc=()=>{var e;return(null==(e=this._instance.persistence)?void 0:e.props[nD])===this.Dr},this.kc=()=>
1{if(0===this.R.data.length)return null;var e,t,r=null==(e=this.R.data[0])?void 0:e.timestamp,n=null==(t=this.R.data[this.R.data.length-1])?void 0:t.timestamp;return rF(r)&&rF(n)?n-r:null},this._c=()=>{var e,t,r=this.zh;if(!rF(r))return!1;if(null==(e=null==(t=this._instance.config.session_recording)?void 0:t.strictMinimumDuration)||!e){var n=this.Sc;return rF(n)&&n>=0&&r>n}if(this.bc())return!1;var i,s=this.kc();return!!rD(s)||r>s||(null==(i=this._instance.persistence)||i.register({[nD]:this.Dr}),!1)},this.Mc=()=>{this.status!==nV?(this.Jh&&this.Qh&&this.ao&&!this.Xh&&(this.Jh=!1),this.Ic(),this.Cc()):this.Rc()},this.xc=()=>{this.Mc()},this.Ac=()=>{this.Lh("browser offline",{})},this.Ia=()=>{this.Lh("browser online",{})},this.Ie=()=>{null!=rv&&rv.visibilityState&&("visible"===rv.visibilityState&&(this.ao=!0),this.Lh("window "+rv.visibilityState,{}))},this._instance=e,this.ao=null==t||t;var r=this.Ph.checkAndGetSessionAndWindowId(),n=r.windowId;this.Dr=r.sessionId,this.Or=n,this.ph=new n8(this._instance),this.dh=new n4(this._instance),this.fh=new n6(this._instance),this.R=this.Rc(),this.Ph.sessionTimeoutMs>this.Wh||i3.warn("session_idle_threshold_ms ("+this.Wh+") is greater than the session timeout ("+this.Ph.sessionTimeoutMs+"). Session will never be detected as idle"),this.gc=new iW(this._instance)}setDocumentWasEverVisible(e){e&&(this.ao=!0)}get Tc(){var e,t,r,n,i,s,a,o,l,h=null==(e=this.eu)?void 0:e.masking,u={maskAllInputs:null==(t=this._instance.config.session_recording)?void 0:t.maskAllInputs,maskTextSelector:null==(r=this._instance.config.session_recording)?void 0:r.maskTextSelector,blockSelector:null==(n=this._instance.config.session_recording)?void 0:n.blockSelector,maskAllElementAttributes:null==(i=this._instance.config.session_recording)?void 0:i.maskAllElementAttributes},d=null!=(s=null==u?void 0:u.maskAllInputs)?s:null==h?void 0:h.maskAllInputs,c=null!=(a=null==u?void 0:u.maskTextSelector)?a:null==h?void 0:h.maskTextSelector,p=null!=(o=null==u?void 0:u.blockSelector)?o:null==h?void 0:h.blockSelector,f=null!=(l=null==u?void 0:u.maskAllElementAttributes)?l:null==h?void 0:h.maskAllElementAttributes;return rL(d)&&rL(c)&&rL(p)&&rL(f)?void 0:{maskAllInputs:null==d||d,maskTextSelector:c,blockSelector:p,maskAllElementAttributes:f}}Ec(){var e;if(!this.ec){var t=null==(e=this.eu)?void 0:e.masking;if(!rN(t)){var r=this._instance.config.session_recording,n=["maskAllInputs","maskTextSelector","blockSelector","maskAllElementAttributes"].filter(e=>{var n=null==r?void 0:r[e],i=t[e];return!rL(n)&&n!==i});0!==n.length&&(this.ec=!0,i3.warn('Session recording masking is configured both in `posthog.init` and in your project settings, and they differ. The `session_recording` options in `posthog.init` take precedence, so the project ("Privacy and masking") setting is ignored for: '+n.join(", ")+". Remove these masking options from `posthog.init` to use the project setting instead. See https://posthog.com/docs/session-replay/privacy",{client:{maskAllInputs:null==r?void 0:r.maskAllInputs,maskTextSelector:null==r?void 0:r.maskTextSelector,blockSelector:null==r?void 0:r.blockSelector,maskAllElementAttributes:null==r?void 0:r.maskAllElementAttributes},project:t}))}}}get Fc(){var e;return rH(null==(e=this._instance.config.session_recording.canvasCapture)?void 0:e.resolutionScale,.1,1,r$("canvas recording resolution scale"),1)}get Oc(){var e,t,r,n,i,s,a,o=this._instance.config.session_recording.captureCanvas,l=null==(e=this.eu)?void 0:e.canvasRecording,h=null!=(t=null!=(r=null==o?void 0:o.recordCanvas)?r:null==l?void 0:l.enabled)&&t,u=null!=(n=null!=(i=null==o?void 0:o.canvasFps)?i:null==l?void 0:l.fps)?n:4,d=null!=(s=null!=(a=null==o?void 0:o.canvasQuality)?a:null==l?void 0:l.quality)?s:.4;if("string"==typeof d){var c=parseFloat(d);d=isNaN(c)?.4:c}return{enabled:h,fps:rH(u,0,12,r$("canvas recording fps"),4),quality:rH(d,0,1,r$("canvas recording quality"),.4)}}get Nc(){var e,t=!(null==(e=this.eu)||!e.consoleLogRecordingEnabled),r=this._instance.config.enable_recording_console_log;return null!=r?r:t}get Lc(){var e,t,r,n=null==(e=this.eu)?void 0:e.networkPayloadCapture,
1i={recordHeaders:null==(t=this._instance.config.session_recording)?void 0:t.recordHeaders,recordBody:null==(r=this._instance.config.session_recording)?void 0:r.recordBody},s=(null==i?void 0:i.recordHeaders)||(null==n?void 0:n.recordHeaders),a=(null==i?void 0:i.recordBody)||(null==n?void 0:n.recordBody),o=iK(this._instance.config.capture_performance),l=iK(null==n?void 0:n.capturePerformance),h=!!(rP(o)?o:l);return s||a||h?{recordHeaders:s,recordBody:a,recordPerformance:h}:void 0}Dc(){var e,t,r=[],n=null==(e=rS.__PosthogExtensions__)||null==(e=e.rrwebPlugins)?void 0:e.getRecordConsolePlugin;n&&this.Nc&&r.push(n());var i=null==(t=rS.__PosthogExtensions__)||null==(t=t.rrwebPlugins)?void 0:t.getRecordNetworkPlugin;if(this.Lc&&rx(i))if(!rV.includes(rg.hostname)||this._forceAllowLocalhostNetworkCapture){var s,a,o,l,u,d,c,p,f,m,v=rx(this._instance.requestRouter.isIngestionEndpoint)?this._instance.requestRouter.isIngestionEndpoint.bind(this._instance.requestRouter):void 0;r.push(i((s=this._instance.config,a=this.Lc,l={payloadSizeLimitBytes:r9.payloadSizeLimitBytes,performanceEntryTypeToObserve:[...r9.performanceEntryTypeToObserve],payloadHostDenyList:[...a.payloadHostDenyList||[],...r9.payloadHostDenyList]},u=!1!==s.session_recording.recordHeaders&&a.recordHeaders,d=!1!==s.session_recording.recordBody&&a.recordBody,c=!1!==s.capture_performance&&a.recordPerformance,o=r6(l),p=e=>(null!=e&&e.requestBody&&(e.requestBody=ni(e.requestBody,e.requestHeaders,o,"Request")),null!=e&&e.responseBody&&(e.responseBody=ni(e.responseBody,e.responseHeaders,o,"Response")),e),f=e=>p(((e,t,r)=>{var n;if(null==r||!r(e.name)){var i=rZ(e.name),s=0===t.indexOf("http")?null==(n=rZ(t))?void 0:n.pathname:t;"/"===s&&(s="");var a=null==i?void 0:i.pathname.replace(s||"","");if(!(i&&a&&nn.some(e=>0===a.indexOf(e))))return e}})((nr(e.requestHeaders),nr(e.responseHeaders),e),s.api_host,v)),(m=rx(s.session_recording.maskNetworkRequestFn))&&rx(s.session_recording.maskCapturedNetworkRequestFn)&&rq.warn("Both `maskNetworkRequestFn` and `maskCapturedNetworkRequestFn` are defined. `maskNetworkRequestFn` will be ignored."),m&&(s.session_recording.maskCapturedNetworkRequestFn=e=>{var t=s.session_recording.maskNetworkRequestFn({url:e.name});return!t&&e.isInitial?t:h({},e,{name:null==t?void 0:t.url})}),l.maskRequestFn=rx(s.session_recording.maskCapturedNetworkRequestFn)?e=>{var t=f(e);if(t){var r=t.isInitial?{name:"",entryType:t.entryType,startTime:t.startTime,duration:t.duration,endTime:t.endTime,timeOrigin:t.timeOrigin,timestamp:t.timestamp,isInitial:!0}:void 0,n=null==s.session_recording.maskCapturedNetworkRequestFn?void 0:s.session_recording.maskCapturedNetworkRequestFn(t);return rN(n)&&r?(na.add(r),r):null!=n?n:void 0}}:e=>(function(e){if(!rL(e))return e.requestBody=ns(e.requestBody,"Request"),e.responseBody=ns(e.responseBody,"Response"),e})(f(e)),h({},r9,l,{recordHeaders:u,recordBody:d,recordPerformance:c,recordInitialRequests:c,streamNetworkBody:!0===s.session_recording.streamNetworkBody}))))}else i3.info("NetworkCapture not started because we are on localhost.");return r}$c(e){return this._instance.config.disable_capture_url_hashes?rW(e):e}Pc(e,t){void 0===t&&(t=!1);var r=t?rW(e):this.$c(e),n=this._instance.config.mask_personal_data_properties?[...iY,...this._instance.config.custom_personal_data_properties||[]]:[];return this.Wc(function(e,t){if(!e||!t||!t.length)return e;for(var r=e.split("#"),n=r[1],i=(r[0]||"").split("?"),s=i[1],a=i[0],o=(s||"").split("&"),l=[],h=0;o.length>h;h++){var u=o[h].split("=");rT(u)&&(t.includes(u[0])?l.push(u[0]+"=<masked>"):l.push(o[h]))}var d=a;return null!=s&&(d+="?"+l.join("&")),null!=n&&(d+="#"+n),d}(r,n))}Wc(e){var t=this._instance.config.session_recording;if(t.maskCapturedNetworkRequestFn){var r,n=t.maskCapturedNetworkRequestFn({name:e});return null!=(r=null==n?void 0:n.name)?r:null==n?void 0:n.url}if(t.maskNetworkRequestFn){var i=t.maskNetworkRequestFn({url:e});return null==i?void 0:i.url}return e}Bc(e){try{return e.rrwebMethod(),!0}catch(t){return 10>this.Vh.length?this.Vh.push({enqueuedAt:e.enqueuedAt||Date.now(),attempt:e.attempt+1,rrwebMethod:e.rrwebMethod}):i3.warn("could not emit queued rrweb event.",t,e),!1}}Lh(e,t){return this.Bc(i4(()=>i6().addCustomEvent(e,t)))}zc(){try{if(this._instance.config.capture_pageview||!rf)return;var e=new URL(rf.location.href),t=this.Pc(e.origin+e.pathname+e.search);this.Uc!==t&&(this.Uc=t,this.Lh("$url_changed",{href:t}))}catch(e){}}jc(){if(this.Vh.length){var e=[...this.Vh];
1this.Vh=[],e.forEach(e=>{Date.now()-e.enqueuedAt>2e3||this.Bc(e)})}}xh(){return this.Bc(i4(()=>i6().takeFullSnapshot()))}get qc(){var e,t,r;if(null!=(e=this.Uh)&&e.hasPendingTriggers(this.sessionId)&&!["sampled","active"].includes(this.status)){var n,i=null==(n=this._instance.config.session_recording)?void 0:n.trigger_pending_buffer_interval_millis;return rF(i)&&Number.isFinite(i)&&i>=1e3&&36e5>=i?i:6e4}return null!=(t=null==(r=this._instance.config.session_recording)?void 0:r.full_snapshot_interval_millis)?t:3e5}Hc(){if(this.Gc&&clearInterval(this.Gc),!0!==this.Zh){var e=this.qc;e&&(this.Gc=setInterval(()=>{this.xh()},e))}}Ah(e){"event"===e&&this.Vc(),!this.dh.urlBlocked&&["sampled","active"].includes(this.status)&&this.Hc()}Zc(){this.dh.urlBlocked||(this.dh.urlBlocked=!0,clearInterval(this.Gc),i3.info("recording paused due to URL blocker"),this.Lh("recording paused",{reason:"url blocker"}))}Jc(){this.dh.urlBlocked&&(this.dh.urlBlocked=!1,this.xh(),this.Hc(),this.Lh("recording resumed",{reason:"left blocked url"}),i3.info("recording resumed"))}Qc(e,t){var r,n,i;if("event"===e&&this.Vc(),!this.Gh&&null!=(r=this.Uh)&&r.hasPendingTriggers(this.sessionId)){this.Gh=!0;try{null==(n=this._instance.persistence)||n.register({["url"===e?nN:nF]:this.sessionId}),null==(i=this.Uh)||i.updateActiveTriggers(this.sessionId),this.Ah(),this.Cc(),this.Rh(e+"_trigger_matched",{["url"===e?"matchedUrl":"matchedEvent"]:t})}finally{this.Gh=!1}}}get isStarted(){return!!this.qh}get eu(){var e=this._instance.get_property(nR);if(e){try{t=rA(e)?e:JSON.parse(e)}catch(e){return void i3.warn("persisted remote config for session recording is invalid and will be ignored",e)}if(!this.isStarted){var t,r,n,i=null!=(r=t.cache_timestamp)?r:Date.now();if(Date.now()-i>36e5)return i3.info("persisted remote config for session recording is stale and will be ignored",{cacheTimestamp:i,persistedConfig:e}),void(null==(n=this._instance.persistence)||n.unregister(nR))}return t}}Xc(e,t,r){this._instance.get_property(e)&&(t(),r())}start(e){var t,r,n=this.eu;if(n){this.isStarted||(this.Jh=!1!==this.Zh&&!this.Kh,this.Kh=!1,this.Qh=this.Jh,this.Xh=!1),this.dc&&(this.Kc(),this.Rc());var i=this.Ph.checkAndGetSessionAndWindowId(),s=i.windowId;this.Dr=i.sessionId,this.Or=s,null==(t=this._instance.persistence)||t.unregister(nW),null!=n&&n.endpoint&&(this.jh=null==n?void 0:n.endpoint),this.Uh=2===(null==n?void 0:n.version)&&(null==n?void 0:n.triggerGroups)&&n.triggerGroups.length>0?new iJ(this._instance,this.dh,this.Rh.bind(this),this.Lh.bind(this),this.Ah.bind(this)):new iX(this._instance,this.dh,this.fh,this.ph,this.Rh.bind(this),this.xh.bind(this),this.Ah.bind(this)),this.Uh.onRemoteConfig(n),null==(r=this.Eh)||r.call(this),this.Eh=this.Uh.setupEventTriggerListeners(this._instance.on.bind(this._instance,"eventCaptured"),this.sessionId,(e,t)=>this.Qc(e,t)),this.Xc(nT,()=>{this.overrideSampling()},()=>{var e;return null==(e=this._instance.persistence)?void 0:e.unregister(nT)}),this.Xc(nx,()=>{this.overrideLinkedFlag()},()=>{var e;return null==(e=this._instance.persistence)?void 0:e.unregister(nx)}),this.Xc(nL,()=>{this.overrideTrigger("event")},()=>{var e;return null==(e=this._instance.persistence)?void 0:e.unregister(nL)}),this.Xc(nA,()=>{this.overrideTrigger("url")},()=>{var e;return null==(e=this._instance.persistence)?void 0:e.unregister(nA)}),this.Uh.makeSamplingDecisions(this.sessionId),this.Yc(),this.Yh||(rG(rf,"beforeunload",this.Mc),rG(rf,"pagehide",this.xc),rG(rf,"offline",this.Ac),rG(rf,"online",this.Ia),rG(rv,"visibilitychange",this.Ie),!this.vc&&rx(this.Ph.onSessionId)&&(this.vc=this.Ph.onSessionId(this.kr)),!this.fc&&rx(this.Ph.on)?this.fc=this.Ph.on("forcedIdleReset",()=>{this.yc(),this.Zh="unknown",this.stop(),this.mc=this.Ph.onSessionId((e,t,r)=>{var n;null==(n=this.mc)||n.call(this),this.mc=void 0,this.kr(e,t,r)})}):rx(this.Ph.on)||i3.warn("bundled core has no SessionIdManager.on (requires posthog-js >= 1.268.6); recording will start but skip forced-idle-reset handling"),rN(this.cc)&&(this.cc=this._instance.on("eventCaptured",e=>{try{if("$pageview"===e.event){var t=null!=e&&e.properties.$current_url?this.Pc(e.properties.$current_url):"";if(!t)return;this.Lh("$pageview",{href:t})}}catch(e){i3.error("Could not add $pageview to rrweb session",e)}})),this.status===nG&&this.Rh(e||"recording_initialized"))}else i3.info("remote config must be stored in persistence before recording can start")}tv(){var e,t,r,n,i,s;null==rf||rf.removeEventListener("beforeunload",this.Mc),null==rf||rf.removeEventListener("pagehide",this.xc),null==rf||rf.removeEventListener("offline",this.Ac
1),null==rf||rf.removeEventListener("online",this.Ia),null==rv||rv.removeEventListener("visibilitychange",this.Ie),clearInterval(this.Gc),this.ev(),null==(e=this.cc)||e.call(this),this.cc=void 0,null==(t=this.Eh)||t.call(this),this.Eh=void 0,null==(r=this.vc)||r.call(this),this.vc=void 0,null==(n=this.fc)||n.call(this),this.fc=void 0,null==(i=this.mc)||i.call(this),this.mc=void 0,null==(s=this.Uh)||s.stop(),this.rv(),this.Kc()}Kc(){this.hc+=1,this.uc=[],this.lc=0,this.iv=void 0,this.dc=!1}rv(){var e,t;null==(e=this.nv)||e.stop(),this.Vh=[],null==(t=this.qh)||t.call(this),this.qh=void 0}sv(){if(!this.iv||0===this.lc)return!1;if(this.dc)return!0;this.dc=!0;var e=this.hc;return this.ev(),this.rv(),this.iv.catch(()=>{}).then(()=>{e===this.hc&&(this.dc=!1,this.Cc(),this.Rc(),this.tv(),i3.info("stopped"))}).catch(()=>{this.dc=!1,this.tv(),i3.info("stopped")}),!0}stop(){this.rv(),this.sv()||(this.Cc(),this.Rc(),this.tv(),i3.info("stopped"))}wc(e){var t;this.stop(),this.av=void 0,this.ov=void 0,null==(t=i8())||null==t.resetSnapshotCostState||t.resetSnapshotCostState(),this.start("session_id_changed"),this.Jh=e,this.Qh=!1}Vc(){this.isStarted||(this.Kh=!0),this.Jh&&(this.Jh=!1,this.Qh=!1,this.Xh&&(this.Xh=!1,this.xh()),this.uv())}discard(){this.Rc(),this.tv(),i3.info("discarded")}lv(e,t,r,n,i){this.status!==n$?(this.hv(e,n),this.dv({$snapshot_bytes:r,$snapshot_data:t,$session_id:n,$window_id:i})):this.Rc()}vv(){try{this.fv()}catch(e){this.tc||(this.tc=!0,i3.error("could not track full snapshot cost",e))}}fv(){var e,t=null==(e=i8())||null==e.getLastSnapshotCost?void 0:e.getLastSnapshotCost();t&&t!==this.ov&&(this.ov=t,this.av&&this.av.durationMs>=t.durationMs||(this.av=t),500>t.durationMs||i3.warn("full snapshot was slow, the page may have been unresponsive while it ran",{durationMs:Math.round(t.durationMs),stylesheetMs:Math.round(t.stylesheetMs),nodeCount:t.nodeCount,cssRuleCount:t.cssRuleCount,nonDeferrableCssRuleCount:t.nonDeferrableCssRuleCount,deferredStylesheetCount:t.deferredStylesheetCount}))}hv(e,t){2!==e.type?3===e.type&&(rL(this.ac)||this.ac===t||this.oc===t||(this.oc=t,i3.info("incremental snapshot for a session with no full snapshot - requesting one",{sessionId:t}),this.xh())):this.ac=t}pv(e){e.counted&&e.generation===this.hc&&(this.lc=Math.max(0,this.lc-1)),e.counted=!1,this.uc=this.uc.filter(t=>t!==e)}mv(e,t,r){e.processed||e.generation!==this.hc||(e.processed=!0,this.lv(e.event,t,r,e.targetSessionId,e.targetWindowId))}gv(e){try{var t=e.compressionEnabled?sd(e.event):{event:e.event,size:ir(e.event)};this.mv(e,t.event,t.size)}finally{this.pv(e)}}Ic(){[...this.uc].forEach(e=>{this.gv(e)})}yv(e,t,r,n){var i,s=this,a={event:e,compressionEnabled:t,targetSessionId:r,targetWindowId:n,generation:this.hc,processed:!1,counted:!0};this.uc.push(a),this.lc+=1;var o=(i=l(function*(){try{if(a.processed)return;try{var r,n,i=t?so(e)?yield function(e){return sc.apply(this,arguments)}(e):sd(e):{event:e,size:ir(e)};r=i.event,n=i.size}catch(t){i3.error("could not process queued compression event - will use uncompressed event",t),r=e,n=ir(e)}s.mv(a,r,n)}finally{s.pv(a)}}),function(){return i.apply(this,arguments)});this.iv=this.iv?this.iv.catch(()=>{}).then(o):o()}onRRwebEmit(e){var t,r,n,i,s,a,o;if(this._instance.sessionManager&&(this.jc(),e&&rA(e))){if(4===e.type){var l=this.Pc(e.data.href);if(this.Uc=l,!l)return;e.data.href=l}else this.zc();if(null==(t=this.Uh)||t.checkUrlTriggers(this.sessionId,()=>this.Zc(),()=>this.Jc(),(e,t)=>this.Qc(e,t)),!this.dh.urlBlocked||5===e.type&&"recording paused"===e.data.tag){2===e.type&&(null!=(h=i8())&&null!=h.wasMaxDepthReached&&h.wasMaxDepthReached()&&(this.Qd=!0),this.vv(),Promise.resolve().then(()=>this.vv()),this.Hc(),null==(u=this.nv)||u.reset(),null==(d=this._instance.persistence)||d.register_once({[nW]:e.timestamp},void 0)),2===e.type&&null!=(r=this.Uh)&&r.hasPendingTriggers(this.sessionId)&&this.wv();var h,u,d,c=this.nv?this.nv.throttleMutations(e):e;if(c){var p,f=function(e){if(e&&rA(e)&&6===e.type&&rA(e.data)&&"rrweb/console@1"===e.data.plugin){e.data.payload.payload.length>10&&(e.data.payload.payload=e.data.payload.payload.slice(0,10),e.data.payload.payload.push("...[truncated]"));for(var t=[],r=0;e.data.payload.payload.length>r;r++)t.push(e.data.payload.payload[r]&&e.data.payload.payload[r].length>2e3?e.data.payload.payload[r].slice(0,2e3)+"...[truncated]":e.data.payload.payload[r]);return e.data.payload.payload=t,e}return e}(c),m=sm(f)?f.data.payload:null,v=sv(f)?f.data.payload:null;if(m||v){var g=null!=m?m:v;null!=g&&g.lastActivityTimestamp&&(f.timestamp=g.lastActivityTimestamp)}else this.bv(f);2===e.type&&(this.sc.push([this.Dr,e.timestamp]),this.sc.length>6&&(this.sc=this.sc.slice(-6)));var y=null!=(n=null!=(i=null==m?void 0:m.currentSessionId)?i:null==v?void 0:v.nextSessionId)?n:this.Dr,b=null!=(s=null!=(a=null==m?void 0:m.currentWindowId)?a:null==v?void 0:v.nextWindowId)?s:this.Or;if(!0!==this.Zh||sf(p=f)||sm(p)||sv(p)){if(sf(f)){var w=f.data.payload;w&&(f.timestamp=w.lastActivityTimestamp+w.threshold)}var S=null==(o=this._instance.config.session_recording.compress_events)||o;if(this.lc>0||S&&so(f))this.yv(f,S,y,b);else{var k=S?sd(f):{event:f,size:ir(f)};this.lv(f,k.event,k.size,y,b)}}}}}}get status(){return this.Uh?this.Uh.getStatus({instance:this._instance,sessionId:this.sessionId,isSampled:this.Bh,rrwebError:this.Yh,urlTriggerMatching:this.dh,eventTriggerMatching:this.fh,linkedFlagMatching:this.ph,remoteConfig:this.eu}):n$}log(e,t){var r;void 0===t&&(t="log"),null==(r=this._instance.sessionRecording)||r.onRRwebEmit({type:6,data:{plugin:"rrweb/console@1",payload:{level:t,trace:[],payload:[JSON.stringify(e)]}},timestamp:Date.now()})}overrideLinkedFlag(){this.ph.linkedFlagSeen=!0,this.xh(),this.Vc(),this.Rh("linked_flag_overridden")}overrideSampling(){var e;null==(e=this._instance.persistence)||e.register({[nO]:this.sessionId,[nE]:null}),this.xh(),this.Vc(),this.Rh("sampling_overridden")}overrideTrigger(e){this.Qc(e),this.Vc()}kv(){try{var e,t=null==rf||null==(e=rf.location)?void 0:e.href;if(!t)return;var r=this.Pc(t);if(!r)return;return new URL(r).hostname||void 0}catch(e){return}}ev(){this._v&&(clearTimeout(this._v),this._v=void 0)}uv(){this._v||(this._v=setTimeout(()=>{this.Cc()},2e3))}Sv(){return this.ac!==this.R.sessionId&&0!==this.R.data.length&&this.R.data.every(e=>(null==e?void 0:e.type)===5&&!sm(e)&&!sv(e))}Cc(){if(this.ev(),this.Jh)return this.R;if(this.Sv())return this.R.size>943718.4?this.Rc():this.R;var e=this.R;null==(r=this.Uh)||r.ensureSamplingDecision(this.sessionId);var t=this._c();if(this.status===nV||this.status===nZ||this.status===n$||t)return this.uv(),this.R;if(this.R!==e)return this.R;if(e.data.length>0){var r,n,i=this.kv();(function e(t,r){if(void 0===r&&(r=6606028.8),t.size>=r&&t.data.length>1){var n=Math.floor(t.data.length/2),i=t.sizes.slice(0,n),s=t.sizes.slice(n);return[e({size:i.reduce((e,t)=>
1e+t,0),data:t.data.slice(0,n),sizes:i,sessionId:t.sessionId,windowId:t.windowId}),e({size:s.reduce((e,t)=>e+t,0),data:t.data.slice(n),sizes:s,sessionId:t.sessionId,windowId:t.windowId})].flatMap(e=>e)}return[t]})(e).forEach(e=>{var t;null==(t=this.gc)||t.trackSize(e.sessionId,e.size),this.Mv({$snapshot_bytes:e.size,$snapshot_data:e.data,$session_id:e.sessionId,$window_id:e.windowId,$lib:rz.LIB_NAME,$lib_version:rz.LIB_VERSION,$snapshot_host:i})}),null==(n=this.Uh)||n.onFlushComplete()}return this.Rc()}dv(e){var t,r=2+((null==(t=this.R)?void 0:t.data.length)||0),n=e.$session_id,i=this.R.sessionId!==n;if(i||!0!==this.Zh&&!this.Jh&&this.R.size+e.$snapshot_bytes+r>943718.4){var s=this.Dr;if(this.R=this.Cc(),this.Dr!==s)return;i&&this.R.data.length>0&&(this.R=this.Rc()),this.R.sessionId=n,this.R.windowId=e.$window_id}this.Jh&&(this.Xh||this.R.size+e.$snapshot_bytes+r>943718.4)?this.Xh||(this.Xh=!0,this.R=this.Rc()):(this.R.size+=e.$snapshot_bytes,this.R.data.push(e.$snapshot_data),this.R.sizes.push(e.$snapshot_bytes),!0===this.Zh||this.Jh||this.uv())}Mv(e){this._instance.capture("$snapshot",e,{_url:this._instance.requestRouter.endpointFor("api",this.jh),_noTruncate:!0,_batchKey:"recordings",skip_client_rate_limiting:!0})}get Sc(){var e,t,r=null==(e=this.R)?void 0:e.data[(null==(t=this.R)?void 0:t.data.length)-1],n=this.Ph.checkAndGetSessionAndWindowId(!0);return r?r.timestamp-n.sessionStartTimestamp:null}wv(){if(!this.R||0===this.R.data.length)return this.Rc();for(var e=-1,t=this.R.data.length-1;t>=0;t--)if(4===this.R.data[t].type){e=t;break}return 0>e?this.Rc():(this.R.data=this.R.data.slice(e),this.R.sizes=this.R.sizes.slice(e),this.R.size=this.R.sizes.reduce((e,t)=>e+t,0),this.R)}Rc(){return this.R={size:0,data:[],sizes:[],sessionId:this.Dr,windowId:this.Or},this.R}Rh(e,t){this._instance.register_for_session({$session_recording_start_reason:e}),i3.info(e.replace("_"," "),t),"session_id_changed"!==e&&this.Lh("$recording_started",h({reason:e},t))}Iv(e){var t;return 3===e.type&&-1!==i5.indexOf(null==(t=e.data)?void 0:t.source)}bv(e){var t=this.Iv(e);t||!0===this.Zh||e.timestamp-this.Hh>this.Wh&&(this.Zh=!0,clearInterval(this.Gc),this.Lh("sessionIdle",{eventTimestamp:e.timestamp,lastActivityTimestamp:this.Hh,threshold:this.Wh,bufferLength:this.R.data.length,bufferSize:this.R.size}),this.Cc());var r=!1;if(t&&(this.Hh=e.timestamp,this.Zh)){var n="unknown"===this.Zh;this.Zh=!1,n||(this.Lh("sessionNoLongerIdle",{reason:"user activity",type:e.type}),r=!0)}var i=this.Ph.checkAndGetSessionAndWindowId(!t,e.timestamp),s=i.windowId,a=i.sessionId,o=this.Dr!==a,l=this.Or!==s;if(this.Or=s,this.Dr=a,o||l){var h=o&&!1!==this.Zh;h&&(this.Zh="unknown"),this.wc(h)}else t&&this.Vc(),r&&this.Hc()}yc(){var e;null==(e=this.Uh)||e.clearConditionalRecordingPersistence()}get sdkDebugProperties(){var e,t,r,n,i,s,a,o,l,h=this.Ph.checkAndGetSessionAndWindowId(!0).sessionStartTimestamp,u=null==(e=i8())||null==e.getDeferredStylesheetStats?void 0:e.getDeferredStylesheetStats();return{$recording_status:this.status,$sdk_debug_replay_internal_buffer_length:this.R.data.length,$sdk_debug_replay_internal_buffer_size:this.R.size,$sdk_debug_current_session_duration:this.Sc,$sdk_debug_session_start:h,$sdk_debug_replay_flushed_size:null==(t=this.gc)?void 0:t.currentTrackedSize(this.sessionId),$sdk_debug_replay_full_snapshots:this.sc,$snapshot_max_depth_exceeded:this.Qd,$sdk_debug_replay_slowest_full_snapshot_ms:iQ(null==(r=this.av)?void 0:r.durationMs),$sdk_debug_replay_slowest_full_snapshot_stylesheet_ms:iQ(null==(n=this.av)?void 0:n.stylesheetMs),$sdk_debug_replay_slowest_full_snapshot_nodes:null==(i=this.av)?void 0:i.nodeCount,$sdk_debug_replay_slowest_full_snapshot_css_rules:null==(s=this.av)?void 0:s.cssRuleCount,$sdk_debug_replay_slowest_full_snapshot_css_rules_non_deferrable:null==(a=this.av)?void 0:a.nonDeferrableCssRuleCount,$sdk_debug_replay_deferred_stylesheets:null==u?void 0:u.deferredCount,$sdk_debug_replay_deferred_stylesheets_failed:null==u?void 0:u.failedCount,$sdk_debug_replay_deferred_stylesheets_abandoned:null==u?void 0:u.abandonedCount,$sdk_debug_replay_deferred_stylesheet_ms:iQ(null==u?void 0:u.totalMs),$sdk_debug_replay_deferred_stylesheet_slowest_slice_ms:iQ(null==u?void 0:u.slowestSliceMs),$sdk_debug_replay_slowest_mutation_batch_ms:iQ(null==(o=i8())||null==o.getMutationCost||null==(o=o.getMutationCost())?void 0:o.slowestBatchMs),$sdk_debug_replay_discarded_duration_samples:null==(l=i8())||null==l.getDiscardedDurationSamples?void 0:l.getDiscardedDurationSamples(),$sdk_debug_replay_rrweb_error:this.Yh,$sdk_debug_rrweb_attached:!!this.qh,$sdk_debug_rrweb_start_attempted:this.Zd}}Yc(){var e;if(!this.qh){this.Zd=!0;var t,r,n,i,s={blockClass:"ph-no-capture",blockSelector:void 0,ignoreClass:"ph-ignore-input",maskTextClass:"ph-mask",maskTextSelector:void 0,maskTextFn:void 0,maskAllInputs:!0,maskInputOptions:{password:!0},maskInputFn:void 0,maskAllElementAttributes:!1,maskAttributeFn:void 0,slimDOMOptions:{}
1,collectFonts:!1,inlineStylesheet:!0,inlineStylesheetBudgetRules:1e4,recordCrossOriginIframes:!1,sampling:void 0,attributeFilter:void 0};for(var a of Object.entries(this._instance.config.session_recording||{})){var o=a[0],l=a[1];if(o in s)if("maskInputOptions"===o)s.maskInputOptions=h({password:!0},l);else if("sampling"===o){var u=null!=l?l:{},d={};rL(u.mousemove)||(d.mousemove=u.mousemove),rL(u.mouseInteraction)||(d.mouseInteraction=u.mouseInteraction),s.sampling=d}else s[o]=l}this.Oc&&this.Oc.enabled&&(s.recordCanvas=!0,s.sampling=h({},s.sampling,{canvas:this.Oc.fps}),s.dataURLOptions={type:"image/webp",quality:this.Oc.quality},s.canvasResolutionScale=this.Fc,s.canvasMasking={configured:()=>{var e;return rx(null==(e=this._instance.config.session_recording)||null==(e=e.canvasCapture)?void 0:e.maskRegionsFn)},regionsFn:e=>{var t,r,n=null==(r=this._instance.config.session_recording)||null==(r=r.canvasCapture)?void 0:r.maskRegionsFn;if(rx(n))try{return null!=(t=n(e))?t:null}catch(e){return this.ic||(this.ic=!0,i3.warn("canvasCapture.maskRegionsFn threw, canvas frames will be skipped",e)),null}}}),this.Tc&&(s.maskAllInputs=null==(t=this.Tc.maskAllInputs)||t,s.maskTextSelector=null!=(r=this.Tc.maskTextSelector)?r:void 0,s.blockSelector=null!=(n=this.Tc.blockSelector)?n:void 0,s.maskAllElementAttributes=null!=(i=this.Tc.maskAllElementAttributes)&&i),s.maskAllElementAttributes&&s.maskAttributeFn&&(s.maskAttributeFn=void 0,this.rc||(this.rc=!0,i3.warn('`maskAllElementAttributes` and `maskAttributeFn` are mutually exclusive, and `maskAttributeFn` is being ignored. Remove one of the two. Note that `maskAllElementAttributes` can also come from your project\'s "Privacy and masking" settings. See https://posthog.com/docs/session-replay/privacy'))),this.Ec();var c=i6();if(c){this.nv=null!=(e=this.nv)?e:new iB(c,{refillRate:this._instance.config.session_recording.__mutationThrottlerRefillRate,bucketSize:this._instance.config.session_recording.__mutationThrottlerBucketSize,onBlockedNode:(e,t)=>{var r="Too many mutations on node '"+e+"'. Rate limiting. This could be due to SVG animations or something similar";i3.info(r,{node:t}),this.log(i2+" "+r,"warn")}});var p=this.Dc();if(this.qh=c(h({emit:e=>{this.onRRwebEmit(e)},plugins:p,errorHandler:(e,t)=>"rrweb"===t&&(this.nc||(this.nc=!0,i3.error("rrweb internal error - recording will continue but may be incomplete",e)),!0)},s)),!this.qh)return this.Yh=!0,void i3.error("rrweb failed to start - Loss of recording data is possible. Check the browser console for rrweb errors.");this.Yh=!1,this.Hh=Date.now(),this.Zh=rP(this.Zh)?this.Zh:"unknown",this.tryAddCustomEvent("$remote_config_received",this.eu),this.Lh("$session_options",{sessionRecordingOptions:s,activePlugins:p.map(e=>null==e?void 0:e.name)}),this.Lh("$posthog_config",{config:this._instance.config})}else i3.error("_startRecorder was called but rrwebRecord is not available. This indicates something has gone wrong.")}}tryAddCustomEvent(e,t){return this.Lh(e,t)}}rS.__PosthogExtensions__=rS.__PosthogExtensions__||{},rS.__PosthogExtensions__.rrwebPlugins={getRecordConsolePlugin:e=>({name:"rrweb/console@1",observer:rp,options:e}),getRecordNetworkPlugin:e=>({name:"rrweb/network@1",observer:nC,options:e})},rS.__PosthogExtensions__.rrweb={record:rt,version:"v2",wasMaxDepthReached:()=>e0,resetMaxDepthState(){e0=!1,eK=!1},getLastSnapshotCost:()=>G,getMutationCost:()=>h({},Y),getDeferredStylesheetStats:()=>h({},Q),getDiscardedDurationSamples:()=>B,resetSnapshotCostState(){U=0,q=0,$=0,H=0,B=0,j=F(),G=null,V=null,Z=[],X=0,J=0,Y={slowestBatchMs:0},Q={deferredCount:0,failedCount:0,abandonedCount:0,totalMs:0,slowestSliceMs:0}}},rS.__PosthogExtensions__.initSessionRecording=(e,t)=>new sg(e,t)}()}}]);
Line numbers count LF bytes from the start of the resource, as the search results do. Vendor segments are library code the classifier recognised; they are stored but not indexed. Bytes are shown as Latin1 characters, one per byte.