var JF=Object.defineProperty;var ZF=(mt,mn,Xs)=>mn in mt?JF(mt,mn,{enumerable:!0,configurable:!0,writable:!0,value:Xs}):mt[mn]=Xs;var Ft=(mt,mn,Xs)=>ZF(mt,typeof mn!="symbol"?mn+"":mn,Xs);try{let mt=typeof window<"u"?window:typeof global<"u"?global:typeof globalThis<"u"?globalThis:typeof self<"u"?self:{},mn=new mt.Error().stack;mn&&(mt._sentryDebugIds=mt._sentryDebugIds||{},mt._sentryDebugIds[mn]="6631c43d-d93f-448a-b99c-d56e52d236d5",mt._sentryDebugIdIdentifier="sentry-dbid-6631c43d-d93f-448a-b99c-d56e52d236d5")}catch{}(function(){"use strict";{let e=typeof window<"u"?window:typeof global<"u"?global:typeof globalThis<"u"?globalThis:typeof self<"u"?self:{};e.SENTRY_RELEASE={id:"df57a938a6f009206afdb0eff8d432343148c0da"}}const mt={mounted:"edmap-root-mounted",unmounted:"edmap-root-unmounted"};class mn extends HTMLElement{constructor(){super()}connectedCallback(){window.dispatchEvent(new CustomEvent(mt.mounted)),console.log(mt.mounted)}disconnectedCallback(){window.dispatchEvent(new CustomEvent(mt.unmounted)),console.log(mt.unmounted)}}customElements.get("edmap-view-root")||customElements.define("edmap-view-root",mn);function Xs(e){return e&&e.__esModule&&Object.prototype.hasOwnProperty.call(e,"default")?e.default:e}var Eu={exports:{}},oi={},xu={exports:{}},be={};/**
 * @license React
 * react.production.min.js
 *
 * Copyright (c) Facebook, Inc. and its affiliates.
 *
 * This source code is licensed under the MIT license found in the
 * LICENSE file in the root directory of this source tree.
 */var Hh;function zE(){if(Hh)return be;Hh=1;var e=Symbol.for("react.element"),t=Symbol.for("react.portal"),n=Symbol.for("react.fragment"),r=Symbol.for("react.strict_mode"),i=Symbol.for("react.profiler"),a=Symbol.for("react.provider"),c=Symbol.for("react.context"),d=Symbol.for("react.forward_ref"),f=Symbol.for("react.suspense"),h=Symbol.for("react.memo"),y=Symbol.for("react.lazy"),g=Symbol.iterator;function w(A){return A===null||typeof A!="object"?null:(A=g&&A[g]||A["@@iterator"],typeof A=="function"?A:null)}var x={isMounted:function(){return!1},enqueueForceUpdate:function(){},enqueueReplaceState:function(){},enqueueSetState:function(){}},_=Object.assign,E={};function k(A,q,ve){this.props=A,this.context=q,this.refs=E,this.updater=ve||x}k.prototype.isReactComponent={},k.prototype.setState=function(A,q){if(typeof A!="object"&&typeof A!="function"&&A!=null)throw Error("setState(...): takes an object of state variables to update or a function which returns an object of state variables.");this.updater.enqueueSetState(this,A,q,"setState")},k.prototype.forceUpdate=function(A){this.updater.enqueueForceUpdate(this,A,"forceUpdate")};function O(){}O.prototype=k.prototype;function R(A,q,ve){this.props=A,this.context=q,this.refs=E,this.updater=ve||x}var $=R.prototype=new O;$.constructor=R,_($,k.prototype),$.isPureReactComponent=!0;var H=Array.isArray,z=Object.prototype.hasOwnProperty,M={current:null},L={key:!0,ref:!0,__self:!0,__source:!0};function U(A,q,ve){var we,Oe={},Pe=null,ze=null;if(q!=null)for(we in q.ref!==void 0&&(ze=q.ref),q.key!==void 0&&(Pe=""+q.key),q)z.call(q,we)&&!L.hasOwnProperty(we)&&(Oe[we]=q[we]);var De=arguments.length-2;if(De===1)Oe.children=ve;else if(1<De){for(var qe=Array(De),wt=0;wt<De;wt++)qe[wt]=arguments[wt+2];Oe.children=qe}if(A&&A.defaultProps)for(we in De=A.defaultProps,De)Oe[we]===void 0&&(Oe[we]=De[we]);return{$$typeof:e,type:A,key:Pe,ref:ze,props:Oe,_owner:M.current}}function te(A,q){return{$$typeof:e,type:A.type,key:q,ref:A.ref,props:A.props,_owner:A._owner}}function K(A){return typeof A=="object"&&A!==null&&A.$$typeof===e}function oe(A){var q={"=":"=0",":":"=2"};return"$"+A.replace(/[=:]/g,function(ve){return q[ve]})}var ae=/\/+/g;function ye(A,q){return typeof A=="object"&&A!==null&&A.key!=null?oe(""+A.key):q.toString(36)}function Ie(A,q,ve,we,Oe){var Pe=typeof A;(Pe==="undefined"||Pe==="boolean")&&(A=null);var ze=!1;if(A===null)ze=!0;else switch(Pe){case"string":case"number":ze=!0;break;case"object":switch(A.$$typeof){case e:case t:ze=!0}}if(ze)return ze=A,Oe=Oe(ze),A=we===""?"."+ye(ze,0):we,H(Oe)?(ve="",A!=null&&(ve=A.replace(ae,"$&/")+"/"),Ie(Oe,q,ve,"",function(wt){return wt})):Oe!=null&&(K(Oe)&&(Oe=te(Oe,ve+(!Oe.key||ze&&ze.key===Oe.key?"":(""+Oe.key).replace(ae,"$&/")+"/")+A)),q.push(Oe)),1;if(ze=0,we=we===""?".":we+":",H(A))for(var De=0;De<A.length;De++){Pe=A[De];var qe=we+ye(Pe,De);ze+=Ie(Pe,q,ve,qe,Oe)}else if(qe=w(A),typeof qe=="function")for(A=qe.call(A),De=0;!(Pe=A.next()).done;)Pe=Pe.value,qe=we+ye(Pe,De++),ze+=Ie(Pe,q,ve,qe,Oe);else if(Pe==="object")throw q=String(A),Error("Objects are not valid as a React child (found: "+(q==="[object Object]"?"object with keys {"+Object.keys(A).join(", ")+"}":q)+"). If you meant to render a collection of children, use an array instead.");return ze}function We(A,q,ve){if(A==null)return A;var we=[],Oe=0;return Ie(A,we,"","",function(Pe){return q.call(ve,Pe,Oe++)}),we}function ce(A){if(A._status===-1){var q=A._result;q=q(),q.then(function(ve){(A._status===0||A._status===-1)&&(A._status=1,A._result=ve)},function(ve){(A._status===0||A._status===-1)&&(A._status=2,A._result=ve)}),A._status===-1&&(A._status=0,A._result=q)}if(A._status===1)return A._result.default;throw A._result}var ke={current:null},W={transition:null},re={ReactCurrentDispatcher:ke,ReactCurrentBatchConfig:W,ReactCurrentOwner:M};function J(){throw Error("act(...) is not supported in production builds of React.")}return be.Children={map:We,forEach:function(A,q,ve){We(A,function(){q.apply(this,arguments)},ve)},count:function(A){var q=0;return We(A,function(){q++}),q},toArray:function(A){return We(A,function(q){return q})||[]},only:function(A){if(!K(A))throw Error("React.Children.only expected to receive a single React element child.");return A}},be.Component=k,be.Fragment=n,be.Profiler=i,be.PureComponent=R,be.StrictMode=r,be.Suspense=f,be.__SECRET_INTERNALS_DO_NOT_USE_OR_YOU_WILL_BE_FIRED=re,be.act=J,be.cloneElement=function(A,q,ve){if(A==null)throw Error("React.cloneElement(...): The argument must be a React element, but you passed "+A+".");var we=_({},A.props),Oe=A.key,Pe=A.ref,ze=A._owner;if(q!=null){if(q.ref!==void 0&&(Pe=q.ref,ze=M.current),q.key!==void 0&&(Oe=""+q.key),A.type&&A.type.defaultProps)var De=A.type.defaultProps;for(qe in q)z.call(q,qe)&&!L.hasOwnProperty(qe)&&(we[qe]=q[qe]===void 0&&De!==void 0?De[qe]:q[qe])}var qe=arguments.length-2;if(qe===1)we.children=ve;else if(1<qe){De=Array(qe);for(var wt=0;wt<qe;wt++)De[wt]=arguments[wt+2];we.children=De}return{$$typeof:e,type:A.type,key:Oe,ref:Pe,props:we,_owner:ze}},be.createContext=function(A){return A={$$typeof:c,_currentValue:A,_currentValue2:A,_threadCount:0,Provider:null,Consumer:null,_defaultValue:null,_globalName:null},A.Provider={$$typeof:a,_context:A},A.Consumer=A},be.createElement=U,be.createFactory=function(A){var q=U.bind(null,A);return q.type=A,q},be.createRef=function(){return{current:null}},be.forwardRef=function(A){return{$$typeof:d,render:A}},be.isValidElement=K,be.lazy=function(A){return{$$typeof:y,_payload:{_status:-1,_result:A},_init:ce}},be.memo=function(A,q){return{$$typeof:h,type:A,compare:q===void 0?null:q}},be.startTransition=function(A){var q=W.transition;W.transition={};try{A()}finally{W.transition=q}},be.unstable_act=J,be.useCallback=function(A,q){return ke.current.useCallback(A,q)},be.useContext=function(A){return ke.current.useContext(A)},be.useDebugValue=function(){},be.useDeferredValue=function(A){return ke.current.useDeferredValue(A)},be.useEffect=function(A,q){return ke.current.useEffect(A,q)},be.useId=function(){return ke.current.useId()},be.useImperativeHandle=function(A,q,ve){return ke.current.useImperativeHandle(A,q,ve)},be.useInsertionEffect=function(A,q){return ke.current.useInsertionEffect(A,q)},be.useLayoutEffect=function(A,q){return ke.current.useLayoutEffect(A,q)},be.useMemo=function(A,q){return ke.current.useMemo(A,q)},be.useReducer=function(A,q,ve){return ke.current.useReducer(A,q,ve)},be.useRef=function(A){return ke.current.useRef(A)},be.useState=function(A){return ke.current.useState(A)},be.useSyncExternalStore=function(A,q,ve){return ke.current.useSyncExternalStore(A,q,ve)},be.useTransition=function(){return ke.current.useTransition()},be.version="18.3.1",be}var Wh;function ku(){return Wh||(Wh=1,xu.exports=zE()),xu.exports}/**
 * @license React
 * react-jsx-runtime.production.min.js
 *
 * Copyright (c) Facebook, Inc. and its affiliates.
 *
 * This source code is licensed under the MIT license found in the
 * LICENSE file in the root directory of this source tree.
 */var qh;function UE(){if(qh)return oi;qh=1;var e=ku(),t=Symbol.for("react.element"),n=Symbol.for("react.fragment"),r=Object.prototype.hasOwnProperty,i=e.__SECRET_INTERNALS_DO_NOT_USE_OR_YOU_WILL_BE_FIRED.ReactCurrentOwner,a={key:!0,ref:!0,__self:!0,__source:!0};function c(d,f,h){var y,g={},w=null,x=null;h!==void 0&&(w=""+h),f.key!==void 0&&(w=""+f.key),f.ref!==void 0&&(x=f.ref);for(y in f)r.call(f,y)&&!a.hasOwnProperty(y)&&(g[y]=f[y]);if(d&&d.defaultProps)for(y in f=d.defaultProps,f)g[y]===void 0&&(g[y]=f[y]);return{$$typeof:t,type:d,key:w,ref:x,props:g,_owner:i.current}}return oi.Fragment=n,oi.jsx=c,oi.jsxs=c,oi}var Vh;function HE(){return Vh||(Vh=1,Eu.exports=UE()),Eu.exports}var v=HE(),C=ku();const Tt=Xs(C);var Ca={},Tu={exports:{}},Vt={},bu={exports:{}},Iu={};/**
 * @license React
 * scheduler.production.min.js
 *
 * Copyright (c) Facebook, Inc. and its affiliates.
 *
 * This source code is licensed under the MIT license found in the
 * LICENSE file in the root directory of this source tree.
 */var Gh;function WE(){return Gh||(Gh=1,function(e){function t(W,re){var J=W.length;W.push(re);e:for(;0<J;){var A=J-1>>>1,q=W[A];if(0<i(q,re))W[A]=re,W[J]=q,J=A;else break e}}function n(W){return W.length===0?null:W[0]}function r(W){if(W.length===0)return null;var re=W[0],J=W.pop();if(J!==re){W[0]=J;e:for(var A=0,q=W.length,ve=q>>>1;A<ve;){var we=2*(A+1)-1,Oe=W[we],Pe=we+1,ze=W[Pe];if(0>i(Oe,J))Pe<q&&0>i(ze,Oe)?(W[A]=ze,W[Pe]=J,A=Pe):(W[A]=Oe,W[we]=J,A=we);else if(Pe<q&&0>i(ze,J))W[A]=ze,W[Pe]=J,A=Pe;else break e}}return re}function i(W,re){var J=W.sortIndex-re.sortIndex;return J!==0?J:W.id-re.id}if(typeof performance=="object"&&typeof performance.now=="function"){var a=performance;e.unstable_now=function(){return a.now()}}else{var c=Date,d=c.now();e.unstable_now=function(){return c.now()-d}}var f=[],h=[],y=1,g=null,w=3,x=!1,_=!1,E=!1,k=typeof setTimeout=="function"?setTimeout:null,O=typeof clearTimeout=="function"?clearTimeout:null,R=typeof setImmediate<"u"?setImmediate:null;typeof navigator<"u"&&navigator.scheduling!==void 0&&navigator.scheduling.isInputPending!==void 0&&navigator.scheduling.isInputPending.bind(navigator.scheduling);function $(W){for(var re=n(h);re!==null;){if(re.callback===null)r(h);else if(re.startTime<=W)r(h),re.sortIndex=re.expirationTime,t(f,re);else break;re=n(h)}}function H(W){if(E=!1,$(W),!_)if(n(f)!==null)_=!0,ce(z);else{var re=n(h);re!==null&&ke(H,re.startTime-W)}}function z(W,re){_=!1,E&&(E=!1,O(U),U=-1),x=!0;var J=w;try{for($(re),g=n(f);g!==null&&(!(g.expirationTime>re)||W&&!oe());){var A=g.callback;if(typeof A=="function"){g.callback=null,w=g.priorityLevel;var q=A(g.expirationTime<=re);re=e.unstable_now(),typeof q=="function"?g.callback=q:g===n(f)&&r(f),$(re)}else r(f);g=n(f)}if(g!==null)var ve=!0;else{var we=n(h);we!==null&&ke(H,we.startTime-re),ve=!1}return ve}finally{g=null,w=J,x=!1}}var M=!1,L=null,U=-1,te=5,K=-1;function oe(){return!(e.unstable_now()-K<te)}function ae(){if(L!==null){var W=e.unstable_now();K=W;var re=!0;try{re=L(!0,W)}finally{re?ye():(M=!1,L=null)}}else M=!1}var ye;if(typeof R=="function")ye=function(){R(ae)};else if(typeof MessageChannel<"u"){var Ie=new MessageChannel,We=Ie.port2;Ie.port1.onmessage=ae,ye=function(){We.postMessage(null)}}else ye=function(){k(ae,0)};function ce(W){L=W,M||(M=!0,ye())}function ke(W,re){U=k(function(){W(e.unstable_now())},re)}e.unstable_IdlePriority=5,e.unstable_ImmediatePriority=1,e.unstable_LowPriority=4,e.unstable_NormalPriority=3,e.unstable_Profiling=null,e.unstable_UserBlockingPriority=2,e.unstable_cancelCallback=function(W){W.callback=null},e.unstable_continueExecution=function(){_||x||(_=!0,ce(z))},e.unstable_forceFrameRate=function(W){0>W||125<W?console.error("forceFrameRate takes a positive int between 0 and 125, forcing frame rates higher than 125 fps is not supported"):te=0<W?Math.floor(1e3/W):5},e.unstable_getCurrentPriorityLevel=function(){return w},e.unstable_getFirstCallbackNode=function(){return n(f)},e.unstable_next=function(W){switch(w){case 1:case 2:case 3:var re=3;break;default:re=w}var J=w;w=re;try{return W()}finally{w=J}},e.unstable_pauseExecution=function(){},e.unstable_requestPaint=function(){},e.unstable_runWithPriority=function(W,re){switch(W){case 1:case 2:case 3:case 4:case 5:break;default:W=3}var J=w;w=W;try{return re()}finally{w=J}},e.unstable_scheduleCallback=function(W,re,J){var A=e.unstable_now();switch(typeof J=="object"&&J!==null?(J=J.delay,J=typeof J=="number"&&0<J?A+J:A):J=A,W){case 1:var q=-1;break;case 2:q=250;break;case 5:q=1073741823;break;case 4:q=1e4;break;default:q=5e3}return q=J+q,W={id:y++,callback:re,priorityLevel:W,startTime:J,expirationTime:q,sortIndex:-1},J>A?(W.sortIndex=J,t(h,W),n(f)===null&&W===n(h)&&(E?(O(U),U=-1):E=!0,ke(H,J-A))):(W.sortIndex=q,t(f,W),_||x||(_=!0,ce(z))),W},e.unstable_shouldYield=oe,e.unstable_wrapCallback=function(W){var re=w;return function(){var J=w;w=re;try{return W.apply(this,arguments)}finally{w=J}}}}(Iu)),Iu}var Yh;function qE(){return Yh||(Yh=1,bu.exports=WE()),bu.exports}/**
 * @license React
 * react-dom.production.min.js
 *
 * Copyright (c) Facebook, Inc. and its affiliates.
 *
 * This source code is licensed under the MIT license found in the
 * LICENSE file in the root directory of this source tree.
 */var Kh;function VE(){if(Kh)return Vt;Kh=1;var e=ku(),t=qE();function n(s){for(var o="https://reactjs.org/docs/error-decoder.html?invariant="+s,l=1;l<arguments.length;l++)o+="&args[]="+encodeURIComponent(arguments[l]);return"Minified React error #"+s+"; visit "+o+" for the full message or use the non-minified dev environment for full errors and additional helpful warnings."}var r=new Set,i={};function a(s,o){c(s,o),c(s+"Capture",o)}function c(s,o){for(i[s]=o,s=0;s<o.length;s++)r.add(o[s])}var d=!(typeof window>"u"||typeof window.document>"u"||typeof window.document.createElement>"u"),f=Object.prototype.hasOwnProperty,h=/^[:A-Z_a-z\u00C0-\u00D6\u00D8-\u00F6\u00F8-\u02FF\u0370-\u037D\u037F-\u1FFF\u200C-\u200D\u2070-\u218F\u2C00-\u2FEF\u3001-\uD7FF\uF900-\uFDCF\uFDF0-\uFFFD][:A-Z_a-z\u00C0-\u00D6\u00D8-\u00F6\u00F8-\u02FF\u0370-\u037D\u037F-\u1FFF\u200C-\u200D\u2070-\u218F\u2C00-\u2FEF\u3001-\uD7FF\uF900-\uFDCF\uFDF0-\uFFFD\-.0-9\u00B7\u0300-\u036F\u203F-\u2040]*$/,y={},g={};function w(s){return f.call(g,s)?!0:f.call(y,s)?!1:h.test(s)?g[s]=!0:(y[s]=!0,!1)}function x(s,o,l,u){if(l!==null&&l.type===0)return!1;switch(typeof o){case"function":case"symbol":return!0;case"boolean":return u?!1:l!==null?!l.acceptsBooleans:(s=s.toLowerCase().slice(0,5),s!=="data-"&&s!=="aria-");default:return!1}}function _(s,o,l,u){if(o===null||typeof o>"u"||x(s,o,l,u))return!0;if(u)return!1;if(l!==null)switch(l.type){case 3:return!o;case 4:return o===!1;case 5:return isNaN(o);case 6:return isNaN(o)||1>o}return!1}function E(s,o,l,u,p,m,S){this.acceptsBooleans=o===2||o===3||o===4,this.attributeName=u,this.attributeNamespace=p,this.mustUseProperty=l,this.propertyName=s,this.type=o,this.sanitizeURL=m,this.removeEmptyString=S}var k={};"children dangerouslySetInnerHTML defaultValue defaultChecked innerHTML suppressContentEditableWarning suppressHydrationWarning style".split(" ").forEach(function(s){k[s]=new E(s,0,!1,s,null,!1,!1)}),[["acceptCharset","accept-charset"],["className","class"],["htmlFor","for"],["httpEquiv","http-equiv"]].forEach(function(s){var o=s[0];k[o]=new E(o,1,!1,s[1],null,!1,!1)}),["contentEditable","draggable","spellCheck","value"].forEach(function(s){k[s]=new E(s,2,!1,s.toLowerCase(),null,!1,!1)}),["autoReverse","externalResourcesRequired","focusable","preserveAlpha"].forEach(function(s){k[s]=new E(s,2,!1,s,null,!1,!1)}),"allowFullScreen async autoFocus autoPlay controls default defer disabled disablePictureInPicture disableRemotePlayback formNoValidate hidden loop noModule noValidate open playsInline readOnly required reversed scoped seamless itemScope".split(" ").forEach(function(s){k[s]=new E(s,3,!1,s.toLowerCase(),null,!1,!1)}),["checked","multiple","muted","selected"].forEach(function(s){k[s]=new E(s,3,!0,s,null,!1,!1)}),["capture","download"].forEach(function(s){k[s]=new E(s,4,!1,s,null,!1,!1)}),["cols","rows","size","span"].forEach(function(s){k[s]=new E(s,6,!1,s,null,!1,!1)}),["rowSpan","start"].forEach(function(s){k[s]=new E(s,5,!1,s.toLowerCase(),null,!1,!1)});var O=/[\-:]([a-z])/g;function R(s){return s[1].toUpperCase()}"accent-height alignment-baseline arabic-form baseline-shift cap-height clip-path clip-rule color-interpolation color-interpolation-filters color-profile color-rendering dominant-baseline enable-background fill-opacity fill-rule flood-color flood-opacity font-family font-size font-size-adjust font-stretch font-style font-variant font-weight glyph-name glyph-orientation-horizontal glyph-orientation-vertical horiz-adv-x horiz-origin-x image-rendering letter-spacing lighting-color marker-end marker-mid marker-start overline-position overline-thickness paint-order panose-1 pointer-events rendering-intent shape-rendering stop-color stop-opacity strikethrough-position strikethrough-thickness stroke-dasharray stroke-dashoffset stroke-linecap stroke-linejoin stroke-miterlimit stroke-opacity stroke-width text-anchor text-decoration text-rendering underline-position underline-thickness unicode-bidi unicode-range units-per-em v-alphabetic v-hanging v-ideographic v-mathematical vector-effect vert-adv-y vert-origin-x vert-origin-y word-spacing writing-mode xmlns:xlink x-height".split(" ").forEach(function(s){var o=s.replace(O,R);k[o]=new E(o,1,!1,s,null,!1,!1)}),"xlink:actuate xlink:arcrole xlink:role xlink:show xlink:title xlink:type".split(" ").forEach(function(s){var o=s.replace(O,R);k[o]=new E(o,1,!1,s,"http://www.w3.org/1999/xlink",!1,!1)}),["xml:base","xml:lang","xml:space"].forEach(function(s){var o=s.replace(O,R);k[o]=new E(o,1,!1,s,"http://www.w3.org/XML/1998/namespace",!1,!1)}),["tabIndex","crossOrigin"].forEach(function(s){k[s]=new E(s,1,!1,s.toLowerCase(),null,!1,!1)}),k.xlinkHref=new E("xlinkHref",1,!1,"xlink:href","http://www.w3.org/1999/xlink",!0,!1),["src","href","action","formAction"].forEach(function(s){k[s]=new E(s,1,!1,s.toLowerCase(),null,!0,!0)});function $(s,o,l,u){var p=k.hasOwnProperty(o)?k[o]:null;(p!==null?p.type!==0:u||!(2<o.length)||o[0]!=="o"&&o[0]!=="O"||o[1]!=="n"&&o[1]!=="N")&&(_(o,l,p,u)&&(l=null),u||p===null?w(o)&&(l===null?s.removeAttribute(o):s.setAttribute(o,""+l)):p.mustUseProperty?s[p.propertyName]=l===null?p.type===3?!1:"":l:(o=p.attributeName,u=p.attributeNamespace,l===null?s.removeAttribute(o):(p=p.type,l=p===3||p===4&&l===!0?"":""+l,u?s.setAttributeNS(u,o,l):s.setAttribute(o,l))))}var H=e.__SECRET_INTERNALS_DO_NOT_USE_OR_YOU_WILL_BE_FIRED,z=Symbol.for("react.element"),M=Symbol.for("react.portal"),L=Symbol.for("react.fragment"),U=Symbol.for("react.strict_mode"),te=Symbol.for("react.profiler"),K=Symbol.for("react.provider"),oe=Symbol.for("react.context"),ae=Symbol.for("react.forward_ref"),ye=Symbol.for("react.suspense"),Ie=Symbol.for("react.suspense_list"),We=Symbol.for("react.memo"),ce=Symbol.for("react.lazy"),ke=Symbol.for("react.offscreen"),W=Symbol.iterator;function re(s){return s===null||typeof s!="object"?null:(s=W&&s[W]||s["@@iterator"],typeof s=="function"?s:null)}var J=Object.assign,A;function q(s){if(A===void 0)try{throw Error()}catch(l){var o=l.stack.trim().match(/\n( *(at )?)/);A=o&&o[1]||""}return`
`+A+s}var ve=!1;function we(s,o){if(!s||ve)return"";ve=!0;var l=Error.prepareStackTrace;Error.prepareStackTrace=void 0;try{if(o)if(o=function(){throw Error()},Object.defineProperty(o.prototype,"props",{set:function(){throw Error()}}),typeof Reflect=="object"&&Reflect.construct){try{Reflect.construct(o,[])}catch(D){var u=D}Reflect.construct(s,[],o)}else{try{o.call()}catch(D){u=D}s.call(o.prototype)}else{try{throw Error()}catch(D){u=D}s()}}catch(D){if(D&&u&&typeof D.stack=="string"){for(var p=D.stack.split(`
`),m=u.stack.split(`
`),S=p.length-1,T=m.length-1;1<=S&&0<=T&&p[S]!==m[T];)T--;for(;1<=S&&0<=T;S--,T--)if(p[S]!==m[T]){if(S!==1||T!==1)do if(S--,T--,0>T||p[S]!==m[T]){var b=`
`+p[S].replace(" at new "," at ");return s.displayName&&b.includes("<anonymous>")&&(b=b.replace("<anonymous>",s.displayName)),b}while(1<=S&&0<=T);break}}}finally{ve=!1,Error.prepareStackTrace=l}return(s=s?s.displayName||s.name:"")?q(s):""}function Oe(s){switch(s.tag){case 5:return q(s.type);case 16:return q("Lazy");case 13:return q("Suspense");case 19:return q("SuspenseList");case 0:case 2:case 15:return s=we(s.type,!1),s;case 11:return s=we(s.type.render,!1),s;case 1:return s=we(s.type,!0),s;default:return""}}function Pe(s){if(s==null)return null;if(typeof s=="function")return s.displayName||s.name||null;if(typeof s=="string")return s;switch(s){case L:return"Fragment";case M:return"Portal";case te:return"Profiler";case U:return"StrictMode";case ye:return"Suspense";case Ie:return"SuspenseList"}if(typeof s=="object")switch(s.$$typeof){case oe:return(s.displayName||"Context")+".Consumer";case K:return(s._context.displayName||"Context")+".Provider";case ae:var o=s.render;return s=s.displayName,s||(s=o.displayName||o.name||"",s=s!==""?"ForwardRef("+s+")":"ForwardRef"),s;case We:return o=s.displayName||null,o!==null?o:Pe(s.type)||"Memo";case ce:o=s._payload,s=s._init;try{return Pe(s(o))}catch{}}return null}function ze(s){var o=s.type;switch(s.tag){case 24:return"Cache";case 9:return(o.displayName||"Context")+".Consumer";case 10:return(o._context.displayName||"Context")+".Provider";case 18:return"DehydratedFragment";case 11:return s=o.render,s=s.displayName||s.name||"",o.displayName||(s!==""?"ForwardRef("+s+")":"ForwardRef");case 7:return"Fragment";case 5:return o;case 4:return"Portal";case 3:return"Root";case 6:return"Text";case 16:return Pe(o);case 8:return o===U?"StrictMode":"Mode";case 22:return"Offscreen";case 12:return"Profiler";case 21:return"Scope";case 13:return"Suspense";case 19:return"SuspenseList";case 25:return"TracingMarker";case 1:case 0:case 17:case 2:case 14:case 15:if(typeof o=="function")return o.displayName||o.name||null;if(typeof o=="string")return o}return null}function De(s){switch(typeof s){case"boolean":case"number":case"string":case"undefined":return s;case"object":return s;default:return""}}function qe(s){var o=s.type;return(s=s.nodeName)&&s.toLowerCase()==="input"&&(o==="checkbox"||o==="radio")}function wt(s){var o=qe(s)?"checked":"value",l=Object.getOwnPropertyDescriptor(s.constructor.prototype,o),u=""+s[o];if(!s.hasOwnProperty(o)&&typeof l<"u"&&typeof l.get=="function"&&typeof l.set=="function"){var p=l.get,m=l.set;return Object.defineProperty(s,o,{configurable:!0,get:function(){return p.call(this)},set:function(S){u=""+S,m.call(this,S)}}),Object.defineProperty(s,o,{enumerable:l.enumerable}),{getValue:function(){return u},setValue:function(S){u=""+S},stopTracking:function(){s._valueTracker=null,delete s[o]}}}}function Ms(s){s._valueTracker||(s._valueTracker=wt(s))}function fc(s){if(!s)return!1;var o=s._valueTracker;if(!o)return!0;var l=o.getValue(),u="";return s&&(u=qe(s)?s.checked?"true":"false":s.value),s=u,s!==l?(o.setValue(s),!0):!1}function No(s){if(s=s||(typeof document<"u"?document:void 0),typeof s>"u")return null;try{return s.activeElement||s.body}catch{return s.body}}function Mn(s,o){var l=o.checked;return J({},o,{defaultChecked:void 0,defaultValue:void 0,value:void 0,checked:l??s._wrapperState.initialChecked})}function Kn(s,o){var l=o.defaultValue==null?"":o.defaultValue,u=o.checked!=null?o.checked:o.defaultChecked;l=De(o.value!=null?o.value:l),s._wrapperState={initialChecked:u,initialValue:l,controlled:o.type==="checkbox"||o.type==="radio"?o.checked!=null:o.value!=null}}function Mo(s,o){o=o.checked,o!=null&&$(s,"checked",o,!1)}function Ls(s,o){Mo(s,o);var l=De(o.value),u=o.type;if(l!=null)u==="number"?(l===0&&s.value===""||s.value!=l)&&(s.value=""+l):s.value!==""+l&&(s.value=""+l);else if(u==="submit"||u==="reset"){s.removeAttribute("value");return}o.hasOwnProperty("value")?Ds(s,o.type,l):o.hasOwnProperty("defaultValue")&&Ds(s,o.type,De(o.defaultValue)),o.checked==null&&o.defaultChecked!=null&&(s.defaultChecked=!!o.defaultChecked)}function js(s,o,l){if(o.hasOwnProperty("value")||o.hasOwnProperty("defaultValue")){var u=o.type;if(!(u!=="submit"&&u!=="reset"||o.value!==void 0&&o.value!==null))return;o=""+s._wrapperState.initialValue,l||o===s.value||(s.value=o),s.defaultValue=o}l=s.name,l!==""&&(s.name=""),s.defaultChecked=!!s._wrapperState.initialChecked,l!==""&&(s.name=l)}function Ds(s,o,l){(o!=="number"||No(s.ownerDocument)!==s)&&(l==null?s.defaultValue=""+s._wrapperState.initialValue:s.defaultValue!==""+l&&(s.defaultValue=""+l))}var Re=Array.isArray;function _t(s,o,l,u){if(s=s.options,o){o={};for(var p=0;p<l.length;p++)o["$"+l[p]]=!0;for(l=0;l<s.length;l++)p=o.hasOwnProperty("$"+s[l].value),s[l].selected!==p&&(s[l].selected=p),p&&u&&(s[l].defaultSelected=!0)}else{for(l=""+De(l),o=null,p=0;p<s.length;p++){if(s[p].value===l){s[p].selected=!0,u&&(s[p].defaultSelected=!0);return}o!==null||s[p].disabled||(o=s[p])}o!==null&&(o.selected=!0)}}function Ce(s,o){if(o.dangerouslySetInnerHTML!=null)throw Error(n(91));return J({},o,{value:void 0,defaultValue:void 0,children:""+s._wrapperState.initialValue})}function Ke(s,o){var l=o.value;if(l==null){if(l=o.children,o=o.defaultValue,l!=null){if(o!=null)throw Error(n(92));if(Re(l)){if(1<l.length)throw Error(n(93));l=l[0]}o=l}o==null&&(o=""),l=o}s._wrapperState={initialValue:De(l)}}function je(s,o){var l=De(o.value),u=De(o.defaultValue);l!=null&&(l=""+l,l!==s.value&&(s.value=l),o.defaultValue==null&&s.defaultValue!==l&&(s.defaultValue=l)),u!=null&&(s.defaultValue=""+u)}function Qn(s){var o=s.textContent;o===s._wrapperState.initialValue&&o!==""&&o!==null&&(s.value=o)}function pc(s){switch(s){case"svg":return"http://www.w3.org/2000/svg";case"math":return"http://www.w3.org/1998/Math/MathML";default:return"http://www.w3.org/1999/xhtml"}}function ep(s,o){return s==null||s==="http://www.w3.org/1999/xhtml"?pc(o):s==="http://www.w3.org/2000/svg"&&o==="foreignObject"?"http://www.w3.org/1999/xhtml":s}var hc,ew=function(s){return typeof MSApp<"u"&&MSApp.execUnsafeLocalFunction?function(o,l,u,p){MSApp.execUnsafeLocalFunction(function(){return s(o,l,u,p)})}:s}(function(s,o){if(s.namespaceURI!=="http://www.w3.org/2000/svg"||"innerHTML"in s)s.innerHTML=o;else{for(hc=hc||document.createElement("div"),hc.innerHTML="<svg>"+o.valueOf().toString()+"</svg>",o=hc.firstChild;s.firstChild;)s.removeChild(s.firstChild);for(;o.firstChild;)s.appendChild(o.firstChild)}});function Wi(s,o){if(o){var l=s.firstChild;if(l&&l===s.lastChild&&l.nodeType===3){l.nodeValue=o;return}}s.textContent=o}var qi={animationIterationCount:!0,aspectRatio:!0,borderImageOutset:!0,borderImageSlice:!0,borderImageWidth:!0,boxFlex:!0,boxFlexGroup:!0,boxOrdinalGroup:!0,columnCount:!0,columns:!0,flex:!0,flexGrow:!0,flexPositive:!0,flexShrink:!0,flexNegative:!0,flexOrder:!0,gridArea:!0,gridRow:!0,gridRowEnd:!0,gridRowSpan:!0,gridRowStart:!0,gridColumn:!0,gridColumnEnd:!0,gridColumnSpan:!0,gridColumnStart:!0,fontWeight:!0,lineClamp:!0,lineHeight:!0,opacity:!0,order:!0,orphans:!0,tabSize:!0,widows:!0,zIndex:!0,zoom:!0,fillOpacity:!0,floodOpacity:!0,stopOpacity:!0,strokeDasharray:!0,strokeDashoffset:!0,strokeMiterlimit:!0,strokeOpacity:!0,strokeWidth:!0},n8=["Webkit","ms","Moz","O"];Object.keys(qi).forEach(function(s){n8.forEach(function(o){o=o+s.charAt(0).toUpperCase()+s.substring(1),qi[o]=qi[s]})});function tw(s,o,l){return o==null||typeof o=="boolean"||o===""?"":l||typeof o!="number"||o===0||qi.hasOwnProperty(s)&&qi[s]?(""+o).trim():o+"px"}function nw(s,o){s=s.style;for(var l in o)if(o.hasOwnProperty(l)){var u=l.indexOf("--")===0,p=tw(l,o[l],u);l==="float"&&(l="cssFloat"),u?s.setProperty(l,p):s[l]=p}}var r8=J({menuitem:!0},{area:!0,base:!0,br:!0,col:!0,embed:!0,hr:!0,img:!0,input:!0,keygen:!0,link:!0,meta:!0,param:!0,source:!0,track:!0,wbr:!0});function tp(s,o){if(o){if(r8[s]&&(o.children!=null||o.dangerouslySetInnerHTML!=null))throw Error(n(137,s));if(o.dangerouslySetInnerHTML!=null){if(o.children!=null)throw Error(n(60));if(typeof o.dangerouslySetInnerHTML!="object"||!("__html"in o.dangerouslySetInnerHTML))throw Error(n(61))}if(o.style!=null&&typeof o.style!="object")throw Error(n(62))}}function np(s,o){if(s.indexOf("-")===-1)return typeof o.is=="string";switch(s){case"annotation-xml":case"color-profile":case"font-face":case"font-face-src":case"font-face-uri":case"font-face-format":case"font-face-name":case"missing-glyph":return!1;default:return!0}}var rp=null;function sp(s){return s=s.target||s.srcElement||window,s.correspondingUseElement&&(s=s.correspondingUseElement),s.nodeType===3?s.parentNode:s}var op=null,Lo=null,jo=null;function rw(s){if(s=pa(s)){if(typeof op!="function")throw Error(n(280));var o=s.stateNode;o&&(o=Dc(o),op(s.stateNode,s.type,o))}}function sw(s){Lo?jo?jo.push(s):jo=[s]:Lo=s}function ow(){if(Lo){var s=Lo,o=jo;if(jo=Lo=null,rw(s),o)for(s=0;s<o.length;s++)rw(o[s])}}function iw(s,o){return s(o)}function aw(){}var ip=!1;function lw(s,o,l){if(ip)return s(o,l);ip=!0;try{return iw(s,o,l)}finally{ip=!1,(Lo!==null||jo!==null)&&(aw(),ow())}}function Vi(s,o){var l=s.stateNode;if(l===null)return null;var u=Dc(l);if(u===null)return null;l=u[o];e:switch(o){case"onClick":case"onClickCapture":case"onDoubleClick":case"onDoubleClickCapture":case"onMouseDown":case"onMouseDownCapture":case"onMouseMove":case"onMouseMoveCapture":case"onMouseUp":case"onMouseUpCapture":case"onMouseEnter":(u=!u.disabled)||(s=s.type,u=!(s==="button"||s==="input"||s==="select"||s==="textarea")),s=!u;break e;default:s=!1}if(s)return null;if(l&&typeof l!="function")throw Error(n(231,o,typeof l));return l}var ap=!1;if(d)try{var Gi={};Object.defineProperty(Gi,"passive",{get:function(){ap=!0}}),window.addEventListener("test",Gi,Gi),window.removeEventListener("test",Gi,Gi)}catch{ap=!1}function s8(s,o,l,u,p,m,S,T,b){var D=Array.prototype.slice.call(arguments,3);try{o.apply(l,D)}catch(G){this.onError(G)}}var Yi=!1,mc=null,gc=!1,lp=null,o8={onError:function(s){Yi=!0,mc=s}};function i8(s,o,l,u,p,m,S,T,b){Yi=!1,mc=null,s8.apply(o8,arguments)}function a8(s,o,l,u,p,m,S,T,b){if(i8.apply(this,arguments),Yi){if(Yi){var D=mc;Yi=!1,mc=null}else throw Error(n(198));gc||(gc=!0,lp=D)}}function $s(s){var o=s,l=s;if(s.alternate)for(;o.return;)o=o.return;else{s=o;do o=s,o.flags&4098&&(l=o.return),s=o.return;while(s)}return o.tag===3?l:null}function cw(s){if(s.tag===13){var o=s.memoizedState;if(o===null&&(s=s.alternate,s!==null&&(o=s.memoizedState)),o!==null)return o.dehydrated}return null}function uw(s){if($s(s)!==s)throw Error(n(188))}function l8(s){var o=s.alternate;if(!o){if(o=$s(s),o===null)throw Error(n(188));return o!==s?null:s}for(var l=s,u=o;;){var p=l.return;if(p===null)break;var m=p.alternate;if(m===null){if(u=p.return,u!==null){l=u;continue}break}if(p.child===m.child){for(m=p.child;m;){if(m===l)return uw(p),s;if(m===u)return uw(p),o;m=m.sibling}throw Error(n(188))}if(l.return!==u.return)l=p,u=m;else{for(var S=!1,T=p.child;T;){if(T===l){S=!0,l=p,u=m;break}if(T===u){S=!0,u=p,l=m;break}T=T.sibling}if(!S){for(T=m.child;T;){if(T===l){S=!0,l=m,u=p;break}if(T===u){S=!0,u=m,l=p;break}T=T.sibling}if(!S)throw Error(n(189))}}if(l.alternate!==u)throw Error(n(190))}if(l.tag!==3)throw Error(n(188));return l.stateNode.current===l?s:o}function dw(s){return s=l8(s),s!==null?fw(s):null}function fw(s){if(s.tag===5||s.tag===6)return s;for(s=s.child;s!==null;){var o=fw(s);if(o!==null)return o;s=s.sibling}return null}var pw=t.unstable_scheduleCallback,hw=t.unstable_cancelCallback,c8=t.unstable_shouldYield,u8=t.unstable_requestPaint,at=t.unstable_now,d8=t.unstable_getCurrentPriorityLevel,cp=t.unstable_ImmediatePriority,mw=t.unstable_UserBlockingPriority,yc=t.unstable_NormalPriority,f8=t.unstable_LowPriority,gw=t.unstable_IdlePriority,vc=null,Xn=null;function p8(s){if(Xn&&typeof Xn.onCommitFiberRoot=="function")try{Xn.onCommitFiberRoot(vc,s,void 0,(s.current.flags&128)===128)}catch{}}var Ln=Math.clz32?Math.clz32:g8,h8=Math.log,m8=Math.LN2;function g8(s){return s>>>=0,s===0?32:31-(h8(s)/m8|0)|0}var Sc=64,wc=4194304;function Ki(s){switch(s&-s){case 1:return 1;case 2:return 2;case 4:return 4;case 8:return 8;case 16:return 16;case 32:return 32;case 64:case 128:case 256:case 512:case 1024:case 2048:case 4096:case 8192:case 16384:case 32768:case 65536:case 131072:case 262144:case 524288:case 1048576:case 2097152:return s&4194240;case 4194304:case 8388608:case 16777216:case 33554432:case 67108864:return s&130023424;case 134217728:return 134217728;case 268435456:return 268435456;case 536870912:return 536870912;case 1073741824:return 1073741824;default:return s}}function _c(s,o){var l=s.pendingLanes;if(l===0)return 0;var u=0,p=s.suspendedLanes,m=s.pingedLanes,S=l&268435455;if(S!==0){var T=S&~p;T!==0?u=Ki(T):(m&=S,m!==0&&(u=Ki(m)))}else S=l&~p,S!==0?u=Ki(S):m!==0&&(u=Ki(m));if(u===0)return 0;if(o!==0&&o!==u&&!(o&p)&&(p=u&-u,m=o&-o,p>=m||p===16&&(m&4194240)!==0))return o;if(u&4&&(u|=l&16),o=s.entangledLanes,o!==0)for(s=s.entanglements,o&=u;0<o;)l=31-Ln(o),p=1<<l,u|=s[l],o&=~p;return u}function y8(s,o){switch(s){case 1:case 2:case 4:return o+250;case 8:case 16:case 32:case 64:case 128:case 256:case 512:case 1024:case 2048:case 4096:case 8192:case 16384:case 32768:case 65536:case 131072:case 262144:case 524288:case 1048576:case 2097152:return o+5e3;case 4194304:case 8388608:case 16777216:case 33554432:case 67108864:return-1;case 134217728:case 268435456:case 536870912:case 1073741824:return-1;default:return-1}}function v8(s,o){for(var l=s.suspendedLanes,u=s.pingedLanes,p=s.expirationTimes,m=s.pendingLanes;0<m;){var S=31-Ln(m),T=1<<S,b=p[S];b===-1?(!(T&l)||T&u)&&(p[S]=y8(T,o)):b<=o&&(s.expiredLanes|=T),m&=~T}}function up(s){return s=s.pendingLanes&-1073741825,s!==0?s:s&1073741824?1073741824:0}function yw(){var s=Sc;return Sc<<=1,!(Sc&4194240)&&(Sc=64),s}function dp(s){for(var o=[],l=0;31>l;l++)o.push(s);return o}function Qi(s,o,l){s.pendingLanes|=o,o!==536870912&&(s.suspendedLanes=0,s.pingedLanes=0),s=s.eventTimes,o=31-Ln(o),s[o]=l}function S8(s,o){var l=s.pendingLanes&~o;s.pendingLanes=o,s.suspendedLanes=0,s.pingedLanes=0,s.expiredLanes&=o,s.mutableReadLanes&=o,s.entangledLanes&=o,o=s.entanglements;var u=s.eventTimes;for(s=s.expirationTimes;0<l;){var p=31-Ln(l),m=1<<p;o[p]=0,u[p]=-1,s[p]=-1,l&=~m}}function fp(s,o){var l=s.entangledLanes|=o;for(s=s.entanglements;l;){var u=31-Ln(l),p=1<<u;p&o|s[u]&o&&(s[u]|=o),l&=~p}}var Ue=0;function vw(s){return s&=-s,1<s?4<s?s&268435455?16:536870912:4:1}var Sw,pp,ww,_w,Ew,hp=!1,Ec=[],Wr=null,qr=null,Vr=null,Xi=new Map,Ji=new Map,Gr=[],w8="mousedown mouseup touchcancel touchend touchstart auxclick dblclick pointercancel pointerdown pointerup dragend dragstart drop compositionend compositionstart keydown keypress keyup input textInput copy cut paste click change contextmenu reset submit".split(" ");function xw(s,o){switch(s){case"focusin":case"focusout":Wr=null;break;case"dragenter":case"dragleave":qr=null;break;case"mouseover":case"mouseout":Vr=null;break;case"pointerover":case"pointerout":Xi.delete(o.pointerId);break;case"gotpointercapture":case"lostpointercapture":Ji.delete(o.pointerId)}}function Zi(s,o,l,u,p,m){return s===null||s.nativeEvent!==m?(s={blockedOn:o,domEventName:l,eventSystemFlags:u,nativeEvent:m,targetContainers:[p]},o!==null&&(o=pa(o),o!==null&&pp(o)),s):(s.eventSystemFlags|=u,o=s.targetContainers,p!==null&&o.indexOf(p)===-1&&o.push(p),s)}function _8(s,o,l,u,p){switch(o){case"focusin":return Wr=Zi(Wr,s,o,l,u,p),!0;case"dragenter":return qr=Zi(qr,s,o,l,u,p),!0;case"mouseover":return Vr=Zi(Vr,s,o,l,u,p),!0;case"pointerover":var m=p.pointerId;return Xi.set(m,Zi(Xi.get(m)||null,s,o,l,u,p)),!0;case"gotpointercapture":return m=p.pointerId,Ji.set(m,Zi(Ji.get(m)||null,s,o,l,u,p)),!0}return!1}function kw(s){var o=Fs(s.target);if(o!==null){var l=$s(o);if(l!==null){if(o=l.tag,o===13){if(o=cw(l),o!==null){s.blockedOn=o,Ew(s.priority,function(){ww(l)});return}}else if(o===3&&l.stateNode.current.memoizedState.isDehydrated){s.blockedOn=l.tag===3?l.stateNode.containerInfo:null;return}}}s.blockedOn=null}function xc(s){if(s.blockedOn!==null)return!1;for(var o=s.targetContainers;0<o.length;){var l=gp(s.domEventName,s.eventSystemFlags,o[0],s.nativeEvent);if(l===null){l=s.nativeEvent;var u=new l.constructor(l.type,l);rp=u,l.target.dispatchEvent(u),rp=null}else return o=pa(l),o!==null&&pp(o),s.blockedOn=l,!1;o.shift()}return!0}function Tw(s,o,l){xc(s)&&l.delete(o)}function E8(){hp=!1,Wr!==null&&xc(Wr)&&(Wr=null),qr!==null&&xc(qr)&&(qr=null),Vr!==null&&xc(Vr)&&(Vr=null),Xi.forEach(Tw),Ji.forEach(Tw)}function ea(s,o){s.blockedOn===o&&(s.blockedOn=null,hp||(hp=!0,t.unstable_scheduleCallback(t.unstable_NormalPriority,E8)))}function ta(s){function o(p){return ea(p,s)}if(0<Ec.length){ea(Ec[0],s);for(var l=1;l<Ec.length;l++){var u=Ec[l];u.blockedOn===s&&(u.blockedOn=null)}}for(Wr!==null&&ea(Wr,s),qr!==null&&ea(qr,s),Vr!==null&&ea(Vr,s),Xi.forEach(o),Ji.forEach(o),l=0;l<Gr.length;l++)u=Gr[l],u.blockedOn===s&&(u.blockedOn=null);for(;0<Gr.length&&(l=Gr[0],l.blockedOn===null);)kw(l),l.blockedOn===null&&Gr.shift()}var Do=H.ReactCurrentBatchConfig,kc=!0;function x8(s,o,l,u){var p=Ue,m=Do.transition;Do.transition=null;try{Ue=1,mp(s,o,l,u)}finally{Ue=p,Do.transition=m}}function k8(s,o,l,u){var p=Ue,m=Do.transition;Do.transition=null;try{Ue=4,mp(s,o,l,u)}finally{Ue=p,Do.transition=m}}function mp(s,o,l,u){if(kc){var p=gp(s,o,l,u);if(p===null)Np(s,o,u,Tc,l),xw(s,u);else if(_8(p,s,o,l,u))u.stopPropagation();else if(xw(s,u),o&4&&-1<w8.indexOf(s)){for(;p!==null;){var m=pa(p);if(m!==null&&Sw(m),m=gp(s,o,l,u),m===null&&Np(s,o,u,Tc,l),m===p)break;p=m}p!==null&&u.stopPropagation()}else Np(s,o,u,null,l)}}var Tc=null;function gp(s,o,l,u){if(Tc=null,s=sp(u),s=Fs(s),s!==null)if(o=$s(s),o===null)s=null;else if(l=o.tag,l===13){if(s=cw(o),s!==null)return s;s=null}else if(l===3){if(o.stateNode.current.memoizedState.isDehydrated)return o.tag===3?o.stateNode.containerInfo:null;s=null}else o!==s&&(s=null);return Tc=s,null}function bw(s){switch(s){case"cancel":case"click":case"close":case"contextmenu":case"copy":case"cut":case"auxclick":case"dblclick":case"dragend":case"dragstart":case"drop":case"focusin":case"focusout":case"input":case"invalid":case"keydown":case"keypress":case"keyup":case"mousedown":case"mouseup":case"paste":case"pause":case"play":case"pointercancel":case"pointerdown":case"pointerup":case"ratechange":case"reset":case"resize":case"seeked":case"submit":case"touchcancel":case"touchend":case"touchstart":case"volumechange":case"change":case"selectionchange":case"textInput":case"compositionstart":case"compositionend":case"compositionupdate":case"beforeblur":case"afterblur":case"beforeinput":case"blur":case"fullscreenchange":case"focus":case"hashchange":case"popstate":case"select":case"selectstart":return 1;case"drag":case"dragenter":case"dragexit":case"dragleave":case"dragover":case"mousemove":case"mouseout":case"mouseover":case"pointermove":case"pointerout":case"pointerover":case"scroll":case"toggle":case"touchmove":case"wheel":case"mouseenter":case"mouseleave":case"pointerenter":case"pointerleave":return 4;case"message":switch(d8()){case cp:return 1;case mw:return 4;case yc:case f8:return 16;case gw:return 536870912;default:return 16}default:return 16}}var Yr=null,yp=null,bc=null;function Iw(){if(bc)return bc;var s,o=yp,l=o.length,u,p="value"in Yr?Yr.value:Yr.textContent,m=p.length;for(s=0;s<l&&o[s]===p[s];s++);var S=l-s;for(u=1;u<=S&&o[l-u]===p[m-u];u++);return bc=p.slice(s,1<u?1-u:void 0)}function Ic(s){var o=s.keyCode;return"charCode"in s?(s=s.charCode,s===0&&o===13&&(s=13)):s=o,s===10&&(s=13),32<=s||s===13?s:0}function Cc(){return!0}function Cw(){return!1}function dn(s){function o(l,u,p,m,S){this._reactName=l,this._targetInst=p,this.type=u,this.nativeEvent=m,this.target=S,this.currentTarget=null;for(var T in s)s.hasOwnProperty(T)&&(l=s[T],this[T]=l?l(m):m[T]);return this.isDefaultPrevented=(m.defaultPrevented!=null?m.defaultPrevented:m.returnValue===!1)?Cc:Cw,this.isPropagationStopped=Cw,this}return J(o.prototype,{preventDefault:function(){this.defaultPrevented=!0;var l=this.nativeEvent;l&&(l.preventDefault?l.preventDefault():typeof l.returnValue!="unknown"&&(l.returnValue=!1),this.isDefaultPrevented=Cc)},stopPropagation:function(){var l=this.nativeEvent;l&&(l.stopPropagation?l.stopPropagation():typeof l.cancelBubble!="unknown"&&(l.cancelBubble=!0),this.isPropagationStopped=Cc)},persist:function(){},isPersistent:Cc}),o}var $o={eventPhase:0,bubbles:0,cancelable:0,timeStamp:function(s){return s.timeStamp||Date.now()},defaultPrevented:0,isTrusted:0},vp=dn($o),na=J({},$o,{view:0,detail:0}),T8=dn(na),Sp,wp,ra,Rc=J({},na,{screenX:0,screenY:0,clientX:0,clientY:0,pageX:0,pageY:0,ctrlKey:0,shiftKey:0,altKey:0,metaKey:0,getModifierState:Ep,button:0,buttons:0,relatedTarget:function(s){return s.relatedTarget===void 0?s.fromElement===s.srcElement?s.toElement:s.fromElement:s.relatedTarget},movementX:function(s){return"movementX"in s?s.movementX:(s!==ra&&(ra&&s.type==="mousemove"?(Sp=s.screenX-ra.screenX,wp=s.screenY-ra.screenY):wp=Sp=0,ra=s),Sp)},movementY:function(s){return"movementY"in s?s.movementY:wp}}),Rw=dn(Rc),b8=J({},Rc,{dataTransfer:0}),I8=dn(b8),C8=J({},na,{relatedTarget:0}),_p=dn(C8),R8=J({},$o,{animationName:0,elapsedTime:0,pseudoElement:0}),A8=dn(R8),O8=J({},$o,{clipboardData:function(s){return"clipboardData"in s?s.clipboardData:window.clipboardData}}),P8=dn(O8),N8=J({},$o,{data:0}),Aw=dn(N8),M8={Esc:"Escape",Spacebar:" ",Left:"ArrowLeft",Up:"ArrowUp",Right:"ArrowRight",Down:"ArrowDown",Del:"Delete",Win:"OS",Menu:"ContextMenu",Apps:"ContextMenu",Scroll:"ScrollLock",MozPrintableKey:"Unidentified"},L8={8:"Backspace",9:"Tab",12:"Clear",13:"Enter",16:"Shift",17:"Control",18:"Alt",19:"Pause",20:"CapsLock",27:"Escape",32:" ",33:"PageUp",34:"PageDown",35:"End",36:"Home",37:"ArrowLeft",38:"ArrowUp",39:"ArrowRight",40:"ArrowDown",45:"Insert",46:"Delete",112:"F1",113:"F2",114:"F3",115:"F4",116:"F5",117:"F6",118:"F7",119:"F8",120:"F9",121:"F10",122:"F11",123:"F12",144:"NumLock",145:"ScrollLock",224:"Meta"},j8={Alt:"altKey",Control:"ctrlKey",Meta:"metaKey",Shift:"shiftKey"};function D8(s){var o=this.nativeEvent;return o.getModifierState?o.getModifierState(s):(s=j8[s])?!!o[s]:!1}function Ep(){return D8}var $8=J({},na,{key:function(s){if(s.key){var o=M8[s.key]||s.key;if(o!=="Unidentified")return o}return s.type==="keypress"?(s=Ic(s),s===13?"Enter":String.fromCharCode(s)):s.type==="keydown"||s.type==="keyup"?L8[s.keyCode]||"Unidentified":""},code:0,location:0,ctrlKey:0,shiftKey:0,altKey:0,metaKey:0,repeat:0,locale:0,getModifierState:Ep,charCode:function(s){return s.type==="keypress"?Ic(s):0},keyCode:function(s){return s.type==="keydown"||s.type==="keyup"?s.keyCode:0},which:function(s){return s.type==="keypress"?Ic(s):s.type==="keydown"||s.type==="keyup"?s.keyCode:0}}),F8=dn($8),B8=J({},Rc,{pointerId:0,width:0,height:0,pressure:0,tangentialPressure:0,tiltX:0,tiltY:0,twist:0,pointerType:0,isPrimary:0}),Ow=dn(B8),z8=J({},na,{touches:0,targetTouches:0,changedTouches:0,altKey:0,metaKey:0,ctrlKey:0,shiftKey:0,getModifierState:Ep}),U8=dn(z8),H8=J({},$o,{propertyName:0,elapsedTime:0,pseudoElement:0}),W8=dn(H8),q8=J({},Rc,{deltaX:function(s){return"deltaX"in s?s.deltaX:"wheelDeltaX"in s?-s.wheelDeltaX:0},deltaY:function(s){return"deltaY"in s?s.deltaY:"wheelDeltaY"in s?-s.wheelDeltaY:"wheelDelta"in s?-s.wheelDelta:0},deltaZ:0,deltaMode:0}),V8=dn(q8),G8=[9,13,27,32],xp=d&&"CompositionEvent"in window,sa=null;d&&"documentMode"in document&&(sa=document.documentMode);var Y8=d&&"TextEvent"in window&&!sa,Pw=d&&(!xp||sa&&8<sa&&11>=sa),Nw=" ",Mw=!1;function Lw(s,o){switch(s){case"keyup":return G8.indexOf(o.keyCode)!==-1;case"keydown":return o.keyCode!==229;case"keypress":case"mousedown":case"focusout":return!0;default:return!1}}function jw(s){return s=s.detail,typeof s=="object"&&"data"in s?s.data:null}var Fo=!1;function K8(s,o){switch(s){case"compositionend":return jw(o);case"keypress":return o.which!==32?null:(Mw=!0,Nw);case"textInput":return s=o.data,s===Nw&&Mw?null:s;default:return null}}function Q8(s,o){if(Fo)return s==="compositionend"||!xp&&Lw(s,o)?(s=Iw(),bc=yp=Yr=null,Fo=!1,s):null;switch(s){case"paste":return null;case"keypress":if(!(o.ctrlKey||o.altKey||o.metaKey)||o.ctrlKey&&o.altKey){if(o.char&&1<o.char.length)return o.char;if(o.which)return String.fromCharCode(o.which)}return null;case"compositionend":return Pw&&o.locale!=="ko"?null:o.data;default:return null}}var X8={color:!0,date:!0,datetime:!0,"datetime-local":!0,email:!0,month:!0,number:!0,password:!0,range:!0,search:!0,tel:!0,text:!0,time:!0,url:!0,week:!0};function Dw(s){var o=s&&s.nodeName&&s.nodeName.toLowerCase();return o==="input"?!!X8[s.type]:o==="textarea"}function $w(s,o,l,u){sw(u),o=Mc(o,"onChange"),0<o.length&&(l=new vp("onChange","change",null,l,u),s.push({event:l,listeners:o}))}var oa=null,ia=null;function J8(s){n_(s,0)}function Ac(s){var o=Wo(s);if(fc(o))return s}function Z8(s,o){if(s==="change")return o}var Fw=!1;if(d){var kp;if(d){var Tp="oninput"in document;if(!Tp){var Bw=document.createElement("div");Bw.setAttribute("oninput","return;"),Tp=typeof Bw.oninput=="function"}kp=Tp}else kp=!1;Fw=kp&&(!document.documentMode||9<document.documentMode)}function zw(){oa&&(oa.detachEvent("onpropertychange",Uw),ia=oa=null)}function Uw(s){if(s.propertyName==="value"&&Ac(ia)){var o=[];$w(o,ia,s,sp(s)),lw(J8,o)}}function eF(s,o,l){s==="focusin"?(zw(),oa=o,ia=l,oa.attachEvent("onpropertychange",Uw)):s==="focusout"&&zw()}function tF(s){if(s==="selectionchange"||s==="keyup"||s==="keydown")return Ac(ia)}function nF(s,o){if(s==="click")return Ac(o)}function rF(s,o){if(s==="input"||s==="change")return Ac(o)}function sF(s,o){return s===o&&(s!==0||1/s===1/o)||s!==s&&o!==o}var jn=typeof Object.is=="function"?Object.is:sF;function aa(s,o){if(jn(s,o))return!0;if(typeof s!="object"||s===null||typeof o!="object"||o===null)return!1;var l=Object.keys(s),u=Object.keys(o);if(l.length!==u.length)return!1;for(u=0;u<l.length;u++){var p=l[u];if(!f.call(o,p)||!jn(s[p],o[p]))return!1}return!0}function Hw(s){for(;s&&s.firstChild;)s=s.firstChild;return s}function Ww(s,o){var l=Hw(s);s=0;for(var u;l;){if(l.nodeType===3){if(u=s+l.textContent.length,s<=o&&u>=o)return{node:l,offset:o-s};s=u}e:{for(;l;){if(l.nextSibling){l=l.nextSibling;break e}l=l.parentNode}l=void 0}l=Hw(l)}}function qw(s,o){return s&&o?s===o?!0:s&&s.nodeType===3?!1:o&&o.nodeType===3?qw(s,o.parentNode):"contains"in s?s.contains(o):s.compareDocumentPosition?!!(s.compareDocumentPosition(o)&16):!1:!1}function Vw(){for(var s=window,o=No();o instanceof s.HTMLIFrameElement;){try{var l=typeof o.contentWindow.location.href=="string"}catch{l=!1}if(l)s=o.contentWindow;else break;o=No(s.document)}return o}function bp(s){var o=s&&s.nodeName&&s.nodeName.toLowerCase();return o&&(o==="input"&&(s.type==="text"||s.type==="search"||s.type==="tel"||s.type==="url"||s.type==="password")||o==="textarea"||s.contentEditable==="true")}function oF(s){var o=Vw(),l=s.focusedElem,u=s.selectionRange;if(o!==l&&l&&l.ownerDocument&&qw(l.ownerDocument.documentElement,l)){if(u!==null&&bp(l)){if(o=u.start,s=u.end,s===void 0&&(s=o),"selectionStart"in l)l.selectionStart=o,l.selectionEnd=Math.min(s,l.value.length);else if(s=(o=l.ownerDocument||document)&&o.defaultView||window,s.getSelection){s=s.getSelection();var p=l.textContent.length,m=Math.min(u.start,p);u=u.end===void 0?m:Math.min(u.end,p),!s.extend&&m>u&&(p=u,u=m,m=p),p=Ww(l,m);var S=Ww(l,u);p&&S&&(s.rangeCount!==1||s.anchorNode!==p.node||s.anchorOffset!==p.offset||s.focusNode!==S.node||s.focusOffset!==S.offset)&&(o=o.createRange(),o.setStart(p.node,p.offset),s.removeAllRanges(),m>u?(s.addRange(o),s.extend(S.node,S.offset)):(o.setEnd(S.node,S.offset),s.addRange(o)))}}for(o=[],s=l;s=s.parentNode;)s.nodeType===1&&o.push({element:s,left:s.scrollLeft,top:s.scrollTop});for(typeof l.focus=="function"&&l.focus(),l=0;l<o.length;l++)s=o[l],s.element.scrollLeft=s.left,s.element.scrollTop=s.top}}var iF=d&&"documentMode"in document&&11>=document.documentMode,Bo=null,Ip=null,la=null,Cp=!1;function Gw(s,o,l){var u=l.window===l?l.document:l.nodeType===9?l:l.ownerDocument;Cp||Bo==null||Bo!==No(u)||(u=Bo,"selectionStart"in u&&bp(u)?u={start:u.selectionStart,end:u.selectionEnd}:(u=(u.ownerDocument&&u.ownerDocument.defaultView||window).getSelection(),u={anchorNode:u.anchorNode,anchorOffset:u.anchorOffset,focusNode:u.focusNode,focusOffset:u.focusOffset}),la&&aa(la,u)||(la=u,u=Mc(Ip,"onSelect"),0<u.length&&(o=new vp("onSelect","select",null,o,l),s.push({event:o,listeners:u}),o.target=Bo)))}function Oc(s,o){var l={};return l[s.toLowerCase()]=o.toLowerCase(),l["Webkit"+s]="webkit"+o,l["Moz"+s]="moz"+o,l}var zo={animationend:Oc("Animation","AnimationEnd"),animationiteration:Oc("Animation","AnimationIteration"),animationstart:Oc("Animation","AnimationStart"),transitionend:Oc("Transition","TransitionEnd")},Rp={},Yw={};d&&(Yw=document.createElement("div").style,"AnimationEvent"in window||(delete zo.animationend.animation,delete zo.animationiteration.animation,delete zo.animationstart.animation),"TransitionEvent"in window||delete zo.transitionend.transition);function Pc(s){if(Rp[s])return Rp[s];if(!zo[s])return s;var o=zo[s],l;for(l in o)if(o.hasOwnProperty(l)&&l in Yw)return Rp[s]=o[l];return s}var Kw=Pc("animationend"),Qw=Pc("animationiteration"),Xw=Pc("animationstart"),Jw=Pc("transitionend"),Zw=new Map,e_="abort auxClick cancel canPlay canPlayThrough click close contextMenu copy cut drag dragEnd dragEnter dragExit dragLeave dragOver dragStart drop durationChange emptied encrypted ended error gotPointerCapture input invalid keyDown keyPress keyUp load loadedData loadedMetadata loadStart lostPointerCapture mouseDown mouseMove mouseOut mouseOver mouseUp paste pause play playing pointerCancel pointerDown pointerMove pointerOut pointerOver pointerUp progress rateChange reset resize seeked seeking stalled submit suspend timeUpdate touchCancel touchEnd touchStart volumeChange scroll toggle touchMove waiting wheel".split(" ");function Kr(s,o){Zw.set(s,o),a(o,[s])}for(var Ap=0;Ap<e_.length;Ap++){var Op=e_[Ap],aF=Op.toLowerCase(),lF=Op[0].toUpperCase()+Op.slice(1);Kr(aF,"on"+lF)}Kr(Kw,"onAnimationEnd"),Kr(Qw,"onAnimationIteration"),Kr(Xw,"onAnimationStart"),Kr("dblclick","onDoubleClick"),Kr("focusin","onFocus"),Kr("focusout","onBlur"),Kr(Jw,"onTransitionEnd"),c("onMouseEnter",["mouseout","mouseover"]),c("onMouseLeave",["mouseout","mouseover"]),c("onPointerEnter",["pointerout","pointerover"]),c("onPointerLeave",["pointerout","pointerover"]),a("onChange","change click focusin focusout input keydown keyup selectionchange".split(" ")),a("onSelect","focusout contextmenu dragend focusin keydown keyup mousedown mouseup selectionchange".split(" ")),a("onBeforeInput",["compositionend","keypress","textInput","paste"]),a("onCompositionEnd","compositionend focusout keydown keypress keyup mousedown".split(" ")),a("onCompositionStart","compositionstart focusout keydown keypress keyup mousedown".split(" ")),a("onCompositionUpdate","compositionupdate focusout keydown keypress keyup mousedown".split(" "));var ca="abort canplay canplaythrough durationchange emptied encrypted ended error loadeddata loadedmetadata loadstart pause play playing progress ratechange resize seeked seeking stalled suspend timeupdate volumechange waiting".split(" "),cF=new Set("cancel close invalid load scroll toggle".split(" ").concat(ca));function t_(s,o,l){var u=s.type||"unknown-event";s.currentTarget=l,a8(u,o,void 0,s),s.currentTarget=null}function n_(s,o){o=(o&4)!==0;for(var l=0;l<s.length;l++){var u=s[l],p=u.event;u=u.listeners;e:{var m=void 0;if(o)for(var S=u.length-1;0<=S;S--){var T=u[S],b=T.instance,D=T.currentTarget;if(T=T.listener,b!==m&&p.isPropagationStopped())break e;t_(p,T,D),m=b}else for(S=0;S<u.length;S++){if(T=u[S],b=T.instance,D=T.currentTarget,T=T.listener,b!==m&&p.isPropagationStopped())break e;t_(p,T,D),m=b}}}if(gc)throw s=lp,gc=!1,lp=null,s}function Xe(s,o){var l=o[Fp];l===void 0&&(l=o[Fp]=new Set);var u=s+"__bubble";l.has(u)||(r_(o,s,2,!1),l.add(u))}function Pp(s,o,l){var u=0;o&&(u|=4),r_(l,s,u,o)}var Nc="_reactListening"+Math.random().toString(36).slice(2);function ua(s){if(!s[Nc]){s[Nc]=!0,r.forEach(function(l){l!=="selectionchange"&&(cF.has(l)||Pp(l,!1,s),Pp(l,!0,s))});var o=s.nodeType===9?s:s.ownerDocument;o===null||o[Nc]||(o[Nc]=!0,Pp("selectionchange",!1,o))}}function r_(s,o,l,u){switch(bw(o)){case 1:var p=x8;break;case 4:p=k8;break;default:p=mp}l=p.bind(null,o,l,s),p=void 0,!ap||o!=="touchstart"&&o!=="touchmove"&&o!=="wheel"||(p=!0),u?p!==void 0?s.addEventListener(o,l,{capture:!0,passive:p}):s.addEventListener(o,l,!0):p!==void 0?s.addEventListener(o,l,{passive:p}):s.addEventListener(o,l,!1)}function Np(s,o,l,u,p){var m=u;if(!(o&1)&&!(o&2)&&u!==null)e:for(;;){if(u===null)return;var S=u.tag;if(S===3||S===4){var T=u.stateNode.containerInfo;if(T===p||T.nodeType===8&&T.parentNode===p)break;if(S===4)for(S=u.return;S!==null;){var b=S.tag;if((b===3||b===4)&&(b=S.stateNode.containerInfo,b===p||b.nodeType===8&&b.parentNode===p))return;S=S.return}for(;T!==null;){if(S=Fs(T),S===null)return;if(b=S.tag,b===5||b===6){u=m=S;continue e}T=T.parentNode}}u=u.return}lw(function(){var D=m,G=sp(l),Y=[];e:{var V=Zw.get(s);if(V!==void 0){var ee=vp,se=s;switch(s){case"keypress":if(Ic(l)===0)break e;case"keydown":case"keyup":ee=F8;break;case"focusin":se="focus",ee=_p;break;case"focusout":se="blur",ee=_p;break;case"beforeblur":case"afterblur":ee=_p;break;case"click":if(l.button===2)break e;case"auxclick":case"dblclick":case"mousedown":case"mousemove":case"mouseup":case"mouseout":case"mouseover":case"contextmenu":ee=Rw;break;case"drag":case"dragend":case"dragenter":case"dragexit":case"dragleave":case"dragover":case"dragstart":case"drop":ee=I8;break;case"touchcancel":case"touchend":case"touchmove":case"touchstart":ee=U8;break;case Kw:case Qw:case Xw:ee=A8;break;case Jw:ee=W8;break;case"scroll":ee=T8;break;case"wheel":ee=V8;break;case"copy":case"cut":case"paste":ee=P8;break;case"gotpointercapture":case"lostpointercapture":case"pointercancel":case"pointerdown":case"pointermove":case"pointerout":case"pointerover":case"pointerup":ee=Ow}var ie=(o&4)!==0,lt=!ie&&s==="scroll",P=ie?V!==null?V+"Capture":null:V;ie=[];for(var I=D,N;I!==null;){N=I;var Q=N.stateNode;if(N.tag===5&&Q!==null&&(N=Q,P!==null&&(Q=Vi(I,P),Q!=null&&ie.push(da(I,Q,N)))),lt)break;I=I.return}0<ie.length&&(V=new ee(V,se,null,l,G),Y.push({event:V,listeners:ie}))}}if(!(o&7)){e:{if(V=s==="mouseover"||s==="pointerover",ee=s==="mouseout"||s==="pointerout",V&&l!==rp&&(se=l.relatedTarget||l.fromElement)&&(Fs(se)||se[mr]))break e;if((ee||V)&&(V=G.window===G?G:(V=G.ownerDocument)?V.defaultView||V.parentWindow:window,ee?(se=l.relatedTarget||l.toElement,ee=D,se=se?Fs(se):null,se!==null&&(lt=$s(se),se!==lt||se.tag!==5&&se.tag!==6)&&(se=null)):(ee=null,se=D),ee!==se)){if(ie=Rw,Q="onMouseLeave",P="onMouseEnter",I="mouse",(s==="pointerout"||s==="pointerover")&&(ie=Ow,Q="onPointerLeave",P="onPointerEnter",I="pointer"),lt=ee==null?V:Wo(ee),N=se==null?V:Wo(se),V=new ie(Q,I+"leave",ee,l,G),V.target=lt,V.relatedTarget=N,Q=null,Fs(G)===D&&(ie=new ie(P,I+"enter",se,l,G),ie.target=N,ie.relatedTarget=lt,Q=ie),lt=Q,ee&&se)t:{for(ie=ee,P=se,I=0,N=ie;N;N=Uo(N))I++;for(N=0,Q=P;Q;Q=Uo(Q))N++;for(;0<I-N;)ie=Uo(ie),I--;for(;0<N-I;)P=Uo(P),N--;for(;I--;){if(ie===P||P!==null&&ie===P.alternate)break t;ie=Uo(ie),P=Uo(P)}ie=null}else ie=null;ee!==null&&s_(Y,V,ee,ie,!1),se!==null&&lt!==null&&s_(Y,lt,se,ie,!0)}}e:{if(V=D?Wo(D):window,ee=V.nodeName&&V.nodeName.toLowerCase(),ee==="select"||ee==="input"&&V.type==="file")var le=Z8;else if(Dw(V))if(Fw)le=rF;else{le=tF;var ue=eF}else(ee=V.nodeName)&&ee.toLowerCase()==="input"&&(V.type==="checkbox"||V.type==="radio")&&(le=nF);if(le&&(le=le(s,D))){$w(Y,le,l,G);break e}ue&&ue(s,V,D),s==="focusout"&&(ue=V._wrapperState)&&ue.controlled&&V.type==="number"&&Ds(V,"number",V.value)}switch(ue=D?Wo(D):window,s){case"focusin":(Dw(ue)||ue.contentEditable==="true")&&(Bo=ue,Ip=D,la=null);break;case"focusout":la=Ip=Bo=null;break;case"mousedown":Cp=!0;break;case"contextmenu":case"mouseup":case"dragend":Cp=!1,Gw(Y,l,G);break;case"selectionchange":if(iF)break;case"keydown":case"keyup":Gw(Y,l,G)}var de;if(xp)e:{switch(s){case"compositionstart":var me="onCompositionStart";break e;case"compositionend":me="onCompositionEnd";break e;case"compositionupdate":me="onCompositionUpdate";break e}me=void 0}else Fo?Lw(s,l)&&(me="onCompositionEnd"):s==="keydown"&&l.keyCode===229&&(me="onCompositionStart");me&&(Pw&&l.locale!=="ko"&&(Fo||me!=="onCompositionStart"?me==="onCompositionEnd"&&Fo&&(de=Iw()):(Yr=G,yp="value"in Yr?Yr.value:Yr.textContent,Fo=!0)),ue=Mc(D,me),0<ue.length&&(me=new Aw(me,s,null,l,G),Y.push({event:me,listeners:ue}),de?me.data=de:(de=jw(l),de!==null&&(me.data=de)))),(de=Y8?K8(s,l):Q8(s,l))&&(D=Mc(D,"onBeforeInput"),0<D.length&&(G=new Aw("onBeforeInput","beforeinput",null,l,G),Y.push({event:G,listeners:D}),G.data=de))}n_(Y,o)})}function da(s,o,l){return{instance:s,listener:o,currentTarget:l}}function Mc(s,o){for(var l=o+"Capture",u=[];s!==null;){var p=s,m=p.stateNode;p.tag===5&&m!==null&&(p=m,m=Vi(s,l),m!=null&&u.unshift(da(s,m,p)),m=Vi(s,o),m!=null&&u.push(da(s,m,p))),s=s.return}return u}function Uo(s){if(s===null)return null;do s=s.return;while(s&&s.tag!==5);return s||null}function s_(s,o,l,u,p){for(var m=o._reactName,S=[];l!==null&&l!==u;){var T=l,b=T.alternate,D=T.stateNode;if(b!==null&&b===u)break;T.tag===5&&D!==null&&(T=D,p?(b=Vi(l,m),b!=null&&S.unshift(da(l,b,T))):p||(b=Vi(l,m),b!=null&&S.push(da(l,b,T)))),l=l.return}S.length!==0&&s.push({event:o,listeners:S})}var uF=/\r\n?/g,dF=/\u0000|\uFFFD/g;function o_(s){return(typeof s=="string"?s:""+s).replace(uF,`
`).replace(dF,"")}function Lc(s,o,l){if(o=o_(o),o_(s)!==o&&l)throw Error(n(425))}function jc(){}var Mp=null,Lp=null;function jp(s,o){return s==="textarea"||s==="noscript"||typeof o.children=="string"||typeof o.children=="number"||typeof o.dangerouslySetInnerHTML=="object"&&o.dangerouslySetInnerHTML!==null&&o.dangerouslySetInnerHTML.__html!=null}var Dp=typeof setTimeout=="function"?setTimeout:void 0,fF=typeof clearTimeout=="function"?clearTimeout:void 0,i_=typeof Promise=="function"?Promise:void 0,pF=typeof queueMicrotask=="function"?queueMicrotask:typeof i_<"u"?function(s){return i_.resolve(null).then(s).catch(hF)}:Dp;function hF(s){setTimeout(function(){throw s})}function $p(s,o){var l=o,u=0;do{var p=l.nextSibling;if(s.removeChild(l),p&&p.nodeType===8)if(l=p.data,l==="/$"){if(u===0){s.removeChild(p),ta(o);return}u--}else l!=="$"&&l!=="$?"&&l!=="$!"||u++;l=p}while(l);ta(o)}function Qr(s){for(;s!=null;s=s.nextSibling){var o=s.nodeType;if(o===1||o===3)break;if(o===8){if(o=s.data,o==="$"||o==="$!"||o==="$?")break;if(o==="/$")return null}}return s}function a_(s){s=s.previousSibling;for(var o=0;s;){if(s.nodeType===8){var l=s.data;if(l==="$"||l==="$!"||l==="$?"){if(o===0)return s;o--}else l==="/$"&&o++}s=s.previousSibling}return null}var Ho=Math.random().toString(36).slice(2),Jn="__reactFiber$"+Ho,fa="__reactProps$"+Ho,mr="__reactContainer$"+Ho,Fp="__reactEvents$"+Ho,mF="__reactListeners$"+Ho,gF="__reactHandles$"+Ho;function Fs(s){var o=s[Jn];if(o)return o;for(var l=s.parentNode;l;){if(o=l[mr]||l[Jn]){if(l=o.alternate,o.child!==null||l!==null&&l.child!==null)for(s=a_(s);s!==null;){if(l=s[Jn])return l;s=a_(s)}return o}s=l,l=s.parentNode}return null}function pa(s){return s=s[Jn]||s[mr],!s||s.tag!==5&&s.tag!==6&&s.tag!==13&&s.tag!==3?null:s}function Wo(s){if(s.tag===5||s.tag===6)return s.stateNode;throw Error(n(33))}function Dc(s){return s[fa]||null}var Bp=[],qo=-1;function Xr(s){return{current:s}}function Je(s){0>qo||(s.current=Bp[qo],Bp[qo]=null,qo--)}function Qe(s,o){qo++,Bp[qo]=s.current,s.current=o}var Jr={},Lt=Xr(Jr),Zt=Xr(!1),Bs=Jr;function Vo(s,o){var l=s.type.contextTypes;if(!l)return Jr;var u=s.stateNode;if(u&&u.__reactInternalMemoizedUnmaskedChildContext===o)return u.__reactInternalMemoizedMaskedChildContext;var p={},m;for(m in l)p[m]=o[m];return u&&(s=s.stateNode,s.__reactInternalMemoizedUnmaskedChildContext=o,s.__reactInternalMemoizedMaskedChildContext=p),p}function en(s){return s=s.childContextTypes,s!=null}function $c(){Je(Zt),Je(Lt)}function l_(s,o,l){if(Lt.current!==Jr)throw Error(n(168));Qe(Lt,o),Qe(Zt,l)}function c_(s,o,l){var u=s.stateNode;if(o=o.childContextTypes,typeof u.getChildContext!="function")return l;u=u.getChildContext();for(var p in u)if(!(p in o))throw Error(n(108,ze(s)||"Unknown",p));return J({},l,u)}function Fc(s){return s=(s=s.stateNode)&&s.__reactInternalMemoizedMergedChildContext||Jr,Bs=Lt.current,Qe(Lt,s),Qe(Zt,Zt.current),!0}function u_(s,o,l){var u=s.stateNode;if(!u)throw Error(n(169));l?(s=c_(s,o,Bs),u.__reactInternalMemoizedMergedChildContext=s,Je(Zt),Je(Lt),Qe(Lt,s)):Je(Zt),Qe(Zt,l)}var gr=null,Bc=!1,zp=!1;function d_(s){gr===null?gr=[s]:gr.push(s)}function yF(s){Bc=!0,d_(s)}function Zr(){if(!zp&&gr!==null){zp=!0;var s=0,o=Ue;try{var l=gr;for(Ue=1;s<l.length;s++){var u=l[s];do u=u(!0);while(u!==null)}gr=null,Bc=!1}catch(p){throw gr!==null&&(gr=gr.slice(s+1)),pw(cp,Zr),p}finally{Ue=o,zp=!1}}return null}var Go=[],Yo=0,zc=null,Uc=0,_n=[],En=0,zs=null,yr=1,vr="";function Us(s,o){Go[Yo++]=Uc,Go[Yo++]=zc,zc=s,Uc=o}function f_(s,o,l){_n[En++]=yr,_n[En++]=vr,_n[En++]=zs,zs=s;var u=yr;s=vr;var p=32-Ln(u)-1;u&=~(1<<p),l+=1;var m=32-Ln(o)+p;if(30<m){var S=p-p%5;m=(u&(1<<S)-1).toString(32),u>>=S,p-=S,yr=1<<32-Ln(o)+p|l<<p|u,vr=m+s}else yr=1<<m|l<<p|u,vr=s}function Up(s){s.return!==null&&(Us(s,1),f_(s,1,0))}function Hp(s){for(;s===zc;)zc=Go[--Yo],Go[Yo]=null,Uc=Go[--Yo],Go[Yo]=null;for(;s===zs;)zs=_n[--En],_n[En]=null,vr=_n[--En],_n[En]=null,yr=_n[--En],_n[En]=null}var fn=null,pn=null,Ze=!1,Dn=null;function p_(s,o){var l=bn(5,null,null,0);l.elementType="DELETED",l.stateNode=o,l.return=s,o=s.deletions,o===null?(s.deletions=[l],s.flags|=16):o.push(l)}function h_(s,o){switch(s.tag){case 5:var l=s.type;return o=o.nodeType!==1||l.toLowerCase()!==o.nodeName.toLowerCase()?null:o,o!==null?(s.stateNode=o,fn=s,pn=Qr(o.firstChild),!0):!1;case 6:return o=s.pendingProps===""||o.nodeType!==3?null:o,o!==null?(s.stateNode=o,fn=s,pn=null,!0):!1;case 13:return o=o.nodeType!==8?null:o,o!==null?(l=zs!==null?{id:yr,overflow:vr}:null,s.memoizedState={dehydrated:o,treeContext:l,retryLane:1073741824},l=bn(18,null,null,0),l.stateNode=o,l.return=s,s.child=l,fn=s,pn=null,!0):!1;default:return!1}}function Wp(s){return(s.mode&1)!==0&&(s.flags&128)===0}function qp(s){if(Ze){var o=pn;if(o){var l=o;if(!h_(s,o)){if(Wp(s))throw Error(n(418));o=Qr(l.nextSibling);var u=fn;o&&h_(s,o)?p_(u,l):(s.flags=s.flags&-4097|2,Ze=!1,fn=s)}}else{if(Wp(s))throw Error(n(418));s.flags=s.flags&-4097|2,Ze=!1,fn=s}}}function m_(s){for(s=s.return;s!==null&&s.tag!==5&&s.tag!==3&&s.tag!==13;)s=s.return;fn=s}function Hc(s){if(s!==fn)return!1;if(!Ze)return m_(s),Ze=!0,!1;var o;if((o=s.tag!==3)&&!(o=s.tag!==5)&&(o=s.type,o=o!=="head"&&o!=="body"&&!jp(s.type,s.memoizedProps)),o&&(o=pn)){if(Wp(s))throw g_(),Error(n(418));for(;o;)p_(s,o),o=Qr(o.nextSibling)}if(m_(s),s.tag===13){if(s=s.memoizedState,s=s!==null?s.dehydrated:null,!s)throw Error(n(317));e:{for(s=s.nextSibling,o=0;s;){if(s.nodeType===8){var l=s.data;if(l==="/$"){if(o===0){pn=Qr(s.nextSibling);break e}o--}else l!=="$"&&l!=="$!"&&l!=="$?"||o++}s=s.nextSibling}pn=null}}else pn=fn?Qr(s.stateNode.nextSibling):null;return!0}function g_(){for(var s=pn;s;)s=Qr(s.nextSibling)}function Ko(){pn=fn=null,Ze=!1}function Vp(s){Dn===null?Dn=[s]:Dn.push(s)}var vF=H.ReactCurrentBatchConfig;function ha(s,o,l){if(s=l.ref,s!==null&&typeof s!="function"&&typeof s!="object"){if(l._owner){if(l=l._owner,l){if(l.tag!==1)throw Error(n(309));var u=l.stateNode}if(!u)throw Error(n(147,s));var p=u,m=""+s;return o!==null&&o.ref!==null&&typeof o.ref=="function"&&o.ref._stringRef===m?o.ref:(o=function(S){var T=p.refs;S===null?delete T[m]:T[m]=S},o._stringRef=m,o)}if(typeof s!="string")throw Error(n(284));if(!l._owner)throw Error(n(290,s))}return s}function Wc(s,o){throw s=Object.prototype.toString.call(o),Error(n(31,s==="[object Object]"?"object with keys {"+Object.keys(o).join(", ")+"}":s))}function y_(s){var o=s._init;return o(s._payload)}function v_(s){function o(P,I){if(s){var N=P.deletions;N===null?(P.deletions=[I],P.flags|=16):N.push(I)}}function l(P,I){if(!s)return null;for(;I!==null;)o(P,I),I=I.sibling;return null}function u(P,I){for(P=new Map;I!==null;)I.key!==null?P.set(I.key,I):P.set(I.index,I),I=I.sibling;return P}function p(P,I){return P=as(P,I),P.index=0,P.sibling=null,P}function m(P,I,N){return P.index=N,s?(N=P.alternate,N!==null?(N=N.index,N<I?(P.flags|=2,I):N):(P.flags|=2,I)):(P.flags|=1048576,I)}function S(P){return s&&P.alternate===null&&(P.flags|=2),P}function T(P,I,N,Q){return I===null||I.tag!==6?(I=Dh(N,P.mode,Q),I.return=P,I):(I=p(I,N),I.return=P,I)}function b(P,I,N,Q){var le=N.type;return le===L?G(P,I,N.props.children,Q,N.key):I!==null&&(I.elementType===le||typeof le=="object"&&le!==null&&le.$$typeof===ce&&y_(le)===I.type)?(Q=p(I,N.props),Q.ref=ha(P,I,N),Q.return=P,Q):(Q=hu(N.type,N.key,N.props,null,P.mode,Q),Q.ref=ha(P,I,N),Q.return=P,Q)}function D(P,I,N,Q){return I===null||I.tag!==4||I.stateNode.containerInfo!==N.containerInfo||I.stateNode.implementation!==N.implementation?(I=$h(N,P.mode,Q),I.return=P,I):(I=p(I,N.children||[]),I.return=P,I)}function G(P,I,N,Q,le){return I===null||I.tag!==7?(I=Qs(N,P.mode,Q,le),I.return=P,I):(I=p(I,N),I.return=P,I)}function Y(P,I,N){if(typeof I=="string"&&I!==""||typeof I=="number")return I=Dh(""+I,P.mode,N),I.return=P,I;if(typeof I=="object"&&I!==null){switch(I.$$typeof){case z:return N=hu(I.type,I.key,I.props,null,P.mode,N),N.ref=ha(P,null,I),N.return=P,N;case M:return I=$h(I,P.mode,N),I.return=P,I;case ce:var Q=I._init;return Y(P,Q(I._payload),N)}if(Re(I)||re(I))return I=Qs(I,P.mode,N,null),I.return=P,I;Wc(P,I)}return null}function V(P,I,N,Q){var le=I!==null?I.key:null;if(typeof N=="string"&&N!==""||typeof N=="number")return le!==null?null:T(P,I,""+N,Q);if(typeof N=="object"&&N!==null){switch(N.$$typeof){case z:return N.key===le?b(P,I,N,Q):null;case M:return N.key===le?D(P,I,N,Q):null;case ce:return le=N._init,V(P,I,le(N._payload),Q)}if(Re(N)||re(N))return le!==null?null:G(P,I,N,Q,null);Wc(P,N)}return null}function ee(P,I,N,Q,le){if(typeof Q=="string"&&Q!==""||typeof Q=="number")return P=P.get(N)||null,T(I,P,""+Q,le);if(typeof Q=="object"&&Q!==null){switch(Q.$$typeof){case z:return P=P.get(Q.key===null?N:Q.key)||null,b(I,P,Q,le);case M:return P=P.get(Q.key===null?N:Q.key)||null,D(I,P,Q,le);case ce:var ue=Q._init;return ee(P,I,N,ue(Q._payload),le)}if(Re(Q)||re(Q))return P=P.get(N)||null,G(I,P,Q,le,null);Wc(I,Q)}return null}function se(P,I,N,Q){for(var le=null,ue=null,de=I,me=I=0,kt=null;de!==null&&me<N.length;me++){de.index>me?(kt=de,de=null):kt=de.sibling;var Be=V(P,de,N[me],Q);if(Be===null){de===null&&(de=kt);break}s&&de&&Be.alternate===null&&o(P,de),I=m(Be,I,me),ue===null?le=Be:ue.sibling=Be,ue=Be,de=kt}if(me===N.length)return l(P,de),Ze&&Us(P,me),le;if(de===null){for(;me<N.length;me++)de=Y(P,N[me],Q),de!==null&&(I=m(de,I,me),ue===null?le=de:ue.sibling=de,ue=de);return Ze&&Us(P,me),le}for(de=u(P,de);me<N.length;me++)kt=ee(de,P,me,N[me],Q),kt!==null&&(s&&kt.alternate!==null&&de.delete(kt.key===null?me:kt.key),I=m(kt,I,me),ue===null?le=kt:ue.sibling=kt,ue=kt);return s&&de.forEach(function(ls){return o(P,ls)}),Ze&&Us(P,me),le}function ie(P,I,N,Q){var le=re(N);if(typeof le!="function")throw Error(n(150));if(N=le.call(N),N==null)throw Error(n(151));for(var ue=le=null,de=I,me=I=0,kt=null,Be=N.next();de!==null&&!Be.done;me++,Be=N.next()){de.index>me?(kt=de,de=null):kt=de.sibling;var ls=V(P,de,Be.value,Q);if(ls===null){de===null&&(de=kt);break}s&&de&&ls.alternate===null&&o(P,de),I=m(ls,I,me),ue===null?le=ls:ue.sibling=ls,ue=ls,de=kt}if(Be.done)return l(P,de),Ze&&Us(P,me),le;if(de===null){for(;!Be.done;me++,Be=N.next())Be=Y(P,Be.value,Q),Be!==null&&(I=m(Be,I,me),ue===null?le=Be:ue.sibling=Be,ue=Be);return Ze&&Us(P,me),le}for(de=u(P,de);!Be.done;me++,Be=N.next())Be=ee(de,P,me,Be.value,Q),Be!==null&&(s&&Be.alternate!==null&&de.delete(Be.key===null?me:Be.key),I=m(Be,I,me),ue===null?le=Be:ue.sibling=Be,ue=Be);return s&&de.forEach(function(XF){return o(P,XF)}),Ze&&Us(P,me),le}function lt(P,I,N,Q){if(typeof N=="object"&&N!==null&&N.type===L&&N.key===null&&(N=N.props.children),typeof N=="object"&&N!==null){switch(N.$$typeof){case z:e:{for(var le=N.key,ue=I;ue!==null;){if(ue.key===le){if(le=N.type,le===L){if(ue.tag===7){l(P,ue.sibling),I=p(ue,N.props.children),I.return=P,P=I;break e}}else if(ue.elementType===le||typeof le=="object"&&le!==null&&le.$$typeof===ce&&y_(le)===ue.type){l(P,ue.sibling),I=p(ue,N.props),I.ref=ha(P,ue,N),I.return=P,P=I;break e}l(P,ue);break}else o(P,ue);ue=ue.sibling}N.type===L?(I=Qs(N.props.children,P.mode,Q,N.key),I.return=P,P=I):(Q=hu(N.type,N.key,N.props,null,P.mode,Q),Q.ref=ha(P,I,N),Q.return=P,P=Q)}return S(P);case M:e:{for(ue=N.key;I!==null;){if(I.key===ue)if(I.tag===4&&I.stateNode.containerInfo===N.containerInfo&&I.stateNode.implementation===N.implementation){l(P,I.sibling),I=p(I,N.children||[]),I.return=P,P=I;break e}else{l(P,I);break}else o(P,I);I=I.sibling}I=$h(N,P.mode,Q),I.return=P,P=I}return S(P);case ce:return ue=N._init,lt(P,I,ue(N._payload),Q)}if(Re(N))return se(P,I,N,Q);if(re(N))return ie(P,I,N,Q);Wc(P,N)}return typeof N=="string"&&N!==""||typeof N=="number"?(N=""+N,I!==null&&I.tag===6?(l(P,I.sibling),I=p(I,N),I.return=P,P=I):(l(P,I),I=Dh(N,P.mode,Q),I.return=P,P=I),S(P)):l(P,I)}return lt}var Qo=v_(!0),S_=v_(!1),qc=Xr(null),Vc=null,Xo=null,Gp=null;function Yp(){Gp=Xo=Vc=null}function Kp(s){var o=qc.current;Je(qc),s._currentValue=o}function Qp(s,o,l){for(;s!==null;){var u=s.alternate;if((s.childLanes&o)!==o?(s.childLanes|=o,u!==null&&(u.childLanes|=o)):u!==null&&(u.childLanes&o)!==o&&(u.childLanes|=o),s===l)break;s=s.return}}function Jo(s,o){Vc=s,Gp=Xo=null,s=s.dependencies,s!==null&&s.firstContext!==null&&(s.lanes&o&&(tn=!0),s.firstContext=null)}function xn(s){var o=s._currentValue;if(Gp!==s)if(s={context:s,memoizedValue:o,next:null},Xo===null){if(Vc===null)throw Error(n(308));Xo=s,Vc.dependencies={lanes:0,firstContext:s}}else Xo=Xo.next=s;return o}var Hs=null;function Xp(s){Hs===null?Hs=[s]:Hs.push(s)}function w_(s,o,l,u){var p=o.interleaved;return p===null?(l.next=l,Xp(o)):(l.next=p.next,p.next=l),o.interleaved=l,Sr(s,u)}function Sr(s,o){s.lanes|=o;var l=s.alternate;for(l!==null&&(l.lanes|=o),l=s,s=s.return;s!==null;)s.childLanes|=o,l=s.alternate,l!==null&&(l.childLanes|=o),l=s,s=s.return;return l.tag===3?l.stateNode:null}var es=!1;function Jp(s){s.updateQueue={baseState:s.memoizedState,firstBaseUpdate:null,lastBaseUpdate:null,shared:{pending:null,interleaved:null,lanes:0},effects:null}}function __(s,o){s=s.updateQueue,o.updateQueue===s&&(o.updateQueue={baseState:s.baseState,firstBaseUpdate:s.firstBaseUpdate,lastBaseUpdate:s.lastBaseUpdate,shared:s.shared,effects:s.effects})}function wr(s,o){return{eventTime:s,lane:o,tag:0,payload:null,callback:null,next:null}}function ts(s,o,l){var u=s.updateQueue;if(u===null)return null;if(u=u.shared,$e&2){var p=u.pending;return p===null?o.next=o:(o.next=p.next,p.next=o),u.pending=o,Sr(s,l)}return p=u.interleaved,p===null?(o.next=o,Xp(u)):(o.next=p.next,p.next=o),u.interleaved=o,Sr(s,l)}function Gc(s,o,l){if(o=o.updateQueue,o!==null&&(o=o.shared,(l&4194240)!==0)){var u=o.lanes;u&=s.pendingLanes,l|=u,o.lanes=l,fp(s,l)}}function E_(s,o){var l=s.updateQueue,u=s.alternate;if(u!==null&&(u=u.updateQueue,l===u)){var p=null,m=null;if(l=l.firstBaseUpdate,l!==null){do{var S={eventTime:l.eventTime,lane:l.lane,tag:l.tag,payload:l.payload,callback:l.callback,next:null};m===null?p=m=S:m=m.next=S,l=l.next}while(l!==null);m===null?p=m=o:m=m.next=o}else p=m=o;l={baseState:u.baseState,firstBaseUpdate:p,lastBaseUpdate:m,shared:u.shared,effects:u.effects},s.updateQueue=l;return}s=l.lastBaseUpdate,s===null?l.firstBaseUpdate=o:s.next=o,l.lastBaseUpdate=o}function Yc(s,o,l,u){var p=s.updateQueue;es=!1;var m=p.firstBaseUpdate,S=p.lastBaseUpdate,T=p.shared.pending;if(T!==null){p.shared.pending=null;var b=T,D=b.next;b.next=null,S===null?m=D:S.next=D,S=b;var G=s.alternate;G!==null&&(G=G.updateQueue,T=G.lastBaseUpdate,T!==S&&(T===null?G.firstBaseUpdate=D:T.next=D,G.lastBaseUpdate=b))}if(m!==null){var Y=p.baseState;S=0,G=D=b=null,T=m;do{var V=T.lane,ee=T.eventTime;if((u&V)===V){G!==null&&(G=G.next={eventTime:ee,lane:0,tag:T.tag,payload:T.payload,callback:T.callback,next:null});e:{var se=s,ie=T;switch(V=o,ee=l,ie.tag){case 1:if(se=ie.payload,typeof se=="function"){Y=se.call(ee,Y,V);break e}Y=se;break e;case 3:se.flags=se.flags&-65537|128;case 0:if(se=ie.payload,V=typeof se=="function"?se.call(ee,Y,V):se,V==null)break e;Y=J({},Y,V);break e;case 2:es=!0}}T.callback!==null&&T.lane!==0&&(s.flags|=64,V=p.effects,V===null?p.effects=[T]:V.push(T))}else ee={eventTime:ee,lane:V,tag:T.tag,payload:T.payload,callback:T.callback,next:null},G===null?(D=G=ee,b=Y):G=G.next=ee,S|=V;if(T=T.next,T===null){if(T=p.shared.pending,T===null)break;V=T,T=V.next,V.next=null,p.lastBaseUpdate=V,p.shared.pending=null}}while(!0);if(G===null&&(b=Y),p.baseState=b,p.firstBaseUpdate=D,p.lastBaseUpdate=G,o=p.shared.interleaved,o!==null){p=o;do S|=p.lane,p=p.next;while(p!==o)}else m===null&&(p.shared.lanes=0);Vs|=S,s.lanes=S,s.memoizedState=Y}}function x_(s,o,l){if(s=o.effects,o.effects=null,s!==null)for(o=0;o<s.length;o++){var u=s[o],p=u.callback;if(p!==null){if(u.callback=null,u=l,typeof p!="function")throw Error(n(191,p));p.call(u)}}}var ma={},Zn=Xr(ma),ga=Xr(ma),ya=Xr(ma);function Ws(s){if(s===ma)throw Error(n(174));return s}function Zp(s,o){switch(Qe(ya,o),Qe(ga,s),Qe(Zn,ma),s=o.nodeType,s){case 9:case 11:o=(o=o.documentElement)?o.namespaceURI:ep(null,"");break;default:s=s===8?o.parentNode:o,o=s.namespaceURI||null,s=s.tagName,o=ep(o,s)}Je(Zn),Qe(Zn,o)}function Zo(){Je(Zn),Je(ga),Je(ya)}function k_(s){Ws(ya.current);var o=Ws(Zn.current),l=ep(o,s.type);o!==l&&(Qe(ga,s),Qe(Zn,l))}function eh(s){ga.current===s&&(Je(Zn),Je(ga))}var et=Xr(0);function Kc(s){for(var o=s;o!==null;){if(o.tag===13){var l=o.memoizedState;if(l!==null&&(l=l.dehydrated,l===null||l.data==="$?"||l.data==="$!"))return o}else if(o.tag===19&&o.memoizedProps.revealOrder!==void 0){if(o.flags&128)return o}else if(o.child!==null){o.child.return=o,o=o.child;continue}if(o===s)break;for(;o.sibling===null;){if(o.return===null||o.return===s)return null;o=o.return}o.sibling.return=o.return,o=o.sibling}return null}var th=[];function nh(){for(var s=0;s<th.length;s++)th[s]._workInProgressVersionPrimary=null;th.length=0}var Qc=H.ReactCurrentDispatcher,rh=H.ReactCurrentBatchConfig,qs=0,tt=null,pt=null,Et=null,Xc=!1,va=!1,Sa=0,SF=0;function jt(){throw Error(n(321))}function sh(s,o){if(o===null)return!1;for(var l=0;l<o.length&&l<s.length;l++)if(!jn(s[l],o[l]))return!1;return!0}function oh(s,o,l,u,p,m){if(qs=m,tt=o,o.memoizedState=null,o.updateQueue=null,o.lanes=0,Qc.current=s===null||s.memoizedState===null?xF:kF,s=l(u,p),va){m=0;do{if(va=!1,Sa=0,25<=m)throw Error(n(301));m+=1,Et=pt=null,o.updateQueue=null,Qc.current=TF,s=l(u,p)}while(va)}if(Qc.current=eu,o=pt!==null&&pt.next!==null,qs=0,Et=pt=tt=null,Xc=!1,o)throw Error(n(300));return s}function ih(){var s=Sa!==0;return Sa=0,s}function er(){var s={memoizedState:null,baseState:null,baseQueue:null,queue:null,next:null};return Et===null?tt.memoizedState=Et=s:Et=Et.next=s,Et}function kn(){if(pt===null){var s=tt.alternate;s=s!==null?s.memoizedState:null}else s=pt.next;var o=Et===null?tt.memoizedState:Et.next;if(o!==null)Et=o,pt=s;else{if(s===null)throw Error(n(310));pt=s,s={memoizedState:pt.memoizedState,baseState:pt.baseState,baseQueue:pt.baseQueue,queue:pt.queue,next:null},Et===null?tt.memoizedState=Et=s:Et=Et.next=s}return Et}function wa(s,o){return typeof o=="function"?o(s):o}function ah(s){var o=kn(),l=o.queue;if(l===null)throw Error(n(311));l.lastRenderedReducer=s;var u=pt,p=u.baseQueue,m=l.pending;if(m!==null){if(p!==null){var S=p.next;p.next=m.next,m.next=S}u.baseQueue=p=m,l.pending=null}if(p!==null){m=p.next,u=u.baseState;var T=S=null,b=null,D=m;do{var G=D.lane;if((qs&G)===G)b!==null&&(b=b.next={lane:0,action:D.action,hasEagerState:D.hasEagerState,eagerState:D.eagerState,next:null}),u=D.hasEagerState?D.eagerState:s(u,D.action);else{var Y={lane:G,action:D.action,hasEagerState:D.hasEagerState,eagerState:D.eagerState,next:null};b===null?(T=b=Y,S=u):b=b.next=Y,tt.lanes|=G,Vs|=G}D=D.next}while(D!==null&&D!==m);b===null?S=u:b.next=T,jn(u,o.memoizedState)||(tn=!0),o.memoizedState=u,o.baseState=S,o.baseQueue=b,l.lastRenderedState=u}if(s=l.interleaved,s!==null){p=s;do m=p.lane,tt.lanes|=m,Vs|=m,p=p.next;while(p!==s)}else p===null&&(l.lanes=0);return[o.memoizedState,l.dispatch]}function lh(s){var o=kn(),l=o.queue;if(l===null)throw Error(n(311));l.lastRenderedReducer=s;var u=l.dispatch,p=l.pending,m=o.memoizedState;if(p!==null){l.pending=null;var S=p=p.next;do m=s(m,S.action),S=S.next;while(S!==p);jn(m,o.memoizedState)||(tn=!0),o.memoizedState=m,o.baseQueue===null&&(o.baseState=m),l.lastRenderedState=m}return[m,u]}function T_(){}function b_(s,o){var l=tt,u=kn(),p=o(),m=!jn(u.memoizedState,p);if(m&&(u.memoizedState=p,tn=!0),u=u.queue,ch(R_.bind(null,l,u,s),[s]),u.getSnapshot!==o||m||Et!==null&&Et.memoizedState.tag&1){if(l.flags|=2048,_a(9,C_.bind(null,l,u,p,o),void 0,null),xt===null)throw Error(n(349));qs&30||I_(l,o,p)}return p}function I_(s,o,l){s.flags|=16384,s={getSnapshot:o,value:l},o=tt.updateQueue,o===null?(o={lastEffect:null,stores:null},tt.updateQueue=o,o.stores=[s]):(l=o.stores,l===null?o.stores=[s]:l.push(s))}function C_(s,o,l,u){o.value=l,o.getSnapshot=u,A_(o)&&O_(s)}function R_(s,o,l){return l(function(){A_(o)&&O_(s)})}function A_(s){var o=s.getSnapshot;s=s.value;try{var l=o();return!jn(s,l)}catch{return!0}}function O_(s){var o=Sr(s,1);o!==null&&zn(o,s,1,-1)}function P_(s){var o=er();return typeof s=="function"&&(s=s()),o.memoizedState=o.baseState=s,s={pending:null,interleaved:null,lanes:0,dispatch:null,lastRenderedReducer:wa,lastRenderedState:s},o.queue=s,s=s.dispatch=EF.bind(null,tt,s),[o.memoizedState,s]}function _a(s,o,l,u){return s={tag:s,create:o,destroy:l,deps:u,next:null},o=tt.updateQueue,o===null?(o={lastEffect:null,stores:null},tt.updateQueue=o,o.lastEffect=s.next=s):(l=o.lastEffect,l===null?o.lastEffect=s.next=s:(u=l.next,l.next=s,s.next=u,o.lastEffect=s)),s}function N_(){return kn().memoizedState}function Jc(s,o,l,u){var p=er();tt.flags|=s,p.memoizedState=_a(1|o,l,void 0,u===void 0?null:u)}function Zc(s,o,l,u){var p=kn();u=u===void 0?null:u;var m=void 0;if(pt!==null){var S=pt.memoizedState;if(m=S.destroy,u!==null&&sh(u,S.deps)){p.memoizedState=_a(o,l,m,u);return}}tt.flags|=s,p.memoizedState=_a(1|o,l,m,u)}function M_(s,o){return Jc(8390656,8,s,o)}function ch(s,o){return Zc(2048,8,s,o)}function L_(s,o){return Zc(4,2,s,o)}function j_(s,o){return Zc(4,4,s,o)}function D_(s,o){if(typeof o=="function")return s=s(),o(s),function(){o(null)};if(o!=null)return s=s(),o.current=s,function(){o.current=null}}function $_(s,o,l){return l=l!=null?l.concat([s]):null,Zc(4,4,D_.bind(null,o,s),l)}function uh(){}function F_(s,o){var l=kn();o=o===void 0?null:o;var u=l.memoizedState;return u!==null&&o!==null&&sh(o,u[1])?u[0]:(l.memoizedState=[s,o],s)}function B_(s,o){var l=kn();o=o===void 0?null:o;var u=l.memoizedState;return u!==null&&o!==null&&sh(o,u[1])?u[0]:(s=s(),l.memoizedState=[s,o],s)}function z_(s,o,l){return qs&21?(jn(l,o)||(l=yw(),tt.lanes|=l,Vs|=l,s.baseState=!0),o):(s.baseState&&(s.baseState=!1,tn=!0),s.memoizedState=l)}function wF(s,o){var l=Ue;Ue=l!==0&&4>l?l:4,s(!0);var u=rh.transition;rh.transition={};try{s(!1),o()}finally{Ue=l,rh.transition=u}}function U_(){return kn().memoizedState}function _F(s,o,l){var u=os(s);if(l={lane:u,action:l,hasEagerState:!1,eagerState:null,next:null},H_(s))W_(o,l);else if(l=w_(s,o,l,u),l!==null){var p=qt();zn(l,s,u,p),q_(l,o,u)}}function EF(s,o,l){var u=os(s),p={lane:u,action:l,hasEagerState:!1,eagerState:null,next:null};if(H_(s))W_(o,p);else{var m=s.alternate;if(s.lanes===0&&(m===null||m.lanes===0)&&(m=o.lastRenderedReducer,m!==null))try{var S=o.lastRenderedState,T=m(S,l);if(p.hasEagerState=!0,p.eagerState=T,jn(T,S)){var b=o.interleaved;b===null?(p.next=p,Xp(o)):(p.next=b.next,b.next=p),o.interleaved=p;return}}catch{}finally{}l=w_(s,o,p,u),l!==null&&(p=qt(),zn(l,s,u,p),q_(l,o,u))}}function H_(s){var o=s.alternate;return s===tt||o!==null&&o===tt}function W_(s,o){va=Xc=!0;var l=s.pending;l===null?o.next=o:(o.next=l.next,l.next=o),s.pending=o}function q_(s,o,l){if(l&4194240){var u=o.lanes;u&=s.pendingLanes,l|=u,o.lanes=l,fp(s,l)}}var eu={readContext:xn,useCallback:jt,useContext:jt,useEffect:jt,useImperativeHandle:jt,useInsertionEffect:jt,useLayoutEffect:jt,useMemo:jt,useReducer:jt,useRef:jt,useState:jt,useDebugValue:jt,useDeferredValue:jt,useTransition:jt,useMutableSource:jt,useSyncExternalStore:jt,useId:jt,unstable_isNewReconciler:!1},xF={readContext:xn,useCallback:function(s,o){return er().memoizedState=[s,o===void 0?null:o],s},useContext:xn,useEffect:M_,useImperativeHandle:function(s,o,l){return l=l!=null?l.concat([s]):null,Jc(4194308,4,D_.bind(null,o,s),l)},useLayoutEffect:function(s,o){return Jc(4194308,4,s,o)},useInsertionEffect:function(s,o){return Jc(4,2,s,o)},useMemo:function(s,o){var l=er();return o=o===void 0?null:o,s=s(),l.memoizedState=[s,o],s},useReducer:function(s,o,l){var u=er();return o=l!==void 0?l(o):o,u.memoizedState=u.baseState=o,s={pending:null,interleaved:null,lanes:0,dispatch:null,lastRenderedReducer:s,lastRenderedState:o},u.queue=s,s=s.dispatch=_F.bind(null,tt,s),[u.memoizedState,s]},useRef:function(s){var o=er();return s={current:s},o.memoizedState=s},useState:P_,useDebugValue:uh,useDeferredValue:function(s){return er().memoizedState=s},useTransition:function(){var s=P_(!1),o=s[0];return s=wF.bind(null,s[1]),er().memoizedState=s,[o,s]},useMutableSource:function(){},useSyncExternalStore:function(s,o,l){var u=tt,p=er();if(Ze){if(l===void 0)throw Error(n(407));l=l()}else{if(l=o(),xt===null)throw Error(n(349));qs&30||I_(u,o,l)}p.memoizedState=l;var m={value:l,getSnapshot:o};return p.queue=m,M_(R_.bind(null,u,m,s),[s]),u.flags|=2048,_a(9,C_.bind(null,u,m,l,o),void 0,null),l},useId:function(){var s=er(),o=xt.identifierPrefix;if(Ze){var l=vr,u=yr;l=(u&~(1<<32-Ln(u)-1)).toString(32)+l,o=":"+o+"R"+l,l=Sa++,0<l&&(o+="H"+l.toString(32)),o+=":"}else l=SF++,o=":"+o+"r"+l.toString(32)+":";return s.memoizedState=o},unstable_isNewReconciler:!1},kF={readContext:xn,useCallback:F_,useContext:xn,useEffect:ch,useImperativeHandle:$_,useInsertionEffect:L_,useLayoutEffect:j_,useMemo:B_,useReducer:ah,useRef:N_,useState:function(){return ah(wa)},useDebugValue:uh,useDeferredValue:function(s){var o=kn();return z_(o,pt.memoizedState,s)},useTransition:function(){var s=ah(wa)[0],o=kn().memoizedState;return[s,o]},useMutableSource:T_,useSyncExternalStore:b_,useId:U_,unstable_isNewReconciler:!1},TF={readContext:xn,useCallback:F_,useContext:xn,useEffect:ch,useImperativeHandle:$_,useInsertionEffect:L_,useLayoutEffect:j_,useMemo:B_,useReducer:lh,useRef:N_,useState:function(){return lh(wa)},useDebugValue:uh,useDeferredValue:function(s){var o=kn();return pt===null?o.memoizedState=s:z_(o,pt.memoizedState,s)},useTransition:function(){var s=lh(wa)[0],o=kn().memoizedState;return[s,o]},useMutableSource:T_,useSyncExternalStore:b_,useId:U_,unstable_isNewReconciler:!1};function $n(s,o){if(s&&s.defaultProps){o=J({},o),s=s.defaultProps;for(var l in s)o[l]===void 0&&(o[l]=s[l]);return o}return o}function dh(s,o,l,u){o=s.memoizedState,l=l(u,o),l=l==null?o:J({},o,l),s.memoizedState=l,s.lanes===0&&(s.updateQueue.baseState=l)}var tu={isMounted:function(s){return(s=s._reactInternals)?$s(s)===s:!1},enqueueSetState:function(s,o,l){s=s._reactInternals;var u=qt(),p=os(s),m=wr(u,p);m.payload=o,l!=null&&(m.callback=l),o=ts(s,m,p),o!==null&&(zn(o,s,p,u),Gc(o,s,p))},enqueueReplaceState:function(s,o,l){s=s._reactInternals;var u=qt(),p=os(s),m=wr(u,p);m.tag=1,m.payload=o,l!=null&&(m.callback=l),o=ts(s,m,p),o!==null&&(zn(o,s,p,u),Gc(o,s,p))},enqueueForceUpdate:function(s,o){s=s._reactInternals;var l=qt(),u=os(s),p=wr(l,u);p.tag=2,o!=null&&(p.callback=o),o=ts(s,p,u),o!==null&&(zn(o,s,u,l),Gc(o,s,u))}};function V_(s,o,l,u,p,m,S){return s=s.stateNode,typeof s.shouldComponentUpdate=="function"?s.shouldComponentUpdate(u,m,S):o.prototype&&o.prototype.isPureReactComponent?!aa(l,u)||!aa(p,m):!0}function G_(s,o,l){var u=!1,p=Jr,m=o.contextType;return typeof m=="object"&&m!==null?m=xn(m):(p=en(o)?Bs:Lt.current,u=o.contextTypes,m=(u=u!=null)?Vo(s,p):Jr),o=new o(l,m),s.memoizedState=o.state!==null&&o.state!==void 0?o.state:null,o.updater=tu,s.stateNode=o,o._reactInternals=s,u&&(s=s.stateNode,s.__reactInternalMemoizedUnmaskedChildContext=p,s.__reactInternalMemoizedMaskedChildContext=m),o}function Y_(s,o,l,u){s=o.state,typeof o.componentWillReceiveProps=="function"&&o.componentWillReceiveProps(l,u),typeof o.UNSAFE_componentWillReceiveProps=="function"&&o.UNSAFE_componentWillReceiveProps(l,u),o.state!==s&&tu.enqueueReplaceState(o,o.state,null)}function fh(s,o,l,u){var p=s.stateNode;p.props=l,p.state=s.memoizedState,p.refs={},Jp(s);var m=o.contextType;typeof m=="object"&&m!==null?p.context=xn(m):(m=en(o)?Bs:Lt.current,p.context=Vo(s,m)),p.state=s.memoizedState,m=o.getDerivedStateFromProps,typeof m=="function"&&(dh(s,o,m,l),p.state=s.memoizedState),typeof o.getDerivedStateFromProps=="function"||typeof p.getSnapshotBeforeUpdate=="function"||typeof p.UNSAFE_componentWillMount!="function"&&typeof p.componentWillMount!="function"||(o=p.state,typeof p.componentWillMount=="function"&&p.componentWillMount(),typeof p.UNSAFE_componentWillMount=="function"&&p.UNSAFE_componentWillMount(),o!==p.state&&tu.enqueueReplaceState(p,p.state,null),Yc(s,l,p,u),p.state=s.memoizedState),typeof p.componentDidMount=="function"&&(s.flags|=4194308)}function ei(s,o){try{var l="",u=o;do l+=Oe(u),u=u.return;while(u);var p=l}catch(m){p=`
Error generating stack: `+m.message+`
`+m.stack}return{value:s,source:o,stack:p,digest:null}}function ph(s,o,l){return{value:s,source:null,stack:l??null,digest:o??null}}function hh(s,o){try{console.error(o.value)}catch(l){setTimeout(function(){throw l})}}var bF=typeof WeakMap=="function"?WeakMap:Map;function K_(s,o,l){l=wr(-1,l),l.tag=3,l.payload={element:null};var u=o.value;return l.callback=function(){lu||(lu=!0,Rh=u),hh(s,o)},l}function Q_(s,o,l){l=wr(-1,l),l.tag=3;var u=s.type.getDerivedStateFromError;if(typeof u=="function"){var p=o.value;l.payload=function(){return u(p)},l.callback=function(){hh(s,o)}}var m=s.stateNode;return m!==null&&typeof m.componentDidCatch=="function"&&(l.callback=function(){hh(s,o),typeof u!="function"&&(rs===null?rs=new Set([this]):rs.add(this));var S=o.stack;this.componentDidCatch(o.value,{componentStack:S!==null?S:""})}),l}function X_(s,o,l){var u=s.pingCache;if(u===null){u=s.pingCache=new bF;var p=new Set;u.set(o,p)}else p=u.get(o),p===void 0&&(p=new Set,u.set(o,p));p.has(l)||(p.add(l),s=BF.bind(null,s,o,l),o.then(s,s))}function J_(s){do{var o;if((o=s.tag===13)&&(o=s.memoizedState,o=o!==null?o.dehydrated!==null:!0),o)return s;s=s.return}while(s!==null);return null}function Z_(s,o,l,u,p){return s.mode&1?(s.flags|=65536,s.lanes=p,s):(s===o?s.flags|=65536:(s.flags|=128,l.flags|=131072,l.flags&=-52805,l.tag===1&&(l.alternate===null?l.tag=17:(o=wr(-1,1),o.tag=2,ts(l,o,1))),l.lanes|=1),s)}var IF=H.ReactCurrentOwner,tn=!1;function Wt(s,o,l,u){o.child=s===null?S_(o,null,l,u):Qo(o,s.child,l,u)}function eE(s,o,l,u,p){l=l.render;var m=o.ref;return Jo(o,p),u=oh(s,o,l,u,m,p),l=ih(),s!==null&&!tn?(o.updateQueue=s.updateQueue,o.flags&=-2053,s.lanes&=~p,_r(s,o,p)):(Ze&&l&&Up(o),o.flags|=1,Wt(s,o,u,p),o.child)}function tE(s,o,l,u,p){if(s===null){var m=l.type;return typeof m=="function"&&!jh(m)&&m.defaultProps===void 0&&l.compare===null&&l.defaultProps===void 0?(o.tag=15,o.type=m,nE(s,o,m,u,p)):(s=hu(l.type,null,u,o,o.mode,p),s.ref=o.ref,s.return=o,o.child=s)}if(m=s.child,!(s.lanes&p)){var S=m.memoizedProps;if(l=l.compare,l=l!==null?l:aa,l(S,u)&&s.ref===o.ref)return _r(s,o,p)}return o.flags|=1,s=as(m,u),s.ref=o.ref,s.return=o,o.child=s}function nE(s,o,l,u,p){if(s!==null){var m=s.memoizedProps;if(aa(m,u)&&s.ref===o.ref)if(tn=!1,o.pendingProps=u=m,(s.lanes&p)!==0)s.flags&131072&&(tn=!0);else return o.lanes=s.lanes,_r(s,o,p)}return mh(s,o,l,u,p)}function rE(s,o,l){var u=o.pendingProps,p=u.children,m=s!==null?s.memoizedState:null;if(u.mode==="hidden")if(!(o.mode&1))o.memoizedState={baseLanes:0,cachePool:null,transitions:null},Qe(ni,hn),hn|=l;else{if(!(l&1073741824))return s=m!==null?m.baseLanes|l:l,o.lanes=o.childLanes=1073741824,o.memoizedState={baseLanes:s,cachePool:null,transitions:null},o.updateQueue=null,Qe(ni,hn),hn|=s,null;o.memoizedState={baseLanes:0,cachePool:null,transitions:null},u=m!==null?m.baseLanes:l,Qe(ni,hn),hn|=u}else m!==null?(u=m.baseLanes|l,o.memoizedState=null):u=l,Qe(ni,hn),hn|=u;return Wt(s,o,p,l),o.child}function sE(s,o){var l=o.ref;(s===null&&l!==null||s!==null&&s.ref!==l)&&(o.flags|=512,o.flags|=2097152)}function mh(s,o,l,u,p){var m=en(l)?Bs:Lt.current;return m=Vo(o,m),Jo(o,p),l=oh(s,o,l,u,m,p),u=ih(),s!==null&&!tn?(o.updateQueue=s.updateQueue,o.flags&=-2053,s.lanes&=~p,_r(s,o,p)):(Ze&&u&&Up(o),o.flags|=1,Wt(s,o,l,p),o.child)}function oE(s,o,l,u,p){if(en(l)){var m=!0;Fc(o)}else m=!1;if(Jo(o,p),o.stateNode===null)ru(s,o),G_(o,l,u),fh(o,l,u,p),u=!0;else if(s===null){var S=o.stateNode,T=o.memoizedProps;S.props=T;var b=S.context,D=l.contextType;typeof D=="object"&&D!==null?D=xn(D):(D=en(l)?Bs:Lt.current,D=Vo(o,D));var G=l.getDerivedStateFromProps,Y=typeof G=="function"||typeof S.getSnapshotBeforeUpdate=="function";Y||typeof S.UNSAFE_componentWillReceiveProps!="function"&&typeof S.componentWillReceiveProps!="function"||(T!==u||b!==D)&&Y_(o,S,u,D),es=!1;var V=o.memoizedState;S.state=V,Yc(o,u,S,p),b=o.memoizedState,T!==u||V!==b||Zt.current||es?(typeof G=="function"&&(dh(o,l,G,u),b=o.memoizedState),(T=es||V_(o,l,T,u,V,b,D))?(Y||typeof S.UNSAFE_componentWillMount!="function"&&typeof S.componentWillMount!="function"||(typeof S.componentWillMount=="function"&&S.componentWillMount(),typeof S.UNSAFE_componentWillMount=="function"&&S.UNSAFE_componentWillMount()),typeof S.componentDidMount=="function"&&(o.flags|=4194308)):(typeof S.componentDidMount=="function"&&(o.flags|=4194308),o.memoizedProps=u,o.memoizedState=b),S.props=u,S.state=b,S.context=D,u=T):(typeof S.componentDidMount=="function"&&(o.flags|=4194308),u=!1)}else{S=o.stateNode,__(s,o),T=o.memoizedProps,D=o.type===o.elementType?T:$n(o.type,T),S.props=D,Y=o.pendingProps,V=S.context,b=l.contextType,typeof b=="object"&&b!==null?b=xn(b):(b=en(l)?Bs:Lt.current,b=Vo(o,b));var ee=l.getDerivedStateFromProps;(G=typeof ee=="function"||typeof S.getSnapshotBeforeUpdate=="function")||typeof S.UNSAFE_componentWillReceiveProps!="function"&&typeof S.componentWillReceiveProps!="function"||(T!==Y||V!==b)&&Y_(o,S,u,b),es=!1,V=o.memoizedState,S.state=V,Yc(o,u,S,p);var se=o.memoizedState;T!==Y||V!==se||Zt.current||es?(typeof ee=="function"&&(dh(o,l,ee,u),se=o.memoizedState),(D=es||V_(o,l,D,u,V,se,b)||!1)?(G||typeof S.UNSAFE_componentWillUpdate!="function"&&typeof S.componentWillUpdate!="function"||(typeof S.componentWillUpdate=="function"&&S.componentWillUpdate(u,se,b),typeof S.UNSAFE_componentWillUpdate=="function"&&S.UNSAFE_componentWillUpdate(u,se,b)),typeof S.componentDidUpdate=="function"&&(o.flags|=4),typeof S.getSnapshotBeforeUpdate=="function"&&(o.flags|=1024)):(typeof S.componentDidUpdate!="function"||T===s.memoizedProps&&V===s.memoizedState||(o.flags|=4),typeof S.getSnapshotBeforeUpdate!="function"||T===s.memoizedProps&&V===s.memoizedState||(o.flags|=1024),o.memoizedProps=u,o.memoizedState=se),S.props=u,S.state=se,S.context=b,u=D):(typeof S.componentDidUpdate!="function"||T===s.memoizedProps&&V===s.memoizedState||(o.flags|=4),typeof S.getSnapshotBeforeUpdate!="function"||T===s.memoizedProps&&V===s.memoizedState||(o.flags|=1024),u=!1)}return gh(s,o,l,u,m,p)}function gh(s,o,l,u,p,m){sE(s,o);var S=(o.flags&128)!==0;if(!u&&!S)return p&&u_(o,l,!1),_r(s,o,m);u=o.stateNode,IF.current=o;var T=S&&typeof l.getDerivedStateFromError!="function"?null:u.render();return o.flags|=1,s!==null&&S?(o.child=Qo(o,s.child,null,m),o.child=Qo(o,null,T,m)):Wt(s,o,T,m),o.memoizedState=u.state,p&&u_(o,l,!0),o.child}function iE(s){var o=s.stateNode;o.pendingContext?l_(s,o.pendingContext,o.pendingContext!==o.context):o.context&&l_(s,o.context,!1),Zp(s,o.containerInfo)}function aE(s,o,l,u,p){return Ko(),Vp(p),o.flags|=256,Wt(s,o,l,u),o.child}var yh={dehydrated:null,treeContext:null,retryLane:0};function vh(s){return{baseLanes:s,cachePool:null,transitions:null}}function lE(s,o,l){var u=o.pendingProps,p=et.current,m=!1,S=(o.flags&128)!==0,T;if((T=S)||(T=s!==null&&s.memoizedState===null?!1:(p&2)!==0),T?(m=!0,o.flags&=-129):(s===null||s.memoizedState!==null)&&(p|=1),Qe(et,p&1),s===null)return qp(o),s=o.memoizedState,s!==null&&(s=s.dehydrated,s!==null)?(o.mode&1?s.data==="$!"?o.lanes=8:o.lanes=1073741824:o.lanes=1,null):(S=u.children,s=u.fallback,m?(u=o.mode,m=o.child,S={mode:"hidden",children:S},!(u&1)&&m!==null?(m.childLanes=0,m.pendingProps=S):m=mu(S,u,0,null),s=Qs(s,u,l,null),m.return=o,s.return=o,m.sibling=s,o.child=m,o.child.memoizedState=vh(l),o.memoizedState=yh,s):Sh(o,S));if(p=s.memoizedState,p!==null&&(T=p.dehydrated,T!==null))return CF(s,o,S,u,T,p,l);if(m){m=u.fallback,S=o.mode,p=s.child,T=p.sibling;var b={mode:"hidden",children:u.children};return!(S&1)&&o.child!==p?(u=o.child,u.childLanes=0,u.pendingProps=b,o.deletions=null):(u=as(p,b),u.subtreeFlags=p.subtreeFlags&14680064),T!==null?m=as(T,m):(m=Qs(m,S,l,null),m.flags|=2),m.return=o,u.return=o,u.sibling=m,o.child=u,u=m,m=o.child,S=s.child.memoizedState,S=S===null?vh(l):{baseLanes:S.baseLanes|l,cachePool:null,transitions:S.transitions},m.memoizedState=S,m.childLanes=s.childLanes&~l,o.memoizedState=yh,u}return m=s.child,s=m.sibling,u=as(m,{mode:"visible",children:u.children}),!(o.mode&1)&&(u.lanes=l),u.return=o,u.sibling=null,s!==null&&(l=o.deletions,l===null?(o.deletions=[s],o.flags|=16):l.push(s)),o.child=u,o.memoizedState=null,u}function Sh(s,o){return o=mu({mode:"visible",children:o},s.mode,0,null),o.return=s,s.child=o}function nu(s,o,l,u){return u!==null&&Vp(u),Qo(o,s.child,null,l),s=Sh(o,o.pendingProps.children),s.flags|=2,o.memoizedState=null,s}function CF(s,o,l,u,p,m,S){if(l)return o.flags&256?(o.flags&=-257,u=ph(Error(n(422))),nu(s,o,S,u)):o.memoizedState!==null?(o.child=s.child,o.flags|=128,null):(m=u.fallback,p=o.mode,u=mu({mode:"visible",children:u.children},p,0,null),m=Qs(m,p,S,null),m.flags|=2,u.return=o,m.return=o,u.sibling=m,o.child=u,o.mode&1&&Qo(o,s.child,null,S),o.child.memoizedState=vh(S),o.memoizedState=yh,m);if(!(o.mode&1))return nu(s,o,S,null);if(p.data==="$!"){if(u=p.nextSibling&&p.nextSibling.dataset,u)var T=u.dgst;return u=T,m=Error(n(419)),u=ph(m,u,void 0),nu(s,o,S,u)}if(T=(S&s.childLanes)!==0,tn||T){if(u=xt,u!==null){switch(S&-S){case 4:p=2;break;case 16:p=8;break;case 64:case 128:case 256:case 512:case 1024:case 2048:case 4096:case 8192:case 16384:case 32768:case 65536:case 131072:case 262144:case 524288:case 1048576:case 2097152:case 4194304:case 8388608:case 16777216:case 33554432:case 67108864:p=32;break;case 536870912:p=268435456;break;default:p=0}p=p&(u.suspendedLanes|S)?0:p,p!==0&&p!==m.retryLane&&(m.retryLane=p,Sr(s,p),zn(u,s,p,-1))}return Lh(),u=ph(Error(n(421))),nu(s,o,S,u)}return p.data==="$?"?(o.flags|=128,o.child=s.child,o=zF.bind(null,s),p._reactRetry=o,null):(s=m.treeContext,pn=Qr(p.nextSibling),fn=o,Ze=!0,Dn=null,s!==null&&(_n[En++]=yr,_n[En++]=vr,_n[En++]=zs,yr=s.id,vr=s.overflow,zs=o),o=Sh(o,u.children),o.flags|=4096,o)}function cE(s,o,l){s.lanes|=o;var u=s.alternate;u!==null&&(u.lanes|=o),Qp(s.return,o,l)}function wh(s,o,l,u,p){var m=s.memoizedState;m===null?s.memoizedState={isBackwards:o,rendering:null,renderingStartTime:0,last:u,tail:l,tailMode:p}:(m.isBackwards=o,m.rendering=null,m.renderingStartTime=0,m.last=u,m.tail=l,m.tailMode=p)}function uE(s,o,l){var u=o.pendingProps,p=u.revealOrder,m=u.tail;if(Wt(s,o,u.children,l),u=et.current,u&2)u=u&1|2,o.flags|=128;else{if(s!==null&&s.flags&128)e:for(s=o.child;s!==null;){if(s.tag===13)s.memoizedState!==null&&cE(s,l,o);else if(s.tag===19)cE(s,l,o);else if(s.child!==null){s.child.return=s,s=s.child;continue}if(s===o)break e;for(;s.sibling===null;){if(s.return===null||s.return===o)break e;s=s.return}s.sibling.return=s.return,s=s.sibling}u&=1}if(Qe(et,u),!(o.mode&1))o.memoizedState=null;else switch(p){case"forwards":for(l=o.child,p=null;l!==null;)s=l.alternate,s!==null&&Kc(s)===null&&(p=l),l=l.sibling;l=p,l===null?(p=o.child,o.child=null):(p=l.sibling,l.sibling=null),wh(o,!1,p,l,m);break;case"backwards":for(l=null,p=o.child,o.child=null;p!==null;){if(s=p.alternate,s!==null&&Kc(s)===null){o.child=p;break}s=p.sibling,p.sibling=l,l=p,p=s}wh(o,!0,l,null,m);break;case"together":wh(o,!1,null,null,void 0);break;default:o.memoizedState=null}return o.child}function ru(s,o){!(o.mode&1)&&s!==null&&(s.alternate=null,o.alternate=null,o.flags|=2)}function _r(s,o,l){if(s!==null&&(o.dependencies=s.dependencies),Vs|=o.lanes,!(l&o.childLanes))return null;if(s!==null&&o.child!==s.child)throw Error(n(153));if(o.child!==null){for(s=o.child,l=as(s,s.pendingProps),o.child=l,l.return=o;s.sibling!==null;)s=s.sibling,l=l.sibling=as(s,s.pendingProps),l.return=o;l.sibling=null}return o.child}function RF(s,o,l){switch(o.tag){case 3:iE(o),Ko();break;case 5:k_(o);break;case 1:en(o.type)&&Fc(o);break;case 4:Zp(o,o.stateNode.containerInfo);break;case 10:var u=o.type._context,p=o.memoizedProps.value;Qe(qc,u._currentValue),u._currentValue=p;break;case 13:if(u=o.memoizedState,u!==null)return u.dehydrated!==null?(Qe(et,et.current&1),o.flags|=128,null):l&o.child.childLanes?lE(s,o,l):(Qe(et,et.current&1),s=_r(s,o,l),s!==null?s.sibling:null);Qe(et,et.current&1);break;case 19:if(u=(l&o.childLanes)!==0,s.flags&128){if(u)return uE(s,o,l);o.flags|=128}if(p=o.memoizedState,p!==null&&(p.rendering=null,p.tail=null,p.lastEffect=null),Qe(et,et.current),u)break;return null;case 22:case 23:return o.lanes=0,rE(s,o,l)}return _r(s,o,l)}var dE,_h,fE,pE;dE=function(s,o){for(var l=o.child;l!==null;){if(l.tag===5||l.tag===6)s.appendChild(l.stateNode);else if(l.tag!==4&&l.child!==null){l.child.return=l,l=l.child;continue}if(l===o)break;for(;l.sibling===null;){if(l.return===null||l.return===o)return;l=l.return}l.sibling.return=l.return,l=l.sibling}},_h=function(){},fE=function(s,o,l,u){var p=s.memoizedProps;if(p!==u){s=o.stateNode,Ws(Zn.current);var m=null;switch(l){case"input":p=Mn(s,p),u=Mn(s,u),m=[];break;case"select":p=J({},p,{value:void 0}),u=J({},u,{value:void 0}),m=[];break;case"textarea":p=Ce(s,p),u=Ce(s,u),m=[];break;default:typeof p.onClick!="function"&&typeof u.onClick=="function"&&(s.onclick=jc)}tp(l,u);var S;l=null;for(D in p)if(!u.hasOwnProperty(D)&&p.hasOwnProperty(D)&&p[D]!=null)if(D==="style"){var T=p[D];for(S in T)T.hasOwnProperty(S)&&(l||(l={}),l[S]="")}else D!=="dangerouslySetInnerHTML"&&D!=="children"&&D!=="suppressContentEditableWarning"&&D!=="suppressHydrationWarning"&&D!=="autoFocus"&&(i.hasOwnProperty(D)?m||(m=[]):(m=m||[]).push(D,null));for(D in u){var b=u[D];if(T=p!=null?p[D]:void 0,u.hasOwnProperty(D)&&b!==T&&(b!=null||T!=null))if(D==="style")if(T){for(S in T)!T.hasOwnProperty(S)||b&&b.hasOwnProperty(S)||(l||(l={}),l[S]="");for(S in b)b.hasOwnProperty(S)&&T[S]!==b[S]&&(l||(l={}),l[S]=b[S])}else l||(m||(m=[]),m.push(D,l)),l=b;else D==="dangerouslySetInnerHTML"?(b=b?b.__html:void 0,T=T?T.__html:void 0,b!=null&&T!==b&&(m=m||[]).push(D,b)):D==="children"?typeof b!="string"&&typeof b!="number"||(m=m||[]).push(D,""+b):D!=="suppressContentEditableWarning"&&D!=="suppressHydrationWarning"&&(i.hasOwnProperty(D)?(b!=null&&D==="onScroll"&&Xe("scroll",s),m||T===b||(m=[])):(m=m||[]).push(D,b))}l&&(m=m||[]).push("style",l);var D=m;(o.updateQueue=D)&&(o.flags|=4)}},pE=function(s,o,l,u){l!==u&&(o.flags|=4)};function Ea(s,o){if(!Ze)switch(s.tailMode){case"hidden":o=s.tail;for(var l=null;o!==null;)o.alternate!==null&&(l=o),o=o.sibling;l===null?s.tail=null:l.sibling=null;break;case"collapsed":l=s.tail;for(var u=null;l!==null;)l.alternate!==null&&(u=l),l=l.sibling;u===null?o||s.tail===null?s.tail=null:s.tail.sibling=null:u.sibling=null}}function Dt(s){var o=s.alternate!==null&&s.alternate.child===s.child,l=0,u=0;if(o)for(var p=s.child;p!==null;)l|=p.lanes|p.childLanes,u|=p.subtreeFlags&14680064,u|=p.flags&14680064,p.return=s,p=p.sibling;else for(p=s.child;p!==null;)l|=p.lanes|p.childLanes,u|=p.subtreeFlags,u|=p.flags,p.return=s,p=p.sibling;return s.subtreeFlags|=u,s.childLanes=l,o}function AF(s,o,l){var u=o.pendingProps;switch(Hp(o),o.tag){case 2:case 16:case 15:case 0:case 11:case 7:case 8:case 12:case 9:case 14:return Dt(o),null;case 1:return en(o.type)&&$c(),Dt(o),null;case 3:return u=o.stateNode,Zo(),Je(Zt),Je(Lt),nh(),u.pendingContext&&(u.context=u.pendingContext,u.pendingContext=null),(s===null||s.child===null)&&(Hc(o)?o.flags|=4:s===null||s.memoizedState.isDehydrated&&!(o.flags&256)||(o.flags|=1024,Dn!==null&&(Ph(Dn),Dn=null))),_h(s,o),Dt(o),null;case 5:eh(o);var p=Ws(ya.current);if(l=o.type,s!==null&&o.stateNode!=null)fE(s,o,l,u,p),s.ref!==o.ref&&(o.flags|=512,o.flags|=2097152);else{if(!u){if(o.stateNode===null)throw Error(n(166));return Dt(o),null}if(s=Ws(Zn.current),Hc(o)){u=o.stateNode,l=o.type;var m=o.memoizedProps;switch(u[Jn]=o,u[fa]=m,s=(o.mode&1)!==0,l){case"dialog":Xe("cancel",u),Xe("close",u);break;case"iframe":case"object":case"embed":Xe("load",u);break;case"video":case"audio":for(p=0;p<ca.length;p++)Xe(ca[p],u);break;case"source":Xe("error",u);break;case"img":case"image":case"link":Xe("error",u),Xe("load",u);break;case"details":Xe("toggle",u);break;case"input":Kn(u,m),Xe("invalid",u);break;case"select":u._wrapperState={wasMultiple:!!m.multiple},Xe("invalid",u);break;case"textarea":Ke(u,m),Xe("invalid",u)}tp(l,m),p=null;for(var S in m)if(m.hasOwnProperty(S)){var T=m[S];S==="children"?typeof T=="string"?u.textContent!==T&&(m.suppressHydrationWarning!==!0&&Lc(u.textContent,T,s),p=["children",T]):typeof T=="number"&&u.textContent!==""+T&&(m.suppressHydrationWarning!==!0&&Lc(u.textContent,T,s),p=["children",""+T]):i.hasOwnProperty(S)&&T!=null&&S==="onScroll"&&Xe("scroll",u)}switch(l){case"input":Ms(u),js(u,m,!0);break;case"textarea":Ms(u),Qn(u);break;case"select":case"option":break;default:typeof m.onClick=="function"&&(u.onclick=jc)}u=p,o.updateQueue=u,u!==null&&(o.flags|=4)}else{S=p.nodeType===9?p:p.ownerDocument,s==="http://www.w3.org/1999/xhtml"&&(s=pc(l)),s==="http://www.w3.org/1999/xhtml"?l==="script"?(s=S.createElement("div"),s.innerHTML="<script><\/script>",s=s.removeChild(s.firstChild)):typeof u.is=="string"?s=S.createElement(l,{is:u.is}):(s=S.createElement(l),l==="select"&&(S=s,u.multiple?S.multiple=!0:u.size&&(S.size=u.size))):s=S.createElementNS(s,l),s[Jn]=o,s[fa]=u,dE(s,o,!1,!1),o.stateNode=s;e:{switch(S=np(l,u),l){case"dialog":Xe("cancel",s),Xe("close",s),p=u;break;case"iframe":case"object":case"embed":Xe("load",s),p=u;break;case"video":case"audio":for(p=0;p<ca.length;p++)Xe(ca[p],s);p=u;break;case"source":Xe("error",s),p=u;break;case"img":case"image":case"link":Xe("error",s),Xe("load",s),p=u;break;case"details":Xe("toggle",s),p=u;break;case"input":Kn(s,u),p=Mn(s,u),Xe("invalid",s);break;case"option":p=u;break;case"select":s._wrapperState={wasMultiple:!!u.multiple},p=J({},u,{value:void 0}),Xe("invalid",s);break;case"textarea":Ke(s,u),p=Ce(s,u),Xe("invalid",s);break;default:p=u}tp(l,p),T=p;for(m in T)if(T.hasOwnProperty(m)){var b=T[m];m==="style"?nw(s,b):m==="dangerouslySetInnerHTML"?(b=b?b.__html:void 0,b!=null&&ew(s,b)):m==="children"?typeof b=="string"?(l!=="textarea"||b!=="")&&Wi(s,b):typeof b=="number"&&Wi(s,""+b):m!=="suppressContentEditableWarning"&&m!=="suppressHydrationWarning"&&m!=="autoFocus"&&(i.hasOwnProperty(m)?b!=null&&m==="onScroll"&&Xe("scroll",s):b!=null&&$(s,m,b,S))}switch(l){case"input":Ms(s),js(s,u,!1);break;case"textarea":Ms(s),Qn(s);break;case"option":u.value!=null&&s.setAttribute("value",""+De(u.value));break;case"select":s.multiple=!!u.multiple,m=u.value,m!=null?_t(s,!!u.multiple,m,!1):u.defaultValue!=null&&_t(s,!!u.multiple,u.defaultValue,!0);break;default:typeof p.onClick=="function"&&(s.onclick=jc)}switch(l){case"button":case"input":case"select":case"textarea":u=!!u.autoFocus;break e;case"img":u=!0;break e;default:u=!1}}u&&(o.flags|=4)}o.ref!==null&&(o.flags|=512,o.flags|=2097152)}return Dt(o),null;case 6:if(s&&o.stateNode!=null)pE(s,o,s.memoizedProps,u);else{if(typeof u!="string"&&o.stateNode===null)throw Error(n(166));if(l=Ws(ya.current),Ws(Zn.current),Hc(o)){if(u=o.stateNode,l=o.memoizedProps,u[Jn]=o,(m=u.nodeValue!==l)&&(s=fn,s!==null))switch(s.tag){case 3:Lc(u.nodeValue,l,(s.mode&1)!==0);break;case 5:s.memoizedProps.suppressHydrationWarning!==!0&&Lc(u.nodeValue,l,(s.mode&1)!==0)}m&&(o.flags|=4)}else u=(l.nodeType===9?l:l.ownerDocument).createTextNode(u),u[Jn]=o,o.stateNode=u}return Dt(o),null;case 13:if(Je(et),u=o.memoizedState,s===null||s.memoizedState!==null&&s.memoizedState.dehydrated!==null){if(Ze&&pn!==null&&o.mode&1&&!(o.flags&128))g_(),Ko(),o.flags|=98560,m=!1;else if(m=Hc(o),u!==null&&u.dehydrated!==null){if(s===null){if(!m)throw Error(n(318));if(m=o.memoizedState,m=m!==null?m.dehydrated:null,!m)throw Error(n(317));m[Jn]=o}else Ko(),!(o.flags&128)&&(o.memoizedState=null),o.flags|=4;Dt(o),m=!1}else Dn!==null&&(Ph(Dn),Dn=null),m=!0;if(!m)return o.flags&65536?o:null}return o.flags&128?(o.lanes=l,o):(u=u!==null,u!==(s!==null&&s.memoizedState!==null)&&u&&(o.child.flags|=8192,o.mode&1&&(s===null||et.current&1?ht===0&&(ht=3):Lh())),o.updateQueue!==null&&(o.flags|=4),Dt(o),null);case 4:return Zo(),_h(s,o),s===null&&ua(o.stateNode.containerInfo),Dt(o),null;case 10:return Kp(o.type._context),Dt(o),null;case 17:return en(o.type)&&$c(),Dt(o),null;case 19:if(Je(et),m=o.memoizedState,m===null)return Dt(o),null;if(u=(o.flags&128)!==0,S=m.rendering,S===null)if(u)Ea(m,!1);else{if(ht!==0||s!==null&&s.flags&128)for(s=o.child;s!==null;){if(S=Kc(s),S!==null){for(o.flags|=128,Ea(m,!1),u=S.updateQueue,u!==null&&(o.updateQueue=u,o.flags|=4),o.subtreeFlags=0,u=l,l=o.child;l!==null;)m=l,s=u,m.flags&=14680066,S=m.alternate,S===null?(m.childLanes=0,m.lanes=s,m.child=null,m.subtreeFlags=0,m.memoizedProps=null,m.memoizedState=null,m.updateQueue=null,m.dependencies=null,m.stateNode=null):(m.childLanes=S.childLanes,m.lanes=S.lanes,m.child=S.child,m.subtreeFlags=0,m.deletions=null,m.memoizedProps=S.memoizedProps,m.memoizedState=S.memoizedState,m.updateQueue=S.updateQueue,m.type=S.type,s=S.dependencies,m.dependencies=s===null?null:{lanes:s.lanes,firstContext:s.firstContext}),l=l.sibling;return Qe(et,et.current&1|2),o.child}s=s.sibling}m.tail!==null&&at()>ri&&(o.flags|=128,u=!0,Ea(m,!1),o.lanes=4194304)}else{if(!u)if(s=Kc(S),s!==null){if(o.flags|=128,u=!0,l=s.updateQueue,l!==null&&(o.updateQueue=l,o.flags|=4),Ea(m,!0),m.tail===null&&m.tailMode==="hidden"&&!S.alternate&&!Ze)return Dt(o),null}else 2*at()-m.renderingStartTime>ri&&l!==1073741824&&(o.flags|=128,u=!0,Ea(m,!1),o.lanes=4194304);m.isBackwards?(S.sibling=o.child,o.child=S):(l=m.last,l!==null?l.sibling=S:o.child=S,m.last=S)}return m.tail!==null?(o=m.tail,m.rendering=o,m.tail=o.sibling,m.renderingStartTime=at(),o.sibling=null,l=et.current,Qe(et,u?l&1|2:l&1),o):(Dt(o),null);case 22:case 23:return Mh(),u=o.memoizedState!==null,s!==null&&s.memoizedState!==null!==u&&(o.flags|=8192),u&&o.mode&1?hn&1073741824&&(Dt(o),o.subtreeFlags&6&&(o.flags|=8192)):Dt(o),null;case 24:return null;case 25:return null}throw Error(n(156,o.tag))}function OF(s,o){switch(Hp(o),o.tag){case 1:return en(o.type)&&$c(),s=o.flags,s&65536?(o.flags=s&-65537|128,o):null;case 3:return Zo(),Je(Zt),Je(Lt),nh(),s=o.flags,s&65536&&!(s&128)?(o.flags=s&-65537|128,o):null;case 5:return eh(o),null;case 13:if(Je(et),s=o.memoizedState,s!==null&&s.dehydrated!==null){if(o.alternate===null)throw Error(n(340));Ko()}return s=o.flags,s&65536?(o.flags=s&-65537|128,o):null;case 19:return Je(et),null;case 4:return Zo(),null;case 10:return Kp(o.type._context),null;case 22:case 23:return Mh(),null;case 24:return null;default:return null}}var su=!1,$t=!1,PF=typeof WeakSet=="function"?WeakSet:Set,ne=null;function ti(s,o){var l=s.ref;if(l!==null)if(typeof l=="function")try{l(null)}catch(u){rt(s,o,u)}else l.current=null}function Eh(s,o,l){try{l()}catch(u){rt(s,o,u)}}var hE=!1;function NF(s,o){if(Mp=kc,s=Vw(),bp(s)){if("selectionStart"in s)var l={start:s.selectionStart,end:s.selectionEnd};else e:{l=(l=s.ownerDocument)&&l.defaultView||window;var u=l.getSelection&&l.getSelection();if(u&&u.rangeCount!==0){l=u.anchorNode;var p=u.anchorOffset,m=u.focusNode;u=u.focusOffset;try{l.nodeType,m.nodeType}catch{l=null;break e}var S=0,T=-1,b=-1,D=0,G=0,Y=s,V=null;t:for(;;){for(var ee;Y!==l||p!==0&&Y.nodeType!==3||(T=S+p),Y!==m||u!==0&&Y.nodeType!==3||(b=S+u),Y.nodeType===3&&(S+=Y.nodeValue.length),(ee=Y.firstChild)!==null;)V=Y,Y=ee;for(;;){if(Y===s)break t;if(V===l&&++D===p&&(T=S),V===m&&++G===u&&(b=S),(ee=Y.nextSibling)!==null)break;Y=V,V=Y.parentNode}Y=ee}l=T===-1||b===-1?null:{start:T,end:b}}else l=null}l=l||{start:0,end:0}}else l=null;for(Lp={focusedElem:s,selectionRange:l},kc=!1,ne=o;ne!==null;)if(o=ne,s=o.child,(o.subtreeFlags&1028)!==0&&s!==null)s.return=o,ne=s;else for(;ne!==null;){o=ne;try{var se=o.alternate;if(o.flags&1024)switch(o.tag){case 0:case 11:case 15:break;case 1:if(se!==null){var ie=se.memoizedProps,lt=se.memoizedState,P=o.stateNode,I=P.getSnapshotBeforeUpdate(o.elementType===o.type?ie:$n(o.type,ie),lt);P.__reactInternalSnapshotBeforeUpdate=I}break;case 3:var N=o.stateNode.containerInfo;N.nodeType===1?N.textContent="":N.nodeType===9&&N.documentElement&&N.removeChild(N.documentElement);break;case 5:case 6:case 4:case 17:break;default:throw Error(n(163))}}catch(Q){rt(o,o.return,Q)}if(s=o.sibling,s!==null){s.return=o.return,ne=s;break}ne=o.return}return se=hE,hE=!1,se}function xa(s,o,l){var u=o.updateQueue;if(u=u!==null?u.lastEffect:null,u!==null){var p=u=u.next;do{if((p.tag&s)===s){var m=p.destroy;p.destroy=void 0,m!==void 0&&Eh(o,l,m)}p=p.next}while(p!==u)}}function ou(s,o){if(o=o.updateQueue,o=o!==null?o.lastEffect:null,o!==null){var l=o=o.next;do{if((l.tag&s)===s){var u=l.create;l.destroy=u()}l=l.next}while(l!==o)}}function xh(s){var o=s.ref;if(o!==null){var l=s.stateNode;switch(s.tag){case 5:s=l;break;default:s=l}typeof o=="function"?o(s):o.current=s}}function mE(s){var o=s.alternate;o!==null&&(s.alternate=null,mE(o)),s.child=null,s.deletions=null,s.sibling=null,s.tag===5&&(o=s.stateNode,o!==null&&(delete o[Jn],delete o[fa],delete o[Fp],delete o[mF],delete o[gF])),s.stateNode=null,s.return=null,s.dependencies=null,s.memoizedProps=null,s.memoizedState=null,s.pendingProps=null,s.stateNode=null,s.updateQueue=null}function gE(s){return s.tag===5||s.tag===3||s.tag===4}function yE(s){e:for(;;){for(;s.sibling===null;){if(s.return===null||gE(s.return))return null;s=s.return}for(s.sibling.return=s.return,s=s.sibling;s.tag!==5&&s.tag!==6&&s.tag!==18;){if(s.flags&2||s.child===null||s.tag===4)continue e;s.child.return=s,s=s.child}if(!(s.flags&2))return s.stateNode}}function kh(s,o,l){var u=s.tag;if(u===5||u===6)s=s.stateNode,o?l.nodeType===8?l.parentNode.insertBefore(s,o):l.insertBefore(s,o):(l.nodeType===8?(o=l.parentNode,o.insertBefore(s,l)):(o=l,o.appendChild(s)),l=l._reactRootContainer,l!=null||o.onclick!==null||(o.onclick=jc));else if(u!==4&&(s=s.child,s!==null))for(kh(s,o,l),s=s.sibling;s!==null;)kh(s,o,l),s=s.sibling}function Th(s,o,l){var u=s.tag;if(u===5||u===6)s=s.stateNode,o?l.insertBefore(s,o):l.appendChild(s);else if(u!==4&&(s=s.child,s!==null))for(Th(s,o,l),s=s.sibling;s!==null;)Th(s,o,l),s=s.sibling}var At=null,Fn=!1;function ns(s,o,l){for(l=l.child;l!==null;)vE(s,o,l),l=l.sibling}function vE(s,o,l){if(Xn&&typeof Xn.onCommitFiberUnmount=="function")try{Xn.onCommitFiberUnmount(vc,l)}catch{}switch(l.tag){case 5:$t||ti(l,o);case 6:var u=At,p=Fn;At=null,ns(s,o,l),At=u,Fn=p,At!==null&&(Fn?(s=At,l=l.stateNode,s.nodeType===8?s.parentNode.removeChild(l):s.removeChild(l)):At.removeChild(l.stateNode));break;case 18:At!==null&&(Fn?(s=At,l=l.stateNode,s.nodeType===8?$p(s.parentNode,l):s.nodeType===1&&$p(s,l),ta(s)):$p(At,l.stateNode));break;case 4:u=At,p=Fn,At=l.stateNode.containerInfo,Fn=!0,ns(s,o,l),At=u,Fn=p;break;case 0:case 11:case 14:case 15:if(!$t&&(u=l.updateQueue,u!==null&&(u=u.lastEffect,u!==null))){p=u=u.next;do{var m=p,S=m.destroy;m=m.tag,S!==void 0&&(m&2||m&4)&&Eh(l,o,S),p=p.next}while(p!==u)}ns(s,o,l);break;case 1:if(!$t&&(ti(l,o),u=l.stateNode,typeof u.componentWillUnmount=="function"))try{u.props=l.memoizedProps,u.state=l.memoizedState,u.componentWillUnmount()}catch(T){rt(l,o,T)}ns(s,o,l);break;case 21:ns(s,o,l);break;case 22:l.mode&1?($t=(u=$t)||l.memoizedState!==null,ns(s,o,l),$t=u):ns(s,o,l);break;default:ns(s,o,l)}}function SE(s){var o=s.updateQueue;if(o!==null){s.updateQueue=null;var l=s.stateNode;l===null&&(l=s.stateNode=new PF),o.forEach(function(u){var p=UF.bind(null,s,u);l.has(u)||(l.add(u),u.then(p,p))})}}function Bn(s,o){var l=o.deletions;if(l!==null)for(var u=0;u<l.length;u++){var p=l[u];try{var m=s,S=o,T=S;e:for(;T!==null;){switch(T.tag){case 5:At=T.stateNode,Fn=!1;break e;case 3:At=T.stateNode.containerInfo,Fn=!0;break e;case 4:At=T.stateNode.containerInfo,Fn=!0;break e}T=T.return}if(At===null)throw Error(n(160));vE(m,S,p),At=null,Fn=!1;var b=p.alternate;b!==null&&(b.return=null),p.return=null}catch(D){rt(p,o,D)}}if(o.subtreeFlags&12854)for(o=o.child;o!==null;)wE(o,s),o=o.sibling}function wE(s,o){var l=s.alternate,u=s.flags;switch(s.tag){case 0:case 11:case 14:case 15:if(Bn(o,s),tr(s),u&4){try{xa(3,s,s.return),ou(3,s)}catch(ie){rt(s,s.return,ie)}try{xa(5,s,s.return)}catch(ie){rt(s,s.return,ie)}}break;case 1:Bn(o,s),tr(s),u&512&&l!==null&&ti(l,l.return);break;case 5:if(Bn(o,s),tr(s),u&512&&l!==null&&ti(l,l.return),s.flags&32){var p=s.stateNode;try{Wi(p,"")}catch(ie){rt(s,s.return,ie)}}if(u&4&&(p=s.stateNode,p!=null)){var m=s.memoizedProps,S=l!==null?l.memoizedProps:m,T=s.type,b=s.updateQueue;if(s.updateQueue=null,b!==null)try{T==="input"&&m.type==="radio"&&m.name!=null&&Mo(p,m),np(T,S);var D=np(T,m);for(S=0;S<b.length;S+=2){var G=b[S],Y=b[S+1];G==="style"?nw(p,Y):G==="dangerouslySetInnerHTML"?ew(p,Y):G==="children"?Wi(p,Y):$(p,G,Y,D)}switch(T){case"input":Ls(p,m);break;case"textarea":je(p,m);break;case"select":var V=p._wrapperState.wasMultiple;p._wrapperState.wasMultiple=!!m.multiple;var ee=m.value;ee!=null?_t(p,!!m.multiple,ee,!1):V!==!!m.multiple&&(m.defaultValue!=null?_t(p,!!m.multiple,m.defaultValue,!0):_t(p,!!m.multiple,m.multiple?[]:"",!1))}p[fa]=m}catch(ie){rt(s,s.return,ie)}}break;case 6:if(Bn(o,s),tr(s),u&4){if(s.stateNode===null)throw Error(n(162));p=s.stateNode,m=s.memoizedProps;try{p.nodeValue=m}catch(ie){rt(s,s.return,ie)}}break;case 3:if(Bn(o,s),tr(s),u&4&&l!==null&&l.memoizedState.isDehydrated)try{ta(o.containerInfo)}catch(ie){rt(s,s.return,ie)}break;case 4:Bn(o,s),tr(s);break;case 13:Bn(o,s),tr(s),p=s.child,p.flags&8192&&(m=p.memoizedState!==null,p.stateNode.isHidden=m,!m||p.alternate!==null&&p.alternate.memoizedState!==null||(Ch=at())),u&4&&SE(s);break;case 22:if(G=l!==null&&l.memoizedState!==null,s.mode&1?($t=(D=$t)||G,Bn(o,s),$t=D):Bn(o,s),tr(s),u&8192){if(D=s.memoizedState!==null,(s.stateNode.isHidden=D)&&!G&&s.mode&1)for(ne=s,G=s.child;G!==null;){for(Y=ne=G;ne!==null;){switch(V=ne,ee=V.child,V.tag){case 0:case 11:case 14:case 15:xa(4,V,V.return);break;case 1:ti(V,V.return);var se=V.stateNode;if(typeof se.componentWillUnmount=="function"){u=V,l=V.return;try{o=u,se.props=o.memoizedProps,se.state=o.memoizedState,se.componentWillUnmount()}catch(ie){rt(u,l,ie)}}break;case 5:ti(V,V.return);break;case 22:if(V.memoizedState!==null){xE(Y);continue}}ee!==null?(ee.return=V,ne=ee):xE(Y)}G=G.sibling}e:for(G=null,Y=s;;){if(Y.tag===5){if(G===null){G=Y;try{p=Y.stateNode,D?(m=p.style,typeof m.setProperty=="function"?m.setProperty("display","none","important"):m.display="none"):(T=Y.stateNode,b=Y.memoizedProps.style,S=b!=null&&b.hasOwnProperty("display")?b.display:null,T.style.display=tw("display",S))}catch(ie){rt(s,s.return,ie)}}}else if(Y.tag===6){if(G===null)try{Y.stateNode.nodeValue=D?"":Y.memoizedProps}catch(ie){rt(s,s.return,ie)}}else if((Y.tag!==22&&Y.tag!==23||Y.memoizedState===null||Y===s)&&Y.child!==null){Y.child.return=Y,Y=Y.child;continue}if(Y===s)break e;for(;Y.sibling===null;){if(Y.return===null||Y.return===s)break e;G===Y&&(G=null),Y=Y.return}G===Y&&(G=null),Y.sibling.return=Y.return,Y=Y.sibling}}break;case 19:Bn(o,s),tr(s),u&4&&SE(s);break;case 21:break;default:Bn(o,s),tr(s)}}function tr(s){var o=s.flags;if(o&2){try{e:{for(var l=s.return;l!==null;){if(gE(l)){var u=l;break e}l=l.return}throw Error(n(160))}switch(u.tag){case 5:var p=u.stateNode;u.flags&32&&(Wi(p,""),u.flags&=-33);var m=yE(s);Th(s,m,p);break;case 3:case 4:var S=u.stateNode.containerInfo,T=yE(s);kh(s,T,S);break;default:throw Error(n(161))}}catch(b){rt(s,s.return,b)}s.flags&=-3}o&4096&&(s.flags&=-4097)}function MF(s,o,l){ne=s,_E(s)}function _E(s,o,l){for(var u=(s.mode&1)!==0;ne!==null;){var p=ne,m=p.child;if(p.tag===22&&u){var S=p.memoizedState!==null||su;if(!S){var T=p.alternate,b=T!==null&&T.memoizedState!==null||$t;T=su;var D=$t;if(su=S,($t=b)&&!D)for(ne=p;ne!==null;)S=ne,b=S.child,S.tag===22&&S.memoizedState!==null?kE(p):b!==null?(b.return=S,ne=b):kE(p);for(;m!==null;)ne=m,_E(m),m=m.sibling;ne=p,su=T,$t=D}EE(s)}else p.subtreeFlags&8772&&m!==null?(m.return=p,ne=m):EE(s)}}function EE(s){for(;ne!==null;){var o=ne;if(o.flags&8772){var l=o.alternate;try{if(o.flags&8772)switch(o.tag){case 0:case 11:case 15:$t||ou(5,o);break;case 1:var u=o.stateNode;if(o.flags&4&&!$t)if(l===null)u.componentDidMount();else{var p=o.elementType===o.type?l.memoizedProps:$n(o.type,l.memoizedProps);u.componentDidUpdate(p,l.memoizedState,u.__reactInternalSnapshotBeforeUpdate)}var m=o.updateQueue;m!==null&&x_(o,m,u);break;case 3:var S=o.updateQueue;if(S!==null){if(l=null,o.child!==null)switch(o.child.tag){case 5:l=o.child.stateNode;break;case 1:l=o.child.stateNode}x_(o,S,l)}break;case 5:var T=o.stateNode;if(l===null&&o.flags&4){l=T;var b=o.memoizedProps;switch(o.type){case"button":case"input":case"select":case"textarea":b.autoFocus&&l.focus();break;case"img":b.src&&(l.src=b.src)}}break;case 6:break;case 4:break;case 12:break;case 13:if(o.memoizedState===null){var D=o.alternate;if(D!==null){var G=D.memoizedState;if(G!==null){var Y=G.dehydrated;Y!==null&&ta(Y)}}}break;case 19:case 17:case 21:case 22:case 23:case 25:break;default:throw Error(n(163))}$t||o.flags&512&&xh(o)}catch(V){rt(o,o.return,V)}}if(o===s){ne=null;break}if(l=o.sibling,l!==null){l.return=o.return,ne=l;break}ne=o.return}}function xE(s){for(;ne!==null;){var o=ne;if(o===s){ne=null;break}var l=o.sibling;if(l!==null){l.return=o.return,ne=l;break}ne=o.return}}function kE(s){for(;ne!==null;){var o=ne;try{switch(o.tag){case 0:case 11:case 15:var l=o.return;try{ou(4,o)}catch(b){rt(o,l,b)}break;case 1:var u=o.stateNode;if(typeof u.componentDidMount=="function"){var p=o.return;try{u.componentDidMount()}catch(b){rt(o,p,b)}}var m=o.return;try{xh(o)}catch(b){rt(o,m,b)}break;case 5:var S=o.return;try{xh(o)}catch(b){rt(o,S,b)}}}catch(b){rt(o,o.return,b)}if(o===s){ne=null;break}var T=o.sibling;if(T!==null){T.return=o.return,ne=T;break}ne=o.return}}var LF=Math.ceil,iu=H.ReactCurrentDispatcher,bh=H.ReactCurrentOwner,Tn=H.ReactCurrentBatchConfig,$e=0,xt=null,ct=null,Ot=0,hn=0,ni=Xr(0),ht=0,ka=null,Vs=0,au=0,Ih=0,Ta=null,nn=null,Ch=0,ri=1/0,Er=null,lu=!1,Rh=null,rs=null,cu=!1,ss=null,uu=0,ba=0,Ah=null,du=-1,fu=0;function qt(){return $e&6?at():du!==-1?du:du=at()}function os(s){return s.mode&1?$e&2&&Ot!==0?Ot&-Ot:vF.transition!==null?(fu===0&&(fu=yw()),fu):(s=Ue,s!==0||(s=window.event,s=s===void 0?16:bw(s.type)),s):1}function zn(s,o,l,u){if(50<ba)throw ba=0,Ah=null,Error(n(185));Qi(s,l,u),(!($e&2)||s!==xt)&&(s===xt&&(!($e&2)&&(au|=l),ht===4&&is(s,Ot)),rn(s,u),l===1&&$e===0&&!(o.mode&1)&&(ri=at()+500,Bc&&Zr()))}function rn(s,o){var l=s.callbackNode;v8(s,o);var u=_c(s,s===xt?Ot:0);if(u===0)l!==null&&hw(l),s.callbackNode=null,s.callbackPriority=0;else if(o=u&-u,s.callbackPriority!==o){if(l!=null&&hw(l),o===1)s.tag===0?yF(bE.bind(null,s)):d_(bE.bind(null,s)),pF(function(){!($e&6)&&Zr()}),l=null;else{switch(vw(u)){case 1:l=cp;break;case 4:l=mw;break;case 16:l=yc;break;case 536870912:l=gw;break;default:l=yc}l=ME(l,TE.bind(null,s))}s.callbackPriority=o,s.callbackNode=l}}function TE(s,o){if(du=-1,fu=0,$e&6)throw Error(n(327));var l=s.callbackNode;if(si()&&s.callbackNode!==l)return null;var u=_c(s,s===xt?Ot:0);if(u===0)return null;if(u&30||u&s.expiredLanes||o)o=pu(s,u);else{o=u;var p=$e;$e|=2;var m=CE();(xt!==s||Ot!==o)&&(Er=null,ri=at()+500,Ys(s,o));do try{$F();break}catch(T){IE(s,T)}while(!0);Yp(),iu.current=m,$e=p,ct!==null?o=0:(xt=null,Ot=0,o=ht)}if(o!==0){if(o===2&&(p=up(s),p!==0&&(u=p,o=Oh(s,p))),o===1)throw l=ka,Ys(s,0),is(s,u),rn(s,at()),l;if(o===6)is(s,u);else{if(p=s.current.alternate,!(u&30)&&!jF(p)&&(o=pu(s,u),o===2&&(m=up(s),m!==0&&(u=m,o=Oh(s,m))),o===1))throw l=ka,Ys(s,0),is(s,u),rn(s,at()),l;switch(s.finishedWork=p,s.finishedLanes=u,o){case 0:case 1:throw Error(n(345));case 2:Ks(s,nn,Er);break;case 3:if(is(s,u),(u&130023424)===u&&(o=Ch+500-at(),10<o)){if(_c(s,0)!==0)break;if(p=s.suspendedLanes,(p&u)!==u){qt(),s.pingedLanes|=s.suspendedLanes&p;break}s.timeoutHandle=Dp(Ks.bind(null,s,nn,Er),o);break}Ks(s,nn,Er);break;case 4:if(is(s,u),(u&4194240)===u)break;for(o=s.eventTimes,p=-1;0<u;){var S=31-Ln(u);m=1<<S,S=o[S],S>p&&(p=S),u&=~m}if(u=p,u=at()-u,u=(120>u?120:480>u?480:1080>u?1080:1920>u?1920:3e3>u?3e3:4320>u?4320:1960*LF(u/1960))-u,10<u){s.timeoutHandle=Dp(Ks.bind(null,s,nn,Er),u);break}Ks(s,nn,Er);break;case 5:Ks(s,nn,Er);break;default:throw Error(n(329))}}}return rn(s,at()),s.callbackNode===l?TE.bind(null,s):null}function Oh(s,o){var l=Ta;return s.current.memoizedState.isDehydrated&&(Ys(s,o).flags|=256),s=pu(s,o),s!==2&&(o=nn,nn=l,o!==null&&Ph(o)),s}function Ph(s){nn===null?nn=s:nn.push.apply(nn,s)}function jF(s){for(var o=s;;){if(o.flags&16384){var l=o.updateQueue;if(l!==null&&(l=l.stores,l!==null))for(var u=0;u<l.length;u++){var p=l[u],m=p.getSnapshot;p=p.value;try{if(!jn(m(),p))return!1}catch{return!1}}}if(l=o.child,o.subtreeFlags&16384&&l!==null)l.return=o,o=l;else{if(o===s)break;for(;o.sibling===null;){if(o.return===null||o.return===s)return!0;o=o.return}o.sibling.return=o.return,o=o.sibling}}return!0}function is(s,o){for(o&=~Ih,o&=~au,s.suspendedLanes|=o,s.pingedLanes&=~o,s=s.expirationTimes;0<o;){var l=31-Ln(o),u=1<<l;s[l]=-1,o&=~u}}function bE(s){if($e&6)throw Error(n(327));si();var o=_c(s,0);if(!(o&1))return rn(s,at()),null;var l=pu(s,o);if(s.tag!==0&&l===2){var u=up(s);u!==0&&(o=u,l=Oh(s,u))}if(l===1)throw l=ka,Ys(s,0),is(s,o),rn(s,at()),l;if(l===6)throw Error(n(345));return s.finishedWork=s.current.alternate,s.finishedLanes=o,Ks(s,nn,Er),rn(s,at()),null}function Nh(s,o){var l=$e;$e|=1;try{return s(o)}finally{$e=l,$e===0&&(ri=at()+500,Bc&&Zr())}}function Gs(s){ss!==null&&ss.tag===0&&!($e&6)&&si();var o=$e;$e|=1;var l=Tn.transition,u=Ue;try{if(Tn.transition=null,Ue=1,s)return s()}finally{Ue=u,Tn.transition=l,$e=o,!($e&6)&&Zr()}}function Mh(){hn=ni.current,Je(ni)}function Ys(s,o){s.finishedWork=null,s.finishedLanes=0;var l=s.timeoutHandle;if(l!==-1&&(s.timeoutHandle=-1,fF(l)),ct!==null)for(l=ct.return;l!==null;){var u=l;switch(Hp(u),u.tag){case 1:u=u.type.childContextTypes,u!=null&&$c();break;case 3:Zo(),Je(Zt),Je(Lt),nh();break;case 5:eh(u);break;case 4:Zo();break;case 13:Je(et);break;case 19:Je(et);break;case 10:Kp(u.type._context);break;case 22:case 23:Mh()}l=l.return}if(xt=s,ct=s=as(s.current,null),Ot=hn=o,ht=0,ka=null,Ih=au=Vs=0,nn=Ta=null,Hs!==null){for(o=0;o<Hs.length;o++)if(l=Hs[o],u=l.interleaved,u!==null){l.interleaved=null;var p=u.next,m=l.pending;if(m!==null){var S=m.next;m.next=p,u.next=S}l.pending=u}Hs=null}return s}function IE(s,o){do{var l=ct;try{if(Yp(),Qc.current=eu,Xc){for(var u=tt.memoizedState;u!==null;){var p=u.queue;p!==null&&(p.pending=null),u=u.next}Xc=!1}if(qs=0,Et=pt=tt=null,va=!1,Sa=0,bh.current=null,l===null||l.return===null){ht=1,ka=o,ct=null;break}e:{var m=s,S=l.return,T=l,b=o;if(o=Ot,T.flags|=32768,b!==null&&typeof b=="object"&&typeof b.then=="function"){var D=b,G=T,Y=G.tag;if(!(G.mode&1)&&(Y===0||Y===11||Y===15)){var V=G.alternate;V?(G.updateQueue=V.updateQueue,G.memoizedState=V.memoizedState,G.lanes=V.lanes):(G.updateQueue=null,G.memoizedState=null)}var ee=J_(S);if(ee!==null){ee.flags&=-257,Z_(ee,S,T,m,o),ee.mode&1&&X_(m,D,o),o=ee,b=D;var se=o.updateQueue;if(se===null){var ie=new Set;ie.add(b),o.updateQueue=ie}else se.add(b);break e}else{if(!(o&1)){X_(m,D,o),Lh();break e}b=Error(n(426))}}else if(Ze&&T.mode&1){var lt=J_(S);if(lt!==null){!(lt.flags&65536)&&(lt.flags|=256),Z_(lt,S,T,m,o),Vp(ei(b,T));break e}}m=b=ei(b,T),ht!==4&&(ht=2),Ta===null?Ta=[m]:Ta.push(m),m=S;do{switch(m.tag){case 3:m.flags|=65536,o&=-o,m.lanes|=o;var P=K_(m,b,o);E_(m,P);break e;case 1:T=b;var I=m.type,N=m.stateNode;if(!(m.flags&128)&&(typeof I.getDerivedStateFromError=="function"||N!==null&&typeof N.componentDidCatch=="function"&&(rs===null||!rs.has(N)))){m.flags|=65536,o&=-o,m.lanes|=o;var Q=Q_(m,T,o);E_(m,Q);break e}}m=m.return}while(m!==null)}AE(l)}catch(le){o=le,ct===l&&l!==null&&(ct=l=l.return);continue}break}while(!0)}function CE(){var s=iu.current;return iu.current=eu,s===null?eu:s}function Lh(){(ht===0||ht===3||ht===2)&&(ht=4),xt===null||!(Vs&268435455)&&!(au&268435455)||is(xt,Ot)}function pu(s,o){var l=$e;$e|=2;var u=CE();(xt!==s||Ot!==o)&&(Er=null,Ys(s,o));do try{DF();break}catch(p){IE(s,p)}while(!0);if(Yp(),$e=l,iu.current=u,ct!==null)throw Error(n(261));return xt=null,Ot=0,ht}function DF(){for(;ct!==null;)RE(ct)}function $F(){for(;ct!==null&&!c8();)RE(ct)}function RE(s){var o=NE(s.alternate,s,hn);s.memoizedProps=s.pendingProps,o===null?AE(s):ct=o,bh.current=null}function AE(s){var o=s;do{var l=o.alternate;if(s=o.return,o.flags&32768){if(l=OF(l,o),l!==null){l.flags&=32767,ct=l;return}if(s!==null)s.flags|=32768,s.subtreeFlags=0,s.deletions=null;else{ht=6,ct=null;return}}else if(l=AF(l,o,hn),l!==null){ct=l;return}if(o=o.sibling,o!==null){ct=o;return}ct=o=s}while(o!==null);ht===0&&(ht=5)}function Ks(s,o,l){var u=Ue,p=Tn.transition;try{Tn.transition=null,Ue=1,FF(s,o,l,u)}finally{Tn.transition=p,Ue=u}return null}function FF(s,o,l,u){do si();while(ss!==null);if($e&6)throw Error(n(327));l=s.finishedWork;var p=s.finishedLanes;if(l===null)return null;if(s.finishedWork=null,s.finishedLanes=0,l===s.current)throw Error(n(177));s.callbackNode=null,s.callbackPriority=0;var m=l.lanes|l.childLanes;if(S8(s,m),s===xt&&(ct=xt=null,Ot=0),!(l.subtreeFlags&2064)&&!(l.flags&2064)||cu||(cu=!0,ME(yc,function(){return si(),null})),m=(l.flags&15990)!==0,l.subtreeFlags&15990||m){m=Tn.transition,Tn.transition=null;var S=Ue;Ue=1;var T=$e;$e|=4,bh.current=null,NF(s,l),wE(l,s),oF(Lp),kc=!!Mp,Lp=Mp=null,s.current=l,MF(l),u8(),$e=T,Ue=S,Tn.transition=m}else s.current=l;if(cu&&(cu=!1,ss=s,uu=p),m=s.pendingLanes,m===0&&(rs=null),p8(l.stateNode),rn(s,at()),o!==null)for(u=s.onRecoverableError,l=0;l<o.length;l++)p=o[l],u(p.value,{componentStack:p.stack,digest:p.digest});if(lu)throw lu=!1,s=Rh,Rh=null,s;return uu&1&&s.tag!==0&&si(),m=s.pendingLanes,m&1?s===Ah?ba++:(ba=0,Ah=s):ba=0,Zr(),null}function si(){if(ss!==null){var s=vw(uu),o=Tn.transition,l=Ue;try{if(Tn.transition=null,Ue=16>s?16:s,ss===null)var u=!1;else{if(s=ss,ss=null,uu=0,$e&6)throw Error(n(331));var p=$e;for($e|=4,ne=s.current;ne!==null;){var m=ne,S=m.child;if(ne.flags&16){var T=m.deletions;if(T!==null){for(var b=0;b<T.length;b++){var D=T[b];for(ne=D;ne!==null;){var G=ne;switch(G.tag){case 0:case 11:case 15:xa(8,G,m)}var Y=G.child;if(Y!==null)Y.return=G,ne=Y;else for(;ne!==null;){G=ne;var V=G.sibling,ee=G.return;if(mE(G),G===D){ne=null;break}if(V!==null){V.return=ee,ne=V;break}ne=ee}}}var se=m.alternate;if(se!==null){var ie=se.child;if(ie!==null){se.child=null;do{var lt=ie.sibling;ie.sibling=null,ie=lt}while(ie!==null)}}ne=m}}if(m.subtreeFlags&2064&&S!==null)S.return=m,ne=S;else e:for(;ne!==null;){if(m=ne,m.flags&2048)switch(m.tag){case 0:case 11:case 15:xa(9,m,m.return)}var P=m.sibling;if(P!==null){P.return=m.return,ne=P;break e}ne=m.return}}var I=s.current;for(ne=I;ne!==null;){S=ne;var N=S.child;if(S.subtreeFlags&2064&&N!==null)N.return=S,ne=N;else e:for(S=I;ne!==null;){if(T=ne,T.flags&2048)try{switch(T.tag){case 0:case 11:case 15:ou(9,T)}}catch(le){rt(T,T.return,le)}if(T===S){ne=null;break e}var Q=T.sibling;if(Q!==null){Q.return=T.return,ne=Q;break e}ne=T.return}}if($e=p,Zr(),Xn&&typeof Xn.onPostCommitFiberRoot=="function")try{Xn.onPostCommitFiberRoot(vc,s)}catch{}u=!0}return u}finally{Ue=l,Tn.transition=o}}return!1}function OE(s,o,l){o=ei(l,o),o=K_(s,o,1),s=ts(s,o,1),o=qt(),s!==null&&(Qi(s,1,o),rn(s,o))}function rt(s,o,l){if(s.tag===3)OE(s,s,l);else for(;o!==null;){if(o.tag===3){OE(o,s,l);break}else if(o.tag===1){var u=o.stateNode;if(typeof o.type.getDerivedStateFromError=="function"||typeof u.componentDidCatch=="function"&&(rs===null||!rs.has(u))){s=ei(l,s),s=Q_(o,s,1),o=ts(o,s,1),s=qt(),o!==null&&(Qi(o,1,s),rn(o,s));break}}o=o.return}}function BF(s,o,l){var u=s.pingCache;u!==null&&u.delete(o),o=qt(),s.pingedLanes|=s.suspendedLanes&l,xt===s&&(Ot&l)===l&&(ht===4||ht===3&&(Ot&130023424)===Ot&&500>at()-Ch?Ys(s,0):Ih|=l),rn(s,o)}function PE(s,o){o===0&&(s.mode&1?(o=wc,wc<<=1,!(wc&130023424)&&(wc=4194304)):o=1);var l=qt();s=Sr(s,o),s!==null&&(Qi(s,o,l),rn(s,l))}function zF(s){var o=s.memoizedState,l=0;o!==null&&(l=o.retryLane),PE(s,l)}function UF(s,o){var l=0;switch(s.tag){case 13:var u=s.stateNode,p=s.memoizedState;p!==null&&(l=p.retryLane);break;case 19:u=s.stateNode;break;default:throw Error(n(314))}u!==null&&u.delete(o),PE(s,l)}var NE;NE=function(s,o,l){if(s!==null)if(s.memoizedProps!==o.pendingProps||Zt.current)tn=!0;else{if(!(s.lanes&l)&&!(o.flags&128))return tn=!1,RF(s,o,l);tn=!!(s.flags&131072)}else tn=!1,Ze&&o.flags&1048576&&f_(o,Uc,o.index);switch(o.lanes=0,o.tag){case 2:var u=o.type;ru(s,o),s=o.pendingProps;var p=Vo(o,Lt.current);Jo(o,l),p=oh(null,o,u,s,p,l);var m=ih();return o.flags|=1,typeof p=="object"&&p!==null&&typeof p.render=="function"&&p.$$typeof===void 0?(o.tag=1,o.memoizedState=null,o.updateQueue=null,en(u)?(m=!0,Fc(o)):m=!1,o.memoizedState=p.state!==null&&p.state!==void 0?p.state:null,Jp(o),p.updater=tu,o.stateNode=p,p._reactInternals=o,fh(o,u,s,l),o=gh(null,o,u,!0,m,l)):(o.tag=0,Ze&&m&&Up(o),Wt(null,o,p,l),o=o.child),o;case 16:u=o.elementType;e:{switch(ru(s,o),s=o.pendingProps,p=u._init,u=p(u._payload),o.type=u,p=o.tag=WF(u),s=$n(u,s),p){case 0:o=mh(null,o,u,s,l);break e;case 1:o=oE(null,o,u,s,l);break e;case 11:o=eE(null,o,u,s,l);break e;case 14:o=tE(null,o,u,$n(u.type,s),l);break e}throw Error(n(306,u,""))}return o;case 0:return u=o.type,p=o.pendingProps,p=o.elementType===u?p:$n(u,p),mh(s,o,u,p,l);case 1:return u=o.type,p=o.pendingProps,p=o.elementType===u?p:$n(u,p),oE(s,o,u,p,l);case 3:e:{if(iE(o),s===null)throw Error(n(387));u=o.pendingProps,m=o.memoizedState,p=m.element,__(s,o),Yc(o,u,null,l);var S=o.memoizedState;if(u=S.element,m.isDehydrated)if(m={element:u,isDehydrated:!1,cache:S.cache,pendingSuspenseBoundaries:S.pendingSuspenseBoundaries,transitions:S.transitions},o.updateQueue.baseState=m,o.memoizedState=m,o.flags&256){p=ei(Error(n(423)),o),o=aE(s,o,u,l,p);break e}else if(u!==p){p=ei(Error(n(424)),o),o=aE(s,o,u,l,p);break e}else for(pn=Qr(o.stateNode.containerInfo.firstChild),fn=o,Ze=!0,Dn=null,l=S_(o,null,u,l),o.child=l;l;)l.flags=l.flags&-3|4096,l=l.sibling;else{if(Ko(),u===p){o=_r(s,o,l);break e}Wt(s,o,u,l)}o=o.child}return o;case 5:return k_(o),s===null&&qp(o),u=o.type,p=o.pendingProps,m=s!==null?s.memoizedProps:null,S=p.children,jp(u,p)?S=null:m!==null&&jp(u,m)&&(o.flags|=32),sE(s,o),Wt(s,o,S,l),o.child;case 6:return s===null&&qp(o),null;case 13:return lE(s,o,l);case 4:return Zp(o,o.stateNode.containerInfo),u=o.pendingProps,s===null?o.child=Qo(o,null,u,l):Wt(s,o,u,l),o.child;case 11:return u=o.type,p=o.pendingProps,p=o.elementType===u?p:$n(u,p),eE(s,o,u,p,l);case 7:return Wt(s,o,o.pendingProps,l),o.child;case 8:return Wt(s,o,o.pendingProps.children,l),o.child;case 12:return Wt(s,o,o.pendingProps.children,l),o.child;case 10:e:{if(u=o.type._context,p=o.pendingProps,m=o.memoizedProps,S=p.value,Qe(qc,u._currentValue),u._currentValue=S,m!==null)if(jn(m.value,S)){if(m.children===p.children&&!Zt.current){o=_r(s,o,l);break e}}else for(m=o.child,m!==null&&(m.return=o);m!==null;){var T=m.dependencies;if(T!==null){S=m.child;for(var b=T.firstContext;b!==null;){if(b.context===u){if(m.tag===1){b=wr(-1,l&-l),b.tag=2;var D=m.updateQueue;if(D!==null){D=D.shared;var G=D.pending;G===null?b.next=b:(b.next=G.next,G.next=b),D.pending=b}}m.lanes|=l,b=m.alternate,b!==null&&(b.lanes|=l),Qp(m.return,l,o),T.lanes|=l;break}b=b.next}}else if(m.tag===10)S=m.type===o.type?null:m.child;else if(m.tag===18){if(S=m.return,S===null)throw Error(n(341));S.lanes|=l,T=S.alternate,T!==null&&(T.lanes|=l),Qp(S,l,o),S=m.sibling}else S=m.child;if(S!==null)S.return=m;else for(S=m;S!==null;){if(S===o){S=null;break}if(m=S.sibling,m!==null){m.return=S.return,S=m;break}S=S.return}m=S}Wt(s,o,p.children,l),o=o.child}return o;case 9:return p=o.type,u=o.pendingProps.children,Jo(o,l),p=xn(p),u=u(p),o.flags|=1,Wt(s,o,u,l),o.child;case 14:return u=o.type,p=$n(u,o.pendingProps),p=$n(u.type,p),tE(s,o,u,p,l);case 15:return nE(s,o,o.type,o.pendingProps,l);case 17:return u=o.type,p=o.pendingProps,p=o.elementType===u?p:$n(u,p),ru(s,o),o.tag=1,en(u)?(s=!0,Fc(o)):s=!1,Jo(o,l),G_(o,u,p),fh(o,u,p,l),gh(null,o,u,!0,s,l);case 19:return uE(s,o,l);case 22:return rE(s,o,l)}throw Error(n(156,o.tag))};function ME(s,o){return pw(s,o)}function HF(s,o,l,u){this.tag=s,this.key=l,this.sibling=this.child=this.return=this.stateNode=this.type=this.elementType=null,this.index=0,this.ref=null,this.pendingProps=o,this.dependencies=this.memoizedState=this.updateQueue=this.memoizedProps=null,this.mode=u,this.subtreeFlags=this.flags=0,this.deletions=null,this.childLanes=this.lanes=0,this.alternate=null}function bn(s,o,l,u){return new HF(s,o,l,u)}function jh(s){return s=s.prototype,!(!s||!s.isReactComponent)}function WF(s){if(typeof s=="function")return jh(s)?1:0;if(s!=null){if(s=s.$$typeof,s===ae)return 11;if(s===We)return 14}return 2}function as(s,o){var l=s.alternate;return l===null?(l=bn(s.tag,o,s.key,s.mode),l.elementType=s.elementType,l.type=s.type,l.stateNode=s.stateNode,l.alternate=s,s.alternate=l):(l.pendingProps=o,l.type=s.type,l.flags=0,l.subtreeFlags=0,l.deletions=null),l.flags=s.flags&14680064,l.childLanes=s.childLanes,l.lanes=s.lanes,l.child=s.child,l.memoizedProps=s.memoizedProps,l.memoizedState=s.memoizedState,l.updateQueue=s.updateQueue,o=s.dependencies,l.dependencies=o===null?null:{lanes:o.lanes,firstContext:o.firstContext},l.sibling=s.sibling,l.index=s.index,l.ref=s.ref,l}function hu(s,o,l,u,p,m){var S=2;if(u=s,typeof s=="function")jh(s)&&(S=1);else if(typeof s=="string")S=5;else e:switch(s){case L:return Qs(l.children,p,m,o);case U:S=8,p|=8;break;case te:return s=bn(12,l,o,p|2),s.elementType=te,s.lanes=m,s;case ye:return s=bn(13,l,o,p),s.elementType=ye,s.lanes=m,s;case Ie:return s=bn(19,l,o,p),s.elementType=Ie,s.lanes=m,s;case ke:return mu(l,p,m,o);default:if(typeof s=="object"&&s!==null)switch(s.$$typeof){case K:S=10;break e;case oe:S=9;break e;case ae:S=11;break e;case We:S=14;break e;case ce:S=16,u=null;break e}throw Error(n(130,s==null?s:typeof s,""))}return o=bn(S,l,o,p),o.elementType=s,o.type=u,o.lanes=m,o}function Qs(s,o,l,u){return s=bn(7,s,u,o),s.lanes=l,s}function mu(s,o,l,u){return s=bn(22,s,u,o),s.elementType=ke,s.lanes=l,s.stateNode={isHidden:!1},s}function Dh(s,o,l){return s=bn(6,s,null,o),s.lanes=l,s}function $h(s,o,l){return o=bn(4,s.children!==null?s.children:[],s.key,o),o.lanes=l,o.stateNode={containerInfo:s.containerInfo,pendingChildren:null,implementation:s.implementation},o}function qF(s,o,l,u,p){this.tag=o,this.containerInfo=s,this.finishedWork=this.pingCache=this.current=this.pendingChildren=null,this.timeoutHandle=-1,this.callbackNode=this.pendingContext=this.context=null,this.callbackPriority=0,this.eventTimes=dp(0),this.expirationTimes=dp(-1),this.entangledLanes=this.finishedLanes=this.mutableReadLanes=this.expiredLanes=this.pingedLanes=this.suspendedLanes=this.pendingLanes=0,this.entanglements=dp(0),this.identifierPrefix=u,this.onRecoverableError=p,this.mutableSourceEagerHydrationData=null}function Fh(s,o,l,u,p,m,S,T,b){return s=new qF(s,o,l,T,b),o===1?(o=1,m===!0&&(o|=8)):o=0,m=bn(3,null,null,o),s.current=m,m.stateNode=s,m.memoizedState={element:u,isDehydrated:l,cache:null,transitions:null,pendingSuspenseBoundaries:null},Jp(m),s}function VF(s,o,l){var u=3<arguments.length&&arguments[3]!==void 0?arguments[3]:null;return{$$typeof:M,key:u==null?null:""+u,children:s,containerInfo:o,implementation:l}}function LE(s){if(!s)return Jr;s=s._reactInternals;e:{if($s(s)!==s||s.tag!==1)throw Error(n(170));var o=s;do{switch(o.tag){case 3:o=o.stateNode.context;break e;case 1:if(en(o.type)){o=o.stateNode.__reactInternalMemoizedMergedChildContext;break e}}o=o.return}while(o!==null);throw Error(n(171))}if(s.tag===1){var l=s.type;if(en(l))return c_(s,l,o)}return o}function jE(s,o,l,u,p,m,S,T,b){return s=Fh(l,u,!0,s,p,m,S,T,b),s.context=LE(null),l=s.current,u=qt(),p=os(l),m=wr(u,p),m.callback=o??null,ts(l,m,p),s.current.lanes=p,Qi(s,p,u),rn(s,u),s}function gu(s,o,l,u){var p=o.current,m=qt(),S=os(p);return l=LE(l),o.context===null?o.context=l:o.pendingContext=l,o=wr(m,S),o.payload={element:s},u=u===void 0?null:u,u!==null&&(o.callback=u),s=ts(p,o,S),s!==null&&(zn(s,p,S,m),Gc(s,p,S)),S}function yu(s){if(s=s.current,!s.child)return null;switch(s.child.tag){case 5:return s.child.stateNode;default:return s.child.stateNode}}function DE(s,o){if(s=s.memoizedState,s!==null&&s.dehydrated!==null){var l=s.retryLane;s.retryLane=l!==0&&l<o?l:o}}function Bh(s,o){DE(s,o),(s=s.alternate)&&DE(s,o)}function GF(){return null}var $E=typeof reportError=="function"?reportError:function(s){console.error(s)};function zh(s){this._internalRoot=s}vu.prototype.render=zh.prototype.render=function(s){var o=this._internalRoot;if(o===null)throw Error(n(409));gu(s,o,null,null)},vu.prototype.unmount=zh.prototype.unmount=function(){var s=this._internalRoot;if(s!==null){this._internalRoot=null;var o=s.containerInfo;Gs(function(){gu(null,s,null,null)}),o[mr]=null}};function vu(s){this._internalRoot=s}vu.prototype.unstable_scheduleHydration=function(s){if(s){var o=_w();s={blockedOn:null,target:s,priority:o};for(var l=0;l<Gr.length&&o!==0&&o<Gr[l].priority;l++);Gr.splice(l,0,s),l===0&&kw(s)}};function Uh(s){return!(!s||s.nodeType!==1&&s.nodeType!==9&&s.nodeType!==11)}function Su(s){return!(!s||s.nodeType!==1&&s.nodeType!==9&&s.nodeType!==11&&(s.nodeType!==8||s.nodeValue!==" react-mount-point-unstable "))}function FE(){}function YF(s,o,l,u,p){if(p){if(typeof u=="function"){var m=u;u=function(){var D=yu(S);m.call(D)}}var S=jE(o,u,s,0,null,!1,!1,"",FE);return s._reactRootContainer=S,s[mr]=S.current,ua(s.nodeType===8?s.parentNode:s),Gs(),S}for(;p=s.lastChild;)s.removeChild(p);if(typeof u=="function"){var T=u;u=function(){var D=yu(b);T.call(D)}}var b=Fh(s,0,!1,null,null,!1,!1,"",FE);return s._reactRootContainer=b,s[mr]=b.current,ua(s.nodeType===8?s.parentNode:s),Gs(function(){gu(o,b,l,u)}),b}function wu(s,o,l,u,p){var m=l._reactRootContainer;if(m){var S=m;if(typeof p=="function"){var T=p;p=function(){var b=yu(S);T.call(b)}}gu(o,S,s,p)}else S=YF(l,o,s,p,u);return yu(S)}Sw=function(s){switch(s.tag){case 3:var o=s.stateNode;if(o.current.memoizedState.isDehydrated){var l=Ki(o.pendingLanes);l!==0&&(fp(o,l|1),rn(o,at()),!($e&6)&&(ri=at()+500,Zr()))}break;case 13:Gs(function(){var u=Sr(s,1);if(u!==null){var p=qt();zn(u,s,1,p)}}),Bh(s,1)}},pp=function(s){if(s.tag===13){var o=Sr(s,134217728);if(o!==null){var l=qt();zn(o,s,134217728,l)}Bh(s,134217728)}},ww=function(s){if(s.tag===13){var o=os(s),l=Sr(s,o);if(l!==null){var u=qt();zn(l,s,o,u)}Bh(s,o)}},_w=function(){return Ue},Ew=function(s,o){var l=Ue;try{return Ue=s,o()}finally{Ue=l}},op=function(s,o,l){switch(o){case"input":if(Ls(s,l),o=l.name,l.type==="radio"&&o!=null){for(l=s;l.parentNode;)l=l.parentNode;for(l=l.querySelectorAll("input[name="+JSON.stringify(""+o)+'][type="radio"]'),o=0;o<l.length;o++){var u=l[o];if(u!==s&&u.form===s.form){var p=Dc(u);if(!p)throw Error(n(90));fc(u),Ls(u,p)}}}break;case"textarea":je(s,l);break;case"select":o=l.value,o!=null&&_t(s,!!l.multiple,o,!1)}},iw=Nh,aw=Gs;var KF={usingClientEntryPoint:!1,Events:[pa,Wo,Dc,sw,ow,Nh]},Ia={findFiberByHostInstance:Fs,bundleType:0,version:"18.3.1",rendererPackageName:"react-dom"},QF={bundleType:Ia.bundleType,version:Ia.version,rendererPackageName:Ia.rendererPackageName,rendererConfig:Ia.rendererConfig,overrideHookState:null,overrideHookStateDeletePath:null,overrideHookStateRenamePath:null,overrideProps:null,overridePropsDeletePath:null,overridePropsRenamePath:null,setErrorHandler:null,setSuspenseHandler:null,scheduleUpdate:null,currentDispatcherRef:H.ReactCurrentDispatcher,findHostInstanceByFiber:function(s){return s=dw(s),s===null?null:s.stateNode},findFiberByHostInstance:Ia.findFiberByHostInstance||GF,findHostInstancesForRefresh:null,scheduleRefresh:null,scheduleRoot:null,setRefreshHandler:null,getCurrentFiber:null,reconcilerVersion:"18.3.1-next-f1338f8080-20240426"};if(typeof __REACT_DEVTOOLS_GLOBAL_HOOK__<"u"){var _u=__REACT_DEVTOOLS_GLOBAL_HOOK__;if(!_u.isDisabled&&_u.supportsFiber)try{vc=_u.inject(QF),Xn=_u}catch{}}return Vt.__SECRET_INTERNALS_DO_NOT_USE_OR_YOU_WILL_BE_FIRED=KF,Vt.createPortal=function(s,o){var l=2<arguments.length&&arguments[2]!==void 0?arguments[2]:null;if(!Uh(o))throw Error(n(200));return VF(s,o,null,l)},Vt.createRoot=function(s,o){if(!Uh(s))throw Error(n(299));var l=!1,u="",p=$E;return o!=null&&(o.unstable_strictMode===!0&&(l=!0),o.identifierPrefix!==void 0&&(u=o.identifierPrefix),o.onRecoverableError!==void 0&&(p=o.onRecoverableError)),o=Fh(s,1,!1,null,null,l,!1,u,p),s[mr]=o.current,ua(s.nodeType===8?s.parentNode:s),new zh(o)},Vt.findDOMNode=function(s){if(s==null)return null;if(s.nodeType===1)return s;var o=s._reactInternals;if(o===void 0)throw typeof s.render=="function"?Error(n(188)):(s=Object.keys(s).join(","),Error(n(268,s)));return s=dw(o),s=s===null?null:s.stateNode,s},Vt.flushSync=function(s){return Gs(s)},Vt.hydrate=function(s,o,l){if(!Su(o))throw Error(n(200));return wu(null,s,o,!0,l)},Vt.hydrateRoot=function(s,o,l){if(!Uh(s))throw Error(n(405));var u=l!=null&&l.hydratedSources||null,p=!1,m="",S=$E;if(l!=null&&(l.unstable_strictMode===!0&&(p=!0),l.identifierPrefix!==void 0&&(m=l.identifierPrefix),l.onRecoverableError!==void 0&&(S=l.onRecoverableError)),o=jE(o,null,s,1,l??null,p,!1,m,S),s[mr]=o.current,ua(s),u)for(s=0;s<u.length;s++)l=u[s],p=l._getVersion,p=p(l._source),o.mutableSourceEagerHydrationData==null?o.mutableSourceEagerHydrationData=[l,p]:o.mutableSourceEagerHydrationData.push(l,p);return new vu(o)},Vt.render=function(s,o,l){if(!Su(o))throw Error(n(200));return wu(null,s,o,!1,l)},Vt.unmountComponentAtNode=function(s){if(!Su(s))throw Error(n(40));return s._reactRootContainer?(Gs(function(){wu(null,null,s,!1,function(){s._reactRootContainer=null,s[mr]=null})}),!0):!1},Vt.unstable_batchedUpdates=Nh,Vt.unstable_renderSubtreeIntoContainer=function(s,o,l,u){if(!Su(l))throw Error(n(200));if(s==null||s._reactInternals===void 0)throw Error(n(38));return wu(s,o,l,!1,u)},Vt.version="18.3.1-next-f1338f8080-20240426",Vt}var Qh;function Xh(){if(Qh)return Tu.exports;Qh=1;function e(){if(!(typeof __REACT_DEVTOOLS_GLOBAL_HOOK__>"u"||typeof __REACT_DEVTOOLS_GLOBAL_HOOK__.checkDCE!="function"))try{__REACT_DEVTOOLS_GLOBAL_HOOK__.checkDCE(e)}catch(t){console.error(t)}}return e(),Tu.exports=VE(),Tu.exports}var Jh;function GE(){if(Jh)return Ca;Jh=1;var e=Xh();return Ca.createRoot=e.createRoot,Ca.hydrateRoot=e.hydrateRoot,Ca}var YE=GE();const xr=e=>{const t=crypto.randomUUID();return e?t.substring(0,e):t},gn={userId:"edmap-user-id",profileEmoji:"edmap-profileEmoji",defaultName:"edmap-random-name",accessToken:"edmap-access-token"},KE=()=>{localStorage.removeItem("edmap-access-token"),localStorage.removeItem("edmap-refresh-token")},QE=async()=>(XE(),await fr()),XE=()=>{localStorage.removeItem(gn.userId)},JE=()=>{const e=new URL(window.location.href);e.searchParams.delete("code"),window.history.replaceState({index:0,scrollX:0,scrollY:document.scrollY},"",e.toString())},Zh=async()=>(KE(),JE(),await QE());function em(e,t){return function(){return e.apply(t,arguments)}}const{toString:ZE}=Object.prototype,{getPrototypeOf:Cu}=Object,Ra=(e=>t=>{const n=ZE.call(t);return e[n]||(e[n]=n.slice(8,-1).toLowerCase())})(Object.create(null)),In=e=>(e=e.toLowerCase(),t=>Ra(t)===e),Aa=e=>t=>typeof t===e,{isArray:Js}=Array,ii=Aa("undefined");function ex(e){return e!==null&&!ii(e)&&e.constructor!==null&&!ii(e.constructor)&&sn(e.constructor.isBuffer)&&e.constructor.isBuffer(e)}const tm=In("ArrayBuffer");function tx(e){let t;return typeof ArrayBuffer<"u"&&ArrayBuffer.isView?t=ArrayBuffer.isView(e):t=e&&e.buffer&&tm(e.buffer),t}const nx=Aa("string"),sn=Aa("function"),nm=Aa("number"),Oa=e=>e!==null&&typeof e=="object",rx=e=>e===!0||e===!1,Pa=e=>{if(Ra(e)!=="object")return!1;const t=Cu(e);return(t===null||t===Object.prototype||Object.getPrototypeOf(t)===null)&&!(Symbol.toStringTag in e)&&!(Symbol.iterator in e)},sx=In("Date"),ox=In("File"),ix=In("Blob"),ax=In("FileList"),lx=e=>Oa(e)&&sn(e.pipe),cx=e=>{let t;return e&&(typeof FormData=="function"&&e instanceof FormData||sn(e.append)&&((t=Ra(e))==="formdata"||t==="object"&&sn(e.toString)&&e.toString()==="[object FormData]"))},ux=In("URLSearchParams"),[dx,fx,px,hx]=["ReadableStream","Request","Response","Headers"].map(In),mx=e=>e.trim?e.trim():e.replace(/^[\s\uFEFF\xA0]+|[\s\uFEFF\xA0]+$/g,"");function ai(e,t,{allOwnKeys:n=!1}={}){if(e===null||typeof e>"u")return;let r,i;if(typeof e!="object"&&(e=[e]),Js(e))for(r=0,i=e.length;r<i;r++)t.call(null,e[r],r,e);else{const a=n?Object.getOwnPropertyNames(e):Object.keys(e),c=a.length;let d;for(r=0;r<c;r++)d=a[r],t.call(null,e[d],d,e)}}function rm(e,t){t=t.toLowerCase();const n=Object.keys(e);let r=n.length,i;for(;r-- >0;)if(i=n[r],t===i.toLowerCase())return i;return null}const cs=typeof globalThis<"u"?globalThis:typeof self<"u"?self:typeof window<"u"?window:global,sm=e=>!ii(e)&&e!==cs;function Ru(){const{caseless:e}=sm(this)&&this||{},t={},n=(r,i)=>{const a=e&&rm(t,i)||i;Pa(t[a])&&Pa(r)?t[a]=Ru(t[a],r):Pa(r)?t[a]=Ru({},r):Js(r)?t[a]=r.slice():t[a]=r};for(let r=0,i=arguments.length;r<i;r++)arguments[r]&&ai(arguments[r],n);return t}const gx=(e,t,n,{allOwnKeys:r}={})=>(ai(t,(i,a)=>{n&&sn(i)?e[a]=em(i,n):e[a]=i},{allOwnKeys:r}),e),yx=e=>(e.charCodeAt(0)===65279&&(e=e.slice(1)),e),vx=(e,t,n,r)=>{e.prototype=Object.create(t.prototype,r),e.prototype.constructor=e,Object.defineProperty(e,"super",{value:t.prototype}),n&&Object.assign(e.prototype,n)},Sx=(e,t,n,r)=>{let i,a,c;const d={};if(t=t||{},e==null)return t;do{for(i=Object.getOwnPropertyNames(e),a=i.length;a-- >0;)c=i[a],(!r||r(c,e,t))&&!d[c]&&(t[c]=e[c],d[c]=!0);e=n!==!1&&Cu(e)}while(e&&(!n||n(e,t))&&e!==Object.prototype);return t},wx=(e,t,n)=>{e=String(e),(n===void 0||n>e.length)&&(n=e.length),n-=t.length;const r=e.indexOf(t,n);return r!==-1&&r===n},_x=e=>{if(!e)return null;if(Js(e))return e;let t=e.length;if(!nm(t))return null;const n=new Array(t);for(;t-- >0;)n[t]=e[t];return n},Ex=(e=>t=>e&&t instanceof e)(typeof Uint8Array<"u"&&Cu(Uint8Array)),xx=(e,t)=>{const r=(e&&e[Symbol.iterator]).call(e);let i;for(;(i=r.next())&&!i.done;){const a=i.value;t.call(e,a[0],a[1])}},kx=(e,t)=>{let n;const r=[];for(;(n=e.exec(t))!==null;)r.push(n);return r},Tx=In("HTMLFormElement"),bx=e=>e.toLowerCase().replace(/[-_\s]([a-z\d])(\w*)/g,function(n,r,i){return r.toUpperCase()+i}),om=(({hasOwnProperty:e})=>(t,n)=>e.call(t,n))(Object.prototype),Ix=In("RegExp"),im=(e,t)=>{const n=Object.getOwnPropertyDescriptors(e),r={};ai(n,(i,a)=>{let c;(c=t(i,a,e))!==!1&&(r[a]=c||i)}),Object.defineProperties(e,r)},Cx=e=>{im(e,(t,n)=>{if(sn(e)&&["arguments","caller","callee"].indexOf(n)!==-1)return!1;const r=e[n];if(sn(r)){if(t.enumerable=!1,"writable"in t){t.writable=!1;return}t.set||(t.set=()=>{throw Error("Can not rewrite read-only method '"+n+"'")})}})},Rx=(e,t)=>{const n={},r=i=>{i.forEach(a=>{n[a]=!0})};return Js(e)?r(e):r(String(e).split(t)),n},Ax=()=>{},Ox=(e,t)=>e!=null&&Number.isFinite(e=+e)?e:t,Au="abcdefghijklmnopqrstuvwxyz",am="0123456789",lm={DIGIT:am,ALPHA:Au,ALPHA_DIGIT:Au+Au.toUpperCase()+am},Px=(e=16,t=lm.ALPHA_DIGIT)=>{let n="";const{length:r}=t;for(;e--;)n+=t[Math.random()*r|0];return n};function Nx(e){return!!(e&&sn(e.append)&&e[Symbol.toStringTag]==="FormData"&&e[Symbol.iterator])}const Mx=e=>{const t=new Array(10),n=(r,i)=>{if(Oa(r)){if(t.indexOf(r)>=0)return;if(!("toJSON"in r)){t[i]=r;const a=Js(r)?[]:{};return ai(r,(c,d)=>{const f=n(c,i+1);!ii(f)&&(a[d]=f)}),t[i]=void 0,a}}return r};return n(e,0)},Lx=In("AsyncFunction"),jx=e=>e&&(Oa(e)||sn(e))&&sn(e.then)&&sn(e.catch),cm=((e,t)=>e?setImmediate:t?((n,r)=>(cs.addEventListener("message",({source:i,data:a})=>{i===cs&&a===n&&r.length&&r.shift()()},!1),i=>{r.push(i),cs.postMessage(n,"*")}))(`axios@${Math.random()}`,[]):n=>setTimeout(n))(typeof setImmediate=="function",sn(cs.postMessage)),Dx=typeof queueMicrotask<"u"?queueMicrotask.bind(cs):typeof process<"u"&&process.nextTick||cm,B={isArray:Js,isArrayBuffer:tm,isBuffer:ex,isFormData:cx,isArrayBufferView:tx,isString:nx,isNumber:nm,isBoolean:rx,isObject:Oa,isPlainObject:Pa,isReadableStream:dx,isRequest:fx,isResponse:px,isHeaders:hx,isUndefined:ii,isDate:sx,isFile:ox,isBlob:ix,isRegExp:Ix,isFunction:sn,isStream:lx,isURLSearchParams:ux,isTypedArray:Ex,isFileList:ax,forEach:ai,merge:Ru,extend:gx,trim:mx,stripBOM:yx,inherits:vx,toFlatObject:Sx,kindOf:Ra,kindOfTest:In,endsWith:wx,toArray:_x,forEachEntry:xx,matchAll:kx,isHTMLForm:Tx,hasOwnProperty:om,hasOwnProp:om,reduceDescriptors:im,freezeMethods:Cx,toObjectSet:Rx,toCamelCase:bx,noop:Ax,toFiniteNumber:Ox,findKey:rm,global:cs,isContextDefined:sm,ALPHABET:lm,generateString:Px,isSpecCompliantForm:Nx,toJSONObject:Mx,isAsyncFn:Lx,isThenable:jx,setImmediate:cm,asap:Dx};function _e(e,t,n,r,i){Error.call(this),Error.captureStackTrace?Error.captureStackTrace(this,this.constructor):this.stack=new Error().stack,this.message=e,this.name="AxiosError",t&&(this.code=t),n&&(this.config=n),r&&(this.request=r),i&&(this.response=i,this.status=i.status?i.status:null)}B.inherits(_e,Error,{toJSON:function(){return{message:this.message,name:this.name,description:this.description,number:this.number,fileName:this.fileName,lineNumber:this.lineNumber,columnNumber:this.columnNumber,stack:this.stack,config:B.toJSONObject(this.config),code:this.code,status:this.status}}});const um=_e.prototype,dm={};["ERR_BAD_OPTION_VALUE","ERR_BAD_OPTION","ECONNABORTED","ETIMEDOUT","ERR_NETWORK","ERR_FR_TOO_MANY_REDIRECTS","ERR_DEPRECATED","ERR_BAD_RESPONSE","ERR_BAD_REQUEST","ERR_CANCELED","ERR_NOT_SUPPORT","ERR_INVALID_URL"].forEach(e=>{dm[e]={value:e}}),Object.defineProperties(_e,dm),Object.defineProperty(um,"isAxiosError",{value:!0}),_e.from=(e,t,n,r,i,a)=>{const c=Object.create(um);return B.toFlatObject(e,c,function(f){return f!==Error.prototype},d=>d!=="isAxiosError"),_e.call(c,e.message,t,n,r,i),c.cause=e,c.name=e.name,a&&Object.assign(c,a),c};const $x=null;function Ou(e){return B.isPlainObject(e)||B.isArray(e)}function fm(e){return B.endsWith(e,"[]")?e.slice(0,-2):e}function pm(e,t,n){return e?e.concat(t).map(function(i,a){return i=fm(i),!n&&a?"["+i+"]":i}).join(n?".":""):t}function Fx(e){return B.isArray(e)&&!e.some(Ou)}const Bx=B.toFlatObject(B,{},null,function(t){return/^is[A-Z]/.test(t)});function Na(e,t,n){if(!B.isObject(e))throw new TypeError("target must be an object");t=t||new FormData,n=B.toFlatObject(n,{metaTokens:!0,dots:!1,indexes:!1},!1,function(E,k){return!B.isUndefined(k[E])});const r=n.metaTokens,i=n.visitor||y,a=n.dots,c=n.indexes,f=(n.Blob||typeof Blob<"u"&&Blob)&&B.isSpecCompliantForm(t);if(!B.isFunction(i))throw new TypeError("visitor must be a function");function h(_){if(_===null)return"";if(B.isDate(_))return _.toISOString();if(!f&&B.isBlob(_))throw new _e("Blob is not supported. Use a Buffer instead.");return B.isArrayBuffer(_)||B.isTypedArray(_)?f&&typeof Blob=="function"?new Blob([_]):Buffer.from(_):_}function y(_,E,k){let O=_;if(_&&!k&&typeof _=="object"){if(B.endsWith(E,"{}"))E=r?E:E.slice(0,-2),_=JSON.stringify(_);else if(B.isArray(_)&&Fx(_)||(B.isFileList(_)||B.endsWith(E,"[]"))&&(O=B.toArray(_)))return E=fm(E),O.forEach(function($,H){!(B.isUndefined($)||$===null)&&t.append(c===!0?pm([E],H,a):c===null?E:E+"[]",h($))}),!1}return Ou(_)?!0:(t.append(pm(k,E,a),h(_)),!1)}const g=[],w=Object.assign(Bx,{defaultVisitor:y,convertValue:h,isVisitable:Ou});function x(_,E){if(!B.isUndefined(_)){if(g.indexOf(_)!==-1)throw Error("Circular reference detected in "+E.join("."));g.push(_),B.forEach(_,function(O,R){(!(B.isUndefined(O)||O===null)&&i.call(t,O,B.isString(R)?R.trim():R,E,w))===!0&&x(O,E?E.concat(R):[R])}),g.pop()}}if(!B.isObject(e))throw new TypeError("data must be an object");return x(e),t}function hm(e){const t={"!":"%21","'":"%27","(":"%28",")":"%29","~":"%7E","%20":"+","%00":"\0"};return encodeURIComponent(e).replace(/[!'()~]|%20|%00/g,function(r){return t[r]})}function Pu(e,t){this._pairs=[],e&&Na(e,this,t)}const mm=Pu.prototype;mm.append=function(t,n){this._pairs.push([t,n])},mm.toString=function(t){const n=t?function(r){return t.call(this,r,hm)}:hm;return this._pairs.map(function(i){return n(i[0])+"="+n(i[1])},"").join("&")};function zx(e){return encodeURIComponent(e).replace(/%3A/gi,":").replace(/%24/g,"$").replace(/%2C/gi,",").replace(/%20/g,"+").replace(/%5B/gi,"[").replace(/%5D/gi,"]")}function gm(e,t,n){if(!t)return e;const r=n&&n.encode||zx;B.isFunction(n)&&(n={serialize:n});const i=n&&n.serialize;let a;if(i?a=i(t,n):a=B.isURLSearchParams(t)?t.toString():new Pu(t,n).toString(r),a){const c=e.indexOf("#");c!==-1&&(e=e.slice(0,c)),e+=(e.indexOf("?")===-1?"?":"&")+a}return e}let ym=class{constructor(){this.handlers=[]}use(t,n,r){return this.handlers.push({fulfilled:t,rejected:n,synchronous:r?r.synchronous:!1,runWhen:r?r.runWhen:null}),this.handlers.length-1}eject(t){this.handlers[t]&&(this.handlers[t]=null)}clear(){this.handlers&&(this.handlers=[])}forEach(t){B.forEach(this.handlers,function(r){r!==null&&t(r)})}};const vm={silentJSONParsing:!0,forcedJSONParsing:!0,clarifyTimeoutError:!1},Ux={isBrowser:!0,classes:{URLSearchParams:typeof URLSearchParams<"u"?URLSearchParams:Pu,FormData:typeof FormData<"u"?FormData:null,Blob:typeof Blob<"u"?Blob:null},protocols:["http","https","file","blob","url","data"]},Nu=typeof window<"u"&&typeof document<"u",Mu=typeof navigator=="object"&&navigator||void 0,Hx=Nu&&(!Mu||["ReactNative","NativeScript","NS"].indexOf(Mu.product)<0),Wx=typeof WorkerGlobalScope<"u"&&self instanceof WorkerGlobalScope&&typeof self.importScripts=="function",qx=Nu&&window.location.href||"http://localhost",Pt={...Object.freeze(Object.defineProperty({__proto__:null,hasBrowserEnv:Nu,hasStandardBrowserEnv:Hx,hasStandardBrowserWebWorkerEnv:Wx,navigator:Mu,origin:qx},Symbol.toStringTag,{value:"Module"})),...Ux};function Vx(e,t){return Na(e,new Pt.classes.URLSearchParams,Object.assign({visitor:function(n,r,i,a){return Pt.isNode&&B.isBuffer(n)?(this.append(r,n.toString("base64")),!1):a.defaultVisitor.apply(this,arguments)}},t))}function Gx(e){return B.matchAll(/\w+|\[(\w*)]/g,e).map(t=>t[0]==="[]"?"":t[1]||t[0])}function Yx(e){const t={},n=Object.keys(e);let r;const i=n.length;let a;for(r=0;r<i;r++)a=n[r],t[a]=e[a];return t}function Sm(e){function t(n,r,i,a){let c=n[a++];if(c==="__proto__")return!0;const d=Number.isFinite(+c),f=a>=n.length;return c=!c&&B.isArray(i)?i.length:c,f?(B.hasOwnProp(i,c)?i[c]=[i[c],r]:i[c]=r,!d):((!i[c]||!B.isObject(i[c]))&&(i[c]=[]),t(n,r,i[c],a)&&B.isArray(i[c])&&(i[c]=Yx(i[c])),!d)}if(B.isFormData(e)&&B.isFunction(e.entries)){const n={};return B.forEachEntry(e,(r,i)=>{t(Gx(r),i,n,0)}),n}return null}function Kx(e,t,n){if(B.isString(e))try{return(t||JSON.parse)(e),B.trim(e)}catch(r){if(r.name!=="SyntaxError")throw r}return(0,JSON.stringify)(e)}const li={transitional:vm,adapter:["xhr","http","fetch"],transformRequest:[function(t,n){const r=n.getContentType()||"",i=r.indexOf("application/json")>-1,a=B.isObject(t);if(a&&B.isHTMLForm(t)&&(t=new FormData(t)),B.isFormData(t))return i?JSON.stringify(Sm(t)):t;if(B.isArrayBuffer(t)||B.isBuffer(t)||B.isStream(t)||B.isFile(t)||B.isBlob(t)||B.isReadableStream(t))return t;if(B.isArrayBufferView(t))return t.buffer;if(B.isURLSearchParams(t))return n.setContentType("application/x-www-form-urlencoded;charset=utf-8",!1),t.toString();let d;if(a){if(r.indexOf("application/x-www-form-urlencoded")>-1)return Vx(t,this.formSerializer).toString();if((d=B.isFileList(t))||r.indexOf("multipart/form-data")>-1){const f=this.env&&this.env.FormData;return Na(d?{"files[]":t}:t,f&&new f,this.formSerializer)}}return a||i?(n.setContentType("application/json",!1),Kx(t)):t}],transformResponse:[function(t){const n=this.transitional||li.transitional,r=n&&n.forcedJSONParsing,i=this.responseType==="json";if(B.isResponse(t)||B.isReadableStream(t))return t;if(t&&B.isString(t)&&(r&&!this.responseType||i)){const c=!(n&&n.silentJSONParsing)&&i;try{return JSON.parse(t)}catch(d){if(c)throw d.name==="SyntaxError"?_e.from(d,_e.ERR_BAD_RESPONSE,this,null,this.response):d}}return t}],timeout:0,xsrfCookieName:"XSRF-TOKEN",xsrfHeaderName:"X-XSRF-TOKEN",maxContentLength:-1,maxBodyLength:-1,env:{FormData:Pt.classes.FormData,Blob:Pt.classes.Blob},validateStatus:function(t){return t>=200&&t<300},headers:{common:{Accept:"application/json, text/plain, */*","Content-Type":void 0}}};B.forEach(["delete","get","head","post","put","patch"],e=>{li.headers[e]={}});const Qx=B.toObjectSet(["age","authorization","content-length","content-type","etag","expires","from","host","if-modified-since","if-unmodified-since","last-modified","location","max-forwards","proxy-authorization","referer","retry-after","user-agent"]),Xx=e=>{const t={};let n,r,i;return e&&e.split(`
`).forEach(function(c){i=c.indexOf(":"),n=c.substring(0,i).trim().toLowerCase(),r=c.substring(i+1).trim(),!(!n||t[n]&&Qx[n])&&(n==="set-cookie"?t[n]?t[n].push(r):t[n]=[r]:t[n]=t[n]?t[n]+", "+r:r)}),t},wm=Symbol("internals");function ci(e){return e&&String(e).trim().toLowerCase()}function Ma(e){return e===!1||e==null?e:B.isArray(e)?e.map(Ma):String(e)}function Jx(e){const t=Object.create(null),n=/([^\s,;=]+)\s*(?:=\s*([^,;]+))?/g;let r;for(;r=n.exec(e);)t[r[1]]=r[2];return t}const Zx=e=>/^[-_a-zA-Z0-9^`|~,!#$%&'*+.]+$/.test(e.trim());function Lu(e,t,n,r,i){if(B.isFunction(r))return r.call(this,t,n);if(i&&(t=n),!!B.isString(t)){if(B.isString(r))return t.indexOf(r)!==-1;if(B.isRegExp(r))return r.test(t)}}function ek(e){return e.trim().toLowerCase().replace(/([a-z\d])(\w*)/g,(t,n,r)=>n.toUpperCase()+r)}function tk(e,t){const n=B.toCamelCase(" "+t);["get","set","has"].forEach(r=>{Object.defineProperty(e,r+n,{value:function(i,a,c){return this[r].call(this,t,i,a,c)},configurable:!0})})}let Gt=class{constructor(t){t&&this.set(t)}set(t,n,r){const i=this;function a(d,f,h){const y=ci(f);if(!y)throw new Error("header name must be a non-empty string");const g=B.findKey(i,y);(!g||i[g]===void 0||h===!0||h===void 0&&i[g]!==!1)&&(i[g||f]=Ma(d))}const c=(d,f)=>B.forEach(d,(h,y)=>a(h,y,f));if(B.isPlainObject(t)||t instanceof this.constructor)c(t,n);else if(B.isString(t)&&(t=t.trim())&&!Zx(t))c(Xx(t),n);else if(B.isHeaders(t))for(const[d,f]of t.entries())a(f,d,r);else t!=null&&a(n,t,r);return this}get(t,n){if(t=ci(t),t){const r=B.findKey(this,t);if(r){const i=this[r];if(!n)return i;if(n===!0)return Jx(i);if(B.isFunction(n))return n.call(this,i,r);if(B.isRegExp(n))return n.exec(i);throw new TypeError("parser must be boolean|regexp|function")}}}has(t,n){if(t=ci(t),t){const r=B.findKey(this,t);return!!(r&&this[r]!==void 0&&(!n||Lu(this,this[r],r,n)))}return!1}delete(t,n){const r=this;let i=!1;function a(c){if(c=ci(c),c){const d=B.findKey(r,c);d&&(!n||Lu(r,r[d],d,n))&&(delete r[d],i=!0)}}return B.isArray(t)?t.forEach(a):a(t),i}clear(t){const n=Object.keys(this);let r=n.length,i=!1;for(;r--;){const a=n[r];(!t||Lu(this,this[a],a,t,!0))&&(delete this[a],i=!0)}return i}normalize(t){const n=this,r={};return B.forEach(this,(i,a)=>{const c=B.findKey(r,a);if(c){n[c]=Ma(i),delete n[a];return}const d=t?ek(a):String(a).trim();d!==a&&delete n[a],n[d]=Ma(i),r[d]=!0}),this}concat(...t){return this.constructor.concat(this,...t)}toJSON(t){const n=Object.create(null);return B.forEach(this,(r,i)=>{r!=null&&r!==!1&&(n[i]=t&&B.isArray(r)?r.join(", "):r)}),n}[Symbol.iterator](){return Object.entries(this.toJSON())[Symbol.iterator]()}toString(){return Object.entries(this.toJSON()).map(([t,n])=>t+": "+n).join(`
`)}get[Symbol.toStringTag](){return"AxiosHeaders"}static from(t){return t instanceof this?t:new this(t)}static concat(t,...n){const r=new this(t);return n.forEach(i=>r.set(i)),r}static accessor(t){const r=(this[wm]=this[wm]={accessors:{}}).accessors,i=this.prototype;function a(c){const d=ci(c);r[d]||(tk(i,c),r[d]=!0)}return B.isArray(t)?t.forEach(a):a(t),this}};Gt.accessor(["Content-Type","Content-Length","Accept","Accept-Encoding","User-Agent","Authorization"]),B.reduceDescriptors(Gt.prototype,({value:e},t)=>{let n=t[0].toUpperCase()+t.slice(1);return{get:()=>e,set(r){this[n]=r}}}),B.freezeMethods(Gt);function ju(e,t){const n=this||li,r=t||n,i=Gt.from(r.headers);let a=r.data;return B.forEach(e,function(d){a=d.call(n,a,i.normalize(),t?t.status:void 0)}),i.normalize(),a}function _m(e){return!!(e&&e.__CANCEL__)}function Zs(e,t,n){_e.call(this,e??"canceled",_e.ERR_CANCELED,t,n),this.name="CanceledError"}B.inherits(Zs,_e,{__CANCEL__:!0});function Em(e,t,n){const r=n.config.validateStatus;!n.status||!r||r(n.status)?e(n):t(new _e("Request failed with status code "+n.status,[_e.ERR_BAD_REQUEST,_e.ERR_BAD_RESPONSE][Math.floor(n.status/100)-4],n.config,n.request,n))}function nk(e){const t=/^([-+\w]{1,25})(:?\/\/|:)/.exec(e);return t&&t[1]||""}function rk(e,t){e=e||10;const n=new Array(e),r=new Array(e);let i=0,a=0,c;return t=t!==void 0?t:1e3,function(f){const h=Date.now(),y=r[a];c||(c=h),n[i]=f,r[i]=h;let g=a,w=0;for(;g!==i;)w+=n[g++],g=g%e;if(i=(i+1)%e,i===a&&(a=(a+1)%e),h-c<t)return;const x=y&&h-y;return x?Math.round(w*1e3/x):void 0}}function sk(e,t){let n=0,r=1e3/t,i,a;const c=(h,y=Date.now())=>{n=y,i=null,a&&(clearTimeout(a),a=null),e.apply(null,h)};return[(...h)=>{const y=Date.now(),g=y-n;g>=r?c(h,y):(i=h,a||(a=setTimeout(()=>{a=null,c(i)},r-g)))},()=>i&&c(i)]}const La=(e,t,n=3)=>{let r=0;const i=rk(50,250);return sk(a=>{const c=a.loaded,d=a.lengthComputable?a.total:void 0,f=c-r,h=i(f),y=c<=d;r=c;const g={loaded:c,total:d,progress:d?c/d:void 0,bytes:f,rate:h||void 0,estimated:h&&d&&y?(d-c)/h:void 0,event:a,lengthComputable:d!=null,[t?"download":"upload"]:!0};e(g)},n)},xm=(e,t)=>{const n=e!=null;return[r=>t[0]({lengthComputable:n,total:e,loaded:r}),t[1]]},km=e=>(...t)=>B.asap(()=>e(...t)),ok=Pt.hasStandardBrowserEnv?((e,t)=>n=>(n=new URL(n,Pt.origin),e.protocol===n.protocol&&e.host===n.host&&(t||e.port===n.port)))(new URL(Pt.origin),Pt.navigator&&/(msie|trident)/i.test(Pt.navigator.userAgent)):()=>!0,ik=Pt.hasStandardBrowserEnv?{write(e,t,n,r,i,a){const c=[e+"="+encodeURIComponent(t)];B.isNumber(n)&&c.push("expires="+new Date(n).toGMTString()),B.isString(r)&&c.push("path="+r),B.isString(i)&&c.push("domain="+i),a===!0&&c.push("secure"),document.cookie=c.join("; ")},read(e){const t=document.cookie.match(new RegExp("(^|;\\s*)("+e+")=([^;]*)"));return t?decodeURIComponent(t[3]):null},remove(e){this.write(e,"",Date.now()-864e5)}}:{write(){},read(){return null},remove(){}};function ak(e){return/^([a-z][a-z\d+\-.]*:)?\/\//i.test(e)}function lk(e,t){return t?e.replace(/\/?\/$/,"")+"/"+t.replace(/^\/+/,""):e}function Tm(e,t){return e&&!ak(t)?lk(e,t):t}const bm=e=>e instanceof Gt?{...e}:e;function us(e,t){t=t||{};const n={};function r(h,y,g,w){return B.isPlainObject(h)&&B.isPlainObject(y)?B.merge.call({caseless:w},h,y):B.isPlainObject(y)?B.merge({},y):B.isArray(y)?y.slice():y}function i(h,y,g,w){if(B.isUndefined(y)){if(!B.isUndefined(h))return r(void 0,h,g,w)}else return r(h,y,g,w)}function a(h,y){if(!B.isUndefined(y))return r(void 0,y)}function c(h,y){if(B.isUndefined(y)){if(!B.isUndefined(h))return r(void 0,h)}else return r(void 0,y)}function d(h,y,g){if(g in t)return r(h,y);if(g in e)return r(void 0,h)}const f={url:a,method:a,data:a,baseURL:c,transformRequest:c,transformResponse:c,paramsSerializer:c,timeout:c,timeoutMessage:c,withCredentials:c,withXSRFToken:c,adapter:c,responseType:c,xsrfCookieName:c,xsrfHeaderName:c,onUploadProgress:c,onDownloadProgress:c,decompress:c,maxContentLength:c,maxBodyLength:c,beforeRedirect:c,transport:c,httpAgent:c,httpsAgent:c,cancelToken:c,socketPath:c,responseEncoding:c,validateStatus:d,headers:(h,y,g)=>i(bm(h),bm(y),g,!0)};return B.forEach(Object.keys(Object.assign({},e,t)),function(y){const g=f[y]||i,w=g(e[y],t[y],y);B.isUndefined(w)&&g!==d||(n[y]=w)}),n}const Im=e=>{const t=us({},e);let{data:n,withXSRFToken:r,xsrfHeaderName:i,xsrfCookieName:a,headers:c,auth:d}=t;t.headers=c=Gt.from(c),t.url=gm(Tm(t.baseURL,t.url),e.params,e.paramsSerializer),d&&c.set("Authorization","Basic "+btoa((d.username||"")+":"+(d.password?unescape(encodeURIComponent(d.password)):"")));let f;if(B.isFormData(n)){if(Pt.hasStandardBrowserEnv||Pt.hasStandardBrowserWebWorkerEnv)c.setContentType(void 0);else if((f=c.getContentType())!==!1){const[h,...y]=f?f.split(";").map(g=>g.trim()).filter(Boolean):[];c.setContentType([h||"multipart/form-data",...y].join("; "))}}if(Pt.hasStandardBrowserEnv&&(r&&B.isFunction(r)&&(r=r(t)),r||r!==!1&&ok(t.url))){const h=i&&a&&ik.read(a);h&&c.set(i,h)}return t},ck=typeof XMLHttpRequest<"u"&&function(e){return new Promise(function(n,r){const i=Im(e);let a=i.data;const c=Gt.from(i.headers).normalize();let{responseType:d,onUploadProgress:f,onDownloadProgress:h}=i,y,g,w,x,_;function E(){x&&x(),_&&_(),i.cancelToken&&i.cancelToken.unsubscribe(y),i.signal&&i.signal.removeEventListener("abort",y)}let k=new XMLHttpRequest;k.open(i.method.toUpperCase(),i.url,!0),k.timeout=i.timeout;function O(){if(!k)return;const $=Gt.from("getAllResponseHeaders"in k&&k.getAllResponseHeaders()),z={data:!d||d==="text"||d==="json"?k.responseText:k.response,status:k.status,statusText:k.statusText,headers:$,config:e,request:k};Em(function(L){n(L),E()},function(L){r(L),E()},z),k=null}"onloadend"in k?k.onloadend=O:k.onreadystatechange=function(){!k||k.readyState!==4||k.status===0&&!(k.responseURL&&k.responseURL.indexOf("file:")===0)||setTimeout(O)},k.onabort=function(){k&&(r(new _e("Request aborted",_e.ECONNABORTED,e,k)),k=null)},k.onerror=function(){r(new _e("Network Error",_e.ERR_NETWORK,e,k)),k=null},k.ontimeout=function(){let H=i.timeout?"timeout of "+i.timeout+"ms exceeded":"timeout exceeded";const z=i.transitional||vm;i.timeoutErrorMessage&&(H=i.timeoutErrorMessage),r(new _e(H,z.clarifyTimeoutError?_e.ETIMEDOUT:_e.ECONNABORTED,e,k)),k=null},a===void 0&&c.setContentType(null),"setRequestHeader"in k&&B.forEach(c.toJSON(),function(H,z){k.setRequestHeader(z,H)}),B.isUndefined(i.withCredentials)||(k.withCredentials=!!i.withCredentials),d&&d!=="json"&&(k.responseType=i.responseType),h&&([w,_]=La(h,!0),k.addEventListener("progress",w)),f&&k.upload&&([g,x]=La(f),k.upload.addEventListener("progress",g),k.upload.addEventListener("loadend",x)),(i.cancelToken||i.signal)&&(y=$=>{k&&(r(!$||$.type?new Zs(null,e,k):$),k.abort(),k=null)},i.cancelToken&&i.cancelToken.subscribe(y),i.signal&&(i.signal.aborted?y():i.signal.addEventListener("abort",y)));const R=nk(i.url);if(R&&Pt.protocols.indexOf(R)===-1){r(new _e("Unsupported protocol "+R+":",_e.ERR_BAD_REQUEST,e));return}k.send(a||null)})},uk=(e,t)=>{const{length:n}=e=e?e.filter(Boolean):[];if(t||n){let r=new AbortController,i;const a=function(h){if(!i){i=!0,d();const y=h instanceof Error?h:this.reason;r.abort(y instanceof _e?y:new Zs(y instanceof Error?y.message:y))}};let c=t&&setTimeout(()=>{c=null,a(new _e(`timeout ${t} of ms exceeded`,_e.ETIMEDOUT))},t);const d=()=>{e&&(c&&clearTimeout(c),c=null,e.forEach(h=>{h.unsubscribe?h.unsubscribe(a):h.removeEventListener("abort",a)}),e=null)};e.forEach(h=>h.addEventListener("abort",a));const{signal:f}=r;return f.unsubscribe=()=>B.asap(d),f}},dk=function*(e,t){let n=e.byteLength;if(n<t){yield e;return}let r=0,i;for(;r<n;)i=r+t,yield e.slice(r,i),r=i},fk=async function*(e,t){for await(const n of pk(e))yield*dk(n,t)},pk=async function*(e){if(e[Symbol.asyncIterator]){yield*e;return}const t=e.getReader();try{for(;;){const{done:n,value:r}=await t.read();if(n)break;yield r}}finally{await t.cancel()}},Cm=(e,t,n,r)=>{const i=fk(e,t);let a=0,c,d=f=>{c||(c=!0,r&&r(f))};return new ReadableStream({async pull(f){try{const{done:h,value:y}=await i.next();if(h){d(),f.close();return}let g=y.byteLength;if(n){let w=a+=g;n(w)}f.enqueue(new Uint8Array(y))}catch(h){throw d(h),h}},cancel(f){return d(f),i.return()}},{highWaterMark:2})},ja=typeof fetch=="function"&&typeof Request=="function"&&typeof Response=="function",Rm=ja&&typeof ReadableStream=="function",hk=ja&&(typeof TextEncoder=="function"?(e=>t=>e.encode(t))(new TextEncoder):async e=>new Uint8Array(await new Response(e).arrayBuffer())),Am=(e,...t)=>{try{return!!e(...t)}catch{return!1}},mk=Rm&&Am(()=>{let e=!1;const t=new Request(Pt.origin,{body:new ReadableStream,method:"POST",get duplex(){return e=!0,"half"}}).headers.has("Content-Type");return e&&!t}),Om=64*1024,Du=Rm&&Am(()=>B.isReadableStream(new Response("").body)),Da={stream:Du&&(e=>e.body)};ja&&(e=>{["text","arrayBuffer","blob","formData","stream"].forEach(t=>{!Da[t]&&(Da[t]=B.isFunction(e[t])?n=>n[t]():(n,r)=>{throw new _e(`Response type '${t}' is not supported`,_e.ERR_NOT_SUPPORT,r)})})})(new Response);const gk=async e=>{if(e==null)return 0;if(B.isBlob(e))return e.size;if(B.isSpecCompliantForm(e))return(await new Request(Pt.origin,{method:"POST",body:e}).arrayBuffer()).byteLength;if(B.isArrayBufferView(e)||B.isArrayBuffer(e))return e.byteLength;if(B.isURLSearchParams(e)&&(e=e+""),B.isString(e))return(await hk(e)).byteLength},yk=async(e,t)=>{const n=B.toFiniteNumber(e.getContentLength());return n??gk(t)},$u={http:$x,xhr:ck,fetch:ja&&(async e=>{let{url:t,method:n,data:r,signal:i,cancelToken:a,timeout:c,onDownloadProgress:d,onUploadProgress:f,responseType:h,headers:y,withCredentials:g="same-origin",fetchOptions:w}=Im(e);h=h?(h+"").toLowerCase():"text";let x=uk([i,a&&a.toAbortSignal()],c),_;const E=x&&x.unsubscribe&&(()=>{x.unsubscribe()});let k;try{if(f&&mk&&n!=="get"&&n!=="head"&&(k=await yk(y,r))!==0){let z=new Request(t,{method:"POST",body:r,duplex:"half"}),M;if(B.isFormData(r)&&(M=z.headers.get("content-type"))&&y.setContentType(M),z.body){const[L,U]=xm(k,La(km(f)));r=Cm(z.body,Om,L,U)}}B.isString(g)||(g=g?"include":"omit");const O="credentials"in Request.prototype;_=new Request(t,{...w,signal:x,method:n.toUpperCase(),headers:y.normalize().toJSON(),body:r,duplex:"half",credentials:O?g:void 0});let R=await fetch(_);const $=Du&&(h==="stream"||h==="response");if(Du&&(d||$&&E)){const z={};["status","statusText","headers"].forEach(te=>{z[te]=R[te]});const M=B.toFiniteNumber(R.headers.get("content-length")),[L,U]=d&&xm(M,La(km(d),!0))||[];R=new Response(Cm(R.body,Om,L,()=>{U&&U(),E&&E()}),z)}h=h||"text";let H=await Da[B.findKey(Da,h)||"text"](R,e);return!$&&E&&E(),await new Promise((z,M)=>{Em(z,M,{data:H,headers:Gt.from(R.headers),status:R.status,statusText:R.statusText,config:e,request:_})})}catch(O){throw E&&E(),O&&O.name==="TypeError"&&/fetch/i.test(O.message)?Object.assign(new _e("Network Error",_e.ERR_NETWORK,e,_),{cause:O.cause||O}):_e.from(O,O&&O.code,e,_)}})};B.forEach($u,(e,t)=>{if(e){try{Object.defineProperty(e,"name",{value:t})}catch{}Object.defineProperty(e,"adapterName",{value:t})}});const Pm=e=>`- ${e}`,vk=e=>B.isFunction(e)||e===null||e===!1,Nm={getAdapter:e=>{e=B.isArray(e)?e:[e];const{length:t}=e;let n,r;const i={};for(let a=0;a<t;a++){n=e[a];let c;if(r=n,!vk(n)&&(r=$u[(c=String(n)).toLowerCase()],r===void 0))throw new _e(`Unknown adapter '${c}'`);if(r)break;i[c||"#"+a]=r}if(!r){const a=Object.entries(i).map(([d,f])=>`adapter ${d} `+(f===!1?"is not supported by the environment":"is not available in the build"));let c=t?a.length>1?`since :
`+a.map(Pm).join(`
`):" "+Pm(a[0]):"as no adapter specified";throw new _e("There is no suitable adapter to dispatch the request "+c,"ERR_NOT_SUPPORT")}return r},adapters:$u};function Fu(e){if(e.cancelToken&&e.cancelToken.throwIfRequested(),e.signal&&e.signal.aborted)throw new Zs(null,e)}function Mm(e){return Fu(e),e.headers=Gt.from(e.headers),e.data=ju.call(e,e.transformRequest),["post","put","patch"].indexOf(e.method)!==-1&&e.headers.setContentType("application/x-www-form-urlencoded",!1),Nm.getAdapter(e.adapter||li.adapter)(e).then(function(r){return Fu(e),r.data=ju.call(e,e.transformResponse,r),r.headers=Gt.from(r.headers),r},function(r){return _m(r)||(Fu(e),r&&r.response&&(r.response.data=ju.call(e,e.transformResponse,r.response),r.response.headers=Gt.from(r.response.headers))),Promise.reject(r)})}const Lm="1.7.9",$a={};["object","boolean","number","function","string","symbol"].forEach((e,t)=>{$a[e]=function(r){return typeof r===e||"a"+(t<1?"n ":" ")+e}});const jm={};$a.transitional=function(t,n,r){function i(a,c){return"[Axios v"+Lm+"] Transitional option '"+a+"'"+c+(r?". "+r:"")}return(a,c,d)=>{if(t===!1)throw new _e(i(c," has been removed"+(n?" in "+n:"")),_e.ERR_DEPRECATED);return n&&!jm[c]&&(jm[c]=!0,console.warn(i(c," has been deprecated since v"+n+" and will be removed in the near future"))),t?t(a,c,d):!0}},$a.spelling=function(t){return(n,r)=>(console.warn(`${r} is likely a misspelling of ${t}`),!0)};function Sk(e,t,n){if(typeof e!="object")throw new _e("options must be an object",_e.ERR_BAD_OPTION_VALUE);const r=Object.keys(e);let i=r.length;for(;i-- >0;){const a=r[i],c=t[a];if(c){const d=e[a],f=d===void 0||c(d,a,e);if(f!==!0)throw new _e("option "+a+" must be "+f,_e.ERR_BAD_OPTION_VALUE);continue}if(n!==!0)throw new _e("Unknown option "+a,_e.ERR_BAD_OPTION)}}const Fa={assertOptions:Sk,validators:$a},Un=Fa.validators;let ds=class{constructor(t){this.defaults=t,this.interceptors={request:new ym,response:new ym}}async request(t,n){try{return await this._request(t,n)}catch(r){if(r instanceof Error){let i={};Error.captureStackTrace?Error.captureStackTrace(i):i=new Error;const a=i.stack?i.stack.replace(/^.+\n/,""):"";try{r.stack?a&&!String(r.stack).endsWith(a.replace(/^.+\n.+\n/,""))&&(r.stack+=`
`+a):r.stack=a}catch{}}throw r}}_request(t,n){typeof t=="string"?(n=n||{},n.url=t):n=t||{},n=us(this.defaults,n);const{transitional:r,paramsSerializer:i,headers:a}=n;r!==void 0&&Fa.assertOptions(r,{silentJSONParsing:Un.transitional(Un.boolean),forcedJSONParsing:Un.transitional(Un.boolean),clarifyTimeoutError:Un.transitional(Un.boolean)},!1),i!=null&&(B.isFunction(i)?n.paramsSerializer={serialize:i}:Fa.assertOptions(i,{encode:Un.function,serialize:Un.function},!0)),Fa.assertOptions(n,{baseUrl:Un.spelling("baseURL"),withXsrfToken:Un.spelling("withXSRFToken")},!0),n.method=(n.method||this.defaults.method||"get").toLowerCase();let c=a&&B.merge(a.common,a[n.method]);a&&B.forEach(["delete","get","head","post","put","patch","common"],_=>{delete a[_]}),n.headers=Gt.concat(c,a);const d=[];let f=!0;this.interceptors.request.forEach(function(E){typeof E.runWhen=="function"&&E.runWhen(n)===!1||(f=f&&E.synchronous,d.unshift(E.fulfilled,E.rejected))});const h=[];this.interceptors.response.forEach(function(E){h.push(E.fulfilled,E.rejected)});let y,g=0,w;if(!f){const _=[Mm.bind(this),void 0];for(_.unshift.apply(_,d),_.push.apply(_,h),w=_.length,y=Promise.resolve(n);g<w;)y=y.then(_[g++],_[g++]);return y}w=d.length;let x=n;for(g=0;g<w;){const _=d[g++],E=d[g++];try{x=_(x)}catch(k){E.call(this,k);break}}try{y=Mm.call(this,x)}catch(_){return Promise.reject(_)}for(g=0,w=h.length;g<w;)y=y.then(h[g++],h[g++]);return y}getUri(t){t=us(this.defaults,t);const n=Tm(t.baseURL,t.url);return gm(n,t.params,t.paramsSerializer)}};B.forEach(["delete","get","head","options"],function(t){ds.prototype[t]=function(n,r){return this.request(us(r||{},{method:t,url:n,data:(r||{}).data}))}}),B.forEach(["post","put","patch"],function(t){function n(r){return function(a,c,d){return this.request(us(d||{},{method:t,headers:r?{"Content-Type":"multipart/form-data"}:{},url:a,data:c}))}}ds.prototype[t]=n(),ds.prototype[t+"Form"]=n(!0)});let wk=class BE{constructor(t){if(typeof t!="function")throw new TypeError("executor must be a function.");let n;this.promise=new Promise(function(a){n=a});const r=this;this.promise.then(i=>{if(!r._listeners)return;let a=r._listeners.length;for(;a-- >0;)r._listeners[a](i);r._listeners=null}),this.promise.then=i=>{let a;const c=new Promise(d=>{r.subscribe(d),a=d}).then(i);return c.cancel=function(){r.unsubscribe(a)},c},t(function(a,c,d){r.reason||(r.reason=new Zs(a,c,d),n(r.reason))})}throwIfRequested(){if(this.reason)throw this.reason}subscribe(t){if(this.reason){t(this.reason);return}this._listeners?this._listeners.push(t):this._listeners=[t]}unsubscribe(t){if(!this._listeners)return;const n=this._listeners.indexOf(t);n!==-1&&this._listeners.splice(n,1)}toAbortSignal(){const t=new AbortController,n=r=>{t.abort(r)};return this.subscribe(n),t.signal.unsubscribe=()=>this.unsubscribe(n),t.signal}static source(){let t;return{token:new BE(function(i){t=i}),cancel:t}}};function _k(e){return function(n){return e.apply(null,n)}}function Ek(e){return B.isObject(e)&&e.isAxiosError===!0}const Bu={Continue:100,SwitchingProtocols:101,Processing:102,EarlyHints:103,Ok:200,Created:201,Accepted:202,NonAuthoritativeInformation:203,NoContent:204,ResetContent:205,PartialContent:206,MultiStatus:207,AlreadyReported:208,ImUsed:226,MultipleChoices:300,MovedPermanently:301,Found:302,SeeOther:303,NotModified:304,UseProxy:305,Unused:306,TemporaryRedirect:307,PermanentRedirect:308,BadRequest:400,Unauthorized:401,PaymentRequired:402,Forbidden:403,NotFound:404,MethodNotAllowed:405,NotAcceptable:406,ProxyAuthenticationRequired:407,RequestTimeout:408,Conflict:409,Gone:410,LengthRequired:411,PreconditionFailed:412,PayloadTooLarge:413,UriTooLong:414,UnsupportedMediaType:415,RangeNotSatisfiable:416,ExpectationFailed:417,ImATeapot:418,MisdirectedRequest:421,UnprocessableEntity:422,Locked:423,FailedDependency:424,TooEarly:425,UpgradeRequired:426,PreconditionRequired:428,TooManyRequests:429,RequestHeaderFieldsTooLarge:431,UnavailableForLegalReasons:451,InternalServerError:500,NotImplemented:501,BadGateway:502,ServiceUnavailable:503,GatewayTimeout:504,HttpVersionNotSupported:505,VariantAlsoNegotiates:506,InsufficientStorage:507,LoopDetected:508,NotExtended:510,NetworkAuthenticationRequired:511};Object.entries(Bu).forEach(([e,t])=>{Bu[t]=e});function Dm(e){const t=new ds(e),n=em(ds.prototype.request,t);return B.extend(n,ds.prototype,t,{allOwnKeys:!0}),B.extend(n,t,null,{allOwnKeys:!0}),n.create=function(i){return Dm(us(e,i))},n}const st=Dm(li);st.Axios=ds,st.CanceledError=Zs,st.CancelToken=wk,st.isCancel=_m,st.VERSION=Lm,st.toFormData=Na,st.AxiosError=_e,st.Cancel=st.CanceledError,st.all=function(t){return Promise.all(t)},st.spread=_k,st.isAxiosError=Ek,st.mergeConfig=us,st.AxiosHeaders=Gt,st.formToJSON=e=>Sm(B.isHTMLForm(e)?new FormData(e):e),st.getAdapter=Nm.getAdapter,st.HttpStatusCode=Bu,st.default=st;const zu="https://api.edmap.space",ut=st.create();ut.defaults.baseURL=zu,ut.interceptors.request.use(async e=>{const t=localStorage.getItem("edmap-access-token");return e.headers.Accept="application/json",t&&(e.headers.Authorization=`Bearer ${t}`),e},e=>Promise.reject(e));const ui={},$m=async e=>(await Zh(),window.location.reload(),Promise.reject(e)),Fm=async(e,t)=>{const n=e.data.accessToken,r=e.data.refreshToken;return localStorage.setItem("edmap-access-token",n),localStorage.setItem("edmap-refresh-token",r),t.headers||(t.headers={}),t.headers.Authorization=`Bearer ${n}`,ut(t)};ut.interceptors.response.use(e=>e,async e=>{const t=e.config,n=e.response.status===401,r=t._retry;if(!n||r)return Promise.reject(e);t._retry=!0;const i=localStorage.getItem("edmap-refresh-token");if(!i)return $m(e);try{if(!ui.time||Date.now()-ui.time>1e3*3){const c=st.post(`${zu}/auth/revalidate-token`,{refreshToken:i},{headers:{Authorization:`Bearer ${i}`}});ui.time=Date.now(),ui.request=c;const d=await c;return Fm(d,t)}const a=await ui.request;if(!a)throw new Error;return Fm(a,t)}catch(a){return $m(a)}});class xk{constructor(){Ft(this,"reportAction",(t,n)=>{this.reportActiveUser(),this.actions+=1,this.performPost(t,n)});Ft(this,"reportEdgeClick",t=>{const{mapId:n,questId:r}=this.getBaseAnalyticsProps();this.reportAction("/journey-edge-click",{mapId:n,questId:r,userId:Bl(),edgeId:t})});Ft(this,"reportTestAnswers",t=>{const{mapId:n,questId:r}=this.getBaseAnalyticsProps(),i=Bl(),a=t.map(c=>({mapId:n,questId:r,questionId:c.questionId,answerId:c.answerId||"",userId:i}));this.reportAction("/test-selected-answer",a)});Ft(this,"reportWidgetView",()=>{if(this.isWidgetViewed)return;this.isWidgetViewed=!0;const{mapId:t,questId:n}=this.getBaseAnalyticsProps();return this.performPost("/widget-view",{mapId:t,questId:n})});Ft(this,"reportActiveUser",()=>{if(this.isUserActive)return;this.isUserActive=!0,this.reportWidgetView();const{mapId:t,questId:n}=this.getBaseAnalyticsProps();return this.performPost("/active-user",{mapId:t,questId:n})});Ft(this,"reportActions",(t,n)=>{this.actions!==0&&(this.performPost("/actions-agriggated",{mapId:t,questId:n,userId:Bl(),actionCount:this.actions}),this.actions=0)});Ft(this,"reportQuestCompletion",(t,n)=>{this.performPost("/quest-competed",{mapId:t,questId:n})});Ft(this,"reportNewUserCreated",()=>{this.performPost("/user-created",this.getBaseAnalyticsProps())});Ft(this,"reportUserRegistration",()=>{this.performPost("/user-registrated",{...this.getBaseAnalyticsProps(),userId:Bl()})});Ft(this,"reportQuestEnded",(t,n)=>{this.reportQuestCompletion(t,n)});Ft(this,"drainPendingAnalytics",()=>{const{mapId:t,questId:n}=this.getBaseAnalyticsProps();this.reportActions(t,n)});Ft(this,"performPost",(t,n)=>{try{const r=this.formPayload(n);return navigator.sendBeacon(`${this.baseUrl}${t}`,r)}catch{}});Ft(this,"dropUserActivation",()=>{this.isUserActive=!1,this.isWidgetViewed=!1});Ft(this,"formPayload",t=>{const n=JSON.stringify(t);return new Blob([n],{type:"application/json"})});Ft(this,"getBaseAnalyticsProps",()=>{const[t,n]=localStorage.getItem("analytics").split("@");return{mapId:t,questId:n}});this.actions=0,this.isUserActive=!1,this.isWidgetViewed=!1,this.baseUrl=`${zu}/analytics`}}const kr=new xk,Ee=typeof __SENTRY_DEBUG__>"u"||__SENTRY_DEBUG__,fs="8.50.0",Ne=globalThis;function Ba(e,t,n){const r=Ne,i=r.__SENTRY__=r.__SENTRY__||{},a=i[fs]=i[fs]||{};return a[e]||(a[e]=t())}const Tr=typeof __SENTRY_DEBUG__>"u"||__SENTRY_DEBUG__,kk="Sentry Logger ",Uu=["debug","info","warn","error","log","assert","trace"],za={};function br(e){if(!("console"in Ne))return e();const t=Ne.console,n={},r=Object.keys(za);r.forEach(i=>{const a=za[i];n[i]=t[i],t[i]=a});try{return e()}finally{r.forEach(i=>{t[i]=n[i]})}}function Tk(){let e=!1;const t={enable:()=>{e=!0},disable:()=>{e=!1},isEnabled:()=>e};return Tr?Uu.forEach(n=>{t[n]=(...r)=>{e&&br(()=>{Ne.console[n](`${kk}[${n}]:`,...r)})}}):Uu.forEach(n=>{t[n]=()=>{}}),t}const X=Ba("logger",Tk),Bm=50,ps="?",zm=/\(error: (.*)\)/,Um=/captureMessage|captureException/;function Hm(...e){const t=e.sort((n,r)=>n[0]-r[0]).map(n=>n[1]);return(n,r=0,i=0)=>{const a=[],c=n.split(`
`);for(let d=r;d<c.length;d++){const f=c[d];if(f.length>1024)continue;const h=zm.test(f)?f.replace(zm,"$1"):f;if(!h.match(/\S*Error: /)){for(const y of t){const g=y(h);if(g){a.push(g);break}}if(a.length>=Bm+i)break}}return Ik(a.slice(i))}}function bk(e){return Array.isArray(e)?Hm(...e):e}function Ik(e){if(!e.length)return[];const t=Array.from(e);return/sentryWrapped/.test(Ua(t).function||"")&&t.pop(),t.reverse(),Um.test(Ua(t).function||"")&&(t.pop(),Um.test(Ua(t).function||"")&&t.pop()),t.slice(0,Bm).map(n=>({...n,filename:n.filename||Ua(t).filename,function:n.function||ps}))}function Ua(e){return e[e.length-1]||{}}const Hu="<anonymous>";function nr(e){try{return!e||typeof e!="function"?Hu:e.name||Hu}catch{return Hu}}function Wm(e){const t=e.exception;if(t){const n=[];try{return t.values.forEach(r=>{r.stacktrace.frames&&n.push(...r.stacktrace.frames)}),n}catch{return}}}const Ha={},qm={};function Ir(e,t){Ha[e]=Ha[e]||[],Ha[e].push(t)}function Cr(e,t){if(!qm[e]){qm[e]=!0;try{t()}catch(n){Tr&&X.error(`Error while instrumenting ${e}`,n)}}}function yn(e,t){const n=e&&Ha[e];if(n)for(const r of n)try{r(t)}catch(i){Tr&&X.error(`Error while triggering instrumentation handler.
Type: ${e}
Name: ${nr(r)}
Error:`,i)}}let Wu=null;function Vm(e){const t="error";Ir(t,e),Cr(t,Ck)}function Ck(){Wu=Ne.onerror,Ne.onerror=function(e,t,n,r,i){return yn("error",{column:r,error:i,line:n,msg:e,url:t}),Wu?Wu.apply(this,arguments):!1},Ne.onerror.__SENTRY_INSTRUMENTED__=!0}let qu=null;function Gm(e){const t="unhandledrejection";Ir(t,e),Cr(t,Rk)}function Rk(){qu=Ne.onunhandledrejection,Ne.onunhandledrejection=function(e){return yn("unhandledrejection",e),qu?qu.apply(this,arguments):!0},Ne.onunhandledrejection.__SENTRY_INSTRUMENTED__=!0}function hs(){return Vu(Ne),Ne}function Vu(e){const t=e.__SENTRY__=e.__SENTRY__||{};return t.version=t.version||fs,t[fs]=t[fs]||{}}const Ym=Object.prototype.toString;function Gu(e){switch(Ym.call(e)){case"[object Error]":case"[object Exception]":case"[object DOMException]":case"[object WebAssembly.Exception]":return!0;default:return sr(e,Error)}}function eo(e,t){return Ym.call(e)===`[object ${t}]`}function Km(e){return eo(e,"ErrorEvent")}function Qm(e){return eo(e,"DOMError")}function Ak(e){return eo(e,"DOMException")}function rr(e){return eo(e,"String")}function Yu(e){return typeof e=="object"&&e!==null&&"__sentry_template_string__"in e&&"__sentry_template_values__"in e}function Ku(e){return e===null||Yu(e)||typeof e!="object"&&typeof e!="function"}function to(e){return eo(e,"Object")}function Wa(e){return typeof Event<"u"&&sr(e,Event)}function Ok(e){return typeof Element<"u"&&sr(e,Element)}function Pk(e){return eo(e,"RegExp")}function qa(e){return!!(e&&e.then&&typeof e.then=="function")}function Nk(e){return to(e)&&"nativeEvent"in e&&"preventDefault"in e&&"stopPropagation"in e}function sr(e,t){try{return e instanceof t}catch{return!1}}function Xm(e){return!!(typeof e=="object"&&e!==null&&(e.__isVue||e._isVue))}const no=Ne,Mk=80;function or(e,t={}){if(!e)return"<unknown>";try{let n=e;const r=5,i=[];let a=0,c=0;const d=" > ",f=d.length;let h;const y=Array.isArray(t)?t:t.keyAttrs,g=!Array.isArray(t)&&t.maxStringLength||Mk;for(;n&&a++<r&&(h=Lk(n,y),!(h==="html"||a>1&&c+i.length*f+h.length>=g));)i.push(h),c+=h.length,n=n.parentNode;return i.reverse().join(d)}catch{return"<unknown>"}}function Lk(e,t){const n=e,r=[];if(!n||!n.tagName)return"";if(no.HTMLElement&&n instanceof HTMLElement&&n.dataset){if(n.dataset.sentryComponent)return n.dataset.sentryComponent;if(n.dataset.sentryElement)return n.dataset.sentryElement}r.push(n.tagName.toLowerCase());const i=t&&t.length?t.filter(c=>n.getAttribute(c)).map(c=>[c,n.getAttribute(c)]):null;if(i&&i.length)i.forEach(c=>{r.push(`[${c[0]}="${c[1]}"]`)});else{n.id&&r.push(`#${n.id}`);const c=n.className;if(c&&rr(c)){const d=c.split(/\s+/);for(const f of d)r.push(`.${f}`)}}const a=["aria-label","type","name","title","alt"];for(const c of a){const d=n.getAttribute(c);d&&r.push(`[${c}="${d}"]`)}return r.join("")}function Jm(){try{return no.document.location.href}catch{return""}}function jk(e){return no.document&&no.document.querySelector?no.document.querySelector(e):null}function Zm(e){if(!no.HTMLElement)return null;let t=e;const n=5;for(let r=0;r<n;r++){if(!t)return null;if(t instanceof HTMLElement){if(t.dataset.sentryComponent)return t.dataset.sentryComponent;if(t.dataset.sentryElement)return t.dataset.sentryElement}t=t.parentNode}return null}function ro(e,t=0){return typeof e!="string"||t===0||e.length<=t?e:`${e.slice(0,t)}...`}function eg(e,t){if(!Array.isArray(e))return"";const n=[];for(let r=0;r<e.length;r++){const i=e[r];try{Xm(i)?n.push("[VueViewModel]"):n.push(String(i))}catch{n.push("[value cannot be serialized]")}}return n.join(t)}function Dk(e,t,n=!1){return rr(e)?Pk(t)?t.test(e):rr(t)?n?e===t:e.includes(t):!1:!1}function Rr(e,t=[],n=!1){return t.some(r=>Dk(e,r,n))}function Yt(e,t,n){if(!(t in e))return;const r=e[t],i=n(r);typeof i=="function"&&tg(i,r);try{e[t]=i}catch{Tr&&X.log(`Failed to replace method "${t}" in object`,e)}}function vn(e,t,n){try{Object.defineProperty(e,t,{value:n,writable:!0,configurable:!0})}catch{Tr&&X.log(`Failed to add non-enumerable property "${t}" to object`,e)}}function tg(e,t){try{const n=t.prototype||{};e.prototype=t.prototype=n,vn(e,"__sentry_original__",t)}catch{}}function Qu(e){return e.__sentry_original__}function ng(e){if(Gu(e))return{message:e.message,name:e.name,stack:e.stack,...sg(e)};if(Wa(e)){const t={type:e.type,target:rg(e.target),currentTarget:rg(e.currentTarget),...sg(e)};return typeof CustomEvent<"u"&&sr(e,CustomEvent)&&(t.detail=e.detail),t}else return e}function rg(e){try{return Ok(e)?or(e):Object.prototype.toString.call(e)}catch{return"<unknown>"}}function sg(e){if(typeof e=="object"&&e!==null){const t={};for(const n in e)Object.prototype.hasOwnProperty.call(e,n)&&(t[n]=e[n]);return t}else return{}}function $k(e,t=40){const n=Object.keys(ng(e));n.sort();const r=n[0];if(!r)return"[object has no keys]";if(r.length>=t)return ro(r,t);for(let i=n.length;i>0;i--){const a=n.slice(0,i).join(", ");if(!(a.length>t))return i===n.length?a:ro(a,t)}return""}function dt(e){return Xu(e,new Map)}function Xu(e,t){if(Fk(e)){const n=t.get(e);if(n!==void 0)return n;const r={};t.set(e,r);for(const i of Object.getOwnPropertyNames(e))typeof e[i]<"u"&&(r[i]=Xu(e[i],t));return r}if(Array.isArray(e)){const n=t.get(e);if(n!==void 0)return n;const r=[];return t.set(e,r),e.forEach(i=>{r.push(Xu(i,t))}),r}return e}function Fk(e){if(!to(e))return!1;try{const t=Object.getPrototypeOf(e).constructor.name;return!t||t==="Object"}catch{return!0}}const og=1e3;function di(){return Date.now()/og}function Bk(){const{performance:e}=Ne;if(!e||!e.now)return di;const t=Date.now()-e.now(),n=e.timeOrigin==null?t:e.timeOrigin;return()=>(n+e.now())/og}const Bt=Bk(),zt=(()=>{const{performance:e}=Ne;if(!e||!e.now)return;const t=3600*1e3,n=e.now(),r=Date.now(),i=e.timeOrigin?Math.abs(e.timeOrigin+n-r):t,a=i<t,c=e.timing&&e.timing.navigationStart,f=typeof c=="number"?Math.abs(c+n-r):t,h=f<t;return a||h?i<=f?e.timeOrigin:c:r})();function on(){const e=Ne,t=e.crypto||e.msCrypto;let n=()=>Math.random()*16;try{if(t&&t.randomUUID)return t.randomUUID().replace(/-/g,"");t&&t.getRandomValues&&(n=()=>{const r=new Uint8Array(1);return t.getRandomValues(r),r[0]})}catch{}return("10000000100040008000"+1e11).replace(/[018]/g,r=>(r^(n()&15)>>r/4).toString(16))}function ig(e){return e.exception&&e.exception.values?e.exception.values[0]:void 0}function Ar(e){const{message:t,event_id:n}=e;if(t)return t;const r=ig(e);return r?r.type&&r.value?`${r.type}: ${r.value}`:r.type||r.value||n||"<unknown>":n||"<unknown>"}function Ju(e,t,n){const r=e.exception=e.exception||{},i=r.values=r.values||[],a=i[0]=i[0]||{};a.value||(a.value=t||""),a.type||(a.type="Error")}function so(e,t){const n=ig(e);if(!n)return;const r={type:"generic",handled:!0},i=n.mechanism;if(n.mechanism={...r,...i,...t},t&&"data"in t){const a={...i&&i.data,...t.data};n.mechanism.data=a}}function ag(e){if(zk(e))return!0;try{vn(e,"__sentry_captured__",!0)}catch{}return!1}function zk(e){try{return e.__sentry_captured__}catch{}}var ir;(function(e){e[e.PENDING=0]="PENDING";const n=1;e[e.RESOLVED=n]="RESOLVED";const r=2;e[e.REJECTED=r]="REJECTED"})(ir||(ir={}));function ar(e){return new Sn(t=>{t(e)})}function Va(e){return new Sn((t,n)=>{n(e)})}class Sn{constructor(t){Sn.prototype.__init.call(this),Sn.prototype.__init2.call(this),Sn.prototype.__init3.call(this),Sn.prototype.__init4.call(this),this._state=ir.PENDING,this._handlers=[];try{t(this._resolve,this._reject)}catch(n){this._reject(n)}}then(t,n){return new Sn((r,i)=>{this._handlers.push([!1,a=>{if(!t)r(a);else try{r(t(a))}catch(c){i(c)}},a=>{if(!n)i(a);else try{r(n(a))}catch(c){i(c)}}]),this._executeHandlers()})}catch(t){return this.then(n=>n,t)}finally(t){return new Sn((n,r)=>{let i,a;return this.then(c=>{a=!1,i=c,t&&t()},c=>{a=!0,i=c,t&&t()}).then(()=>{if(a){r(i);return}n(i)})})}__init(){this._resolve=t=>{this._setResult(ir.RESOLVED,t)}}__init2(){this._reject=t=>{this._setResult(ir.REJECTED,t)}}__init3(){this._setResult=(t,n)=>{if(this._state===ir.PENDING){if(qa(n)){n.then(this._resolve,this._reject);return}this._state=t,this._value=n,this._executeHandlers()}}}__init4(){this._executeHandlers=()=>{if(this._state===ir.PENDING)return;const t=this._handlers.slice();this._handlers=[],t.forEach(n=>{n[0]||(this._state===ir.RESOLVED&&n[1](this._value),this._state===ir.REJECTED&&n[2](this._value),n[0]=!0)})}}}function Uk(e){const t=Bt(),n={sid:on(),init:!0,timestamp:t,started:t,duration:0,status:"ok",errors:0,ignoreDuration:!1,toJSON:()=>Wk(n)};return e&&oo(n,e),n}function oo(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||Bt(),t.abnormal_mechanism&&(e.abnormal_mechanism=t.abnormal_mechanism),t.ignoreDuration&&(e.ignoreDuration=t.ignoreDuration),t.sid&&(e.sid=t.sid.length===32?t.sid:on()),t.init!==void 0&&(e.init=t.init),!e.did&&t.did&&(e.did=`${t.did}`),typeof t.started=="number"&&(e.started=t.started),e.ignoreDuration)e.duration=void 0;else if(typeof t.duration=="number")e.duration=t.duration;else{const n=e.timestamp-e.started;e.duration=n>=0?n:0}t.release&&(e.release=t.release),t.environment&&(e.environment=t.environment),!e.ipAddress&&t.ipAddress&&(e.ipAddress=t.ipAddress),!e.userAgent&&t.userAgent&&(e.userAgent=t.userAgent),typeof t.errors=="number"&&(e.errors=t.errors),t.status&&(e.status=t.status)}function Hk(e,t){let n={};e.status==="ok"&&(n={status:"exited"}),oo(e,n)}function Wk(e){return dt({sid:`${e.sid}`,init:e.init,started:new Date(e.started*1e3).toISOString(),timestamp:new Date(e.timestamp*1e3).toISOString(),status:e.status,errors:e.errors,did:typeof e.did=="number"||typeof e.did=="string"?`${e.did}`:void 0,duration:e.duration,abnormal_mechanism:e.abnormal_mechanism,attrs:{release:e.release,environment:e.environment,ip_address:e.ipAddress,user_agent:e.userAgent}})}function Or(){return on()}function Pr(){return on().substring(16)}function Ga(e,t,n=2){if(!t||typeof t!="object"||n<=0)return t;if(e&&t&&Object.keys(t).length===0)return e;const r={...e};for(const i in t)Object.prototype.hasOwnProperty.call(t,i)&&(r[i]=Ga(r[i],t[i],n-1));return r}const Zu="_sentrySpan";function fi(e,t){t?vn(e,Zu,t):delete e[Zu]}function Ya(e){return e[Zu]}const qk=100;class ed{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:Or(),spanId:Pr()}}clone(){const t=new ed;return t._breadcrumbs=[...this._breadcrumbs],t._tags={...this._tags},t._extra={...this._extra},t._contexts={...this._contexts},this._contexts.flags&&(t._contexts.flags={values:[...this._contexts.flags.values]}),t._user=this._user,t._level=this._level,t._session=this._session,t._transactionName=this._transactionName,t._fingerprint=this._fingerprint,t._eventProcessors=[...this._eventProcessors],t._requestSession=this._requestSession,t._attachments=[...this._attachments],t._sdkProcessingMetadata={...this._sdkProcessingMetadata},t._propagationContext={...this._propagationContext},t._client=this._client,t._lastEventId=this._lastEventId,fi(t,Ya(this)),t}setClient(t){this._client=t}setLastEventId(t){this._lastEventId=t}getClient(){return this._client}lastEventId(){return this._lastEventId}addScopeListener(t){this._scopeListeners.push(t)}addEventProcessor(t){return this._eventProcessors.push(t),this}setUser(t){return this._user=t||{email:void 0,id:void 0,ip_address:void 0,username:void 0},this._session&&oo(this._session,{user:t}),this._notifyScopeListeners(),this}getUser(){return this._user}getRequestSession(){return this._requestSession}setRequestSession(t){return this._requestSession=t,this}setTags(t){return this._tags={...this._tags,...t},this._notifyScopeListeners(),this}setTag(t,n){return this._tags={...this._tags,[t]:n},this._notifyScopeListeners(),this}setExtras(t){return this._extra={...this._extra,...t},this._notifyScopeListeners(),this}setExtra(t,n){return this._extra={...this._extra,[t]:n},this._notifyScopeListeners(),this}setFingerprint(t){return this._fingerprint=t,this._notifyScopeListeners(),this}setLevel(t){return this._level=t,this._notifyScopeListeners(),this}setTransactionName(t){return this._transactionName=t,this._notifyScopeListeners(),this}setContext(t,n){return n===null?delete this._contexts[t]:this._contexts[t]=n,this._notifyScopeListeners(),this}setSession(t){return t?this._session=t:delete this._session,this._notifyScopeListeners(),this}getSession(){return this._session}update(t){if(!t)return this;const n=typeof t=="function"?t(this):t,[r,i]=n instanceof ms?[n.getScopeData(),n.getRequestSession()]:to(n)?[t,t.requestSession]:[],{tags:a,extra:c,user:d,contexts:f,level:h,fingerprint:y=[],propagationContext:g}=r||{};return this._tags={...this._tags,...a},this._extra={...this._extra,...c},this._contexts={...this._contexts,...f},d&&Object.keys(d).length&&(this._user=d),h&&(this._level=h),y.length&&(this._fingerprint=y),g&&(this._propagationContext=g),i&&(this._requestSession=i),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,fi(this,void 0),this._attachments=[],this.setPropagationContext({traceId:Or()}),this._notifyScopeListeners(),this}addBreadcrumb(t,n){const r=typeof n=="number"?n:qk;if(r<=0)return this;const i={timestamp:di(),...t},a=this._breadcrumbs;return a.push(i),this._breadcrumbs=a.length>r?a.slice(-r):a,this._notifyScopeListeners(),this}getLastBreadcrumb(){return this._breadcrumbs[this._breadcrumbs.length-1]}clearBreadcrumbs(){return this._breadcrumbs=[],this._notifyScopeListeners(),this}addAttachment(t){return this._attachments.push(t),this}clearAttachments(){return this._attachments=[],this}getScopeData(){return{breadcrumbs:this._breadcrumbs,attachments:this._attachments,contexts:this._contexts,tags:this._tags,extra:this._extra,user:this._user,level:this._level,fingerprint:this._fingerprint||[],eventProcessors:this._eventProcessors,propagationContext:this._propagationContext,sdkProcessingMetadata:this._sdkProcessingMetadata,transactionName:this._transactionName,span:Ya(this)}}setSDKProcessingMetadata(t){return this._sdkProcessingMetadata=Ga(this._sdkProcessingMetadata,t,2),this}setPropagationContext(t){return this._propagationContext={spanId:Pr(),...t},this}getPropagationContext(){return this._propagationContext}captureException(t,n){const r=n&&n.event_id?n.event_id:on();if(!this._client)return X.warn("No client configured on scope - will not capture exception!"),r;const i=new Error("Sentry syntheticException");return this._client.captureException(t,{originalException:t,syntheticException:i,...n,event_id:r},this),r}captureMessage(t,n,r){const i=r&&r.event_id?r.event_id:on();if(!this._client)return X.warn("No client configured on scope - will not capture message!"),i;const a=new Error(t);return this._client.captureMessage(t,n,{originalException:t,syntheticException:a,...r,event_id:i},this),i}captureEvent(t,n){const r=n&&n.event_id?n.event_id:on();return this._client?(this._client.captureEvent(t,{...n,event_id:r},this),r):(X.warn("No client configured on scope - will not capture event!"),r)}_notifyScopeListeners(){this._notifyingListeners||(this._notifyingListeners=!0,this._scopeListeners.forEach(t=>{t(this)}),this._notifyingListeners=!1)}}const ms=ed;function Vk(){return Ba("defaultCurrentScope",()=>new ms)}function Gk(){return Ba("defaultIsolationScope",()=>new ms)}class Yk{constructor(t,n){let r;t?r=t:r=new ms;let i;n?i=n:i=new ms,this._stack=[{scope:r}],this._isolationScope=i}withScope(t){const n=this._pushScope();let r;try{r=t(n)}catch(i){throw this._popScope(),i}return qa(r)?r.then(i=>(this._popScope(),i),i=>{throw this._popScope(),i}):(this._popScope(),r)}getClient(){return this.getStackTop().client}getScope(){return this.getStackTop().scope}getIsolationScope(){return this._isolationScope}getStackTop(){return this._stack[this._stack.length-1]}_pushScope(){const t=this.getScope().clone();return this._stack.push({client:this.getClient(),scope:t}),t}_popScope(){return this._stack.length<=1?!1:!!this._stack.pop()}}function io(){const e=hs(),t=Vu(e);return t.stack=t.stack||new Yk(Vk(),Gk())}function Kk(e){return io().withScope(e)}function Qk(e,t){const n=io();return n.withScope(()=>(n.getStackTop().scope=e,t(e)))}function lg(e){return io().withScope(()=>e(io().getIsolationScope()))}function Xk(){return{withIsolationScope:lg,withScope:Kk,withSetScope:Qk,withSetIsolationScope:(e,t)=>lg(t),getCurrentScope:()=>io().getScope(),getIsolationScope:()=>io().getIsolationScope()}}function ao(e){const t=Vu(e);return t.acs?t.acs:Xk()}function Ve(){const e=hs();return ao(e).getCurrentScope()}function Cn(){const e=hs();return ao(e).getIsolationScope()}function Jk(){return Ba("globalScope",()=>new ms)}function td(...e){const t=hs(),n=ao(t);if(e.length===2){const[r,i]=e;return r?n.withSetScope(r,i):n.withScope(i)}return n.withScope(e[0])}function Ae(){return Ve().getClient()}function Zk(e){const t=e.getPropagationContext(),{traceId:n,spanId:r,parentSpanId:i}=t;return dt({trace_id:n,span_id:r,parent_span_id:i})}const eT="_sentryMetrics";function nd(e){const t=e[eT];if(!t)return;const n={};for(const[,[r,i]]of t)(n[r]||(n[r]=[])).push(dt(i));return n}const Hn="sentry.source",cg="sentry.sample_rate",gs="sentry.op",gt="sentry.origin",rd="sentry.idle_span_finish_reason",Ka="sentry.measurement_unit",Qa="sentry.measurement_value",ug="sentry.custom_span_name",tT="sentry.profile_id",sd="sentry.exclusive_time",nT=0,dg=1,yt=2;function rT(e){if(e<400&&e>=100)return{code:dg};if(e>=400&&e<500)switch(e){case 401:return{code:yt,message:"unauthenticated"};case 403:return{code:yt,message:"permission_denied"};case 404:return{code:yt,message:"not_found"};case 409:return{code:yt,message:"already_exists"};case 413:return{code:yt,message:"failed_precondition"};case 429:return{code:yt,message:"resource_exhausted"};case 499:return{code:yt,message:"cancelled"};default:return{code:yt,message:"invalid_argument"}}if(e>=500&&e<600)switch(e){case 501:return{code:yt,message:"unimplemented"};case 503:return{code:yt,message:"unavailable"};case 504:return{code:yt,message:"deadline_exceeded"};default:return{code:yt,message:"internal_error"}}return{code:yt,message:"unknown_error"}}function fg(e,t){e.setAttribute("http.response.status_code",t);const n=rT(t);n.message!=="unknown_error"&&e.setStatus(n)}const od="sentry-",sT=/^sentry-/,oT=8192;function pg(e){const t=aT(e);if(!t)return;const n=Object.entries(t).reduce((r,[i,a])=>{if(i.match(sT)){const c=i.slice(od.length);r[c]=a}return r},{});if(Object.keys(n).length>0)return n}function iT(e){if(!e)return;const t=Object.entries(e).reduce((n,[r,i])=>(i&&(n[`${od}${r}`]=i),n),{});return lT(t)}function aT(e){if(!(!e||!rr(e)&&!Array.isArray(e)))return Array.isArray(e)?e.reduce((t,n)=>{const r=hg(n);return Object.entries(r).forEach(([i,a])=>{t[i]=a}),t},{}):hg(e)}function hg(e){return e.split(",").map(t=>t.split("=").map(n=>decodeURIComponent(n.trim()))).reduce((t,[n,r])=>(n&&r&&(t[n]=r),t),{})}function lT(e){if(Object.keys(e).length!==0)return Object.entries(e).reduce((t,[n,r],i)=>{const a=`${encodeURIComponent(n)}=${encodeURIComponent(r)}`,c=i===0?a:`${t},${a}`;return c.length>oT?(Tr&&X.warn(`Not adding key: ${n} with val: ${r} to baggage header due to exceeding baggage size limits.`),t):c},"")}const mg=new RegExp("^[ \\t]*([0-9a-f]{32})?-?([0-9a-f]{16})?-?([01])?[ \\t]*$");function cT(e){if(!e)return;const t=e.match(mg);if(!t)return;let n;return t[3]==="1"?n=!0:t[3]==="0"&&(n=!1),{traceId:t[1],parentSampled:n,parentSpanId:t[2]}}function uT(e,t){const n=cT(e),r=pg(t);if(!n||!n.traceId)return{traceId:Or(),spanId:Pr()};const{traceId:i,parentSpanId:a,parentSampled:c}=n,d=Pr();return{traceId:i,parentSpanId:a,spanId:d,sampled:c,dsc:r||{}}}function gg(e=Or(),t=Pr(),n){let r="";return n!==void 0&&(r=n?"-1":"-0"),`${e}-${t}${r}`}const yg=0,vg=1;let Sg=!1;function dT(e){const{spanId:t,traceId:n}=e.spanContext(),{data:r,op:i,parent_span_id:a,status:c,origin:d}=Fe(e);return dt({parent_span_id:a,span_id:t,trace_id:n,data:r,op:i,status:c,origin:d})}function fT(e){const{spanId:t,traceId:n,isRemote:r}=e.spanContext(),i=r?t:Fe(e).parent_span_id,a=r?Pr():t;return dt({parent_span_id:i,span_id:a,trace_id:n})}function pT(e){const{traceId:t,spanId:n}=e.spanContext(),r=vs(e);return gg(t,n,r)}function ys(e){return typeof e=="number"?wg(e):Array.isArray(e)?e[0]+e[1]/1e9:e instanceof Date?wg(e.getTime()):Bt()}function wg(e){return e>9999999999?e/1e3:e}function Fe(e){if(mT(e))return e.getSpanJSON();try{const{spanId:t,traceId:n}=e.spanContext();if(hT(e)){const{attributes:r,startTime:i,name:a,endTime:c,parentSpanId:d,status:f}=e;return dt({span_id:t,trace_id:n,data:r,description:a,parent_span_id:d,start_timestamp:ys(i),timestamp:ys(c)||void 0,status:_g(f),op:r[gs],origin:r[gt],_metrics_summary:nd(e)})}return{span_id:t,trace_id:n}}catch{return{}}}function hT(e){const t=e;return!!t.attributes&&!!t.startTime&&!!t.name&&!!t.endTime&&!!t.status}function mT(e){return typeof e.getSpanJSON=="function"}function vs(e){const{traceFlags:t}=e.spanContext();return t===vg}function _g(e){if(!(!e||e.code===nT))return e.code===dg?"ok":e.message||"unknown_error"}const Ss="_sentryChildSpans",id="_sentryRootSpan";function Eg(e,t){const n=e[id]||e;vn(t,id,n),e[Ss]?e[Ss].add(t):vn(e,Ss,new Set([t]))}function gT(e,t){e[Ss]&&e[Ss].delete(t)}function Xa(e){const t=new Set;function n(r){if(!t.has(r)&&vs(r)){t.add(r);const i=r[Ss]?Array.from(r[Ss]):[];for(const a of i)n(a)}}return n(e),Array.from(t)}function bt(e){return e[id]||e}function vt(){const e=hs(),t=ao(e);return t.getActiveSpan?t.getActiveSpan():Ya(Ve())}function xg(){Sg||(br(()=>{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.")}),Sg=!0)}let kg=!1;function yT(){kg||(kg=!0,Vm(ad),Gm(ad))}function ad(){const e=vt(),t=e&&bt(e);if(t){const n="internal_error";Ee&&X.log(`[Tracing] Root span: ${n} -> Global error occurred`),t.setStatus({code:yt,message:n})}}ad.tag="sentry_tracingErrorCallback";const Tg="_sentryScope",bg="_sentryIsolationScope";function vT(e,t,n){e&&(vn(e,bg,n),vn(e,Tg,t))}function Ig(e){return{scope:e[Tg],isolationScope:e[bg]}}function Nr(e){if(typeof __SENTRY_TRACING__=="boolean"&&!__SENTRY_TRACING__)return!1;const t=Ae(),n=e||t&&t.getOptions();return!!n&&(n.enableTracing||"tracesSampleRate"in n||"tracesSampler"in n)}class lo{constructor(t={}){this._traceId=t.traceId||Or(),this._spanId=t.spanId||Pr()}spanContext(){return{spanId:this._spanId,traceId:this._traceId,traceFlags:yg}}end(t){}setAttribute(t,n){return this}setAttributes(t){return this}setStatus(t){return this}updateName(t){return this}isRecording(){return!1}addEvent(t,n,r){return this}addLink(t){return this}addLinks(t){return this}recordException(t,n){}}const ld="production",Cg="_frozenDsc";function Rg(e,t){vn(e,Cg,t)}function Ag(e,t){const n=t.getOptions(),{publicKey:r}=t.getDsn()||{},i=dt({environment:n.environment||ld,release:n.release,public_key:r,trace_id:e});return t.emit("createDsc",i),i}function Og(e,t){const n=t.getPropagationContext();return n.dsc||Ag(n.traceId,e)}function ws(e){const t=Ae();if(!t)return{};const n=bt(e),r=n[Cg];if(r)return r;const i=n.spanContext().traceState,a=i&&i.get("sentry.dsc"),c=a&&pg(a);if(c)return c;const d=Ag(e.spanContext().traceId,t),f=Fe(n),h=f.data||{},y=h[cg];y!=null&&(d.sample_rate=`${y}`);const g=h[Hn],w=f.description;return g!=="url"&&w&&(d.transaction=w),Nr()&&(d.sampled=String(vs(n))),t.emit("createDsc",d,n),d}function ST(e){if(!Ee)return;const{description:t="< unknown name >",op:n="< unknown op >",parent_span_id:r}=Fe(e),{spanId:i}=e.spanContext(),a=vs(e),c=bt(e),d=c===e,f=`[Tracing] Starting ${a?"sampled":"unsampled"} ${d?"root ":""}span`,h=[`op: ${n}`,`name: ${t}`,`ID: ${i}`];if(r&&h.push(`parent ID: ${r}`),!d){const{op:y,description:g}=Fe(c);h.push(`root ID: ${c.spanContext().spanId}`),y&&h.push(`root op: ${y}`),g&&h.push(`root description: ${g}`)}X.log(`${f}
  ${h.join(`
  `)}`)}function wT(e){if(!Ee)return;const{description:t="< unknown name >",op:n="< unknown op >"}=Fe(e),{spanId:r}=e.spanContext(),a=bt(e)===e,c=`[Tracing] Finishing "${n}" ${a?"root ":""}span "${t}" with ID ${r}`;X.log(c)}function Ja(e){if(typeof e=="boolean")return Number(e);const t=typeof e=="string"?parseFloat(e):e;if(typeof t!="number"||isNaN(t)||t<0||t>1){Ee&&X.warn(`[Tracing] Given sample rate is invalid. Sample rate must be a boolean or a number between 0 and 1. Got ${JSON.stringify(e)} of type ${JSON.stringify(typeof e)}.`);return}return t}function _T(e,t){if(!Nr(e))return[!1];const n=Cn().getScopeData().sdkProcessingMetadata.normalizedRequest,r={...t,normalizedRequest:t.normalizedRequest||n};let i;typeof e.tracesSampler=="function"?i=e.tracesSampler(r):r.parentSampled!==void 0?i=r.parentSampled:typeof e.tracesSampleRate<"u"?i=e.tracesSampleRate:i=1;const a=Ja(i);return a===void 0?(Ee&&X.warn("[Tracing] Discarding transaction because of invalid sample rate."),[!1]):a?Math.random()<a?[!0,a]:(Ee&&X.log(`[Tracing] Discarding transaction because it's not included in the random sample (sampling rate = ${Number(i)})`),[!1,a]):(Ee&&X.log(`[Tracing] Discarding transaction because ${typeof e.tracesSampler=="function"?"tracesSampler returned 0 or false":"a negative sampling decision was inherited or tracesSampleRate is set to 0"}`),[!1,a])}const ET=/^(?:(\w+):)\/\/(?:(\w+)(?::(\w+)?)?@)([\w.-]+)(?::(\d+))?\/(.+)/;function xT(e){return e==="http"||e==="https"}function pi(e,t=!1){const{host:n,path:r,pass:i,port:a,projectId:c,protocol:d,publicKey:f}=e;return`${d}://${f}${t&&i?`:${i}`:""}@${n}${a?`:${a}`:""}/${r&&`${r}/`}${c}`}function kT(e){const t=ET.exec(e);if(!t){br(()=>{console.error(`Invalid Sentry Dsn: ${e}`)});return}const[n,r,i="",a="",c="",d=""]=t.slice(1);let f="",h=d;const y=h.split("/");if(y.length>1&&(f=y.slice(0,-1).join("/"),h=y.pop()),h){const g=h.match(/^\d+/);g&&(h=g[0])}return Pg({host:a,pass:i,path:f,projectId:h,port:c,protocol:n,publicKey:r})}function Pg(e){return{protocol:e.protocol,publicKey:e.publicKey||"",pass:e.pass||"",host:e.host,port:e.port||"",path:e.path||"",projectId:e.projectId}}function TT(e){if(!Tr)return!0;const{port:t,projectId:n,protocol:r}=e;return["protocol","publicKey","host","projectId"].find(c=>e[c]?!1:(X.error(`Invalid Sentry Dsn: ${c} missing`),!0))?!1:n.match(/^\d+$/)?xT(r)?t&&isNaN(parseInt(t,10))?(X.error(`Invalid Sentry Dsn: Invalid port ${t}`),!1):!0:(X.error(`Invalid Sentry Dsn: Invalid protocol ${r}`),!1):(X.error(`Invalid Sentry Dsn: Invalid projectId ${n}`),!1)}function bT(e){const t=typeof e=="string"?kT(e):Pg(e);if(!(!t||!TT(t)))return t}function IT(){const e=typeof WeakSet=="function",t=e?new WeakSet:[];function n(i){if(e)return t.has(i)?!0:(t.add(i),!1);for(let a=0;a<t.length;a++)if(t[a]===i)return!0;return t.push(i),!1}function r(i){if(e)t.delete(i);else for(let a=0;a<t.length;a++)if(t[a]===i){t.splice(a,1);break}}return[n,r]}function Rn(e,t=100,n=1/0){try{return cd("",e,t,n)}catch(r){return{ERROR:`**non-serializable** (${r})`}}}function Ng(e,t=3,n=100*1024){const r=Rn(e,t);return OT(r)>n?Ng(e,t-1,n):r}function cd(e,t,n=1/0,r=1/0,i=IT()){const[a,c]=i;if(t==null||["boolean","string"].includes(typeof t)||typeof t=="number"&&Number.isFinite(t))return t;const d=CT(e,t);if(!d.startsWith("[object "))return d;if(t.__sentry_skip_normalization__)return t;const f=typeof t.__sentry_override_normalization_depth__=="number"?t.__sentry_override_normalization_depth__:n;if(f===0)return d.replace("object ","");if(a(t))return"[Circular ~]";const h=t;if(h&&typeof h.toJSON=="function")try{const x=h.toJSON();return cd("",x,f-1,r,i)}catch{}const y=Array.isArray(t)?[]:{};let g=0;const w=ng(t);for(const x in w){if(!Object.prototype.hasOwnProperty.call(w,x))continue;if(g>=r){y[x]="[MaxProperties ~]";break}const _=w[x];y[x]=cd(x,_,f-1,r,i),g++}return c(t),y}function CT(e,t){try{if(e==="domain"&&t&&typeof t=="object"&&t._events)return"[Domain]";if(e==="domainEmitter")return"[DomainEmitter]";if(typeof global<"u"&&t===global)return"[Global]";if(typeof window<"u"&&t===window)return"[Window]";if(typeof document<"u"&&t===document)return"[Document]";if(Xm(t))return"[VueViewModel]";if(Nk(t))return"[SyntheticEvent]";if(typeof t=="number"&&!Number.isFinite(t))return`[${t}]`;if(typeof t=="function")return`[Function: ${nr(t)}]`;if(typeof t=="symbol")return`[${String(t)}]`;if(typeof t=="bigint")return`[BigInt: ${String(t)}]`;const n=RT(t);return/^HTML(\w*)Element$/.test(n)?`[HTMLElement: ${n}]`:`[object ${n}]`}catch(n){return`**non-serializable** (${n})`}}function RT(e){const t=Object.getPrototypeOf(e);return t?t.constructor.name:"null prototype"}function AT(e){return~-encodeURI(e).split(/%..|./).length}function OT(e){return AT(JSON.stringify(e))}function _s(e,t=[]){return[e,t]}function PT(e,t){const[n,r]=e;return[n,[...r,t]]}function Mg(e,t){const n=e[1];for(const r of n){const i=r[0].type;if(t(r,i))return!0}return!1}function ud(e){return Ne.__SENTRY__&&Ne.__SENTRY__.encodePolyfill?Ne.__SENTRY__.encodePolyfill(e):new TextEncoder().encode(e)}function NT(e){const[t,n]=e;let r=JSON.stringify(t);function i(a){typeof r=="string"?r=typeof a=="string"?r+a:[ud(r),a]:r.push(typeof a=="string"?ud(a):a)}for(const a of n){const[c,d]=a;if(i(`
${JSON.stringify(c)}
`),typeof d=="string"||d instanceof Uint8Array)i(d);else{let f;try{f=JSON.stringify(d)}catch{f=JSON.stringify(Rn(d))}i(f)}}return typeof r=="string"?r:MT(r)}function MT(e){const t=e.reduce((i,a)=>i+a.length,0),n=new Uint8Array(t);let r=0;for(const i of e)n.set(i,r),r+=i.length;return n}function LT(e){return[{type:"span"},e]}function jT(e){const t=typeof e.data=="string"?ud(e.data):e.data;return[dt({type:"attachment",length:t.length,filename:e.filename,content_type:e.contentType,attachment_type:e.attachmentType}),t]}const DT={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 Lg(e){return DT[e]}function dd(e){if(!e||!e.sdk)return;const{name:t,version:n}=e.sdk;return{name:t,version:n}}function jg(e,t,n,r){const i=e.sdkProcessingMetadata&&e.sdkProcessingMetadata.dynamicSamplingContext;return{event_id:e.event_id,sent_at:new Date().toISOString(),...t&&{sdk:t},...!!n&&r&&{dsn:pi(r)},...i&&{trace:dt({...i})}}}function $T(e,t){return t&&(e.sdk=e.sdk||{},e.sdk.name=e.sdk.name||t.name,e.sdk.version=e.sdk.version||t.version,e.sdk.integrations=[...e.sdk.integrations||[],...t.integrations||[]],e.sdk.packages=[...e.sdk.packages||[],...t.packages||[]]),e}function FT(e,t,n,r){const i=dd(n),a={sent_at:new Date().toISOString(),...i&&{sdk:i},...!!r&&t&&{dsn:pi(t)}},c="aggregates"in e?[{type:"sessions"},e]:[{type:"session"},e.toJSON()];return _s(a,[c])}function BT(e,t,n,r){const i=dd(n),a=e.type&&e.type!=="replay_event"?e.type:"event";$T(e,n&&n.sdk);const c=jg(e,i,r,t);return delete e.sdkProcessingMetadata,_s(c,[[{type:a},e]])}function zT(e,t){function n(y){return!!y.trace_id&&!!y.public_key}const r=ws(e[0]),i=t&&t.getDsn(),a=t&&t.getOptions().tunnel,c={sent_at:new Date().toISOString(),...n(r)&&{trace:r},...!!a&&i&&{dsn:pi(i)}},d=t&&t.getOptions().beforeSendSpan,f=d?y=>{const g=d(Fe(y));return g||xg(),g}:y=>Fe(y),h=[];for(const y of e){const g=f(y);g&&h.push(LT(g))}return _s(c,h)}function UT(e,t,n,r=vt()){const i=r&&bt(r);i&&(Ee&&X.log(`[Measurement] Setting measurement on root span: ${e} = ${t} ${n}`),i.addEvent(e,{[Qa]:t,[Ka]:n}))}function Dg(e){if(!e||e.length===0)return;const t={};return e.forEach(n=>{const r=n.attributes||{},i=r[Ka],a=r[Qa];typeof i=="string"&&typeof a=="number"&&(t[n.name]={value:a,unit:i})}),t}const $g=1e3;class fd{constructor(t={}){this._traceId=t.traceId||Or(),this._spanId=t.spanId||Pr(),this._startTime=t.startTimestamp||Bt(),this._attributes={},this.setAttributes({[gt]:"manual",[gs]:t.op,...t.attributes}),this._name=t.name,t.parentSpanId&&(this._parentSpanId=t.parentSpanId),"sampled"in t&&(this._sampled=t.sampled),t.endTimestamp&&(this._endTime=t.endTimestamp),this._events=[],this._isStandaloneSpan=t.isStandalone,this._endTime&&this._onSpanEnded()}addLink(t){return this}addLinks(t){return this}recordException(t,n){}spanContext(){const{_spanId:t,_traceId:n,_sampled:r}=this;return{spanId:t,traceId:n,traceFlags:r?vg:yg}}setAttribute(t,n){return n===void 0?delete this._attributes[t]:this._attributes[t]=n,this}setAttributes(t){return Object.keys(t).forEach(n=>this.setAttribute(n,t[n])),this}updateStartTime(t){this._startTime=ys(t)}setStatus(t){return this._status=t,this}updateName(t){return this._name=t,this.setAttribute(Hn,"custom"),this}end(t){this._endTime||(this._endTime=ys(t),wT(this),this._onSpanEnded())}getSpanJSON(){return dt({data:this._attributes,description:this._name,op:this._attributes[gs],parent_span_id:this._parentSpanId,span_id:this._spanId,start_timestamp:this._startTime,status:_g(this._status),timestamp:this._endTime,trace_id:this._traceId,origin:this._attributes[gt],_metrics_summary:nd(this),profile_id:this._attributes[tT],exclusive_time:this._attributes[sd],measurements:Dg(this._events),is_segment:this._isStandaloneSpan&&bt(this)===this||void 0,segment_id:this._isStandaloneSpan?bt(this).spanContext().spanId:void 0})}isRecording(){return!this._endTime&&!!this._sampled}addEvent(t,n,r){Ee&&X.log("[Tracing] Adding an event to span:",t);const i=Fg(n)?n:r||Bt(),a=Fg(n)?{}:n||{},c={name:t,time:ys(i),attributes:a};return this._events.push(c),this}isStandaloneSpan(){return!!this._isStandaloneSpan}_onSpanEnded(){const t=Ae();if(t&&t.emit("spanEnd",this),!(this._isStandaloneSpan||this===bt(this)))return;if(this._isStandaloneSpan){this._sampled?WT(zT([this],t)):(Ee&&X.log("[Tracing] Discarding standalone span because its trace was not chosen to be sampled."),t&&t.recordDroppedEvent("sample_rate","span"));return}const r=this._convertSpanToTransaction();r&&(Ig(this).scope||Ve()).captureEvent(r)}_convertSpanToTransaction(){if(!Bg(Fe(this)))return;this._name||(Ee&&X.warn("Transaction has no name, falling back to `<unlabeled transaction>`."),this._name="<unlabeled transaction>");const{scope:t,isolationScope:n}=Ig(this),i=(t||Ve()).getClient()||Ae();if(this._sampled!==!0){Ee&&X.log("[Tracing] Discarding transaction because its trace was not chosen to be sampled."),i&&i.recordDroppedEvent("sample_rate","transaction");return}const c=Xa(this).filter(g=>g!==this&&!HT(g)).map(g=>Fe(g)).filter(Bg),d=this._attributes[Hn];delete this._attributes[ug],c.forEach(g=>{g.data&&delete g.data[ug]});const f={contexts:{trace:dT(this)},spans:c.length>$g?c.sort((g,w)=>g.start_timestamp-w.start_timestamp).slice(0,$g):c,start_timestamp:this._startTime,timestamp:this._endTime,transaction:this._name,type:"transaction",sdkProcessingMetadata:{capturedSpanScope:t,capturedSpanIsolationScope:n,...dt({dynamicSamplingContext:ws(this)})},_metrics_summary:nd(this),...d&&{transaction_info:{source:d}}},h=Dg(this._events);return h&&Object.keys(h).length&&(Ee&&X.log("[Measurements] Adding measurements to transaction event",JSON.stringify(h,void 0,2)),f.measurements=h),f}}function Fg(e){return e&&typeof e=="number"||e instanceof Date||Array.isArray(e)}function Bg(e){return!!e.start_timestamp&&!!e.timestamp&&!!e.span_id&&!!e.trace_id}function HT(e){return e instanceof fd&&e.isStandaloneSpan()}function WT(e){const t=Ae();if(!t)return;const n=e[1];if(!n||n.length===0){t.recordDroppedEvent("before_send","span");return}t.sendEnvelope(e)}const zg="__SENTRY_SUPPRESS_TRACING__";function hi(e){const t=Hg();if(t.startInactiveSpan)return t.startInactiveSpan(e);const n=VT(e),{forceTransaction:r,parentSpan:i}=e;return(e.scope?c=>td(e.scope,c):i!==void 0?c=>Ug(i,c):c=>c())(()=>{const c=Ve(),d=YT(c);return e.onlyIfParent&&!d?new lo:qT({parentSpan:d,spanArguments:n,forceTransaction:r,scope:c})})}function Ug(e,t){const n=Hg();return n.withActiveSpan?n.withActiveSpan(e,t):td(r=>(fi(r,e||void 0),t(r)))}function qT({parentSpan:e,spanArguments:t,forceTransaction:n,scope:r}){if(!Nr())return new lo;const i=Cn();let a;if(e&&!n)a=GT(e,r,t),Eg(e,a);else if(e){const c=ws(e),{traceId:d,spanId:f}=e.spanContext(),h=vs(e);a=Wg({traceId:d,parentSpanId:f,...t},r,h),Rg(a,c)}else{const{traceId:c,dsc:d,parentSpanId:f,sampled:h}={...i.getPropagationContext(),...r.getPropagationContext()};a=Wg({traceId:c,parentSpanId:f,...t},r,h),d&&Rg(a,d)}return ST(a),vT(a,r,i),a}function VT(e){const n={isStandalone:(e.experimental||{}).standalone,...e};if(e.startTime){const r={...n};return r.startTimestamp=ys(e.startTime),delete r.startTime,r}return n}function Hg(){const e=hs();return ao(e)}function Wg(e,t,n){const r=Ae(),i=r&&r.getOptions()||{},{name:a="",attributes:c}=e,[d,f]=t.getScopeData().sdkProcessingMetadata[zg]?[!1]:_T(i,{name:a,parentSampled:n,attributes:c,transactionContext:{name:a,parentSampled:n}}),h=new fd({...e,attributes:{[Hn]:"custom",...e.attributes},sampled:d});return f!==void 0&&h.setAttribute(cg,f),r&&r.emit("spanStart",h),h}function GT(e,t,n){const{spanId:r,traceId:i}=e.spanContext(),a=t.getScopeData().sdkProcessingMetadata[zg]?!1:vs(e),c=a?new fd({...n,parentSpanId:r,traceId:i,sampled:a}):new lo({traceId:i});Eg(e,c);const d=Ae();return d&&(d.emit("spanStart",c),n.endTimestamp&&d.emit("spanEnd",c)),c}function YT(e){const t=Ya(e);if(!t)return;const n=Ae();return(n?n.getOptions():{}).parentSpanIsAlwaysRootSpan?bt(t):t}const Za={idleTimeout:1e3,finalTimeout:3e4,childSpanTimeout:15e3},KT="heartbeatFailed",QT="idleTimeout",XT="finalTimeout",JT="externalFinish";function qg(e,t={}){const n=new Map;let r=!1,i,a=JT,c=!t.disableAutoFinish;const d=[],{idleTimeout:f=Za.idleTimeout,finalTimeout:h=Za.finalTimeout,childSpanTimeout:y=Za.childSpanTimeout,beforeSpanEnd:g}=t,w=Ae();if(!w||!Nr())return new lo;const x=Ve(),_=vt(),E=ZT(e);E.end=new Proxy(E.end,{apply(M,L,U){g&&g(E);const[te,...K]=U,oe=te||Bt(),ae=ys(oe),ye=Xa(E).filter(W=>W!==E);if(!ye.length)return z(ae),Reflect.apply(M,L,[ae,...K]);const Ie=ye.map(W=>Fe(W).timestamp).filter(W=>!!W),We=Ie.length?Math.max(...Ie):void 0,ce=Fe(E).start_timestamp,ke=Math.min(ce?ce+h/1e3:1/0,Math.max(ce||-1/0,Math.min(ae,We||1/0)));return z(ke),Reflect.apply(M,L,[ke,...K])}});function k(){i&&(clearTimeout(i),i=void 0)}function O(M){k(),i=setTimeout(()=>{!r&&n.size===0&&c&&(a=QT,E.end(M))},f)}function R(M){i=setTimeout(()=>{!r&&c&&(a=KT,E.end(M))},y)}function $(M){k(),n.set(M,!0);const L=Bt();R(L+y/1e3)}function H(M){if(n.has(M)&&n.delete(M),n.size===0){const L=Bt();O(L+f/1e3)}}function z(M){r=!0,n.clear(),d.forEach(ae=>ae()),fi(x,_);const L=Fe(E),{start_timestamp:U}=L;if(!U)return;(L.data||{})[rd]||E.setAttribute(rd,a),X.log(`[Tracing] Idle span "${L.op}" finished`);const K=Xa(E).filter(ae=>ae!==E);let oe=0;K.forEach(ae=>{ae.isRecording()&&(ae.setStatus({code:yt,message:"cancelled"}),ae.end(M),Ee&&X.log("[Tracing] Cancelling span since span ended early",JSON.stringify(ae,void 0,2)));const ye=Fe(ae),{timestamp:Ie=0,start_timestamp:We=0}=ye,ce=We<=M,ke=(h+f)/1e3,W=Ie-We<=ke;if(Ee){const re=JSON.stringify(ae,void 0,2);ce?W||X.log("[Tracing] Discarding span since it finished after idle span final timeout",re):X.log("[Tracing] Discarding span since it happened after idle span was finished",re)}(!W||!ce)&&(gT(E,ae),oe++)}),oe>0&&E.setAttribute("sentry.idle_span_discarded_spans",oe)}return d.push(w.on("spanStart",M=>{if(r||M===E||Fe(M).timestamp)return;Xa(E).includes(M)&&$(M.spanContext().spanId)})),d.push(w.on("spanEnd",M=>{r||H(M.spanContext().spanId)})),d.push(w.on("idleSpanEnableAutoFinish",M=>{M===E&&(c=!0,O(),n.size&&R())})),t.disableAutoFinish||O(),setTimeout(()=>{r||(E.setStatus({code:yt,message:"deadline_exceeded"}),a=XT,E.end())},h),E}function ZT(e){const t=hi(e);return fi(Ve(),t),Ee&&X.log("[Tracing] Started span is an idle span"),t}function pd(e,t,n,r=0){return new Sn((i,a)=>{const c=e[r];if(t===null||typeof c!="function")i(t);else{const d=c({...t},n);Ee&&c.id&&d===null&&X.log(`Event processor "${c.id}" dropped event`),qa(d)?d.then(f=>pd(e,f,n,r+1).then(i)).then(null,a):pd(e,d,n,r+1).then(i).then(null,a)}})}let el,Vg,tl;function eb(e){const t=Ne._sentryDebugIds;if(!t)return{};const n=Object.keys(t);return tl&&n.length===Vg||(Vg=n.length,tl=n.reduce((r,i)=>{el||(el={});const a=el[i];if(a)r[a[0]]=a[1];else{const c=e(i);for(let d=c.length-1;d>=0;d--){const f=c[d],h=f&&f.filename,y=t[i];if(h&&y){r[h]=y,el[i]=[h,y];break}}}return r},{})),tl}function tb(e,t){const{fingerprint:n,span:r,breadcrumbs:i,sdkProcessingMetadata:a}=t;nb(e,t),r&&ob(e,r),ib(e,n),rb(e,i),sb(e,a)}function Gg(e,t){const{extra:n,tags:r,user:i,contexts:a,level:c,sdkProcessingMetadata:d,breadcrumbs:f,fingerprint:h,eventProcessors:y,attachments:g,propagationContext:w,transactionName:x,span:_}=t;nl(e,"extra",n),nl(e,"tags",r),nl(e,"user",i),nl(e,"contexts",a),e.sdkProcessingMetadata=Ga(e.sdkProcessingMetadata,d,2),c&&(e.level=c),x&&(e.transactionName=x),_&&(e.span=_),f.length&&(e.breadcrumbs=[...e.breadcrumbs,...f]),h.length&&(e.fingerprint=[...e.fingerprint,...h]),y.length&&(e.eventProcessors=[...e.eventProcessors,...y]),g.length&&(e.attachments=[...e.attachments,...g]),e.propagationContext={...e.propagationContext,...w}}function nl(e,t,n){e[t]=Ga(e[t],n,1)}function nb(e,t){const{extra:n,tags:r,user:i,contexts:a,level:c,transactionName:d}=t,f=dt(n);f&&Object.keys(f).length&&(e.extra={...f,...e.extra});const h=dt(r);h&&Object.keys(h).length&&(e.tags={...h,...e.tags});const y=dt(i);y&&Object.keys(y).length&&(e.user={...y,...e.user});const g=dt(a);g&&Object.keys(g).length&&(e.contexts={...g,...e.contexts}),c&&(e.level=c),d&&e.type!=="transaction"&&(e.transaction=d)}function rb(e,t){const n=[...e.breadcrumbs||[],...t];e.breadcrumbs=n.length?n:void 0}function sb(e,t){e.sdkProcessingMetadata={...e.sdkProcessingMetadata,...t}}function ob(e,t){e.contexts={trace:fT(t),...e.contexts},e.sdkProcessingMetadata={dynamicSamplingContext:ws(t),...e.sdkProcessingMetadata};const n=bt(t),r=Fe(n).description;r&&!e.transaction&&e.type==="transaction"&&(e.transaction=r)}function ib(e,t){e.fingerprint=e.fingerprint?Array.isArray(e.fingerprint)?e.fingerprint:[e.fingerprint]:[],t&&(e.fingerprint=e.fingerprint.concat(t)),e.fingerprint&&!e.fingerprint.length&&delete e.fingerprint}function Yg(e,t,n,r,i,a){const{normalizeDepth:c=3,normalizeMaxBreadth:d=1e3}=e,f={...t,event_id:t.event_id||n.event_id||on(),timestamp:t.timestamp||di()},h=n.integrations||e.integrations.map(k=>k.name);ab(f,e),ub(f,h),i&&i.emit("applyFrameMetadata",t),t.type===void 0&&lb(f,e.stackParser);const y=fb(r,n.captureContext);n.mechanism&&so(f,n.mechanism);const g=i?i.getEventProcessors():[],w=Jk().getScopeData();if(a){const k=a.getScopeData();Gg(w,k)}if(y){const k=y.getScopeData();Gg(w,k)}const x=[...n.attachments||[],...w.attachments];x.length&&(n.attachments=x),tb(f,w);const _=[...g,...w.eventProcessors];return pd(_,f,n).then(k=>(k&&cb(k),typeof c=="number"&&c>0?db(k,c,d):k))}function ab(e,t){const{environment:n,release:r,dist:i,maxValueLength:a=250}=t;e.environment=e.environment||n||ld,!e.release&&r&&(e.release=r),!e.dist&&i&&(e.dist=i),e.message&&(e.message=ro(e.message,a));const c=e.exception&&e.exception.values&&e.exception.values[0];c&&c.value&&(c.value=ro(c.value,a));const d=e.request;d&&d.url&&(d.url=ro(d.url,a))}function lb(e,t){const n=eb(t);try{e.exception.values.forEach(r=>{r.stacktrace.frames.forEach(i=>{n&&i.filename&&(i.debug_id=n[i.filename])})})}catch{}}function cb(e){const t={};try{e.exception.values.forEach(r=>{r.stacktrace.frames.forEach(i=>{i.debug_id&&(i.abs_path?t[i.abs_path]=i.debug_id:i.filename&&(t[i.filename]=i.debug_id),delete i.debug_id)})})}catch{}if(Object.keys(t).length===0)return;e.debug_meta=e.debug_meta||{},e.debug_meta.images=e.debug_meta.images||[];const n=e.debug_meta.images;Object.entries(t).forEach(([r,i])=>{n.push({type:"sourcemap",code_file:r,debug_id:i})})}function ub(e,t){t.length>0&&(e.sdk=e.sdk||{},e.sdk.integrations=[...e.sdk.integrations||[],...t])}function db(e,t,n){if(!e)return null;const r={...e,...e.breadcrumbs&&{breadcrumbs:e.breadcrumbs.map(i=>({...i,...i.data&&{data:Rn(i.data,t,n)}}))},...e.user&&{user:Rn(e.user,t,n)},...e.contexts&&{contexts:Rn(e.contexts,t,n)},...e.extra&&{extra:Rn(e.extra,t,n)}};return e.contexts&&e.contexts.trace&&r.contexts&&(r.contexts.trace=e.contexts.trace,e.contexts.trace.data&&(r.contexts.trace.data=Rn(e.contexts.trace.data,t,n))),e.spans&&(r.spans=e.spans.map(i=>({...i,...i.data&&{data:Rn(i.data,t,n)}}))),e.contexts&&e.contexts.flags&&r.contexts&&(r.contexts.flags=Rn(e.contexts.flags,3,n)),r}function fb(e,t){if(!t)return e;const n=e?e.clone():new ms;return n.update(t),n}function iB(e){}function An(e,t){return Ve().captureException(e,void 0)}function Kg(e,t){return Ve().captureEvent(e,t)}function Qg(e,t){Cn().setContext(e,t)}function pb(){const e=Ae();return!!e&&e.getOptions().enabled!==!1&&!!e.getTransport()}function hb(e){Cn().addEventProcessor(e)}function Xg(e){const t=Ae(),n=Cn(),r=Ve(),{release:i,environment:a=ld}=t&&t.getOptions()||{},{userAgent:c}=Ne.navigator||{},d=Uk({release:i,environment:a,user:r.getUser()||n.getUser(),...c&&{userAgent:c},...e}),f=n.getSession();return f&&f.status==="ok"&&oo(f,{status:"exited"}),Jg(),n.setSession(d),r.setSession(d),d}function Jg(){const e=Cn(),t=Ve(),n=t.getSession()||e.getSession();n&&Hk(n),Zg(),e.setSession(),t.setSession()}function Zg(){const e=Cn(),t=Ve(),n=Ae(),r=t.getSession()||e.getSession();r&&n&&n.captureSession(r)}function ey(e=!1){if(e){Jg();return}Zg()}const mb="7";function gb(e){const t=e.protocol?`${e.protocol}:`:"",n=e.port?`:${e.port}`:"";return`${t}//${e.host}${n}${e.path?`/${e.path}`:""}/api/`}function yb(e){return`${gb(e)}${e.projectId}/envelope/`}function vb(e,t){const n={sentry_version:mb};return e.publicKey&&(n.sentry_key=e.publicKey),t&&(n.sentry_client=`${t.name}/${t.version}`),new URLSearchParams(n).toString()}function Sb(e,t,n){return t||`${yb(e)}?${vb(e,n)}`}const ty=[];function wb(e){const t={};return e.forEach(n=>{const{name:r}=n,i=t[r];i&&!i.isDefaultInstance&&n.isDefaultInstance||(t[r]=n)}),Object.values(t)}function _b(e){const t=e.defaultIntegrations||[],n=e.integrations;t.forEach(c=>{c.isDefaultInstance=!0});let r;if(Array.isArray(n))r=[...t,...n];else if(typeof n=="function"){const c=n(t);r=Array.isArray(c)?c:[c]}else r=t;const i=wb(r),a=i.findIndex(c=>c.name==="Debug");if(a>-1){const[c]=i.splice(a,1);i.push(c)}return i}function Eb(e,t){const n={};return t.forEach(r=>{r&&ry(e,r,n)}),n}function ny(e,t){for(const n of t)n&&n.afterAllSetup&&n.afterAllSetup(e)}function ry(e,t,n){if(n[t.name]){Ee&&X.log(`Integration skipped because it was already installed: ${t.name}`);return}if(n[t.name]=t,ty.indexOf(t.name)===-1&&typeof t.setupOnce=="function"&&(t.setupOnce(),ty.push(t.name)),t.setup&&typeof t.setup=="function"&&t.setup(e),typeof t.preprocessEvent=="function"){const r=t.preprocessEvent.bind(t);e.on("preprocessEvent",(i,a)=>r(i,a,e))}if(typeof t.processEvent=="function"){const r=t.processEvent.bind(t),i=Object.assign((a,c)=>r(a,c,e),{id:t.name});e.addEventProcessor(i)}Ee&&X.log(`Integration installed: ${t.name}`)}function aB(e){return e}function xb(e,t,n){const r=[{type:"client_report"},{timestamp:di(),discarded_events:e}];return _s(t?{dsn:t}:{},[r])}class Wn extends Error{constructor(t,n="warn"){super(t),this.message=t,this.name=new.target.prototype.constructor.name,Object.setPrototypeOf(this,new.target.prototype),this.logLevel=n}}const sy="Not capturing exception because it's already been captured.";class kb{constructor(t){if(this._options=t,this._integrations={},this._numProcessing=0,this._outcomes={},this._hooks={},this._eventProcessors=[],t.dsn?this._dsn=bT(t.dsn):Ee&&X.warn("No DSN provided, client will not send events."),this._dsn){const i=Sb(this._dsn,t.tunnel,t._metadata?t._metadata.sdk:void 0);this._transport=t.transport({tunnel:this._options.tunnel,recordDroppedEvent:this.recordDroppedEvent.bind(this),...t.transportOptions,url:i})}const r=["enableTracing","tracesSampleRate","tracesSampler"].find(i=>i in t&&t[i]==null);r&&br(()=>{console.warn(`[Sentry] Deprecation warning: \`${r}\` is set to undefined, which leads to tracing being enabled. In v9, a value of \`undefined\` will result in tracing being disabled.`)})}captureException(t,n,r){const i=on();if(ag(t))return Ee&&X.log(sy),i;const a={event_id:i,...n};return this._process(this.eventFromException(t,a).then(c=>this._captureEvent(c,a,r))),a.event_id}captureMessage(t,n,r,i){const a={event_id:on(),...r},c=Yu(t)?t:String(t),d=Ku(t)?this.eventFromMessage(c,n,a):this.eventFromException(t,a);return this._process(d.then(f=>this._captureEvent(f,a,i))),a.event_id}captureEvent(t,n,r){const i=on();if(n&&n.originalException&&ag(n.originalException))return Ee&&X.log(sy),i;const a={event_id:i,...n},d=(t.sdkProcessingMetadata||{}).capturedSpanScope;return this._process(this._captureEvent(t,a,d||r)),a.event_id}captureSession(t){typeof t.release!="string"?Ee&&X.warn("Discarded session because of missing or non-string release"):(this.sendSession(t),oo(t,{init:!1}))}getDsn(){return this._dsn}getOptions(){return this._options}getSdkMetadata(){return this._options._metadata}getTransport(){return this._transport}flush(t){const n=this._transport;return n?(this.emit("flush"),this._isClientDoneProcessing(t).then(r=>n.flush(t).then(i=>r&&i))):ar(!0)}close(t){return this.flush(t).then(n=>(this.getOptions().enabled=!1,this.emit("close"),n))}getEventProcessors(){return this._eventProcessors}addEventProcessor(t){this._eventProcessors.push(t)}init(){(this._isEnabled()||this._options.integrations.some(({name:t})=>t.startsWith("Spotlight")))&&this._setupIntegrations()}getIntegrationByName(t){return this._integrations[t]}addIntegration(t){const n=this._integrations[t.name];ry(this,t,this._integrations),n||ny(this,[t])}sendEvent(t,n={}){this.emit("beforeSendEvent",t,n);let r=BT(t,this._dsn,this._options._metadata,this._options.tunnel);for(const a of n.attachments||[])r=PT(r,jT(a));const i=this.sendEnvelope(r);i&&i.then(a=>this.emit("afterSendEvent",t,a),null)}sendSession(t){const n=FT(t,this._dsn,this._options._metadata,this._options.tunnel);this.sendEnvelope(n)}recordDroppedEvent(t,n,r){if(this._options.sendClientReports){const i=typeof r=="number"?r:1,a=`${t}:${n}`;Ee&&X.log(`Recording outcome: "${a}"${i>1?` (${i} times)`:""}`),this._outcomes[a]=(this._outcomes[a]||0)+i}}on(t,n){const r=this._hooks[t]=this._hooks[t]||[];return r.push(n),()=>{const i=r.indexOf(n);i>-1&&r.splice(i,1)}}emit(t,...n){const r=this._hooks[t];r&&r.forEach(i=>i(...n))}sendEnvelope(t){return this.emit("beforeEnvelope",t),this._isEnabled()&&this._transport?this._transport.send(t).then(null,n=>(Ee&&X.error("Error while sending envelope:",n),n)):(Ee&&X.error("Transport disabled"),ar({}))}_setupIntegrations(){const{integrations:t}=this._options;this._integrations=Eb(this,t),ny(this,t)}_updateSessionFromEvent(t,n){let r=!1,i=!1;const a=n.exception&&n.exception.values;if(a){i=!0;for(const f of a){const h=f.mechanism;if(h&&h.handled===!1){r=!0;break}}}const c=t.status==="ok";(c&&t.errors===0||c&&r)&&(oo(t,{...r&&{status:"crashed"},errors:t.errors||Number(i||r)}),this.captureSession(t))}_isClientDoneProcessing(t){return new Sn(n=>{let r=0;const i=1,a=setInterval(()=>{this._numProcessing==0?(clearInterval(a),n(!0)):(r+=i,t&&r>=t&&(clearInterval(a),n(!1)))},i)})}_isEnabled(){return this.getOptions().enabled!==!1&&this._transport!==void 0}_prepareEvent(t,n,r=Ve(),i=Cn()){const a=this.getOptions(),c=Object.keys(this._integrations);return!n.integrations&&c.length>0&&(n.integrations=c),this.emit("preprocessEvent",t,n),t.type||i.setLastEventId(t.event_id||n.event_id),Yg(a,t,n,r,this,i).then(d=>{if(d===null)return d;d.contexts={trace:Zk(r),...d.contexts};const f=Og(this,r);return d.sdkProcessingMetadata={dynamicSamplingContext:f,...d.sdkProcessingMetadata},d})}_captureEvent(t,n={},r){return this._processEvent(t,n,r).then(i=>i.event_id,i=>{if(Ee){const a=i;a.logLevel==="log"?X.log(a.message):X.warn(a)}})}_processEvent(t,n,r){const i=this.getOptions(),{sampleRate:a}=i,c=iy(t),d=oy(t),f=t.type||"error",h=`before send for type \`${f}\``,y=typeof a>"u"?void 0:Ja(a);if(d&&typeof y=="number"&&Math.random()>y)return this.recordDroppedEvent("sample_rate","error",t),Va(new Wn(`Discarding event because it's not included in the random sample (sampling rate = ${a})`,"log"));const g=f==="replay_event"?"replay":f,x=(t.sdkProcessingMetadata||{}).capturedSpanIsolationScope;return this._prepareEvent(t,n,r,x).then(_=>{if(_===null)throw this.recordDroppedEvent("event_processor",g,t),new Wn("An event processor returned `null`, will not send event.","log");if(n.data&&n.data.__sentry__===!0)return _;const k=bb(this,i,_,n);return Tb(k,h)}).then(_=>{if(_===null){if(this.recordDroppedEvent("before_send",g,t),c){const R=1+(t.spans||[]).length;this.recordDroppedEvent("before_send","span",R)}throw new Wn(`${h} returned \`null\`, will not send event.`,"log")}const E=r&&r.getSession();if(!c&&E&&this._updateSessionFromEvent(E,_),c){const O=_.sdkProcessingMetadata&&_.sdkProcessingMetadata.spanCountBeforeProcessing||0,R=_.spans?_.spans.length:0,$=O-R;$>0&&this.recordDroppedEvent("before_send","span",$)}const k=_.transaction_info;if(c&&k&&_.transaction!==t.transaction){const O="custom";_.transaction_info={...k,source:O}}return this.sendEvent(_,n),_}).then(null,_=>{throw _ instanceof Wn?_:(this.captureException(_,{data:{__sentry__:!0},originalException:_}),new Wn(`Event processing pipeline threw an error, original event will not be sent. Details have been sent as a new event.
Reason: ${_}`))})}_process(t){this._numProcessing++,t.then(n=>(this._numProcessing--,n),n=>(this._numProcessing--,n))}_clearOutcomes(){const t=this._outcomes;return this._outcomes={},Object.entries(t).map(([n,r])=>{const[i,a]=n.split(":");return{reason:i,category:a,quantity:r}})}_flushOutcomes(){Ee&&X.log("Flushing outcomes...");const t=this._clearOutcomes();if(t.length===0){Ee&&X.log("No outcomes to send");return}if(!this._dsn){Ee&&X.log("No dsn provided, will not send outcomes");return}Ee&&X.log("Sending outcomes:",t);const n=xb(t,this._options.tunnel&&pi(this._dsn));this.sendEnvelope(n)}}function Tb(e,t){const n=`${t} must return \`null\` or a valid event.`;if(qa(e))return e.then(r=>{if(!to(r)&&r!==null)throw new Wn(n);return r},r=>{throw new Wn(`${t} rejected with ${r}`)});if(!to(e)&&e!==null)throw new Wn(n);return e}function bb(e,t,n,r){const{beforeSend:i,beforeSendTransaction:a,beforeSendSpan:c}=t;if(oy(n)&&i)return i(n,r);if(iy(n)){if(n.spans&&c){const d=[];for(const f of n.spans){const h=c(f);h?d.push(h):(xg(),e.recordDroppedEvent("before_send","span"))}n.spans=d}if(a){if(n.spans){const d=n.spans.length;n.sdkProcessingMetadata={...n.sdkProcessingMetadata,spanCountBeforeProcessing:d}}return a(n,r)}}return n}function oy(e){return e.type===void 0}function iy(e){return e.type==="transaction"}function Ib(e,t){t.debug===!0&&(Ee?X.enable():br(()=>{console.warn("[Sentry] Cannot initialize SDK with `debug` option using a non-debug bundle.")})),Ve().update(t.initialScope);const r=new e(t);return Cb(r),r.init(),r}function Cb(e){Ve().setClient(e)}function Rb(e){const t=[];function n(){return e===void 0||t.length<e}function r(c){return t.splice(t.indexOf(c),1)[0]||Promise.resolve(void 0)}function i(c){if(!n())return Va(new Wn("Not adding Promise because buffer limit was reached."));const d=c();return t.indexOf(d)===-1&&t.push(d),d.then(()=>r(d)).then(null,()=>r(d).then(null,()=>{})),d}function a(c){return new Sn((d,f)=>{let h=t.length;if(!h)return d(!0);const y=setTimeout(()=>{c&&c>0&&d(!1)},c);t.forEach(g=>{ar(g).then(()=>{--h||(clearTimeout(y),d(!0))},f)})})}return{$:t,add:i,drain:a}}const Ab=60*1e3;function Ob(e,t=Date.now()){const n=parseInt(`${e}`,10);if(!isNaN(n))return n*1e3;const r=Date.parse(`${e}`);return isNaN(r)?Ab:r-t}function Pb(e,t){return e[t]||e.all||0}function ay(e,t,n=Date.now()){return Pb(e,t)>n}function ly(e,{statusCode:t,headers:n},r=Date.now()){const i={...e},a=n&&n["x-sentry-rate-limits"],c=n&&n["retry-after"];if(a)for(const d of a.trim().split(",")){const[f,h,,,y]=d.split(":",5),g=parseInt(f,10),w=(isNaN(g)?60:g)*1e3;if(!h)i.all=r+w;else for(const x of h.split(";"))x==="metric_bucket"?(!y||y.split(";").includes("custom"))&&(i[x]=r+w):i[x]=r+w}else c?i.all=r+Ob(c,r):t===429&&(i.all=r+60*1e3);return i}const Nb=64;function Mb(e,t,n=Rb(e.bufferSize||Nb)){let r={};const i=c=>n.drain(c);function a(c){const d=[];if(Mg(c,(g,w)=>{const x=Lg(w);if(ay(r,x)){const _=cy(g,w);e.recordDroppedEvent("ratelimit_backoff",x,_)}else d.push(g)}),d.length===0)return ar({});const f=_s(c[0],d),h=g=>{Mg(f,(w,x)=>{const _=cy(w,x);e.recordDroppedEvent(g,Lg(x),_)})},y=()=>t({body:NT(f)}).then(g=>(g.statusCode!==void 0&&(g.statusCode<200||g.statusCode>=300)&&Ee&&X.warn(`Sentry responded with status code ${g.statusCode} to sent event.`),r=ly(r,g),g),g=>{throw h("network_error"),g});return n.add(y).then(g=>g,g=>{if(g instanceof Wn)return Ee&&X.error("Skipped sending event because buffer is full."),h("queue_overflow"),ar({});throw g})}return{send:a,flush:i}}function cy(e,t){if(!(t!=="event"&&t!=="transaction"))return Array.isArray(e)?e[1]:void 0}function Lb(e,t){const n=t&&t.getDsn(),r=t&&t.getOptions().tunnel;return Db(e,n)||jb(e,r)}function jb(e,t){return t?uy(e)===uy(t):!1}function Db(e,t){return t?e.includes(t.host):!1}function uy(e){return e[e.length-1]==="/"?e.slice(0,-1):e}function dy(e,t,n=[t],r="npm"){const i=e._metadata||{};i.sdk||(i.sdk={name:`sentry.javascript.${t}`,packages:n.map(a=>({name:`${r}:@sentry/${a}`,version:fs})),version:fs}),e._metadata=i}function fy(e={}){const t=Ae();if(!pb()||!t)return{};const n=hs(),r=ao(n);if(r.getTraceData)return r.getTraceData(e);const i=Ve(),a=e.span||vt(),c=a?pT(a):$b(i),d=a?ws(a):Og(t,i),f=iT(d);return mg.test(c)?{"sentry-trace":c,baggage:f}:(X.warn("Invalid sentry-trace data. Cannot generate trace data"),{})}function $b(e){const{traceId:t,sampled:n,spanId:r}=e.getPropagationContext();return gg(t,r,n)}const Fb=100;function Mr(e,t){const n=Ae(),r=Cn();if(!n)return;const{beforeBreadcrumb:i=null,maxBreadcrumbs:a=Fb}=n.getOptions();if(a<=0)return;const d={timestamp:di(),...e},f=i?br(()=>i(d,t)):d;f!==null&&(n.emit&&n.emit("beforeAddBreadcrumb",f,t),r.addBreadcrumb(f,a))}let py;const Bb="FunctionToString",hy=new WeakMap,zb=()=>({name:Bb,setupOnce(){py=Function.prototype.toString;try{Function.prototype.toString=function(...e){const t=Qu(this),n=hy.has(Ae())&&t!==void 0?t:this;return py.apply(n,e)}}catch{}},setup(e){hy.set(e,!0)}}),Ub=[/^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+$/],Hb="InboundFilters",Wb=(e={})=>({name:Hb,processEvent(t,n,r){const i=r.getOptions(),a=qb(e,i);return Vb(t,a)?null:t}});function qb(e={},t={}){return{allowUrls:[...e.allowUrls||[],...t.allowUrls||[]],denyUrls:[...e.denyUrls||[],...t.denyUrls||[]],ignoreErrors:[...e.ignoreErrors||[],...t.ignoreErrors||[],...e.disableErrorDefaults?[]:Ub],ignoreTransactions:[...e.ignoreTransactions||[],...t.ignoreTransactions||[]],ignoreInternal:e.ignoreInternal!==void 0?e.ignoreInternal:!0}}function Vb(e,t){return t.ignoreInternal&&Jb(e)?(Ee&&X.warn(`Event dropped due to being internal Sentry Error.
Event: ${Ar(e)}`),!0):Gb(e,t.ignoreErrors)?(Ee&&X.warn(`Event dropped due to being matched by \`ignoreErrors\` option.
Event: ${Ar(e)}`),!0):eI(e)?(Ee&&X.warn(`Event dropped due to not having an error message, error type or stacktrace.
Event: ${Ar(e)}`),!0):Yb(e,t.ignoreTransactions)?(Ee&&X.warn(`Event dropped due to being matched by \`ignoreTransactions\` option.
Event: ${Ar(e)}`),!0):Kb(e,t.denyUrls)?(Ee&&X.warn(`Event dropped due to being matched by \`denyUrls\` option.
Event: ${Ar(e)}.
Url: ${rl(e)}`),!0):Qb(e,t.allowUrls)?!1:(Ee&&X.warn(`Event dropped due to not being matched by \`allowUrls\` option.
Event: ${Ar(e)}.
Url: ${rl(e)}`),!0)}function Gb(e,t){return e.type||!t||!t.length?!1:Xb(e).some(n=>Rr(n,t))}function Yb(e,t){if(e.type!=="transaction"||!t||!t.length)return!1;const n=e.transaction;return n?Rr(n,t):!1}function Kb(e,t){if(!t||!t.length)return!1;const n=rl(e);return n?Rr(n,t):!1}function Qb(e,t){if(!t||!t.length)return!0;const n=rl(e);return n?Rr(n,t):!0}function Xb(e){const t=[];e.message&&t.push(e.message);let n;try{n=e.exception.values[e.exception.values.length-1]}catch{}return n&&n.value&&(t.push(n.value),n.type&&t.push(`${n.type}: ${n.value}`)),t}function Jb(e){try{return e.exception.values[0].type==="SentryError"}catch{}return!1}function Zb(e=[]){for(let t=e.length-1;t>=0;t--){const n=e[t];if(n&&n.filename!=="<anonymous>"&&n.filename!=="[native code]")return n.filename||null}return null}function rl(e){try{let t;try{t=e.exception.values[0].stacktrace.frames}catch{}return t?Zb(t):null}catch{return Ee&&X.error(`Cannot extract url for event ${Ar(e)}`),null}}function eI(e){return e.type||!e.exception||!e.exception.values||e.exception.values.length===0?!1:!e.message&&!e.exception.values.some(t=>t.stacktrace||t.type&&t.type!=="Error"||t.value)}function tI(e,t,n=250,r,i,a,c){if(!a.exception||!a.exception.values||!c||!sr(c.originalException,Error))return;const d=a.exception.values.length>0?a.exception.values[a.exception.values.length-1]:void 0;d&&(a.exception.values=nI(hd(e,t,i,c.originalException,r,a.exception.values,d,0),n))}function hd(e,t,n,r,i,a,c,d){if(a.length>=n+1)return a;let f=[...a];if(sr(r[i],Error)){my(c,d);const h=e(t,r[i]),y=f.length;gy(h,i,y,d),f=hd(e,t,n,r[i],i,[h,...f],h,y)}return Array.isArray(r.errors)&&r.errors.forEach((h,y)=>{if(sr(h,Error)){my(c,d);const g=e(t,h),w=f.length;gy(g,`errors[${y}]`,w,d),f=hd(e,t,n,h,i,[g,...f],g,w)}}),f}function my(e,t){e.mechanism=e.mechanism||{type:"generic",handled:!0},e.mechanism={...e.mechanism,...e.type==="AggregateError"&&{is_exception_group:!0},exception_id:t}}function gy(e,t,n,r){e.mechanism=e.mechanism||{type:"generic",handled:!0},e.mechanism={...e.mechanism,type:"chained",source:t,exception_id:n,parent_id:r}}function nI(e,t){return e.map(n=>(n.value&&(n.value=ro(n.value,t)),n))}function Es(e){if(!e)return{};const t=e.match(/^(([^:/?#]+):)?(\/\/([^/?#]*))?([^?#]*)(\?([^#]*))?(#(.*))?$/);if(!t)return{};const n=t[6]||"",r=t[8]||"";return{host:t[4],path:t[5],protocol:t[2],search:n,hash:r,relative:t[5]+n+r}}function rI(e){const t="console";Ir(t,e),Cr(t,sI)}function sI(){"console"in Ne&&Uu.forEach(function(e){e in Ne.console&&Yt(Ne.console,e,function(t){return za[e]=t,function(...n){yn("console",{args:n,level:e});const i=za[e];i&&i.apply(Ne.console,n)}})})}function yy(e){return e==="warn"?"warning":["fatal","error","warning","log","info","debug"].includes(e)?e:"log"}const oI="Dedupe",iI=()=>{let e;return{name:oI,processEvent(t){if(t.type)return t;try{if(aI(t,e))return Ee&&X.warn("Event dropped due to being a duplicate of previously captured event."),null}catch{}return e=t}}};function aI(e,t){return t?!!(lI(e,t)||cI(e,t)):!1}function lI(e,t){const n=e.message,r=t.message;return!(!n&&!r||n&&!r||!n&&r||n!==r||!Sy(e,t)||!vy(e,t))}function cI(e,t){const n=wy(t),r=wy(e);return!(!n||!r||n.type!==r.type||n.value!==r.value||!Sy(e,t)||!vy(e,t))}function vy(e,t){let n=Wm(e),r=Wm(t);if(!n&&!r)return!0;if(n&&!r||!n&&r||(n=n,r=r,r.length!==n.length))return!1;for(let i=0;i<r.length;i++){const a=r[i],c=n[i];if(a.filename!==c.filename||a.lineno!==c.lineno||a.colno!==c.colno||a.function!==c.function)return!1}return!0}function Sy(e,t){let n=e.fingerprint,r=t.fingerprint;if(!n&&!r)return!0;if(n&&!r||!n&&r)return!1;n=n,r=r;try{return n.join("")===r.join("")}catch{return!1}}function wy(e){return e.exception&&e.exception.values&&e.exception.values[0]}function uI(e,t,n,r,i="auto.http.browser"){if(!e.fetchData)return;const a=Nr()&&t(e.fetchData.url);if(e.endTimestamp&&a){const w=e.fetchData.__span;if(!w)return;const x=r[w];x&&(pI(x,e),delete r[w]);return}const{method:c,url:d}=e.fetchData,f=fI(d),h=f?Es(f).host:void 0,y=!!vt(),g=a&&y?hi({name:`${c} ${d}`,attributes:{url:d,type:"fetch","http.method":c,"http.url":f,"server.address":h,[gt]:i,[gs]:"http.client"}}):new lo;if(e.fetchData.__span=g.spanContext().spanId,r[g.spanContext().spanId]=g,n(e.fetchData.url)){const w=e.args[0],x=e.args[1]||{},_=dI(w,x,Nr()&&y?g:void 0);_&&(e.args[1]=x,x.headers=_)}return g}function dI(e,t,n){const r=fy({span:n}),i=r["sentry-trace"],a=r.baggage;if(!i)return;const c=t.headers||(hI(e)?e.headers:void 0);if(c)if(mI(c)){const d=new Headers(c);if(d.set("sentry-trace",i),a){const f=d.get("baggage");if(f){const h=sl(f);d.set("baggage",h?`${h},${a}`:a)}else d.set("baggage",a)}return d}else if(Array.isArray(c)){const d=[...c.filter(f=>!(Array.isArray(f)&&f[0]==="sentry-trace")).map(f=>{if(Array.isArray(f)&&f[0]==="baggage"&&typeof f[1]=="string"){const[h,y,...g]=f;return[h,sl(y),...g]}else return f}),["sentry-trace",i]];return a&&d.push(["baggage",a]),d}else{const d="baggage"in c?c.baggage:void 0;let f=[];return Array.isArray(d)?f=d.map(h=>typeof h=="string"?sl(h):h).filter(h=>h===""):d&&f.push(sl(d)),a&&f.push(a),{...c,"sentry-trace":i,baggage:f.length>0?f.join(","):void 0}}else return{...r}}function fI(e){try{return new URL(e).href}catch{return}}function pI(e,t){if(t.response){fg(e,t.response.status);const n=t.response&&t.response.headers&&t.response.headers.get("content-length");if(n){const r=parseInt(n);r>0&&e.setAttribute("http.response_content_length",r)}}else t.error&&e.setStatus({code:yt,message:"internal_error"});e.end()}function sl(e){return e.split(",").filter(t=>!t.split("=")[0].startsWith(od)).join(",")}function hI(e){return typeof Request<"u"&&sr(e,Request)}function mI(e){return typeof Headers<"u"&&sr(e,Headers)}function _y(e){if(e!==void 0)return e>=400&&e<500?"warning":e>=500?"error":void 0}const md=Ne;function Ey(){if(!("fetch"in md))return!1;try{return new Headers,new Request("http://www.example.com"),new Response,!0}catch{return!1}}function gd(e){return e&&/^function\s+\w+\(\)\s+\{\s+\[native code\]\s+\}$/.test(e.toString())}function gI(){if(typeof EdgeRuntime=="string")return!0;if(!Ey())return!1;if(gd(md.fetch))return!0;let e=!1;const t=md.document;if(t&&typeof t.createElement=="function")try{const n=t.createElement("iframe");n.hidden=!0,t.head.appendChild(n),n.contentWindow&&n.contentWindow.fetch&&(e=gd(n.contentWindow.fetch)),t.head.removeChild(n)}catch(n){Tr&&X.warn("Could not create sandbox iframe for pure fetch check, bailing to window.fetch: ",n)}return e}function xy(e,t){const n="fetch";Ir(n,e),Cr(n,()=>ky(void 0,t))}function yI(e){const t="fetch-body-resolved";Ir(t,e),Cr(t,()=>ky(SI))}function ky(e,t=!1){t&&!gI()||Yt(Ne,"fetch",function(n){return function(...r){const i=new Error,{method:a,url:c}=wI(r),d={args:r,fetchData:{method:a,url:c},startTimestamp:Bt()*1e3,virtualError:i};return e||yn("fetch",{...d}),n.apply(Ne,r).then(async f=>(e?e(f):yn("fetch",{...d,endTimestamp:Bt()*1e3,response:f}),f),f=>{throw yn("fetch",{...d,endTimestamp:Bt()*1e3,error:f}),Gu(f)&&f.stack===void 0&&(f.stack=i.stack,vn(f,"framesToPop",1)),f})}})}async function vI(e,t){if(e&&e.body){const n=e.body,r=n.getReader(),i=setTimeout(()=>{n.cancel().then(null,()=>{})},90*1e3);let a=!0;for(;a;){let c;try{c=setTimeout(()=>{n.cancel().then(null,()=>{})},5e3);const{done:d}=await r.read();clearTimeout(c),d&&(t(),a=!1)}catch{a=!1}finally{clearTimeout(c)}}clearTimeout(i),r.releaseLock(),n.cancel().then(null,()=>{})}}function SI(e){let t;try{t=e.clone()}catch{return}vI(t,()=>{yn("fetch-body-resolved",{endTimestamp:Bt()*1e3,response:e})})}function yd(e,t){return!!e&&typeof e=="object"&&!!e[t]}function Ty(e){return typeof e=="string"?e:e?yd(e,"url")?e.url:e.toString?e.toString():"":""}function wI(e){if(e.length===0)return{method:"GET",url:""};if(e.length===2){const[n,r]=e;return{url:Ty(n),method:yd(r,"method")?String(r.method).toUpperCase():"GET"}}const t=e[0];return{url:Ty(t),method:yd(t,"method")?String(t.method).toUpperCase():"GET"}}function _I(){return typeof __SENTRY_BROWSER_BUNDLE__<"u"&&!!__SENTRY_BROWSER_BUNDLE__}function EI(){return"npm"}function xI(){return!_I()&&Object.prototype.toString.call(typeof process<"u"?process:0)==="[object process]"}function by(){return typeof window<"u"&&(!xI()||kI())}function kI(){const e=Ne.process;return!!e&&e.type==="renderer"}const ol=Ne;function TI(){const e=ol.chrome,t=e&&e.app&&e.app.runtime,n="history"in ol&&!!ol.history.pushState&&!!ol.history.replaceState;return!t&&n}function bI(e,t){return e??t()}function il(e){let t,n=e[0],r=1;for(;r<e.length;){const i=e[r],a=e[r+1];if(r+=2,(i==="optionalAccess"||i==="optionalCall")&&n==null)return;i==="access"||i==="optionalAccess"?(t=n,n=a(n)):(i==="call"||i==="optionalCall")&&(n=a((...c)=>n.call(t,...c)),t=void 0)}return n}const Se=Ne;let vd=0;function Iy(){return vd>0}function II(){vd++,setTimeout(()=>{vd--})}function co(e,t={}){function n(i){return typeof i=="function"}if(!n(e))return e;try{const i=e.__sentry_wrapped__;if(i)return typeof i=="function"?i:e;if(Qu(e))return e}catch{return e}const r=function(...i){try{const a=i.map(c=>co(c,t));return e.apply(this,a)}catch(a){throw II(),td(c=>{c.addEventProcessor(d=>(t.mechanism&&(Ju(d,void 0),so(d,t.mechanism)),d.extra={...d.extra,arguments:i},d)),An(a)}),a}};try{for(const i in e)Object.prototype.hasOwnProperty.call(e,i)&&(r[i]=e[i])}catch{}tg(r,e),vn(e,"__sentry_wrapped__",r);try{Object.getOwnPropertyDescriptor(r,"name").configurable&&Object.defineProperty(r,"name",{get(){return e.name}})}catch{}return r}const qn=typeof __SENTRY_DEBUG__>"u"||__SENTRY_DEBUG__;function Sd(e,t){const n=_d(e,t),r={type:PI(t),value:NI(t)};return n.length&&(r.stacktrace={frames:n}),r.type===void 0&&r.value===""&&(r.value="Unrecoverable error caught"),r}function CI(e,t,n,r){const i=Ae(),a=i&&i.getOptions().normalizeDepth,c=$I(t),d={__serialized__:Ng(t,a)};if(c)return{exception:{values:[Sd(e,c)]},extra:d};const f={exception:{values:[{type:Wa(t)?t.constructor.name:r?"UnhandledRejection":"Error",value:jI(t,{isUnhandledRejection:r})}]},extra:d};if(n){const h=_d(e,n);h.length&&(f.exception.values[0].stacktrace={frames:h})}return f}function wd(e,t){return{exception:{values:[Sd(e,t)]}}}function _d(e,t){const n=t.stacktrace||t.stack||"",r=AI(t),i=OI(t);try{return e(n,r,i)}catch{}return[]}const RI=/Minified React error #\d+;/i;function AI(e){return e&&RI.test(e.message)?1:0}function OI(e){return typeof e.framesToPop=="number"?e.framesToPop:0}function Cy(e){return typeof WebAssembly<"u"&&typeof WebAssembly.Exception<"u"?e instanceof WebAssembly.Exception:!1}function PI(e){const t=e&&e.name;return!t&&Cy(e)?e.message&&Array.isArray(e.message)&&e.message.length==2?e.message[0]:"WebAssembly.Exception":t}function NI(e){const t=e&&e.message;return t?t.error&&typeof t.error.message=="string"?t.error.message:Cy(e)&&Array.isArray(e.message)&&e.message.length==2?e.message[1]:t:"No error message"}function MI(e,t,n,r){const i=n&&n.syntheticException||void 0,a=Ed(e,t,i,r);return so(a),a.level="error",n&&n.event_id&&(a.event_id=n.event_id),ar(a)}function LI(e,t,n="info",r,i){const a=r&&r.syntheticException||void 0,c=xd(e,t,a,i);return c.level=n,r&&r.event_id&&(c.event_id=r.event_id),ar(c)}function Ed(e,t,n,r,i){let a;if(Km(t)&&t.error)return wd(e,t.error);if(Qm(t)||Ak(t)){const c=t;if("stack"in t)a=wd(e,t);else{const d=c.name||(Qm(c)?"DOMError":"DOMException"),f=c.message?`${d}: ${c.message}`:d;a=xd(e,f,n,r),Ju(a,f)}return"code"in c&&(a.tags={...a.tags,"DOMException.code":`${c.code}`}),a}return Gu(t)?wd(e,t):to(t)||Wa(t)?(a=CI(e,t,n,i),so(a,{synthetic:!0}),a):(a=xd(e,t,n,r),Ju(a,`${t}`),so(a,{synthetic:!0}),a)}function xd(e,t,n,r){const i={};if(r&&n){const a=_d(e,n);a.length&&(i.exception={values:[{value:t,stacktrace:{frames:a}}]}),so(i,{synthetic:!0})}if(Yu(t)){const{__sentry_template_string__:a,__sentry_template_values__:c}=t;return i.logentry={message:a,params:c},i}return i.message=t,i}function jI(e,{isUnhandledRejection:t}){const n=$k(e),r=t?"promise rejection":"exception";return Km(e)?`Event \`ErrorEvent\` captured as ${r} with message \`${e.message}\``:Wa(e)?`Event \`${DI(e)}\` (type=${e.type}) captured as ${r}`:`Object captured as ${r} with keys: ${n}`}function DI(e){try{const t=Object.getPrototypeOf(e);return t?t.constructor.name:void 0}catch{}}function $I(e){for(const t in e)if(Object.prototype.hasOwnProperty.call(e,t)){const n=e[t];if(n instanceof Error)return n}}function FI(e,{metadata:t,tunnel:n,dsn:r}){const i={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:pi(r)}},a=BI(e);return _s(i,[a])}function BI(e){return[{type:"user_report"},e]}class zI extends kb{constructor(t){const n={parentSpanIsAlwaysRootSpan:!0,...t},r=Se.SENTRY_SDK_SOURCE||EI();dy(n,"browser",["browser"],r),super(n),n.sendClientReports&&Se.document&&Se.document.addEventListener("visibilitychange",()=>{Se.document.visibilityState==="hidden"&&this._flushOutcomes()})}eventFromException(t,n){return MI(this._options.stackParser,t,n,this._options.attachStacktrace)}eventFromMessage(t,n="info",r){return LI(this._options.stackParser,t,n,r,this._options.attachStacktrace)}captureUserFeedback(t){if(!this._isEnabled()){qn&&X.warn("SDK not enabled, will not capture user feedback.");return}const n=FI(t,{metadata:this.getSdkMetadata(),dsn:this.getDsn(),tunnel:this.getOptions().tunnel});this.sendEnvelope(n)}_prepareEvent(t,n,r){return t.platform=t.platform||"javascript",super._prepareEvent(t,n,r)}}const kd=typeof __SENTRY_DEBUG__>"u"||__SENTRY_DEBUG__,UI=(e,t)=>e>t[1]?"poor":e>t[0]?"needs-improvement":"good",uo=(e,t,n,r)=>{let i,a;return c=>{t.value>=0&&(c||r)&&(a=t.value-(i||0),(a||i===void 0)&&(i=t.value,t.delta=a,t.rating=UI(t.value,n),e(t)))}},fe=Ne,HI=()=>`v4-${Date.now()}-${Math.floor(Math.random()*(9e12-1))+1e12}`,mi=(e=!0)=>{const t=fe.performance&&fe.performance.getEntriesByType&&fe.performance.getEntriesByType("navigation")[0];if(!e||t&&t.responseStart>0&&t.responseStart<performance.now())return t},gi=()=>{const e=mi();return e&&e.activationStart||0},fo=(e,t)=>{const n=mi();let r="navigate";return n&&(fe.document&&fe.document.prerendering||gi()>0?r="prerender":fe.document&&fe.document.wasDiscarded?r="restore":n.type&&(r=n.type.replace(/_/g,"-"))),{name:e,value:typeof t>"u"?-1:t,rating:"good",delta:0,entries:[],id:HI(),navigationType:r}},xs=(e,t,n)=>{try{if(PerformanceObserver.supportedEntryTypes.includes(e)){const r=new PerformanceObserver(i=>{Promise.resolve().then(()=>{t(i.getEntries())})});return r.observe(Object.assign({type:e,buffered:!0},n||{})),r}}catch{}},po=e=>{const t=n=>{(n.type==="pagehide"||fe.document&&fe.document.visibilityState==="hidden")&&e(n)};fe.document&&(addEventListener("visibilitychange",t,!0),addEventListener("pagehide",t,!0))},al=e=>{let t=!1;return()=>{t||(e(),t=!0)}};let yi=-1;const WI=()=>fe.document.visibilityState==="hidden"&&!fe.document.prerendering?0:1/0,ll=e=>{fe.document.visibilityState==="hidden"&&yi>-1&&(yi=e.type==="visibilitychange"?e.timeStamp:0,VI())},qI=()=>{addEventListener("visibilitychange",ll,!0),addEventListener("prerenderingchange",ll,!0)},VI=()=>{removeEventListener("visibilitychange",ll,!0),removeEventListener("prerenderingchange",ll,!0)},cl=()=>(fe.document&&yi<0&&(yi=WI(),qI()),{get firstHiddenTime(){return yi}}),vi=e=>{fe.document&&fe.document.prerendering?addEventListener("prerenderingchange",()=>e(),!0):e()},GI=[1800,3e3],YI=(e,t={})=>{vi(()=>{const n=cl(),r=fo("FCP");let i;const c=xs("paint",d=>{d.forEach(f=>{f.name==="first-contentful-paint"&&(c.disconnect(),f.startTime<n.firstHiddenTime&&(r.value=Math.max(f.startTime-gi(),0),r.entries.push(f),i(!0)))})});c&&(i=uo(e,r,GI,t.reportAllChanges))})},KI=[.1,.25],QI=(e,t={})=>{YI(al(()=>{const n=fo("CLS",0);let r,i=0,a=[];const c=f=>{f.forEach(h=>{if(!h.hadRecentInput){const y=a[0],g=a[a.length-1];i&&y&&g&&h.startTime-g.startTime<1e3&&h.startTime-y.startTime<5e3?(i+=h.value,a.push(h)):(i=h.value,a=[h])}}),i>n.value&&(n.value=i,n.entries=a,r())},d=xs("layout-shift",c);d&&(r=uo(e,n,KI,t.reportAllChanges),po(()=>{c(d.takeRecords()),r(!0)}),setTimeout(r,0))}))},XI=[100,300],JI=(e,t={})=>{vi(()=>{const n=cl(),r=fo("FID");let i;const a=f=>{f.startTime<n.firstHiddenTime&&(r.value=f.processingStart-f.startTime,r.entries.push(f),i(!0))},c=f=>{f.forEach(a)},d=xs("first-input",c);i=uo(e,r,XI,t.reportAllChanges),d&&po(al(()=>{c(d.takeRecords()),d.disconnect()}))})};let Ry=0,Td=1/0,ul=0;const ZI=e=>{e.forEach(t=>{t.interactionId&&(Td=Math.min(Td,t.interactionId),ul=Math.max(ul,t.interactionId),Ry=ul?(ul-Td)/7+1:0)})};let bd;const eC=()=>bd?Ry:performance.interactionCount||0,tC=()=>{"interactionCount"in performance||bd||(bd=xs("event",ZI,{type:"event",buffered:!0,durationThreshold:0}))},lr=[],Id=new Map,nC=40;let rC=0;const sC=()=>eC()-rC,oC=()=>{const e=Math.min(lr.length-1,Math.floor(sC()/50));return lr[e]},Cd=10,iC=[],aC=e=>{if(iC.forEach(r=>r(e)),!(e.interactionId||e.entryType==="first-input"))return;const t=lr[lr.length-1],n=Id.get(e.interactionId);if(n||lr.length<Cd||t&&e.duration>t.latency){if(n)e.duration>n.latency?(n.entries=[e],n.latency=e.duration):e.duration===n.latency&&e.startTime===(n.entries[0]&&n.entries[0].startTime)&&n.entries.push(e);else{const r={id:e.interactionId,latency:e.duration,entries:[e]};Id.set(r.id,r),lr.push(r)}lr.sort((r,i)=>i.latency-r.latency),lr.length>Cd&&lr.splice(Cd).forEach(r=>Id.delete(r.id))}},Ay=e=>{const t=fe.requestIdleCallback||fe.setTimeout;let n=-1;return e=al(e),fe.document&&fe.document.visibilityState==="hidden"?e():(n=t(e),po(e)),n},lC=[200,500],cC=(e,t={})=>{"PerformanceEventTiming"in fe&&"interactionId"in PerformanceEventTiming.prototype&&vi(()=>{tC();const n=fo("INP");let r;const i=c=>{Ay(()=>{c.forEach(aC);const d=oC();d&&d.latency!==n.value&&(n.value=d.latency,n.entries=d.entries,r())})},a=xs("event",i,{durationThreshold:t.durationThreshold!=null?t.durationThreshold:nC});r=uo(e,n,lC,t.reportAllChanges),a&&(a.observe({type:"first-input",buffered:!0}),po(()=>{i(a.takeRecords()),r(!0)}))})},uC=[2500,4e3],Oy={},dC=(e,t={})=>{vi(()=>{const n=cl(),r=fo("LCP");let i;const a=d=>{t.reportAllChanges||(d=d.slice(-1)),d.forEach(f=>{f.startTime<n.firstHiddenTime&&(r.value=Math.max(f.startTime-gi(),0),r.entries=[f],i())})},c=xs("largest-contentful-paint",a);if(c){i=uo(e,r,uC,t.reportAllChanges);const d=al(()=>{Oy[r.id]||(a(c.takeRecords()),c.disconnect(),Oy[r.id]=!0,i(!0))});["keydown","click"].forEach(f=>{fe.document&&addEventListener(f,()=>Ay(d),{once:!0,capture:!0})}),po(d)}})},fC=[800,1800],Rd=e=>{fe.document&&fe.document.prerendering?vi(()=>Rd(e)):fe.document&&fe.document.readyState!=="complete"?addEventListener("load",()=>Rd(e),!0):setTimeout(e,0)},pC=(e,t={})=>{const n=fo("TTFB"),r=uo(e,n,fC,t.reportAllChanges);Rd(()=>{const i=mi();i&&(n.value=Math.max(i.responseStart-gi(),0),n.entries=[i],r(!0))})},Si={},dl={};let Py,Ny,My,Ly,jy;function Ad(e,t=!1){return wi("cls",e,mC,Py,t)}function Dy(e,t=!1){return wi("lcp",e,yC,My,t)}function $y(e){return wi("fid",e,gC,Ny)}function hC(e){return wi("ttfb",e,vC,Ly)}function Fy(e){return wi("inp",e,SC,jy)}function ho(e,t){return By(e,t),dl[e]||(wC(e),dl[e]=!0),zy(e,t)}function mo(e,t){const n=Si[e];if(!(!n||!n.length))for(const r of n)try{r(t)}catch(i){kd&&X.error(`Error while triggering instrumentation handler.
Type: ${e}
Name: ${nr(r)}
Error:`,i)}}function mC(){return QI(e=>{mo("cls",{metric:e}),Py=e},{reportAllChanges:!0})}function gC(){return JI(e=>{mo("fid",{metric:e}),Ny=e})}function yC(){return dC(e=>{mo("lcp",{metric:e}),My=e},{reportAllChanges:!0})}function vC(){return pC(e=>{mo("ttfb",{metric:e}),Ly=e})}function SC(){return cC(e=>{mo("inp",{metric:e}),jy=e})}function wi(e,t,n,r,i=!1){By(e,t);let a;return dl[e]||(a=n(),dl[e]=!0),r&&t({metric:r}),zy(e,t,i?a:void 0)}function wC(e){const t={};e==="event"&&(t.durationThreshold=0),xs(e,n=>{mo(e,{entries:n})},t)}function By(e,t){Si[e]=Si[e]||[],Si[e].push(t)}function zy(e,t,n){return()=>{n&&n();const r=Si[e];if(!r)return;const i=r.indexOf(t);i!==-1&&r.splice(i,1)}}function _C(e){return"duration"in e}function Od(e){return typeof e=="number"&&isFinite(e)}function cr(e,t,n,{...r}){const i=Fe(e).start_timestamp;return i&&i>t&&typeof e.updateStartTime=="function"&&e.updateStartTime(t),Ug(e,()=>{const a=hi({startTime:t,...r});return a&&a.end(n),a})}function Uy(e){const t=Ae();if(!t)return;const{name:n,transaction:r,attributes:i,startTime:a}=e,{release:c,environment:d}=t.getOptions(),f=t.getIntegrationByName("Replay"),h=f&&f.getReplayId(),y=Ve(),g=y.getUser(),w=g!==void 0?g.email||g.id||g.ip_address:void 0;let x;try{x=y.getScopeData().contexts.profile.profile_id}catch{}const _={release:c,environment:d,user:w||void 0,profile_id:x||void 0,replay_id:h||void 0,transaction:r,"user_agent.original":fe.navigator&&fe.navigator.userAgent,...i};return hi({name:n,attributes:_,startTime:a,experimental:{standalone:!0}})}function Pd(){return fe&&fe.addEventListener&&fe.performance}function ot(e){return e/1e3}function EC(){let e=0,t,n;if(!kC())return;let r=!1;function i(){r||(r=!0,n&&xC(e,t,n),a())}const a=Ad(({metric:c})=>{const d=c.entries[c.entries.length-1];d&&(e=c.value,t=d)},!0);po(()=>{i()}),setTimeout(()=>{const c=Ae();if(!c)return;const d=c.on("startNavigationSpan",()=>{i(),d&&d()}),f=vt(),h=f&&bt(f),y=h&&Fe(h);y&&y.op==="pageload"&&(n=h.spanContext().spanId)},0)}function xC(e,t,n){kd&&X.log(`Sending CLS span (${e})`);const r=ot((zt||0)+(t&&t.startTime||0)),i=Ve().getScopeData().transactionName,a=t?or(t.sources[0]&&t.sources[0].node):"Layout shift",c=dt({[gt]:"auto.http.browser.cls",[gs]:"ui.webvital.cls",[sd]:t&&t.duration||0,"sentry.pageload.span_id":n}),d=Uy({name:a,transaction:i,attributes:c,startTime:r});d&&(d.addEvent("cls",{[Ka]:"",[Qa]:e}),d.end(r))}function kC(){try{return PerformanceObserver.supportedEntryTypes.includes("layout-shift")}catch{return!1}}const TC=2147483647;let Hy=0,It={},Kt,_i;function bC({recordClsStandaloneSpans:e}){const t=Pd();if(t&&zt){t.mark&&fe.performance.mark("sentry-tracing-init");const n=PC(),r=OC(),i=NC(),a=e?EC():AC();return()=>{n(),r(),i(),a&&a()}}return()=>{}}function IC(){ho("longtask",({entries:e})=>{const t=vt();if(!t)return;const{op:n,start_timestamp:r}=Fe(t);for(const i of e){const a=ot(zt+i.startTime),c=ot(i.duration);n==="navigation"&&r&&a<r||cr(t,a,a+c,{name:"Main UI thread blocked",op:"ui.long-task",attributes:{[gt]:"auto.ui.browser.metrics"}})}})}function CC(){new PerformanceObserver(t=>{const n=vt();if(n)for(const r of t.getEntries()){if(!r.scripts[0])continue;const i=ot(zt+r.startTime),{start_timestamp:a,op:c}=Fe(n);if(c==="navigation"&&a&&i<a)continue;const d=ot(r.duration),f={[gt]:"auto.ui.browser.metrics"},h=r.scripts[0],{invoker:y,invokerType:g,sourceURL:w,sourceFunctionName:x,sourceCharPosition:_}=h;f["browser.script.invoker"]=y,f["browser.script.invoker_type"]=g,w&&(f["code.filepath"]=w),x&&(f["code.function"]=x),_!==-1&&(f["browser.script.source_char_position"]=_),cr(n,i,i+d,{name:"Main UI thread blocked",op:"ui.long-animation-frame",attributes:f})}}).observe({type:"long-animation-frame",buffered:!0})}function RC(){ho("event",({entries:e})=>{const t=vt();if(t){for(const n of e)if(n.name==="click"){const r=ot(zt+n.startTime),i=ot(n.duration),a={name:or(n.target),op:`ui.interaction.${n.name}`,startTime:r,attributes:{[gt]:"auto.ui.browser.metrics"}},c=Zm(n.target);c&&(a.attributes["ui.component_name"]=c),cr(t,r,r+i,a)}}})}function AC(){return Ad(({metric:e})=>{const t=e.entries[e.entries.length-1];t&&(It.cls={value:e.value,unit:""},_i=t)},!0)}function OC(){return Dy(({metric:e})=>{const t=e.entries[e.entries.length-1];t&&(It.lcp={value:e.value,unit:"millisecond"},Kt=t)},!0)}function PC(){return $y(({metric:e})=>{const t=e.entries[e.entries.length-1];if(!t)return;const n=ot(zt),r=ot(t.startTime);It.fid={value:e.value,unit:"millisecond"},It["mark.fid"]={value:n+r,unit:"second"}})}function NC(){return hC(({metric:e})=>{e.entries[e.entries.length-1]&&(It.ttfb={value:e.value,unit:"millisecond"})})}function MC(e,t){const n=Pd();if(!n||!n.getEntries||!zt)return;const r=ot(zt),i=n.getEntries(),{op:a,start_timestamp:c}=Fe(e);if(i.slice(Hy).forEach(d=>{const f=ot(d.startTime),h=ot(Math.max(0,d.duration));if(!(a==="navigation"&&c&&r+f<c))switch(d.entryType){case"navigation":{jC(e,d,r);break}case"mark":case"paint":case"measure":{LC(e,d,f,h,r);const y=cl(),g=d.startTime<y.firstHiddenTime;d.name==="first-paint"&&g&&(It.fp={value:d.startTime,unit:"millisecond"}),d.name==="first-contentful-paint"&&g&&(It.fcp={value:d.startTime,unit:"millisecond"});break}case"resource":{FC(e,d,d.name,f,h,r);break}}}),Hy=Math.max(i.length-1,0),BC(e),a==="pageload"){UC(It);const d=It["mark.fid"];d&&It.fid&&(cr(e,d.value,d.value+ot(It.fid.value),{name:"first input delay",op:"ui.action",attributes:{[gt]:"auto.ui.browser.metrics"}}),delete It["mark.fid"]),(!("fcp"in It)||!t.recordClsOnPageloadSpan)&&delete It.cls,Object.entries(It).forEach(([f,h])=>{UT(f,h.value,h.unit)}),e.setAttribute("performance.timeOrigin",r),e.setAttribute("performance.activationStart",gi()),zC(e)}Kt=void 0,_i=void 0,It={}}function LC(e,t,n,r,i){const a=mi(!1),c=ot(a?a.requestStart:0),d=i+Math.max(n,c),f=i+n,h=f+r,y={[gt]:"auto.resource.browser.metrics"};return d!==f&&(y["sentry.browser.measure_happened_before_request"]=!0,y["sentry.browser.measure_start_time"]=d),cr(e,d,h,{name:t.name,op:t.entryType,attributes:y}),d}function jC(e,t,n){["unloadEvent","redirect","domContentLoadedEvent","loadEvent","connect"].forEach(r=>{fl(e,t,r,n)}),fl(e,t,"secureConnection",n,"TLS/SSL"),fl(e,t,"fetch",n,"cache"),fl(e,t,"domainLookup",n,"DNS"),$C(e,t,n)}function fl(e,t,n,r,i=n){const a=DC(n),c=t[a],d=t[`${n}Start`];!d||!c||cr(e,r+ot(d),r+ot(c),{op:`browser.${i}`,name:t.name,attributes:{[gt]:"auto.ui.browser.metrics"}})}function DC(e){return e==="secureConnection"?"connectEnd":e==="fetch"?"domainLookupStart":`${e}End`}function $C(e,t,n){const r=n+ot(t.requestStart),i=n+ot(t.responseEnd),a=n+ot(t.responseStart);t.responseEnd&&(cr(e,r,i,{op:"browser.request",name:t.name,attributes:{[gt]:"auto.ui.browser.metrics"}}),cr(e,a,i,{op:"browser.response",name:t.name,attributes:{[gt]:"auto.ui.browser.metrics"}}))}function FC(e,t,n,r,i,a){if(t.initiatorType==="xmlhttprequest"||t.initiatorType==="fetch")return;const c=Es(n),d={[gt]:"auto.resource.browser.metrics"};Nd(d,t,"transferSize","http.response_transfer_size"),Nd(d,t,"encodedBodySize","http.response_content_length"),Nd(d,t,"decodedBodySize","http.decoded_response_content_length");const f=t.deliveryType;f!=null&&(d["http.response_delivery_type"]=f);const h=t.renderBlockingStatus;h&&(d["resource.render_blocking_status"]=h),c.protocol&&(d["url.scheme"]=c.protocol.split(":").pop()),c.host&&(d["server.address"]=c.host),d["url.same_origin"]=n.includes(fe.location.origin);const y=a+r,g=y+i;cr(e,y,g,{name:n.replace(fe.location.origin,""),op:t.initiatorType?`resource.${t.initiatorType}`:"resource.other",attributes:d})}function BC(e){const t=fe.navigator;if(!t)return;const n=t.connection;n&&(n.effectiveType&&e.setAttribute("effectiveConnectionType",n.effectiveType),n.type&&e.setAttribute("connectionType",n.type),Od(n.rtt)&&(It["connection.rtt"]={value:n.rtt,unit:"millisecond"})),Od(t.deviceMemory)&&e.setAttribute("deviceMemory",`${t.deviceMemory} GB`),Od(t.hardwareConcurrency)&&e.setAttribute("hardwareConcurrency",String(t.hardwareConcurrency))}function zC(e){Kt&&(Kt.element&&e.setAttribute("lcp.element",or(Kt.element)),Kt.id&&e.setAttribute("lcp.id",Kt.id),Kt.url&&e.setAttribute("lcp.url",Kt.url.trim().slice(0,200)),Kt.loadTime!=null&&e.setAttribute("lcp.loadTime",Kt.loadTime),Kt.renderTime!=null&&e.setAttribute("lcp.renderTime",Kt.renderTime),e.setAttribute("lcp.size",Kt.size)),_i&&_i.sources&&_i.sources.forEach((t,n)=>e.setAttribute(`cls.source.${n+1}`,or(t.node)))}function Nd(e,t,n,r){const i=t[n];i!=null&&i<TC&&(e[r]=i)}function UC(e){const t=mi(!1);if(!t)return;const{responseStart:n,requestStart:r}=t;r<=n&&(e["ttfb.requestTime"]={value:n-r,unit:"millisecond"})}const HC=1e3;let Wy,Md,Ld;function qy(e){const t="dom";Ir(t,e),Cr(t,WC)}function WC(){if(!fe.document)return;const e=yn.bind(null,"dom"),t=Vy(e,!0);fe.document.addEventListener("click",t,!1),fe.document.addEventListener("keypress",t,!1),["EventTarget","Node"].forEach(n=>{const i=fe[n],a=i&&i.prototype;!a||!a.hasOwnProperty||!a.hasOwnProperty("addEventListener")||(Yt(a,"addEventListener",function(c){return function(d,f,h){if(d==="click"||d=="keypress")try{const y=this.__sentry_instrumentation_handlers__=this.__sentry_instrumentation_handlers__||{},g=y[d]=y[d]||{refCount:0};if(!g.handler){const w=Vy(e);g.handler=w,c.call(this,d,w,h)}g.refCount++}catch{}return c.call(this,d,f,h)}}),Yt(a,"removeEventListener",function(c){return function(d,f,h){if(d==="click"||d=="keypress")try{const y=this.__sentry_instrumentation_handlers__||{},g=y[d];g&&(g.refCount--,g.refCount<=0&&(c.call(this,d,g.handler,h),g.handler=void 0,delete y[d]),Object.keys(y).length===0&&delete this.__sentry_instrumentation_handlers__)}catch{}return c.call(this,d,f,h)}}))})}function qC(e){if(e.type!==Md)return!1;try{if(!e.target||e.target._sentryId!==Ld)return!1}catch{}return!0}function VC(e,t){return e!=="keypress"?!1:!t||!t.tagName?!0:!(t.tagName==="INPUT"||t.tagName==="TEXTAREA"||t.isContentEditable)}function Vy(e,t=!1){return n=>{if(!n||n._sentryCaptured)return;const r=GC(n);if(VC(n.type,r))return;vn(n,"_sentryCaptured",!0),r&&!r._sentryId&&vn(r,"_sentryId",on());const i=n.type==="keypress"?"input":n.type;qC(n)||(e({event:n,name:i,global:t}),Md=n.type,Ld=r?r._sentryId:void 0),clearTimeout(Wy),Wy=fe.setTimeout(()=>{Ld=void 0,Md=void 0},HC)}}function GC(e){try{return e.target}catch{return null}}let pl;function hl(e){const t="history";Ir(t,e),Cr(t,YC)}function YC(){if(!TI())return;const e=fe.onpopstate;fe.onpopstate=function(...n){const r=fe.location.href,i=pl;if(pl=r,yn("history",{from:i,to:r}),e)try{return e.apply(this,n)}catch{}};function t(n){return function(...r){const i=r.length>2?r[2]:void 0;if(i){const a=pl,c=String(i);pl=c,yn("history",{from:a,to:c})}return n.apply(this,r)}}Yt(fe.history,"pushState",t),Yt(fe.history,"replaceState",t)}const ml={};function Gy(e){const t=ml[e];if(t)return t;let n=fe[e];if(gd(n))return ml[e]=n.bind(fe);const r=fe.document;if(r&&typeof r.createElement=="function")try{const i=r.createElement("iframe");i.hidden=!0,r.head.appendChild(i);const a=i.contentWindow;a&&a[e]&&(n=a[e]),r.head.removeChild(i)}catch(i){kd&&X.warn(`Could not create sandbox iframe for ${e} check, bailing to window.${e}: `,i)}return n&&(ml[e]=n.bind(fe))}function Yy(e){ml[e]=void 0}function go(...e){return Gy("setTimeout")(...e)}const ks="__sentry_xhr_v3__";function Ky(e){const t="xhr";Ir(t,e),Cr(t,KC)}function KC(){if(!fe.XMLHttpRequest)return;const e=XMLHttpRequest.prototype;e.open=new Proxy(e.open,{apply(t,n,r){const i=new Error,a=Bt()*1e3,c=rr(r[0])?r[0].toUpperCase():void 0,d=QC(r[1]);if(!c||!d)return t.apply(n,r);n[ks]={method:c,url:d,request_headers:{}},c==="POST"&&d.match(/sentry_key/)&&(n.__sentry_own_request__=!0);const f=()=>{const h=n[ks];if(h&&n.readyState===4){try{h.status_code=n.status}catch{}const y={endTimestamp:Bt()*1e3,startTimestamp:a,xhr:n,virtualError:i};yn("xhr",y)}};return"onreadystatechange"in n&&typeof n.onreadystatechange=="function"?n.onreadystatechange=new Proxy(n.onreadystatechange,{apply(h,y,g){return f(),h.apply(y,g)}}):n.addEventListener("readystatechange",f),n.setRequestHeader=new Proxy(n.setRequestHeader,{apply(h,y,g){const[w,x]=g,_=y[ks];return _&&rr(w)&&rr(x)&&(_.request_headers[w.toLowerCase()]=x),h.apply(y,g)}}),t.apply(n,r)}}),e.send=new Proxy(e.send,{apply(t,n,r){const i=n[ks];if(!i)return t.apply(n,r);r[0]!==void 0&&(i.body=r[0]);const a={startTimestamp:Bt()*1e3,xhr:n};return yn("xhr",a),t.apply(n,r)}})}function QC(e){if(rr(e))return e;try{return e.toString()}catch{}}const jd=[],gl=new Map;function XC(){if(Pd()&&zt){const t=JC();return()=>{t()}}return()=>{}}const Qy={click:"click",pointerdown:"click",pointerup:"click",mousedown:"click",mouseup:"click",touchstart:"click",touchend:"click",mouseover:"hover",mouseout:"hover",mouseenter:"hover",mouseleave:"hover",pointerover:"hover",pointerout:"hover",pointerenter:"hover",pointerleave:"hover",dragstart:"drag",dragend:"drag",drag:"drag",dragenter:"drag",dragleave:"drag",dragover:"drag",drop:"drag",keydown:"press",keyup:"press",keypress:"press",input:"press"};function JC(){return Fy(({metric:e})=>{if(e.value==null)return;const t=e.entries.find(_=>_.duration===e.value&&Qy[_.name]);if(!t)return;const{interactionId:n}=t,r=Qy[t.name],i=ot(zt+t.startTime),a=ot(e.value),c=vt(),d=c?bt(c):void 0,h=(n!=null?gl.get(n):void 0)||d,y=h?Fe(h).description:Ve().getScopeData().transactionName,g=or(t.target),w=dt({[gt]:"auto.http.browser.inp",[gs]:`ui.interaction.${r}`,[sd]:t.duration}),x=Uy({name:g,transaction:y,attributes:w,startTime:i});x&&(x.addEvent("inp",{[Ka]:"millisecond",[Qa]:e.value}),x.end(i+a))})}function ZC(e){const t=({entries:n})=>{const r=vt(),i=r&&bt(r);n.forEach(a=>{if(!_C(a)||!i)return;const c=a.interactionId;if(c!=null&&!gl.has(c)){if(jd.length>10){const d=jd.shift();gl.delete(d)}jd.push(c),gl.set(c,i)}})};ho("event",t),ho("first-input",t)}function eR(e,t=Gy("fetch")){let n=0,r=0;function i(a){const c=a.body.length;n+=c,r++;const d={body:a.body,method:"POST",referrerPolicy:"origin",headers:e.headers,keepalive:n<=6e4&&r<15,...e.fetchOptions};if(!t)return Yy("fetch"),Va("No fetch implementation available");try{return t(e.url,d).then(f=>(n-=c,r--,{statusCode:f.status,headers:{"x-sentry-rate-limits":f.headers.get("X-Sentry-Rate-Limits"),"retry-after":f.headers.get("Retry-After")}}))}catch(f){return Yy("fetch"),n-=c,r--,Va(f)}}return Mb(e,i)}const tR=30,nR=50;function Dd(e,t,n,r){const i={filename:e,function:t==="<anonymous>"?ps:t,in_app:!0};return n!==void 0&&(i.lineno=n),r!==void 0&&(i.colno=r),i}const rR=/^\s*at (\S+?)(?::(\d+))(?::(\d+))\s*$/i,sR=/^\s*at (?:(.+?\)(?: \[.+\])?|.*?) ?\((?:address at )?)?(?:async )?((?:<anonymous>|[-a-z]+:|.*bundle|\/)?.*?)(?::(\d+))?(?::(\d+))?\)?\s*$/i,oR=/\((\S*)(?::(\d+))(?::(\d+))\)/,iR=[tR,e=>{const t=rR.exec(e);if(t){const[,r,i,a]=t;return Dd(r,ps,+i,+a)}const n=sR.exec(e);if(n){if(n[2]&&n[2].indexOf("eval")===0){const c=oR.exec(n[2]);c&&(n[2]=c[1],n[3]=c[2],n[4]=c[3])}const[i,a]=Xy(n[1]||ps,n[2]);return Dd(a,i,n[3]?+n[3]:void 0,n[4]?+n[4]:void 0)}}],aR=/^\s*(.*?)(?:\((.*?)\))?(?:^|@)?((?:[-a-z]+)?:\/.*?|\[native code\]|[^@]*(?:bundle|\d+\.js)|\/[\w\-. /=]+)(?::(\d+))?(?::(\d+))?\s*$/i,lR=/(\S+) line (\d+)(?: > eval line \d+)* > eval/i,cR=Hm(...[iR,[nR,e=>{const t=aR.exec(e);if(t){if(t[3]&&t[3].indexOf(" > eval")>-1){const a=lR.exec(t[3]);a&&(t[1]=t[1]||"eval",t[3]=a[1],t[4]=a[2],t[5]="")}let r=t[3],i=t[1]||ps;return[i,r]=Xy(i,r),Dd(r,i,t[4]?+t[4]:void 0,t[5]?+t[5]:void 0)}}]]),Xy=(e,t)=>{const n=e.indexOf("safari-extension")!==-1,r=e.indexOf("safari-web-extension")!==-1;return n||r?[e.indexOf("@")!==-1?e.split("@")[0]:ps,n?`safari-extension:${t}`:`safari-web-extension:${t}`]:[e,t]},yl=1024,uR="Breadcrumbs",dR=(e={})=>{const t={console:!0,dom:!0,fetch:!0,history:!0,sentry:!0,xhr:!0,...e};return{name:uR,setup(n){t.console&&rI(hR(n)),t.dom&&qy(pR(n,t.dom)),t.xhr&&Ky(mR(n)),t.fetch&&xy(gR(n)),t.history&&hl(yR(n)),t.sentry&&n.on("beforeSendEvent",fR(n))}}};function fR(e){return function(n){Ae()===e&&Mr({category:`sentry.${n.type==="transaction"?"transaction":"event"}`,event_id:n.event_id,level:n.level,message:Ar(n)},{event:n})}}function pR(e,t){return function(r){if(Ae()!==e)return;let i,a,c=typeof t=="object"?t.serializeAttribute:void 0,d=typeof t=="object"&&typeof t.maxStringLength=="number"?t.maxStringLength:void 0;d&&d>yl&&(qn&&X.warn(`\`dom.maxStringLength\` cannot exceed ${yl}, but a value of ${d} was configured. Sentry will use ${yl} instead.`),d=yl),typeof c=="string"&&(c=[c]);try{const h=r.event,y=vR(h)?h.target:h;i=or(y,{keyAttrs:c,maxStringLength:d}),a=Zm(y)}catch{i="<unknown>"}if(i.length===0)return;const f={category:`ui.${r.name}`,message:i};a&&(f.data={"ui.component_name":a}),Mr(f,{event:r.event,name:r.name,global:r.global})}}function hR(e){return function(n){if(Ae()!==e)return;const r={category:"console",data:{arguments:n.args,logger:"console"},level:yy(n.level),message:eg(n.args," ")};if(n.level==="assert")if(n.args[0]===!1)r.message=`Assertion failed: ${eg(n.args.slice(1)," ")||"console.assert"}`,r.data.arguments=n.args.slice(1);else return;Mr(r,{input:n.args,level:n.level})}}function mR(e){return function(n){if(Ae()!==e)return;const{startTimestamp:r,endTimestamp:i}=n,a=n.xhr[ks];if(!r||!i||!a)return;const{method:c,url:d,status_code:f,body:h}=a,y={method:c,url:d,status_code:f},g={xhr:n.xhr,input:h,startTimestamp:r,endTimestamp:i},w=_y(f);Mr({category:"xhr",data:y,type:"http",level:w},g)}}function gR(e){return function(n){if(Ae()!==e)return;const{startTimestamp:r,endTimestamp:i}=n;if(i&&!(n.fetchData.url.match(/sentry_key/)&&n.fetchData.method==="POST"))if(n.error){const a=n.fetchData,c={data:n.error,input:n.args,startTimestamp:r,endTimestamp:i};Mr({category:"fetch",data:a,level:"error",type:"http"},c)}else{const a=n.response,c={...n.fetchData,status_code:a&&a.status},d={input:n.args,response:a,startTimestamp:r,endTimestamp:i},f=_y(c.status_code);Mr({category:"fetch",data:c,type:"http",level:f},d)}}}function yR(e){return function(n){if(Ae()!==e)return;let r=n.from,i=n.to;const a=Es(Se.location.href);let c=r?Es(r):void 0;const d=Es(i);(!c||!c.path)&&(c=a),a.protocol===d.protocol&&a.host===d.host&&(i=d.relative),a.protocol===c.protocol&&a.host===c.host&&(r=c.relative),Mr({category:"navigation",data:{from:r,to:i}})}}function vR(e){return!!e&&!!e.target}const SR=["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"],wR="BrowserApiErrors",_R=(e={})=>{const t={XMLHttpRequest:!0,eventTarget:!0,requestAnimationFrame:!0,setInterval:!0,setTimeout:!0,...e};return{name:wR,setupOnce(){t.setTimeout&&Yt(Se,"setTimeout",Jy),t.setInterval&&Yt(Se,"setInterval",Jy),t.requestAnimationFrame&&Yt(Se,"requestAnimationFrame",ER),t.XMLHttpRequest&&"XMLHttpRequest"in Se&&Yt(XMLHttpRequest.prototype,"send",xR);const n=t.eventTarget;n&&(Array.isArray(n)?n:SR).forEach(kR)}}};function Jy(e){return function(...t){const n=t[0];return t[0]=co(n,{mechanism:{data:{function:nr(e)},handled:!1,type:"instrument"}}),e.apply(this,t)}}function ER(e){return function(t){return e.apply(this,[co(t,{mechanism:{data:{function:"requestAnimationFrame",handler:nr(e)},handled:!1,type:"instrument"}})])}}function xR(e){return function(...t){const n=this;return["onload","onerror","onprogress","onreadystatechange"].forEach(i=>{i in n&&typeof n[i]=="function"&&Yt(n,i,function(a){const c={mechanism:{data:{function:i,handler:nr(a)},handled:!1,type:"instrument"}},d=Qu(a);return d&&(c.mechanism.data.handler=nr(d)),co(a,c)})}),e.apply(this,t)}}function kR(e){const n=Se[e],r=n&&n.prototype;!r||!r.hasOwnProperty||!r.hasOwnProperty("addEventListener")||(Yt(r,"addEventListener",function(i){return function(a,c,d){try{TR(c)&&(c.handleEvent=co(c.handleEvent,{mechanism:{data:{function:"handleEvent",handler:nr(c),target:e},handled:!1,type:"instrument"}}))}catch{}return i.apply(this,[a,co(c,{mechanism:{data:{function:"addEventListener",handler:nr(c),target:e},handled:!1,type:"instrument"}}),d])}}),Yt(r,"removeEventListener",function(i){return function(a,c,d){try{const f=c.__sentry_wrapped__;f&&i.call(this,a,f,d)}catch{}return i.call(this,a,c,d)}}))}function TR(e){return typeof e.handleEvent=="function"}const bR=()=>({name:"BrowserSession",setupOnce(){if(typeof Se.document>"u"){qn&&X.warn("Using the `browserSessionIntegration` in non-browser environments is not supported.");return}Xg({ignoreDuration:!0}),ey(),hl(({from:e,to:t})=>{e!==void 0&&e!==t&&(Xg({ignoreDuration:!0}),ey())})}}),IR="GlobalHandlers",CR=(e={})=>{const t={onerror:!0,onunhandledrejection:!0,...e};return{name:IR,setupOnce(){Error.stackTraceLimit=50},setup(n){t.onerror&&(RR(n),Zy("onerror")),t.onunhandledrejection&&(AR(n),Zy("onunhandledrejection"))}}};function RR(e){Vm(t=>{const{stackParser:n,attachStacktrace:r}=e0();if(Ae()!==e||Iy())return;const{msg:i,url:a,line:c,column:d,error:f}=t,h=NR(Ed(n,f||i,void 0,r,!1),a,c,d);h.level="error",Kg(h,{originalException:f,mechanism:{handled:!1,type:"onerror"}})})}function AR(e){Gm(t=>{const{stackParser:n,attachStacktrace:r}=e0();if(Ae()!==e||Iy())return;const i=OR(t),a=Ku(i)?PR(i):Ed(n,i,void 0,r,!0);a.level="error",Kg(a,{originalException:i,mechanism:{handled:!1,type:"onunhandledrejection"}})})}function OR(e){if(Ku(e))return e;try{if("reason"in e)return e.reason;if("detail"in e&&"reason"in e.detail)return e.detail.reason}catch{}return e}function PR(e){return{exception:{values:[{type:"UnhandledRejection",value:`Non-Error promise rejection captured with value: ${String(e)}`}]}}}function NR(e,t,n,r){const i=e.exception=e.exception||{},a=i.values=i.values||[],c=a[0]=a[0]||{},d=c.stacktrace=c.stacktrace||{},f=d.frames=d.frames||[],h=r,y=n,g=rr(t)&&t.length>0?t:Jm();return f.length===0&&f.push({colno:h,filename:g,function:ps,in_app:!0,lineno:y}),e}function Zy(e){qn&&X.log(`Global Handler attached: ${e}`)}function e0(){const e=Ae();return e&&e.getOptions()||{stackParser:()=>[],attachStacktrace:!1}}const MR=()=>({name:"HttpContext",preprocessEvent(e){if(!Se.navigator&&!Se.location&&!Se.document)return;const t=e.request&&e.request.url||Se.location&&Se.location.href,{referrer:n}=Se.document||{},{userAgent:r}=Se.navigator||{},i={...e.request&&e.request.headers,...n&&{Referer:n},...r&&{"User-Agent":r}},a={...e.request,...t&&{url:t},headers:i};e.request=a}}),LR="cause",jR=5,DR="LinkedErrors",$R=(e={})=>{const t=e.limit||jR,n=e.key||LR;return{name:DR,preprocessEvent(r,i,a){const c=a.getOptions();tI(Sd,c.stackParser,c.maxValueLength,n,t,r,i)}}};function FR(e){const t=[Wb(),zb(),_R(),dR(),CR(),$R(),iI(),MR()];return e.autoSessionTracking!==!1&&t.push(bR()),t}function BR(e={}){const t={defaultIntegrations:FR(e),release:typeof __SENTRY_RELEASE__=="string"?__SENTRY_RELEASE__:Se.SENTRY_RELEASE&&Se.SENTRY_RELEASE.id?Se.SENTRY_RELEASE.id:void 0,autoSessionTracking:!0,sendClientReports:!0};return e.defaultIntegrations==null&&delete e.defaultIntegrations,{...t,...e}}function zR(){const e=typeof Se.window<"u"&&Se;if(!e)return!1;const t=e.chrome?"chrome":"browser",n=e[t],r=n&&n.runtime&&n.runtime.id,i=Se.location&&Se.location.href||"",a=["chrome-extension:","moz-extension:","ms-browser-extension:","safari-web-extension:"],c=!!r&&Se===Se.top&&a.some(f=>i.startsWith(`${f}//`)),d=typeof e.nw<"u";return!!r&&!c&&!d}function UR(e={}){const t=BR(e);if(!t.skipBrowserExtensionCheck&&zR()){br(()=>{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}qn&&(Ey()||X.warn("No Fetch API detected. The Sentry SDK requires a Fetch API compatible environment to send events. Please add a Fetch API polyfill."));const n={...t,stackParser:bk(t.stackParser||cR),integrations:_b(t),transport:t.transport||eR};return Ib(zI,n)}const Ge=Ne,$d="sentryReplaySession",HR="replay_event",Fd="Unable to send Replay",WR=3e5,qR=9e5,VR=5e3,GR=5500,YR=6e4,KR=5e3,QR=3,t0=15e4,vl=5e3,XR=3e3,JR=300,Bd=2e7,ZR=4999,e2=15e3,n0=36e5;function zd(e,t){return e??t()}function Ei(e){let t,n=e[0],r=1;for(;r<e.length;){const i=e[r],a=e[r+1];if(r+=2,(i==="optionalAccess"||i==="optionalCall")&&n==null)return;i==="access"||i==="optionalAccess"?(t=n,n=a(n)):(i==="call"||i==="optionalCall")&&(n=a((...c)=>n.call(t,...c)),t=void 0)}return n}var ft;(function(e){e[e.Document=0]="Document",e[e.DocumentType=1]="DocumentType",e[e.Element=2]="Element",e[e.Text=3]="Text",e[e.CDATA=4]="CDATA",e[e.Comment=5]="Comment"})(ft||(ft={}));function t2(e){return e.nodeType===e.ELEMENT_NODE}function xi(e){const t=Ei([e,"optionalAccess",n=>n.host]);return Ei([t,"optionalAccess",n=>n.shadowRoot])===e}function ki(e){return Object.prototype.toString.call(e)==="[object ShadowRoot]"}function n2(e){return e.includes(" background-clip: text;")&&!e.includes(" -webkit-background-clip: text;")&&(e=e.replace(/\sbackground-clip:\s*text;/g," -webkit-background-clip: text; background-clip: text;")),e}function r2(e){const{cssText:t}=e;if(t.split('"').length<3)return t;const n=["@import",`url(${JSON.stringify(e.href)})`];return e.layerName===""?n.push("layer"):e.layerName&&n.push(`layer(${e.layerName})`),e.supportsText&&n.push(`supports(${e.supportsText})`),e.media.length&&n.push(e.media.mediaText),n.join(" ")+";"}function Sl(e){try{const t=e.rules||e.cssRules;return t?n2(Array.from(t,r0).join("")):null}catch{return null}}function s2(e){let t="";for(let n=0;n<e.style.length;n++){const r=e.style,i=r[n],a=r.getPropertyPriority(i);t+=`${i}:${r.getPropertyValue(i)}${a?" !important":""};`}return`${e.selectorText} { ${t} }`}function r0(e){let t;if(i2(e))try{t=Sl(e.styleSheet)||r2(e)}catch{}else if(a2(e)){let n=e.cssText;const r=e.selectorText.includes(":"),i=typeof e.style.all=="string"&&e.style.all;if(i&&(n=s2(e)),r&&(n=o2(n)),r||i)return n}return t||e.cssText}function o2(e){const t=/(\[(?:[\w-]+)[^\\])(:(?:[\w-]+)\])/gm;return e.replace(t,"$1\\$2")}function i2(e){return"styleSheet"in e}function a2(e){return"selectorText"in e}class s0{constructor(){this.idNodeMap=new Map,this.nodeMetaMap=new WeakMap}getId(t){if(!t)return-1;const n=Ei([this,"access",r=>r.getMeta,"call",r=>r(t),"optionalAccess",r=>r.id]);return zd(n,()=>-1)}getNode(t){return this.idNodeMap.get(t)||null}getIds(){return Array.from(this.idNodeMap.keys())}getMeta(t){return this.nodeMetaMap.get(t)||null}removeNodeFromMap(t){const n=this.getId(t);this.idNodeMap.delete(n),t.childNodes&&t.childNodes.forEach(r=>this.removeNodeFromMap(r))}has(t){return this.idNodeMap.has(t)}hasNode(t){return this.nodeMetaMap.has(t)}add(t,n){const r=n.id;this.idNodeMap.set(r,t),this.nodeMetaMap.set(t,n)}replace(t,n){const r=this.getNode(t);if(r){const i=this.nodeMetaMap.get(r);i&&this.nodeMetaMap.set(n,i)}this.idNodeMap.set(t,n)}reset(){this.idNodeMap=new Map,this.nodeMetaMap=new WeakMap}}function l2(){return new s0}function wl({maskInputOptions:e,tagName:t,type:n}){return t==="OPTION"&&(t="SELECT"),!!(e[t.toLowerCase()]||n&&e[n]||n==="password"||t==="INPUT"&&!n&&e.text)}function Ti({isMasked:e,element:t,value:n,maskInputFn:r}){let i=n||"";return e?(r&&(i=r(i,t)),"*".repeat(i.length)):i}function yo(e){return e.toLowerCase()}function Ud(e){return e.toUpperCase()}const o0="__rrweb_original__";function c2(e){const t=e.getContext("2d");if(!t)return!0;const n=50;for(let r=0;r<e.width;r+=n)for(let i=0;i<e.height;i+=n){const a=t.getImageData,c=o0 in a?a[o0]:a;if(new Uint32Array(c.call(t,r,i,Math.min(n,e.width-r),Math.min(n,e.height-i)).data.buffer).some(f=>f!==0))return!1}return!0}function Hd(e){const t=e.type;return e.hasAttribute("data-rr-is-password")?"password":t?yo(t):null}function _l(e,t,n){return t==="INPUT"&&(n==="radio"||n==="checkbox")?e.getAttribute("value")||"":e.value}function i0(e,t){let n;try{n=new URL(e,zd(t,()=>window.location.href))}catch{return null}const r=/\.([0-9a-z]+)(?:$)/i,i=n.pathname.match(r);return zd(Ei([i,"optionalAccess",a=>a[1]]),()=>null)}const a0={};function l0(e){const t=a0[e];if(t)return t;const n=window.document;let r=window[e];if(n&&typeof n.createElement=="function")try{const i=n.createElement("iframe");i.hidden=!0,n.head.appendChild(i);const a=i.contentWindow;a&&a[e]&&(r=a[e]),n.head.removeChild(i)}catch{}return a0[e]=r.bind(window)}function Wd(...e){return l0("setTimeout")(...e)}function c0(...e){return l0("clearTimeout")(...e)}function u0(e){try{return e.contentDocument}catch{}}let u2=1;const d2=new RegExp("[^a-z0-9-_:]"),bi=-2;function qd(){return u2++}function f2(e){if(e instanceof HTMLFormElement)return"form";const t=yo(e.tagName);return d2.test(t)?"div":t}function p2(e){let t="";return e.indexOf("//")>-1?t=e.split("/").slice(0,3).join("/"):t=e.split("/")[0],t=t.split("?")[0],t}let vo,d0;const h2=/url\((?:(')([^']*)'|(")(.*?)"|([^)]*))\)/gm,m2=/^(?:[a-z+]+:)?\/\//i,g2=/^www\..*/i,y2=/^(data:)([^,]*),(.*)/i;function El(e,t){return(e||"").replace(h2,(n,r,i,a,c,d)=>{const f=i||c||d,h=r||a||"";if(!f)return n;if(m2.test(f)||g2.test(f))return`url(${h}${f}${h})`;if(y2.test(f))return`url(${h}${f}${h})`;if(f[0]==="/")return`url(${h}${p2(t)+f}${h})`;const y=t.split("/"),g=f.split("/");y.pop();for(const w of g)w!=="."&&(w===".."?y.pop():y.push(w));return`url(${h}${y.join("/")}${h})`})}const v2=/^[^ \t\n\r\u000c]+/,S2=/^[, \t\n\r\u000c]+/;function w2(e,t){if(t.trim()==="")return t;let n=0;function r(a){let c;const d=a.exec(t.substring(n));return d?(c=d[0],n+=c.length,c):""}const i=[];for(;r(S2),!(n>=t.length);){let a=r(v2);if(a.slice(-1)===",")a=So(e,a.substring(0,a.length-1)),i.push(a);else{let c="";a=So(e,a);let d=!1;for(;;){const f=t.charAt(n);if(f===""){i.push((a+c).trim());break}else if(d)f===")"&&(d=!1);else if(f===","){n+=1,i.push((a+c).trim());break}else f==="("&&(d=!0);c+=f,n+=1}}}return i.join(", ")}const f0=new WeakMap;function So(e,t){return!t||t.trim()===""?t:xl(e,t)}function _2(e){return!!(e.tagName==="svg"||e.ownerSVGElement)}function xl(e,t){let n=f0.get(e);if(n||(n=e.createElement("a"),f0.set(e,n)),!t)t="";else if(t.startsWith("blob:")||t.startsWith("data:"))return t;return n.setAttribute("href",t),n.href}function p0(e,t,n,r,i,a){return r&&(n==="src"||n==="href"&&!(t==="use"&&r[0]==="#")||n==="xlink:href"&&r[0]!=="#"||n==="background"&&(t==="table"||t==="td"||t==="th")?So(e,r):n==="srcset"?w2(e,r):n==="style"?El(r,xl(e)):t==="object"&&n==="data"?So(e,r):typeof a=="function"?a(n,r,i):r)}function h0(e,t,n){return(e==="video"||e==="audio")&&t==="autoplay"}function E2(e,t,n,r){try{if(r&&e.matches(r))return!1;if(typeof t=="string"){if(e.classList.contains(t))return!0}else for(let i=e.classList.length;i--;){const a=e.classList[i];if(t.test(a))return!0}if(n)return e.matches(n)}catch{}return!1}function x2(e,t){for(let n=e.classList.length;n--;){const r=e.classList[n];if(t.test(r))return!0}return!1}function Ts(e,t,n=1/0,r=0){return!e||e.nodeType!==e.ELEMENT_NODE||r>n?-1:t(e)?r:Ts(e.parentNode,t,n,r+1)}function wo(e,t){return n=>{const r=n;if(r===null)return!1;try{if(e){if(typeof e=="string"){if(r.matches(`.${e}`))return!0}else if(x2(r,e))return!0}return!!(t&&r.matches(t))}catch{return!1}}}function _o(e,t,n,r,i,a){try{const c=e.nodeType===e.ELEMENT_NODE?e:e.parentElement;if(c===null)return!1;if(c.tagName==="INPUT"){const h=c.getAttribute("autocomplete");if(["current-password","new-password","cc-number","cc-exp","cc-exp-month","cc-exp-year","cc-csc"].includes(h))return!0}let d=-1,f=-1;if(a){if(f=Ts(c,wo(r,i)),f<0)return!0;d=Ts(c,wo(t,n),f>=0?f:1/0)}else{if(d=Ts(c,wo(t,n)),d<0)return!1;f=Ts(c,wo(r,i),d>=0?d:1/0)}return d>=0?f>=0?d<=f:!0:f>=0?!1:!!a}catch{}return!!a}function k2(e,t,n){const r=e.contentWindow;if(!r)return;let i=!1,a;try{a=r.document.readyState}catch{return}if(a!=="complete"){const d=Wd(()=>{i||(t(),i=!0)},n);e.addEventListener("load",()=>{c0(d),i=!0,t()});return}const c="about:blank";if(r.location.href!==c||e.src===c||e.src==="")return Wd(t,0),e.addEventListener("load",t);e.addEventListener("load",t)}function T2(e,t,n){let r=!1,i;try{i=e.sheet}catch{return}if(i)return;const a=Wd(()=>{r||(t(),r=!0)},n);e.addEventListener("load",()=>{c0(a),r=!0,t()})}function b2(e,t){const{doc:n,mirror:r,blockClass:i,blockSelector:a,unblockSelector:c,maskAllText:d,maskAttributeFn:f,maskTextClass:h,unmaskTextClass:y,maskTextSelector:g,unmaskTextSelector:w,inlineStylesheet:x,maskInputOptions:_={},maskTextFn:E,maskInputFn:k,dataURLOptions:O={},inlineImages:R,recordCanvas:$,keepIframeSrcFn:H,newlyAddedElement:z=!1}=t,M=I2(n,r);switch(e.nodeType){case e.DOCUMENT_NODE:return e.compatMode!=="CSS1Compat"?{type:ft.Document,childNodes:[],compatMode:e.compatMode}:{type:ft.Document,childNodes:[]};case e.DOCUMENT_TYPE_NODE:return{type:ft.DocumentType,name:e.name,publicId:e.publicId,systemId:e.systemId,rootId:M};case e.ELEMENT_NODE:return R2(e,{doc:n,blockClass:i,blockSelector:a,unblockSelector:c,inlineStylesheet:x,maskAttributeFn:f,maskInputOptions:_,maskInputFn:k,dataURLOptions:O,inlineImages:R,recordCanvas:$,keepIframeSrcFn:H,newlyAddedElement:z,rootId:M,maskAllText:d,maskTextClass:h,unmaskTextClass:y,maskTextSelector:g,unmaskTextSelector:w});case e.TEXT_NODE:return C2(e,{doc:n,maskAllText:d,maskTextClass:h,unmaskTextClass:y,maskTextSelector:g,unmaskTextSelector:w,maskTextFn:E,maskInputOptions:_,maskInputFn:k,rootId:M});case e.CDATA_SECTION_NODE:return{type:ft.CDATA,textContent:"",rootId:M};case e.COMMENT_NODE:return{type:ft.Comment,textContent:e.textContent||"",rootId:M};default:return!1}}function I2(e,t){if(!t.hasNode(e))return;const n=t.getId(e);return n===1?void 0:n}function C2(e,t){const{maskAllText:n,maskTextClass:r,unmaskTextClass:i,maskTextSelector:a,unmaskTextSelector:c,maskTextFn:d,maskInputOptions:f,maskInputFn:h,rootId:y}=t,g=e.parentNode&&e.parentNode.tagName;let w=e.textContent;const x=g==="STYLE"?!0:void 0,_=g==="SCRIPT"?!0:void 0,E=g==="TEXTAREA"?!0:void 0;if(x&&w){try{e.nextSibling||e.previousSibling||Ei([e,"access",O=>O.parentNode,"access",O=>O.sheet,"optionalAccess",O=>O.cssRules])&&(w=Sl(e.parentNode.sheet))}catch(O){console.warn(`Cannot get CSS styles from text's parentNode. Error: ${O}`,e)}w=El(w,xl(t.doc))}_&&(w="SCRIPT_PLACEHOLDER");const k=_o(e,r,a,i,c,n);if(!x&&!_&&!E&&w&&k&&(w=d?d(w,e.parentElement):w.replace(/[\S]/g,"*")),E&&w&&(f.textarea||k)&&(w=h?h(w,e.parentNode):w.replace(/[\S]/g,"*")),g==="OPTION"&&w){const O=wl({type:null,tagName:g,maskInputOptions:f});w=Ti({isMasked:_o(e,r,a,i,c,O),element:e,value:w,maskInputFn:h})}return{type:ft.Text,textContent:w||"",isStyle:x,rootId:y}}function R2(e,t){const{doc:n,blockClass:r,blockSelector:i,unblockSelector:a,inlineStylesheet:c,maskInputOptions:d={},maskAttributeFn:f,maskInputFn:h,dataURLOptions:y={},inlineImages:g,recordCanvas:w,keepIframeSrcFn:x,newlyAddedElement:_=!1,rootId:E,maskAllText:k,maskTextClass:O,unmaskTextClass:R,maskTextSelector:$,unmaskTextSelector:H}=t,z=E2(e,r,i,a),M=f2(e);let L={};const U=e.attributes.length;for(let K=0;K<U;K++){const oe=e.attributes[K];oe.name&&!h0(M,oe.name,oe.value)&&(L[oe.name]=p0(n,M,yo(oe.name),oe.value,e,f))}if(M==="link"&&c){const K=Array.from(n.styleSheets).find(ae=>ae.href===e.href);let oe=null;K&&(oe=Sl(K)),oe&&(L.rel=null,L.href=null,L.crossorigin=null,L._cssText=El(oe,K.href))}if(M==="style"&&e.sheet&&!(e.innerText||e.textContent||"").trim().length){const K=Sl(e.sheet);K&&(L._cssText=El(K,xl(n)))}if(M==="input"||M==="textarea"||M==="select"||M==="option"){const K=e,oe=Hd(K),ae=_l(K,Ud(M),oe),ye=K.checked;if(oe!=="submit"&&oe!=="button"&&ae){const Ie=_o(K,O,$,R,H,wl({type:oe,tagName:Ud(M),maskInputOptions:d}));L.value=Ti({isMasked:Ie,element:K,value:ae,maskInputFn:h})}ye&&(L.checked=ye)}if(M==="option"&&(e.selected&&!d.select?L.selected=!0:delete L.selected),M==="canvas"&&w){if(e.__context==="2d")c2(e)||(L.rr_dataURL=e.toDataURL(y.type,y.quality));else if(!("__context"in e)){const K=e.toDataURL(y.type,y.quality),oe=n.createElement("canvas");oe.width=e.width,oe.height=e.height;const ae=oe.toDataURL(y.type,y.quality);K!==ae&&(L.rr_dataURL=K)}}if(M==="img"&&g){vo||(vo=n.createElement("canvas"),d0=vo.getContext("2d"));const K=e,oe=K.currentSrc||K.getAttribute("src")||"<unknown-src>",ae=K.crossOrigin,ye=()=>{K.removeEventListener("load",ye);try{vo.width=K.naturalWidth,vo.height=K.naturalHeight,d0.drawImage(K,0,0),L.rr_dataURL=vo.toDataURL(y.type,y.quality)}catch(Ie){if(K.crossOrigin!=="anonymous"){K.crossOrigin="anonymous",K.complete&&K.naturalWidth!==0?ye():K.addEventListener("load",ye);return}else console.warn(`Cannot inline img src=${oe}! Error: ${Ie}`)}K.crossOrigin==="anonymous"&&(ae?L.crossOrigin=ae:K.removeAttribute("crossorigin"))};K.complete&&K.naturalWidth!==0?ye():K.addEventListener("load",ye)}if((M==="audio"||M==="video")&&(L.rr_mediaState=e.paused?"paused":"played",L.rr_mediaCurrentTime=e.currentTime),_||(e.scrollLeft&&(L.rr_scrollLeft=e.scrollLeft),e.scrollTop&&(L.rr_scrollTop=e.scrollTop)),z){const{width:K,height:oe}=e.getBoundingClientRect();L={class:L.class,rr_width:`${K}px`,rr_height:`${oe}px`}}M==="iframe"&&!x(L.src)&&(!z&&!u0(e)&&(L.rr_src=L.src),delete L.src);let te;try{customElements.get(M)&&(te=!0)}catch{}return{type:ft.Element,tagName:M,attributes:L,childNodes:[],isSVG:_2(e)||void 0,needBlock:z,rootId:E,isCustom:te}}function Ye(e){return e==null?"":e.toLowerCase()}function A2(e,t){if(t.comment&&e.type===ft.Comment)return!0;if(e.type===ft.Element){if(t.script&&(e.tagName==="script"||e.tagName==="link"&&(e.attributes.rel==="preload"||e.attributes.rel==="modulepreload")||e.tagName==="link"&&e.attributes.rel==="prefetch"&&typeof e.attributes.href=="string"&&i0(e.attributes.href)==="js"))return!0;if(t.headFavicon&&(e.tagName==="link"&&e.attributes.rel==="shortcut icon"||e.tagName==="meta"&&(Ye(e.attributes.name).match(/^msapplication-tile(image|color)$/)||Ye(e.attributes.name)==="application-name"||Ye(e.attributes.rel)==="icon"||Ye(e.attributes.rel)==="apple-touch-icon"||Ye(e.attributes.rel)==="shortcut icon")))return!0;if(e.tagName==="meta"){if(t.headMetaDescKeywords&&Ye(e.attributes.name).match(/^description|keywords$/))return!0;if(t.headMetaSocial&&(Ye(e.attributes.property).match(/^(og|twitter|fb):/)||Ye(e.attributes.name).match(/^(og|twitter):/)||Ye(e.attributes.name)==="pinterest"))return!0;if(t.headMetaRobots&&(Ye(e.attributes.name)==="robots"||Ye(e.attributes.name)==="googlebot"||Ye(e.attributes.name)==="bingbot"))return!0;if(t.headMetaHttpEquiv&&e.attributes["http-equiv"]!==void 0)return!0;if(t.headMetaAuthorship&&(Ye(e.attributes.name)==="author"||Ye(e.attributes.name)==="generator"||Ye(e.attributes.name)==="framework"||Ye(e.attributes.name)==="publisher"||Ye(e.attributes.name)==="progid"||Ye(e.attributes.property).match(/^article:/)||Ye(e.attributes.property).match(/^product:/)))return!0;if(t.headMetaVerification&&(Ye(e.attributes.name)==="google-site-verification"||Ye(e.attributes.name)==="yandex-verification"||Ye(e.attributes.name)==="csrf-token"||Ye(e.attributes.name)==="p:domain_verify"||Ye(e.attributes.name)==="verify-v1"||Ye(e.attributes.name)==="verification"||Ye(e.attributes.name)==="shopify-checkout-api-token"))return!0}}return!1}function Eo(e,t){const{doc:n,mirror:r,blockClass:i,blockSelector:a,unblockSelector:c,maskAllText:d,maskTextClass:f,unmaskTextClass:h,maskTextSelector:y,unmaskTextSelector:g,skipChild:w=!1,inlineStylesheet:x=!0,maskInputOptions:_={},maskAttributeFn:E,maskTextFn:k,maskInputFn:O,slimDOMOptions:R,dataURLOptions:$={},inlineImages:H=!1,recordCanvas:z=!1,onSerialize:M,onIframeLoad:L,iframeLoadTimeout:U=5e3,onStylesheetLoad:te,stylesheetLoadTimeout:K=5e3,keepIframeSrcFn:oe=()=>!1,newlyAddedElement:ae=!1}=t;let{preserveWhiteSpace:ye=!0}=t;const Ie=b2(e,{doc:n,mirror:r,blockClass:i,blockSelector:a,maskAllText:d,unblockSelector:c,maskTextClass:f,unmaskTextClass:h,maskTextSelector:y,unmaskTextSelector:g,inlineStylesheet:x,maskInputOptions:_,maskAttributeFn:E,maskTextFn:k,maskInputFn:O,dataURLOptions:$,inlineImages:H,recordCanvas:z,keepIframeSrcFn:oe,newlyAddedElement:ae});if(!Ie)return console.warn(e,"not serialized"),null;let We;r.hasNode(e)?We=r.getId(e):A2(Ie,R)||!ye&&Ie.type===ft.Text&&!Ie.isStyle&&!Ie.textContent.replace(/^\s+|\s+$/gm,"").length?We=bi:We=qd();const ce=Object.assign(Ie,{id:We});if(r.add(e,ce),We===bi)return null;M&&M(e);let ke=!w;if(ce.type===ft.Element){ke=ke&&!ce.needBlock,delete ce.needBlock;const W=e.shadowRoot;W&&ki(W)&&(ce.isShadowHost=!0)}if((ce.type===ft.Document||ce.type===ft.Element)&&ke){R.headWhitespace&&ce.type===ft.Element&&ce.tagName==="head"&&(ye=!1);const W={doc:n,mirror:r,blockClass:i,blockSelector:a,maskAllText:d,unblockSelector:c,maskTextClass:f,unmaskTextClass:h,maskTextSelector:y,unmaskTextSelector:g,skipChild:w,inlineStylesheet:x,maskInputOptions:_,maskAttributeFn:E,maskTextFn:k,maskInputFn:O,slimDOMOptions:R,dataURLOptions:$,inlineImages:H,recordCanvas:z,preserveWhiteSpace:ye,onSerialize:M,onIframeLoad:L,iframeLoadTimeout:U,onStylesheetLoad:te,stylesheetLoadTimeout:K,keepIframeSrcFn:oe};for(const re of Array.from(e.childNodes)){const J=Eo(re,W);J&&ce.childNodes.push(J)}if(t2(e)&&e.shadowRoot)for(const re of Array.from(e.shadowRoot.childNodes)){const J=Eo(re,W);J&&(ki(e.shadowRoot)&&(J.isShadow=!0),ce.childNodes.push(J))}}return e.parentNode&&xi(e.parentNode)&&ki(e.parentNode)&&(ce.isShadow=!0),ce.type===ft.Element&&ce.tagName==="iframe"&&k2(e,()=>{const W=u0(e);if(W&&L){const re=Eo(W,{doc:W,mirror:r,blockClass:i,blockSelector:a,unblockSelector:c,maskAllText:d,maskTextClass:f,unmaskTextClass:h,maskTextSelector:y,unmaskTextSelector:g,skipChild:!1,inlineStylesheet:x,maskInputOptions:_,maskAttributeFn:E,maskTextFn:k,maskInputFn:O,slimDOMOptions:R,dataURLOptions:$,inlineImages:H,recordCanvas:z,preserveWhiteSpace:ye,onSerialize:M,onIframeLoad:L,iframeLoadTimeout:U,onStylesheetLoad:te,stylesheetLoadTimeout:K,keepIframeSrcFn:oe});re&&L(e,re)}},U),ce.type===ft.Element&&ce.tagName==="link"&&typeof ce.attributes.rel=="string"&&(ce.attributes.rel==="stylesheet"||ce.attributes.rel==="preload"&&typeof ce.attributes.href=="string"&&i0(ce.attributes.href)==="css")&&T2(e,()=>{if(te){const W=Eo(e,{doc:n,mirror:r,blockClass:i,blockSelector:a,unblockSelector:c,maskAllText:d,maskTextClass:f,unmaskTextClass:h,maskTextSelector:y,unmaskTextSelector:g,skipChild:!1,inlineStylesheet:x,maskInputOptions:_,maskAttributeFn:E,maskTextFn:k,maskInputFn:O,slimDOMOptions:R,dataURLOptions:$,inlineImages:H,recordCanvas:z,preserveWhiteSpace:ye,onSerialize:M,onIframeLoad:L,iframeLoadTimeout:U,onStylesheetLoad:te,stylesheetLoadTimeout:K,keepIframeSrcFn:oe});W&&te(e,W)}},K),ce}function O2(e,t){const{mirror:n=new s0,blockClass:r="rr-block",blockSelector:i=null,unblockSelector:a=null,maskAllText:c=!1,maskTextClass:d="rr-mask",unmaskTextClass:f=null,maskTextSelector:h=null,unmaskTextSelector:y=null,inlineStylesheet:g=!0,inlineImages:w=!1,recordCanvas:x=!1,maskAllInputs:_=!1,maskAttributeFn:E,maskTextFn:k,maskInputFn:O,slimDOM:R=!1,dataURLOptions:$,preserveWhiteSpace:H,onSerialize:z,onIframeLoad:M,iframeLoadTimeout:L,onStylesheetLoad:U,stylesheetLoadTimeout:te,keepIframeSrcFn:K=()=>!1}=t||{};return Eo(e,{doc:e,mirror:n,blockClass:r,blockSelector:i,unblockSelector:a,maskAllText:c,maskTextClass:d,unmaskTextClass:f,maskTextSelector:h,unmaskTextSelector:y,skipChild:!1,inlineStylesheet:g,maskInputOptions:_===!0?{color:!0,date:!0,"datetime-local":!0,email:!0,month:!0,number:!0,range:!0,search:!0,tel:!0,text:!0,time:!0,url:!0,week:!0,textarea:!0,select:!0}:_===!1?{}:_,maskAttributeFn:E,maskTextFn:k,maskInputFn:O,slimDOMOptions:R===!0||R==="all"?{script:!0,comment:!0,headFavicon:!0,headWhitespace:!0,headMetaDescKeywords:R==="all",headMetaSocial:!0,headMetaRobots:!0,headMetaHttpEquiv:!0,headMetaAuthorship:!0,headMetaVerification:!0}:R===!1?{}:R,dataURLOptions:$,inlineImages:w,recordCanvas:x,preserveWhiteSpace:H,onSerialize:z,onIframeLoad:M,iframeLoadTimeout:L,onStylesheetLoad:U,stylesheetLoadTimeout:te,keepIframeSrcFn:K,newlyAddedElement:!1})}function Lr(e){let t,n=e[0],r=1;for(;r<e.length;){const i=e[r],a=e[r+1];if(r+=2,(i==="optionalAccess"||i==="optionalCall")&&n==null)return;i==="access"||i==="optionalAccess"?(t=n,n=a(n)):(i==="call"||i==="optionalCall")&&(n=a((...c)=>n.call(t,...c)),t=void 0)}return n}function Ut(e,t,n=document){const r={capture:!0,passive:!0};return n.addEventListener(e,t,r),()=>n.removeEventListener(e,t,r)}const xo=`Please stop import mirror directly. Instead of that,\r
now you can use replayer.getMirror() to access the mirror instance of a replayer,\r
or you can use record.mirror to access the mirror instance during recording.`;let m0={map:{},getId(){return console.error(xo),-1},getNode(){return console.error(xo),null},removeNodeFromMap(){console.error(xo)},has(){return console.error(xo),!1},reset(){console.error(xo)}};typeof window<"u"&&window.Proxy&&window.Reflect&&(m0=new Proxy(m0,{get(e,t,n){return t==="map"&&console.error(xo),Reflect.get(e,t,n)}}));function Ii(e,t,n={}){let r=null,i=0;return function(...a){const c=Date.now();!i&&n.leading===!1&&(i=c);const d=t-(c-i),f=this;d<=0||d>t?(r&&($2(r),r=null),i=c,e.apply(f,a)):!r&&n.trailing!==!1&&(r=Tl(()=>{i=n.leading===!1?0:Date.now(),r=null,e.apply(f,a)},d))}}function g0(e,t,n,r,i=window){const a=i.Object.getOwnPropertyDescriptor(e,t);return i.Object.defineProperty(e,t,r?n:{set(c){Tl(()=>{n.set.call(this,c)},0),a&&a.set&&a.set.call(this,c)}}),()=>g0(e,t,a||{},!0)}function Vd(e,t,n){try{if(!(t in e))return()=>{};const r=e[t],i=n(r);return typeof i=="function"&&(i.prototype=i.prototype||{},Object.defineProperties(i,{__rrweb_original__:{enumerable:!1,value:r}})),e[t]=i,()=>{e[t]=r}}catch{return()=>{}}}let kl=Date.now;/[1-9][0-9]{12}/.test(Date.now().toString())||(kl=()=>new Date().getTime());function y0(e){const t=e.document;return{left:t.scrollingElement?t.scrollingElement.scrollLeft:e.pageXOffset!==void 0?e.pageXOffset:Lr([t,"optionalAccess",n=>n.documentElement,"access",n=>n.scrollLeft])||Lr([t,"optionalAccess",n=>n.body,"optionalAccess",n=>n.parentElement,"optionalAccess",n=>n.scrollLeft])||Lr([t,"optionalAccess",n=>n.body,"optionalAccess",n=>n.scrollLeft])||0,top:t.scrollingElement?t.scrollingElement.scrollTop:e.pageYOffset!==void 0?e.pageYOffset:Lr([t,"optionalAccess",n=>n.documentElement,"access",n=>n.scrollTop])||Lr([t,"optionalAccess",n=>n.body,"optionalAccess",n=>n.parentElement,"optionalAccess",n=>n.scrollTop])||Lr([t,"optionalAccess",n=>n.body,"optionalAccess",n=>n.scrollTop])||0}}function v0(){return window.innerHeight||document.documentElement&&document.documentElement.clientHeight||document.body&&document.body.clientHeight}function S0(){return window.innerWidth||document.documentElement&&document.documentElement.clientWidth||document.body&&document.body.clientWidth}function w0(e){return e?e.nodeType===e.ELEMENT_NODE?e:e.parentElement:null}function an(e,t,n,r,i){if(!e)return!1;const a=w0(e);if(!a)return!1;const c=wo(t,n);if(!i){const h=r&&a.matches(r);return c(a)&&!h}const d=Ts(a,c);let f=-1;return d<0?!1:(r&&(f=Ts(a,wo(null,r))),d>-1&&f<0?!0:d<f)}function P2(e,t){return t.getId(e)!==-1}function Gd(e,t){return t.getId(e)===bi}function _0(e,t){if(xi(e))return!1;const n=t.getId(e);return t.has(n)?e.parentNode&&e.parentNode.nodeType===e.DOCUMENT_NODE?!1:e.parentNode?_0(e.parentNode,t):!0:!0}function Yd(e){return!!e.changedTouches}function N2(e=window){"NodeList"in e&&!e.NodeList.prototype.forEach&&(e.NodeList.prototype.forEach=Array.prototype.forEach),"DOMTokenList"in e&&!e.DOMTokenList.prototype.forEach&&(e.DOMTokenList.prototype.forEach=Array.prototype.forEach),Node.prototype.contains||(Node.prototype.contains=(...t)=>{let n=t[0];if(!(0 in t))throw new TypeError("1 argument is required");do if(this===n)return!0;while(n=n&&n.parentNode);return!1})}function E0(e,t){return!!(e.nodeName==="IFRAME"&&t.getMeta(e))}function x0(e,t){return!!(e.nodeName==="LINK"&&e.nodeType===e.ELEMENT_NODE&&e.getAttribute&&e.getAttribute("rel")==="stylesheet"&&t.getMeta(e))}function Kd(e){return!!Lr([e,"optionalAccess",t=>t.shadowRoot])}class M2{constructor(){this.id=1,this.styleIDMap=new WeakMap,this.idStyleMap=new Map}getId(t){return bI(this.styleIDMap.get(t),()=>-1)}has(t){return this.styleIDMap.has(t)}add(t,n){if(this.has(t))return this.getId(t);let r;return n===void 0?r=this.id++:r=n,this.styleIDMap.set(t,r),this.idStyleMap.set(r,t),r}getStyle(t){return this.idStyleMap.get(t)||null}reset(){this.styleIDMap=new WeakMap,this.idStyleMap=new Map,this.id=1}generateId(){return this.id++}}function k0(e){let t=null;return Lr([e,"access",n=>n.getRootNode,"optionalCall",n=>n(),"optionalAccess",n=>n.nodeType])===Node.DOCUMENT_FRAGMENT_NODE&&e.getRootNode().host&&(t=e.getRootNode().host),t}function L2(e){let t=e,n;for(;n=k0(t);)t=n;return t}function j2(e){const t=e.ownerDocument;if(!t)return!1;const n=L2(e);return t.contains(n)}function T0(e){const t=e.ownerDocument;return t?t.contains(e)||j2(e):!1}const b0={};function Qd(e){const t=b0[e];if(t)return t;const n=window.document;let r=window[e];if(n&&typeof n.createElement=="function")try{const i=n.createElement("iframe");i.hidden=!0,n.head.appendChild(i);const a=i.contentWindow;a&&a[e]&&(r=a[e]),n.head.removeChild(i)}catch{}return b0[e]=r.bind(window)}function D2(...e){return Qd("requestAnimationFrame")(...e)}function Tl(...e){return Qd("setTimeout")(...e)}function $2(...e){return Qd("clearTimeout")(...e)}var Te=(e=>(e[e.DomContentLoaded=0]="DomContentLoaded",e[e.Load=1]="Load",e[e.FullSnapshot=2]="FullSnapshot",e[e.IncrementalSnapshot=3]="IncrementalSnapshot",e[e.Meta=4]="Meta",e[e.Custom=5]="Custom",e[e.Plugin=6]="Plugin",e))(Te||{}),ge=(e=>(e[e.Mutation=0]="Mutation",e[e.MouseMove=1]="MouseMove",e[e.MouseInteraction=2]="MouseInteraction",e[e.Scroll=3]="Scroll",e[e.ViewportResize=4]="ViewportResize",e[e.Input=5]="Input",e[e.TouchMove=6]="TouchMove",e[e.MediaInteraction=7]="MediaInteraction",e[e.StyleSheetRule=8]="StyleSheetRule",e[e.CanvasMutation=9]="CanvasMutation",e[e.Font=10]="Font",e[e.Log=11]="Log",e[e.Drag=12]="Drag",e[e.StyleDeclaration=13]="StyleDeclaration",e[e.Selection=14]="Selection",e[e.AdoptedStyleSheet=15]="AdoptedStyleSheet",e[e.CustomElement=16]="CustomElement",e))(ge||{}),Ht=(e=>(e[e.MouseUp=0]="MouseUp",e[e.MouseDown=1]="MouseDown",e[e.Click=2]="Click",e[e.ContextMenu=3]="ContextMenu",e[e.DblClick=4]="DblClick",e[e.Focus=5]="Focus",e[e.Blur=6]="Blur",e[e.TouchStart=7]="TouchStart",e[e.TouchMove_Departed=8]="TouchMove_Departed",e[e.TouchEnd=9]="TouchEnd",e[e.TouchCancel=10]="TouchCancel",e))(Ht||{}),ur=(e=>(e[e.Mouse=0]="Mouse",e[e.Pen=1]="Pen",e[e.Touch=2]="Touch",e))(ur||{}),I0;(function(e){e[e.Document=0]="Document",e[e.DocumentType=1]="DocumentType",e[e.Element=2]="Element",e[e.Text=3]="Text",e[e.CDATA=4]="CDATA",e[e.Comment=5]="Comment"})(I0||(I0={}));var C0;(function(e){e[e.PLACEHOLDER=0]="PLACEHOLDER",e[e.ELEMENT_NODE=1]="ELEMENT_NODE",e[e.ATTRIBUTE_NODE=2]="ATTRIBUTE_NODE",e[e.TEXT_NODE=3]="TEXT_NODE",e[e.CDATA_SECTION_NODE=4]="CDATA_SECTION_NODE",e[e.ENTITY_REFERENCE_NODE=5]="ENTITY_REFERENCE_NODE",e[e.ENTITY_NODE=6]="ENTITY_NODE",e[e.PROCESSING_INSTRUCTION_NODE=7]="PROCESSING_INSTRUCTION_NODE",e[e.COMMENT_NODE=8]="COMMENT_NODE",e[e.DOCUMENT_NODE=9]="DOCUMENT_NODE",e[e.DOCUMENT_TYPE_NODE=10]="DOCUMENT_TYPE_NODE",e[e.DOCUMENT_FRAGMENT_NODE=11]="DOCUMENT_FRAGMENT_NODE"})(C0||(C0={}));function Xd(e){try{return e.contentDocument}catch{}}function F2(e){try{return e.contentWindow}catch{}}function B2(e){let t,n=e[0],r=1;for(;r<e.length;){const i=e[r],a=e[r+1];if(r+=2,(i==="optionalAccess"||i==="optionalCall")&&n==null)return;i==="access"||i==="optionalAccess"?(t=n,n=a(n)):(i==="call"||i==="optionalCall")&&(n=a((...c)=>n.call(t,...c)),t=void 0)}return n}function R0(e){return"__ln"in e}class z2{constructor(){this.length=0,this.head=null,this.tail=null}get(t){if(t>=this.length)throw new Error("Position outside of list range");let n=this.head;for(let r=0;r<t;r++)n=B2([n,"optionalAccess",i=>i.next])||null;return n}addNode(t){const n={value:t,previous:null,next:null};if(t.__ln=n,t.previousSibling&&R0(t.previousSibling)){const r=t.previousSibling.__ln.next;n.next=r,n.previous=t.previousSibling.__ln,t.previousSibling.__ln.next=n,r&&(r.previous=n)}else if(t.nextSibling&&R0(t.nextSibling)&&t.nextSibling.__ln.previous){const r=t.nextSibling.__ln.previous;n.previous=r,n.next=t.nextSibling.__ln,t.nextSibling.__ln.previous=n,r&&(r.next=n)}else this.head&&(this.head.previous=n),n.next=this.head,this.head=n;n.next===null&&(this.tail=n),this.length++}removeNode(t){const n=t.__ln;this.head&&(n.previous?(n.previous.next=n.next,n.next?n.next.previous=n.previous:this.tail=n.previous):(this.head=n.next,this.head?this.head.previous=null:this.tail=null),t.__ln&&delete t.__ln,this.length--)}}const A0=(e,t)=>`${e}@${t}`;class U2{constructor(){this.frozen=!1,this.locked=!1,this.texts=[],this.attributes=[],this.attributeMap=new WeakMap,this.removes=[],this.mapRemoves=[],this.movedMap={},this.addedSet=new Set,this.movedSet=new Set,this.droppedSet=new Set,this.processMutations=t=>{t.forEach(this.processMutation),this.emit()},this.emit=()=>{if(this.frozen||this.locked)return;const t=[],n=new Set,r=new z2,i=f=>{let h=f,y=bi;for(;y===bi;)h=h&&h.nextSibling,y=h&&this.mirror.getId(h);return y},a=f=>{if(!f.parentNode||!T0(f))return;const h=xi(f.parentNode)?this.mirror.getId(k0(f)):this.mirror.getId(f.parentNode),y=i(f);if(h===-1||y===-1)return r.addNode(f);const g=Eo(f,{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:w=>{E0(w,this.mirror)&&!an(w,this.blockClass,this.blockSelector,this.unblockSelector,!1)&&this.iframeManager.addIframe(w),x0(w,this.mirror)&&this.stylesheetManager.trackLinkElement(w),Kd(f)&&this.shadowDomManager.addShadowRoot(f.shadowRoot,this.doc)},onIframeLoad:(w,x)=>{an(w,this.blockClass,this.blockSelector,this.unblockSelector,!1)||(this.iframeManager.attachIframe(w,x),w.contentWindow&&this.canvasManager.addWindow(w.contentWindow),this.shadowDomManager.observeAttachShadow(w))},onStylesheetLoad:(w,x)=>{this.stylesheetManager.attachLinkElement(w,x)}});g&&(t.push({parentId:h,nextId:y,node:g}),n.add(g.id))};for(;this.mapRemoves.length;)this.mirror.removeNodeFromMap(this.mapRemoves.shift());for(const f of this.movedSet)O0(this.removes,f,this.mirror)&&!this.movedSet.has(f.parentNode)||a(f);for(const f of this.addedSet)!P0(this.droppedSet,f)&&!O0(this.removes,f,this.mirror)||P0(this.movedSet,f)?a(f):this.droppedSet.add(f);let c=null;for(;r.length;){let f=null;if(c){const h=this.mirror.getId(c.value.parentNode),y=i(c.value);h!==-1&&y!==-1&&(f=c)}if(!f){let h=r.tail;for(;h;){const y=h;if(h=h.previous,y){const g=this.mirror.getId(y.value.parentNode);if(i(y.value)===-1)continue;if(g!==-1){f=y;break}else{const x=y.value;if(x.parentNode&&x.parentNode.nodeType===Node.DOCUMENT_FRAGMENT_NODE){const _=x.parentNode.host;if(this.mirror.getId(_)!==-1){f=y;break}}}}}}if(!f){for(;r.head;)r.removeNode(r.head.value);break}c=f.previous,r.removeNode(f.value),a(f.value)}const d={texts:this.texts.map(f=>({id:this.mirror.getId(f.node),value:f.value})).filter(f=>!n.has(f.id)).filter(f=>this.mirror.has(f.id)),attributes:this.attributes.map(f=>{const{attributes:h}=f;if(typeof h.style=="string"){const y=JSON.stringify(f.styleDiff),g=JSON.stringify(f._unchangedStyles);y.length<h.style.length&&(y+g).split("var(").length===h.style.split("var(").length&&(h.style=f.styleDiff)}return{id:this.mirror.getId(f.node),attributes:h}}).filter(f=>!n.has(f.id)).filter(f=>this.mirror.has(f.id)),removes:this.removes,adds:t};!d.texts.length&&!d.attributes.length&&!d.removes.length&&!d.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(d))},this.processMutation=t=>{if(!Gd(t.target,this.mirror))switch(t.type){case"characterData":{const n=t.target.textContent;!an(t.target,this.blockClass,this.blockSelector,this.unblockSelector,!1)&&n!==t.oldValue&&this.texts.push({value:_o(t.target,this.maskTextClass,this.maskTextSelector,this.unmaskTextClass,this.unmaskTextSelector,this.maskAllText)&&n?this.maskTextFn?this.maskTextFn(n,w0(t.target)):n.replace(/[\S]/g,"*"):n,node:t.target});break}case"attributes":{const n=t.target;let r=t.attributeName,i=t.target.getAttribute(r);if(r==="value"){const c=Hd(n),d=n.tagName;i=_l(n,d,c);const f=wl({maskInputOptions:this.maskInputOptions,tagName:d,type:c}),h=_o(t.target,this.maskTextClass,this.maskTextSelector,this.unmaskTextClass,this.unmaskTextSelector,f);i=Ti({isMasked:h,element:n,value:i,maskInputFn:this.maskInputFn})}if(an(t.target,this.blockClass,this.blockSelector,this.unblockSelector,!1)||i===t.oldValue)return;let a=this.attributeMap.get(t.target);if(n.tagName==="IFRAME"&&r==="src"&&!this.keepIframeSrcFn(i))if(!Xd(n))r="rr_src";else return;if(a||(a={node:t.target,attributes:{},styleDiff:{},_unchangedStyles:{}},this.attributes.push(a),this.attributeMap.set(t.target,a)),r==="type"&&n.tagName==="INPUT"&&(t.oldValue||"").toLowerCase()==="password"&&n.setAttribute("data-rr-is-password","true"),!h0(n.tagName,r)&&(a.attributes[r]=p0(this.doc,yo(n.tagName),yo(r),i,n,this.maskAttributeFn),r==="style")){if(!this.unattachedDoc)try{this.unattachedDoc=document.implementation.createHTMLDocument()}catch{this.unattachedDoc=this.doc}const c=this.unattachedDoc.createElement("span");t.oldValue&&c.setAttribute("style",t.oldValue);for(const d of Array.from(n.style)){const f=n.style.getPropertyValue(d),h=n.style.getPropertyPriority(d);f!==c.style.getPropertyValue(d)||h!==c.style.getPropertyPriority(d)?h===""?a.styleDiff[d]=f:a.styleDiff[d]=[f,h]:a._unchangedStyles[d]=[f,h]}for(const d of Array.from(c.style))n.style.getPropertyValue(d)===""&&(a.styleDiff[d]=!1)}break}case"childList":{if(an(t.target,this.blockClass,this.blockSelector,this.unblockSelector,!0))return;t.addedNodes.forEach(n=>this.genAdds(n,t.target)),t.removedNodes.forEach(n=>{const r=this.mirror.getId(n),i=xi(t.target)?this.mirror.getId(t.target.host):this.mirror.getId(t.target);an(t.target,this.blockClass,this.blockSelector,this.unblockSelector,!1)||Gd(n,this.mirror)||!P2(n,this.mirror)||(this.addedSet.has(n)?(Jd(this.addedSet,n),this.droppedSet.add(n)):this.addedSet.has(t.target)&&r===-1||_0(t.target,this.mirror)||(this.movedSet.has(n)&&this.movedMap[A0(r,i)]?Jd(this.movedSet,n):this.removes.push({parentId:i,id:r,isShadow:xi(t.target)&&ki(t.target)?!0:void 0})),this.mapRemoves.push(n))});break}}},this.genAdds=(t,n)=>{if(!this.processedNodeManager.inOtherBuffer(t,this)&&!(this.addedSet.has(t)||this.movedSet.has(t))){if(this.mirror.hasNode(t)){if(Gd(t,this.mirror))return;this.movedSet.add(t);let r=null;n&&this.mirror.hasNode(n)&&(r=this.mirror.getId(n)),r&&r!==-1&&(this.movedMap[A0(this.mirror.getId(t),r)]=!0)}else this.addedSet.add(t),this.droppedSet.delete(t);an(t,this.blockClass,this.blockSelector,this.unblockSelector,!1)||(t.childNodes.forEach(r=>this.genAdds(r)),Kd(t)&&t.shadowRoot.childNodes.forEach(r=>{this.processedNodeManager.add(r,this),this.genAdds(r,t)}))}}}init(t){["mutationCb","blockClass","blockSelector","unblockSelector","maskAllText","maskTextClass","unmaskTextClass","maskTextSelector","unmaskTextSelector","inlineStylesheet","maskInputOptions","maskAttributeFn","maskTextFn","maskInputFn","keepIframeSrcFn","recordCanvas","inlineImages","slimDOMOptions","dataURLOptions","doc","mirror","iframeManager","stylesheetManager","shadowDomManager","canvasManager","processedNodeManager"].forEach(n=>{this[n]=t[n]})}freeze(){this.frozen=!0,this.canvasManager.freeze()}unfreeze(){this.frozen=!1,this.canvasManager.unfreeze(),this.emit()}isFrozen(){return this.frozen}lock(){this.locked=!0,this.canvasManager.lock()}unlock(){this.locked=!1,this.canvasManager.unlock(),this.emit()}reset(){this.shadowDomManager.reset(),this.canvasManager.reset()}}function Jd(e,t){e.delete(t),t.childNodes.forEach(n=>Jd(e,n))}function O0(e,t,n){return e.length===0?!1:H2(e,t,n)}function H2(e,t,n){let r=t.parentNode;for(;r;){const i=n.getId(r);if(e.some(a=>a.id===i))return!0;r=r.parentNode}return!1}function P0(e,t){return e.size===0?!1:N0(e,t)}function N0(e,t){const{parentNode:n}=t;return n?e.has(n)?!0:N0(e,n):!1}let Ci;function W2(e){Ci=e}function q2(){Ci=void 0}const Le=e=>Ci?(...n)=>{try{return e(...n)}catch(r){if(Ci&&Ci(r)===!0)return()=>{};throw r}}:e;function On(e){let t,n=e[0],r=1;for(;r<e.length;){const i=e[r],a=e[r+1];if(r+=2,(i==="optionalAccess"||i==="optionalCall")&&n==null)return;i==="access"||i==="optionalAccess"?(t=n,n=a(n)):(i==="call"||i==="optionalCall")&&(n=a((...c)=>n.call(t,...c)),t=void 0)}return n}const ko=[];function Ri(e){try{if("composedPath"in e){const t=e.composedPath();if(t.length)return t[0]}else if("path"in e&&e.path.length)return e.path[0]}catch{}return e&&e.target}function M0(e,t){const n=new U2;ko.push(n),n.init(e);let r=window.MutationObserver||window.__rrMutationObserver;const i=On([window,"optionalAccess",c=>c.Zone,"optionalAccess",c=>c.__symbol__,"optionalCall",c=>c("MutationObserver")]);i&&window[i]&&(r=window[i]);const a=new r(Le(c=>{e.onMutation&&e.onMutation(c)===!1||n.processMutations.bind(n)(c)}));return a.observe(t,{attributes:!0,attributeOldValue:!0,characterData:!0,characterDataOldValue:!0,childList:!0,subtree:!0}),a}function V2({mousemoveCb:e,sampling:t,doc:n,mirror:r}){if(t.mousemove===!1)return()=>{};const i=typeof t.mousemove=="number"?t.mousemove:50,a=typeof t.mousemoveCallback=="number"?t.mousemoveCallback:500;let c=[],d;const f=Ii(Le(g=>{const w=Date.now()-d;e(c.map(x=>(x.timeOffset-=w,x)),g),c=[],d=null}),a),h=Le(Ii(Le(g=>{const w=Ri(g),{clientX:x,clientY:_}=Yd(g)?g.changedTouches[0]:g;d||(d=kl()),c.push({x,y:_,id:r.getId(w),timeOffset:kl()-d}),f(typeof DragEvent<"u"&&g instanceof DragEvent?ge.Drag:g instanceof MouseEvent?ge.MouseMove:ge.TouchMove)}),i,{trailing:!1})),y=[Ut("mousemove",h,n),Ut("touchmove",h,n),Ut("drag",h,n)];return Le(()=>{y.forEach(g=>g())})}function G2({mouseInteractionCb:e,doc:t,mirror:n,blockClass:r,blockSelector:i,unblockSelector:a,sampling:c}){if(c.mouseInteraction===!1)return()=>{};const d=c.mouseInteraction===!0||c.mouseInteraction===void 0?{}:c.mouseInteraction,f=[];let h=null;const y=g=>w=>{const x=Ri(w);if(an(x,r,i,a,!0))return;let _=null,E=g;if("pointerType"in w){switch(w.pointerType){case"mouse":_=ur.Mouse;break;case"touch":_=ur.Touch;break;case"pen":_=ur.Pen;break}_===ur.Touch?Ht[g]===Ht.MouseDown?E="TouchStart":Ht[g]===Ht.MouseUp&&(E="TouchEnd"):ur.Pen}else Yd(w)&&(_=ur.Touch);_!==null?(h=_,(E.startsWith("Touch")&&_===ur.Touch||E.startsWith("Mouse")&&_===ur.Mouse)&&(_=null)):Ht[g]===Ht.Click&&(_=h,h=null);const k=Yd(w)?w.changedTouches[0]:w;if(!k)return;const O=n.getId(x),{clientX:R,clientY:$}=k;Le(e)({type:Ht[E],id:O,x:R,y:$,..._!==null&&{pointerType:_}})};return Object.keys(Ht).filter(g=>Number.isNaN(Number(g))&&!g.endsWith("_Departed")&&d[g]!==!1).forEach(g=>{let w=yo(g);const x=y(g);if(window.PointerEvent)switch(Ht[g]){case Ht.MouseDown:case Ht.MouseUp:w=w.replace("mouse","pointer");break;case Ht.TouchStart:case Ht.TouchEnd:return}f.push(Ut(w,x,t))}),Le(()=>{f.forEach(g=>g())})}function L0({scrollCb:e,doc:t,mirror:n,blockClass:r,blockSelector:i,unblockSelector:a,sampling:c}){const d=Le(Ii(Le(f=>{const h=Ri(f);if(!h||an(h,r,i,a,!0))return;const y=n.getId(h);if(h===t&&t.defaultView){const g=y0(t.defaultView);e({id:y,x:g.left,y:g.top})}else e({id:y,x:h.scrollLeft,y:h.scrollTop})}),c.scroll||100));return Ut("scroll",d,t)}function Y2({viewportResizeCb:e},{win:t}){let n=-1,r=-1;const i=Le(Ii(Le(()=>{const a=v0(),c=S0();(n!==a||r!==c)&&(e({width:Number(c),height:Number(a)}),n=a,r=c)}),200));return Ut("resize",i,t)}const K2=["INPUT","TEXTAREA","SELECT"],j0=new WeakMap;function Q2({inputCb:e,doc:t,mirror:n,blockClass:r,blockSelector:i,unblockSelector:a,ignoreClass:c,ignoreSelector:d,maskInputOptions:f,maskInputFn:h,sampling:y,userTriggeredOnInput:g,maskTextClass:w,unmaskTextClass:x,maskTextSelector:_,unmaskTextSelector:E}){function k(L){let U=Ri(L);const te=L.isTrusted,K=U&&Ud(U.tagName);if(K==="OPTION"&&(U=U.parentElement),!U||!K||K2.indexOf(K)<0||an(U,r,i,a,!0))return;const oe=U;if(oe.classList.contains(c)||d&&oe.matches(d))return;const ae=Hd(U);let ye=_l(oe,K,ae),Ie=!1;const We=wl({maskInputOptions:f,tagName:K,type:ae}),ce=_o(U,w,_,x,E,We);(ae==="radio"||ae==="checkbox")&&(Ie=U.checked),ye=Ti({isMasked:ce,element:U,value:ye,maskInputFn:h}),O(U,g?{text:ye,isChecked:Ie,userTriggered:te}:{text:ye,isChecked:Ie});const ke=U.name;ae==="radio"&&ke&&Ie&&t.querySelectorAll(`input[type="radio"][name="${ke}"]`).forEach(W=>{if(W!==U){const re=Ti({isMasked:ce,element:W,value:_l(W,K,ae),maskInputFn:h});O(W,g?{text:re,isChecked:!Ie,userTriggered:!1}:{text:re,isChecked:!Ie})}})}function O(L,U){const te=j0.get(L);if(!te||te.text!==U.text||te.isChecked!==U.isChecked){j0.set(L,U);const K=n.getId(L);Le(e)({...U,id:K})}}const $=(y.input==="last"?["change"]:["input","change"]).map(L=>Ut(L,Le(k),t)),H=t.defaultView;if(!H)return()=>{$.forEach(L=>L())};const z=H.Object.getOwnPropertyDescriptor(H.HTMLInputElement.prototype,"value"),M=[[H.HTMLInputElement.prototype,"value"],[H.HTMLInputElement.prototype,"checked"],[H.HTMLSelectElement.prototype,"value"],[H.HTMLTextAreaElement.prototype,"value"],[H.HTMLSelectElement.prototype,"selectedIndex"],[H.HTMLOptionElement.prototype,"selected"]];return z&&z.set&&$.push(...M.map(L=>g0(L[0],L[1],{set(){Le(k)({target:this,isTrusted:!1})}},!1,H))),Le(()=>{$.forEach(L=>L())})}function bl(e){const t=[];function n(r,i){if(Il("CSSGroupingRule")&&r.parentRule instanceof CSSGroupingRule||Il("CSSMediaRule")&&r.parentRule instanceof CSSMediaRule||Il("CSSSupportsRule")&&r.parentRule instanceof CSSSupportsRule||Il("CSSConditionRule")&&r.parentRule instanceof CSSConditionRule){const c=Array.from(r.parentRule.cssRules).indexOf(r);i.unshift(c)}else if(r.parentStyleSheet){const c=Array.from(r.parentStyleSheet.cssRules).indexOf(r);i.unshift(c)}return i}return n(e,t)}function jr(e,t,n){let r,i;return e?(e.ownerNode?r=t.getId(e.ownerNode):i=n.getId(e),{styleId:i,id:r}):{}}function X2({styleSheetRuleCb:e,mirror:t,stylesheetManager:n},{win:r}){if(!r.CSSStyleSheet||!r.CSSStyleSheet.prototype)return()=>{};const i=r.CSSStyleSheet.prototype.insertRule;r.CSSStyleSheet.prototype.insertRule=new Proxy(i,{apply:Le((y,g,w)=>{const[x,_]=w,{id:E,styleId:k}=jr(g,t,n.styleMirror);return(E&&E!==-1||k&&k!==-1)&&e({id:E,styleId:k,adds:[{rule:x,index:_}]}),y.apply(g,w)})});const a=r.CSSStyleSheet.prototype.deleteRule;r.CSSStyleSheet.prototype.deleteRule=new Proxy(a,{apply:Le((y,g,w)=>{const[x]=w,{id:_,styleId:E}=jr(g,t,n.styleMirror);return(_&&_!==-1||E&&E!==-1)&&e({id:_,styleId:E,removes:[{index:x}]}),y.apply(g,w)})});let c;r.CSSStyleSheet.prototype.replace&&(c=r.CSSStyleSheet.prototype.replace,r.CSSStyleSheet.prototype.replace=new Proxy(c,{apply:Le((y,g,w)=>{const[x]=w,{id:_,styleId:E}=jr(g,t,n.styleMirror);return(_&&_!==-1||E&&E!==-1)&&e({id:_,styleId:E,replace:x}),y.apply(g,w)})}));let d;r.CSSStyleSheet.prototype.replaceSync&&(d=r.CSSStyleSheet.prototype.replaceSync,r.CSSStyleSheet.prototype.replaceSync=new Proxy(d,{apply:Le((y,g,w)=>{const[x]=w,{id:_,styleId:E}=jr(g,t,n.styleMirror);return(_&&_!==-1||E&&E!==-1)&&e({id:_,styleId:E,replaceSync:x}),y.apply(g,w)})}));const f={};Cl("CSSGroupingRule")?f.CSSGroupingRule=r.CSSGroupingRule:(Cl("CSSMediaRule")&&(f.CSSMediaRule=r.CSSMediaRule),Cl("CSSConditionRule")&&(f.CSSConditionRule=r.CSSConditionRule),Cl("CSSSupportsRule")&&(f.CSSSupportsRule=r.CSSSupportsRule));const h={};return Object.entries(f).forEach(([y,g])=>{h[y]={insertRule:g.prototype.insertRule,deleteRule:g.prototype.deleteRule},g.prototype.insertRule=new Proxy(h[y].insertRule,{apply:Le((w,x,_)=>{const[E,k]=_,{id:O,styleId:R}=jr(x.parentStyleSheet,t,n.styleMirror);return(O&&O!==-1||R&&R!==-1)&&e({id:O,styleId:R,adds:[{rule:E,index:[...bl(x),k||0]}]}),w.apply(x,_)})}),g.prototype.deleteRule=new Proxy(h[y].deleteRule,{apply:Le((w,x,_)=>{const[E]=_,{id:k,styleId:O}=jr(x.parentStyleSheet,t,n.styleMirror);return(k&&k!==-1||O&&O!==-1)&&e({id:k,styleId:O,removes:[{index:[...bl(x),E]}]}),w.apply(x,_)})})}),Le(()=>{r.CSSStyleSheet.prototype.insertRule=i,r.CSSStyleSheet.prototype.deleteRule=a,c&&(r.CSSStyleSheet.prototype.replace=c),d&&(r.CSSStyleSheet.prototype.replaceSync=d),Object.entries(f).forEach(([y,g])=>{g.prototype.insertRule=h[y].insertRule,g.prototype.deleteRule=h[y].deleteRule})})}function D0({mirror:e,stylesheetManager:t},n){let r=null;n.nodeName==="#document"?r=e.getId(n):r=e.getId(n.host);const i=n.nodeName==="#document"?On([n,"access",c=>c.defaultView,"optionalAccess",c=>c.Document]):On([n,"access",c=>c.ownerDocument,"optionalAccess",c=>c.defaultView,"optionalAccess",c=>c.ShadowRoot]),a=On([i,"optionalAccess",c=>c.prototype])?Object.getOwnPropertyDescriptor(On([i,"optionalAccess",c=>c.prototype]),"adoptedStyleSheets"):void 0;return r===null||r===-1||!i||!a?()=>{}:(Object.defineProperty(n,"adoptedStyleSheets",{configurable:a.configurable,enumerable:a.enumerable,get(){return On([a,"access",c=>c.get,"optionalAccess",c=>c.call,"call",c=>c(this)])},set(c){const d=On([a,"access",f=>f.set,"optionalAccess",f=>f.call,"call",f=>f(this,c)]);if(r!==null&&r!==-1)try{t.adoptStyleSheets(c,r)}catch{}return d}}),Le(()=>{Object.defineProperty(n,"adoptedStyleSheets",{configurable:a.configurable,enumerable:a.enumerable,get:a.get,set:a.set})}))}function J2({styleDeclarationCb:e,mirror:t,ignoreCSSAttributes:n,stylesheetManager:r},{win:i}){const a=i.CSSStyleDeclaration.prototype.setProperty;i.CSSStyleDeclaration.prototype.setProperty=new Proxy(a,{apply:Le((d,f,h)=>{const[y,g,w]=h;if(n.has(y))return a.apply(f,[y,g,w]);const{id:x,styleId:_}=jr(On([f,"access",E=>E.parentRule,"optionalAccess",E=>E.parentStyleSheet]),t,r.styleMirror);return(x&&x!==-1||_&&_!==-1)&&e({id:x,styleId:_,set:{property:y,value:g,priority:w},index:bl(f.parentRule)}),d.apply(f,h)})});const c=i.CSSStyleDeclaration.prototype.removeProperty;return i.CSSStyleDeclaration.prototype.removeProperty=new Proxy(c,{apply:Le((d,f,h)=>{const[y]=h;if(n.has(y))return c.apply(f,[y]);const{id:g,styleId:w}=jr(On([f,"access",x=>x.parentRule,"optionalAccess",x=>x.parentStyleSheet]),t,r.styleMirror);return(g&&g!==-1||w&&w!==-1)&&e({id:g,styleId:w,remove:{property:y},index:bl(f.parentRule)}),d.apply(f,h)})}),Le(()=>{i.CSSStyleDeclaration.prototype.setProperty=a,i.CSSStyleDeclaration.prototype.removeProperty=c})}function Z2({mediaInteractionCb:e,blockClass:t,blockSelector:n,unblockSelector:r,mirror:i,sampling:a,doc:c}){const d=Le(h=>Ii(Le(y=>{const g=Ri(y);if(!g||an(g,t,n,r,!0))return;const{currentTime:w,volume:x,muted:_,playbackRate:E}=g;e({type:h,id:i.getId(g),currentTime:w,volume:x,muted:_,playbackRate:E})}),a.media||500)),f=[Ut("play",d(0),c),Ut("pause",d(1),c),Ut("seeked",d(2),c),Ut("volumechange",d(3),c),Ut("ratechange",d(4),c)];return Le(()=>{f.forEach(h=>h())})}function eA({fontCb:e,doc:t}){const n=t.defaultView;if(!n)return()=>{};const r=[],i=new WeakMap,a=n.FontFace;n.FontFace=function(f,h,y){const g=new a(f,h,y);return i.set(g,{family:f,buffer:typeof h!="string",descriptors:y,fontSource:typeof h=="string"?h:JSON.stringify(Array.from(new Uint8Array(h)))}),g};const c=Vd(t.fonts,"add",function(d){return function(f){return Tl(Le(()=>{const h=i.get(f);h&&(e(h),i.delete(f))}),0),d.apply(this,[f])}});return r.push(()=>{n.FontFace=a}),r.push(c),Le(()=>{r.forEach(d=>d())})}function tA(e){const{doc:t,mirror:n,blockClass:r,blockSelector:i,unblockSelector:a,selectionCb:c}=e;let d=!0;const f=Le(()=>{const h=t.getSelection();if(!h||d&&On([h,"optionalAccess",w=>w.isCollapsed]))return;d=h.isCollapsed||!1;const y=[],g=h.rangeCount||0;for(let w=0;w<g;w++){const x=h.getRangeAt(w),{startContainer:_,startOffset:E,endContainer:k,endOffset:O}=x;an(_,r,i,a,!0)||an(k,r,i,a,!0)||y.push({start:n.getId(_),startOffset:E,end:n.getId(k),endOffset:O})}c({ranges:y})});return f(),Ut("selectionchange",f)}function nA({doc:e,customElementCb:t}){const n=e.defaultView;return!n||!n.customElements?()=>{}:Vd(n.customElements,"define",function(i){return function(a,c,d){try{t({define:{name:a}})}catch{}return i.apply(this,[a,c,d])}})}function rA(e,t={}){const n=e.doc.defaultView;if(!n)return()=>{};let r;e.recordDOM&&(r=M0(e,e.doc));const i=V2(e),a=G2(e),c=L0(e),d=Y2(e,{win:n}),f=Q2(e),h=Z2(e);let y=()=>{},g=()=>{},w=()=>{},x=()=>{};e.recordDOM&&(y=X2(e,{win:n}),g=D0(e,e.doc),w=J2(e,{win:n}),e.collectFonts&&(x=eA(e)));const _=tA(e),E=nA(e),k=[];for(const O of e.plugins)k.push(O.observer(O.callback,n,O.options));return Le(()=>{ko.forEach(O=>O.reset()),On([r,"optionalAccess",O=>O.disconnect,"call",O=>O()]),i(),a(),c(),d(),f(),h(),y(),g(),w(),x(),_(),E(),k.forEach(O=>O())})}function Il(e){return typeof window[e]<"u"}function Cl(e){return!!(typeof window[e]<"u"&&window[e].prototype&&"insertRule"in window[e].prototype&&"deleteRule"in window[e].prototype)}class Zd{constructor(t){this.generateIdFn=t,this.iframeIdToRemoteIdMap=new WeakMap,this.iframeRemoteIdToIdMap=new WeakMap}getId(t,n,r,i){const a=r||this.getIdToRemoteIdMap(t),c=i||this.getRemoteIdToIdMap(t);let d=a.get(n);return d||(d=this.generateIdFn(),a.set(n,d),c.set(d,n)),d}getIds(t,n){const r=this.getIdToRemoteIdMap(t),i=this.getRemoteIdToIdMap(t);return n.map(a=>this.getId(t,a,r,i))}getRemoteId(t,n,r){const i=r||this.getRemoteIdToIdMap(t);if(typeof n!="number")return n;const a=i.get(n);return a||-1}getRemoteIds(t,n){const r=this.getRemoteIdToIdMap(t);return n.map(i=>this.getRemoteId(t,i,r))}reset(t){if(!t){this.iframeIdToRemoteIdMap=new WeakMap,this.iframeRemoteIdToIdMap=new WeakMap;return}this.iframeIdToRemoteIdMap.delete(t),this.iframeRemoteIdToIdMap.delete(t)}getIdToRemoteIdMap(t){let n=this.iframeIdToRemoteIdMap.get(t);return n||(n=new Map,this.iframeIdToRemoteIdMap.set(t,n)),n}getRemoteIdToIdMap(t){let n=this.iframeRemoteIdToIdMap.get(t);return n||(n=new Map,this.iframeRemoteIdToIdMap.set(t,n)),n}}function $0(e){let t,n=e[0],r=1;for(;r<e.length;){const i=e[r],a=e[r+1];if(r+=2,(i==="optionalAccess"||i==="optionalCall")&&n==null)return;i==="access"||i==="optionalAccess"?(t=n,n=a(n)):(i==="call"||i==="optionalCall")&&(n=a((...c)=>n.call(t,...c)),t=void 0)}return n}class sA{constructor(){this.crossOriginIframeMirror=new Zd(qd),this.crossOriginIframeRootIdMap=new WeakMap}addIframe(){}addLoadListener(){}attachIframe(){}}class oA{constructor(t){this.iframes=new WeakMap,this.crossOriginIframeMap=new WeakMap,this.crossOriginIframeMirror=new Zd(qd),this.crossOriginIframeRootIdMap=new WeakMap,this.mutationCb=t.mutationCb,this.wrappedEmit=t.wrappedEmit,this.stylesheetManager=t.stylesheetManager,this.recordCrossOriginIframes=t.recordCrossOriginIframes,this.crossOriginIframeStyleMirror=new Zd(this.stylesheetManager.styleMirror.generateId.bind(this.stylesheetManager.styleMirror)),this.mirror=t.mirror,this.recordCrossOriginIframes&&window.addEventListener("message",this.handleMessage.bind(this))}addIframe(t){this.iframes.set(t,!0),t.contentWindow&&this.crossOriginIframeMap.set(t.contentWindow,t)}addLoadListener(t){this.loadListener=t}attachIframe(t,n){this.mutationCb({adds:[{parentId:this.mirror.getId(t),nextId:null,node:n}],removes:[],texts:[],attributes:[],isAttachIframe:!0}),$0([this,"access",i=>i.loadListener,"optionalCall",i=>i(t)]);const r=Xd(t);r&&r.adoptedStyleSheets&&r.adoptedStyleSheets.length>0&&this.stylesheetManager.adoptStyleSheets(r.adoptedStyleSheets,this.mirror.getId(r))}handleMessage(t){const n=t;if(n.data.type!=="rrweb"||n.origin!==n.data.origin||!t.source)return;const i=this.crossOriginIframeMap.get(t.source);if(!i)return;const a=this.transformCrossOriginEvent(i,n.data.event);a&&this.wrappedEmit(a,n.data.isCheckout)}transformCrossOriginEvent(t,n){switch(n.type){case Te.FullSnapshot:{this.crossOriginIframeMirror.reset(t),this.crossOriginIframeStyleMirror.reset(t),this.replaceIdOnNode(n.data.node,t);const r=n.data.node.id;return this.crossOriginIframeRootIdMap.set(t,r),this.patchRootIdOnNode(n.data.node,r),{timestamp:n.timestamp,type:Te.IncrementalSnapshot,data:{source:ge.Mutation,adds:[{parentId:this.mirror.getId(t),nextId:null,node:n.data.node}],removes:[],texts:[],attributes:[],isAttachIframe:!0}}}case Te.Meta:case Te.Load:case Te.DomContentLoaded:return!1;case Te.Plugin:return n;case Te.Custom:return this.replaceIds(n.data.payload,t,["id","parentId","previousId","nextId"]),n;case Te.IncrementalSnapshot:switch(n.data.source){case ge.Mutation:return n.data.adds.forEach(r=>{this.replaceIds(r,t,["parentId","nextId","previousId"]),this.replaceIdOnNode(r.node,t);const i=this.crossOriginIframeRootIdMap.get(t);i&&this.patchRootIdOnNode(r.node,i)}),n.data.removes.forEach(r=>{this.replaceIds(r,t,["parentId","id"])}),n.data.attributes.forEach(r=>{this.replaceIds(r,t,["id"])}),n.data.texts.forEach(r=>{this.replaceIds(r,t,["id"])}),n;case ge.Drag:case ge.TouchMove:case ge.MouseMove:return n.data.positions.forEach(r=>{this.replaceIds(r,t,["id"])}),n;case ge.ViewportResize:return!1;case ge.MediaInteraction:case ge.MouseInteraction:case ge.Scroll:case ge.CanvasMutation:case ge.Input:return this.replaceIds(n.data,t,["id"]),n;case ge.StyleSheetRule:case ge.StyleDeclaration:return this.replaceIds(n.data,t,["id"]),this.replaceStyleIds(n.data,t,["styleId"]),n;case ge.Font:return n;case ge.Selection:return n.data.ranges.forEach(r=>{this.replaceIds(r,t,["start","end"])}),n;case ge.AdoptedStyleSheet:return this.replaceIds(n.data,t,["id"]),this.replaceStyleIds(n.data,t,["styleIds"]),$0([n,"access",r=>r.data,"access",r=>r.styles,"optionalAccess",r=>r.forEach,"call",r=>r(i=>{this.replaceStyleIds(i,t,["styleId"])})]),n}}return!1}replace(t,n,r,i){for(const a of i)!Array.isArray(n[a])&&typeof n[a]!="number"||(Array.isArray(n[a])?n[a]=t.getIds(r,n[a]):n[a]=t.getId(r,n[a]));return n}replaceIds(t,n,r){return this.replace(this.crossOriginIframeMirror,t,n,r)}replaceStyleIds(t,n,r){return this.replace(this.crossOriginIframeStyleMirror,t,n,r)}replaceIdOnNode(t,n){this.replaceIds(t,n,["id","rootId"]),"childNodes"in t&&t.childNodes.forEach(r=>{this.replaceIdOnNode(r,n)})}patchRootIdOnNode(t,n){t.type!==ft.Document&&!t.rootId&&(t.rootId=n),"childNodes"in t&&t.childNodes.forEach(r=>{this.patchRootIdOnNode(r,n)})}}class iA{init(){}addShadowRoot(){}observeAttachShadow(){}reset(){}}class aA{constructor(t){this.shadowDoms=new WeakSet,this.restoreHandlers=[],this.mutationCb=t.mutationCb,this.scrollCb=t.scrollCb,this.bypassOptions=t.bypassOptions,this.mirror=t.mirror,this.init()}init(){this.reset(),this.patchAttachShadow(Element,document)}addShadowRoot(t,n){if(!ki(t)||this.shadowDoms.has(t))return;this.shadowDoms.add(t),this.bypassOptions.canvasManager.addShadowRoot(t);const r=M0({...this.bypassOptions,doc:n,mutationCb:this.mutationCb,mirror:this.mirror,shadowDomManager:this},t);this.restoreHandlers.push(()=>r.disconnect()),this.restoreHandlers.push(L0({...this.bypassOptions,scrollCb:this.scrollCb,doc:t,mirror:this.mirror})),Tl(()=>{t.adoptedStyleSheets&&t.adoptedStyleSheets.length>0&&this.bypassOptions.stylesheetManager.adoptStyleSheets(t.adoptedStyleSheets,this.mirror.getId(t.host)),this.restoreHandlers.push(D0({mirror:this.mirror,stylesheetManager:this.bypassOptions.stylesheetManager},t))},0)}observeAttachShadow(t){const n=Xd(t),r=F2(t);!n||!r||this.patchAttachShadow(r.Element,n)}patchAttachShadow(t,n){const r=this;this.restoreHandlers.push(Vd(t.prototype,"attachShadow",function(i){return function(a){const c=i.call(this,a);return this.shadowRoot&&T0(this)&&r.addShadowRoot(this.shadowRoot,n),c}}))}reset(){this.restoreHandlers.forEach(t=>{try{t()}catch{}}),this.restoreHandlers=[],this.shadowDoms=new WeakSet,this.bypassOptions.canvasManager.resetShadowRoots()}}class F0{reset(){}freeze(){}unfreeze(){}lock(){}unlock(){}snapshot(){}addWindow(){}addShadowRoot(){}resetShadowRoots(){}}class lA{constructor(t){this.trackedLinkElements=new WeakSet,this.styleMirror=new M2,this.mutationCb=t.mutationCb,this.adoptedStyleSheetCb=t.adoptedStyleSheetCb}attachLinkElement(t,n){"_cssText"in n.attributes&&this.mutationCb({adds:[],removes:[],texts:[],attributes:[{id:n.id,attributes:n.attributes}]}),this.trackLinkElement(t)}trackLinkElement(t){this.trackedLinkElements.has(t)||(this.trackedLinkElements.add(t),this.trackStylesheetInLinkElement(t))}adoptStyleSheets(t,n){if(t.length===0)return;const r={id:n,styleIds:[]},i=[];for(const a of t){let c;this.styleMirror.has(a)?c=this.styleMirror.getId(a):(c=this.styleMirror.add(a),i.push({styleId:c,rules:Array.from(a.rules||CSSRule,(d,f)=>({rule:r0(d),index:f}))})),r.styleIds.push(c)}i.length>0&&(r.styles=i),this.adoptedStyleSheetCb(r)}reset(){this.styleMirror.reset(),this.trackedLinkElements=new WeakSet}trackStylesheetInLinkElement(t){}}class cA{constructor(){this.nodeMap=new WeakMap,this.active=!1}inOtherBuffer(t,n){const r=this.nodeMap.get(t);return r&&Array.from(r).some(i=>i!==n)}add(t,n){this.active||(this.active=!0,D2(()=>{this.nodeMap=new WeakMap,this.active=!1})),this.nodeMap.set(t,(this.nodeMap.get(t)||new Set).add(n))}destroy(){}}let nt,Rl;try{if(Array.from([1],e=>e*2)[0]!==2){const e=document.createElement("iframe");document.body.appendChild(e),Array.from=il([e,"access",t=>t.contentWindow,"optionalAccess",t=>t.Array,"access",t=>t.from])||Array.from,document.body.removeChild(e)}}catch(e){console.debug("Unable to override Array.from",e)}const Pn=l2();function dr(e={}){const{emit:t,checkoutEveryNms:n,checkoutEveryNth:r,blockClass:i="rr-block",blockSelector:a=null,unblockSelector:c=null,ignoreClass:d="rr-ignore",ignoreSelector:f=null,maskAllText:h=!1,maskTextClass:y="rr-mask",unmaskTextClass:g=null,maskTextSelector:w=null,unmaskTextSelector:x=null,inlineStylesheet:_=!0,maskAllInputs:E,maskInputOptions:k,slimDOMOptions:O,maskAttributeFn:R,maskInputFn:$,maskTextFn:H,maxCanvasSize:z=null,packFn:M,sampling:L={},dataURLOptions:U={},mousemoveWait:te,recordDOM:K=!0,recordCanvas:oe=!1,recordCrossOriginIframes:ae=!1,recordAfter:ye=e.recordAfter==="DOMContentLoaded"?e.recordAfter:"load",userTriggeredOnInput:Ie=!1,collectFonts:We=!1,inlineImages:ce=!1,plugins:ke,keepIframeSrcFn:W=()=>!1,ignoreCSSAttributes:re=new Set([]),errorHandler:J,onMutation:A,getCanvasManager:q}=e;W2(J);const ve=ae?window.parent===window:!0;let we=!1;if(!ve)try{window.parent.document&&(we=!1)}catch{we=!0}if(ve&&!t)throw new Error("emit function is required");if(!ve&&!we)return()=>{};te!==void 0&&L.mousemove===void 0&&(L.mousemove=te),Pn.reset();const Oe=E===!0?{color:!0,date:!0,"datetime-local":!0,email:!0,month:!0,number:!0,range:!0,search:!0,tel:!0,text:!0,time:!0,url:!0,week:!0,textarea:!0,select:!0,radio:!0,checkbox:!0}:k!==void 0?k:{},Pe=O===!0||O==="all"?{script:!0,comment:!0,headFavicon:!0,headWhitespace:!0,headMetaSocial:!0,headMetaRobots:!0,headMetaHttpEquiv:!0,headMetaVerification:!0,headMetaAuthorship:O==="all",headMetaDescKeywords:O==="all"}:O||{};N2();let ze,De=0;const qe=Re=>{for(const _t of ke||[])_t.eventProcessor&&(Re=_t.eventProcessor(Re));return M&&!we&&(Re=M(Re)),Re};nt=(Re,_t)=>{const Ce=Re;if(Ce.timestamp=kl(),il([ko,"access",Ke=>Ke[0],"optionalAccess",Ke=>Ke.isFrozen,"call",Ke=>Ke()])&&Ce.type!==Te.FullSnapshot&&!(Ce.type===Te.IncrementalSnapshot&&Ce.data.source===ge.Mutation)&&ko.forEach(Ke=>Ke.unfreeze()),ve)il([t,"optionalCall",Ke=>Ke(qe(Ce),_t)]);else if(we){const Ke={type:"rrweb",event:qe(Ce),origin:window.location.origin,isCheckout:_t};window.parent.postMessage(Ke,"*")}if(Ce.type===Te.FullSnapshot)ze=Ce,De=0;else if(Ce.type===Te.IncrementalSnapshot){if(Ce.data.source===ge.Mutation&&Ce.data.isAttachIframe)return;De++;const Ke=r&&De>=r,je=n&&ze&&Ce.timestamp-ze.timestamp>n;(Ke||je)&&Ds(!0)}};const wt=Re=>{nt({type:Te.IncrementalSnapshot,data:{source:ge.Mutation,...Re}})},Ms=Re=>nt({type:Te.IncrementalSnapshot,data:{source:ge.Scroll,...Re}}),fc=Re=>nt({type:Te.IncrementalSnapshot,data:{source:ge.CanvasMutation,...Re}}),No=Re=>nt({type:Te.IncrementalSnapshot,data:{source:ge.AdoptedStyleSheet,...Re}}),Mn=new lA({mutationCb:wt,adoptedStyleSheetCb:No}),Kn=typeof __RRWEB_EXCLUDE_IFRAME__=="boolean"&&__RRWEB_EXCLUDE_IFRAME__?new sA:new oA({mirror:Pn,mutationCb:wt,stylesheetManager:Mn,recordCrossOriginIframes:ae,wrappedEmit:nt});for(const Re of ke||[])Re.getMirror&&Re.getMirror({nodeMirror:Pn,crossOriginIframeMirror:Kn.crossOriginIframeMirror,crossOriginIframeStyleMirror:Kn.crossOriginIframeStyleMirror});const Mo=new cA,Ls=dA(q,{mirror:Pn,win:window,mutationCb:Re=>nt({type:Te.IncrementalSnapshot,data:{source:ge.CanvasMutation,...Re}}),recordCanvas:oe,blockClass:i,blockSelector:a,unblockSelector:c,maxCanvasSize:z,sampling:L.canvas,dataURLOptions:U,errorHandler:J}),js=typeof __RRWEB_EXCLUDE_SHADOW_DOM__=="boolean"&&__RRWEB_EXCLUDE_SHADOW_DOM__?new iA:new aA({mutationCb:wt,scrollCb:Ms,bypassOptions:{onMutation:A,blockClass:i,blockSelector:a,unblockSelector:c,maskAllText:h,maskTextClass:y,unmaskTextClass:g,maskTextSelector:w,unmaskTextSelector:x,inlineStylesheet:_,maskInputOptions:Oe,dataURLOptions:U,maskAttributeFn:R,maskTextFn:H,maskInputFn:$,recordCanvas:oe,inlineImages:ce,sampling:L,slimDOMOptions:Pe,iframeManager:Kn,stylesheetManager:Mn,canvasManager:Ls,keepIframeSrcFn:W,processedNodeManager:Mo},mirror:Pn}),Ds=(Re=!1)=>{if(!K)return;nt({type:Te.Meta,data:{href:window.location.href,width:S0(),height:v0()}},Re),Mn.reset(),js.init(),ko.forEach(Ce=>Ce.lock());const _t=O2(document,{mirror:Pn,blockClass:i,blockSelector:a,unblockSelector:c,maskAllText:h,maskTextClass:y,unmaskTextClass:g,maskTextSelector:w,unmaskTextSelector:x,inlineStylesheet:_,maskAllInputs:Oe,maskAttributeFn:R,maskInputFn:$,maskTextFn:H,slimDOM:Pe,dataURLOptions:U,recordCanvas:oe,inlineImages:ce,onSerialize:Ce=>{E0(Ce,Pn)&&Kn.addIframe(Ce),x0(Ce,Pn)&&Mn.trackLinkElement(Ce),Kd(Ce)&&js.addShadowRoot(Ce.shadowRoot,document)},onIframeLoad:(Ce,Ke)=>{Kn.attachIframe(Ce,Ke),Ce.contentWindow&&Ls.addWindow(Ce.contentWindow),js.observeAttachShadow(Ce)},onStylesheetLoad:(Ce,Ke)=>{Mn.attachLinkElement(Ce,Ke)},keepIframeSrcFn:W});if(!_t)return console.warn("Failed to snapshot the document");nt({type:Te.FullSnapshot,data:{node:_t,initialOffset:y0(window)}}),ko.forEach(Ce=>Ce.unlock()),document.adoptedStyleSheets&&document.adoptedStyleSheets.length>0&&Mn.adoptStyleSheets(document.adoptedStyleSheets,Pn.getId(document))};Rl=Ds;try{const Re=[],_t=Ke=>Le(rA)({onMutation:A,mutationCb:wt,mousemoveCb:(je,Qn)=>nt({type:Te.IncrementalSnapshot,data:{source:Qn,positions:je}}),mouseInteractionCb:je=>nt({type:Te.IncrementalSnapshot,data:{source:ge.MouseInteraction,...je}}),scrollCb:Ms,viewportResizeCb:je=>nt({type:Te.IncrementalSnapshot,data:{source:ge.ViewportResize,...je}}),inputCb:je=>nt({type:Te.IncrementalSnapshot,data:{source:ge.Input,...je}}),mediaInteractionCb:je=>nt({type:Te.IncrementalSnapshot,data:{source:ge.MediaInteraction,...je}}),styleSheetRuleCb:je=>nt({type:Te.IncrementalSnapshot,data:{source:ge.StyleSheetRule,...je}}),styleDeclarationCb:je=>nt({type:Te.IncrementalSnapshot,data:{source:ge.StyleDeclaration,...je}}),canvasMutationCb:fc,fontCb:je=>nt({type:Te.IncrementalSnapshot,data:{source:ge.Font,...je}}),selectionCb:je=>{nt({type:Te.IncrementalSnapshot,data:{source:ge.Selection,...je}})},customElementCb:je=>{nt({type:Te.IncrementalSnapshot,data:{source:ge.CustomElement,...je}})},blockClass:i,ignoreClass:d,ignoreSelector:f,maskAllText:h,maskTextClass:y,unmaskTextClass:g,maskTextSelector:w,unmaskTextSelector:x,maskInputOptions:Oe,inlineStylesheet:_,sampling:L,recordDOM:K,recordCanvas:oe,inlineImages:ce,userTriggeredOnInput:Ie,collectFonts:We,doc:Ke,maskAttributeFn:R,maskInputFn:$,maskTextFn:H,keepIframeSrcFn:W,blockSelector:a,unblockSelector:c,slimDOMOptions:Pe,dataURLOptions:U,mirror:Pn,iframeManager:Kn,stylesheetManager:Mn,shadowDomManager:js,processedNodeManager:Mo,canvasManager:Ls,ignoreCSSAttributes:re,plugins:il([ke,"optionalAccess",je=>je.filter,"call",je=>je(Qn=>Qn.observer),"optionalAccess",je=>je.map,"call",je=>je(Qn=>({observer:Qn.observer,options:Qn.options,callback:pc=>nt({type:Te.Plugin,data:{plugin:Qn.name,payload:pc}})}))])||[]},{});Kn.addLoadListener(Ke=>{try{Re.push(_t(Ke.contentDocument))}catch(je){console.warn(je)}});const Ce=()=>{Ds(),Re.push(_t(document))};return document.readyState==="interactive"||document.readyState==="complete"?Ce():(Re.push(Ut("DOMContentLoaded",()=>{nt({type:Te.DomContentLoaded,data:{}}),ye==="DOMContentLoaded"&&Ce()})),Re.push(Ut("load",()=>{nt({type:Te.Load,data:{}}),ye==="load"&&Ce()},window))),()=>{Re.forEach(Ke=>Ke()),Mo.destroy(),Rl=void 0,q2()}}catch(Re){console.warn(Re)}}function uA(e){if(!Rl)throw new Error("please take full snapshot after start recording");Rl(e)}dr.mirror=Pn,dr.takeFullSnapshot=uA;function dA(e,t){try{return e?e(t):new F0}catch{return console.warn("Unable to initialize CanvasManager"),new F0}}const fA=3,pA=5;function ef(e){return e>9999999999?e:e*1e3}function tf(e){return e>9999999999?e/1e3:e}function Ai(e,t){t.category!=="sentry.transaction"&&(["ui.click","ui.input"].includes(t.category)?e.triggerUserActivity():e.checkAndHandleExpiredSession(),e.addUpdate(()=>(e.throttledAddEvent({type:Te.Custom,timestamp:(t.timestamp||0)*1e3,data:{tag:"breadcrumb",payload:Rn(t,10,1e3)}}),t.category==="console")))}const hA="button,a";function B0(e){return e.closest(hA)||e}function z0(e){const t=U0(e);return!t||!(t instanceof Element)?t:B0(t)}function U0(e){return mA(e)?e.target:e}function mA(e){return typeof e=="object"&&!!e&&"target"in e}let Dr;function gA(e){return Dr||(Dr=[],yA()),Dr.push(e),()=>{const t=Dr?Dr.indexOf(e):-1;t>-1&&Dr.splice(t,1)}}function yA(){Yt(Ge,"open",function(e){return function(...t){if(Dr)try{Dr.forEach(n=>n())}catch{}return e.apply(Ge,t)}})}const vA=new Set([ge.Mutation,ge.StyleSheetRule,ge.StyleDeclaration,ge.AdoptedStyleSheet,ge.CanvasMutation,ge.Selection,ge.MediaInteraction]);function SA(e,t,n){e.handleClick(t,n)}class wA{constructor(t,n,r=Ai){this._lastMutation=0,this._lastScroll=0,this._clicks=[],this._timeout=n.timeout/1e3,this._threshold=n.threshold/1e3,this._scrollTimeout=n.scrollTimeout/1e3,this._replay=t,this._ignoreSelector=n.ignoreSelector,this._addBreadcrumbEvent=r}addListeners(){const t=gA(()=>{this._lastMutation=H0()});this._teardown=()=>{t(),this._clicks=[],this._lastMutation=0,this._lastScroll=0}}removeListeners(){this._teardown&&this._teardown(),this._checkClickTimeout&&clearTimeout(this._checkClickTimeout)}handleClick(t,n){if(EA(n,this._ignoreSelector)||!xA(t))return;const r={timestamp:tf(t.timestamp),clickBreadcrumb:t,clickCount:0,node:n};this._clicks.some(i=>i.node===r.node&&Math.abs(i.timestamp-r.timestamp)<1)||(this._clicks.push(r),this._clicks.length===1&&this._scheduleCheckClicks())}registerMutation(t=Date.now()){this._lastMutation=tf(t)}registerScroll(t=Date.now()){this._lastScroll=tf(t)}registerClick(t){const n=B0(t);this._handleMultiClick(n)}_handleMultiClick(t){this._getClicks(t).forEach(n=>{n.clickCount++})}_getClicks(t){return this._clicks.filter(n=>n.node===t)}_checkClicks(){const t=[],n=H0();this._clicks.forEach(r=>{!r.mutationAfter&&this._lastMutation&&(r.mutationAfter=r.timestamp<=this._lastMutation?this._lastMutation-r.timestamp:void 0),!r.scrollAfter&&this._lastScroll&&(r.scrollAfter=r.timestamp<=this._lastScroll?this._lastScroll-r.timestamp:void 0),r.timestamp+this._timeout<=n&&t.push(r)});for(const r of t){const i=this._clicks.indexOf(r);i>-1&&(this._generateBreadcrumbs(r),this._clicks.splice(i,1))}this._clicks.length&&this._scheduleCheckClicks()}_generateBreadcrumbs(t){const n=this._replay,r=t.scrollAfter&&t.scrollAfter<=this._scrollTimeout,i=t.mutationAfter&&t.mutationAfter<=this._threshold,a=!r&&!i,{clickCount:c,clickBreadcrumb:d}=t;if(a){const f=Math.min(t.mutationAfter||this._timeout,this._timeout)*1e3,h=f<this._timeout*1e3?"mutation":"timeout",y={type:"default",message:d.message,timestamp:d.timestamp,category:"ui.slowClickDetected",data:{...d.data,url:Ge.location.href,route:n.getCurrentRoute(),timeAfterClickMs:f,endReason:h,clickCount:c||1}};this._addBreadcrumbEvent(n,y);return}if(c>1){const f={type:"default",message:d.message,timestamp:d.timestamp,category:"ui.multiClick",data:{...d.data,url:Ge.location.href,route:n.getCurrentRoute(),clickCount:c,metric:!0}};this._addBreadcrumbEvent(n,f)}}_scheduleCheckClicks(){this._checkClickTimeout&&clearTimeout(this._checkClickTimeout),this._checkClickTimeout=go(()=>this._checkClicks(),1e3)}}const _A=["A","BUTTON","INPUT"];function EA(e,t){return!!(!_A.includes(e.tagName)||e.tagName==="INPUT"&&!["submit","button"].includes(e.getAttribute("type")||"")||e.tagName==="A"&&(e.hasAttribute("download")||e.hasAttribute("target")&&e.getAttribute("target")!=="_self")||t&&e.matches(t))}function xA(e){return!!(e.data&&typeof e.data.nodeId=="number"&&e.timestamp)}function H0(){return Date.now()/1e3}function kA(e,t){try{if(!TA(t))return;const{source:n}=t.data;if(vA.has(n)&&e.registerMutation(t.timestamp),n===ge.Scroll&&e.registerScroll(t.timestamp),bA(t)){const{type:r,id:i}=t.data,a=dr.mirror.getNode(i);a instanceof HTMLElement&&r===Ht.Click&&e.registerClick(a)}}catch{}}function TA(e){return e.type===fA}function bA(e){return e.data.source===ge.MouseInteraction}function Vn(e){return{timestamp:Date.now()/1e3,type:"default",...e}}var Al;(function(e){e[e.Document=0]="Document",e[e.DocumentType=1]="DocumentType",e[e.Element=2]="Element",e[e.Text=3]="Text",e[e.CDATA=4]="CDATA",e[e.Comment=5]="Comment"})(Al||(Al={}));const IA=new Set(["id","class","aria-label","role","name","alt","title","data-test-id","data-testid","disabled","aria-disabled","data-sentry-component"]);function CA(e){const t={};!e["data-sentry-component"]&&e["data-sentry-element"]&&(e["data-sentry-component"]=e["data-sentry-element"]);for(const n in e)if(IA.has(n)){let r=n;(n==="data-testid"||n==="data-test-id")&&(r="testId"),t[r]=e[n]}return t}const RA=e=>t=>{if(!e.isEnabled())return;const n=AA(t);if(!n)return;const r=t.name==="click",i=r?t.event:void 0;r&&e.clickDetector&&i&&i.target&&!i.altKey&&!i.metaKey&&!i.ctrlKey&&!i.shiftKey&&SA(e.clickDetector,n,z0(t.event)),Ai(e,n)};function W0(e,t){const n=dr.mirror.getId(e),r=n&&dr.mirror.getNode(n),i=r&&dr.mirror.getMeta(r),a=i&&PA(i)?i:null;return{message:t,data:a?{nodeId:n,node:{id:n,tagName:a.tagName,textContent:Array.from(a.childNodes).map(c=>c.type===Al.Text&&c.textContent).filter(Boolean).map(c=>c.trim()).join(""),attributes:CA(a.attributes)}}:{}}}function AA(e){const{target:t,message:n}=OA(e);return Vn({category:`ui.${e.name}`,...W0(t,n)})}function OA(e){const t=e.name==="click";let n,r=null;try{r=t?z0(e.event):U0(e.event),n=or(r,{maxStringLength:200})||"<unknown>"}catch{n="<unknown>"}return{target:r,message:n}}function PA(e){return e.type===Al.Element}function NA(e,t){if(!e.isEnabled())return;e.updateUserActivity();const n=MA(t);n&&Ai(e,n)}function MA(e){const{metaKey:t,shiftKey:n,ctrlKey:r,altKey:i,key:a,target:c}=e;if(!c||LA(c)||!a)return null;const d=t||r||i,f=a.length===1;if(!d&&f)return null;const h=or(c,{maxStringLength:200})||"<unknown>",y=W0(c,h);return Vn({category:"ui.keyDown",message:h,data:{...y.data,metaKey:t,shiftKey:n,ctrlKey:r,altKey:i,key:a}})}function LA(e){return e.tagName==="INPUT"||e.tagName==="TEXTAREA"||e.isContentEditable}const jA={resource:zA,paint:FA,navigation:BA};function Ol(e,t){return({metric:n})=>void t.replayPerformanceEntries.push(e(n))}function DA(e){return e.map($A).filter(Boolean)}function $A(e){const t=jA[e.entryType];return t?t(e):null}function To(e){return((zt||Ge.performance.timeOrigin)+e)/1e3}function FA(e){const{duration:t,entryType:n,name:r,startTime:i}=e,a=To(i);return{type:n,name:r,start:a,end:a+t,data:void 0}}function BA(e){const{entryType:t,name:n,decodedBodySize:r,duration:i,domComplete:a,encodedBodySize:c,domContentLoadedEventStart:d,domContentLoadedEventEnd:f,domInteractive:h,loadEventStart:y,loadEventEnd:g,redirectCount:w,startTime:x,transferSize:_,type:E}=e;return i===0?null:{type:`${t}.${E}`,start:To(x),end:To(a),name:n,data:{size:_,decodedBodySize:r,encodedBodySize:c,duration:i,domInteractive:h,domContentLoadedEventStart:d,domContentLoadedEventEnd:f,loadEventStart:y,loadEventEnd:g,domComplete:a,redirectCount:w}}}function zA(e){const{entryType:t,initiatorType:n,name:r,responseEnd:i,startTime:a,decodedBodySize:c,encodedBodySize:d,responseStatus:f,transferSize:h}=e;return["fetch","xmlhttprequest"].includes(n)?null:{type:`${t}.${n}`,start:To(a),end:To(i),name:r,data:{size:h,statusCode:f,decodedBodySize:c,encodedBodySize:d}}}function UA(e){const t=e.entries[e.entries.length-1],n=t&&t.element?[t.element]:void 0;return Pl(e,"largest-contentful-paint",n)}function HA(e){return e.sources!==void 0}function WA(e){const t=[],n=[];for(const r of e.entries)if(HA(r)){const i=[];for(const a of r.sources)if(a.node){n.push(a.node);const c=dr.mirror.getId(a.node);c&&i.push(c)}t.push({value:r.value,nodeIds:i.length?i:void 0})}return Pl(e,"cumulative-layout-shift",n,t)}function qA(e){const t=e.entries[e.entries.length-1],n=t&&t.target?[t.target]:void 0;return Pl(e,"first-input-delay",n)}function VA(e){const t=e.entries[e.entries.length-1],n=t&&t.target?[t.target]:void 0;return Pl(e,"interaction-to-next-paint",n)}function Pl(e,t,n,r){const i=e.value,a=e.rating,c=To(i);return{type:"web-vital",name:t,start:c,end:c,data:{value:i,size:i,rating:a,nodeIds:n?n.map(d=>dr.mirror.getId(d)):void 0,attributions:r}}}function GA(e){function t(i){e.performanceEntries.includes(i)||e.performanceEntries.push(i)}function n({entries:i}){i.forEach(t)}const r=[];return["navigation","paint","resource"].forEach(i=>{r.push(ho(i,n))}),r.push(Dy(Ol(UA,e)),Ad(Ol(WA,e)),$y(Ol(qA,e)),Fy(Ol(VA,e))),()=>{r.forEach(i=>i())}}const pe=typeof __SENTRY_DEBUG__>"u"||__SENTRY_DEBUG__,YA='var t=Uint8Array,n=Uint16Array,r=Int32Array,e=new t([0,0,0,0,0,0,0,0,1,1,1,1,2,2,2,2,3,3,3,3,4,4,4,4,5,5,5,5,0,0,0,0]),i=new t([0,0,0,0,1,1,2,2,3,3,4,4,5,5,6,6,7,7,8,8,9,9,10,10,11,11,12,12,13,13,0,0]),a=new t([16,17,18,0,8,7,9,6,10,5,11,4,12,3,13,2,14,1,15]),s=function(t,e){for(var i=new n(31),a=0;a<31;++a)i[a]=e+=1<<t[a-1];var s=new r(i[30]);for(a=1;a<30;++a)for(var o=i[a];o<i[a+1];++o)s[o]=o-i[a]<<5|a;return{b:i,r:s}},o=s(e,2),f=o.b,h=o.r;f[28]=258,h[258]=28;for(var l=s(i,0).r,u=new n(32768),c=0;c<32768;++c){var v=(43690&c)>>1|(21845&c)<<1;v=(61680&(v=(52428&v)>>2|(13107&v)<<2))>>4|(3855&v)<<4,u[c]=((65280&v)>>8|(255&v)<<8)>>1}var d=function(t,r,e){for(var i=t.length,a=0,s=new n(r);a<i;++a)t[a]&&++s[t[a]-1];var o,f=new n(r);for(a=1;a<r;++a)f[a]=f[a-1]+s[a-1]<<1;if(e){o=new n(1<<r);var h=15-r;for(a=0;a<i;++a)if(t[a])for(var l=a<<4|t[a],c=r-t[a],v=f[t[a]-1]++<<c,d=v|(1<<c)-1;v<=d;++v)o[u[v]>>h]=l}else for(o=new n(i),a=0;a<i;++a)t[a]&&(o[a]=u[f[t[a]-1]++]>>15-t[a]);return o},g=new t(288);for(c=0;c<144;++c)g[c]=8;for(c=144;c<256;++c)g[c]=9;for(c=256;c<280;++c)g[c]=7;for(c=280;c<288;++c)g[c]=8;var w=new t(32);for(c=0;c<32;++c)w[c]=5;var p=d(g,9,0),y=d(w,5,0),m=function(t){return(t+7)/8|0},b=function(n,r,e){return(null==e||e>n.length)&&(e=n.length),new t(n.subarray(r,e))},M=["unexpected EOF","invalid block type","invalid length/literal","invalid distance","stream finished","no stream handler",,"no callback","invalid UTF-8 data","extra field too long","date not in range 1980-2099","filename too long","stream finishing","invalid zip data"],E=function(t,n,r){var e=new Error(n||M[t]);if(e.code=t,Error.captureStackTrace&&Error.captureStackTrace(e,E),!r)throw e;return e},z=function(t,n,r){r<<=7&n;var e=n/8|0;t[e]|=r,t[e+1]|=r>>8},_=function(t,n,r){r<<=7&n;var e=n/8|0;t[e]|=r,t[e+1]|=r>>8,t[e+2]|=r>>16},x=function(r,e){for(var i=[],a=0;a<r.length;++a)r[a]&&i.push({s:a,f:r[a]});var s=i.length,o=i.slice();if(!s)return{t:F,l:0};if(1==s){var f=new t(i[0].s+1);return f[i[0].s]=1,{t:f,l:1}}i.sort((function(t,n){return t.f-n.f})),i.push({s:-1,f:25001});var h=i[0],l=i[1],u=0,c=1,v=2;for(i[0]={s:-1,f:h.f+l.f,l:h,r:l};c!=s-1;)h=i[i[u].f<i[v].f?u++:v++],l=i[u!=c&&i[u].f<i[v].f?u++:v++],i[c++]={s:-1,f:h.f+l.f,l:h,r:l};var d=o[0].s;for(a=1;a<s;++a)o[a].s>d&&(d=o[a].s);var g=new n(d+1),w=A(i[c-1],g,0);if(w>e){a=0;var p=0,y=w-e,m=1<<y;for(o.sort((function(t,n){return g[n.s]-g[t.s]||t.f-n.f}));a<s;++a){var b=o[a].s;if(!(g[b]>e))break;p+=m-(1<<w-g[b]),g[b]=e}for(p>>=y;p>0;){var M=o[a].s;g[M]<e?p-=1<<e-g[M]++-1:++a}for(;a>=0&&p;--a){var E=o[a].s;g[E]==e&&(--g[E],++p)}w=e}return{t:new t(g),l:w}},A=function(t,n,r){return-1==t.s?Math.max(A(t.l,n,r+1),A(t.r,n,r+1)):n[t.s]=r},D=function(t){for(var r=t.length;r&&!t[--r];);for(var e=new n(++r),i=0,a=t[0],s=1,o=function(t){e[i++]=t},f=1;f<=r;++f)if(t[f]==a&&f!=r)++s;else{if(!a&&s>2){for(;s>138;s-=138)o(32754);s>2&&(o(s>10?s-11<<5|28690:s-3<<5|12305),s=0)}else if(s>3){for(o(a),--s;s>6;s-=6)o(8304);s>2&&(o(s-3<<5|8208),s=0)}for(;s--;)o(a);s=1,a=t[f]}return{c:e.subarray(0,i),n:r}},T=function(t,n){for(var r=0,e=0;e<n.length;++e)r+=t[e]*n[e];return r},k=function(t,n,r){var e=r.length,i=m(n+2);t[i]=255&e,t[i+1]=e>>8,t[i+2]=255^t[i],t[i+3]=255^t[i+1];for(var a=0;a<e;++a)t[i+a+4]=r[a];return 8*(i+4+e)},U=function(t,r,s,o,f,h,l,u,c,v,m){z(r,m++,s),++f[256];for(var b=x(f,15),M=b.t,E=b.l,A=x(h,15),U=A.t,C=A.l,F=D(M),I=F.c,S=F.n,L=D(U),O=L.c,j=L.n,q=new n(19),B=0;B<I.length;++B)++q[31&I[B]];for(B=0;B<O.length;++B)++q[31&O[B]];for(var G=x(q,7),H=G.t,J=G.l,K=19;K>4&&!H[a[K-1]];--K);var N,P,Q,R,V=v+5<<3,W=T(f,g)+T(h,w)+l,X=T(f,M)+T(h,U)+l+14+3*K+T(q,H)+2*q[16]+3*q[17]+7*q[18];if(c>=0&&V<=W&&V<=X)return k(r,m,t.subarray(c,c+v));if(z(r,m,1+(X<W)),m+=2,X<W){N=d(M,E,0),P=M,Q=d(U,C,0),R=U;var Y=d(H,J,0);z(r,m,S-257),z(r,m+5,j-1),z(r,m+10,K-4),m+=14;for(B=0;B<K;++B)z(r,m+3*B,H[a[B]]);m+=3*K;for(var Z=[I,O],$=0;$<2;++$){var tt=Z[$];for(B=0;B<tt.length;++B){var nt=31&tt[B];z(r,m,Y[nt]),m+=H[nt],nt>15&&(z(r,m,tt[B]>>5&127),m+=tt[B]>>12)}}}else N=p,P=g,Q=y,R=w;for(B=0;B<u;++B){var rt=o[B];if(rt>255){_(r,m,N[(nt=rt>>18&31)+257]),m+=P[nt+257],nt>7&&(z(r,m,rt>>23&31),m+=e[nt]);var et=31&rt;_(r,m,Q[et]),m+=R[et],et>3&&(_(r,m,rt>>5&8191),m+=i[et])}else _(r,m,N[rt]),m+=P[rt]}return _(r,m,N[256]),m+P[256]},C=new r([65540,131080,131088,131104,262176,1048704,1048832,2114560,2117632]),F=new t(0),I=function(){for(var t=new Int32Array(256),n=0;n<256;++n){for(var r=n,e=9;--e;)r=(1&r&&-306674912)^r>>>1;t[n]=r}return t}(),S=function(){var t=-1;return{p:function(n){for(var r=t,e=0;e<n.length;++e)r=I[255&r^n[e]]^r>>>8;t=r},d:function(){return~t}}},L=function(){var t=1,n=0;return{p:function(r){for(var e=t,i=n,a=0|r.length,s=0;s!=a;){for(var o=Math.min(s+2655,a);s<o;++s)i+=e+=r[s];e=(65535&e)+15*(e>>16),i=(65535&i)+15*(i>>16)}t=e,n=i},d:function(){return(255&(t%=65521))<<24|(65280&t)<<8|(255&(n%=65521))<<8|n>>8}}},O=function(a,s,o,f,u){if(!u&&(u={l:1},s.dictionary)){var c=s.dictionary.subarray(-32768),v=new t(c.length+a.length);v.set(c),v.set(a,c.length),a=v,u.w=c.length}return function(a,s,o,f,u,c){var v=c.z||a.length,d=new t(f+v+5*(1+Math.ceil(v/7e3))+u),g=d.subarray(f,d.length-u),w=c.l,p=7&(c.r||0);if(s){p&&(g[0]=c.r>>3);for(var y=C[s-1],M=y>>13,E=8191&y,z=(1<<o)-1,_=c.p||new n(32768),x=c.h||new n(z+1),A=Math.ceil(o/3),D=2*A,T=function(t){return(a[t]^a[t+1]<<A^a[t+2]<<D)&z},F=new r(25e3),I=new n(288),S=new n(32),L=0,O=0,j=c.i||0,q=0,B=c.w||0,G=0;j+2<v;++j){var H=T(j),J=32767&j,K=x[H];if(_[J]=K,x[H]=J,B<=j){var N=v-j;if((L>7e3||q>24576)&&(N>423||!w)){p=U(a,g,0,F,I,S,O,q,G,j-G,p),q=L=O=0,G=j;for(var P=0;P<286;++P)I[P]=0;for(P=0;P<30;++P)S[P]=0}var Q=2,R=0,V=E,W=J-K&32767;if(N>2&&H==T(j-W))for(var X=Math.min(M,N)-1,Y=Math.min(32767,j),Z=Math.min(258,N);W<=Y&&--V&&J!=K;){if(a[j+Q]==a[j+Q-W]){for(var $=0;$<Z&&a[j+$]==a[j+$-W];++$);if($>Q){if(Q=$,R=W,$>X)break;var tt=Math.min(W,$-2),nt=0;for(P=0;P<tt;++P){var rt=j-W+P&32767,et=rt-_[rt]&32767;et>nt&&(nt=et,K=rt)}}}W+=(J=K)-(K=_[J])&32767}if(R){F[q++]=268435456|h[Q]<<18|l[R];var it=31&h[Q],at=31&l[R];O+=e[it]+i[at],++I[257+it],++S[at],B=j+Q,++L}else F[q++]=a[j],++I[a[j]]}}for(j=Math.max(j,B);j<v;++j)F[q++]=a[j],++I[a[j]];p=U(a,g,w,F,I,S,O,q,G,j-G,p),w||(c.r=7&p|g[p/8|0]<<3,p-=7,c.h=x,c.p=_,c.i=j,c.w=B)}else{for(j=c.w||0;j<v+w;j+=65535){var st=j+65535;st>=v&&(g[p/8|0]=w,st=v),p=k(g,p+1,a.subarray(j,st))}c.i=v}return b(d,0,f+m(p)+u)}(a,null==s.level?6:s.level,null==s.mem?Math.ceil(1.5*Math.max(8,Math.min(13,Math.log(a.length)))):12+s.mem,o,f,u)},j=function(t,n,r){for(;r;++n)t[n]=r,r>>>=8},q=function(t,n){var r=n.filename;if(t[0]=31,t[1]=139,t[2]=8,t[8]=n.level<2?4:9==n.level?2:0,t[9]=3,0!=n.mtime&&j(t,4,Math.floor(new Date(n.mtime||Date.now())/1e3)),r){t[3]=8;for(var e=0;e<=r.length;++e)t[e+10]=r.charCodeAt(e)}},B=function(t){return 10+(t.filename?t.filename.length+1:0)},G=function(){function n(n,r){if("function"==typeof n&&(r=n,n={}),this.ondata=r,this.o=n||{},this.s={l:0,i:32768,w:32768,z:32768},this.b=new t(98304),this.o.dictionary){var e=this.o.dictionary.subarray(-32768);this.b.set(e,32768-e.length),this.s.i=32768-e.length}}return n.prototype.p=function(t,n){this.ondata(O(t,this.o,0,0,this.s),n)},n.prototype.push=function(n,r){this.ondata||E(5),this.s.l&&E(4);var e=n.length+this.s.z;if(e>this.b.length){if(e>2*this.b.length-32768){var i=new t(-32768&e);i.set(this.b.subarray(0,this.s.z)),this.b=i}var a=this.b.length-this.s.z;a&&(this.b.set(n.subarray(0,a),this.s.z),this.s.z=this.b.length,this.p(this.b,!1)),this.b.set(this.b.subarray(-32768)),this.b.set(n.subarray(a),32768),this.s.z=n.length-a+32768,this.s.i=32766,this.s.w=32768}else this.b.set(n,this.s.z),this.s.z+=n.length;this.s.l=1&r,(this.s.z>this.s.w+8191||r)&&(this.p(this.b,r||!1),this.s.w=this.s.i,this.s.i-=2)},n}();var H=function(){function t(t,n){this.c=L(),this.v=1,G.call(this,t,n)}return t.prototype.push=function(t,n){this.c.p(t),G.prototype.push.call(this,t,n)},t.prototype.p=function(t,n){var r=O(t,this.o,this.v&&(this.o.dictionary?6:2),n&&4,this.s);this.v&&(function(t,n){var r=n.level,e=0==r?0:r<6?1:9==r?3:2;if(t[0]=120,t[1]=e<<6|(n.dictionary&&32),t[1]|=31-(t[0]<<8|t[1])%31,n.dictionary){var i=L();i.p(n.dictionary),j(t,2,i.d())}}(r,this.o),this.v=0),n&&j(r,r.length-4,this.c.d()),this.ondata(r,n)},t}(),J="undefined"!=typeof TextEncoder&&new TextEncoder,K="undefined"!=typeof TextDecoder&&new TextDecoder;try{K.decode(F,{stream:!0})}catch(t){}var N=function(){function t(t){this.ondata=t}return t.prototype.push=function(t,n){this.ondata||E(5),this.d&&E(4),this.ondata(P(t),this.d=n||!1)},t}();function P(n,r){if(J)return J.encode(n);for(var e=n.length,i=new t(n.length+(n.length>>1)),a=0,s=function(t){i[a++]=t},o=0;o<e;++o){if(a+5>i.length){var f=new t(a+8+(e-o<<1));f.set(i),i=f}var h=n.charCodeAt(o);h<128||r?s(h):h<2048?(s(192|h>>6),s(128|63&h)):h>55295&&h<57344?(s(240|(h=65536+(1047552&h)|1023&n.charCodeAt(++o))>>18),s(128|h>>12&63),s(128|h>>6&63),s(128|63&h)):(s(224|h>>12),s(128|h>>6&63),s(128|63&h))}return b(i,0,a)}function Q(t){return function(t,n){n||(n={});var r=S(),e=t.length;r.p(t);var i=O(t,n,B(n),8),a=i.length;return q(i,n),j(i,a-8,r.d()),j(i,a-4,e),i}(P(t))}const R=new class{constructor(){this._init()}clear(){this._init()}addEvent(t){if(!t)throw new Error("Adding invalid event");const n=this._hasEvents?",":"";this.stream.push(n+t),this._hasEvents=!0}finish(){this.stream.push("]",!0);const t=function(t){let n=0;for(const r of t)n+=r.length;const r=new Uint8Array(n);for(let n=0,e=0,i=t.length;n<i;n++){const i=t[n];r.set(i,e),e+=i.length}return r}(this._deflatedData);return this._init(),t}_init(){this._hasEvents=!1,this._deflatedData=[],this.deflate=new H,this.deflate.ondata=(t,n)=>{this._deflatedData.push(t)},this.stream=new N(((t,n)=>{this.deflate.push(t,n)})),this.stream.push("[")}},V={clear:()=>{R.clear()},addEvent:t=>R.addEvent(t),finish:()=>R.finish(),compress:t=>Q(t)};addEventListener("message",(function(t){const n=t.data.method,r=t.data.id,e=t.data.arg;if(n in V&&"function"==typeof V[n])try{const t=V[n](e);postMessage({id:r,method:n,success:!0,response:t})}catch(t){postMessage({id:r,method:n,success:!1,response:t.message}),console.error(t)}})),postMessage({id:void 0,method:"init",success:!0,response:void 0});';function KA(){const e=new Blob([YA]);return URL.createObjectURL(e)}const q0=["info","warn","error","log"],Nl="[Replay] ";function nf(e,t="info"){Mr({category:"console",data:{logger:"replay"},level:t,message:`${Nl}${e}`},{level:t})}function QA(){let e=!1,t=!1;const n={exception:()=>{},infoTick:()=>{},setConfig:r=>{e=r.captureExceptions,t=r.traceInternals}};return pe?(q0.forEach(r=>{n[r]=(...i)=>{X[r](Nl,...i),t&&nf(i.join(""),yy(r))}}),n.exception=(r,...i)=>{i.length&&n.error&&n.error(...i),X.error(Nl,r),e?An(r):t&&nf(r,"error")},n.infoTick=(...r)=>{X.info(Nl,...r),t&&setTimeout(()=>nf(r[0]),0)}):q0.forEach(r=>{n[r]=()=>{}}),n}const he=QA();class rf extends Error{constructor(){super(`Event buffer exceeded maximum size of ${Bd}.`)}}class V0{constructor(){this.events=[],this._totalSize=0,this.hasCheckout=!1,this.waitForCheckout=!1}get hasEvents(){return this.events.length>0}get type(){return"sync"}destroy(){this.events=[]}async addEvent(t){const n=JSON.stringify(t).length;if(this._totalSize+=n,this._totalSize>Bd)throw new rf;this.events.push(t)}finish(){return new Promise(t=>{const n=this.events;this.clear(),t(JSON.stringify(n))})}clear(){this.events=[],this._totalSize=0,this.hasCheckout=!1}getEarliestTimestamp(){const t=this.events.map(n=>n.timestamp).sort()[0];return t?ef(t):null}}class XA{constructor(t){this._worker=t,this._id=0}ensureReady(){return this._ensureReadyPromise?this._ensureReadyPromise:(this._ensureReadyPromise=new Promise((t,n)=>{this._worker.addEventListener("message",({data:r})=>{r.success?t():n()},{once:!0}),this._worker.addEventListener("error",r=>{n(r)},{once:!0})}),this._ensureReadyPromise)}destroy(){pe&&he.info("Destroying compression worker"),this._worker.terminate()}postMessage(t,n){const r=this._getAndIncrementId();return new Promise((i,a)=>{const c=({data:d})=>{const f=d;if(f.method===t&&f.id===r){if(this._worker.removeEventListener("message",c),!f.success){pe&&he.error("Error in compression worker: ",f.response),a(new Error("Error in compression worker"));return}i(f.response)}};this._worker.addEventListener("message",c),this._worker.postMessage({id:r,method:t,arg:n})})}_getAndIncrementId(){return this._id++}}class JA{constructor(t){this._worker=new XA(t),this._earliestTimestamp=null,this._totalSize=0,this.hasCheckout=!1,this.waitForCheckout=!1}get hasEvents(){return!!this._earliestTimestamp}get type(){return"worker"}ensureReady(){return this._worker.ensureReady()}destroy(){this._worker.destroy()}addEvent(t){const n=ef(t.timestamp);(!this._earliestTimestamp||n<this._earliestTimestamp)&&(this._earliestTimestamp=n);const r=JSON.stringify(t);return this._totalSize+=r.length,this._totalSize>Bd?Promise.reject(new rf):this._sendEventToWorker(r)}finish(){return this._finishRequest()}clear(){this._earliestTimestamp=null,this._totalSize=0,this.hasCheckout=!1,this._worker.postMessage("clear").then(null,t=>{pe&&he.exception(t,'Sending "clear" message to worker failed',t)})}getEarliestTimestamp(){return this._earliestTimestamp}_sendEventToWorker(t){return this._worker.postMessage("addEvent",t)}async _finishRequest(){const t=await this._worker.postMessage("finish");return this._earliestTimestamp=null,this._totalSize=0,t}}class ZA{constructor(t){this._fallback=new V0,this._compression=new JA(t),this._used=this._fallback,this._ensureWorkerIsLoadedPromise=this._ensureWorkerIsLoaded()}get waitForCheckout(){return this._used.waitForCheckout}get type(){return this._used.type}get hasEvents(){return this._used.hasEvents}get hasCheckout(){return this._used.hasCheckout}set hasCheckout(t){this._used.hasCheckout=t}set waitForCheckout(t){this._used.waitForCheckout=t}destroy(){this._fallback.destroy(),this._compression.destroy()}clear(){return this._used.clear()}getEarliestTimestamp(){return this._used.getEarliestTimestamp()}addEvent(t){return this._used.addEvent(t)}async finish(){return await this.ensureWorkerIsLoaded(),this._used.finish()}ensureWorkerIsLoaded(){return this._ensureWorkerIsLoadedPromise}async _ensureWorkerIsLoaded(){try{await this._compression.ensureReady()}catch(t){pe&&he.exception(t,"Failed to load the compression worker, falling back to simple buffer");return}await this._switchToCompressionWorker()}async _switchToCompressionWorker(){const{events:t,hasCheckout:n,waitForCheckout:r}=this._fallback,i=[];for(const a of t)i.push(this._compression.addEvent(a));this._compression.hasCheckout=n,this._compression.waitForCheckout=r,this._used=this._compression;try{await Promise.all(i),this._fallback.clear()}catch(a){pe&&he.exception(a,"Failed to add events when switching buffers.")}}}function eO({useCompression:e,workerUrl:t}){if(e&&window.Worker){const n=tO(t);if(n)return n}return pe&&he.info("Using simple buffer"),new V0}function tO(e){try{const t=e||nO();if(!t)return;pe&&he.info(`Using compression worker${e?` from ${e}`:""}`);const n=new Worker(t);return new ZA(n)}catch(t){pe&&he.exception(t,"Failed to create compression worker")}}function nO(){return typeof __SENTRY_EXCLUDE_REPLAY_WORKER__>"u"||!__SENTRY_EXCLUDE_REPLAY_WORKER__?KA():""}function sf(){try{return"sessionStorage"in Ge&&!!Ge.sessionStorage}catch{return!1}}function rO(e){sO(),e.session=void 0}function sO(){if(sf())try{Ge.sessionStorage.removeItem($d)}catch{}}function G0(e){return e===void 0?!1:Math.random()<e}function Y0(e){const t=Date.now(),n=e.id||on(),r=e.started||t,i=e.lastActivity||t,a=e.segmentId||0,c=e.sampled,d=e.previousSessionId;return{id:n,started:r,lastActivity:i,segmentId:a,sampled:c,previousSessionId:d}}function of(e){if(sf())try{Ge.sessionStorage.setItem($d,JSON.stringify(e))}catch{}}function oO(e,t){return G0(e)?"session":t?"buffer":!1}function K0({sessionSampleRate:e,allowBuffering:t,stickySession:n=!1},{previousSessionId:r}={}){const i=oO(e,t),a=Y0({sampled:i,previousSessionId:r});return n&&of(a),a}function iO(){if(!sf())return null;try{const e=Ge.sessionStorage.getItem($d);if(!e)return null;const t=JSON.parse(e);return pe&&he.infoTick("Loading existing session"),Y0(t)}catch{return null}}function af(e,t,n=+new Date){return e===null||t===void 0||t<0?!0:t===0?!1:e+t<=n}function Q0(e,{maxReplayDuration:t,sessionIdleExpire:n,targetTime:r=Date.now()}){return af(e.started,t,r)||af(e.lastActivity,n,r)}function X0(e,{sessionIdleExpire:t,maxReplayDuration:n}){return!(!Q0(e,{sessionIdleExpire:t,maxReplayDuration:n})||e.sampled==="buffer"&&e.segmentId===0)}function lf({sessionIdleExpire:e,maxReplayDuration:t,previousSessionId:n},r){const i=r.stickySession&&iO();return i?X0(i,{sessionIdleExpire:e,maxReplayDuration:t})?(pe&&he.infoTick("Session in sessionStorage is expired, creating new one..."),K0(r,{previousSessionId:i.id})):i:(pe&&he.infoTick("Creating new session"),K0(r,{previousSessionId:n}))}function aO(e){return e.type===Te.Custom}function cf(e,t,n){return Z0(e,t)?(J0(e,t,n),!0):!1}function lO(e,t,n){return Z0(e,t)?J0(e,t,n):Promise.resolve(null)}async function J0(e,t,n){const{eventBuffer:r}=e;if(!r||r.waitForCheckout&&!n)return null;const i=e.recordingMode==="buffer";try{n&&i&&r.clear(),n&&(r.hasCheckout=!0,r.waitForCheckout=!1);const a=e.getOptions(),c=cO(t,a.beforeAddRecordingEvent);return c?await r.addEvent(c):void 0}catch(a){const c=a&&a instanceof rf,d=c?"addEventSizeExceeded":"addEvent";if(c&&i)return r.clear(),r.waitForCheckout=!0,null;e.handleException(a),await e.stop({reason:d});const f=Ae();f&&f.recordDroppedEvent("internal_sdk_error","replay")}}function Z0(e,t){if(!e.eventBuffer||e.isPaused()||!e.isEnabled())return!1;const n=ef(t.timestamp);return n+e.timeouts.sessionIdlePause<Date.now()?!1:n>e.getContext().initialTimestamp+e.getOptions().maxReplayDuration?(pe&&he.infoTick(`Skipping event with timestamp ${n} because it is after maxReplayDuration`),!1):!0}function cO(e,t){try{if(typeof t=="function"&&aO(e))return t(e)}catch(n){return pe&&he.exception(n,"An error occurred in the `beforeAddRecordingEvent` callback, skipping the event..."),null}return e}function uf(e){return!e.type}function df(e){return e.type==="transaction"}function uO(e){return e.type==="replay_event"}function e1(e){return e.type==="feedback"}function dO(e){return(t,n)=>{if(!e.isEnabled()||!uf(t)&&!df(t))return;const r=n&&n.statusCode;if(!(!r||r<200||r>=300)){if(df(t)){fO(e,t);return}pO(e,t)}}}function fO(e,t){const n=e.getContext();t.contexts&&t.contexts.trace&&t.contexts.trace.trace_id&&n.traceIds.size<100&&n.traceIds.add(t.contexts.trace.trace_id)}function pO(e,t){const n=e.getContext();if(t.event_id&&n.errorIds.size<100&&n.errorIds.add(t.event_id),e.recordingMode!=="buffer"||!t.tags||!t.tags.replayId)return;const{beforeErrorSampling:r}=e.getOptions();typeof r=="function"&&!r(t)||go(async()=>{try{await e.sendBufferedReplayOrFlush()}catch(i){e.handleException(i)}})}function hO(e){return t=>{!e.isEnabled()||!uf(t)||mO(e,t)}}function mO(e,t){const n=t.exception&&t.exception.values&&t.exception.values[0]&&t.exception.values[0].value;if(typeof n=="string"&&(n.match(/(reactjs\.org\/docs\/error-decoder\.html\?invariant=|react\.dev\/errors\/)(418|419|422|423|425)/)||n.match(/(does not match server-rendered HTML|Hydration failed because)/i))){const r=Vn({category:"replay.hydrate-error",data:{url:Jm()}});Ai(e,r)}}function gO(e){const t=Ae();t&&t.on("beforeAddBreadcrumb",n=>yO(e,n))}function yO(e,t){if(!e.isEnabled()||!t1(t))return;const n=vO(t);n&&Ai(e,n)}function vO(e){return!t1(e)||["fetch","xhr","sentry.event","sentry.transaction"].includes(e.category)||e.category.startsWith("ui.")?null:e.category==="console"?SO(e):Vn(e)}function SO(e){const t=e.data&&e.data.arguments;if(!Array.isArray(t)||t.length===0)return Vn(e);let n=!1;const r=t.map(i=>{if(!i)return i;if(typeof i=="string")return i.length>vl?(n=!0,`${i.slice(0,vl)}…`):i;if(typeof i=="object")try{const a=Rn(i,7);return JSON.stringify(a).length>vl?(n=!0,`${JSON.stringify(a,null,2).slice(0,vl)}…`):a}catch{}return i});return Vn({...e,data:{...e.data,arguments:r,...n?{_meta:{warnings:["CONSOLE_ARG_TRUNCATED"]}}:{}}})}function t1(e){return!!e.category}function wO(e,t){return e.type||!e.exception||!e.exception.values||!e.exception.values.length?!1:!!(t.originalException&&t.originalException.__rrweb__)}function n1(){const e=Ve().getPropagationContext().dsc;e&&delete e.replay_id;const t=vt();if(t){const n=ws(t);delete n.replay_id}}function _O(e,t){e.triggerUserActivity(),e.addUpdate(()=>t.timestamp?(e.throttledAddEvent({type:Te.Custom,timestamp:t.timestamp*1e3,data:{tag:"breadcrumb",payload:{timestamp:t.timestamp,type:"default",category:"sentry.feedback",data:{feedbackId:t.event_id}}}}),!1):!0)}function EO(e,t){return e.recordingMode!=="buffer"||t.message===Fd||!t.exception||t.type?!1:G0(e.getOptions().errorSampleRate)}function xO(e){return Object.assign((t,n)=>!e.isEnabled()||e.isPaused()?t:uO(t)?(delete t.breadcrumbs,t):!uf(t)&&!df(t)&&!e1(t)?t:e.checkAndHandleExpiredSession()?e1(t)?(e.flush(),t.contexts.feedback.replay_id=e.getSessionId(),_O(e,t),t):wO(t,n)&&!e.getOptions()._experiments.captureExceptions?(pe&&he.log("Ignoring error from rrweb internals",t),null):((EO(e,t)||e.recordingMode==="session")&&(t.tags={...t.tags,replayId:e.getSessionId()}),t):(n1(),t),{id:"Replay"})}function Ml(e,t){return t.map(({type:n,start:r,end:i,name:a,data:c})=>{const d=e.throttledAddEvent({type:Te.Custom,timestamp:r,data:{tag:"performanceSpan",payload:{op:n,description:a,startTimestamp:r,endTimestamp:i,data:c}}});return typeof d=="string"?Promise.resolve(null):d})}function kO(e){const{from:t,to:n}=e,r=Date.now()/1e3;return{type:"navigation.push",start:r,end:r,name:n,data:{previous:t}}}function TO(e){return t=>{if(!e.isEnabled())return;const n=kO(t);n!==null&&(e.getContext().urls.push(n.name),e.triggerUserActivity(),e.addUpdate(()=>(Ml(e,[n]),!1)))}}function bO(e,t){return pe&&e.getOptions()._experiments.traceInternals?!1:Lb(t,Ae())}function r1(e,t){e.isEnabled()&&t!==null&&(bO(e,t.name)||e.addUpdate(()=>(Ml(e,[t]),!0)))}function Ll(e){if(!e)return;const t=new TextEncoder;try{if(typeof e=="string")return t.encode(e).length;if(e instanceof URLSearchParams)return t.encode(e.toString()).length;if(e instanceof FormData){const n=a1(e);return t.encode(n).length}if(e instanceof Blob)return e.size;if(e instanceof ArrayBuffer)return e.byteLength}catch{}}function s1(e){if(!e)return;const t=parseInt(e,10);return isNaN(t)?void 0:t}function o1(e){try{if(typeof e=="string")return[e];if(e instanceof URLSearchParams)return[e.toString()];if(e instanceof FormData)return[a1(e)];if(!e)return[void 0]}catch(t){return pe&&he.exception(t,"Failed to serialize body",e),[void 0,"BODY_PARSE_ERROR"]}return pe&&he.info("Skipping network body because of body type",e),[void 0,"UNPARSEABLE_BODY_TYPE"]}function jl(e,t){if(!e)return{headers:{},size:void 0,_meta:{warnings:[t]}};const n={...e._meta},r=n.warnings||[];return n.warnings=[...r,t],e._meta=n,e}function i1(e,t){if(!t)return null;const{startTimestamp:n,endTimestamp:r,url:i,method:a,statusCode:c,request:d,response:f}=t;return{type:e,start:n/1e3,end:r/1e3,name:i,data:dt({method:a,statusCode:c,request:d,response:f})}}function Oi(e){return{headers:{},size:e,_meta:{warnings:["URL_SKIPPED"]}}}function $r(e,t,n){if(!t&&Object.keys(e).length===0)return;if(!t)return{headers:e};if(!n)return{headers:e,size:t};const r={headers:e,size:t},{body:i,warnings:a}=IO(n);return r.body=i,a&&a.length>0&&(r._meta={warnings:a}),r}function ff(e,t){return Object.entries(e).reduce((n,[r,i])=>{const a=r.toLowerCase();return t.includes(a)&&e[r]&&(n[a]=i),n},{})}function a1(e){return new URLSearchParams(e).toString()}function IO(e){if(!e||typeof e!="string")return{body:e};const t=e.length>t0,n=CO(e);if(t){const r=e.slice(0,t0);return n?{body:r,warnings:["MAYBE_JSON_TRUNCATED"]}:{body:`${r}…`,warnings:["TEXT_TRUNCATED"]}}if(n)try{return{body:JSON.parse(e)}}catch{}return{body:e}}function CO(e){const t=e[0],n=e[e.length-1];return t==="["&&n==="]"||t==="{"&&n==="}"}function Dl(e,t){const n=RO(e);return Rr(n,t)}function RO(e,t=Ge.document.baseURI){if(e.startsWith("http://")||e.startsWith("https://")||e.startsWith(Ge.location.origin))return e;const n=new URL(e,t);if(n.origin!==new URL(t).origin)return e;const r=n.href;return!e.endsWith("/")&&r.endsWith("/")?r.slice(0,-1):r}async function AO(e,t,n){try{const r=await PO(e,t,n),i=i1("resource.fetch",r);r1(n.replay,i)}catch(r){pe&&he.exception(r,"Failed to capture fetch breadcrumb")}}function OO(e,t){const{input:n,response:r}=t,i=n?l1(n):void 0,a=Ll(i),c=r?s1(r.headers.get("content-length")):void 0;a!==void 0&&(e.data.request_body_size=a),c!==void 0&&(e.data.response_body_size=c)}async function PO(e,t,n){const r=Date.now(),{startTimestamp:i=r,endTimestamp:a=r}=t,{url:c,method:d,status_code:f=0,request_body_size:h,response_body_size:y}=e.data,g=Dl(c,n.networkDetailAllowUrls)&&!Dl(c,n.networkDetailDenyUrls),w=g?NO(n,t.input,h):Oi(h),x=await MO(g,n,t.response,y);return{startTimestamp:i,endTimestamp:a,url:c,method:d,statusCode:f,request:w,response:x}}function NO({networkCaptureBodies:e,networkRequestHeaders:t},n,r){const i=n?DO(n,t):{};if(!e)return $r(i,r,void 0);const a=l1(n),[c,d]=o1(a),f=$r(i,r,c);return d?jl(f,d):f}async function MO(e,{networkCaptureBodies:t,networkResponseHeaders:n},r,i){if(!e&&i!==void 0)return Oi(i);const a=r?c1(r.headers,n):{};if(!r||!t&&i!==void 0)return $r(a,i,void 0);const[c,d]=await jO(r),f=LO(c,{networkCaptureBodies:t,responseBodySize:i,captureDetails:e,headers:a});return d?jl(f,d):f}function LO(e,{networkCaptureBodies:t,responseBodySize:n,captureDetails:r,headers:i}){try{const a=e&&e.length&&n===void 0?Ll(e):n;return r?t?$r(i,a,e):$r(i,a,void 0):Oi(a)}catch(a){return pe&&he.exception(a,"Failed to serialize response body"),$r(i,n,void 0)}}async function jO(e){const t=$O(e);if(!t)return[void 0,"BODY_PARSE_ERROR"];try{return[await FO(t)]}catch(n){return n instanceof Error&&n.message.indexOf("Timeout")>-1?(pe&&he.warn("Parsing text body from response timed out"),[void 0,"BODY_PARSE_TIMEOUT"]):(pe&&he.exception(n,"Failed to get text body from response"),[void 0,"BODY_PARSE_ERROR"])}}function l1(e=[]){if(!(e.length!==2||typeof e[1]!="object"))return e[1].body}function c1(e,t){const n={};return t.forEach(r=>{e.get(r)&&(n[r]=e.get(r))}),n}function DO(e,t){return e.length===1&&typeof e[0]!="string"?u1(e[0],t):e.length===2?u1(e[1],t):{}}function u1(e,t){if(!e)return{};const n=e.headers;return n?n instanceof Headers?c1(n,t):Array.isArray(n)?{}:ff(n,t):{}}function $O(e){try{return e.clone()}catch(t){pe&&he.exception(t,"Failed to clone response body")}}function FO(e){return new Promise((t,n)=>{const r=go(()=>n(new Error("Timeout while trying to read response body")),500);BO(e).then(i=>t(i),i=>n(i)).finally(()=>clearTimeout(r))})}async function BO(e){return await e.text()}async function zO(e,t,n){try{const r=HO(e,t,n),i=i1("resource.xhr",r);r1(n.replay,i)}catch(r){pe&&he.exception(r,"Failed to capture xhr breadcrumb")}}function UO(e,t){const{xhr:n,input:r}=t;if(!n)return;const i=Ll(r),a=n.getResponseHeader("content-length")?s1(n.getResponseHeader("content-length")):GO(n.response,n.responseType);i!==void 0&&(e.data.request_body_size=i),a!==void 0&&(e.data.response_body_size=a)}function HO(e,t,n){const r=Date.now(),{startTimestamp:i=r,endTimestamp:a=r,input:c,xhr:d}=t,{url:f,method:h,status_code:y=0,request_body_size:g,response_body_size:w}=e.data;if(!f)return null;if(!d||!Dl(f,n.networkDetailAllowUrls)||Dl(f,n.networkDetailDenyUrls)){const M=Oi(g),L=Oi(w);return{startTimestamp:i,endTimestamp:a,url:f,method:h,statusCode:y,request:M,response:L}}const x=d[ks],_=x?ff(x.request_headers,n.networkRequestHeaders):{},E=ff(WO(d),n.networkResponseHeaders),[k,O]=n.networkCaptureBodies?o1(c):[void 0],[R,$]=n.networkCaptureBodies?qO(d):[void 0],H=$r(_,g,k),z=$r(E,w,R);return{startTimestamp:i,endTimestamp:a,url:f,method:h,statusCode:y,request:O?jl(H,O):H,response:$?jl(z,$):z}}function WO(e){const t=e.getAllResponseHeaders();return t?t.split(`\r
`).reduce((n,r)=>{const[i,a]=r.split(": ");return a&&(n[i.toLowerCase()]=a),n},{}):{}}function qO(e){const t=[];try{return[e.responseText]}catch(n){t.push(n)}try{return VO(e.response,e.responseType)}catch(n){t.push(n)}return pe&&he.warn("Failed to get xhr response body",...t),[void 0]}function VO(e,t){try{if(typeof e=="string")return[e];if(e instanceof Document)return[e.body.outerHTML];if(t==="json"&&e&&typeof e=="object")return[JSON.stringify(e)];if(!e)return[void 0]}catch(n){return pe&&he.exception(n,"Failed to serialize body",e),[void 0,"BODY_PARSE_ERROR"]}return pe&&he.info("Skipping network body because of body type",e),[void 0,"UNPARSEABLE_BODY_TYPE"]}function GO(e,t){try{const n=t==="json"&&e&&typeof e=="object"?JSON.stringify(e):e;return Ll(n)}catch{return}}function YO(e){const t=Ae();try{const{networkDetailAllowUrls:n,networkDetailDenyUrls:r,networkCaptureBodies:i,networkRequestHeaders:a,networkResponseHeaders:c}=e.getOptions(),d={replay:e,networkDetailAllowUrls:n,networkDetailDenyUrls:r,networkCaptureBodies:i,networkRequestHeaders:a,networkResponseHeaders:c};t&&t.on("beforeAddBreadcrumb",(f,h)=>KO(d,f,h))}catch{}}function KO(e,t,n){if(t.data)try{QO(t)&&JO(n)&&(UO(t,n),zO(t,n,e)),XO(t)&&ZO(n)&&(OO(t,n),AO(t,n,e))}catch(r){pe&&he.exception(r,"Error when enriching network breadcrumb")}}function QO(e){return e.category==="xhr"}function XO(e){return e.category==="fetch"}function JO(e){return e&&e.xhr}function ZO(e){return e&&e.response}function eP(e){const t=Ae();qy(RA(e)),hl(TO(e)),gO(e),YO(e);const n=xO(e);hb(n),t&&(t.on("beforeSendEvent",hO(e)),t.on("afterSendEvent",dO(e)),t.on("createDsc",r=>{const i=e.getSessionId();i&&e.isEnabled()&&e.recordingMode==="session"&&e.checkAndHandleExpiredSession()&&(r.replay_id=i)}),t.on("spanStart",r=>{e.lastActiveSpan=r}),t.on("spanEnd",r=>{e.lastActiveSpan=r}),t.on("beforeSendFeedback",(r,i)=>{const a=e.getSessionId();i&&i.includeReplay&&e.isEnabled()&&a&&r.contexts&&r.contexts.feedback&&(r.contexts.feedback.replay_id=a)}))}async function tP(e){try{return Promise.all(Ml(e,[nP(Ge.performance.memory)]))}catch{return[]}}function nP(e){const{jsHeapSizeLimit:t,totalJSHeapSize:n,usedJSHeapSize:r}=e,i=Date.now()/1e3;return{type:"memory",name:"memory",start:i,end:i,data:{memory:{jsHeapSizeLimit:t,totalJSHeapSize:n,usedJSHeapSize:r}}}}function rP(e,t,n){let r,i,a;const c=n&&n.maxWait?Math.max(n.maxWait,t):0;function d(){return f(),r=e(),r}function f(){i!==void 0&&clearTimeout(i),a!==void 0&&clearTimeout(a),i=a=void 0}function h(){return i!==void 0||a!==void 0?d():r}function y(){return i&&clearTimeout(i),i=go(d,t),c&&a===void 0&&(a=go(d,c)),r}return y.cancel=f,y.flush=h,y}const bs=Ne.navigator;function sP(){return/iPhone|iPad|iPod/i.test(bs&&bs.userAgent||"")||/Macintosh/i.test(bs&&bs.userAgent||"")&&bs&&bs.maxTouchPoints&&bs.maxTouchPoints>1?{sampling:{mousemove:!1}}:{}}function oP(e){let t=!1;return(n,r)=>{if(!e.checkAndHandleExpiredSession()){pe&&he.warn("Received replay event after session expired.");return}const i=r||!t;t=!0,e.clickDetector&&kA(e.clickDetector,n),e.addUpdate(()=>{if(e.recordingMode==="buffer"&&i&&e.setInitialState(),!cf(e,n,i))return!0;if(!i)return!1;const a=e.session;if(aP(e,i),e.recordingMode==="buffer"&&a&&e.eventBuffer){const c=e.eventBuffer.getEarliestTimestamp();c&&(pe&&he.info(`Updating session start time to earliest event in buffer to ${new Date(c)}`),a.started=c,e.getOptions().stickySession&&of(a))}return a&&a.previousSessionId||e.recordingMode==="session"&&e.flush(),!0})}}function iP(e){const t=e.getOptions();return{type:Te.Custom,timestamp:Date.now(),data:{tag:"options",payload:{shouldRecordCanvas:e.isRecordingCanvas(),sessionSampleRate:t.sessionSampleRate,errorSampleRate:t.errorSampleRate,useCompressionOption:t.useCompression,blockAllMedia:t.blockAllMedia,maskAllText:t.maskAllText,maskAllInputs:t.maskAllInputs,useCompression:e.eventBuffer?e.eventBuffer.type==="worker":!1,networkDetailHasUrls:t.networkDetailAllowUrls.length>0,networkCaptureBodies:t.networkCaptureBodies,networkRequestHasHeaders:t.networkRequestHeaders.length>0,networkResponseHasHeaders:t.networkResponseHeaders.length>0}}}}function aP(e,t){!t||!e.session||e.session.segmentId!==0||cf(e,iP(e),!1)}function lP(e,t,n,r){return _s(jg(e,dd(e),r,n),[[{type:"replay_event"},e],[{type:"replay_recording",length:typeof t=="string"?new TextEncoder().encode(t).length:t.length},t]])}function cP({recordingData:e,headers:t}){let n;const r=`${JSON.stringify(t)}
`;if(typeof e=="string")n=`${r}${e}`;else{const a=new TextEncoder().encode(r);n=new Uint8Array(a.length+e.length),n.set(a),n.set(e,a.length)}return n}async function uP({client:e,scope:t,replayId:n,event:r}){const i=typeof e._integrations=="object"&&e._integrations!==null&&!Array.isArray(e._integrations)?Object.keys(e._integrations):void 0,a={event_id:n,integrations:i};e.emit("preprocessEvent",r,a);const c=await Yg(e.getOptions(),r,a,t,e,Cn());if(!c)return null;c.platform=c.platform||"javascript";const d=e.getSdkMetadata(),{name:f,version:h}=d&&d.sdk||{};return c.sdk={...c.sdk,name:f||"sentry.javascript.unknown",version:h||"0.0.0"},c}async function dP({recordingData:e,replayId:t,segmentId:n,eventContext:r,timestamp:i,session:a}){const c=cP({recordingData:e,headers:{segment_id:n}}),{urls:d,errorIds:f,traceIds:h,initialTimestamp:y}=r,g=Ae(),w=Ve(),x=g&&g.getTransport(),_=g&&g.getDsn();if(!g||!x||!_||!a.sampled)return ar({});const E={type:HR,replay_start_timestamp:y/1e3,timestamp:i/1e3,error_ids:f,trace_ids:h,urls:d,replay_id:t,segment_id:n,replay_type:a.sampled},k=await uP({scope:w,client:g,replayId:t,event:E});if(!k)return g.recordDroppedEvent("event_processor","replay",E),pe&&he.info("An event processor returned `null`, will not send event."),ar({});delete k.sdkProcessingMetadata;const O=lP(k,c,_,g.getOptions().tunnel);let R;try{R=await x.send(O)}catch(H){const z=new Error(Fd);try{z.cause=H}catch{}throw z}if(typeof R.statusCode=="number"&&(R.statusCode<200||R.statusCode>=300))throw new d1(R.statusCode);const $=ly({},R);if(ay($,"replay"))throw new pf($);return R}class d1 extends Error{constructor(t){super(`Transport returned status code ${t}`)}}class pf extends Error{constructor(t){super("Rate limit hit"),this.rateLimits=t}}async function f1(e,t={count:0,interval:KR}){const{recordingData:n,onError:r}=e;if(n.length)try{return await dP(e),!0}catch(i){if(i instanceof d1||i instanceof pf)throw i;if(Qg("Replays",{_retryCount:t.count}),r&&r(i),t.count>=QR){const a=new Error(`${Fd} - max retries exceeded`);try{a.cause=i}catch{}throw a}return t.interval*=++t.count,new Promise((a,c)=>{go(async()=>{try{await f1(e,t),a(!0)}catch(d){c(d)}},t.interval)})}}const p1="__THROTTLED",fP="__SKIPPED";function pP(e,t,n){const r=new Map,i=d=>{const f=d-n;r.forEach((h,y)=>{y<f&&r.delete(y)})},a=()=>[...r.values()].reduce((d,f)=>d+f,0);let c=!1;return(...d)=>{const f=Math.floor(Date.now()/1e3);if(i(f),a()>=t){const y=c;return c=!0,y?fP:p1}c=!1;const h=r.get(f)||0;return r.set(f,h+1),e(...d)}}class Fr{constructor({options:t,recordingOptions:n}){Fr.prototype.__init.call(this),Fr.prototype.__init2.call(this),Fr.prototype.__init3.call(this),Fr.prototype.__init4.call(this),Fr.prototype.__init5.call(this),Fr.prototype.__init6.call(this),this.eventBuffer=null,this.performanceEntries=[],this.replayPerformanceEntries=[],this.recordingMode="session",this.timeouts={sessionIdlePause:WR,sessionIdleExpire:qR},this._lastActivity=Date.now(),this._isEnabled=!1,this._isPaused=!1,this._requiresManualStart=!1,this._hasInitializedCoreListeners=!1,this._context={errorIds:new Set,traceIds:new Set,urls:[],initialTimestamp:Date.now(),initialUrl:""},this._recordingOptions=n,this._options=t,this._debouncedFlush=rP(()=>this._flush(),this._options.flushMinDelay,{maxWait:this._options.flushMaxDelay}),this._throttledAddEvent=pP((c,d)=>lO(this,c,d),300,5);const{slowClickTimeout:r,slowClickIgnoreSelectors:i}=this.getOptions(),a=r?{threshold:Math.min(XR,r),timeout:r,scrollTimeout:JR,ignoreSelector:i?i.join(","):""}:void 0;if(a&&(this.clickDetector=new wA(this,a)),pe){const c=t._experiments;he.setConfig({captureExceptions:!!c.captureExceptions,traceInternals:!!c.traceInternals})}}getContext(){return this._context}isEnabled(){return this._isEnabled}isPaused(){return this._isPaused}isRecordingCanvas(){return!!this._canvas}getOptions(){return this._options}handleException(t){pe&&he.exception(t),this._options.onError&&this._options.onError(t)}initializeSampling(t){const{errorSampleRate:n,sessionSampleRate:r}=this._options,i=n<=0&&r<=0;if(this._requiresManualStart=i,!i){if(this._initializeSessionForSampling(t),!this.session){pe&&he.exception(new Error("Unable to initialize and create session"));return}this.session.sampled!==!1&&(this.recordingMode=this.session.sampled==="buffer"&&this.session.segmentId===0?"buffer":"session",pe&&he.infoTick(`Starting replay in ${this.recordingMode} mode`),this._initializeRecording())}}start(){if(this._isEnabled&&this.recordingMode==="session"){pe&&he.info("Recording is already in progress");return}if(this._isEnabled&&this.recordingMode==="buffer"){pe&&he.info("Buffering is in progress, call `flush()` to save the replay");return}pe&&he.infoTick("Starting replay in session mode"),this._updateUserActivity();const t=lf({maxReplayDuration:this._options.maxReplayDuration,sessionIdleExpire:this.timeouts.sessionIdleExpire},{stickySession:this._options.stickySession,sessionSampleRate:1,allowBuffering:!1});this.session=t,this._initializeRecording()}startBuffering(){if(this._isEnabled){pe&&he.info("Buffering is in progress, call `flush()` to save the replay");return}pe&&he.infoTick("Starting replay in buffer mode");const t=lf({sessionIdleExpire:this.timeouts.sessionIdleExpire,maxReplayDuration:this._options.maxReplayDuration},{stickySession:this._options.stickySession,sessionSampleRate:0,allowBuffering:!0});this.session=t,this.recordingMode="buffer",this._initializeRecording()}startRecording(){try{const t=this._canvas;this._stopRecording=dr({...this._recordingOptions,...this.recordingMode==="buffer"?{checkoutEveryNms:YR}:this._options._experiments.continuousCheckout&&{checkoutEveryNms:Math.max(36e4,this._options._experiments.continuousCheckout)},emit:oP(this),...sP(),onMutation:this._onMutationHandler,...t?{recordCanvas:t.recordCanvas,getCanvasManager:t.getCanvasManager,sampling:t.sampling,dataURLOptions:t.dataURLOptions}:{}})}catch(t){this.handleException(t)}}stopRecording(){try{return this._stopRecording&&(this._stopRecording(),this._stopRecording=void 0),!0}catch(t){return this.handleException(t),!1}}async stop({forceFlush:t=!1,reason:n}={}){if(this._isEnabled){this._isEnabled=!1;try{pe&&he.info(`Stopping Replay${n?` triggered by ${n}`:""}`),n1(),this._removeListeners(),this.stopRecording(),this._debouncedFlush.cancel(),t&&await this._flush({force:!0}),this.eventBuffer&&this.eventBuffer.destroy(),this.eventBuffer=null,rO(this)}catch(r){this.handleException(r)}}}pause(){this._isPaused||(this._isPaused=!0,this.stopRecording(),pe&&he.info("Pausing replay"))}resume(){!this._isPaused||!this._checkSession()||(this._isPaused=!1,this.startRecording(),pe&&he.info("Resuming replay"))}async sendBufferedReplayOrFlush({continueRecording:t=!0}={}){if(this.recordingMode==="session")return this.flushImmediate();const n=Date.now();pe&&he.info("Converting buffer to session"),await this.flushImmediate();const r=this.stopRecording();!t||!r||this.recordingMode!=="session"&&(this.recordingMode="session",this.session&&(this._updateUserActivity(n),this._updateSessionActivity(n),this._maybeSaveSession()),this.startRecording())}addUpdate(t){const n=t();this.recordingMode!=="buffer"&&n!==!0&&this._debouncedFlush()}triggerUserActivity(){if(this._updateUserActivity(),!this._stopRecording){if(!this._checkSession())return;this.resume();return}this.checkAndHandleExpiredSession(),this._updateSessionActivity()}updateUserActivity(){this._updateUserActivity(),this._updateSessionActivity()}conditionalFlush(){return this.recordingMode==="buffer"?Promise.resolve():this.flushImmediate()}flush(){return this._debouncedFlush()}flushImmediate(){return this._debouncedFlush(),this._debouncedFlush.flush()}cancelFlush(){this._debouncedFlush.cancel()}getSessionId(){return this.session&&this.session.id}checkAndHandleExpiredSession(){if(this._lastActivity&&af(this._lastActivity,this.timeouts.sessionIdlePause)&&this.session&&this.session.sampled==="session"){this.pause();return}return!!this._checkSession()}setInitialState(){const t=`${Ge.location.pathname}${Ge.location.hash}${Ge.location.search}`,n=`${Ge.location.origin}${t}`;this.performanceEntries=[],this.replayPerformanceEntries=[],this._clearContext(),this._context.initialUrl=n,this._context.initialTimestamp=Date.now(),this._context.urls.push(n)}throttledAddEvent(t,n){const r=this._throttledAddEvent(t,n);if(r===p1){const i=Vn({category:"replay.throttled"});this.addUpdate(()=>!cf(this,{type:pA,timestamp:i.timestamp||0,data:{tag:"breadcrumb",payload:i,metric:!0}}))}return r}getCurrentRoute(){const t=this.lastActiveSpan||vt(),n=t&&bt(t),i=(n&&Fe(n).data||{})[Hn];if(!(!n||!i||!["route","custom"].includes(i)))return Fe(n).description}_initializeRecording(){this.setInitialState(),this._updateSessionActivity(),this.eventBuffer=eO({useCompression:this._options.useCompression,workerUrl:this._options.workerUrl}),this._removeListeners(),this._addListeners(),this._isEnabled=!0,this._isPaused=!1,this.startRecording()}_initializeSessionForSampling(t){const n=this._options.errorSampleRate>0,r=lf({sessionIdleExpire:this.timeouts.sessionIdleExpire,maxReplayDuration:this._options.maxReplayDuration,previousSessionId:t},{stickySession:this._options.stickySession,sessionSampleRate:this._options.sessionSampleRate,allowBuffering:n});this.session=r}_checkSession(){if(!this.session)return!1;const t=this.session;return X0(t,{sessionIdleExpire:this.timeouts.sessionIdleExpire,maxReplayDuration:this._options.maxReplayDuration})?(this._refreshSession(t),!1):!0}async _refreshSession(t){this._isEnabled&&(await this.stop({reason:"refresh session"}),this.initializeSampling(t.id))}_addListeners(){try{Ge.document.addEventListener("visibilitychange",this._handleVisibilityChange),Ge.addEventListener("blur",this._handleWindowBlur),Ge.addEventListener("focus",this._handleWindowFocus),Ge.addEventListener("keydown",this._handleKeyboardEvent),this.clickDetector&&this.clickDetector.addListeners(),this._hasInitializedCoreListeners||(eP(this),this._hasInitializedCoreListeners=!0)}catch(t){this.handleException(t)}this._performanceCleanupCallback=GA(this)}_removeListeners(){try{Ge.document.removeEventListener("visibilitychange",this._handleVisibilityChange),Ge.removeEventListener("blur",this._handleWindowBlur),Ge.removeEventListener("focus",this._handleWindowFocus),Ge.removeEventListener("keydown",this._handleKeyboardEvent),this.clickDetector&&this.clickDetector.removeListeners(),this._performanceCleanupCallback&&this._performanceCleanupCallback()}catch(t){this.handleException(t)}}__init(){this._handleVisibilityChange=()=>{Ge.document.visibilityState==="visible"?this._doChangeToForegroundTasks():this._doChangeToBackgroundTasks()}}__init2(){this._handleWindowBlur=()=>{const t=Vn({category:"ui.blur"});this._doChangeToBackgroundTasks(t)}}__init3(){this._handleWindowFocus=()=>{const t=Vn({category:"ui.focus"});this._doChangeToForegroundTasks(t)}}__init4(){this._handleKeyboardEvent=t=>{NA(this,t)}}_doChangeToBackgroundTasks(t){!this.session||Q0(this.session,{maxReplayDuration:this._options.maxReplayDuration,sessionIdleExpire:this.timeouts.sessionIdleExpire})||(t&&this._createCustomBreadcrumb(t),this.conditionalFlush())}_doChangeToForegroundTasks(t){if(!this.session)return;if(!this.checkAndHandleExpiredSession()){pe&&he.info("Document has become active, but session has expired");return}t&&this._createCustomBreadcrumb(t)}_updateUserActivity(t=Date.now()){this._lastActivity=t}_updateSessionActivity(t=Date.now()){this.session&&(this.session.lastActivity=t,this._maybeSaveSession())}_createCustomBreadcrumb(t){this.addUpdate(()=>{this.throttledAddEvent({type:Te.Custom,timestamp:t.timestamp||0,data:{tag:"breadcrumb",payload:t}})})}_addPerformanceEntries(){let t=DA(this.performanceEntries).concat(this.replayPerformanceEntries);if(this.performanceEntries=[],this.replayPerformanceEntries=[],this._requiresManualStart){const n=this._context.initialTimestamp/1e3;t=t.filter(r=>r.start>=n)}return Promise.all(Ml(this,t))}_clearContext(){this._context.errorIds.clear(),this._context.traceIds.clear(),this._context.urls=[]}_updateInitialTimestampFromEventBuffer(){const{session:t,eventBuffer:n}=this;if(!t||!n||this._requiresManualStart||t.segmentId)return;const r=n.getEarliestTimestamp();r&&r<this._context.initialTimestamp&&(this._context.initialTimestamp=r)}_popEventContext(){const t={initialTimestamp:this._context.initialTimestamp,initialUrl:this._context.initialUrl,errorIds:Array.from(this._context.errorIds),traceIds:Array.from(this._context.traceIds),urls:this._context.urls};return this._clearContext(),t}async _runFlush(){const t=this.getSessionId();if(!this.session||!this.eventBuffer||!t){pe&&he.error("No session or eventBuffer found to flush.");return}if(await this._addPerformanceEntries(),!(!this.eventBuffer||!this.eventBuffer.hasEvents)&&(await tP(this),!!this.eventBuffer&&t===this.getSessionId()))try{this._updateInitialTimestampFromEventBuffer();const n=Date.now();if(n-this._context.initialTimestamp>this._options.maxReplayDuration+3e4)throw new Error("Session is too long, not sending replay");const r=this._popEventContext(),i=this.session.segmentId++;this._maybeSaveSession();const a=await this.eventBuffer.finish();await f1({replayId:t,recordingData:a,segmentId:i,eventContext:r,session:this.session,timestamp:n,onError:c=>this.handleException(c)})}catch(n){this.handleException(n),this.stop({reason:"sendReplay"});const r=Ae();if(r){const i=n instanceof pf?"ratelimit_backoff":"send_error";r.recordDroppedEvent(i,"replay")}}}__init5(){this._flush=async({force:t=!1}={})=>{if(!this._isEnabled&&!t)return;if(!this.checkAndHandleExpiredSession()){pe&&he.error("Attempting to finish replay event after session expired.");return}if(!this.session)return;const n=this.session.started,i=Date.now()-n;this._debouncedFlush.cancel();const a=i<this._options.minReplayDuration,c=i>this._options.maxReplayDuration+5e3;if(a||c){pe&&he.info(`Session duration (${Math.floor(i/1e3)}s) is too ${a?"short":"long"}, not sending replay.`),a&&this._debouncedFlush();return}const d=this.eventBuffer;d&&this.session.segmentId===0&&!d.hasCheckout&&pe&&he.info("Flushing initial segment without checkout.");const f=!!this._flushLock;this._flushLock||(this._flushLock=this._runFlush());try{await this._flushLock}catch(h){this.handleException(h)}finally{this._flushLock=void 0,f&&this._debouncedFlush()}}}_maybeSaveSession(){this.session&&this._options.stickySession&&of(this.session)}__init6(){this._onMutationHandler=t=>{const n=t.length,r=this._options.mutationLimit,i=this._options.mutationBreadcrumbLimit,a=r&&n>r;if(n>i||a){const c=Vn({category:"replay.mutations",data:{count:n,limit:a}});this._createCustomBreadcrumb(c)}return a?(this.stop({reason:"mutationLimit",forceFlush:this.recordingMode==="session"}),!1):!0}}}function Pi(e,t){return[...e,...t].join(",")}function hP({mask:e,unmask:t,block:n,unblock:r,ignore:i}){const a=["base","iframe[srcdoc]:not([src])"],c=Pi(e,[".sentry-mask","[data-sentry-mask]"]),d=Pi(t,[]);return{maskTextSelector:c,unmaskTextSelector:d,blockSelector:Pi(n,[".sentry-block","[data-sentry-block]",...a]),unblockSelector:Pi(r,[]),ignoreSelector:Pi(i,[".sentry-ignore","[data-sentry-ignore]",'input[type="file"]'])}}function mP({el:e,key:t,maskAttributes:n,maskAllText:r,privacyOptions:i,value:a}){return!r||i.unmaskTextSelector&&e.matches(i.unmaskTextSelector)?a:n.includes(t)||t==="value"&&e.tagName==="INPUT"&&["submit","button"].includes(e.getAttribute("type")||"")?a.replace(/[\S]/g,"*"):a}const h1='img,image,svg,video,object,picture,embed,map,audio,link[rel="icon"],link[rel="apple-touch-icon"]',gP=["content-length","content-type","accept"];let m1=!1;const yP=e=>new $l(e);class $l{static __initStatic(){this.id="Replay"}constructor({flushMinDelay:t=VR,flushMaxDelay:n=GR,minReplayDuration:r=ZR,maxReplayDuration:i=n0,stickySession:a=!0,useCompression:c=!0,workerUrl:d,_experiments:f={},maskAllText:h=!0,maskAllInputs:y=!0,blockAllMedia:g=!0,mutationBreadcrumbLimit:w=750,mutationLimit:x=1e4,slowClickTimeout:_=7e3,slowClickIgnoreSelectors:E=[],networkDetailAllowUrls:k=[],networkDetailDenyUrls:O=[],networkCaptureBodies:R=!0,networkRequestHeaders:$=[],networkResponseHeaders:H=[],mask:z=[],maskAttributes:M=["title","placeholder"],unmask:L=[],block:U=[],unblock:te=[],ignore:K=[],maskFn:oe,beforeAddRecordingEvent:ae,beforeErrorSampling:ye,onError:Ie}={}){this.name=$l.id;const We=hP({mask:z,unmask:L,block:U,unblock:te,ignore:K});if(this._recordingOptions={maskAllInputs:y,maskAllText:h,maskInputOptions:{password:!0},maskTextFn:oe,maskInputFn:oe,maskAttributeFn:(ce,ke,W)=>mP({maskAttributes:M,maskAllText:h,privacyOptions:We,key:ce,value:ke,el:W}),...We,slimDOMOptions:"all",inlineStylesheet:!0,inlineImages:!1,collectFonts:!0,errorHandler:ce=>{try{ce.__rrweb__=!0}catch{}}},this._initialOptions={flushMinDelay:t,flushMaxDelay:n,minReplayDuration:Math.min(r,e2),maxReplayDuration:Math.min(i,n0),stickySession:a,useCompression:c,workerUrl:d,blockAllMedia:g,maskAllInputs:y,maskAllText:h,mutationBreadcrumbLimit:w,mutationLimit:x,slowClickTimeout:_,slowClickIgnoreSelectors:E,networkDetailAllowUrls:k,networkDetailDenyUrls:O,networkCaptureBodies:R,networkRequestHeaders:g1($),networkResponseHeaders:g1(H),beforeAddRecordingEvent:ae,beforeErrorSampling:ye,onError:Ie,_experiments:f},this._initialOptions.blockAllMedia&&(this._recordingOptions.blockSelector=this._recordingOptions.blockSelector?`${this._recordingOptions.blockSelector},${h1}`:h1),this._isInitialized&&by())throw new Error("Multiple Sentry Session Replay instances are not supported");this._isInitialized=!0}get _isInitialized(){return m1}set _isInitialized(t){m1=t}afterAllSetup(t){!by()||this._replay||(this._setup(t),this._initialize(t))}start(){this._replay&&this._replay.start()}startBuffering(){this._replay&&this._replay.startBuffering()}stop(){return this._replay?this._replay.stop({forceFlush:this._replay.recordingMode==="session"}):Promise.resolve()}flush(t){return this._replay?this._replay.isEnabled()?this._replay.sendBufferedReplayOrFlush(t):(this._replay.start(),Promise.resolve()):Promise.resolve()}getReplayId(){if(!(!this._replay||!this._replay.isEnabled()))return this._replay.getSessionId()}getRecordingMode(){if(!(!this._replay||!this._replay.isEnabled()))return this._replay.recordingMode}_initialize(t){this._replay&&(this._maybeLoadFromReplayCanvasIntegration(t),this._replay.initializeSampling())}_setup(t){const n=vP(this._initialOptions,t);this._replay=new Fr({options:n,recordingOptions:this._recordingOptions})}_maybeLoadFromReplayCanvasIntegration(t){try{const n=t.getIntegrationByName("ReplayCanvas");if(!n)return;this._replay._canvas=n.getOptions()}catch{}}}$l.__initStatic();function vP(e,t){const n=t.getOptions(),r={sessionSampleRate:0,errorSampleRate:0,...dt(e)},i=Ja(n.replaysSessionSampleRate),a=Ja(n.replaysOnErrorSampleRate);return i==null&&a==null&&br(()=>{console.warn("Replay is disabled because neither `replaysSessionSampleRate` nor `replaysOnErrorSampleRate` are set.")}),i!=null&&(r.sessionSampleRate=i),a!=null&&(r.errorSampleRate=a),r}function g1(e){return[...gP,...e.map(t=>t.toLowerCase())]}const y1=new WeakMap,hf=new Map,Fl={traceFetch:!0,traceXHR:!0,enableHTTPTimings:!0,trackFetchStreamPerformance:!1};function SP(e,t){const{traceFetch:n,traceXHR:r,trackFetchStreamPerformance:i,shouldCreateSpanForRequest:a,enableHTTPTimings:c,tracePropagationTargets:d}={traceFetch:Fl.traceFetch,traceXHR:Fl.traceXHR,trackFetchStreamPerformance:Fl.trackFetchStreamPerformance,...t},f=typeof a=="function"?a:g=>!0,h=g=>xP(g,d),y={};n&&(e.addEventProcessor(g=>(g.type==="transaction"&&g.spans&&g.spans.forEach(w=>{if(w.op==="http.client"){const x=hf.get(w.span_id);x&&(w.timestamp=x/1e3,hf.delete(w.span_id))}}),g)),i&&yI(g=>{if(g.response){const w=y1.get(g.response);w&&g.endTimestamp&&hf.set(w,g.endTimestamp)}}),xy(g=>{const w=uI(g,f,h,y);if(g.response&&g.fetchData.__span&&y1.set(g.response,g.fetchData.__span),w){const x=S1(g.fetchData.url),_=x?Es(x).host:void 0;w.setAttributes({"http.url":x,"server.address":_})}c&&w&&v1(w)})),r&&Ky(g=>{const w=kP(g,f,h,y);c&&w&&v1(w)})}function wP(e){return e.entryType==="resource"&&"initiatorType"in e&&typeof e.nextHopProtocol=="string"&&(e.initiatorType==="fetch"||e.initiatorType==="xmlhttprequest")}function v1(e){const{url:t}=Fe(e).data||{};if(!t||typeof t!="string")return;const n=ho("resource",({entries:r})=>{r.forEach(i=>{wP(i)&&i.name.endsWith(t)&&(EP(i).forEach(c=>e.setAttribute(...c)),setTimeout(n))})})}function _P(e){let t="unknown",n="unknown",r="";for(const i of e){if(i==="/"){[t,n]=e.split("/");break}if(!isNaN(Number(i))){t=r==="h"?"http":r,n=e.split(r)[1];break}r+=i}return r===e&&(t=r),{name:t,version:n}}function Gn(e=0){return((zt||performance.timeOrigin)+e)/1e3}function EP(e){const{name:t,version:n}=_P(e.nextHopProtocol),r=[];return r.push(["network.protocol.version",n],["network.protocol.name",t]),zt?[...r,["http.request.redirect_start",Gn(e.redirectStart)],["http.request.fetch_start",Gn(e.fetchStart)],["http.request.domain_lookup_start",Gn(e.domainLookupStart)],["http.request.domain_lookup_end",Gn(e.domainLookupEnd)],["http.request.connect_start",Gn(e.connectStart)],["http.request.secure_connection_start",Gn(e.secureConnectionStart)],["http.request.connection_end",Gn(e.connectEnd)],["http.request.request_start",Gn(e.requestStart)],["http.request.response_start",Gn(e.responseStart)],["http.request.response_end",Gn(e.responseEnd)]]:r}function xP(e,t){const n=Se.location&&Se.location.href;if(n){let r,i;try{r=new URL(e,n),i=new URL(n).origin}catch{return!1}const a=r.origin===i;return t?Rr(r.toString(),t)||a&&Rr(r.pathname,t):a}else{const r=!!e.match(/^\/(?!\/)/);return t?Rr(e,t):r}}function kP(e,t,n,r){const i=e.xhr,a=i&&i[ks];if(!i||i.__sentry_own_request__||!a)return;const c=Nr()&&t(a.url);if(e.endTimestamp&&c){const g=i.__sentry_xhr_span_id__;if(!g)return;const w=r[g];w&&a.status_code!==void 0&&(fg(w,a.status_code),w.end(),delete r[g]);return}const d=S1(a.url),f=d?Es(d).host:void 0,h=!!vt(),y=c&&h?hi({name:`${a.method} ${a.url}`,attributes:{type:"xhr","http.method":a.method,"http.url":d,url:a.url,"server.address":f,[gt]:"auto.http.browser",[gs]:"http.client"}}):new lo;return i.__sentry_xhr_span_id__=y.spanContext().spanId,r[i.__sentry_xhr_span_id__]=y,n(a.url)&&TP(i,Nr()&&h?y:void 0),y}function TP(e,t){const{"sentry-trace":n,baggage:r}=fy({span:t});n&&bP(e,n,r)}function bP(e,t,n){try{e.setRequestHeader("sentry-trace",t),n&&e.setRequestHeader("baggage",n)}catch{}}function S1(e){try{return new URL(e,Se.location.origin).href}catch{return}}function IP(){Se&&Se.document?Se.document.addEventListener("visibilitychange",()=>{const e=vt();if(!e)return;const t=bt(e);if(Se.document.hidden&&t){const n="cancelled",{op:r,status:i}=Fe(t);qn&&X.log(`[Tracing] Transaction: ${n} -> since tab moved to the background, op: ${r}`),i||t.setStatus({code:yt,message:n}),t.setAttribute("sentry.cancellation_reason","document.hidden"),t.end()}}):qn&&X.warn("[Tracing] Could not set up background tab detection due to lack of global document")}const CP="BrowserTracing",RP={...Za,instrumentNavigation:!0,instrumentPageLoad:!0,markBackgroundSpan:!0,enableLongTask:!0,enableLongAnimationFrame:!0,enableInp:!0,_experiments:{},...Fl},AP=(e={})=>{yT();const{enableInp:t,enableLongTask:n,enableLongAnimationFrame:r,_experiments:{enableInteractions:i,enableStandaloneClsSpans:a},beforeStartSpan:c,idleTimeout:d,finalTimeout:f,childSpanTimeout:h,markBackgroundSpan:y,traceFetch:g,traceXHR:w,trackFetchStreamPerformance:x,shouldCreateSpanForRequest:_,enableHTTPTimings:E,instrumentPageLoad:k,instrumentNavigation:O}={...RP,...e},R=bC({recordClsStandaloneSpans:a||!1});t&&XC(),r&&Ne.PerformanceObserver&&PerformanceObserver.supportedEntryTypes&&PerformanceObserver.supportedEntryTypes.includes("long-animation-frame")?CC():n&&IC(),i&&RC();const $={name:void 0,source:void 0};function H(z,M){const L=M.op==="pageload",U=c?c(M):M,te=U.attributes||{};M.name!==U.name&&(te[Hn]="custom",U.attributes=te),$.name=U.name,$.source=te[Hn];const K=qg(U,{idleTimeout:d,finalTimeout:f,childSpanTimeout:h,disableAutoFinish:L,beforeSpanEnd:ae=>{R(),MC(ae,{recordClsOnPageloadSpan:!a})}});function oe(){["interactive","complete"].includes(Se.document.readyState)&&z.emit("idleSpanEnableAutoFinish",K)}return L&&Se.document&&(Se.document.addEventListener("readystatechange",()=>{oe()}),oe()),K}return{name:CP,afterAllSetup(z){let M,L=Se.location&&Se.location.href;function U(){M&&!Fe(M).timestamp&&(qn&&X.log(`[Tracing] Finishing current active span with op: ${Fe(M).op}`),M.end())}z.on("startNavigationSpan",te=>{Ae()===z&&(U(),M=H(z,{op:"navigation",...te}))}),z.on("startPageLoadSpan",(te,K={})=>{if(Ae()!==z)return;U();const oe=K.sentryTrace||w1("sentry-trace"),ae=K.baggage||w1("baggage"),ye=uT(oe,ae);Ve().setPropagationContext(ye),M=H(z,{op:"pageload",...te})}),z.on("spanEnd",te=>{const K=Fe(te).op;if(te!==bt(te)||K!=="navigation"&&K!=="pageload")return;const oe=Ve(),ae=oe.getPropagationContext();oe.setPropagationContext({...ae,sampled:ae.sampled!==void 0?ae.sampled:vs(te),dsc:ae.dsc||ws(te)})}),Se.location&&(k&&OP(z,{name:Se.location.pathname,startTime:zt?zt/1e3:void 0,attributes:{[Hn]:"url",[gt]:"auto.pageload.browser"}}),O&&hl(({to:te,from:K})=>{if(K===void 0&&L&&L.indexOf(te)!==-1){L=void 0;return}K!==te&&(L=void 0,PP(z,{name:Se.location.pathname,attributes:{[Hn]:"url",[gt]:"auto.navigation.browser"}}))})),y&&IP(),i&&NP(d,f,h,$),t&&ZC(),SP(z,{traceFetch:g,traceXHR:w,trackFetchStreamPerformance:x,tracePropagationTargets:z.getOptions().tracePropagationTargets,shouldCreateSpanForRequest:_,enableHTTPTimings:E})}}};function OP(e,t,n){e.emit("startPageLoadSpan",t,n),Ve().setTransactionName(t.name);const r=vt();return(r&&Fe(r).op)==="pageload"?r:void 0}function PP(e,t){Cn().setPropagationContext({traceId:Or()}),Ve().setPropagationContext({traceId:Or()}),e.emit("startNavigationSpan",t),Ve().setTransactionName(t.name);const n=vt();return(n&&Fe(n).op)==="navigation"?n:void 0}function w1(e){const t=jk(`meta[name=${e}]`);return t?t.getAttribute("content"):void 0}function NP(e,t,n,r){let i;const a=()=>{const c="ui.action.click",d=vt(),f=d&&bt(d);if(f){const h=Fe(f).op;if(["navigation","pageload"].includes(h)){qn&&X.warn(`[Tracing] Did not create ${c} span because a pageload or navigation span is in progress.`);return}}if(i&&(i.setAttribute(rd,"interactionInterrupted"),i.end(),i=void 0),!r.name){qn&&X.warn(`[Tracing] Did not create ${c} transaction because _latestRouteName is missing.`);return}i=qg({name:r.name,op:c,attributes:{[Hn]:r.source||"url"}},{idleTimeout:e,finalTimeout:t,childSpanTimeout:n})};Se.document&&addEventListener("click",a,{once:!1,capture:!0})}function MP(e){const t={...e};return dy(t,"react"),Qg("react",{version:C.version}),UR(t)}const LP=async e=>{try{return await $P(e),kr.reportNewUserCreated(),e}catch(t){throw console.error("User haven't been registered"),t}},_1=e=>LP(e).then(()=>{mf(e)}).catch(t=>{jP()}),fr=async()=>{const e=bo();if(e)return e;const t=xr(13);return await _1(t),mf(t),t},Bl=()=>{const e=bo();if(e)return e;const t=xr(13);return mf(t),_1(t),t},mf=e=>localStorage.setItem(gn.userId,e),bo=()=>localStorage.getItem(gn.userId),jP=()=>{localStorage.removeItem(gn.userId)},DP=async()=>bo()??"dafult-user",$P=async e=>{var r,i;const n=(((r=window.__widgetEdmap)==null?void 0:r.mode)||"default")==="admin"?"/registration/auto-disposable?seconds=32400":"/registration/auto";try{const a=await ut.post(n,{id:e});return(i=a==null?void 0:a.data)==null?void 0:i.id}catch(a){throw console.error("Error registering new user:",a),a}},FP=async()=>{var i,a;const e=(i=window==null?void 0:window.__widgetEdmap)==null?void 0:i.mapId;if(!e)return;const t=`/registration/telegram/${e}`,n=await fr(),r=window.location.href;try{const c=await ut.post(t,{redirectUrl:r,userId:n});(c==null?void 0:c.status)===201&&(window.location.href=(a=c==null?void 0:c.data)==null?void 0:a.link)}catch(c){An(c),console.error("Error registering new user through telegram",c)}},BP=async e=>{const t="/auth/telegram";try{const n=await ut.post(t,{code:e});(n==null?void 0:n.status)===201&&E1(n==null?void 0:n.data)}catch(n){An(n),console.error("Failed to authorize through Telegram",n)}},zP=async()=>{var a;const e=(a=window==null?void 0:window.__widgetEdmap)==null?void 0:a.mapId,t=bo(),n=encodeURIComponent(window.location.href);if(!e)return;const r=new URLSearchParams;r.append("mapId",e),r.append("userId",t),r.append("redirectUrl",n);const i=`/auth/google?${r.toString()}`;try{const c=await ut.get(i);window.location.href=c.data.redirectUrl}catch(c){An(c),console.error("Error registering new user through gmail",c)}},UP=async()=>{const e=new URLSearchParams(window.location.search),t=e.get("accessToken"),n=e.get("refreshToken"),r=e.get("userId");!t||!n||!r||E1({accessToken:t,refreshToken:n,userId:r})},E1=e=>{kr.reportUserRegistration(),localStorage.setItem(gn.userId,e==null?void 0:e.userId),localStorage.setItem("edmap-access-token",e==null?void 0:e.accessToken),localStorage.setItem("edmap-refresh-token",e==null?void 0:e.refreshToken)},HP=e=>{if(!e)return"edmap-session-prob";const t=xr(13),n=`edmap-session-${e}`;return localStorage.setItem(n,`${t}@${Date.now()}`),t},x1=e=>{const t=`edmap-session-${e}`;localStorage.removeItem(t)},WP=e=>{const t=localStorage.getItem(`edmap-session-${e}`);return t||null},Is=e=>{const t=qP(e),[n,r]=t.split("@");return n},qP=e=>{const t=localStorage.getItem(`edmap-session-${e}`);return t||HP(e)},VP=async(e,t)=>{t&&await BP(t);const n=new URLSearchParams(window.location.search),r=n.get("accessToken"),i=n.get("refreshToken"),a=n.get("userId");r&&i&&a&&await UP();const c=await DP();return T1(e,c)},k1=()=>typeof window>"u"?!1:!!localStorage.getItem("edmap-access-token"),GP=async(e,t)=>{const n=`/quest/${e}/${encodeURIComponent(t)}`;try{const r=await ut.get(n);return r.data?r.data:null}catch{return null}},YP=async e=>{const t=`/quest/widget/${e}`;try{const n=await ut.get(t);return n.data?n.data:null}catch(n){An(n),console.error("Error fetching quest:",n)}},KP=async e=>{const t="/result-quest-answer/test";try{return await ut.post(t,{id:xr(13),sessionId:Is(e.id),questId:e.id,mapId:e.mapId,userId:await fr()})}catch(n){throw console.error("Failed to send result test answers:",n),n}},T1=async(e,t)=>{const n=`/user-result/${e}/${t}`;try{return(await ut.get(n)).data}catch(r){An(r),console.error("Failed to get user results:",r)}},QP=async(e,t,n)=>{const r=`/leaderboard/${e}`;try{return await ut.get(r,{params:{take:t,skip:n}})}catch(i){An(i),console.error("Failed to fetch leaderboard:",i)}},b1=e=>{let t;const n=new Set,r=(h,y)=>{const g=typeof h=="function"?h(t):h;if(!Object.is(g,t)){const w=t;t=y??(typeof g!="object"||g===null)?g:Object.assign({},t,g),n.forEach(x=>x(t,w))}},i=()=>t,d={setState:r,getState:i,getInitialState:()=>f,subscribe:h=>(n.add(h),()=>n.delete(h))},f=t=e(r,i,d);return d},XP=e=>e?b1(e):b1,JP=e=>e;function ZP(e,t=JP){const n=Tt.useSyncExternalStore(e.subscribe,()=>t(e.getState()),()=>t(e.getInitialState()));return Tt.useDebugValue(n),n}const I1=e=>{const t=XP(e),n=r=>ZP(t,r);return Object.assign(n,t),n},eN=e=>e?I1(e):I1,C1=new Set,tN=()=>{C1.forEach(e=>e())},Nt=e=>{const t=eN(e),n=t.getState();return C1.add(()=>t.setState(n,!0)),t},Me=Nt((e,t)=>({quest:{},stepCount:0,currentStep:0,currentTryPoints:0,isFinished:null,mapLeaderboard:[],isError:!1,resetQuest:()=>e({currentTryPoints:0,isFinished:!1}),increaseCurrentStep:()=>e({currentStep:t().currentStep+1}),setQuest:n=>e({quest:n}),setIsFinished:n=>e({isFinished:n}),setMapLeaderboard:n=>e({mapLeaderboard:n}),setCurrentTryPoints:n=>e({currentTryPoints:n}),setIsError:n=>e({isError:n})})),gf="eddpzuabl",R1="edl168snjk",nN="edwbmletw",A1="edr10i0h72",yf="edn16xylqg",rN="edb19h1gx0",O1="edt1n7onvl",sN="edw16bh3dw",oN="edw1j9fzy2";function iN(e){var t=Object.create(null);return function(n){return t[n]===void 0&&(t[n]=e(n)),t[n]}}var aN=/^((children|dangerouslySetInnerHTML|key|ref|autoFocus|defaultValue|defaultChecked|innerHTML|suppressContentEditableWarning|suppressHydrationWarning|valueLink|abbr|accept|acceptCharset|accessKey|action|allow|allowUserMedia|allowPaymentRequest|allowFullScreen|allowTransparency|alt|async|autoComplete|autoPlay|capture|cellPadding|cellSpacing|challenge|charSet|checked|cite|classID|className|cols|colSpan|content|contentEditable|contextMenu|controls|controlsList|coords|crossOrigin|data|dateTime|decoding|default|defer|dir|disabled|disablePictureInPicture|disableRemotePlayback|download|draggable|encType|enterKeyHint|fetchpriority|fetchPriority|form|formAction|formEncType|formMethod|formNoValidate|formTarget|frameBorder|headers|height|hidden|high|href|hrefLang|htmlFor|httpEquiv|id|inputMode|integrity|is|keyParams|keyType|kind|label|lang|list|loading|loop|low|marginHeight|marginWidth|max|maxLength|media|mediaGroup|method|min|minLength|multiple|muted|name|nonce|noValidate|open|optimum|pattern|placeholder|playsInline|poster|preload|profile|radioGroup|readOnly|referrerPolicy|rel|required|reversed|role|rows|rowSpan|sandbox|scope|scoped|scrolling|seamless|selected|shape|size|sizes|slot|span|spellCheck|src|srcDoc|srcLang|srcSet|start|step|style|summary|tabIndex|target|title|translate|type|useMap|value|width|wmode|wrap|about|datatype|inlist|prefix|property|resource|typeof|vocab|autoCapitalize|autoCorrect|autoSave|color|incremental|fallback|inert|itemProp|itemScope|itemType|itemID|itemRef|on|option|results|security|unselectable|accentHeight|accumulate|additive|alignmentBaseline|allowReorder|alphabetic|amplitude|arabicForm|ascent|attributeName|attributeType|autoReverse|azimuth|baseFrequency|baselineShift|baseProfile|bbox|begin|bias|by|calcMode|capHeight|clip|clipPathUnits|clipPath|clipRule|colorInterpolation|colorInterpolationFilters|colorProfile|colorRendering|contentScriptType|contentStyleType|cursor|cx|cy|d|decelerate|descent|diffuseConstant|direction|display|divisor|dominantBaseline|dur|dx|dy|edgeMode|elevation|enableBackground|end|exponent|externalResourcesRequired|fill|fillOpacity|fillRule|filter|filterRes|filterUnits|floodColor|floodOpacity|focusable|fontFamily|fontSize|fontSizeAdjust|fontStretch|fontStyle|fontVariant|fontWeight|format|from|fr|fx|fy|g1|g2|glyphName|glyphOrientationHorizontal|glyphOrientationVertical|glyphRef|gradientTransform|gradientUnits|hanging|horizAdvX|horizOriginX|ideographic|imageRendering|in|in2|intercept|k|k1|k2|k3|k4|kernelMatrix|kernelUnitLength|kerning|keyPoints|keySplines|keyTimes|lengthAdjust|letterSpacing|lightingColor|limitingConeAngle|local|markerEnd|markerMid|markerStart|markerHeight|markerUnits|markerWidth|mask|maskContentUnits|maskUnits|mathematical|mode|numOctaves|offset|opacity|operator|order|orient|orientation|origin|overflow|overlinePosition|overlineThickness|panose1|paintOrder|pathLength|patternContentUnits|patternTransform|patternUnits|pointerEvents|points|pointsAtX|pointsAtY|pointsAtZ|preserveAlpha|preserveAspectRatio|primitiveUnits|r|radius|refX|refY|renderingIntent|repeatCount|repeatDur|requiredExtensions|requiredFeatures|restart|result|rotate|rx|ry|scale|seed|shapeRendering|slope|spacing|specularConstant|specularExponent|speed|spreadMethod|startOffset|stdDeviation|stemh|stemv|stitchTiles|stopColor|stopOpacity|strikethroughPosition|strikethroughThickness|string|stroke|strokeDasharray|strokeDashoffset|strokeLinecap|strokeLinejoin|strokeMiterlimit|strokeOpacity|strokeWidth|surfaceScale|systemLanguage|tableValues|targetX|targetY|textAnchor|textDecoration|textRendering|textLength|to|transform|u1|u2|underlinePosition|underlineThickness|unicode|unicodeBidi|unicodeRange|unitsPerEm|vAlphabetic|vHanging|vIdeographic|vMathematical|values|vectorEffect|version|vertAdvY|vertOriginX|vertOriginY|viewBox|viewTarget|visibility|widths|wordSpacing|writingMode|x|xHeight|x1|x2|xChannelSelector|xlinkActuate|xlinkArcrole|xlinkHref|xlinkRole|xlinkShow|xlinkTitle|xlinkType|xmlBase|xmlns|xmlnsXlink|xmlLang|xmlSpace|y|y1|y2|yChannelSelector|z|zoomAndPan|for|class|autofocus)|(([Dd][Aa][Tt][Aa]|[Aa][Rr][Ii][Aa]|x)-.*))$/,vf=iN(function(e){return aN.test(e)||e.charCodeAt(0)===111&&e.charCodeAt(1)===110&&e.charCodeAt(2)<91}),lN=function(){const t=Array.prototype.slice.call(arguments).filter(Boolean),n={},r=[];t.forEach(a=>{(a?a.split(" "):[]).forEach(d=>{if(d.startsWith("atm_")){const[,f]=d.split("_");n[f]=d}else r.push(d)})});const i=[];for(const a in n)Object.prototype.hasOwnProperty.call(n,a)&&i.push(n[a]);return i.push(...r),i.join(" ")},P1=lN,cN=e=>e.toUpperCase()===e,uN=e=>t=>e.indexOf(t)===-1,N1=(e,t)=>{const n={};return Object.keys(e).filter(uN(t)).forEach(r=>{n[r]=e[r]}),n};function dN(e,t,n){const r=N1(t,n);if(!e){const i=typeof vf=="function"?{default:vf}:vf;Object.keys(r).forEach(a=>{i.default(a)||delete r[a]})}return r}var fN=(e,t)=>{};function pN(e){let t="";return n=>{const r=(a,c)=>{const{as:d=e,class:f=t}=a,h=n.propsAsIs===void 0?!(typeof d=="string"&&d.indexOf("-")===-1&&!cN(d[0])):n.propsAsIs,y=dN(h,a,["as","class"]);y.ref=c,y.className=n.atomic?P1(n.class,y.className||f):P1(y.className||f,n.class);const{vars:g}=n;if(g){const w={};for(const E in g){const k=g[E],O=k[0],R=k[1]||"",$=typeof O=="function"?O(a):O;fN($,n.name),w[`--${E}`]=`${$}${R}`}const x=y.style||{},_=Object.keys(x);_.length>0&&_.forEach(E=>{w[E]=x[E]}),y.style=w}return e.__wyw_meta&&e!==d?(y.as=d,Tt.createElement(e,y)):Tt.createElement(d,y)},i=Tt.forwardRef?Tt.forwardRef(r):a=>{const c=N1(a,["innerRef"]);return r(c,a.innerRef)};return i.displayName=n.name,i.__wyw_meta={className:n.class||t,extends:e},i}}var j=pN;const hN=j("div")({name:"Container",class:"edc2mc3o7",propsAsIs:!1}),mN=j("div")({name:"ContentWrapper",class:"edc1mezuql",propsAsIs:!1}),M1=j("div")({name:"InfoBlock",class:"edi282h0s",propsAsIs:!1}),L1=j("p")({name:"InfoBlockTitle",class:"edi1hvj2ef",propsAsIs:!1}),j1=j("p")({name:"InfoBlockSubtitle",class:"edil1zahd",propsAsIs:!1}),D1=j("div")({name:"ButtonsWrapper",class:"edb19bodzu",propsAsIs:!1}),gN=j("div")({name:"SignInBlock",class:"eds1kockd",propsAsIs:!1}),yN=j("div")({name:"MenuSection",class:"edm1mglzga",propsAsIs:!1}),vN=j("div")({name:"Container",class:"edc1j8vq8z",propsAsIs:!1}),SN=j("ul")({name:"Nav",class:"edn1cd6joy",propsAsIs:!1}),wN=()=>e=>e.isActive?"var(--accent)":"var(--popup-menu-tabs)",_N=()=>e=>e.isActive?"var(--accent)":"var(--popup-menu-tabs-font-hover)",EN=j("li")({name:"NavItem",class:"edn1fabm11",propsAsIs:!1,vars:{"n1fabm11-0":[wN()],"n1fabm11-1":[_N()]}}),$1=e=>({...e,prizes:xN(e)}),xN=e=>{var t,n;return[...(t=e.receivedPrizes)==null?void 0:t.map(kN).map(r=>F1(r,!0)),...(n=e.restPrizes)==null?void 0:n.map(r=>F1(r,!1))]},kN=e=>({...e,...e.prize,id:e.id}),F1=(e,t=!0)=>({...e,isReceived:t}),Ct=Nt(e=>({points:0,results:{},pointsAreReceived:!1,resetUser:()=>e({pointsAreReceived:!1}),setUserPoints:t=>e(n=>({points:n.points+t})),setUserResults:t=>e({results:$1(t)}),setPointsAreReceived:t=>e({pointsAreReceived:t}),refreshUserResults:async t=>{const n=await fr(),r=await T1(t,n);e({results:$1(r)})}})),TN=({data:e,activeIndex:t,setActiveIndex:n})=>{var a;const r=Ct(c=>c.results),i=(a=r==null?void 0:r.prizes)==null?void 0:a.length;return v.jsx(vN,{children:v.jsx(SN,{children:e.map((c,d)=>v.jsxs(EN,{onClick:()=>n(d),isActive:d===t,children:[c,d===0&&v.jsx("span",{children:i})]},c))})})},bN=j("div")({name:"Container",class:"edc17us64y",propsAsIs:!1}),B1=j("div")({name:"Header",class:"edh141t6pe",propsAsIs:!1}),z1=j("div")({name:"PrizeBackground",class:"edp1oopuya",propsAsIs:!1}),U1=j("div")({name:"Title",class:"edtlw5k9f",propsAsIs:!1}),IN=j("div")({name:"ButtonWrapper",class:"edbggxr7n",propsAsIs:!1}),CN=j("div")({name:"IconButtonWrapper",class:"edi16rf10j",propsAsIs:!1}),RN=j("div")({name:"ProgressWrapper",class:"edp121tjyk",propsAsIs:!1}),AN=e=>C.createElement("svg",{xmlns:"http://www.w3.org/2000/svg",width:24,height:24,fill:"none",...e},C.createElement("path",{fill:"currentColor",d:"M13 10v9h-2v-9zm0-5v2h-2V5z"}));function ON(e){var t=Object.create(null);return function(n){return t[n]===void 0&&(t[n]=e(n)),t[n]}}var PN=/^((children|dangerouslySetInnerHTML|key|ref|autoFocus|defaultValue|defaultChecked|innerHTML|suppressContentEditableWarning|suppressHydrationWarning|valueLink|abbr|accept|acceptCharset|accessKey|action|allow|allowUserMedia|allowPaymentRequest|allowFullScreen|allowTransparency|alt|async|autoComplete|autoPlay|capture|cellPadding|cellSpacing|challenge|charSet|checked|cite|classID|className|cols|colSpan|content|contentEditable|contextMenu|controls|controlsList|coords|crossOrigin|data|dateTime|decoding|default|defer|dir|disabled|disablePictureInPicture|disableRemotePlayback|download|draggable|encType|enterKeyHint|fetchpriority|fetchPriority|form|formAction|formEncType|formMethod|formNoValidate|formTarget|frameBorder|headers|height|hidden|high|href|hrefLang|htmlFor|httpEquiv|id|inputMode|integrity|is|keyParams|keyType|kind|label|lang|list|loading|loop|low|marginHeight|marginWidth|max|maxLength|media|mediaGroup|method|min|minLength|multiple|muted|name|nonce|noValidate|open|optimum|pattern|placeholder|playsInline|poster|preload|profile|radioGroup|readOnly|referrerPolicy|rel|required|reversed|role|rows|rowSpan|sandbox|scope|scoped|scrolling|seamless|selected|shape|size|sizes|slot|span|spellCheck|src|srcDoc|srcLang|srcSet|start|step|style|summary|tabIndex|target|title|translate|type|useMap|value|width|wmode|wrap|about|datatype|inlist|prefix|property|resource|typeof|vocab|autoCapitalize|autoCorrect|autoSave|color|incremental|fallback|inert|itemProp|itemScope|itemType|itemID|itemRef|on|option|results|security|unselectable|accentHeight|accumulate|additive|alignmentBaseline|allowReorder|alphabetic|amplitude|arabicForm|ascent|attributeName|attributeType|autoReverse|azimuth|baseFrequency|baselineShift|baseProfile|bbox|begin|bias|by|calcMode|capHeight|clip|clipPathUnits|clipPath|clipRule|colorInterpolation|colorInterpolationFilters|colorProfile|colorRendering|contentScriptType|contentStyleType|cursor|cx|cy|d|decelerate|descent|diffuseConstant|direction|display|divisor|dominantBaseline|dur|dx|dy|edgeMode|elevation|enableBackground|end|exponent|externalResourcesRequired|fill|fillOpacity|fillRule|filter|filterRes|filterUnits|floodColor|floodOpacity|focusable|fontFamily|fontSize|fontSizeAdjust|fontStretch|fontStyle|fontVariant|fontWeight|format|from|fr|fx|fy|g1|g2|glyphName|glyphOrientationHorizontal|glyphOrientationVertical|glyphRef|gradientTransform|gradientUnits|hanging|horizAdvX|horizOriginX|ideographic|imageRendering|in|in2|intercept|k|k1|k2|k3|k4|kernelMatrix|kernelUnitLength|kerning|keyPoints|keySplines|keyTimes|lengthAdjust|letterSpacing|lightingColor|limitingConeAngle|local|markerEnd|markerMid|markerStart|markerHeight|markerUnits|markerWidth|mask|maskContentUnits|maskUnits|mathematical|mode|numOctaves|offset|opacity|operator|order|orient|orientation|origin|overflow|overlinePosition|overlineThickness|panose1|paintOrder|pathLength|patternContentUnits|patternTransform|patternUnits|pointerEvents|points|pointsAtX|pointsAtY|pointsAtZ|preserveAlpha|preserveAspectRatio|primitiveUnits|r|radius|refX|refY|renderingIntent|repeatCount|repeatDur|requiredExtensions|requiredFeatures|restart|result|rotate|rx|ry|scale|seed|shapeRendering|slope|spacing|specularConstant|specularExponent|speed|spreadMethod|startOffset|stdDeviation|stemh|stemv|stitchTiles|stopColor|stopOpacity|strikethroughPosition|strikethroughThickness|string|stroke|strokeDasharray|strokeDashoffset|strokeLinecap|strokeLinejoin|strokeMiterlimit|strokeOpacity|strokeWidth|surfaceScale|systemLanguage|tableValues|targetX|targetY|textAnchor|textDecoration|textRendering|textLength|to|transform|u1|u2|underlinePosition|underlineThickness|unicode|unicodeBidi|unicodeRange|unitsPerEm|vAlphabetic|vHanging|vIdeographic|vMathematical|values|vectorEffect|version|vertAdvY|vertOriginX|vertOriginY|viewBox|viewTarget|visibility|widths|wordSpacing|writingMode|x|xHeight|x1|x2|xChannelSelector|xlinkActuate|xlinkArcrole|xlinkHref|xlinkRole|xlinkShow|xlinkTitle|xlinkType|xmlBase|xmlns|xmlnsXlink|xmlLang|xmlSpace|y|y1|y2|yChannelSelector|z|zoomAndPan|for|class|autofocus)|(([Dd][Aa][Tt][Aa]|[Aa][Rr][Ii][Aa]|x)-.*))$/,Sf=ON(function(e){return PN.test(e)||e.charCodeAt(0)===111&&e.charCodeAt(1)===110&&e.charCodeAt(2)<91}),NN=function(){const t=Array.prototype.slice.call(arguments).filter(Boolean),n={},r=[];t.forEach(a=>{(a?a.split(" "):[]).forEach(d=>{if(d.startsWith("atm_")){const[,f]=d.split("_");n[f]=d}else r.push(d)})});const i=[];for(const a in n)Object.prototype.hasOwnProperty.call(n,a)&&i.push(n[a]);return i.push(...r),i.join(" ")},H1=NN,MN=e=>e.toUpperCase()===e,LN=e=>t=>e.indexOf(t)===-1,W1=(e,t)=>{const n={};return Object.keys(e).filter(LN(t)).forEach(r=>{n[r]=e[r]}),n};function jN(e,t,n){const r=W1(t,n);if(!e){const i=typeof Sf=="function"?{default:Sf}:Sf;Object.keys(r).forEach(a=>{i.default(a)||delete r[a]})}return r}var DN=(e,t)=>{};function $N(e){let t="";return n=>{const r=(a,c)=>{const{as:d=e,class:f=t}=a,h=n.propsAsIs===void 0?!(typeof d=="string"&&d.indexOf("-")===-1&&!MN(d[0])):n.propsAsIs,y=jN(h,a,["as","class"]);y.ref=c,y.className=n.atomic?H1(n.class,y.className||f):H1(y.className||f,n.class);const{vars:g}=n;if(g){const w={};for(const E in g){const k=g[E],O=k[0],R=k[1]||"",$=typeof O=="function"?O(a):O;DN($,n.name),w[`--${E}`]=`${$}${R}`}const x=y.style||{},_=Object.keys(x);_.length>0&&_.forEach(E=>{w[E]=x[E]}),y.style=w}return e.__wyw_meta&&e!==d?(y.as=d,Tt.createElement(e,y)):Tt.createElement(d,y)},i=Tt.forwardRef?Tt.forwardRef(r):a=>{const c=W1(a,["innerRef"]);return r(c,a.innerRef)};return i.displayName=n.name,i.__wyw_meta={className:n.class||t,extends:e},i}}var Z=$N;const q1=Z("button")({name:"ColoredButton",class:"edc1h8okqi",propsAsIs:!1}),wf=Z(q1)({name:"Button",class:"edbym73sg",propsAsIs:!0}),V1=({icon:e,title:t,...n})=>v.jsx(FN,{...n,children:e||t}),FN=Z(wf)({name:"CustomButton",class:"edc1r5q1nu",propsAsIs:!0}),wn=({title:e,isAccent:t,isSuccess:n,link:r,target:i="_blank",linkProps:a,...c})=>r?v.jsx("a",{target:i,href:r,rel:i==="_blank"&&"noopener noreferrer",...a,children:v.jsx(G1,{isAccent:t,...c,children:e})}):v.jsx(G1,{isAccent:t,...c,children:e}),BN=()=>e=>e.isAccent?"var(--main-btn-accent-bg)":"var(--main-btn-bg)",zN=()=>e=>e.isAccent?"900":"400",UN=()=>e=>e.isAccent?"var(--edmap-text-on-main)":"var(--accent)",HN=()=>e=>e.isAccent?"var(--main-btn-accent-bg-hover)":"var(--main-btn-bg-hover)",WN=()=>e=>e.isAccent?"var(--main-btn-accent-bg-active)":"var(--main-btn-bg-active)",G1=Z("button")({name:"Button",class:"edb16ruis3",propsAsIs:!1,vars:{"b16ruis3-0":[BN()],"b16ruis3-1":[zN()],"b16ruis3-2":[UN()],"b16ruis3-3":[HN()],"b16ruis3-4":[WN()]}}),zl=({progressValue:e,overallValue:t})=>{const n=e<=t?(100/t*e).toFixed(0):100;return v.jsx(VN,{progressBarWidth:n})},qN=()=>e=>`${e.progressBarWidth}%`,VN=Z("div")({name:"Bar",class:"edb1pz075f",propsAsIs:!1,vars:{"b1pz075f-0":[qN()]}}),Cs=({progressValue:e,overallValue:t,text:n})=>v.jsxs(GN,{children:[v.jsx("span",{children:e}),v.jsxs("span",{children:["/",t," "]}),n&&v.jsx(YN,{children:n})]}),GN=Z("div")({name:"Container",class:"edc1sl84gi",propsAsIs:!1}),YN=Z("span")({name:"PointsText",class:"edpccfrec",propsAsIs:!1}),KN=()=>v.jsx("svg",{viewBox:"0 0 30 30",xmlns:"http://www.w3.org/2000/svg",children:v.jsx("g",{"data-name":"Layer 2",id:"Layer_2",children:v.jsx("g",{id:"Interface-Light",children:v.jsxs("g",{id:"interface-light-rating-stars-1",children:[v.jsx("path",{d:"M15.78,14.07l1.46,4.14a.82.82,0,0,0,.74.56L22.2,19a.87.87,0,0,1,.48,1.54l-3.31,2.74a.9.9,0,0,0-.29.91l1.15,4.26a.84.84,0,0,1-1.26,1L15.46,26.9a.78.78,0,0,0-.92,0L11,29.35a.84.84,0,0,1-1.26-1l1.15-4.26a.9.9,0,0,0-.29-.91L7.32,20.49A.87.87,0,0,1,7.8,19L12,18.77a.82.82,0,0,0,.74-.56l1.46-4.14A.82.82,0,0,1,15.78,14.07Z",fill:"none",stroke:"currentColor",strokeLinecap:"round",strokeLinejoin:"round"}),v.jsx("path",{d:"M7.08.92,8.18,4a.63.63,0,0,0,.56.43l3.16.13a.65.65,0,0,1,.36,1.16L9.78,7.8a.65.65,0,0,0-.22.68l.86,3.19a.63.63,0,0,1-.94.72L6.84,10.55a.57.57,0,0,0-.68,0L3.52,12.39a.63.63,0,0,1-.94-.72l.86-3.19a.65.65,0,0,0-.22-.68l-2.48-2A.65.65,0,0,1,1.1,4.59l3.16-.13A.63.63,0,0,0,4.82,4L5.92.92A.61.61,0,0,1,7.08.92Z",fill:"none",stroke:"currentColor",strokeLinecap:"round",strokeLinejoin:"round"}),v.jsx("path",{d:"M24.08.92,25.18,4a.63.63,0,0,0,.56.43l3.16.13a.65.65,0,0,1,.36,1.16L26.78,7.8a.65.65,0,0,0-.22.68l.86,3.19a.63.63,0,0,1-.94.72l-2.64-1.84a.57.57,0,0,0-.68,0l-2.64,1.84a.63.63,0,0,1-.94-.72l.86-3.19a.65.65,0,0,0-.22-.68l-2.48-2a.65.65,0,0,1,.36-1.16l3.16-.13A.63.63,0,0,0,21.82,4L22.92.92A.61.61,0,0,1,24.08.92Z",fill:"none",stroke:"currentColor",strokeLinecap:"round",strokeLinejoin:"round"})]})})})}),QN=()=>v.jsxs("svg",{viewBox:"-4 0 30 30",xmlns:"http://www.w3.org/2000/svg",children:[v.jsx("defs",{children:v.jsx("style",{children:".cls-1{fill:none;stroke:currentColor;stroke-linecap:round;stroke-linejoin:round;}"})}),v.jsx("title",{children:"Award Medal"}),v.jsx("g",{"data-name":"Layer 2",id:"Layer_2",children:v.jsx("g",{id:"Interface-Light",children:v.jsxs("g",{id:"interface-light-award-medal-1",children:[v.jsx("polyline",{className:"cls-1",points:"21.5 0.5 10.5 0.5 0.5 0.5"}),v.jsx("line",{className:"cls-1",x1:"21.5",x2:"17",y1:"0.5",y2:"12.5"}),v.jsx("line",{className:"cls-1",x1:"0.5",x2:"5",y1:"0.5",y2:"12.5"}),v.jsx("circle",{className:"cls-1",cx:"11",cy:"20",r:"9.5"}),v.jsx("line",{className:"cls-1",x1:"8",x2:"9",y1:"0.5",y2:"10.5"}),v.jsx("line",{className:"cls-1",x1:"14",x2:"13",y1:"0.5",y2:"10.5"}),v.jsx("path",{className:"cls-1",d:"M11.49,15.35l.91,2.59a.52.52,0,0,0,.46.36l2.64.11a.54.54,0,0,1,.3,1l-2.07,1.71a.58.58,0,0,0-.18.57l.72,2.66a.53.53,0,0,1-.79.6l-2.19-1.54a.51.51,0,0,0-.58,0L8.52,24.91a.53.53,0,0,1-.79-.6l.72-2.66a.58.58,0,0,0-.18-.57L6.2,19.37a.54.54,0,0,1,.3-1l2.64-.11a.52.52,0,0,0,.46-.36l.91-2.59A.52.52,0,0,1,11.49,15.35Z"})]})})})]}),XN=()=>v.jsxs("svg",{viewBox:"-0.5 0 30 30",xmlns:"http://www.w3.org/2000/svg",children:[v.jsx("defs",{children:v.jsx("style",{children:".cls-1{fill:none;stroke:currentColor;stroke-linecap:round;stroke-linejoin:round;}"})}),v.jsx("title",{children:"Award Trophie"}),v.jsx("g",{"data-name":"Layer 2",id:"Layer_2",children:v.jsx("g",{id:"Interface-Light",children:v.jsxs("g",{id:"interface-light-award-trophie",children:[v.jsx("path",{className:"cls-1",d:"M9.5.5h-6c0,7.73,4.92,14,11,14s11-6.27,11-14h-6"}),v.jsx("rect",{className:"cls-1",height:"5",rx:"1",width:"13",x:"8",y:"24.5"}),v.jsx("line",{className:"cls-1",x1:"12.5",x2:"12.5",y1:"14.3",y2:"24.5"}),v.jsx("line",{className:"cls-1",x1:"16.5",x2:"16.5",y1:"14.3",y2:"24.5"}),v.jsx("path",{className:"cls-1",d:"M25.1,4.5a3.36,3.36,0,0,1,3.4,3c0,1.66-1.34,5-3,5"}),v.jsx("path",{className:"cls-1",d:"M3.5,12.5c-1.66,0-3-3.34-3-5a3.36,3.36,0,0,1,3.4-3"}),v.jsx("path",{className:"cls-1",d:"M15,.85l.91,2.59a.52.52,0,0,0,.46.36L19,3.91a.54.54,0,0,1,.3,1L17.23,6.58a.58.58,0,0,0-.18.57l.72,2.66a.53.53,0,0,1-.79.6L14.79,8.87a.51.51,0,0,0-.58,0L12,10.41a.53.53,0,0,1-.79-.6L12,7.15a.58.58,0,0,0-.18-.57L9.7,4.87a.54.54,0,0,1,.3-1l2.64-.11a.52.52,0,0,0,.46-.36L14,.85A.52.52,0,0,1,15,.85Z"})]})})})]}),JN={1:v.jsx(KN,{}),2:v.jsx(QN,{}),3:v.jsx(XN,{})},ZN=Z("div")({name:"InnerIconContainer",class:"edim3awnl",propsAsIs:!1}),Y1=({iconId:e,...t})=>v.jsx(ZN,{...t,children:JN[e]}),Ul={es:{timer:{remainingTitle:"Límite de tiempo:"},popup:{skillsTitle:"experiencia",menuItems:["Premios","Misiones","Participantes","Configuración"],prizes:{buttonTitle:"Obtener premio",questionsTitle:"puntos"}},gameMenu:{restart:"Empezar de nuevo"},share:{share:"Compartir",downloadFallback:"Descargar"},popupBar:{prizesTitle:"premios",skillsTitle:"exp"},widget:{skillsTitle:"experiencia",accentButtonTitle:"Confirmar respuesta",buttonTitle:"Omitir"},preloader:{text:"El modelo está pensando"},input:{placeholder:"Introduzca texto…"},testCard:{successTitle:"Has aprobado el test",buttonTitle:"Volver a intentar",worstScoreTemplate:"Has obtenido <mark>{points} de {maxPoints}</mark> puntos. Tu mejor resultado es <mark>{bestPoints} de {maxPoints}</mark>.",bestScoreTemplate:"Has obtenido <mark>{bestPoints} de {maxPoints}</mark> puntos.",prizesTitle:"Premios que aún puedes conseguir",questsTitle:"Misiones que aún puedes completar",chooseAnswer:"Seleccione todas las respuestas que correspondan de la lista:"},journeyCard:{successTitle:"Has completado el juego",buttonTitle:"Volver a jugar",worstScoreTemplate:"Has obtenido <mark>{points} de {maxPoints}</mark> puntos. Tu mejor resultado es <mark>{bestPoints} de {maxPoints}</mark>.",bestScoreTemplate:"Has obtenido <mark>{bestPoints} de {maxPoints}</mark> puntos.",prizesTitle:"Premios que aún puedes conseguir",questsTitle:"Misiones que aún puedes completar",chooseAnswer:"Seleccione una respuesta:"},settings:{signInPopup:{title:"Para guardar tu progreso y obtener premios, necesitas registrar una cuenta.",subtitle:"¡Tu progreso se transferirá a ella!",buttonTitle:"Cerrar",accentButtonTitle:"Registrarse"},logout:"Cerrar sesión"},globalError:{title:"Algo salió mal 🤔",subtitle:"Mientras pensamos cómo solucionarlo, puedes intentar actualizar la misión"},socialsPopup:{title:"Registrarse con",subTitle:"Próximamente...",telegram:{title:"Telegram"},google:{title:"Google"},discord:{title:"Discord"}},footer:{buttonTitle:"Omitir",accentButtonTitle:"Confirmar respuesta"},header:{title:"Semana gratuita de entrenamiento en el plan «Erich Fromm»",progressText:"experiencia",freeAccessBlock:{title:"1",subtitle:"semana",text:"gratis"},button:{link:"/"},image:{url:"/src/assets/header/robert.webp",alt:"Imagen de encabezado"}},prizeList:{title:"Premios"},questList:{title:"Misiones",emptyQuestsWarning:"No hay misiones"},user:{defaultName:"Juan Pérez",avatar:{alt:"Foto de perfil"},ban:{forbiddenQuest:"Esta misión no está disponible temporalmente para usted",wait:"Por favor, espere"},randomNames:[{id:1,name:"Pelusa Traviesa"},{id:2,name:"Copito Alegre"},{id:3,name:"Trasto Gruñón"},{id:4,name:"Peludo Saltarín"},{id:5,name:"Chispa Pícara"},{id:6,name:"Canela Veloz"},{id:7,name:"Gordi Glotón"},{id:8,name:"Nube Temblorosa"},{id:9,name:"Lento Perezoso"},{id:10,name:"Capitán Migaja"},{id:11,name:"Señor Hámster"},{id:12,name:"Lola Risueña"},{id:13,name:"Bigotes Curiosos"},{id:14,name:"Jack Comilón"},{id:15,name:"Bufón Resoplón"},{id:16,name:"Rey Miau"},{id:17,name:"Ron Ron Peludo"},{id:18,name:"Boris Refunfuñón"},{id:19,name:"Zorro Astuto"},{id:20,name:"Pugron Sueñón"},{id:21,name:"Gruñón Fuerte"},{id:22,name:"Solecito Feliz"},{id:23,name:"Manchitas Ágil"},{id:24,name:"Quesito Veloz"},{id:25,name:"Peluchín Divertido"},{id:26,name:"Gominita Dulzona"},{id:27,name:"Trueno Travieso"},{id:28,name:"Barrigón Juguetón"},{id:29,name:"Tomás Espía"},{id:30,name:"Marisol Saltarina"},{id:31,name:"Erizo Astuto"},{id:32,name:"Chispero Enérgico"},{id:33,name:"Snoopy Parlanchín"},{id:34,name:"Desayuno Feliz"},{id:35,name:"Coco Risueño"},{id:36,name:"Pica Lástima"},{id:37,name:"Pelusón Suave"},{id:38,name:"Aurora Matutina"},{id:39,name:"Jerry Travieso"},{id:40,name:"Tigre Nube"},{id:41,name:"Panda Risueña"},{id:42,name:"Hugo Pensativo"},{id:43,name:"Pompa Burbuja"},{id:44,name:"Sedosa Delicia"},{id:45,name:"Dómini Donut"},{id:46,name:"Brisa Vivaz"},{id:47,name:"Garza Alegre"},{id:48,name:"Félix Narizudo"},{id:49,name:"Peludín Suave"},{id:50,name:"Pinto Manchado"}]}},de:{timer:{remainingTitle:"Zeitlimit:"},popup:{skillsTitle:"Erfahrung",menuItems:["Preise","Quests","Teilnehmer","Einstellungen"],prizes:{buttonTitle:"Preis erhalten",questionsTitle:"Punkte"}},gameMenu:{restart:"Neu starten"},popupBar:{prizesTitle:"Preise",skillsTitle:"Erfahrung"},share:{share:"Teilen",downloadFallback:"Herunterladen"},widget:{skillsTitle:"Erfahrung",accentButtonTitle:"Antwort bestätigen",buttonTitle:"Überspringen"},preloader:{text:"Das Modell denkt nach"},input:{placeholder:"Geben Sie Text ein…"},testCard:{successTitle:"Test bestanden",buttonTitle:"Erneut versuchen",worstScoreTemplate:"Sie haben <mark>{points} von {maxPoints}</mark> Punkten erzielt. Ihr bester Wert ist <mark>{bestPoints} von {maxPoints}</mark>.",bestScoreTemplate:"Sie haben <mark>{bestPoints} von {maxPoints}</mark> Punkten erzielt.",prizesTitle:"Preise, die Sie noch erhalten können",questsTitle:"Quests, die Sie noch abschließen können",chooseAnswer:"Wählen Sie alle zutreffenden Antworten aus der Liste aus:"},journeyCard:{successTitle:"Spiel abgeschlossen",buttonTitle:"Nochmals spielen",worstScoreTemplate:"Sie haben <mark>{points} von {maxPoints}</mark> Punkten erzielt. Ihr bester Wert ist <mark>{bestPoints} von {maxPoints}</mark>.",bestScoreTemplate:"Sie haben <mark>{bestPoints} von {maxPoints}</mark> Punkten erzielt.",prizesTitle:"Preise, die Sie noch erhalten können",questsTitle:"Quests, die Sie noch abschließen können",chooseAnswer:"Wählen Sie eine Antwort aus:"},settings:{signInPopup:{title:"Um Ihren Fortschritt zu speichern und Preise zu erhalten, müssen Sie ein Konto registrieren.",subtitle:"Ihr bisheriger Fortschritt wird darauf übertragen!",buttonTitle:"Schließen",accentButtonTitle:"Registrieren"},logout:"Abmelden"},globalError:{title:"Etwas ist schiefgelaufen 🤔",subtitle:"Während wir herausfinden, wie wir das Problem beheben können, können Sie versuchen, die Quest neu zu laden."},socialsPopup:{title:"Anmelden mit",subTitle:"Demnächst...",telegram:{title:"Telegram"},google:{title:"Google"},discord:{title:"Discord"}},footer:{buttonTitle:"Überspringen",accentButtonTitle:"Antwort bestätigen"},header:{title:"Kostenlose Trainingswoche im Tarif „Erich Fromm“",progressText:"Erfahrung",freeAccessBlock:{title:"1",subtitle:"Woche",text:"kostenlos"},button:{link:"/"},image:{url:"/src/assets/header/robert.webp",alt:"Header-Bild"}},prizeList:{title:"Preise"},questList:{title:"Quests",emptyQuestsWarning:"Keine Quests verfügbar"},user:{defaultName:"Max Mustermann",avatar:{alt:"Profilbild"},ban:{forbiddenQuest:"Diese Quest ist vorübergehend nicht für Sie verfügbar",wait:"Bitte warten"},randomNames:[{id:1,name:"Luna"},{id:2,name:"Bella"},{id:3,name:"Charlie"},{id:4,name:"Max"},{id:5,name:"Mia"},{id:6,name:"Lucy"},{id:7,name:"Leo"},{id:8,name:"Lotte"},{id:9,name:"Lilo"},{id:10,name:"Balu"},{id:11,name:"Molly"},{id:12,name:"Sammy"},{id:13,name:"Flocke"},{id:14,name:"Finja"},{id:15,name:"Frida"},{id:16,name:"Henry"},{id:17,name:"Lenny"},{id:18,name:"Lia"},{id:19,name:"Fiona"},{id:20,name:"Emil"},{id:21,name:"Paula"},{id:22,name:"Oskar"},{id:23,name:"Rico"},{id:24,name:"Nala"},{id:25,name:"Loki"},{id:26,name:"Kira"},{id:27,name:"Benji"},{id:28,name:"Leia"},{id:29,name:"Teddy"},{id:30,name:"Sophie"},{id:31,name:"Arco"},{id:32,name:"Chico"},{id:33,name:"Lilly"},{id:34,name:"Emma"},{id:35,name:"Maja"},{id:36,name:"Nele"},{id:37,name:"Milo"},{id:38,name:"Rosie"},{id:39,name:"Toby"},{id:40,name:"Yuki"},{id:41,name:"Keks"},{id:42,name:"Bruno"},{id:43,name:"Fritz"},{id:44,name:"Gismo"},{id:45,name:"Nicky"},{id:46,name:"Ronja"},{id:47,name:"Trixi"},{id:48,name:"Zoe"},{id:49,name:"Hugo"},{id:50,name:"Pia"}]}},en:{timer:{remainingTitle:"Time limit:"},popup:{skillsTitle:"experience",menuItems:["Prizes","Quests","Participants","Settings"],prizes:{buttonTitle:"Get Prize",questionsTitle:"points"}},gameMenu:{restart:"Start over"},share:{share:"Share",downloadFallback:"Download"},popupBar:{prizesTitle:"prizes",skillsTitle:"exp"},widget:{skillsTitle:"experience",accentButtonTitle:"Confirm Answer",buttonTitle:"Skip"},preloader:{text:"The model is thinking"},input:{placeholder:"Enter text…"},testCard:{successTitle:"You passed the test",buttonTitle:"Retake",worstScoreTemplate:"You scored <mark>{points} out of {maxPoints}</mark> points. Your best result is <mark>{bestPoints} out of {maxPoints}<mark/>",bestScoreTemplate:"You scored <mark>{bestPoints} out of {maxPoints}</mark> points",prizesTitle:"Prizes you can still earn",questsTitle:"Quests you can still complete",chooseAnswer:"Select all answers that apply from the list:"},journeyCard:{successTitle:"You completed the game",buttonTitle:"Play Again",worstScoreTemplate:"You scored <mark>{points} out of {maxPoints}</mark> points. Your best result is <mark>{bestPoints} out of {maxPoints}<mark/>",bestScoreTemplate:"You scored <mark>{bestPoints} out of {maxPoints}</mark> points",prizesTitle:"Prizes you can still earn",questsTitle:"Quests you can still complete",chooseAnswer:"Select an answer:"},settings:{signInPopup:{title:"To save your progress and earn prizes, you need to register an account.",subtitle:"Your progress will be transferred to it!",buttonTitle:"Close",accentButtonTitle:"Register"},logout:"Log Out"},globalError:{title:"Something went wrong 🤔",subtitle:"While we figure out how to fix it, you can try refreshing the quest"},socialsPopup:{title:"Sign up with",subTitle:"Coming soon...",telegram:{title:"Telegram"},google:{title:"Google"},discord:{title:"Discord"}},footer:{buttonTitle:"Skip",accentButtonTitle:"Confirm Answer"},header:{title:'Free week of training on the "Erich Fromm" plan',progressText:"experience",freeAccessBlock:{title:"1",subtitle:"week",text:"free"},button:{link:"/"},image:{url:"/src/assets/header/robert.webp",alt:"Header image"}},prizeList:{title:"Prizes"},questList:{title:"Quests",emptyQuestsWarning:"There is no quest"},user:{defaultName:"Guest",avatar:{alt:"Profile picture"},ban:{forbiddenQuest:"This quest is temporarily unavailable to you",wait:"Please wait"},randomNames:[{id:1,name:"Whiskers"},{id:2,name:"Buddy"},{id:3,name:"Grumpy"},{id:4,name:"Oliver"},{id:5,name:"Cleo"},{id:6,name:"Bubbles"},{id:7,name:"Rex"},{id:8,name:"Shadow"},{id:9,name:"Max"},{id:10,name:"Charlie"},{id:11,name:"Nibbles"},{id:12,name:"Daisy"},{id:13,name:"Chip"},{id:14,name:"Jack"},{id:15,name:"Toby"},{id:16,name:"Simba"},{id:17,name:"Ginger"},{id:18,name:"Oscar"},{id:19,name:"Bandit"},{id:20,name:"Pugsley"},{id:21,name:"Spike"},{id:22,name:"Sunny"},{id:23,name:"Cutie"},{id:24,name:"Dash"},{id:25,name:"Snowball"},{id:26,name:"Sparkle"},{id:27,name:"Mischief"},{id:28,name:"Pumpkin"},{id:29,name:"Thomas"},{id:30,name:"Bella"},{id:31,name:"Bandit"},{id:32,name:"Zippy"},{id:33,name:"Snoopy"},{id:34,name:"Chappy"},{id:35,name:"Coco"},{id:36,name:"Pip"},{id:37,name:"Fuzzy"},{id:38,name:"Misty"},{id:39,name:"Jerry"},{id:40,name:"Tigger"},{id:41,name:"Panda"},{id:42,name:"Hugo"},{id:43,name:"Bubbles"},{id:44,name:"Silky"},{id:45,name:"Midnight"},{id:46,name:"Bonnie"},{id:47,name:"Herbie"},{id:48,name:"Fiona"},{id:49,name:"Dusty"},{id:50,name:"Speckles"}]}},ru:{timer:{remainingTitle:"Ограничение времени:"},popup:{skillsTitle:"опыта",menuItems:["Призы","Квесты","Участники","Настройки"],prizes:{buttonTitle:"Получить приз",questionsTitle:"баллов"}},gameMenu:{restart:"Начать заново"},share:{share:"Поделиться",downloadFallback:"Скачать"},popupBar:{prizesTitle:"призов",skillsTitle:"опыта"},widget:{skillsTitle:"опыта",accentButtonTitle:"Подтвердить ответ",buttonTitle:"Пропустить"},preloader:{text:"Модель думает"},input:{placeholder:"Введите текст…"},testCard:{successTitle:"Вы прошли тест",buttonTitle:"Пройти еще раз",worstScoreTemplate:"Вы набрали <mark>{points} из {maxPoints}</mark> баллов. Ваш лучший результат <mark>{bestPoints} из {maxPoints}</mark>",bestScoreTemplate:"Вы набрали <mark>{bestPoints} из {maxPoints} баллов</mark>",prizesTitle:"Призы, которые еще можно получить",questsTitle:"Квесты, которые можно пройти ещё",chooseAnswer:"Выберите все подходящие ответы из списка:"},journeyCard:{successTitle:"Вы прошли игру",buttonTitle:"Пройти еще раз",worstScoreTemplate:"Вы набрали <mark>{points} из {maxPoints}</mark> баллов. Ваш лучший результат <mark>{bestPoints} из {maxPoints}</mark>",bestScoreTemplate:"Вы набрали <mark>{bestPoints} из {maxPoints} баллов</mark>",prizesTitle:"Призы, которые еще можно получить",questsTitle:"Квесты, которые можно пройти ещё",chooseAnswer:"Выберите ответ:"},settings:{signInPopup:{title:"Чтобы сохранить прогресс и получить призы, необходимо зарегистрировать аккаунт.",subtitle:"Полученный прогресс перенесется на него!",buttonTitle:"Закрыть",accentButtonTitle:"Зарегистрироваться"},logout:"Выйти"},globalError:{title:"Что-то пошло не так 🤔",subtitle:"Пока мы думаем, как всё починить, можете попробовать обновить квест"},socialsPopup:{title:"Зарегистрироваться с",subTitle:"Скоро...",telegram:{title:"Telegram"},google:{title:"Google"},discord:{title:"Discord"}},footer:{buttonTitle:"Пропустить",accentButtonTitle:"Подтвердить ответ"},header:{title:"Бесплатная неделя обучения по тарифу «Эрих Фром»",progressText:"опыта",freeAccessBlock:{title:"1",subtitle:"неделя",text:"бесплатно"},button:{link:"/"},image:{url:"/src/assets/header/robert.webp",alt:"Header image"}},prizeList:{title:"Призы"},questList:{title:"Квесты",emptyQuestsWarning:"Квестов нет"},user:{defaultName:"Иван Иванов",avatar:{alt:"Картинка профиля"},ban:{forbiddenQuest:"Этот квест временно не доступен для вас",wait:"Подождите"},randomNames:[{id:1,name:"Барсик Грозный"},{id:2,name:"Пушистый Соловей"},{id:3,name:"Тяпа Угрюмый"},{id:4,name:"Василий Хвостатый"},{id:5,name:"Кеша Коварный"},{id:6,name:"Бублик Шустрый"},{id:7,name:"Шарик Проглот"},{id:8,name:"Мурзик Трепещущий"},{id:9,name:"Жора Ленивый"},{id:10,name:"Капитан Блоха"},{id:11,name:"Лорд Хомяк"},{id:12,name:"Жужа Смешная"},{id:13,name:"Чип Усатый"},{id:14,name:"Джек Обжора"},{id:15,name:"Тихон Пыхтящий"},{id:16,name:"Мяу Царь"},{id:17,name:"Рыжик Пушистик"},{id:18,name:"Борис Фырчащий"},{id:19,name:"Зорро Хитрый"},{id:20,name:"Мопсик Храпун"},{id:21,name:"Хрюша Громкий"},{id:22,name:"Гаврюша Радостный"},{id:23,name:"Котлетка Ловкая"},{id:24,name:"Сырник Бегущий"},{id:25,name:"Умка Забавный"},{id:26,name:"Бусинка Мимимишная"},{id:27,name:"Крош Шалун"},{id:28,name:"Пузик Забавный"},{id:29,name:"Томас Шпионистый"},{id:30,name:"Маруся Скачущая"},{id:31,name:"Ёжик Хитрый"},{id:32,name:"Клёпа Задорный"},{id:33,name:"Снупи Болтун"},{id:34,name:"Чапа Завтрак"},{id:35,name:"Кокос Хохотун"},{id:36,name:"Лапка Ласточка"},{id:37,name:"Фунтик Плюшевый"},{id:38,name:"Мурка Утренняя"},{id:39,name:"Джерри Нахальный"},{id:40,name:"Тигрик Зефирный"},{id:41,name:"Панда Забавная"},{id:42,name:"Хома Задумчивый"},{id:43,name:"Рыбка Пузырь"},{id:44,name:"Ласка Шелковая"},{id:45,name:"Мурзик Пончик"},{id:46,name:"Бонька Резвый"},{id:47,name:"Цапля Весёлая"},{id:48,name:"Филя Носатый"},{id:49,name:"Тузик Мохнатый"},{id:50,name:"Зяблик Пятнистый"}]}}},Hl=Object.keys(Ul)[0],He=Nt(e=>({translations:Ul[Hl],localeName:Hl,setLocale:t=>{let n=Ul[t];n||(n=Ul[Hl],t=Hl),e(()=>({translations:n,localeName:t}))}})),e3=async e=>{const{data:t}=await ut.post("/certificate",{userPrizeId:e},{responseType:"blob"});return t},t3={plain:"Plain",certificate:"Certificate"},ln=Nt((e,t)=>({prize:null,certificate:{url:"",file:null},richTextBlocks:[],isRegistrationModalOpen:!1,isRichTextModalOpen:!1,isCertificateModalOpen:!1,openModalForRegistration(n){e({prize:n,isRegistrationModalOpen:!0})},openModalForRichText(n){e({richTextBlocks:n,isRichTextModalOpen:!0})},opemCertificateModal(n){e({certificate:n,isCertificateModalOpen:!0})},closeModalForRegistration(){e({prize:null,isRegistrationModalOpen:!1})},closeModalForRichText(){e({prize:null,isRichTextModalOpen:!1})},closeCertificateModal(){e({certificate:{url:"",file:null},isCertificateModalOpen:!1})}})),n3=()=>{const e=ln(r=>r.openModalForRegistration),t=ln(r=>r.openModalForRichText),n=ln(r=>r.opemCertificateModal);return C.useMemo(()=>{const r={handleWantForPrize:i=>{if(!localStorage.getItem(gn.accessToken)){r.askForRegistration(i);return}return r.openPrize(i)},askForRegistration(i){e(i)},openPrize(i){if(i.type===t3.plain){r.showAwardRichText(i);return}return r.openCertificate(i)},async openCertificate(i){const a=await e3(i.id);n({url:URL.createObjectURL(a),file:r.constractFile(i.id,a)})},constractFile(i,a){const c=a.type||"image/webp",d=c.split("/")[1];return new File([a],`certificate-${i}.${d}`,{type:c})},showFullDescription(i){t(i.descriptionRichText.blocks)},showAwardRichText(i){t(i.awardRichText.blocks)}};return r},[e,t,n])},_f=({prizeData:e,userPoints:t,index:n})=>{const r=He(c=>c.translations.popup.prizes),{handleWantForPrize:i,showFullDescription:a}=n3();return v.jsxs(bN,{children:[v.jsxs(B1,{children:[v.jsx(z1,{children:v.jsx(Y1,{iconId:e==null?void 0:e.iconId})}),v.jsx(U1,{children:e==null?void 0:e.name})]}),v.jsxs(IN,{children:[e!=null&&e.isReceived?v.jsx(wn,{"data-testid":`edmap-widget__prize-btn-${n+1}`,title:r.buttonTitle,isAccent:!0,style:{minWidth:"159px"},onClick:()=>i(e)}):v.jsx(v.Fragment,{children:v.jsxs(RN,{children:[v.jsx(Cs,{text:r.questionsTitle,progressValue:t,overallValue:e==null?void 0:e.awardPoints}),v.jsx(zl,{progressValue:t,overallValue:e==null?void 0:e.awardPoints})]})}),v.jsx(CN,{children:v.jsx(V1,{icon:v.jsx(AN,{}),onClick:()=>a(e)})})]})]})},r3=j("div")({name:"GiftsContainer",class:"edg1do84z2",propsAsIs:!1}),s3=()=>{var t;const e=Ct(n=>n.results);return v.jsx(r3,{children:(t=e==null?void 0:e.prizes)==null?void 0:t.map((n,r)=>v.jsx(_f,{index:r,prizeData:n,userPoints:e==null?void 0:e.allPoints},n==null?void 0:n.id))})},o3=j("div")({name:"UserInfoWrapper",class:"eduxnm4b4",propsAsIs:!1}),i3=j("div")({name:"ImageWrapper",class:"edi1fh8glv",propsAsIs:!1}),a3=j("div")({name:"InfoWrapper",class:"edi1e8ga1u",propsAsIs:!1}),l3=j("div")({name:"MainInfo",class:"edm1qs3iet",propsAsIs:!1}),c3=j("div")({name:"TitleWrapper",class:"edtbtnkwj",propsAsIs:!1}),u3=j("div")({name:"PoweredContainer",class:"edp1rvtj15",propsAsIs:!1}),d3=j("div")({name:"ProgressTextWrapper",class:"edpseoz31",propsAsIs:!1}),f3=j("h3")({name:"Title",class:"edt1jzrydq",propsAsIs:!1}),p3=e=>C.createElement("svg",{xmlns:"http://www.w3.org/2000/svg",width:22,height:26,fill:"none",...e},C.createElement("path",{fill:"#C3C3C3",stroke:"#363636",strokeWidth:2,d:"m20.66 18.577-.5.29-8.66 5-.5.287-.5-.288-8.66-5-.5-.289V7.423l.5-.29 8.66-5 .5-.287.5.288 8.66 5 .5.289z"})),h3=e=>C.createElement("svg",{xmlns:"http://www.w3.org/2000/svg",width:22,height:24,fill:"none",...e},C.createElement("path",{fill:"#FCBC21",stroke:"#ED7527",strokeWidth:2,d:"M9 2a4 4 0 0 1 4 0l5.66 3.268c1.238.714 2 2.035 2 3.464v6.536c0 1.429-.762 2.75-2 3.464L13 22a4 4 0 0 1-4 0l-5.66-3.268a4 4 0 0 1-2-3.464V8.732c0-1.429.762-2.75 2-3.464z"})),Ef=({level:e})=>v.jsxs(y3,{children:[v.jsx(g3,{children:v.jsx(p3,{})}),v.jsx(m3,{children:v.jsx(h3,{})}),v.jsx("span",{children:e})]}),m3=Z("div")({name:"SmoothContainer",class:"edsvd1acj",propsAsIs:!1}),g3=Z("div")({name:"RoughContainer",class:"edr1a0zzy8",propsAsIs:!1}),y3=Z("div")({name:"Container",class:"edc1fcmc7w",propsAsIs:!1}),v3=[...new Intl.Segmenter("en",{granularity:"grapheme"}).segment("🦄🐺🪼🐝🦅🐋")].map(e=>e.segment),S3=e=>[...e].map(t=>t.codePointAt(0)).join("-"),Wl=Object.fromEntries(v3.map(e=>[S3(e),e])),w3=()=>{const e=localStorage.getItem(gn.profileEmoji);if(e&&Wl[e])return Wl[e];const t=_3();return localStorage.setItem(gn.profileEmoji,t),Wl[t]},_3=()=>{const e=Object.keys(Wl),t=E3(e.length);return e[t]},E3=e=>Math.floor(Math.random()*e),K1=j("div")({name:"Container",class:"edci91fsv",propsAsIs:!1}),xf=({src:e,...t})=>{const n=He(i=>i.translations.user.avatar.alt);if(e)return v.jsx(K1,{children:v.jsx("img",{...t,src:e,alt:n})});const r=w3();return v.jsx(K1,{children:r})},kf=e=>e?e<10?1:Math.floor(e/10):1,x3=j("a")({name:"Container",class:"edc1ryazt0",propsAsIs:!1}),k3=j("span")({name:"Text",class:"edtk7p3bu",propsAsIs:!1}),T3=e=>C.createElement("svg",{xmlns:"http://www.w3.org/2000/svg",width:85,height:12,fill:"none",...e},C.createElement("path",{fill:"currentColor",d:"M4.992 0h10.144q1.04 0 1.936.4a4.9 4.9 0 0 1 1.584 1.056q.688.672 1.072 1.584.4.896.4 1.936v1.6H2.8q0 .511.176.96.192.432.496.768.32.32.752.512t.928.192h9.808q.336 0 .592-.064.255-.08.448-.192.208-.112.368-.256t.304-.32h3.264a5 5 0 0 1-.688 1.456 5.008 5.008 0 0 1-2.48 1.904 4.9 4.9 0 0 1-1.632.272H4.992a5 5 0 0 1-1.952-.384 5.1 5.1 0 0 1-1.584-1.072A5.1 5.1 0 0 1 .384 8.768 4.9 4.9 0 0 1 0 6.832V4.976q0-1.04.384-1.936a5.1 5.1 0 0 1 1.072-1.584Q2.128.784 3.04.4A4.8 4.8 0 0 1 4.992 0m.16 2.8q-.495 0-.928.192a2.3 2.3 0 0 0-.752.528q-.304.32-.496.768a2.5 2.5 0 0 0-.176.944h14.528a2.5 2.5 0 0 0-.176-.944 2.2 2.2 0 0 0-.496-.768 2.298 2.298 0 0 0-1.696-.72zM20.938.304H36.09q1.04 0 1.935.4A4.9 4.9 0 0 1 39.61 1.76q.672.672 1.056 1.584.4.896.4 1.936v1.248q0 1.024-.4 1.936a4.9 4.9 0 0 1-1.056 1.584 5.1 5.1 0 0 1-1.584 1.072 4.9 4.9 0 0 1-1.935.384H20.937zm2.8 2.8v5.6H36.09q.431 0 .831-.16.4-.176.688-.464.305-.304.48-.688.177-.4.177-.832V5.248q-.001-.432-.176-.816a2.1 2.1 0 0 0-.48-.688 1.9 1.9 0 0 0-.688-.464 2.05 2.05 0 0 0-.832-.176zM41.078 11.504l3.184-11.2h3.488l3.392 8.144L54.55.304h3.488l3.168 11.2h-3.04l-2.704-8.656-3.776 8.656h-1.088l-3.776-9.248-2.704 9.248zM65.037.304h5.471l2.225 11.2h-2.8l-.945-4.928h-2.431l-.945 4.928h-2.8zm3.328 2.768H67.18l-.352 2.16h1.888zM81.064.304q.656 0 1.232.256.592.24 1.024.672t.672 1.024q.255.576.256 1.232 0 .656-.256 1.232-.24.56-.672.976t-1.024.656q-.576.224-1.232.224h-3.936v4.928h-2.8V.304zm-.832 2.8h-3.104v2.128h3.104q.56 0 .88-.288.336-.288.336-.784 0-.48-.336-.768-.32-.288-.88-.288"})),Q1={en:"en",ru:"ru",de:"de",es:"es",default:"en"},b3=e=>{const t=Q1[e];return t||Q1.default},X1=()=>{const e=He(r=>r.localeName),t=b3(e),n=new URLSearchParams;return n.set("utm_source",window.location.hostname),n.set("utm_medium",window.location.href),v.jsxs(x3,{href:`https://edmap.space/${t}?${n}`,target:"_blank",children:[v.jsx(k3,{children:"Powered by"}),v.jsx(T3,{})]})},I3=()=>typeof window<"u"&&window.location.hostname==="edmap.space",C3=()=>{var d,f,h,y,g;const[e,t]=C.useState(""),n=Ct(w=>w.results),r=(d=n==null?void 0:n.User)==null?void 0:d.username,i=He(w=>w.translations.user.randomNames),a=He(w=>w.translations.popup),c=I3();return C.useEffect(()=>{const w=_=>{var k;const E=Math.floor(Math.random()*_.length);return(k=_[E])==null?void 0:k.name};(_=>{const E=localStorage.getItem("edmap-access-token"),k=localStorage.getItem(gn.defaultName);if(!k&&!E){const O=w(_);localStorage.setItem(gn.defaultName,O),t(O)}else E?(localStorage.removeItem(gn.defaultName),t(r)):t(k)})(i)},[r,i]),v.jsxs(o3,{children:[v.jsx(i3,{children:v.jsx(xf,{src:(h=(f=n==null?void 0:n.User)==null?void 0:f.avatar)==null?void 0:h.src})}),v.jsxs(a3,{children:[v.jsxs(l3,{children:[v.jsxs(c3,{children:[v.jsx(f3,{children:r??e}),v.jsx(Ef,{level:kf(n==null?void 0:n.allPoints)})]}),v.jsx(d3,{children:v.jsx(Cs,{progressValue:n==null?void 0:n.allPoints,overallValue:(y=n==null?void 0:n.map)==null?void 0:y.points,text:a.skillsTitle})}),v.jsx(zl,{progressValue:n==null?void 0:n.allPoints,overallValue:(g=n==null?void 0:n.map)==null?void 0:g.points})]}),!c&&v.jsx(u3,{children:v.jsx(X1,{})})]})]})},R3=j("ul")({name:"Container",class:"edc18eiqam",propsAsIs:!1}),A3=j("li")({name:"Item",class:"edi8drxbn",propsAsIs:!1}),O3=j("a")({name:"ItemLink",class:"edi1ovdisv",propsAsIs:!1}),P3=j("p")({name:"QuestName",class:"edqiwgwie",propsAsIs:!1}),N3=j("div")({name:"IconWrapper",class:"edi5p8aot",propsAsIs:!1}),J1=e=>C.createElement("svg",{xmlns:"http://www.w3.org/2000/svg",fill:"none",viewBox:"0 0 16 16",...e},C.createElement("path",{fill:"currentColor",d:"M16 15h-2V3.414L1.707 15.707.293 14.293 12.586 2H1V0h15z"})),Tf=({quests:e})=>v.jsx(R3,{children:e==null?void 0:e.map(t=>{var n;return v.jsx(A3,{children:v.jsxs(O3,{href:t==null?void 0:t.url,children:[v.jsx(P3,{children:t==null?void 0:t.name}),v.jsxs(N3,{children:[v.jsx(Cs,{progressValue:((n=t==null?void 0:t.resultQuestAnswer)==null?void 0:n.points)??0,overallValue:t==null?void 0:t.maxPoints}),v.jsx(J1,{})]})]})},t==null?void 0:t.id)})}),M3=j("div")({name:"Container",class:"edc1cuvton",propsAsIs:!1}),L3=j("div")({name:"Wrapper",class:"edw1bhqzg6",propsAsIs:!1}),cn=Nt(e=>({isPanelModalOpen:!1,isRegistrationOpen:!1,setIsPanelOpen:t=>e({isPanelModalOpen:t}),setIsRegistrationOpen:t=>e({isRegistrationOpen:t})})),bf=({setIsRegInfoVisible:e})=>{const t=cn(i=>i.setIsRegistrationOpen),n=He(i=>i.translations.settings.signInPopup),r=()=>{t(!0)};return v.jsxs(L3,{children:[v.jsxs(M1,{children:[v.jsx(L1,{children:n.title}),v.jsx(j1,{children:n.subtitle})]}),v.jsxs(D1,{children:[v.jsx(wn,{title:n.buttonTitle,onClick:()=>e(!1)}),v.jsx(wn,{title:n.accentButtonTitle,isAccent:!0,onClick:r})]})]})},Z1=async(e=[],t="high")=>{const n=e.map(i=>new Promise(a=>{const c=new Image;c.src=i,c.fetchPriority=t,c.onload=()=>a(),c.onerror=()=>a()}));return await Promise.all(n)},ql=200,If=()=>new Promise(e=>{setTimeout(()=>{e()},ql)}),ev=e=>{const t=e.current;if(!t)return()=>{};const n=t.getBoundingClientRect().height;return t.style.height=`${n}px`,()=>{setTimeout(()=>{t.style.height="auto";const r=t.getBoundingClientRect().height;t.style.height=`${n}px`,setTimeout(()=>{t.style.height=`${r}px`,setTimeout(()=>{t.style.height="auto"},ql+25)},25)},25)}},Br=Nt((e,t)=>({isHidden:!1,preloader:null,ref:{current:null},setRef:n=>e({ref:n}),preparePreloader:async n=>{const r=t().ref;e({isHidden:!0}),await If();const i=ev(r);let a=null;const c=new Promise(d=>{setTimeout(d,600)});e({preloader:{promise:c,resolve:a,text:n.text}}),i(),await If(),e({isHidden:!1})},startFadeTransition:async(n=[])=>{const r=t().ref,i=t().preloader;if(i&&await i.preloaderPromise,!r||!r.current){const y=Promise.resolve();return[y,()=>y]}e({isHidden:!0});const a=ev(r),c=If(),d=async()=>{await c,a(),e({isHidden:!1,preloader:null})},f=async(y=[])=>{const g=await Z1(y);return await d(),g};return await(async(y=[])=>{const[g,w]=await Promise.all([c,f(y)]);return w})(n)}})),tv=(e=0)=>{setTimeout(()=>{const t=document.getElementById("edmap-widget__container");if(!t)return;const n=t.getBoundingClientRect();window.scrollTo({behavior:"smooth",top:n.top+window.scrollY-e})},ql)},St={test:"Test",journey:"Journey"},pr=Nt(e=>({topOffset:0,marginRootTop:0,gapFromOffset:0,breakPoints:null,setGapFromOffset:t=>e({gapFromOffset:t}),setTopOffset:t=>e({topOffset:t}),setMarginRootTop:t=>e({marginRootTop:t}),setBreakPoints:t=>e({breakPoints:t})})),Rs={node:"node",inputAnswerNode:"input-answer-node",random:"random",if:"if",present:"present",ai:"ai"},Rt={journeyDefault:"journey-default",testDefault:"test-default",journeyText:"journey-text",journeyAi:"journey-ai"},j3={[St.journey]:"/user-journey-answer",[St.test]:"/user-test-answer"},D3=e=>({currentNode:e.node,currentResources:iv(e.currentResources)}),nv={[St.journey]:D3,[St.test]:e=>e},$3=e=>({quest:{currentStep:e.questionIndex+1},zustandState:e}),F3=e=>({quest:{},zustandState:e}),rv={[St.journey]:F3,[St.test]:$3},B3={[Rt.journeyDefault]:"/user-journey-answer",[Rt.journeyText]:"/user-journey-answer/text",[Rt.journeyAi]:"/user-journey-answer/text",[Rt.testDefault]:"/user-test-answer"},sv=async(e,t,n)=>({text:t.textAnswer,sessionId:Is(e.id),userId:await fr(),nodeId:t.currentNode.id}),z3=async(e,t,n)=>({id:xr(13),journeyEdgeId:n.journeyEdgeId,sessionId:Is(e.id),userId:await fr()}),U3=async(e,t,n)=>{const r=await fr(),i=Is(e.id);return(t.selectedAnswers.length>0?t.selectedAnswers:[{id:null}]).map(c=>({id:`${xr(13)}`,answerId:c.answerId,questId:c.questId,questionId:t.currentQuestion.id,userId:r,sessionId:i}))},H3={[Rt.journeyDefault]:z3,[Rt.testDefault]:U3,[Rt.journeyText]:sv,[Rt.journeyAi]:sv},W3=e=>e.currentNode.type===Rs.present,q3=e=>e.currentQuestion===null,V3={[St.journey]:W3,[St.test]:q3},G3=(e,t)=>V3[e.quest.questType](t),ov=(e,t,n)=>{if(e.questType===St.test)return Rt.testDefault;if(e.questType===St.journey)return Rs.ai===t.currentNode.type?Rt.journeyAi:Rs.inputAnswerNode===t.currentNode.type?Rt.journeyText:Rt.journeyDefault},Y3=async(e,t,n)=>{const r=ov(e,t),i=await H3[r](e,t,n),a=B3[r],{data:c}=await ut.post(a,i);return nv[e.questType](c)},Cf=async e=>{if(!e)return null;const t=Is(e.id),n=`${j3[e.questType]}/${e.id}/${t}`,r=await ut.get(n);return nv[e.questType](r.data)},K3=e=>{const t=e.currentNode;if(!t)return[];const n=Af(t.data.blocks);return[...t.sourceEdges.flatMap(i=>Af(i.richText.blocks)),...n]},Q3=e=>{const t=e.currentQuestion;return t?Af(t.text.blocks):[]},Rf={[St.journey]:K3,[St.test]:Q3},X3=async e=>await ut.post("/result-quest-answer/journey",{id:xr(16),sessionId:Is(e.id),questId:e.id,mapId:e.mapId,userId:await fr()}),iv=e=>e.map(nM),J3=e=>{const t=Number.isInteger(e);return new Intl.NumberFormat(void 0,{minimumFractionDigits:t?0:2,maximumFractionDigits:2}).format(e)},Z3=(e,t,n)=>kr.reportEdgeClick(n.journeyEdgeId),eM=(e,t,n)=>kr.reportTestAnswers(t.selectedAnswers),tM={[Rt.journeyDefault]:Z3,[Rt.journeyText]:()=>{},[Rt.journeyAi]:()=>{},[Rt.testDefault]:eM},nM=e=>({...e,value:J3(e.value)}),Af=e=>e.filter(n=>n.type==="image").map(n=>{var r,i;return(i=(r=n.data)==null?void 0:r.file)==null?void 0:i.url}),rM=async(e,t)=>{const n=`/journey-node/${e}/resources`;try{const{data:r}=await ut.get(n,{signal:t});return r}catch{return{imageUrls:[]}}},hr=Nt(e=>({currentNode:{data:{blocks:[]},sourceEdges:[]},currentResources:[],textAnswer:"",setTextAnswer:t=>e({textAnswer:t}),setCurrentNode:(t,n)=>{e({currentNode:t,currentResources:iv(n)})},initialize:async t=>{if(!t)return;const{node:n,currentResources:r}=await Cf(t);e(()=>({currentNode:n,currentResources:r}))},restart:(t,n)=>{e({currentNode:t,currentResources:n})}})),Vl=Nt(e=>({currentQuestion:null,selectedAnswers:[],setQuestion:t=>e({currentQuestion:t}),addAnswer:async(t,n,r)=>{const i={id:`${xr(13)}`,answerId:n,questionId:r,questId:t,userId:await fr(),sessionId:Is(t)};e(a=>({selectedAnswers:[...a.selectedAnswers,i]}))},initialize:async t=>{if(!t)return;const{node:n,currentResources:r}=await Cf(t);e(()=>({currentNode:n,resources:r}))},removeAnswer:t=>e(n=>({selectedAnswers:n.selectedAnswers.filter(r=>r.answerId!==t)})),resetAnswers:()=>e({selectedAnswers:[]}),resetTest:()=>e({selectedAnswers:[]})})),Of={[St.test]:Vl,[St.journey]:hr},av=()=>{const e=Me(n=>n.quest),t=Of[e.questType];return C.useMemo(()=>({quest:e,currentZustandHook:t}))},sM=()=>{const e=He(t=>t.translations.preloader);return C.useMemo(()=>({[Rt.journeyAi]:{text:e.text}}),[e])},Pf=Nt(e=>({error:null,setError:t=>e({error:t})})),Io=()=>{const{quest:e,currentZustandHook:t}=av(),n=Me(d=>d.setIsFinished),r=Br(d=>d.startFadeTransition),i=Br(d=>d.preparePreloader),a=sM(),c=pr(d=>d.marginRootTop);return C.useMemo(()=>{const d=Of[e.questType],f={fetchPreviousProgress:async h=>{const y=await Cf(h),g=rv[h.questType](y);await r(Rf[h.questType](g.zustandState)),Me.setState(g.quest),Of[h.questType].setState(g.zustandState)},makeStep:async h=>{try{const y=d.getState(),g=ov(e,y,h);tM[g](e,y,h);const w=a[g];w&&await i(w);const x=await Y3(e,y,h),_=rv[e.questType](x),E=Br.getState().preloader;E&&await E.promise,w||await r(Rf[e.questType](_.zustandState)),Me.setState(_.quest),d.setState(_.zustandState),w&&await r(Rf[e.questType](_.zustandState));const k=G3(Me.getState(),_.zustandState);n(k),tv(c)}catch(y){Pf.setState({error:y})}},cleanQuestInit:async h=>{await f.fetchPreviousProgress(h),n(!1)},restartQuest:async()=>{x1(e.id),f.cleanQuestInit(e),tv(c)}};return f},[e,t,c])},oM=()=>{const{resetQuest:e}=Io(),t=Ct(i=>i.refreshUserResults),n=He(i=>i.translations.settings),r=async()=>{var i;await Zh(),t((i=window.__widgetEdmap)==null?void 0:i.mapId),e()};return v.jsx(wn,{onClick:r,title:n.logout,isAccent:!0})},iM=()=>{const e=localStorage.getItem(gn.accessToken),[t,n]=C.useState(!0);return v.jsx(M3,{children:e&&v.jsx(D1,{children:v.jsx(oM,{})})||t&&v.jsx(bf,{setIsRegInfoVisible:n})})},aM=j("div")({name:"PoweredContainer",class:"edp153jgy2",propsAsIs:!1}),lM=j("div")({name:"ProgressTextContainer",class:"edp88qvra",propsAsIs:!1}),cM=j("div")({name:"StepContainer",class:"eds3v2lpt",propsAsIs:!1}),lv=j("div")({name:"ButtonWrapper",class:"edb1h6cmje",propsAsIs:!1}),uM=j("div")({name:"Container",class:"edc1g9vmxh",propsAsIs:!1}),dM=j("div")({name:"Background",class:"edb1dvqizg",propsAsIs:!1}),fM=j("div")({name:"Container",class:"edc24c84i",propsAsIs:!1}),pM=j("div")({name:"InfoBlock",class:"edic7ywtw",propsAsIs:!1}),hM=j("p")({name:"InfoBlockTitle",class:"ediy16h9m",propsAsIs:!1}),mM=j("p")({name:"InfoBlockSubtitle",class:"edi1m54nr",propsAsIs:!1}),gM=j(lv)({name:"CustomButtonWrapper",class:"edc10pc0jd",propsAsIs:!0}),yM=j("div")({name:"Container",class:"edc1mwrga6",propsAsIs:!1}),cv=j("h3")({name:"Title",class:"edt1l3a9ma",propsAsIs:!1}),vM=j("div")({name:"UnavailableButtons",class:"edutbpur",propsAsIs:!1}),SM=j("div")({name:"CloseButton",class:"edcnx305o",propsAsIs:!1}),wM=e=>C.createElement("svg",{xmlns:"http://www.w3.org/2000/svg",fill:"currentColor",fillRule:"evenodd",clipRule:"evenodd",imageRendering:"optimizeQuality",shapeRendering:"geometricPrecision",textRendering:"geometricPrecision",viewBox:"0 0 333334 333334",...e},C.createElement("path",{d:"M166667 0c92048 0 166667 74619 166667 166667s-74619 166667-166667 166667S0 258715 0 166667 74619 0 166667 0m80219 91205-29735 149919s-4158 10396-15594 5404l-68410-53854s76104-68409 79222-71320c3119-2911 2079-3534 2079-3534 207-3535-5614 0-5614 0l-100846 64043-42002-14140s-6446-2288-7069-7277c-624-4992 7277-7694 7277-7694l166970-65498s13722-6030 13722 3951m-87637 122889-27141 24745s-2122 1609-4443 601l5197-45965z"})),_M=e=>C.createElement("svg",{xmlns:"http://www.w3.org/2000/svg",fill:"currentColor",fillRule:"evenodd",strokeLinejoin:"round",strokeMiterlimit:2,clipRule:"evenodd",viewBox:"0 0 512 512",...e},C.createElement("path",{d:"M32.582 370.734C15.127 336.291 5.12 297.425 5.12 256c0-41.426 10.007-80.291 27.462-114.735C74.705 57.484 161.047 0 261.12 0c69.12 0 126.836 25.367 171.287 66.793l-73.31 73.309c-26.763-25.135-60.276-38.168-97.977-38.168-66.56 0-123.113 44.917-143.36 105.426-5.12 15.36-8.146 31.65-8.146 48.64 0 16.989 3.026 33.28 8.146 48.64l-.303.232h.303c20.247 60.51 76.8 105.426 143.36 105.426 34.443 0 63.534-9.31 86.341-24.67 27.23-18.152 45.382-45.148 51.433-77.032H261.12v-99.142h241.105c3.025 16.757 4.654 34.211 4.654 52.364 0 77.963-27.927 143.592-76.334 188.276-42.356 39.098-100.305 61.905-169.425 61.905-100.073 0-186.415-57.483-228.538-141.032z"})),EM=e=>C.createElement("svg",{xmlns:"http://www.w3.org/2000/svg",fill:"currentColor",viewBox:"0 0 50 50",...e},C.createElement("path",{d:"M41.625 10.77c-3.98-3.204-10.277-3.747-10.547-3.766a.99.99 0 0 0-.988.586 7 7 0 0 0-.305.832c2.633.445 5.867 1.34 8.793 3.156a1 1 0 1 1-1.055 1.7C32.493 10.155 26.211 10 25 10c-1.21 0-7.496.156-12.523 3.277a1 1 0 0 1-1.055-1.7c2.926-1.811 6.16-2.71 8.793-3.151-.152-.496-.29-.809-.3-.836a.99.99 0 0 0-.993-.586c-.27.02-6.567.562-10.602 3.809C6.215 12.762 2 24.153 2 34c0 .176.047.344.133.496 2.906 5.11 10.84 6.445 12.648 6.504h.031a1 1 0 0 0 .81-.41l1.827-2.516c-4.933-1.273-7.453-3.437-7.597-3.566a1 1 0 0 1 1.324-1.5C11.234 33.063 15.875 37 25 37c9.14 0 13.781-3.953 13.828-3.992a1 1 0 0 1 1.41.094.996.996 0 0 1-.09 1.406c-.144.129-2.664 2.293-7.597 3.566l1.828 2.516a1 1 0 0 0 .809.41h.03c1.81-.059 9.743-1.395 12.65-6.504.085-.152.132-.32.132-.496 0-9.848-4.215-21.238-6.375-23.23M18.5 30c-1.934 0-3.5-1.79-3.5-4s1.566-4 3.5-4 3.5 1.79 3.5 4-1.566 4-3.5 4m13 0c-1.934 0-3.5-1.79-3.5-4s1.566-4 3.5-4 3.5 1.79 3.5 4-1.566 4-3.5 4"})),xM=[{name:"telegram",icon:v.jsx(wM,{}),onClick:FP},{name:"google",icon:v.jsx(_M,{}),onClick:zP},{name:"discord",icon:v.jsx(EM,{}),onClick:console.log}],kM=({icon:e,title:t,...n})=>v.jsxs(TM,{...n,children:[e,v.jsx(bM,{children:t})]}),TM=Z(wf)({name:"CustomButton",class:"edc1yr71r",propsAsIs:!0}),bM=Z("p")({name:"Title",class:"edtsdg8a8",propsAsIs:!1}),uv=e=>v.jsx(kM,{"data-testid":`edmap-widget__social-${e.name}-btn`,title:e.title,icon:e.icon,disabled:e.disabled,onClick:e.onClick},e.name),IM=(e,t)=>{var n;return{...e,title:(n=t[e.name])==null?void 0:n.title}},CM=(e,t)=>({...e,disabled:t}),RM=({closeModal:e})=>{var f;const t=He(h=>h.translations.socialsPopup),n=Ct(h=>h.results),r=(f=n==null?void 0:n.map)==null?void 0:f.registration,a=xM.map(h=>IM(h,t)).map(h=>CM(h,!r[h.name])),c=a.filter(h=>!h.disabled),d=a.filter(h=>h.disabled);return v.jsxs(yM,{"data-testid":"edmap-widget__social-popup",children:[c.length>0&&v.jsxs(v.Fragment,{children:[v.jsx(SM,{onClick:e,children:"✕"}),v.jsx(cv,{children:t.title}),c.map(uv)]}),d.length>0&&v.jsxs(vM,{children:[v.jsx(cv,{children:t.subTitle}),d.map(uv)]})]})},dv=({isOpen:e,closeModal:t,isSocialModalVisible:n,setIsSocialModalVisible:r})=>{const i=C.useRef(null),a=He(y=>y.translations.signInPopup),[c,d]=C.useState(!1),f=y=>{i.current&&!i.current.contains(y.target)&&(t(),r(!1),d(!1))},h=()=>{r(!1),d(!1),t()};if(C.useEffect(()=>(d(!1),e?document.addEventListener("mousedown",f):document.removeEventListener("mousedown",f),()=>{document.removeEventListener("mousedown",f)}),[e]),!!e)return v.jsx(dM,{children:v.jsx(fM,{ref:i,children:c||n?v.jsx(RM,{closeModal:h}):v.jsxs("div",{"data-testid":"edmap-widget__signin-popup",children:[v.jsxs(pM,{children:[v.jsx(hM,{children:a.title}),v.jsx(mM,{children:a.subtitle})]}),v.jsxs(gM,{children:[v.jsx(wn,{title:a.buttonTitle,onClick:t}),v.jsx(wn,{"data-testid":"edmap-widget__signin-popup-btn",title:a.accentButtonTitle,isAccent:!0,onClick:()=>d(!0)})]})]})})})},AM=j("div")({name:"Background",class:"edbwx2goj",propsAsIs:!1}),OM=j("div")({name:"Container",class:"edcc2hi8c",propsAsIs:!1}),PM=j("div")({name:"CloseButton",class:"edc1td8pnr",propsAsIs:!1}),Co=Z("p")({name:"FittableText",class:"edf16hcfkz",propsAsIs:!1}),NM=Z(Co)({name:"QuestionParagraph",class:"edqbe2o7o",propsAsIs:!0}),MM=Z(Co)({name:"AnswerParagraph",class:"eda1u10kac",propsAsIs:!0}),LM=Z(Co)({name:"JourneyWidgetText",class:"edj1c2nqbc",propsAsIs:!0}),fv=Z(Co)({name:"EdgeText",class:"edew0t9wk",propsAsIs:!0}),jM=Z(fv)({name:"NodeDescription",class:"edn13pdjrz",propsAsIs:!0}),DM=Z(Co)({name:"PrizeInfoParagraph",class:"edp1ot2zjf",propsAsIs:!0}),$M=Z(Co)({name:"PrizeDescParagraph",class:"edp120urih",propsAsIs:!0}),FM=Z("div")({name:"RichTextWrap",class:"edr4pnqsv",propsAsIs:!1}),BM=Z("table")({name:"StyledTable",class:"edsnwt7pg",propsAsIs:!1}),zM=Z("div")({name:"Border",class:"edb1uwnm14",propsAsIs:!1}),UM=Z("img")({name:"StyledImage",class:"eds4xz4ib",propsAsIs:!1}),HM=Z("div")({name:"CenteringBlock",class:"edc1nwul5g",propsAsIs:!1}),WM=Z("img")({name:"NodeDescriptionImage",class:"ednk9d4jz",propsAsIs:!1}),qM=Z("span")({name:"ImageCaption",class:"ediz6of6y",propsAsIs:!1}),VM=Z("h1")({name:"Heading1",class:"edh1mrpu6g",propsAsIs:!1}),GM=Z("h2")({name:"Heading2",class:"edh4lzuk3",propsAsIs:!1}),YM=Z("h3")({name:"Heading3",class:"edhpo5zbv",propsAsIs:!1}),KM=Z("h4")({name:"Heading4",class:"edhm6a0je",propsAsIs:!1}),QM=Z("div")({name:"BlockWrapper",class:"edbaa4gm3",propsAsIs:!1}),XM=Z("div")({name:"Container",class:"edc1gv2nxr",propsAsIs:!1}),JM=Z("div")({name:"Header",class:"edh1ox5ey6",propsAsIs:!1}),ZM=Z("div")({name:"CodeBackground",class:"edc1pst60x",propsAsIs:!1}),e4=Z("div")({name:"CodeBlock",class:"edc1m8ekz6",propsAsIs:!1}),t4=Z("pre")({name:"Scrollable",class:"eds1002l4s",propsAsIs:!1}),n4=Z("span")({name:"LangName",class:"edllrx5n5",propsAsIs:!1});function Gl(e){var t=typeof e;return e!=null&&(t=="object"||t=="function")}var r4=typeof global=="object"&&global&&global.Object===Object&&global,s4=typeof self=="object"&&self&&self.Object===Object&&self,pv=r4||s4||Function("return this")(),Nf=function(){return pv.Date.now()},o4=/\s/;function i4(e){for(var t=e.length;t--&&o4.test(e.charAt(t)););return t}var a4=/^\s+/;function l4(e){return e&&e.slice(0,i4(e)+1).replace(a4,"")}var Yl=pv.Symbol,hv=Object.prototype,c4=hv.hasOwnProperty,u4=hv.toString,Ni=Yl?Yl.toStringTag:void 0;function d4(e){var t=c4.call(e,Ni),n=e[Ni];try{e[Ni]=void 0;var r=!0}catch{}var i=u4.call(e);return r&&(t?e[Ni]=n:delete e[Ni]),i}var f4=Object.prototype,p4=f4.toString;function h4(e){return p4.call(e)}var m4="[object Null]",g4="[object Undefined]",mv=Yl?Yl.toStringTag:void 0;function y4(e){return e==null?e===void 0?g4:m4:mv&&mv in Object(e)?d4(e):h4(e)}function v4(e){return e!=null&&typeof e=="object"}var S4="[object Symbol]";function w4(e){return typeof e=="symbol"||v4(e)&&y4(e)==S4}var gv=NaN,_4=/^[-+]0x[0-9a-f]+$/i,E4=/^0b[01]+$/i,x4=/^0o[0-7]+$/i,k4=parseInt;function yv(e){if(typeof e=="number")return e;if(w4(e))return gv;if(Gl(e)){var t=typeof e.valueOf=="function"?e.valueOf():e;e=Gl(t)?t+"":t}if(typeof e!="string")return e===0?e:+e;e=l4(e);var n=E4.test(e);return n||x4.test(e)?k4(e.slice(2),n?2:8):_4.test(e)?gv:+e}var T4="Expected a function",b4=Math.max,I4=Math.min;function Kl(e,t,n){var r,i,a,c,d,f,h=0,y=!1,g=!1,w=!0;if(typeof e!="function")throw new TypeError(T4);t=yv(t)||0,Gl(n)&&(y=!!n.leading,g="maxWait"in n,a=g?b4(yv(n.maxWait)||0,t):a,w="trailing"in n?!!n.trailing:w);function x(M){var L=r,U=i;return r=i=void 0,h=M,c=e.apply(U,L),c}function _(M){return h=M,d=setTimeout(O,t),y?x(M):c}function E(M){var L=M-f,U=M-h,te=t-L;return g?I4(te,a-U):te}function k(M){var L=M-f,U=M-h;return f===void 0||L>=t||L<0||g&&U>=a}function O(){var M=Nf();if(k(M))return R(M);d=setTimeout(O,E(M))}function R(M){return d=void 0,w&&r?x(M):(r=i=void 0,c)}function $(){d!==void 0&&clearTimeout(d),h=0,r=f=i=d=void 0}function H(){return d===void 0?c:R(Nf())}function z(){var M=Nf(),L=k(M);if(r=arguments,i=this,f=M,L){if(d===void 0)return _(f);if(g)return clearTimeout(d),d=setTimeout(O,t),x(f)}return d===void 0&&(d=setTimeout(O,t)),c}return z.cancel=$,z.flush=H,z}var C4="Expected a function";function R4(e,t,n){var r=!0,i=!0;if(typeof e!="function")throw new TypeError(C4);return Gl(n)&&(r="leading"in n?!!n.leading:r,i="trailing"in n?!!n.trailing:i),Kl(e,t,{leading:r,maxWait:t,trailing:i})}var Ro=function(){return Ro=Object.assign||function(t){for(var n,r=1,i=arguments.length;r<i;r++){n=arguments[r];for(var a in n)Object.prototype.hasOwnProperty.call(n,a)&&(t[a]=n[a])}return t},Ro.apply(this,arguments)};function vv(e){return!e||!e.ownerDocument||!e.ownerDocument.defaultView?window:e.ownerDocument.defaultView}function Sv(e){return!e||!e.ownerDocument?document:e.ownerDocument}var wv=function(e){var t={},n=Array.prototype.reduce.call(e,function(r,i){var a=i.name.match(/data-simplebar-(.+)/);if(a){var c=a[1].replace(/\W+(.)/g,function(d,f){return f.toUpperCase()});switch(i.value){case"true":r[c]=!0;break;case"false":r[c]=!1;break;case void 0:r[c]=!0;break;default:r[c]=i.value}}return r},t);return n};function _v(e,t){var n;e&&(n=e.classList).add.apply(n,t.split(" "))}function Ev(e,t){e&&t.split(" ").forEach(function(n){e.classList.remove(n)})}function xv(e){return".".concat(e.split(" ").join("."))}var Mf=!!(typeof window<"u"&&window.document&&window.document.createElement),A4=Object.freeze({__proto__:null,addClasses:_v,canUseDOM:Mf,classNamesToQuery:xv,getElementDocument:Sv,getElementWindow:vv,getOptions:wv,removeClasses:Ev}),Ao=null,kv=null;Mf&&window.addEventListener("resize",function(){kv!==window.devicePixelRatio&&(kv=window.devicePixelRatio,Ao=null)});function Tv(){if(Ao===null){if(typeof document>"u")return Ao=0,Ao;var e=document.body,t=document.createElement("div");t.classList.add("simplebar-hide-scrollbar"),e.appendChild(t);var n=t.getBoundingClientRect().right;e.removeChild(t),Ao=n}return Ao}var zr=vv,Lf=Sv,O4=wv,Ur=_v,Hr=Ev,Qt=xv,Mi=function(){function e(t,n){n===void 0&&(n={});var r=this;if(this.removePreventClickId=null,this.minScrollbarWidth=20,this.stopScrollDelay=175,this.isScrolling=!1,this.isMouseEntering=!1,this.isDragging=!1,this.scrollXTicking=!1,this.scrollYTicking=!1,this.wrapperEl=null,this.contentWrapperEl=null,this.contentEl=null,this.offsetEl=null,this.maskEl=null,this.placeholderEl=null,this.heightAutoObserverWrapperEl=null,this.heightAutoObserverEl=null,this.rtlHelpers=null,this.scrollbarWidth=0,this.resizeObserver=null,this.mutationObserver=null,this.elStyles=null,this.isRtl=null,this.mouseX=0,this.mouseY=0,this.onMouseMove=function(){},this.onWindowResize=function(){},this.onStopScrolling=function(){},this.onMouseEntered=function(){},this.onScroll=function(){var i=zr(r.el);r.scrollXTicking||(i.requestAnimationFrame(r.scrollX),r.scrollXTicking=!0),r.scrollYTicking||(i.requestAnimationFrame(r.scrollY),r.scrollYTicking=!0),r.isScrolling||(r.isScrolling=!0,Ur(r.el,r.classNames.scrolling)),r.showScrollbar("x"),r.showScrollbar("y"),r.onStopScrolling()},this.scrollX=function(){r.axis.x.isOverflowing&&r.positionScrollbar("x"),r.scrollXTicking=!1},this.scrollY=function(){r.axis.y.isOverflowing&&r.positionScrollbar("y"),r.scrollYTicking=!1},this._onStopScrolling=function(){Hr(r.el,r.classNames.scrolling),r.options.autoHide&&(r.hideScrollbar("x"),r.hideScrollbar("y")),r.isScrolling=!1},this.onMouseEnter=function(){r.isMouseEntering||(Ur(r.el,r.classNames.mouseEntered),r.showScrollbar("x"),r.showScrollbar("y"),r.isMouseEntering=!0),r.onMouseEntered()},this._onMouseEntered=function(){Hr(r.el,r.classNames.mouseEntered),r.options.autoHide&&(r.hideScrollbar("x"),r.hideScrollbar("y")),r.isMouseEntering=!1},this._onMouseMove=function(i){r.mouseX=i.clientX,r.mouseY=i.clientY,(r.axis.x.isOverflowing||r.axis.x.forceVisible)&&r.onMouseMoveForAxis("x"),(r.axis.y.isOverflowing||r.axis.y.forceVisible)&&r.onMouseMoveForAxis("y")},this.onMouseLeave=function(){r.onMouseMove.cancel(),(r.axis.x.isOverflowing||r.axis.x.forceVisible)&&r.onMouseLeaveForAxis("x"),(r.axis.y.isOverflowing||r.axis.y.forceVisible)&&r.onMouseLeaveForAxis("y"),r.mouseX=-1,r.mouseY=-1},this._onWindowResize=function(){r.scrollbarWidth=r.getScrollbarWidth(),r.hideNativeScrollbar()},this.onPointerEvent=function(i){if(!(!r.axis.x.track.el||!r.axis.y.track.el||!r.axis.x.scrollbar.el||!r.axis.y.scrollbar.el)){var a,c;r.axis.x.track.rect=r.axis.x.track.el.getBoundingClientRect(),r.axis.y.track.rect=r.axis.y.track.el.getBoundingClientRect(),(r.axis.x.isOverflowing||r.axis.x.forceVisible)&&(a=r.isWithinBounds(r.axis.x.track.rect)),(r.axis.y.isOverflowing||r.axis.y.forceVisible)&&(c=r.isWithinBounds(r.axis.y.track.rect)),(a||c)&&(i.stopPropagation(),i.type==="pointerdown"&&i.pointerType!=="touch"&&(a&&(r.axis.x.scrollbar.rect=r.axis.x.scrollbar.el.getBoundingClientRect(),r.isWithinBounds(r.axis.x.scrollbar.rect)?r.onDragStart(i,"x"):r.onTrackClick(i,"x")),c&&(r.axis.y.scrollbar.rect=r.axis.y.scrollbar.el.getBoundingClientRect(),r.isWithinBounds(r.axis.y.scrollbar.rect)?r.onDragStart(i,"y"):r.onTrackClick(i,"y"))))}},this.drag=function(i){var a,c,d,f,h,y,g,w,x,_,E;if(!(!r.draggedAxis||!r.contentWrapperEl)){var k,O=r.axis[r.draggedAxis].track,R=(c=(a=O.rect)===null||a===void 0?void 0:a[r.axis[r.draggedAxis].sizeAttr])!==null&&c!==void 0?c:0,$=r.axis[r.draggedAxis].scrollbar,H=(f=(d=r.contentWrapperEl)===null||d===void 0?void 0:d[r.axis[r.draggedAxis].scrollSizeAttr])!==null&&f!==void 0?f:0,z=parseInt((y=(h=r.elStyles)===null||h===void 0?void 0:h[r.axis[r.draggedAxis].sizeAttr])!==null&&y!==void 0?y:"0px",10);i.preventDefault(),i.stopPropagation(),r.draggedAxis==="y"?k=i.pageY:k=i.pageX;var M=k-((w=(g=O.rect)===null||g===void 0?void 0:g[r.axis[r.draggedAxis].offsetAttr])!==null&&w!==void 0?w:0)-r.axis[r.draggedAxis].dragOffset;M=r.draggedAxis==="x"&&r.isRtl?((_=(x=O.rect)===null||x===void 0?void 0:x[r.axis[r.draggedAxis].sizeAttr])!==null&&_!==void 0?_:0)-$.size-M:M;var L=M/(R-$.size),U=L*(H-z);r.draggedAxis==="x"&&r.isRtl&&(U=!((E=e.getRtlHelpers())===null||E===void 0)&&E.isScrollingToNegative?-U:U),r.contentWrapperEl[r.axis[r.draggedAxis].scrollOffsetAttr]=U}},this.onEndDrag=function(i){r.isDragging=!1;var a=Lf(r.el),c=zr(r.el);i.preventDefault(),i.stopPropagation(),Hr(r.el,r.classNames.dragging),r.onStopScrolling(),a.removeEventListener("mousemove",r.drag,!0),a.removeEventListener("mouseup",r.onEndDrag,!0),r.removePreventClickId=c.setTimeout(function(){a.removeEventListener("click",r.preventClick,!0),a.removeEventListener("dblclick",r.preventClick,!0),r.removePreventClickId=null})},this.preventClick=function(i){i.preventDefault(),i.stopPropagation()},this.el=t,this.options=Ro(Ro({},e.defaultOptions),n),this.classNames=Ro(Ro({},e.defaultOptions.classNames),n.classNames),this.axis={x:{scrollOffsetAttr:"scrollLeft",sizeAttr:"width",scrollSizeAttr:"scrollWidth",offsetSizeAttr:"offsetWidth",offsetAttr:"left",overflowAttr:"overflowX",dragOffset:0,isOverflowing:!0,forceVisible:!1,track:{size:null,el:null,rect:null,isVisible:!1},scrollbar:{size:null,el:null,rect:null,isVisible:!1}},y:{scrollOffsetAttr:"scrollTop",sizeAttr:"height",scrollSizeAttr:"scrollHeight",offsetSizeAttr:"offsetHeight",offsetAttr:"top",overflowAttr:"overflowY",dragOffset:0,isOverflowing:!0,forceVisible:!1,track:{size:null,el:null,rect:null,isVisible:!1},scrollbar:{size:null,el:null,rect:null,isVisible:!1}}},typeof this.el!="object"||!this.el.nodeName)throw new Error("Argument passed to SimpleBar must be an HTML element instead of ".concat(this.el));this.onMouseMove=R4(this._onMouseMove,64),this.onWindowResize=Kl(this._onWindowResize,64,{leading:!0}),this.onStopScrolling=Kl(this._onStopScrolling,this.stopScrollDelay),this.onMouseEntered=Kl(this._onMouseEntered,this.stopScrollDelay),this.init()}return e.getRtlHelpers=function(){if(e.rtlHelpers)return e.rtlHelpers;var t=document.createElement("div");t.innerHTML='<div class="simplebar-dummy-scrollbar-size"><div></div></div>';var n=t.firstElementChild,r=n==null?void 0:n.firstElementChild;if(!r)return null;document.body.appendChild(n),n.scrollLeft=0;var i=e.getOffset(n),a=e.getOffset(r);n.scrollLeft=-999;var c=e.getOffset(r);return document.body.removeChild(n),e.rtlHelpers={isScrollOriginAtZero:i.left!==a.left,isScrollingToNegative:a.left!==c.left},e.rtlHelpers},e.prototype.getScrollbarWidth=function(){try{return this.contentWrapperEl&&getComputedStyle(this.contentWrapperEl,"::-webkit-scrollbar").display==="none"||"scrollbarWidth"in document.documentElement.style||"-ms-overflow-style"in document.documentElement.style?0:Tv()}catch{return Tv()}},e.getOffset=function(t){var n=t.getBoundingClientRect(),r=Lf(t),i=zr(t);return{top:n.top+(i.pageYOffset||r.documentElement.scrollTop),left:n.left+(i.pageXOffset||r.documentElement.scrollLeft)}},e.prototype.init=function(){Mf&&(this.initDOM(),this.rtlHelpers=e.getRtlHelpers(),this.scrollbarWidth=this.getScrollbarWidth(),this.recalculate(),this.initListeners())},e.prototype.initDOM=function(){var t,n;this.wrapperEl=this.el.querySelector(Qt(this.classNames.wrapper)),this.contentWrapperEl=this.options.scrollableNode||this.el.querySelector(Qt(this.classNames.contentWrapper)),this.contentEl=this.options.contentNode||this.el.querySelector(Qt(this.classNames.contentEl)),this.offsetEl=this.el.querySelector(Qt(this.classNames.offset)),this.maskEl=this.el.querySelector(Qt(this.classNames.mask)),this.placeholderEl=this.findChild(this.wrapperEl,Qt(this.classNames.placeholder)),this.heightAutoObserverWrapperEl=this.el.querySelector(Qt(this.classNames.heightAutoObserverWrapperEl)),this.heightAutoObserverEl=this.el.querySelector(Qt(this.classNames.heightAutoObserverEl)),this.axis.x.track.el=this.findChild(this.el,"".concat(Qt(this.classNames.track)).concat(Qt(this.classNames.horizontal))),this.axis.y.track.el=this.findChild(this.el,"".concat(Qt(this.classNames.track)).concat(Qt(this.classNames.vertical))),this.axis.x.scrollbar.el=((t=this.axis.x.track.el)===null||t===void 0?void 0:t.querySelector(Qt(this.classNames.scrollbar)))||null,this.axis.y.scrollbar.el=((n=this.axis.y.track.el)===null||n===void 0?void 0:n.querySelector(Qt(this.classNames.scrollbar)))||null,this.options.autoHide||(Ur(this.axis.x.scrollbar.el,this.classNames.visible),Ur(this.axis.y.scrollbar.el,this.classNames.visible))},e.prototype.initListeners=function(){var t=this,n,r=zr(this.el);if(this.el.addEventListener("mouseenter",this.onMouseEnter),this.el.addEventListener("pointerdown",this.onPointerEvent,!0),this.el.addEventListener("mousemove",this.onMouseMove),this.el.addEventListener("mouseleave",this.onMouseLeave),(n=this.contentWrapperEl)===null||n===void 0||n.addEventListener("scroll",this.onScroll),r.addEventListener("resize",this.onWindowResize),!!this.contentEl){if(window.ResizeObserver){var i=!1,a=r.ResizeObserver||ResizeObserver;this.resizeObserver=new a(function(){i&&r.requestAnimationFrame(function(){t.recalculate()})}),this.resizeObserver.observe(this.el),this.resizeObserver.observe(this.contentEl),r.requestAnimationFrame(function(){i=!0})}this.mutationObserver=new r.MutationObserver(function(){r.requestAnimationFrame(function(){t.recalculate()})}),this.mutationObserver.observe(this.contentEl,{childList:!0,subtree:!0,characterData:!0})}},e.prototype.recalculate=function(){if(!(!this.heightAutoObserverEl||!this.contentEl||!this.contentWrapperEl||!this.wrapperEl||!this.placeholderEl)){var t=zr(this.el);this.elStyles=t.getComputedStyle(this.el),this.isRtl=this.elStyles.direction==="rtl";var n=this.contentEl.offsetWidth,r=this.heightAutoObserverEl.offsetHeight<=1,i=this.heightAutoObserverEl.offsetWidth<=1||n>0,a=this.contentWrapperEl.offsetWidth,c=this.elStyles.overflowX,d=this.elStyles.overflowY;this.contentEl.style.padding="".concat(this.elStyles.paddingTop," ").concat(this.elStyles.paddingRight," ").concat(this.elStyles.paddingBottom," ").concat(this.elStyles.paddingLeft),this.wrapperEl.style.margin="-".concat(this.elStyles.paddingTop," -").concat(this.elStyles.paddingRight," -").concat(this.elStyles.paddingBottom," -").concat(this.elStyles.paddingLeft);var f=this.contentEl.scrollHeight,h=this.contentEl.scrollWidth;this.contentWrapperEl.style.height=r?"auto":"100%",this.placeholderEl.style.width=i?"".concat(n||h,"px"):"auto",this.placeholderEl.style.height="".concat(f,"px");var y=this.contentWrapperEl.offsetHeight;this.axis.x.isOverflowing=n!==0&&h>n,this.axis.y.isOverflowing=f>y,this.axis.x.isOverflowing=c==="hidden"?!1:this.axis.x.isOverflowing,this.axis.y.isOverflowing=d==="hidden"?!1:this.axis.y.isOverflowing,this.axis.x.forceVisible=this.options.forceVisible==="x"||this.options.forceVisible===!0,this.axis.y.forceVisible=this.options.forceVisible==="y"||this.options.forceVisible===!0,this.hideNativeScrollbar();var g=this.axis.x.isOverflowing?this.scrollbarWidth:0,w=this.axis.y.isOverflowing?this.scrollbarWidth:0;this.axis.x.isOverflowing=this.axis.x.isOverflowing&&h>a-w,this.axis.y.isOverflowing=this.axis.y.isOverflowing&&f>y-g,this.axis.x.scrollbar.size=this.getScrollbarSize("x"),this.axis.y.scrollbar.size=this.getScrollbarSize("y"),this.axis.x.scrollbar.el&&(this.axis.x.scrollbar.el.style.width="".concat(this.axis.x.scrollbar.size,"px")),this.axis.y.scrollbar.el&&(this.axis.y.scrollbar.el.style.height="".concat(this.axis.y.scrollbar.size,"px")),this.positionScrollbar("x"),this.positionScrollbar("y"),this.toggleTrackVisibility("x"),this.toggleTrackVisibility("y")}},e.prototype.getScrollbarSize=function(t){var n,r;if(t===void 0&&(t="y"),!this.axis[t].isOverflowing||!this.contentEl)return 0;var i=this.contentEl[this.axis[t].scrollSizeAttr],a=(r=(n=this.axis[t].track.el)===null||n===void 0?void 0:n[this.axis[t].offsetSizeAttr])!==null&&r!==void 0?r:0,c=a/i,d;return d=Math.max(~~(c*a),this.options.scrollbarMinSize),this.options.scrollbarMaxSize&&(d=Math.min(d,this.options.scrollbarMaxSize)),d},e.prototype.positionScrollbar=function(t){var n,r,i;t===void 0&&(t="y");var a=this.axis[t].scrollbar;if(!(!this.axis[t].isOverflowing||!this.contentWrapperEl||!a.el||!this.elStyles)){var c=this.contentWrapperEl[this.axis[t].scrollSizeAttr],d=((n=this.axis[t].track.el)===null||n===void 0?void 0:n[this.axis[t].offsetSizeAttr])||0,f=parseInt(this.elStyles[this.axis[t].sizeAttr],10),h=this.contentWrapperEl[this.axis[t].scrollOffsetAttr];h=t==="x"&&this.isRtl&&(!((r=e.getRtlHelpers())===null||r===void 0)&&r.isScrollOriginAtZero)?-h:h,t==="x"&&this.isRtl&&(h=!((i=e.getRtlHelpers())===null||i===void 0)&&i.isScrollingToNegative?h:-h);var y=h/(c-f),g=~~((d-a.size)*y);g=t==="x"&&this.isRtl?-g+(d-a.size):g,a.el.style.transform=t==="x"?"translate3d(".concat(g,"px, 0, 0)"):"translate3d(0, ".concat(g,"px, 0)")}},e.prototype.toggleTrackVisibility=function(t){t===void 0&&(t="y");var n=this.axis[t].track.el,r=this.axis[t].scrollbar.el;!n||!r||!this.contentWrapperEl||(this.axis[t].isOverflowing||this.axis[t].forceVisible?(n.style.visibility="visible",this.contentWrapperEl.style[this.axis[t].overflowAttr]="scroll",this.el.classList.add("".concat(this.classNames.scrollable,"-").concat(t))):(n.style.visibility="hidden",this.contentWrapperEl.style[this.axis[t].overflowAttr]="hidden",this.el.classList.remove("".concat(this.classNames.scrollable,"-").concat(t))),this.axis[t].isOverflowing?r.style.display="block":r.style.display="none")},e.prototype.showScrollbar=function(t){t===void 0&&(t="y"),this.axis[t].isOverflowing&&!this.axis[t].scrollbar.isVisible&&(Ur(this.axis[t].scrollbar.el,this.classNames.visible),this.axis[t].scrollbar.isVisible=!0)},e.prototype.hideScrollbar=function(t){t===void 0&&(t="y"),!this.isDragging&&this.axis[t].isOverflowing&&this.axis[t].scrollbar.isVisible&&(Hr(this.axis[t].scrollbar.el,this.classNames.visible),this.axis[t].scrollbar.isVisible=!1)},e.prototype.hideNativeScrollbar=function(){this.offsetEl&&(this.offsetEl.style[this.isRtl?"left":"right"]=this.axis.y.isOverflowing||this.axis.y.forceVisible?"-".concat(this.scrollbarWidth,"px"):"0px",this.offsetEl.style.bottom=this.axis.x.isOverflowing||this.axis.x.forceVisible?"-".concat(this.scrollbarWidth,"px"):"0px")},e.prototype.onMouseMoveForAxis=function(t){t===void 0&&(t="y");var n=this.axis[t];!n.track.el||!n.scrollbar.el||(n.track.rect=n.track.el.getBoundingClientRect(),n.scrollbar.rect=n.scrollbar.el.getBoundingClientRect(),this.isWithinBounds(n.track.rect)?(this.showScrollbar(t),Ur(n.track.el,this.classNames.hover),this.isWithinBounds(n.scrollbar.rect)?Ur(n.scrollbar.el,this.classNames.hover):Hr(n.scrollbar.el,this.classNames.hover)):(Hr(n.track.el,this.classNames.hover),this.options.autoHide&&this.hideScrollbar(t)))},e.prototype.onMouseLeaveForAxis=function(t){t===void 0&&(t="y"),Hr(this.axis[t].track.el,this.classNames.hover),Hr(this.axis[t].scrollbar.el,this.classNames.hover),this.options.autoHide&&this.hideScrollbar(t)},e.prototype.onDragStart=function(t,n){var r;n===void 0&&(n="y"),this.isDragging=!0;var i=Lf(this.el),a=zr(this.el),c=this.axis[n].scrollbar,d=n==="y"?t.pageY:t.pageX;this.axis[n].dragOffset=d-(((r=c.rect)===null||r===void 0?void 0:r[this.axis[n].offsetAttr])||0),this.draggedAxis=n,Ur(this.el,this.classNames.dragging),i.addEventListener("mousemove",this.drag,!0),i.addEventListener("mouseup",this.onEndDrag,!0),this.removePreventClickId===null?(i.addEventListener("click",this.preventClick,!0),i.addEventListener("dblclick",this.preventClick,!0)):(a.clearTimeout(this.removePreventClickId),this.removePreventClickId=null)},e.prototype.onTrackClick=function(t,n){var r=this,i,a,c,d;n===void 0&&(n="y");var f=this.axis[n];if(!(!this.options.clickOnTrack||!f.scrollbar.el||!this.contentWrapperEl)){t.preventDefault();var h=zr(this.el);this.axis[n].scrollbar.rect=f.scrollbar.el.getBoundingClientRect();var y=this.axis[n].scrollbar,g=(a=(i=y.rect)===null||i===void 0?void 0:i[this.axis[n].offsetAttr])!==null&&a!==void 0?a:0,w=parseInt((d=(c=this.elStyles)===null||c===void 0?void 0:c[this.axis[n].sizeAttr])!==null&&d!==void 0?d:"0px",10),x=this.contentWrapperEl[this.axis[n].scrollOffsetAttr],_=n==="y"?this.mouseY-g:this.mouseX-g,E=_<0?-1:1,k=E===-1?x-w:x+w,O=40,R=function(){r.contentWrapperEl&&(E===-1?x>k&&(x-=O,r.contentWrapperEl[r.axis[n].scrollOffsetAttr]=x,h.requestAnimationFrame(R)):x<k&&(x+=O,r.contentWrapperEl[r.axis[n].scrollOffsetAttr]=x,h.requestAnimationFrame(R)))};R()}},e.prototype.getContentElement=function(){return this.contentEl},e.prototype.getScrollElement=function(){return this.contentWrapperEl},e.prototype.removeListeners=function(){var t=zr(this.el);this.el.removeEventListener("mouseenter",this.onMouseEnter),this.el.removeEventListener("pointerdown",this.onPointerEvent,!0),this.el.removeEventListener("mousemove",this.onMouseMove),this.el.removeEventListener("mouseleave",this.onMouseLeave),this.contentWrapperEl&&this.contentWrapperEl.removeEventListener("scroll",this.onScroll),t.removeEventListener("resize",this.onWindowResize),this.mutationObserver&&this.mutationObserver.disconnect(),this.resizeObserver&&this.resizeObserver.disconnect(),this.onMouseMove.cancel(),this.onWindowResize.cancel(),this.onStopScrolling.cancel(),this.onMouseEntered.cancel()},e.prototype.unMount=function(){this.removeListeners()},e.prototype.isWithinBounds=function(t){return this.mouseX>=t.left&&this.mouseX<=t.left+t.width&&this.mouseY>=t.top&&this.mouseY<=t.top+t.height},e.prototype.findChild=function(t,n){var r=t.matches||t.webkitMatchesSelector||t.mozMatchesSelector||t.msMatchesSelector;return Array.prototype.filter.call(t.children,function(i){return r.call(i,n)})[0]},e.rtlHelpers=null,e.defaultOptions={forceVisible:!1,clickOnTrack:!0,scrollbarMinSize:25,scrollbarMaxSize:0,ariaLabel:"scrollable content",tabIndex:0,classNames:{contentEl:"simplebar-content",contentWrapper:"simplebar-content-wrapper",offset:"simplebar-offset",mask:"simplebar-mask",wrapper:"simplebar-wrapper",placeholder:"simplebar-placeholder",scrollbar:"simplebar-scrollbar",track:"simplebar-track",heightAutoObserverWrapperEl:"simplebar-height-auto-observer-wrapper",heightAutoObserverEl:"simplebar-height-auto-observer",visible:"simplebar-visible",horizontal:"simplebar-horizontal",vertical:"simplebar-vertical",hover:"simplebar-hover",dragging:"simplebar-dragging",scrolling:"simplebar-scrolling",scrollable:"simplebar-scrollable",mouseEntered:"simplebar-mouse-entered"},scrollableNode:null,contentNode:null,autoHide:!0},e.getOptions=O4,e.helpers=A4,e}(),un=function(){return un=Object.assign||function(t){for(var n,r=1,i=arguments.length;r<i;r++){n=arguments[r];for(var a in n)Object.prototype.hasOwnProperty.call(n,a)&&(t[a]=n[a])}return t},un.apply(this,arguments)};function P4(e,t){var n={};for(var r in e)Object.prototype.hasOwnProperty.call(e,r)&&t.indexOf(r)<0&&(n[r]=e[r]);if(e!=null&&typeof Object.getOwnPropertySymbols=="function")for(var i=0,r=Object.getOwnPropertySymbols(e);i<r.length;i++)t.indexOf(r[i])<0&&Object.prototype.propertyIsEnumerable.call(e,r[i])&&(n[r[i]]=e[r[i]]);return n}var bv=C.forwardRef(function(e,t){var n=e.children,r=e.scrollableNodeProps,i=r===void 0?{}:r,a=P4(e,["children","scrollableNodeProps"]),c=C.useRef(),d=C.useRef(),f=C.useRef(),h={},y={};Object.keys(a).forEach(function(x){Object.prototype.hasOwnProperty.call(Mi.defaultOptions,x)?h[x]=a[x]:y[x]=a[x]});var g=un(un({},Mi.defaultOptions.classNames),h.classNames),w=un(un({},i),{className:"".concat(g.contentWrapper).concat(i.className?" ".concat(i.className):""),tabIndex:h.tabIndex||Mi.defaultOptions.tabIndex,role:"region","aria-label":h.ariaLabel||Mi.defaultOptions.ariaLabel});return C.useEffect(function(){var x;return d.current=w.ref?w.ref.current:d.current,c.current&&(x=new Mi(c.current,un(un(un({},h),d.current&&{scrollableNode:d.current}),f.current&&{contentNode:f.current})),typeof t=="function"?t(x):t&&(t.current=x)),function(){x==null||x.unMount(),x=null,typeof t=="function"&&t(null)}},[]),C.createElement("div",un({"data-simplebar":"init",ref:c},y),C.createElement("div",{className:g.wrapper},C.createElement("div",{className:g.heightAutoObserverWrapperEl},C.createElement("div",{className:g.heightAutoObserverEl})),C.createElement("div",{className:g.mask},C.createElement("div",{className:g.offset},typeof n=="function"?n({scrollableNodeRef:d,scrollableNodeProps:un(un({},w),{ref:d}),contentNodeRef:f,contentNodeProps:{className:g.contentEl,ref:f}}):C.createElement("div",un({},w),C.createElement("div",{className:g.contentEl},n)))),C.createElement("div",{className:g.placeholder})),C.createElement("div",{className:"".concat(g.track," ").concat(g.horizontal)},C.createElement("div",{className:g.scrollbar})),C.createElement("div",{className:"".concat(g.track," ").concat(g.vertical)},C.createElement("div",{className:g.scrollbar})))});bv.displayName="SimpleBar";const N4=Z("button")({name:"Container",class:"edc1q8nrja",propsAsIs:!1}),M4=Z("span")({name:"Text",class:"edt1votrxj",propsAsIs:!1}),L4=e=>C.createElement("svg",{xmlns:"http://www.w3.org/2000/svg",width:14,height:14,fill:"none",viewBox:"0 0 24 24",...e},C.createElement("path",{fill:"currentColor",d:"M16 9a1 1 0 0 0-1-1H5a1 1 0 0 0-1 1v10a1 1 0 0 0 1 1h10a1 1 0 0 0 1-1zm2 10a3 3 0 0 1-3 3H5a3 3 0 0 1-3-3V9a3 3 0 0 1 3-3h10a3 3 0 0 1 3 3z"}),C.createElement("path",{fill:"currentColor",d:"M19 2a3 3 0 0 1 3 3v10a3 3 0 0 1-2 2.825V5a1 1 0 0 0-1-1H6.174C6.586 2.835 7.694 2 9 2z"})),j4=e=>C.createElement("svg",{xmlns:"http://www.w3.org/2000/svg",width:14,height:14,fill:"none",viewBox:"0 0 24 24",...e},C.createElement("path",{fill:"currentColor",d:"M20.414 7.01 9.88 17.405l-6.293-6.21L4.99 9.771l4.888 4.824 9.132-9.01z"})),D4=({textToCopy:e})=>{const[t,n]=C.useState(!1),r=C.useRef(null),i=()=>{if(clearTimeout(r.current),t){n(!1);return}navigator.clipboard.writeText(e),n(!0),r.current=setTimeout(()=>{n(!1)},2e3)};return v.jsxs(N4,{style:{background:t?"var(--code-block-copied-button-bg)":"var(--code-block-copy-button-bg)"},onClick:i,children:[t?v.jsx(j4,{}):v.jsx(L4,{}),v.jsx(M4,{children:t?"copied":"copy"})]})},$4=({data:e})=>{const{html:t,language:n,code:r}=e,a=r.split(/\r?\n/).length>1,c=a?{width:"100%",maxHeight:"456px"}:{width:"100%",height:"auto"};return v.jsxs(XM,{children:[v.jsxs(JM,{children:[v.jsx(n4,{children:n||"code"}),v.jsx(D4,{textToCopy:r})]}),v.jsx(ZM,{style:c,children:v.jsx(bv,{autoHide:!1,style:c,children:v.jsx(e4,{children:v.jsx(t4,{style:{paddingRight:a?"20px":"10px"},children:v.jsx("div",{dangerouslySetInnerHTML:{__html:t}})})})})})]})},F4=/\[(.*?)\]/g,Iv=(e,t)=>e.replace(F4,(n,r)=>t[r]?`${t[r]}`:n),B4=e=>Object.keys(e).reduce((t,n)=>{const r=e[n],i=r.slice(1,r.length-1);return{...t,[i]:`[${n}]`}},{}),Cv=e=>C.useMemo(()=>{const t=B4(e);return{convertStringToReplacement:c=>Iv(c,e),convertStringToId:c=>Iv(c,t),convertIdToReplacement:c=>{const d=e[c];return d||c},convertReplacementToId:c=>{const d=t[c];return d||c}}},[e]),z4={1:VM,2:GM,3:YM,4:KM,5:"h5",6:"h6"},U4=({data:e,isEdgeText:t,replacements:n})=>{const{text:r,level:i}=e,{convertStringToReplacement:a}=Cv(n),c=z4[i];return v.jsx(c,{isEdgeText:t,children:a(r)})},H4=Z("li")({name:"ListItem",class:"edl18kdprd",propsAsIs:!1}),W4=Z("ol")({name:"OrderedList",class:"edoyxj7j5",propsAsIs:!1}),q4=Z("div")({name:"Row",class:"edr7e6b3z",propsAsIs:!1}),V4=Z("ul")({name:"UnorderedList",class:"eduyntbxa",propsAsIs:!1}),G4=e=>C.createElement("svg",{xmlns:"http://www.w3.org/2000/svg",width:18,height:18,fill:"none",viewBox:"0 0 24 24",...e},C.createElement("path",{fill:"currentColor",d:"M18 12a6 6 0 1 1-12 0 6 6 0 0 1 12 0"})),Y4=e=>C.createElement("svg",{xmlns:"http://www.w3.org/2000/svg",width:18,height:18,fill:"none",viewBox:"0 0 24 24",...e},C.createElement("path",{fill:"currentColor",fillRule:"evenodd",d:"M12 6a6 6 0 1 1 0 12 6 6 0 0 1 0-12m0 2a4 4 0 1 0 0 8 4 4 0 0 0 0-8",clipRule:"evenodd"})),K4=e=>C.createElement("svg",{xmlns:"http://www.w3.org/2000/svg",width:18,height:18,fill:"none",viewBox:"0 0 24 24",...e},C.createElement("path",{fill:"currentColor",d:"m19 12-7 7-7-7 7-7zM7.828 12 12 16.172 16.172 12 12 7.828z"})),Q4=Z("div")({name:"Container",class:"edc8c3d4h",propsAsIs:!1}),X4={0:v.jsx(G4,{}),1:v.jsx(Y4,{}),2:v.jsx(K4,{})},J4=({style:e,text:t,level:n})=>{const i=e==="ordered"?t:X4[(n-1)%3];return v.jsx(Q4,{children:i})},Z4=({data:e,replacements:t,isAnswer:n,isPrizeInfo:r,isPrizeDesc:i,isEdgeText:a,isJourneyWidgetText:c,isNodeDescription:d})=>{const{convertStringToReplacement:f}=Cv(t),{text:h}=e,y=f(h),g=Rv(y);let w;return n?w=MM:r?w=DM:i?w=$M:a?w=fv:c?w=LM:d?w=jM:w=NM,v.jsx(w,{dangerouslySetInnerHTML:{__html:g}})},Rv=e=>{const n=new DOMParser().parseFromString(`<div>${e}</div>`,"text/html");return n.querySelectorAll("a").forEach(i=>{i.setAttribute("target","_blank"),i.setAttribute("rel","noopener noreferrer")}),n.body.firstChild.innerHTML},eL=({data:e})=>{const{meta:t,items:n,style:r}=e,i=(a,c,d)=>{if(!a||a.length===0)return null;const f=r==="unordered"?V4:W4;return v.jsx(f,{counterType:t==null?void 0:t.counterType,children:a.map((h,y)=>{const g=d+(y+1)+".";return v.jsx(Tt.Fragment,{children:v.jsxs(H4,{style:{paddingLeft:c===1?"0px":"32px"},children:[v.jsxs(q4,{children:[v.jsx(J4,{style:r,level:c,text:g}),v.jsx("span",{dangerouslySetInnerHTML:{__html:Rv(h.content)}})]}),i(h.items,c+1,g)]})},y)})})};return v.jsx(v.Fragment,{children:i(n,1,"")})},tL=Z("blockquote")({name:"Container",class:"edc1pmqebe",propsAsIs:!1}),nL=Z("span")({name:"Content",class:"edcfeuydt",propsAsIs:!1}),rL=Z("div")({name:"CaptionBlock",class:"edcqx7kpx",propsAsIs:!1}),sL=e=>C.createElement("svg",{xmlns:"http://www.w3.org/2000/svg",width:24,height:24,...e},C.createElement("path",{fill:"currentColor",d:"M19.866 12.887V19h-6.078v-4.563q0-2.959.565-5.212A14.2 14.2 0 0 1 16.182 5H20q-1.398 2-2.124 4.028-.726 2-.726 3.86zm-9.789 0V19H4v-4.563q0-2.959.565-5.212T6.42 5h3.792Q8.813 7 8.06 9.028q-.726 2.028-.726 3.86z"})),oL=({data:e})=>v.jsxs(tL,{children:[v.jsx(sL,{}),v.jsx(nL,{children:e.quote}),v.jsxs(rL,{children:[v.jsx("p",{children:e.authorName}),v.jsx("p",{children:e.profession})]})]}),iL=({data:e})=>{const{content:t,withHeadings:n}=e;if(!Array.isArray(t)||t.length===0)return;const r=n?t[0]:null,i=n?t.slice(1):t;return v.jsxs(BM,{children:[r&&v.jsx("thead",{children:v.jsx("tr",{children:r.map((a,c)=>v.jsx("th",{children:a},c))})}),v.jsx("tbody",{children:i.map((a,c)=>v.jsx("tr",{children:a.map((d,f)=>v.jsx("td",{dangerouslySetInnerHTML:{__html:d||"—"}},f))},c))})]})},aL=({data:e,isNodeDescription:t})=>{const{file:{url:n},stretched:r,withBackground:i,withBorder:a,caption:c}=e;let d;t?d=WM:d=UM;const f=r?"auto":"400px",h=r?"100%":"fit-content";return v.jsxs(HM,{style:{alignItems:r?"center":"flex-start"},children:[v.jsx(zM,{style:{width:h},children:v.jsx(d,{src:n,alt:c??"test image",style:{width:h,height:f},fetchpriority:"high"})}),c&&v.jsx(qM,{children:c})]})},lL=({data:e})=>v.jsx("div",{dangerouslySetInnerHTML:{__html:e==null?void 0:e.html}}),cL=({data:e,replacements:t,...n})=>{const r=yS(e,t,n);return v.jsx(QM,{style:{gap:n.isJourneyWidgetText?"12px":"14px"},children:r})},uL=Z("a")({name:"Border",class:"edb1n9nuyu",propsAsIs:!1}),dL=Z("div")({name:"FaviconContainer",class:"edf33eea4",propsAsIs:!1}),fL=Z("img")({name:"Favicon",class:"edf1siw68p",propsAsIs:!1}),pL=Z("div")({name:"MetaBlock",class:"edm1u7odcx",propsAsIs:!1}),Av=Z("span")({name:"Text",class:"edt4nkw3z",propsAsIs:!1}),hL=Z(Av)({name:"BoldText",class:"edbz1s450",propsAsIs:!0}),mL=e=>C.createElement("svg",{xmlns:"http://www.w3.org/2000/svg",width:24,height:24,fill:"none",...e},C.createElement("path",{fill:"currentColor",d:"M20 19h-2V7.414L5.707 19.707l-1.414-1.414L16.586 6H5V4h15z"}));function Ov(e,t){return function(){return e.apply(t,arguments)}}const{toString:gL}=Object.prototype,{getPrototypeOf:jf}=Object,{iterator:Ql,toStringTag:Pv}=Symbol,Xl=(e=>t=>{const n=gL.call(t);return e[n]||(e[n]=n.slice(8,-1).toLowerCase())})(Object.create(null)),Nn=e=>(e=e.toLowerCase(),t=>Xl(t)===e),Jl=e=>t=>typeof t===e,{isArray:Oo}=Array,Li=Jl("undefined");function ji(e){return e!==null&&!Li(e)&&e.constructor!==null&&!Li(e.constructor)&&Xt(e.constructor.isBuffer)&&e.constructor.isBuffer(e)}const Nv=Nn("ArrayBuffer");function yL(e){let t;return typeof ArrayBuffer<"u"&&ArrayBuffer.isView?t=ArrayBuffer.isView(e):t=e&&e.buffer&&Nv(e.buffer),t}const vL=Jl("string"),Xt=Jl("function"),Mv=Jl("number"),Di=e=>e!==null&&typeof e=="object",SL=e=>e===!0||e===!1,Zl=e=>{if(Xl(e)!=="object")return!1;const t=jf(e);return(t===null||t===Object.prototype||Object.getPrototypeOf(t)===null)&&!(Pv in e)&&!(Ql in e)},wL=e=>{if(!Di(e)||ji(e))return!1;try{return Object.keys(e).length===0&&Object.getPrototypeOf(e)===Object.prototype}catch{return!1}},_L=Nn("Date"),EL=Nn("File"),xL=Nn("Blob"),kL=Nn("FileList"),TL=e=>Di(e)&&Xt(e.pipe),bL=e=>{let t;return e&&(typeof FormData=="function"&&e instanceof FormData||Xt(e.append)&&((t=Xl(e))==="formdata"||t==="object"&&Xt(e.toString)&&e.toString()==="[object FormData]"))},IL=Nn("URLSearchParams"),[CL,RL,AL,OL]=["ReadableStream","Request","Response","Headers"].map(Nn),PL=e=>e.trim?e.trim():e.replace(/^[\s\uFEFF\xA0]+|[\s\uFEFF\xA0]+$/g,"");function $i(e,t,{allOwnKeys:n=!1}={}){if(e===null||typeof e>"u")return;let r,i;if(typeof e!="object"&&(e=[e]),Oo(e))for(r=0,i=e.length;r<i;r++)t.call(null,e[r],r,e);else{if(ji(e))return;const a=n?Object.getOwnPropertyNames(e):Object.keys(e),c=a.length;let d;for(r=0;r<c;r++)d=a[r],t.call(null,e[d],d,e)}}function Lv(e,t){if(ji(e))return null;t=t.toLowerCase();const n=Object.keys(e);let r=n.length,i;for(;r-- >0;)if(i=n[r],t===i.toLowerCase())return i;return null}const As=typeof globalThis<"u"?globalThis:typeof self<"u"?self:typeof window<"u"?window:global,jv=e=>!Li(e)&&e!==As;function Df(){const{caseless:e}=jv(this)&&this||{},t={},n=(r,i)=>{const a=e&&Lv(t,i)||i;Zl(t[a])&&Zl(r)?t[a]=Df(t[a],r):Zl(r)?t[a]=Df({},r):Oo(r)?t[a]=r.slice():t[a]=r};for(let r=0,i=arguments.length;r<i;r++)arguments[r]&&$i(arguments[r],n);return t}const NL=(e,t,n,{allOwnKeys:r}={})=>($i(t,(i,a)=>{n&&Xt(i)?e[a]=Ov(i,n):e[a]=i},{allOwnKeys:r}),e),ML=e=>(e.charCodeAt(0)===65279&&(e=e.slice(1)),e),LL=(e,t,n,r)=>{e.prototype=Object.create(t.prototype,r),e.prototype.constructor=e,Object.defineProperty(e,"super",{value:t.prototype}),n&&Object.assign(e.prototype,n)},jL=(e,t,n,r)=>{let i,a,c;const d={};if(t=t||{},e==null)return t;do{for(i=Object.getOwnPropertyNames(e),a=i.length;a-- >0;)c=i[a],(!r||r(c,e,t))&&!d[c]&&(t[c]=e[c],d[c]=!0);e=n!==!1&&jf(e)}while(e&&(!n||n(e,t))&&e!==Object.prototype);return t},DL=(e,t,n)=>{e=String(e),(n===void 0||n>e.length)&&(n=e.length),n-=t.length;const r=e.indexOf(t,n);return r!==-1&&r===n},$L=e=>{if(!e)return null;if(Oo(e))return e;let t=e.length;if(!Mv(t))return null;const n=new Array(t);for(;t-- >0;)n[t]=e[t];return n},FL=(e=>t=>e&&t instanceof e)(typeof Uint8Array<"u"&&jf(Uint8Array)),BL=(e,t)=>{const r=(e&&e[Ql]).call(e);let i;for(;(i=r.next())&&!i.done;){const a=i.value;t.call(e,a[0],a[1])}},zL=(e,t)=>{let n;const r=[];for(;(n=e.exec(t))!==null;)r.push(n);return r},UL=Nn("HTMLFormElement"),HL=e=>e.toLowerCase().replace(/[-_\s]([a-z\d])(\w*)/g,function(n,r,i){return r.toUpperCase()+i}),Dv=(({hasOwnProperty:e})=>(t,n)=>e.call(t,n))(Object.prototype),WL=Nn("RegExp"),$v=(e,t)=>{const n=Object.getOwnPropertyDescriptors(e),r={};$i(n,(i,a)=>{let c;(c=t(i,a,e))!==!1&&(r[a]=c||i)}),Object.defineProperties(e,r)},qL=e=>{$v(e,(t,n)=>{if(Xt(e)&&["arguments","caller","callee"].indexOf(n)!==-1)return!1;const r=e[n];if(Xt(r)){if(t.enumerable=!1,"writable"in t){t.writable=!1;return}t.set||(t.set=()=>{throw Error("Can not rewrite read-only method '"+n+"'")})}})},VL=(e,t)=>{const n={},r=i=>{i.forEach(a=>{n[a]=!0})};return Oo(e)?r(e):r(String(e).split(t)),n},GL=()=>{},YL=(e,t)=>e!=null&&Number.isFinite(e=+e)?e:t;function KL(e){return!!(e&&Xt(e.append)&&e[Pv]==="FormData"&&e[Ql])}const QL=e=>{const t=new Array(10),n=(r,i)=>{if(Di(r)){if(t.indexOf(r)>=0)return;if(ji(r))return r;if(!("toJSON"in r)){t[i]=r;const a=Oo(r)?[]:{};return $i(r,(c,d)=>{const f=n(c,i+1);!Li(f)&&(a[d]=f)}),t[i]=void 0,a}}return r};return n(e,0)},XL=Nn("AsyncFunction"),JL=e=>e&&(Di(e)||Xt(e))&&Xt(e.then)&&Xt(e.catch),Fv=((e,t)=>e?setImmediate:t?((n,r)=>(As.addEventListener("message",({source:i,data:a})=>{i===As&&a===n&&r.length&&r.shift()()},!1),i=>{r.push(i),As.postMessage(n,"*")}))(`axios@${Math.random()}`,[]):n=>setTimeout(n))(typeof setImmediate=="function",Xt(As.postMessage)),ZL=typeof queueMicrotask<"u"?queueMicrotask.bind(As):typeof process<"u"&&process.nextTick||Fv,F={isArray:Oo,isArrayBuffer:Nv,isBuffer:ji,isFormData:bL,isArrayBufferView:yL,isString:vL,isNumber:Mv,isBoolean:SL,isObject:Di,isPlainObject:Zl,isEmptyObject:wL,isReadableStream:CL,isRequest:RL,isResponse:AL,isHeaders:OL,isUndefined:Li,isDate:_L,isFile:EL,isBlob:xL,isRegExp:WL,isFunction:Xt,isStream:TL,isURLSearchParams:IL,isTypedArray:FL,isFileList:kL,forEach:$i,merge:Df,extend:NL,trim:PL,stripBOM:ML,inherits:LL,toFlatObject:jL,kindOf:Xl,kindOfTest:Nn,endsWith:DL,toArray:$L,forEachEntry:BL,matchAll:zL,isHTMLForm:UL,hasOwnProperty:Dv,hasOwnProp:Dv,reduceDescriptors:$v,freezeMethods:qL,toObjectSet:VL,toCamelCase:HL,noop:GL,toFiniteNumber:YL,findKey:Lv,global:As,isContextDefined:jv,isSpecCompliantForm:KL,toJSONObject:QL,isAsyncFn:XL,isThenable:JL,setImmediate:Fv,asap:ZL,isIterable:e=>e!=null&&Xt(e[Ql])};function xe(e,t,n,r,i){Error.call(this),Error.captureStackTrace?Error.captureStackTrace(this,this.constructor):this.stack=new Error().stack,this.message=e,this.name="AxiosError",t&&(this.code=t),n&&(this.config=n),r&&(this.request=r),i&&(this.response=i,this.status=i.status?i.status:null)}F.inherits(xe,Error,{toJSON:function(){return{message:this.message,name:this.name,description:this.description,number:this.number,fileName:this.fileName,lineNumber:this.lineNumber,columnNumber:this.columnNumber,stack:this.stack,config:F.toJSONObject(this.config),code:this.code,status:this.status}}});const Bv=xe.prototype,zv={};["ERR_BAD_OPTION_VALUE","ERR_BAD_OPTION","ECONNABORTED","ETIMEDOUT","ERR_NETWORK","ERR_FR_TOO_MANY_REDIRECTS","ERR_DEPRECATED","ERR_BAD_RESPONSE","ERR_BAD_REQUEST","ERR_CANCELED","ERR_NOT_SUPPORT","ERR_INVALID_URL"].forEach(e=>{zv[e]={value:e}}),Object.defineProperties(xe,zv),Object.defineProperty(Bv,"isAxiosError",{value:!0}),xe.from=(e,t,n,r,i,a)=>{const c=Object.create(Bv);return F.toFlatObject(e,c,function(f){return f!==Error.prototype},d=>d!=="isAxiosError"),xe.call(c,e.message,t,n,r,i),c.cause=e,c.name=e.name,a&&Object.assign(c,a),c};const ej=null;function $f(e){return F.isPlainObject(e)||F.isArray(e)}function Uv(e){return F.endsWith(e,"[]")?e.slice(0,-2):e}function Hv(e,t,n){return e?e.concat(t).map(function(i,a){return i=Uv(i),!n&&a?"["+i+"]":i}).join(n?".":""):t}function tj(e){return F.isArray(e)&&!e.some($f)}const nj=F.toFlatObject(F,{},null,function(t){return/^is[A-Z]/.test(t)});function ec(e,t,n){if(!F.isObject(e))throw new TypeError("target must be an object");t=t||new FormData,n=F.toFlatObject(n,{metaTokens:!0,dots:!1,indexes:!1},!1,function(E,k){return!F.isUndefined(k[E])});const r=n.metaTokens,i=n.visitor||y,a=n.dots,c=n.indexes,f=(n.Blob||typeof Blob<"u"&&Blob)&&F.isSpecCompliantForm(t);if(!F.isFunction(i))throw new TypeError("visitor must be a function");function h(_){if(_===null)return"";if(F.isDate(_))return _.toISOString();if(F.isBoolean(_))return _.toString();if(!f&&F.isBlob(_))throw new xe("Blob is not supported. Use a Buffer instead.");return F.isArrayBuffer(_)||F.isTypedArray(_)?f&&typeof Blob=="function"?new Blob([_]):Buffer.from(_):_}function y(_,E,k){let O=_;if(_&&!k&&typeof _=="object"){if(F.endsWith(E,"{}"))E=r?E:E.slice(0,-2),_=JSON.stringify(_);else if(F.isArray(_)&&tj(_)||(F.isFileList(_)||F.endsWith(E,"[]"))&&(O=F.toArray(_)))return E=Uv(E),O.forEach(function($,H){!(F.isUndefined($)||$===null)&&t.append(c===!0?Hv([E],H,a):c===null?E:E+"[]",h($))}),!1}return $f(_)?!0:(t.append(Hv(k,E,a),h(_)),!1)}const g=[],w=Object.assign(nj,{defaultVisitor:y,convertValue:h,isVisitable:$f});function x(_,E){if(!F.isUndefined(_)){if(g.indexOf(_)!==-1)throw Error("Circular reference detected in "+E.join("."));g.push(_),F.forEach(_,function(O,R){(!(F.isUndefined(O)||O===null)&&i.call(t,O,F.isString(R)?R.trim():R,E,w))===!0&&x(O,E?E.concat(R):[R])}),g.pop()}}if(!F.isObject(e))throw new TypeError("data must be an object");return x(e),t}function Wv(e){const t={"!":"%21","'":"%27","(":"%28",")":"%29","~":"%7E","%20":"+","%00":"\0"};return encodeURIComponent(e).replace(/[!'()~]|%20|%00/g,function(r){return t[r]})}function Ff(e,t){this._pairs=[],e&&ec(e,this,t)}const qv=Ff.prototype;qv.append=function(t,n){this._pairs.push([t,n])},qv.toString=function(t){const n=t?function(r){return t.call(this,r,Wv)}:Wv;return this._pairs.map(function(i){return n(i[0])+"="+n(i[1])},"").join("&")};function rj(e){return encodeURIComponent(e).replace(/%3A/gi,":").replace(/%24/g,"$").replace(/%2C/gi,",").replace(/%20/g,"+").replace(/%5B/gi,"[").replace(/%5D/gi,"]")}function Vv(e,t,n){if(!t)return e;const r=n&&n.encode||rj;F.isFunction(n)&&(n={serialize:n});const i=n&&n.serialize;let a;if(i?a=i(t,n):a=F.isURLSearchParams(t)?t.toString():new Ff(t,n).toString(r),a){const c=e.indexOf("#");c!==-1&&(e=e.slice(0,c)),e+=(e.indexOf("?")===-1?"?":"&")+a}return e}class Gv{constructor(){this.handlers=[]}use(t,n,r){return this.handlers.push({fulfilled:t,rejected:n,synchronous:r?r.synchronous:!1,runWhen:r?r.runWhen:null}),this.handlers.length-1}eject(t){this.handlers[t]&&(this.handlers[t]=null)}clear(){this.handlers&&(this.handlers=[])}forEach(t){F.forEach(this.handlers,function(r){r!==null&&t(r)})}}const Yv={silentJSONParsing:!0,forcedJSONParsing:!0,clarifyTimeoutError:!1},sj={isBrowser:!0,classes:{URLSearchParams:typeof URLSearchParams<"u"?URLSearchParams:Ff,FormData:typeof FormData<"u"?FormData:null,Blob:typeof Blob<"u"?Blob:null},protocols:["http","https","file","blob","url","data"]},Bf=typeof window<"u"&&typeof document<"u",zf=typeof navigator=="object"&&navigator||void 0,oj=Bf&&(!zf||["ReactNative","NativeScript","NS"].indexOf(zf.product)<0),ij=typeof WorkerGlobalScope<"u"&&self instanceof WorkerGlobalScope&&typeof self.importScripts=="function",aj=Bf&&window.location.href||"http://localhost",Mt={...Object.freeze(Object.defineProperty({__proto__:null,hasBrowserEnv:Bf,hasStandardBrowserEnv:oj,hasStandardBrowserWebWorkerEnv:ij,navigator:zf,origin:aj},Symbol.toStringTag,{value:"Module"})),...sj};function lj(e,t){return ec(e,new Mt.classes.URLSearchParams,{visitor:function(n,r,i,a){return Mt.isNode&&F.isBuffer(n)?(this.append(r,n.toString("base64")),!1):a.defaultVisitor.apply(this,arguments)},...t})}function cj(e){return F.matchAll(/\w+|\[(\w*)]/g,e).map(t=>t[0]==="[]"?"":t[1]||t[0])}function uj(e){const t={},n=Object.keys(e);let r;const i=n.length;let a;for(r=0;r<i;r++)a=n[r],t[a]=e[a];return t}function Kv(e){function t(n,r,i,a){let c=n[a++];if(c==="__proto__")return!0;const d=Number.isFinite(+c),f=a>=n.length;return c=!c&&F.isArray(i)?i.length:c,f?(F.hasOwnProp(i,c)?i[c]=[i[c],r]:i[c]=r,!d):((!i[c]||!F.isObject(i[c]))&&(i[c]=[]),t(n,r,i[c],a)&&F.isArray(i[c])&&(i[c]=uj(i[c])),!d)}if(F.isFormData(e)&&F.isFunction(e.entries)){const n={};return F.forEachEntry(e,(r,i)=>{t(cj(r),i,n,0)}),n}return null}function dj(e,t,n){if(F.isString(e))try{return(t||JSON.parse)(e),F.trim(e)}catch(r){if(r.name!=="SyntaxError")throw r}return(0,JSON.stringify)(e)}const Fi={transitional:Yv,adapter:["xhr","http","fetch"],transformRequest:[function(t,n){const r=n.getContentType()||"",i=r.indexOf("application/json")>-1,a=F.isObject(t);if(a&&F.isHTMLForm(t)&&(t=new FormData(t)),F.isFormData(t))return i?JSON.stringify(Kv(t)):t;if(F.isArrayBuffer(t)||F.isBuffer(t)||F.isStream(t)||F.isFile(t)||F.isBlob(t)||F.isReadableStream(t))return t;if(F.isArrayBufferView(t))return t.buffer;if(F.isURLSearchParams(t))return n.setContentType("application/x-www-form-urlencoded;charset=utf-8",!1),t.toString();let d;if(a){if(r.indexOf("application/x-www-form-urlencoded")>-1)return lj(t,this.formSerializer).toString();if((d=F.isFileList(t))||r.indexOf("multipart/form-data")>-1){const f=this.env&&this.env.FormData;return ec(d?{"files[]":t}:t,f&&new f,this.formSerializer)}}return a||i?(n.setContentType("application/json",!1),dj(t)):t}],transformResponse:[function(t){const n=this.transitional||Fi.transitional,r=n&&n.forcedJSONParsing,i=this.responseType==="json";if(F.isResponse(t)||F.isReadableStream(t))return t;if(t&&F.isString(t)&&(r&&!this.responseType||i)){const c=!(n&&n.silentJSONParsing)&&i;try{return JSON.parse(t)}catch(d){if(c)throw d.name==="SyntaxError"?xe.from(d,xe.ERR_BAD_RESPONSE,this,null,this.response):d}}return t}],timeout:0,xsrfCookieName:"XSRF-TOKEN",xsrfHeaderName:"X-XSRF-TOKEN",maxContentLength:-1,maxBodyLength:-1,env:{FormData:Mt.classes.FormData,Blob:Mt.classes.Blob},validateStatus:function(t){return t>=200&&t<300},headers:{common:{Accept:"application/json, text/plain, */*","Content-Type":void 0}}};F.forEach(["delete","get","head","post","put","patch"],e=>{Fi.headers[e]={}});const fj=F.toObjectSet(["age","authorization","content-length","content-type","etag","expires","from","host","if-modified-since","if-unmodified-since","last-modified","location","max-forwards","proxy-authorization","referer","retry-after","user-agent"]),pj=e=>{const t={};let n,r,i;return e&&e.split(`
`).forEach(function(c){i=c.indexOf(":"),n=c.substring(0,i).trim().toLowerCase(),r=c.substring(i+1).trim(),!(!n||t[n]&&fj[n])&&(n==="set-cookie"?t[n]?t[n].push(r):t[n]=[r]:t[n]=t[n]?t[n]+", "+r:r)}),t},Qv=Symbol("internals");function Bi(e){return e&&String(e).trim().toLowerCase()}function tc(e){return e===!1||e==null?e:F.isArray(e)?e.map(tc):String(e)}function hj(e){const t=Object.create(null),n=/([^\s,;=]+)\s*(?:=\s*([^,;]+))?/g;let r;for(;r=n.exec(e);)t[r[1]]=r[2];return t}const mj=e=>/^[-_a-zA-Z0-9^`|~,!#$%&'*+.]+$/.test(e.trim());function Uf(e,t,n,r,i){if(F.isFunction(r))return r.call(this,t,n);if(i&&(t=n),!!F.isString(t)){if(F.isString(r))return t.indexOf(r)!==-1;if(F.isRegExp(r))return r.test(t)}}function gj(e){return e.trim().toLowerCase().replace(/([a-z\d])(\w*)/g,(t,n,r)=>n.toUpperCase()+r)}function yj(e,t){const n=F.toCamelCase(" "+t);["get","set","has"].forEach(r=>{Object.defineProperty(e,r+n,{value:function(i,a,c){return this[r].call(this,t,i,a,c)},configurable:!0})})}class Jt{constructor(t){t&&this.set(t)}set(t,n,r){const i=this;function a(d,f,h){const y=Bi(f);if(!y)throw new Error("header name must be a non-empty string");const g=F.findKey(i,y);(!g||i[g]===void 0||h===!0||h===void 0&&i[g]!==!1)&&(i[g||f]=tc(d))}const c=(d,f)=>F.forEach(d,(h,y)=>a(h,y,f));if(F.isPlainObject(t)||t instanceof this.constructor)c(t,n);else if(F.isString(t)&&(t=t.trim())&&!mj(t))c(pj(t),n);else if(F.isObject(t)&&F.isIterable(t)){let d={},f,h;for(const y of t){if(!F.isArray(y))throw TypeError("Object iterator must return a key-value pair");d[h=y[0]]=(f=d[h])?F.isArray(f)?[...f,y[1]]:[f,y[1]]:y[1]}c(d,n)}else t!=null&&a(n,t,r);return this}get(t,n){if(t=Bi(t),t){const r=F.findKey(this,t);if(r){const i=this[r];if(!n)return i;if(n===!0)return hj(i);if(F.isFunction(n))return n.call(this,i,r);if(F.isRegExp(n))return n.exec(i);throw new TypeError("parser must be boolean|regexp|function")}}}has(t,n){if(t=Bi(t),t){const r=F.findKey(this,t);return!!(r&&this[r]!==void 0&&(!n||Uf(this,this[r],r,n)))}return!1}delete(t,n){const r=this;let i=!1;function a(c){if(c=Bi(c),c){const d=F.findKey(r,c);d&&(!n||Uf(r,r[d],d,n))&&(delete r[d],i=!0)}}return F.isArray(t)?t.forEach(a):a(t),i}clear(t){const n=Object.keys(this);let r=n.length,i=!1;for(;r--;){const a=n[r];(!t||Uf(this,this[a],a,t,!0))&&(delete this[a],i=!0)}return i}normalize(t){const n=this,r={};return F.forEach(this,(i,a)=>{const c=F.findKey(r,a);if(c){n[c]=tc(i),delete n[a];return}const d=t?gj(a):String(a).trim();d!==a&&delete n[a],n[d]=tc(i),r[d]=!0}),this}concat(...t){return this.constructor.concat(this,...t)}toJSON(t){const n=Object.create(null);return F.forEach(this,(r,i)=>{r!=null&&r!==!1&&(n[i]=t&&F.isArray(r)?r.join(", "):r)}),n}[Symbol.iterator](){return Object.entries(this.toJSON())[Symbol.iterator]()}toString(){return Object.entries(this.toJSON()).map(([t,n])=>t+": "+n).join(`
`)}getSetCookie(){return this.get("set-cookie")||[]}get[Symbol.toStringTag](){return"AxiosHeaders"}static from(t){return t instanceof this?t:new this(t)}static concat(t,...n){const r=new this(t);return n.forEach(i=>r.set(i)),r}static accessor(t){const r=(this[Qv]=this[Qv]={accessors:{}}).accessors,i=this.prototype;function a(c){const d=Bi(c);r[d]||(yj(i,c),r[d]=!0)}return F.isArray(t)?t.forEach(a):a(t),this}}Jt.accessor(["Content-Type","Content-Length","Accept","Accept-Encoding","User-Agent","Authorization"]),F.reduceDescriptors(Jt.prototype,({value:e},t)=>{let n=t[0].toUpperCase()+t.slice(1);return{get:()=>e,set(r){this[n]=r}}}),F.freezeMethods(Jt);function Hf(e,t){const n=this||Fi,r=t||n,i=Jt.from(r.headers);let a=r.data;return F.forEach(e,function(d){a=d.call(n,a,i.normalize(),t?t.status:void 0)}),i.normalize(),a}function Xv(e){return!!(e&&e.__CANCEL__)}function Po(e,t,n){xe.call(this,e??"canceled",xe.ERR_CANCELED,t,n),this.name="CanceledError"}F.inherits(Po,xe,{__CANCEL__:!0});function Jv(e,t,n){const r=n.config.validateStatus;!n.status||!r||r(n.status)?e(n):t(new xe("Request failed with status code "+n.status,[xe.ERR_BAD_REQUEST,xe.ERR_BAD_RESPONSE][Math.floor(n.status/100)-4],n.config,n.request,n))}function vj(e){const t=/^([-+\w]{1,25})(:?\/\/|:)/.exec(e);return t&&t[1]||""}function Sj(e,t){e=e||10;const n=new Array(e),r=new Array(e);let i=0,a=0,c;return t=t!==void 0?t:1e3,function(f){const h=Date.now(),y=r[a];c||(c=h),n[i]=f,r[i]=h;let g=a,w=0;for(;g!==i;)w+=n[g++],g=g%e;if(i=(i+1)%e,i===a&&(a=(a+1)%e),h-c<t)return;const x=y&&h-y;return x?Math.round(w*1e3/x):void 0}}function wj(e,t){let n=0,r=1e3/t,i,a;const c=(h,y=Date.now())=>{n=y,i=null,a&&(clearTimeout(a),a=null),e(...h)};return[(...h)=>{const y=Date.now(),g=y-n;g>=r?c(h,y):(i=h,a||(a=setTimeout(()=>{a=null,c(i)},r-g)))},()=>i&&c(i)]}const nc=(e,t,n=3)=>{let r=0;const i=Sj(50,250);return wj(a=>{const c=a.loaded,d=a.lengthComputable?a.total:void 0,f=c-r,h=i(f),y=c<=d;r=c;const g={loaded:c,total:d,progress:d?c/d:void 0,bytes:f,rate:h||void 0,estimated:h&&d&&y?(d-c)/h:void 0,event:a,lengthComputable:d!=null,[t?"download":"upload"]:!0};e(g)},n)},Zv=(e,t)=>{const n=e!=null;return[r=>t[0]({lengthComputable:n,total:e,loaded:r}),t[1]]},eS=e=>(...t)=>F.asap(()=>e(...t)),_j=Mt.hasStandardBrowserEnv?((e,t)=>n=>(n=new URL(n,Mt.origin),e.protocol===n.protocol&&e.host===n.host&&(t||e.port===n.port)))(new URL(Mt.origin),Mt.navigator&&/(msie|trident)/i.test(Mt.navigator.userAgent)):()=>!0,Ej=Mt.hasStandardBrowserEnv?{write(e,t,n,r,i,a){const c=[e+"="+encodeURIComponent(t)];F.isNumber(n)&&c.push("expires="+new Date(n).toGMTString()),F.isString(r)&&c.push("path="+r),F.isString(i)&&c.push("domain="+i),a===!0&&c.push("secure"),document.cookie=c.join("; ")},read(e){const t=document.cookie.match(new RegExp("(^|;\\s*)("+e+")=([^;]*)"));return t?decodeURIComponent(t[3]):null},remove(e){this.write(e,"",Date.now()-864e5)}}:{write(){},read(){return null},remove(){}};function xj(e){return/^([a-z][a-z\d+\-.]*:)?\/\//i.test(e)}function kj(e,t){return t?e.replace(/\/?\/$/,"")+"/"+t.replace(/^\/+/,""):e}function tS(e,t,n){let r=!xj(t);return e&&(r||n==!1)?kj(e,t):t}const nS=e=>e instanceof Jt?{...e}:e;function Os(e,t){t=t||{};const n={};function r(h,y,g,w){return F.isPlainObject(h)&&F.isPlainObject(y)?F.merge.call({caseless:w},h,y):F.isPlainObject(y)?F.merge({},y):F.isArray(y)?y.slice():y}function i(h,y,g,w){if(F.isUndefined(y)){if(!F.isUndefined(h))return r(void 0,h,g,w)}else return r(h,y,g,w)}function a(h,y){if(!F.isUndefined(y))return r(void 0,y)}function c(h,y){if(F.isUndefined(y)){if(!F.isUndefined(h))return r(void 0,h)}else return r(void 0,y)}function d(h,y,g){if(g in t)return r(h,y);if(g in e)return r(void 0,h)}const f={url:a,method:a,data:a,baseURL:c,transformRequest:c,transformResponse:c,paramsSerializer:c,timeout:c,timeoutMessage:c,withCredentials:c,withXSRFToken:c,adapter:c,responseType:c,xsrfCookieName:c,xsrfHeaderName:c,onUploadProgress:c,onDownloadProgress:c,decompress:c,maxContentLength:c,maxBodyLength:c,beforeRedirect:c,transport:c,httpAgent:c,httpsAgent:c,cancelToken:c,socketPath:c,responseEncoding:c,validateStatus:d,headers:(h,y,g)=>i(nS(h),nS(y),g,!0)};return F.forEach(Object.keys({...e,...t}),function(y){const g=f[y]||i,w=g(e[y],t[y],y);F.isUndefined(w)&&g!==d||(n[y]=w)}),n}const rS=e=>{const t=Os({},e);let{data:n,withXSRFToken:r,xsrfHeaderName:i,xsrfCookieName:a,headers:c,auth:d}=t;t.headers=c=Jt.from(c),t.url=Vv(tS(t.baseURL,t.url,t.allowAbsoluteUrls),e.params,e.paramsSerializer),d&&c.set("Authorization","Basic "+btoa((d.username||"")+":"+(d.password?unescape(encodeURIComponent(d.password)):"")));let f;if(F.isFormData(n)){if(Mt.hasStandardBrowserEnv||Mt.hasStandardBrowserWebWorkerEnv)c.setContentType(void 0);else if((f=c.getContentType())!==!1){const[h,...y]=f?f.split(";").map(g=>g.trim()).filter(Boolean):[];c.setContentType([h||"multipart/form-data",...y].join("; "))}}if(Mt.hasStandardBrowserEnv&&(r&&F.isFunction(r)&&(r=r(t)),r||r!==!1&&_j(t.url))){const h=i&&a&&Ej.read(a);h&&c.set(i,h)}return t},Tj=typeof XMLHttpRequest<"u"&&function(e){return new Promise(function(n,r){const i=rS(e);let a=i.data;const c=Jt.from(i.headers).normalize();let{responseType:d,onUploadProgress:f,onDownloadProgress:h}=i,y,g,w,x,_;function E(){x&&x(),_&&_(),i.cancelToken&&i.cancelToken.unsubscribe(y),i.signal&&i.signal.removeEventListener("abort",y)}let k=new XMLHttpRequest;k.open(i.method.toUpperCase(),i.url,!0),k.timeout=i.timeout;function O(){if(!k)return;const $=Jt.from("getAllResponseHeaders"in k&&k.getAllResponseHeaders()),z={data:!d||d==="text"||d==="json"?k.responseText:k.response,status:k.status,statusText:k.statusText,headers:$,config:e,request:k};Jv(function(L){n(L),E()},function(L){r(L),E()},z),k=null}"onloadend"in k?k.onloadend=O:k.onreadystatechange=function(){!k||k.readyState!==4||k.status===0&&!(k.responseURL&&k.responseURL.indexOf("file:")===0)||setTimeout(O)},k.onabort=function(){k&&(r(new xe("Request aborted",xe.ECONNABORTED,e,k)),k=null)},k.onerror=function(){r(new xe("Network Error",xe.ERR_NETWORK,e,k)),k=null},k.ontimeout=function(){let H=i.timeout?"timeout of "+i.timeout+"ms exceeded":"timeout exceeded";const z=i.transitional||Yv;i.timeoutErrorMessage&&(H=i.timeoutErrorMessage),r(new xe(H,z.clarifyTimeoutError?xe.ETIMEDOUT:xe.ECONNABORTED,e,k)),k=null},a===void 0&&c.setContentType(null),"setRequestHeader"in k&&F.forEach(c.toJSON(),function(H,z){k.setRequestHeader(z,H)}),F.isUndefined(i.withCredentials)||(k.withCredentials=!!i.withCredentials),d&&d!=="json"&&(k.responseType=i.responseType),h&&([w,_]=nc(h,!0),k.addEventListener("progress",w)),f&&k.upload&&([g,x]=nc(f),k.upload.addEventListener("progress",g),k.upload.addEventListener("loadend",x)),(i.cancelToken||i.signal)&&(y=$=>{k&&(r(!$||$.type?new Po(null,e,k):$),k.abort(),k=null)},i.cancelToken&&i.cancelToken.subscribe(y),i.signal&&(i.signal.aborted?y():i.signal.addEventListener("abort",y)));const R=vj(i.url);if(R&&Mt.protocols.indexOf(R)===-1){r(new xe("Unsupported protocol "+R+":",xe.ERR_BAD_REQUEST,e));return}k.send(a||null)})},bj=(e,t)=>{const{length:n}=e=e?e.filter(Boolean):[];if(t||n){let r=new AbortController,i;const a=function(h){if(!i){i=!0,d();const y=h instanceof Error?h:this.reason;r.abort(y instanceof xe?y:new Po(y instanceof Error?y.message:y))}};let c=t&&setTimeout(()=>{c=null,a(new xe(`timeout ${t} of ms exceeded`,xe.ETIMEDOUT))},t);const d=()=>{e&&(c&&clearTimeout(c),c=null,e.forEach(h=>{h.unsubscribe?h.unsubscribe(a):h.removeEventListener("abort",a)}),e=null)};e.forEach(h=>h.addEventListener("abort",a));const{signal:f}=r;return f.unsubscribe=()=>F.asap(d),f}},Ij=function*(e,t){let n=e.byteLength;if(n<t){yield e;return}let r=0,i;for(;r<n;)i=r+t,yield e.slice(r,i),r=i},Cj=async function*(e,t){for await(const n of Rj(e))yield*Ij(n,t)},Rj=async function*(e){if(e[Symbol.asyncIterator]){yield*e;return}const t=e.getReader();try{for(;;){const{done:n,value:r}=await t.read();if(n)break;yield r}}finally{await t.cancel()}},sS=(e,t,n,r)=>{const i=Cj(e,t);let a=0,c,d=f=>{c||(c=!0,r&&r(f))};return new ReadableStream({async pull(f){try{const{done:h,value:y}=await i.next();if(h){d(),f.close();return}let g=y.byteLength;if(n){let w=a+=g;n(w)}f.enqueue(new Uint8Array(y))}catch(h){throw d(h),h}},cancel(f){return d(f),i.return()}},{highWaterMark:2})},rc=typeof fetch=="function"&&typeof Request=="function"&&typeof Response=="function",oS=rc&&typeof ReadableStream=="function",Aj=rc&&(typeof TextEncoder=="function"?(e=>t=>e.encode(t))(new TextEncoder):async e=>new Uint8Array(await new Response(e).arrayBuffer())),iS=(e,...t)=>{try{return!!e(...t)}catch{return!1}},Oj=oS&&iS(()=>{let e=!1;const t=new Request(Mt.origin,{body:new ReadableStream,method:"POST",get duplex(){return e=!0,"half"}}).headers.has("Content-Type");return e&&!t}),aS=64*1024,Wf=oS&&iS(()=>F.isReadableStream(new Response("").body)),sc={stream:Wf&&(e=>e.body)};rc&&(e=>{["text","arrayBuffer","blob","formData","stream"].forEach(t=>{!sc[t]&&(sc[t]=F.isFunction(e[t])?n=>n[t]():(n,r)=>{throw new xe(`Response type '${t}' is not supported`,xe.ERR_NOT_SUPPORT,r)})})})(new Response);const Pj=async e=>{if(e==null)return 0;if(F.isBlob(e))return e.size;if(F.isSpecCompliantForm(e))return(await new Request(Mt.origin,{method:"POST",body:e}).arrayBuffer()).byteLength;if(F.isArrayBufferView(e)||F.isArrayBuffer(e))return e.byteLength;if(F.isURLSearchParams(e)&&(e=e+""),F.isString(e))return(await Aj(e)).byteLength},Nj=async(e,t)=>{const n=F.toFiniteNumber(e.getContentLength());return n??Pj(t)},qf={http:ej,xhr:Tj,fetch:rc&&(async e=>{let{url:t,method:n,data:r,signal:i,cancelToken:a,timeout:c,onDownloadProgress:d,onUploadProgress:f,responseType:h,headers:y,withCredentials:g="same-origin",fetchOptions:w}=rS(e);h=h?(h+"").toLowerCase():"text";let x=bj([i,a&&a.toAbortSignal()],c),_;const E=x&&x.unsubscribe&&(()=>{x.unsubscribe()});let k;try{if(f&&Oj&&n!=="get"&&n!=="head"&&(k=await Nj(y,r))!==0){let z=new Request(t,{method:"POST",body:r,duplex:"half"}),M;if(F.isFormData(r)&&(M=z.headers.get("content-type"))&&y.setContentType(M),z.body){const[L,U]=Zv(k,nc(eS(f)));r=sS(z.body,aS,L,U)}}F.isString(g)||(g=g?"include":"omit");const O="credentials"in Request.prototype;_=new Request(t,{...w,signal:x,method:n.toUpperCase(),headers:y.normalize().toJSON(),body:r,duplex:"half",credentials:O?g:void 0});let R=await fetch(_,w);const $=Wf&&(h==="stream"||h==="response");if(Wf&&(d||$&&E)){const z={};["status","statusText","headers"].forEach(te=>{z[te]=R[te]});const M=F.toFiniteNumber(R.headers.get("content-length")),[L,U]=d&&Zv(M,nc(eS(d),!0))||[];R=new Response(sS(R.body,aS,L,()=>{U&&U(),E&&E()}),z)}h=h||"text";let H=await sc[F.findKey(sc,h)||"text"](R,e);return!$&&E&&E(),await new Promise((z,M)=>{Jv(z,M,{data:H,headers:Jt.from(R.headers),status:R.status,statusText:R.statusText,config:e,request:_})})}catch(O){throw E&&E(),O&&O.name==="TypeError"&&/Load failed|fetch/i.test(O.message)?Object.assign(new xe("Network Error",xe.ERR_NETWORK,e,_),{cause:O.cause||O}):xe.from(O,O&&O.code,e,_)}})};F.forEach(qf,(e,t)=>{if(e){try{Object.defineProperty(e,"name",{value:t})}catch{}Object.defineProperty(e,"adapterName",{value:t})}});const lS=e=>`- ${e}`,Mj=e=>F.isFunction(e)||e===null||e===!1,cS={getAdapter:e=>{e=F.isArray(e)?e:[e];const{length:t}=e;let n,r;const i={};for(let a=0;a<t;a++){n=e[a];let c;if(r=n,!Mj(n)&&(r=qf[(c=String(n)).toLowerCase()],r===void 0))throw new xe(`Unknown adapter '${c}'`);if(r)break;i[c||"#"+a]=r}if(!r){const a=Object.entries(i).map(([d,f])=>`adapter ${d} `+(f===!1?"is not supported by the environment":"is not available in the build"));let c=t?a.length>1?`since :
`+a.map(lS).join(`
`):" "+lS(a[0]):"as no adapter specified";throw new xe("There is no suitable adapter to dispatch the request "+c,"ERR_NOT_SUPPORT")}return r},adapters:qf};function Vf(e){if(e.cancelToken&&e.cancelToken.throwIfRequested(),e.signal&&e.signal.aborted)throw new Po(null,e)}function uS(e){return Vf(e),e.headers=Jt.from(e.headers),e.data=Hf.call(e,e.transformRequest),["post","put","patch"].indexOf(e.method)!==-1&&e.headers.setContentType("application/x-www-form-urlencoded",!1),cS.getAdapter(e.adapter||Fi.adapter)(e).then(function(r){return Vf(e),r.data=Hf.call(e,e.transformResponse,r),r.headers=Jt.from(r.headers),r},function(r){return Xv(r)||(Vf(e),r&&r.response&&(r.response.data=Hf.call(e,e.transformResponse,r.response),r.response.headers=Jt.from(r.response.headers))),Promise.reject(r)})}const dS="1.11.0",oc={};["object","boolean","number","function","string","symbol"].forEach((e,t)=>{oc[e]=function(r){return typeof r===e||"a"+(t<1?"n ":" ")+e}});const fS={};oc.transitional=function(t,n,r){function i(a,c){return"[Axios v"+dS+"] Transitional option '"+a+"'"+c+(r?". "+r:"")}return(a,c,d)=>{if(t===!1)throw new xe(i(c," has been removed"+(n?" in "+n:"")),xe.ERR_DEPRECATED);return n&&!fS[c]&&(fS[c]=!0,console.warn(i(c," has been deprecated since v"+n+" and will be removed in the near future"))),t?t(a,c,d):!0}},oc.spelling=function(t){return(n,r)=>(console.warn(`${r} is likely a misspelling of ${t}`),!0)};function Lj(e,t,n){if(typeof e!="object")throw new xe("options must be an object",xe.ERR_BAD_OPTION_VALUE);const r=Object.keys(e);let i=r.length;for(;i-- >0;){const a=r[i],c=t[a];if(c){const d=e[a],f=d===void 0||c(d,a,e);if(f!==!0)throw new xe("option "+a+" must be "+f,xe.ERR_BAD_OPTION_VALUE);continue}if(n!==!0)throw new xe("Unknown option "+a,xe.ERR_BAD_OPTION)}}const ic={assertOptions:Lj,validators:oc},Yn=ic.validators;class Ps{constructor(t){this.defaults=t||{},this.interceptors={request:new Gv,response:new Gv}}async request(t,n){try{return await this._request(t,n)}catch(r){if(r instanceof Error){let i={};Error.captureStackTrace?Error.captureStackTrace(i):i=new Error;const a=i.stack?i.stack.replace(/^.+\n/,""):"";try{r.stack?a&&!String(r.stack).endsWith(a.replace(/^.+\n.+\n/,""))&&(r.stack+=`
`+a):r.stack=a}catch{}}throw r}}_request(t,n){typeof t=="string"?(n=n||{},n.url=t):n=t||{},n=Os(this.defaults,n);const{transitional:r,paramsSerializer:i,headers:a}=n;r!==void 0&&ic.assertOptions(r,{silentJSONParsing:Yn.transitional(Yn.boolean),forcedJSONParsing:Yn.transitional(Yn.boolean),clarifyTimeoutError:Yn.transitional(Yn.boolean)},!1),i!=null&&(F.isFunction(i)?n.paramsSerializer={serialize:i}:ic.assertOptions(i,{encode:Yn.function,serialize:Yn.function},!0)),n.allowAbsoluteUrls!==void 0||(this.defaults.allowAbsoluteUrls!==void 0?n.allowAbsoluteUrls=this.defaults.allowAbsoluteUrls:n.allowAbsoluteUrls=!0),ic.assertOptions(n,{baseUrl:Yn.spelling("baseURL"),withXsrfToken:Yn.spelling("withXSRFToken")},!0),n.method=(n.method||this.defaults.method||"get").toLowerCase();let c=a&&F.merge(a.common,a[n.method]);a&&F.forEach(["delete","get","head","post","put","patch","common"],_=>{delete a[_]}),n.headers=Jt.concat(c,a);const d=[];let f=!0;this.interceptors.request.forEach(function(E){typeof E.runWhen=="function"&&E.runWhen(n)===!1||(f=f&&E.synchronous,d.unshift(E.fulfilled,E.rejected))});const h=[];this.interceptors.response.forEach(function(E){h.push(E.fulfilled,E.rejected)});let y,g=0,w;if(!f){const _=[uS.bind(this),void 0];for(_.unshift(...d),_.push(...h),w=_.length,y=Promise.resolve(n);g<w;)y=y.then(_[g++],_[g++]);return y}w=d.length;let x=n;for(g=0;g<w;){const _=d[g++],E=d[g++];try{x=_(x)}catch(k){E.call(this,k);break}}try{y=uS.call(this,x)}catch(_){return Promise.reject(_)}for(g=0,w=h.length;g<w;)y=y.then(h[g++],h[g++]);return y}getUri(t){t=Os(this.defaults,t);const n=tS(t.baseURL,t.url,t.allowAbsoluteUrls);return Vv(n,t.params,t.paramsSerializer)}}F.forEach(["delete","get","head","options"],function(t){Ps.prototype[t]=function(n,r){return this.request(Os(r||{},{method:t,url:n,data:(r||{}).data}))}}),F.forEach(["post","put","patch"],function(t){function n(r){return function(a,c,d){return this.request(Os(d||{},{method:t,headers:r?{"Content-Type":"multipart/form-data"}:{},url:a,data:c}))}}Ps.prototype[t]=n(),Ps.prototype[t+"Form"]=n(!0)});class Gf{constructor(t){if(typeof t!="function")throw new TypeError("executor must be a function.");let n;this.promise=new Promise(function(a){n=a});const r=this;this.promise.then(i=>{if(!r._listeners)return;let a=r._listeners.length;for(;a-- >0;)r._listeners[a](i);r._listeners=null}),this.promise.then=i=>{let a;const c=new Promise(d=>{r.subscribe(d),a=d}).then(i);return c.cancel=function(){r.unsubscribe(a)},c},t(function(a,c,d){r.reason||(r.reason=new Po(a,c,d),n(r.reason))})}throwIfRequested(){if(this.reason)throw this.reason}subscribe(t){if(this.reason){t(this.reason);return}this._listeners?this._listeners.push(t):this._listeners=[t]}unsubscribe(t){if(!this._listeners)return;const n=this._listeners.indexOf(t);n!==-1&&this._listeners.splice(n,1)}toAbortSignal(){const t=new AbortController,n=r=>{t.abort(r)};return this.subscribe(n),t.signal.unsubscribe=()=>this.unsubscribe(n),t.signal}static source(){let t;return{token:new Gf(function(i){t=i}),cancel:t}}}function jj(e){return function(n){return e.apply(null,n)}}function Dj(e){return F.isObject(e)&&e.isAxiosError===!0}const Yf={Continue:100,SwitchingProtocols:101,Processing:102,EarlyHints:103,Ok:200,Created:201,Accepted:202,NonAuthoritativeInformation:203,NoContent:204,ResetContent:205,PartialContent:206,MultiStatus:207,AlreadyReported:208,ImUsed:226,MultipleChoices:300,MovedPermanently:301,Found:302,SeeOther:303,NotModified:304,UseProxy:305,Unused:306,TemporaryRedirect:307,PermanentRedirect:308,BadRequest:400,Unauthorized:401,PaymentRequired:402,Forbidden:403,NotFound:404,MethodNotAllowed:405,NotAcceptable:406,ProxyAuthenticationRequired:407,RequestTimeout:408,Conflict:409,Gone:410,LengthRequired:411,PreconditionFailed:412,PayloadTooLarge:413,UriTooLong:414,UnsupportedMediaType:415,RangeNotSatisfiable:416,ExpectationFailed:417,ImATeapot:418,MisdirectedRequest:421,UnprocessableEntity:422,Locked:423,FailedDependency:424,TooEarly:425,UpgradeRequired:426,PreconditionRequired:428,TooManyRequests:429,RequestHeaderFieldsTooLarge:431,UnavailableForLegalReasons:451,InternalServerError:500,NotImplemented:501,BadGateway:502,ServiceUnavailable:503,GatewayTimeout:504,HttpVersionNotSupported:505,VariantAlsoNegotiates:506,InsufficientStorage:507,LoopDetected:508,NotExtended:510,NetworkAuthenticationRequired:511};Object.entries(Yf).forEach(([e,t])=>{Yf[t]=e});function pS(e){const t=new Ps(e),n=Ov(Ps.prototype.request,t);return F.extend(n,Ps.prototype,t,{allOwnKeys:!0}),F.extend(n,t,null,{allOwnKeys:!0}),n.create=function(i){return pS(Os(e,i))},n}const it=pS(Fi);it.Axios=Ps,it.CanceledError=Po,it.CancelToken=Gf,it.isCancel=Xv,it.VERSION=dS,it.toFormData=ec,it.AxiosError=xe,it.Cancel=it.CanceledError,it.all=function(t){return Promise.all(t)},it.spread=jj,it.isAxiosError=Dj,it.mergeConfig=Os,it.AxiosHeaders=Jt,it.formToJSON=e=>Kv(F.isHTMLForm(e)?new FormData(e):e),it.getAdapter=cS.getAdapter,it.HttpStatusCode=Yf,it.default=it;const hS="https://api.edmap.space",ac=it.create();ac.defaults.baseURL=hS,ac.interceptors.request.use(async e=>{const t=localStorage.getItem("access");return e.headers.Accept="application/json",t&&(e.headers.Authorization=`Bearer ${t}`),e},e=>Promise.reject(e));const zi={};function mS(e){return localStorage.removeItem("access"),localStorage.removeItem("refresh"),localStorage.removeItem("userId"),window.location.href="/sign-in",Promise.reject(e)}function gS(e,t){const n=e.data.accessToken,r=e.data.refreshToken;return localStorage.setItem("access",n),localStorage.setItem("refresh",r),t.headers||(t.headers={}),t.headers.Authorization=`Bearer ${n}`,ac(t)}ac.interceptors.response.use(e=>e,async e=>{const t=e.config;if(t.url.startsWith("/admin/login")||e.response.status!==401||t._retry)return Promise.reject(e);t._retry=!0;const n=localStorage.getItem("refresh");if(n)try{if(!zi.time||Date.now()-zi.time>1e3*3){const i=it.post(`${hS}/auth/revalidate-token`,{refreshToken:n},{headers:{Authorization:`Bearer ${n}`}});zi.time=Date.now(),zi.request=i;const a=await i;return gS(a,t)}const r=await zi.request;if(!r)throw new Error;return gS(r,t)}catch(r){return mS(r)}else return mS(e)});const $j=e=>{if(!e)return"";try{const n=e.startsWith("http://")||e.startsWith("https://")?e:`https://${e}`;let i=new URL(n).hostname;return i=i.replace(/^www\./i,""),i.includes(".")||(i+=".com"),i}catch{let n=e.replace(/^https?:\/\//i,"").replace(/^www\./i,"");return n=n.split(/[\/?#]/)[0],n&&!n.includes(".")&&(n+=".com"),n||""}},Fj=({data:e})=>v.jsxs(uL,{href:e.url,target:"_blank",children:[v.jsx(dL,{children:v.jsx(fL,{src:`https://www.google.com/s2/favicons?sz=64&domain_url=${encodeURIComponent(e.url)}`,alt:"favicon"})}),v.jsxs(pL,{children:[v.jsx(Av,{children:$j(e.url)}),v.jsx(hL,{children:e.title})]}),v.jsx(mL,{})]}),Bj=Z("div")({name:"Container",class:"edc85czkw",propsAsIs:!1}),zj=({data:e})=>v.jsxs(Bj,{role:"alert",children:[v.jsx("p",{children:e.message}),v.jsx("p",{children:e.title})]}),Uj=e=>{const t=[];for(let n=0;n<e.length;n++){if(e[n].type!=="header"){t.push(e[n]);continue}const r={id:e[n].id,data:[e[n]],type:"mergedHeaderAndParagraph"};let i=!1;for(let a=n+1;a<e.length&&!i;a++){if(e[a].type!=="paragraph"){i=!0;continue}r.data.push(e[a]),n++}t.push(r)}return t},Hj=e=>{if(e==="paragraph")return Z4;if(e==="list")return eL;if(e==="quote")return oL;if(e==="header")return U4;if(e==="mergedHeaderAndParagraph")return cL;if(e==="code")return $4;if(e==="table")return iL;if(e==="image")return aL;if(e==="linkBlock")return Fj;if(e==="warning")return zj;if(e==="raw")return lL},yS=(e,t,n)=>{const r=[];return e.forEach(({id:i,data:a,type:c})=>{const d=Hj(c),f=d?v.jsx(d,{data:a,replacements:t,...n},i):null;r.push(f)}),r},Ui=({blocksArray:e,replacements:t={},...n})=>{if(!e||!Array.isArray(e))return;const r=Uj(e),i=yS(r,t,n);return v.jsx(FM,{...n,children:i})},vS=()=>{const e=ln(i=>i.isRichTextModalOpen),t=ln(i=>i.closeModalForRichText),n=ln(i=>i.richTextBlocks),r=C.useRef(null);if(C.useEffect(()=>{const i=a=>{r.current&&!r.current.contains(a.target)&&t()};return e?document.addEventListener("mousedown",i):document.removeEventListener("mousedown",i),()=>{document.removeEventListener("mousedown",i)}},[e]),!!e)return v.jsx(AM,{children:v.jsxs(OM,{ref:r,children:[v.jsx(PM,{onClick:t,children:"✕"}),v.jsx(Ui,{blocksArray:n,isPrizeDesc:!0})]})})},Wj=j("div")({name:"Container",class:"edc1uixbmy",propsAsIs:!1}),qj=j("ul")({name:"List",class:"edl1h2mntg",propsAsIs:!1}),Vj=j("div")({name:"Wrapper",class:"edwkqefnd",propsAsIs:!1}),Gj=j("li")({name:"Participant",class:"edp1m90lkb",propsAsIs:!1}),Yj=j("li")({name:"ParticipantPosition",class:"edplp9wkn",propsAsIs:!1}),Kj=j("div")({name:"ParticipantWrapper",class:"edpi7ekwg",propsAsIs:!1}),Qj=j("div")({name:"PointsWrapper",class:"edp8vzmbe",propsAsIs:!1}),Xj=j("p")({name:"Points",class:"edpnrrx6w",propsAsIs:!1}),Jj=j("div")({name:"LoaderWrapper",class:"edli7avpg",propsAsIs:!1}),Zj=()=>v.jsx("svg",{width:"20",height:"21",viewBox:"0 0 20 21",fill:"none",xmlns:"http://www.w3.org/2000/svg",children:v.jsx("path",{d:"M8.85595 3.09539C9.2085 1.97699 10.7925 1.97699 11.1451 3.09539L12.2384 6.56383C12.3958 7.06308 12.8591 7.40262 13.383 7.40262L16.9987 7.40263C18.1521 7.40263 18.6413 8.86985 17.7184 9.56103L14.7296 11.7993C14.3221 12.1045 14.1517 12.6335 14.3048 13.1189L15.4311 16.692C15.7814 17.8032 14.4999 18.7103 13.5668 18.0116L10.7202 15.8798C10.2937 15.5604 9.70737 15.5604 9.28082 15.8798L6.43425 18.0116C5.5012 18.7103 4.21968 17.8032 4.56997 16.692L5.6963 13.1189C5.8493 12.6335 5.67898 12.1045 5.27143 11.7993L2.28267 9.56103C1.35974 8.86985 1.84897 7.40263 3.00238 7.40263L6.61804 7.40262C7.14191 7.40262 7.60524 7.06308 7.76262 6.56383L8.85595 3.09539Z"})}),e6=()=>v.jsxs("svg",{width:"20",height:"21",viewBox:"0 0 20 21",fill:"none",xmlns:"http://www.w3.org/2000/svg",children:[v.jsx("path",{d:"M17.4 18.6566C17.4 14.5697 14.0869 11.2566 9.99998 11.2566C5.91307 11.2566 2.59998 14.5697 2.59998 18.6566",stroke:"white",strokeLinecap:"round"}),v.jsx("path",{d:"M13.6 5.45669C13.6 7.44491 11.9882 9.05669 10 9.05669C8.0118 9.05669 6.40002 7.44491 6.40002 5.45669C6.40002 3.46846 8.0118 1.85669 10 1.85669C11.9882 1.85669 13.6 3.46846 13.6 5.45669Z",stroke:"white"})]}),t6=j("ul")({name:"Container",class:"edc65edga",propsAsIs:!1}),n6=()=>e=>e.active?"var(--accent)":"var(--popup-menu-tabs)",r6=()=>e=>(e.active,"var(--accent)"),s6=j("li")({name:"PaginationItem",class:"edp1cf5kvo",propsAsIs:!1,vars:{"p1cf5kvo-0":[n6()],"p1cf5kvo-1":[r6()]}}),o6=j("div")({name:"Dots",class:"eddw2ykav",propsAsIs:!1}),SS=j("button")({name:"ChevronButton",class:"edcjgljwh",propsAsIs:!1}),wS=()=>v.jsx("svg",{xmlns:"http://www.w3.org/2000/svg",width:"16",height:"16",fill:"currentColor",viewBox:"0 0 16 16",children:v.jsx("path",{fillRule:"evenodd",d:"M4.646 1.646a.5.5 0 0 1 .708 0l6 6a.5.5 0 0 1 0 .708l-6 6a.5.5 0 0 1-.708-.708L10.293 8 4.646 2.354a.5.5 0 0 1 0-.708"})}),i6=({currentPage:e,handleSetCurrentPage:t,totalPages:n})=>{const r=(a,c)=>a<=7?Array.from({length:a},(d,f)=>f+1):c<=4?[1,2,3,4,5,"...",a]:c>=a-2?[1,"...",a-4,a-3,a-2,a-1,a]:[1,"...",c-1,c,c+1,"...",a];if(n<2)return;const i=r(n,e);return v.jsxs(t6,{children:[v.jsx(SS,{onClick:()=>t(e-1),disabled:e<2,children:v.jsx(wS,{})}),i.map((a,c)=>v.jsx(s6,{active:a===e,children:a==="..."?v.jsx(o6,{children:"..."}):v.jsx(V1,{title:a,onClick:()=>t(a)})},c)),v.jsx(SS,{onClick:()=>t(e+1),disabled:e>=n,children:v.jsx(wS,{})})]})},a6=j("div")({name:"Container",class:"edc1o85nbd",propsAsIs:!1}),l6=j("h1")({name:"Title",class:"edtueka45",propsAsIs:!1}),_S=({title:e})=>v.jsxs(a6,{children:[v.jsx("svg",{width:"60px",height:"60px",viewBox:"0 0 24 24",xmlns:"http://www.w3.org/2000/svg",children:v.jsx("path",{d:"M22.8 12A10.8 10.8 0 1 1 10 1.393v1.014a9.8 9.8 0 1 0 4 0V1.393A10.812 10.812 0 0 1 22.8 12z"})}),e&&v.jsx(l6,{children:e})]}),c6=()=>{const e=Me(_=>_.mapLeaderboard),t=Me(_=>_.setMapLeaderboard),[n,r]=C.useState(1),[i,a]=C.useState(0),[c,d]=C.useState(!1),f=He(_=>_.translations.user),h=10,y=(n-1)*h,g=Math.ceil(i/h),w=()=>{var E;const _=(E=window.__widgetEdmap)==null?void 0:E.mapId;_&&(d(!0),QP(_,h,y).then(k=>{a(k.data.totalCount),t(k.data.results)}).catch(k=>{console.error(k)}).finally(()=>d(!1)))},x=_=>{d(!0),r(_)};return C.useEffect(()=>{w()},[n]),c?v.jsx(Jj,{children:v.jsx(_S,{})}):v.jsxs(Wj,{children:[v.jsx(qj,{children:e==null?void 0:e.map((_,E)=>{var O;const k=y+E+1;return v.jsxs(Vj,{children:[v.jsxs(Kj,{children:[v.jsx(Yj,{children:k}),v.jsx(e6,{}),v.jsx(Gj,{children:((O=_==null?void 0:_.User)==null?void 0:O.username)??f.defaultName})]}),v.jsxs(Qj,{children:[v.jsx(Zj,{}),v.jsx(Xj,{children:_==null?void 0:_.allPoints})]})]},_==null?void 0:_.id)})}),i&&v.jsx(i6,{currentPage:n,handleSetCurrentPage:x,totalPages:g})]})},u6=j("div")({name:"Background",class:"edb1d6ibuo",propsAsIs:!1}),d6=j("div")({name:"Container",class:"edc9edd3f",propsAsIs:!1}),f6=j("div")({name:"PrizeBlock",class:"edpzra8fb",propsAsIs:!1}),p6=j("div")({name:"ButtonBlock",class:"edb17wiemr",propsAsIs:!1}),h6=()=>{const e=ln(f=>f.prize),t=ln(f=>f.isRegistrationModalOpen),n=ln(f=>f.closeModalForRegistration),r=cn(f=>f.setIsRegistrationOpen),i=C.useRef(null),a=He(f=>f.translations.settings.signInPopup),c=f=>{i.current&&!i.current.contains(f.target)&&n()};C.useEffect(()=>(t?document.addEventListener("mousedown",c):document.removeEventListener("mousedown",c),()=>{document.removeEventListener("mousedown",c)}),[t]);const d=()=>{r(!0),n()};return t?v.jsx(u6,{children:v.jsxs(d6,{ref:i,children:[v.jsxs(M1,{children:[v.jsx(L1,{children:a.title}),v.jsx(j1,{children:a.subtitle})]}),v.jsx(f6,{children:v.jsxs(B1,{children:[v.jsx(z1,{children:v.jsx(Y1,{iconId:e==null?void 0:e.iconId})}),v.jsx(U1,{children:e==null?void 0:e.name})]})}),v.jsxs(p6,{children:[v.jsx(wn,{title:a.buttonTitle,onClick:n}),v.jsx(wn,{"data-testid":"edmap-widget__signin-popup-btn",title:a.accentButtonTitle,isAccent:!0,onClick:d})]})]})}):null};var Hi=Xh();const m6=j("div")({name:"Container",class:"edc1uqjekp",propsAsIs:!1}),g6=j("div")({name:"Container",class:"edc1sokvv3",propsAsIs:!1}),y6=(e,t)=>{const n=URL.createObjectURL(e);v6(n,t),URL.revokeObjectURL(n)},ES=e=>y6(e,e.name),v6=(e,t)=>{const n=document.createElement("a");n.href=e,n.download=t,document.body.appendChild(n),n.click(),n.remove()},S6=()=>typeof navigator<"u"&&typeof navigator.share=="function",w6=e=>{try{return navigator.canShare({files:[e]})}catch{return!1}},_6=e=>e?S6()&&w6(e):!1,E6=e=>navigator.share({files:[e]}).then(()=>!0).catch(t=>(ES(e),!1)),x6=()=>{const{share:e,downloadFallback:t}=He(i=>i.translations.share),n=ln(i=>i.certificate.file);if(!n)return null;const r=_6(n);return v.jsx(g6,{children:r?v.jsx(wn,{title:e,onClick:()=>E6(n),isAccent:!0}):v.jsx(wn,{title:t,onClick:()=>ES(n),isAccent:!0})})},k6=()=>{const e=ln(a=>a.isCertificateModalOpen),t=ln(a=>a.closeCertificateModal),n=ln(a=>a.certificate.url),r=C.useRef(null),i=a=>{var f;!r.current||(((f=a.composedPath)==null?void 0:f.call(a))||[]).includes(r.current)||t()};return C.useEffect(()=>(e?setTimeout(()=>document.addEventListener("click",i)):document.removeEventListener("click",i),()=>{document.removeEventListener("click",i)}),[e]),e?Hi.createPortal(v.jsxs(m6,{ref:r,children:[v.jsx("img",{src:n}),v.jsx(x6,{})]}),document.body):null},T6=()=>{const e=cn(k=>k.isPanelModalOpen),t=cn(k=>k.setIsPanelOpen),n=cn(k=>k.isRegistrationOpen),r=cn(k=>k.setIsRegistrationOpen),[i,a]=C.useState(0),[c,d]=C.useState(!0),f=Ct(k=>k.results),h=(f==null?void 0:f.allPoints)||0,y=He(k=>k.translations.popup),g=h<10?1:Math.floor(h/10),w=C.useRef(null),x=k1(),_=[v.jsx(s3,{}),v.jsx(Tf,{quests:f==null?void 0:f.quests}),v.jsx(c6,{}),v.jsx(iM,{})],E=k=>{var $;!w.current||((($=k.composedPath)==null?void 0:$.call(k))||[]).includes(w.current)||(a(0),t(!1))};if(C.useEffect(()=>(e?setTimeout(()=>document.addEventListener("click",E)):document.removeEventListener("click",E),()=>{document.removeEventListener("click",E)}),[e]),!!e)return v.jsx(hN,{ref:w,id:"edmap-widget__popup",children:v.jsxs(mN,{children:[v.jsx(C3,{userLevel:g}),!x&&c&&v.jsx(gN,{children:v.jsx(bf,{setIsRegInfoVisible:d,openSignInModal:()=>r(!0)})}),v.jsx(TN,{data:y.menuItems,activeIndex:i,setActiveIndex:a}),v.jsx(yN,{children:_[i]}),v.jsx(dv,{isOpen:n,closeModal:()=>r(!1),setIsSocialModalVisible:()=>{},isSocialModalVisible:!0}),v.jsx(h6,{}),v.jsx(vS,{})]})})},b6=j("div")({name:"Container",class:"edc16l98jz",propsAsIs:!1}),I6=j("div")({name:"ImageWrapper",class:"edi13krnav",propsAsIs:!1}),C6=j("div")({name:"InfoWrapper",class:"edied2wr6",propsAsIs:!1}),R6=j("div")({name:"LevelWrapper",class:"edl11c2ni8",propsAsIs:!1}),A6=j("div")({name:"TextWrapper",class:"edt133co2j",propsAsIs:!1}),O6=j("img")({name:"Confetti",class:"edc1etko73",propsAsIs:!1}),P6=e=>C.createElement("svg",{xmlns:"http://www.w3.org/2000/svg",width:18,height:18,fill:"none",...e},C.createElement("path",{stroke:"#fff",strokeLinecap:"square",strokeWidth:2,d:"m2 2 14 14m0-14L2 16"})),N6=({...e})=>v.jsx(M6,{...e,children:v.jsx(P6,{})}),M6=Z("button")({name:"Button",class:"edb1b1pm51",propsAsIs:!1}),L6="https://widget.edmap.space/assets/confetti-edmap-widget.gif",j6=({points:e,setPointsAreReceived:t})=>{const[n,r]=C.useState(0),i=Ct(f=>f.pointsAreReceived),a=Me(f=>f.isFinished),c=C.useRef(e),d=C.useRef(null);return C.useEffect(()=>(a&&c.current!==e&&(r(f=>f+1),t(!0),d.current=setTimeout(()=>{t(!1)},8e3)),c.current=e,()=>clearTimeout(d)),[e,a]),i&&v.jsx(O6,{src:L6,alt:"Confetti"})},D6=()=>{var f,h,y,g,w,x,_;const e=cn(E=>E.isPanelModalOpen),t=cn(E=>E.setIsPanelOpen),n=Ct(E=>E.results),r=Ct(E=>E.setPointsAreReceived),i=He(E=>E.translations.popupBar),a=((h=(f=n==null?void 0:n.prizes)==null?void 0:f.filter(E=>E==null?void 0:E.awardRichText))==null?void 0:h.length)??0,c=(n==null?void 0:n.allPoints)||0,d=()=>{t(!0),r(!1)};return v.jsx(v.Fragment,{children:e?v.jsx(N6,{onClick:()=>t(!1),id:"edmap-widget__popup-bar-btn"}):v.jsxs(b6,{onClick:d,id:"edmap-widget__popup-bar",children:[v.jsx(I6,{children:v.jsx(xf,{src:(g=(y=n==null?void 0:n.User)==null?void 0:y.avatar)==null?void 0:g.src,style:{borderRadius:"var(--extreme-border-radius)"}})}),v.jsxs(C6,{children:[v.jsxs(R6,{children:[v.jsx(Ef,{level:kf(c)}),v.jsxs(A6,{children:[v.jsx(Cs,{text:i.prizesTitle,progressValue:a??0,overallValue:((w=n==null?void 0:n.prizes)==null?void 0:w.length)??0}),v.jsx(Cs,{text:i.skillsTitle,progressValue:(n==null?void 0:n.allPoints)??0,overallValue:((x=n==null?void 0:n.map)==null?void 0:x.points)??0})]})]}),v.jsx(zl,{progressValue:(n==null?void 0:n.allPoints)??0,overallValue:((_=n==null?void 0:n.map)==null?void 0:_.points)??0})]}),v.jsx(j6,{points:c,setPointsAreReceived:r})]})})};Nt((e,t)=>({isOpen:!1,toggle:()=>e(n=>({isOpen:!n.isOpen})),closeModal:()=>e({isOpen:!1}),openModal:()=>e({isOpen:!0})}));const lc=Nt(e=>({popupBarStyle:{},widgetContainerStyle:{},setPopupBarStyle:t=>e({popupBarStyle:t}),setWidgetContainerStyle:t=>e({widgetContainerStyle:t})})),$6=j("div")({name:"Container",class:"edc1vap6o9",propsAsIs:!1}),F6=()=>{const e=cn(i=>i.isPanelModalOpen),t=lc(i=>i.popupBarStyle),n=Me(i=>i.quest);return(n==null?void 0:n.isMiniPanelVisible)||e?v.jsxs($6,{style:t,children:[v.jsx(T6,{}),(n==null?void 0:n.isMiniPanelVisible)&&v.jsx(D6,{})]}):null},xS=e=>{if(!e)return{};if(e.startsWith("{"))try{e=e.slice(1,e.length-1)}catch(n){return An(n),console.error("Parse Error: something wrong with custom style string"),{}}const t={};return e.split(";").forEach(n=>{const[r,i]=n.split(":").map(a=>a.trim());if(r&&i){const a=r.replace(/-([a-z])/g,c=>c[1].toUpperCase());t[a]=i}else console.warn(`Parse Warning: faild to parse custom property style for property: ${r||"not found"}`)}),t},B6=(e,t)=>{if(e==="admin"){const n=t.match(/quests\/([^/?]+)/);return(!n||!n[1])&&console.error("Parse Error: wrong url for quest search in admin panel"),n[1]}else return t},z6=j("div")({name:"Container",class:"edcsc8z9h",propsAsIs:!1}),U6=j("div")({name:"HidingContainer",class:"edhc15unp",propsAsIs:!1}),kS=j("div")({name:"QuestionBlock",class:"edq12kw8l3",propsAsIs:!1}),H6=j("div")({name:"HeaderScrollableSpace",class:"edh1iwfgmu",propsAsIs:!1}),W6=j("div")({name:"SidePadding",class:"edsz53tfr",propsAsIs:!1}),q6=j("div")({name:"Container",class:"edc8gkhop",propsAsIs:!1}),V6=j("div")({name:"TitleSection",class:"edtp3l3kp",propsAsIs:!1}),G6=j("div")({name:"Wrapper",class:"edw11bk3uj",propsAsIs:!1}),TS=j("div")({name:"Divider",class:"edd1nx5xv8",propsAsIs:!1}),Y6=j("div")({name:"UserContainer",class:"edu5m07eq",propsAsIs:!1}),K6=j("h2")({name:"Title",class:"edt1xyelki",propsAsIs:!1}),Q6=j("div")({name:"AvatarContainer",class:"eda1j00vs7",propsAsIs:!1}),X6=j("button")({name:"AvatarButton",class:"edab6hzvg",propsAsIs:!1}),J6=j("div")({name:"LevelContainer",class:"edl8lxqvm",propsAsIs:!1}),Z6=j("div")({name:"ButtonContainer",class:"edb1m2edat",propsAsIs:!1}),eD=j("div")({name:"Container",class:"edcitwxpq",propsAsIs:!1}),tD=j("div")({name:"QuestTypeIcon",class:"edqdo840j",propsAsIs:!1}),nD=e=>C.createElement("svg",{xmlns:"http://www.w3.org/2000/svg",width:24,height:24,fill:"none",...e},C.createElement("path",{fill:"currentColor",d:"m14.505 15.138.11.006a1 1 0 0 1 .66.354l3.114 3.748c.89 1.072 2.633.442 2.633-.95v-9.43a4.656 4.656 0 0 0-4.425-4.65l-.23-.005H7.634A4.656 4.656 0 0 0 2.98 8.866v8.953c0 1.344 1.64 2 2.567 1.025l3.224-3.396c.189-.198.451-.31.726-.31zm8.517 3.158c0 3.264-4.084 4.74-6.17 2.228l-2.815-3.386H9.925L6.998 20.22C4.828 22.504.98 20.97.98 17.819V8.866a6.657 6.657 0 0 1 6.653-6.655h8.734l.33.008a6.66 6.66 0 0 1 6.325 6.645z"}),C.createElement("path",{fill:"currentColor",d:"M9 7v2h2v2H9v2H7v-2H5V9h2V7zM15.05 10.59a1.25 1.25 0 1 0 0-2.5 1.25 1.25 0 0 0 0 2.5M17.434 12.973a1.25 1.25 0 1 0 0-2.5 1.25 1.25 0 0 0 0 2.5"})),rD=e=>C.createElement("svg",{xmlns:"http://www.w3.org/2000/svg",width:24,height:24,fill:"none",...e},C.createElement("path",{fill:"currentColor",d:"m8.6 2.799-4.694 3.52-2.613-2.613 1.414-1.414 1.387 1.387L7.4 1.199zm13.4-.3v2H11v-2zM22 10.999v2H11v-2zM22 19.499v2H11v-2zM4.5 13.999a2 2 0 1 0 0-4 2 2 0 0 0 0 4M4.5 22.499a2 2 0 1 0 0-4 2 2 0 0 0 0 4"})),sD=()=>{const t=Me(n=>n.quest).questType==="Test"?v.jsx(rD,{}):v.jsx(nD,{});return v.jsx(eD,{children:v.jsx(tD,{children:t})})},oD=({icon:e,...t})=>v.jsx(wf,{...t,children:e}),iD=e=>C.createElement("svg",{xmlns:"http://www.w3.org/2000/svg",width:14,height:14,fill:"none",viewBox:"0 0 18 18",...e},C.createElement("path",{stroke:"#fff",strokeLinecap:"square",strokeWidth:2,d:"m2 2 14 14m0-14L2 16"})),aD=j("div")({name:"Container",class:"edchp8usr",propsAsIs:!1}),lD=j("span")({name:"Text",class:"edt141dyxo",propsAsIs:!1}),bS=({minutes:e,seconds:t})=>(e=Math.max(0,e),t=Math.max(0,t),v.jsxs(lD,{children:[e.toString().padStart(2,"0"),":",t.toString().padStart(2,"0")]})),cD=e=>{const t=WP(e);if(!t)return Date.now();const[n,r]=t.split("@");return Number(r)},uD=e=>Date.now()-e,dD=(e,t)=>{const n=cD(t);return fD(e,n)},fD=(e,t)=>{const n=Math.floor(uD(t)/1e3),r=e-n,i=r%60,a=Math.floor(r/60);return{seconds:i,minutes:a}},pD=j("div")({name:"Container",class:"edc1qu2wft",propsAsIs:!1}),hD=j("div")({name:"TextBlock",class:"edtoc84xr",propsAsIs:!1}),mD=j("p")({name:"RestrictionText",class:"edr6awsvd",propsAsIs:!1}),Kf=e=>C.createElement("svg",{xmlns:"http://www.w3.org/2000/svg",fill:"none",viewBox:"0 0 24 24",...e},C.createElement("path",{fill:"currentColor",d:"M20 12a8 8 0 1 0-16 0 8 8 0 0 0 16 0m2 0c0 5.523-4.477 10-10 10S2 17.523 2 12 6.477 2 12 2s10 4.477 10 10"}),C.createElement("path",{fill:"currentColor",d:"m13 11.106 1.732-1.732 1.415 1.414-3.733 3.732L11 13.5V6h2z"})),gD=({timeValues:e})=>{const{remainingTitle:t}=He(n=>n.translations.timer);return v.jsxs(pD,{children:[v.jsx(Kf,{}),v.jsxs(hD,{children:[v.jsx(mD,{children:t}),v.jsx(bS,{...e})]})]})},yD=j("div")({name:"Container",class:"edc16uhwme",propsAsIs:!1}),vD=({timeValues:e})=>v.jsxs(yD,{children:[v.jsx(Kf,{}),v.jsx(bS,{...e})]}),cc=Nt(e=>({isTimerOverlapped:!1,values:{minutes:0,seconds:0},setIsTimerOverlapped:t=>e({isTimerOverlapped:t}),setValues:t=>e({values:t})})),IS=({type:e})=>{const t=Me(h=>h.quest),n=cc(h=>h.values),r=cc(h=>h.setValues),i=Me(h=>h.setIsFinished),a=Me(h=>h.isFinished),c=Br(h=>h.startFadeTransition),d=()=>dD(t.timeLimitSeconds,t.id),f=()=>c([]).then(()=>{i(!0),r(d())});return C.useEffect(()=>{if(a)return;const h=()=>{const g=d();if(g.minutes<=0&&g.seconds<=0){f(),r({minutes:0,seconds:0});return}r(g)},y=setInterval(h,1e3);return h(),()=>{clearInterval(y)}},[t.id,a]),e==="horizontal"?v.jsx(gD,{timeValues:n}):v.jsx(vD,{timeValues:n})},SD=()=>{const e=Me(n=>n.quest),t=cc(n=>n.isTimerOverlapped);return e.timeLimitSeconds===0||!t?null:v.jsxs(aD,{children:[v.jsx(TS,{}),v.jsx(IS,{type:"vertical"})]})},CS=Nt(e=>({height:0,width:null,setHeight:t=>e({height:t}),setWidth:t=>e({width:t}),headerShift:0,setHeaderShift:t=>e({headerShift:t})})),uc=Nt((e,t)=>({ref:null,height:null,width:null,initialHeight:0,top:0,setRef:()=>e({ref}),setTop:n=>e({top:n}),setHeight:n=>e({height:n}),setWidth:n=>e({width:n}),getHeight:()=>t().height,setInitialHeight:n=>e({initialHeight:n,height:n})})),wD=Z("div")({name:"Container",class:"edcsej1qu",propsAsIs:!1}),_D=()=>({verticalDirection:e})=>e==="down"?"100%":"unset",ED=()=>({verticalDirection:e})=>e==="up"?"100%":"unset",xD=()=>({horizontalDirection:e})=>e==="left"?"unset":"0",kD=()=>({horizontalDirection:e})=>e==="left"?"0":"unset",TD=Z("div")({name:"DropdownMenu",class:"edd146lpl0",propsAsIs:!1,vars:{"d146lpl0-0":[_D()],"d146lpl0-1":[ED()],"d146lpl0-2":[xD()],"d146lpl0-3":[kD()]}}),bD=()=>({isChosen:e})=>e?"var(--dropdown-item-bg-active)":"transparent",ID=()=>({isChosen:e})=>e?"block":"none",CD=Z("div")({name:"MenuItem",class:"edmqt74d7",propsAsIs:!1,vars:{"mqt74d7-0":[bD()],"mqt74d7-1":[ID()]}}),RD=(e,t)=>{const[n,r]=C.useState("right");return C.useLayoutEffect(()=>{if(!e.current||!t.current)return;const i=e.current.getBoundingClientRect(),a=t.current.getBoundingClientRect();return i.left-a.left+i.width>a.width?r("left"):r("right"),()=>{r("right")}},[e,t]),n},AD=({items:e,chosenItem:t,dropdownButton:n,handleChooseItem:r,isDropdownOpen:i,setIsDropdownOpen:a,viewportRef:c={current:window.document.body},...d})=>{const[f,h]=C.useState("down"),y=C.useRef(null),g=C.useRef(null),[w,x]=C.useState("right"),_=()=>{const R=y.current,$=g.current;if(!R||!$)return;const H=R.getBoundingClientRect(),z=$.offsetHeight,M=window.innerHeight-H.bottom,L=H.top;M<z&&L>z?h("up"):h("down");const U=c.current.getBoundingClientRect(),te=$.getBoundingClientRect();H.left-U.left+te.width>U.width?x("left"):x("right")},E=R=>{y.current&&!y.current.contains(R.target)&&a(!1)};C.useLayoutEffect(()=>{if(i)return _(),document.addEventListener("mousedown",E),()=>{document.removeEventListener("mousedown",E)}},[i]);const k=R=>typeof R=="object"?R.name:R,O=R=>typeof R=="object"?(R==null?void 0:R.id)===t:R===t;return v.jsxs(wD,{...d,ref:y,children:[n,i&&e.length>0&&v.jsx(TD,{ref:g,verticalDirection:f,horizontalDirection:w,children:e.map(R=>v.jsx(CD,{isChosen:O(R),onClick:()=>{R!=null&&R.callback&&typeof(R==null?void 0:R.callback)=="function"?R==null||R.callback():r((R==null?void 0:R.id)??R)},children:k(R)},typeof R=="object"?R.id:R))})]})},OD=Z("button")({name:"ButtonContainer",class:"edb1lpjq8r",propsAsIs:!1}),PD=e=>{const[t,n]=C.useState(!1),r=C.useMemo(()=>e.items.map(a=>({...a,callback:()=>{a.callback(),n(!1)}})),[e.items]),i=C.useCallback(()=>{n(a=>!a)},[]);return v.jsx(AD,{...e,isDropdownOpen:t,setIsDropdownOpen:n,items:r,dropdownButton:v.jsx(OD,{onClick:i,children:e.dropdownButton})})},ND=e=>C.createElement("svg",{xmlns:"http://www.w3.org/2000/svg",width:24,height:24,fill:"none",...e},C.createElement("path",{stroke:"currentColor",strokeLinecap:"round",strokeLinejoin:"round",strokeWidth:2,d:"M12 5v.01M12 12v.01M12 19v.01M12 6a1 1 0 1 1 0-2 1 1 0 0 1 0 2m0 7a1 1 0 1 1 0-2 1 1 0 0 1 0 2m0 7a1 1 0 1 1 0-2 1 1 0 0 1 0 2"})),MD=j("div")({name:"MenuContainer",class:"edm1b26o2n",propsAsIs:!1}),LD=({parentRef:e})=>{const{restartQuest:t}=Io(),{restart:n}=He(i=>i.translations.gameMenu),r=C.useMemo(()=>[{id:"reset-session",name:n,callback:t}],[t,n]);return v.jsx(PD,{viewportRef:e,dropdownButton:v.jsx(MD,{children:v.jsx(ND,{})}),items:r})},jD=({isSticky:e,style:t,parentRef:n})=>{var R,$,H,z,M;const r=Ct(L=>L.results),i=Me(L=>L.quest),a=cn(L=>L.isPanelModalOpen),c=cn(L=>L.setIsPanelOpen),d=C.useRef(null),f=He(L=>L.translations.header),h=CS(L=>L.setHeight),y=uc(L=>L.width),g=pr(L=>L.topOffset),w=pr(L=>L.marginRootTop),x=()=>{c(!a)};C.useEffect(()=>{if(!(d.current instanceof HTMLElement))return;const U=window.getComputedStyle(d.current),te=parseFloat(U.height),K=parseFloat(U.paddingBottom);h(te-K/2)},[]);const _=L=>{L.preventDefault(),L.stopPropagation()},E=a?iD:J1,k=e?-g+w:-g,O=v.jsxs(q6,{id:"edmap-header",ref:d,style:{position:e?"fixed":"absolute",top:`${k}px`,...t,width:y??"100%"},children:[v.jsx(sD,{}),v.jsxs(V6,{children:[v.jsxs(G6,{children:[v.jsx(K6,{children:i==null?void 0:i.name}),v.jsx(Cs,{progressValue:(r==null?void 0:r.allPoints)??0,overallValue:((R=r==null?void 0:r.map)==null?void 0:R.points)??0,text:f.progressText})]}),v.jsx(zl,{progressValue:(r==null?void 0:r.allPoints)??0,overallValue:(($=r==null?void 0:r.map)==null?void 0:$.points)??0})]}),v.jsx(Z6,{children:v.jsx(oD,{onMouseDown:_,onClick:x,icon:v.jsx(E,{})})}),v.jsx(TS,{}),v.jsxs(Y6,{children:[v.jsx(LD,{parentRef:n}),v.jsxs(Q6,{children:[v.jsx(xf,{style:{cursor:"pointer"},onMouseDown:_,onClick:x,src:(z=(H=r==null?void 0:r.User)==null?void 0:H.avatar)==null?void 0:z.src,alt:(M=f.image)==null?void 0:M.alt}),v.jsx(X6,{onClick:x,"aria-label":"avatar-button"}),v.jsx(J6,{children:v.jsx(Ef,{level:kf(r==null?void 0:r.allPoints)})})]})]}),v.jsx(SD,{})]});return e&&typeof document<"u"?Hi.createPortal(O,document.body):O},RS=Nt(e=>({top:0,bottom:0,height:0,setTop:t=>e({top:t}),setBottom:t=>e({bottom:t}),setHeight:t=>e({height:t})})),DD=(e,t,n)=>t.textAnswer.length===0,$D={[St.test]:()=>!1,[St.journey]:DD},FD=()=>{const{currentZustandHook:e,quest:t}=av(),[n,r]=C.useState(e.getState()),i=Br(a=>a.preloader);return C.useEffect(()=>{const a=e.subscribe(c=>{r(c)});return()=>a()},[t,e]),C.useMemo(()=>i||$D[t.questType](t,n,null),[n,t,i])},BD=()=>{const e=He(r=>r.translations.footer),{makeStep:t}=Io(),n=FD();return v.jsx(wn,{disabled:n,id:"edmap-widget__accept-btn","data-test":"button game",title:e.accentButtonTitle,isAccent:!0,onClick:t})},zD=()=>{const e=Me(g=>g.currentStep),t=Me(g=>{var w;return(w=g.quest)==null?void 0:w.details.stepCount}),n=Me(g=>g.isFinished),r=Me(g=>g.quest),i=C.useRef(null),a=RS(g=>g.setHeight),c=hr(g=>g.currentNode.type);if(C.useEffect(()=>{i.current&&a(i.current.clientHeight)},[i.current]),!(r!=null&&r.id))return;const{questType:d=""}=r,f=d===St.journey,h=f&&[Rs.inputAnswerNode,Rs.ai].includes(c),y=d===St.test||h;return v.jsxs(uM,{ref:i,children:[v.jsx(aM,{children:v.jsx(X1,{})}),!n&&y&&v.jsxs(cM,{children:[f?null:v.jsx(lM,{children:v.jsx(Cs,{progressValue:e,overallValue:t})}),v.jsx(lv,{children:v.jsx(BD,{})})]})]})},UD=(e,t=!1,n=0)=>{const r=C.useRef(null),i=C.useRef(null),a=C.useRef(null);return C.useEffect(()=>{const c=r.current;if(!c)return;const d=(h,y)=>{let g=null;if(t){const w=h.top,x=a.current!==null&&a.current<n,_=w-n>0;x&&_&&(g=!0),a.current=h.top}else y?g=!1:h.top<n&&(g=!0);g===null||i.current===g||e(g)},f=new IntersectionObserver(h=>{h.forEach(y=>{d(y.boundingClientRect,y.isIntersecting)})},{root:null,threshold:0});return f.observe(c),()=>{f.disconnect()}},[e,t,n,r]),r},AS=j("div")({name:"Container",class:"edc12456a3",propsAsIs:!1}),HD=j(AS)({name:"BottomSensorContainer",class:"edbig50hz",propsAsIs:!0}),WD=Tt.forwardRef(({setIsSensorTriggered:e,isBottomUpTriggered:t,rootOffset:n,topOffset:r,bottomOffset:i,className:a,color:c,isStickToBottom:d=!1,isPortal:f=!0},h)=>{const y=UD(e,t,n);C.useImperativeHandle(h,()=>y.current,[]);const g=C.useMemo(()=>({marginTop:r||"unset",marginBottom:i||"unset",backgroundColor:c??"red"}),[r,i,c]);let w=null;return d?w=v.jsx(HD,{className:a??"edmap-sensor",ref:y,style:g}):w=v.jsx(AS,{className:a??"edmap-sensor",ref:y,style:g}),f?Hi.createPortal(w,document.body):w}),Ns=Tt.memo(WD);class qD extends Tt.Component{static getDerivedStateFromError(){return{}}componentDidCatch(t,n){console.log(t),Pf.setState({error:t}),An(t)}render(){return this.props.children}}const VD=({width:e=24,height:t=24,...n})=>v.jsx("svg",{width:e,height:t,viewBox:"0.5 -0.5 17 17",xmlns:"http://www.w3.org/2000/svg",fill:"none",...n,children:v.jsxs("g",{transform:"translate(1.000000, 2.000000)",fill:"currentColor",children:[v.jsx("path",{d:"M15.796,6.908 L14.234,5.21 C14.019,4.998 13.672,4.998 13.458,5.21 L11.894,6.908 C11.679,7.122 11.679,7.467 11.894,7.68 L13.188,7.68 C12.702,9.505 11.27,10.976 9.399,11.47 C7.231,12.042 4.913,11.191 3.632,9.351 L2.541,10.102 C3.807,11.921 5.884,12.966 8.039,12.966 C8.604,12.966 9.176,12.894 9.737,12.745 C12.188,12.099 14.04,10.112 14.55,7.68 L15.795,7.68 C16.01,7.467 16.01,7.122 15.796,6.908 Z"}),v.jsx("path",{d:"M4.475,6.021 C4.69,5.808 4.69,5.462 4.475,5.249 L3.018,5.249 C3.516,3.448 4.936,2.001 6.789,1.511 C8.959,0.938 11.275,1.791 12.555,3.632 L13.647,2.88 C12.049,0.585 9.161,-0.479 6.448,0.235 C4.016,0.878 2.175,2.84 1.648,5.249 L0.196,5.249 C-0.019,5.463 -0.019,5.809 0.196,6.021 L1.834,7.658 C2.048,7.87 2.396,7.87 2.61,7.658 L4.475,6.021 Z"})]})}),GD=j("div")({name:"Background",class:"edb1tdpu9l",propsAsIs:!1}),YD=j(q1)({name:"Button",class:"edb16l2gyb",propsAsIs:!0}),KD=j("p")({name:"Title",class:"edt15nnhmy",propsAsIs:!1}),QD=j("p")({name:"Subtitle",class:"eds1a894cv",propsAsIs:!1}),XD=j("div")({name:"Container",class:"edczp6bkd",propsAsIs:!1}),JD=j("div")({name:"TextContainer",class:"edt1807jed",propsAsIs:!1}),OS=({children:e})=>{const t=He(i=>i.translations.globalError),n=Pf(i=>i.error),r=()=>{window.location.reload()};return n?v.jsx(GD,{children:v.jsxs(XD,{children:[v.jsxs(JD,{children:[v.jsx(KD,{children:t.title}),v.jsx(QD,{children:t.subtitle})]}),v.jsx(YD,{onClick:r,children:v.jsx(VD,{width:80,height:75})})]})}):v.jsx(qD,{children:e})},ZD=({children:e})=>{const t=Me(n=>n.quest);return t!=null&&t.id?v.jsx(v.Fragment,{children:e}):v.jsx(_S,{})},e5=j("div")({name:"Container",class:"edctzb4h8",propsAsIs:!1}),t5=j("p")({name:"Title",class:"edtg41o65",propsAsIs:!1}),Qf=e=>{if(!e)return 60;const n=new Date(e).getTime()-Date.now();return n<0?0:Math.round(n/1e3)},n5=e=>{const t=Math.floor(e/3600),n=Math.floor(e%3600/60),r=e%60,i=String(n).padStart(2,"0"),a=String(r).padStart(2,"0");return t<1?`${i}:${a}`:`${String(t).padStart(2,"0")}:${i}:${a}`},r5=j("div")({name:"Container",class:"edc11azq9p",propsAsIs:!1}),PS=({expiresAt:e,onTimeEnds:t})=>{const[n,r]=C.useState(Qf(e)),i=He(a=>a.translations.user.ban);return C.useEffect(()=>{r(Qf(e))},[e]),C.useEffect(()=>{const a=setInterval(()=>{r(Qf(e))},1e3);return()=>{clearInterval(a)}},[e]),C.useEffect(()=>{n>0||t&&t()},[n]),v.jsxs(r5,{children:[v.jsx(Kf,{}),v.jsxs("span",{children:[i.wait," ",n5(n)]})]})},NS=async e=>{if(!bo())return!1;const{data:n}=await ut.get(`/banned-user/${bo()}/${e}`),{isBanned:r,expiresAt:i}=n;return{isBanned:r,expiresAt:i}},MS=()=>{const e=Me(d=>d.quest),[t,n]=C.useState(!0),[r,i]=C.useState({isBanned:!1,expiresAt:null}),a=C.useCallback(()=>{n(!0)},[]),c=C.useCallback(()=>{NS(e.id).then(({isBanned:d,expiresAt:f})=>{i({isBanned:d,expiresAt:f}),n(!d)})},[e.id]);return{isBanExpired:t,expiresAt:r.expiresAt,onTimeEnds:a,refreshBanStatus:c}},s5=({children:e})=>{const t=He(d=>d.translations.user.ban),n=Me(d=>{var f;return(f=d.quest)==null?void 0:f.id}),{isBanExpired:r,expiresAt:i,onTimeEnds:a,refreshBanStatus:c}=MS();return C.useEffect(()=>{c()},[n]),r?e:v.jsxs(e5,{children:[v.jsx(t5,{children:t.forbiddenQuest}),v.jsx(PS,{expiresAt:i,onTimeEnds:a})]})},o5=(e,t)=>{C.useEffect(()=>{if(!e.current)return;const n=()=>{t(e.current.clientWidth)};return n(),window.addEventListener("resize",n),()=>{window.removeEventListener("resize",n)}},[e.current])},i5=j("div")({name:"Background",class:"edbgw902r",propsAsIs:!1}),a5=j("div")({name:"Container",class:"edcv2zzw1",propsAsIs:!1}),l5=j("div")({name:"MessageBlock",class:"edm2b9k2r",propsAsIs:!1}),c5=j("div")({name:"Row",class:"edr4gsubj",propsAsIs:!1}),u5=j("div")({name:"Divider",class:"edd3sdabk",propsAsIs:!1}),d5=j("h1")({name:"Title",class:"edt1cvxfwm",propsAsIs:!1}),f5=j("div")({name:"QuestsContainer",class:"edq1tclzqz",propsAsIs:!1}),LS=j("div")({name:"Section",class:"eds1ce4iti",propsAsIs:!1}),jS=j("p")({name:"SectionTitle",class:"edsqdd2kx",propsAsIs:!1}),p5=j(c5)({name:"PrizesContainer",class:"edpiwm40a",propsAsIs:!0}),h5=(e,t=5)=>{const n=e==null?void 0:e.quests;return n?n.filter(a=>a.url!==window.location.pathname).filter(a=>!("resultQuestAnswer"in a)).slice(0,t):[]},m5=e=>{const t=e==null?void 0:e.prizes,n=e==null?void 0:e.allPoints;return t?t.filter(i=>i.awardPoints>n):[]},g5=async e=>{if(kr.reportQuestEnded(e.mapId,e.id),e.questType==="Test")return KP(e);if(e.questType==="Journey")return X3(e)},y5=(e,t)=>{const n=v5(e,t),r=S5(n),i=w5(n);return[r,i]},v5=(e,t)=>{var n;return(n=t==null?void 0:t.quests)==null?void 0:n.find(r=>r.id===e)},S5=e=>{var t;return((t=e==null?void 0:e.resultQuestAnswer)==null?void 0:t.points)||0},w5=e=>(e==null?void 0:e.maxPoints)||0,_5=(e,t)=>e.replace(/{(\w+)}/g,(n,r)=>{var i;return((i=t[r])==null?void 0:i.toString())??`{${r}}`}),E5=(e,t,n,r)=>e<t?n:r,x5=(e,t,n,r,i)=>{const[a,c]=y5(e,t),d=E5(n,a,r,i);return _5(d,{points:n,bestPoints:a,maxPoints:c})},k5=j("p")({name:"HighlightingContainer",class:"edh1r5zzja",propsAsIs:!1}),T5=({worstScoreTemplate:e,bestScoreTemplate:t})=>{const n=Ct(c=>c.results),r=Me(c=>c.quest),i=Me(c=>c.currentTryPoints),a=x5(r.id,n,i,e,t);return v.jsx(k5,{dangerouslySetInnerHTML:{__html:a}})},DS=({translations:e})=>{const[t,n]=C.useState(!0),{isBanExpired:r,expiresAt:i,onTimeEnds:a,refreshBanStatus:c}=MS(),d=Ct(U=>U.results),f=Ct(U=>U.refreshUserResults),h=Me(U=>U.setCurrentTryPoints),y=h5(d),g=m5(d),w=Me(U=>U.quest),x=e.successTitle,_=e.buttonTitle,E=e.prizesTitle,k=e.questsTitle,O=e.bestScoreTemplate,R=e.worstScoreTemplate,$=k1(),H=cn(U=>U.setIsPanelOpen),z=cn(U=>U.setIsRegistrationOpen),{restartQuest:M}=Io(),L=()=>{H(!0),z(!0)};return C.useEffect(()=>{g5(w).then(({data:U})=>{var te;return c(),h(U.points),f((te=window.__widgetEdmap)==null?void 0:te.mapId)}).finally(()=>{x1(w.id)})},[w]),C.useEffect(()=>{w!=null&&w.id&&NS(w.id).then()},[w==null?void 0:w.id]),v.jsx(i5,{id:"edmap-widget__success",children:v.jsxs(a5,{children:[v.jsxs(l5,{children:[v.jsx(d5,{children:x}),w.isAwardPointsShowned&&v.jsx(T5,{worstScoreTemplate:R,bestScoreTemplate:O}),r?v.jsx(wn,{id:"edmap-widget__success-btn",onClick:M,title:_,isAccent:!0}):v.jsx(PS,{expiresAt:i,onTimeEnds:a})]}),!$&&t&&v.jsx(bf,{setIsRegInfoVisible:n,openSignInModal:L}),g.length>0&&y.length>0&&v.jsx(u5,{}),g.length>0?v.jsxs(LS,{children:[v.jsx(jS,{children:E}),v.jsx(p5,{children:g.map((U,te)=>v.jsx(_f,{index:te,prizeData:U,userPoints:d==null?void 0:d.allPoints},U==null?void 0:U.id))})]}):null,y.length>0?v.jsxs(LS,{children:[v.jsx(jS,{children:k}),v.jsx(f5,{children:v.jsx(Tf,{quests:y})})]}):null]})})},b5=Z("div")({name:"Gap",class:"edg5lnmft",propsAsIs:!1}),I5=Z("div")({name:"ResourceWrapper",class:"edr1u056rp",propsAsIs:!1}),$S=Z("p")({name:"Text",class:"edtjt97q3",propsAsIs:!1}),C5=Z("div")({name:"TooltipConent",class:"edt3zaxx",propsAsIs:!1}),R5=Z("div")({name:"Container",class:"edc6pydkm",propsAsIs:!1}),A5=[...new Intl.Segmenter("en",{granularity:"grapheme"}).segment("💪🏃‍♂️🧠❤️🔥💰🪵⛏️🍖🔮👾⭐️😒😊🌈🐋🦄😎🤢🤮🤡👺💩🤥🐷👑⌛️🛢️🪙💎🗡️🧬🎁🎉🧸🪆🪩📊❗️💖❤️‍🔥💔")].map(e=>e.segment),O5=e=>[...e].map(t=>t.codePointAt(0)).join("-"),FS=Object.fromEntries(A5.map(e=>[O5(e),e])),BS=({iconId:e,text:t,...n})=>v.jsxs(R5,{...n,children:[v.jsx("span",{children:FS[e]}),t?v.jsx("span",{children:t}):null]}),P5=Z("div")({name:"TooltipContainer",class:"edtlfbks8",propsAsIs:!1}),N5=()=>({isStickLeft:e})=>e?"0":"102%",M5=()=>({isVisible:e})=>e?"visible":"hidden",L5=()=>({isVisible:e,isFading:t})=>e&&!t?"1":"0",j5=()=>({zIndex:e=100})=>e,D5=Z("div")({name:"TooltipContent",class:"edtlzs19l",propsAsIs:!1,vars:{"tlzs19l-0":[N5()],"tlzs19l-1":[M5()],"tlzs19l-2":[L5()],"tlzs19l-3":[j5()]}}),zS=e=>{let t;const n=new Set,r=(h,y)=>{const g=typeof h=="function"?h(t):h;if(!Object.is(g,t)){const w=t;t=y??(typeof g!="object"||g===null)?g:Object.assign({},t,g),n.forEach(x=>x(t,w))}},i=()=>t,d={setState:r,getState:i,getInitialState:()=>f,subscribe:h=>(n.add(h),()=>n.delete(h))},f=t=e(r,i,d);return d},$5=e=>e?zS(e):zS,F5=e=>e;function B5(e,t=F5){const n=Tt.useSyncExternalStore(e.subscribe,()=>t(e.getState()),()=>t(e.getInitialState()));return Tt.useDebugValue(n),n}const US=e=>{const t=$5(e),n=r=>B5(t,r);return Object.assign(n,t),n},HS=(e=>e?US(e):US)(e=>({activeTooltip:null,setActiveTooltip:t=>e({activeTooltip:t}),currentZIndex:101,getNextZIndex:()=>(e(t=>({currentZIndex:t.currentZIndex+1})),HS.getState().currentZIndex)})),WS=({tooltipContent:e,children:t,isStickLeft:n,...r})=>{const[i,a]=C.useState(!1),[c,d]=C.useState(!1),[f,h]=C.useState(null),[y,g]=C.useState(100),{setActiveTooltip:w,getNextZIndex:x}=HS(),_=C.useRef(null),E=()=>{d(!1),f&&(clearTimeout(f),h(null));const O=x();g(O),w(_.current),a(!0)},k=()=>{d(!0);const O=setTimeout(()=>{a(!1),h(null),d(!1)},300);h(O)};return v.jsxs(P5,{...r,onMouseEnter:E,onMouseLeave:k,children:[t,v.jsx(D5,{ref:_,className:"tooltip-content",isFading:c,isStickLeft:n,isVisible:i,onMouseEnter:E,onMouseLeave:k,style:{zIndex:y},children:e||""})]})},z5=({resource:e,animationClass:t,viewportRef:n})=>{const r=C.useRef(null),i=RD(r,n),a=i==="right"?"0":"unset",c=i==="right"?"unset":"-40px";return v.jsx(WS,{isStickLeft:!0,tooltipContent:v.jsx(C5,{ref:r,style:{left:a,right:c},children:v.jsx($S,{children:e.name})}),children:v.jsxs(I5,{children:[v.jsx(BS,{style:{gap:"0"},iconId:e.iconId}),v.jsx($S,{className:t,children:e.value})]})})},U5=({resources:e})=>{const[t,n]=C.useState(e),[r,i]=C.useState({}),a=C.useRef(null);C.useEffect(()=>{e.every(d=>t.find(f=>f.name===d.name))||(i({}),n(e))},[e]),C.useEffect(()=>{const d={};e.forEach((h,y)=>{const g=t[y],w=parseFloat(g==null?void 0:g.value.replace(/\s/g,""))||0,x=parseFloat(h==null?void 0:h.value.replace(/\s/g,""))||0;g?w<x?d[h.name]="increase":x<w?d[h.name]="decrease":d[h.name]="":d[h.name]="increase"}),i(d);const f=setTimeout(()=>{i({})},600);return n(e),()=>{clearTimeout(f),i({})}},[e]);const c=e.filter(({isVisible:d})=>d);return v.jsx(b5,{ref:a,children:c.map((d,f)=>v.jsx(z5,{viewportRef:a,resource:d,animationClass:r[d.name]||""},f))})},H5=e=>e.reduce((t,n)=>({...t,[n.id]:`${FS[n.iconId]} ${n.name} ${n.value}`}),{}),qS=()=>{const e=hr(t=>t.currentResources);return C.useMemo(()=>H5(e),[e])},VS=e=>{const t=qS();return v.jsx(Ui,{...e,replacements:t})},W5=e=>Array.from(new Set(e)),q5=(e,t)=>{const n=e.sourceEdges.filter(r=>!t.has(r.targetId));return W5(n.map(r=>r.targetId))},V5=(e,t)=>e.filter(n=>!t.has(n)),G5=()=>{const e=hr(i=>i.currentNode),t=C.useRef(new Set),n=C.useRef(new Set),r=C.useRef(0);C.useEffect(()=>{let i;return r.current=setTimeout(()=>{if(!e)return;const a=q5(e,t.current),c=V5(a,n.current);c.forEach(f=>n.current.add(f)),i=new AbortController;const d=c.map(async f=>{const h=await rM(f,i.signal);return await Z1(h.imageUrls,"low"),t.current.add(f),n.current.delete(f),h});Promise.all(d)},2e3),()=>{clearTimeout(r.current),i&&i.abort()}},[e])},GS=j("div")({name:"AnswersContainer",class:"eda1nbdv32",propsAsIs:!1}),Y5=j("span")({name:"SelectBelowText",class:"eds1wn0vwj",propsAsIs:!1}),K5=j("div")({name:"Divider",class:"edd1ctwus6",propsAsIs:!1}),Q5=j("button")({name:"QuestAnswerCardWrapper",class:"edqfq64oi",propsAsIs:!1}),X5=j("div")({name:"Container",class:"edcbf1r91",propsAsIs:!1}),J5=({resourceIds:e})=>{const t=hr(n=>n.currentResources);return v.jsx(X5,{children:e.map(n=>{const r=t.find(i=>i.id===n);return v.jsx(BS,{iconId:r.iconId},n)})})},Z5=C.forwardRef(({blocksArray:e,handleClick:t,jourenyEdgeId:n,failedResources:r,replacements:i,...a},c)=>{const d=h=>{h.preventDefault(),h.stopPropagation(),t(n)},f=r.length===0;return v.jsx(WS,{isStickLeft:!0,style:{flex:"1 1 calc(50% - 6px)"},tooltipContent:f?null:v.jsx(J5,{resourceIds:r}),children:v.jsx(Q5,{"data-test":"button game",ref:c,style:{opacity:f?1:.6},isActive:!1,disabled:!f,onClick:d,...a,children:v.jsx(Ui,{blocksArray:e,isJourneyWidgetText:!0,replacements:i})})})}),e$=Z("form")({name:"Form",class:"edf1c40yuf",propsAsIs:!1}),t$=Z("textarea")({name:"Container",class:"edc1gf2psj",propsAsIs:!1}),n$=(e,t)=>{C.useEffect(()=>{const n=e.current;if(!n)return;const r=()=>{n.style.height="auto",n.style.height=n.scrollHeight+"px"};return r(),n.addEventListener("input",r),()=>n.removeEventListener("input",r)},[e,t])},r$=e=>{const t=C.useRef(null),{placeholder:n}=He(r=>r.translations.input);return n$(t),v.jsx(e$,{children:v.jsx(t$,{id:"answer",ref:t,maxLength:e.maxLength||250,placeholder:n,...e})})},s$=(e,t)=>{const n=qS(),r=hr(a=>a.setTextAnswer),i=hr(a=>a.textAnswer);return C.useEffect(()=>{r("")},[e==null?void 0:e.id]),[Rs.inputAnswerNode,Rs.ai].includes(e.type)?v.jsx(r$,{maxLength:e.responseLimit,value:i,onChange:a=>r(a.target.value)}):e.sourceEdges.map((a,c)=>v.jsx(Z5,{isAccessable:a.isAccessable,jourenyEdgeId:a.id,failedResources:a.failedResources,replacements:n,handleClick:d=>t(d),blocksArray:a.richText.blocks,index:c},a.id))},o$=({node:e,handleAnswerClick:t})=>{const n=s$(e,t);return v.jsxs(GS,{children:[v.jsx(K5,{}),n]})},i$=j("div")({name:"Container",class:"edc5xh5du",propsAsIs:!1}),a$=j("div")({name:"HideableContent",class:"edh89x7rh",propsAsIs:!1}),l$=j("div")({name:"Container",class:"edc170a6p7",propsAsIs:!1}),c$=j("div")({name:"TimerPadding",class:"edt1jyjufh",propsAsIs:!1}),u$=()=>{const t=Me(n=>n.quest).timeLimitSeconds===0;return v.jsx(l$,{children:t?null:v.jsx(c$,{children:v.jsx(IS,{type:"horizontal"})})})},YS=({children:e})=>{const t=Br(i=>i.isHidden),n=Br(i=>i.setRef),r=C.useRef(null);return C.useEffect(()=>{n(r)},[]),v.jsxs(i$,{children:[v.jsx(u$,{}),v.jsx(a$,{ref:r,style:{opacity:t?0:1,transition:`all ${ql}ms ease-out `},children:e})]})},d$=j("div")({name:"Container",class:"edc1i9husi",propsAsIs:!1}),f$=j("div")({name:"DotsContainer",class:"eddsynemh",propsAsIs:!1}),Xf=j("div")({name:"Dot",class:"edd1itpe37",propsAsIs:!1}),p$=({children:e})=>{const t=Br(n=>n.preloader);return t?v.jsx(d$,{children:v.jsxs(f$,{children:[t.text,v.jsx(Xf,{}),v.jsx(Xf,{}),v.jsx(Xf,{})]})}):e},h$=()=>{const{makeStep:e}=Io(),t=Me(a=>a.isFinished),n=hr(a=>a.currentNode),r=hr(a=>a.currentResources),i=He(a=>a.translations.journeyCard);return G5(),v.jsx(YS,{children:v.jsxs(p$,{children:[v.jsxs(kS,{children:[v.jsx(VS,{isNodeDescription:!0,blocksArray:n.data.blocks}),n.extraData?v.jsx(VS,{isNodeDescription:!0,blocksArray:n.extraData.blocks}):null,r.length>0&&v.jsx(U5,{resources:r})]}),t?v.jsx(DS,{translations:i}):v.jsx(o$,{node:n,handleAnswerClick:a=>e({journeyEdgeId:a})})]})})},m$=j("div")({name:"AnswersWrapper",class:"eda1vi3dgi",propsAsIs:!1}),g$=Z("label")({name:"Label",class:"edlzct43p",propsAsIs:!1}),y$=Z("input")({name:"HiddenInput",class:"edhtu66xn",propsAsIs:!1}),v$=()=>e=>e.isChecked?"var(--checkbox-bg-active)":"var(--checkbox-bg-default)",S$=Z("div")({name:"CustomInput",class:"edchq6avi",propsAsIs:!1,vars:{"chq6avi-0":[v$()]}}),w$=({label:e,id:t,name:n,index:r,onChange:i,isInsideChecked:a=null})=>{const c=d=>{const f=d.target.checked;i==null||i(f)};return v.jsxs(g$,{htmlFor:t,"data-testid":`edmap-widget__test-answer-${r+1}`,children:[v.jsx(y$,{id:t,name:n,type:"checkbox",checked:a,value:!a,onChange:c}),v.jsx(S$,{isChecked:a,children:a?v.jsx("svg",{width:"22",height:"16",viewBox:"0 0 22 16",fill:"none",xmlns:"http://www.w3.org/2000/svg",children:v.jsx("path",{d:"M1.5 7.56812L8.12121 14.1893L20.5 1.81055",stroke:"white",strokeWidth:"2",strokeLinecap:"square",strokeLinejoin:"round"})}):null}),v.jsx(Ui,{isAnswer:!0,blocksArray:e})]})},_$=({label:e,name:t,id:n,index:r,onChange:i,isInsideChecked:a=null})=>{const[c,d]=C.useState(!1),f=h=>{d(h),i==null||i(h)};return v.jsx(w$,{name:t,label:e,id:n,index:r,onChange:f,isInsideChecked:a||c})},E$=()=>{var d;const e=Me(f=>{var h;return(h=f.quest)==null?void 0:h.id}),t=Vl(f=>f.currentQuestion),n=Me(f=>f.isFinished),r=Vl(f=>f.addAnswer),i=He(f=>f.translations.testCard),a=Vl(f=>f.removeAnswer),c=(f,h,y)=>{y?r(e,f,h):a(f)};return v.jsx(YS,{children:n?v.jsx(DS,{translations:i}):v.jsxs(v.Fragment,{children:[v.jsx(kS,{children:v.jsx(Ui,{id:"edmap-widget__test-question",blocksArray:(d=t==null?void 0:t.text)==null?void 0:d.blocks})}),v.jsxs(GS,{children:[v.jsx(Y5,{children:i.chooseAnswer}),v.jsx(m$,{id:"edmap-widget__test-answers",children:t==null?void 0:t.answers.map((f,h)=>{var y;return v.jsx(_$,{index:h,label:(y=f==null?void 0:f.text)==null?void 0:y.blocks,id:f==null?void 0:f.id,onChange:g=>c(f==null?void 0:f.id,t==null?void 0:t.id,g)},f==null?void 0:f.id)})})]})]})})},x$=()=>{const e=Me(t=>t.quest);if(e!=null&&e.id)return e.questType==="Test"?v.jsx(E$,{test:e.test}):e.questType==="Journey"?v.jsx(h$,{data:e.journey}):null},k$=Tt.memo(x$),T$=({children:e})=>{const t=Me(n=>n.quest);return t!=null&&t.id?v.jsx("div",{children:e}):null},Jf=350,b$=1,I$=()=>{const e=Me(i=>i.quest),[t,n]=C.useState(!1);C.useEffect(()=>{if(!t)return;const i=setTimeout(()=>{kr.reportWidgetView()},b$*1e3);return()=>{clearTimeout(i)}},[t,e==null?void 0:e.id,e==null?void 0:e.mapId]),C.useEffect(()=>{kr.dropUserActivation()},[e==null?void 0:e.id,e==null?void 0:e.mapId]),C.useEffect(()=>{const i=()=>{kr.drainPendingAnalytics()};return window.addEventListener("pagehide",i),()=>{window.removeEventListener("pagehide",i)}},[]);const r=C.useCallback(i=>{i&&n(!i)},[]);return v.jsxs(v.Fragment,{children:[v.jsx(Ns,{topOffset:-Jf,setIsSensorTriggered:r,isBottomUpTriggered:!0,color:"blue",className:"view-counter-out",isPortal:!1}),v.jsx(Ns,{topOffset:-Jf,setIsSensorTriggered:n,color:"green",className:"view-counter-enter",isPortal:!1}),v.jsx(Ns,{bottomOffset:Jf,setIsSensorTriggered:n,isBottomUpTriggered:!0,color:"yellow",className:"view-counter-enter",isPortal:!1,isStickToBottom:!0}),v.jsx(Ns,{topOffset:0,setIsSensorTriggered:r,color:"green",className:"view-counter-out",isPortal:!1,isStickToBottom:!0})]})},C$=()=>{const e=Me(t=>t.quest);return C.useLayoutEffect(()=>{e!=null&&e.id&&localStorage.setItem("analytics",`${e.mapId}@${e.id}`)},[e==null?void 0:e.id]),null},KS=()=>{const e=C.useRef(),t=lc(R=>R.widgetContainerStyle),[n,r]=C.useState(!1),[i,a]=C.useState(!1),c=CS(R=>R.height),d=pr(R=>R.marginRootTop),f=pr(R=>R.setTopOffset),h=uc(R=>R.setWidth),y=uc(R=>R.top),g=RS(R=>R.height),w=uc(R=>R.setTop),x=cc(R=>R.setIsTimerOverlapped),_=C.useRef(),E=C.useRef(),k=30;o5(e,h),C.useEffect(()=>{e.current&&w(e.current.getBoundingClientRect().top+window.scrollY)},[e]),C.useEffect(()=>{if(!i)return;const R=()=>{const $=E.current;if(!$)return;const z=$.getBoundingClientRect().top;f(Math.max(0,-z))};return window.addEventListener("scroll",R),R(),()=>{f(0),window.removeEventListener("scroll",R)}},[i,c]);const O=y-d;return v.jsxs("edmap-view-root",{id:"edmap-view-root",children:[v.jsxs(U6,{className:"sensor root",children:[v.jsx(Ns,{className:"widget-trigger-header-stick",setIsSensorTriggered:r,topOffset:`${-d}px`,ref:_,isPortal:!1}),v.jsx(Ns,{setIsSensorTriggered:x,topOffset:`${O+c-k}px`}),v.jsx(I$,{}),v.jsxs(z6,{ref:e,style:{...t},children:[v.jsx(OS,{children:v.jsxs(T$,{children:[v.jsxs(H6,{children:[v.jsx(jD,{isSticky:n,parentRef:e}),v.jsx(W6,{children:v.jsx(ZD,{children:v.jsx(s5,{children:v.jsx(k$,{})})})})]}),v.jsx(zD,{})]})}),v.jsx(C$,{})]}),v.jsx(Ns,{isPortal:!1,isStickToBottom:!0,color:"black",className:"bottom sensor",setIsSensorTriggered:a,bottomOffset:`${g+c+d}px`,isBottomUpTriggered:!1,ref:E})]}),v.jsx(k6,{})]})},R$=j("div")({name:"WrapperForStyles",class:"edw1ckr4k2",propsAsIs:!1}),A$=j("div")({name:"Container",class:"edc1moeqqj",propsAsIs:!1}),O$=j("div")({name:"Container",class:"edcrg0ist",propsAsIs:!1}),P$=j("p")({name:"EmptyQuestsMessage",class:"ede1tl4sfq",propsAsIs:!1}),N$=j("div")({name:"Container",class:"edcjx2ut5",propsAsIs:!1}),M$=j("p")({name:"Title",class:"edt75yszp",propsAsIs:!1}),QS=({title:e,children:t})=>v.jsxs(N$,{children:[v.jsx(M$,{children:e}),t]}),L$=({quests:e})=>{const t=He(r=>r.translations.questList),n=!e||e.length===0;return v.jsx(QS,{title:t.title,children:v.jsx(O$,{children:n?v.jsx(P$,{children:t.emptyQuestsWarning}):v.jsx(Tf,{quests:e})})})},j$=j("div")({name:"PrizesContainer",class:"edp1163kd8",propsAsIs:!1}),D$=()=>{const e=Ct(r=>r.results),t=He(r=>r.translations.prizeList),n=(e==null?void 0:e.prizes)||[];return!n||n.length===0?null:v.jsx(QS,{title:t.title,children:v.jsx(j$,{children:n.map((r,i)=>v.jsx(_f,{prizeData:r,userPoints:(e==null?void 0:e.allPoints)||0,index:i},r.id))})})},$$=()=>{const e=Ct(r=>r.results),t=(e==null?void 0:e.quests)||[],n=lc(r=>r.widgetContainerStyle);return v.jsx(R$,{style:n,children:v.jsx(A$,{children:v.jsxs(OS,{children:[v.jsx(L$,{quests:t}),v.jsx(D$,{}),v.jsx(dv,{}),v.jsx(vS,{})]})})})},F$=[gf,yf,O1],XS={color:{[R1]:["light"],[gf]:[],[nN]:["white","blue"]},rounded:{[A1]:["rounded"],[yf]:[]},text:{[rN]:["bold","text"],[O1]:[]},wordWrap:{[sN]:[],[oN]:["nowrap"]}},B$=Object.keys(XS).map(e=>Object.entries(XS[e]).sort(([t,n],[r,i])=>i.length-n.length)),z$=e=>{if(!e)return F$;const t=e.split("-");return B$.map(r=>r.find(([i,a])=>a.every(c=>t.includes(c)))).map(r=>r[0])},U$={"--main-color":["--edmap-main-color"],"--main-shadow-color":["--edmap-main-color-shadow"],"--main-dark-color":["--edmap-main-color-dark"],"--text-on-main":["--edmap-text-on-main"]},H$=e=>{const t={};return Object.keys(e).forEach(n=>{U$[n].forEach(r=>{t[r]=e[n]})}),t},W$=()=>{var t;const e=H$(((t=window==null?void 0:window.__widgetEdmap)==null?void 0:t.cssVariablesOverride)??{});Object.keys(e).forEach(n=>{document.body.style.setProperty(n,e[n],"important")})},q$=()=>{var n;const e=((n=window.__widgetEdmap)==null?void 0:n.headerOffset)||0,t=e!==null&&typeof e=="object";return t?G$(t,e):[{width:0,value:dc(e)}]},V$=e=>Object.keys(e).sort((n,r)=>r-n).map(n=>({width:Number(n),value:e[n]})),G$=(e,t)=>{if(!e)return dc(t);const n=Object.keys(t).reduce((r,i)=>{const a=dc(i),c=dc(t[i]);return{...r,[a]:c}},{});return V$(n)},dc=e=>Number.parseFloat(e)||0,Y$=()=>{const[e,t]=C.useState(window.innerWidth);K$(e),C.useEffect(()=>{const n=()=>t(window.innerWidth);n(),window.addEventListener("resize",n)},[])},K$=e=>{const t=pr(i=>i.breakPoints),n=pr(i=>i.setMarginRootTop),r=pr(i=>i.marginRootTop);C.useEffect(()=>{if(!t)return;const i=t.find(a=>e>a.width);i&&i.value!==r&&n(i.value)},[t,e,e])},Q$=[R1,gf,A1,yf],X$=[{id:"edmap-widget__container",Component:KS},{id:"edmap-widget-quest-picker__container",Component:$$}];console.log("Выполнен код вне корня");function J$({mode:e=null}){var R;const t=Me($=>$.setQuest),{cleanQuestInit:n}=Io(),r=Ct($=>$.setUserResults),i=Ct($=>$.setPointsAreReceived),a=He($=>$.setLocale),c=pr($=>$.setBreakPoints),{setPopupBarStyle:d,setWidgetContainerStyle:f}=lc(),[h,y]=C.useState([]);Y$();const g=B6(e,window.location.pathname),x=new URLSearchParams(window.location.search).get("code"),_=async($,H,z)=>{let M=null;return H==="admin"?M=await YP(z):M=await GP($,z),M},E=()=>{const $=X$.filter(({id:H})=>document.getElementById(H));y($)},k=()=>{var $;document.body.classList.remove(...Q$),document.body.classList.add(...z$(($=window==null?void 0:window.__widgetEdmap)==null?void 0:$.theme)),W$()},O=()=>{E(),k()};return C.useEffect(()=>{O()},[]),C.useEffect(()=>{window.__widgetEdmap&&(window.__widgetEdmap.mode=e)},[e]),C.useEffect(()=>{(async()=>{var z;const H=(z=window==null?void 0:window.__widgetEdmap)==null?void 0:z.mapId;if(H){i(!1);try{if(!h.some(({id:U})=>U==="edmap-widget__container")&&e!=="admin")return;const L=await _(H,e,g);if(!L)return;t(L),await n(L)}catch(M){An(M),console.error("Error during initialization:",M)}}})()},[e,g,h]),C.useEffect(()=>{var H;const $=(H=window==null?void 0:window.__widgetEdmap)==null?void 0:H.mapId;$&&VP($,x).then(z=>{a(z.map.widgetUILanguage),r(z)})},[x,g]),C.useEffect(()=>{h.forEach(({id:$})=>{const H=document.getElementById($);H&&(H.dataset.popupBarStyle&&d(xS(H.dataset.popupBarStyle)),H.dataset.widgetContainerStyle&&f(xS(H.dataset.widgetContainerStyle)))})},[h]),C.useEffect(()=>{const $=q$();c($)},[]),e==="admin"?v.jsx(KS,{}):h.length===0||!((R=window==null?void 0:window.__widgetEdmap)!=null&&R.mapId)?null:v.jsxs(v.Fragment,{children:[h.map(({id:$,Component:H})=>{const z=document.getElementById($);return z?Hi.createPortal(v.jsx(H,{},$+(window.location.pathname||"")),z):null}),e!=="admin"&&Hi.createPortal(v.jsx(F6,{},window.location.pathname||""),document.body)]})}MP({dsn:"https://f54e3fc0fb41b6b943cd81aa16c927d3@o4508675319726080.ingest.de.sentry.io/4508676111138896",integrations:[AP(),yP()],tracesSampleRate:1,tracePropagationTargets:["localhost","https://api.edmap.space"],replaysSessionSampleRate:.1,replaysOnErrorSampleRate:1});const Z$=e=>new Promise(t=>{setTimeout(t,e)}),e8=async e=>{let t=0;for(;t<10;){for(const n of e){const r=document.getElementById(n);if(r)return console.log(`${n} was found`),r}await Z$(200+100*t),t++}return null};let Zf=!1;const JS=async()=>{if(!Zf){Zf=!0;try{await e8(["edmap-widget__container","edmap-widget-quest-picker__container"])&&t8()}finally{Zf=!1}}},t8=()=>{if(typeof window>"u"){console.log("Widget loaded in node env");return}let e=document.querySelector("#invisible-edmap-container");e&&e.remove(),e=document.createElement("div"),e.setAttribute("id","invisible-edmap-container"),e.style.display="none",e.style.pointerEvents="none",document.body.appendChild(e);const t=YE.createRoot(e);window.__edmapRoot=t,t.render(v.jsx(C.StrictMode,{children:v.jsx(J$,{})}))};function ZS(e,t,n=!1){let r;function i(){const a=this,c=arguments,d=function(){r=null,n||e.apply(a,c)},f=n&&!r;clearTimeout(r),r=setTimeout(d,t),f&&e.apply(a,c)}return i.cancel=function(){clearTimeout(r),r=null},i}(function(){window.__widgetEdmap=window.__widgetEdmap||{};let e=0;const t=ZS(()=>{JS()},50),n=()=>{const i=window.__edmapRoot;window.__edmapRoot?Promise.resolve().then(()=>{window.__edmapRoot&&(i.unmount(),tN(),JS())}):t()},r=ZS(i=>{e=i},300);window.addEventListener("edmap-routing-triggered",i=>{var c,d,f;if(document.getElementById("edmap-view-root")){console.log("routing ignored");return}const a=i.detail.type;if(a==="pushState"&&n(a,i.detail),a=="replaceState"){const h=(f=(d=(c=i.detail)==null?void 0:c.args)==null?void 0:d[0])==null?void 0:f.scrollY;if(!(typeof h=="number"&&!Number.isNaN(h)))return;e===h?n():r(h);return}if(a==="popstate"){n(),e=0;return}}),window.addEventListener(mt.unmounted,()=>{console.log("unmount triggered search for container"),n()}),n(),console.log("routing trigger loaded")})()})();
