!function(){try{var e="undefined"!=typeof window?window:"undefined"!=typeof global?global:"undefined"!=typeof self?self:{},t=(new e.Error).stack;t&&(e._sentryDebugIds=e._sentryDebugIds||{},e._sentryDebugIds[t]="8eb96d2b-a03a-40ce-a07b-a4d829d463a1",e._sentryDebugIdIdentifier="sentry-dbid-8eb96d2b-a03a-40ce-a07b-a4d829d463a1")}catch(e){}}(),(self.webpackChunk_N_E=self.webpackChunk_N_E||[]).push([[2888],{36154:function(e,t,n){"use strict";function r(e){var t=Object.create(null);return function(n){return void 0===t[n]&&(t[n]=e(n)),t[n]}}n.d(t,{Z:function(){return r}})},87654:function(e,t,n){"use strict";n.d(t,{xB:function(){return eE},iv:function(){return eb}});var r,i,o,s=n(75271),a=n.t(s,2),c=function(){function e(e){var t=this;this._insertTag=function(e){var n;n=0===t.tags.length?t.insertionPoint?t.insertionPoint.nextSibling:t.prepend?t.container.firstChild:t.before:t.tags[t.tags.length-1].nextSibling,t.container.insertBefore(e,n),t.tags.push(e)},this.isSpeedy=void 0===e.speedy||e.speedy,this.tags=[],this.ctr=0,this.nonce=e.nonce,this.key=e.key,this.container=e.container,this.prepend=e.prepend,this.insertionPoint=e.insertionPoint,this.before=null}var t=e.prototype;return t.hydrate=function(e){e.forEach(this._insertTag)},t.insert=function(e){if(this.ctr%(this.isSpeedy?65e3:1)==0){var t;this._insertTag(((t=document.createElement("style")).setAttribute("data-emotion",this.key),void 0!==this.nonce&&t.setAttribute("nonce",this.nonce),t.appendChild(document.createTextNode("")),t.setAttribute("data-s",""),t))}var n=this.tags[this.tags.length-1];if(this.isSpeedy){var r=function(e){if(e.sheet)return e.sheet;for(var t=0;t0?p[E]+" "+b:h(b,/&\f/g,p[E])).trim())&&(c[v++]=S);return w(e,t,n,0===i?M:a,c,u,d)}function F(e,t,n,r){return w(e,t,n,L,m(e,0,r),m(e,r+1,-1),r)}var q=function(e,t,n){for(var r=0,i=0;r=i,i=R(),38===r&&12===i&&(t[n]=1),!A(i);)C();return m(T,e,b)},H=function(e,t){var n=-1,r=44;do switch(A(r)){case 0:38===r&&12===R()&&(t[n]=1),e[n]+=q(b-1,t,n);break;case 2:e[n]+=N(r);break;case 4:if(44===r){e[++n]=58===R()?"&\f":"",t[n]=e[n].length;break}default:e[n]+=u(r)}while(r=C());return e},W=function(e,t){var n;return n=H(k(e),t),T="",n},G=new WeakMap,z=function(e){if("rule"===e.type&&e.parent&&!(e.length<1)){for(var t=e.value,n=e.parent,r=e.column===n.column&&e.line===n.line;"rule"!==n.type;)if(!(n=n.parent))return;if((1!==e.props.length||58===t.charCodeAt(0)||G.get(n))&&!r){G.set(e,!0);for(var i=[],o=W(t,i),s=n.props,a=0,c=0;a-1&&!e.return)switch(e.type){case L:e.return=function e(t,n){switch(45^p(t,0)?(((n<<2^p(t,0))<<2^p(t,1))<<2^p(t,2))<<2^p(t,3):0){case 5103:return D+"print-"+t+t;case 5737:case 4201:case 3177:case 3433:case 1641:case 4457:case 2921:case 5572:case 6356:case 5844:case 3191:case 6645:case 3005:case 6391:case 5879:case 5623:case 6135:case 4599:case 4855:case 4215:case 6389:case 5109:case 5365:case 5621:case 3829:return D+t+t;case 5349:case 4246:case 4810:case 6968:case 2756:return D+t+x+t+I+t+t;case 6828:case 4268:return D+t+I+t+t;case 6165:return D+t+I+"flex-"+t+t;case 5187:return D+t+h(t,/(\w+).+(:[^]+)/,D+"box-$1$2"+I+"flex-$1$2")+t;case 5443:return D+t+I+"flex-item-"+h(t,/flex-|-self/,"")+t;case 4675:return D+t+I+"flex-line-pack"+h(t,/align-content|flex-|-self/,"")+t;case 5548:return D+t+I+h(t,"shrink","negative")+t;case 5292:return D+t+I+h(t,"basis","preferred-size")+t;case 6060:return D+"box-"+h(t,"-grow","")+D+t+I+h(t,"grow","positive")+t;case 4554:return D+h(t,/([^-])(transform)/g,"$1"+D+"$2")+t;case 6187:return h(h(h(t,/(zoom-|grab)/,D+"$1"),/(image-set)/,D+"$1"),t,"")+t;case 5495:case 3959:return h(t,/(image-set\([^]*)/,D+"$1$`$1");case 4968:return h(h(t,/(.+:)(flex-)?(.*)/,D+"box-pack:$3"+I+"flex-pack:$3"),/s.+-b[^;]+/,"justify")+D+t+t;case 4095:case 3583:case 4068:case 2532:return h(t,/(.+)-inline(.+)/,D+"$1$2")+t;case 8116:case 7059:case 5753:case 5535:case 5445:case 5701:case 4933:case 4677:case 5533:case 5789:case 5021:case 4765:if(g(t)-1-n>6)switch(p(t,n+1)){case 109:if(45!==p(t,n+4))break;case 102:return h(t,/(.+:)(.+)-([^]+)/,"$1"+D+"$2-$3$1"+x+(108==p(t,n+3)?"$3":"$2-$3"))+t;case 115:return~f(t,"stretch")?e(h(t,"stretch","fill-available"),n)+t:t}break;case 4949:if(115!==p(t,n+1))break;case 6444:switch(p(t,g(t)-3-(~f(t,"!important")&&10))){case 107:return h(t,":",":"+D)+t;case 101:return h(t,/(.+:)([^;!]+)(;|!.+)?/,"$1"+D+(45===p(t,14)?"inline-":"")+"box$3$1"+D+"$2$3$1"+I+"$2box$3")+t}break;case 5936:switch(p(t,n+11)){case 114:return D+t+I+h(t,/[svh]\w+-[tblr]{2}/,"tb")+t;case 108:return D+t+I+h(t,/[svh]\w+-[tblr]{2}/,"tb-rl")+t;case 45:return D+t+I+h(t,/[svh]\w+-[tblr]{2}/,"lr")+t}return D+t+I+t+t}return t}(e.value,e.length);break;case j:return U([O(e,{value:h(e.value,"@","@"+D)})],r);case M:if(e.length){var i,o;return i=e.props,o=function(t){var n;switch(n=t,(n=/(::plac\w+|:read-\w+)/.exec(n))?n[0]:n){case":read-only":case":read-write":return U([O(e,{props:[h(t,/:(read-\w+)/,":"+x+"$1")]})],r);case"::placeholder":return U([O(e,{props:[h(t,/:(plac\w+)/,":"+D+"input-$1")]}),O(e,{props:[h(t,/:(plac\w+)/,":"+x+"$1")]}),O(e,{props:[h(t,/:(plac\w+)/,I+"input-$1")]})],r)}return""},i.map(o).join("")}}}],V=function(e,t,n){var r=e.key+"-"+t.name;!1===n&&void 0===e.registered[r]&&(e.registered[r]=t.styles)},Y=function(e,t,n){V(e,t,n);var r=e.key+"-"+t.name;if(void 0===e.inserted[t.name]){var i=t;do e.insert(t===i?"."+r:"",i,e.sheet,!0),i=i.next;while(void 0!==i)}},Z={animationIterationCount:1,aspectRatio:1,borderImageOutset:1,borderImageSlice:1,borderImageWidth:1,boxFlex:1,boxFlexGroup:1,boxOrdinalGroup:1,columnCount:1,columns:1,flex:1,flexGrow:1,flexPositive:1,flexShrink:1,flexNegative:1,flexOrder:1,gridRow:1,gridRowEnd:1,gridRowSpan:1,gridRowStart:1,gridColumn:1,gridColumnEnd:1,gridColumnSpan:1,gridColumnStart:1,msGridRow:1,msGridRowSpan:1,msGridColumn:1,msGridColumnSpan:1,fontWeight:1,lineHeight:1,opacity:1,order:1,orphans:1,scale:1,tabSize:1,widows:1,zIndex:1,zoom:1,WebkitLineClamp:1,fillOpacity:1,floodOpacity:1,stopOpacity:1,strokeDasharray:1,strokeDashoffset:1,strokeMiterlimit:1,strokeOpacity:1,strokeWidth:1},K=n(36154),Q=/[A-Z]|^ms/g,ee=/_EMO_([^_]+?)_([^]*?)_EMO_/g,et=function(e){return 45===e.charCodeAt(1)},en=function(e){return null!=e&&"boolean"!=typeof e},er=(0,K.Z)(function(e){return et(e)?e:e.replace(Q,"-$&").toLowerCase()}),ei=function(e,t){switch(e){case"animation":case"animationName":if("string"==typeof t)return t.replace(ee,function(e,t,n){return o={name:t,styles:n,next:o},t})}return 1===Z[e]||et(e)||"number"!=typeof t||0===t?t:t+"px"};function eo(e,t,n){if(null==n)return"";if(void 0!==n.__emotion_styles)return n;switch(typeof n){case"boolean":return"";case"object":if(1===n.anim)return o={name:n.name,styles:n.styles,next:o},n.name;if(void 0!==n.styles){var r=n.next;if(void 0!==r)for(;void 0!==r;)o={name:r.name,styles:r.styles,next:o},r=r.next;return n.styles+";"}return function(e,t,n){var r="";if(Array.isArray(n))for(var i=0;i=4;++r,i-=4)t=(65535&(t=255&e.charCodeAt(r)|(255&e.charCodeAt(++r))<<8|(255&e.charCodeAt(++r))<<16|(255&e.charCodeAt(++r))<<24))*1540483477+((t>>>16)*59797<<16),t^=t>>>24,n=(65535&t)*1540483477+((t>>>16)*59797<<16)^(65535&n)*1540483477+((n>>>16)*59797<<16);switch(i){case 3:n^=(255&e.charCodeAt(r+2))<<16;case 2:n^=(255&e.charCodeAt(r+1))<<8;case 1:n^=255&e.charCodeAt(r),n=(65535&n)*1540483477+((n>>>16)*59797<<16)}return n^=n>>>13,(((n=(65535&n)*1540483477+((n>>>16)*59797<<16))^n>>>15)>>>0).toString(36)}(s)+l,styles:s,next:o}}var ec=!!a.useInsertionEffect&&a.useInsertionEffect,el=ec||function(e){return e()},eu=ec||s.useLayoutEffect,ed=s.createContext("undefined"!=typeof HTMLElement?function(e){var t,n,r,i,o,s,a=e.key;if("css"===a){var l=document.querySelectorAll("style[data-emotion]:not([data-s])");Array.prototype.forEach.call(l,function(e){-1!==e.getAttribute("data-emotion").indexOf(" ")&&(document.head.appendChild(e),e.setAttribute("data-s",""))})}var d=e.stylisPlugins||J,E={},O=[];i=e.container||document.head,Array.prototype.forEach.call(document.querySelectorAll('style[data-emotion^="'+a+' "]'),function(e){for(var t=e.getAttribute("data-emotion").split(" "),n=1;n2||A(S)>3?"":" "}(D);break;case 92:G+=function(e,t){for(var n;--t&&C()&&!(S<48)&&!(S>102)&&(!(S>57)||!(S<65))&&(!(S>70)||!(S<97)););return n=b+(t<6&&32==R()&&32==C()),m(T,e,n)}(b-1,7);continue;case 47:switch(R()){case 42:case 47:_(w(d=function(e,t){for(;C();)if(e+S===57)break;else if(e+S===84&&47===R())break;return"/*"+m(T,t,b-1)+"*"+u(47===e?e:C())}(C(),b),n,r,P,u(S),m(d,2,-2),0),l);break;default:G+="/"}break;case 123*M:c[E++]=g(G)*j;case 125*M:case 59:case 0:switch(U){case 0:case 125:L=0;case 59+O:-1==j&&(G=h(G,/\f/g,"")),x>0&&g(G)-k&&_(x>32?F(G+";",i,r,k-1):F(h(G," ","")+";",i,r,k-2),l);break;case 59:G+=";";default:if(_(W=B(G,n,r,E,O,o,c,$,q=[],H=[],k),s),123===U){if(0===O)e(G,n,W,W,q,s,k,c,H);else switch(99===I&&110===p(G,3)?100:I){case 100:case 108:case 109:case 115:e(t,W,W,i&&_(B(t,W,W,0,0,o,c,$,o,q=[],k),H),o,H,k,c,i?q:H);break;default:e(G,W,W,W,[""],H,0,c,H)}}}E=O=x=0,M=j=1,$=G="",k=a;break;case 58:k=1+g(G),x=D;default:if(M<1){if(123==U)--M;else if(125==U&&0==M++&&125==(S=b>0?p(T,--b):0,v--,10===S&&(v=1,y--),S))continue}switch(G+=u(U),U*M){case 38:j=O>0?1:(G+="\f",-1);break;case 44:c[E++]=(g(G)-1)*j,j=1;break;case 64:45===R()&&(G+=N(C())),I=R(),O=k=g($=G+=function(e){for(;!A(R());)C();return m(T,e,b)}(b)),U++;break;case 45:45===D&&2==g(G)&&(M=0)}}return s}("",null,null,null,[""],t=k(t=e),0,[0],t),T="",n),I)};o=function(e,t,n,r){s=n,x(e?e+"{"+t.styles+"}":t.styles),r&&(D.inserted[t.name]=!0)};var D={key:a,sheet:new c({key:a,container:i,nonce:e.nonce,speedy:e.speedy,prepend:e.prepend,insertionPoint:e.insertionPoint}),nonce:e.nonce,inserted:E,registered:{},insert:o};return D.sheet.hydrate(O),D}({key:"css"}):null);ed.Provider;var eh=function(e){return(0,s.forwardRef)(function(t,n){return e(t,(0,s.useContext)(ed),n)})},ef=s.createContext({}),ep={}.hasOwnProperty,em="__EMOTION_TYPE_PLEASE_DO_NOT_USE__",eg=function(e,t){var n={};for(var r in t)ep.call(t,r)&&(n[r]=t[r]);return n[em]=e,n},e_=function(e){var t=e.cache,n=e.serialized,r=e.isStringTag;return V(t,n,r),el(function(){return Y(t,n,r)}),null},ey=eh(function(e,t,n){var r,i,o,a=e.css;"string"==typeof a&&void 0!==t.registered[a]&&(a=t.registered[a]);var c=e[em],l=[a],u="";"string"==typeof e.className?(r=t.registered,i=e.className,o="",i.split(" ").forEach(function(e){void 0!==r[e]?l.push(r[e]+";"):e&&(o+=e+" ")}),u=o):null!=e.className&&(u=e.className+" ");var d=ea(l,void 0,s.useContext(ef));u+=t.key+"-"+d.name;var h={};for(var f in e)ep.call(e,f)&&"css"!==f&&f!==em&&(h[f]=e[f]);return h.className=u,n&&(h.ref=n),s.createElement(s.Fragment,null,s.createElement(e_,{cache:t,serialized:d,isStringTag:"string"==typeof c}),s.createElement(c,h))});n(72535);var ev=function(e,t){var n=arguments;if(null==t||!ep.call(t,"css"))return s.createElement.apply(void 0,n);var r=n.length,i=Array(r);i[0]=ey,i[1]=eg(e,t);for(var o=2;o!1){this._tagParts=[],this._tagText="",this._enabled=!0,this._level=i.NONE,this.tag="",this.description="",this._predicate=function(){return!1},this.tag=e,this.description=t,this._predicate=n,this._tagParts=e.split("."),this._tagText=`[${e}]`}_print(e,t,n){if(!this._enabled&&!(this._level&t))return;let r={args:n,type:e,tag:this.tag};this._predicate(r)||console[e](this._tagText,...n)}matchesTag(e){let t=Array.isArray(e)?e:e.split("."),n=this._tagParts;if(t.length>n.length)return!1;for(let e=0,r=t.length;e{}}function y(e){let t=Object.keys(h).filter(e=>h[e]).sort();return e?t.map(e=>({tag:e,description:h[e].description||"No description."})):t.reduce((e,t)=>(e[t]=h[t].description||"No description",e),{})}function v(e){var t;let n=Array.isArray(e)?e:[e],r=n.length;for(;r--;){let e=null===(t=n[r])||void 0===t?void 0:t.toLowerCase(),i=f.length;for(;i--;){let t=f[i];t.matchesTag(e)&&t.enable()}}}function E(e){var t;let n=Array.isArray(e)?e:[e],r=n.length;for(;r--;){let e=null===(t=n[r])||void 0===t?void 0:t.toLowerCase(),i=f.length;for(;i--;){let t=f[i];t.matchesTag(e)&&t.disable()}}}function b(e){m=e;let t=f.length;for(;t--;){let n=f[t];n&&n.setLevel(e)}}function S(){let e=f.length;for(;e--;)f[e]&&f[e].enable()}function T(){let e=f.length;for(;e--;)f[e]&&f[e].disable()}function w(e,t){let n,r;if("string"==typeof e?(n=e.toLowerCase(),r=t):(n=e.tag,r=e.description),h.hasOwnProperty(n)&&h[n])return h[n];let i=new l(n,r,p);return i.setLevel(m),h[n]=i,f.push(i),i}function O(e){let t=e.toLowerCase();if(!h.hasOwnProperty(t)||!h[t])return;let n=h[t];h[t]=null;let r=f.indexOf(n);-1!==r&&f.splice(r,1)}},46847:function(e,t,n){"use strict";n.d(t,{n:function(){return i},q:function(){return r}});let r=function(e,t){try{if("number"==typeof e())return e}catch(e){}let n=t(),r=0;return()=>r=Math.max(r,t()-n)}(()=>performance.now(),Date.now),i=(e,t=r())=>Math.round(Math.abs(t-e))},43048:function(e,t,n){"use strict";n.r(t),n.d(t,{Base62:function(){return r},Base64:function(){return i}});var r={};n.r(r),n.d(r,{fromBytes:function(){return d},fromHex:function(){return p},toBytes:function(){return h},toHex:function(){return f}});var i={};n.r(i),n.d(i,{decode:function(){return y},encode:function(){return _}});let o="0123456789abcdefghijklmnopqrstuvwxyzABCDEFGHIJKLMNOPQRSTUVWXYZ",s={},a={};function c(e,t,n){let r=[0],i=[1];for(let o of e)(function(e,t,n,r){let i,o,s=0;for(o=0;o{let e=[];for(let t=0;t<256;++t)e[t]=255;for(let t=0;t>2),m.charAt((3&e)<<4),"==");break}let o=t.charCodeAt(i++);if(i===r){n.push(m.charAt(e>>2),m.charAt((3&e)<<4|(240&o)>>4),m.charAt((15&o)<<2),"=");break}let s=t.charCodeAt(i++);n.push(m.charAt(e>>2),m.charAt((3&e)<<4|(240&o)>>4),m.charAt((15&o)<<2|(192&s)>>6),m.charAt(63&s))}return n.join("")},y=function(e){let t,n;let r=String(e),i=[],o=r.length,s=0;for(;;){do t=g.charCodeAt(255&r.charCodeAt(s++));while(255===t&&s>4)&255);do t=g.charCodeAt(255&r.charCodeAt(s++));while(255===t&&s>2)&255);do n=g.charCodeAt(255&r.charCodeAt(s++));while(255===n&&swindow.btoa(e),y=e=>window.atob(e))},84539:function(e,t,n){"use strict";let r;n.d(t,{B:function(){return i},vp:function(){return h}});class i{constructor(e,t){this.defaultPrevented=!1,this.immediateStopped=!1,this.stopped=!1,this.type=e,this.data=t}preventDefault(){this.defaultPrevented=!0}stopPropagation(){this.stopped=!0}stopImmediatePropagation(){this.immediateStopped=!0}}let o="undefined"!=typeof window,s=[];function a(){var e;let t=s.splice(0);if(t.length)for(let n=0,r=t.length;n{let t=!s.length;s.push(e),t&&r()};function l(e,t,n){for(let r=0,i=e.length;rthis._dispatchFromStore(this._listeners,n)),n}emitSync(e,t){if(!e)throw TypeError("Argument `eventType` is required.");let n=this.createEvent(e,t);return this._dispatchFromStore(this._listeners,n),n}emitEvent(e){return c(()=>this._dispatchFromStore(this._listeners,e)),e}emitEventSync(e){return this._dispatchFromStore(this._listeners,e),e}emitAndWait(e,t,n){if(!e)throw TypeError("Argument `eventType` is required.");let r=this.createEvent(e,t);return c(()=>{this._dispatchFromStore(this._listeners,r),n.call(this,r)}),r}emitEventAndWait(e,t){return c(()=>{this._dispatchFromStore(this._listeners,e),t.call(this,e)}),e}proxyEmit(e,t,n){if(!e||"function"!=typeof e.on)throw TypeError("Proxy source must be an EventEmitter");if(e===this)throw ReferenceError("Cannot create recursive proxy.");if(!t||!n)throw TypeError("Parameter sourceType and targetType are required.");let r=e=>{e.stopped||this.emitAndWait(n,e.data,t=>{t.defaultPrevented&&e.preventDefault()})};return e.on(t,r),r}proxyEmitSync(e,t,n){if(!e||"function"!=typeof e.on)throw TypeError("Proxy source must be an EventEmitter");if(e===this)throw ReferenceError("Cannot create recursive proxy.");if(!t||!n)throw TypeError("Parameter sourceType and targetType are required.");let r=e=>{if(e.stopped)return;let t=this.createEvent(n,e.data);this.emitEventSync(t),t.defaultPrevented&&e.preventDefault()};return e.on(t,r),r}proxyEmitAll(e,t){for(let n in t)t.hasOwnProperty(n)&&this.proxyEmit(e,n,t[n])}proxyEmitAllSync(e,t){for(let n in t)t.hasOwnProperty(n)&&this.proxyEmitSync(e,n,t[n])}onAddListener(e,t,n={}){let r=this._metaListeners.add;return u(r,e,t,n)&&d(r,e,t,n),this}onRemoveListener(e,t,n={}){let r=this._metaListeners.remove;return u(r,e,t,n)&&d(r,e,t,n),this}}},57858:function(e,t){"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.createSemanticMetricClient=void 0,t.createSemanticMetricClient=function(e){return{name:"SemanticMetricClient",environments:["browser","device"],data:e}}},54138:function(e,t){"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.createSemanticMetricClientNonAuth=void 0,t.createSemanticMetricClientNonAuth=function(e){return{name:"SemanticMetricClientNonAuth",environments:["browsernonauth","devicenonauth"],data:e}}},12563:function(e,t){"use strict";t.i=void 0,t.i=function(e){return{name:"EventSenderStats2NonAuth",environments:["devicenonauth","browsernonauth","desktopnonauth"],data:e}}},47863:function(e,t){"use strict";t.t=void 0,t.t=function(e){return{name:"RejectedClientEventNonAuth",environments:["browsernonauth","desktopnonauth","devicenonauth"],data:e}}},88664:function(e,t,n){"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.hexToBase64=void 0;var r=n(43048);t.hexToBase64=function(e){if(!e||e.length%2!=0)throw TypeError("Invalid hexString value.");var t=e.split("").reduce(function(e,t,n){return n%2==0?e.push(t):e[e.length-1]=""+e[e.length-1]+t,e},[]),n=String.fromCharCode.apply(null,t.map(function(e){var t=parseInt(e,16);if(isNaN(t))throw TypeError("Invalid hexString value.");return t}));return r.Base64.encode(n)}},87471:function(e,t){"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.createApplicationContext=void 0,t.createApplicationContext=function(e){return function(){return{name:"context_application",data:e}}}},4631:function(e,t){"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.createApplicationDesktopContext=void 0,t.createApplicationDesktopContext=function(e){return function(){return{name:"context_application_desktop",data:e}}}},86153:function(e,t,n){"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.createCacheIdContext=void 0;var r=n(88664);t.createCacheIdContext=function(e){var t=r.hexToBase64(e);return function(){return{name:"context_cache_id",data:{value:t}}}}},35137:function(e,t,n){"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.createClientIdContext=void 0;var r=n(88664);t.createClientIdContext=function(e){var t=r.hexToBase64(e);return function(){return{name:"context_client_id",data:{value:t}}}}},50706:function(e,t){"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.createClientIpContext=void 0,t.createClientIpContext=function(e){return function(){return{name:"context_client_ip",data:{value:e}}}}},84037:function(e,t){"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.createCorrelationIdContext=void 0,t.createCorrelationIdContext=function(e){return function(){return{name:"context_correlation_id",data:{value:e}}}}},31697:function(e,t){"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.createDeviceContext=void 0,t.createDeviceContext=function(e){return function(){return{name:"context_device",data:e}}}},76167:function(e,t){"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.createDeviceDesktopContext=void 0,t.createDeviceDesktopContext=function(e){return function(){return{name:"context_device_desktop",data:e}}}},17931:function(e,t,n){"use strict";Object.defineProperty(t,"__esModule",{value:!0});var r=n(15767);r.__exportStar(n(87471),t),r.__exportStar(n(4631),t),r.__exportStar(n(86153),t),r.__exportStar(n(35137),t),r.__exportStar(n(50706),t),r.__exportStar(n(84037),t),r.__exportStar(n(31697),t),r.__exportStar(n(76167),t),r.__exportStar(n(82147),t),r.__exportStar(n(16936),t),r.__exportStar(n(84012),t)},82147:function(e,t,n){"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.createInstallationIdContext=void 0;var r=n(88664);t.createInstallationIdContext=function(e){var t=r.hexToBase64(e);return function(){return{name:"context_installation_id",data:{value:t}}}}},16936:function(e,t){"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.createOsContext=void 0,t.createOsContext=function(e){return function(){return{name:"context_os",data:e}}}},84012:function(e,t){"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.createUserAgentContext=void 0,t.createUserAgentContext=function(e){if(!e&&"undefined"==typeof navigator)throw Error("userAgent is not provided and navigator.UserAgent is not available");return function(){return{name:"context_user_agent",data:{value:e||navigator.userAgent}}}}},54189:function(e,t,n){"use strict";n.r(t),n.d(t,{Environment:function(){return a},EventSenderEvent:function(){return l},createEventSender:function(){return U}}),(s=a||(a={})).BACKEND="BACKEND",s.BROWSER="BROWSER",s.BROWSER_NON_AUTH="BROWSER_NON_AUTH",s.DESKTOP="DESKTOP",s.DESKTOP_NON_AUTH="DESKTOP_NON_AUTH",s.DEVICE="DEVICE",s.DEVICE_NON_AUTH="DEVICE_NON_AUTH";var r,i,o,s,a,c,l,u,d=n(15767),h=n(18918);n(12509),(r=c||(c={}))[r.NONE=0]="NONE",r[r.LOG=1]="LOG",r[r.DEBUG=2]="DEBUG",r[r.INFO=4]="INFO",r[r.WARN=8]="WARN",r[r.ERROR=16]="ERROR";class f{constructor(){this.tag="",this.description=""}matchesTag(){return!1}setLevel(){}enable(){}disable(){}log(){}debug(){}info(){}warn(){}error(){}}var p=n(12509);class m{constructor(e,t="",n=()=>!1){this._tagParts=[],this._tagText="",this._enabled=!0,this._level=c.NONE,this.tag="",this.description="",this._predicate=function(){return!1},this.tag=e,this.description=t,this._predicate=n,this._tagParts=e.split("."),this._tagText=`[${e}]`}_print(e,t,n){if(!this._enabled&&!(this._level&t))return;let r={args:n,type:e,tag:this.tag};this._predicate(r)||console[e](this._tagText,...n)}matchesTag(e){let t=Array.isArray(e)?e:e.split("."),n=this._tagParts;if(t.length>n.length)return!1;for(let e=0,r=t.length;ee.event_name)},headers:{"content-type":"application/json"},responseType:"json",parseResponseHeaders:!0,payload:JSON.stringify({suppress_persist:this._suppressPersist,events:e}),forget:t,authorize:!t&&this._authorize}).then(this._parseUploadResponse.bind(this,e,t))}_parseUploadResponse(e,t,n){if(t)return Promise.resolve([]);let{body:r,headers:i,status:o}=n,s=this._authorize;if(200!==o||!r)return w.warn("Upload request failed",n),this.emit(l.UPLOAD_REQUEST_FAILED,{authorize:s,status:o}),this._backoff=!0,Promise.resolve(e);let a=[],c=[],u=[];if(r.error&&r.error.length){w.info("response errors",e,r.error);for(let t=0,n=r.error.length;t0&&this.emit(l.UPLOAD_FAILED,{authorize:s,rejected:u,will_retry:c}),f>0&&this.emit(l.UPLOAD_SUCCEEDED,{authorize:this._authorize,num_events:f}),Promise.resolve(a)}upload(e,t=[]){let n=t;if(!e.length)return Promise.resolve({nack:n,backoff:this._backoff});let r=[...e];return this._uploadBatch(r.splice(0,20)).then(e=>{if(n=[...n,...e],this._backoff)n=[...n,...r];else if(r.length)return this.upload(r,n);return{nack:n,backoff:this._backoff}})}lastUpload(e){return e.length?this._uploadBatch(e.splice(0,100),!0).then(e=>0===e.length,()=>!1):Promise.resolve(!0)}shouldBackoff(){return this._backoff}}let C={baseTime:200,ceiling:0,curve:"linear",jitter:!0};class R{constructor(e={}){this._curve=e.curve||C.curve,this._baseTime=e.baseTime||C.baseTime,this._ceiling=e.ceiling||C.ceiling,this._jitter="jitter"in e?!!e.jitter:C.jitter}getTime(e){let t;switch(this._curve){case"static":t=1;break;case"logarithmic":t=Math.log(e);break;case"exponential":t=Math.pow(Math.E,e);break;default:t=e+1}let n=Math.min(4294967296,Math.floor(t*this._baseTime));return this._ceiling&&(n=Math.min(n,this._ceiling)),this._jitter?function(e){let t=e/5;return Math.floor(e-t/2+Math.random()*t)}(n):n}}let A={backoffInitial:!1,baseTime:200,ceiling:0,curve:"linear",jitter:!0,maxDuration:1/0,maxRetries:1/0,maxTime:1/0,retryPredicate:()=>!0};class k{constructor(e,t){let n,r;this._resolver={promise:new Promise((e,t)=>{n=e,r=t}),resolve:n,reject:r},this._ts=0,this._callCount=0,this._tickInterval=0,this._isRunning=!1,this._isDestroyed=!1;let i=Object.assign(Object.assign({},A),t),{backoffInitial:o,maxDuration:s,maxRetries:a,maxTime:c,retryPredicate:l}=i,u=(0,d.__rest)(i,["backoffInitial","maxDuration","maxRetries","maxTime","retryPredicate"]);this._fn=e,this._backoffInitial=o,this._maxDuration=s,this._maxRetries=a,this._maxTime=c,this._retryPredicate=l,this._backoffInitial=o,this._counter=new R(u),this._backoffInitial&&(this._maxRetries+=1)}static init(e,t={}){return new k(e,t).start()}_destroy(){this._isRunning=!1,this._isDestroyed=!0}_failure(e){if(!this._isDestroyed){if(e&&"retryAfter"in e)this._retryAfter(e);else{let t=this._counter.getTime(this._callCount);this._shouldRetry(t,e)?(this._callCount++,this._tickInterval=setTimeout(()=>this._tick(),t)):(this._resolver.reject(e),this._destroy())}}}_retryAfter(e){this._callCount++,this._tickInterval=setTimeout(()=>this._tick(),e.retryAfter)}_success(...e){this._isDestroyed||(this._resolver.resolve(...e),this._destroy())}_shouldRetry(e,t){let n=Date.now()-this._ts+e;return this._callCountthis._success(...e)).catch(e=>this._failure(e))}getResolver(){return this._resolver.promise}start(){return this._isDestroyed?Promise.reject(Error("Backoff already consumed")):(this._isRunning||(this._ts=Date.now(),this._isRunning=!0,this._backoffInitial?(this._callCount=1,this._tickInterval=setTimeout(()=>this._tick(),this._counter.getTime(0))):this._tick()),this._resolver.promise)}stop(){clearTimeout(this._tickInterval),this._destroy()}getRetryCount(){return this._callCount}}var N=n(47863);(o=u||(u={})).INVALID_PAYLOAD="INVALID_PAYLOAD",o.INVALID_NAME="INVALID_NAME",o.UNKNOWN_OWNER="UNKNOWN_OWNER",o.PAYLOAD_SIZE_LIMIT_EXCEEDED="PAYLOAD_SIZE_LIMIT_EXCEEDED";var I=n(12563);class x{static pushToArrIfMissing(e,t){-1===e.indexOf(t)&&e.push(t)}static isMissingFromArray(e,t){return -1===e.indexOf(t)}}class D{_addEventsToEventSenderStatsData(e,t){Object.keys(t).map(n=>{for(let r=0;r{if(x.isMissingFromArray(t.sequence_ids,e))t.sequence_ids.push(e),t.loss_stats_num_entries_per_sequence_id.push(Object.keys(n).length);else{let r=t.sequence_ids.indexOf(e);t.loss_stats_num_entries_per_sequence_id[r]+=Object.keys(n).length}Object.entries(n).map(([e,n])=>{x.pushToArrIfMissing(t.event_names,e);let r=t.event_names.indexOf(e);t.loss_stats_event_name_index.push(r);let i=Object.keys(n);for(let e=0;ee&&t).catch(()=>!1)}initializeContexts(e){if(!(null==e?void 0:e.length))return;let t=this._instanceContexts;for(let n of e){let e=n();(null==e?void 0:e.name)&&(t[e.name]=e.data)}}initFlush(e){let t=this._uploaders[e].shouldBackoff(),{ceiling:n,maxDuration:r,baseTime:i}=this._backoffTimeSettings;return k.init(()=>this.upload(e),{curve:"exponential",backoffInitial:t,retryPredicate:()=>this._transport.isOnline(),ceiling:n,baseTime:t?n:i,maxDuration:r})}waitForConnection(){return new Promise(e=>{this._transport.once(h.TransportEvent.CONNECTION_ONLINE,()=>e())})}upload(e){return this._uploaders[e].upload(this._events[e].splice(0)).then(t=>{if(t.nack.length)throw this._events[e]=t.nack.concat(this._events[e]),Error("Backoff requested");return t})}sendToGabito(e){let t=e?"authorized":"unauthorized";this._transport.isOnline()||this._ongoingUploads[t]||(this._ongoingUploads[t]=this.waitForConnection());let n=this._ongoingUploads[t];if(n)return this._uploadWaiting[t]||(this._uploadWaiting[t]=!0,this._ongoingUploads[t]=n.then(()=>(this._ongoingUploads[t]=!1,this._uploadWaiting[t]=!1,this.sendToGabito(e)))),this._ongoingUploads[t];if(!this._events[t].length)return Promise.resolve({nack:this._events[t],backoff:this._uploaders[t].shouldBackoff()});if(!this._essLastSent||Date.now()-this._essLastSent.getTime()>3e5){let e=[this.makeEvent(this._statsSender.createESSEvent(this._events,this._sequenceIdGenerator.getAllSequenceNumberCounters(),this._sequenceIdGenerator.getSequenceId()))];this._uploaders.unauthorized.upload(e).finally(()=>{this._essLastSent=new Date})}let r=this.initFlush(t).then(e=>(this._ongoingUploads[t]=!1,e)).catch(()=>(this._ongoingUploads[t]=!1,this._transport.isOnline())?(j.consoleLogger.warn(`The events in the queue could not be uploaded. Throwing away ${this._events[t].length} ${t} events.`),this._events[t]=[],{nack:this._events[t],backoff:this._uploaders[t].shouldBackoff()}):this.sendToGabito(e));return this._ongoingUploads[t]=r,r}storeEvent(e,t){let n=this.makeEvent(t);this._events[e?"authorized":"unauthorized"].push(n)}makeEvent(e){let t=this._sequenceIdGenerator;return{sequence_id:t.getSequenceId(),sequence_number:t.nextSequenceNumber(e.name),event_name:e.name,fragments:Object.assign(Object.assign({context_sdk:{version_name:this._sdkVersion,type:"javascript"},context_time:{timestamp:Date.now()}},this._instanceContexts),{message:e.data})}}validateEventData(e,t,n){return e.name?function(e){let t=e.length,n=t;for(;n--;){let r=e.charCodeAt(n);r>127&&r<=2047?t++:r>2047&&r<=65535&&(t+=2),r>=56320&&r<=57343&&n--}return t}(JSON.stringify(e.data))>5e3?u.PAYLOAD_SIZE_LIMIT_EXCEEDED:t&&n&&!n()?u.UNKNOWN_OWNER:null:u.INVALID_NAME}checkIsEventAuthorized(e){return!e.endsWith("NonAuth")}flush(e=!0){return this.sendToGabito(e).then(()=>void 0).catch(()=>void 0)}flushAll(){return Promise.all([this.sendToGabito(!0),this.sendToGabito(!1)]).then(()=>void 0).catch(()=>void 0)}finalFlush(){return this.uploadFlush()}log(e,t={}){this.send(e,t)}send(e,{flush:t=!0}={}){let n=this.checkIsEventAuthorized(e.name),r=this.validateEventData(e,n,this._ownerProvider);if(r===u.UNKNOWN_OWNER&&(j.consoleLogger.warn(`Trying to send an authenticated event without a current owner: ${e.name}`),r=null),r){let t=(0,N.t)({event_name:e.name,reject_reason:r});return this.storeEvent(!1,t),Promise.reject(TypeError(`The event is invalid and has been rejected for reason: ${r}`))}return(this.storeEvent(n,e),t)?this.flush(n):Promise.resolve()}hasContext(...e){return e.every(e=>!!this._instanceContexts[e])}}function U(e){let t={suppressPersist:e.suppressPersist,transport:e.transport};return new j(Object.assign(Object.assign({},e),{uploaders:{authorized:new O(t),unauthorized:new O(Object.assign(Object.assign({},t),{authorize:!1}))}}))}j.consoleLogger=S("EventSender")},11498:function(e,t,n){"use strict";var r=this&&this.__importDefault||function(e){return e&&e.__esModule?e:{default:e}};Object.defineProperty(t,"__esModule",{value:!0}),t.silly=t.verbose=t.debug=t.info=t.warn=t.error=t.log=t.logger=t.default=void 0;var i=n(88474);Object.defineProperty(t,"default",{enumerable:!0,get:function(){return r(i).default}}),Object.defineProperty(t,"logger",{enumerable:!0,get:function(){return i.logger}}),Object.defineProperty(t,"log",{enumerable:!0,get:function(){return i.log}}),Object.defineProperty(t,"error",{enumerable:!0,get:function(){return i.error}}),Object.defineProperty(t,"warn",{enumerable:!0,get:function(){return i.warn}}),Object.defineProperty(t,"info",{enumerable:!0,get:function(){return i.info}}),Object.defineProperty(t,"debug",{enumerable:!0,get:function(){return i.debug}}),Object.defineProperty(t,"verbose",{enumerable:!0,get:function(){return i.verbose}}),Object.defineProperty(t,"silly",{enumerable:!0,get:function(){return i.silly}})},88474:function(e,t){"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.silly=t.verbose=t.debug=t.info=t.warn=t.error=t.log=t.logger=void 0,t.logger={log:(...e)=>console.log(...e),error:(...e)=>console.error(...e),warn:(...e)=>console.warn(...e),info:(...e)=>console.info(...e),debug:(...e)=>console.debug(...e),verbose:(...e)=>console.log("verbose:",...e),silly:(...e)=>console.log("silly:",...e)},t.default=t.logger,t.log=t.logger.log.bind(t.logger),t.error=t.logger.error.bind(t.logger),t.warn=t.logger.warn.bind(t.logger),t.info=t.logger.info.bind(t.logger),t.debug=t.logger.debug.bind(t.logger),t.verbose=t.logger.verbose.bind(t.logger),t.silly=t.logger.silly.bind(t.logger)},77882:function(e,t,n){"use strict";var r=n(12509),i=this&&this.__awaiter||function(e,t,n,r){return new(n||(n=Promise))(function(i,o){function s(e){try{c(r.next(e))}catch(e){o(e)}}function a(e){try{c(r.throw(e))}catch(e){o(e)}}function c(e){var t;e.done?i(e.value):((t=e.value)instanceof n?t:new n(function(e){e(t)})).then(s,a)}c((r=r.apply(e,t||[])).next())})},o=this&&this.__importDefault||function(e){return e&&e.__esModule?e:{default:e}};Object.defineProperty(t,"__esModule",{value:!0}),t.sendMetric=t.reportMetrics=t.createSemanticMetrics=t.asNanoseconds=t.MetricTypes=void 0;let s=o(n(11498)),a=n(88328);t.MetricTypes={COUNTER:"counter",GAUGE:"gauge",TIMER:"timer"},t.asNanoseconds=function(e){return e};let c=(e,t)=>i(void 0,void 0,void 0,function*(){if(Array.isArray(t.reporter)){let n=t.reporter.map(t=>t.send(e));yield Promise.all(n)}else yield t.reporter.send(e)});t.reportMetrics=c;let l=e=>{(void 0!==e.dev?e.dev:r.env&&!1)&&(e.reporter=new a.NoopReporter);let t={queue:[],timeout:void 0,flush(){return i(this,void 0,void 0,function*(){yield c(this.queue,e),this.queue=[],this.timeout=void 0})}},n=!1;return void 0===e.batching&&(e.batching={delay:4e3}),e.batching&&"object"==typeof window&&"function"==typeof window.addEventListener&&window.addEventListener("beforeunload",()=>{n=!0,t.flush()}),{sendMetric:r=>i(void 0,void 0,void 0,function*(){var i,o;let s=Object.assign({},r);if(r.tags&&(s.tags=Object.assign({},r.tags)),s.key=s.key||e.key,!s.key)throw Error(`metric.key is required. Got: "${s.key}". Set it in createSemanticMetrics(...) or pass it to sendMetric(...).`);s.tags=Object.assign({app:null!==(i=e.app)&&void 0!==i?i:s.key,application:null!==(o=e.app)&&void 0!==o?o:s.key},s.tags),e.component_id?s.component_id=s.component_id||e.component_id:s.component_id=e.key,e.batching&&!n?(t.queue.push(s),t.timeout||(t.timeout=setTimeout(()=>t.flush(),e.batching.delay))):yield c([s],e)}),config:e,isWindowUnloading:n,flush:()=>e.batching?t.flush():(s.default.warn("Manual flushing only supported in batch mode. Set config.batching: true"),Promise.resolve())}};t.createSemanticMetrics=l;class u{static init(e){u.config&&s.default.error("SemanticMetrics has already been initialized. This may lead to dangerous side effects such as your metrics disappearing from Grafana due to the `key` value being overwritten by something else"),s.default.warn("The singleton usage of SemanticMetrics will be deprecated. Please use createSemanticMetrics()"),u.config=e;let{sendMetric:t,isWindowUnloading:n}=l(e);u.sendMetric=t,u.isWindowUnloading=n}}t.default=u,t.sendMetric=e=>i(void 0,void 0,void 0,function*(){if(!u.config)throw Error("SemanticMetrics has not been initialized. Call SemanticMetrics.init()");return u.sendMetric(e)})},18007:function(e,t){"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.WEBAPI_URL=t.INTERNAL_WEBGATE_URL=void 0,t.INTERNAL_WEBGATE_URL="https://wgint.spotify.net",t.WEBAPI_URL="https://api.spotify.com"},36383:function(e,t,n){"use strict";var r=this&&this.__createBinding||(Object.create?function(e,t,n,r){void 0===r&&(r=n),Object.defineProperty(e,r,{enumerable:!0,get:function(){return t[n]}})}:function(e,t,n,r){void 0===r&&(r=n),e[r]=t[n]}),i=this&&this.__exportStar||function(e,t){for(var n in e)"default"===n||Object.prototype.hasOwnProperty.call(t,n)||r(t,e,n)},o=this&&this.__importDefault||function(e){return e&&e.__esModule?e:{default:e}};Object.defineProperty(t,"__esModule",{value:!0}),t.default=void 0,i(n(31493),t),i(n(69933),t),i(n(54261),t);var s=n(77882);Object.defineProperty(t,"default",{enumerable:!0,get:function(){return o(s).default}})},31493:function(e,t,n){"use strict";var r=this&&this.__createBinding||(Object.create?function(e,t,n,r){void 0===r&&(r=n),Object.defineProperty(e,r,{enumerable:!0,get:function(){return t[n]}})}:function(e,t,n,r){void 0===r&&(r=n),e[r]=t[n]}),i=this&&this.__exportStar||function(e,t){for(var n in e)"default"===n||Object.prototype.hasOwnProperty.call(t,n)||r(t,e,n)};Object.defineProperty(t,"__esModule",{value:!0}),t.Time=t.Timer=void 0,i(n(77882),t),i(n(21595),t),i(n(41696),t),i(n(74121),t);var o=n(43616);Object.defineProperty(t,"Timer",{enumerable:!0,get:function(){return o.Timer}});var s=n(52244);Object.defineProperty(t,"Time",{enumerable:!0,get:function(){return s.Time}})},54261:function(e,t,n){"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.BrowserMetrics=void 0;let r=n(77882),i=n(52244);function o(){let[e]=window.performance.getEntriesByType("navigation");return e}function s(e){return new Promise((t,n)=>window.performance&&"function"==typeof performance.getEntriesByType?window.addEventListener("load",()=>{let r=performance.getEntriesByType("paint"),i=r.find(({name:t})=>t===e);return void 0!==r&&i?t(i.startTime):n("Time to paint api is not supported on this browser")}):n("window.performance api is not supported in this browser"))}function a({name:e,label:t,value:n},r){let o;return o="cls"===e.toLowerCase()?{metric_type:"gauge",value:n}:{metric_type:"timer",value:i.Time.fromMillis(Math.round(n)).asNanos()},Object.assign(Object.assign({what:`web_vitals_${e.toLowerCase()}`},o),{tags:Object.assign({name:e,label:t},r)})}t.BrowserMetrics={getPageLoadTime:function(){return new Promise((e,t)=>{if(!window.performance||"function"!=typeof performance.getEntriesByType)return t("window.performance api is not supported in this browser");if(void 0===o())return t("navigationTiming api is not supported in this browser");let{loadEventEnd:n}=o();return n>0?e(n):window.addEventListener("load",()=>{setTimeout(()=>{let{loadEventEnd:t}=o();return e(t)},0)})})},getResourceTiming:function(){return window.performance.getEntriesByType("resource")},getTimeToFirstPaint:function(){return s("first-paint")},getTimeToFirstContentfulPaint:function(){return s("first-contentful-paint")},sendWebVitalsMetric:function(e,t){return r.sendMetric(a(e,t))},getWebVitalsMetric:a}},74121:function(e,t,n){"use strict";var r=this&&this.__awaiter||function(e,t,n,r){return new(n||(n=Promise))(function(i,o){function s(e){try{c(r.next(e))}catch(e){o(e)}}function a(e){try{c(r.throw(e))}catch(e){o(e)}}function c(e){var t;e.done?i(e.value):((t=e.value)instanceof n?t:new n(function(e){e(t)})).then(s,a)}c((r=r.apply(e,t||[])).next())})},i=this&&this.__importDefault||function(e){return e&&e.__esModule?e:{default:e}};Object.defineProperty(t,"__esModule",{value:!0}),t.ConsoleReporter=void 0;let o=i(n(11498));class s{constructor(e=2,t="info"){this.spacingLevel=e,this.logLevel=t}send(e){return r(this,void 0,void 0,function*(){o.default.log(this.logLevel,`[semantic-metrics] ${JSON.stringify(e,null,this.spacingLevel)}`)})}}t.ConsoleReporter=s},41696:function(e,t,n){"use strict";var r=this&&this.__awaiter||function(e,t,n,r){return new(n||(n=Promise))(function(i,o){function s(e){try{c(r.next(e))}catch(e){o(e)}}function a(e){try{c(r.throw(e))}catch(e){o(e)}}function c(e){var t;e.done?i(e.value):((t=e.value)instanceof n?t:new n(function(e){e(t)})).then(s,a)}c((r=r.apply(e,t||[])).next())})},i=this&&this.__importDefault||function(e){return e&&e.__esModule?e:{default:e}};Object.defineProperty(t,"__esModule",{value:!0}),t.EventSenderReporter=void 0;let o=n(54189),s=n(57858),a=n(54138),c=i(n(11498)),l=n(18918),u=n(18007);function d(e){return t=>e.isAuthenticated()?s.createSemanticMetricClient(t):a.createSemanticMetricClientNonAuth(t)}class h{constructor(e,t,n="browser",r){this.eventSender=e,this.createEvent=t,this.environment=n,this.transport=r}static create(e){let t="getToken"in e?e.getToken:null,n="ownerProvider"in e?e.ownerProvider:null,i=e.context?[...e.context]:void 0,s=e.environment,a=l.createBaseTransport({providers:{endpoints:(()=>{let t=l.createXResolveProvider();return n=>r(this,void 0,void 0,function*(){return Object.assign(Object.assign({},(yield t(n))),e.internal&&{webgate:u.INTERNAL_WEBGATE_URL})})})(),token:()=>new Promise(e=>{if(!t){e("");return}t((t,n)=>{if(void 0!==n){e([t,n]);return}e(t)})})}});return t&&(a.on(l.TransportEvent.CONNECTED,()=>{a.authenticate().catch(e=>{var t,n;c.default.debug("authentication fail.",null!==(n=null!==(t=null==e?void 0:e.message)&&void 0!==t?t:null==e?void 0:e.code)&&void 0!==n?n:"")})}),a.on(l.TransportEvent.AUTHENTICATED,()=>{c.default.debug("created authenticated browser transport")}),a.on(l.TransportEvent.TOKEN_PROVIDER_ERROR,()=>{c.default.debug("the token provided isn't working.")})),a.connect(),new h(o.createEventSender(Object.assign({transport:a,context:i},n&&{ownerProvider:n})),d(a),s,a)}static createWithCustomTransport(e){let t="ownerProvider"in e?e.ownerProvider:null,n=e.context?[...e.context]:void 0;return new h(o.createEventSender(Object.assign({transport:e.transport,context:n},t&&{ownerProvider:t})),d(e.transport),e.environment,e.transport)}send(e){return r(this,void 0,void 0,function*(){for(let t of e){let e=Object.assign({},t);e.tags=Object.assign({},e.tags),e.tags.environment&&c.default.error("`tags.environment` must not be set. It is a reserved tag and will be overwritten."),e.tags.environment=this.environment;let n=this.createEvent(Object.assign({},e));this.eventSender.send(n,{flush:!1})}return this.eventSender.flush(this.transport.isAuthenticated())})}}t.EventSenderReporter=h},88328:function(e,t){"use strict";var n=this&&this.__awaiter||function(e,t,n,r){return new(n||(n=Promise))(function(i,o){function s(e){try{c(r.next(e))}catch(e){o(e)}}function a(e){try{c(r.throw(e))}catch(e){o(e)}}function c(e){var t;e.done?i(e.value):((t=e.value)instanceof n?t:new n(function(e){e(t)})).then(s,a)}c((r=r.apply(e,t||[])).next())})};Object.defineProperty(t,"__esModule",{value:!0}),t.NoopReporter=void 0;class r{send(e){return n(this,void 0,void 0,function*(){})}}t.NoopReporter=r},21595:function(e,t){"use strict";Object.defineProperty(t,"__esModule",{value:!0})},52244:function(e,t){"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.Time=void 0;class n{constructor(e=0){this.nanos=e}static fromNanos(e){return new n(e)}static fromMicros(e){return new n(1e3*e)}static fromMillis(e){return new n(1e6*e)}static fromSeconds(e){return new n(1e9*e)}static from(e){return new n(e.asNanos())}asSeconds(){return this.nanos/1e9}asMillis(){return this.nanos/1e6}asMicros(){return this.nanos/1e3}asNanos(){return Math.round(this.nanos)}}t.Time=n,n.ZERO=new n(0)},43616:function(e,t,n){"use strict";var r=n(12509);Object.defineProperty(t,"__esModule",{value:!0}),t.Timer=t.getHighResolutionTime=t.getLowResolutionTime=t.getTime=t.getBrowserTime=t.supportsHighResolutionTime=void 0;let i=n(52244),o=n(77882);t.supportsHighResolutionTime=()=>"undefined"==typeof window&&"function"==typeof r.hrtime,t.getBrowserTime=()=>"undefined"!=typeof performance?performance.now():Date.now(),t.getTime=()=>t.supportsHighResolutionTime()?r.hrtime():t.getBrowserTime(),t.getLowResolutionTime=e=>{let n=t.getTime()-e,r=i.Time.fromMillis(n);return{nanoseconds:o.asNanoseconds(r.asNanos()),milliseconds:r.asMillis(),seconds:r.asSeconds()}},t.getHighResolutionTime=e=>{let[t,n]=r.hrtime(e),i=1e9*t+n,s=i/1e6,a=i/1e9;return{nanoseconds:o.asNanoseconds(i),milliseconds:s,seconds:a}};class s{constructor(e){this.startTime=e}static start(){return new s(t.getTime())}end(){return t.supportsHighResolutionTime()?t.getHighResolutionTime(this.startTime):t.getLowResolutionTime(this.startTime)}}t.Timer=s},69933:function(e,t,n){"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.createUniversalReporter=void 0;let r=n(41696),i=n(17931);t.createUniversalReporter=function(e={}){let t=e.context?[i.createUserAgentContext(),...e.context]:[i.createUserAgentContext()];return r.EventSenderReporter.create(Object.assign(Object.assign({environment:"browser"},e),{context:t}))}},61878:function(e,t,n){"use strict";var r,i;n.d(t,{J:function(){return r}}),(i=r||(r={})).HTTP_REQUEST_ABORTED="HTTP_REQUEST_ABORTED",i.HTTP_REQUEST_FAILED="HTTP_REQUEST_FAILED",i.HTTP_REQUEST_TIMEOUT="HTTP_REQUEST_TIMEOUT",i.LOGGING_REQUEST_FAILED="LOGGING_REQUEST_FAILED",i.TRANSPORT_ENDPOINTS_PROVIDER_ERROR="TRANSPORT_ENDPOINTS_PROVIDER_ERROR",i.TRANSPORT_INVALID_STATE="TRANSPORT_INVALID_STATE",i.TRANSPORT_INVALID_TOKEN="TRANSPORT_INVALID_TOKEN",i.TRANSPORT_STALE_TOKEN="TRANSPORT_STALE_TOKEN ",i.TRANSPORT_TOKEN_PROVIDER_ERROR="TRANSPORT_TOKEN_PROVIDER_ERROR",i.TRANSPORT_LIFECYCLE_DISABLED="TRANSPORT_LIFECYCLE_DISABLED",i.TRANSPORT_UNSUPPORTED_OPTION="TRANSPORT_UNSUPPORTED_OPTION",i.XRESOLVE_INCOMPLETE_RESPONSE="XRESOLVE_INCOMPLETE_RESPONSE",i.XRESOLVE_INVALID_RESPONSE="XRESOLVE_INVALID_RESPONSE",i.XRESOLVE_REQUEST_FAILED_WITH_STATUS="XRESOLVE_REQUEST_FAILED_WITH_STATUS"},17253:function(e,t,n){"use strict";var r,i;n.d(t,{j:function(){return r}}),(i=r||(r={})).CONNECTION_ONLINE="online",i.CONNECTION_OFFLINE="offline",i.PRODUCT_STATE_CHANGED="product_state_changed",i.ACCESS_TOKEN="access_token",i.AUTHENTICATED="authenticated",i.AUTHENTICATION_FAILED="authentication_failed",i.BEFORE_OFFLINE_DISCONNECT="before_offline_disconnect",i.BEFORE_ONLINE_DISCONNECT="before_online_disconnect",i.CONNECTED="connected",i.CONNECTION_FAILED="connection_failed",i.CONNECTION_ID="connection_id",i.DISCONNECTED="disconnected",i.ENDPOINTS_RESOLVED="endpoints_resolved",i.LOGGED_OUT="logged_out",i.SHORT_SESSION_DISCONNECTED="short_session_disconnected",i.TOKEN_PROVIDER_ERROR="token_provider_error",i.RECONNECTED="reconnected",i.RECONNECTING="reconnecting",i.WINDOW_BEFORE_UNLOAD="beforeunload"},28679:function(e,t,n){"use strict";var r,i;n.d(t,{n:function(){return r}}),(i=r||(r={})).DELETE="DELETE",i.GET="GET",i.OPTIONS="OPTIONS",i.PATCH="PATCH",i.POST="POST",i.PUT="PUT",i.TRACE="TRACE"},83297:function(e,t,n){"use strict";var r,i;n.d(t,{G:function(){return r}}),(i=r||(r={}))[i.UNKNOWN=0]="UNKNOWN",i[i.OK=200]="OK",i[i.CREATED=201]="CREATED",i[i.ACCEPTED=202]="ACCEPTED",i[i.NO_CONTENT=204]="NO_CONTENT",i[i.PARTIAL_CONTENT=206]="PARTIAL_CONTENT",i[i.BAD_REQUEST=400]="BAD_REQUEST",i[i.UNAUTHORIZED=401]="UNAUTHORIZED",i[i.PAYMENT_REQUIRED=402]="PAYMENT_REQUIRED",i[i.FORBIDDEN=403]="FORBIDDEN",i[i.NOT_FOUND=404]="NOT_FOUND",i[i.METHOD_NOT_ALLOWED=405]="METHOD_NOT_ALLOWED",i[i.NOT_ACCEPTABLE=406]="NOT_ACCEPTABLE",i[i.PROXY_AUTHENTICATION_REQUIRED=407]="PROXY_AUTHENTICATION_REQUIRED",i[i.TIMED_OUT=408]="TIMED_OUT",i[i.REQUEST_TIMEOUT=408]="REQUEST_TIMEOUT",i[i.CONFLICT=409]="CONFLICT",i[i.GONE=410]="GONE",i[i.LENGTH_REQUIRED=411]="LENGTH_REQUIRED",i[i.PRECONDITION_FAILED=412]="PRECONDITION_FAILED",i[i.REQUEST_ENTITY_TOO_LARGE=413]="REQUEST_ENTITY_TOO_LARGE",i[i.REQUEST_URI_TOO_LONG=414]="REQUEST_URI_TOO_LONG",i[i.UNSUPPORTED_MEDIA_TYPE=415]="UNSUPPORTED_MEDIA_TYPE",i[i.REQUESTED_RANGE_NOT_SATISFIABLE=416]="REQUESTED_RANGE_NOT_SATISFIABLE",i[i.EXPECTATION_FAILED=417]="EXPECTATION_FAILED",i[i.INTERNAL_SERVER_ERROR=500]="INTERNAL_SERVER_ERROR",i[i.NOT_IMPLEMENTED=501]="NOT_IMPLEMENTED",i[i.BAD_GATEWAY=502]="BAD_GATEWAY",i[i.SERVICE_UNAVAILABLE=503]="SERVICE_UNAVAILABLE",i[i.GATEWAY_TIMEOUT=504]="GATEWAY_TIMEOUT",i[i.HTTP_VERSION_NOT_SUPPORTED=505]="HTTP_VERSION_NOT_SUPPORTED"},62553:function(e,t,n){"use strict";var r,i;n.d(t,{S:function(){return r}}),(i=r||(r={}))[i.CONNECTION_ERROR=0]="CONNECTION_ERROR",i[i.INFORMATIONAL=1]="INFORMATIONAL",i[i.SUCCESS=2]="SUCCESS",i[i.REDIRECTION=3]="REDIRECTION",i[i.CLIENT_ERROR=4]="CLIENT_ERROR",i[i.SERVER_ERROR=5]="SERVER_ERROR"},18918:function(e,t,n){"use strict";n.r(t),n.d(t,{ConnectionObserver:function(){return T},DEALER_PLUGIN_NAME:function(){return H},DealerErrors:function(){return f},DisconnectionReason:function(){return u},Method:function(){return b.n},PluginEvent:function(){return l},REQUEST_TRANSFORMER_PLUGIN_NAME:function(){return ex},TransportErrors:function(){return v.J},TransportEvent:function(){return E.j},createAbortControllerLike:function(){return D},createAbortSignalWithTimeout:function(){return P},createBaseTransport:function(){return eM},createSpotifyComEndpointsProvider:function(){return ek},createSpotifyComProviders:function(){return eI},createSpotifyComTokenProvider:function(){return eN},createTransport:function(){return eL},createXResolveProvider:function(){return eA.Q},dealerCreator:function(){return G},requestTransformerCreator:function(){return eP}});var r,i,o,s,a,c,l,u,d,h,f,p,m,g,_={};n.r(_),n.d(_,{isSupported:function(){return ee},request:function(){return et}});var y={};n.r(y),n.d(y,{request:function(){return eR}});var v=n(61878),E=n(17253),b=n(28679);(r=l||(l={})).TRANSPORT_AUTHENTICATE="transport_authenticate",r.TRANSPORT_AUTHENTICATE_FAILED="transport_authenticate_failed",r.TRANSPORT_CONNECT="transport_connect",r.TRANSPORT_DISCONNECT="transport_disconnect",r.TRANSPORT_ENDPOINTS_RESOLVED="transport_endpoints_resolved",r.TRANSPORT_BEFORE_PROCESS_REQUEST="transport_before_process_request",r.TRANSPORT_BEFORE_SEND_REQUEST="transport_before_send_request",r.TRANSPORT_BEFORE_RETURN_RESPONSE="transport_before_return_response",r.TRANSPORT_REQUEST="transport_request",r.PLUGIN_CONNECTION_INFO="plugin_connection_info",r.PLUGIN_DISCONNECTED="plugin_disconnected",r.PLUGIN_MESSAGE="plugin_message",r.PLUGIN_REQUEST="plugin_request",r.PLUGIN_ERROR="plugin_error",(i=u||(u={})).RECONNECTION_FAILED="reconnection_failed",i.EXPLICIT="explicit",i.LOG_OUT="log_out",i.WINDOW_BEFORE_UNLOAD="window_before_unload";var S=n(84539);class T extends S.vp{}class w extends T{constructor(e){super();let t="undefined"!=typeof window,n=e&&e.notifyBeforeUnload;this._navigator=t&&window.navigator||null,t&&"function"==typeof window.addEventListener&&(window.addEventListener("online",this.emitSync.bind(this,E.j.CONNECTION_ONLINE,null)),window.addEventListener("offline",this.emitSync.bind(this,E.j.CONNECTION_OFFLINE,null)),n&&window.addEventListener(E.j.WINDOW_BEFORE_UNLOAD,this.emitSync.bind(this,E.j.WINDOW_BEFORE_UNLOAD,null)))}static create(e){return new w(e)}isOnline(){let e=this._navigator;return!e||!("onLine"in e)||e.onLine}}class O extends Error{constructor(e,t,n,r){super(e),this.name="RequestError",this.message=e,this.code=t,this.status=n||0,this.url=r}}class C extends O{constructor(e,t){super("Request aborted by signal.",v.J.HTTP_REQUEST_ABORTED,0,e),this.name="RequestAbortedError",this.reason=t}}class R extends O{constructor(e,t){super("Request aborted by timeout.",v.J.HTTP_REQUEST_TIMEOUT,0,e),this.name="RequestTimeoutError",this.reason=t}}let A="Signal is aborted without reason";function k(e,t){let n=Error(t);return n.name=e,n}class N extends S.vp{constructor(){super(),this._aborted=!1,this._reason=void 0,this.onabort=null,this.on("abort",()=>{var e;return null===(e=this.onabort)||void 0===e?void 0:e.call(this)})}static abort(e){let t=new N;return t._aborted=!0,t._reason=k("AbortError",null!=e?e:A),t}static signalAbort(e,t){"_aborted"in e&&!e._aborted&&(e._aborted=!0,"_reason"in e&&(e._reason=t||k("AbortError",A)),e.emit("abort",null))}static timeout(e){if(!isFinite(e))throw TypeError('Value of "delay" is not supported.');let t=new N;return setTimeout(()=>{N.signalAbort(t,k("TimeoutError","Signal timed out"))},e),t}get aborted(){return this._aborted}set aborted(e){}get reason(){return this._reason}addEventListener(e,t){this.addListener(e,t)}removeEventListener(e,t){this.removeListener(e,t)}dispatchEvent(){}}class I{constructor(){this.signal=new N}abort(e){let t=this.signal;N.signalAbort(t,e)}}function x(){return"undefined"!=typeof window&&"function"==typeof window.AbortController}let D=x()?()=>new AbortController:()=>new I;"undefined"!=typeof window&&"function"==typeof(null===(d=window.AbortSignal)||void 0===d?void 0:d.any)&&window.AbortSignal.any;let P="undefined"!=typeof window&&"function"==typeof(null===(h=window.AbortSignal)||void 0===h?void 0:h.timeout)?window.AbortSignal.timeout:N.timeout;function M(e,t){var n;return(null===(n=t.reason)||void 0===n?void 0:n.name)==="TimeoutError"?new R(e,t.reason):new C(e,t.reason)}(o=f||(f={})).DEALER_CONNECTION_ERROR="DEALER_CONNECTION_ERROR",o.DEALER_AUTHENTICATION_FAILED="DEALER_AUTHENTICATION_FAILED",o.DEALER_ERROR="DEALER_ERROR",o.DEALER_DISCONNECTED_BEFORE_EVENTS="DEALER_DISCONNECTED_BEFORE_EVENTS",o.ENDPOINT_NOT_DEFINED="ENDPOINT_NOT_DEFINED",o.INVALID_ENDPOINT="INVALID_ENDPOINT";class L extends Error{constructor(e=f.DEALER_ERROR,t,n={}){super(t),this.name="DealerError",this.message=t,this.code=e,this.raw=n,this.wsCode=n.code||null,this.wsReason=n.reason||null}}function j(){let e,t;return{promise:new Promise((n,r)=>{e=n,t=r}),resolve:e,reject:t}}(s=p||(p={})).AUTHENTICATED="authenticated",s.AUTHENTICATION_FAILED="authentication_failed",s.CONNECTED="connected",s.CONNECTION_ID="connection_id",s.ERROR="error",s.DISCONNECTED="disconnected",s.MESSAGE="message",s.REQUEST="request",(a=m||(m={}))[a.CLOSE=4e3]="CLOSE",a[a.TIMEOUT=4001]="TIMEOUT";var U=n(91620).Buffer;let $=function(){},B=/hm:\/\/pusher\/(?:[^]+)?\/connections\/([^]+)/,F="undefined"!=typeof window;class q extends S.vp{constructor(e){super(),this._socket=null,this._lastPingDeferred=null,this._waitingForConnectionId=!0,this._connectionId=null,this._connectionURI=null,this._heartbeatToken=0,this._heartbeatTimeoutToken=0,this._connected=!1,this._endpoint=null,this._closeBeforeEventsRejector=null,this._WebSocket=e.WebSocket||WebSocket,this._heartbeatTimeout=e.heartbeatTimeout||1e4}static create(e){return new q(e)}_startHeartbeat(e){let t=()=>{this.ping().then(()=>this._onHeartbeatSuccess(),()=>this._onHeartbeatError()),this._heartbeatTimeoutToken=setTimeout(()=>this._onHeartbeatError(),this._heartbeatTimeout)};e?t():this._heartbeatToken=setTimeout(()=>t(),3e4)}_onHeartbeatError(){this._stopHeartbeat(),this._socket&&this._socket.close(m.TIMEOUT,"internal-timeout")}_onHeartbeatSuccess(){this._stopHeartbeat(),this._startHeartbeat()}_stopHeartbeat(){null!==this._heartbeatToken&&clearTimeout(this._heartbeatToken),null!==this._heartbeatTimeoutToken&&clearTimeout(this._heartbeatTimeoutToken)}_prepareConnectionId(e){var t;let n;if(!e.uri)return!1;let[,r]=null!==(t=e.uri.match(B))&&void 0!==t?t:[];return!!r&&(n=e.headers&&e.headers["Spotify-Connection-Id"]?e.headers["Spotify-Connection-Id"]:decodeURIComponent(r),this._connectionId=n,this._connectionURI=e.uri,this.emit(p.CONNECTION_ID,{id:n,uri:e.uri}),!0)}_reply(e,t){if(!e)throw TypeError("Invalid key.");let n=this._socket;n&&1===n.readyState&&n.send(JSON.stringify({type:"reply",key:e,payload:t}))}_parseMessage(e){let t;try{t=JSON.parse(e)}catch(e){return}if("message"===t.type)this._waitingForConnectionId&&this._prepareConnectionId(t)?(this._waitingForConnectionId=!1,this._startHeartbeat(!0)):this.emit(p.MESSAGE,{message:t});else if("pong"===t.type&&this._lastPingDeferred)this._lastPingDeferred.resolve(!0),this._lastPingDeferred=null;else if("request"===t.type){let e=t.key;e&&this.emit(p.REQUEST,{request:t,reply:this._reply.bind(this,e)})}}_handleOpen(e){e.resolve(!0),this._connected=!0,this.emit(p.AUTHENTICATED,null)}_handleMessage(e){let t=this,n=e.data;if(F&&window.Blob&&n instanceof window.Blob){let e=new FileReader;e.onloadend=function(){let e;if(this.result){if(this.result instanceof ArrayBuffer){e="";let t=new Uint8Array(this.result);for(let n=0;n{this.once(p.CONNECTION_ID,t=>{e(t.data.id)})}):Promise.resolve(this._connectionId)}getConnectionInfo(){return this._waitingForConnectionId?new Promise(e=>{this.once(p.CONNECTION_ID,t=>{e({id:t.data.id,uri:t.data.uri})})}):Promise.resolve({id:this._connectionId,uri:this._connectionURI})}hasConnectionId(){return!this._waitingForConnectionId&&!!this._connectionId}}let H="dealer";class W{constructor(e){this.name=H,this._dealer=new q(e),this.api={hasConnectionInfo:()=>this._dealer.hasConnectionId(),getConnectionInfo:()=>this._dealer.getConnectionInfo().then(e=>Object.assign({plugin:this.name},e))},this._onDealerConnectionId=this._onDealerConnectionId.bind(this),this._onDealerDisconnected=this._onDealerDisconnected.bind(this),this._onDealerMessage=this._onDealerMessage.bind(this),this._onDealerRequest=this._onDealerRequest.bind(this),this._onTransportConnect=this._onTransportConnect.bind(this),this._onTransportAuthenticate=this._onTransportAuthenticate.bind(this),this._onTransportDisconnect=this._onTransportDisconnect.bind(this)}_onDealerConnectionId(e){this._mediator&&this._mediator.emit(l.PLUGIN_CONNECTION_INFO,Object.assign({plugin:this.name},e.data))}_onDealerDisconnected(e){if(!this._mediator)return;let t=e.data;this._mediator.emit(l.PLUGIN_DISCONNECTED,{plugin:this.name,code:t.wsCode,reason:t.reason})}_onDealerMessage(e){this._mediator&&this._mediator.emit(l.PLUGIN_MESSAGE,Object.assign({plugin:this.name},e.data))}_onDealerRequest(e){this._mediator&&this._mediator.emit(l.PLUGIN_REQUEST,Object.assign({plugin:this.name},e.data))}_onTransportConnect(e){let t=e.data.endpoints,n=e.data.awaitPromise;if(!t.dealer){n(Promise.reject(new L(f.ENDPOINT_NOT_DEFINED,'No "dealer" endpoint defined.')));return}if(!/^wss:/.test(t.dealer)){n(Promise.reject(new L(f.INVALID_ENDPOINT,"Dealer endpoint needs to be wss://")));return}n(this._dealer.connect(t.dealer))}_onTransportAuthenticate(e){let t=e.data;t.awaitPromise(this._dealer.authenticate(t.token))}_onTransportDisconnect(){this._dealer.disconnect()}_onDealerError(e){var t;null===(t=this._mediator)||void 0===t||t.emit(l.PLUGIN_ERROR,{plugin:this.name,error:e.data.error})}attach(e,t){this._mediator=t,t.addListeners({[l.TRANSPORT_CONNECT]:this._onTransportConnect,[l.TRANSPORT_AUTHENTICATE]:this._onTransportAuthenticate,[l.TRANSPORT_DISCONNECT]:this._onTransportDisconnect}),this._dealer.addListeners({[p.DISCONNECTED]:this._onDealerDisconnected,[p.CONNECTION_ID]:this._onDealerConnectionId,[p.MESSAGE]:this._onDealerMessage,[p.REQUEST]:this._onDealerRequest,[p.ERROR]:this._onDealerError})}detach(e,t){this._mediator=void 0,t.removeListeners({[l.TRANSPORT_CONNECT]:this._onTransportConnect,[l.TRANSPORT_AUTHENTICATE]:this._onTransportAuthenticate,[l.TRANSPORT_DISCONNECT]:this._onTransportDisconnect}),this._dealer.removeListeners({[p.DISCONNECTED]:this._onDealerDisconnected,[p.CONNECTION_ID]:this._onDealerConnectionId,[p.MESSAGE]:this._onDealerMessage,[p.REQUEST]:this._onDealerRequest,[p.ERROR]:this._onDealerError})}}function G(e,t){return new W(t)}var z=n(54704),X=n(46847);let J={POST:!0,PUT:!0,PATCH:!0,DELETE:!0};var V=n(83297);class Y{constructor(e){this.get=e.get.bind(e),this.has=e.has.bind(e)}get(e){return null}has(e){return!1}}class Z{constructor(e,t=0){this.url="",this.status=0,this.headers=null,this.body=null,this.offline=!1,this.timing=null,this.metadata=null,this.retries={count:0},this.url=e,this.status=t,this.ok=t>=200&&t<=299}getStatusFamily(){return 0|this.status/100}}let K=z.P.forTag("transport.http.fetch"),Q={json:!0,text:!0,arraybuffer:!0,blob:!0};function ee(){return"function"==typeof fetch}function et(e){if(!ee())return Promise.reject(TypeError("Fetch is not supported"));let t=e.options.signal;if(null==t?void 0:t.aborted)return Promise.reject(M(e.url,t));if(!e.url)return Promise.reject(TypeError("Request URL cannot be blank."));let n=e.method||"GET",r=e.url,i=null;if(n in J&&!0===J[n]&&e.payload?i=e.payload:e.payload&&(r+=`?${e.payload}`),e.options.responseType&&!(e.options.responseType in Q))return Promise.reject(TypeError("Cannot set responseType: not supported in browser."));let o={mode:e.options.mode||"cors",credentials:e.options.credentials||"same-origin",redirect:e.options.redirect||"follow",signal:t,method:n};e.headers.count()&&(o.headers=e.headers.toJSON()),i&&(o.body=i);let s=(0,X.q)();return fetch(r,o).then(function(t){let n;n=e.options.ignoreResponseBody||t.status===V.G.NO_CONTENT?null:"json"===e.options.responseType?t.json().catch(function(e){return K.warn("Could not parse response as JSON:",e),null}):"arraybuffer"===e.options.responseType?t.arrayBuffer():"blob"===e.options.responseType?t.blob():t.text();let r=e.options.parseResponseHeaders||t.status>299?new Y(t.headers):null;return Promise.all([t.url,t.status,r,n])}).then(function([t,n,r,i]){let o=(0,X.q)(),a=new Z(t,n);return a.body=i,a.headers=r,e.options.timing&&(a.timing={completed:(0,X.n)(s,o)}),a}).catch(function(t){let n=(0,X.q)();if((null==t?void 0:t.name)==="AbortError")throw new C(r);if((null==t?void 0:t.name)==="TimeoutError")throw new R(r);let i=new Z(r);return e.options.timing&&(i.timing={completed:(0,X.n)(s,n)}),i}).then(function(t){return e.options.connectionObserver&&(t.offline=!e.options.connectionObserver.isOnline()),t})}var en=n(15767);let er={baseTime:200,ceiling:0,curve:"linear",jitter:!0};class ei{constructor(e={}){this._curve=e.curve||er.curve,this._baseTime=e.baseTime||er.baseTime,this._ceiling=e.ceiling||er.ceiling,this._jitter="jitter"in e?!!e.jitter:er.jitter}getTime(e){let t;switch(this._curve){case"static":t=1;break;case"logarithmic":t=Math.log(e);break;case"exponential":t=Math.pow(Math.E,e);break;default:t=e+1}let n=Math.min(4294967296,Math.floor(t*this._baseTime));return this._ceiling&&(n=Math.min(n,this._ceiling)),this._jitter?function(e){let t=e/5;return Math.floor(e-t/2+Math.random()*t)}(n):n}}let eo={backoffInitial:!1,baseTime:200,ceiling:0,curve:"linear",jitter:!0,maxDuration:1/0,maxRetries:1/0,maxTime:1/0,retryPredicate:()=>!0};class es{constructor(e,t){this._resolver=j(),this._ts=0,this._callCount=0,this._tickInterval=0,this._isRunning=!1,this._isDestroyed=!1;let n=Object.assign(Object.assign({},eo),t),{backoffInitial:r,maxDuration:i,maxRetries:o,maxTime:s,retryPredicate:a}=n,c=(0,en.__rest)(n,["backoffInitial","maxDuration","maxRetries","maxTime","retryPredicate"]);this._fn=e,this._backoffInitial=r,this._maxDuration=i,this._maxRetries=o,this._maxTime=s,this._retryPredicate=a,this._backoffInitial=r,this._counter=new ei(c),this._backoffInitial&&(this._maxRetries+=1)}static init(e,t={}){return new es(e,t).start()}_destroy(){this._isRunning=!1,this._isDestroyed=!0}_failure(e){if(!this._isDestroyed){if(e&&"retryAfter"in e)this._retryAfter(e);else{let t=this._counter.getTime(this._callCount);this._shouldRetry(t,e)?(this._callCount++,this._tickInterval=setTimeout(()=>this._tick(),t)):(this._resolver.reject(e),this._destroy())}}}_retryAfter(e){this._callCount++,this._tickInterval=setTimeout(()=>this._tick(),e.retryAfter)}_success(...e){this._isDestroyed||(this._resolver.resolve(...e),this._destroy())}_shouldRetry(e,t){let n=Date.now()-this._ts+e;return this._callCountthis._success(...e)).catch(e=>this._failure(e))}getResolver(){return this._resolver.promise}start(){return this._isDestroyed?Promise.reject(Error("Backoff already consumed")):(this._isRunning||(this._ts=Date.now(),this._isRunning=!0,this._backoffInitial?(this._callCount=1,this._tickInterval=setTimeout(()=>this._tick(),this._counter.getTime(0))):this._tick()),this._resolver.promise)}stop(){clearTimeout(this._tickInterval),this._destroy()}getRetryCount(){return this._callCount}}var ea=n(62553);class ec extends Error{constructor(e,t,n=null){super(t),this.name="TransportError",this.message=t,this.code=e,this.origin=n}}class el{constructor(e){this._headers={},this._count=0,this._setAll(e)}_setAll(e){let t=0;for(let n in e)e.hasOwnProperty(n)&&e[n]&&(this._headers[n.toLowerCase()]=e[n],t++);this._count=t}get(e){return this._headers[e.toLowerCase()]||null}has(e){return!!this._headers[e.toLowerCase()]}set(e,t){this._headers[e.toLowerCase()]=t,this._count++}delete(e){let t=e.toLowerCase();this._headers[t]&&this._count--,delete this._headers[e.toLowerCase()]}count(){return this._count}toJSON(){return Object.assign({},this._headers)}}class eu{constructor(e,t){this.url=e,this.method=(null==t?void 0:t.method)||"GET",this.headers=new el(null==t?void 0:t.headers),this.options=(null==t?void 0:t.options)||{},this.payload=null==t?void 0:t.payload,this.urlExpanded=(null==t?void 0:t.urlExpanded)||!1,this.retryOptions=(null==t?void 0:t.retryOptions)||{}}static create(e,t){return new eu(e,t)}clone(){let e=new eu(this.url);return e.method=this.method,e.headers=new el(this.headers.toJSON()),e.options=this.options,e.payload=this.payload,e.urlExpanded=this.urlExpanded,e.retryOptions=this.retryOptions,e}}(c=g||(g={})).EVENT_ACCESS_TOKEN="access_token",c.EVENT_CONNECTION_ID="connection_id",c.EVENT_CONNECTION_OFFLINE="connection_offline",c.EVENT_CONNECTION_ONLINE="connection_online",c.EVENT_ENDPOINTS_RESOLVED="endpoints_resolved";class ed extends S.vp{constructor(e,t){super(),this.EVENT_ACCESS_TOKEN=g.EVENT_ACCESS_TOKEN,this.EVENT_CONNECTION_ID=g.EVENT_CONNECTION_ID,this.EVENT_CONNECTION_OFFLINE=g.EVENT_CONNECTION_OFFLINE,this.EVENT_CONNECTION_ONLINE=g.EVENT_CONNECTION_ONLINE,this.EVENT_ENDPOINTS_RESOLVED=g.EVENT_ENDPOINTS_RESOLVED,this.StatusCode=V.G,this.StatusFamily=ea.S,this.getConnectionId=e.getConnectionId.bind(e),this.getEndpoints=e.getEndpoints.bind(e),this.getInitTime=e.getInitTime.bind(e),this.getLastToken=e.getLastToken.bind(e),this.matchMessages=e.matchMessages.bind(e),this.unmatchMessages=e.unmatchMessages.bind(e),this.handlePushRequests=e.handlePushRequests.bind(e),this.unhandlePushRequests=e.unhandlePushRequests.bind(e),this.hasPlugin=e.hasPlugin.bind(e),this.getPluginAPI=e.getPluginAPI.bind(e);let n=e.request.bind(e);(null==t?void 0:t.requestOptions)?this.request=(e,r)=>r?n(e,Object.assign(Object.assign(Object.assign({},null==t?void 0:t.requestOptions),r),{metadata:Object.assign(Object.assign({},t.requestOptions.metadata),null==r?void 0:r.metadata),retry:Object.assign(Object.assign({},t.requestOptions.retry),null==r?void 0:r.retry)})):n(e,t.requestOptions):this.request=n,this.proxyEmit(e,E.j.ACCESS_TOKEN,g.EVENT_ACCESS_TOKEN),this.proxyEmit(e,E.j.CONNECTION_OFFLINE,g.EVENT_CONNECTION_OFFLINE),this.proxyEmit(e,E.j.CONNECTION_ONLINE,g.EVENT_CONNECTION_ONLINE),this.proxyEmit(e,E.j.ENDPOINTS_RESOLVED,g.EVENT_ENDPOINTS_RESOLVED),this.onAddListener(g.EVENT_CONNECTION_ID,this._onAddConnectionIdListener.bind(this,e.on.bind(e))),this.onRemoveListener(g.EVENT_CONNECTION_ID,this._onRemoveConnectionIdListener.bind(this,e.removeListener.bind(e)))}_onAddConnectionIdListener(e,t){t.preventDefault();let n=t.data.listener,r=e=>{let t=this.createEvent(g.EVENT_CONNECTION_ID,e.data);n.call(this,t)};n.$proxy_wrapper=r,e(E.j.CONNECTION_ID,r,t.data.options)}_onRemoveConnectionIdListener(e,t){t.preventDefault();let n=t.data.listener;n.$proxy_wrapper&&e(E.j.CONNECTION_ID,n.$proxy_wrapper,t.data.options)}removeAllListeners(){return this}}class eh{constructor(){this._startTime=null,this._endTime=null}static create(){return new eh}start(){if(null!==this._startTime)throw Error("Measurement is already in progress.");this._startTime=Date.now()}end(){if(null===this._startTime||null!==this._endTime)throw Error("Measurement is not in progress.");this._endTime=Date.now()}getMetrics(){if(null===this._startTime||null===this._endTime)throw Error("Measurement is not done.");return{start_time:this._startTime,end_time:this._endTime}}}let ef=z.P.forTag("transport.transport"),ep=/^(?:https?:\/\/)?@([^\/]+)\//,em=/^(ws|http)s?:\/\/.*[^\/]$/,eg=/^([a-zA-Z]{3},\ \d{1,2}\ [a-zA-Z]{3}\ (\d{1,2}.){3})/,e_={xhr:!0,fetch:!0};function ey(e,t){let n=`access_token=${encodeURIComponent(t)}`,[r,i]=e.split("?");if(!i)return`${r}?${n}`;let o=i.replace(/access_token=[^&]*(&|$)/,`${n}$1`);return o!==i?`${r}?${o}`:`${r}?${n}&${i}`}class ev extends S.vp{constructor(e){if(super(),this._plugins={},this._pluginMediator=new S.vp,this._connectCalled=!1,this._authenticateCalled=!1,this._endpoints=null,this._lastToken=null,this._lastTokenExpiry=0,this._refreshTokenPromise=null,this._authenticationPromise=null,this._reconnectTimeout=0,this._isReconnecting=!1,this._initTime=0,this._lastDisconnect=0,this._stateMask=0,this._quickDisconnectCount=0,this._counter=new ei({curve:"exponential",baseTime:5e3,ceiling:15e3}),this._stateAwareListeners={connected:[],authenticated:[],connection_id:[],transport_connect:[],transport_authenticate:[]},this._stateAwareOperationMetrics={authenticated:null},this._stateAwareRunners={connected:null,authenticated:null,connection_id:null,transport_connect:null,transport_authenticate:null},!e)throw TypeError("Argument `options` for Transport cannot be null.");if(!e.providers)throw TypeError("Argument `options.providers` for Transport cannot be null.");this._ownerRef="ownerRef"in e?Object(e.ownerRef):{},this._tokenProvider=e.providers.token,this._endpointsProvider=e.providers.endpoints,this._XHR=e.XHR,this._Fetch=e.Fetch,this._reconnectionRetries=e.reconnectionRetries>=0?e.reconnectionRetries:3,this._requestMode=e.requestMode in e_?e.requestMode:"xhr",this._forcePolyfillTypes=e.forcePolyfillTypes||{},this._disableAutoLogout="disableAutoLogout"in e&&!!e.disableAutoLogout,this._disconnectBeforeUnload=e.disconnectBeforeUnload||!1;let t=e.createConnectionObserver||w.create;this._connectionObserver=t({notifyBeforeUnload:this._disconnectBeforeUnload}),this.authenticate=this.authenticate.bind(this),this._authenticateWithToken=this._authenticateWithToken.bind(this),this._connectToEndpoints=this._connectToEndpoints.bind(this),this._parseProvidedToken=this._parseProvidedToken.bind(this),this._onConnected=this._onConnected.bind(this),this._onAuthenticated=this._onAuthenticated.bind(this),this._onAuthenticationFailed=this._onAuthenticationFailed.bind(this),this._init()}static create(e){return new ev(e)}_init(){this.onAddListener(E.j.CONNECTED,this._onAddListener.bind(this,"connected")),this.onAddListener(E.j.AUTHENTICATED,this._onAddListener.bind(this,"authenticated")),this.onAddListener(E.j.CONNECTION_ID,this._onAddListener.bind(this,"connection_id")),this.onRemoveListener(E.j.CONNECTED,this._onRemoveListener.bind(this,"connected")),this.onRemoveListener(E.j.AUTHENTICATED,this._onRemoveListener.bind(this,"authenticated")),this.onRemoveListener(E.j.CONNECTION_ID,this._onRemoveListener.bind(this,"connection_id")),this._pluginMediator.onAddListener(l.TRANSPORT_CONNECT,this._onAddListener.bind(this,"transport_connect")),this._pluginMediator.onAddListener(l.TRANSPORT_AUTHENTICATE,this._onAddListener.bind(this,"transport_authenticate")),this._pluginMediator.onRemoveListener(l.TRANSPORT_CONNECT,this._onRemoveListener.bind(this,"transport_connect")),this._pluginMediator.onRemoveListener(l.TRANSPORT_AUTHENTICATE,this._onRemoveListener.bind(this,"transport_authenticate")),"fetch"!==this._requestMode||this._Fetch&&this._Fetch.isSupported()||(ef.warn('Default "fetch" request mode unavailable; Fallback to "xhr"'),this._requestMode="xhr");let e=this._pluginMediator;e.addListeners({[l.PLUGIN_DISCONNECTED]:this._onPluginDisconnected.bind(this)}),this.proxyEmit(e,l.PLUGIN_CONNECTION_INFO,E.j.CONNECTION_ID),this._disableAutoLogout||this.matchMessages("client:logout",()=>this._onLogout()),this._connectionObserver.on(E.j.CONNECTION_ONLINE,()=>this._onOnline()),this._connectionObserver.on(E.j.CONNECTION_OFFLINE,()=>this._onOffline()),this._connectionObserver.on(E.j.WINDOW_BEFORE_UNLOAD,()=>this._disconnect(u.WINDOW_BEFORE_UNLOAD))}_runStateAwareQueues(e,t){let n=this._stateAwareListeners[e].splice(0);try{for(let e of n)e.call(this,t)}finally{this._stateAwareRunners[e]=null}}_connect(){return 1&this._stateMask?Promise.resolve(!1):this._connectionObserver.isOnline()?this._performConnect():new Promise((e,t)=>{ef.info("Waiting to go online before connecting"),this._connectionObserver.once(E.j.CONNECTION_ONLINE,()=>{this._performConnect().then(e,t)})})}_performConnect(){return new Promise(e=>{ef.info("Resolving endpoints"),e(this._endpointsProvider(this.toPublic()))}).catch(e=>{let t=(null==e?void 0:e.code)?e:new ec(v.J.TRANSPORT_ENDPOINTS_PROVIDER_ERROR,(null==e?void 0:e.message)||"Endpoints provider error",null!=e?e:null);return ef.error("Endpoints resolution failed",t),Promise.reject(t)}).then(this._connectToEndpoints).then(this._onConnected).catch(e=>{let t=e&&e.error?e.error:e;return this.emit(E.j.CONNECTION_FAILED,{error:t}),ef.error("Connection failed",t),Promise.reject(t)})}_connectToEndpoints(e){let t={webgate:"",webapi:""};for(let n in e){if(!e.hasOwnProperty(n))continue;let r=e[n];r&&(em.test(r)&&(r+="/"),t[n]=r)}this._endpoints=t,this.emit(E.j.ENDPOINTS_RESOLVED,{endpoints:Object.assign({},t)}),ef.info("Endpoints resolved");let n=[],r=e=>{n.push(e)};return ef.info("Waiting for plugins to connect"),new Promise((e,i)=>{this._pluginMediator.emitAndWait(l.TRANSPORT_CONNECT,{endpoints:Object.assign({},t),awaitPromise:r},()=>{Promise.all(n).then(()=>e(!0),i)})})}_refreshToken(e=!1){if(this._refreshTokenPromise)return this._refreshTokenPromise;if(!e&&this._lastToken&&this._lastTokenExpiry>Date.now())return Promise.resolve(this._lastToken);this._refreshTokenPromise=new Promise(e=>{ef.info("Requesting token from provider"),e(this._tokenProvider())}).then(this._parseProvidedToken);let t=()=>{this._refreshTokenPromise=null};return this._refreshTokenPromise.then(t,t),this._refreshTokenPromise.catch(e=>{let t=(null==e?void 0:e.code)?e:new ec(v.J.TRANSPORT_TOKEN_PROVIDER_ERROR,(null==e?void 0:e.message)||"Token provider error",e);return this.emit(E.j.TOKEN_PROVIDER_ERROR,{error:t}),ef.error("Token provider error",t),Promise.reject(t)})}_parseProvidedToken(e){let t;let n=3540;if(Array.isArray(e)?(t=e[0],"number"==typeof(n="string"==typeof e[1]?parseInt(e[1],10):e[1])&&isFinite(n)||(n=3540)):t=e,!t)throw this._lastToken=null,this._lastTokenExpiry=0,ef.error("No token was provided"),new ec(v.J.TRANSPORT_INVALID_TOKEN,`Token provider returned an invalid token, "${t}"`);if(this._lastToken===t){ef.error("TokenProvider returned same token twice.");let e=new ec(v.J.TRANSPORT_STALE_TOKEN,"Token provider returned the same token twice.");throw this._lastToken=null,this._lastTokenExpiry=0,e}return this._lastToken=t,this._lastTokenExpiry=Date.now()+1e3*n,this.emit(E.j.ACCESS_TOKEN,{token:t}),ef.info("Access token set"),t}_authenticateWithToken(e){if(!this._endpoints)return Promise.resolve(!0);let t=[],n=e=>{t.push(e)};return ef.info("Waiting for plugins to authenticate"),new Promise((r,i)=>{this._pluginMediator.emitAndWait(l.TRANSPORT_AUTHENTICATE,{token:e,awaitPromise:n},()=>{Promise.all(t).then(()=>r(!0),i)})})}_authenticate(e){if(!(1&this._stateMask))return Promise.reject(new ec(v.J.TRANSPORT_INVALID_STATE,"Cannot authenticate disconnected transport."));if(this._authenticationPromise)return this._authenticationPromise;let t=eh.create();return t.start(),this._authenticationPromise=es.init(()=>(ef.info("Authenticating"),this._refreshToken(e).then(this._authenticateWithToken)),{curve:"exponential",maxRetries:2,baseTime:500,retryPredicate:e=>(ef.warn("Retrying authentication due to failure",e),!0)}).then(()=>this._onAuthenticated(t)).catch(e=>this._onAuthenticationFailed(e,t)),this._authenticationPromise}_performDisconnect(e){return this._stateMask=0,e&&(this.emit(E.j.DISCONNECTED,{reason:e}),ef.info("Disconnected")),ef.info("Waiting for plugins to disconnect."),this._pluginMediator.emitSync(l.TRANSPORT_DISCONNECT,{supressed:!e}),!0}_createReconnector(){let e=!1;return()=>(this._isReconnecting=!0,this.emit(E.j.RECONNECTING,null),ef.info("Reconnecting"),this._performDisconnect(),this._connect().then(()=>!!this._authenticateCalled&&this._authenticate(e).then(t=>(e=!1,t),t=>(e=!0,Promise.reject(t)))).then(()=>(this._isReconnecting=!1,this.emit(E.j.RECONNECTED,null),ef.info("Reconnected"),!0)))}_tryToReconnect(){if(this._isReconnecting){ef.warn("Reconnection triggered while already reconnecting");return}this._stateMask=0,es.init(this._createReconnector(),{baseTime:1e3,maxTime:15e3,maxRetries:this._reconnectionRetries,retryPredicate:e=>(ef.warn("Retrying reconnection due to failure",e),!0)}).catch(()=>{this._stateMask=0,this._isReconnecting=!1,this.emit(E.j.DISCONNECTED,{reason:u.RECONNECTION_FAILED}),ef.info("Disconnected: reconnection failed")})}_sendRequest(e,t={},n={}){let r=t.signal;return(null==r?void 0:r.aborted)?Promise.reject(M(e,r)):this._processRequestArgs(e,t).then(t=>(null==r?void 0:r.aborted)?Promise.reject(M(e,r)):t.options.forget?this._sendFireAndForgetRequest(t):this._sendRetriedRequest(t,n))}_processRequestArgs(e,t={}){var n,r;if(null===(n=t.signal)||void 0===n?void 0:n.aborted)return Promise.reject(M(e,t.signal));let i=e,o=!1,s=Object.assign(Object.assign({},t),{forcePolyfill:!!(t.responseType&&t.responseType in this._forcePolyfillTypes),requestMode:null!==(r=null==t?void 0:t.requestMode)&&void 0!==r?r:this._requestMode,connectionObserver:this._connectionObserver,metadata:(null==t?void 0:t.metadata)||null});if((null==t?void 0:t.signal)&&!x()&&("fetch"===t.requestMode?ef.warn("Request with `{requestMode: fetch}` but no native AbortController."):s.requestMode="xhr"),ep.test(i)){o=!0;try{i=this._tryExpandSpecialURL(i)}catch(e){return Promise.reject(e)}"authorize"in s||(s.authorize=!0,s.autoAuthorized=!0)}let a=Object.assign(Object.assign({maxRetries:2,curve:"exponential"},t.retry),{retryPredicate:e=>!(e instanceof C)});return Promise.resolve(eu.create(i,{method:t.method,headers:t.headers,payload:t.payload,options:s,urlExpanded:o,retryOptions:a}))}_tryExpandSpecialURL(e){let t=this._endpoints;return e.replace(ep,(e,n)=>{if(!t.hasOwnProperty(n))throw TypeError(`Cannot replace endpoint @${n}: endpoint not defined.`);return t[n]})}_sendFireAndForgetRequest(e){var t;let{url:n,method:r,options:i}=e;if(null===(t=i.signal)||void 0===t?void 0:t.aborted)return Promise.reject(M(n,i.signal));if("GET"!==r&&"POST"!==r)return Promise.reject(new ec(v.J.TRANSPORT_UNSUPPORTED_OPTION,`Option 'forget' cannot be used for ${r} request.`));if(!i.autoAuthorized&&i.authorize)return Promise.reject(new ec(v.J.TRANSPORT_UNSUPPORTED_OPTION,"Option 'forget' cannot be used for authorized request."));if(i.requestMode="xhr",i.authorize=!1,i.ignoreResponseBody=!0,"GET"===r){if("function"==typeof fetch){let e={mode:"no-cors"};i.signal&&x()&&(e.signal=i.signal),fetch(n,e).catch(()=>{})}else"function"==typeof Image?new Image().src=n:this._sendRetriedRequest(e,{}).catch(()=>{})}else if("POST"===r){if("undefined"!=typeof navigator&&(null==navigator?void 0:navigator.sendBeacon)){let t=e.headers.get("content-type");navigator.sendBeacon(e.url,"string"==typeof e.payload&&t?new Blob([e.payload],{type:t}):e.payload)}else if("function"==typeof fetch){let t=e.headers.get("content-type"),r={method:"POST",body:e.payload,headers:t?{"content-type":t}:void 0};i.signal&&x()&&(r.signal=i.signal),fetch(n,r).catch(()=>{})}else this._sendRetriedRequest(e,{}).catch(()=>{})}return Promise.resolve(new Z(n,0))}_sendRetriedRequest(e,t){let n=e.retryOptions,r=e.options.signal,i=!1,o=()=>(null==r?void 0:r.aborted)?Promise.reject(M(e.url,r)):this._setAuthHeader(e,i),s=this._connectionObserver,a=new es(()=>(s.isOnline()||e.options.allowOffline?o():new Promise((e,t)=>{s.once(E.j.CONNECTION_ONLINE,()=>{o().then(e,t)})})).then(()=>{let n;if(null==r?void 0:r.aborted)return Promise.reject(M(e.url,r));if(this._pluginMediator.emitSync(l.TRANSPORT_BEFORE_SEND_REQUEST,{request:e,context:t}),"fetch"===e.options.requestMode&&this._Fetch&&this._Fetch.isSupported())n=this._Fetch.request(e);else if(this._XHR)n=this._XHR.request(e);else throw Error("No available request mechanisms.");return n}).then(t=>{if(null==r?void 0:r.aborted)return Promise.reject(M(e.url,r));let o=null;if(t.headers&&(o=t.headers.get("Retry-After")),t.status===V.G.UNAUTHORIZED&&!e.options.ignoreUnauthorized)return i=!0,Promise.reject(t);if("function"==typeof(null==n?void 0:n.condition)&&(n.condition(t,ea.S)||o)){if(null!==o){if(eg.test(o))t.retryAfter=new Date(o).getTime()-Date.now();else{let e=parseInt(o,10);e>0&&(t.retryAfter=1e3*e)}}return Promise.reject(t)}return Promise.resolve(t)}),n);return a.start().catch(this._handleRetriedRequestError).then(n=>(null==r?void 0:r.aborted)?Promise.reject(M(e.url,r)):(n.metadata=e.options.metadata,n.retries=n.retries||{count:0},n.retries.count=a.getRetryCount(),this._pluginMediator.emitSync(l.TRANSPORT_BEFORE_RETURN_RESPONSE,{context:t,response:n}),e.options.rejectNotOk&&!n.ok)?Promise.reject(n):n)}_setAuthHeader(e,t){if(!e.options.authorize)return Promise.resolve(e);let n=()=>this._refreshToken(t).then(t=>(e.headers.set("Authorization",`Bearer ${t}`),e));return 4&this._stateMask?n():new Promise((e,t)=>{ef.info("Auth header setting awaiting authentication."),this.once(E.j.AUTHENTICATED,()=>{ef.info("Auth header set after authentication."),n().then(e,t)})})}_handleRetriedRequestError(e){return e instanceof Z?Promise.resolve(e):Promise.reject(e)}_onAddListener(e,t){let n;let r=t.data.options;if(r.ignoreCurrentState)return;switch(e){case"connected":if(!this.isConnected())return;n=Promise.resolve(this.createEvent(E.j.CONNECTED,null));break;case"authenticated":{if(!this.isAuthenticated())return;let e=this._stateAwareOperationMetrics.authenticated;n=Promise.resolve(this.createEvent(E.j.AUTHENTICATED,{timing:e}));break}case"connection_id":{let e=this.getPluginAPI("dealer");if(!e||!e.hasConnectionInfo())return;n=e.getConnectionInfo().then(e=>this.createEvent(E.j.CONNECTION_ID,e));break}case"transport_connect":if(!this.isConnected()||!this._endpoints)return;n=Promise.resolve(this._pluginMediator.createEvent(l.TRANSPORT_CONNECT,{endpoints:Object.assign({},this._endpoints),awaitPromise:e=>{}}));break;case"transport_authenticate":if(!this.isAuthenticated())return;n=this._refreshToken().then(e=>this._pluginMediator.createEvent(l.TRANSPORT_AUTHENTICATE,{token:e,awaitPromise:e=>{}}));break;default:return}let i=t.data.listener;this._stateAwareListeners[e].push(i);let o=this._stateAwareRunners;!o[e]&&(o[e]=n.then(this._runStateAwareQueues.bind(this,e)),r.once&&t.preventDefault())}_onRemoveListener(e,t){let n=t.data.options;if(n.ignoreCurrentState||n.once)return;let r=t.data.listener,i=this._stateAwareListeners[e].indexOf(r);-1!==i&&this._stateAwareListeners[e].splice(i,1)}_getQuickDisconnectTimeout(){return this._counter.getTime(this._quickDisconnectCount)}_onPluginDisconnected(e){let t=Date.now(),n=t-this._lastDisconnect;if(this._performDisconnect(),e.data.code===m.CLOSE){ef.info(`Plugin "${e.data.plugin}" explicitly disconnected`),this._quickDisconnectCount=0;return}this._connectionObserver.isOnline()&&(ef.info(`Plugin "${e.data.plugin}" unexpectedly disconnect; trying to reconnect`),n<5e3?(this._reconnectTimeout&&clearTimeout(this._reconnectTimeout),this._quickDisconnectCount++,this.emit(E.j.SHORT_SESSION_DISCONNECTED,{disconnectCount:this._quickDisconnectCount,sessionLength:n}),this._reconnectTimeout=setTimeout(this._tryToReconnect.bind(this),this._getQuickDisconnectTimeout())):(this._quickDisconnectCount=0,this._lastDisconnect=t,this._tryToReconnect()))}_onOnline(){this.emit(E.j.CONNECTION_ONLINE,null),ef.info("ConnectionObserver online"),this._connectCalled&&this._tryToReconnect()}_onOffline(){this.emit(E.j.CONNECTION_OFFLINE,null),ef.info("ConnectioObserver offline"),this._performDisconnect()}_onConnected(){return this._stateMask|=1,this.emit(E.j.CONNECTED,null),ef.info("Connected"),Promise.resolve(!0)}_onAuthenticated(e){e.end(),clearTimeout(this._reconnectTimeout),this._authenticationPromise=null,this._stateMask|=4,this._initTime=Date.now();let t=e.getMetrics();return this.emit(E.j.AUTHENTICATED,{timing:t}),this._stateAwareOperationMetrics.authenticated=t,ef.info("Authenticated"),Promise.resolve(!0)}_onAuthenticationFailed(e,t){t.end();let n=e&&e.error?e.error:e;this._authenticationPromise=null,this._stateMask&=-5;let r={error:n,timing:t.getMetrics()};return this.emit(E.j.AUTHENTICATION_FAILED,r),this._pluginMediator.emit(l.TRANSPORT_AUTHENTICATE_FAILED,r),ef.info("Authentication failed",n),Promise.reject(n)}_onLogout(){let e=()=>{this._lastToken=null,this._lastTokenExpiry=0,this.emit(E.j.LOGGED_OUT,null)};this._disconnect(u.LOG_OUT).then(e,e)}_disconnect(e){if(!this._connectCalled)return Promise.resolve(!1);this._connectCalled=!1,this._authenticateCalled=!1;let t=this.isConnected()?E.j.BEFORE_ONLINE_DISCONNECT:E.j.BEFORE_OFFLINE_DISCONNECT,n=[];return this.emitSync(t,{awaitPromise:e=>{n.push(e.catch(()=>{}))}}),Promise.all(n).then(()=>this._performDisconnect(e))}isConnected(){return!!(1&this._stateMask)}isAuthenticated(){return!!(4&this._stateMask)}isReconnecting(){return this._isReconnecting}isOnline(){return this._connectionObserver.isOnline()}connect(){return this._connectCalled=!0,this._connect()}authenticate(){return this._authenticateCalled=!0,this._authenticate(!0)}disconnect(){return this._disconnect(u.EXPLICIT)}forceDisconnect(){return this._connectCalled?(this._connectCalled=!1,this._authenticateCalled=!1,this._performDisconnect(u.EXPLICIT),Promise.resolve(!0)):Promise.resolve(!1)}forceTokenRefresh(){return this._refreshToken(!0).then(()=>!0)}getInitTime(){return this._initTime}getEndpoints(){return this._endpoints?Object.assign({},this._endpoints):null}getLastToken(){return this._lastToken}toPublic(e){return new ed(this,e)}hasOwnerRef(e){return this._ownerRef===e}appendTokenQuery(e){return this._refreshToken().then(t=>ey(e,t))}appendLastTokenQuery(e){return this._lastToken?ey(e,this._lastToken):e}matchMessages(e,t,n){if(!e)throw TypeError('Message "matcher" cannot be null.');if("function"!=typeof t)throw TypeError("Message callback cannot be null.");let r=r=>{let i=r.data.message;i.uri&&i.uri.match(e)&&(!n||n===r.data.plugin)&&t(i)};r.__matchMessagesExp=e,r.__matchMessagesPlugin=n,t.__matchMessagesWrapper=r,this._pluginMediator.on(l.PLUGIN_MESSAGE,r)}unmatchMessages(e,t,n){if("function"!=typeof t)throw TypeError("Message callback cannot be null.");let r=t.__matchMessagesWrapper;return!!r&&r.__matchMessagesExp===e&&r.__matchMessagesPlugin===n&&(this._pluginMediator.removeListener(l.PLUGIN_MESSAGE,r),!0)}handlePushRequests(e,t,n){if(!e)throw TypeError('Push request "matcher" cannot be null.');if("function"!=typeof t)throw TypeError("Push request callback cannot be null.");let r=r=>{let i=r.data.request;i.message_ident&&i.message_ident.match(e)&&(!n||n===r.data.plugin)&&Promise.resolve(t(i)).then(r.data.reply)};r.__matchRequestExp=e,r.__matchRequestPlugin=n,t.__matchRequestWrapper=r,this._pluginMediator.on(l.PLUGIN_REQUEST,r)}unhandlePushRequests(e,t,n){if("function"!=typeof t)throw TypeError("Push request callback cannot be null.");let r=t.__matchRequestWrapper;return!!r&&r.__matchRequestExp===e&&r.__matchRequestPlugin===n&&(this._pluginMediator.removeListener(l.PLUGIN_REQUEST,r),!0)}request(e,t){var n;let r={uri:e,options:t,context:{}};this._pluginMediator.emitSync(l.TRANSPORT_BEFORE_PROCESS_REQUEST,r);let i=this._sendRequest.bind(this,r.uri,r.options,r.context);return!this._endpoints&&ep.test(r.uri)?(ef.info("Request queued until endpoints resolved",r.uri),new Promise((e,t)=>{this.once(E.j.ENDPOINTS_RESOLVED,()=>{ef.info("Sending endpoints-queued request",r.uri),i().then(e,t)})})):this._connectionObserver.isOnline()||(null===(n=r.options)||void 0===n?void 0:n.allowOffline)?i():(ef.info("Request queued until online",r.uri),new Promise((e,t)=>{this.once(E.j.CONNECTION_ONLINE,()=>{ef.info("Sending offline-queued request",r.uri),i().then(e,t)})}))}addPlugin(e,t){let n=e(this,t),r=n.name;if(this._plugins[r])throw TypeError("Plugin is already added.");return n.attach(this,this._pluginMediator),this._plugins[r]=n,r}removePlugin(e){let t=this._plugins[e];return!!t&&(t.detach(this,this._pluginMediator),this._plugins[e]=void 0,!0)}hasPlugin(e){return!!this._plugins[e]}getPluginAPI(e){let t=this._plugins[e];return t&&t.api?t.api:null}getConnectionId(e="dealer"){let t=this._plugins[e];return t?t.api&&"getConnectionInfo"in t.api?t.api.getConnectionInfo().then(e=>e.id):Promise.reject(TypeError(`Plugin ${t} is not a socket plugin.`)):Promise.reject(TypeError(`Cannot retrieve connection id for plugin ${t}.`))}removeAllListeners(){return this}}class eE{constructor(e){this._headers={},this._init(e)}_init(e){if(e)for(let t of e.split("\r\n")){let e=t.indexOf(": ");if(e>0){let n=t.substring(0,e).toLowerCase(),r=t.substring(e+2);this._headers[n]=r}}}get(e){return this._headers[e.toLowerCase()]||null}has(e){return this._headers.hasOwnProperty(e.toLowerCase())}}let eb=z.P.forTag("transport.http.xhr"),eS=function(){},eT={json:!0,text:!0,document:!0};function ew(){this.onabort=eS,this.onerror=eS,this.onload=eS,this.onloadend=eS}function eO(e,t,n){var r,i;if(null===(r=e.options.signal)||void 0===r?void 0:r.aborted)return;let o=(0,X.q)(),s=this.status,a=new Z(this.responseURL||e.url,s);a.body=null;let c=e.options;if(c.timing&&(a.timing={completed:(0,X.n)(t,o)}),(null===(i=c.connectionObserver)||void 0===i?void 0:i.isOnline)&&(a.offline=!c.connectionObserver.isOnline()),(c.parseResponseHeaders||s>299)&&(a.headers=new eE(this.getAllResponseHeaders())),!c.ignoreResponseBody&&s!==V.G.NO_CONTENT){let e=c.responseType||"";if(!c.forcePolyfill&&"response"in this&&e===this.responseType)a.body=this.response;else if("document"===e)a.body=this.responseXML;else if("json"===e)try{a.body=JSON.parse(this.responseText)}catch(e){eb.warn("Could not parse response as JSON:",e),a.body=null}else("text"===e||""===e)&&(a.body=this.responseText)}n(a)}function eC(e,t,n){4===this.readyState?t(new Z(this.responseURL||e,this.status)):n(new O("Request cannot be completed.",v.J.HTTP_REQUEST_FAILED,this.status,e))}function eR(e){return function(e){let t=e.options.signal;return new Promise((n,r)=>{if(null==t?void 0:t.aborted){r(M(e.url,t));return}let i=new XMLHttpRequest,o=e.url;if(!o){r(TypeError("Request URL cannot be blank."));return}let s=null,a=e.method||"GET",c=e.payload||"";if(c&&"[object ReadableStream]"===Object.prototype.toString.call(c)){r(TypeError("payload is a ReadableStream, which is not supported"));return}a in J&&!0===J[a]&&c?s=c:c&&(o+=`?${c}`),i.open(a,o,!0),i.onerror=eC.bind(i,o,n,r),i.onabort=ew,i.onloadend=ew,i.onprogress=eS;let l=e.options;"include"===l.credentials&&(i.withCredentials=!0);let u=l.responseType;if(u){if(l.forcePolyfill){if(!(u in eT)){r(TypeError(`Cannot polyfill responseType "${u}"`));return}}else{if(!("responseType"in i)&&!(u in eT)){r(TypeError("Cannot set responseType: not supported in browser."));return}try{i.responseType=u}catch(e){r(TypeError(`Unknown responseType "${u}".`));return}if(i&&u!==i.responseType&&!(u in eT)){r(TypeError(`Unknown responseType "${u}".`));return}}}let d=e.headers.count()?e.headers.toJSON():null;if(d){for(let e in d)if(d.hasOwnProperty(e)&&d[e])try{i.setRequestHeader(e,d[e])}catch(e){r(e);return}}t&&t.addEventListener("abort",function e(){t.removeEventListener("abort",e),i.abort(),r(M(o,t))}),i.onload=eO.bind(i,e,(0,X.q)(),n);try{i.send(s)}catch(e){r(e);return}})}(e)}var eA=n(46685);function ek(){return()=>Promise.resolve({webgate:"https://www.spotify.com/api/",webapi:"https://api.spotify.com"})}function eN(){return()=>Promise.resolve("NOT_A_TOKEN")}function eI(){return{endpoints:ek(),token:eN()}}let ex="request-transformer";class eD{constructor(e){this.name=ex,this._uriTransformer=e.uriTransformer,this._optionsOverrides=e.optionsOverrides,this._include=e.include,this._processRequest=this._processRequest.bind(this)}_processRequest(e){var t,n;let r=e.data;if((null===(n=null===(t=r.options)||void 0===t?void 0:t.metadata)||void 0===n?void 0:n.noRequestTransform)||this._include&&!this._include(r.uri,r.options))return;this._uriTransformer&&(r.uri=this._uriTransformer(r.uri));let i=this._optionsOverrides;if(i){if(r.options){let e=Object.assign(Object.assign(Object.assign({},r.options),i),{metadata:Object.assign(Object.assign({},r.options.metadata),i.metadata),retry:Object.assign(Object.assign({},r.options.retry),i.retry),headers:Object.assign(Object.assign({},r.options.headers),i.headers)});r.options=e}else r.options=i}}attach(e,t){t.on(l.TRANSPORT_BEFORE_PROCESS_REQUEST,this._processRequest)}detach(e,t){t.removeListener(l.TRANSPORT_BEFORE_PROCESS_REQUEST,this._processRequest)}}function eP(e,t){return new eD(t)}function eM(e){let t=Object.assign({},e);return t.XHR||(t.XHR=y),t.Fetch=_,ev.create(t)}function eL(e){let t=eM(e);return t.addPlugin(G,{WebSocket:WebSocket}),t}},46685:function(e,t,n){"use strict";n.d(t,{Q:function(){return a}});var r=n(61878);class i extends Error{constructor(e,t,n=-1){super(t),this.name="XResolveError",this.message=t,this.code=e,this.status=n}}let o={DEALER:"dealer",WEBGATE:"spclient"},s={spclient:"spclient.wg.spotify.com",exp:"exp.wg.spotify.com",partners:"partners.wg.spotify.com"};function a(e={}){let t={dealer:e.dealer||o.DEALER,webgate:e.webgate||o.WEBGATE},n=`https://apresolve.spotify.com/?type=${t.dealer}&type=${t.webgate}`;return function(e){return e.request(n,{forcePolyfill:!0,responseType:"json",retry:{maxRetries:3,curve:"exponential",condition:function(e,t){return e.getStatusFamily()!==t.SUCCESS}},metadata:{noRequestTransform:!0}}).then(e=>{var n,o,a,c,l;let u=e.body,d={dealer:null!==(o=null===(n=null==u?void 0:u[t.dealer])||void 0===n?void 0:n[0])&&void 0!==o?o:"dealer.spotify.com",webgate:null!==(l=null!==(c=null===(a=null==u?void 0:u[t.webgate])||void 0===a?void 0:a[0])&&void 0!==c?c:s[t.webgate])&&void 0!==l?l:s.spclient,webapi:"https://api.spotify.com/"};if(!d.dealer||!d.webgate)throw new i(r.J.XRESOLVE_INCOMPLETE_RESPONSE,"X-Resolve responded with incomplete results.",e.status);return d}).then(e=>(e.dealer=`wss://${e.dealer.replace(/:443$/,"")}`,e.webgate=`https://${e.webgate.replace(/:443$/,"")}`,e))}}},65415:function(e,t){"use strict";t.byteLength=function(e){var t=c(e),n=t[0],r=t[1];return(n+r)*3/4-r},t.toByteArray=function(e){var t,n,o=c(e),s=o[0],a=o[1],l=new i((s+a)*3/4-a),u=0,d=a>0?s-4:s;for(n=0;n>16&255,l[u++]=t>>8&255,l[u++]=255&t;return 2===a&&(t=r[e.charCodeAt(n)]<<2|r[e.charCodeAt(n+1)]>>4,l[u++]=255&t),1===a&&(t=r[e.charCodeAt(n)]<<10|r[e.charCodeAt(n+1)]<<4|r[e.charCodeAt(n+2)]>>2,l[u++]=t>>8&255,l[u++]=255&t),l},t.fromByteArray=function(e){for(var t,r=e.length,i=r%3,o=[],s=0,a=r-i;s>18&63]+n[i>>12&63]+n[i>>6&63]+n[63&i]);return o.join("")}(e,s,s+16383>a?a:s+16383));return 1===i?o.push(n[(t=e[r-1])>>2]+n[t<<4&63]+"=="):2===i&&o.push(n[(t=(e[r-2]<<8)+e[r-1])>>10]+n[t>>4&63]+n[t<<2&63]+"="),o.join("")};for(var n=[],r=[],i="undefined"!=typeof Uint8Array?Uint8Array:Array,o="ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789+/",s=0,a=o.length;s0)throw Error("Invalid string. Length must be a multiple of 4");var n=e.indexOf("=");-1===n&&(n=t);var r=n===t?0:4-n%4;return[n,r]}r["-".charCodeAt(0)]=62,r["_".charCodeAt(0)]=63},91620:function(e,t,n){"use strict";var r=n(65415),i=n(30551),o="function"==typeof Symbol&&"function"==typeof Symbol.for?Symbol.for("nodejs.util.inspect.custom"):null;function s(e){if(e>2147483647)throw RangeError('The value "'+e+'" is invalid for option "size"');var t=new Uint8Array(e);return Object.setPrototypeOf(t,a.prototype),t}function a(e,t,n){if("number"==typeof e){if("string"==typeof t)throw TypeError('The "string" argument must be of type string. Received type number');return u(e)}return c(e,t,n)}function c(e,t,n){if("string"==typeof e)return function(e,t){if(("string"!=typeof t||""===t)&&(t="utf8"),!a.isEncoding(t))throw TypeError("Unknown encoding: "+t);var n=0|p(e,t),r=s(n),i=r.write(e,t);return i!==n&&(r=r.slice(0,i)),r}(e,t);if(ArrayBuffer.isView(e))return function(e){if(k(e,Uint8Array)){var t=new Uint8Array(e);return h(t.buffer,t.byteOffset,t.byteLength)}return d(e)}(e);if(null==e)throw TypeError("The first argument must be one of type string, Buffer, ArrayBuffer, Array, or Array-like Object. Received type "+typeof e);if(k(e,ArrayBuffer)||e&&k(e.buffer,ArrayBuffer)||"undefined"!=typeof SharedArrayBuffer&&(k(e,SharedArrayBuffer)||e&&k(e.buffer,SharedArrayBuffer)))return h(e,t,n);if("number"==typeof e)throw TypeError('The "value" argument must not be of type number. Received type number');var r=e.valueOf&&e.valueOf();if(null!=r&&r!==e)return a.from(r,t,n);var i=function(e){if(a.isBuffer(e)){var t,n=0|f(e.length),r=s(n);return 0===r.length||e.copy(r,0,0,n),r}return void 0!==e.length?"number"!=typeof e.length||(t=e.length)!=t?s(0):d(e):"Buffer"===e.type&&Array.isArray(e.data)?d(e.data):void 0}(e);if(i)return i;if("undefined"!=typeof Symbol&&null!=Symbol.toPrimitive&&"function"==typeof e[Symbol.toPrimitive])return a.from(e[Symbol.toPrimitive]("string"),t,n);throw TypeError("The first argument must be one of type string, Buffer, ArrayBuffer, Array, or Array-like Object. Received type "+typeof e)}function l(e){if("number"!=typeof e)throw TypeError('"size" argument must be of type number');if(e<0)throw RangeError('The value "'+e+'" is invalid for option "size"')}function u(e){return l(e),s(e<0?0:0|f(e))}function d(e){for(var t=e.length<0?0:0|f(e.length),n=s(t),r=0;r=2147483647)throw RangeError("Attempt to allocate Buffer larger than maximum size: 0x7fffffff bytes");return 0|e}function p(e,t){if(a.isBuffer(e))return e.length;if(ArrayBuffer.isView(e)||k(e,ArrayBuffer))return e.byteLength;if("string"!=typeof e)throw TypeError('The "string" argument must be one of type string, Buffer, or ArrayBuffer. Received type '+typeof e);var n=e.length,r=arguments.length>2&&!0===arguments[2];if(!r&&0===n)return 0;for(var i=!1;;)switch(t){case"ascii":case"latin1":case"binary":return n;case"utf8":case"utf-8":return C(e).length;case"ucs2":case"ucs-2":case"utf16le":case"utf-16le":return 2*n;case"hex":return n>>>1;case"base64":return R(e).length;default:if(i)return r?-1:C(e).length;t=(""+t).toLowerCase(),i=!0}}function m(e,t,n){var i,o,s=!1;if((void 0===t||t<0)&&(t=0),t>this.length||((void 0===n||n>this.length)&&(n=this.length),n<=0||(n>>>=0)<=(t>>>=0)))return"";for(e||(e="utf8");;)switch(e){case"hex":return function(e,t,n){var r=e.length;(!t||t<0)&&(t=0),(!n||n<0||n>r)&&(n=r);for(var i="",o=t;o2147483647?n=2147483647:n<-2147483648&&(n=-2147483648),(o=n=+n)!=o&&(n=i?0:e.length-1),n<0&&(n=e.length+n),n>=e.length){if(i)return -1;n=e.length-1}else if(n<0){if(!i)return -1;n=0}if("string"==typeof t&&(t=a.from(t,r)),a.isBuffer(t))return 0===t.length?-1:y(e,t,n,r,i);if("number"==typeof t)return(t&=255,"function"==typeof Uint8Array.prototype.indexOf)?i?Uint8Array.prototype.indexOf.call(e,t,n):Uint8Array.prototype.lastIndexOf.call(e,t,n):y(e,[t],n,r,i);throw TypeError("val must be string, number or Buffer")}function y(e,t,n,r,i){var o,s=1,a=e.length,c=t.length;if(void 0!==r&&("ucs2"===(r=String(r).toLowerCase())||"ucs-2"===r||"utf16le"===r||"utf-16le"===r)){if(e.length<2||t.length<2)return -1;s=2,a/=2,c/=2,n/=2}function l(e,t){return 1===s?e[t]:e.readUInt16BE(t*s)}if(i){var u=-1;for(o=n;oa&&(n=a-c),o=n;o>=0;o--){for(var d=!0,h=0;h239?4:l>223?3:l>191?2:1;if(i+d<=n)switch(d){case 1:l<128&&(u=l);break;case 2:(192&(o=e[i+1]))==128&&(c=(31&l)<<6|63&o)>127&&(u=c);break;case 3:o=e[i+1],s=e[i+2],(192&o)==128&&(192&s)==128&&(c=(15&l)<<12|(63&o)<<6|63&s)>2047&&(c<55296||c>57343)&&(u=c);break;case 4:o=e[i+1],s=e[i+2],a=e[i+3],(192&o)==128&&(192&s)==128&&(192&a)==128&&(c=(15&l)<<18|(63&o)<<12|(63&s)<<6|63&a)>65535&&c<1114112&&(u=c)}null===u?(u=65533,d=1):u>65535&&(u-=65536,r.push(u>>>10&1023|55296),u=56320|1023&u),r.push(u),i+=d}return function(e){var t=e.length;if(t<=4096)return String.fromCharCode.apply(String,e);for(var n="",r=0;rn)throw RangeError("Trying to access beyond buffer length")}function b(e,t,n,r,i,o){if(!a.isBuffer(e))throw TypeError('"buffer" argument must be a Buffer instance');if(t>i||te.length)throw RangeError("Index out of range")}function S(e,t,n,r,i,o){if(n+r>e.length||n<0)throw RangeError("Index out of range")}function T(e,t,n,r,o){return t=+t,n>>>=0,o||S(e,t,n,4,34028234663852886e22,-34028234663852886e22),i.write(e,t,n,r,23,4),n+4}function w(e,t,n,r,o){return t=+t,n>>>=0,o||S(e,t,n,8,17976931348623157e292,-17976931348623157e292),i.write(e,t,n,r,52,8),n+8}t.Buffer=a,t.SlowBuffer=function(e){return+e!=e&&(e=0),a.alloc(+e)},t.INSPECT_MAX_BYTES=50,t.kMaxLength=2147483647,a.TYPED_ARRAY_SUPPORT=function(){try{var e=new Uint8Array(1),t={foo:function(){return 42}};return Object.setPrototypeOf(t,Uint8Array.prototype),Object.setPrototypeOf(e,t),42===e.foo()}catch(e){return!1}}(),a.TYPED_ARRAY_SUPPORT||"undefined"==typeof console||"function"!=typeof console.error||console.error("This browser lacks typed array (Uint8Array) support which is required by `buffer` v5.x. Use `buffer` v4.x if you require old browser support."),Object.defineProperty(a.prototype,"parent",{enumerable:!0,get:function(){if(a.isBuffer(this))return this.buffer}}),Object.defineProperty(a.prototype,"offset",{enumerable:!0,get:function(){if(a.isBuffer(this))return this.byteOffset}}),a.poolSize=8192,a.from=function(e,t,n){return c(e,t,n)},Object.setPrototypeOf(a.prototype,Uint8Array.prototype),Object.setPrototypeOf(a,Uint8Array),a.alloc=function(e,t,n){return(l(e),e<=0)?s(e):void 0!==t?"string"==typeof n?s(e).fill(t,n):s(e).fill(t):s(e)},a.allocUnsafe=function(e){return u(e)},a.allocUnsafeSlow=function(e){return u(e)},a.isBuffer=function(e){return null!=e&&!0===e._isBuffer&&e!==a.prototype},a.compare=function(e,t){if(k(e,Uint8Array)&&(e=a.from(e,e.offset,e.byteLength)),k(t,Uint8Array)&&(t=a.from(t,t.offset,t.byteLength)),!a.isBuffer(e)||!a.isBuffer(t))throw TypeError('The "buf1", "buf2" arguments must be one of type Buffer or Uint8Array');if(e===t)return 0;for(var n=e.length,r=t.length,i=0,o=Math.min(n,r);ir.length?a.from(o).copy(r,i):Uint8Array.prototype.set.call(r,o,i);else if(a.isBuffer(o))o.copy(r,i);else throw TypeError('"list" argument must be an Array of Buffers');i+=o.length}return r},a.byteLength=p,a.prototype._isBuffer=!0,a.prototype.swap16=function(){var e=this.length;if(e%2!=0)throw RangeError("Buffer size must be a multiple of 16-bits");for(var t=0;tn&&(e+=" ... "),""},o&&(a.prototype[o]=a.prototype.inspect),a.prototype.compare=function(e,t,n,r,i){if(k(e,Uint8Array)&&(e=a.from(e,e.offset,e.byteLength)),!a.isBuffer(e))throw TypeError('The "target" argument must be one of type Buffer or Uint8Array. Received type '+typeof e);if(void 0===t&&(t=0),void 0===n&&(n=e?e.length:0),void 0===r&&(r=0),void 0===i&&(i=this.length),t<0||n>e.length||r<0||i>this.length)throw RangeError("out of range index");if(r>=i&&t>=n)return 0;if(r>=i)return -1;if(t>=n)return 1;if(t>>>=0,n>>>=0,r>>>=0,i>>>=0,this===e)return 0;for(var o=i-r,s=n-t,c=Math.min(o,s),l=this.slice(r,i),u=e.slice(t,n),d=0;d>>=0,isFinite(n)?(n>>>=0,void 0===r&&(r="utf8")):(r=n,n=void 0);else throw Error("Buffer.write(string, encoding, offset[, length]) is no longer supported");var i,o,s,a,c,l,u,d,h=this.length-t;if((void 0===n||n>h)&&(n=h),e.length>0&&(n<0||t<0)||t>this.length)throw RangeError("Attempt to write outside buffer bounds");r||(r="utf8");for(var f=!1;;)switch(r){case"hex":return function(e,t,n,r){n=Number(n)||0;var i=e.length-n;r?(r=Number(r))>i&&(r=i):r=i;var o=t.length;r>o/2&&(r=o/2);for(var s=0;s>8,i.push(n%256),i.push(r);return i}(e,this.length-u),this,u,d);default:if(f)throw TypeError("Unknown encoding: "+r);r=(""+r).toLowerCase(),f=!0}},a.prototype.toJSON=function(){return{type:"Buffer",data:Array.prototype.slice.call(this._arr||this,0)}},a.prototype.slice=function(e,t){var n=this.length;e=~~e,t=void 0===t?n:~~t,e<0?(e+=n)<0&&(e=0):e>n&&(e=n),t<0?(t+=n)<0&&(t=0):t>n&&(t=n),t>>=0,t>>>=0,n||E(e,t,this.length);for(var r=this[e],i=1,o=0;++o>>=0,t>>>=0,n||E(e,t,this.length);for(var r=this[e+--t],i=1;t>0&&(i*=256);)r+=this[e+--t]*i;return r},a.prototype.readUint8=a.prototype.readUInt8=function(e,t){return e>>>=0,t||E(e,1,this.length),this[e]},a.prototype.readUint16LE=a.prototype.readUInt16LE=function(e,t){return e>>>=0,t||E(e,2,this.length),this[e]|this[e+1]<<8},a.prototype.readUint16BE=a.prototype.readUInt16BE=function(e,t){return e>>>=0,t||E(e,2,this.length),this[e]<<8|this[e+1]},a.prototype.readUint32LE=a.prototype.readUInt32LE=function(e,t){return e>>>=0,t||E(e,4,this.length),(this[e]|this[e+1]<<8|this[e+2]<<16)+16777216*this[e+3]},a.prototype.readUint32BE=a.prototype.readUInt32BE=function(e,t){return e>>>=0,t||E(e,4,this.length),16777216*this[e]+(this[e+1]<<16|this[e+2]<<8|this[e+3])},a.prototype.readIntLE=function(e,t,n){e>>>=0,t>>>=0,n||E(e,t,this.length);for(var r=this[e],i=1,o=0;++o=(i*=128)&&(r-=Math.pow(2,8*t)),r},a.prototype.readIntBE=function(e,t,n){e>>>=0,t>>>=0,n||E(e,t,this.length);for(var r=t,i=1,o=this[e+--r];r>0&&(i*=256);)o+=this[e+--r]*i;return o>=(i*=128)&&(o-=Math.pow(2,8*t)),o},a.prototype.readInt8=function(e,t){return(e>>>=0,t||E(e,1,this.length),128&this[e])?-((255-this[e]+1)*1):this[e]},a.prototype.readInt16LE=function(e,t){e>>>=0,t||E(e,2,this.length);var n=this[e]|this[e+1]<<8;return 32768&n?4294901760|n:n},a.prototype.readInt16BE=function(e,t){e>>>=0,t||E(e,2,this.length);var n=this[e+1]|this[e]<<8;return 32768&n?4294901760|n:n},a.prototype.readInt32LE=function(e,t){return e>>>=0,t||E(e,4,this.length),this[e]|this[e+1]<<8|this[e+2]<<16|this[e+3]<<24},a.prototype.readInt32BE=function(e,t){return e>>>=0,t||E(e,4,this.length),this[e]<<24|this[e+1]<<16|this[e+2]<<8|this[e+3]},a.prototype.readFloatLE=function(e,t){return e>>>=0,t||E(e,4,this.length),i.read(this,e,!0,23,4)},a.prototype.readFloatBE=function(e,t){return e>>>=0,t||E(e,4,this.length),i.read(this,e,!1,23,4)},a.prototype.readDoubleLE=function(e,t){return e>>>=0,t||E(e,8,this.length),i.read(this,e,!0,52,8)},a.prototype.readDoubleBE=function(e,t){return e>>>=0,t||E(e,8,this.length),i.read(this,e,!1,52,8)},a.prototype.writeUintLE=a.prototype.writeUIntLE=function(e,t,n,r){if(e=+e,t>>>=0,n>>>=0,!r){var i=Math.pow(2,8*n)-1;b(this,e,t,n,i,0)}var o=1,s=0;for(this[t]=255&e;++s>>=0,n>>>=0,!r){var i=Math.pow(2,8*n)-1;b(this,e,t,n,i,0)}var o=n-1,s=1;for(this[t+o]=255&e;--o>=0&&(s*=256);)this[t+o]=e/s&255;return t+n},a.prototype.writeUint8=a.prototype.writeUInt8=function(e,t,n){return e=+e,t>>>=0,n||b(this,e,t,1,255,0),this[t]=255&e,t+1},a.prototype.writeUint16LE=a.prototype.writeUInt16LE=function(e,t,n){return e=+e,t>>>=0,n||b(this,e,t,2,65535,0),this[t]=255&e,this[t+1]=e>>>8,t+2},a.prototype.writeUint16BE=a.prototype.writeUInt16BE=function(e,t,n){return e=+e,t>>>=0,n||b(this,e,t,2,65535,0),this[t]=e>>>8,this[t+1]=255&e,t+2},a.prototype.writeUint32LE=a.prototype.writeUInt32LE=function(e,t,n){return e=+e,t>>>=0,n||b(this,e,t,4,4294967295,0),this[t+3]=e>>>24,this[t+2]=e>>>16,this[t+1]=e>>>8,this[t]=255&e,t+4},a.prototype.writeUint32BE=a.prototype.writeUInt32BE=function(e,t,n){return e=+e,t>>>=0,n||b(this,e,t,4,4294967295,0),this[t]=e>>>24,this[t+1]=e>>>16,this[t+2]=e>>>8,this[t+3]=255&e,t+4},a.prototype.writeIntLE=function(e,t,n,r){if(e=+e,t>>>=0,!r){var i=Math.pow(2,8*n-1);b(this,e,t,n,i-1,-i)}var o=0,s=1,a=0;for(this[t]=255&e;++o>0)-a&255;return t+n},a.prototype.writeIntBE=function(e,t,n,r){if(e=+e,t>>>=0,!r){var i=Math.pow(2,8*n-1);b(this,e,t,n,i-1,-i)}var o=n-1,s=1,a=0;for(this[t+o]=255&e;--o>=0&&(s*=256);)e<0&&0===a&&0!==this[t+o+1]&&(a=1),this[t+o]=(e/s>>0)-a&255;return t+n},a.prototype.writeInt8=function(e,t,n){return e=+e,t>>>=0,n||b(this,e,t,1,127,-128),e<0&&(e=255+e+1),this[t]=255&e,t+1},a.prototype.writeInt16LE=function(e,t,n){return e=+e,t>>>=0,n||b(this,e,t,2,32767,-32768),this[t]=255&e,this[t+1]=e>>>8,t+2},a.prototype.writeInt16BE=function(e,t,n){return e=+e,t>>>=0,n||b(this,e,t,2,32767,-32768),this[t]=e>>>8,this[t+1]=255&e,t+2},a.prototype.writeInt32LE=function(e,t,n){return e=+e,t>>>=0,n||b(this,e,t,4,2147483647,-2147483648),this[t]=255&e,this[t+1]=e>>>8,this[t+2]=e>>>16,this[t+3]=e>>>24,t+4},a.prototype.writeInt32BE=function(e,t,n){return e=+e,t>>>=0,n||b(this,e,t,4,2147483647,-2147483648),e<0&&(e=4294967295+e+1),this[t]=e>>>24,this[t+1]=e>>>16,this[t+2]=e>>>8,this[t+3]=255&e,t+4},a.prototype.writeFloatLE=function(e,t,n){return T(this,e,t,!0,n)},a.prototype.writeFloatBE=function(e,t,n){return T(this,e,t,!1,n)},a.prototype.writeDoubleLE=function(e,t,n){return w(this,e,t,!0,n)},a.prototype.writeDoubleBE=function(e,t,n){return w(this,e,t,!1,n)},a.prototype.copy=function(e,t,n,r){if(!a.isBuffer(e))throw TypeError("argument should be a Buffer");if(n||(n=0),r||0===r||(r=this.length),t>=e.length&&(t=e.length),t||(t=0),r>0&&r=this.length)throw RangeError("Index out of range");if(r<0)throw RangeError("sourceEnd out of bounds");r>this.length&&(r=this.length),e.length-t>>=0,n=void 0===n?this.length:n>>>0,e||(e=0),"number"==typeof e)for(i=t;i55295&&n<57344){if(!i){if(n>56319||s+1===r){(t-=3)>-1&&o.push(239,191,189);continue}i=n;continue}if(n<56320){(t-=3)>-1&&o.push(239,191,189),i=n;continue}n=(i-55296<<10|n-56320)+65536}else i&&(t-=3)>-1&&o.push(239,191,189);if(i=null,n<128){if((t-=1)<0)break;o.push(n)}else if(n<2048){if((t-=2)<0)break;o.push(n>>6|192,63&n|128)}else if(n<65536){if((t-=3)<0)break;o.push(n>>12|224,n>>6&63|128,63&n|128)}else if(n<1114112){if((t-=4)<0)break;o.push(n>>18|240,n>>12&63|128,n>>6&63|128,63&n|128)}else throw Error("Invalid code point")}return o}function R(e){return r.toByteArray(function(e){if((e=(e=e.split("=")[0]).trim().replace(O,"")).length<2)return"";for(;e.length%4!=0;)e+="=";return e}(e))}function A(e,t,n,r){for(var i=0;i=t.length)&&!(i>=e.length);++i)t[i+n]=e[i];return i}function k(e,t){return e instanceof t||null!=e&&null!=e.constructor&&null!=e.constructor.name&&e.constructor.name===t.name}var N=function(){for(var e="0123456789abcdef",t=Array(256),n=0;n<16;++n)for(var r=16*n,i=0;i<16;++i)t[r+i]=e[n]+e[i];return t}()},72535:function(e,t,n){"use strict";var r=n(56237),i={childContextTypes:!0,contextType:!0,contextTypes:!0,defaultProps:!0,displayName:!0,getDefaultProps:!0,getDerivedStateFromError:!0,getDerivedStateFromProps:!0,mixins:!0,propTypes:!0,type:!0},o={name:!0,length:!0,prototype:!0,caller:!0,callee:!0,arguments:!0,arity:!0},s={$$typeof:!0,compare:!0,defaultProps:!0,displayName:!0,propTypes:!0,type:!0},a={};function c(e){return r.isMemo(e)?s:a[e.$$typeof]||i}a[r.ForwardRef]={$$typeof:!0,render:!0,defaultProps:!0,displayName:!0,propTypes:!0},a[r.Memo]=s;var l=Object.defineProperty,u=Object.getOwnPropertyNames,d=Object.getOwnPropertySymbols,h=Object.getOwnPropertyDescriptor,f=Object.getPrototypeOf,p=Object.prototype;e.exports=function e(t,n,r){if("string"!=typeof n){if(p){var i=f(n);i&&i!==p&&e(t,i,r)}var s=u(n);d&&(s=s.concat(d(n)));for(var a=c(t),m=c(n),g=0;g>1,u=-7,d=n?i-1:0,h=n?-1:1,f=e[t+d];for(d+=h,o=f&(1<<-u)-1,f>>=-u,u+=a;u>0;o=256*o+e[t+d],d+=h,u-=8);for(s=o&(1<<-u)-1,o>>=-u,u+=r;u>0;s=256*s+e[t+d],d+=h,u-=8);if(0===o)o=1-l;else{if(o===c)return s?NaN:1/0*(f?-1:1);s+=Math.pow(2,r),o-=l}return(f?-1:1)*s*Math.pow(2,o-r)},t.write=function(e,t,n,r,i,o){var s,a,c,l=8*o-i-1,u=(1<>1,h=23===i?5960464477539062e-23:0,f=r?0:o-1,p=r?1:-1,m=t<0||0===t&&1/t<0?1:0;for(isNaN(t=Math.abs(t))||t===1/0?(a=isNaN(t)?1:0,s=u):(s=Math.floor(Math.log(t)/Math.LN2),t*(c=Math.pow(2,-s))<1&&(s--,c*=2),s+d>=1?t+=h/c:t+=h*Math.pow(2,1-d),t*c>=2&&(s++,c/=2),s+d>=u?(a=0,s=u):s+d>=1?(a=(t*c-1)*Math.pow(2,i),s+=d):(a=t*Math.pow(2,d-1)*Math.pow(2,i),s=0));i>=8;e[n+f]=255&a,f+=p,a/=256,i-=8);for(s=s<0;e[n+f]=255&s,f+=p,s/=256,l-=8);e[n+f-p]|=128*m}},12509:function(e,t,n){"use strict";var r,i;e.exports=(null==(r=n.g.process)?void 0:r.env)&&"object"==typeof(null==(i=n.g.process)?void 0:i.env)?n.g.process:n(19378)},86788:function(e,t,n){(window.__NEXT_P=window.__NEXT_P||[]).push(["/_app",function(){return n(58221)}])},7427:function(e,t,n){"use strict";let r,i,o,s,a,c,l,u,d,h,f,p,m,g,_,y,v,E,b;function S(e){let t;let n=e[0],r=1;for(;rn.call(t,...e)),t=void 0)}return n}var T,w,O,C,R,A,k,N,I,x,D,P,M=n(12538),L=n(14481);function j(e,t,n=[t],r="npm"){let i=e._metadata||{};i.sdk||(i.sdk={name:`sentry.javascript.${t}`,packages:n.map(e=>({name:`${r}:@sentry/${e}`,version:L.J})),version:L.J}),e._metadata=i}var U=n(38211),$=n(57229),B=n(15196);let F=[];function q(e,t){for(let n of t)n&&n.afterAllSetup&&n.afterAllSetup(e)}function H(e,t,n){if(n[t.name]){$.X&&B.kg.log(`Integration skipped because it was already installed: ${t.name}`);return}if(n[t.name]=t,-1===F.indexOf(t.name)&&"function"==typeof t.setupOnce&&(t.setupOnce(),F.push(t.name)),t.setup&&"function"==typeof t.setup&&t.setup(e),"function"==typeof t.preprocessEvent){let n=t.preprocessEvent.bind(t);e.on("preprocessEvent",(t,r)=>n(t,r,e))}if("function"==typeof t.processEvent){let n=t.processEvent.bind(t),r=Object.assign((t,r)=>n(t,r,e),{id:t.name});e.addEventProcessor(r)}$.X&&B.kg.log(`Integration installed: ${t.name}`)}var W=n(14038),G=n(21632);let z=[/^Script error\.?$/,/^Javascript error: Script error\.? on line 0$/,/^ResizeObserver loop completed with undelivered notifications.$/,/^Cannot redefine property: googletag$/,"undefined is not an object (evaluating 'a.L')",'can\'t redefine non-configurable property "solana"',"vv().getRestrictions is not a function. (In 'vv().getRestrictions(1,a)', 'vv().getRestrictions' is undefined)","Can't find variable: _AutofillCallbackHandler",/^Non-Error promise rejection captured with value: Object Not Found Matching Id:\d+, MethodName:simulateEvent, ParamCount:\d+$/],X=(e={})=>({name:"InboundFilters",processEvent:(t,n,r)=>{var i,o;return((i=function(e={},t={}){return{allowUrls:[...e.allowUrls||[],...t.allowUrls||[]],denyUrls:[...e.denyUrls||[],...t.denyUrls||[]],ignoreErrors:[...e.ignoreErrors||[],...t.ignoreErrors||[],...e.disableErrorDefaults?[]:z],ignoreTransactions:[...e.ignoreTransactions||[],...t.ignoreTransactions||[]],ignoreInternal:void 0===e.ignoreInternal||e.ignoreInternal}}(e,r.getOptions())).ignoreInternal&&function(e){try{return"SentryError"===e.exception.values[0].type}catch(e){}return!1}(t)?($.X&&B.kg.warn(`Event dropped due to being internal Sentry Error. Event: ${(0,W.jH)(t)}`),0):(o=i.ignoreErrors,!t.type&&o&&o.length&&(function(e){let t;let n=[];e.message&&n.push(e.message);try{t=e.exception.values[e.exception.values.length-1]}catch(e){}return t&&t.value&&(n.push(t.value),t.type&&n.push(`${t.type}: ${t.value}`)),n})(t).some(e=>(0,G.U0)(e,o)))?($.X&&B.kg.warn(`Event dropped due to being matched by \`ignoreErrors\` option. Event: ${(0,W.jH)(t)}`),0):t.type||!t.exception||!t.exception.values||0===t.exception.values.length||t.message||t.exception.values.some(e=>e.stacktrace||e.type&&"Error"!==e.type||e.value)?!function(e,t){if("transaction"!==e.type||!t||!t.length)return!1;let n=e.transaction;return!!n&&(0,G.U0)(n,t)}(t,i.ignoreTransactions)?!function(e,t){if(!t||!t.length)return!1;let n=J(e);return!!n&&(0,G.U0)(n,t)}(t,i.denyUrls)?function(e,t){if(!t||!t.length)return!0;let n=J(e);return!n||(0,G.U0)(n,t)}(t,i.allowUrls)||($.X&&B.kg.warn(`Event dropped due to not being matched by \`allowUrls\` option. Event: ${(0,W.jH)(t)}. Url: ${J(t)}`),0):($.X&&B.kg.warn(`Event dropped due to being matched by \`denyUrls\` option. Event: ${(0,W.jH)(t)}. Url: ${J(t)}`),0):($.X&&B.kg.warn(`Event dropped due to being matched by \`ignoreTransactions\` option. Event: ${(0,W.jH)(t)}`),0):($.X&&B.kg.warn(`Event dropped due to not having an error message, error type or stacktrace. Event: ${(0,W.jH)(t)}`),0))?t:null}});function J(e){try{let t;try{t=e.exception.values[0].stacktrace.frames}catch(e){}return t?function(e=[]){for(let t=e.length-1;t>=0;t--){let n=e[t];if(n&&""!==n.filename&&"[native code]"!==n.filename)return n.filename||null}return null}(t):null}catch(t){return $.X&&B.kg.error(`Cannot extract url for event ${(0,W.jH)(e)}`),null}}var V=n(6411),Y=n(98802);let Z=new WeakMap,K=()=>({name:"FunctionToString",setupOnce(){r=Function.prototype.toString;try{Function.prototype.toString=function(...e){let t=(0,Y.HK)(this),n=Z.has((0,V.s3)())&&void 0!==t?t:this;return r.apply(n,e)}}catch(e){}},setup(e){Z.set(e,!0)}});var Q=n(59628);let ee=()=>{let e;return{name:"Dedupe",processEvent(t){if(t.type)return t;try{var n;if((n=e)&&(function(e,t){let n=e.message,r=t.message;return!!((n||r)&&(!n||r)&&(n||!r)&&n===r&&en(e,t)&&et(e,t))}(t,n)||function(e,t){let n=er(t),r=er(e);return!!(n&&r&&n.type===r.type&&n.value===r.value&&en(e,t)&&et(e,t))}(t,n)))return $.X&&B.kg.warn("Event dropped due to being a duplicate of previously captured event."),null}catch(e){}return e=t}}};function et(e,t){let n=(0,Q.Fr)(e),r=(0,Q.Fr)(t);if(!n&&!r)return!0;if(n&&!r||!n&&r||r.length!==n.length)return!1;for(let e=0;e{console.error(`Invalid Sentry Dsn: ${e}`)});return}let[n,r,i="",o="",s="",a=""]=t.slice(1),c="",l=a,u=l.split("/");if(u.length>1&&(c=u.slice(0,-1).join("/"),l=u.pop()),l){let e=l.match(/^\d+/);e&&(l=e[0])}return ed({host:o,pass:i,path:c,projectId:l,port:s,protocol:n,publicKey:r})}function ed(e){return{protocol:e.protocol,publicKey:e.publicKey||"",pass:e.pass||"",host:e.host,port:e.port||"",path:e.path||"",projectId:e.projectId}}var eh=n(67089);function ef(e,t=[]){return[e,t]}function ep(e,t){for(let n of e[1]){let e=n[0].type;if(t(n,e))return!0}return!1}function em(e){return M.GLOBAL_OBJ.__SENTRY__&&M.GLOBAL_OBJ.__SENTRY__.encodePolyfill?M.GLOBAL_OBJ.__SENTRY__.encodePolyfill(e):new TextEncoder().encode(e)}let eg={session:"session",sessions:"session",attachment:"attachment",transaction:"transaction",event:"error",client_report:"internal",user_report:"default",profile:"profile",profile_chunk:"profile",replay_event:"replay",replay_recording:"replay",check_in:"monitor",feedback:"feedback",span:"span",statsd:"metric_bucket",raw_security:"security"};function e_(e){if(!e||!e.sdk)return;let{name:t,version:n}=e.sdk;return{name:t,version:n}}function ey(e,t,n,r){let i=e.sdkProcessingMetadata&&e.sdkProcessingMetadata.dynamicSamplingContext;return{event_id:e.event_id,sent_at:new Date().toISOString(),...t&&{sdk:t},...!!n&&r&&{dsn:el(r)},...i&&{trace:(0,Y.Jr)({...i})}}}var ev=n(1543),eE=n(28161),eb=n(4134);class eS extends Error{constructor(e,t="warn"){super(e),this.message=e,this.name=new.target.prototype.constructor.name,Object.setPrototypeOf(this,new.target.prototype),this.logLevel=t}}var eT=n(10318),ew=n(71027);function eO(e){if("boolean"==typeof e)return Number(e);let t="string"==typeof e?parseFloat(e):e;if("number"!=typeof t||isNaN(t)||t<0||t>1){$.X&&B.kg.warn(`[Tracing] Given sample rate is invalid. Sample rate must be a boolean or a number between 0 and 1. Got ${JSON.stringify(e)} of type ${JSON.stringify(typeof e)}.`);return}return t}var eC=n(24660);let eR="Not capturing exception because it's already been captured.";class eA{constructor(e){if(this._options=e,this._integrations={},this._numProcessing=0,this._outcomes={},this._hooks={},this._eventProcessors=[],e.dsn?this._dsn=function(e){let t="string"==typeof e?eu(e):ed(e);if(t&&function(e){if(!ei.X)return!0;let{port:t,projectId:n,protocol:r}=e;return!["protocol","publicKey","host","projectId"].find(t=>!e[t]&&(B.kg.error(`Invalid Sentry Dsn: ${t} missing`),!0))&&(n.match(/^\d+$/)?"http"===r||"https"===r?!(t&&isNaN(parseInt(t,10)))||(B.kg.error(`Invalid Sentry Dsn: Invalid port ${t}`),!1):(B.kg.error(`Invalid Sentry Dsn: Invalid protocol ${r}`),!1):(B.kg.error(`Invalid Sentry Dsn: Invalid projectId ${n}`),!1))}(t))return t}(e.dsn):$.X&&B.kg.warn("No DSN provided, client will not send events."),this._dsn){var t,n,r;let i=(t=this._dsn,n=e.tunnel,r=e._metadata?e._metadata.sdk:void 0,n||`${function(e){let t=e.protocol?`${e.protocol}:`:"",n=e.port?`:${e.port}`:"";return`${t}//${e.host}${n}${e.path?`/${e.path}`:""}/api/`}(t)}${t.projectId}/envelope/?${function(e,t){let n={sentry_version:"7"};return e.publicKey&&(n.sentry_key=e.publicKey),t&&(n.sentry_client=`${t.name}/${t.version}`),new URLSearchParams(n).toString()}(t,r)}`);this._transport=e.transport({tunnel:this._options.tunnel,recordDroppedEvent:this.recordDroppedEvent.bind(this),...e.transportOptions,url:i})}let i=["enableTracing","tracesSampleRate","tracesSampler"].find(t=>t in e&&void 0==e[t]);i&&(0,B.Cf)(()=>{console.warn(`[Sentry] Deprecation warning: \`${i}\` is set to undefined, which leads to tracing being enabled. In v9, a value of \`undefined\` will result in tracing being disabled.`)})}captureException(e,t,n){let r=(0,W.DM)();if((0,W.YO)(e))return $.X&&B.kg.log(eR),r;let i={event_id:r,...t};return this._process(this.eventFromException(e,i).then(e=>this._captureEvent(e,i,n))),i.event_id}captureMessage(e,t,n,r){let i={event_id:(0,W.DM)(),...n},o=(0,eT.Le)(e)?e:String(e),s=(0,eT.pt)(e)?this.eventFromMessage(o,t,i):this.eventFromException(e,i);return this._process(s.then(e=>this._captureEvent(e,i,r))),i.event_id}captureEvent(e,t,n){let r=(0,W.DM)();if(t&&t.originalException&&(0,W.YO)(t.originalException))return $.X&&B.kg.log(eR),r;let i={event_id:r,...t},o=(e.sdkProcessingMetadata||{}).capturedSpanScope;return this._process(this._captureEvent(e,i,o||n)),i.event_id}captureSession(e){"string"!=typeof e.release?$.X&&B.kg.warn("Discarded session because of missing or non-string release"):(this.sendSession(e),(0,eE.CT)(e,{init:!1}))}getDsn(){return this._dsn}getOptions(){return this._options}getSdkMetadata(){return this._options._metadata}getTransport(){return this._transport}flush(e){let t=this._transport;return t?(this.emit("flush"),this._isClientDoneProcessing(e).then(n=>t.flush(e).then(e=>n&&e))):(0,ew.WD)(!0)}close(e){return this.flush(e).then(e=>(this.getOptions().enabled=!1,this.emit("close"),e))}getEventProcessors(){return this._eventProcessors}addEventProcessor(e){this._eventProcessors.push(e)}init(){(this._isEnabled()||this._options.integrations.some(({name:e})=>e.startsWith("Spotlight")))&&this._setupIntegrations()}getIntegrationByName(e){return this._integrations[e]}addIntegration(e){let t=this._integrations[e.name];H(this,e,this._integrations),t||q(this,[e])}sendEvent(e,t={}){this.emit("beforeSendEvent",e,t);let n=function(e,t,n,r){var i;let o=e_(n),s=e.type&&"replay_event"!==e.type?e.type:"event";(i=n&&n.sdk)&&(e.sdk=e.sdk||{},e.sdk.name=e.sdk.name||i.name,e.sdk.version=e.sdk.version||i.version,e.sdk.integrations=[...e.sdk.integrations||[],...i.integrations||[]],e.sdk.packages=[...e.sdk.packages||[],...i.packages||[]]);let a=ey(e,o,r,t);return delete e.sdkProcessingMetadata,ef(a,[[{type:s},e]])}(e,this._dsn,this._options._metadata,this._options.tunnel);for(let e of t.attachments||[])n=function(e,t){let[n,r]=e;return[n,[...r,t]]}(n,function(e){let t="string"==typeof e.data?em(e.data):e.data;return[(0,Y.Jr)({type:"attachment",length:t.length,filename:e.filename,content_type:e.contentType,attachment_type:e.attachmentType}),t]}(e));let r=this.sendEnvelope(n);r&&r.then(t=>this.emit("afterSendEvent",e,t),null)}sendSession(e){let t=function(e,t,n,r){let i=e_(n);return ef({sent_at:new Date().toISOString(),...i&&{sdk:i},...!!r&&t&&{dsn:el(t)}},["aggregates"in e?[{type:"sessions"},e]:[{type:"session"},e.toJSON()]])}(e,this._dsn,this._options._metadata,this._options.tunnel);this.sendEnvelope(t)}recordDroppedEvent(e,t,n){if(this._options.sendClientReports){let r="number"==typeof n?n:1,i=`${e}:${t}`;$.X&&B.kg.log(`Recording outcome: "${i}"${r>1?` (${r} times)`:""}`),this._outcomes[i]=(this._outcomes[i]||0)+r}}on(e,t){let n=this._hooks[e]=this._hooks[e]||[];return n.push(t),()=>{let e=n.indexOf(t);e>-1&&n.splice(e,1)}}emit(e,...t){let n=this._hooks[e];n&&n.forEach(e=>e(...t))}sendEnvelope(e){return(this.emit("beforeEnvelope",e),this._isEnabled()&&this._transport)?this._transport.send(e).then(null,e=>($.X&&B.kg.error("Error while sending envelope:",e),e)):($.X&&B.kg.error("Transport disabled"),(0,ew.WD)({}))}_setupIntegrations(){let{integrations:e}=this._options;this._integrations=function(e,t){let n={};return t.forEach(t=>{t&&H(e,t,n)}),n}(this,e),q(this,e)}_updateSessionFromEvent(e,t){let n=!1,r=!1,i=t.exception&&t.exception.values;if(i)for(let e of(r=!0,i)){let t=e.mechanism;if(t&&!1===t.handled){n=!0;break}}let o="ok"===e.status;(o&&0===e.errors||o&&n)&&((0,eE.CT)(e,{...n&&{status:"crashed"},errors:e.errors||Number(r||n)}),this.captureSession(e))}_isClientDoneProcessing(e){return new ew.cW(t=>{let n=0,r=setInterval(()=>{0==this._numProcessing?(clearInterval(r),t(!0)):(n+=1,e&&n>=e&&(clearInterval(r),t(!1)))},1)})}_isEnabled(){return!1!==this.getOptions().enabled&&void 0!==this._transport}_prepareEvent(e,t,n=(0,V.nZ)(),r=(0,V.aF)()){let i=this.getOptions(),o=Object.keys(this._integrations);return!t.integrations&&o.length>0&&(t.integrations=o),this.emit("preprocessEvent",e,t),e.type||r.setLastEventId(e.event_id||t.event_id),(0,eC.R)(i,e,t,n,this,r).then(e=>{if(null===e)return e;e.contexts={trace:(0,V.XX)(n),...e.contexts};let t=(0,ea.CG)(this,n);return e.sdkProcessingMetadata={dynamicSamplingContext:t,...e.sdkProcessingMetadata},e})}_captureEvent(e,t={},n){return this._processEvent(e,t,n).then(e=>e.event_id,e=>{$.X&&("log"===e.logLevel?B.kg.log(e.message):B.kg.warn(e))})}_processEvent(e,t,n){let r=this.getOptions(),{sampleRate:i}=r,o=eN(e),s=ek(e),a=e.type||"error",c=`before send for type \`${a}\``,l=void 0===i?void 0:eO(i);if(s&&"number"==typeof l&&Math.random()>l)return this.recordDroppedEvent("sample_rate","error",e),(0,ew.$2)(new eS(`Discarding event because it's not included in the random sample (sampling rate = ${i})`,"log"));let u="replay_event"===a?"replay":a,d=(e.sdkProcessingMetadata||{}).capturedSpanIsolationScope;return this._prepareEvent(e,t,n,d).then(n=>{if(null===n)throw this.recordDroppedEvent("event_processor",u,e),new eS("An event processor returned `null`, will not send event.","log");return t.data&&!0===t.data.__sentry__?n:function(e,t){let n=`${t} must return \`null\` or a valid event.`;if((0,eT.J8)(e))return e.then(e=>{if(!(0,eT.PO)(e)&&null!==e)throw new eS(n);return e},e=>{throw new eS(`${t} rejected with ${e}`)});if(!(0,eT.PO)(e)&&null!==e)throw new eS(n);return e}(function(e,t,n,r){let{beforeSend:i,beforeSendTransaction:o,beforeSendSpan:s}=t;if(ek(n)&&i)return i(n,r);if(eN(n)){if(n.spans&&s){let t=[];for(let r of n.spans){let n=s(r);n?t.push(n):((0,ev.R6)(),e.recordDroppedEvent("before_send","span"))}n.spans=t}if(o){if(n.spans){let e=n.spans.length;n.sdkProcessingMetadata={...n.sdkProcessingMetadata,spanCountBeforeProcessing:e}}return o(n,r)}}return n}(this,r,n,t),c)}).then(r=>{if(null===r){if(this.recordDroppedEvent("before_send",u,e),o){let t=1+(e.spans||[]).length;this.recordDroppedEvent("before_send","span",t)}throw new eS(`${c} returned \`null\`, will not send event.`,"log")}let i=n&&n.getSession();if(!o&&i&&this._updateSessionFromEvent(i,r),o){let e=(r.sdkProcessingMetadata&&r.sdkProcessingMetadata.spanCountBeforeProcessing||0)-(r.spans?r.spans.length:0);e>0&&this.recordDroppedEvent("before_send","span",e)}let s=r.transaction_info;return o&&s&&r.transaction!==e.transaction&&(r.transaction_info={...s,source:"custom"}),this.sendEvent(r,t),r}).then(null,e=>{if(e instanceof eS)throw e;throw this.captureException(e,{data:{__sentry__:!0},originalException:e}),new eS(`Event processing pipeline threw an error, original event will not be sent. Details have been sent as a new event. Reason: ${e}`)})}_process(e){this._numProcessing++,e.then(e=>(this._numProcessing--,e),e=>(this._numProcessing--,e))}_clearOutcomes(){let e=this._outcomes;return this._outcomes={},Object.entries(e).map(([e,t])=>{let[n,r]=e.split(":");return{reason:n,category:r,quantity:t}})}_flushOutcomes(){var e;$.X&&B.kg.log("Flushing outcomes...");let t=this._clearOutcomes();if(0===t.length){$.X&&B.kg.log("No outcomes to send");return}if(!this._dsn){$.X&&B.kg.log("No dsn provided, will not send outcomes");return}$.X&&B.kg.log("Sending outcomes:",t);let n=ef((e=this._options.tunnel&&el(this._dsn))?{dsn:e}:{},[[{type:"client_report"},{timestamp:(0,eb.yW)(),discarded_events:t}]]);this.sendEnvelope(n)}}function ek(e){return void 0===e.type}function eN(e){return"transaction"===e.type}function eI(e,t){let n=eD(e,t),r={type:function(e){let t=e&&e.name;return!t&&eM(e)?e.message&&Array.isArray(e.message)&&2==e.message.length?e.message[0]:"WebAssembly.Exception":t}(t),value:function(e){let t=e&&e.message;return t?t.error&&"string"==typeof t.error.message?t.error.message:eM(e)&&Array.isArray(e.message)&&2==e.message.length?e.message[1]:t:"No error message"}(t)};return n.length&&(r.stacktrace={frames:n}),void 0===r.type&&""===r.value&&(r.value="Unrecoverable error caught"),r}function ex(e,t){return{exception:{values:[eI(e,t)]}}}function eD(e,t){let n=t.stacktrace||t.stack||"",r=t&&eP.test(t.message)?1:0,i="number"==typeof t.framesToPop?t.framesToPop:0;try{return e(n,r,i)}catch(e){}return[]}let eP=/Minified React error #\d+;/i;function eM(e){return"undefined"!=typeof WebAssembly&&void 0!==WebAssembly.Exception&&e instanceof WebAssembly.Exception}function eL(e,t,n,r,i){let o;if((0,eT.VW)(t)&&t.error)return ex(e,t.error);if((0,eT.TX)(t)||(0,eT.fm)(t)){if("stack"in t)o=ex(e,t);else{let i=t.name||((0,eT.TX)(t)?"DOMError":"DOMException"),s=t.message?`${i}: ${t.message}`:i;o=ej(e,s,n,r),(0,W.Db)(o,s)}return"code"in t&&(o.tags={...o.tags,"DOMException.code":`${t.code}`}),o}return(0,eT.VZ)(t)?ex(e,t):((0,eT.PO)(t)||(0,eT.cO)(t)?o=function(e,t,n,r){let i=(0,V.s3)(),o=i&&i.getOptions().normalizeDepth,s=function(e){for(let t in e)if(Object.prototype.hasOwnProperty.call(e,t)){let n=e[t];if(n instanceof Error)return n}}(t),a={__serialized__:(0,eh.Qy)(t,o)};if(s)return{exception:{values:[eI(e,s)]},extra:a};let c={exception:{values:[{type:(0,eT.cO)(t)?t.constructor.name:r?"UnhandledRejection":"Error",value:function(e,{isUnhandledRejection:t}){let n=(0,Y.zf)(e),r=t?"promise rejection":"exception";if((0,eT.VW)(e))return`Event \`ErrorEvent\` captured as ${r} with message \`${e.message}\``;if((0,eT.cO)(e)){let t=function(e){try{let t=Object.getPrototypeOf(e);return t?t.constructor.name:void 0}catch(e){}}(e);return`Event \`${t}\` (type=${e.type}) captured as ${r}`}return`Object captured as ${r} with keys: ${n}`}(t,{isUnhandledRejection:r})}]},extra:a};if(n){let t=eD(e,n);t.length&&(c.exception.values[0].stacktrace={frames:t})}return c}(e,t,n,i):(o=ej(e,t,n,r),(0,W.Db)(o,`${t}`,void 0)),(0,W.EG)(o,{synthetic:!0}),o)}function ej(e,t,n,r){let i={};if(r&&n){let r=eD(e,n);r.length&&(i.exception={values:[{value:t,stacktrace:{frames:r}}]}),(0,W.EG)(i,{synthetic:!0})}if((0,eT.Le)(t)){let{__sentry_template_string__:e,__sentry_template_values__:n}=t;return i.logentry={message:e,params:n},i}return i.message=t,i}let eU=M.GLOBAL_OBJ,e$=0;function eB(e,t={}){if("function"!=typeof e)return e;try{let t=e.__sentry_wrapped__;if(t){if("function"==typeof t)return t;return e}if((0,Y.HK)(e))return e}catch(t){return e}let n=function(...n){try{let r=n.map(e=>eB(e,t));return e.apply(this,r)}catch(e){throw e$++,setTimeout(()=>{e$--}),(0,V.$e)(r=>{r.addEventProcessor(e=>(t.mechanism&&((0,W.Db)(e,void 0,void 0),(0,W.EG)(e,t.mechanism)),e.extra={...e.extra,arguments:n},e)),(0,U.Tb)(e)}),e}};try{for(let t in e)Object.prototype.hasOwnProperty.call(e,t)&&(n[t]=e[t])}catch(e){}(0,Y.$Q)(n,e),(0,Y.xp)(e,"__sentry_wrapped__",n);try{Object.getOwnPropertyDescriptor(n,"name").configurable&&Object.defineProperty(n,"name",{get:()=>e.name})}catch(e){}return n}class eF extends eA{constructor(e){let t={parentSpanIsAlwaysRootSpan:!0,...e};j(t,"browser",["browser"],eU.SENTRY_SDK_SOURCE||"npm"),super(t),t.sendClientReports&&eU.document&&eU.document.addEventListener("visibilitychange",()=>{"hidden"===eU.document.visibilityState&&this._flushOutcomes()})}eventFromException(e,t){return function(e,t,n,r){let i=eL(e,t,n&&n.syntheticException||void 0,r);return(0,W.EG)(i),i.level="error",n&&n.event_id&&(i.event_id=n.event_id),(0,ew.WD)(i)}(this._options.stackParser,e,t,this._options.attachStacktrace)}eventFromMessage(e,t="info",n){return function(e,t,n="info",r,i){let o=ej(e,t,r&&r.syntheticException||void 0,i);return o.level=n,r&&r.event_id&&(o.event_id=r.event_id),(0,ew.WD)(o)}(this._options.stackParser,e,t,n,this._options.attachStacktrace)}captureUserFeedback(e){if(!this._isEnabled())return;let t=function(e,{metadata:t,tunnel:n,dsn:r}){return ef({event_id:e.event_id,sent_at:new Date().toISOString(),...t&&t.sdk&&{sdk:{name:t.sdk.name,version:t.sdk.version}},...!!n&&!!r&&{dsn:el(r)}},[[{type:"user_report"},e]])}(e,{metadata:this.getSdkMetadata(),dsn:this.getDsn(),tunnel:this.getOptions().tunnel});this.sendEnvelope(t)}_prepareEvent(e,t,n){return e.platform=e.platform||"javascript",super._prepareEvent(e,t,n)}}let eq={},eH={};function eW(e,t){eq[e]=eq[e]||[],eq[e].push(t)}function eG(e,t){if(!eH[e]){eH[e]=!0;try{t()}catch(t){ei.X&&B.kg.error(`Error while instrumenting ${e}`,t)}}}function ez(e,t){let n=e&&eq[e];if(n)for(let r of n)try{r(t)}catch(t){ei.X&&B.kg.error(`Error while triggering instrumentation handler. Type: ${e} Name: ${(0,Q.$P)(r)} Error:`,t)}}let eX=M.GLOBAL_OBJ;function eJ(e){eW("dom",e),eG("dom",eV)}function eV(){if(!eX.document)return;let e=ez.bind(null,"dom"),t=eY(e,!0);eX.document.addEventListener("click",t,!1),eX.document.addEventListener("keypress",t,!1),["EventTarget","Node"].forEach(t=>{let n=eX[t],r=n&&n.prototype;r&&r.hasOwnProperty&&r.hasOwnProperty("addEventListener")&&((0,Y.hl)(r,"addEventListener",function(t){return function(n,r,i){if("click"===n||"keypress"==n)try{let r=this.__sentry_instrumentation_handlers__=this.__sentry_instrumentation_handlers__||{},o=r[n]=r[n]||{refCount:0};if(!o.handler){let r=eY(e);o.handler=r,t.call(this,n,r,i)}o.refCount++}catch(e){}return t.call(this,n,r,i)}}),(0,Y.hl)(r,"removeEventListener",function(e){return function(t,n,r){if("click"===t||"keypress"==t)try{let n=this.__sentry_instrumentation_handlers__||{},i=n[t];i&&(i.refCount--,i.refCount<=0&&(e.call(this,t,i.handler,r),i.handler=void 0,delete n[t]),0===Object.keys(n).length&&delete this.__sentry_instrumentation_handlers__)}catch(e){}return e.call(this,t,n,r)}}))})}function eY(e,t=!1){return n=>{if(!n||n._sentryCaptured)return;let r=function(e){try{return e.target}catch(e){return null}}(n);if("keypress"===n.type&&(!r||!r.tagName||"INPUT"!==r.tagName&&"TEXTAREA"!==r.tagName&&!r.isContentEditable))return;(0,Y.xp)(n,"_sentryCaptured",!0),r&&!r._sentryId&&(0,Y.xp)(r,"_sentryId",(0,W.DM)());let a="keypress"===n.type?"input":n.type;!function(e){if(e.type!==o)return!1;try{if(!e.target||e.target._sentryId!==s)return!1}catch(e){}return!0}(n)&&(e({event:n,name:a,global:t}),o=n.type,s=r?r._sentryId:void 0),clearTimeout(i),i=eX.setTimeout(()=>{s=void 0,o=void 0},1e3)}}let eZ="__sentry_xhr_v3__";function eK(e){eW("xhr",e),eG("xhr",eQ)}function eQ(){if(!eX.XMLHttpRequest)return;let e=XMLHttpRequest.prototype;e.open=new Proxy(e.open,{apply(e,t,n){let r=Error(),i=1e3*(0,eb.ph)(),o=(0,eT.HD)(n[0])?n[0].toUpperCase():void 0,s=function(e){if((0,eT.HD)(e))return e;try{return e.toString()}catch(e){}}(n[1]);if(!o||!s)return e.apply(t,n);t[eZ]={method:o,url:s,request_headers:{}},"POST"===o&&s.match(/sentry_key/)&&(t.__sentry_own_request__=!0);let a=()=>{let e=t[eZ];if(e&&4===t.readyState){try{e.status_code=t.status}catch(e){}ez("xhr",{endTimestamp:1e3*(0,eb.ph)(),startTimestamp:i,xhr:t,virtualError:r})}};return"onreadystatechange"in t&&"function"==typeof t.onreadystatechange?t.onreadystatechange=new Proxy(t.onreadystatechange,{apply:(e,t,n)=>(a(),e.apply(t,n))}):t.addEventListener("readystatechange",a),t.setRequestHeader=new Proxy(t.setRequestHeader,{apply(e,t,n){let[r,i]=n,o=t[eZ];return o&&(0,eT.HD)(r)&&(0,eT.HD)(i)&&(o.request_headers[r.toLowerCase()]=i),e.apply(t,n)}}),e.apply(t,n)}}),e.send=new Proxy(e.send,{apply(e,t,n){let r=t[eZ];return r&&(void 0!==n[0]&&(r.body=n[0]),ez("xhr",{startTimestamp:1e3*(0,eb.ph)(),xhr:t})),e.apply(t,n)}})}let e0=M.GLOBAL_OBJ;function e1(e){let t="history";eW(t,e),eG(t,e2)}function e2(){if(!function(){let e=e0.chrome,t=e&&e.app&&e.app.runtime,n="history"in e0&&!!e0.history.pushState&&!!e0.history.replaceState;return!t&&n}())return;let e=eX.onpopstate;function t(e){return function(...t){let n=t.length>2?t[2]:void 0;if(n){let e=a,t=String(n);a=t,ez("history",{from:e,to:t})}return e.apply(this,t)}}eX.onpopstate=function(...t){let n=eX.location.href,r=a;if(a=n,ez("history",{from:r,to:n}),e)try{return e.apply(this,t)}catch(e){}},(0,Y.hl)(eX.history,"pushState",t),(0,Y.hl)(eX.history,"replaceState",t)}function e3(){"console"in M.GLOBAL_OBJ&&B.RU.forEach(function(e){e in M.GLOBAL_OBJ.console&&(0,Y.hl)(M.GLOBAL_OBJ.console,e,function(t){return B.LD[e]=t,function(...t){ez("console",{args:t,level:e});let n=B.LD[e];n&&n.apply(M.GLOBAL_OBJ.console,t)}})})}function e5(e,t){let n="fetch";eW(n,e),eG(n,()=>e4(void 0,t))}function e4(e,t=!1){(!t||function(){if("string"==typeof EdgeRuntime)return!0;if(!function(){if(!("fetch"in eo))return!1;try{return new Headers,new Request("http://www.example.com"),new Response,!0}catch(e){return!1}}())return!1;if(es(eo.fetch))return!0;let e=!1,t=eo.document;if(t&&"function"==typeof t.createElement)try{let n=t.createElement("iframe");n.hidden=!0,t.head.appendChild(n),n.contentWindow&&n.contentWindow.fetch&&(e=es(n.contentWindow.fetch)),t.head.removeChild(n)}catch(e){ei.X&&B.kg.warn("Could not create sandbox iframe for pure fetch check, bailing to window.fetch: ",e)}return e}())&&(0,Y.hl)(M.GLOBAL_OBJ,"fetch",function(t){return function(...n){let r=Error(),{method:i,url:o}=function(e){if(0===e.length)return{method:"GET",url:""};if(2===e.length){let[t,n]=e;return{url:e7(t),method:e9(n,"method")?String(n.method).toUpperCase():"GET"}}let t=e[0];return{url:e7(t),method:e9(t,"method")?String(t.method).toUpperCase():"GET"}}(n),s={args:n,fetchData:{method:i,url:o},startTimestamp:1e3*(0,eb.ph)(),virtualError:r};return e||ez("fetch",{...s}),t.apply(M.GLOBAL_OBJ,n).then(async t=>(e?e(t):ez("fetch",{...s,endTimestamp:1e3*(0,eb.ph)(),response:t}),t),e=>{throw ez("fetch",{...s,endTimestamp:1e3*(0,eb.ph)(),error:e}),(0,eT.VZ)(e)&&void 0===e.stack&&(e.stack=r.stack,(0,Y.xp)(e,"framesToPop",1)),e})}})}async function e6(e,t){if(e&&e.body){let n=e.body,r=n.getReader(),i=setTimeout(()=>{n.cancel().then(null,()=>{})},9e4),o=!0;for(;o;){let e;try{e=setTimeout(()=>{n.cancel().then(null,()=>{})},5e3);let{done:i}=await r.read();clearTimeout(e),i&&(t(),o=!1)}catch(e){o=!1}finally{clearTimeout(e)}}clearTimeout(i),r.releaseLock(),n.cancel().then(null,()=>{})}}function e8(e){let t;try{t=e.clone()}catch(e){return}e6(t,()=>{ez("fetch-body-resolved",{endTimestamp:1e3*(0,eb.ph)(),response:e})})}function e9(e,t){return!!e&&"object"==typeof e&&!!e[t]}function e7(e){return"string"==typeof e?e:e?e9(e,"url")?e.url:e.toString?e.toString():"":""}function te(e,t){let n=(0,V.s3)(),r=(0,V.aF)();if(!n)return;let{beforeBreadcrumb:i=null,maxBreadcrumbs:o=100}=n.getOptions();if(o<=0)return;let s={timestamp:(0,eb.yW)(),...e},a=i?(0,B.Cf)(()=>i(s,t)):s;null!==a&&(n.emit&&n.emit("beforeAddBreadcrumb",a,t),r.addBreadcrumb(a,o))}var tt=n(37389);function tn(e){if(void 0!==e)return e>=400&&e<500?"warning":e>=500?"error":void 0}function tr(e){if(!e)return{};let t=e.match(/^(([^:/?#]+):)?(\/\/([^/?#]*))?([^?#]*)(\?([^#]*))?(#(.*))?$/);if(!t)return{};let n=t[6]||"",r=t[8]||"";return{host:t[4],path:t[5],protocol:t[2],search:n,hash:r,relative:t[5]+n+r}}let ti=(e={})=>{let t={console:!0,dom:!0,fetch:!0,history:!0,sentry:!0,xhr:!0,...e};return{name:"Breadcrumbs",setup(e){var n;t.console&&function(e){let t="console";eW(t,e),eG(t,e3)}(function(t){var n;if((0,V.s3)()!==e)return;let r={category:"console",data:{arguments:t.args,logger:"console"},level:"warn"===(n=t.level)?"warning":["fatal","error","warning","log","info","debug"].includes(n)?n:"log",message:(0,G.nK)(t.args," ")};if("assert"===t.level){if(!1!==t.args[0])return;r.message=`Assertion failed: ${(0,G.nK)(t.args.slice(1)," ")||"console.assert"}`,r.data.arguments=t.args.slice(1)}te(r,{input:t.args,level:t.level})}),t.dom&&eJ((n=t.dom,function(t){let r,i;if((0,V.s3)()!==e)return;let o="object"==typeof n?n.serializeAttribute:void 0,s="object"==typeof n&&"number"==typeof n.maxStringLength?n.maxStringLength:void 0;s&&s>1024&&(s=1024),"string"==typeof o&&(o=[o]);try{let e=t.event,n=e&&e.target?e.target:e;r=(0,tt.Rt)(n,{keyAttrs:o,maxStringLength:s}),i=(0,tt.iY)(n)}catch(e){r=""}if(0===r.length)return;let a={category:`ui.${t.name}`,message:r};i&&(a.data={"ui.component_name":i}),te(a,{event:t.event,name:t.name,global:t.global})})),t.xhr&&eK(function(t){if((0,V.s3)()!==e)return;let{startTimestamp:n,endTimestamp:r}=t,i=t.xhr[eZ];if(!n||!r||!i)return;let{method:o,url:s,status_code:a,body:c}=i,l={xhr:t.xhr,input:c,startTimestamp:n,endTimestamp:r},u=tn(a);te({category:"xhr",data:{method:o,url:s,status_code:a},type:"http",level:u},l)}),t.fetch&&e5(function(t){if((0,V.s3)()!==e)return;let{startTimestamp:n,endTimestamp:r}=t;if(!(!r||t.fetchData.url.match(/sentry_key/)&&"POST"===t.fetchData.method)){if(t.error)te({category:"fetch",data:t.fetchData,level:"error",type:"http"},{data:t.error,input:t.args,startTimestamp:n,endTimestamp:r});else{let e=t.response,i={...t.fetchData,status_code:e&&e.status},o={input:t.args,response:e,startTimestamp:n,endTimestamp:r},s=tn(i.status_code);te({category:"fetch",data:i,type:"http",level:s},o)}}}),t.history&&e1(function(t){if((0,V.s3)()!==e)return;let n=t.from,r=t.to,i=tr(eU.location.href),o=n?tr(n):void 0,s=tr(r);o&&o.path||(o=i),i.protocol===s.protocol&&i.host===s.host&&(r=s.relative),i.protocol===o.protocol&&i.host===o.host&&(n=o.relative),te({category:"navigation",data:{from:n,to:r}})}),t.sentry&&e.on("beforeSendEvent",function(t){(0,V.s3)()===e&&te({category:`sentry.${"transaction"===t.type?"transaction":"event"}`,event_id:t.event_id,level:t.level,message:(0,W.jH)(t)},{event:t})})}}},to=["EventTarget","Window","Node","ApplicationCache","AudioTrackList","BroadcastChannel","ChannelMergerNode","CryptoOperation","EventSource","FileReader","HTMLUnknownElement","IDBDatabase","IDBRequest","IDBTransaction","KeyOperation","MediaController","MessagePort","ModalWindow","Notification","SVGElementInstance","Screen","SharedWorker","TextTrack","TextTrackCue","TextTrackList","WebSocket","WebSocketWorker","Worker","XMLHttpRequest","XMLHttpRequestEventTarget","XMLHttpRequestUpload"],ts=(e={})=>{let t={XMLHttpRequest:!0,eventTarget:!0,requestAnimationFrame:!0,setInterval:!0,setTimeout:!0,...e};return{name:"BrowserApiErrors",setupOnce(){t.setTimeout&&(0,Y.hl)(eU,"setTimeout",ta),t.setInterval&&(0,Y.hl)(eU,"setInterval",ta),t.requestAnimationFrame&&(0,Y.hl)(eU,"requestAnimationFrame",tc),t.XMLHttpRequest&&"XMLHttpRequest"in eU&&(0,Y.hl)(XMLHttpRequest.prototype,"send",tl);let e=t.eventTarget;e&&(Array.isArray(e)?e:to).forEach(tu)}}};function ta(e){return function(...t){let n=t[0];return t[0]=eB(n,{mechanism:{data:{function:(0,Q.$P)(e)},handled:!1,type:"instrument"}}),e.apply(this,t)}}function tc(e){return function(t){return e.apply(this,[eB(t,{mechanism:{data:{function:"requestAnimationFrame",handler:(0,Q.$P)(e)},handled:!1,type:"instrument"}})])}}function tl(e){return function(...t){let n=this;return["onload","onerror","onprogress","onreadystatechange"].forEach(e=>{e in n&&"function"==typeof n[e]&&(0,Y.hl)(n,e,function(t){let n={mechanism:{data:{function:e,handler:(0,Q.$P)(t)},handled:!1,type:"instrument"}},r=(0,Y.HK)(t);return r&&(n.mechanism.data.handler=(0,Q.$P)(r)),eB(t,n)})}),e.apply(this,t)}}function tu(e){let t=eU[e],n=t&&t.prototype;n&&n.hasOwnProperty&&n.hasOwnProperty("addEventListener")&&((0,Y.hl)(n,"addEventListener",function(t){return function(n,r,i){try{"function"==typeof r.handleEvent&&(r.handleEvent=eB(r.handleEvent,{mechanism:{data:{function:"handleEvent",handler:(0,Q.$P)(r),target:e},handled:!1,type:"instrument"}}))}catch(e){}return t.apply(this,[n,eB(r,{mechanism:{data:{function:"addEventListener",handler:(0,Q.$P)(r),target:e},handled:!1,type:"instrument"}}),i])}}),(0,Y.hl)(n,"removeEventListener",function(e){return function(t,n,r){try{let i=n.__sentry_wrapped__;i&&e.call(this,t,i,r)}catch(e){}return e.call(this,t,n,r)}}))}let td=()=>({name:"BrowserSession",setupOnce(){void 0!==eU.document&&((0,U.yj)({ignoreDuration:!0}),(0,U.cg)(),e1(({from:e,to:t})=>{void 0!==e&&e!==t&&((0,U.yj)({ignoreDuration:!0}),(0,U.cg)())}))}}),th=null;function tf(e){let t="error";eW(t,e),eG(t,tp)}function tp(){th=M.GLOBAL_OBJ.onerror,M.GLOBAL_OBJ.onerror=function(e,t,n,r,i){return ez("error",{column:r,error:i,line:n,msg:e,url:t}),!!th&&th.apply(this,arguments)},M.GLOBAL_OBJ.onerror.__SENTRY_INSTRUMENTED__=!0}let tm=null;function tg(e){let t="unhandledrejection";eW(t,e),eG(t,t_)}function t_(){tm=M.GLOBAL_OBJ.onunhandledrejection,M.GLOBAL_OBJ.onunhandledrejection=function(e){return ez("unhandledrejection",e),!tm||tm.apply(this,arguments)},M.GLOBAL_OBJ.onunhandledrejection.__SENTRY_INSTRUMENTED__=!0}let ty=(e={})=>{let t={onerror:!0,onunhandledrejection:!0,...e};return{name:"GlobalHandlers",setupOnce(){Error.stackTraceLimit=50},setup(e){t.onerror&&tf(t=>{let{stackParser:n,attachStacktrace:r}=tv();if((0,V.s3)()!==e||e$>0)return;let{msg:i,url:o,line:s,column:a,error:c}=t,l=function(e,t,n,r){let i=e.exception=e.exception||{},o=i.values=i.values||[],s=o[0]=o[0]||{},a=s.stacktrace=s.stacktrace||{},c=a.frames=a.frames||[],l=(0,eT.HD)(t)&&t.length>0?t:(0,tt.l4)();return 0===c.length&&c.push({colno:r,filename:l,function:Q.Fi,in_app:!0,lineno:n}),e}(eL(n,c||i,void 0,r,!1),o,s,a);l.level="error",(0,U.eN)(l,{originalException:c,mechanism:{handled:!1,type:"onerror"}})}),t.onunhandledrejection&&tg(t=>{let{stackParser:n,attachStacktrace:r}=tv();if((0,V.s3)()!==e||e$>0)return;let i=function(e){if((0,eT.pt)(e))return e;try{if("reason"in e)return e.reason;if("detail"in e&&"reason"in e.detail)return e.detail.reason}catch(e){}return e}(t),o=(0,eT.pt)(i)?{exception:{values:[{type:"UnhandledRejection",value:`Non-Error promise rejection captured with value: ${String(i)}`}]}}:eL(n,i,void 0,r,!0);o.level="error",(0,U.eN)(o,{originalException:i,mechanism:{handled:!1,type:"onunhandledrejection"}})})}}};function tv(){let e=(0,V.s3)();return e&&e.getOptions()||{stackParser:()=>[],attachStacktrace:!1}}let tE=()=>({name:"HttpContext",preprocessEvent(e){if(!eU.navigator&&!eU.location&&!eU.document)return;let t=e.request&&e.request.url||eU.location&&eU.location.href,{referrer:n}=eU.document||{},{userAgent:r}=eU.navigator||{},i={...e.request&&e.request.headers,...n&&{Referer:n},...r&&{"User-Agent":r}},o={...e.request,...t&&{url:t},headers:i};e.request=o}});function tb(e,t){e.mechanism=e.mechanism||{type:"generic",handled:!0},e.mechanism={...e.mechanism,..."AggregateError"===e.type&&{is_exception_group:!0},exception_id:t}}function tS(e,t,n,r){e.mechanism=e.mechanism||{type:"generic",handled:!0},e.mechanism={...e.mechanism,type:"chained",source:t,exception_id:n,parent_id:r}}let tT=(e={})=>{let t=e.limit||5,n=e.key||"cause";return{name:"LinkedErrors",preprocessEvent(e,r,i){let o=i.getOptions();!function(e,t,n=250,r,i,o,s){if(!o.exception||!o.exception.values||!s||!(0,eT.V9)(s.originalException,Error))return;let a=o.exception.values.length>0?o.exception.values[o.exception.values.length-1]:void 0;a&&(o.exception.values=(function e(t,n,r,i,o,s,a,c){if(s.length>=r+1)return s;let l=[...s];if((0,eT.V9)(i[o],Error)){tb(a,c);let s=t(n,i[o]),u=l.length;tS(s,o,u,c),l=e(t,n,r,i[o],o,[s,...l],s,u)}return Array.isArray(i.errors)&&i.errors.forEach((i,s)=>{if((0,eT.V9)(i,Error)){tb(a,c);let u=t(n,i),d=l.length;tS(u,`errors[${s}]`,d,c),l=e(t,n,r,i,o,[u,...l],u,d)}}),l})(e,t,i,s.originalException,r,o.exception.values,a,0).map(e=>(e.value&&(e.value=(0,G.$G)(e.value,n)),e)))}(eI,o.stackParser,o.maxValueLength,n,t,e,r)}}};function tw(e,t,n,r){let i={filename:e,function:""===t?Q.Fi:t,in_app:!0};return void 0!==n&&(i.lineno=n),void 0!==r&&(i.colno=r),i}let tO=/^\s*at (\S+?)(?::(\d+))(?::(\d+))\s*$/i,tC=/^\s*at (?:(.+?\)(?: \[.+\])?|.*?) ?\((?:address at )?)?(?:async )?((?:|[-a-z]+:|.*bundle|\/)?.*?)(?::(\d+))?(?::(\d+))?\)?\s*$/i,tR=/\((\S*)(?::(\d+))(?::(\d+))\)/,tA=[30,e=>{let t=tO.exec(e);if(t){let[,e,n,r]=t;return tw(e,Q.Fi,+n,+r)}let n=tC.exec(e);if(n){if(n[2]&&0===n[2].indexOf("eval")){let e=tR.exec(n[2]);e&&(n[2]=e[1],n[3]=e[2],n[4]=e[3])}let[e,t]=tD(n[1]||Q.Fi,n[2]);return tw(t,e,n[3]?+n[3]:void 0,n[4]?+n[4]:void 0)}}],tk=/^\s*(.*?)(?:\((.*?)\))?(?:^|@)?((?:[-a-z]+)?:\/.*?|\[native code\]|[^@]*(?:bundle|\d+\.js)|\/[\w\-. /=]+)(?::(\d+))?(?::(\d+))?\s*$/i,tN=/(\S+) line (\d+)(?: > eval line \d+)* > eval/i,tI=[50,e=>{let t=tk.exec(e);if(t){if(t[3]&&t[3].indexOf(" > eval")>-1){let e=tN.exec(t[3]);e&&(t[1]=t[1]||"eval",t[3]=e[1],t[4]=e[2],t[5]="")}let e=t[3],n=t[1]||Q.Fi;return[n,e]=tD(n,e),tw(e,n,t[4]?+t[4]:void 0,t[5]?+t[5]:void 0)}}],tx=(0,Q.pE)(tA,tI),tD=(e,t)=>{let n=-1!==e.indexOf("safari-extension"),r=-1!==e.indexOf("safari-web-extension");return n||r?[-1!==e.indexOf("@")?e.split("@")[0]:Q.Fi,n?`safari-extension:${t}`:`safari-web-extension:${t}`]:[e,t]},tP={};function tM(e){let t=tP[e];if(t)return t;let n=eX[e];if(es(n))return tP[e]=n.bind(eX);let r=eX.document;if(r&&"function"==typeof r.createElement)try{let t=r.createElement("iframe");t.hidden=!0,r.head.appendChild(t);let i=t.contentWindow;i&&i[e]&&(n=i[e]),r.head.removeChild(t)}catch(e){}return n?tP[e]=n.bind(eX):n}function tL(...e){return tM("setTimeout")(...e)}function tj(e,t,n=Date.now()){return(e[t]||e.all||0)>n}function tU(e,{statusCode:t,headers:n},r=Date.now()){let i={...e},o=n&&n["x-sentry-rate-limits"],s=n&&n["retry-after"];if(o)for(let e of o.trim().split(",")){let[t,n,,,o]=e.split(":",5),s=parseInt(t,10),a=(isNaN(s)?60:s)*1e3;if(n)for(let e of n.split(";"))"metric_bucket"===e?(!o||o.split(";").includes("custom"))&&(i[e]=r+a):i[e]=r+a;else i.all=r+a}else s?i.all=r+function(e,t=Date.now()){let n=parseInt(`${e}`,10);if(!isNaN(n))return 1e3*n;let r=Date.parse(`${e}`);return isNaN(r)?6e4:r-t}(s,r):429===t&&(i.all=r+6e4);return i}function t$(e,t){if("event"===t||"transaction"===t)return Array.isArray(e)?e[1]:void 0}function tB(e,t=tM("fetch")){let n=0,r=0;return function(e,t,n=function(e){let t=[];function n(e){return t.splice(t.indexOf(e),1)[0]||Promise.resolve(void 0)}return{$:t,add:function(r){if(!(void 0===e||t.lengthn(i)).then(null,()=>n(i).then(null,()=>{})),i},drain:function(e){return new ew.cW((n,r)=>{let i=t.length;if(!i)return n(!0);let o=setTimeout(()=>{e&&e>0&&n(!1)},e);t.forEach(e=>{(0,ew.WD)(e).then(()=>{--i||(clearTimeout(o),n(!0))},r)})})}}}(e.bufferSize||64)){let r={};return{send:function(i){let o=[];if(ep(i,(t,n)=>{let i=eg[n];if(tj(r,i)){let r=t$(t,n);e.recordDroppedEvent("ratelimit_backoff",i,r)}else o.push(t)}),0===o.length)return(0,ew.WD)({});let s=ef(i[0],o),a=t=>{ep(s,(n,r)=>{let i=t$(n,r);e.recordDroppedEvent(t,eg[r],i)})};return n.add(()=>t({body:function(e){let[t,n]=e,r=JSON.stringify(t);function i(e){"string"==typeof r?r="string"==typeof e?r+e:[em(r),e]:r.push("string"==typeof e?em(e):e)}for(let e of n){let[t,n]=e;if(i(` ${JSON.stringify(t)} `),"string"==typeof n||n instanceof Uint8Array)i(n);else{let e;try{e=JSON.stringify(n)}catch(t){e=JSON.stringify((0,eh.Fv)(n))}i(e)}}return"string"==typeof r?r:function(e){let t=new Uint8Array(e.reduce((e,t)=>e+t.length,0)),n=0;for(let r of e)t.set(r,n),n+=r.length;return t}(r)}(s)}).then(e=>(void 0!==e.statusCode&&(e.statusCode<200||e.statusCode>=300)&&$.X&&B.kg.warn(`Sentry responded with status code ${e.statusCode} to sent event.`),r=tU(r,e),e),e=>{throw a("network_error"),e})).then(e=>e,e=>{if(e instanceof eS)return $.X&&B.kg.error("Skipped sending event because buffer is full."),a("queue_overflow"),(0,ew.WD)({});throw e})},flush:e=>n.drain(e)}}(e,function(i){let o=i.body.length;n+=o,r++;let s={body:i.body,method:"POST",referrerPolicy:"origin",headers:e.headers,keepalive:n<=6e4&&r<15,...e.fetchOptions};if(!t)return tP.fetch=void 0,(0,ew.$2)("No fetch implementation available");try{return t(e.url,s).then(e=>(n-=o,r--,{statusCode:e.status,headers:{"x-sentry-rate-limits":e.headers.get("X-Sentry-Rate-Limits"),"retry-after":e.headers.get("Retry-After")}}))}catch(e){return tP.fetch=void 0,n-=o,r--,(0,ew.$2)(e)}})}function tF(e){let t=[X(),K(),ts(),ti(),ty(),tT(),ee(),tE()];return!1!==e.autoSessionTracking&&t.push(td()),t}var tq=n(75271),tH=n(12509),tW=n(95503);function tG(e){if(!e||0===e.length)return;let t={};return e.forEach(e=>{let n=e.attributes||{},r=n[tW.E1],i=n[tW.Wb];"string"==typeof r&&"number"==typeof i&&(t[e.name]={value:i,unit:r})}),t}let tz=(e,t)=>e>t[1]?"poor":e>t[0]?"needs-improvement":"good",tX=(e,t,n,r)=>{let i,o;return s=>{t.value>=0&&(s||r)&&((o=t.value-(i||0))||void 0===i)&&(i=t.value,t.delta=o,t.rating=tz(t.value,n),e(t))}},tJ=()=>`v4-${Date.now()}-${Math.floor(Math.random()*(9e12-1))+1e12}`,tV=(e=!0)=>{let t=eX.performance&&eX.performance.getEntriesByType&&eX.performance.getEntriesByType("navigation")[0];if(!e||t&&t.responseStart>0&&t.responseStart{let e=tV();return e&&e.activationStart||0},tZ=(e,t)=>{let n=tV(),r="navigate";return n&&(eX.document&&eX.document.prerendering||tY()>0?r="prerender":eX.document&&eX.document.wasDiscarded?r="restore":n.type&&(r=n.type.replace(/_/g,"-"))),{name:e,value:void 0===t?-1:t,rating:"good",delta:0,entries:[],id:tJ(),navigationType:r}},tK=(e,t,n)=>{try{if(PerformanceObserver.supportedEntryTypes.includes(e)){let r=new PerformanceObserver(e=>{Promise.resolve().then(()=>{t(e.getEntries())})});return r.observe(Object.assign({type:e,buffered:!0},n||{})),r}}catch(e){}},tQ=e=>{let t=t=>{("pagehide"===t.type||eX.document&&"hidden"===eX.document.visibilityState)&&e(t)};eX.document&&(addEventListener("visibilitychange",t,!0),addEventListener("pagehide",t,!0))},t0=e=>{let t=!1;return()=>{t||(e(),t=!0)}},t1=-1,t2=()=>"hidden"!==eX.document.visibilityState||eX.document.prerendering?1/0:0,t3=e=>{"hidden"===eX.document.visibilityState&&t1>-1&&(t1="visibilitychange"===e.type?e.timeStamp:0,t4())},t5=()=>{addEventListener("visibilitychange",t3,!0),addEventListener("prerenderingchange",t3,!0)},t4=()=>{removeEventListener("visibilitychange",t3,!0),removeEventListener("prerenderingchange",t3,!0)},t6=()=>(eX.document&&t1<0&&(t1=t2(),t5()),{get firstHiddenTime(){return t1}}),t8=e=>{eX.document&&eX.document.prerendering?addEventListener("prerenderingchange",()=>e(),!0):e()},t9=[1800,3e3],t7=(e,t={})=>{t8(()=>{let n;let r=t6(),i=tZ("FCP"),o=tK("paint",e=>{e.forEach(e=>{"first-contentful-paint"===e.name&&(o.disconnect(),e.startTime{t7(t0(()=>{let n;let r=tZ("CLS",0),i=0,o=[],s=e=>{e.forEach(e=>{if(!e.hadRecentInput){let t=o[0],n=o[o.length-1];i&&t&&n&&e.startTime-n.startTime<1e3&&e.startTime-t.startTime<5e3?(i+=e.value,o.push(e)):(i=e.value,o=[e])}}),i>r.value&&(r.value=i,r.entries=o,n())},a=tK("layout-shift",s);a&&(n=tX(e,r,ne,t.reportAllChanges),tQ(()=>{s(a.takeRecords()),n(!0)}),setTimeout(n,0))}))},nn=[100,300],nr=(e,t={})=>{t8(()=>{let n;let r=t6(),i=tZ("FID"),o=e=>{e.startTime{e.forEach(o)},a=tK("first-input",s);n=tX(e,i,nn,t.reportAllChanges),a&&tQ(t0(()=>{s(a.takeRecords()),a.disconnect()}))})},ni=0,no=1/0,ns=0,na=e=>{e.forEach(e=>{e.interactionId&&(no=Math.min(no,e.interactionId),ni=(ns=Math.max(ns,e.interactionId))?(ns-no)/7+1:0)})},nc=()=>c?ni:performance.interactionCount||0,nl=()=>{"interactionCount"in performance||c||(c=tK("event",na,{type:"event",buffered:!0,durationThreshold:0}))},nu=[],nd=new Map,nh=()=>nc()-0,nf=()=>{let e=Math.min(nu.length-1,Math.floor(nh()/50));return nu[e]},np=[],nm=e=>{if(np.forEach(t=>t(e)),!(e.interactionId||"first-input"===e.entryType))return;let t=nu[nu.length-1],n=nd.get(e.interactionId);if(n||nu.length<10||t&&e.duration>t.latency){if(n)e.duration>n.latency?(n.entries=[e],n.latency=e.duration):e.duration===n.latency&&e.startTime===(n.entries[0]&&n.entries[0].startTime)&&n.entries.push(e);else{let t={id:e.interactionId,latency:e.duration,entries:[e]};nd.set(t.id,t),nu.push(t)}nu.sort((e,t)=>t.latency-e.latency),nu.length>10&&nu.splice(10).forEach(e=>nd.delete(e.id))}},ng=e=>{let t=eX.requestIdleCallback||eX.setTimeout,n=-1;return e=t0(e),eX.document&&"hidden"===eX.document.visibilityState?e():(n=t(e),tQ(e)),n},n_=[200,500],ny=(e,t={})=>{"PerformanceEventTiming"in eX&&"interactionId"in PerformanceEventTiming.prototype&&t8(()=>{let n;nl();let r=tZ("INP"),i=e=>{ng(()=>{e.forEach(nm);let t=nf();t&&t.latency!==r.value&&(r.value=t.latency,r.entries=t.entries,n())})},o=tK("event",i,{durationThreshold:null!=t.durationThreshold?t.durationThreshold:40});n=tX(e,r,n_,t.reportAllChanges),o&&(o.observe({type:"first-input",buffered:!0}),tQ(()=>{i(o.takeRecords()),n(!0)}))})},nv=[2500,4e3],nE={},nb=(e,t={})=>{t8(()=>{let n;let r=t6(),i=tZ("LCP"),o=e=>{t.reportAllChanges||(e=e.slice(-1)),e.forEach(e=>{e.startTime{nE[i.id]||(o(s.takeRecords()),s.disconnect(),nE[i.id]=!0,n(!0))});["keydown","click"].forEach(e=>{eX.document&&addEventListener(e,()=>ng(r),{once:!0,capture:!0})}),tQ(r)}})},nS=[800,1800],nT=e=>{eX.document&&eX.document.prerendering?t8(()=>nT(e)):eX.document&&"complete"!==eX.document.readyState?addEventListener("load",()=>nT(e),!0):setTimeout(e,0)},nw=(e,t={})=>{let n=tZ("TTFB"),r=tX(e,n,nS,t.reportAllChanges);nT(()=>{let e=tV();e&&(n.value=Math.max(e.responseStart-tY(),0),n.entries=[e],r(!0))})},nO={},nC={};function nR(e,t=!1){return nU("cls",e,nD,l,t)}function nA(e,t=!1){return nU("lcp",e,nM,d,t)}function nk(e){return nU("fid",e,nP,u)}function nN(e){return nU("inp",e,nj,f)}function nI(e,t){return n$(e,t),nC[e]||(function(e){let t={};"event"===e&&(t.durationThreshold=0),tK(e,t=>{nx(e,{entries:t})},t)}(e),nC[e]=!0),nB(e,t)}function nx(e,t){let n=nO[e];if(n&&n.length)for(let e of n)try{e(t)}catch(e){}}function nD(){return nt(e=>{nx("cls",{metric:e}),l=e},{reportAllChanges:!0})}function nP(){return nr(e=>{nx("fid",{metric:e}),u=e})}function nM(){return nb(e=>{nx("lcp",{metric:e}),d=e},{reportAllChanges:!0})}function nL(){return nw(e=>{nx("ttfb",{metric:e}),h=e})}function nj(){return ny(e=>{nx("inp",{metric:e}),f=e})}function nU(e,t,n,r,i=!1){let o;return n$(e,t),nC[e]||(o=n(),nC[e]=!0),r&&t({metric:r}),nB(e,t,i?o:void 0)}function n$(e,t){nO[e]=nO[e]||[],nO[e].push(t)}function nB(e,t,n){return()=>{n&&n();let r=nO[e];if(!r)return;let i=r.indexOf(t);-1!==i&&r.splice(i,1)}}var nF=n(53290),nq=n(46926),nH=n(8845),nW=n(39960),nG=n(42370);class nz{constructor(e={}){this._traceId=e.traceId||(0,nG.Ht)(),this._spanId=e.spanId||(0,nG.M)()}spanContext(){return{spanId:this._spanId,traceId:this._traceId,traceFlags:ev.ve}}end(e){}setAttribute(e,t){return this}setAttributes(e){return this}setStatus(e){return this}updateName(e){return this}isRecording(){return!1}addEvent(e,t,n){return this}addLink(e){return this}addLinks(e){return this}recordException(e,t){}}var nX=n(94637);let nJ="_sentryScope",nV="_sentryIsolationScope";function nY(e){return{scope:e[nJ],isolationScope:e[nV]}}class nZ{constructor(e={}){this._traceId=e.traceId||(0,nG.Ht)(),this._spanId=e.spanId||(0,nG.M)(),this._startTime=e.startTimestamp||(0,eb.ph)(),this._attributes={},this.setAttributes({[tW.S3]:"manual",[tW.$J]:e.op,...e.attributes}),this._name=e.name,e.parentSpanId&&(this._parentSpanId=e.parentSpanId),"sampled"in e&&(this._sampled=e.sampled),e.endTimestamp&&(this._endTime=e.endTimestamp),this._events=[],this._isStandaloneSpan=e.isStandalone,this._endTime&&this._onSpanEnded()}addLink(e){return this}addLinks(e){return this}recordException(e,t){}spanContext(){let{_spanId:e,_traceId:t,_sampled:n}=this;return{spanId:e,traceId:t,traceFlags:n?ev.i0:ev.ve}}setAttribute(e,t){return void 0===t?delete this._attributes[e]:this._attributes[e]=t,this}setAttributes(e){return Object.keys(e).forEach(t=>this.setAttribute(t,e[t])),this}updateStartTime(e){this._startTime=(0,ev.$k)(e)}setStatus(e){return this._status=e,this}updateName(e){return this._name=e,this.setAttribute(tW.Zj,"custom"),this}end(e){this._endTime||(this._endTime=(0,ev.$k)(e),function(e){if(!$.X)return;let{description:t="< unknown name >",op:n="< unknown op >"}=(0,ev.XU)(e),{spanId:r}=e.spanContext(),i=(0,ev.Gx)(e)===e,o=`[Tracing] Finishing "${n}" ${i?"root ":""}span "${t}" with ID ${r}`;B.kg.log(o)}(this),this._onSpanEnded())}getSpanJSON(){return(0,Y.Jr)({data:this._attributes,description:this._name,op:this._attributes[tW.$J],parent_span_id:this._parentSpanId,span_id:this._spanId,start_timestamp:this._startTime,status:(0,ev._4)(this._status),timestamp:this._endTime,trace_id:this._traceId,origin:this._attributes[tW.S3],_metrics_summary:(0,nX.y)(this),profile_id:this._attributes[tW.p6],exclusive_time:this._attributes[tW.JQ],measurements:tG(this._events),is_segment:this._isStandaloneSpan&&(0,ev.Gx)(this)===this||void 0,segment_id:this._isStandaloneSpan?(0,ev.Gx)(this).spanContext().spanId:void 0})}isRecording(){return!this._endTime&&!!this._sampled}addEvent(e,t,n){$.X&&B.kg.log("[Tracing] Adding an event to span:",e);let r=nK(t)?t:n||(0,eb.ph)(),i=nK(t)?{}:t||{},o={name:e,time:(0,ev.$k)(r),attributes:i};return this._events.push(o),this}isStandaloneSpan(){return!!this._isStandaloneSpan}_onSpanEnded(){let e=(0,V.s3)();if(e&&e.emit("spanEnd",this),!(this._isStandaloneSpan||this===(0,ev.Gx)(this)))return;if(this._isStandaloneSpan){this._sampled?function(e){let t=(0,V.s3)();if(!t)return;let n=e[1];if(!n||0===n.length){t.recordDroppedEvent("before_send","span");return}t.sendEnvelope(e)}(function(e,t){let n=(0,ea.jC)(e[0]),r=t&&t.getDsn(),i=t&&t.getOptions().tunnel,o={sent_at:new Date().toISOString(),...!!n.trace_id&&!!n.public_key&&{trace:n},...!!i&&r&&{dsn:el(r)}},s=t&&t.getOptions().beforeSendSpan,a=s?e=>{let t=s((0,ev.XU)(e));return t||(0,ev.R6)(),t}:e=>(0,ev.XU)(e),c=[];for(let t of e){let e=a(t);e&&c.push([{type:"span"},e])}return ef(o,c)}([this],e)):($.X&&B.kg.log("[Tracing] Discarding standalone span because its trace was not chosen to be sampled."),e&&e.recordDroppedEvent("sample_rate","span"));return}let t=this._convertSpanToTransaction();t&&(nY(this).scope||(0,V.nZ)()).captureEvent(t)}_convertSpanToTransaction(){if(!nQ((0,ev.XU)(this)))return;this._name||($.X&&B.kg.warn("Transaction has no name, falling back to ``."),this._name="");let{scope:e,isolationScope:t}=nY(this),n=(e||(0,V.nZ)()).getClient()||(0,V.s3)();if(!0!==this._sampled){$.X&&B.kg.log("[Tracing] Discarding transaction because its trace was not chosen to be sampled."),n&&n.recordDroppedEvent("sample_rate","transaction");return}let r=(0,ev.Dp)(this).filter(e=>e!==this&&!(e instanceof nZ&&e.isStandaloneSpan())).map(e=>(0,ev.XU)(e)).filter(nQ),i=this._attributes[tW.Zj],o={contexts:{trace:(0,ev.HR)(this)},spans:r.length>1e3?r.sort((e,t)=>e.start_timestamp-t.start_timestamp).slice(0,1e3):r,start_timestamp:this._startTime,timestamp:this._endTime,transaction:this._name,type:"transaction",sdkProcessingMetadata:{capturedSpanScope:e,capturedSpanIsolationScope:t,...(0,Y.Jr)({dynamicSamplingContext:(0,ea.jC)(this)})},_metrics_summary:(0,nX.y)(this),...i&&{transaction_info:{source:i}}},s=tG(this._events);return s&&Object.keys(s).length&&($.X&&B.kg.log("[Measurements] Adding measurements to transaction event",JSON.stringify(s,void 0,2)),o.measurements=s),o}}function nK(e){return e&&"number"==typeof e||e instanceof Date||Array.isArray(e)}function nQ(e){return!!e.start_timestamp&&!!e.timestamp&&!!e.span_id&&!!e.trace_id}let n0="__SENTRY_SUPPRESS_TRACING__";function n1(e){let t=n3();if(t.startInactiveSpan)return t.startInactiveSpan(e);let n=function(e){let t={isStandalone:(e.experimental||{}).standalone,...e};if(e.startTime){let n={...t};return n.startTimestamp=(0,ev.$k)(e.startTime),delete n.startTime,n}return t}(e),{forceTransaction:r,parentSpan:i}=e;return(e.scope?t=>(0,V.$e)(e.scope,t):void 0!==i?e=>n2(i,e):e=>e())(()=>{let t=(0,V.nZ)(),i=function(e){let t=(0,nW.Y)(e);if(!t)return;let n=(0,V.s3)();return(n?n.getOptions():{}).parentSpanIsAlwaysRootSpan?(0,ev.Gx)(t):t}(t);return e.onlyIfParent&&!i?new nz:function({parentSpan:e,spanArguments:t,forceTransaction:n,scope:r}){var i;let o;if(!(0,nH.z)())return new nz;let s=(0,V.aF)();if(e&&!n)o=function(e,t,n){let{spanId:r,traceId:i}=e.spanContext(),o=!t.getScopeData().sdkProcessingMetadata[n0]&&(0,ev.Tt)(e),s=o?new nZ({...n,parentSpanId:r,traceId:i,sampled:o}):new nz({traceId:i});(0,ev.j5)(e,s);let a=(0,V.s3)();return a&&(a.emit("spanStart",s),n.endTimestamp&&a.emit("spanEnd",s)),s}(e,r,t),(0,ev.j5)(e,o);else if(e){let n=(0,ea.jC)(e),{traceId:i,spanId:s}=e.spanContext(),a=(0,ev.Tt)(e);o=n5({traceId:i,parentSpanId:s,...t},r,a),(0,ea.Lh)(o,n)}else{let{traceId:e,dsc:n,parentSpanId:i,sampled:a}={...s.getPropagationContext(),...r.getPropagationContext()};o=n5({traceId:e,parentSpanId:i,...t},r,a),n&&(0,ea.Lh)(o,n)}return function(e){if(!$.X)return;let{description:t="< unknown name >",op:n="< unknown op >",parent_span_id:r}=(0,ev.XU)(e),{spanId:i}=e.spanContext(),o=(0,ev.Tt)(e),s=(0,ev.Gx)(e),a=s===e,c=`[Tracing] Starting ${o?"sampled":"unsampled"} ${a?"root ":""}span`,l=[`op: ${n}`,`name: ${t}`,`ID: ${i}`];if(r&&l.push(`parent ID: ${r}`),!a){let{op:e,description:t}=(0,ev.XU)(s);l.push(`root ID: ${s.spanContext().spanId}`),e&&l.push(`root op: ${e}`),t&&l.push(`root description: ${t}`)}B.kg.log(`${c} ${l.join("\n ")}`)}(o),(i=o)&&((0,Y.xp)(i,nV,s),(0,Y.xp)(i,nJ,r)),o}({parentSpan:i,spanArguments:n,forceTransaction:r,scope:t})})}function n2(e,t){let n=n3();return n.withActiveSpan?n.withActiveSpan(e,t):(0,V.$e)(n=>((0,nW.D)(n,e||void 0),t(n)))}function n3(){let e=(0,nF.c)();return(0,nq.G)(e)}function n5(e,t,n){let r=(0,V.s3)(),i=r&&r.getOptions()||{},{name:o="",attributes:s}=e,[a,c]=t.getScopeData().sdkProcessingMetadata[n0]?[!1]:function(e,t){let n;if(!(0,nH.z)(e))return[!1];let r=eO(n="function"==typeof e.tracesSampler?e.tracesSampler(t):void 0!==t.parentSampled?t.parentSampled:void 0!==e.tracesSampleRate?e.tracesSampleRate:1);return void 0===r?($.X&&B.kg.warn("[Tracing] Discarding transaction because of invalid sample rate."),[!1]):r?Math.random()t&&"function"==typeof e.updateStartTime&&e.updateStartTime(t),n2(e,()=>{let e=n1({startTime:t,...r});return e&&e.end(n),e})}function n8(e){let t;let n=(0,V.s3)();if(!n)return;let{name:r,transaction:i,attributes:o,startTime:s}=e,{release:a,environment:c}=n.getOptions(),l=n.getIntegrationByName("Replay"),u=l&&l.getReplayId(),d=(0,V.nZ)(),h=d.getUser(),f=void 0!==h?h.email||h.id||h.ip_address:void 0;try{t=d.getScopeData().contexts.profile.profile_id}catch(e){}return n1({name:r,attributes:{release:a,environment:c,user:f||void 0,profile_id:t||void 0,replay_id:u||void 0,transaction:i,"user_agent.original":eX.navigator&&eX.navigator.userAgent,...o},startTime:s,experimental:{standalone:!0}})}function n9(){return eX&&eX.addEventListener&&eX.performance}function n7(e){return e/1e3}let re=0,rt={};function rn(e,t,n,r,i=n){let o=t["secureConnection"===n?"connectEnd":"fetch"===n?"domainLookupStart":`${n}End`],s=t[`${n}Start`];s&&o&&n6(e,r+n7(s),r+n7(o),{op:`browser.${i}`,name:t.name,attributes:{[tW.S3]:"auto.ui.browser.metrics"}})}function rr(e,t,n,r){let i=t[n];null!=i&&i<2147483647&&(e[r]=i)}let ri=[],ro=new Map,rs={click:"click",pointerdown:"click",pointerup:"click",mousedown:"click",mouseup:"click",touchstart:"click",touchend:"click",mouseover:"hover",mouseout:"hover",mouseenter:"hover",mouseleave:"hover",pointerover:"hover",pointerout:"hover",pointerenter:"hover",pointerleave:"hover",dragstart:"drag",dragend:"drag",drag:"drag",dragenter:"drag",dragleave:"drag",dragover:"drag",drop:"drag",keydown:"press",keyup:"press",keypress:"press",input:"press"};var ra=n(18225);let rc={idleTimeout:1e3,finalTimeout:3e4,childSpanTimeout:15e3};function rl(e,t={}){let n;let r=new Map,i=!1,o="externalFinish",s=!t.disableAutoFinish,a=[],{idleTimeout:c=rc.idleTimeout,finalTimeout:l=rc.finalTimeout,childSpanTimeout:u=rc.childSpanTimeout,beforeSpanEnd:d}=t,h=(0,V.s3)();if(!h||!(0,nH.z)())return new nz;let f=(0,V.nZ)(),p=(0,ev.HN)(),m=function(e){let t=n1(e);return(0,nW.D)((0,V.nZ)(),t),$.X&&B.kg.log("[Tracing] Started span is an idle span"),t}(e);function g(){n&&(clearTimeout(n),n=void 0)}function _(e){g(),n=setTimeout(()=>{!i&&0===r.size&&s&&(o="idleTimeout",m.end(e))},c)}function y(e){n=setTimeout(()=>{!i&&s&&(o="heartbeatFailed",m.end(e))},u)}function v(e){i=!0,r.clear(),a.forEach(e=>e()),(0,nW.D)(f,p);let t=(0,ev.XU)(m),{start_timestamp:n}=t;if(!n)return;(t.data||{})[tW.ju]||m.setAttribute(tW.ju,o),B.kg.log(`[Tracing] Idle span "${t.op}" finished`);let s=(0,ev.Dp)(m).filter(e=>e!==m),u=0;s.forEach(t=>{t.isRecording()&&(t.setStatus({code:ra.jt,message:"cancelled"}),t.end(e),$.X&&B.kg.log("[Tracing] Cancelling span since span ended early",JSON.stringify(t,void 0,2)));let{timestamp:n=0,start_timestamp:r=0}=(0,ev.XU)(t),i=r<=e,o=n-r<=(l+c)/1e3;if($.X){let e=JSON.stringify(t,void 0,2);i?o||B.kg.log("[Tracing] Discarding span since it finished after idle span final timeout",e):B.kg.log("[Tracing] Discarding span since it happened after idle span was finished",e)}(!o||!i)&&((0,ev.ed)(m,t),u++)}),u>0&&m.setAttribute("sentry.idle_span_discarded_spans",u)}return m.end=new Proxy(m.end,{apply(e,t,n){d&&d(m);let[r,...i]=n,o=r||(0,eb.ph)(),s=(0,ev.$k)(o),a=(0,ev.Dp)(m).filter(e=>e!==m);if(!a.length)return v(s),Reflect.apply(e,t,[s,...i]);let c=a.map(e=>(0,ev.XU)(e).timestamp).filter(e=>!!e),u=c.length?Math.max(...c):void 0,h=(0,ev.XU)(m).start_timestamp,f=Math.min(h?h+l/1e3:1/0,Math.max(h||-1/0,Math.min(s,u||1/0)));return v(f),Reflect.apply(e,t,[f,...i])}}),a.push(h.on("spanStart",e=>{if(!i&&e!==m&&!(0,ev.XU)(e).timestamp&&(0,ev.Dp)(m).includes(e)){var t;t=e.spanContext().spanId,g(),r.set(t,!0),y((0,eb.ph)()+u/1e3)}})),a.push(h.on("spanEnd",e=>{var t;i||(t=e.spanContext().spanId,r.has(t)&&r.delete(t),0===r.size&&_((0,eb.ph)()+c/1e3))})),a.push(h.on("idleSpanEnableAutoFinish",e=>{e===m&&(s=!0,_(),r.size&&y())})),t.disableAutoFinish||_(),setTimeout(()=>{i||(m.setStatus({code:ra.jt,message:"deadline_exceeded"}),o="finalTimeout",m.end())},l),m}let ru=!1;function rd(){let e=(0,ev.HN)(),t=e&&(0,ev.Gx)(e);if(t){let e="internal_error";$.X&&B.kg.log(`[Tracing] Root span: ${e} -> Global error occurred`),t.setStatus({code:ra.jt,message:e})}}rd.tag="sentry_tracingErrorCallback";var rh=n(54310),rf=n(70600);function rp(e={}){let t=(0,V.s3)();if(!(0,U._k)()||!t)return{};let n=(0,nF.c)(),r=(0,nq.G)(n);if(r.getTraceData)return r.getTraceData(e);let i=(0,V.nZ)(),o=e.span||(0,ev.HN)(),s=o?(0,ev.Hb)(o):function(e){let{traceId:t,sampled:n,spanId:r}=e.getPropagationContext();return(0,rh.$p)(t,r,n)}(i),a=o?(0,ea.jC)(o):(0,ea.CG)(t,i),c=(0,rf.IQ)(a);return rh.Ke.test(s)?{"sentry-trace":s,baggage:c}:(B.kg.warn("Invalid sentry-trace data. Cannot generate trace data"),{})}function rm(e){return e.split(",").filter(e=>!e.split("=")[0].startsWith(rf.lq)).join(",")}let rg=new WeakMap,r_=new Map,ry={traceFetch:!0,traceXHR:!0,enableHTTPTimings:!0,trackFetchStreamPerformance:!1};function rv(e){let{url:t}=(0,ev.XU)(e).data||{};if(!t||"string"!=typeof t)return;let n=nI("resource",({entries:r})=>{r.forEach(r=>{"resource"===r.entryType&&"initiatorType"in r&&"string"==typeof r.nextHopProtocol&&("fetch"===r.initiatorType||"xmlhttprequest"===r.initiatorType)&&r.name.endsWith(t)&&((function(e){let{name:t,version:n}=function(e){let t="unknown",n="unknown",r="";for(let i of e){if("/"===i){[t,n]=e.split("/");break}if(!isNaN(Number(i))){t="h"===r?"http":r,n=e.split(r)[1];break}r+=i}return r===e&&(t=r),{name:t,version:n}}(e.nextHopProtocol),r=[];return(r.push(["network.protocol.version",n],["network.protocol.name",t]),eb.Z1)?[...r,["http.request.redirect_start",rE(e.redirectStart)],["http.request.fetch_start",rE(e.fetchStart)],["http.request.domain_lookup_start",rE(e.domainLookupStart)],["http.request.domain_lookup_end",rE(e.domainLookupEnd)],["http.request.connect_start",rE(e.connectStart)],["http.request.secure_connection_start",rE(e.secureConnectionStart)],["http.request.connection_end",rE(e.connectEnd)],["http.request.request_start",rE(e.requestStart)],["http.request.response_start",rE(e.responseStart)],["http.request.response_end",rE(e.responseEnd)]]:r})(r).forEach(t=>e.setAttribute(...t)),setTimeout(n))})})}function rE(e=0){return((eb.Z1||performance.timeOrigin)+e)/1e3}function rb(e){try{return new URL(e,eU.location.origin).href}catch(e){return}}let rS={...rc,instrumentNavigation:!0,instrumentPageLoad:!0,markBackgroundSpan:!0,enableLongTask:!0,enableLongAnimationFrame:!0,enableInp:!0,_experiments:{},...ry},rT=(e={})=>{ru||(ru=!0,tf(rd),tg(rd));let{enableInp:t,enableLongTask:n,enableLongAnimationFrame:r,_experiments:{enableInteractions:i,enableStandaloneClsSpans:o},beforeStartSpan:s,idleTimeout:a,finalTimeout:c,childSpanTimeout:l,markBackgroundSpan:u,traceFetch:d,traceXHR:f,trackFetchStreamPerformance:g,shouldCreateSpanForRequest:_,enableHTTPTimings:y,instrumentPageLoad:v,instrumentNavigation:E}={...rS,...e},b=function({recordClsStandaloneSpans:e}){let t=n9();if(t&&eb.Z1){t.mark&&eX.performance.mark("sentry-tracing-init");let n=nk(({metric:e})=>{let t=e.entries[e.entries.length-1];if(!t)return;let n=n7(eb.Z1),r=n7(t.startTime);rt.fid={value:e.value,unit:"millisecond"},rt["mark.fid"]={value:n+r,unit:"second"}}),r=nA(({metric:e})=>{let t=e.entries[e.entries.length-1];t&&(rt.lcp={value:e.value,unit:"millisecond"},p=t)},!0),i=nU("ttfb",({metric:e})=>{e.entries[e.entries.length-1]&&(rt.ttfb={value:e.value,unit:"millisecond"})},nL,h),o=e?function(){let e,t,n=0;if(!function(){try{return PerformanceObserver.supportedEntryTypes.includes("layout-shift")}catch(e){return!1}}())return;let r=!1;function i(){r||(r=!0,t&&function(e,t,n){let r=n7((eb.Z1||0)+(t&&t.startTime||0)),i=(0,V.nZ)().getScopeData().transactionName,o=n8({name:t?(0,tt.Rt)(t.sources[0]&&t.sources[0].node):"Layout shift",transaction:i,attributes:(0,Y.Jr)({[tW.S3]:"auto.http.browser.cls",[tW.$J]:"ui.webvital.cls",[tW.JQ]:t&&t.duration||0,"sentry.pageload.span_id":n}),startTime:r});o&&(o.addEvent("cls",{[tW.E1]:"",[tW.Wb]:e}),o.end(r))}(n,e,t),o())}let o=nR(({metric:t})=>{let r=t.entries[t.entries.length-1];r&&(n=t.value,e=r)},!0);tQ(()=>{i()}),setTimeout(()=>{let e=(0,V.s3)();if(!e)return;let n=e.on("startNavigationSpan",()=>{i(),n&&n()}),r=(0,ev.HN)(),o=r&&(0,ev.Gx)(r),s=o&&(0,ev.XU)(o);s&&"pageload"===s.op&&(t=o.spanContext().spanId)},0)}():nR(({metric:e})=>{let t=e.entries[e.entries.length-1];t&&(rt.cls={value:e.value,unit:""},m=t)},!0);return()=>{n(),r(),i(),o&&o()}}return()=>void 0}({recordClsStandaloneSpans:o||!1});t&&function(){if(n9()&&eb.Z1){let e=nN(({metric:e})=>{if(void 0==e.value)return;let t=e.entries.find(t=>t.duration===e.value&&rs[t.name]);if(!t)return;let{interactionId:n}=t,r=rs[t.name],i=n7(eb.Z1+t.startTime),o=n7(e.value),s=(0,ev.HN)(),a=s?(0,ev.Gx)(s):void 0,c=(null!=n?ro.get(n):void 0)||a,l=c?(0,ev.XU)(c).description:(0,V.nZ)().getScopeData().transactionName,u=n8({name:(0,tt.Rt)(t.target),transaction:l,attributes:(0,Y.Jr)({[tW.S3]:"auto.http.browser.inp",[tW.$J]:`ui.interaction.${r}`,[tW.JQ]:t.duration}),startTime:i});u&&(u.addEvent("inp",{[tW.E1]:"millisecond",[tW.Wb]:e.value}),u.end(i+o))})}}(),r&&M.GLOBAL_OBJ.PerformanceObserver&&PerformanceObserver.supportedEntryTypes&&PerformanceObserver.supportedEntryTypes.includes("long-animation-frame")?new PerformanceObserver(e=>{let t=(0,ev.HN)();if(t)for(let n of e.getEntries()){if(!n.scripts[0])continue;let e=n7(eb.Z1+n.startTime),{start_timestamp:r,op:i}=(0,ev.XU)(t);if("navigation"===i&&r&&e{let t=(0,ev.HN)();if(!t)return;let{op:n,start_timestamp:r}=(0,ev.XU)(t);for(let i of e){let e=n7(eb.Z1+i.startTime),o=n7(i.duration);"navigation"===n&&r&&e{let t=(0,ev.HN)();if(t){for(let n of e)if("click"===n.name){let e=n7(eb.Z1+n.startTime),r=n7(n.duration),i={name:(0,tt.Rt)(n.target),op:`ui.interaction.${n.name}`,startTime:e,attributes:{[tW.S3]:"auto.ui.browser.metrics"}},o=(0,tt.iY)(n.target);o&&(i.attributes["ui.component_name"]=o),n6(t,e,e+r,i)}}});let S={name:void 0,source:void 0};function T(e,t){let n="pageload"===t.op,r=s?s(t):t,i=r.attributes||{};t.name!==r.name&&(i[tW.Zj]="custom",r.attributes=i),S.name=r.name,S.source=i[tW.Zj];let u=rl(r,{idleTimeout:a,finalTimeout:c,childSpanTimeout:l,disableAutoFinish:n,beforeSpanEnd:e=>{b(),function(e,t){let n=n9();if(!n||!n.getEntries||!eb.Z1)return;let r=n7(eb.Z1),i=n.getEntries(),{op:o,start_timestamp:s}=(0,ev.XU)(e);if(i.slice(re).forEach(t=>{let n=n7(t.startTime),i=n7(Math.max(0,t.duration));if("navigation"!==o||!s||!(r+n{rn(e,t,n,r)}),rn(e,t,"secureConnection",r,"TLS/SSL"),rn(e,t,"fetch",r,"cache"),rn(e,t,"domainLookup",r,"DNS"),function(e,t,n){let r=n+n7(t.requestStart),i=n+n7(t.responseEnd),o=n+n7(t.responseStart);t.responseEnd&&(n6(e,r,i,{op:"browser.request",name:t.name,attributes:{[tW.S3]:"auto.ui.browser.metrics"}}),n6(e,o,i,{op:"browser.response",name:t.name,attributes:{[tW.S3]:"auto.ui.browser.metrics"}}))}(e,t,r);break;case"mark":case"paint":case"measure":{(function(e,t,n,r,i){let o=tV(!1),s=i+Math.max(n,n7(o?o.requestStart:0)),a=i+n,c={[tW.S3]:"auto.resource.browser.metrics"};s!==a&&(c["sentry.browser.measure_happened_before_request"]=!0,c["sentry.browser.measure_start_time"]=s),n6(e,s,a+r,{name:t.name,op:t.entryType,attributes:c})})(e,t,n,i,r);let o=t6(),s=t.startTime{!function(e,t,n,r=(0,ev.HN)()){let i=r&&(0,ev.Gx)(r);i&&($.X&&B.kg.log(`[Measurement] Setting measurement on root span: ${e} = ${t} ${n}`),i.addEvent(e,{[tW.Wb]:t,[tW.E1]:n}))}(e,t.value,t.unit)}),e.setAttribute("performance.timeOrigin",r),e.setAttribute("performance.activationStart",tY()),p&&(p.element&&e.setAttribute("lcp.element",(0,tt.Rt)(p.element)),p.id&&e.setAttribute("lcp.id",p.id),p.url&&e.setAttribute("lcp.url",p.url.trim().slice(0,200)),null!=p.loadTime&&e.setAttribute("lcp.loadTime",p.loadTime),null!=p.renderTime&&e.setAttribute("lcp.renderTime",p.renderTime),e.setAttribute("lcp.size",p.size)),m&&m.sources&&m.sources.forEach((t,n)=>e.setAttribute(`cls.source.${n+1}`,(0,tt.Rt)(t.node)))}p=void 0,m=void 0,rt={}}(e,{recordClsOnPageloadSpan:!o})}});function d(){["interactive","complete"].includes(eU.document.readyState)&&e.emit("idleSpanEnableAutoFinish",u)}return n&&eU.document&&(eU.document.addEventListener("readystatechange",()=>{d()}),d()),u}return{name:"BrowserTracing",afterAllSetup(e){let n,r;let o=eU.location&&eU.location.href;function s(){n&&!(0,ev.XU)(n).timestamp&&n.end()}e.on("startNavigationSpan",t=>{(0,V.s3)()===e&&(s(),n=T(e,{op:"navigation",...t}))}),e.on("startPageLoadSpan",(t,r={})=>{if((0,V.s3)()!==e)return;s();let i=r.sentryTrace||rC("sentry-trace"),o=r.baggage||rC("baggage"),a=(0,rh.pT)(i,o);(0,V.nZ)().setPropagationContext(a),n=T(e,{op:"pageload",...t})}),e.on("spanEnd",e=>{let t=(0,ev.XU)(e).op;if(e!==(0,ev.Gx)(e)||"navigation"!==t&&"pageload"!==t)return;let n=(0,V.nZ)(),r=n.getPropagationContext();n.setPropagationContext({...r,sampled:void 0!==r.sampled?r.sampled:(0,ev.Tt)(e),dsc:r.dsc||(0,ea.jC)(e)})}),eU.location&&(v&&rw(e,{name:eU.location.pathname,startTime:eb.Z1?eb.Z1/1e3:void 0,attributes:{[tW.Zj]:"url",[tW.S3]:"auto.pageload.browser"}}),E&&e1(({to:t,from:n})=>{if(void 0===n&&o&&-1!==o.indexOf(t)){o=void 0;return}n!==t&&(o=void 0,rO(e,{name:eU.location.pathname,attributes:{[tW.Zj]:"url",[tW.S3]:"auto.navigation.browser"}}))})),u&&eU&&eU.document&&eU.document.addEventListener("visibilitychange",()=>{let e=(0,ev.HN)();if(!e)return;let t=(0,ev.Gx)(e);if(eU.document.hidden&&t){let{op:e,status:n}=(0,ev.XU)(t);n||t.setStatus({code:ra.jt,message:"cancelled"}),t.setAttribute("sentry.cancellation_reason","document.hidden"),t.end()}}),i&&eU.document&&addEventListener("click",()=>{let e=(0,ev.HN)(),t=e&&(0,ev.Gx)(e);!(t&&["navigation","pageload"].includes((0,ev.XU)(t).op))&&(r&&(r.setAttribute(tW.ju,"interactionInterrupted"),r.end(),r=void 0),S.name&&(r=rl({name:S.name,op:"ui.action.click",attributes:{[tW.Zj]:S.source||"url"}},{idleTimeout:a,finalTimeout:c,childSpanTimeout:l})))},{once:!1,capture:!0}),t&&function(){let e=({entries:e})=>{let t=(0,ev.HN)(),n=t&&(0,ev.Gx)(t);e.forEach(e=>{if(!("duration"in e)||!n)return;let t=e.interactionId;if(!(null==t||ro.has(t))){if(ri.length>10){let e=ri.shift();ro.delete(e)}ri.push(t),ro.set(t,n)}})};nI("event",e),nI("first-input",e)}(),function(e,t){let{traceFetch:n,traceXHR:r,trackFetchStreamPerformance:i,shouldCreateSpanForRequest:o,enableHTTPTimings:s,tracePropagationTargets:a}={traceFetch:ry.traceFetch,traceXHR:ry.traceXHR,trackFetchStreamPerformance:ry.trackFetchStreamPerformance,...t},c="function"==typeof o?o:e=>!0,l=e=>(function(e,t){let n=eU.location&&eU.location.href;if(n){let r,i;try{r=new URL(e,n),i=new URL(n).origin}catch(e){return!1}let o=r.origin===i;return t?(0,G.U0)(r.toString(),t)||o&&(0,G.U0)(r.pathname,t):o}{let n=!!e.match(/^\/(?!\/)/);return t?(0,G.U0)(e,t):n}})(e,a),u={};n&&(e.addEventProcessor(e=>("transaction"===e.type&&e.spans&&e.spans.forEach(e=>{if("http.client"===e.op){let t=r_.get(e.span_id);t&&(e.timestamp=t/1e3,r_.delete(e.span_id))}}),e)),i&&function(e){let t="fetch-body-resolved";eW(t,e),eG(t,()=>e4(e8))}(e=>{if(e.response){let t=rg.get(e.response);t&&e.endTimestamp&&r_.set(t,e.endTimestamp)}}),e5(e=>{let t=function(e,t,n,r,i="auto.http.browser"){if(!e.fetchData)return;let o=(0,nH.z)()&&t(e.fetchData.url);if(e.endTimestamp&&o){let t=e.fetchData.__span;if(!t)return;let n=r[t];n&&(function(e,t){if(t.response){(0,ra.Q0)(e,t.response.status);let n=t.response&&t.response.headers&&t.response.headers.get("content-length");if(n){let t=parseInt(n);t>0&&e.setAttribute("http.response_content_length",t)}}else t.error&&e.setStatus({code:ra.jt,message:"internal_error"});e.end()}(n,e),delete r[t]);return}let{method:s,url:a}=e.fetchData,c=function(e){try{return new URL(e).href}catch(e){return}}(a),l=c?tr(c).host:void 0,u=!!(0,ev.HN)(),d=o&&u?n1({name:`${s} ${a}`,attributes:{url:a,type:"fetch","http.method":s,"http.url":c,"server.address":l,[tW.S3]:i,[tW.$J]:"http.client"}}):new nz;if(e.fetchData.__span=d.spanContext().spanId,r[d.spanContext().spanId]=d,n(e.fetchData.url)){let t=e.args[0],n=e.args[1]||{},r=function(e,t,n){let r=rp({span:n}),i=r["sentry-trace"],o=r.baggage;if(!i)return;let s=t.headers||("undefined"!=typeof Request&&(0,eT.V9)(e,Request)?e.headers:void 0);if(!s)return{...r};if("undefined"!=typeof Headers&&(0,eT.V9)(s,Headers)){let e=new Headers(s);if(e.set("sentry-trace",i),o){let t=e.get("baggage");if(t){let n=rm(t);e.set("baggage",n?`${n},${o}`:o)}else e.set("baggage",o)}return e}if(Array.isArray(s)){let e=[...s.filter(e=>!(Array.isArray(e)&&"sentry-trace"===e[0])).map(e=>{if(!Array.isArray(e)||"baggage"!==e[0]||"string"!=typeof e[1])return e;{let[t,n,...r]=e;return[t,rm(n),...r]}}),["sentry-trace",i]];return o&&e.push(["baggage",o]),e}{let e="baggage"in s?s.baggage:void 0,t=[];return Array.isArray(e)?t=e.map(e=>"string"==typeof e?rm(e):e).filter(e=>""===e):e&&t.push(rm(e)),o&&t.push(o),{...s,"sentry-trace":i,baggage:t.length>0?t.join(","):void 0}}}(t,n,(0,nH.z)()&&u?d:void 0);r&&(e.args[1]=n,n.headers=r)}return d}(e,c,l,u);if(e.response&&e.fetchData.__span&&rg.set(e.response,e.fetchData.__span),t){let n=rb(e.fetchData.url),r=n?tr(n).host:void 0;t.setAttributes({"http.url":n,"server.address":r})}s&&t&&rv(t)})),r&&eK(e=>{let t=function(e,t,n,r){let i=e.xhr,o=i&&i[eZ];if(!i||i.__sentry_own_request__||!o)return;let s=(0,nH.z)()&&t(o.url);if(e.endTimestamp&&s){let e=i.__sentry_xhr_span_id__;if(!e)return;let t=r[e];t&&void 0!==o.status_code&&((0,ra.Q0)(t,o.status_code),t.end(),delete r[e]);return}let a=rb(o.url),c=a?tr(a).host:void 0,l=!!(0,ev.HN)(),u=s&&l?n1({name:`${o.method} ${o.url}`,attributes:{type:"xhr","http.method":o.method,"http.url":a,url:o.url,"server.address":c,[tW.S3]:"auto.http.browser",[tW.$J]:"http.client"}}):new nz;return i.__sentry_xhr_span_id__=u.spanContext().spanId,r[i.__sentry_xhr_span_id__]=u,n(o.url)&&function(e,t){let{"sentry-trace":n,baggage:r}=rp({span:t});n&&function(e,t,n){try{e.setRequestHeader("sentry-trace",t),n&&e.setRequestHeader("baggage",n)}catch(e){}}(e,n,r)}(i,(0,nH.z)()&&l?u:void 0),u}(e,c,l,u);s&&t&&rv(t)})}(e,{traceFetch:d,traceXHR:f,trackFetchStreamPerformance:g,tracePropagationTargets:e.getOptions().tracePropagationTargets,shouldCreateSpanForRequest:_,enableHTTPTimings:y})}}};function rw(e,t,n){e.emit("startPageLoadSpan",t,n),(0,V.nZ)().setTransactionName(t.name);let r=(0,ev.HN)();return"pageload"===(r&&(0,ev.XU)(r).op)?r:void 0}function rO(e,t){(0,V.aF)().setPropagationContext({traceId:(0,nG.Ht)()}),(0,V.nZ)().setPropagationContext({traceId:(0,nG.Ht)()}),e.emit("startNavigationSpan",t),(0,V.nZ)().setTransactionName(t.name);let n=(0,ev.HN)();return"navigation"===(n&&(0,ev.XU)(n).op)?n:void 0}function rC(e){let t=(0,tt.qT)(`meta[name=${e}]`);return t?t.getAttribute("content"):void 0}let rR="incomplete-app-router-transaction",rA=M.GLOBAL_OBJ;function rk(e){try{return new URL(e,"http://some-random-base.com/").pathname}catch(e){return"/"}}var rN=n(68874),rI=n(26811);let rx=rN.events?rN:rN.default,rD=/^(\S+:\\|\/?)([\s\S]*?)((?:\.{1,2}|[^/\\]+?|)(\.[^./\\]*|))(?:[/\\]*)$/;function rP(...e){let t="",n=!1;for(let r=e.length-1;r>=-1&&!n;r--){let i=r>=0?e[r]:"/";i&&(t=`${i}/${t}`,n="/"===i.charAt(0))}return t=(function(e,t){let n=0;for(let t=e.length-1;t>=0;t--){let r=e[t];"."===r?e.splice(t,1):".."===r?(e.splice(t,1),n++):n&&(e.splice(t,1),n--)}if(t)for(;n--;n)e.unshift("..");return e})(t.split("/").filter(e=>!!e),!n).join("/"),(n?"/":"")+t||"."}function rM(e){let t=0;for(;t=0&&""===e[n];n--);return t>n?[]:e.slice(t,n-t+1)}let rL=(e={})=>{let t=e.root,n=e.prefix||"app:///",r="window"in M.GLOBAL_OBJ&&void 0!==M.GLOBAL_OBJ.window,i=e.iteratee||function({isBrowser:e,root:t,prefix:n}){return r=>{if(!r.filename)return r;let i=/^[a-zA-Z]:\\/.test(r.filename)||r.filename.includes("\\")&&!r.filename.includes("/"),o=/^\//.test(r.filename);if(e){if(t){let e=r.filename;0===e.indexOf(t)&&(r.filename=e.replace(t,n))}}else if(i||o){let e;let o=i?r.filename.replace(/^[a-zA-Z]:/,"").replace(/\\/g,"/"):r.filename,s=t?function(e,t){e=rP(e).slice(1),t=rP(t).slice(1);let n=rM(e.split("/")),r=rM(t.split("/")),i=Math.min(n.length,r.length),o=i;for(let e=0;e1024?`${e.slice(-1024)}`:e,n=rD.exec(t);return n?n.slice(1):[]}(o)[2]||"";r.filename=`${n}${s}`}return r}}({isBrowser:r,root:t,prefix:n});return{name:"RewriteFrames",processEvent(e){let t=e;return e.exception&&Array.isArray(e.exception.values)&&(t=function(e){try{return{...e,exception:{...e.exception,values:e.exception.values.map(e=>{var t;return{...e,...e.stacktrace&&{stacktrace:{...t=e.stacktrace,frames:t&&t.frames&&t.frames.map(e=>i(e))}}}})}}}catch(t){return e}}(t)),t}}},rj=({assetPrefixPath:e})=>({...rL({iteratee:t=>{try{let{origin:n}=new URL(t.filename);t.filename=S([t,"access",e=>e.filename,"optionalAccess",e=>e.replace,"call",e=>e(n,"app://"),"access",e=>e.replace,"call",t=>t(e,"")])}catch(e){}return t.filename&&t.filename.startsWith("app:///_next")&&(t.filename=decodeURI(t.filename)),t.filename&&t.filename.match(/^app:\/\/\/_next\/static\/chunks\/(main-|main-app-|polyfills-|webpack-|framework-|framework\.)[0-9a-f]+\.js$/)&&(t.in_app=!1),t}}),name:"NextjsClientStackFrameNormalization"});var rU=n(12509);let r$=M.GLOBAL_OBJ,rB=M.GLOBAL_OBJ;function rF(e){return"/"===e[e.length-1]?e.slice(0,-1):e}var rq=n(12509);function rH(){return"undefined"!=typeof window&&(!(!("undefined"!=typeof __SENTRY_BROWSER_BUNDLE__&&__SENTRY_BROWSER_BUNDLE__)&&"[object process]"===Object.prototype.toString.call(void 0!==rq?rq:0))||function(){let e=M.GLOBAL_OBJ.process;return!!e&&"renderer"===e.type}())}let rW=M.GLOBAL_OBJ,rG="sentryReplaySession",rz="Unable to send Replay";function rX(e,t){return null!=e?e:t()}function rJ(e){let t;let n=e[0],r=1;for(;rn.call(t,...e)),t=void 0)}return n}function rV(e){let t=rJ([e,"optionalAccess",e=>e.host]);return rJ([t,"optionalAccess",e=>e.shadowRoot])===e}function rY(e){return"[object ShadowRoot]"===Object.prototype.toString.call(e)}function rZ(e){try{var t;let n=e.rules||e.cssRules;return n?((t=Array.from(n,rK).join("")).includes(" background-clip: text;")&&!t.includes(" -webkit-background-clip: text;")&&(t=t.replace(/\sbackground-clip:\s*text;/g," -webkit-background-clip: text; background-clip: text;")),t):null}catch(e){return null}}function rK(e){let t;if("styleSheet"in e)try{t=rZ(e.styleSheet)||function(e){let{cssText:t}=e;if(t.split('"').length<3)return t;let n=["@import",`url(${JSON.stringify(e.href)})`];return""===e.layerName?n.push("layer"):e.layerName&&n.push(`layer(${e.layerName})`),e.supportsText&&n.push(`supports(${e.supportsText})`),e.media.length&&n.push(e.media.mediaText),n.join(" ")+";"}(e)}catch(e){}else if("selectorText"in e){let t=e.cssText,n=e.selectorText.includes(":"),r="string"==typeof e.style.all&&e.style.all;if(r&&(t=function(e){let t="";for(let n=0;ne.getMeta,"call",t=>t(e),"optionalAccess",e=>e.id]),()=>-1):-1}getNode(e){return this.idNodeMap.get(e)||null}getIds(){return Array.from(this.idNodeMap.keys())}getMeta(e){return this.nodeMetaMap.get(e)||null}removeNodeFromMap(e){let t=this.getId(e);this.idNodeMap.delete(t),e.childNodes&&e.childNodes.forEach(e=>this.removeNodeFromMap(e))}has(e){return this.idNodeMap.has(e)}hasNode(e){return this.nodeMetaMap.has(e)}add(e,t){let n=t.id;this.idNodeMap.set(n,e),this.nodeMetaMap.set(e,t)}replace(e,t){let n=this.getNode(e);if(n){let e=this.nodeMetaMap.get(n);e&&this.nodeMetaMap.set(t,e)}this.idNodeMap.set(e,t)}reset(){this.idNodeMap=new Map,this.nodeMetaMap=new WeakMap}}function r0({maskInputOptions:e,tagName:t,type:n}){return"OPTION"===t&&(t="SELECT"),!!(e[t.toLowerCase()]||n&&e[n]||"password"===n||"INPUT"===t&&!n&&e.text)}function r1({isMasked:e,element:t,value:n,maskInputFn:r}){let i=n||"";return e?(r&&(i=r(i,t)),"*".repeat(i.length)):i}function r2(e){return e.toLowerCase()}function r3(e){return e.toUpperCase()}let r5="__rrweb_original__";function r4(e){let t=e.type;return e.hasAttribute("data-rr-is-password")?"password":t?r2(t):null}function r6(e,t,n){return"INPUT"===t&&("radio"===n||"checkbox"===n)?e.getAttribute("value")||"":e.value}function r8(e,t){let n;try{n=new URL(e,rX(t,()=>window.location.href))}catch(e){return null}return rX(rJ([n.pathname.match(/\.([0-9a-z]+)(?:$)/i),"optionalAccess",e=>e[1]]),()=>null)}let r9={};function r7(e){let t=r9[e];if(t)return t;let n=window.document,r=window[e];if(n&&"function"==typeof n.createElement)try{let t=n.createElement("iframe");t.hidden=!0,n.head.appendChild(t);let i=t.contentWindow;i&&i[e]&&(r=i[e]),n.head.removeChild(t)}catch(e){}return r9[e]=r.bind(window)}function ie(...e){return r7("setTimeout")(...e)}function it(...e){return r7("clearTimeout")(...e)}function ir(e){try{return e.contentDocument}catch(e){}}let ii=1,io=RegExp("[^a-z0-9-_:]");function is(){return ii++}let ia=/url\((?:(')([^']*)'|(")(.*?)"|([^)]*))\)/gm,ic=/^(?:[a-z+]+:)?\/\//i,il=/^www\..*/i,iu=/^(data:)([^,]*),(.*)/i;function id(e,t){return(e||"").replace(ia,(e,n,r,i,o,s)=>{let a=r||o||s,c=n||i||"";if(!a)return e;if(ic.test(a)||il.test(a)||iu.test(a))return`url(${c}${a}${c})`;if("/"===a[0])return`url(${c}${(t.indexOf("//")>-1?t.split("/").slice(0,3).join("/"):t.split("/")[0]).split("?")[0]+a}${c})`;let l=t.split("/"),u=a.split("/");for(let e of(l.pop(),u))"."!==e&&(".."===e?l.pop():l.push(e));return`url(${c}${l.join("/")}${c})`})}let ih=/^[^ \t\n\r\u000c]+/,ip=/^[, \t\n\r\u000c]+/,im=new WeakMap;function ig(e,t){return t&&""!==t.trim()?i_(e,t):t}function i_(e,t){let n=im.get(e);if(n||(n=e.createElement("a"),im.set(e,n)),t){if(t.startsWith("blob:")||t.startsWith("data:"))return t}else t="";return n.setAttribute("href",t),n.href}function iy(e,t,n,r,i,o){return r?"src"!==n&&("href"!==n||"use"===t&&"#"===r[0])&&("xlink:href"!==n||"#"===r[0])&&("background"!==n||"table"!==t&&"td"!==t&&"th"!==t)?"srcset"===n?function(e,t){if(""===t.trim())return t;let n=0;function r(e){let r;let i=e.exec(t.substring(n));return i?(r=i[0],n+=r.length,r):""}let i=[];for(;r(ip),!(n>=t.length);){let o=r(ih);if(","===o.slice(-1))o=ig(e,o.substring(0,o.length-1)),i.push(o);else{let r="";o=ig(e,o);let s=!1;for(;;){let e=t.charAt(n);if(""===e){i.push((o+r).trim());break}if(s)")"===e&&(s=!1);else{if(","===e){n+=1,i.push((o+r).trim());break}"("===e&&(s=!0)}r+=e,n+=1}}}return i.join(", ")}(e,r):"style"===n?id(r,i_(e)):"object"===t&&"data"===n?ig(e,r):"function"==typeof o?o(n,r,i):r:ig(e,r):r}function iv(e,t,n){return("video"===e||"audio"===e)&&"autoplay"===t}function iE(e,t,n=1/0,r=0){return!e||e.nodeType!==e.ELEMENT_NODE||r>n?-1:t(e)?r:iE(e.parentNode,t,n,r+1)}function ib(e,t){return n=>{if(null===n)return!1;try{if(e){if("string"==typeof e){if(n.matches(`.${e}`))return!0}else if(function(e,t){for(let n=e.classList.length;n--;){let r=e.classList[n];if(t.test(r))return!0}return!1}(n,e))return!0}if(t&&n.matches(t))return!0;return!1}catch(e){return!1}}}function iS(e,t,n,r,i,o){try{let s=e.nodeType===e.ELEMENT_NODE?e:e.parentElement;if(null===s)return!1;if("INPUT"===s.tagName){let e=s.getAttribute("autocomplete");if(["current-password","new-password","cc-number","cc-exp","cc-exp-month","cc-exp-year","cc-csc"].includes(e))return!0}let a=-1,c=-1;if(o){if((c=iE(s,ib(r,i)))<0)return!0;a=iE(s,ib(t,n),c>=0?c:1/0)}else{if((a=iE(s,ib(t,n)))<0)return!1;c=iE(s,ib(r,i),a>=0?a:1/0)}return a>=0?!(c>=0)||a<=c:!(c>=0)&&!!o}catch(e){}return!!o}function iT(e){return null==e?"":e.toLowerCase()}function iw(e,t){let n;let{doc:r,mirror:i,blockClass:o,blockSelector:s,unblockSelector:a,maskAllText:c,maskTextClass:l,unmaskTextClass:u,maskTextSelector:d,unmaskTextSelector:h,skipChild:f=!1,inlineStylesheet:p=!0,maskInputOptions:m={},maskAttributeFn:y,maskTextFn:v,maskInputFn:E,slimDOMOptions:b,dataURLOptions:S={},inlineImages:T=!1,recordCanvas:w=!1,onSerialize:O,onIframeLoad:C,iframeLoadTimeout:R=5e3,onStylesheetLoad:A,stylesheetLoadTimeout:k=5e3,keepIframeSrcFn:N=()=>!1,newlyAddedElement:x=!1}=t,{preserveWhiteSpace:D=!0}=t,P=function(e,t){let{doc:n,mirror:r,blockClass:i,blockSelector:o,unblockSelector:s,maskAllText:a,maskAttributeFn:c,maskTextClass:l,unmaskTextClass:u,maskTextSelector:d,unmaskTextSelector:h,inlineStylesheet:f,maskInputOptions:p={},maskTextFn:m,maskInputFn:y,dataURLOptions:v={},inlineImages:E,recordCanvas:b,keepIframeSrcFn:S,newlyAddedElement:T=!1}=t,w=function(e,t){if(!t.hasNode(e))return;let n=t.getId(e);return 1===n?void 0:n}(n,r);switch(e.nodeType){case e.DOCUMENT_NODE:if("CSS1Compat"!==e.compatMode)return{type:I.Document,childNodes:[],compatMode:e.compatMode};return{type:I.Document,childNodes:[]};case e.DOCUMENT_TYPE_NODE:return{type:I.DocumentType,name:e.name,publicId:e.publicId,systemId:e.systemId,rootId:w};case e.ELEMENT_NODE:return function(e,t){let n;let{doc:r,blockClass:i,blockSelector:o,unblockSelector:s,inlineStylesheet:a,maskInputOptions:c={},maskAttributeFn:l,maskInputFn:u,dataURLOptions:d={},inlineImages:h,recordCanvas:f,keepIframeSrcFn:p,newlyAddedElement:m=!1,rootId:y,maskAllText:v,maskTextClass:E,unmaskTextClass:b,maskTextSelector:S,unmaskTextSelector:T}=t,w=function(e,t,n,r){try{if(r&&e.matches(r))return!1;if("string"==typeof t){if(e.classList.contains(t))return!0}else for(let n=e.classList.length;n--;){let r=e.classList[n];if(t.test(r))return!0}if(n)return e.matches(n)}catch(e){}return!1}(e,i,o,s),O=function(e){if(e instanceof HTMLFormElement)return"form";let t=r2(e.tagName);return io.test(t)?"div":t}(e),C={},R=e.attributes.length;for(let t=0;tt.href===e.href),n=null;t&&(n=rZ(t)),n&&(C.rel=null,C.href=null,C.crossorigin=null,C._cssText=id(n,t.href))}if("style"===O&&e.sheet&&!(e.innerText||e.textContent||"").trim().length){let t=rZ(e.sheet);t&&(C._cssText=id(t,i_(r)))}if("input"===O||"textarea"===O||"select"===O||"option"===O){let t=r4(e),n=r6(e,r3(O),t),r=e.checked;if("submit"!==t&&"button"!==t&&n){let r=iS(e,E,S,b,T,r0({type:t,tagName:r3(O),maskInputOptions:c}));C.value=r1({isMasked:r,element:e,value:n,maskInputFn:u})}r&&(C.checked=r)}if("option"===O&&(e.selected&&!c.select?C.selected=!0:delete C.selected),"canvas"===O&&f){if("2d"===e.__context)!function(e){let t=e.getContext("2d");if(!t)return!0;for(let n=0;n0!==e))return!1}return!0}(e)&&(C.rr_dataURL=e.toDataURL(d.type,d.quality));else if(!("__context"in e)){let t=e.toDataURL(d.type,d.quality),n=r.createElement("canvas");n.width=e.width,n.height=e.height,t!==n.toDataURL(d.type,d.quality)&&(C.rr_dataURL=t)}}if("img"===O&&h){g||(_=(g=r.createElement("canvas")).getContext("2d"));let t=e.currentSrc||e.getAttribute("src")||"",n=e.crossOrigin,i=()=>{e.removeEventListener("load",i);try{g.width=e.naturalWidth,g.height=e.naturalHeight,_.drawImage(e,0,0),C.rr_dataURL=g.toDataURL(d.type,d.quality)}catch(n){if("anonymous"!==e.crossOrigin){e.crossOrigin="anonymous",e.complete&&0!==e.naturalWidth?i():e.addEventListener("load",i);return}console.warn(`Cannot inline img src=${t}! Error: ${n}`)}"anonymous"===e.crossOrigin&&(n?C.crossOrigin=n:e.removeAttribute("crossorigin"))};e.complete&&0!==e.naturalWidth?i():e.addEventListener("load",i)}if(("audio"===O||"video"===O)&&(C.rr_mediaState=e.paused?"paused":"played",C.rr_mediaCurrentTime=e.currentTime),!m&&(e.scrollLeft&&(C.rr_scrollLeft=e.scrollLeft),e.scrollTop&&(C.rr_scrollTop=e.scrollTop)),w){let{width:t,height:n}=e.getBoundingClientRect();C={class:C.class,rr_width:`${t}px`,rr_height:`${n}px`}}"iframe"!==O||p(C.src)||(w||ir(e)||(C.rr_src=C.src),delete C.src);try{customElements.get(O)&&(n=!0)}catch(e){}return{type:I.Element,tagName:O,attributes:C,childNodes:[],isSVG:!!("svg"===e.tagName||e.ownerSVGElement)||void 0,needBlock:w,rootId:y,isCustom:n}}(e,{doc:n,blockClass:i,blockSelector:o,unblockSelector:s,inlineStylesheet:f,maskAttributeFn:c,maskInputOptions:p,maskInputFn:y,dataURLOptions:v,inlineImages:E,recordCanvas:b,keepIframeSrcFn:S,newlyAddedElement:T,rootId:w,maskAllText:a,maskTextClass:l,unmaskTextClass:u,maskTextSelector:d,unmaskTextSelector:h});case e.TEXT_NODE:return function(e,t){let{maskAllText:n,maskTextClass:r,unmaskTextClass:i,maskTextSelector:o,unmaskTextSelector:s,maskTextFn:a,maskInputOptions:c,maskInputFn:l,rootId:u}=t,d=e.parentNode&&e.parentNode.tagName,h=e.textContent,f="STYLE"===d||void 0,p="SCRIPT"===d||void 0,m="TEXTAREA"===d||void 0;if(f&&h){try{e.nextSibling||e.previousSibling||rJ([e,"access",e=>e.parentNode,"access",e=>e.sheet,"optionalAccess",e=>e.cssRules])&&(h=rZ(e.parentNode.sheet))}catch(t){console.warn(`Cannot get CSS styles from text's parentNode. Error: ${t}`,e)}h=id(h,i_(t.doc))}p&&(h="SCRIPT_PLACEHOLDER");let g=iS(e,r,o,i,s,n);return f||p||m||!h||!g||(h=a?a(h,e.parentElement):h.replace(/[\S]/g,"*")),m&&h&&(c.textarea||g)&&(h=l?l(h,e.parentNode):h.replace(/[\S]/g,"*")),"OPTION"===d&&h&&(h=r1({isMasked:iS(e,r,o,i,s,r0({type:null,tagName:d,maskInputOptions:c})),element:e,value:h,maskInputFn:l})),{type:I.Text,textContent:h||"",isStyle:f,rootId:u}}(e,{doc:n,maskAllText:a,maskTextClass:l,unmaskTextClass:u,maskTextSelector:d,unmaskTextSelector:h,maskTextFn:m,maskInputOptions:p,maskInputFn:y,rootId:w});case e.CDATA_SECTION_NODE:return{type:I.CDATA,textContent:"",rootId:w};case e.COMMENT_NODE:return{type:I.Comment,textContent:e.textContent||"",rootId:w};default:return!1}}(e,{doc:r,mirror:i,blockClass:o,blockSelector:s,maskAllText:c,unblockSelector:a,maskTextClass:l,unmaskTextClass:u,maskTextSelector:d,unmaskTextSelector:h,inlineStylesheet:p,maskInputOptions:m,maskAttributeFn:y,maskTextFn:v,maskInputFn:E,dataURLOptions:S,inlineImages:T,recordCanvas:w,keepIframeSrcFn:N,newlyAddedElement:x});if(!P)return console.warn(e,"not serialized"),null;n=i.hasNode(e)?i.getId(e):!function(e,t){if(t.comment&&e.type===I.Comment)return!0;if(e.type===I.Element){if(t.script&&("script"===e.tagName||"link"===e.tagName&&("preload"===e.attributes.rel||"modulepreload"===e.attributes.rel)||"link"===e.tagName&&"prefetch"===e.attributes.rel&&"string"==typeof e.attributes.href&&"js"===r8(e.attributes.href))||t.headFavicon&&("link"===e.tagName&&"shortcut icon"===e.attributes.rel||"meta"===e.tagName&&(iT(e.attributes.name).match(/^msapplication-tile(image|color)$/)||"application-name"===iT(e.attributes.name)||"icon"===iT(e.attributes.rel)||"apple-touch-icon"===iT(e.attributes.rel)||"shortcut icon"===iT(e.attributes.rel))))return!0;if("meta"===e.tagName){if(t.headMetaDescKeywords&&iT(e.attributes.name).match(/^description|keywords$/)||t.headMetaSocial&&(iT(e.attributes.property).match(/^(og|twitter|fb):/)||iT(e.attributes.name).match(/^(og|twitter):/)||"pinterest"===iT(e.attributes.name)))return!0;if(t.headMetaRobots&&("robots"===iT(e.attributes.name)||"googlebot"===iT(e.attributes.name)||"bingbot"===iT(e.attributes.name)))return!0;if(t.headMetaHttpEquiv&&void 0!==e.attributes["http-equiv"])return!0;else if(t.headMetaAuthorship&&("author"===iT(e.attributes.name)||"generator"===iT(e.attributes.name)||"framework"===iT(e.attributes.name)||"publisher"===iT(e.attributes.name)||"progid"===iT(e.attributes.name)||iT(e.attributes.property).match(/^article:/)||iT(e.attributes.property).match(/^product:/)))return!0;else if(t.headMetaVerification&&("google-site-verification"===iT(e.attributes.name)||"yandex-verification"===iT(e.attributes.name)||"csrf-token"===iT(e.attributes.name)||"p:domain_verify"===iT(e.attributes.name)||"verify-v1"===iT(e.attributes.name)||"verification"===iT(e.attributes.name)||"shopify-checkout-api-token"===iT(e.attributes.name)))return!0}}return!1}(P,b)&&(D||P.type!==I.Text||P.isStyle||P.textContent.replace(/^\s+|\s+$/gm,"").length)?is():-2;let M=Object.assign(P,{id:n});if(i.add(e,M),-2===n)return null;O&&O(e);let L=!f;if(M.type===I.Element){L=L&&!M.needBlock,delete M.needBlock;let t=e.shadowRoot;t&&rY(t)&&(M.isShadowHost=!0)}if((M.type===I.Document||M.type===I.Element)&&L){b.headWhitespace&&M.type===I.Element&&"head"===M.tagName&&(D=!1);let t={doc:r,mirror:i,blockClass:o,blockSelector:s,maskAllText:c,unblockSelector:a,maskTextClass:l,unmaskTextClass:u,maskTextSelector:d,unmaskTextSelector:h,skipChild:f,inlineStylesheet:p,maskInputOptions:m,maskAttributeFn:y,maskTextFn:v,maskInputFn:E,slimDOMOptions:b,dataURLOptions:S,inlineImages:T,recordCanvas:w,preserveWhiteSpace:D,onSerialize:O,onIframeLoad:C,iframeLoadTimeout:R,onStylesheetLoad:A,stylesheetLoadTimeout:k,keepIframeSrcFn:N};for(let n of Array.from(e.childNodes)){let e=iw(n,t);e&&M.childNodes.push(e)}if(e.nodeType===e.ELEMENT_NODE&&e.shadowRoot)for(let n of Array.from(e.shadowRoot.childNodes)){let r=iw(n,t);r&&(rY(e.shadowRoot)&&(r.isShadow=!0),M.childNodes.push(r))}}return e.parentNode&&rV(e.parentNode)&&rY(e.parentNode)&&(M.isShadow=!0),M.type===I.Element&&"iframe"===M.tagName&&function(e,t,n){let r;let i=e.contentWindow;if(!i)return;let o=!1;try{r=i.document.readyState}catch(e){return}if("complete"!==r){let r=ie(()=>{o||(t(),o=!0)},n);e.addEventListener("load",()=>{it(r),o=!0,t()});return}let s="about:blank";if(i.location.href!==s||e.src===s||""===e.src)return ie(t,0),e.addEventListener("load",t);e.addEventListener("load",t)}(e,()=>{let t=ir(e);if(t&&C){let n=iw(t,{doc:t,mirror:i,blockClass:o,blockSelector:s,unblockSelector:a,maskAllText:c,maskTextClass:l,unmaskTextClass:u,maskTextSelector:d,unmaskTextSelector:h,skipChild:!1,inlineStylesheet:p,maskInputOptions:m,maskAttributeFn:y,maskTextFn:v,maskInputFn:E,slimDOMOptions:b,dataURLOptions:S,inlineImages:T,recordCanvas:w,preserveWhiteSpace:D,onSerialize:O,onIframeLoad:C,iframeLoadTimeout:R,onStylesheetLoad:A,stylesheetLoadTimeout:k,keepIframeSrcFn:N});n&&C(e,n)}},R),M.type===I.Element&&"link"===M.tagName&&"string"==typeof M.attributes.rel&&("stylesheet"===M.attributes.rel||"preload"===M.attributes.rel&&"string"==typeof M.attributes.href&&"css"===r8(M.attributes.href))&&function(e,t,n){let r,i=!1;try{r=e.sheet}catch(e){return}if(r)return;let o=ie(()=>{i||(t(),i=!0)},n);e.addEventListener("load",()=>{it(o),i=!0,t()})}(e,()=>{if(A){let t=iw(e,{doc:r,mirror:i,blockClass:o,blockSelector:s,unblockSelector:a,maskAllText:c,maskTextClass:l,unmaskTextClass:u,maskTextSelector:d,unmaskTextSelector:h,skipChild:!1,inlineStylesheet:p,maskInputOptions:m,maskAttributeFn:y,maskTextFn:v,maskInputFn:E,slimDOMOptions:b,dataURLOptions:S,inlineImages:T,recordCanvas:w,preserveWhiteSpace:D,onSerialize:O,onIframeLoad:C,iframeLoadTimeout:R,onStylesheetLoad:A,stylesheetLoadTimeout:k,keepIframeSrcFn:N});t&&A(e,t)}},k),M}function iO(e){let t;let n=e[0],r=1;for(;rn.call(t,...e)),t=void 0)}return n}function iC(e,t,n=document){let r={capture:!0,passive:!0};return n.addEventListener(e,t,r),()=>n.removeEventListener(e,t,r)}let iR="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.",iA={map:{},getId:()=>(console.error(iR),-1),getNode:()=>(console.error(iR),null),removeNodeFromMap(){console.error(iR)},has:()=>(console.error(iR),!1),reset(){console.error(iR)}};function ik(e,t,n={}){let r=null,i=0;return function(...o){let s=Date.now();i||!1!==n.leading||(i=s);let a=t-(s-i),c=this;a<=0||a>t?(r&&(function(...e){iz("clearTimeout")(...e)}(r),r=null),i=s,e.apply(c,o)):r||!1===n.trailing||(r=iX(()=>{i=!1===n.leading?0:Date.now(),r=null,e.apply(c,o)},a))}}function iN(e,t,n){try{if(!(t in e))return()=>{};let r=e[t],i=n(r);return"function"==typeof i&&(i.prototype=i.prototype||{},Object.defineProperties(i,{__rrweb_original__:{enumerable:!1,value:r}})),e[t]=i,()=>{e[t]=r}}catch(e){return()=>{}}}"undefined"!=typeof window&&window.Proxy&&window.Reflect&&(iA=new Proxy(iA,{get:(e,t,n)=>("map"===t&&console.error(iR),Reflect.get(e,t,n))}));let iI=Date.now;function ix(e){let t=e.document;return{left:t.scrollingElement?t.scrollingElement.scrollLeft:void 0!==e.pageXOffset?e.pageXOffset:iO([t,"optionalAccess",e=>e.documentElement,"access",e=>e.scrollLeft])||iO([t,"optionalAccess",e=>e.body,"optionalAccess",e=>e.parentElement,"optionalAccess",e=>e.scrollLeft])||iO([t,"optionalAccess",e=>e.body,"optionalAccess",e=>e.scrollLeft])||0,top:t.scrollingElement?t.scrollingElement.scrollTop:void 0!==e.pageYOffset?e.pageYOffset:iO([t,"optionalAccess",e=>e.documentElement,"access",e=>e.scrollTop])||iO([t,"optionalAccess",e=>e.body,"optionalAccess",e=>e.parentElement,"optionalAccess",e=>e.scrollTop])||iO([t,"optionalAccess",e=>e.body,"optionalAccess",e=>e.scrollTop])||0}}function iD(){return window.innerHeight||document.documentElement&&document.documentElement.clientHeight||document.body&&document.body.clientHeight}function iP(){return window.innerWidth||document.documentElement&&document.documentElement.clientWidth||document.body&&document.body.clientWidth}function iM(e){return e?e.nodeType===e.ELEMENT_NODE?e:e.parentElement:null}function iL(e,t,n,r,i){if(!e)return!1;let o=iM(e);if(!o)return!1;let s=ib(t,n);if(!i){let e=r&&o.matches(r);return s(o)&&!e}let a=iE(o,s),c=-1;return!(a<0)&&(r&&(c=iE(o,ib(null,r))),a>-1&&c<0||ae.shadowRoot])}/[1-9][0-9]{12}/.test(Date.now().toString())||(iI=()=>new Date().getTime());class iq{constructor(){this.id=1,this.styleIDMap=new WeakMap,this.idStyleMap=new Map}getId(e){var t;return t=this.styleIDMap.get(e),null!=t?t:-1}has(e){return this.styleIDMap.has(e)}add(e,t){let n;return this.has(e)?this.getId(e):(n=void 0===t?this.id++:t,this.styleIDMap.set(e,n),this.idStyleMap.set(n,e),n)}getStyle(e){return this.idStyleMap.get(e)||null}reset(){this.styleIDMap=new WeakMap,this.idStyleMap=new Map,this.id=1}generateId(){return this.id++}}function iH(e){let t=null;return iO([e,"access",e=>e.getRootNode,"optionalCall",e=>e(),"optionalAccess",e=>e.nodeType])===Node.DOCUMENT_FRAGMENT_NODE&&e.getRootNode().host&&(t=e.getRootNode().host),t}function iW(e){let t=e.ownerDocument;return!!t&&(t.contains(e)||function(e){let t=e.ownerDocument;if(!t)return!1;let n=function(e){let t,n=e;for(;t=iH(n);)n=t;return n}(e);return t.contains(n)}(e))}let iG={};function iz(e){let t=iG[e];if(t)return t;let n=window.document,r=window[e];if(n&&"function"==typeof n.createElement)try{let t=n.createElement("iframe");t.hidden=!0,n.head.appendChild(t);let i=t.contentWindow;i&&i[e]&&(r=i[e]),n.head.removeChild(t)}catch(e){}return iG[e]=r.bind(window)}function iX(...e){return iz("setTimeout")(...e)}var iJ=((w=iJ||{})[w.DomContentLoaded=0]="DomContentLoaded",w[w.Load=1]="Load",w[w.FullSnapshot=2]="FullSnapshot",w[w.IncrementalSnapshot=3]="IncrementalSnapshot",w[w.Meta=4]="Meta",w[w.Custom=5]="Custom",w[w.Plugin=6]="Plugin",w),iV=((O=iV||{})[O.Mutation=0]="Mutation",O[O.MouseMove=1]="MouseMove",O[O.MouseInteraction=2]="MouseInteraction",O[O.Scroll=3]="Scroll",O[O.ViewportResize=4]="ViewportResize",O[O.Input=5]="Input",O[O.TouchMove=6]="TouchMove",O[O.MediaInteraction=7]="MediaInteraction",O[O.StyleSheetRule=8]="StyleSheetRule",O[O.CanvasMutation=9]="CanvasMutation",O[O.Font=10]="Font",O[O.Log=11]="Log",O[O.Drag=12]="Drag",O[O.StyleDeclaration=13]="StyleDeclaration",O[O.Selection=14]="Selection",O[O.AdoptedStyleSheet=15]="AdoptedStyleSheet",O[O.CustomElement=16]="CustomElement",O),iY=((C=iY||{})[C.MouseUp=0]="MouseUp",C[C.MouseDown=1]="MouseDown",C[C.Click=2]="Click",C[C.ContextMenu=3]="ContextMenu",C[C.DblClick=4]="DblClick",C[C.Focus=5]="Focus",C[C.Blur=6]="Blur",C[C.TouchStart=7]="TouchStart",C[C.TouchMove_Departed=8]="TouchMove_Departed",C[C.TouchEnd=9]="TouchEnd",C[C.TouchCancel=10]="TouchCancel",C),iZ=((R=iZ||{})[R.Mouse=0]="Mouse",R[R.Pen=1]="Pen",R[R.Touch=2]="Touch",R);function iK(e){try{return e.contentDocument}catch(e){}}(A=x||(x={}))[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",(k=D||(D={}))[k.PLACEHOLDER=0]="PLACEHOLDER",k[k.ELEMENT_NODE=1]="ELEMENT_NODE",k[k.ATTRIBUTE_NODE=2]="ATTRIBUTE_NODE",k[k.TEXT_NODE=3]="TEXT_NODE",k[k.CDATA_SECTION_NODE=4]="CDATA_SECTION_NODE",k[k.ENTITY_REFERENCE_NODE=5]="ENTITY_REFERENCE_NODE",k[k.ENTITY_NODE=6]="ENTITY_NODE",k[k.PROCESSING_INSTRUCTION_NODE=7]="PROCESSING_INSTRUCTION_NODE",k[k.COMMENT_NODE=8]="COMMENT_NODE",k[k.DOCUMENT_NODE=9]="DOCUMENT_NODE",k[k.DOCUMENT_TYPE_NODE=10]="DOCUMENT_TYPE_NODE",k[k.DOCUMENT_FRAGMENT_NODE=11]="DOCUMENT_FRAGMENT_NODE";class iQ{constructor(){this.length=0,this.head=null,this.tail=null}get(e){if(e>=this.length)throw Error("Position outside of list range");let t=this.head;for(let n=0;nn.call(t,...e)),t=void 0)}return n}([t,"optionalAccess",e=>e.next])||null;return t}addNode(e){let t={value:e,previous:null,next:null};if(e.__ln=t,e.previousSibling&&"__ln"in e.previousSibling){let n=e.previousSibling.__ln.next;t.next=n,t.previous=e.previousSibling.__ln,e.previousSibling.__ln.next=t,n&&(n.previous=t)}else if(e.nextSibling&&"__ln"in e.nextSibling&&e.nextSibling.__ln.previous){let n=e.nextSibling.__ln.previous;t.previous=n,t.next=e.nextSibling.__ln,e.nextSibling.__ln.previous=t,n&&(n.next=t)}else this.head&&(this.head.previous=t),t.next=this.head,this.head=t;null===t.next&&(this.tail=t),this.length++}removeNode(e){let t=e.__ln;this.head&&(t.previous?(t.previous.next=t.next,t.next?t.next.previous=t.previous:this.tail=t.previous):(this.head=t.next,this.head?this.head.previous=null:this.tail=null),e.__ln&&delete e.__ln,this.length--)}}let i0=(e,t)=>`${e}@${t}`;class i1{constructor(){this.frozen=!1,this.locked=!1,this.texts=[],this.attributes=[],this.attributeMap=new WeakMap,this.removes=[],this.mapRemoves=[],this.movedMap={},this.addedSet=new Set,this.movedSet=new Set,this.droppedSet=new Set,this.processMutations=e=>{e.forEach(this.processMutation),this.emit()},this.emit=()=>{if(this.frozen||this.locked)return;let e=[],t=new Set,n=new iQ,r=e=>{let t=e,n=-2;for(;-2===n;)n=(t=t&&t.nextSibling)&&this.mirror.getId(t);return n},i=i=>{if(!i.parentNode||!iW(i))return;let o=rV(i.parentNode)?this.mirror.getId(iH(i)):this.mirror.getId(i.parentNode),s=r(i);if(-1===o||-1===s)return n.addNode(i);let a=iw(i,{doc:this.doc,mirror:this.mirror,blockClass:this.blockClass,blockSelector:this.blockSelector,maskAllText:this.maskAllText,unblockSelector:this.unblockSelector,maskTextClass:this.maskTextClass,unmaskTextClass:this.unmaskTextClass,maskTextSelector:this.maskTextSelector,unmaskTextSelector:this.unmaskTextSelector,skipChild:!0,newlyAddedElement:!0,inlineStylesheet:this.inlineStylesheet,maskInputOptions:this.maskInputOptions,maskAttributeFn:this.maskAttributeFn,maskTextFn:this.maskTextFn,maskInputFn:this.maskInputFn,slimDOMOptions:this.slimDOMOptions,dataURLOptions:this.dataURLOptions,recordCanvas:this.recordCanvas,inlineImages:this.inlineImages,onSerialize:e=>{i$(e,this.mirror)&&!iL(e,this.blockClass,this.blockSelector,this.unblockSelector,!1)&&this.iframeManager.addIframe(e),iB(e,this.mirror)&&this.stylesheetManager.trackLinkElement(e),iF(i)&&this.shadowDomManager.addShadowRoot(i.shadowRoot,this.doc)},onIframeLoad:(e,t)=>{iL(e,this.blockClass,this.blockSelector,this.unblockSelector,!1)||(this.iframeManager.attachIframe(e,t),e.contentWindow&&this.canvasManager.addWindow(e.contentWindow),this.shadowDomManager.observeAttachShadow(e))},onStylesheetLoad:(e,t)=>{this.stylesheetManager.attachLinkElement(e,t)}});a&&(e.push({parentId:o,nextId:s,node:a}),t.add(a.id))};for(;this.mapRemoves.length;)this.mirror.removeNodeFromMap(this.mapRemoves.shift());for(let e of this.movedSet)(!i3(this.removes,e,this.mirror)||this.movedSet.has(e.parentNode))&&i(e);for(let e of this.addedSet)i5(this.droppedSet,e)||i3(this.removes,e,this.mirror)?i5(this.movedSet,e)?i(e):this.droppedSet.add(e):i(e);let o=null;for(;n.length;){let e=null;if(o){let t=this.mirror.getId(o.value.parentNode),n=r(o.value);-1!==t&&-1!==n&&(e=o)}if(!e){let t=n.tail;for(;t;){let n=t;if(t=t.previous,n){let t=this.mirror.getId(n.value.parentNode);if(-1===r(n.value))continue;if(-1!==t){e=n;break}{let t=n.value;if(t.parentNode&&t.parentNode.nodeType===Node.DOCUMENT_FRAGMENT_NODE){let r=t.parentNode.host;if(-1!==this.mirror.getId(r)){e=n;break}}}}}}if(!e){for(;n.head;)n.removeNode(n.head.value);break}o=e.previous,n.removeNode(e.value),i(e.value)}let s={texts:this.texts.map(e=>({id:this.mirror.getId(e.node),value:e.value})).filter(e=>!t.has(e.id)).filter(e=>this.mirror.has(e.id)),attributes:this.attributes.map(e=>{let{attributes:t}=e;if("string"==typeof t.style){let n=JSON.stringify(e.styleDiff),r=JSON.stringify(e._unchangedStyles);n.length!t.has(e.id)).filter(e=>this.mirror.has(e.id)),removes:this.removes,adds:e};(s.texts.length||s.attributes.length||s.removes.length||s.adds.length)&&(this.texts=[],this.attributes=[],this.attributeMap=new WeakMap,this.removes=[],this.addedSet=new Set,this.movedSet=new Set,this.droppedSet=new Set,this.movedMap={},this.mutationCb(s))},this.processMutation=e=>{if(!ij(e.target,this.mirror))switch(e.type){case"characterData":{let t=e.target.textContent;iL(e.target,this.blockClass,this.blockSelector,this.unblockSelector,!1)||t===e.oldValue||this.texts.push({value:iS(e.target,this.maskTextClass,this.maskTextSelector,this.unmaskTextClass,this.unmaskTextSelector,this.maskAllText)&&t?this.maskTextFn?this.maskTextFn(t,iM(e.target)):t.replace(/[\S]/g,"*"):t,node:e.target});break}case"attributes":{let t=e.target,n=e.attributeName,r=e.target.getAttribute(n);if("value"===n){let n=r4(t),i=t.tagName;r=r6(t,i,n);let o=r0({maskInputOptions:this.maskInputOptions,tagName:i,type:n});r=r1({isMasked:iS(e.target,this.maskTextClass,this.maskTextSelector,this.unmaskTextClass,this.unmaskTextSelector,o),element:t,value:r,maskInputFn:this.maskInputFn})}if(iL(e.target,this.blockClass,this.blockSelector,this.unblockSelector,!1)||r===e.oldValue)return;let i=this.attributeMap.get(e.target);if("IFRAME"===t.tagName&&"src"===n&&!this.keepIframeSrcFn(r)){if(iK(t))return;n="rr_src"}if(i||(i={node:e.target,attributes:{},styleDiff:{},_unchangedStyles:{}},this.attributes.push(i),this.attributeMap.set(e.target,i)),"type"===n&&"INPUT"===t.tagName&&"password"===(e.oldValue||"").toLowerCase()&&t.setAttribute("data-rr-is-password","true"),!iv(t.tagName,n)&&(i.attributes[n]=iy(this.doc,r2(t.tagName),r2(n),r,t,this.maskAttributeFn),"style"===n)){if(!this.unattachedDoc)try{this.unattachedDoc=document.implementation.createHTMLDocument()}catch(e){this.unattachedDoc=this.doc}let n=this.unattachedDoc.createElement("span");for(let r of(e.oldValue&&n.setAttribute("style",e.oldValue),Array.from(t.style))){let e=t.style.getPropertyValue(r),o=t.style.getPropertyPriority(r);e!==n.style.getPropertyValue(r)||o!==n.style.getPropertyPriority(r)?""===o?i.styleDiff[r]=e:i.styleDiff[r]=[e,o]:i._unchangedStyles[r]=[e,o]}for(let e of Array.from(n.style))""===t.style.getPropertyValue(e)&&(i.styleDiff[e]=!1)}break}case"childList":if(iL(e.target,this.blockClass,this.blockSelector,this.unblockSelector,!0))return;e.addedNodes.forEach(t=>this.genAdds(t,e.target)),e.removedNodes.forEach(t=>{let n=this.mirror.getId(t),r=rV(e.target)?this.mirror.getId(e.target.host):this.mirror.getId(e.target);iL(e.target,this.blockClass,this.blockSelector,this.unblockSelector,!1)||ij(t,this.mirror)||-1===this.mirror.getId(t)||(this.addedSet.has(t)?(i2(this.addedSet,t),this.droppedSet.add(t)):this.addedSet.has(e.target)&&-1===n||function e(t,n){if(rV(t))return!1;let r=n.getId(t);return!n.has(r)||(!t.parentNode||t.parentNode.nodeType!==t.DOCUMENT_NODE)&&(!t.parentNode||e(t.parentNode,n))}(e.target,this.mirror)||(this.movedSet.has(t)&&this.movedMap[i0(n,r)]?i2(this.movedSet,t):this.removes.push({parentId:r,id:n,isShadow:!!(rV(e.target)&&rY(e.target))||void 0})),this.mapRemoves.push(t))})}},this.genAdds=(e,t)=>{if(!this.processedNodeManager.inOtherBuffer(e,this)&&!(this.addedSet.has(e)||this.movedSet.has(e))){if(this.mirror.hasNode(e)){if(ij(e,this.mirror))return;this.movedSet.add(e);let n=null;t&&this.mirror.hasNode(t)&&(n=this.mirror.getId(t)),n&&-1!==n&&(this.movedMap[i0(this.mirror.getId(e),n)]=!0)}else this.addedSet.add(e),this.droppedSet.delete(e);!iL(e,this.blockClass,this.blockSelector,this.unblockSelector,!1)&&(e.childNodes.forEach(e=>this.genAdds(e)),iF(e)&&e.shadowRoot.childNodes.forEach(t=>{this.processedNodeManager.add(t,this),this.genAdds(t,e)}))}}}init(e){["mutationCb","blockClass","blockSelector","unblockSelector","maskAllText","maskTextClass","unmaskTextClass","maskTextSelector","unmaskTextSelector","inlineStylesheet","maskInputOptions","maskAttributeFn","maskTextFn","maskInputFn","keepIframeSrcFn","recordCanvas","inlineImages","slimDOMOptions","dataURLOptions","doc","mirror","iframeManager","stylesheetManager","shadowDomManager","canvasManager","processedNodeManager"].forEach(t=>{this[t]=e[t]})}freeze(){this.frozen=!0,this.canvasManager.freeze()}unfreeze(){this.frozen=!1,this.canvasManager.unfreeze(),this.emit()}isFrozen(){return this.frozen}lock(){this.locked=!0,this.canvasManager.lock()}unlock(){this.locked=!1,this.canvasManager.unlock(),this.emit()}reset(){this.shadowDomManager.reset(),this.canvasManager.reset()}}function i2(e,t){e.delete(t),t.childNodes.forEach(t=>i2(e,t))}function i3(e,t,n){return 0!==e.length&&function(e,t,n){let r=t.parentNode;for(;r;){let t=n.getId(r);if(e.some(e=>e.id===t))return!0;r=r.parentNode}return!1}(e,t,n)}function i5(e,t){return 0!==e.size&&function e(t,n){let{parentNode:r}=n;return!!r&&(!!t.has(r)||e(t,r))}(e,t)}let i4=e=>y?(...t)=>{try{return e(...t)}catch(e){if(y&&!0===y(e))return()=>{};throw e}}:e;function i6(e){let t;let n=e[0],r=1;for(;rn.call(t,...e)),t=void 0)}return n}let i8=[];function i9(e){try{if("composedPath"in e){let t=e.composedPath();if(t.length)return t[0]}else if("path"in e&&e.path.length)return e.path[0]}catch(e){}return e&&e.target}function i7(e,t){let n=new i1;i8.push(n),n.init(e);let r=window.MutationObserver||window.__rrMutationObserver,i=i6([window,"optionalAccess",e=>e.Zone,"optionalAccess",e=>e.__symbol__,"optionalCall",e=>e("MutationObserver")]);i&&window[i]&&(r=window[i]);let o=new r(i4(t=>{e.onMutation&&!1===e.onMutation(t)||n.processMutations.bind(n)(t)}));return o.observe(t,{attributes:!0,attributeOldValue:!0,characterData:!0,characterDataOldValue:!0,childList:!0,subtree:!0}),o}function oe({scrollCb:e,doc:t,mirror:n,blockClass:r,blockSelector:i,unblockSelector:o,sampling:s}){return iC("scroll",i4(ik(i4(s=>{let a=i9(s);if(!a||iL(a,r,i,o,!0))return;let c=n.getId(a);if(a===t&&t.defaultView){let n=ix(t.defaultView);e({id:c,x:n.left,y:n.top})}else e({id:c,x:a.scrollLeft,y:a.scrollTop})}),s.scroll||100)),t)}let ot=["INPUT","TEXTAREA","SELECT"],on=new WeakMap;function or(e){var t;return t=[],oa("CSSGroupingRule")&&e.parentRule instanceof CSSGroupingRule||oa("CSSMediaRule")&&e.parentRule instanceof CSSMediaRule||oa("CSSSupportsRule")&&e.parentRule instanceof CSSSupportsRule||oa("CSSConditionRule")&&e.parentRule instanceof CSSConditionRule?t.unshift(Array.from(e.parentRule.cssRules).indexOf(e)):e.parentStyleSheet&&t.unshift(Array.from(e.parentStyleSheet.cssRules).indexOf(e)),t}function oi(e,t,n){let r,i;return e?(e.ownerNode?r=t.getId(e.ownerNode):i=n.getId(e),{styleId:i,id:r}):{}}function oo({mirror:e,stylesheetManager:t},n){let r=null;r="#document"===n.nodeName?e.getId(n):e.getId(n.host);let i="#document"===n.nodeName?i6([n,"access",e=>e.defaultView,"optionalAccess",e=>e.Document]):i6([n,"access",e=>e.ownerDocument,"optionalAccess",e=>e.defaultView,"optionalAccess",e=>e.ShadowRoot]),o=i6([i,"optionalAccess",e=>e.prototype])?Object.getOwnPropertyDescriptor(i6([i,"optionalAccess",e=>e.prototype]),"adoptedStyleSheets"):void 0;return null!==r&&-1!==r&&i&&o?(Object.defineProperty(n,"adoptedStyleSheets",{configurable:o.configurable,enumerable:o.enumerable,get(){return i6([o,"access",e=>e.get,"optionalAccess",e=>e.call,"call",e=>e(this)])},set(e){let n=i6([o,"access",e=>e.set,"optionalAccess",e=>e.call,"call",t=>t(this,e)]);if(null!==r&&-1!==r)try{t.adoptStyleSheets(e,r)}catch(e){}return n}}),i4(()=>{Object.defineProperty(n,"adoptedStyleSheets",{configurable:o.configurable,enumerable:o.enumerable,get:o.get,set:o.set})})):()=>{}}function os(e,t={}){let n;let r=e.doc.defaultView;if(!r)return()=>{};e.recordDOM&&(n=i7(e,e.doc));let i=function({mousemoveCb:e,sampling:t,doc:n,mirror:r}){let i;if(!1===t.mousemove)return()=>{};let o="number"==typeof t.mousemove?t.mousemove:50,s="number"==typeof t.mousemoveCallback?t.mousemoveCallback:500,a=[],c=ik(i4(t=>{let n=Date.now()-i;e(a.map(e=>(e.timeOffset-=n,e)),t),a=[],i=null}),s),l=i4(ik(i4(e=>{let t=i9(e),{clientX:n,clientY:o}=iU(e)?e.changedTouches[0]:e;i||(i=iI()),a.push({x:n,y:o,id:r.getId(t),timeOffset:iI()-i}),c("undefined"!=typeof DragEvent&&e instanceof DragEvent?iV.Drag:e instanceof MouseEvent?iV.MouseMove:iV.TouchMove)}),o,{trailing:!1})),u=[iC("mousemove",l,n),iC("touchmove",l,n),iC("drag",l,n)];return i4(()=>{u.forEach(e=>e())})}(e),o=function({mouseInteractionCb:e,doc:t,mirror:n,blockClass:r,blockSelector:i,unblockSelector:o,sampling:s}){if(!1===s.mouseInteraction)return()=>{};let a=!0===s.mouseInteraction||void 0===s.mouseInteraction?{}:s.mouseInteraction,c=[],l=null,u=t=>s=>{let a=i9(s);if(iL(a,r,i,o,!0))return;let c=null,u=t;if("pointerType"in s){switch(s.pointerType){case"mouse":c=iZ.Mouse;break;case"touch":c=iZ.Touch;break;case"pen":c=iZ.Pen}c===iZ.Touch?iY[t]===iY.MouseDown?u="TouchStart":iY[t]===iY.MouseUp&&(u="TouchEnd"):iZ.Pen}else iU(s)&&(c=iZ.Touch);null!==c?(l=c,(u.startsWith("Touch")&&c===iZ.Touch||u.startsWith("Mouse")&&c===iZ.Mouse)&&(c=null)):iY[t]===iY.Click&&(c=l,l=null);let d=iU(s)?s.changedTouches[0]:s;if(!d)return;let h=n.getId(a),{clientX:f,clientY:p}=d;i4(e)({type:iY[u],id:h,x:f,y:p,...null!==c&&{pointerType:c}})};return Object.keys(iY).filter(e=>Number.isNaN(Number(e))&&!e.endsWith("_Departed")&&!1!==a[e]).forEach(e=>{let n=r2(e),r=u(e);if(window.PointerEvent)switch(iY[e]){case iY.MouseDown:case iY.MouseUp:n=n.replace("mouse","pointer");break;case iY.TouchStart:case iY.TouchEnd:return}c.push(iC(n,r,t))}),i4(()=>{c.forEach(e=>e())})}(e),s=oe(e),a=function({viewportResizeCb:e},{win:t}){let n=-1,r=-1;return iC("resize",i4(ik(i4(()=>{let t=iD(),i=iP();(n!==t||r!==i)&&(e({width:Number(i),height:Number(t)}),n=t,r=i)}),200)),t)}(e,{win:r}),c=function({inputCb:e,doc:t,mirror:n,blockClass:r,blockSelector:i,unblockSelector:o,ignoreClass:s,ignoreSelector:a,maskInputOptions:c,maskInputFn:l,sampling:u,userTriggeredOnInput:d,maskTextClass:h,unmaskTextClass:f,maskTextSelector:p,unmaskTextSelector:m}){function g(e){let n=i9(e),u=e.isTrusted,g=n&&r3(n.tagName);if("OPTION"===g&&(n=n.parentElement),!n||!g||0>ot.indexOf(g)||iL(n,r,i,o,!0))return;let y=n;if(y.classList.contains(s)||a&&y.matches(a))return;let v=r4(n),E=r6(y,g,v),b=!1,S=r0({maskInputOptions:c,tagName:g,type:v}),T=iS(n,h,p,f,m,S);("radio"===v||"checkbox"===v)&&(b=n.checked),E=r1({isMasked:T,element:n,value:E,maskInputFn:l}),_(n,d?{text:E,isChecked:b,userTriggered:u}:{text:E,isChecked:b});let w=n.name;"radio"===v&&w&&b&&t.querySelectorAll(`input[type="radio"][name="${w}"]`).forEach(e=>{if(e!==n){let t=r1({isMasked:T,element:e,value:r6(e,g,v),maskInputFn:l});_(e,d?{text:t,isChecked:!b,userTriggered:!1}:{text:t,isChecked:!b})}})}function _(t,r){let i=on.get(t);if(!i||i.text!==r.text||i.isChecked!==r.isChecked){on.set(t,r);let i=n.getId(t);i4(e)({...r,id:i})}}let y=("last"===u.input?["change"]:["input","change"]).map(e=>iC(e,i4(g),t)),v=t.defaultView;if(!v)return()=>{y.forEach(e=>e())};let E=v.Object.getOwnPropertyDescriptor(v.HTMLInputElement.prototype,"value"),b=[[v.HTMLInputElement.prototype,"value"],[v.HTMLInputElement.prototype,"checked"],[v.HTMLSelectElement.prototype,"value"],[v.HTMLTextAreaElement.prototype,"value"],[v.HTMLSelectElement.prototype,"selectedIndex"],[v.HTMLOptionElement.prototype,"selected"]];return E&&E.set&&y.push(...b.map(e=>(function e(t,n,r,i,o=window){let s=o.Object.getOwnPropertyDescriptor(t,n);return o.Object.defineProperty(t,n,i?r:{set(e){iX(()=>{r.set.call(this,e)},0),s&&s.set&&s.set.call(this,e)}}),()=>e(t,n,s||{},!0)})(e[0],e[1],{set(){i4(g)({target:this,isTrusted:!1})}},!1,v))),i4(()=>{y.forEach(e=>e())})}(e),l=function({mediaInteractionCb:e,blockClass:t,blockSelector:n,unblockSelector:r,mirror:i,sampling:o,doc:s}){let a=i4(s=>ik(i4(o=>{let a=i9(o);if(!a||iL(a,t,n,r,!0))return;let{currentTime:c,volume:l,muted:u,playbackRate:d}=a;e({type:s,id:i.getId(a),currentTime:c,volume:l,muted:u,playbackRate:d})}),o.media||500)),c=[iC("play",a(0),s),iC("pause",a(1),s),iC("seeked",a(2),s),iC("volumechange",a(3),s),iC("ratechange",a(4),s)];return i4(()=>{c.forEach(e=>e())})}(e),u=()=>{},d=()=>{},h=()=>{},f=()=>{};e.recordDOM&&(u=function({styleSheetRuleCb:e,mirror:t,stylesheetManager:n},{win:r}){let i,o;if(!r.CSSStyleSheet||!r.CSSStyleSheet.prototype)return()=>{};let s=r.CSSStyleSheet.prototype.insertRule;r.CSSStyleSheet.prototype.insertRule=new Proxy(s,{apply:i4((r,i,o)=>{let[s,a]=o,{id:c,styleId:l}=oi(i,t,n.styleMirror);return(c&&-1!==c||l&&-1!==l)&&e({id:c,styleId:l,adds:[{rule:s,index:a}]}),r.apply(i,o)})});let a=r.CSSStyleSheet.prototype.deleteRule;r.CSSStyleSheet.prototype.deleteRule=new Proxy(a,{apply:i4((r,i,o)=>{let[s]=o,{id:a,styleId:c}=oi(i,t,n.styleMirror);return(a&&-1!==a||c&&-1!==c)&&e({id:a,styleId:c,removes:[{index:s}]}),r.apply(i,o)})}),r.CSSStyleSheet.prototype.replace&&(i=r.CSSStyleSheet.prototype.replace,r.CSSStyleSheet.prototype.replace=new Proxy(i,{apply:i4((r,i,o)=>{let[s]=o,{id:a,styleId:c}=oi(i,t,n.styleMirror);return(a&&-1!==a||c&&-1!==c)&&e({id:a,styleId:c,replace:s}),r.apply(i,o)})})),r.CSSStyleSheet.prototype.replaceSync&&(o=r.CSSStyleSheet.prototype.replaceSync,r.CSSStyleSheet.prototype.replaceSync=new Proxy(o,{apply:i4((r,i,o)=>{let[s]=o,{id:a,styleId:c}=oi(i,t,n.styleMirror);return(a&&-1!==a||c&&-1!==c)&&e({id:a,styleId:c,replaceSync:s}),r.apply(i,o)})}));let c={};oc("CSSGroupingRule")?c.CSSGroupingRule=r.CSSGroupingRule:(oc("CSSMediaRule")&&(c.CSSMediaRule=r.CSSMediaRule),oc("CSSConditionRule")&&(c.CSSConditionRule=r.CSSConditionRule),oc("CSSSupportsRule")&&(c.CSSSupportsRule=r.CSSSupportsRule));let l={};return Object.entries(c).forEach(([r,i])=>{l[r]={insertRule:i.prototype.insertRule,deleteRule:i.prototype.deleteRule},i.prototype.insertRule=new Proxy(l[r].insertRule,{apply:i4((r,i,o)=>{let[s,a]=o,{id:c,styleId:l}=oi(i.parentStyleSheet,t,n.styleMirror);return(c&&-1!==c||l&&-1!==l)&&e({id:c,styleId:l,adds:[{rule:s,index:[...or(i),a||0]}]}),r.apply(i,o)})}),i.prototype.deleteRule=new Proxy(l[r].deleteRule,{apply:i4((r,i,o)=>{let[s]=o,{id:a,styleId:c}=oi(i.parentStyleSheet,t,n.styleMirror);return(a&&-1!==a||c&&-1!==c)&&e({id:a,styleId:c,removes:[{index:[...or(i),s]}]}),r.apply(i,o)})})}),i4(()=>{r.CSSStyleSheet.prototype.insertRule=s,r.CSSStyleSheet.prototype.deleteRule=a,i&&(r.CSSStyleSheet.prototype.replace=i),o&&(r.CSSStyleSheet.prototype.replaceSync=o),Object.entries(c).forEach(([e,t])=>{t.prototype.insertRule=l[e].insertRule,t.prototype.deleteRule=l[e].deleteRule})})}(e,{win:r}),d=oo(e,e.doc),h=function({styleDeclarationCb:e,mirror:t,ignoreCSSAttributes:n,stylesheetManager:r},{win:i}){let o=i.CSSStyleDeclaration.prototype.setProperty;i.CSSStyleDeclaration.prototype.setProperty=new Proxy(o,{apply:i4((i,s,a)=>{let[c,l,u]=a;if(n.has(c))return o.apply(s,[c,l,u]);let{id:d,styleId:h}=oi(i6([s,"access",e=>e.parentRule,"optionalAccess",e=>e.parentStyleSheet]),t,r.styleMirror);return(d&&-1!==d||h&&-1!==h)&&e({id:d,styleId:h,set:{property:c,value:l,priority:u},index:or(s.parentRule)}),i.apply(s,a)})});let s=i.CSSStyleDeclaration.prototype.removeProperty;return i.CSSStyleDeclaration.prototype.removeProperty=new Proxy(s,{apply:i4((i,o,a)=>{let[c]=a;if(n.has(c))return s.apply(o,[c]);let{id:l,styleId:u}=oi(i6([o,"access",e=>e.parentRule,"optionalAccess",e=>e.parentStyleSheet]),t,r.styleMirror);return(l&&-1!==l||u&&-1!==u)&&e({id:l,styleId:u,remove:{property:c},index:or(o.parentRule)}),i.apply(o,a)})}),i4(()=>{i.CSSStyleDeclaration.prototype.setProperty=o,i.CSSStyleDeclaration.prototype.removeProperty=s})}(e,{win:r}),e.collectFonts&&(f=function({fontCb:e,doc:t}){let n=t.defaultView;if(!n)return()=>{};let r=[],i=new WeakMap,o=n.FontFace;n.FontFace=function(e,t,n){let r=new o(e,t,n);return i.set(r,{family:e,buffer:"string"!=typeof t,descriptors:n,fontSource:"string"==typeof t?t:JSON.stringify(Array.from(new Uint8Array(t)))}),r};let s=iN(t.fonts,"add",function(t){return function(n){return iX(i4(()=>{let t=i.get(n);t&&(e(t),i.delete(n))}),0),t.apply(this,[n])}});return r.push(()=>{n.FontFace=o}),r.push(s),i4(()=>{r.forEach(e=>e())})}(e)));let p=function(e){let{doc:t,mirror:n,blockClass:r,blockSelector:i,unblockSelector:o,selectionCb:s}=e,a=!0,c=i4(()=>{let e=t.getSelection();if(!e||a&&i6([e,"optionalAccess",e=>e.isCollapsed]))return;a=e.isCollapsed||!1;let c=[],l=e.rangeCount||0;for(let t=0;t{}}(e),g=[];for(let t of e.plugins)g.push(t.observer(t.callback,r,t.options));return i4(()=>{i8.forEach(e=>e.reset()),i6([n,"optionalAccess",e=>e.disconnect,"call",e=>e()]),i(),o(),s(),a(),c(),l(),u(),d(),h(),f(),p(),m(),g.forEach(e=>e())})}function oa(e){return void 0!==window[e]}function oc(e){return!!(void 0!==window[e]&&window[e].prototype&&"insertRule"in window[e].prototype&&"deleteRule"in window[e].prototype)}class ol{constructor(e){this.generateIdFn=e,this.iframeIdToRemoteIdMap=new WeakMap,this.iframeRemoteIdToIdMap=new WeakMap}getId(e,t,n,r){let i=n||this.getIdToRemoteIdMap(e),o=r||this.getRemoteIdToIdMap(e),s=i.get(t);return s||(s=this.generateIdFn(),i.set(t,s),o.set(s,t)),s}getIds(e,t){let n=this.getIdToRemoteIdMap(e),r=this.getRemoteIdToIdMap(e);return t.map(t=>this.getId(e,t,n,r))}getRemoteId(e,t,n){let r=n||this.getRemoteIdToIdMap(e);return"number"!=typeof t?t:r.get(t)||-1}getRemoteIds(e,t){let n=this.getRemoteIdToIdMap(e);return t.map(t=>this.getRemoteId(e,t,n))}reset(e){if(!e){this.iframeIdToRemoteIdMap=new WeakMap,this.iframeRemoteIdToIdMap=new WeakMap;return}this.iframeIdToRemoteIdMap.delete(e),this.iframeRemoteIdToIdMap.delete(e)}getIdToRemoteIdMap(e){let t=this.iframeIdToRemoteIdMap.get(e);return t||(t=new Map,this.iframeIdToRemoteIdMap.set(e,t)),t}getRemoteIdToIdMap(e){let t=this.iframeRemoteIdToIdMap.get(e);return t||(t=new Map,this.iframeRemoteIdToIdMap.set(e,t)),t}}function ou(e){let t;let n=e[0],r=1;for(;rn.call(t,...e)),t=void 0)}return n}class od{constructor(){this.crossOriginIframeMirror=new ol(is),this.crossOriginIframeRootIdMap=new WeakMap}addIframe(){}addLoadListener(){}attachIframe(){}}class oh{constructor(e){this.iframes=new WeakMap,this.crossOriginIframeMap=new WeakMap,this.crossOriginIframeMirror=new ol(is),this.crossOriginIframeRootIdMap=new WeakMap,this.mutationCb=e.mutationCb,this.wrappedEmit=e.wrappedEmit,this.stylesheetManager=e.stylesheetManager,this.recordCrossOriginIframes=e.recordCrossOriginIframes,this.crossOriginIframeStyleMirror=new ol(this.stylesheetManager.styleMirror.generateId.bind(this.stylesheetManager.styleMirror)),this.mirror=e.mirror,this.recordCrossOriginIframes&&window.addEventListener("message",this.handleMessage.bind(this))}addIframe(e){this.iframes.set(e,!0),e.contentWindow&&this.crossOriginIframeMap.set(e.contentWindow,e)}addLoadListener(e){this.loadListener=e}attachIframe(e,t){this.mutationCb({adds:[{parentId:this.mirror.getId(e),nextId:null,node:t}],removes:[],texts:[],attributes:[],isAttachIframe:!0}),ou([this,"access",e=>e.loadListener,"optionalCall",t=>t(e)]);let n=iK(e);n&&n.adoptedStyleSheets&&n.adoptedStyleSheets.length>0&&this.stylesheetManager.adoptStyleSheets(n.adoptedStyleSheets,this.mirror.getId(n))}handleMessage(e){if("rrweb"!==e.data.type||e.origin!==e.data.origin||!e.source)return;let t=this.crossOriginIframeMap.get(e.source);if(!t)return;let n=this.transformCrossOriginEvent(t,e.data.event);n&&this.wrappedEmit(n,e.data.isCheckout)}transformCrossOriginEvent(e,t){switch(t.type){case iJ.FullSnapshot:{this.crossOriginIframeMirror.reset(e),this.crossOriginIframeStyleMirror.reset(e),this.replaceIdOnNode(t.data.node,e);let n=t.data.node.id;return this.crossOriginIframeRootIdMap.set(e,n),this.patchRootIdOnNode(t.data.node,n),{timestamp:t.timestamp,type:iJ.IncrementalSnapshot,data:{source:iV.Mutation,adds:[{parentId:this.mirror.getId(e),nextId:null,node:t.data.node}],removes:[],texts:[],attributes:[],isAttachIframe:!0}}}case iJ.Meta:case iJ.Load:case iJ.DomContentLoaded:break;case iJ.Plugin:return t;case iJ.Custom:return this.replaceIds(t.data.payload,e,["id","parentId","previousId","nextId"]),t;case iJ.IncrementalSnapshot:switch(t.data.source){case iV.Mutation:return t.data.adds.forEach(t=>{this.replaceIds(t,e,["parentId","nextId","previousId"]),this.replaceIdOnNode(t.node,e);let n=this.crossOriginIframeRootIdMap.get(e);n&&this.patchRootIdOnNode(t.node,n)}),t.data.removes.forEach(t=>{this.replaceIds(t,e,["parentId","id"])}),t.data.attributes.forEach(t=>{this.replaceIds(t,e,["id"])}),t.data.texts.forEach(t=>{this.replaceIds(t,e,["id"])}),t;case iV.Drag:case iV.TouchMove:case iV.MouseMove:return t.data.positions.forEach(t=>{this.replaceIds(t,e,["id"])}),t;case iV.ViewportResize:return!1;case iV.MediaInteraction:case iV.MouseInteraction:case iV.Scroll:case iV.CanvasMutation:case iV.Input:return this.replaceIds(t.data,e,["id"]),t;case iV.StyleSheetRule:case iV.StyleDeclaration:return this.replaceIds(t.data,e,["id"]),this.replaceStyleIds(t.data,e,["styleId"]),t;case iV.Font:return t;case iV.Selection:return t.data.ranges.forEach(t=>{this.replaceIds(t,e,["start","end"])}),t;case iV.AdoptedStyleSheet:return this.replaceIds(t.data,e,["id"]),this.replaceStyleIds(t.data,e,["styleIds"]),ou([t,"access",e=>e.data,"access",e=>e.styles,"optionalAccess",e=>e.forEach,"call",t=>t(t=>{this.replaceStyleIds(t,e,["styleId"])})]),t}}return!1}replace(e,t,n,r){for(let i of r)(Array.isArray(t[i])||"number"==typeof t[i])&&(Array.isArray(t[i])?t[i]=e.getIds(n,t[i]):t[i]=e.getId(n,t[i]));return t}replaceIds(e,t,n){return this.replace(this.crossOriginIframeMirror,e,t,n)}replaceStyleIds(e,t,n){return this.replace(this.crossOriginIframeStyleMirror,e,t,n)}replaceIdOnNode(e,t){this.replaceIds(e,t,["id","rootId"]),"childNodes"in e&&e.childNodes.forEach(e=>{this.replaceIdOnNode(e,t)})}patchRootIdOnNode(e,t){e.type===I.Document||e.rootId||(e.rootId=t),"childNodes"in e&&e.childNodes.forEach(e=>{this.patchRootIdOnNode(e,t)})}}class of{init(){}addShadowRoot(){}observeAttachShadow(){}reset(){}}class op{constructor(e){this.shadowDoms=new WeakSet,this.restoreHandlers=[],this.mutationCb=e.mutationCb,this.scrollCb=e.scrollCb,this.bypassOptions=e.bypassOptions,this.mirror=e.mirror,this.init()}init(){this.reset(),this.patchAttachShadow(Element,document)}addShadowRoot(e,t){if(!rY(e)||this.shadowDoms.has(e))return;this.shadowDoms.add(e),this.bypassOptions.canvasManager.addShadowRoot(e);let n=i7({...this.bypassOptions,doc:t,mutationCb:this.mutationCb,mirror:this.mirror,shadowDomManager:this},e);this.restoreHandlers.push(()=>n.disconnect()),this.restoreHandlers.push(oe({...this.bypassOptions,scrollCb:this.scrollCb,doc:e,mirror:this.mirror})),iX(()=>{e.adoptedStyleSheets&&e.adoptedStyleSheets.length>0&&this.bypassOptions.stylesheetManager.adoptStyleSheets(e.adoptedStyleSheets,this.mirror.getId(e.host)),this.restoreHandlers.push(oo({mirror:this.mirror,stylesheetManager:this.bypassOptions.stylesheetManager},e))},0)}observeAttachShadow(e){let t=iK(e),n=function(e){try{return e.contentWindow}catch(e){}}(e);t&&n&&this.patchAttachShadow(n.Element,t)}patchAttachShadow(e,t){let n=this;this.restoreHandlers.push(iN(e.prototype,"attachShadow",function(e){return function(r){let i=e.call(this,r);return this.shadowRoot&&iW(this)&&n.addShadowRoot(this.shadowRoot,t),i}}))}reset(){this.restoreHandlers.forEach(e=>{try{e()}catch(e){}}),this.restoreHandlers=[],this.shadowDoms=new WeakSet,this.bypassOptions.canvasManager.resetShadowRoots()}}class om{reset(){}freeze(){}unfreeze(){}lock(){}unlock(){}snapshot(){}addWindow(){}addShadowRoot(){}resetShadowRoots(){}}class og{constructor(e){this.trackedLinkElements=new WeakSet,this.styleMirror=new iq,this.mutationCb=e.mutationCb,this.adoptedStyleSheetCb=e.adoptedStyleSheetCb}attachLinkElement(e,t){"_cssText"in t.attributes&&this.mutationCb({adds:[],removes:[],texts:[],attributes:[{id:t.id,attributes:t.attributes}]}),this.trackLinkElement(e)}trackLinkElement(e){this.trackedLinkElements.has(e)||(this.trackedLinkElements.add(e),this.trackStylesheetInLinkElement(e))}adoptStyleSheets(e,t){if(0===e.length)return;let n={id:t,styleIds:[]},r=[];for(let t of e){let e;this.styleMirror.has(t)?e=this.styleMirror.getId(t):(e=this.styleMirror.add(t),r.push({styleId:e,rules:Array.from(t.rules||CSSRule,(e,t)=>({rule:rK(e),index:t}))})),n.styleIds.push(e)}r.length>0&&(n.styles=r),this.adoptedStyleSheetCb(n)}reset(){this.styleMirror.reset(),this.trackedLinkElements=new WeakSet}trackStylesheetInLinkElement(e){}}class o_{constructor(){this.nodeMap=new WeakMap,this.active=!1}inOtherBuffer(e,t){let n=this.nodeMap.get(e);return n&&Array.from(n).some(e=>e!==t)}add(e,t){this.active||(this.active=!0,function(...e){iz("requestAnimationFrame")(...e)}(()=>{this.nodeMap=new WeakMap,this.active=!1})),this.nodeMap.set(e,(this.nodeMap.get(e)||new Set).add(t))}destroy(){}}try{if(2!==Array.from([1],e=>2*e)[0]){let e=document.createElement("iframe");document.body.appendChild(e),Array.from=S([e,"access",e=>e.contentWindow,"optionalAccess",e=>e.Array,"access",e=>e.from])||Array.from,document.body.removeChild(e)}}catch(e){console.debug("Unable to override Array.from",e)}let oy=new rQ;function ov(e={}){let t;let{emit:n,checkoutEveryNms:r,checkoutEveryNth:i,blockClass:o="rr-block",blockSelector:s=null,unblockSelector:a=null,ignoreClass:c="rr-ignore",ignoreSelector:l=null,maskAllText:u=!1,maskTextClass:d="rr-mask",unmaskTextClass:h=null,maskTextSelector:f=null,unmaskTextSelector:p=null,inlineStylesheet:m=!0,maskAllInputs:g,maskInputOptions:_,slimDOMOptions:b,maskAttributeFn:T,maskInputFn:w,maskTextFn:O,maxCanvasSize:C=null,packFn:R,sampling:A={},dataURLOptions:k={},mousemoveWait:N,recordDOM:I=!0,recordCanvas:x=!1,recordCrossOriginIframes:D=!1,recordAfter:P="DOMContentLoaded"===e.recordAfter?e.recordAfter:"load",userTriggeredOnInput:M=!1,collectFonts:L=!1,inlineImages:j=!1,plugins:U,keepIframeSrcFn:$=()=>!1,ignoreCSSAttributes:B=new Set([]),errorHandler:F,onMutation:q,getCanvasManager:H}=e;y=F;let W=!D||window.parent===window,G=!1;if(!W)try{window.parent.document&&(G=!1)}catch(e){G=!0}if(W&&!n)throw Error("emit function is required");if(!W&&!G)return()=>{};void 0!==N&&void 0===A.mousemove&&(A.mousemove=N),oy.reset();let z=!0===g?{color:!0,date:!0,"datetime-local":!0,email:!0,month:!0,number:!0,range:!0,search:!0,tel:!0,text:!0,time:!0,url:!0,week:!0,textarea:!0,select:!0,radio:!0,checkbox:!0}:void 0!==_?_:{},X=!0===b||"all"===b?{script:!0,comment:!0,headFavicon:!0,headWhitespace:!0,headMetaSocial:!0,headMetaRobots:!0,headMetaHttpEquiv:!0,headMetaVerification:!0,headMetaAuthorship:"all"===b,headMetaDescKeywords:"all"===b}:b||{};!function(e=window){"NodeList"in e&&!e.NodeList.prototype.forEach&&(e.NodeList.prototype.forEach=Array.prototype.forEach),"DOMTokenList"in e&&!e.DOMTokenList.prototype.forEach&&(e.DOMTokenList.prototype.forEach=Array.prototype.forEach),Node.prototype.contains||(Node.prototype.contains=(...e)=>{let t=e[0];if(!(0 in e))throw TypeError("1 argument is required");do if(this===t)return!0;while(t=t&&t.parentNode);return!1})}();let J=0,V=e=>{for(let t of U||[])t.eventProcessor&&(e=t.eventProcessor(e));return R&&!G&&(e=R(e)),e};v=(e,o)=>{if(e.timestamp=iI(),S([i8,"access",e=>e[0],"optionalAccess",e=>e.isFrozen,"call",e=>e()])&&e.type!==iJ.FullSnapshot&&!(e.type===iJ.IncrementalSnapshot&&e.data.source===iV.Mutation)&&i8.forEach(e=>e.unfreeze()),W)S([n,"optionalCall",t=>t(V(e),o)]);else if(G){let t={type:"rrweb",event:V(e),origin:window.location.origin,isCheckout:o};window.parent.postMessage(t,"*")}if(e.type===iJ.FullSnapshot)t=e,J=0;else if(e.type===iJ.IncrementalSnapshot){if(e.data.source===iV.Mutation&&e.data.isAttachIframe)return;J++;let n=i&&J>=i,o=r&&t&&e.timestamp-t.timestamp>r;(n||o)&&ei(!0)}};let Y=e=>{v({type:iJ.IncrementalSnapshot,data:{source:iV.Mutation,...e}})},Z=e=>v({type:iJ.IncrementalSnapshot,data:{source:iV.Scroll,...e}}),K=e=>v({type:iJ.IncrementalSnapshot,data:{source:iV.CanvasMutation,...e}}),Q=new og({mutationCb:Y,adoptedStyleSheetCb:e=>v({type:iJ.IncrementalSnapshot,data:{source:iV.AdoptedStyleSheet,...e}})}),ee="boolean"==typeof __RRWEB_EXCLUDE_IFRAME__&&__RRWEB_EXCLUDE_IFRAME__?new od:new oh({mirror:oy,mutationCb:Y,stylesheetManager:Q,recordCrossOriginIframes:D,wrappedEmit:v});for(let e of U||[])e.getMirror&&e.getMirror({nodeMirror:oy,crossOriginIframeMirror:ee.crossOriginIframeMirror,crossOriginIframeStyleMirror:ee.crossOriginIframeStyleMirror});let et=new o_,en=function(e,t){try{return e?e(t):new om}catch(e){return console.warn("Unable to initialize CanvasManager"),new om}}(H,{mirror:oy,win:window,mutationCb:e=>v({type:iJ.IncrementalSnapshot,data:{source:iV.CanvasMutation,...e}}),recordCanvas:x,blockClass:o,blockSelector:s,unblockSelector:a,maxCanvasSize:C,sampling:A.canvas,dataURLOptions:k,errorHandler:F}),er="boolean"==typeof __RRWEB_EXCLUDE_SHADOW_DOM__&&__RRWEB_EXCLUDE_SHADOW_DOM__?new of:new op({mutationCb:Y,scrollCb:Z,bypassOptions:{onMutation:q,blockClass:o,blockSelector:s,unblockSelector:a,maskAllText:u,maskTextClass:d,unmaskTextClass:h,maskTextSelector:f,unmaskTextSelector:p,inlineStylesheet:m,maskInputOptions:z,dataURLOptions:k,maskAttributeFn:T,maskTextFn:O,maskInputFn:w,recordCanvas:x,inlineImages:j,sampling:A,slimDOMOptions:X,iframeManager:ee,stylesheetManager:Q,canvasManager:en,keepIframeSrcFn:$,processedNodeManager:et},mirror:oy}),ei=(e=!1)=>{if(!I)return;v({type:iJ.Meta,data:{href:window.location.href,width:iP(),height:iD()}},e),Q.reset(),er.init(),i8.forEach(e=>e.lock());let t=function(e,t){let{mirror:n=new rQ,blockClass:r="rr-block",blockSelector:i=null,unblockSelector:o=null,maskAllText:s=!1,maskTextClass:a="rr-mask",unmaskTextClass:c=null,maskTextSelector:l=null,unmaskTextSelector:u=null,inlineStylesheet:d=!0,inlineImages:h=!1,recordCanvas:f=!1,maskAllInputs:p=!1,maskAttributeFn:m,maskTextFn:g,maskInputFn:_,slimDOM:y=!1,dataURLOptions:v,preserveWhiteSpace:E,onSerialize:b,onIframeLoad:S,iframeLoadTimeout:T,onStylesheetLoad:w,stylesheetLoadTimeout:O,keepIframeSrcFn:C=()=>!1}=t||{};return iw(e,{doc:e,mirror:n,blockClass:r,blockSelector:i,unblockSelector:o,maskAllText:s,maskTextClass:a,unmaskTextClass:c,maskTextSelector:l,unmaskTextSelector:u,skipChild:!1,inlineStylesheet:d,maskInputOptions:!0===p?{color:!0,date:!0,"datetime-local":!0,email:!0,month:!0,number:!0,range:!0,search:!0,tel:!0,text:!0,time:!0,url:!0,week:!0,textarea:!0,select:!0}:!1===p?{}:p,maskAttributeFn:m,maskTextFn:g,maskInputFn:_,slimDOMOptions:!0===y||"all"===y?{script:!0,comment:!0,headFavicon:!0,headWhitespace:!0,headMetaDescKeywords:"all"===y,headMetaSocial:!0,headMetaRobots:!0,headMetaHttpEquiv:!0,headMetaAuthorship:!0,headMetaVerification:!0}:!1===y?{}:y,dataURLOptions:v,inlineImages:h,recordCanvas:f,preserveWhiteSpace:E,onSerialize:b,onIframeLoad:S,iframeLoadTimeout:T,onStylesheetLoad:w,stylesheetLoadTimeout:O,keepIframeSrcFn:C,newlyAddedElement:!1})}(document,{mirror:oy,blockClass:o,blockSelector:s,unblockSelector:a,maskAllText:u,maskTextClass:d,unmaskTextClass:h,maskTextSelector:f,unmaskTextSelector:p,inlineStylesheet:m,maskAllInputs:z,maskAttributeFn:T,maskInputFn:w,maskTextFn:O,slimDOM:X,dataURLOptions:k,recordCanvas:x,inlineImages:j,onSerialize:e=>{i$(e,oy)&&ee.addIframe(e),iB(e,oy)&&Q.trackLinkElement(e),iF(e)&&er.addShadowRoot(e.shadowRoot,document)},onIframeLoad:(e,t)=>{ee.attachIframe(e,t),e.contentWindow&&en.addWindow(e.contentWindow),er.observeAttachShadow(e)},onStylesheetLoad:(e,t)=>{Q.attachLinkElement(e,t)},keepIframeSrcFn:$});if(!t)return console.warn("Failed to snapshot the document");v({type:iJ.FullSnapshot,data:{node:t,initialOffset:ix(window)}}),i8.forEach(e=>e.unlock()),document.adoptedStyleSheets&&document.adoptedStyleSheets.length>0&&Q.adoptStyleSheets(document.adoptedStyleSheets,oy.getId(document))};E=ei;try{let e=[],t=e=>i4(os)({onMutation:q,mutationCb:Y,mousemoveCb:(e,t)=>v({type:iJ.IncrementalSnapshot,data:{source:t,positions:e}}),mouseInteractionCb:e=>v({type:iJ.IncrementalSnapshot,data:{source:iV.MouseInteraction,...e}}),scrollCb:Z,viewportResizeCb:e=>v({type:iJ.IncrementalSnapshot,data:{source:iV.ViewportResize,...e}}),inputCb:e=>v({type:iJ.IncrementalSnapshot,data:{source:iV.Input,...e}}),mediaInteractionCb:e=>v({type:iJ.IncrementalSnapshot,data:{source:iV.MediaInteraction,...e}}),styleSheetRuleCb:e=>v({type:iJ.IncrementalSnapshot,data:{source:iV.StyleSheetRule,...e}}),styleDeclarationCb:e=>v({type:iJ.IncrementalSnapshot,data:{source:iV.StyleDeclaration,...e}}),canvasMutationCb:K,fontCb:e=>v({type:iJ.IncrementalSnapshot,data:{source:iV.Font,...e}}),selectionCb:e=>{v({type:iJ.IncrementalSnapshot,data:{source:iV.Selection,...e}})},customElementCb:e=>{v({type:iJ.IncrementalSnapshot,data:{source:iV.CustomElement,...e}})},blockClass:o,ignoreClass:c,ignoreSelector:l,maskAllText:u,maskTextClass:d,unmaskTextClass:h,maskTextSelector:f,unmaskTextSelector:p,maskInputOptions:z,inlineStylesheet:m,sampling:A,recordDOM:I,recordCanvas:x,inlineImages:j,userTriggeredOnInput:M,collectFonts:L,doc:e,maskAttributeFn:T,maskInputFn:w,maskTextFn:O,keepIframeSrcFn:$,blockSelector:s,unblockSelector:a,slimDOMOptions:X,dataURLOptions:k,mirror:oy,iframeManager:ee,stylesheetManager:Q,shadowDomManager:er,processedNodeManager:et,canvasManager:en,ignoreCSSAttributes:B,plugins:S([U,"optionalAccess",e=>e.filter,"call",e=>e(e=>e.observer),"optionalAccess",e=>e.map,"call",e=>e(e=>({observer:e.observer,options:e.options,callback:t=>v({type:iJ.Plugin,data:{plugin:e.name,payload:t}})}))])||[]},{});ee.addLoadListener(n=>{try{e.push(t(n.contentDocument))}catch(e){console.warn(e)}});let n=()=>{ei(),e.push(t(document))};return"interactive"===document.readyState||"complete"===document.readyState?n():(e.push(iC("DOMContentLoaded",()=>{v({type:iJ.DomContentLoaded,data:{}}),"DOMContentLoaded"===P&&n()})),e.push(iC("load",()=>{v({type:iJ.Load,data:{}}),"load"===P&&n()},window))),()=>{e.forEach(e=>e()),et.destroy(),E=void 0,y=void 0}}catch(e){console.warn(e)}}function oE(e){return e>9999999999?e:1e3*e}function ob(e){return e>9999999999?e/1e3:e}function oS(e,t){"sentry.transaction"!==t.category&&(["ui.click","ui.input"].includes(t.category)?e.triggerUserActivity():e.checkAndHandleExpiredSession(),e.addUpdate(()=>(e.throttledAddEvent({type:iJ.Custom,timestamp:1e3*(t.timestamp||0),data:{tag:"breadcrumb",payload:(0,eh.Fv)(t,10,1e3)}}),"console"===t.category)))}function oT(e){return e.closest("button,a")||e}function ow(e){let t=oO(e);return t&&t instanceof Element?oT(t):t}function oO(e){return"object"==typeof e&&e&&"target"in e?e.target:e}ov.mirror=oy,ov.takeFullSnapshot=function(e){if(!E)throw Error("please take full snapshot after start recording");E(e)};let oC=new Set([iV.Mutation,iV.StyleSheetRule,iV.StyleDeclaration,iV.AdoptedStyleSheet,iV.CanvasMutation,iV.Selection,iV.MediaInteraction]);class oR{constructor(e,t,n=oS){this._lastMutation=0,this._lastScroll=0,this._clicks=[],this._timeout=t.timeout/1e3,this._threshold=t.threshold/1e3,this._scrollTimeout=t.scrollTimeout/1e3,this._replay=e,this._ignoreSelector=t.ignoreSelector,this._addBreadcrumbEvent=n}addListeners(){var e;let t=(e=()=>{this._lastMutation=ok()},b||(b=[],(0,Y.hl)(rW,"open",function(e){return function(...t){if(b)try{b.forEach(e=>e())}catch(e){}return e.apply(rW,t)}})),b.push(e),()=>{let t=b?b.indexOf(e):-1;t>-1&&b.splice(t,1)});this._teardown=()=>{t(),this._clicks=[],this._lastMutation=0,this._lastScroll=0}}removeListeners(){this._teardown&&this._teardown(),this._checkClickTimeout&&clearTimeout(this._checkClickTimeout)}handleClick(e,t){var n;if(n=this._ignoreSelector,!oA.includes(t.tagName)||"INPUT"===t.tagName&&!["submit","button"].includes(t.getAttribute("type")||"")||"A"===t.tagName&&(t.hasAttribute("download")||t.hasAttribute("target")&&"_self"!==t.getAttribute("target"))||n&&t.matches(n)||!(e.data&&"number"==typeof e.data.nodeId&&e.timestamp))return;let r={timestamp:ob(e.timestamp),clickBreadcrumb:e,clickCount:0,node:t};this._clicks.some(e=>e.node===r.node&&1>Math.abs(e.timestamp-r.timestamp))||(this._clicks.push(r),1===this._clicks.length&&this._scheduleCheckClicks())}registerMutation(e=Date.now()){this._lastMutation=ob(e)}registerScroll(e=Date.now()){this._lastScroll=ob(e)}registerClick(e){let t=oT(e);this._handleMultiClick(t)}_handleMultiClick(e){this._getClicks(e).forEach(e=>{e.clickCount++})}_getClicks(e){return this._clicks.filter(t=>t.node===e)}_checkClicks(){let e=[],t=ok();for(let n of(this._clicks.forEach(n=>{!n.mutationAfter&&this._lastMutation&&(n.mutationAfter=n.timestamp<=this._lastMutation?this._lastMutation-n.timestamp:void 0),!n.scrollAfter&&this._lastScroll&&(n.scrollAfter=n.timestamp<=this._lastScroll?this._lastScroll-n.timestamp:void 0),n.timestamp+this._timeout<=t&&e.push(n)}),e)){let e=this._clicks.indexOf(n);e>-1&&(this._generateBreadcrumbs(n),this._clicks.splice(e,1))}this._clicks.length&&this._scheduleCheckClicks()}_generateBreadcrumbs(e){let t=this._replay,n=e.scrollAfter&&e.scrollAfter<=this._scrollTimeout,r=e.mutationAfter&&e.mutationAfter<=this._threshold,{clickCount:i,clickBreadcrumb:o}=e;if(!n&&!r){let n=1e3*Math.min(e.mutationAfter||this._timeout,this._timeout),r=n<1e3*this._timeout?"mutation":"timeout",s={type:"default",message:o.message,timestamp:o.timestamp,category:"ui.slowClickDetected",data:{...o.data,url:rW.location.href,route:t.getCurrentRoute(),timeAfterClickMs:n,endReason:r,clickCount:i||1}};this._addBreadcrumbEvent(t,s);return}if(i>1){let e={type:"default",message:o.message,timestamp:o.timestamp,category:"ui.multiClick",data:{...o.data,url:rW.location.href,route:t.getCurrentRoute(),clickCount:i,metric:!0}};this._addBreadcrumbEvent(t,e)}}_scheduleCheckClicks(){this._checkClickTimeout&&clearTimeout(this._checkClickTimeout),this._checkClickTimeout=tL(()=>this._checkClicks(),1e3)}}let oA=["A","BUTTON","INPUT"];function ok(){return Date.now()/1e3}function oN(e){return{timestamp:Date.now()/1e3,type:"default",...e}}(N=P||(P={}))[N.Document=0]="Document",N[N.DocumentType=1]="DocumentType",N[N.Element=2]="Element",N[N.Text=3]="Text",N[N.CDATA=4]="CDATA",N[N.Comment=5]="Comment";let oI=new Set(["id","class","aria-label","role","name","alt","title","data-test-id","data-testid","disabled","aria-disabled","data-sentry-component"]),ox=e=>t=>{if(!e.isEnabled())return;let n=function(e){let{target:t,message:n}=function(e){let t;let n="click"===e.name,r=null;try{r=n?ow(e.event):oO(e.event),t=(0,tt.Rt)(r,{maxStringLength:200})||""}catch(e){t=""}return{target:r,message:t}}(e);return oN({category:`ui.${e.name}`,...oD(t,n)})}(t);if(!n)return;let r="click"===t.name,i=r?t.event:void 0;r&&e.clickDetector&&i&&i.target&&!i.altKey&&!i.metaKey&&!i.ctrlKey&&!i.shiftKey&&function(e,t,n){e.handleClick(t,n)}(e.clickDetector,n,ow(t.event)),oS(e,n)};function oD(e,t){let n=ov.mirror.getId(e),r=n&&ov.mirror.getNode(n),i=r&&ov.mirror.getMeta(r),o=i&&i.type===P.Element?i:null;return{message:t,data:o?{nodeId:n,node:{id:n,tagName:o.tagName,textContent:Array.from(o.childNodes).map(e=>e.type===P.Text&&e.textContent).filter(Boolean).map(e=>e.trim()).join(""),attributes:function(e){let t={};for(let n in!e["data-sentry-component"]&&e["data-sentry-element"]&&(e["data-sentry-component"]=e["data-sentry-element"]),e)if(oI.has(n)){let r=n;("data-testid"===n||"data-test-id"===n)&&(r="testId"),t[r]=e[n]}return t}(o.attributes)}}:{}}}let oP={resource:function(e){let{entryType:t,initiatorType:n,name:r,responseEnd:i,startTime:o,decodedBodySize:s,encodedBodySize:a,responseStatus:c,transferSize:l}=e;return["fetch","xmlhttprequest"].includes(n)?null:{type:`${t}.${n}`,start:oj(o),end:oj(i),name:r,data:{size:l,statusCode:c,decodedBodySize:s,encodedBodySize:a}}},paint:function(e){let{duration:t,entryType:n,name:r,startTime:i}=e,o=oj(i);return{type:n,name:r,start:o,end:o+t,data:void 0}},navigation:function(e){let{entryType:t,name:n,decodedBodySize:r,duration:i,domComplete:o,encodedBodySize:s,domContentLoadedEventStart:a,domContentLoadedEventEnd:c,domInteractive:l,loadEventStart:u,loadEventEnd:d,redirectCount:h,startTime:f,transferSize:p,type:m}=e;return 0===i?null:{type:`${t}.${m}`,start:oj(f),end:oj(o),name:n,data:{size:p,decodedBodySize:r,encodedBodySize:s,duration:i,domInteractive:l,domContentLoadedEventStart:a,domContentLoadedEventEnd:c,loadEventStart:u,loadEventEnd:d,domComplete:o,redirectCount:h}}}};function oM(e,t){return({metric:n})=>void t.replayPerformanceEntries.push(e(n))}function oL(e){let t=oP[e.entryType];return t?t(e):null}function oj(e){return((eb.Z1||rW.performance.timeOrigin)+e)/1e3}function oU(e){let t=e.entries[e.entries.length-1];return oq(e,"largest-contentful-paint",t&&t.element?[t.element]:void 0)}function o$(e){let t=[],n=[];for(let r of e.entries)if(void 0!==r.sources){let e=[];for(let t of r.sources)if(t.node){n.push(t.node);let r=ov.mirror.getId(t.node);r&&e.push(r)}t.push({value:r.value,nodeIds:e.length?e:void 0})}return oq(e,"cumulative-layout-shift",n,t)}function oB(e){let t=e.entries[e.entries.length-1];return oq(e,"first-input-delay",t&&t.target?[t.target]:void 0)}function oF(e){let t=e.entries[e.entries.length-1];return oq(e,"interaction-to-next-paint",t&&t.target?[t.target]:void 0)}function oq(e,t,n,r){let i=e.value,o=e.rating,s=oj(i);return{type:"web-vital",name:t,start:s,end:s,data:{value:i,size:i,rating:o,nodeIds:n?n.map(e=>ov.mirror.getId(e)):void 0,attributions:r}}}let oH=["info","warn","error","log"];(function(){let e={exception:()=>void 0,infoTick:()=>void 0,setConfig:e=>{e.captureExceptions,e.traceInternals}};oH.forEach(t=>{e[t]=()=>void 0})})();class oW extends Error{constructor(){super("Event buffer exceeded maximum size of 20000000.")}}class oG{constructor(){this.events=[],this._totalSize=0,this.hasCheckout=!1,this.waitForCheckout=!1}get hasEvents(){return this.events.length>0}get type(){return"sync"}destroy(){this.events=[]}async addEvent(e){let t=JSON.stringify(e).length;if(this._totalSize+=t,this._totalSize>2e7)throw new oW;this.events.push(e)}finish(){return new Promise(e=>{let t=this.events;this.clear(),e(JSON.stringify(t))})}clear(){this.events=[],this._totalSize=0,this.hasCheckout=!1}getEarliestTimestamp(){let e=this.events.map(e=>e.timestamp).sort()[0];return e?oE(e):null}}class oz{constructor(e){this._worker=e,this._id=0}ensureReady(){return this._ensureReadyPromise||(this._ensureReadyPromise=new Promise((e,t)=>{this._worker.addEventListener("message",({data:n})=>{n.success?e():t()},{once:!0}),this._worker.addEventListener("error",e=>{t(e)},{once:!0})})),this._ensureReadyPromise}destroy(){this._worker.terminate()}postMessage(e,t){let n=this._getAndIncrementId();return new Promise((r,i)=>{let o=({data:t})=>{if(t.method===e&&t.id===n){if(this._worker.removeEventListener("message",o),!t.success){i(Error("Error in compression worker"));return}r(t.response)}};this._worker.addEventListener("message",o),this._worker.postMessage({id:n,method:e,arg:t})})}_getAndIncrementId(){return this._id++}}class oX{constructor(e){this._worker=new oz(e),this._earliestTimestamp=null,this._totalSize=0,this.hasCheckout=!1,this.waitForCheckout=!1}get hasEvents(){return!!this._earliestTimestamp}get type(){return"worker"}ensureReady(){return this._worker.ensureReady()}destroy(){this._worker.destroy()}addEvent(e){let t=oE(e.timestamp);(!this._earliestTimestamp||t2e7)?Promise.reject(new oW):this._sendEventToWorker(n)}finish(){return this._finishRequest()}clear(){this._earliestTimestamp=null,this._totalSize=0,this.hasCheckout=!1,this._worker.postMessage("clear").then(null,e=>{})}getEarliestTimestamp(){return this._earliestTimestamp}_sendEventToWorker(e){return this._worker.postMessage("addEvent",e)}async _finishRequest(){let e=await this._worker.postMessage("finish");return this._earliestTimestamp=null,this._totalSize=0,e}}class oJ{constructor(e){this._fallback=new oG,this._compression=new oX(e),this._used=this._fallback,this._ensureWorkerIsLoadedPromise=this._ensureWorkerIsLoaded()}get waitForCheckout(){return this._used.waitForCheckout}get type(){return this._used.type}get hasEvents(){return this._used.hasEvents}get hasCheckout(){return this._used.hasCheckout}set hasCheckout(e){this._used.hasCheckout=e}set waitForCheckout(e){this._used.waitForCheckout=e}destroy(){this._fallback.destroy(),this._compression.destroy()}clear(){return this._used.clear()}getEarliestTimestamp(){return this._used.getEarliestTimestamp()}addEvent(e){return this._used.addEvent(e)}async finish(){return await this.ensureWorkerIsLoaded(),this._used.finish()}ensureWorkerIsLoaded(){return this._ensureWorkerIsLoadedPromise}async _ensureWorkerIsLoaded(){try{await this._compression.ensureReady()}catch(e){return}await this._switchToCompressionWorker()}async _switchToCompressionWorker(){let{events:e,hasCheckout:t,waitForCheckout:n}=this._fallback,r=[];for(let t of e)r.push(this._compression.addEvent(t));this._compression.hasCheckout=t,this._compression.waitForCheckout=n,this._used=this._compression;try{await Promise.all(r),this._fallback.clear()}catch(e){}}}function oV(){try{return"sessionStorage"in rW&&!!rW.sessionStorage}catch(e){return!1}}function oY(e){return void 0!==e&&Math.random()e.getContext().initialTimestamp+e.getOptions().maxReplayDuration)}function o8(e){return"transaction"===e.type}function o9(e){return"feedback"===e.type}function o7(e){return!!e.category}function se(){let e=(0,V.nZ)().getPropagationContext().dsc;e&&delete e.replay_id;let t=(0,ev.HN)();if(t){let e=(0,ea.jC)(t);delete e.replay_id}}function st(e,t){return t.map(({type:t,start:n,end:r,name:i,data:o})=>{let s=e.throttledAddEvent({type:iJ.Custom,timestamp:n,data:{tag:"performanceSpan",payload:{op:t,description:i,startTimestamp:n,endTimestamp:r,data:o}}});return"string"==typeof s?Promise.resolve(null):s})}function sn(e,t){e.isEnabled()&&null!==t&&!function(e,t){let n=t&&t.getDsn(),r=t&&t.getOptions().tunnel;return!!n&&e.includes(n.host)||!!r&&rF(e)===rF(r)}(t.name,(0,V.s3)())&&e.addUpdate(()=>(st(e,[t]),!0))}function sr(e){if(!e)return;let t=new TextEncoder;try{if("string"==typeof e)return t.encode(e).length;if(e instanceof URLSearchParams)return t.encode(e.toString()).length;if(e instanceof FormData){let n=sd(e);return t.encode(n).length}if(e instanceof Blob)return e.size;if(e instanceof ArrayBuffer)return e.byteLength}catch(e){}}function si(e){if(!e)return;let t=parseInt(e,10);return isNaN(t)?void 0:t}function so(e){try{if("string"==typeof e)return[e];if(e instanceof URLSearchParams)return[e.toString()];if(e instanceof FormData)return[sd(e)];if(!e)return[void 0]}catch(e){return[void 0,"BODY_PARSE_ERROR"]}return[void 0,"UNPARSEABLE_BODY_TYPE"]}function ss(e,t){if(!e)return{headers:{},size:void 0,_meta:{warnings:[t]}};let n={...e._meta},r=n.warnings||[];return n.warnings=[...r,t],e._meta=n,e}function sa(e,t){if(!t)return null;let{startTimestamp:n,endTimestamp:r,url:i,method:o,statusCode:s,request:a,response:c}=t;return{type:e,start:n/1e3,end:r/1e3,name:i,data:(0,Y.Jr)({method:o,statusCode:s,request:a,response:c})}}function sc(e){return{headers:{},size:e,_meta:{warnings:["URL_SKIPPED"]}}}function sl(e,t,n){if(!t&&0===Object.keys(e).length)return;if(!t)return{headers:e};if(!n)return{headers:e,size:t};let r={headers:e,size:t},{body:i,warnings:o}=function(e){if(!e||"string"!=typeof e)return{body:e};let t=e.length>15e4,n=function(e){let t=e[0],n=e[e.length-1];return"["===t&&"]"===n||"{"===t&&"}"===n}(e);if(t){let t=e.slice(0,15e4);return n?{body:t,warnings:["MAYBE_JSON_TRUNCATED"]}:{body:`${t}…`,warnings:["TEXT_TRUNCATED"]}}if(n)try{return{body:JSON.parse(e)}}catch(e){}return{body:e}}(n);return r.body=i,o&&o.length>0&&(r._meta={warnings:o}),r}function su(e,t){return Object.entries(e).reduce((n,[r,i])=>{let o=r.toLowerCase();return t.includes(o)&&e[r]&&(n[o]=i),n},{})}function sd(e){return new URLSearchParams(e).toString()}function sh(e,t){let n=function(e,t=rW.document.baseURI){if(e.startsWith("http://")||e.startsWith("https://")||e.startsWith(rW.location.origin))return e;let n=new URL(e,t);if(n.origin!==new URL(t).origin)return e;let r=n.href;return!e.endsWith("/")&&r.endsWith("/")?r.slice(0,-1):r}(e);return(0,G.U0)(n,t)}async function sf(e,t,n){try{let r=await sp(e,t,n),i=sa("resource.fetch",r);sn(n.replay,i)}catch(e){}}async function sp(e,t,n){let r=Date.now(),{startTimestamp:i=r,endTimestamp:o=r}=t,{url:s,method:a,status_code:c=0,request_body_size:l,response_body_size:u}=e.data,d=sh(s,n.networkDetailAllowUrls)&&!sh(s,n.networkDetailDenyUrls);return{startTimestamp:i,endTimestamp:o,url:s,method:a,statusCode:c,request:d?function({networkCaptureBodies:e,networkRequestHeaders:t},n,r){let i=n?1===n.length&&"string"!=typeof n[0]?sv(n[0],t):2===n.length?sv(n[1],t):{}:{};if(!e)return sl(i,r,void 0);let[o,s]=so(s_(n)),a=sl(i,r,o);return s?ss(a,s):a}(n,t.input,l):sc(l),response:await sm(d,n,t.response,u)}}async function sm(e,{networkCaptureBodies:t,networkResponseHeaders:n},r,i){if(!e&&void 0!==i)return sc(i);let o=r?sy(r.headers,n):{};if(!r||!t&&void 0!==i)return sl(o,i,void 0);let[s,a]=await sg(r),c=function(e,{networkCaptureBodies:t,responseBodySize:n,captureDetails:r,headers:i}){try{let o=e&&e.length&&void 0===n?sr(e):n;if(!r)return sc(o);if(t)return sl(i,o,e);return sl(i,o,void 0)}catch(e){return sl(i,n,void 0)}}(s,{networkCaptureBodies:t,responseBodySize:i,captureDetails:e,headers:o});return a?ss(c,a):c}async function sg(e){let t=function(e){try{return e.clone()}catch(e){}}(e);if(!t)return[void 0,"BODY_PARSE_ERROR"];try{return[await new Promise((e,n)=>{let r=tL(()=>n(Error("Timeout while trying to read response body")),500);sE(t).then(t=>e(t),e=>n(e)).finally(()=>clearTimeout(r))})]}catch(e){if(e instanceof Error&&e.message.indexOf("Timeout")>-1)return[void 0,"BODY_PARSE_TIMEOUT"];return[void 0,"BODY_PARSE_ERROR"]}}function s_(e=[]){if(2===e.length&&"object"==typeof e[1])return e[1].body}function sy(e,t){let n={};return t.forEach(t=>{e.get(t)&&(n[t]=e.get(t))}),n}function sv(e,t){if(!e)return{};let n=e.headers;return n?n instanceof Headers?sy(n,t):Array.isArray(n)?{}:su(n,t):{}}async function sE(e){return await e.text()}async function sb(e,t,n){try{let r=function(e,t,n){let r=Date.now(),{startTimestamp:i=r,endTimestamp:o=r,input:s,xhr:a}=t,{url:c,method:l,status_code:u=0,request_body_size:d,response_body_size:h}=e.data;if(!c)return null;if(!a||!sh(c,n.networkDetailAllowUrls)||sh(c,n.networkDetailDenyUrls)){let e=sc(d);return{startTimestamp:i,endTimestamp:o,url:c,method:l,statusCode:u,request:e,response:sc(h)}}let f=a[eZ],p=f?su(f.request_headers,n.networkRequestHeaders):{},m=su(function(e){let t=e.getAllResponseHeaders();return t?t.split("\r\n").reduce((e,t)=>{let[n,r]=t.split(": ");return r&&(e[n.toLowerCase()]=r),e},{}):{}}(a),n.networkResponseHeaders),[g,_]=n.networkCaptureBodies?so(s):[void 0],[y,v]=n.networkCaptureBodies?function(e){let t=[];try{return[e.responseText]}catch(e){t.push(e)}try{return function(e,t){try{if("string"==typeof e)return[e];if(e instanceof Document)return[e.body.outerHTML];if("json"===t&&e&&"object"==typeof e)return[JSON.stringify(e)];if(!e)return[void 0]}catch(e){return[void 0,"BODY_PARSE_ERROR"]}return[void 0,"UNPARSEABLE_BODY_TYPE"]}(e.response,e.responseType)}catch(e){t.push(e)}return[void 0]}(a):[void 0],E=sl(p,d,g),b=sl(m,h,y);return{startTimestamp:i,endTimestamp:o,url:c,method:l,statusCode:u,request:_?ss(E,_):E,response:v?ss(b,v):b}}(e,t,n),i=sa("resource.xhr",r);sn(n.replay,i)}catch(e){}}async function sS(e){try{return Promise.all(st(e,[function(e){let{jsHeapSizeLimit:t,totalJSHeapSize:n,usedJSHeapSize:r}=e,i=Date.now()/1e3;return{type:"memory",name:"memory",start:i,end:i,data:{memory:{jsHeapSizeLimit:t,totalJSHeapSize:n,usedJSHeapSize:r}}}}(rW.performance.memory)]))}catch(e){return[]}}async function sT({client:e,scope:t,replayId:n,event:r}){let i={event_id:n,integrations:"object"!=typeof e._integrations||null===e._integrations||Array.isArray(e._integrations)?void 0:Object.keys(e._integrations)};e.emit("preprocessEvent",r,i);let o=await (0,eC.R)(e.getOptions(),r,i,t,e,(0,V.aF)());if(!o)return null;o.platform=o.platform||"javascript";let s=e.getSdkMetadata(),{name:a,version:c}=s&&s.sdk||{};return o.sdk={...o.sdk,name:a||"sentry.javascript.unknown",version:c||"0.0.0"},o}async function sw({recordingData:e,replayId:t,segmentId:n,eventContext:r,timestamp:i,session:o}){var s;let a;let c=function({recordingData:e,headers:t}){let n;let r=`${JSON.stringify(t)} `;if("string"==typeof e)n=`${r}${e}`;else{let t=new TextEncoder().encode(r);(n=new Uint8Array(t.length+e.length)).set(t),n.set(e,t.length)}return n}({recordingData:e,headers:{segment_id:n}}),{urls:l,errorIds:u,traceIds:d,initialTimestamp:h}=r,f=(0,V.s3)(),p=(0,V.nZ)(),m=f&&f.getTransport(),g=f&&f.getDsn();if(!f||!m||!g||!o.sampled)return(0,ew.WD)({});let _={type:"replay_event",replay_start_timestamp:h/1e3,timestamp:i/1e3,error_ids:u,trace_ids:d,urls:l,replay_id:t,segment_id:n,replay_type:o.sampled},y=await sT({scope:p,client:f,replayId:t,event:_});if(!y)return f.recordDroppedEvent("event_processor","replay",_),(0,ew.WD)({});delete y.sdkProcessingMetadata;let v=(s=f.getOptions().tunnel,ef(ey(y,e_(y),s,g),[[{type:"replay_event"},y],[{type:"replay_recording",length:"string"==typeof c?new TextEncoder().encode(c).length:c.length},c]]));try{a=await m.send(v)}catch(t){let e=Error(rz);try{e.cause=t}catch(e){}throw e}if("number"==typeof a.statusCode&&(a.statusCode<200||a.statusCode>=300))throw new sO(a.statusCode);let E=tU({},a);if(tj(E,"replay"))throw new sC(E);return a}class sO extends Error{constructor(e){super(`Transport returned status code ${e}`)}}class sC extends Error{constructor(e){super("Rate limit hit"),this.rateLimits=e}}async function sR(e,t={count:0,interval:5e3}){let{recordingData:n,onError:r}=e;if(n.length)try{return await sw(e),!0}catch(n){if(n instanceof sO||n instanceof sC)throw n;if((0,U.v)("Replays",{_retryCount:t.count}),r&&r(n),t.count>=3){let e=Error(`${rz} - max retries exceeded`);try{e.cause=n}catch(e){}throw e}return t.interval*=++t.count,new Promise((n,r)=>{tL(async()=>{try{await sR(e,t),n(!0)}catch(e){r(e)}},t.interval)})}}let sA="__THROTTLED";class sk{constructor({options:e,recordingOptions:t}){sk.prototype.__init.call(this),sk.prototype.__init2.call(this),sk.prototype.__init3.call(this),sk.prototype.__init4.call(this),sk.prototype.__init5.call(this),sk.prototype.__init6.call(this),this.eventBuffer=null,this.performanceEntries=[],this.replayPerformanceEntries=[],this.recordingMode="session",this.timeouts={sessionIdlePause:3e5,sessionIdleExpire:9e5},this._lastActivity=Date.now(),this._isEnabled=!1,this._isPaused=!1,this._requiresManualStart=!1,this._hasInitializedCoreListeners=!1,this._context={errorIds:new Set,traceIds:new Set,urls:[],initialTimestamp:Date.now(),initialUrl:""},this._recordingOptions=t,this._options=e,this._debouncedFlush=function(e,t,n){let r,i,o;let s=n&&n.maxWait?Math.max(n.maxWait,t):0;function a(){return c(),r=e()}function c(){void 0!==i&&clearTimeout(i),void 0!==o&&clearTimeout(o),i=o=void 0}function l(){return i&&clearTimeout(i),i=tL(a,t),s&&void 0===o&&(o=tL(a,s)),r}return l.cancel=c,l.flush=function(){return void 0!==i||void 0!==o?a():r},l}(()=>this._flush(),this._options.flushMinDelay,{maxWait:this._options.flushMaxDelay}),this._throttledAddEvent=function(e,t,n){let r=new Map,i=e=>{let t=e-5;r.forEach((e,n)=>{n[...r.values()].reduce((e,t)=>e+t,0),s=!1;return(...t)=>{let n=Math.floor(Date.now()/1e3);if(i(n),o()>=300){let e=s;return s=!0,e?"__SKIPPED":sA}s=!1;let a=r.get(n)||0;return r.set(n,a+1),e(...t)}}((e,t)=>o6(this,e)?o4(this,e,t):Promise.resolve(null),0,0);let{slowClickTimeout:n,slowClickIgnoreSelectors:r}=this.getOptions(),i=n?{threshold:Math.min(3e3,n),timeout:n,scrollTimeout:300,ignoreSelector:r?r.join(","):""}:void 0;i&&(this.clickDetector=new oR(this,i))}getContext(){return this._context}isEnabled(){return this._isEnabled}isPaused(){return this._isPaused}isRecordingCanvas(){return!!this._canvas}getOptions(){return this._options}handleException(e){this._options.onError&&this._options.onError(e)}initializeSampling(e){let{errorSampleRate:t,sessionSampleRate:n}=this._options,r=t<=0&&n<=0;this._requiresManualStart=r,!r&&(this._initializeSessionForSampling(e),this.session)&&!1!==this.session.sampled&&(this.recordingMode="buffer"===this.session.sampled&&0===this.session.segmentId?"buffer":"session",this._initializeRecording())}start(){if(this._isEnabled&&"session"===this.recordingMode||this._isEnabled&&"buffer"===this.recordingMode)return;this._updateUserActivity();let e=o3({maxReplayDuration:this._options.maxReplayDuration,sessionIdleExpire:this.timeouts.sessionIdleExpire},{stickySession:this._options.stickySession,sessionSampleRate:1,allowBuffering:!1});this.session=e,this._initializeRecording()}startBuffering(){if(this._isEnabled)return;let e=o3({sessionIdleExpire:this.timeouts.sessionIdleExpire,maxReplayDuration:this._options.maxReplayDuration},{stickySession:this._options.stickySession,sessionSampleRate:0,allowBuffering:!0});this.session=e,this.recordingMode="buffer",this._initializeRecording()}startRecording(){try{var e;let t;let n=this._canvas;this._stopRecording=ov({...this._recordingOptions,..."buffer"===this.recordingMode?{checkoutEveryNms:6e4}:this._options._experiments.continuousCheckout&&{checkoutEveryNms:Math.max(36e4,this._options._experiments.continuousCheckout)},emit:(e=this,t=!1,(n,r)=>{if(!e.checkAndHandleExpiredSession())return;let i=r||!t;t=!0,e.clickDetector&&function(e,t){try{if(3!==t.type)return;let{source:n}=t.data;if(oC.has(n)&&e.registerMutation(t.timestamp),n===iV.Scroll&&e.registerScroll(t.timestamp),t.data.source===iV.MouseInteraction){let{type:n,id:r}=t.data,i=ov.mirror.getNode(r);i instanceof HTMLElement&&n===iY.Click&&e.registerClick(i)}}catch(e){}}(e.clickDetector,n),e.addUpdate(()=>{if("buffer"===e.recordingMode&&i&&e.setInitialState(),!o5(e,n,i))return!0;if(!i)return!1;let t=e.session;if(i&&e.session&&0===e.session.segmentId&&o5(e,function(e){let t=e.getOptions();return{type:iJ.Custom,timestamp:Date.now(),data:{tag:"options",payload:{shouldRecordCanvas:e.isRecordingCanvas(),sessionSampleRate:t.sessionSampleRate,errorSampleRate:t.errorSampleRate,useCompressionOption:t.useCompression,blockAllMedia:t.blockAllMedia,maskAllText:t.maskAllText,maskAllInputs:t.maskAllInputs,useCompression:!!e.eventBuffer&&"worker"===e.eventBuffer.type,networkDetailHasUrls:t.networkDetailAllowUrls.length>0,networkCaptureBodies:t.networkCaptureBodies,networkRequestHasHeaders:t.networkRequestHeaders.length>0,networkResponseHasHeaders:t.networkResponseHeaders.length>0}}}}(e),!1),"buffer"===e.recordingMode&&t&&e.eventBuffer){let n=e.eventBuffer.getEarliestTimestamp();n&&(t.started=n,e.getOptions().stickySession&&oK(t))}return!!t&&!!t.previousSessionId||("session"===e.recordingMode&&e.flush(),!0)})}),onMutation:this._onMutationHandler,...n?{recordCanvas:n.recordCanvas,getCanvasManager:n.getCanvasManager,sampling:n.sampling,dataURLOptions:n.dataURLOptions}:{}})}catch(e){this.handleException(e)}}stopRecording(){try{return this._stopRecording&&(this._stopRecording(),this._stopRecording=void 0),!0}catch(e){return this.handleException(e),!1}}async stop({forceFlush:e=!1,reason:t}={}){if(this._isEnabled){this._isEnabled=!1;try{se(),this._removeListeners(),this.stopRecording(),this._debouncedFlush.cancel(),e&&await this._flush({force:!0}),this.eventBuffer&&this.eventBuffer.destroy(),this.eventBuffer=null,function(){if(oV())try{rW.sessionStorage.removeItem(rG)}catch(e){}}(),this.session=void 0}catch(e){this.handleException(e)}}}pause(){this._isPaused||(this._isPaused=!0,this.stopRecording())}resume(){this._isPaused&&this._checkSession()&&(this._isPaused=!1,this.startRecording())}async sendBufferedReplayOrFlush({continueRecording:e=!0}={}){if("session"===this.recordingMode)return this.flushImmediate();let t=Date.now();await this.flushImmediate();let n=this.stopRecording();e&&n&&"session"!==this.recordingMode&&(this.recordingMode="session",this.session&&(this._updateUserActivity(t),this._updateSessionActivity(t),this._maybeSaveSession()),this.startRecording())}addUpdate(e){let t=e();"buffer"!==this.recordingMode&&!0!==t&&this._debouncedFlush()}triggerUserActivity(){if(this._updateUserActivity(),!this._stopRecording){if(!this._checkSession())return;this.resume();return}this.checkAndHandleExpiredSession(),this._updateSessionActivity()}updateUserActivity(){this._updateUserActivity(),this._updateSessionActivity()}conditionalFlush(){return"buffer"===this.recordingMode?Promise.resolve():this.flushImmediate()}flush(){return this._debouncedFlush()}flushImmediate(){return this._debouncedFlush(),this._debouncedFlush.flush()}cancelFlush(){this._debouncedFlush.cancel()}getSessionId(){return this.session&&this.session.id}checkAndHandleExpiredSession(){if(this._lastActivity&&o0(this._lastActivity,this.timeouts.sessionIdlePause)&&this.session&&"session"===this.session.sampled){this.pause();return}return!!this._checkSession()}setInitialState(){let e=`${rW.location.pathname}${rW.location.hash}${rW.location.search}`,t=`${rW.location.origin}${e}`;this.performanceEntries=[],this.replayPerformanceEntries=[],this._clearContext(),this._context.initialUrl=t,this._context.initialTimestamp=Date.now(),this._context.urls.push(t)}throttledAddEvent(e,t){let n=this._throttledAddEvent(e,t);if(n===sA){let e=oN({category:"replay.throttled"});this.addUpdate(()=>!o5(this,{type:5,timestamp:e.timestamp||0,data:{tag:"breadcrumb",payload:e,metric:!0}}))}return n}getCurrentRoute(){let e=this.lastActiveSpan||(0,ev.HN)(),t=e&&(0,ev.Gx)(e),n=(t&&(0,ev.XU)(t).data||{})[tW.Zj];if(t&&n&&["route","custom"].includes(n))return(0,ev.XU)(t).description}_initializeRecording(){this.setInitialState(),this._updateSessionActivity(),this.eventBuffer=function({useCompression:e,workerUrl:t}){if(e&&window.Worker){let e=function(e){try{let t=e||("undefined"!=typeof __SENTRY_EXCLUDE_REPLAY_WORKER__&&__SENTRY_EXCLUDE_REPLAY_WORKER__?"":function(){let e=new Blob(['var t=Uint8Array,n=Uint16Array,r=Int32Array,e=new t([0,0,0,0,0,0,0,0,1,1,1,1,2,2,2,2,3,3,3,3,4,4,4,4,5,5,5,5,0,0,0,0]),i=new t([0,0,0,0,1,1,2,2,3,3,4,4,5,5,6,6,7,7,8,8,9,9,10,10,11,11,12,12,13,13,0,0]),a=new t([16,17,18,0,8,7,9,6,10,5,11,4,12,3,13,2,14,1,15]),s=function(t,e){for(var i=new n(31),a=0;a<31;++a)i[a]=e+=1<>1|(21845&c)<<1;v=(61680&(v=(52428&v)>>2|(13107&v)<<2))>>4|(3855&v)<<4,u[c]=((65280&v)>>8|(255&v)<<8)>>1}var d=function(t,r,e){for(var i=t.length,a=0,s=new n(r);a>h]=l}else for(o=new n(i),a=0;a>15-t[a]);return o},g=new t(288);for(c=0;c<144;++c)g[c]=8;for(c=144;c<256;++c)g[c]=9;for(c=256;c<280;++c)g[c]=7;for(c=280;c<288;++c)g[c]=8;var w=new t(32);for(c=0;c<32;++c)w[c]=5;var p=d(g,9,0),y=d(w,5,0),m=function(t){return(t+7)/8|0},b=function(n,r,e){return(null==e||e>n.length)&&(e=n.length),new t(n.subarray(r,e))},M=["unexpected EOF","invalid block type","invalid length/literal","invalid distance","stream finished","no stream handler",,"no callback","invalid UTF-8 data","extra field too long","date not in range 1980-2099","filename too long","stream finishing","invalid zip data"],E=function(t,n,r){var e=new Error(n||M[t]);if(e.code=t,Error.captureStackTrace&&Error.captureStackTrace(e,E),!r)throw e;return e},z=function(t,n,r){r<<=7&n;var e=n/8|0;t[e]|=r,t[e+1]|=r>>8},_=function(t,n,r){r<<=7&n;var e=n/8|0;t[e]|=r,t[e+1]|=r>>8,t[e+2]|=r>>16},x=function(r,e){for(var i=[],a=0;ad&&(d=o[a].s);var g=new n(d+1),w=A(i[c-1],g,0);if(w>e){a=0;var p=0,y=w-e,m=1<e))break;p+=m-(1<>=y;p>0;){var M=o[a].s;g[M]=0&&p;--a){var E=o[a].s;g[E]==e&&(--g[E],++p)}w=e}return{t:new t(g),l:w}},A=function(t,n,r){return-1==t.s?Math.max(A(t.l,n,r+1),A(t.r,n,r+1)):n[t.s]=r},D=function(t){for(var r=t.length;r&&!t[--r];);for(var e=new n(++r),i=0,a=t[0],s=1,o=function(t){e[i++]=t},f=1;f<=r;++f)if(t[f]==a&&f!=r)++s;else{if(!a&&s>2){for(;s>138;s-=138)o(32754);s>2&&(o(s>10?s-11<<5|28690:s-3<<5|12305),s=0)}else if(s>3){for(o(a),--s;s>6;s-=6)o(8304);s>2&&(o(s-3<<5|8208),s=0)}for(;s--;)o(a);s=1,a=t[f]}return{c:e.subarray(0,i),n:r}},T=function(t,n){for(var r=0,e=0;e>8,t[i+2]=255^t[i],t[i+3]=255^t[i+1];for(var a=0;a4&&!H[a[K-1]];--K);var N,P,Q,R,V=v+5<<3,W=T(f,g)+T(h,w)+l,X=T(f,M)+T(h,U)+l+14+3*K+T(q,H)+2*q[16]+3*q[17]+7*q[18];if(c>=0&&V<=W&&V<=X)return k(r,m,t.subarray(c,c+v));if(z(r,m,1+(X15&&(z(r,m,tt[B]>>5&127),m+=tt[B]>>12)}}}else N=p,P=g,Q=y,R=w;for(B=0;B255){_(r,m,N[(nt=rt>>18&31)+257]),m+=P[nt+257],nt>7&&(z(r,m,rt>>23&31),m+=e[nt]);var et=31&rt;_(r,m,Q[et]),m+=R[et],et>3&&(_(r,m,rt>>5&8191),m+=i[et])}else _(r,m,N[rt]),m+=P[rt]}return _(r,m,N[256]),m+P[256]},C=new r([65540,131080,131088,131104,262176,1048704,1048832,2114560,2117632]),F=new t(0),I=function(){for(var t=new Int32Array(256),n=0;n<256;++n){for(var r=n,e=9;--e;)r=(1&r&&-306674912)^r>>>1;t[n]=r}return t}(),S=function(){var t=-1;return{p:function(n){for(var r=t,e=0;e>>8;t=r},d:function(){return~t}}},L=function(){var t=1,n=0;return{p:function(r){for(var e=t,i=n,a=0|r.length,s=0;s!=a;){for(var o=Math.min(s+2655,a);s>16),i=(65535&i)+15*(i>>16)}t=e,n=i},d:function(){return(255&(t%=65521))<<24|(65280&t)<<8|(255&(n%=65521))<<8|n>>8}}},O=function(a,s,o,f,u){if(!u&&(u={l:1},s.dictionary)){var c=s.dictionary.subarray(-32768),v=new t(c.length+a.length);v.set(c),v.set(a,c.length),a=v,u.w=c.length}return function(a,s,o,f,u,c){var v=c.z||a.length,d=new t(f+v+5*(1+Math.ceil(v/7e3))+u),g=d.subarray(f,d.length-u),w=c.l,p=7&(c.r||0);if(s){p&&(g[0]=c.r>>3);for(var y=C[s-1],M=y>>13,E=8191&y,z=(1<7e3||q>24576)&&(N>423||!w)){p=U(a,g,0,F,I,S,O,q,G,j-G,p),q=L=O=0,G=j;for(var P=0;P<286;++P)I[P]=0;for(P=0;P<30;++P)S[P]=0}var Q=2,R=0,V=E,W=J-K&32767;if(N>2&&H==T(j-W))for(var X=Math.min(M,N)-1,Y=Math.min(32767,j),Z=Math.min(258,N);W<=Y&&--V&&J!=K;){if(a[j+Q]==a[j+Q-W]){for(var $=0;$Q){if(Q=$,R=W,$>X)break;var tt=Math.min(W,$-2),nt=0;for(P=0;Pnt&&(nt=et,K=rt)}}}W+=(J=K)-(K=_[J])&32767}if(R){F[q++]=268435456|h[Q]<<18|l[R];var it=31&h[Q],at=31&l[R];O+=e[it]+i[at],++I[257+it],++S[at],B=j+Q,++L}else F[q++]=a[j],++I[a[j]]}}for(j=Math.max(j,B);j=v&&(g[p/8|0]=w,st=v),p=k(g,p+1,a.subarray(j,st))}c.i=v}return b(d,0,f+m(p)+u)}(a,null==s.level?6:s.level,null==s.mem?Math.ceil(1.5*Math.max(8,Math.min(13,Math.log(a.length)))):12+s.mem,o,f,u)},j=function(t,n,r){for(;r;++n)t[n]=r,r>>>=8},q=function(t,n){var r=n.filename;if(t[0]=31,t[1]=139,t[2]=8,t[8]=n.level<2?4:9==n.level?2:0,t[9]=3,0!=n.mtime&&j(t,4,Math.floor(new Date(n.mtime||Date.now())/1e3)),r){t[3]=8;for(var e=0;e<=r.length;++e)t[e+10]=r.charCodeAt(e)}},B=function(t){return 10+(t.filename?t.filename.length+1:0)},G=function(){function n(n,r){if("function"==typeof n&&(r=n,n={}),this.ondata=r,this.o=n||{},this.s={l:0,i:32768,w:32768,z:32768},this.b=new t(98304),this.o.dictionary){var e=this.o.dictionary.subarray(-32768);this.b.set(e,32768-e.length),this.s.i=32768-e.length}}return n.prototype.p=function(t,n){this.ondata(O(t,this.o,0,0,this.s),n)},n.prototype.push=function(n,r){this.ondata||E(5),this.s.l&&E(4);var e=n.length+this.s.z;if(e>this.b.length){if(e>2*this.b.length-32768){var i=new t(-32768&e);i.set(this.b.subarray(0,this.s.z)),this.b=i}var a=this.b.length-this.s.z;a&&(this.b.set(n.subarray(0,a),this.s.z),this.s.z=this.b.length,this.p(this.b,!1)),this.b.set(this.b.subarray(-32768)),this.b.set(n.subarray(a),32768),this.s.z=n.length-a+32768,this.s.i=32766,this.s.w=32768}else this.b.set(n,this.s.z),this.s.z+=n.length;this.s.l=1&r,(this.s.z>this.s.w+8191||r)&&(this.p(this.b,r||!1),this.s.w=this.s.i,this.s.i-=2)},n}();var H=function(){function t(t,n){this.c=L(),this.v=1,G.call(this,t,n)}return t.prototype.push=function(t,n){this.c.p(t),G.prototype.push.call(this,t,n)},t.prototype.p=function(t,n){var r=O(t,this.o,this.v&&(this.o.dictionary?6:2),n&&4,this.s);this.v&&(function(t,n){var r=n.level,e=0==r?0:r<6?1:9==r?3:2;if(t[0]=120,t[1]=e<<6|(n.dictionary&&32),t[1]|=31-(t[0]<<8|t[1])%31,n.dictionary){var i=L();i.p(n.dictionary),j(t,2,i.d())}}(r,this.o),this.v=0),n&&j(r,r.length-4,this.c.d()),this.ondata(r,n)},t}(),J="undefined"!=typeof TextEncoder&&new TextEncoder,K="undefined"!=typeof TextDecoder&&new TextDecoder;try{K.decode(F,{stream:!0})}catch(t){}var N=function(){function t(t){this.ondata=t}return t.prototype.push=function(t,n){this.ondata||E(5),this.d&&E(4),this.ondata(P(t),this.d=n||!1)},t}();function P(n,r){if(J)return J.encode(n);for(var e=n.length,i=new t(n.length+(n.length>>1)),a=0,s=function(t){i[a++]=t},o=0;oi.length){var f=new t(a+8+(e-o<<1));f.set(i),i=f}var h=n.charCodeAt(o);h<128||r?s(h):h<2048?(s(192|h>>6),s(128|63&h)):h>55295&&h<57344?(s(240|(h=65536+(1047552&h)|1023&n.charCodeAt(++o))>>18),s(128|h>>12&63),s(128|h>>6&63),s(128|63&h)):(s(224|h>>12),s(128|h>>6&63),s(128|63&h))}return b(i,0,a)}function Q(t){return function(t,n){n||(n={});var r=S(),e=t.length;r.p(t);var i=O(t,n,B(n),8),a=i.length;return q(i,n),j(i,a-8,r.d()),j(i,a-4,e),i}(P(t))}const R=new class{constructor(){this._init()}clear(){this._init()}addEvent(t){if(!t)throw new Error("Adding invalid event");const n=this._hasEvents?",":"";this.stream.push(n+t),this._hasEvents=!0}finish(){this.stream.push("]",!0);const t=function(t){let n=0;for(const r of t)n+=r.length;const r=new Uint8Array(n);for(let n=0,e=0,i=t.length;n{this._deflatedData.push(t)},this.stream=new N(((t,n)=>{this.deflate.push(t,n)})),this.stream.push("[")}},V={clear:()=>{R.clear()},addEvent:t=>R.addEvent(t),finish:()=>R.finish(),compress:t=>Q(t)};addEventListener("message",(function(t){const n=t.data.method,r=t.data.id,e=t.data.arg;if(n in V&&"function"==typeof V[n])try{const t=V[n](e);postMessage({id:r,method:n,success:!0,response:t})}catch(t){postMessage({id:r,method:n,success:!1,response:t.message}),console.error(t)}})),postMessage({id:void 0,method:"init",success:!0,response:void 0});']);return URL.createObjectURL(e)}());if(!t)return;let n=new Worker(t);return new oJ(n)}catch(e){}}(t);if(e)return e}return new oG}({useCompression:this._options.useCompression,workerUrl:this._options.workerUrl}),this._removeListeners(),this._addListeners(),this._isEnabled=!0,this._isPaused=!1,this.startRecording()}_initializeSessionForSampling(e){let t=this._options.errorSampleRate>0,n=o3({sessionIdleExpire:this.timeouts.sessionIdleExpire,maxReplayDuration:this._options.maxReplayDuration,previousSessionId:e},{stickySession:this._options.stickySession,sessionSampleRate:this._options.sessionSampleRate,allowBuffering:t});this.session=n}_checkSession(){if(!this.session)return!1;let e=this.session;return!o2(e,{sessionIdleExpire:this.timeouts.sessionIdleExpire,maxReplayDuration:this._options.maxReplayDuration})||(this._refreshSession(e),!1)}async _refreshSession(e){this._isEnabled&&(await this.stop({reason:"refresh session"}),this.initializeSampling(e.id))}_addListeners(){try{rW.document.addEventListener("visibilitychange",this._handleVisibilityChange),rW.addEventListener("blur",this._handleWindowBlur),rW.addEventListener("focus",this._handleWindowFocus),rW.addEventListener("keydown",this._handleKeyboardEvent),this.clickDetector&&this.clickDetector.addListeners(),this._hasInitializedCoreListeners||(function(e){let t=(0,V.s3)();eJ(ox(e)),e1(t=>{if(!e.isEnabled())return;let n=function(e){let{from:t,to:n}=e,r=Date.now()/1e3;return{type:"navigation.push",start:r,end:r,name:n,data:{previous:t}}}(t);null!==n&&(e.getContext().urls.push(n.name),e.triggerUserActivity(),e.addUpdate(()=>(st(e,[n]),!1)))}),function(e){let t=(0,V.s3)();t&&t.on("beforeAddBreadcrumb",t=>(function(e,t){if(!e.isEnabled()||!o7(t))return;let n=!o7(t)||["fetch","xhr","sentry.event","sentry.transaction"].includes(t.category)||t.category.startsWith("ui.")?null:"console"===t.category?function(e){let t=e.data&&e.data.arguments;if(!Array.isArray(t)||0===t.length)return oN(e);let n=!1,r=t.map(e=>{if(!e)return e;if("string"==typeof e)return e.length>5e3?(n=!0,`${e.slice(0,5e3)}…`):e;if("object"==typeof e)try{let t=(0,eh.Fv)(e,7);if(JSON.stringify(t).length>5e3)return n=!0,`${JSON.stringify(t,null,2).slice(0,5e3)}…`;return t}catch(e){}return e});return oN({...e,data:{...e.data,arguments:r,...n?{_meta:{warnings:["CONSOLE_ARG_TRUNCATED"]}}:{}}})}(t):oN(t);n&&oS(e,n)})(e,t))}(e),function(e){let t=(0,V.s3)();try{let{networkDetailAllowUrls:n,networkDetailDenyUrls:r,networkCaptureBodies:i,networkRequestHeaders:o,networkResponseHeaders:s}=e.getOptions(),a={replay:e,networkDetailAllowUrls:n,networkDetailDenyUrls:r,networkCaptureBodies:i,networkRequestHeaders:o,networkResponseHeaders:s};t&&t.on("beforeAddBreadcrumb",(e,t)=>(function(e,t,n){if(t.data)try{var r,i;"xhr"===t.category&&(r=n)&&r.xhr&&(function(e,t){let{xhr:n,input:r}=t;if(!n)return;let i=sr(r),o=n.getResponseHeader("content-length")?si(n.getResponseHeader("content-length")):function(e,t){try{let n="json"===t&&e&&"object"==typeof e?JSON.stringify(e):e;return sr(n)}catch(e){return}}(n.response,n.responseType);void 0!==i&&(e.data.request_body_size=i),void 0!==o&&(e.data.response_body_size=o)}(t,n),sb(t,n,e)),"fetch"===t.category&&(i=n)&&i.response&&(function(e,t){let{input:n,response:r}=t,i=sr(n?s_(n):void 0),o=r?si(r.headers.get("content-length")):void 0;void 0!==i&&(e.data.request_body_size=i),void 0!==o&&(e.data.response_body_size=o)}(t,n),sf(t,n,e))}catch(e){}})(a,e,t))}catch(e){}}(e);let n=Object.assign((t,n)=>!e.isEnabled()||e.isPaused()?t:"replay_event"===t.type?(delete t.breadcrumbs,t):!t.type||o8(t)||o9(t)?e.checkAndHandleExpiredSession()?o9(t)?(e.flush(),t.contexts.feedback.replay_id=e.getSessionId(),e.triggerUserActivity(),e.addUpdate(()=>!t.timestamp||(e.throttledAddEvent({type:iJ.Custom,timestamp:1e3*t.timestamp,data:{tag:"breadcrumb",payload:{timestamp:t.timestamp,type:"default",category:"sentry.feedback",data:{feedbackId:t.event_id}}}}),!1)),t):!t.type&&t.exception&&t.exception.values&&t.exception.values.length&&n.originalException&&n.originalException.__rrweb__&&!e.getOptions()._experiments.captureExceptions?null:(("buffer"===e.recordingMode&&t.message!==rz&&t.exception&&!t.type&&oY(e.getOptions().errorSampleRate)||"session"===e.recordingMode)&&(t.tags={...t.tags,replayId:e.getSessionId()}),t):(se(),t):t,{id:"Replay"});(0,U.Qy)(n),t&&(t.on("beforeSendEvent",t=>{e.isEnabled()&&!t.type&&function(e,t){let n=t.exception&&t.exception.values&&t.exception.values[0]&&t.exception.values[0].value;"string"==typeof n&&(n.match(/(reactjs\.org\/docs\/error-decoder\.html\?invariant=|react\.dev\/errors\/)(418|419|422|423|425)/)||n.match(/(does not match server-rendered HTML|Hydration failed because)/i))&&oS(e,oN({category:"replay.hydrate-error",data:{url:(0,tt.l4)()}}))}(e,t)}),t.on("afterSendEvent",(t,n)=>{if(!e.isEnabled()||t.type&&!o8(t))return;let r=n&&n.statusCode;if(r&&!(r<200)&&!(r>=300)){if(o8(t)){(function(e,t){let n=e.getContext();t.contexts&&t.contexts.trace&&t.contexts.trace.trace_id&&n.traceIds.size<100&&n.traceIds.add(t.contexts.trace.trace_id)})(e,t);return}(function(e,t){let n=e.getContext();if(t.event_id&&n.errorIds.size<100&&n.errorIds.add(t.event_id),"buffer"!==e.recordingMode||!t.tags||!t.tags.replayId)return;let{beforeErrorSampling:r}=e.getOptions();("function"!=typeof r||r(t))&&tL(async()=>{try{await e.sendBufferedReplayOrFlush()}catch(t){e.handleException(t)}})})(e,t)}}),t.on("createDsc",t=>{let n=e.getSessionId();n&&e.isEnabled()&&"session"===e.recordingMode&&e.checkAndHandleExpiredSession()&&(t.replay_id=n)}),t.on("spanStart",t=>{e.lastActiveSpan=t}),t.on("spanEnd",t=>{e.lastActiveSpan=t}),t.on("beforeSendFeedback",(t,n)=>{let r=e.getSessionId();n&&n.includeReplay&&e.isEnabled()&&r&&t.contexts&&t.contexts.feedback&&(t.contexts.feedback.replay_id=r)}))}(this),this._hasInitializedCoreListeners=!0)}catch(e){this.handleException(e)}this._performanceCleanupCallback=function(e){function t(t){e.performanceEntries.includes(t)||e.performanceEntries.push(t)}function n({entries:e}){e.forEach(t)}let r=[];return["navigation","paint","resource"].forEach(e=>{r.push(nI(e,n))}),r.push(nA(oM(oU,e)),nR(oM(o$,e)),nk(oM(oB,e)),nN(oM(oF,e))),()=>{r.forEach(e=>e())}}(this)}_removeListeners(){try{rW.document.removeEventListener("visibilitychange",this._handleVisibilityChange),rW.removeEventListener("blur",this._handleWindowBlur),rW.removeEventListener("focus",this._handleWindowFocus),rW.removeEventListener("keydown",this._handleKeyboardEvent),this.clickDetector&&this.clickDetector.removeListeners(),this._performanceCleanupCallback&&this._performanceCleanupCallback()}catch(e){this.handleException(e)}}__init(){this._handleVisibilityChange=()=>{"visible"===rW.document.visibilityState?this._doChangeToForegroundTasks():this._doChangeToBackgroundTasks()}}__init2(){this._handleWindowBlur=()=>{let e=oN({category:"ui.blur"});this._doChangeToBackgroundTasks(e)}}__init3(){this._handleWindowFocus=()=>{let e=oN({category:"ui.focus"});this._doChangeToForegroundTasks(e)}}__init4(){this._handleKeyboardEvent=e=>{!function(e,t){if(!e.isEnabled())return;e.updateUserActivity();let n=function(e){var t;let{metaKey:n,shiftKey:r,ctrlKey:i,altKey:o,key:s,target:a}=e;if(!a||"INPUT"===(t=a).tagName||"TEXTAREA"===t.tagName||t.isContentEditable||!s)return null;let c=n||i||o,l=1===s.length;if(!c&&l)return null;let u=(0,tt.Rt)(a,{maxStringLength:200})||"",d=oD(a,u);return oN({category:"ui.keyDown",message:u,data:{...d.data,metaKey:n,shiftKey:r,ctrlKey:i,altKey:o,key:s}})}(t);n&&oS(e,n)}(this,e)}}_doChangeToBackgroundTasks(e){!this.session||o1(this.session,{maxReplayDuration:this._options.maxReplayDuration,sessionIdleExpire:this.timeouts.sessionIdleExpire})||(e&&this._createCustomBreadcrumb(e),this.conditionalFlush())}_doChangeToForegroundTasks(e){this.session&&this.checkAndHandleExpiredSession()&&e&&this._createCustomBreadcrumb(e)}_updateUserActivity(e=Date.now()){this._lastActivity=e}_updateSessionActivity(e=Date.now()){this.session&&(this.session.lastActivity=e,this._maybeSaveSession())}_createCustomBreadcrumb(e){this.addUpdate(()=>{this.throttledAddEvent({type:iJ.Custom,timestamp:e.timestamp||0,data:{tag:"breadcrumb",payload:e}})})}_addPerformanceEntries(){let e=this.performanceEntries.map(oL).filter(Boolean).concat(this.replayPerformanceEntries);if(this.performanceEntries=[],this.replayPerformanceEntries=[],this._requiresManualStart){let t=this._context.initialTimestamp/1e3;e=e.filter(e=>e.start>=t)}return Promise.all(st(this,e))}_clearContext(){this._context.errorIds.clear(),this._context.traceIds.clear(),this._context.urls=[]}_updateInitialTimestampFromEventBuffer(){let{session:e,eventBuffer:t}=this;if(!e||!t||this._requiresManualStart||e.segmentId)return;let n=t.getEarliestTimestamp();n&&nthis._options.maxReplayDuration+3e4)throw Error("Session is too long, not sending replay");let n=this._popEventContext(),r=this.session.segmentId++;this._maybeSaveSession();let i=await this.eventBuffer.finish();await sR({replayId:e,recordingData:i,segmentId:r,eventContext:n,session:this.session,timestamp:t,onError:e=>this.handleException(e)})}catch(t){this.handleException(t),this.stop({reason:"sendReplay"});let e=(0,V.s3)();e&&e.recordDroppedEvent(t instanceof sC?"ratelimit_backoff":"send_error","replay")}}__init5(){this._flush=async({force:e=!1}={})=>{if(!this._isEnabled&&!e||!this.checkAndHandleExpiredSession()||!this.session)return;let t=this.session.started,n=Date.now()-t;this._debouncedFlush.cancel();let r=nthis._options.maxReplayDuration+5e3;if(r||i){r&&this._debouncedFlush();return}let o=this.eventBuffer;o&&0===this.session.segmentId&&o.hasCheckout;let s=!!this._flushLock;this._flushLock||(this._flushLock=this._runFlush());try{await this._flushLock}catch(e){this.handleException(e)}finally{this._flushLock=void 0,s&&this._debouncedFlush()}}}_maybeSaveSession(){this.session&&this._options.stickySession&&oK(this.session)}__init6(){this._onMutationHandler=e=>{let t=e.length,n=this._options.mutationLimit,r=this._options.mutationBreadcrumbLimit,i=n&&t>n;if(t>r||i){let e=oN({category:"replay.mutations",data:{count:t,limit:i}});this._createCustomBreadcrumb(e)}return!i||(this.stop({reason:"mutationLimit",forceFlush:"session"===this.recordingMode}),!1)}}}function sN(e,t){return[...e,...t].join(",")}let sI='img,image,svg,video,object,picture,embed,map,audio,link[rel="icon"],link[rel="apple-touch-icon"]',sx=["content-length","content-type","accept"],sD=!1;class sP{static __initStatic(){this.id="Replay"}constructor({flushMinDelay:e=5e3,flushMaxDelay:t=5500,minReplayDuration:n=4999,maxReplayDuration:r=36e5,stickySession:i=!0,useCompression:o=!0,workerUrl:s,_experiments:a={},maskAllText:c=!0,maskAllInputs:l=!0,blockAllMedia:u=!0,mutationBreadcrumbLimit:d=750,mutationLimit:h=1e4,slowClickTimeout:f=7e3,slowClickIgnoreSelectors:p=[],networkDetailAllowUrls:m=[],networkDetailDenyUrls:g=[],networkCaptureBodies:_=!0,networkRequestHeaders:y=[],networkResponseHeaders:v=[],mask:E=[],maskAttributes:b=["title","placeholder"],unmask:S=[],block:T=[],unblock:w=[],ignore:O=[],maskFn:C,beforeAddRecordingEvent:R,beforeErrorSampling:A,onError:k}={}){this.name=sP.id;let N=function({mask:e,unmask:t,block:n,unblock:r,ignore:i}){return{maskTextSelector:sN(e,[".sentry-mask","[data-sentry-mask]"]),unmaskTextSelector:sN(t,[]),blockSelector:sN(n,[".sentry-block","[data-sentry-block]",'base[href="/"]']),unblockSelector:sN(r,[]),ignoreSelector:sN(i,[".sentry-ignore","[data-sentry-ignore]",'input[type="file"]'])}}({mask:E,unmask:S,block:T,unblock:w,ignore:O});if(this._recordingOptions={maskAllInputs:l,maskAllText:c,maskInputOptions:{password:!0},maskTextFn:C,maskInputFn:C,maskAttributeFn:(e,t,n)=>(function({el:e,key:t,maskAttributes:n,maskAllText:r,privacyOptions:i,value:o}){return!r||i.unmaskTextSelector&&e.matches(i.unmaskTextSelector)?o:n.includes(t)||"value"===t&&"INPUT"===e.tagName&&["submit","button"].includes(e.getAttribute("type")||"")?o.replace(/[\S]/g,"*"):o})({maskAttributes:b,maskAllText:c,privacyOptions:N,key:e,value:t,el:n}),...N,slimDOMOptions:"all",inlineStylesheet:!0,inlineImages:!1,collectFonts:!0,errorHandler:e=>{try{e.__rrweb__=!0}catch(e){}}},this._initialOptions={flushMinDelay:e,flushMaxDelay:t,minReplayDuration:Math.min(n,15e3),maxReplayDuration:Math.min(r,36e5),stickySession:i,useCompression:o,workerUrl:s,blockAllMedia:u,maskAllInputs:l,maskAllText:c,mutationBreadcrumbLimit:d,mutationLimit:h,slowClickTimeout:f,slowClickIgnoreSelectors:p,networkDetailAllowUrls:m,networkDetailDenyUrls:g,networkCaptureBodies:_,networkRequestHeaders:sM(y),networkResponseHeaders:sM(v),beforeAddRecordingEvent:R,beforeErrorSampling:A,onError:k,_experiments:a},this._initialOptions.blockAllMedia&&(this._recordingOptions.blockSelector=this._recordingOptions.blockSelector?`${this._recordingOptions.blockSelector},${sI}`:sI),this._isInitialized&&rH())throw Error("Multiple Sentry Session Replay instances are not supported");this._isInitialized=!0}get _isInitialized(){return sD}set _isInitialized(e){sD=e}afterAllSetup(e){rH()&&!this._replay&&(this._setup(e),this._initialize(e))}start(){this._replay&&this._replay.start()}startBuffering(){this._replay&&this._replay.startBuffering()}stop(){return this._replay?this._replay.stop({forceFlush:"session"===this._replay.recordingMode}):Promise.resolve()}flush(e){return this._replay?this._replay.isEnabled()?this._replay.sendBufferedReplayOrFlush(e):(this._replay.start(),Promise.resolve()):Promise.resolve()}getReplayId(){if(this._replay&&this._replay.isEnabled())return this._replay.getSessionId()}getRecordingMode(){if(this._replay&&this._replay.isEnabled())return this._replay.recordingMode}_initialize(e){this._replay&&(this._maybeLoadFromReplayCanvasIntegration(e),this._replay.initializeSampling())}_setup(e){let t=function(e,t){let n=t.getOptions(),r={sessionSampleRate:0,errorSampleRate:0,...(0,Y.Jr)(e)},i=eO(n.replaysSessionSampleRate),o=eO(n.replaysOnErrorSampleRate);return null==i&&null==o&&(0,B.Cf)(()=>{console.warn("Replay is disabled because neither `replaysSessionSampleRate` nor `replaysOnErrorSampleRate` are set.")}),null!=i&&(r.sessionSampleRate=i),null!=o&&(r.errorSampleRate=o),r}(this._initialOptions,e);this._replay=new sk({options:t,recordingOptions:this._recordingOptions})}_maybeLoadFromReplayCanvasIntegration(e){try{let t=e.getIntegrationByName("ReplayCanvas");if(!t)return;this._replay._canvas=t.getOptions()}catch(e){}}}function sM(e){return[...sx,...e.map(e=>e.toLowerCase())]}sP.__initStatic(),globalThis._sentryRewritesTunnelPath=void 0,globalThis.SENTRY_RELEASE={id:"ad333f80cbba591e01efa7a1a54a393c521f55b4"},globalThis._sentryBasePath=void 0,globalThis._sentryRewriteFramesAssetPrefixPath="",function(e){let t={environment:function(e){let t=e?tH.env.NEXT_PUBLIC_VERCEL_ENV:tH.env.VERCEL_ENV;return t?`vercel-${t}`:void 0}(!0)||"production",defaultIntegrations:function(e){let t=tF(e);("undefined"==typeof __SENTRY_TRACING__||__SENTRY_TRACING__)&&t.push(function(e={}){let t=rT({...e,instrumentNavigation:!1,instrumentPageLoad:!1}),{instrumentPageLoad:n=!0,instrumentNavigation:r=!0}=e;return{...t,afterAllSetup(e){var i;r&&(i=e,eU.document.getElementById("__NEXT_DATA__")?rx.events.on("routeChangeStart",e=>{let t,n;let r=e.split(/[?#]/,1)[0],o=function(e){let t=(eU.__BUILD_MANIFEST||{}).sortedPages;if(t)return t.find(t=>{let n=function(e){let t=e.split("/"),n="";S([t,"access",e=>e[t.length-1],"optionalAccess",e=>e.match,"call",e=>e(/^\[\[\.\.\..+\]\]$/)])&&(t.pop(),n="(?:/(.+?))?");let r=t.map(e=>e.replace(/^\[\.\.\..+\]$/,"(.+?)").replace(/^\[.*\]$/,"([^/]+?)")).join("/");return RegExp(`^${r}${n}(?:/)?$`)}(t);return e.match(n)})}(r);o?(t=o,n="route"):(t=r,n="url"),rO(i,{name:t,attributes:{[tW.$J]:"navigation",[tW.S3]:"auto.navigation.nextjs.pages_router_instrumentation",[tW.Zj]:n}})}):function(e){let t;eU.addEventListener("popstate",()=>{t&&t.isRecording()?(t.updateName(eU.location.pathname),t.setAttribute(tW.Zj,"url")):t=rO(e,{name:eU.location.pathname,attributes:{[tW.$J]:"navigation",[tW.S3]:"auto.navigation.nextjs.app_router_instrumentation",[tW.Zj]:"url","navigation.type":"browser.popstate"}})});let n=!1,r=0,i=setInterval(()=>{var o,s;r++;let a=(o=S([rA,"optionalAccess",e=>e.next,"optionalAccess",e=>e.router]),s=()=>S([rA,"optionalAccess",e=>e.nd,"optionalAccess",e=>e.router]),null!=o?o:s());n||r>500?clearInterval(i):a&&(clearInterval(i),n=!0,["back","forward","push","replace"].forEach(n=>{S([a,"optionalAccess",e=>e[n]])&&(a[n]=new Proxy(a[n],{apply(r,i,o){let s=rO(e,{name:rR,attributes:{[tW.$J]:"navigation",[tW.S3]:"auto.navigation.nextjs.app_router_instrumentation",[tW.Zj]:"url"}});return t=s,"push"===n?(S([s,"optionalAccess",e=>e.updateName,"call",e=>e(rk(o[0]))]),S([s,"optionalAccess",e=>e.setAttribute,"call",e=>e(tW.Zj,"url")]),S([s,"optionalAccess",e=>e.setAttribute,"call",e=>e("navigation.type","router.push")])):"replace"===n?(S([s,"optionalAccess",e=>e.updateName,"call",e=>e(rk(o[0]))]),S([s,"optionalAccess",e=>e.setAttribute,"call",e=>e(tW.Zj,"url")]),S([s,"optionalAccess",e=>e.setAttribute,"call",e=>e("navigation.type","router.replace")])):"back"===n?S([s,"optionalAccess",e=>e.setAttribute,"call",e=>e("navigation.type","router.back")]):"forward"===n&&S([s,"optionalAccess",e=>e.setAttribute,"call",e=>e("navigation.type","router.forward")]),r.apply(i,o)}}))}))},20)}(i)),t.afterAllSetup(e),n&&(eU.document.getElementById("__NEXT_DATA__")?function(e){let{route:t,params:n,sentryTrace:r,baggage:i}=function(){let e;let t=eU.document.getElementById("__NEXT_DATA__");if(t&&t.innerHTML)try{e=JSON.parse(t.innerHTML)}catch(e){rI.X&&B.kg.warn("Could not extract __NEXT_DATA__")}if(!e)return{};let n={},{page:r,query:i,props:o}=e;return n.route=r,n.params=i,o&&o.pageProps&&(n.sentryTrace=o.pageProps._sentryTraceData,n.baggage=o.pageProps._sentryBaggage),n}(),o=(0,rf.XM)(i),s=t||eU.location.pathname;o&&o["sentry-transaction"]&&"/_error"===s&&(s=(s=o["sentry-transaction"]).replace(/^(GET|POST|PUT|DELETE|PATCH|HEAD|OPTIONS|TRACE|CONNECT)\s+/i,"")),rw(e,{name:s,startTime:eb.Z1?eb.Z1/1e3:void 0,attributes:{[tW.$J]:"pageload",[tW.S3]:"auto.pageload.nextjs.pages_router_instrumentation",[tW.Zj]:t?"route":"url",...n&&e.getOptions().sendDefaultPii&&{...n}}},{sentryTrace:r,baggage:i})}(e):rw(e,{name:eU.location.pathname,startTime:eb.Z1?eb.Z1/1e3:void 0,attributes:{[tW.$J]:"pageload",[tW.S3]:"auto.pageload.nextjs.app_router_instrumentation",[tW.Zj]:"url"}}))}}}());let n=rB._sentryRewriteFramesAssetPrefixPath||"";return t.push(rj({assetPrefixPath:n})),t}(e),...e};(function(e){let t=rU.env._sentryRewritesTunnelPath||r$._sentryRewritesTunnelPath;if(t&&e.dsn){let n=eu(e.dsn);if(!n)return;let r=n.host.match(/^o(\d+)\.ingest(?:\.([a-z]{2}))?\.sentry\.io$/);if(r){let i=r[1],o=r[2],s=`${t}?o=${i}&p=${n.projectId}`;o&&(s+=`&r=${o}`),e.tunnel=s,rI.X&&B.kg.info(`Tunneling events to "${s}"`)}else rI.X&&B.kg.warn("Provided DSN is not a Sentry SaaS DSN. Will not tunnel events.")}})(t),j(t,"nextjs",["nextjs","react"]),function(e){let t={...e};j(t,"react"),(0,U.v)("react",{version:tq.version}),function(e={}){let t=function(e={}){let t={defaultIntegrations:tF(e),release:"string"==typeof __SENTRY_RELEASE__?__SENTRY_RELEASE__:eU.SENTRY_RELEASE&&eU.SENTRY_RELEASE.id?eU.SENTRY_RELEASE.id:void 0,autoSessionTracking:!0,sendClientReports:!0};return null==e.defaultIntegrations&&delete e.defaultIntegrations,{...t,...e}}(e);if(!t.skipBrowserExtensionCheck&&function(){let e=void 0!==eU.window&&eU;if(!e)return!1;let t=e.chrome?"chrome":"browser",n=e[t],r=n&&n.runtime&&n.runtime.id,i=eU.location&&eU.location.href||"",o=!!r&&eU===eU.top&&["chrome-extension:","moz-extension:","ms-browser-extension:","safari-web-extension:"].some(e=>i.startsWith(`${e}//`)),s=void 0!==e.nw;return!!r&&!o&&!s}()){(0,B.Cf)(()=>{console.error("[Sentry] You cannot run Sentry this way in a browser extension, check: https://docs.sentry.io/platforms/javascript/best-practices/browser-extensions/")});return}(function(e,t){!0===t.debug&&($.X?B.kg.enable():(0,B.Cf)(()=>{console.warn("[Sentry] Cannot initialize SDK with `debug` option using a non-debug bundle.")})),(0,V.nZ)().update(t.initialScope);let n=new e(t);(0,V.nZ)().setClient(n),n.init()})(eF,{...t,stackParser:(0,Q.Sq)(t.stackParser||tx),integrations:function(e){let t;let n=e.defaultIntegrations||[],r=e.integrations;if(n.forEach(e=>{e.isDefaultInstance=!0}),Array.isArray(r))t=[...n,...r];else if("function"==typeof r){let e=r(n);t=Array.isArray(e)?e:[e]}else t=n;let i=function(e){let t={};return e.forEach(e=>{let{name:n}=e,r=t[n];r&&!r.isDefaultInstance&&e.isDefaultInstance||(t[n]=e)}),Object.values(t)}(t),o=i.findIndex(e=>"Debug"===e.name);if(o>-1){let[e]=i.splice(o,1);i.push(e)}return i}(t),transport:t.transport||tB})}(t)}(t);let n=e=>"transaction"===e.type&&"/404"===e.transaction?null:e;n.id="NextClient404Filter",(0,U.Qy)(n);let r=e=>"transaction"===e.type&&e.transaction===rR?null:e;r.id="IncompleteTransactionFilter",(0,U.Qy)(r);let i=(e,t)=>{var n;return(n=S([t,"optionalAccess",e=>e.originalException]),(0,eT.VZ)(n)&&"string"==typeof n.digest&&n.digest.startsWith("NEXT_REDIRECT;"))?null:e};i.id="NextRedirectErrorFilter",(0,U.Qy)(i)}({dsn:"https://4cc707ab12ea4779b417479c0550a5cb@o22381.ingest.us.sentry.io/4505164808585216",ignoreErrors:[/Extension context invalidated./,/querySelectorAll/,"Object Not Found Matching Id"],tracesSampleRate:0,debug:!1,sampleRate:.2,release:"ad333f80cbba591e01efa7a1a54a393c521f55b4",replaysOnErrorSampleRate:1,replaysSessionSampleRate:0,integrations:[new sP({maskAllText:!0,blockAllMedia:!0})]})},58221:function(e,t,n){"use strict";n.r(t),n.d(t,{CustomApp:function(){return b},default:function(){return T},reportWebVitals:function(){return S}});var r,i,o,s=n(52676),a=n(75271),c=(0,n(24159).vJ)(o||(r=["\n /*\n Reset the box-sizing\n\n Heads up! This reset may cause conflicts with some third-party widgets.\n For recommendations on resolving such conflicts, see\n http://getbootstrap.com/getting-started/#third-box-sizing\n */\n\n * {\n box-sizing: border-box;\n }\n\n *::before,\n *::after {\n box-sizing: border-box;\n }\n\n /* Body reset */\n\n body {\n margin: 0;\n }\n\n body, input, textarea, button {\n font-family: var(--encore-body-font-stack);\n }\n\n html,\n body {\n height: 100%;\n }\n"],i||(i=r.slice(0)),o=Object.freeze(Object.defineProperties(r,{raw:{value:Object.freeze(i)}})))),l=function(){return a.createElement(a.Fragment,null,a.createElement(c,null))};n(87045),n(41916),n(9335),n(29134),n(52554);var u=n(36383),d=n(8912),h=n.n(d),f=n(68874),p=n.n(f);let m=(0,a.createContext)(void 0);class g extends a.Component{static getDerivedStateFromError(e){return{error:e}}render(){return(0,s.jsx)(m.Provider,{value:this.state.error,children:this.props.children})}constructor(...e){super(...e),this.state={error:void 0}}}n(78359);var _=n(68677);n(93212);var y=n(52095);let v=e=>{if(!e||e.length<=0)return;if(1===e.length)return e[0];let t=y.dN.largeScreen.small,n=y.dN.largeScreen.small,[r]=e.map(e=>{let r=[(e.width||e.maxWidth||0)*(e.height||e.maxHeight||0),t*n];return{ratio:Math.max(...r)/Math.min(...r),image:e}}).sort((e,t)=>e.ratio-t.ratio);return r.image};var E=n(62085);let b=e=>{let{Component:t,pageProps:n}=e,r=n?.state?.data?.entity?.visualIdentity,i=r?.image?.length?r.image:null,o=v(i??n?.state?.data?.entity?.coverArt?.sources)?.url??"";return(0,a.useEffect)(()=>{let e=(0,E.b)();e&&"discord.com"!==e&&(e="other referrers"),(0,_.sQ)({metric_type:u.MetricTypes.COUNTER,what:"embed_rendered_referrer",tags:{referrer:e},value:1})},[]),(0,s.jsxs)(s.Fragment,{children:[(0,s.jsxs)(h(),{children:[(0,s.jsx)("title",{children:"Spotify Embed"}),(0,s.jsx)("link",{rel:"preload",href:o,as:"image"})]}),(0,s.jsx)(l,{}),(0,s.jsx)(g,{children:(0,s.jsx)("div",{style:{"--image-src":`url('${o}')`},"data-testid":"main-page",children:(0,s.jsx)(t,{...n})})})]})};function S(e){(0,_.p1)(),(0,_.sQ)(u.BrowserMetrics.getWebVitalsMetric(e,{route:p().router?.route??"unknown"}))}var T=b},78359:function(){!function(){"use strict";try{if(window.hasOwnProperty("localStorage")&&null!==window.localStorage){let e=`swxTest_${Math.round(1e7*Math.random())}`;window.localStorage.setItem(e,"test"),window.localStorage.removeItem(e)}}catch(t){let e={};Object.defineProperty(window,"localStorage",{setItem:(t,n)=>(e[t]=n,e[t]),getItem:t=>t in e?e[t]:void 0,removeItem:t=>{delete e[t]},clear:()=>e={}})}}()},68677:function(e,t,n){"use strict";let r;n.d(t,{p1:function(){return s},sQ:function(){return a}});var i=n(36383),o=n(12509);function s(){let e=arguments.length>0&&void 0!==arguments[0]?arguments[0]:"embed-standalone-prod";if(!r){let{sendMetric:t}=(0,i.createSemanticMetrics)({key:e,dev:!"production".startsWith("prod")&&!function(){let e=o.env.DEBUG_SEMANTIC_METRICS;return"1"===e||"2"===e}(),reporter:function(){let{DEBUG_SEMANTIC_METRICS:e}=o.env;return"1"===e?[new i.ConsoleReporter]:[(0,i.createUniversalReporter)(),..."2"===e?[new i.ConsoleReporter]:[]]}(),component_id:"embed-standalone-prod"});r=t}}async function a(e){if(!r)throw Error("Invalid call to sendMetric before initSemanticMetrics.");return e.tags||(e.tags={}),"slingshot"in e.tags||(e.tags.slingshot="1"===o.env.IS_SLINGSHOT?"true":"false"),r(e)}},52095:function(e,t,n){"use strict";n.d(t,{Zo:function(){return c},dN:function(){return l},p4:function(){return a},ue:function(){return s}});var r=n(87654);let i=(0,r.iv)` color: ${"rgb(255, 255, 255)"}; `,o=(0,r.iv)` h1, h2 { margin: 0; font-size: initial; font-weight: normal; } .no-focus-outline { *:focus { outline: 0; } } button { margin: 0; border: 0; padding: 0; color: inherit; background-color: transparent; cursor: pointer; &:focus-visible { outline: #3673d4 auto 5px !important; border-bottom: none !important; } &::after { border-bottom: none !important; } } a { ${i}; text-decoration: none; &:focus-visible { text-decoration: underline !important; } } button { user-select: none; } `,s=(0,r.iv)` body { ${i}; } ${o}; `,a={compactLegacy:80,landscape:152,landscapeLegacy:232,large:352},c={small:360,medium:510},l={landscape:{small:90,large:120},landscapeLegacy:{small:152,medium:160,large:200},portrait:176,largeScreen:{small:216,large:272}}},62085:function(e,t,n){"use strict";n.d(t,{b:function(){return i}});let r=e=>e?new URL(e).hostname:"",i=()=>{let e=document.referrer;if(!e||e.includes("open.spotify.com")){let e=new URL(window.location.href).searchParams.get("referrer");if(e)return r(e)}return r(e)}},87045:function(){},41916:function(){},9335:function(){},29134:function(){},52554:function(){},93212:function(){},19378:function(e){!function(){var t={229:function(e){var t,n,r,i=e.exports={};function o(){throw Error("setTimeout has not been defined")}function s(){throw Error("clearTimeout has not been defined")}function a(e){if(t===setTimeout)return setTimeout(e,0);if((t===o||!t)&&setTimeout)return t=setTimeout,setTimeout(e,0);try{return t(e,0)}catch(n){try{return t.call(null,e,0)}catch(n){return t.call(this,e,0)}}}!function(){try{t="function"==typeof setTimeout?setTimeout:o}catch(e){t=o}try{n="function"==typeof clearTimeout?clearTimeout:s}catch(e){n=s}}();var c=[],l=!1,u=-1;function d(){l&&r&&(l=!1,r.length?c=r.concat(c):u=-1,c.length&&h())}function h(){if(!l){var e=a(d);l=!0;for(var t=c.length;t;){for(r=c,c=[];++u1)for(var n=1;nr&&(r=(t=t.trim()).charCodeAt(0)),r){case 38:return t.replace(m,"$1"+e.trim());case 58:return e.trim()+t.replace(m,"$1"+e.trim());default:if(0<1*n&&0c.charCodeAt(8))break;case 115:s=s.replace(c,"-webkit-"+c)+";"+s;break;case 207:case 102:s=s.replace(c,"-webkit-"+(102a.charCodeAt(0)&&(a=a.trim()),a=[a],0f)&&($=(q=q.replace(" ",":")).length),0e.charCodeAt(2)}),f=n(72535),p=n.n(f),m=n(12509);function g(){return(g=Object.assign||function(e){for(var t=1;t1?t-1:0),r=1;r0?" Args: "+n.join(", "):""))}var k=function(){function e(e){this.groupSizes=new Uint32Array(512),this.length=512,this.tag=e}var t=e.prototype;return t.indexOfGroup=function(e){for(var t=0,n=0;n=this.groupSizes.length){for(var n=this.groupSizes,r=n.length,i=r;e>=i;)(i<<=1)<0&&A(16,""+e);this.groupSizes=new Uint32Array(i),this.groupSizes.set(n),this.length=i;for(var o=r;o=this.length||0===this.groupSizes[e])return t;for(var n=this.groupSizes[e],r=this.indexOfGroup(e),i=r+n,o=r;o=x&&(x=t+1),N.set(e,t),I.set(t,e)},M="style["+w+'][data-styled-version="5.3.11"]',L=RegExp("^"+w+'\\.g(\\d+)\\[id="([\\w\\d-]+)"\\].*?"([^"]*)'),j=function(e,t,n){for(var r,i=n.split(","),o=0,s=i.length;o=0;n--){var r=t[n];if(r&&1===r.nodeType&&r.hasAttribute(w))return r}}(n),o=void 0!==i?i.nextSibling:null;r.setAttribute(w,"active"),r.setAttribute("data-styled-version","5.3.11");var s=$();return s&&r.setAttribute("nonce",s),n.insertBefore(r,o),r},F=function(){function e(e){var t=this.element=B(e);t.appendChild(document.createTextNode("")),this.sheet=function(e){if(e.sheet)return e.sheet;for(var t=document.styleSheets,n=0,r=t.length;n=0){var n=document.createTextNode(t),r=this.nodes[e];return this.element.insertBefore(n,r||null),this.length++,!0}return!1},t.deleteRule=function(e){this.element.removeChild(this.nodes[e]),this.length--},t.getRule=function(e){return e0&&(u+=e+",")}),r+=""+c+l+'{content:"'+u+'"}/*!sc*/\n'}}}return r}(this)},e}(),X=/(a)(d)/gi,J=function(e){return String.fromCharCode(e+(e>25?39:97))};function V(e){var t,n="";for(t=Math.abs(e);t>52;t=t/52|0)n=J(t%52)+n;return(J(t%52)+n).replace(X,"$1-$2")}var Y=function(e,t){for(var n=t.length;n;)e=33*e^t.charCodeAt(--n);return e},Z=function(e){return Y(5381,e)};function K(e){for(var t=0;t>>0);if(!t.hasNameForId(r,s)){var a=n(o,"."+s,void 0,r);t.insertRules(r,s,a)}i.push(s),this.staticRulesId=s}}else{for(var c=this.rules.length,l=Y(this.baseHash,n.hash),u="",d=0;d>>0);if(!t.hasNameForId(r,m)){var g=n(u,"."+m,void 0,r);t.insertRules(r,m,g)}i.push(m)}}return i.join(" ")},e}(),et=/^\s*\/\/.*$/gm,en=[":","[",".","#"];function er(e){var t,n,r,i,o=void 0===e?E:e,s=o.options,a=void 0===s?E:s,l=o.plugins,u=void 0===l?v:l,d=new c(a),h=[],f=function(e){function t(t){if(t)try{e(t+"}")}catch(e){}}return function(n,r,i,o,s,a,c,l,u,d){switch(n){case 1:if(0===u&&64===r.charCodeAt(0))return e(r+";"),"";break;case 2:if(0===l)return r+"/*|*/";break;case 3:switch(l){case 102:case 112:return e(i[0]+r),"";default:return r+(0===d?"/*|*/":"")}case -2:r.split("/*|*/}").forEach(t)}}}(function(e){h.push(e)}),p=function(e,r,o){return 0===r&&-1!==en.indexOf(o[n.length])||o.match(i)?e:"."+t};function m(e,o,s,a){void 0===a&&(a="&");var c=e.replace(et,""),l=o&&s?s+" "+o+" { "+c+" }":c;return t=a,r=RegExp("\\"+(n=o)+"\\b","g"),i=RegExp("(\\"+n+"\\b){2,}"),d(s||!o?"":o,l)}return d.use([].concat(u,[function(e,t,i){2===e&&i.length&&i[0].lastIndexOf(n)>0&&(i[0]=i[0].replace(r,p))},f,function(e){if(-2===e){var t=h;return h=[],t}}])),m.hash=u.length?u.reduce(function(e,t){return t.name||A(15),Y(e,t.name)},5381).toString():"",m}var ei=o.createContext(),eo=(ei.Consumer,o.createContext()),es=(eo.Consumer,new z),ea=er();function ec(){return(0,o.useContext)(ei)||es}function el(){return(0,o.useContext)(eo)||ea}function eu(e){var t=(0,o.useState)(e.stylisPlugins),n=t[0],r=t[1],i=ec(),s=(0,o.useMemo)(function(){var t=i;return e.sheet?t=e.sheet:e.target&&(t=t.reconstructWithOptions({target:e.target},!1)),e.disableCSSOMInjection&&(t=t.reconstructWithOptions({useCSSOMInjection:!1})),t},[e.disableCSSOMInjection,e.sheet,e.target]),c=(0,o.useMemo)(function(){return er({options:{prefix:!e.disableVendorPrefixes},plugins:n})},[e.disableVendorPrefixes,n]);return(0,o.useEffect)(function(){a()(n,e.stylisPlugins)||r(e.stylisPlugins)},[e.stylisPlugins]),o.createElement(ei.Provider,{value:s},o.createElement(eo.Provider,{value:c},e.children))}var ed=function(){function e(e,t){var n=this;this.inject=function(e,t){void 0===t&&(t=ea);var r=n.name+t.hash;e.hasNameForId(n.id,r)||e.insertRules(n.id,r,t(n.rules,r,"@keyframes"))},this.toString=function(){return A(12,String(n.name))},this.name=e,this.id="sc-keyframes-"+e,this.rules=t}return e.prototype.getName=function(e){return void 0===e&&(e=ea),this.name+e.hash},e}(),eh=/([A-Z])/,ef=/([A-Z])/g,ep=/^ms-/,em=function(e){return"-"+e.toLowerCase()};function eg(e){return eh.test(e)?e.replace(ef,em).replace(ep,"-ms-"):e}var e_=function(e){return null==e||!1===e||""===e};function ey(e,t,n,r){if(Array.isArray(e)){for(var i,o=[],s=0,a=e.length;s1?t-1:0),r=1;r?@[\\\]^`{|}~-]+/g,eT=/(^-|-$)/g;function ew(e){return e.replace(eS,"-").replace(eT,"")}var eO=function(e){return V(Z(e)>>>0)};function eC(e){return"string"==typeof e}var eR=function(e){return"function"==typeof e||"object"==typeof e&&null!==e&&!Array.isArray(e)},eA=o.createContext();eA.Consumer;var ek={},eN=function(e){return function e(t,n,r){if(void 0===r&&(r=E),!(0,i.isValidElementType)(n))return A(1,String(n));var o=function(){return t(n,r,eE.apply(void 0,arguments))};return o.withConfig=function(i){return e(t,n,g({},r,{},i))},o.attrs=function(i){return e(t,n,g({},r,{attrs:Array.prototype.concat(r.attrs,i).filter(Boolean)}))},o}(function e(t,n,r){var i=T(t),s=!eC(t),a=n.attrs,c=void 0===a?v:a,l=n.componentId,u=void 0===l?(w=n.displayName,O=n.parentComponentId,ek[C="string"!=typeof w?"sc":ew(w)]=(ek[C]||0)+1,R=C+"-"+eO("5.3.11"+C+ek[C]),O?O+"-"+R:R):l,d=n.displayName,f=void 0===d?eC(t)?"styled."+t:"Styled("+S(t)+")":d,m=n.displayName&&n.componentId?ew(n.displayName)+"-"+n.componentId:n.componentId||u,_=i&&t.attrs?Array.prototype.concat(t.attrs,c).filter(Boolean):c,y=n.shouldForwardProp;i&&t.shouldForwardProp&&(y=n.shouldForwardProp?function(e,r,i){return t.shouldForwardProp(e,r,i)&&n.shouldForwardProp(e,r,i)}:t.shouldForwardProp);var w,O,C,R,A,k=new ee(r,m,i?t.componentStyle:void 0),N=k.isStatic&&0===c.length,I=function(e,t){return function(e,t,n,r){var i,s,a,c,l,u=e.attrs,d=e.componentStyle,f=e.defaultProps,p=e.foldedComponentIds,m=e.shouldForwardProp,_=e.styledComponentId,y=e.target,v=(void 0===(i=eb(t,(0,o.useContext)(eA),f)||E)&&(i=E),s=g({},t,{theme:i}),a={},u.forEach(function(e){var t,n,r,i=e;for(t in b(i)&&(i=i(s)),i)s[t]=a[t]="className"===t?(n=a[t],r=i[t],n&&r?n+" "+r:n||r):i[t]}),[s,a]),S=v[0],T=v[1],w=(c=ec(),l=el(),r?d.generateAndInjectStyles(E,c,l):d.generateAndInjectStyles(S,c,l)),O=T.$as||t.$as||T.as||t.as||y,C=eC(O),R=T!==t?g({},t,{},T):t,A={};for(var k in R)"$"!==k[0]&&"as"!==k&&("forwardedAs"===k?A.as=R[k]:(m?m(k,h,O):!C||h(k))&&(A[k]=R[k]));return t.style&&T.style!==t.style&&(A.style=g({},t.style,{},T.style)),A.className=Array.prototype.concat(p,_,w!==_?w:null,t.className,T.className).filter(Boolean).join(" "),A.ref=n,(0,o.createElement)(O,A)}(A,e,t,N)};return I.displayName=f,(A=o.forwardRef(I)).attrs=_,A.componentStyle=k,A.displayName=f,A.shouldForwardProp=y,A.foldedComponentIds=i?Array.prototype.concat(t.foldedComponentIds,t.styledComponentId):v,A.styledComponentId=m,A.target=i?t.target:t,A.withComponent=function(t){var i=n.componentId,o=function(e,t){if(null==e)return{};var n,r,i={},o=Object.keys(e);for(r=0;r=0||(i[n]=e[n]);return i}(n,["componentId"]),s=i&&i+"-"+(eC(t)?t:ew(S(t)));return e(t,g({},o,{attrs:_,componentId:s}),r)},Object.defineProperty(A,"defaultProps",{get:function(){return this._foldedDefaultProps},set:function(e){this._foldedDefaultProps=i?function e(t){for(var n=arguments.length,r=Array(n>1?n-1:0),i=1;i2&&z.registerId(this.componentId+e),this.removeStyles(e,n),this.createStyles(e,t,n,r)},e}();function ex(e){for(var t=arguments.length,n=Array(t>1?t-1:0),r=1;r1?t-1:0),r=1;r"+t+""},this.getStyleTags=function(){return e.sealed?A(2):e._emitSheetCSS()},this.getStyleElement=function(){if(e.sealed)return A(2);var t,n=((t={})[w]="",t["data-styled-version"]="5.3.11",t.dangerouslySetInnerHTML={__html:e.instance.toString()},t),r=$();return r&&(n.nonce=r),[o.createElement("style",g({},n,{key:"sc-0-0"}))]},this.seal=function(){e.sealed=!0},this.instance=new z({isServer:!0}),this.sealed=!1}).prototype).collectStyles=function(e){return this.sealed?A(2):o.createElement(eu,{sheet:this.instance},e)},r.interleaveWithNodeStream=function(e){return A(3)};var eP=eN},46926:function(e,t,n){"use strict";n.d(t,{G:function(){return h}});var r=n(53290),i=n(64383),o=n(12538),s=n(10318);class a{constructor(e,t){let n,r;n=e||new i.s,r=t||new i.s,this._stack=[{scope:n}],this._isolationScope=r}withScope(e){let t;let n=this._pushScope();try{t=e(n)}catch(e){throw this._popScope(),e}return(0,s.J8)(t)?t.then(e=>(this._popScope(),e),e=>{throw this._popScope(),e}):(this._popScope(),t)}getClient(){return this.getStackTop().client}getScope(){return this.getStackTop().scope}getIsolationScope(){return this._isolationScope}getStackTop(){return this._stack[this._stack.length-1]}_pushScope(){let e=this.getScope().clone();return this._stack.push({client:this.getClient(),scope:e}),e}_popScope(){return!(this._stack.length<=1)&&!!this._stack.pop()}}function c(){let e=(0,r.c)(),t=(0,r.q)(e);return t.stack=t.stack||new a((0,o.Y)("defaultCurrentScope",()=>new i.s),(0,o.Y)("defaultIsolationScope",()=>new i.s))}function l(e){return c().withScope(e)}function u(e,t){let n=c();return n.withScope(()=>(n.getStackTop().scope=e,t(e)))}function d(e){return c().withScope(()=>e(c().getIsolationScope()))}function h(e){let t=(0,r.q)(e);return t.acs?t.acs:{withIsolationScope:d,withScope:l,withSetScope:u,withSetIsolationScope:(e,t)=>d(t),getCurrentScope:()=>c().getScope(),getIsolationScope:()=>c().getIsolationScope()}}},53290:function(e,t,n){"use strict";n.d(t,{c:function(){return o},q:function(){return s}});var r=n(14481),i=n(12538);function o(){return s(i.GLOBAL_OBJ),i.GLOBAL_OBJ}function s(e){let t=e.__SENTRY__=e.__SENTRY__||{};return t.version=t.version||r.J,t[r.J]=t[r.J]||{}}},12556:function(e,t,n){"use strict";n.d(t,{J:function(){return r}});let r="production"},6411:function(e,t,n){"use strict";n.d(t,{$e:function(){return d},XX:function(){return f},aF:function(){return l},lW:function(){return u},nZ:function(){return c},s3:function(){return h}});var r=n(46926),i=n(53290),o=n(64383),s=n(98802),a=n(12538);function c(){let e=(0,i.c)();return(0,r.G)(e).getCurrentScope()}function l(){let e=(0,i.c)();return(0,r.G)(e).getIsolationScope()}function u(){return(0,a.Y)("globalScope",()=>new o.s)}function d(...e){let t=(0,i.c)(),n=(0,r.G)(t);if(2===e.length){let[t,r]=e;return t?n.withSetScope(t,r):n.withScope(r)}return n.withScope(e[0])}function h(){return c().getClient()}function f(e){let{traceId:t,spanId:n,parentSpanId:r}=e.getPropagationContext();return(0,s.Jr)({trace_id:t,span_id:n,parent_span_id:r})}},57229:function(e,t,n){"use strict";n.d(t,{X:function(){return r}});let r=!1},38211:function(e,t,n){"use strict";n.d(t,{Qy:function(){return m},Tb:function(){return u},_k:function(){return p},cg:function(){return v},eN:function(){return d},v:function(){return h},yj:function(){return g},yl:function(){return f}});var r=n(12556),i=n(6411),o=n(57229),s=n(28161),a=n(15196),c=n(12538),l=n(24660);function u(e,t){return(0,i.nZ)().captureException(e,(0,l.U0)(t))}function d(e,t){return(0,i.nZ)().captureEvent(e,t)}function h(e,t){(0,i.aF)().setContext(e,t)}async function f(e){let t=(0,i.s3)();return t?t.flush(e):(o.X&&a.kg.warn("Cannot flush events. No client defined."),Promise.resolve(!1))}function p(){let e=(0,i.s3)();return!!e&&!1!==e.getOptions().enabled&&!!e.getTransport()}function m(e){(0,i.aF)().addEventProcessor(e)}function g(e){let t=(0,i.s3)(),n=(0,i.aF)(),o=(0,i.nZ)(),{release:a,environment:l=r.J}=t&&t.getOptions()||{},{userAgent:u}=c.GLOBAL_OBJ.navigator||{},d=(0,s.Hv)({release:a,environment:l,user:o.getUser()||n.getUser(),...u&&{userAgent:u},...e}),h=n.getSession();return h&&"ok"===h.status&&(0,s.CT)(h,{status:"exited"}),_(),n.setSession(d),o.setSession(d),d}function _(){let e=(0,i.aF)(),t=(0,i.nZ)(),n=t.getSession()||e.getSession();n&&(0,s.RJ)(n),y(),e.setSession(),t.setSession()}function y(){let e=(0,i.aF)(),t=(0,i.nZ)(),n=(0,i.s3)(),r=t.getSession()||e.getSession();r&&n&&n.captureSession(r)}function v(e=!1){if(e){_();return}y()}},94637:function(e,t,n){"use strict";n.d(t,{y:function(){return i}});var r=n(98802);function i(e){let t=e._sentryMetrics;if(!t)return;let n={};for(let[,[e,i]]of t)(n[e]||(n[e]=[])).push((0,r.Jr)(i));return n}},64383:function(e,t,n){"use strict";n.d(t,{s:function(){return h}});var r=n(28161),i=n(10318),o=n(15196),s=n(14038),a=n(42370),c=n(4134),l=n(84246),u=n(39960);class d{constructor(){this._notifyingListeners=!1,this._scopeListeners=[],this._eventProcessors=[],this._breadcrumbs=[],this._attachments=[],this._user={},this._tags={},this._extra={},this._contexts={},this._sdkProcessingMetadata={},this._propagationContext={traceId:(0,a.Ht)(),spanId:(0,a.M)()}}clone(){let e=new d;return e._breadcrumbs=[...this._breadcrumbs],e._tags={...this._tags},e._extra={...this._extra},e._contexts={...this._contexts},this._contexts.flags&&(e._contexts.flags={values:[...this._contexts.flags.values]}),e._user=this._user,e._level=this._level,e._session=this._session,e._transactionName=this._transactionName,e._fingerprint=this._fingerprint,e._eventProcessors=[...this._eventProcessors],e._requestSession=this._requestSession,e._attachments=[...this._attachments],e._sdkProcessingMetadata={...this._sdkProcessingMetadata},e._propagationContext={...this._propagationContext},e._client=this._client,e._lastEventId=this._lastEventId,(0,u.D)(e,(0,u.Y)(this)),e}setClient(e){this._client=e}setLastEventId(e){this._lastEventId=e}getClient(){return this._client}lastEventId(){return this._lastEventId}addScopeListener(e){this._scopeListeners.push(e)}addEventProcessor(e){return this._eventProcessors.push(e),this}setUser(e){return this._user=e||{email:void 0,id:void 0,ip_address:void 0,username:void 0},this._session&&(0,r.CT)(this._session,{user:e}),this._notifyScopeListeners(),this}getUser(){return this._user}getRequestSession(){return this._requestSession}setRequestSession(e){return this._requestSession=e,this}setTags(e){return this._tags={...this._tags,...e},this._notifyScopeListeners(),this}setTag(e,t){return this._tags={...this._tags,[e]:t},this._notifyScopeListeners(),this}setExtras(e){return this._extra={...this._extra,...e},this._notifyScopeListeners(),this}setExtra(e,t){return this._extra={...this._extra,[e]:t},this._notifyScopeListeners(),this}setFingerprint(e){return this._fingerprint=e,this._notifyScopeListeners(),this}setLevel(e){return this._level=e,this._notifyScopeListeners(),this}setTransactionName(e){return this._transactionName=e,this._notifyScopeListeners(),this}setContext(e,t){return null===t?delete this._contexts[e]:this._contexts[e]=t,this._notifyScopeListeners(),this}setSession(e){return e?this._session=e:delete this._session,this._notifyScopeListeners(),this}getSession(){return this._session}update(e){if(!e)return this;let t="function"==typeof e?e(this):e,[n,r]=t instanceof h?[t.getScopeData(),t.getRequestSession()]:(0,i.PO)(t)?[e,e.requestSession]:[],{tags:o,extra:s,user:a,contexts:c,level:l,fingerprint:u=[],propagationContext:d}=n||{};return this._tags={...this._tags,...o},this._extra={...this._extra,...s},this._contexts={...this._contexts,...c},a&&Object.keys(a).length&&(this._user=a),l&&(this._level=l),u.length&&(this._fingerprint=u),d&&(this._propagationContext=d),r&&(this._requestSession=r),this}clear(){return this._breadcrumbs=[],this._tags={},this._extra={},this._user={},this._contexts={},this._level=void 0,this._transactionName=void 0,this._fingerprint=void 0,this._requestSession=void 0,this._session=void 0,(0,u.D)(this,void 0),this._attachments=[],this.setPropagationContext({traceId:(0,a.Ht)()}),this._notifyScopeListeners(),this}addBreadcrumb(e,t){let n="number"==typeof t?t:100;if(n<=0)return this;let r={timestamp:(0,c.yW)(),...e},i=this._breadcrumbs;return i.push(r),this._breadcrumbs=i.length>n?i.slice(-n):i,this._notifyScopeListeners(),this}getLastBreadcrumb(){return this._breadcrumbs[this._breadcrumbs.length-1]}clearBreadcrumbs(){return this._breadcrumbs=[],this._notifyScopeListeners(),this}addAttachment(e){return this._attachments.push(e),this}clearAttachments(){return this._attachments=[],this}getScopeData(){return{breadcrumbs:this._breadcrumbs,attachments:this._attachments,contexts:this._contexts,tags:this._tags,extra:this._extra,user:this._user,level:this._level,fingerprint:this._fingerprint||[],eventProcessors:this._eventProcessors,propagationContext:this._propagationContext,sdkProcessingMetadata:this._sdkProcessingMetadata,transactionName:this._transactionName,span:(0,u.Y)(this)}}setSDKProcessingMetadata(e){return this._sdkProcessingMetadata=(0,l.T)(this._sdkProcessingMetadata,e,2),this}setPropagationContext(e){return this._propagationContext={spanId:(0,a.M)(),...e},this}getPropagationContext(){return this._propagationContext}captureException(e,t){let n=t&&t.event_id?t.event_id:(0,s.DM)();if(!this._client)return o.kg.warn("No client configured on scope - will not capture exception!"),n;let r=Error("Sentry syntheticException");return this._client.captureException(e,{originalException:e,syntheticException:r,...t,event_id:n},this),n}captureMessage(e,t,n){let r=n&&n.event_id?n.event_id:(0,s.DM)();if(!this._client)return o.kg.warn("No client configured on scope - will not capture message!"),r;let i=Error(e);return this._client.captureMessage(e,t,{originalException:e,syntheticException:i,...n,event_id:r},this),r}captureEvent(e,t){let n=t&&t.event_id?t.event_id:(0,s.DM)();return this._client?this._client.captureEvent(e,{...t,event_id:n},this):o.kg.warn("No client configured on scope - will not capture event!"),n}_notifyScopeListeners(){this._notifyingListeners||(this._notifyingListeners=!0,this._scopeListeners.forEach(e=>{e(this)}),this._notifyingListeners=!1)}}let h=d},95503:function(e,t,n){"use strict";n.d(t,{$J:function(){return o},E1:function(){return c},JQ:function(){return d},S3:function(){return s},TE:function(){return i},Wb:function(){return l},Zj:function(){return r},ju:function(){return a},p6:function(){return u}});let r="sentry.source",i="sentry.sample_rate",o="sentry.op",s="sentry.origin",a="sentry.idle_span_finish_reason",c="sentry.measurement_unit",l="sentry.measurement_value",u="sentry.profile_id",d="sentry.exclusive_time"},28161:function(e,t,n){"use strict";n.d(t,{CT:function(){return a},Hv:function(){return s},RJ:function(){return c}});var r=n(98802),i=n(4134),o=n(14038);function s(e){let t=(0,i.ph)(),n={sid:(0,o.DM)(),init:!0,timestamp:t,started:t,duration:0,status:"ok",errors:0,ignoreDuration:!1,toJSON:()=>(0,r.Jr)({sid:`${n.sid}`,init:n.init,started:new Date(1e3*n.started).toISOString(),timestamp:new Date(1e3*n.timestamp).toISOString(),status:n.status,errors:n.errors,did:"number"==typeof n.did||"string"==typeof n.did?`${n.did}`:void 0,duration:n.duration,abnormal_mechanism:n.abnormal_mechanism,attrs:{release:n.release,environment:n.environment,ip_address:n.ipAddress,user_agent:n.userAgent}})};return e&&a(n,e),n}function a(e,t={}){if(!t.user||(!e.ipAddress&&t.user.ip_address&&(e.ipAddress=t.user.ip_address),e.did||t.did||(e.did=t.user.id||t.user.email||t.user.username)),e.timestamp=t.timestamp||(0,i.ph)(),t.abnormal_mechanism&&(e.abnormal_mechanism=t.abnormal_mechanism),t.ignoreDuration&&(e.ignoreDuration=t.ignoreDuration),t.sid&&(e.sid=32===t.sid.length?t.sid:(0,o.DM)()),void 0!==t.init&&(e.init=t.init),!e.did&&t.did&&(e.did=`${t.did}`),"number"==typeof t.started&&(e.started=t.started),e.ignoreDuration)e.duration=void 0;else if("number"==typeof t.duration)e.duration=t.duration;else{let t=e.timestamp-e.started;e.duration=t>=0?t:0}t.release&&(e.release=t.release),t.environment&&(e.environment=t.environment),!e.ipAddress&&t.ipAddress&&(e.ipAddress=t.ipAddress),!e.userAgent&&t.userAgent&&(e.userAgent=t.userAgent),"number"==typeof t.errors&&(e.errors=t.errors),t.status&&(e.status=t.status)}function c(e,t){let n={};t?n={status:t}:"ok"===e.status&&(n={status:"exited"}),a(e,n)}},15815:function(e,t,n){"use strict";n.d(t,{CG:function(){return f},Lh:function(){return d},jC:function(){return p}});var r=n(12556),i=n(6411),o=n(95503),s=n(70600),a=n(98802),c=n(8845),l=n(1543);let u="_frozenDsc";function d(e,t){(0,a.xp)(e,u,t)}function h(e,t){let n=t.getOptions(),{publicKey:i}=t.getDsn()||{},o=(0,a.Jr)({environment:n.environment||r.J,release:n.release,public_key:i,trace_id:e});return t.emit("createDsc",o),o}function f(e,t){let n=t.getPropagationContext();return n.dsc||h(n.traceId,e)}function p(e){let t=(0,i.s3)();if(!t)return{};let n=(0,l.Gx)(e),r=n[u];if(r)return r;let a=n.spanContext().traceState,d=a&&a.get("sentry.dsc"),f=d&&(0,s.EN)(d);if(f)return f;let p=h(e.spanContext().traceId,t),m=(0,l.XU)(n),g=m.data||{},_=g[o.TE];null!=_&&(p.sample_rate=`${_}`);let y=g[o.Zj],v=m.description;return"url"!==y&&v&&(p.transaction=v),(0,c.z)()&&(p.sampled=String((0,l.Tt)(n))),t.emit("createDsc",p,n),p}},18225:function(e,t,n){"use strict";n.d(t,{OP:function(){return i},Q0:function(){return s},jt:function(){return o},pq:function(){return r}});let r=0,i=1,o=2;function s(e,t){e.setAttribute("http.response.status_code",t);let n=function(e){if(e<400&&e>=100)return{code:i};if(e>=400&&e<500)switch(e){case 401:return{code:o,message:"unauthenticated"};case 403:return{code:o,message:"permission_denied"};case 404:return{code:o,message:"not_found"};case 409:return{code:o,message:"already_exists"};case 413:return{code:o,message:"failed_precondition"};case 429:return{code:o,message:"resource_exhausted"};case 499:return{code:o,message:"cancelled"};default:return{code:o,message:"invalid_argument"}}if(e>=500&&e<600)switch(e){case 501:return{code:o,message:"unimplemented"};case 503:return{code:o,message:"unavailable"};case 504:return{code:o,message:"deadline_exceeded"};default:return{code:o,message:"internal_error"}}return{code:o,message:"unknown_error"}}(t);"unknown_error"!==n.message&&e.setStatus(n)}},70600:function(e,t,n){"use strict";n.d(t,{EN:function(){return c},IQ:function(){return l},XM:function(){return u},lq:function(){return s}});var r=n(92051),i=n(10318),o=n(15196);let s="sentry-",a=/^sentry-/;function c(e){let t=u(e);if(!t)return;let n=Object.entries(t).reduce((e,[t,n])=>(t.match(a)&&(e[t.slice(s.length)]=n),e),{});return Object.keys(n).length>0?n:void 0}function l(e){if(e)return function(e){if(0!==Object.keys(e).length)return Object.entries(e).reduce((e,[t,n],i)=>{let s=`${encodeURIComponent(t)}=${encodeURIComponent(n)}`,a=0===i?s:`${e},${s}`;return a.length>8192?(r.X&&o.kg.warn(`Not adding key: ${t} with val: ${n} to baggage header due to exceeding baggage size limits.`),e):a},"")}(Object.entries(e).reduce((e,[t,n])=>(n&&(e[`${s}${t}`]=n),e),{}))}function u(e){return e&&((0,i.HD)(e)||Array.isArray(e))?Array.isArray(e)?e.reduce((e,t)=>(Object.entries(d(t)).forEach(([t,n])=>{e[t]=n}),e),{}):d(e):void 0}function d(e){return e.split(",").map(e=>e.split("=").map(e=>decodeURIComponent(e.trim()))).reduce((e,[t,n])=>(t&&n&&(e[t]=n),e),{})}},37389:function(e,t,n){"use strict";n.d(t,{Rt:function(){return o},iY:function(){return c},l4:function(){return s},qT:function(){return a}});var r=n(10318);let i=n(12538).GLOBAL_OBJ;function o(e,t={}){if(!e)return"";try{let n,o=e,s=[],a=0,c=0,l=Array.isArray(t)?t:t.keyAttrs,u=!Array.isArray(t)&&t.maxStringLength||80;for(;o&&a++<5&&(n=function(e,t){let n=[];if(!e||!e.tagName)return"";if(i.HTMLElement&&e instanceof HTMLElement&&e.dataset){if(e.dataset.sentryComponent)return e.dataset.sentryComponent;if(e.dataset.sentryElement)return e.dataset.sentryElement}n.push(e.tagName.toLowerCase());let o=t&&t.length?t.filter(t=>e.getAttribute(t)).map(t=>[t,e.getAttribute(t)]):null;if(o&&o.length)o.forEach(e=>{n.push(`[${e[0]}="${e[1]}"]`)});else{e.id&&n.push(`#${e.id}`);let t=e.className;if(t&&(0,r.HD)(t))for(let e of t.split(/\s+/))n.push(`.${e}`)}for(let t of["aria-label","type","name","title","alt"]){let r=e.getAttribute(t);r&&n.push(`[${t}="${r}"]`)}return n.join("")}(o,l),"html"!==n&&(!(a>1)||!(c+3*s.length+n.length>=u)));)s.push(n),c+=n.length,o=o.parentNode;return s.reverse().join(" > ")}catch(e){return""}}function s(){try{return i.document.location.href}catch(e){return""}}function a(e){return i.document&&i.document.querySelector?i.document.querySelector(e):null}function c(e){if(!i.HTMLElement)return null;let t=e;for(let e=0;e<5&&t;e++){if(t instanceof HTMLElement){if(t.dataset.sentryComponent)return t.dataset.sentryComponent;if(t.dataset.sentryElement)return t.dataset.sentryElement}t=t.parentNode}return null}},92051:function(e,t,n){"use strict";n.d(t,{X:function(){return r}});let r=!1},10318:function(e,t,n){"use strict";n.d(t,{Cy:function(){return _},HD:function(){return l},J8:function(){return g},Kj:function(){return m},Le:function(){return u},PO:function(){return h},TX:function(){return a},V9:function(){return y},VW:function(){return s},VZ:function(){return i},cO:function(){return f},fm:function(){return c},kK:function(){return p},pt:function(){return d},y1:function(){return v}});let r=Object.prototype.toString;function i(e){switch(r.call(e)){case"[object Error]":case"[object Exception]":case"[object DOMException]":case"[object WebAssembly.Exception]":return!0;default:return y(e,Error)}}function o(e,t){return r.call(e)===`[object ${t}]`}function s(e){return o(e,"ErrorEvent")}function a(e){return o(e,"DOMError")}function c(e){return o(e,"DOMException")}function l(e){return o(e,"String")}function u(e){return"object"==typeof e&&null!==e&&"__sentry_template_string__"in e&&"__sentry_template_values__"in e}function d(e){return null===e||u(e)||"object"!=typeof e&&"function"!=typeof e}function h(e){return o(e,"Object")}function f(e){return"undefined"!=typeof Event&&y(e,Event)}function p(e){return"undefined"!=typeof Element&&y(e,Element)}function m(e){return o(e,"RegExp")}function g(e){return!!(e&&e.then&&"function"==typeof e.then)}function _(e){return h(e)&&"nativeEvent"in e&&"preventDefault"in e&&"stopPropagation"in e}function y(e,t){try{return e instanceof t}catch(e){return!1}}function v(e){return!!("object"==typeof e&&null!==e&&(e.__isVue||e._isVue))}},15196:function(e,t,n){"use strict";n.d(t,{Cf:function(){return a},LD:function(){return s},RU:function(){return o},kg:function(){return c}});var r=n(92051),i=n(12538);let o=["debug","info","warn","error","log","assert","trace"],s={};function a(e){if(!("console"in i.GLOBAL_OBJ))return e();let t=i.GLOBAL_OBJ.console,n={},r=Object.keys(s);r.forEach(e=>{let r=s[e];n[e]=t[e],t[e]=r});try{return e()}finally{r.forEach(e=>{t[e]=n[e]})}}let c=(0,i.Y)("logger",function(){let e=!1,t={enable:()=>{e=!0},disable:()=>{e=!1},isEnabled:()=>e};return r.X?o.forEach(n=>{t[n]=(...t)=>{e&&a(()=>{i.GLOBAL_OBJ.console[n](`Sentry Logger [${n}]:`,...t)})}}):o.forEach(e=>{t[e]=()=>void 0}),t})},14038:function(e,t,n){"use strict";n.d(t,{DM:function(){return o},Db:function(){return c},EG:function(){return l},YO:function(){return u},jH:function(){return a}});var r=n(98802),i=n(12538);function o(){let e=i.GLOBAL_OBJ,t=e.crypto||e.msCrypto,n=()=>16*Math.random();try{if(t&&t.randomUUID)return t.randomUUID().replace(/-/g,"");t&&t.getRandomValues&&(n=()=>{let e=new Uint8Array(1);return t.getRandomValues(e),e[0]})}catch(e){}return"10000000100040008000100000000000".replace(/[018]/g,e=>(e^(15&n())>>e/4).toString(16))}function s(e){return e.exception&&e.exception.values?e.exception.values[0]:void 0}function a(e){let{message:t,event_id:n}=e;if(t)return t;let r=s(e);return r?r.type&&r.value?`${r.type}: ${r.value}`:r.type||r.value||n||"":n||""}function c(e,t,n){let r=e.exception=e.exception||{},i=r.values=r.values||[],o=i[0]=i[0]||{};o.value||(o.value=t||""),o.type||(o.type=n||"Error")}function l(e,t){let n=s(e);if(!n)return;let r=n.mechanism;if(n.mechanism={type:"generic",handled:!0,...r,...t},t&&"data"in t){let e={...r&&r.data,...t.data};n.mechanism.data=e}}function u(e){if(function(e){try{return e.__sentry_captured__}catch(e){}}(e))return!0;try{(0,r.xp)(e,"__sentry_captured__",!0)}catch(e){}return!1}},67089:function(e,t,n){"use strict";n.d(t,{Fv:function(){return s},Qy:function(){return function e(t,n=3,r=102400){let i=s(t,n);return~-encodeURI(JSON.stringify(i)).split(/%..|./).length>r?e(t,n-1,r):i}}});var r=n(10318),i=n(98802),o=n(59628);function s(e,t=100,n=Infinity){try{return function e(t,n,s=Infinity,a=Infinity,c=function(){let e="function"==typeof WeakSet,t=e?new WeakSet:[];return[function(n){if(e)return!!t.has(n)||(t.add(n),!1);for(let e=0;e=a){f[t]="[MaxProperties ~]";break}let n=m[t];f[t]=e(t,n,h-1,a,c),p++}return u(n),f}("",e,t,n)}catch(e){return{ERROR:`**non-serializable** (${e})`}}}},98802:function(e,t,n){"use strict";n.d(t,{$Q:function(){return u},HK:function(){return d},Jr:function(){return g},Sh:function(){return h},hl:function(){return c},xp:function(){return l},zf:function(){return m}});var r=n(37389),i=n(92051),o=n(10318),s=n(15196),a=n(21632);function c(e,t,n){if(!(t in e))return;let r=e[t],o=n(r);"function"==typeof o&&u(o,r);try{e[t]=o}catch(n){i.X&&s.kg.log(`Failed to replace method "${t}" in object`,e)}}function l(e,t,n){try{Object.defineProperty(e,t,{value:n,writable:!0,configurable:!0})}catch(n){i.X&&s.kg.log(`Failed to add non-enumerable property "${t}" to object`,e)}}function u(e,t){try{let n=t.prototype||{};e.prototype=t.prototype=n,l(e,"__sentry_original__",t)}catch(e){}}function d(e){return e.__sentry_original__}function h(e){if((0,o.VZ)(e))return{message:e.message,name:e.name,stack:e.stack,...p(e)};if(!(0,o.cO)(e))return e;{let t={type:e.type,target:f(e.target),currentTarget:f(e.currentTarget),...p(e)};return"undefined"!=typeof CustomEvent&&(0,o.V9)(e,CustomEvent)&&(t.detail=e.detail),t}}function f(e){try{return(0,o.kK)(e)?(0,r.Rt)(e):Object.prototype.toString.call(e)}catch(e){return""}}function p(e){if("object"!=typeof e||null===e)return{};{let t={};for(let n in e)Object.prototype.hasOwnProperty.call(e,n)&&(t[n]=e[n]);return t}}function m(e,t=40){let n=Object.keys(h(e));n.sort();let r=n[0];if(!r)return"[object has no keys]";if(r.length>=t)return(0,a.$G)(r,t);for(let e=n.length;e>0;e--){let r=n.slice(0,e).join(", ");if(!(r.length>t)){if(e===n.length)return r;return(0,a.$G)(r,t)}}return""}function g(e){return function e(t,n){if(function(e){if(!(0,o.PO)(e))return!1;try{let t=Object.getPrototypeOf(e).constructor.name;return!t||"Object"===t}catch(e){return!0}}(t)){let r=n.get(t);if(void 0!==r)return r;let i={};for(let r of(n.set(t,i),Object.getOwnPropertyNames(t)))void 0!==t[r]&&(i[r]=e(t[r],n));return i}if(Array.isArray(t)){let r=n.get(t);if(void 0!==r)return r;let i=[];return n.set(t,i),t.forEach(t=>{i.push(e(t,n))}),i}return t}(e,new Map)}},42370:function(e,t,n){"use strict";n.d(t,{Ht:function(){return i},M:function(){return o}});var r=n(14038);function i(){return(0,r.DM)()}function o(){return(0,r.DM)().substring(16)}},59628:function(e,t,n){"use strict";n.d(t,{$P:function(){return u},Fi:function(){return r},Fr:function(){return d},Sq:function(){return a},pE:function(){return s}});let r="?",i=/\(error: (.*)\)/,o=/captureMessage|captureException/;function s(...e){let t=e.sort((e,t)=>e[0]-t[0]).map(e=>e[1]);return(e,n=0,s=0)=>{let a=[],l=e.split("\n");for(let e=n;e1024)continue;let r=i.test(n)?n.replace(i,"$1"):n;if(!r.match(/\S*Error: /)){for(let e of t){let t=e(r);if(t){a.push(t);break}}if(a.length>=50+s)break}}return function(e){if(!e.length)return[];let t=Array.from(e);return/sentryWrapped/.test(c(t).function||"")&&t.pop(),t.reverse(),o.test(c(t).function||"")&&(t.pop(),o.test(c(t).function||"")&&t.pop()),t.slice(0,50).map(e=>({...e,filename:e.filename||c(t).filename,function:e.function||r}))}(a.slice(s))}}function a(e){return Array.isArray(e)?s(...e):e}function c(e){return e[e.length-1]||{}}let l="";function u(e){try{if(!e||"function"!=typeof e)return l;return e.name||l}catch(e){return l}}function d(e){let t=e.exception;if(t){let e=[];try{return t.values.forEach(t=>{t.stacktrace.frames&&e.push(...t.stacktrace.frames)}),e}catch(e){}}}},21632:function(e,t,n){"use strict";n.d(t,{$G:function(){return i},U0:function(){return s},nK:function(){return o}});var r=n(10318);function i(e,t=0){return"string"!=typeof e||0===t?e:e.length<=t?e:`${e.slice(0,t)}...`}function o(e,t){if(!Array.isArray(e))return"";let n=[];for(let t=0;t(function(e,t,n=!1){return!!(0,r.HD)(e)&&((0,r.Kj)(t)?t.test(e):!!(0,r.HD)(t)&&(n?e===t:e.includes(t)))})(e,t,n))}},71027:function(e,t,n){"use strict";n.d(t,{$2:function(){return a},WD:function(){return s},cW:function(){return c}});var r,i,o=n(10318);function s(e){return new c(t=>{t(e)})}function a(e){return new c((t,n)=>{n(e)})}(r=i||(i={}))[r.PENDING=0]="PENDING",r[r.RESOLVED=1]="RESOLVED",r[r.REJECTED=2]="REJECTED";class c{constructor(e){c.prototype.__init.call(this),c.prototype.__init2.call(this),c.prototype.__init3.call(this),c.prototype.__init4.call(this),this._state=i.PENDING,this._handlers=[];try{e(this._resolve,this._reject)}catch(e){this._reject(e)}}then(e,t){return new c((n,r)=>{this._handlers.push([!1,t=>{if(e)try{n(e(t))}catch(e){r(e)}else n(t)},e=>{if(t)try{n(t(e))}catch(e){r(e)}else r(e)}]),this._executeHandlers()})}catch(e){return this.then(e=>e,e)}finally(e){return new c((t,n)=>{let r,i;return this.then(t=>{i=!1,r=t,e&&e()},t=>{i=!0,r=t,e&&e()}).then(()=>{if(i){n(r);return}t(r)})})}__init(){this._resolve=e=>{this._setResult(i.RESOLVED,e)}}__init2(){this._reject=e=>{this._setResult(i.REJECTED,e)}}__init3(){this._setResult=(e,t)=>{if(this._state===i.PENDING){if((0,o.J8)(t)){t.then(this._resolve,this._reject);return}this._state=e,this._value=t,this._executeHandlers()}}}__init4(){this._executeHandlers=()=>{if(this._state===i.PENDING)return;let e=this._handlers.slice();this._handlers=[],e.forEach(e=>{e[0]||(this._state===i.RESOLVED&&e[1](this._value),this._state===i.REJECTED&&e[2](this._value),e[0]=!0)})}}}},4134:function(e,t,n){"use strict";n.d(t,{Z1:function(){return s},ph:function(){return o},yW:function(){return i}});var r=n(12538);function i(){return Date.now()/1e3}let o=function(){let{performance:e}=r.GLOBAL_OBJ;if(!e||!e.now)return i;let t=Date.now()-e.now(),n=void 0==e.timeOrigin?t:e.timeOrigin;return()=>(n+e.now())/1e3}(),s=(()=>{let{performance:e}=r.GLOBAL_OBJ;if(!e||!e.now)return;let t=e.now(),n=Date.now(),i=e.timeOrigin?Math.abs(e.timeOrigin+t-n):36e5,o=e.timing&&e.timing.navigationStart,s="number"==typeof o?Math.abs(o+t-n):36e5;return i<36e5||s<36e5?i<=s?e.timeOrigin:o:n})()},54310:function(e,t,n){"use strict";n.d(t,{$p:function(){return a},Ke:function(){return o},pT:function(){return s}});var r=n(70600),i=n(42370);let o=RegExp("^[ \\t]*([0-9a-f]{32})?-?([0-9a-f]{16})?-?([01])?[ \\t]*$");function s(e,t){let n=function(e){let t;if(!e)return;let n=e.match(o);if(n)return"1"===n[3]?t=!0:"0"===n[3]&&(t=!1),{traceId:n[1],parentSampled:t,parentSpanId:n[2]}}(e),s=(0,r.EN)(t);if(!n||!n.traceId)return{traceId:(0,i.Ht)(),spanId:(0,i.M)()};let{traceId:a,parentSpanId:c,parentSampled:l}=n;return{traceId:a,parentSpanId:c,spanId:(0,i.M)(),sampled:l,dsc:s||{}}}function a(e=(0,i.Ht)(),t=(0,i.M)(),n){let r="";return void 0!==n&&(r=n?"-1":"-0"),`${e}-${t}${r}`}},14481:function(e,t,n){"use strict";n.d(t,{J:function(){return r}});let r="8.45.0"},12538:function(e,t,n){"use strict";n.d(t,{GLOBAL_OBJ:function(){return i},Y:function(){return o}});var r=n(14481);let i=globalThis;function o(e,t,n){let o=n||i,s=o.__SENTRY__=o.__SENTRY__||{},a=s[r.J]=s[r.J]||{};return a[e]||(a[e]=t())}},8845:function(e,t,n){"use strict";n.d(t,{z:function(){return i}});var r=n(6411);function i(e){if("boolean"==typeof __SENTRY_TRACING__&&!__SENTRY_TRACING__)return!1;let t=(0,r.s3)(),n=e||t&&t.getOptions();return!!n&&(n.enableTracing||"tracesSampleRate"in n||"tracesSampler"in n)}},84246:function(e,t,n){"use strict";n.d(t,{T:function(){return function e(t,n,r=2){if(!n||"object"!=typeof n||r<=0)return n;if(t&&n&&0===Object.keys(n).length)return t;let i={...t};for(let t in n)Object.prototype.hasOwnProperty.call(n,t)&&(i[t]=e(i[t],n[t],r-1));return i}}})},24660:function(e,t,n){"use strict";let r,i,o;n.d(t,{U0:function(){return O},R:function(){return w}});var s=n(12556),a=n(6411),c=n(57229),l=n(10318),u=n(15196),d=n(71027),h=n(64383),f=n(12538),p=n(14038),m=n(67089),g=n(21632),_=n(4134),y=n(15815),v=n(98802),E=n(84246),b=n(1543);function S(e,t){let{extra:n,tags:r,user:i,contexts:o,level:s,sdkProcessingMetadata:a,breadcrumbs:c,fingerprint:l,eventProcessors:u,attachments:d,propagationContext:h,transactionName:f,span:p}=t;T(e,"extra",n),T(e,"tags",r),T(e,"user",i),T(e,"contexts",o),e.sdkProcessingMetadata=(0,E.T)(e.sdkProcessingMetadata,a,2),s&&(e.level=s),f&&(e.transactionName=f),p&&(e.span=p),c.length&&(e.breadcrumbs=[...e.breadcrumbs,...c]),l.length&&(e.fingerprint=[...e.fingerprint,...l]),u.length&&(e.eventProcessors=[...e.eventProcessors,...u]),d.length&&(e.attachments=[...e.attachments,...d]),e.propagationContext={...e.propagationContext,...h}}function T(e,t,n){e[t]=(0,E.T)(e[t],n,1)}function w(e,t,n,E,T,w){let{normalizeDepth:O=3,normalizeMaxBreadth:C=1e3}=e,R={...t,event_id:t.event_id||n.event_id||(0,p.DM)(),timestamp:t.timestamp||(0,_.yW)()},A=n.integrations||e.integrations.map(e=>e.name);(function(e,t){let{environment:n,release:r,dist:i,maxValueLength:o=250}=t;e.environment=e.environment||n||s.J,!e.release&&r&&(e.release=r),!e.dist&&i&&(e.dist=i),e.message&&(e.message=(0,g.$G)(e.message,o));let a=e.exception&&e.exception.values&&e.exception.values[0];a&&a.value&&(a.value=(0,g.$G)(a.value,o));let c=e.request;c&&c.url&&(c.url=(0,g.$G)(c.url,o))})(R,e),A.length>0&&(R.sdk=R.sdk||{},R.sdk.integrations=[...R.sdk.integrations||[],...A]),T&&T.emit("applyFrameMetadata",t),void 0===t.type&&function(e,t){let n=function(e){let t=f.GLOBAL_OBJ._sentryDebugIds;if(!t)return{};let n=Object.keys(t);return o&&n.length===i?o:(i=n.length,o=n.reduce((n,i)=>{r||(r={});let o=r[i];if(o)n[o[0]]=o[1];else{let o=e(i);for(let e=o.length-1;e>=0;e--){let s=o[e],a=s&&s.filename,c=t[i];if(a&&c){n[a]=c,r[i]=[a,c];break}}}return n},{}))}(t);try{e.exception.values.forEach(e=>{e.stacktrace.frames.forEach(e=>{n&&e.filename&&(e.debug_id=n[e.filename])})})}catch(e){}}(R,e.stackParser);let k=function(e,t){if(!t)return e;let n=e?e.clone():new h.s;return n.update(t),n}(E,n.captureContext);n.mechanism&&(0,p.EG)(R,n.mechanism);let N=T?T.getEventProcessors():[],I=(0,a.lW)().getScopeData();w&&S(I,w.getScopeData()),k&&S(I,k.getScopeData());let x=[...n.attachments||[],...I.attachments];return x.length&&(n.attachments=x),function(e,t){let{fingerprint:n,span:r,breadcrumbs:i,sdkProcessingMetadata:o}=t;(function(e,t){let{extra:n,tags:r,user:i,contexts:o,level:s,transactionName:a}=t,c=(0,v.Jr)(n);c&&Object.keys(c).length&&(e.extra={...c,...e.extra});let l=(0,v.Jr)(r);l&&Object.keys(l).length&&(e.tags={...l,...e.tags});let u=(0,v.Jr)(i);u&&Object.keys(u).length&&(e.user={...u,...e.user});let d=(0,v.Jr)(o);d&&Object.keys(d).length&&(e.contexts={...d,...e.contexts}),s&&(e.level=s),a&&"transaction"!==e.type&&(e.transaction=a)})(e,t),r&&function(e,t){e.contexts={trace:(0,b.wy)(t),...e.contexts},e.sdkProcessingMetadata={dynamicSamplingContext:(0,y.jC)(t),...e.sdkProcessingMetadata};let n=(0,b.Gx)(t),r=(0,b.XU)(n).description;r&&!e.transaction&&"transaction"===e.type&&(e.transaction=r)}(e,r),e.fingerprint=e.fingerprint?Array.isArray(e.fingerprint)?e.fingerprint:[e.fingerprint]:[],n&&(e.fingerprint=e.fingerprint.concat(n)),e.fingerprint&&!e.fingerprint.length&&delete e.fingerprint,function(e,t){let n=[...e.breadcrumbs||[],...t];e.breadcrumbs=n.length?n:void 0}(e,i),e.sdkProcessingMetadata={...e.sdkProcessingMetadata,...o}}(R,I),(function e(t,n,r,i=0){return new d.cW((o,s)=>{let a=t[i];if(null===n||"function"!=typeof a)o(n);else{let d=a({...n},r);c.X&&a.id&&null===d&&u.kg.log(`Event processor "${a.id}" dropped event`),(0,l.J8)(d)?d.then(n=>e(t,n,r,i+1).then(o)).then(null,s):e(t,d,r,i+1).then(o).then(null,s)}})})([...N,...I.eventProcessors],R,n).then(e=>(e&&function(e){let t={};try{e.exception.values.forEach(e=>{e.stacktrace.frames.forEach(e=>{e.debug_id&&(e.abs_path?t[e.abs_path]=e.debug_id:e.filename&&(t[e.filename]=e.debug_id),delete e.debug_id)})})}catch(e){}if(0===Object.keys(t).length)return;e.debug_meta=e.debug_meta||{},e.debug_meta.images=e.debug_meta.images||[];let n=e.debug_meta.images;Object.entries(t).forEach(([e,t])=>{n.push({type:"sourcemap",code_file:e,debug_id:t})})}(e),"number"==typeof O&&O>0)?function(e,t,n){if(!e)return null;let r={...e,...e.breadcrumbs&&{breadcrumbs:e.breadcrumbs.map(e=>({...e,...e.data&&{data:(0,m.Fv)(e.data,t,n)}}))},...e.user&&{user:(0,m.Fv)(e.user,t,n)},...e.contexts&&{contexts:(0,m.Fv)(e.contexts,t,n)},...e.extra&&{extra:(0,m.Fv)(e.extra,t,n)}};return e.contexts&&e.contexts.trace&&r.contexts&&(r.contexts.trace=e.contexts.trace,e.contexts.trace.data&&(r.contexts.trace.data=(0,m.Fv)(e.contexts.trace.data,t,n))),e.spans&&(r.spans=e.spans.map(e=>({...e,...e.data&&{data:(0,m.Fv)(e.data,t,n)}}))),e.contexts&&e.contexts.flags&&r.contexts&&(r.contexts.flags=(0,m.Fv)(e.contexts.flags,3,n)),r}(e,O,C):e)}function O(e){return e?e instanceof h.s||"function"==typeof e||Object.keys(e).some(e=>C.includes(e))?{captureContext:e}:e:void 0}let C=["user","level","extra","contexts","tags","fingerprint","requestSession","propagationContext"]},39960:function(e,t,n){"use strict";n.d(t,{D:function(){return o},Y:function(){return s}});var r=n(98802);let i="_sentrySpan";function o(e,t){t?(0,r.xp)(e,i,t):delete e[i]}function s(e){return e[i]}},1543:function(e,t,n){"use strict";n.d(t,{$k:function(){return b},Dp:function(){return N},Gx:function(){return I},HN:function(){return x},HR:function(){return y},Hb:function(){return E},R6:function(){return D},Tt:function(){return w},XU:function(){return T},_4:function(){return O},ed:function(){return k},i0:function(){return g},j5:function(){return A},ve:function(){return m},wy:function(){return v}});var r=n(46926),i=n(53290),o=n(6411),s=n(94637),a=n(95503),c=n(18225),l=n(15196),u=n(98802),d=n(42370),h=n(4134),f=n(54310),p=n(39960);let m=0,g=1,_=!1;function y(e){let{spanId:t,traceId:n}=e.spanContext(),{data:r,op:i,parent_span_id:o,status:s,origin:a}=T(e);return(0,u.Jr)({parent_span_id:o,span_id:t,trace_id:n,data:r,op:i,status:s,origin:a})}function v(e){let{spanId:t,traceId:n,isRemote:r}=e.spanContext(),i=r?t:T(e).parent_span_id,o=r?(0,d.M)():t;return(0,u.Jr)({parent_span_id:i,span_id:o,trace_id:n})}function E(e){let{traceId:t,spanId:n}=e.spanContext(),r=w(e);return(0,f.$p)(t,n,r)}function b(e){return"number"==typeof e?S(e):Array.isArray(e)?e[0]+e[1]/1e9:e instanceof Date?S(e.getTime()):(0,h.ph)()}function S(e){return e>9999999999?e/1e3:e}function T(e){if("function"==typeof e.getSpanJSON)return e.getSpanJSON();try{let{spanId:t,traceId:n}=e.spanContext();if(e.attributes&&e.startTime&&e.name&&e.endTime&&e.status){let{attributes:r,startTime:i,name:o,endTime:c,parentSpanId:l,status:d}=e;return(0,u.Jr)({span_id:t,trace_id:n,data:r,description:o,parent_span_id:l,start_timestamp:b(i),timestamp:b(c)||void 0,status:O(d),op:r[a.$J],origin:r[a.S3],_metrics_summary:(0,s.y)(e)})}return{span_id:t,trace_id:n}}catch(e){return{}}}function w(e){let{traceFlags:t}=e.spanContext();return t===g}function O(e){return e&&e.code!==c.pq?e.code===c.OP?"ok":e.message||"unknown_error":void 0}let C="_sentryChildSpans",R="_sentryRootSpan";function A(e,t){let n=e[R]||e;(0,u.xp)(t,R,n),e[C]?e[C].add(t):(0,u.xp)(e,C,new Set([t]))}function k(e,t){e[C]&&e[C].delete(t)}function N(e){let t=new Set;return function e(n){if(!t.has(n)&&w(n))for(let r of(t.add(n),n[C]?Array.from(n[C]):[]))e(r)}(e),Array.from(t)}function I(e){return e[R]||e}function x(){let e=(0,i.c)(),t=(0,r.G)(e);return t.getActiveSpan?t.getActiveSpan():(0,p.Y)((0,o.nZ)())}function D(){_||((0,l.Cf)(()=>{console.warn("[Sentry] Deprecation warning: Returning null from `beforeSendSpan` will be disallowed from SDK version 9.0.0 onwards. The callback will only support mutating spans. To drop certain spans, configure the respective integrations directly.")}),_=!0)}},26811:function(e,t,n){"use strict";n.d(t,{X:function(){return r}});let r=!1},15767:function(e,t,n){"use strict";n.r(t),n.d(t,{__addDisposableResource:function(){return M},__assign:function(){return o},__asyncDelegator:function(){return O},__asyncGenerator:function(){return w},__asyncValues:function(){return C},__await:function(){return T},__awaiter:function(){return p},__classPrivateFieldGet:function(){return x},__classPrivateFieldIn:function(){return P},__classPrivateFieldSet:function(){return D},__createBinding:function(){return g},__decorate:function(){return a},__disposeResources:function(){return j},__esDecorate:function(){return l},__exportStar:function(){return _},__extends:function(){return i},__generator:function(){return m},__importDefault:function(){return I},__importStar:function(){return N},__makeTemplateObject:function(){return R},__metadata:function(){return f},__param:function(){return c},__propKey:function(){return d},__read:function(){return v},__rest:function(){return s},__rewriteRelativeImportExtension:function(){return U},__runInitializers:function(){return u},__setFunctionName:function(){return h},__spread:function(){return E},__spreadArray:function(){return S},__spreadArrays:function(){return b},__values:function(){return y}});var r=function(e,t){return(r=Object.setPrototypeOf||({__proto__:[]})instanceof Array&&function(e,t){e.__proto__=t}||function(e,t){for(var n in t)Object.prototype.hasOwnProperty.call(t,n)&&(e[n]=t[n])})(e,t)};function i(e,t){if("function"!=typeof t&&null!==t)throw TypeError("Class extends value "+String(t)+" is not a constructor or null");function n(){this.constructor=e}r(e,t),e.prototype=null===t?Object.create(t):(n.prototype=t.prototype,new n)}var o=function(){return(o=Object.assign||function(e){for(var t,n=1,r=arguments.length;nt.indexOf(r)&&(n[r]=e[r]);if(null!=e&&"function"==typeof Object.getOwnPropertySymbols)for(var i=0,r=Object.getOwnPropertySymbols(e);it.indexOf(r[i])&&Object.prototype.propertyIsEnumerable.call(e,r[i])&&(n[r[i]]=e[r[i]]);return n}function a(e,t,n,r){var i,o=arguments.length,s=o<3?t:null===r?r=Object.getOwnPropertyDescriptor(t,n):r;if("object"==typeof Reflect&&"function"==typeof Reflect.decorate)s=Reflect.decorate(e,t,n,r);else for(var a=e.length-1;a>=0;a--)(i=e[a])&&(s=(o<3?i(s):o>3?i(t,n,s):i(t,n))||s);return o>3&&s&&Object.defineProperty(t,n,s),s}function c(e,t){return function(n,r){t(n,r,e)}}function l(e,t,n,r,i,o){function s(e){if(void 0!==e&&"function"!=typeof e)throw TypeError("Function expected");return e}for(var a,c=r.kind,l="getter"===c?"get":"setter"===c?"set":"value",u=!t&&e?r.static?e:e.prototype:null,d=t||(u?Object.getOwnPropertyDescriptor(u,r.name):{}),h=!1,f=n.length-1;f>=0;f--){var p={};for(var m in r)p[m]="access"===m?{}:r[m];for(var m in r.access)p.access[m]=r.access[m];p.addInitializer=function(e){if(h)throw TypeError("Cannot add initializers after decoration has completed");o.push(s(e||null))};var g=(0,n[f])("accessor"===c?{get:d.get,set:d.set}:d[l],p);if("accessor"===c){if(void 0===g)continue;if(null===g||"object"!=typeof g)throw TypeError("Object expected");(a=s(g.get))&&(d.get=a),(a=s(g.set))&&(d.set=a),(a=s(g.init))&&i.unshift(a)}else(a=s(g))&&("field"===c?i.unshift(a):d[l]=a)}u&&Object.defineProperty(u,r.name,d),h=!0}function u(e,t,n){for(var r=arguments.length>2,i=0;i0&&i[i.length-1])&&(6===a[0]||2===a[0])){o=0;continue}if(3===a[0]&&(!i||a[1]>i[0]&&a[1]=e.length&&(e=void 0),{value:e&&e[r++],done:!e}}};throw TypeError(t?"Object is not iterable.":"Symbol.iterator is not defined.")}function v(e,t){var n="function"==typeof Symbol&&e[Symbol.iterator];if(!n)return e;var r,i,o=n.call(e),s=[];try{for(;(void 0===t||t-- >0)&&!(r=o.next()).done;)s.push(r.value)}catch(e){i={error:e}}finally{try{r&&!r.done&&(n=o.return)&&n.call(o)}finally{if(i)throw i.error}}return s}function E(){for(var e=[],t=0;t1||a(e,t)})},t&&(r[e]=t(r[e])))}function a(e,t){try{var n;(n=i[e](t)).value instanceof T?Promise.resolve(n.value.v).then(c,l):u(o[0][2],n)}catch(e){u(o[0][3],e)}}function c(e){a("next",e)}function l(e){a("throw",e)}function u(e,t){e(t),o.shift(),o.length&&a(o[0][0],o[0][1])}}function O(e){var t,n;return t={},r("next"),r("throw",function(e){throw e}),r("return"),t[Symbol.iterator]=function(){return this},t;function r(r,i){t[r]=e[r]?function(t){return(n=!n)?{value:T(e[r](t)),done:!1}:i?i(t):t}:i}}function C(e){if(!Symbol.asyncIterator)throw TypeError("Symbol.asyncIterator is not defined.");var t,n=e[Symbol.asyncIterator];return n?n.call(e):(e=y(e),t={},r("next"),r("throw"),r("return"),t[Symbol.asyncIterator]=function(){return this},t);function r(n){t[n]=e[n]&&function(t){return new Promise(function(r,i){(function(e,t,n,r){Promise.resolve(r).then(function(t){e({value:t,done:n})},t)})(r,i,(t=e[n](t)).done,t.value)})}}}function R(e,t){return Object.defineProperty?Object.defineProperty(e,"raw",{value:t}):e.raw=t,e}var A=Object.create?function(e,t){Object.defineProperty(e,"default",{enumerable:!0,value:t})}:function(e,t){e.default=t},k=function(e){return(k=Object.getOwnPropertyNames||function(e){var t=[];for(var n in e)Object.prototype.hasOwnProperty.call(e,n)&&(t[t.length]=n);return t})(e)};function N(e){if(e&&e.__esModule)return e;var t={};if(null!=e)for(var n=k(e),r=0;r